🐛 Fix issues with updating tiles

This commit is contained in:
Meier Lukas
2023-03-30 22:54:08 +02:00
parent 525985b1dc
commit 8c59ab0846
7 changed files with 23 additions and 34 deletions

View File

@@ -9,6 +9,7 @@ import { WidgetEditModalInnerProps } from './WidgetsEditModal';
import { WidgetsRemoveModalInnerProps } from './WidgetsRemoveModal';
export type WidgetChangePositionModalInnerProps = {
widgetId: string;
widgetType: string;
widget: IWidget<string, any>;
wrapperColumnCount: number;
@@ -38,14 +39,9 @@ export const WidgetsMenu = ({ integration, widget }: WidgetsMenuProps) => {
modal: 'integrationRemove',
title: <Title order={4}>{t('common:remove')}</Title>,
innerProps: {
widgetId: widget.id,
widgetType: integration,
},
styles: {
inner: {
position: 'sticky',
top: 30,
},
},
});
};
@@ -55,6 +51,7 @@ export const WidgetsMenu = ({ integration, widget }: WidgetsMenuProps) => {
size: 'xl',
title: null,
innerProps: {
widgetId: widget.id,
widgetType: integration,
widget,
wrapperColumnCount,
@@ -65,8 +62,9 @@ export const WidgetsMenu = ({ integration, widget }: WidgetsMenuProps) => {
const handleEditClick = () => {
openContextModalGeneric<WidgetEditModalInnerProps>({
modal: 'integrationOptions',
title: t('descriptor.settings.title'),
title: <Title order={4}>{t('descriptor.settings.title')}</Title>,
innerProps: {
widgetId: widget.id,
widgetType: integration,
options: widget.properties,
// Cast as the right type for the correct widget