diff --git a/assets/controllers/iframe_controller.js b/assets/controllers/iframe_controller.js new file mode 100644 index 0000000..c7f0442 --- /dev/null +++ b/assets/controllers/iframe_controller.js @@ -0,0 +1,13 @@ +import { Controller } from '@hotwired/stimulus' + +export default class extends Controller { + connect() { + if ('parentIframe' in window) { + window.iFrameResizer = { + onReady: function () { + window.parentIFrame.scrollTo(0, 0) + } + } + } + } +} \ No newline at end of file diff --git a/templates/booking/edit.html.twig b/templates/booking/edit.html.twig index 35b2a74..ef072b3 100644 --- a/templates/booking/edit.html.twig +++ b/templates/booking/edit.html.twig @@ -7,7 +7,7 @@ {% set messages = form.vars.errors|map(error => error.message) %} {% include '_partials/_alert.html.twig' with { 'level': 'error', 'title': 'Die Buchung konnte nicht aktualisiert werden', 'messages': messages } %} {% endif %} -
+
@@ -210,7 +210,7 @@ zurück