diff --git a/web/app/configs/widget/custom/custom.widget.component.html b/web/app/configs/widget/custom/custom.widget.component.html index 96308f1..94ae81f 100644 --- a/web/app/configs/widget/custom/custom.widget.component.html +++ b/web/app/configs/widget/custom/custom.widget.component.html @@ -2,28 +2,34 @@ + + + + +
- - + - +
+ +
@@ -33,31 +39,16 @@ title="{{ widget.name || widget.url || defaultName }}">
- - + - - - +
+ + +
diff --git a/web/app/configs/widget/widget.component.ts b/web/app/configs/widget/widget.component.ts index fce9cb8..17408b2 100644 --- a/web/app/configs/widget/widget.component.ts +++ b/web/app/configs/widget/widget.component.ts @@ -313,21 +313,4 @@ export class NewWidgetComponent { this.unpackWidget(widget); this.OnWidgetPreparedForEdit.emit(widget); } - - /** - * Determines if a widget has had any changes made to it - * @param {EditableWidget} widget The widget to check - * @returns {boolean} True if the widget has been edited - */ - public hasChanges(widget: EditableWidget): boolean { - if (widget.dimension.newUrl !== this.unwrapUrl(widget.url)) return true; - if (widget.dimension.newName !== widget.name) return true; - if (widget.dimension.newTitle !== widget.data.title) return true; - - const currentData = JSON.parse(JSON.stringify(widget.data || "{}")); - const newData = JSON.parse(JSON.stringify(widget.dimension.newData || "{}")); - if (currentData !== newData) return true; - - return false; - } } \ No newline at end of file