You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Components that need JS (selects, date pickers, file inputs, conditional display, editors) declare their assets with javaabu/manifest so they load automatically. Replace the dependency on js-utilities globals where practical; JS strings use @javaabu/i18n.
Done on next-gen (up to 8ae5828); CI green, including the new Assets job (lint, format, typecheck, 151 Vitest tests with coverage to Codecov, build diff).
Manifest:Assets::register() declares forms::forms (core), forms::select, forms::dates, forms::files, forms::wysiwyg and forms::onu (the prebuilt stylesheet). Components implement manifest's DeclaresAssets, so each page loads only what it uses; for example, plain selects don't load Tom Select. The JS alias is @javaabu/forms-blade, because @javaabu/forms is the React package's name.
js-utilities replaced (TypeScript, no jQuery): conditional display, select all, table sorting, submit spinner, focus on error, Thaana typing (@javaabu/onu/thaana), auto-resize, decimals, and the Onu dialog/tab/alert/menu widgets. Select2 is replaced by Tom Select, with the same data- attributes, ajax query format and cascades; flatpickr handles dates (with a Dhivehi locale); file inputs and uploads are ported too. TinyMCE stays app-hosted, with a configurable URL.
Prebuilt dist/ with .vite/manifest.json is committed for apps without Vite; apps with manifest's Vite plugin build from source.
i18n: the JS strings come from lang/{en,dv}. @javaabu/i18n can't be installed from GitHub yet because it has no prepare script (Add a prepare script so GitHub installs (github:Javaabu/i18n#main) get dist/ i18n#3), so a temporary local __() with the same signature is used. Switching later is a one-line change in resources/js/lang.ts.
Not ported (no v2 view uses them): js-utilities' data-select-children, data-toggle-hide, .select2-b-image, and the map selector, which v1 also left to apps.
Activity
Ship JS and CSS through javaabu/manifest; fix bugs found in review
n4ff4h commentedon Nov 4, 2026
Done on
next-gen(up to 8ae5828); CI green, including the new Assets job (lint, format, typecheck, 151 Vitest tests with coverage to Codecov, build diff).Assets::register()declaresforms::forms(core),forms::select,forms::dates,forms::files,forms::wysiwygandforms::onu(the prebuilt stylesheet). Components implement manifest'sDeclaresAssets, so each page loads only what it uses; for example, plain selects don't load Tom Select. The JS alias is@javaabu/forms-blade, because@javaabu/formsis the React package's name.@javaabu/onu/thaana), auto-resize, decimals, and the Onu dialog/tab/alert/menu widgets. Select2 is replaced by Tom Select, with the samedata-attributes, ajax query format and cascades; flatpickr handles dates (with a Dhivehi locale); file inputs and uploads are ported too. TinyMCE stays app-hosted, with a configurable URL.dist/with.vite/manifest.jsonis committed for apps without Vite; apps with manifest's Vite plugin build from source.lang/{en,dv}.@javaabu/i18ncan't be installed from GitHub yet because it has nopreparescript (Add a prepare script so GitHub installs (github:Javaabu/i18n#main) get dist/ i18n#3), so a temporary local__()with the same signature is used. Switching later is a one-line change inresources/js/lang.ts.data-select-children,data-toggle-hide,.select2-b-image, and the map selector, which v1 also left to apps.