feat(16.2-01): host plugin field type elements in the admin SPA
- loadFieldTypes fetches GET /field-types after sign-in, loads each script once and adds the styles as global links activateStyles never disables - PluginField creates the type's element, sets the value property and the contract attributes, takes summer-change as the form value and never writes back a value the element just emitted - rendererForField and isRegisteredField route any field with an element to PluginField in forms, previews and the save payload - rebuilt modules/boardwalk/dist
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
import { ref } from 'vue'
|
||||
import { useRoute, useRouter } from 'vue-router'
|
||||
import { CircleAlert, Sun } from '@lucide/vue'
|
||||
import { loadFieldTypes } from '../app/fieldTypes'
|
||||
import { t } from '../app/i18n'
|
||||
import { safeRedirect } from '../app/router'
|
||||
import { login, me } from '../state/useAuth'
|
||||
@@ -29,7 +30,7 @@ async function submit(): Promise<void> {
|
||||
return
|
||||
}
|
||||
password.value = ''
|
||||
await Promise.all([loadNavigation(), loadSettings().catch(() => [])])
|
||||
await Promise.all([loadNavigation(), loadSettings().catch(() => []), loadFieldTypes()])
|
||||
await router.replace(safeRedirect(route.query.redirect) ?? '/')
|
||||
} finally {
|
||||
busy.value = false
|
||||
|
||||
Reference in New Issue
Block a user