From a83fffc6a6f5559dfcff15af73fb5bfcf6f6846e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Oliver=20G=C3=BCnther?= Date: Mon, 29 Jul 2024 11:09:05 +0200 Subject: [PATCH] Fix generic drag & drop controller --- .../admin/types/type-form-configuration.component.ts | 10 +++++----- .../draggable-autocomplete.component.ts | 2 +- .../dynamic/admin/custom-fields.controller.ts | 2 +- .../dynamic/generic-drag-and-drop.controller.ts | 2 +- .../meeting-agenda-item-drag-and-drop.controller.ts | 2 +- 5 files changed, 9 insertions(+), 9 deletions(-) diff --git a/frontend/src/app/features/admin/types/type-form-configuration.component.ts b/frontend/src/app/features/admin/types/type-form-configuration.component.ts index c7772f01d40..9400bd0a1f9 100644 --- a/frontend/src/app/features/admin/types/type-form-configuration.component.ts +++ b/frontend/src/app/features/admin/types/type-form-configuration.component.ts @@ -1,9 +1,9 @@ -import { - AfterViewInit, Component, ElementRef, OnInit, -} from '@angular/core'; +import { AfterViewInit, Component, ElementRef, OnInit, } from '@angular/core'; import { I18nService } from 'core-app/core/i18n/i18n.service'; import { ToastService } from 'core-app/shared/components/toaster/toast.service'; -import { ExternalRelationQueryConfigurationService } from 'core-app/features/work-packages/components/wp-table/external-configuration/external-relation-query-configuration.service'; +import { + ExternalRelationQueryConfigurationService +} from 'core-app/features/work-packages/components/wp-table/external-configuration/external-relation-query-configuration.service'; import { DomAutoscrollService } from 'core-app/shared/helpers/drag-and-drop/dom-autoscroll.service'; import { DragulaService, DrakeWithModels } from 'ng2-dragula'; import { GonService } from 'core-app/core/gon/gon.service'; @@ -141,7 +141,7 @@ export class TypeFormConfigurationComponent extends UntilDestroyedMixin implemen const that = this; this.autoscroll = new DomAutoscrollService( [ - document.getElementById('content-wrapper')!, + document.getElementById('content-body')!, ], { margin: 25, diff --git a/frontend/src/app/shared/components/autocompleter/draggable-autocomplete/draggable-autocomplete.component.ts b/frontend/src/app/shared/components/autocompleter/draggable-autocomplete/draggable-autocomplete.component.ts index e641005df4a..36b59bb82a8 100644 --- a/frontend/src/app/shared/components/autocompleter/draggable-autocomplete/draggable-autocomplete.component.ts +++ b/frontend/src/app/shared/components/autocompleter/draggable-autocomplete/draggable-autocomplete.component.ts @@ -117,7 +117,7 @@ export class DraggableAutocompleteComponent extends UntilDestroyedMixin implemen const that = this; this.autoscroll = new DomAutoscrollService( [ - document.getElementById('content-wrapper')!, + document.getElementById('content-body')!, ], { margin: 25, diff --git a/frontend/src/stimulus/controllers/dynamic/admin/custom-fields.controller.ts b/frontend/src/stimulus/controllers/dynamic/admin/custom-fields.controller.ts index c8dd3a30705..c0af7f360bf 100644 --- a/frontend/src/stimulus/controllers/dynamic/admin/custom-fields.controller.ts +++ b/frontend/src/stimulus/controllers/dynamic/admin/custom-fields.controller.ts @@ -257,7 +257,7 @@ export default class CustomFieldsController extends Controller { // eslint-disable-next-line no-new new pluginContext.classes.DomAutoscrollService( [ - document.getElementById('content-wrapper') as HTMLElement, + document.getElementById('content-body') as HTMLElement, ], { margin: 25, diff --git a/frontend/src/stimulus/controllers/dynamic/generic-drag-and-drop.controller.ts b/frontend/src/stimulus/controllers/dynamic/generic-drag-and-drop.controller.ts index cbe9cd9c06b..b783836e7b7 100644 --- a/frontend/src/stimulus/controllers/dynamic/generic-drag-and-drop.controller.ts +++ b/frontend/src/stimulus/controllers/dynamic/generic-drag-and-drop.controller.ts @@ -75,7 +75,7 @@ export default class extends Controller { // eslint-disable-next-line no-new new pluginContext.classes.DomAutoscrollService( [ - document.getElementById('content-wrapper') as HTMLElement, + document.getElementById('content-body') as HTMLElement, ], { margin: 25, diff --git a/frontend/src/stimulus/controllers/dynamic/meeting-agenda-item-drag-and-drop.controller.ts b/frontend/src/stimulus/controllers/dynamic/meeting-agenda-item-drag-and-drop.controller.ts index 458894bf438..88cbd4fccb8 100644 --- a/frontend/src/stimulus/controllers/dynamic/meeting-agenda-item-drag-and-drop.controller.ts +++ b/frontend/src/stimulus/controllers/dynamic/meeting-agenda-item-drag-and-drop.controller.ts @@ -42,7 +42,7 @@ export default class extends Controller { // eslint-disable-next-line no-new new pluginContext.classes.DomAutoscrollService( [ - document.getElementById('content-wrapper') as HTMLElement, + document.getElementById('content-body') as HTMLElement, ], { margin: 25,