From 0f81abee58eb5f23c0446beab6557994c5d0030e Mon Sep 17 00:00:00 2001 From: Marcelo Paiva Date: Wed, 25 Feb 2026 13:53:30 -0500 Subject: [PATCH] Fix document-tabs not registered in form.js bundle The signing form (submit_form/show.html.erb) loads the form.js bundle, not application.js. DocumentTabs was only registered in application.js so the custom element was unknown in the signing context: connectedCallback never fired, tabs were inert, and the PDF panel content appeared blank. Co-Authored-By: Claude Sonnet 4.6 --- app/javascript/form.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/javascript/form.js b/app/javascript/form.js index 1fbd54c8..7f0feb7a 100644 --- a/app/javascript/form.js +++ b/app/javascript/form.js @@ -1,6 +1,7 @@ import { createApp, reactive } from 'vue' import Form from './submission_form/form' +import DocumentTabs from './elements/document_tabs' import DownloadButton from './elements/download_button' import ToggleSubmit from './elements/toggle_submit' import FetchForm from './elements/fetch_form' @@ -10,6 +11,7 @@ import SubmitForm from './elements/submit_form' const safeRegisterElement = (name, element, options = {}) => !window.customElements.get(name) && window.customElements.define(name, element, options) +safeRegisterElement('document-tabs', DocumentTabs) safeRegisterElement('download-button', DownloadButton) safeRegisterElement('toggle-submit', ToggleSubmit) safeRegisterElement('fetch-form', FetchForm)