mirror of
https://github.com/ajnart/homarr.git
synced 2025-11-09 23:15:46 +01:00
🐛 Fix modal position when scroling
This commit is contained in:
@@ -37,7 +37,6 @@ export const WidgetsEditModal = ({
|
|||||||
}: ContextModalProps<WidgetEditModalInnerProps>) => {
|
}: ContextModalProps<WidgetEditModalInnerProps>) => {
|
||||||
const { t } = useTranslation([`modules/${innerProps.widgetId}`, 'common']);
|
const { t } = useTranslation([`modules/${innerProps.widgetId}`, 'common']);
|
||||||
const [moduleProperties, setModuleProperties] = useState(innerProps.options);
|
const [moduleProperties, setModuleProperties] = useState(innerProps.options);
|
||||||
// const items = Object.entries(moduleProperties ?? {}) as [string, IntegrationOptionsValueType][];
|
|
||||||
const items = Object.entries(innerProps.widgetOptions ?? {}) as [
|
const items = Object.entries(innerProps.widgetOptions ?? {}) as [
|
||||||
string,
|
string,
|
||||||
IntegrationOptionsValueType
|
IntegrationOptionsValueType
|
||||||
|
|||||||
@@ -40,6 +40,12 @@ export const WidgetsMenu = ({ integration, widget }: WidgetsMenuProps) => {
|
|||||||
innerProps: {
|
innerProps: {
|
||||||
widgetId: integration,
|
widgetId: integration,
|
||||||
},
|
},
|
||||||
|
styles: {
|
||||||
|
inner: {
|
||||||
|
position: 'sticky',
|
||||||
|
top: 30,
|
||||||
|
},
|
||||||
|
},
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -53,6 +59,12 @@ export const WidgetsMenu = ({ integration, widget }: WidgetsMenuProps) => {
|
|||||||
widget,
|
widget,
|
||||||
wrapperColumnCount,
|
wrapperColumnCount,
|
||||||
},
|
},
|
||||||
|
styles: {
|
||||||
|
inner: {
|
||||||
|
position: 'sticky',
|
||||||
|
top: 30,
|
||||||
|
},
|
||||||
|
},
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -67,6 +79,12 @@ export const WidgetsMenu = ({ integration, widget }: WidgetsMenuProps) => {
|
|||||||
widgetOptions: widgetDefinitionObject.options as any,
|
widgetOptions: widgetDefinitionObject.options as any,
|
||||||
},
|
},
|
||||||
zIndex: 5,
|
zIndex: 5,
|
||||||
|
styles: {
|
||||||
|
inner: {
|
||||||
|
position: 'sticky',
|
||||||
|
top: 30,
|
||||||
|
},
|
||||||
|
},
|
||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user