@cwa/nuxt-edge 1.0.0-29138192.e49c1a0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +38 -0
- package/README.template.md +32 -0
- package/dist/layer/error.vue +13 -0
- package/dist/layer/layouts/CwaRootLayout.vue +140 -0
- package/dist/layer/nuxt.config.spec.ts +10 -0
- package/dist/layer/nuxt.config.ts +3 -0
- package/dist/layer/pages/_cwa/composables/useDataList.ts +50 -0
- package/dist/layer/pages/_cwa/composables/useDataType.ts +30 -0
- package/dist/layer/pages/_cwa/composables/useDynamicPageLoader.ts +28 -0
- package/dist/layer/pages/_cwa/composables/useItemPage.ts +172 -0
- package/dist/layer/pages/_cwa/composables/useListPage.ts +43 -0
- package/dist/layer/pages/_cwa/data/[type]/[iri].vue +17 -0
- package/dist/layer/pages/_cwa/data/[type].vue +131 -0
- package/dist/layer/pages/_cwa/data/index.vue +84 -0
- package/dist/layer/pages/_cwa/layouts/[iri].vue +174 -0
- package/dist/layer/pages/_cwa/layouts.vue +77 -0
- package/dist/layer/pages/_cwa/pages/[iri].vue +11 -0
- package/dist/layer/pages/_cwa/pages.vue +129 -0
- package/dist/layer/pages/_cwa/routes.vue +72 -0
- package/dist/layer/pages/_cwa/users/[iri].vue +248 -0
- package/dist/layer/pages/_cwa/users.vue +86 -0
- package/dist/layer/pages/_cwa.vue +43 -0
- package/dist/layer/pages/forgot-password.vue +32 -0
- package/dist/layer/pages/login.vue +33 -0
- package/dist/layer/pages/reset-password/[username]/[token].vue +39 -0
- package/dist/module.d.mts +53 -0
- package/dist/module.json +13 -0
- package/dist/module.mjs +235 -0
- package/dist/runtime/admin/admin.d.ts +36 -0
- package/dist/runtime/admin/admin.js +65 -0
- package/dist/runtime/admin/manageable-resource.d.ts +41 -0
- package/dist/runtime/admin/manageable-resource.js +206 -0
- package/dist/runtime/admin/manager-tabs-resolver.d.ts +17 -0
- package/dist/runtime/admin/manager-tabs-resolver.js +51 -0
- package/dist/runtime/admin/navigation-guard.d.ts +18 -0
- package/dist/runtime/admin/navigation-guard.js +55 -0
- package/dist/runtime/admin/resource-stack-manager.d.ts +92 -0
- package/dist/runtime/admin/resource-stack-manager.js +355 -0
- package/dist/runtime/api/api-documentation.d.ts +28 -0
- package/dist/runtime/api/api-documentation.js +131 -0
- package/dist/runtime/api/auth.d.ts +85 -0
- package/dist/runtime/api/auth.js +183 -0
- package/dist/runtime/api/fetcher/cwa-fetch.d.ts +5 -0
- package/dist/runtime/api/fetcher/cwa-fetch.js +20 -0
- package/dist/runtime/api/fetcher/fetch-status-manager.d.ts +51 -0
- package/dist/runtime/api/fetcher/fetch-status-manager.js +185 -0
- package/dist/runtime/api/fetcher/fetcher.d.ts +57 -0
- package/dist/runtime/api/fetcher/fetcher.js +222 -0
- package/dist/runtime/api/fetcher/preload-headers.d.ts +6 -0
- package/dist/runtime/api/fetcher/preload-headers.js +31 -0
- package/dist/runtime/api/forms.d.ts +40 -0
- package/dist/runtime/api/forms.js +40 -0
- package/dist/runtime/api/mercure.d.ts +33 -0
- package/dist/runtime/api/mercure.js +191 -0
- package/dist/runtime/composables/component/html-content.d.ts +2 -0
- package/dist/runtime/composables/component/html-content.js +82 -0
- package/dist/runtime/composables/cwa-collection-pagination.d.ts +13 -0
- package/dist/runtime/composables/cwa-collection-pagination.js +34 -0
- package/dist/runtime/composables/cwa-collection-resource.d.ts +16 -0
- package/dist/runtime/composables/cwa-collection-resource.js +92 -0
- package/dist/runtime/composables/cwa-image.d.ts +19 -0
- package/dist/runtime/composables/cwa-image.js +43 -0
- package/dist/runtime/composables/cwa-query-bound-model.d.ts +9 -0
- package/dist/runtime/composables/cwa-query-bound-model.js +108 -0
- package/dist/runtime/composables/cwa-resource-endpoint.d.ts +5 -0
- package/dist/runtime/composables/cwa-resource-endpoint.js +36 -0
- package/dist/runtime/composables/cwa-resource-manageable.d.ts +10 -0
- package/dist/runtime/composables/cwa-resource-manageable.js +32 -0
- package/dist/runtime/composables/cwa-resource-manager-tab.d.ts +17 -0
- package/dist/runtime/composables/cwa-resource-manager-tab.js +30 -0
- package/dist/runtime/composables/cwa-resource-model.d.ts +21 -0
- package/dist/runtime/composables/cwa-resource-model.js +149 -0
- package/dist/runtime/composables/cwa-resource-upload.d.ts +8 -0
- package/dist/runtime/composables/cwa-resource-upload.js +70 -0
- package/dist/runtime/composables/cwa-resource.d.ts +24 -0
- package/dist/runtime/composables/cwa-resource.js +22 -0
- package/dist/runtime/composables/cwa-select-input.d.ts +21 -0
- package/dist/runtime/composables/cwa-select-input.js +37 -0
- package/dist/runtime/composables/cwa-select.d.ts +15 -0
- package/dist/runtime/composables/cwa-select.js +24 -0
- package/dist/runtime/composables/cwa.d.ts +2 -0
- package/dist/runtime/composables/cwa.js +2 -0
- package/dist/runtime/composables/forgot-password.d.ts +9 -0
- package/dist/runtime/composables/forgot-password.js +45 -0
- package/dist/runtime/composables/login.d.ts +9 -0
- package/dist/runtime/composables/login.js +30 -0
- package/dist/runtime/composables/popper.d.ts +529 -0
- package/dist/runtime/composables/popper.js +104 -0
- package/dist/runtime/composables/process.d.ts +4 -0
- package/dist/runtime/composables/process.js +6 -0
- package/dist/runtime/composables/reset-password.d.ts +14 -0
- package/dist/runtime/composables/reset-password.js +75 -0
- package/dist/runtime/composables/transitions.d.ts +12 -0
- package/dist/runtime/composables/transitions.js +12 -0
- package/dist/runtime/cwa.d.ts +61 -0
- package/dist/runtime/cwa.js +123 -0
- package/dist/runtime/errors/cwa-resource-error.d.ts +18 -0
- package/dist/runtime/errors/cwa-resource-error.js +54 -0
- package/dist/runtime/plugin.d.ts +7 -0
- package/dist/runtime/plugin.js +18 -0
- package/dist/runtime/resources/resource-utils.d.ts +44 -0
- package/dist/runtime/resources/resource-utils.js +73 -0
- package/dist/runtime/resources/resources-manager.d.ts +70 -0
- package/dist/runtime/resources/resources-manager.js +463 -0
- package/dist/runtime/resources/resources.d.ts +53 -0
- package/dist/runtime/resources/resources.js +300 -0
- package/dist/runtime/route-middleware.d.ts +2 -0
- package/dist/runtime/route-middleware.js +86 -0
- package/dist/runtime/storage/storage.d.ts +20 -0
- package/dist/runtime/storage/storage.js +25 -0
- package/dist/runtime/storage/stores/admin/actions.d.ts +5 -0
- package/dist/runtime/storage/stores/admin/actions.js +10 -0
- package/dist/runtime/storage/stores/admin/admin-store.d.ts +18 -0
- package/dist/runtime/storage/stores/admin/admin-store.js +20 -0
- package/dist/runtime/storage/stores/admin/state.d.ts +7 -0
- package/dist/runtime/storage/stores/admin/state.js +9 -0
- package/dist/runtime/storage/stores/api-documentation/api-documentation-store.d.ts +16 -0
- package/dist/runtime/storage/stores/api-documentation/api-documentation-store.js +18 -0
- package/dist/runtime/storage/stores/api-documentation/state.d.ts +74 -0
- package/dist/runtime/storage/stores/api-documentation/state.js +6 -0
- package/dist/runtime/storage/stores/auth/auth-store.d.ts +16 -0
- package/dist/runtime/storage/stores/auth/auth-store.js +18 -0
- package/dist/runtime/storage/stores/auth/state.d.ts +20 -0
- package/dist/runtime/storage/stores/auth/state.js +15 -0
- package/dist/runtime/storage/stores/cwa-store-types.d.ts +14 -0
- package/dist/runtime/storage/stores/error/actions.d.ts +11 -0
- package/dist/runtime/storage/stores/error/actions.js +69 -0
- package/dist/runtime/storage/stores/error/error-store.d.ts +13 -0
- package/dist/runtime/storage/stores/error/error-store.js +21 -0
- package/dist/runtime/storage/stores/error/getters.d.ts +7 -0
- package/dist/runtime/storage/stores/error/getters.js +11 -0
- package/dist/runtime/storage/stores/error/state.d.ts +35 -0
- package/dist/runtime/storage/stores/error/state.js +15 -0
- package/dist/runtime/storage/stores/fetcher/actions.d.ts +49 -0
- package/dist/runtime/storage/stores/fetcher/actions.js +125 -0
- package/dist/runtime/storage/stores/fetcher/fetcher-store.d.ts +19 -0
- package/dist/runtime/storage/stores/fetcher/fetcher-store.js +23 -0
- package/dist/runtime/storage/stores/fetcher/getter-utils.d.ts +7 -0
- package/dist/runtime/storage/stores/fetcher/getter-utils.js +27 -0
- package/dist/runtime/storage/stores/fetcher/getters.d.ts +13 -0
- package/dist/runtime/storage/stores/fetcher/getters.js +52 -0
- package/dist/runtime/storage/stores/fetcher/state.d.ts +25 -0
- package/dist/runtime/storage/stores/fetcher/state.js +7 -0
- package/dist/runtime/storage/stores/mercure/mercure-store.d.ts +16 -0
- package/dist/runtime/storage/stores/mercure/mercure-store.js +18 -0
- package/dist/runtime/storage/stores/mercure/state.d.ts +5 -0
- package/dist/runtime/storage/stores/mercure/state.js +6 -0
- package/dist/runtime/storage/stores/resources/actions.d.ts +54 -0
- package/dist/runtime/storage/stores/resources/actions.js +390 -0
- package/dist/runtime/storage/stores/resources/getter-utils.d.ts +7 -0
- package/dist/runtime/storage/stores/resources/getter-utils.js +27 -0
- package/dist/runtime/storage/stores/resources/getters.d.ts +38 -0
- package/dist/runtime/storage/stores/resources/getters.js +251 -0
- package/dist/runtime/storage/stores/resources/resources-store.d.ts +19 -0
- package/dist/runtime/storage/stores/resources/resources-store.js +23 -0
- package/dist/runtime/storage/stores/resources/state.d.ts +64 -0
- package/dist/runtime/storage/stores/resources/state.js +24 -0
- package/dist/runtime/templates/assets/base.css +1 -0
- package/dist/runtime/templates/assets/cwa.css +1 -0
- package/dist/runtime/templates/components/core/ComponentPlaceholder.vue +18 -0
- package/dist/runtime/templates/components/core/ComponentPlaceholder.vue.d.ts +3 -0
- package/dist/runtime/templates/components/core/ComponentPosition.spec.ts.snap +16 -0
- package/dist/runtime/templates/components/core/ComponentPosition.vue +63 -0
- package/dist/runtime/templates/components/core/ComponentPosition.vue.d.ts +3 -0
- package/dist/runtime/templates/components/core/ConfirmDialog.vue +41 -0
- package/dist/runtime/templates/components/core/ConfirmDialog.vue.d.ts +9 -0
- package/dist/runtime/templates/components/core/DialogBox.vue +95 -0
- package/dist/runtime/templates/components/core/DialogBox.vue.d.ts +38 -0
- package/dist/runtime/templates/components/core/README.md +1 -0
- package/dist/runtime/templates/components/core/ResourceLoader.spec.ts.snap +39 -0
- package/dist/runtime/templates/components/core/ResourceLoader.vue +151 -0
- package/dist/runtime/templates/components/core/ResourceLoader.vue.d.ts +13 -0
- package/dist/runtime/templates/components/core/admin/ListContainer.vue +7 -0
- package/dist/runtime/templates/components/core/admin/ListContainer.vue.d.ts +12 -0
- package/dist/runtime/templates/components/core/admin/ListContent.vue +136 -0
- package/dist/runtime/templates/components/core/admin/ListContent.vue.d.ts +21 -0
- package/dist/runtime/templates/components/core/admin/ListFilter.vue +49 -0
- package/dist/runtime/templates/components/core/admin/ListFilter.vue.d.ts +9 -0
- package/dist/runtime/templates/components/core/admin/ListFilterButton.vue +53 -0
- package/dist/runtime/templates/components/core/admin/ListFilterButton.vue.d.ts +9 -0
- package/dist/runtime/templates/components/core/admin/ListHeading.vue +32 -0
- package/dist/runtime/templates/components/core/admin/ListHeading.vue.d.ts +20 -0
- package/dist/runtime/templates/components/core/admin/ListPagination.vue +87 -0
- package/dist/runtime/templates/components/core/admin/ListPagination.vue.d.ts +15 -0
- package/dist/runtime/templates/components/core/admin/ListPaginationButton.vue +18 -0
- package/dist/runtime/templates/components/core/admin/ListPaginationButton.vue.d.ts +16 -0
- package/dist/runtime/templates/components/core/admin/PageAdminModal.vue +260 -0
- package/dist/runtime/templates/components/core/admin/PageAdminModal.vue.d.ts +12 -0
- package/dist/runtime/templates/components/core/admin/PageDataAdminModal.vue +187 -0
- package/dist/runtime/templates/components/core/admin/PageDataAdminModal.vue.d.ts +13 -0
- package/dist/runtime/templates/components/core/admin/ResourceModal.vue +99 -0
- package/dist/runtime/templates/components/core/admin/ResourceModal.vue.d.ts +27 -0
- package/dist/runtime/templates/components/core/admin/ResourceModalOverlay.vue +27 -0
- package/dist/runtime/templates/components/core/admin/ResourceModalOverlay.vue.d.ts +6 -0
- package/dist/runtime/templates/components/core/admin/ResourceModalOverlayTemplate.vue +23 -0
- package/dist/runtime/templates/components/core/admin/ResourceModalOverlayTemplate.vue.d.ts +15 -0
- package/dist/runtime/templates/components/core/admin/ResourceModalTabs.vue +77 -0
- package/dist/runtime/templates/components/core/admin/ResourceModalTabs.vue.d.ts +19 -0
- package/dist/runtime/templates/components/core/admin/RouteListRow.vue +102 -0
- package/dist/runtime/templates/components/core/admin/RouteListRow.vue.d.ts +20 -0
- package/dist/runtime/templates/components/core/admin/RouteRedirectsTree.vue +52 -0
- package/dist/runtime/templates/components/core/admin/RouteRedirectsTree.vue.d.ts +10 -0
- package/dist/runtime/templates/components/core/admin/RoutesTab.vue +273 -0
- package/dist/runtime/templates/components/core/admin/RoutesTab.vue.d.ts +12 -0
- package/dist/runtime/templates/components/core/admin/form/FilterFormWrapper.vue +18 -0
- package/dist/runtime/templates/components/core/admin/form/FilterFormWrapper.vue.d.ts +16 -0
- package/dist/runtime/templates/components/core/admin/form/FilterSelect.vue +86 -0
- package/dist/runtime/templates/components/core/admin/form/FilterSelect.vue.d.ts +3 -0
- package/dist/runtime/templates/components/core/admin/form/ModalInfo.vue +23 -0
- package/dist/runtime/templates/components/core/admin/form/ModalInfo.vue.d.ts +16 -0
- package/dist/runtime/templates/components/core/admin/form/ModalInput.vue +30 -0
- package/dist/runtime/templates/components/core/admin/form/ModalInput.vue.d.ts +15 -0
- package/dist/runtime/templates/components/core/admin/form/ModalSelect.vue +99 -0
- package/dist/runtime/templates/components/core/admin/form/ModalSelect.vue.d.ts +6 -0
- package/dist/runtime/templates/components/core/admin/form/PageTypeSelect.vue +112 -0
- package/dist/runtime/templates/components/core/admin/form/PageTypeSelect.vue.d.ts +4 -0
- package/dist/runtime/templates/components/core/assets/CwaLogo.vue +21 -0
- package/dist/runtime/templates/components/core/assets/CwaLogo.vue.d.ts +2 -0
- package/dist/runtime/templates/components/core/assets/IconComponents.vue +15 -0
- package/dist/runtime/templates/components/core/assets/IconComponents.vue.d.ts +2 -0
- package/dist/runtime/templates/components/core/assets/IconData.vue +24 -0
- package/dist/runtime/templates/components/core/assets/IconData.vue.d.ts +2 -0
- package/dist/runtime/templates/components/core/assets/IconLayouts.vue +20 -0
- package/dist/runtime/templates/components/core/assets/IconLayouts.vue.d.ts +2 -0
- package/dist/runtime/templates/components/core/assets/IconPages.vue +21 -0
- package/dist/runtime/templates/components/core/assets/IconPages.vue.d.ts +2 -0
- package/dist/runtime/templates/components/core/assets/IconRoutes.vue +23 -0
- package/dist/runtime/templates/components/core/assets/IconRoutes.vue.d.ts +2 -0
- package/dist/runtime/templates/components/core/assets/IconUsers.vue +13 -0
- package/dist/runtime/templates/components/core/assets/IconUsers.vue.d.ts +2 -0
- package/dist/runtime/templates/components/core/useDataResolver.d.ts +12 -0
- package/dist/runtime/templates/components/core/useDataResolver.js +109 -0
- package/dist/runtime/templates/components/main/ComponentGroup.Util.Positions.d.ts +6 -0
- package/dist/runtime/templates/components/main/ComponentGroup.Util.Positions.js +164 -0
- package/dist/runtime/templates/components/main/ComponentGroup.Util.Synchronizer.d.ts +20 -0
- package/dist/runtime/templates/components/main/ComponentGroup.Util.Synchronizer.js +69 -0
- package/dist/runtime/templates/components/main/ComponentGroup.spec.ts.snap +59 -0
- package/dist/runtime/templates/components/main/ComponentGroup.vue +107 -0
- package/dist/runtime/templates/components/main/ComponentGroup.vue.d.ts +9 -0
- package/dist/runtime/templates/components/main/CwaLink.vue +51 -0
- package/dist/runtime/templates/components/main/CwaLink.vue.d.ts +14 -0
- package/dist/runtime/templates/components/main/DefaultLayout.vue +8 -0
- package/dist/runtime/templates/components/main/DefaultLayout.vue.d.ts +12 -0
- package/dist/runtime/templates/components/main/ErrorPage.vue +98 -0
- package/dist/runtime/templates/components/main/ErrorPage.vue.d.ts +6 -0
- package/dist/runtime/templates/components/main/Logo.vue +18 -0
- package/dist/runtime/templates/components/main/Logo.vue.d.ts +2 -0
- package/dist/runtime/templates/components/main/README.md +7 -0
- package/dist/runtime/templates/components/main/admin/_common/ResourceContextItem.vue +41 -0
- package/dist/runtime/templates/components/main/admin/_common/ResourceContextItem.vue.d.ts +7 -0
- package/dist/runtime/templates/components/main/admin/_common/ResourceLoadingIndicator.vue +48 -0
- package/dist/runtime/templates/components/main/admin/_common/ResourceLoadingIndicator.vue.d.ts +2 -0
- package/dist/runtime/templates/components/main/admin/_common/useDynamicPositionSelectOptions.d.ts +5 -0
- package/dist/runtime/templates/components/main/admin/_common/useDynamicPositionSelectOptions.js +19 -0
- package/dist/runtime/templates/components/main/admin/header/Header.vue +207 -0
- package/dist/runtime/templates/components/main/admin/header/Header.vue.d.ts +2 -0
- package/dist/runtime/templates/components/main/admin/header/_parts/Menu.vue +189 -0
- package/dist/runtime/templates/components/main/admin/header/_parts/Menu.vue.d.ts +2 -0
- package/dist/runtime/templates/components/main/admin/header/_parts/MenuLink.vue +14 -0
- package/dist/runtime/templates/components/main/admin/header/_parts/MenuLink.vue.d.ts +16 -0
- package/dist/runtime/templates/components/main/admin/header/_parts/MenuPrimaryLink.vue +19 -0
- package/dist/runtime/templates/components/main/admin/header/_parts/MenuPrimaryLink.vue.d.ts +15 -0
- package/dist/runtime/templates/components/main/admin/header/_parts/Notification.vue +69 -0
- package/dist/runtime/templates/components/main/admin/header/_parts/Notification.vue.d.ts +12 -0
- package/dist/runtime/templates/components/main/admin/header/_parts/OutdatedContentNotice.vue +19 -0
- package/dist/runtime/templates/components/main/admin/header/_parts/OutdatedContentNotice.vue.d.ts +2 -0
- package/dist/runtime/templates/components/main/admin/header/_parts/PathSelector.vue +79 -0
- package/dist/runtime/templates/components/main/admin/header/_parts/PathSelector.vue.d.ts +2 -0
- package/dist/runtime/templates/components/main/admin/header/_parts/RequestErrors.vue +52 -0
- package/dist/runtime/templates/components/main/admin/header/_parts/RequestErrors.vue.d.ts +2 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/ComponentFocus.vue +151 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/ComponentFocus.vue.d.ts +10 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/LayoutPageOverlay.vue +192 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/LayoutPageOverlay.vue.d.ts +6 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/ResourceManager.vue +186 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/ResourceManager.vue.d.ts +9 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/_parts/AddComponentDialog.vue +205 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/_parts/AddComponentDialog.vue.d.ts +2 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/_parts/CwaResourceManagerContextMenu.vue +38 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/_parts/CwaResourceManagerContextMenu.vue.d.ts +6 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/_parts/ManagerTab.vue +15 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/_parts/ManagerTab.vue.d.ts +7 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/_parts/ManagerTabs.vue +44 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/_parts/ManagerTabs.vue.d.ts +13 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/_tabs/ResourceInfoTab.vue +59 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/_tabs/ResourceInfoTab.vue.d.ts +6 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/_tabs/component/Order.vue +75 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/_tabs/component/Order.vue.d.ts +6 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/_tabs/component/Publish.vue +41 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/_tabs/component/Publish.vue.d.ts +6 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/_tabs/component/Ui.vue +101 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/_tabs/component/Ui.vue.d.ts +6 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/_tabs/group/Group.vue +34 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/_tabs/group/Group.vue.d.ts +6 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/_tabs/position/DataPage.vue +121 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/_tabs/position/DataPage.vue.d.ts +6 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/_tabs/position/DynamicPage.vue +52 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/_tabs/position/DynamicPage.vue.d.ts +6 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/cta/CurrentResourceCta.vue +99 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/cta/CurrentResourceCta.vue.d.ts +7 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/cta/NewResourceCta.vue +59 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/cta/NewResourceCta.vue.d.ts +7 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/cta/ResourceManagerCtaButton.vue +28 -0
- package/dist/runtime/templates/components/main/admin/resource-manager/cta/ResourceManagerCtaButton.vue.d.ts +2 -0
- package/dist/runtime/templates/components/main/auth/ForgotPasswordPage.vue +55 -0
- package/dist/runtime/templates/components/main/auth/ForgotPasswordPage.vue.d.ts +20 -0
- package/dist/runtime/templates/components/main/auth/LoginPage.vue +60 -0
- package/dist/runtime/templates/components/main/auth/LoginPage.vue.d.ts +23 -0
- package/dist/runtime/templates/components/main/auth/ResetPasswordPage.vue +59 -0
- package/dist/runtime/templates/components/main/auth/ResetPasswordPage.vue.d.ts +27 -0
- package/dist/runtime/templates/components/main/auth/_parts/AuthPageLink.spec.ts.snap +14 -0
- package/dist/runtime/templates/components/main/auth/_parts/AuthPageLink.vue +17 -0
- package/dist/runtime/templates/components/main/auth/_parts/AuthPageLink.vue.d.ts +6 -0
- package/dist/runtime/templates/components/main/auth/_parts/AuthTemplate.spec.ts.snap +90 -0
- package/dist/runtime/templates/components/main/auth/_parts/AuthTemplate.vue +45 -0
- package/dist/runtime/templates/components/main/auth/_parts/AuthTemplate.vue.d.ts +17 -0
- package/dist/runtime/templates/components/main/auth/_parts/InputField.spec.ts.snap +111 -0
- package/dist/runtime/templates/components/main/auth/_parts/InputField.vue +50 -0
- package/dist/runtime/templates/components/main/auth/_parts/InputField.vue.d.ts +17 -0
- package/dist/runtime/templates/components/ui/BackgroundParticles.vue +960 -0
- package/dist/runtime/templates/components/ui/BackgroundParticles.vue.d.ts +2 -0
- package/dist/runtime/templates/components/ui/Hamburger.vue +75 -0
- package/dist/runtime/templates/components/ui/Hamburger.vue.d.ts +9 -0
- package/dist/runtime/templates/components/ui/ProgressBar.spec.ts.snap +71 -0
- package/dist/runtime/templates/components/ui/ProgressBar.vue +29 -0
- package/dist/runtime/templates/components/ui/ProgressBar.vue.d.ts +9 -0
- package/dist/runtime/templates/components/ui/README.md +6 -0
- package/dist/runtime/templates/components/ui/alert/Info.spec.ts.snap +23 -0
- package/dist/runtime/templates/components/ui/alert/Info.vue +13 -0
- package/dist/runtime/templates/components/ui/alert/Info.vue.d.ts +12 -0
- package/dist/runtime/templates/components/ui/alert/Warning.spec.ts.snap +14 -0
- package/dist/runtime/templates/components/ui/alert/Warning.vue +8 -0
- package/dist/runtime/templates/components/ui/alert/Warning.vue.d.ts +12 -0
- package/dist/runtime/templates/components/ui/form/Button.vue +139 -0
- package/dist/runtime/templates/components/ui/form/Button.vue.d.ts +52 -0
- package/dist/runtime/templates/components/ui/form/ButtonPopoverGroup.vue +18 -0
- package/dist/runtime/templates/components/ui/form/ButtonPopoverGroup.vue.d.ts +10 -0
- package/dist/runtime/templates/components/ui/form/ButtonPopoverItem.vue +15 -0
- package/dist/runtime/templates/components/ui/form/ButtonPopoverItem.vue.d.ts +10 -0
- package/dist/runtime/templates/components/ui/form/File.vue +72 -0
- package/dist/runtime/templates/components/ui/form/File.vue.d.ts +9 -0
- package/dist/runtime/templates/components/ui/form/Input.vue +22 -0
- package/dist/runtime/templates/components/ui/form/Input.vue.d.ts +5 -0
- package/dist/runtime/templates/components/ui/form/LabelWrapper.vue +16 -0
- package/dist/runtime/templates/components/ui/form/LabelWrapper.vue.d.ts +15 -0
- package/dist/runtime/templates/components/ui/form/SearchResource.vue +212 -0
- package/dist/runtime/templates/components/ui/form/SearchResource.vue.d.ts +14 -0
- package/dist/runtime/templates/components/ui/form/Select.vue +60 -0
- package/dist/runtime/templates/components/ui/form/Select.vue.d.ts +3 -0
- package/dist/runtime/templates/components/ui/form/Toggle.vue +39 -0
- package/dist/runtime/templates/components/ui/form/Toggle.vue.d.ts +6 -0
- package/dist/runtime/templates/components/ui/icon/ArrowIcon.vue +30 -0
- package/dist/runtime/templates/components/ui/icon/ArrowIcon.vue.d.ts +2 -0
- package/dist/runtime/templates/components/ui/icon/BinIcon.vue +24 -0
- package/dist/runtime/templates/components/ui/icon/BinIcon.vue.d.ts +2 -0
- package/dist/runtime/templates/components/ui/icon/CogIcon.vue +9 -0
- package/dist/runtime/templates/components/ui/icon/CogIcon.vue.d.ts +2 -0
- package/dist/runtime/templates/components/ui/icon/EyeIcon.vue +24 -0
- package/dist/runtime/templates/components/ui/icon/EyeIcon.vue.d.ts +2 -0
- package/dist/runtime/templates/components/ui/icon/PenIcon.vue +12 -0
- package/dist/runtime/templates/components/ui/icon/PenIcon.vue.d.ts +2 -0
- package/dist/runtime/templates/components/ui/icon/PlusIcon.vue +9 -0
- package/dist/runtime/templates/components/ui/icon/PlusIcon.vue.d.ts +2 -0
- package/dist/runtime/templates/components/ui/icon/SearchIcon.vue +10 -0
- package/dist/runtime/templates/components/ui/icon/SearchIcon.vue.d.ts +2 -0
- package/dist/runtime/templates/components/ui/icon/TickIcon.vue +23 -0
- package/dist/runtime/templates/components/ui/icon/TickIcon.vue.d.ts +2 -0
- package/dist/runtime/templates/components/ui/icon/WarningIcon.vue +11 -0
- package/dist/runtime/templates/components/ui/icon/WarningIcon.vue.d.ts +2 -0
- package/dist/runtime/templates/components/ui/icon/XMarkIcon.vue +15 -0
- package/dist/runtime/templates/components/ui/icon/XMarkIcon.vue.d.ts +2 -0
- package/dist/runtime/templates/components/utils/ContextMenu.vue +59 -0
- package/dist/runtime/templates/components/utils/ContextMenu.vue.d.ts +21 -0
- package/dist/runtime/templates/components/utils/HotSpot.vue +24 -0
- package/dist/runtime/templates/components/utils/HotSpot.vue.d.ts +9 -0
- package/dist/runtime/templates/components/utils/README.md +1 -0
- package/dist/runtime/templates/components/utils/Spinner.spec.ts.snap +56 -0
- package/dist/runtime/templates/components/utils/Spinner.vue +42 -0
- package/dist/runtime/templates/components/utils/Spinner.vue.d.ts +5 -0
- package/dist/runtime/templates/components/utils/SpinnerTick.vue +43 -0
- package/dist/runtime/templates/components/utils/SpinnerTick.vue.d.ts +6 -0
- package/dist/runtime/templates/cwa-page.spec.ts.snap +20 -0
- package/dist/runtime/templates/cwa-page.vue +32 -0
- package/dist/runtime/templates/cwa-page.vue.d.ts +2 -0
- package/dist/runtime/types/popper.d.ts +14 -0
- package/dist/types.d.mts +9 -0
- package/package.json +108 -0
|
@@ -0,0 +1,131 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<ListHeading
|
|
3
|
+
:title="pageDataClassName"
|
|
4
|
+
@add="goToAdd"
|
|
5
|
+
>
|
|
6
|
+
<div class="cwa:-mt-7 cwa:mb-5">
|
|
7
|
+
<NuxtLink
|
|
8
|
+
:to="{ name: '_cwa-data' }"
|
|
9
|
+
class="cwa:text-sm cwa:flex cwa:items-center cwa:transition-opacity cwa:gap-x-1.5 cwa:opacity-70 cwa:hover:opacity-100"
|
|
10
|
+
>
|
|
11
|
+
<CwaUiIconArrowIcon class="cwa:w-4 cwa:rotate-90 cwa:my-2" />
|
|
12
|
+
<span>Page data categories</span>
|
|
13
|
+
</NuxtLink>
|
|
14
|
+
</div>
|
|
15
|
+
</ListHeading>
|
|
16
|
+
<ListFilter
|
|
17
|
+
:order-options="orderOptions"
|
|
18
|
+
:search-fields="['title']"
|
|
19
|
+
/>
|
|
20
|
+
<ListContent
|
|
21
|
+
v-if="endpoint"
|
|
22
|
+
ref="listContent"
|
|
23
|
+
:fetch-url="endpoint"
|
|
24
|
+
>
|
|
25
|
+
<template #item="{ data }">
|
|
26
|
+
<div class="cwa:flex cwa:border-b cwa:border-b-stone-700 cwa:py-6 cwa:gap-x-4 cwa:items-center">
|
|
27
|
+
<div class="cwa:grow cwa:flex cwa:flex-col cwa:gap-y-1">
|
|
28
|
+
<div class="cwa:flex cwa:items-center cwa:gap-x-3">
|
|
29
|
+
<span class="cwa:text-xl">{{ data.title }}</span><span :class="['cwa:outline', 'cwa:outline-1', 'cwa:outline-offset-2', 'cwa:w-2', 'cwa:h-2', 'cwa:rounded-full', data.route ? ['cwa:outline-green', 'cwa:bg-green'] : ['cwa:outline-orange', 'cwa:bg-orange']]" />
|
|
30
|
+
</div>
|
|
31
|
+
<span class="cwa:text-stone-400">{{ pageDataById[data.page]?.reference || data.page }}</span>
|
|
32
|
+
</div>
|
|
33
|
+
<div class="cwa:flex cwa:gap-x-2">
|
|
34
|
+
<CwaUiFormButton :to="computedItemLink(data['@id'])">
|
|
35
|
+
<CwaUiIconCogIcon class="cwa:w-6" />
|
|
36
|
+
<span class="cwa:sr-only">Settings</span>
|
|
37
|
+
</CwaUiFormButton>
|
|
38
|
+
<CwaUiFormButton @click="() => goToPage(data['@id'])">
|
|
39
|
+
<CwaUiIconEyeIcon class="cwa:h-5" />
|
|
40
|
+
<span class="cwa:sr-only">View</span>
|
|
41
|
+
</CwaUiFormButton>
|
|
42
|
+
</div>
|
|
43
|
+
</div>
|
|
44
|
+
</template>
|
|
45
|
+
</ListContent>
|
|
46
|
+
<ResourceModalOverlay @reload="triggerReload" />
|
|
47
|
+
</template>
|
|
48
|
+
|
|
49
|
+
<script setup lang="ts">
|
|
50
|
+
import { computed, onMounted, ref, watchEffect } from 'vue'
|
|
51
|
+
import { useRouter } from 'vue-router'
|
|
52
|
+
import { useHead } from '#app'
|
|
53
|
+
import ListHeading from '#cwa/runtime/templates/components/core/admin/ListHeading.vue'
|
|
54
|
+
import { definePageMeta, useCwa } from '#imports'
|
|
55
|
+
import { useDataList } from '#cwa/layer/pages/_cwa/composables/useDataList'
|
|
56
|
+
import ListFilter from '#cwa/runtime/templates/components/core/admin/ListFilter.vue'
|
|
57
|
+
import ResourceModalOverlay from '#cwa/runtime/templates/components/core/admin/ResourceModalOverlay.vue'
|
|
58
|
+
import ListContent from '#cwa/runtime/templates/components/core/admin/ListContent.vue'
|
|
59
|
+
import { useListPage } from '#cwa/layer/pages/_cwa/composables/useListPage'
|
|
60
|
+
import { useDataType } from '#cwa/layer/pages/_cwa/composables/useDataType'
|
|
61
|
+
import { useDynamicPageLoader } from '#cwa/layer/pages/_cwa/composables/useDynamicPageLoader'
|
|
62
|
+
import type { CwaResource } from '#cwa/runtime/resources/resource-utils'
|
|
63
|
+
|
|
64
|
+
const listContent = ref<InstanceType<typeof ListContent> | null>(null)
|
|
65
|
+
|
|
66
|
+
const $cwa = useCwa()
|
|
67
|
+
const router = useRouter()
|
|
68
|
+
const { pageDataClassName, dataType } = useDataType()
|
|
69
|
+
|
|
70
|
+
const { goToAdd, triggerReload, computedItemLink } = useListPage(listContent)
|
|
71
|
+
const { loadDynamicPageOptions, dynamicPages } = useDynamicPageLoader()
|
|
72
|
+
|
|
73
|
+
const endpoint = ref<string>()
|
|
74
|
+
|
|
75
|
+
const orderOptions = [
|
|
76
|
+
{
|
|
77
|
+
label: 'New - Old',
|
|
78
|
+
value: { createdAt: 'desc' },
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
label: 'Old - New',
|
|
82
|
+
value: { createdAt: 'asc' },
|
|
83
|
+
},
|
|
84
|
+
{
|
|
85
|
+
label: 'A - Z',
|
|
86
|
+
value: { title: 'asc' },
|
|
87
|
+
},
|
|
88
|
+
{
|
|
89
|
+
label: 'Z - A',
|
|
90
|
+
value: { title: 'desc' },
|
|
91
|
+
},
|
|
92
|
+
]
|
|
93
|
+
|
|
94
|
+
function goToPage(page: string) {
|
|
95
|
+
router.push(page)
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
// to force the loading of api documentation
|
|
99
|
+
useDataList()
|
|
100
|
+
|
|
101
|
+
onMounted(async () => {
|
|
102
|
+
await loadDynamicPageOptions()
|
|
103
|
+
})
|
|
104
|
+
|
|
105
|
+
const pageDataById = computed(() => {
|
|
106
|
+
if (!dynamicPages.value) {
|
|
107
|
+
return {}
|
|
108
|
+
}
|
|
109
|
+
return dynamicPages.value.reduce((obj, resource) => {
|
|
110
|
+
obj[resource['@id']] = { ...resource }
|
|
111
|
+
return obj
|
|
112
|
+
}, {} as { [iri: string]: CwaResource })
|
|
113
|
+
})
|
|
114
|
+
|
|
115
|
+
watchEffect(async () => {
|
|
116
|
+
const docs = await $cwa.getApiDocumentation()
|
|
117
|
+
if (dataType.value) {
|
|
118
|
+
endpoint.value = docs?.entrypoint?.[dataType.value]
|
|
119
|
+
}
|
|
120
|
+
})
|
|
121
|
+
|
|
122
|
+
useHead({
|
|
123
|
+
title: () => {
|
|
124
|
+
return pageDataClassName.value + ' - Page Data'
|
|
125
|
+
},
|
|
126
|
+
})
|
|
127
|
+
|
|
128
|
+
definePageMeta({
|
|
129
|
+
pageTransition: false,
|
|
130
|
+
})
|
|
131
|
+
</script>
|
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<ListHeading
|
|
3
|
+
title="Page Data Categories"
|
|
4
|
+
:hide-add="true"
|
|
5
|
+
/>
|
|
6
|
+
<ListContainer>
|
|
7
|
+
<div class="cwa:relative">
|
|
8
|
+
<Transition
|
|
9
|
+
appear
|
|
10
|
+
mode="out-in"
|
|
11
|
+
enter-from-class="cwa:transform cwa:opacity-0"
|
|
12
|
+
enter-active-class="cwa:duration-200 cwa:ease-out"
|
|
13
|
+
enter-to-class="cwa:opacity-100"
|
|
14
|
+
leave-from-class="cwa:opacity-100"
|
|
15
|
+
leave-active-class="cwa:duration-200 cwa:ease-in"
|
|
16
|
+
leave-to-class="cwa:transform cwa:opacity-0"
|
|
17
|
+
>
|
|
18
|
+
<Spinner
|
|
19
|
+
v-if="isLoadingDataTypes"
|
|
20
|
+
class="cwa:absolute cwa:top-5"
|
|
21
|
+
:show="true"
|
|
22
|
+
/>
|
|
23
|
+
<div
|
|
24
|
+
v-else-if="!dataTypes.length"
|
|
25
|
+
class="cwa:flex cwa:justify-center"
|
|
26
|
+
>
|
|
27
|
+
<div class="cwa:w-full cwa:max-w-xl cwa:text-center cwa:flex cwa:flex-col cwa:gap-y-2 cwa:text-stone-400">
|
|
28
|
+
<div class="cwa:flex cwa:justify-center">
|
|
29
|
+
<CwaUiIconWarningIcon class="cwa:w-20" />
|
|
30
|
+
</div>
|
|
31
|
+
<h2 class="cwa:font-bold">
|
|
32
|
+
Sorry, no items found
|
|
33
|
+
</h2>
|
|
34
|
+
</div>
|
|
35
|
+
</div>
|
|
36
|
+
<ul
|
|
37
|
+
v-else
|
|
38
|
+
class="cwa:my-6 cwa:flex cwa:flex-col cwa:gap-y-4"
|
|
39
|
+
>
|
|
40
|
+
<li
|
|
41
|
+
v-for="pageData of dataTypes"
|
|
42
|
+
:key="pageData['@id']"
|
|
43
|
+
>
|
|
44
|
+
<NuxtLink
|
|
45
|
+
:to="{ name: '_cwa-data-type', params: { type: fqcnToEntrypointKey(pageData.resourceClass) } }"
|
|
46
|
+
class="cwa:flex cwa:p-4 cwa:border cwa:border-stone-700 cwa:py-6 cwa:gap-x-4 cwa:items-center cwa:bg-dark/80 cwa:hover:bg-dark cwa:cursor-pointer cwa:transition-colors"
|
|
47
|
+
>
|
|
48
|
+
<div class="cwa:grow cwa:flex cwa:flex-col cwa:gap-y-1">
|
|
49
|
+
<div class="cwa:flex cwa:items-center cwa:gap-x-3">
|
|
50
|
+
<span class="cwa:text-xl">{{ displayPageDataClassName(pageData.resourceClass) }}</span>
|
|
51
|
+
</div>
|
|
52
|
+
</div>
|
|
53
|
+
<div class="cwa:flex cwa:gap-x-2">
|
|
54
|
+
<CwaUiFormButton class="cwa:pointer-events-none">
|
|
55
|
+
<CwaUiIconArrowIcon class="cwa:w-5 cwa:-rotate-90 cwa:my-2" />
|
|
56
|
+
<span class="cwa:sr-only">View</span>
|
|
57
|
+
</CwaUiFormButton>
|
|
58
|
+
</div>
|
|
59
|
+
</NuxtLink>
|
|
60
|
+
</li>
|
|
61
|
+
</ul>
|
|
62
|
+
</Transition>
|
|
63
|
+
</div>
|
|
64
|
+
</ListContainer>
|
|
65
|
+
</template>
|
|
66
|
+
|
|
67
|
+
<script setup lang="ts">
|
|
68
|
+
import { useHead } from '#app'
|
|
69
|
+
import ListHeading from '#cwa/runtime/templates/components/core/admin/ListHeading.vue'
|
|
70
|
+
import ListContainer from '#cwa/runtime/templates/components/core/admin/ListContainer.vue'
|
|
71
|
+
import { useDataList } from '#cwa/layer/pages/_cwa/composables/useDataList'
|
|
72
|
+
import Spinner from '#cwa/runtime/templates/components/utils/Spinner.vue'
|
|
73
|
+
import { definePageMeta } from '#imports'
|
|
74
|
+
|
|
75
|
+
const { displayPageDataClassName, dataTypes, fqcnToEntrypointKey, isLoadingDataTypes } = useDataList()
|
|
76
|
+
|
|
77
|
+
useHead({
|
|
78
|
+
title: 'Page Data Categories',
|
|
79
|
+
})
|
|
80
|
+
|
|
81
|
+
definePageMeta({
|
|
82
|
+
pageTransition: false,
|
|
83
|
+
})
|
|
84
|
+
</script>
|
|
@@ -0,0 +1,174 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<ResourceModal
|
|
3
|
+
v-if="localResourceData"
|
|
4
|
+
v-model="localResourceData.reference"
|
|
5
|
+
:is-loading="isLoading"
|
|
6
|
+
@close="$emit('close')"
|
|
7
|
+
@save="saveTitle"
|
|
8
|
+
>
|
|
9
|
+
<ResourceModalTabs :tabs="tabs">
|
|
10
|
+
<template #details>
|
|
11
|
+
<div class="cwa:flex cwa:flex-col cwa:gap-y-2">
|
|
12
|
+
<div>
|
|
13
|
+
<ModalSelect
|
|
14
|
+
v-model="localResourceData.uiComponent"
|
|
15
|
+
label="Layout UI"
|
|
16
|
+
:options="layoutComponentOptions"
|
|
17
|
+
/>
|
|
18
|
+
</div>
|
|
19
|
+
<div v-if="layoutStyleOptions.length">
|
|
20
|
+
<ModalSelect
|
|
21
|
+
v-model="localResourceData.uiClassNames"
|
|
22
|
+
label="Style"
|
|
23
|
+
:options="layoutStyleOptions"
|
|
24
|
+
/>
|
|
25
|
+
</div>
|
|
26
|
+
<div class="cwa:flex cwa:justify-end cwa:pt-2 cwa:gap-x-2">
|
|
27
|
+
<div>
|
|
28
|
+
<CwaUiFormButton
|
|
29
|
+
color="dark"
|
|
30
|
+
:disabled="isUpdating"
|
|
31
|
+
@click="saveResource(!isAdding)"
|
|
32
|
+
>
|
|
33
|
+
{{ isAdding ? 'Add Now' : 'Save & Close' }}
|
|
34
|
+
</CwaUiFormButton>
|
|
35
|
+
</div>
|
|
36
|
+
<div>
|
|
37
|
+
<CwaUiFormButton
|
|
38
|
+
color="blue"
|
|
39
|
+
:disabled="isUpdating"
|
|
40
|
+
@click="() => saveResource(isAdding)"
|
|
41
|
+
>
|
|
42
|
+
{{ isAdding ? 'Add & Close' : 'Save' }}
|
|
43
|
+
</CwaUiFormButton>
|
|
44
|
+
</div>
|
|
45
|
+
</div>
|
|
46
|
+
</div>
|
|
47
|
+
</template>
|
|
48
|
+
<template #info>
|
|
49
|
+
<div class="cwa:flex cwa:flex-col cwa:gap-y-2">
|
|
50
|
+
<div>
|
|
51
|
+
<ModalInfo
|
|
52
|
+
label="Created"
|
|
53
|
+
:content="formatDate(localResourceData.createdAt)"
|
|
54
|
+
/>
|
|
55
|
+
</div>
|
|
56
|
+
<div>
|
|
57
|
+
<ModalInfo
|
|
58
|
+
label="Updated"
|
|
59
|
+
:content="formatDate(localResourceData.updatedAt)"
|
|
60
|
+
/>
|
|
61
|
+
</div>
|
|
62
|
+
<div>
|
|
63
|
+
<ModalInfo
|
|
64
|
+
label="ID"
|
|
65
|
+
:content="localResourceData['@id']"
|
|
66
|
+
/>
|
|
67
|
+
</div>
|
|
68
|
+
<div class="cwa:flex cwa:justify-start cwa:pt-6">
|
|
69
|
+
<div>
|
|
70
|
+
<CwaUiFormButton
|
|
71
|
+
:disabled="isUpdating"
|
|
72
|
+
@click="handleDeleteClick"
|
|
73
|
+
>
|
|
74
|
+
Delete
|
|
75
|
+
</CwaUiFormButton>
|
|
76
|
+
</div>
|
|
77
|
+
</div>
|
|
78
|
+
</div>
|
|
79
|
+
</template>
|
|
80
|
+
</ResourceModalTabs>
|
|
81
|
+
</ResourceModal>
|
|
82
|
+
</template>
|
|
83
|
+
|
|
84
|
+
<script setup lang="ts">
|
|
85
|
+
import { computed } from 'vue'
|
|
86
|
+
import { useItemPage } from '../composables/useItemPage'
|
|
87
|
+
import { type SelectOption, useCwa } from '#imports'
|
|
88
|
+
import ResourceModal from '#cwa/runtime/templates/components/core/admin/ResourceModal.vue'
|
|
89
|
+
import ResourceModalTabs, { type ResourceModalTab } from '#cwa/runtime/templates/components/core/admin/ResourceModalTabs.vue'
|
|
90
|
+
import ModalSelect from '#cwa/runtime/templates/components/core/admin/form/ModalSelect.vue'
|
|
91
|
+
import { componentNames } from '#components'
|
|
92
|
+
import ModalInfo from '#cwa/runtime/templates/components/core/admin/form/ModalInfo.vue'
|
|
93
|
+
|
|
94
|
+
const emit = defineEmits<{
|
|
95
|
+
close: []
|
|
96
|
+
reload: []
|
|
97
|
+
}>()
|
|
98
|
+
|
|
99
|
+
const layoutComponentNames = computed(() => {
|
|
100
|
+
return componentNames.filter(n => n.startsWith('CwaLayout'))
|
|
101
|
+
})
|
|
102
|
+
|
|
103
|
+
function cleanUiName(componentName: string) {
|
|
104
|
+
return componentName.replace(/^CwaLayout/, '')
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
const layoutComponentOptions = computed(() => {
|
|
108
|
+
const options = []
|
|
109
|
+
for (const componentName of layoutComponentNames.value) {
|
|
110
|
+
const cleanName = cleanUiName(componentName)
|
|
111
|
+
options.push({
|
|
112
|
+
label: $cwa.layoutsConfig?.[cleanName]?.name || cleanName,
|
|
113
|
+
value: componentName,
|
|
114
|
+
})
|
|
115
|
+
}
|
|
116
|
+
return options
|
|
117
|
+
})
|
|
118
|
+
|
|
119
|
+
const layoutStyleOptions = computed(() => {
|
|
120
|
+
if (!localResourceData.value?.uiComponent) {
|
|
121
|
+
return []
|
|
122
|
+
}
|
|
123
|
+
const cleanName = cleanUiName(localResourceData.value?.uiComponent)
|
|
124
|
+
const configuredClasses = $cwa.layoutsConfig?.[cleanName]?.classes
|
|
125
|
+
if (!configuredClasses) {
|
|
126
|
+
return []
|
|
127
|
+
}
|
|
128
|
+
const options: SelectOption[] = [
|
|
129
|
+
{
|
|
130
|
+
label: 'Default',
|
|
131
|
+
value: null,
|
|
132
|
+
},
|
|
133
|
+
]
|
|
134
|
+
for (const [label, value] of Object.entries(configuredClasses)) {
|
|
135
|
+
options.push({
|
|
136
|
+
label,
|
|
137
|
+
value,
|
|
138
|
+
})
|
|
139
|
+
}
|
|
140
|
+
return options
|
|
141
|
+
})
|
|
142
|
+
|
|
143
|
+
const tabs = computed<ResourceModalTab[]>(() => {
|
|
144
|
+
const t: ResourceModalTab[] = [
|
|
145
|
+
{
|
|
146
|
+
label: 'Details',
|
|
147
|
+
id: 'details',
|
|
148
|
+
},
|
|
149
|
+
]
|
|
150
|
+
if (!isAdding.value) {
|
|
151
|
+
t.push({
|
|
152
|
+
label: 'Info',
|
|
153
|
+
id: 'info',
|
|
154
|
+
})
|
|
155
|
+
}
|
|
156
|
+
return t
|
|
157
|
+
})
|
|
158
|
+
|
|
159
|
+
const $cwa = useCwa()
|
|
160
|
+
|
|
161
|
+
const { isAdding, isLoading, isUpdating, localResourceData, formatDate, deleteResource, saveResource, saveTitle } = useItemPage({
|
|
162
|
+
createEndpoint: '/_/layouts',
|
|
163
|
+
emit,
|
|
164
|
+
resourceType: 'Layout',
|
|
165
|
+
defaultResource: {
|
|
166
|
+
reference: null,
|
|
167
|
+
uiComponent: layoutComponentOptions.value[0].value,
|
|
168
|
+
},
|
|
169
|
+
})
|
|
170
|
+
|
|
171
|
+
function handleDeleteClick() {
|
|
172
|
+
deleteResource()
|
|
173
|
+
}
|
|
174
|
+
</script>
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<ListHeading
|
|
3
|
+
title="Layouts"
|
|
4
|
+
@add="goToAdd"
|
|
5
|
+
/>
|
|
6
|
+
<ListFilter
|
|
7
|
+
:order-options="orderOptions"
|
|
8
|
+
:search-fields="['reference', 'uiComponent']"
|
|
9
|
+
/>
|
|
10
|
+
<ListContent
|
|
11
|
+
ref="listContent"
|
|
12
|
+
fetch-url="/_/layouts"
|
|
13
|
+
>
|
|
14
|
+
<template #item="{ data }">
|
|
15
|
+
<div class="cwa:flex cwa:border-b cwa:border-b-stone-700 cwa:py-6 cwa:gap-x-4 cwa:items-center">
|
|
16
|
+
<div class="cwa:grow cwa:flex cwa:flex-col cwa:gap-y-1">
|
|
17
|
+
<span class="cwa:text-xl">{{ data.reference }}</span>
|
|
18
|
+
<span class="cwa:text-stone-400">UI: {{ data.uiComponent ? getDisplayLayoutUi(data.uiComponent) : 'Unknown' }}</span>
|
|
19
|
+
</div>
|
|
20
|
+
<div>
|
|
21
|
+
<CwaUiFormButton :to="computedItemLink(data['@id'])">
|
|
22
|
+
<CwaUiIconCogIcon class="cwa:w-6" />
|
|
23
|
+
<span class="cwa:sr-only">Settings</span>
|
|
24
|
+
</CwaUiFormButton>
|
|
25
|
+
</div>
|
|
26
|
+
</div>
|
|
27
|
+
</template>
|
|
28
|
+
</ListContent>
|
|
29
|
+
<ResourceModalOverlay @reload="triggerReload" />
|
|
30
|
+
</template>
|
|
31
|
+
|
|
32
|
+
<script lang="ts" setup>
|
|
33
|
+
import { ref } from 'vue'
|
|
34
|
+
import { useHead } from '#app'
|
|
35
|
+
import ListHeading from '#cwa/runtime/templates/components/core/admin/ListHeading.vue'
|
|
36
|
+
import ListContent from '#cwa/runtime/templates/components/core/admin/ListContent.vue'
|
|
37
|
+
import ListFilter from '#cwa/runtime/templates/components/core/admin/ListFilter.vue'
|
|
38
|
+
import ResourceModalOverlay from '#cwa/runtime/templates/components/core/admin/ResourceModalOverlay.vue'
|
|
39
|
+
import { useListPage } from '#cwa/layer/pages/_cwa/composables/useListPage'
|
|
40
|
+
import { definePageMeta, useCwa } from '#imports'
|
|
41
|
+
|
|
42
|
+
const listContent = ref<InstanceType<typeof ListContent> | null>(null)
|
|
43
|
+
|
|
44
|
+
const $cwa = useCwa()
|
|
45
|
+
const { goToAdd, triggerReload, computedItemLink } = useListPage(listContent)
|
|
46
|
+
|
|
47
|
+
const orderOptions = [
|
|
48
|
+
{
|
|
49
|
+
label: 'New - Old',
|
|
50
|
+
value: { createdAt: 'desc' },
|
|
51
|
+
},
|
|
52
|
+
{
|
|
53
|
+
label: 'Old - New',
|
|
54
|
+
value: { createdAt: 'asc' },
|
|
55
|
+
},
|
|
56
|
+
{
|
|
57
|
+
label: 'A - Z',
|
|
58
|
+
value: { reference: 'asc' },
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
label: 'Z - A',
|
|
62
|
+
value: { reference: 'desc' },
|
|
63
|
+
},
|
|
64
|
+
]
|
|
65
|
+
|
|
66
|
+
function getDisplayLayoutUi(ui: string) {
|
|
67
|
+
return $cwa.layoutsConfig?.[ui]?.name || ui.replace(/^CwaLayout/, '')
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
useHead({
|
|
71
|
+
title: 'Layouts',
|
|
72
|
+
})
|
|
73
|
+
|
|
74
|
+
definePageMeta({
|
|
75
|
+
pageTransition: false,
|
|
76
|
+
})
|
|
77
|
+
</script>
|
|
@@ -0,0 +1,129 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<ListHeading
|
|
3
|
+
title="Pages"
|
|
4
|
+
@add="goToAdd"
|
|
5
|
+
/>
|
|
6
|
+
<ListFilter
|
|
7
|
+
:order-options="orderOptions"
|
|
8
|
+
:search-fields="['reference', 'title', 'uiComponent']"
|
|
9
|
+
/>
|
|
10
|
+
<ListContainer>
|
|
11
|
+
<div>
|
|
12
|
+
<div>
|
|
13
|
+
<FilterFormWrapper
|
|
14
|
+
label="Page Type"
|
|
15
|
+
input-id="page-type"
|
|
16
|
+
>
|
|
17
|
+
<div class="cwa:flex cwa:gap-x-2">
|
|
18
|
+
<div>
|
|
19
|
+
<ListFilterButton
|
|
20
|
+
v-model="selectedTypesModel"
|
|
21
|
+
value="false"
|
|
22
|
+
label="Static"
|
|
23
|
+
background-color-class="cwa:bg-blue-600/20"
|
|
24
|
+
border-color-class="cwa:border-blue-600"
|
|
25
|
+
/>
|
|
26
|
+
</div>
|
|
27
|
+
<div>
|
|
28
|
+
<ListFilterButton
|
|
29
|
+
v-model="selectedTypesModel"
|
|
30
|
+
value="true"
|
|
31
|
+
label="Dynamic"
|
|
32
|
+
background-color-class="cwa:bg-yellow/20"
|
|
33
|
+
border-color-class="cwa:border-yellow"
|
|
34
|
+
/>
|
|
35
|
+
</div>
|
|
36
|
+
</div>
|
|
37
|
+
</FilterFormWrapper>
|
|
38
|
+
</div>
|
|
39
|
+
</div>
|
|
40
|
+
</ListContainer>
|
|
41
|
+
<ListContent
|
|
42
|
+
ref="listContent"
|
|
43
|
+
fetch-url="/_/pages"
|
|
44
|
+
>
|
|
45
|
+
<template #item="{ data }">
|
|
46
|
+
<div class="cwa:flex cwa:border-b cwa:border-b-stone-700 cwa:py-6 cwa:gap-x-4 cwa:items-center">
|
|
47
|
+
<div class="cwa:grow cwa:flex cwa:flex-col cwa:gap-y-1">
|
|
48
|
+
<div class="cwa:flex cwa:items-center cwa:gap-x-3">
|
|
49
|
+
<span class="cwa:text-xl">{{ data.reference }}</span><span :class="['cwa:outline', 'cwa:outline-1', 'cwa:outline-offset-2', 'cwa:w-2', 'cwa:h-2', 'cwa:rounded-full', data.isTemplate ? 'cwa:outline-yellow cwa:bg-yellow' : 'cwa:outline-blue-600 cwa:bg-blue-600']" />
|
|
50
|
+
</div>
|
|
51
|
+
<span class="cwa:text-stone-400">UI: {{ data.uiComponent ? getDisplayPageUi(data.uiComponent) : 'Unknown' }}</span>
|
|
52
|
+
</div>
|
|
53
|
+
<div class="cwa:flex cwa:gap-x-2">
|
|
54
|
+
<CwaUiFormButton :to="computedItemLink(data['@id'])">
|
|
55
|
+
<CwaUiIconCogIcon class="cwa:w-6" />
|
|
56
|
+
<span class="cwa:sr-only">Settings</span>
|
|
57
|
+
</CwaUiFormButton>
|
|
58
|
+
<CwaUiFormButton @click="() => goToPage(data['@id'])">
|
|
59
|
+
<CwaUiIconEyeIcon class="cwa:h-5" />
|
|
60
|
+
<span class="cwa:sr-only">View</span>
|
|
61
|
+
</CwaUiFormButton>
|
|
62
|
+
</div>
|
|
63
|
+
</div>
|
|
64
|
+
</template>
|
|
65
|
+
</ListContent>
|
|
66
|
+
<ResourceModalOverlay @reload="triggerReload" />
|
|
67
|
+
</template>
|
|
68
|
+
|
|
69
|
+
<script lang="ts" setup>
|
|
70
|
+
import { useRouter } from 'vue-router'
|
|
71
|
+
import { ref } from 'vue'
|
|
72
|
+
import { useListPage } from './composables/useListPage'
|
|
73
|
+
import { useHead } from '#app'
|
|
74
|
+
import ListHeading from '#cwa/runtime/templates/components/core/admin/ListHeading.vue'
|
|
75
|
+
import ListContent from '#cwa/runtime/templates/components/core/admin/ListContent.vue'
|
|
76
|
+
import ListFilter from '#cwa/runtime/templates/components/core/admin/ListFilter.vue'
|
|
77
|
+
import ListContainer from '#cwa/runtime/templates/components/core/admin/ListContainer.vue'
|
|
78
|
+
import FilterFormWrapper from '#cwa/runtime/templates/components/core/admin/form/FilterFormWrapper.vue'
|
|
79
|
+
import ListFilterButton from '#cwa/runtime/templates/components/core/admin/ListFilterButton.vue'
|
|
80
|
+
import { useQueryBoundModel } from '#cwa/runtime/composables/cwa-query-bound-model'
|
|
81
|
+
import ResourceModalOverlay from '#cwa/runtime/templates/components/core/admin/ResourceModalOverlay.vue'
|
|
82
|
+
import { definePageMeta, useCwa } from '#imports'
|
|
83
|
+
|
|
84
|
+
const listContent = ref<InstanceType<typeof ListContent> | null>(null)
|
|
85
|
+
|
|
86
|
+
const $cwa = useCwa()
|
|
87
|
+
const { goToAdd, triggerReload, computedItemLink } = useListPage(listContent)
|
|
88
|
+
|
|
89
|
+
const router = useRouter()
|
|
90
|
+
|
|
91
|
+
const orderOptions = [
|
|
92
|
+
{
|
|
93
|
+
label: 'New - Old',
|
|
94
|
+
value: { createdAt: 'desc' },
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
label: 'Old - New',
|
|
98
|
+
value: { createdAt: 'asc' },
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
label: 'A - Z',
|
|
102
|
+
value: { reference: 'asc' },
|
|
103
|
+
},
|
|
104
|
+
{
|
|
105
|
+
label: 'Z - A',
|
|
106
|
+
value: { reference: 'desc' },
|
|
107
|
+
},
|
|
108
|
+
]
|
|
109
|
+
|
|
110
|
+
const { model: selectedTypesModel } = useQueryBoundModel('isTemplate[]', {
|
|
111
|
+
defaultValue: ['true', 'false'],
|
|
112
|
+
})
|
|
113
|
+
|
|
114
|
+
function goToPage(page: string) {
|
|
115
|
+
router.push(page)
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
function getDisplayPageUi(ui: string) {
|
|
119
|
+
return $cwa.pagesConfig?.[ui]?.name || ui
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
useHead({
|
|
123
|
+
title: 'Pages',
|
|
124
|
+
})
|
|
125
|
+
|
|
126
|
+
definePageMeta({
|
|
127
|
+
pageTransition: false,
|
|
128
|
+
})
|
|
129
|
+
</script>
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<ListHeading
|
|
3
|
+
title="Routes"
|
|
4
|
+
:hide-add="true"
|
|
5
|
+
/>
|
|
6
|
+
<ListFilter
|
|
7
|
+
:order-options="orderOptions"
|
|
8
|
+
:search-fields="['path']"
|
|
9
|
+
/>
|
|
10
|
+
<ListContent
|
|
11
|
+
ref="listContent"
|
|
12
|
+
fetch-url="/_/routes"
|
|
13
|
+
>
|
|
14
|
+
<template #item="{ data, rawData }">
|
|
15
|
+
<RouteListRow
|
|
16
|
+
:data="data"
|
|
17
|
+
:associated-resources="rawData.associatedResources"
|
|
18
|
+
:link-fn="computedItemLink"
|
|
19
|
+
@delete="deleteRoute"
|
|
20
|
+
/>
|
|
21
|
+
</template>
|
|
22
|
+
</ListContent>
|
|
23
|
+
</template>
|
|
24
|
+
|
|
25
|
+
<script lang="ts" setup>
|
|
26
|
+
import { ref } from 'vue'
|
|
27
|
+
import { useHead } from '#app'
|
|
28
|
+
import ListHeading from '#cwa/runtime/templates/components/core/admin/ListHeading.vue'
|
|
29
|
+
import ListContent from '#cwa/runtime/templates/components/core/admin/ListContent.vue'
|
|
30
|
+
import ListFilter from '#cwa/runtime/templates/components/core/admin/ListFilter.vue'
|
|
31
|
+
import { useListPage } from '#cwa/layer/pages/_cwa/composables/useListPage'
|
|
32
|
+
import { definePageMeta, useCwa } from '#imports'
|
|
33
|
+
import RouteListRow from '#cwa/runtime/templates/components/core/admin/RouteListRow.vue'
|
|
34
|
+
|
|
35
|
+
const $cwa = useCwa()
|
|
36
|
+
const listContent = ref<InstanceType<typeof ListContent> | null>(null)
|
|
37
|
+
const { computedItemLink, triggerReload } = useListPage(listContent, true)
|
|
38
|
+
|
|
39
|
+
async function deleteRoute(routeIri: string) {
|
|
40
|
+
await $cwa.resourcesManager.deleteResource({
|
|
41
|
+
endpoint: routeIri,
|
|
42
|
+
})
|
|
43
|
+
triggerReload()
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
const orderOptions = [
|
|
47
|
+
{
|
|
48
|
+
label: 'New - Old',
|
|
49
|
+
value: { createdAt: 'desc' },
|
|
50
|
+
},
|
|
51
|
+
{
|
|
52
|
+
label: 'Old - New',
|
|
53
|
+
value: { createdAt: 'asc' },
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
label: 'A - Z',
|
|
57
|
+
value: { path: 'asc' },
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
label: 'Z - A',
|
|
61
|
+
value: { path: 'desc' },
|
|
62
|
+
},
|
|
63
|
+
]
|
|
64
|
+
|
|
65
|
+
useHead({
|
|
66
|
+
title: 'Routes',
|
|
67
|
+
})
|
|
68
|
+
|
|
69
|
+
definePageMeta({
|
|
70
|
+
pageTransition: false,
|
|
71
|
+
})
|
|
72
|
+
</script>
|