@antelopejs/dms 0.8.3 → 0.9.1
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/CHANGELOG.md +36 -0
- package/data/module-store/catalog.json +71 -0
- package/dist/config.d.ts +7 -0
- package/dist/config.js +8 -0
- package/dist/config.js.map +1 -1
- package/dist/implementations/dms/frontend-backend-proxies.d.ts +3 -0
- package/dist/implementations/dms/frontend-backend-proxies.js +39 -0
- package/dist/implementations/dms/frontend-backend-proxies.js.map +1 -0
- package/dist/implementations/dms/frontend-bootstrap.d.ts +1 -0
- package/dist/implementations/dms/frontend-bootstrap.js +13 -0
- package/dist/implementations/dms/frontend-bootstrap.js.map +1 -1
- package/dist/implementations/dms/frontend-modules.d.ts +6 -2
- package/dist/implementations/dms/frontend-modules.js +37 -8
- package/dist/implementations/dms/frontend-modules.js.map +1 -1
- package/dist/implementations/dms/frontend-ready.d.ts +8 -0
- package/dist/implementations/dms/frontend-ready.js +34 -0
- package/dist/implementations/dms/frontend-ready.js.map +1 -0
- package/dist/implementations/dms/manifest.d.ts +7 -0
- package/dist/implementations/dms/manifest.js +13 -0
- package/dist/implementations/dms/manifest.js.map +1 -1
- package/dist/implementations/dms/menu-categories.d.ts +16 -0
- package/dist/implementations/dms/menu-categories.js +30 -0
- package/dist/implementations/dms/menu-categories.js.map +1 -0
- package/dist/implementations/dms/nav-badges.d.ts +0 -8
- package/dist/implementations/dms/nav-badges.js +0 -16
- package/dist/implementations/dms/nav-badges.js.map +1 -1
- package/dist/implementations/dms/page.d.ts +13 -5
- package/dist/implementations/dms/page.js +72 -41
- package/dist/implementations/dms/page.js.map +1 -1
- package/dist/implementations/dms-html-render/index.js +5 -2
- package/dist/implementations/dms-html-render/index.js.map +1 -1
- package/dist/implementations/dms-notifications/index.d.ts +4 -3
- package/dist/implementations/dms-notifications/index.js +14 -6
- package/dist/implementations/dms-notifications/index.js.map +1 -1
- package/dist/pages/settings/settings-index.js +3 -2
- package/dist/pages/settings/settings-index.js.map +1 -1
- package/dist/pages/settings/users/invites.js +2 -2
- package/dist/pages/settings/users/invites.js.map +1 -1
- package/dist/pages/settings/users/member-change-notifications.js +17 -6
- package/dist/pages/settings/users/member-change-notifications.js.map +1 -1
- package/dist/pages/settings/users/member-invite-form.d.ts +3 -2
- package/dist/pages/settings/users/member-invite-form.js +7 -4
- package/dist/pages/settings/users/member-invite-form.js.map +1 -1
- package/dist/pages/settings/users/member-roles-field.js +2 -1
- package/dist/pages/settings/users/member-roles-field.js.map +1 -1
- package/dist/pages/settings/users/members.js +4 -1
- package/dist/pages/settings/users/members.js.map +1 -1
- package/dist/pages/settings/users/notifications.d.ts +6 -0
- package/dist/pages/settings/users/notifications.js +23 -15
- package/dist/pages/settings/users/notifications.js.map +1 -1
- package/dist/pages/settings/users/profile.js +1 -1
- package/dist/pages/settings/users/profile.js.map +1 -1
- package/dist/pages/settings/users/region-form.d.ts +1 -1
- package/dist/pages/settings/users/region-form.js +2 -1
- package/dist/pages/settings/users/region-form.js.map +1 -1
- package/dist/pages/settings/users/role-editor-store.d.ts +3 -1
- package/dist/pages/settings/users/role-editor-store.js +17 -4
- package/dist/pages/settings/users/role-editor-store.js.map +1 -1
- package/dist/pages/settings/users/roles.js +1 -0
- package/dist/pages/settings/users/roles.js.map +1 -1
- package/dist/realtime/registry.d.ts +1 -0
- package/dist/realtime/registry.js +5 -0
- package/dist/realtime/registry.js.map +1 -1
- package/dist/routes/index.d.ts +1 -0
- package/dist/routes/index.js +1 -0
- package/dist/routes/index.js.map +1 -1
- package/dist/routes/realtime.d.ts +5 -1
- package/dist/routes/realtime.js +16 -9
- package/dist/routes/realtime.js.map +1 -1
- package/dist/routes/store.d.ts +21 -0
- package/dist/routes/store.js +130 -0
- package/dist/routes/store.js.map +1 -0
- package/dist/store/activity.d.ts +2 -0
- package/dist/store/activity.js +12 -0
- package/dist/store/activity.js.map +1 -0
- package/dist/store/cache.d.ts +8 -0
- package/dist/store/cache.js +29 -0
- package/dist/store/cache.js.map +1 -0
- package/dist/store/catalog.d.ts +4 -0
- package/dist/store/catalog.js +69 -0
- package/dist/store/catalog.js.map +1 -0
- package/dist/store/compatibility.d.ts +3 -0
- package/dist/store/compatibility.js +45 -0
- package/dist/store/compatibility.js.map +1 -0
- package/dist/store/declarations.d.ts +18 -0
- package/dist/store/declarations.js +116 -0
- package/dist/store/declarations.js.map +1 -0
- package/dist/store/frontend-compatibility.d.ts +18 -0
- package/dist/store/frontend-compatibility.js +93 -0
- package/dist/store/frontend-compatibility.js.map +1 -0
- package/dist/store/interfaces.d.ts +6 -0
- package/dist/store/interfaces.js +126 -0
- package/dist/store/interfaces.js.map +1 -0
- package/dist/store/listing.d.ts +2 -0
- package/dist/store/listing.js +180 -0
- package/dist/store/listing.js.map +1 -0
- package/dist/store/operations.d.ts +8 -0
- package/dist/store/operations.js +254 -0
- package/dist/store/operations.js.map +1 -0
- package/dist/store/registry.d.ts +4 -0
- package/dist/store/registry.js +61 -0
- package/dist/store/registry.js.map +1 -0
- package/dist/store/requirements.d.ts +14 -0
- package/dist/store/requirements.js +81 -0
- package/dist/store/requirements.js.map +1 -0
- package/dist/store/runtime.d.ts +11 -0
- package/dist/store/runtime.js +78 -0
- package/dist/store/runtime.js.map +1 -0
- package/dist/store/tarball.d.ts +2 -0
- package/dist/store/tarball.js +80 -0
- package/dist/store/tarball.js.map +1 -0
- package/dist/store/types.d.ts +98 -0
- package/dist/store/types.js +3 -0
- package/dist/store/types.js.map +1 -0
- package/dist/test/integration/account-deletion.test.js +2 -2
- package/dist/test/integration/account-deletion.test.js.map +1 -1
- package/dist/test/integration/auth/auth-key-rotation.test.js +2 -1
- package/dist/test/integration/auth/auth-key-rotation.test.js.map +1 -1
- package/dist/test/integration/auth/current-password.test.js +2 -1
- package/dist/test/integration/auth/current-password.test.js.map +1 -1
- package/dist/test/integration/auth/session-revocation.test.js +2 -1
- package/dist/test/integration/auth/session-revocation.test.js.map +1 -1
- package/dist/test/integration/auth/sign-in-country.test.js +2 -1
- package/dist/test/integration/auth/sign-in-country.test.js.map +1 -1
- package/dist/test/integration/auth/two-factor-codes.test.js +2 -1
- package/dist/test/integration/auth/two-factor-codes.test.js.map +1 -1
- package/dist/test/integration/auth/two-factor-password.test.js +3 -2
- package/dist/test/integration/auth/two-factor-password.test.js.map +1 -1
- package/dist/test/integration/email-change.test.js +2 -1
- package/dist/test/integration/email-change.test.js.map +1 -1
- package/dist/test/integration/files/component-files.test.js +2 -2
- package/dist/test/integration/files/component-files.test.js.map +1 -1
- package/dist/test/integration/member-settings-access.test.js +8 -7
- package/dist/test/integration/member-settings-access.test.js.map +1 -1
- package/dist/test/integration/menu-access-events.test.d.ts +1 -0
- package/dist/test/integration/menu-access-events.test.js +148 -0
- package/dist/test/integration/menu-access-events.test.js.map +1 -0
- package/dist/test/integration/notification-inbox.test.js +4 -1
- package/dist/test/integration/notification-inbox.test.js.map +1 -1
- package/dist/test/integration/notification-locked-subjects.test.js +3 -2
- package/dist/test/integration/notification-locked-subjects.test.js.map +1 -1
- package/dist/test/integration/notification-unread-badge.test.js +51 -5
- package/dist/test/integration/notification-unread-badge.test.js.map +1 -1
- package/dist/test/integration/page-layout-route-guard.test.d.ts +1 -0
- package/dist/test/integration/page-layout-route-guard.test.js +56 -0
- package/dist/test/integration/page-layout-route-guard.test.js.map +1 -0
- package/dist/test/integration/permission-warnings.test.js +3 -2
- package/dist/test/integration/permission-warnings.test.js.map +1 -1
- package/dist/test/integration/removed-member-notifications.test.js +3 -2
- package/dist/test/integration/removed-member-notifications.test.js.map +1 -1
- package/dist/test/integration/role-delete-reassign.test.js +2 -1
- package/dist/test/integration/role-delete-reassign.test.js.map +1 -1
- package/dist/test/integration/role-permission-ancestors.test.js +2 -1
- package/dist/test/integration/role-permission-ancestors.test.js.map +1 -1
- package/dist/test/unit/frontend-bootstrap.test.js +13 -0
- package/dist/test/unit/frontend-bootstrap.test.js.map +1 -1
- package/dist/test/unit/implementations/dms/category-slug-registry.test.js +14 -5
- package/dist/test/unit/implementations/dms/category-slug-registry.test.js.map +1 -1
- package/dist/test/unit/implementations/dms/frontend-backend-proxies.test.d.ts +1 -0
- package/dist/test/unit/implementations/dms/frontend-backend-proxies.test.js +66 -0
- package/dist/test/unit/implementations/dms/frontend-backend-proxies.test.js.map +1 -0
- package/dist/test/unit/implementations/dms/manifest-strip.test.js +26 -0
- package/dist/test/unit/implementations/dms/manifest-strip.test.js.map +1 -1
- package/dist/test/unit/implementations/dms/nav-badges.test.js +23 -9
- package/dist/test/unit/implementations/dms/nav-badges.test.js.map +1 -1
- package/dist/test/unit/implementations/dms-html-render/generate-html.test.js +22 -4
- package/dist/test/unit/implementations/dms-html-render/generate-html.test.js.map +1 -1
- package/dist/test/unit/interfaces/dms/page-layout-query.test.js +12 -0
- package/dist/test/unit/interfaces/dms/page-layout-query.test.js.map +1 -1
- package/dist/test/unit/interfaces/dms/page-teardown.test.js +1 -1
- package/dist/test/unit/interfaces/dms/page-teardown.test.js.map +1 -1
- package/dist/test/unit/pages/settings/member-roles-field.test.js +1 -1
- package/dist/test/unit/pages/settings/member-roles-field.test.js.map +1 -1
- package/dist/test/unit/pages/settings/role-delete-confirm.test.js.map +1 -1
- package/dist/test/unit/realtime/menu-topics.test.d.ts +1 -0
- package/dist/test/unit/realtime/menu-topics.test.js +26 -0
- package/dist/test/unit/realtime/menu-topics.test.js.map +1 -0
- package/dist/test/unit/store/store.test.d.ts +1 -0
- package/dist/test/unit/store/store.test.js +127 -0
- package/dist/test/unit/store/store.test.js.map +1 -0
- package/dist/validation/store.schema.d.ts +39 -0
- package/dist/validation/store.schema.js +27 -0
- package/dist/validation/store.schema.js.map +1 -0
- package/frontend-vue/deferred-plugins.ts +3 -4
- package/frontend-vue/dms.email.ts +5 -1
- package/frontend-vue/dms.frontend.ts +15 -5
- package/frontend-vue/dms.server.ts +74 -0
- package/frontend-vue/layers/dms-auth/app/composables/useLogout.ts +1 -1
- package/frontend-vue/layers/dms-auth/app/composables/usePostLoginRedirect.ts +16 -3
- package/frontend-vue/layers/dms-auth/app/custom-pages/auth/2fa.vue +3 -1
- package/frontend-vue/layers/dms-auth/app/custom-pages/auth/backup.vue +3 -1
- package/frontend-vue/layers/dms-auth/app/custom-pages/auth/forgot-validation.vue +1 -1
- package/frontend-vue/layers/dms-auth/app/custom-pages/auth/oauth-complete.vue +26 -3
- package/frontend-vue/layers/dms-auth/app/custom-pages/auth/recover.vue +1 -1
- package/frontend-vue/layers/dms-auth/app/custom-pages/auth/signup.vue +22 -25
- package/frontend-vue/layers/dms-auth/app/custom-pages/auth/validate.vue +1 -1
- package/frontend-vue/layers/dms-auth/app/middleware/auth.ts +5 -7
- package/frontend-vue/layers/dms-auth/app/plugins/permissions-preload.ts +17 -0
- package/frontend-vue/layers/dms-auth/server/accounts.ts +135 -0
- package/frontend-vue/layers/dms-auth/server/actions.ts +251 -0
- package/frontend-vue/layers/dms-auth/server/oauth.ts +260 -0
- package/frontend-vue/layers/dms-auth/server/session.ts +158 -0
- package/frontend-vue/layers/dms-core/app/build/utils/asyncDataScope.ts +47 -0
- package/frontend-vue/layers/dms-core/app/build/utils/permission-preview.ts +6 -2
- package/frontend-vue/layers/dms-core/app/composables/auth/useApiData.ts +148 -0
- package/frontend-vue/layers/dms-core/app/composables/auth/useAuthFetch.ts +7 -20
- package/frontend-vue/layers/dms-core/app/composables/auth/useCurrentUser.ts +2 -2
- package/frontend-vue/layers/dms-core/app/composables/auth/useMultiAccount.ts +18 -5
- package/frontend-vue/layers/dms-core/app/composables/auth/usePermissions.ts +35 -6
- package/frontend-vue/layers/dms-core/app/composables/auth/useSessionRecovery.ts +1 -1
- package/frontend-vue/layers/dms-core/app/composables/period/compareResolvers.ts +20 -14
- package/frontend-vue/layers/dms-core/app/composables/period/periodClock.ts +121 -0
- package/frontend-vue/layers/dms-core/app/composables/period/periodRenderNow.ts +42 -0
- package/frontend-vue/layers/dms-core/app/composables/period/periodTimeZone.ts +31 -0
- package/frontend-vue/layers/dms-core/app/composables/period/presetResolvers.ts +48 -19
- package/frontend-vue/layers/dms-core/app/composables/period/usePeriod.ts +33 -4
- package/frontend-vue/layers/dms-core/app/composables/period/usePeriodScope.ts +78 -25
- package/frontend-vue/layers/dms-core/app/composables/realtime/usePageRealtime.ts +3 -0
- package/frontend-vue/layers/dms-core/app/composables/realtime/useUserRealtime.ts +36 -6
- package/frontend-vue/layers/dms-core/app/composables/user/useUserRegionalPreferences.ts +1 -1
- package/frontend-vue/layers/dms-core/app/plugins/async-data-scope.ts +26 -0
- package/frontend-vue/layers/dms-core/app/utils/pageRoutes.ts +22 -0
- package/frontend-vue/layers/dms-core/app/utils/regional.ts +36 -3
- package/frontend-vue/layers/dms-core/app/utils/trailingDeduper.ts +10 -1
- package/frontend-vue/layers/dms-core/shared/types/app-config.ts +48 -4
- package/frontend-vue/layers/dms-layout/app/app.config.ts +42 -23
- package/frontend-vue/layers/dms-layout/app/assets/css/main.css +72 -20
- package/frontend-vue/layers/dms-layout/app/build/components/layout/DashboardFrame.vue +9 -0
- package/frontend-vue/layers/dms-layout/app/build/components/layout/DashboardSidebar.vue +0 -3
- package/frontend-vue/layers/dms-layout/app/build/components/notification/NotificationPopover.vue +9 -3
- package/frontend-vue/layers/dms-layout/app/build/components/pages/modules/ModuleStoreDependencyPicker.vue +136 -0
- package/frontend-vue/layers/dms-layout/app/build/components/pages/modules/ModuleStoreRequirements.vue +98 -0
- package/frontend-vue/layers/dms-layout/app/build/components/pages/modules/ModuleStoreTile.vue +247 -29
- package/frontend-vue/layers/dms-layout/app/build/components/pages/modules/ModuleTile.vue +19 -2
- package/frontend-vue/layers/dms-layout/app/build/components/pages/settings/members/MemberRolePicker.vue +13 -12
- package/frontend-vue/layers/dms-layout/app/build/components/pages/settings/notification/NotificationInboxDisplay.vue +17 -7
- package/frontend-vue/layers/dms-layout/app/build/components/pages/settings/notification/NotificationPreferencesForm.vue +0 -1
- package/frontend-vue/layers/dms-layout/app/build/components/pages/settings/profile/ProfilePersonalInfo.vue +36 -33
- package/frontend-vue/layers/dms-layout/app/build/components/pages/settings/profile/ProfileSecuritySummary.vue +1 -2
- package/frontend-vue/layers/dms-layout/app/build/components/pages/settings/roles/role-types.ts +5 -4
- package/frontend-vue/layers/dms-layout/app/build/components/pages/settings/security/SecuritySessions.vue +35 -28
- package/frontend-vue/layers/dms-layout/app/build/components/pages/settings/security/SecurityStatus.vue +0 -1
- package/frontend-vue/layers/dms-layout/app/build/components/pages/settings/security/SecurityTwoFactor.vue +1 -1
- package/frontend-vue/layers/dms-layout/app/build/composables/dev-reload/useDevReloadHolder.ts +7 -6
- package/frontend-vue/layers/dms-layout/app/build/composables/layout/sidePanelState.ts +1 -1
- package/frontend-vue/layers/dms-layout/app/build/composables/navigation/useVisitNavBadges.ts +26 -0
- package/frontend-vue/layers/dms-layout/app/build/composables/notification/useNotificationCatalog.ts +25 -23
- package/frontend-vue/layers/dms-layout/app/build/composables/notification/useNotificationPreferences.ts +44 -23
- package/frontend-vue/layers/dms-layout/app/build/composables/security/useSessionHandoff.ts +1 -1
- package/frontend-vue/layers/dms-layout/app/build/composables/settings/profile/preferencesSummary.ts +1 -1
- package/frontend-vue/layers/dms-layout/app/build/composables/settings/profile/useAccountData.ts +3 -2
- package/frontend-vue/layers/dms-layout/app/build/composables/settings/profile/useProfileAvatar.ts +1 -18
- package/frontend-vue/layers/dms-layout/app/build/composables/settings/profile/useProfilePreferences.ts +19 -23
- package/frontend-vue/layers/dms-layout/app/build/composables/settings/security/useSecurityFormat.ts +6 -3
- package/frontend-vue/layers/dms-layout/app/build/composables/settings/security/useSecurityOverview.ts +13 -18
- package/frontend-vue/layers/dms-layout/app/build/utils/module-store-catalog.ts +186 -120
- package/frontend-vue/layers/dms-layout/app/build/utils/module-store-install.ts +146 -0
- package/frontend-vue/layers/dms-layout/app/build/utils/modules-catalog.ts +8 -6
- package/frontend-vue/layers/dms-layout/app/build/utils/publicErrorMessage.ts +19 -0
- package/frontend-vue/layers/dms-layout/app/components/navigation/CollapsedMenuItem.vue +0 -11
- package/frontend-vue/layers/dms-layout/app/components/navigation/NavigationMenu.vue +3 -13
- package/frontend-vue/layers/dms-layout/app/composables/general/useSystemState.ts +7 -11
- package/frontend-vue/layers/dms-layout/app/composables/notification/useNotifications.ts +103 -22
- package/frontend-vue/layers/dms-layout/app/composables/page/useModuleStore.ts +109 -0
- package/frontend-vue/layers/dms-layout/app/composables/page/useModulesListing.ts +25 -102
- package/frontend-vue/layers/dms-layout/app/composables/page/usePageComponentPreload.ts +0 -10
- package/frontend-vue/layers/dms-layout/app/composables/page/useSiteLayout.ts +177 -96
- package/frontend-vue/layers/dms-layout/app/composables/profile/useUserLanguage.ts +3 -2
- package/frontend-vue/layers/dms-layout/app/custom-pages/modules.vue +341 -62
- package/frontend-vue/layers/dms-layout/app/emails/components/EmailLayout.vue +31 -11
- package/frontend-vue/layers/dms-layout/app/error.vue +5 -2
- package/frontend-vue/layers/dms-layout/app/middleware/module-routing.global.ts +1 -1
- package/frontend-vue/layers/dms-layout/app/middleware/page-leave-guard.global.ts +2 -2
- package/frontend-vue/layers/dms-layout/app/pages/[...slug].vue +12 -9
- package/frontend-vue/layers/dms-layout/app/plugins/dms-menu-sync.client.ts +31 -3
- package/frontend-vue/layers/dms-layout/app/plugins/favicon.ts +58 -0
- package/frontend-vue/layers/dms-layout/app/plugins/notification-stream.client.ts +15 -7
- package/frontend-vue/layers/dms-layout/app/plugins/profile-sync.client.ts +5 -1
- package/frontend-vue/layers/dms-layout/app/plugins/regional-preferences.ts +10 -4
- package/frontend-vue/layers/dms-layout/app/plugins/time-zone-cookie.client.ts +12 -0
- package/frontend-vue/layers/dms-layout/app/types/module-store.ts +134 -0
- package/frontend-vue/layers/dms-layout/app/types/page.ts +13 -0
- package/frontend-vue/layers/dms-layout/i18n/locales/layout-en-GB.json +107 -9
- package/frontend-vue/layers/dms-layout/i18n/locales/layout-fr-FR.json +107 -9
- package/frontend-vue/layers/dms-layout/server/html-render.ts +58 -0
- package/frontend-vue/layers/dms-layout/server/render-token.ts +95 -0
- package/frontend-vue/layers/dms-onboarding/app/composables/onboarding/useOnboarding.ts +25 -21
- package/frontend-vue/layers/dms-onboarding/app/middleware/onboarding.global.ts +1 -1
- package/frontend-vue/layers/dms-onboarding/app/plugins/onboarding-preload.ts +9 -0
- package/frontend-vue/layers/dms-ui/app/build/composables/data-types/registerDefaults.ts +4 -1
- package/frontend-vue/layers/dms-ui/app/build/composables/files/useFileMetadata.ts +162 -0
- package/frontend-vue/layers/dms-ui/app/build/composables/form/formRecordLoad.ts +23 -4
- package/frontend-vue/layers/dms-ui/app/build/composables/live/usePageDataRefresh.ts +101 -0
- package/frontend-vue/layers/dms-ui/app/build/composables/navigation/useNavBadges.ts +33 -6
- package/frontend-vue/layers/dms-ui/app/build/composables/period/periodDisplay.ts +19 -16
- package/frontend-vue/layers/dms-ui/app/build/composables/period/periodQuery.ts +40 -20
- package/frontend-vue/layers/dms-ui/app/build/composables/table-view/useTableFooter.ts +6 -8
- package/frontend-vue/layers/dms-ui/app/build/composables/table-view/useTableListData.ts +42 -14
- package/frontend-vue/layers/dms-ui/app/build/composables/table-view/useTableRows.ts +19 -8
- package/frontend-vue/layers/dms-ui/app/build/composables/table-view/useTableViews.ts +1 -1
- package/frontend-vue/layers/dms-ui/app/components/chart/ChartCard.vue +5 -2
- package/frontend-vue/layers/dms-ui/app/components/flow-canvas/FlowCanvas.vue +9 -9
- package/frontend-vue/layers/dms-ui/app/components/form/Form.vue +20 -18
- package/frontend-vue/layers/dms-ui/app/components/form/components/Cascader.vue +2 -1
- package/frontend-vue/layers/dms-ui/app/components/form/components/File.vue +26 -132
- package/frontend-vue/layers/dms-ui/app/components/form/components/Image.vue +40 -105
- package/frontend-vue/layers/dms-ui/app/components/form/components/InputAddress.vue +2 -0
- package/frontend-vue/layers/dms-ui/app/components/form/components/Relation.vue +4 -4
- package/frontend-vue/layers/dms-ui/app/components/period/PeriodSelector.vue +9 -13
- package/frontend-vue/layers/dms-ui/app/components/table-view/CascaderPath.vue +2 -1
- package/frontend-vue/layers/dms-ui/app/components/table-view/FilePreview.vue +12 -24
- package/frontend-vue/layers/dms-ui/app/components/table-view/ImagePreview.vue +17 -29
- package/frontend-vue/layers/dms-ui/app/components/table-view/KanbanBoard.vue +7 -3
- package/frontend-vue/layers/dms-ui/app/components/table-view/TableView.vue +20 -8
- package/frontend-vue/layers/dms-ui/app/components/top-list/TopListCard.vue +8 -11
- package/frontend-vue/layers/dms-ui/app/composables/chart/useChartFetch.ts +146 -182
- package/frontend-vue/layers/dms-ui/app/composables/live/usePageLiveRefresh.ts +8 -2
- package/frontend-vue/layers/dms-ui/app/composables/useFileReadUrls.ts +11 -99
- package/frontend-vue/layers/dms-ui/app/utils/blockRefresh.ts +32 -3
- package/frontend-vue/package.json +3 -3
- package/frontend-vue/pnpm-lock.yaml +16 -22
- package/frontend-vue/server/private-options.ts +27 -0
- package/frontend-vue/tests/async-data-scope.test.ts +121 -0
- package/frontend-vue/tests/auth-middleware-error.test.ts +3 -3
- package/frontend-vue/tests/banner-block-fetch.test.ts +3 -0
- package/frontend-vue/tests/block-fetch-options-forwarding.test.ts +3 -0
- package/frontend-vue/tests/block-items-period-realtime.test.ts +3 -0
- package/frontend-vue/tests/block-not-found.test.ts +16 -2
- package/frontend-vue/tests/block-page-refresh.test.ts +3 -0
- package/frontend-vue/tests/block-route-params.test.ts +3 -0
- package/frontend-vue/tests/branding-defaults.test.ts +34 -0
- package/frontend-vue/tests/builtin-emails.test.ts +23 -2
- package/frontend-vue/tests/chart-live-pause.test.ts +4 -1
- package/frontend-vue/tests/chart-value-propagation.test.ts +4 -1
- package/frontend-vue/tests/composed-text-blocks.test.ts +3 -0
- package/frontend-vue/tests/email-layout.test.ts +66 -4
- package/frontend-vue/tests/error-page-message.test.ts +25 -2
- package/frontend-vue/tests/favicon.test.ts +131 -0
- package/frontend-vue/tests/file-fields-ssr.test.ts +145 -0
- package/frontend-vue/tests/file-read-urls.test.ts +145 -34
- package/frontend-vue/tests/file-unavailable.test.ts +5 -1
- package/frontend-vue/tests/fixtures/dataEngine.ts +44 -0
- package/frontend-vue/tests/form-load-error.test.ts +55 -1
- package/frontend-vue/tests/helpers/api-data-runtime.ts +77 -0
- package/frontend-vue/tests/image-hydration-ids.test.ts +21 -16
- package/frontend-vue/tests/image-reference-preservation.test.ts +59 -53
- package/frontend-vue/tests/input-number-adjust.test.ts +14 -0
- package/frontend-vue/tests/key-value-list-copy.test.ts +3 -0
- package/frontend-vue/tests/member-role-picker.test.ts +4 -2
- package/frontend-vue/tests/menu-sync-reconnect.test.ts +47 -0
- package/frontend-vue/tests/metadata-retry.test.ts +5 -1
- package/frontend-vue/tests/module-routing.test.ts +2 -5
- package/frontend-vue/tests/module-store-catalog.test.ts +270 -51
- package/frontend-vue/tests/modules-catalog.test.ts +17 -4
- package/frontend-vue/tests/modules-listing-transfer.test.ts +95 -0
- package/frontend-vue/tests/multi-account-validate.test.ts +23 -1
- package/frontend-vue/tests/nav-badge-tones.test.ts +66 -3
- package/frontend-vue/tests/notification-counts-from-writes.test.ts +223 -0
- package/frontend-vue/tests/notification-counts-transfer.test.ts +88 -0
- package/frontend-vue/tests/notification-inbox-display.test.ts +57 -5
- package/frontend-vue/tests/notification-popover-errors.test.ts +21 -1
- package/frontend-vue/tests/oauth-complete-handoff.test.ts +209 -0
- package/frontend-vue/tests/onboarding-middleware.test.ts +1 -1
- package/frontend-vue/tests/onboarding-transfer.test.ts +106 -0
- package/frontend-vue/tests/page-data-refresh.test.ts +141 -0
- package/frontend-vue/tests/page-fill-height.test.ts +16 -3
- package/frontend-vue/tests/page-no-visible-blocks.test.ts +12 -2
- package/frontend-vue/tests/page-realtime-remount.test.ts +1 -1
- package/frontend-vue/tests/page-record-label.test.ts +0 -7
- package/frontend-vue/tests/page-validation-redirect.test.ts +12 -2
- package/frontend-vue/tests/period-hydration-now.test.ts +185 -0
- package/frontend-vue/tests/period-live-pause.test.ts +3 -0
- package/frontend-vue/tests/period-reader-zone.test.ts +137 -0
- package/frontend-vue/tests/period-scope-first-fetch.test.ts +17 -1
- package/frontend-vue/tests/period-ssr.test.ts +195 -0
- package/frontend-vue/tests/permission-preview-partial.test.ts +0 -2
- package/frontend-vue/tests/permissions-transfer.test.ts +194 -0
- package/frontend-vue/tests/post-login-redirect.test.ts +10 -5
- package/frontend-vue/tests/profile-personal-info-ssr.test.ts +150 -0
- package/frontend-vue/tests/profile-preferences-summary.test.ts +15 -11
- package/frontend-vue/tests/realtime-reconnect.test.ts +22 -3
- package/frontend-vue/tests/roles-name-errors.test.ts +1 -1
- package/frontend-vue/tests/row-side-panel.test.ts +1 -1
- package/frontend-vue/tests/security-sessions-load-error.test.ts +3 -1
- package/frontend-vue/tests/server-routes-vs-pages.test.ts +26 -0
- package/frontend-vue/tests/server-routes.test.ts +582 -0
- package/frontend-vue/tests/session-handoff.test.ts +1 -1
- package/frontend-vue/tests/settings-reads-ssr.test.ts +232 -0
- package/frontend-vue/tests/side-panels.test.ts +8 -1
- package/frontend-vue/tests/sign-in-exit-history.test.ts +219 -0
- package/frontend-vue/tests/signup-invitation-link.test.ts +56 -8
- package/frontend-vue/tests/site-layout-categories.test.ts +42 -0
- package/frontend-vue/tests/site-layout-hydration.test.ts +3 -3
- package/frontend-vue/tests/site-layout-rendered.test.ts +103 -0
- package/frontend-vue/tests/site-layout-resync.test.ts +87 -0
- package/frontend-vue/tests/ssr-guard-preload.test.ts +188 -0
- package/frontend-vue/tests/table-cell-tones.test.ts +36 -1
- package/frontend-vue/tests/table-data-ssr.test.ts +195 -0
- package/frontend-vue/tests/table-list-data-requests.test.ts +154 -0
- package/frontend-vue/tests/table-retry-loading.test.ts +37 -0
- package/frontend-vue/tests/table-source-navigation.test.ts +0 -1
- package/frontend-vue/tests/table-source-period-scope.test.ts +0 -1
- package/frontend-vue/tests/table-view-views.test.ts +1 -1
- package/frontend-vue/tests/top-list-card-actions.test.ts +3 -0
- package/frontend-vue/tests/top-list-card-period-badge-ssr.test.ts +212 -0
- package/frontend-vue/tests/top-list-card-period-badge.test.ts +79 -0
- package/frontend-vue/tests/top-list-card-value-suffix.test.ts +3 -0
- package/frontend-vue/tests/trailing-deduper.test.ts +22 -0
- package/frontend-vue/tests/use-api-data-update.test.ts +119 -0
- package/frontend-vue/tests/use-api-data.test.ts +410 -0
- package/frontend-vue/tests/user-language.test.ts +8 -5
- package/frontend-vue/tests/widget-label-i18n.test.ts +4 -1
- package/frontend-vue/vitest.config.ts +6 -0
- package/package.json +2 -2
- package/skills/dms/SKILL.md +2 -1
- package/skills/dms-module/SKILL.md +1 -1
- package/skills/dms-pages/SKILL.md +4 -1
- package/frontend-vue/layers/dms-core/app/build/composables/page/usePageRecordLabel.ts +0 -9
- package/frontend-vue/layers/dms-layout/app/composables/page/usePrefetch.ts +0 -21
- package/frontend-vue/layers/dms-ui/app/build/composables/form/useControlError.ts +0 -10
- package/frontend-vue/layers/dms-ui/app/build/composables/table-view/useServerRenderedAsyncData.ts +0 -23
- package/frontend-vue/tests/control-error-path.test.ts +0 -11
- package/frontend-vue/tests/modules-listing-per-request.test.ts +0 -104
- package/frontend-vue/tests/page-layout-background-refresh.test.ts +0 -321
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.INTERFACE_PACKAGE = void 0;
|
|
4
|
+
exports.npmView = npmView;
|
|
5
|
+
exports.latestRelease = latestRelease;
|
|
6
|
+
const node_child_process_1 = require("node:child_process");
|
|
7
|
+
const node_util_1 = require("node:util");
|
|
8
|
+
const execFileAsync = (0, node_util_1.promisify)(node_child_process_1.execFile);
|
|
9
|
+
const RELEASE_TTL_MS = 60 * 60 * 1000;
|
|
10
|
+
const FAILED_RELEASE_TTL_MS = 5 * 60 * 1000;
|
|
11
|
+
const NPM_VIEW_TIMEOUT_MS = 30_000;
|
|
12
|
+
const LATEST_TAG = "latest";
|
|
13
|
+
exports.INTERFACE_PACKAGE = "@antelopejs/interface-dms";
|
|
14
|
+
const releases = new Map();
|
|
15
|
+
const pending = new Map();
|
|
16
|
+
async function npmView(spec, fields, projectPath) {
|
|
17
|
+
try {
|
|
18
|
+
const { stdout } = await execFileAsync("npm", ["view", spec, ...fields, "--json"], { cwd: projectPath, timeout: NPM_VIEW_TIMEOUT_MS });
|
|
19
|
+
return stdout.trim() ? JSON.parse(stdout) : undefined;
|
|
20
|
+
}
|
|
21
|
+
catch {
|
|
22
|
+
return undefined;
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
async function viewLatest(packageName, projectPath) {
|
|
26
|
+
const view = (await npmView(`${packageName}@${LATEST_TAG}`, ["version", "dependencies", "antelopeJs"], projectPath));
|
|
27
|
+
if (!view?.version)
|
|
28
|
+
return undefined;
|
|
29
|
+
return {
|
|
30
|
+
version: view.version,
|
|
31
|
+
interfaceRange: view.dependencies?.[exports.INTERFACE_PACKAGE],
|
|
32
|
+
dependencies: view.dependencies ?? {},
|
|
33
|
+
implements: Array.isArray(view.antelopeJs?.implements)
|
|
34
|
+
? view.antelopeJs.implements.map(String)
|
|
35
|
+
: [],
|
|
36
|
+
};
|
|
37
|
+
}
|
|
38
|
+
function isFresh(cached) {
|
|
39
|
+
if (!cached)
|
|
40
|
+
return false;
|
|
41
|
+
const ttl = cached.release ? RELEASE_TTL_MS : FAILED_RELEASE_TTL_MS;
|
|
42
|
+
return Date.now() - cached.fetchedAt < ttl;
|
|
43
|
+
}
|
|
44
|
+
function latestRelease(packageName, projectPath, force = false) {
|
|
45
|
+
const cached = releases.get(packageName);
|
|
46
|
+
if (!force && isFresh(cached)) {
|
|
47
|
+
return Promise.resolve(cached?.release);
|
|
48
|
+
}
|
|
49
|
+
const inFlight = pending.get(packageName);
|
|
50
|
+
if (inFlight)
|
|
51
|
+
return inFlight;
|
|
52
|
+
const lookup = viewLatest(packageName, projectPath)
|
|
53
|
+
.then((release) => {
|
|
54
|
+
releases.set(packageName, { fetchedAt: Date.now(), release });
|
|
55
|
+
return release;
|
|
56
|
+
})
|
|
57
|
+
.finally(() => pending.delete(packageName));
|
|
58
|
+
pending.set(packageName, lookup);
|
|
59
|
+
return lookup;
|
|
60
|
+
}
|
|
61
|
+
//# sourceMappingURL=registry.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"registry.js","sourceRoot":"","sources":["../../src/store/registry.ts"],"names":[],"mappings":";;;AAgCA,0BAeC;AAiCD,sCAmBC;AAnGD,2DAA8C;AAC9C,yCAAsC;AAGtC,MAAM,aAAa,GAAG,IAAA,qBAAS,EAAC,6BAAQ,CAAC,CAAC;AAE1C,MAAM,cAAc,GAAG,EAAE,GAAG,EAAE,GAAG,IAAI,CAAC;AAEtC,MAAM,qBAAqB,GAAG,CAAC,GAAG,EAAE,GAAG,IAAI,CAAC;AAC5C,MAAM,mBAAmB,GAAG,MAAM,CAAC;AACnC,MAAM,UAAU,GAAG,QAAQ,CAAC;AACf,QAAA,iBAAiB,GAAG,2BAA2B,CAAC;AAa7D,MAAM,QAAQ,GAAG,IAAI,GAAG,EAAyB,CAAC;AAClD,MAAM,OAAO,GAAG,IAAI,GAAG,EAA+C,CAAC;AAOhE,KAAK,UAAU,OAAO,CAC3B,IAAY,EACZ,MAAyB,EACzB,WAAmB;IAEnB,IAAI,CAAC;QACH,MAAM,EAAE,MAAM,EAAE,GAAG,MAAM,aAAa,CACpC,KAAK,EACL,CAAC,MAAM,EAAE,IAAI,EAAE,GAAG,MAAM,EAAE,QAAQ,CAAC,EACnC,EAAE,GAAG,EAAE,WAAW,EAAE,OAAO,EAAE,mBAAmB,EAAE,CACnD,CAAC;QACF,OAAO,MAAM,CAAC,IAAI,EAAE,CAAC,CAAC,CAAE,IAAI,CAAC,KAAK,CAAC,MAAM,CAAa,CAAC,CAAC,CAAC,SAAS,CAAC;IACrE,CAAC;IAAC,MAAM,CAAC;QACP,OAAO,SAAS,CAAC;IACnB,CAAC;AACH,CAAC;AAED,KAAK,UAAU,UAAU,CACvB,WAAmB,EACnB,WAAmB;IAEnB,MAAM,I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;IAC9B,MAAM,MAAM,GAAG,UAAU,CAAC,WAAW,EAAE,WAAW,CAAC;SAChD,IAAI,CAAC,CAAC,OAAO,EAAE,EAAE;QAChB,QAAQ,CAAC,GAAG,CAAC,WAAW,EAAE,EAAE,SAAS,EAAE,IAAI,CAAC,GAAG,EAAE,EAAE,OAAO,EAAE,CAAC,CAAC;QAC9D,OAAO,OAAO,CAAC;IACjB,CAAC,CAAC;SACD,OAAO,CAAC,GAAG,EAAE,CAAC,OAAO,CAAC,MAAM,CAAC,WAAW,CAAC,CAAC,CAAC;IAC9C,OAAO,CAAC,GAAG,CAAC,WAAW,EAAE,MAAM,CAAC,CAAC;IACjC,OAAO,MAAM,CAAC;AAChB,CAAC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { PackageRelease, RuntimeModule, StoreCatalogEntry, StoreDependencyChoice } from "./types";
|
|
2
|
+
export interface RequirementContext {
|
|
3
|
+
catalogEntry: StoreCatalogEntry;
|
|
4
|
+
projectPath: string;
|
|
5
|
+
key: string;
|
|
6
|
+
dependencies: StoreDependencyChoice[];
|
|
7
|
+
installedDependencies: string[];
|
|
8
|
+
}
|
|
9
|
+
export declare function caretRange(release: PackageRelease): string;
|
|
10
|
+
export declare function assertFrontendSupports(context: RequirementContext, release: PackageRelease): Promise<void>;
|
|
11
|
+
export declare function runningModules(): Promise<RuntimeModule[]>;
|
|
12
|
+
export declare function pickDependencies(context: RequirementContext, release: PackageRelease, label: string): Promise<Map<string, StoreDependencyChoice>>;
|
|
13
|
+
export declare function installDependency(context: RequirementContext, interfacePackage: string, choice: StoreDependencyChoice): Promise<void>;
|
|
14
|
+
export declare function assertNoDependents(context: RequirementContext): Promise<void>;
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.caretRange = caretRange;
|
|
4
|
+
exports.assertFrontendSupports = assertFrontendSupports;
|
|
5
|
+
exports.runningModules = runningModules;
|
|
6
|
+
exports.pickDependencies = pickDependencies;
|
|
7
|
+
exports.installDependency = installDependency;
|
|
8
|
+
exports.assertNoDependents = assertNoDependents;
|
|
9
|
+
const interface_api_util_1 = require("@antelopejs/interface-api-util");
|
|
10
|
+
const declarations_1 = require("./declarations");
|
|
11
|
+
const frontend_compatibility_1 = require("./frontend-compatibility");
|
|
12
|
+
const interfaces_1 = require("./interfaces");
|
|
13
|
+
const registry_1 = require("./registry");
|
|
14
|
+
const runtime_1 = require("./runtime");
|
|
15
|
+
const HTTP_CONFLICT = 409;
|
|
16
|
+
const RANGE_PREFIX = "^";
|
|
17
|
+
function caretRange(release) {
|
|
18
|
+
return `${RANGE_PREFIX}${release.version}`;
|
|
19
|
+
}
|
|
20
|
+
async function assertFrontendSupports(context, release) {
|
|
21
|
+
const { package: packageName } = context.catalogEntry;
|
|
22
|
+
const range = await (0, frontend_compatibility_1.releaseFrontendRange)(packageName, release.version, context.projectPath);
|
|
23
|
+
const running = (0, frontend_compatibility_1.runningFrontend)(context.projectPath);
|
|
24
|
+
if (!range || !running || (0, frontend_compatibility_1.supportsFrontend)(range, running.version))
|
|
25
|
+
return;
|
|
26
|
+
throw new Error(`${packageName}@${release.version} supports ${frontend_compatibility_1.FRONTEND_PACKAGE} ${range}, this project runs ${running.version}`);
|
|
27
|
+
}
|
|
28
|
+
async function runningModules() {
|
|
29
|
+
return [...(await (0, runtime_1.listRuntimeModules)()).values()].filter((module) => (0, runtime_1.isLive)(module));
|
|
30
|
+
}
|
|
31
|
+
async function pickDependencies(context, release, label) {
|
|
32
|
+
const implemented = await (0, interfaces_1.implementedInterfaces)(await runningModules());
|
|
33
|
+
const missing = await (0, interfaces_1.findMissingInterfaces)(release, implemented, context.projectPath);
|
|
34
|
+
const picked = new Map();
|
|
35
|
+
const unpicked = [];
|
|
36
|
+
for (const { interfacePackage } of missing) {
|
|
37
|
+
const choice = context.dependencies.find((dependency) => dependency.interfacePackage === interfacePackage);
|
|
38
|
+
if (choice)
|
|
39
|
+
picked.set(interfacePackage, choice);
|
|
40
|
+
else
|
|
41
|
+
unpicked.push(interfacePackage);
|
|
42
|
+
}
|
|
43
|
+
if (unpicked.length > 0) {
|
|
44
|
+
throw new Error(`${label} needs ${unpicked.join(", ")}, which no running module implements`);
|
|
45
|
+
}
|
|
46
|
+
return picked;
|
|
47
|
+
}
|
|
48
|
+
async function installDependency(context, interfacePackage, choice) {
|
|
49
|
+
const key = choice.package;
|
|
50
|
+
if (await (0, declarations_1.hasDeclaration)(key)) {
|
|
51
|
+
throw new Error(`${key} is already in antelope.config.ts but does not run: start it from there`);
|
|
52
|
+
}
|
|
53
|
+
const release = await (0, registry_1.latestRelease)(key, context.projectPath, true);
|
|
54
|
+
if (!release) {
|
|
55
|
+
throw new Error(`The npm registry has no release of ${key}`);
|
|
56
|
+
}
|
|
57
|
+
const range = caretRange(release);
|
|
58
|
+
context.installedDependencies.push(key);
|
|
59
|
+
await (0, runtime_1.loadStoreModule)(key, { package: key, range, config: choice.config });
|
|
60
|
+
await assertImplements(key, interfacePackage);
|
|
61
|
+
await (0, declarations_1.saveDeclaration)(key, {
|
|
62
|
+
source: (0, declarations_1.packageDeclarationSource)(key, range),
|
|
63
|
+
config: choice.config ?? {},
|
|
64
|
+
optional: true,
|
|
65
|
+
});
|
|
66
|
+
}
|
|
67
|
+
async function assertImplements(key, interfacePackage) {
|
|
68
|
+
const module = await (0, runtime_1.describeRuntimeModule)(key);
|
|
69
|
+
const implemented = module ? await (0, interfaces_1.implementedBy)(module.localPath) : [];
|
|
70
|
+
if (!implemented.includes(interfacePackage)) {
|
|
71
|
+
throw new Error(`${key} does not implement ${interfacePackage}`);
|
|
72
|
+
}
|
|
73
|
+
}
|
|
74
|
+
async function assertNoDependents(context) {
|
|
75
|
+
const module = await (0, runtime_1.describeRuntimeModule)(context.key);
|
|
76
|
+
if (!module || !(0, runtime_1.isLive)(module))
|
|
77
|
+
return;
|
|
78
|
+
const dependents = await (0, interfaces_1.findDependents)(module, await runningModules());
|
|
79
|
+
(0, interface_api_util_1.assert)(dependents.length === 0, HTTP_CONFLICT, "error.store_module_required");
|
|
80
|
+
}
|
|
81
|
+
//# sourceMappingURL=requirements.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"requirements.js","sourceRoot":"","sources":["../../src/store/requirements.ts"],"names":[],"mappings":";;AAgDA,gCAEC;AAOD,wDAeC;AAED,wCAIC;AAMD,4CA0BC;AAMD,8CAwBC;AAiBD,gDAOC;AApKD,uEAAwD;AACxD,iDAIwB;AACxB,qEAKkC;AAClC,6CAKsB;AACtB,yCAA2C;AAC3C,uCAKmB;AAQnB,MAAM,aAAa,GAAG,GAAG,CAAC;AAE1B,MAAM,YAAY,GAAG,GAAG,CAAC;AAczB,SAAgB,UAAU,CAAC,OAAuB;IAChD,OAAO,GAAG,YAAY,GAAG,OAAO,CAAC,OAAO,EAAE,CAAC;AAC7C,CAAC;AAOM,KAAK,UAAU,sBAAsB,CAC1C,OAA2B,EAC3B,OAAuB;IAEvB,MAAM,EAAE,OAAO,EAAE,WAAW,EAAE,GAAG,OAAO,CAAC,YAAY,CAAC;IACtD,MAAM,KAAK,GAAG,MAAM,IAAA,6CAAoB,EACtC,WAAW,EACX,OAAO,CAAC,OAAO,EACf,OAAO,CAAC,WAAW,CACpB,CAAC;IACF,MAAM,OAAO,GAAG,IAAA,wCAAe,EAAC,OAAO,CAAC,WAAW,CAAC,CAAC;IACrD,IAAI,CAAC,KAAK,IAAI,CAAC,OAAO,IAAI,IAAA,yCAAgB,EAAC,KAAK,EAAE,OAAO,CAAC,OAAO,CAAC;QAAE,OAAO;IAC3E,MAAM,IAAI,KAAK,CACb,GAAG,WAAW,IAAI,OAAO,CAAC,OAAO,aAAa,yCAAgB,IAAI,KAAK,uBAAuB,OAAO,CAAC,OAAO,EAAE,CAChH,CAAC;AACJ,CAAC;AAEM,KAAK,UAAU,cAAc;IAClC,OAAO,CAAC,GAAG,CAAC,MAAM,IAAA,4BAAkB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tC,OAA2B;IAE3B,MAAM,MAAM,GAAG,MAAM,IAAA,+BAAqB,EAAC,OAAO,CAAC,GAAG,CAAC,CAAC;IACxD,IAAI,CAAC,MAAM,IAAI,CAAC,IAAA,gBAAM,EAAC,MAAM,CAAC;QAAE,OAAO;IACvC,MAAM,UAAU,GAAG,MAAM,IAAA,2BAAc,EAAC,MAAM,EAAE,MAAM,cAAc,EAAE,CAAC,CAAC;IACxE,IAAA,2BAAM,EAAC,UAAU,CAAC,MAAM,KAAK,CAAC,EAAE,aAAa,EAAE,6BAA6B,CAAC,CAAC;AAChF,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import type { RuntimeModule } from "./types";
|
|
2
|
+
export interface StoreModuleLoad {
|
|
3
|
+
package: string;
|
|
4
|
+
range: string;
|
|
5
|
+
config?: unknown;
|
|
6
|
+
}
|
|
7
|
+
export declare function isLive(module: RuntimeModule | undefined): boolean;
|
|
8
|
+
export declare function listRuntimeModules(): Promise<Map<string, RuntimeModule>>;
|
|
9
|
+
export declare function loadStoreModule(moduleId: string, load: StoreModuleLoad): Promise<void>;
|
|
10
|
+
export declare function unloadStoreModule(moduleId: string): Promise<void>;
|
|
11
|
+
export declare function describeRuntimeModule(moduleId: string): Promise<RuntimeModule | undefined>;
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.isLive = isLive;
|
|
7
|
+
exports.listRuntimeModules = listRuntimeModules;
|
|
8
|
+
exports.loadStoreModule = loadStoreModule;
|
|
9
|
+
exports.unloadStoreModule = unloadStoreModule;
|
|
10
|
+
exports.describeRuntimeModule = describeRuntimeModule;
|
|
11
|
+
const promises_1 = require("node:fs/promises");
|
|
12
|
+
const node_path_1 = __importDefault(require("node:path"));
|
|
13
|
+
const modules_1 = require("@antelopejs/interface-core/modules");
|
|
14
|
+
const PACKAGE_SOURCE_TYPE = "package";
|
|
15
|
+
const PACKAGE_JSON = "package.json";
|
|
16
|
+
const LIVE_STATUSES = new Set(["constructed", "active"]);
|
|
17
|
+
function isLive(module) {
|
|
18
|
+
return module !== undefined && LIVE_STATUSES.has(module.status);
|
|
19
|
+
}
|
|
20
|
+
async function loadedVersion(localPath) {
|
|
21
|
+
try {
|
|
22
|
+
const manifest = JSON.parse(await (0, promises_1.readFile)(node_path_1.default.join(localPath, PACKAGE_JSON), "utf-8"));
|
|
23
|
+
return manifest.version;
|
|
24
|
+
}
|
|
25
|
+
catch {
|
|
26
|
+
return undefined;
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
async function describeModule(moduleId) {
|
|
30
|
+
try {
|
|
31
|
+
const info = await (0, modules_1.GetModuleInfo)(moduleId);
|
|
32
|
+
const source = info.source;
|
|
33
|
+
const isPackage = source.type === PACKAGE_SOURCE_TYPE;
|
|
34
|
+
return {
|
|
35
|
+
id: moduleId,
|
|
36
|
+
packageName: isPackage ? source.package : undefined,
|
|
37
|
+
version: isPackage ? await loadedVersion(info.localPath) : undefined,
|
|
38
|
+
status: info.status,
|
|
39
|
+
localPath: info.localPath,
|
|
40
|
+
};
|
|
41
|
+
}
|
|
42
|
+
catch {
|
|
43
|
+
return undefined;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
async function listRuntimeModules() {
|
|
47
|
+
const described = await Promise.all((await (0, modules_1.ListModules)()).map((moduleId) => describeModule(moduleId)));
|
|
48
|
+
return new Map(described
|
|
49
|
+
.filter((module) => module !== undefined)
|
|
50
|
+
.map((module) => [module.id, module]));
|
|
51
|
+
}
|
|
52
|
+
async function loadStoreModule(moduleId, load) {
|
|
53
|
+
try {
|
|
54
|
+
await (0, modules_1.LoadModule)(moduleId, {
|
|
55
|
+
source: {
|
|
56
|
+
type: PACKAGE_SOURCE_TYPE,
|
|
57
|
+
package: load.package,
|
|
58
|
+
version: load.range,
|
|
59
|
+
},
|
|
60
|
+
config: load.config ?? {},
|
|
61
|
+
}, true);
|
|
62
|
+
}
|
|
63
|
+
catch (error) {
|
|
64
|
+
await unloadStoreModule(moduleId).catch(() => undefined);
|
|
65
|
+
throw error;
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
async function unloadStoreModule(moduleId) {
|
|
69
|
+
const module = await describeModule(moduleId);
|
|
70
|
+
if (!module)
|
|
71
|
+
return;
|
|
72
|
+
await (0, modules_1.StopModule)(moduleId);
|
|
73
|
+
await (0, modules_1.DestroyModule)(moduleId);
|
|
74
|
+
}
|
|
75
|
+
async function describeRuntimeModule(moduleId) {
|
|
76
|
+
return describeModule(moduleId);
|
|
77
|
+
}
|
|
78
|
+
//# sourceMappingURL=runtime.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"runtime.js","sourceRoot":"","sources":["../../src/store/runtime.ts"],"names":[],"mappings":";;;;;AAqCA,wBAEC;AAkCD,gDAWC;AAOD,0CAqBC;AAGD,8CAKC;AAED,sDAIC;AA9HD,+CAA4C;AAC5C,0DAA6B;AAC7B,gEAM4C;AAG5C,MAAM,mBAAmB,GAAG,SAAS,CAAC;AACtC,MAAM,YAAY,GAAG,cAAc,CAAC;AAMpC,MAAM,aAAa,GAAG,IAAI,GAAG,CAAC,CAAC,aAAa,EAAE,QAAQ,CAAC,CAAC,CAAC;AAmBzD,SAAgB,MAAM,CAAC,MAAiC;IACtD,OAAO,MAAM,KAAK,SAAS,IAAI,aAAa,CAAC,GAAG,CAAC,MAAM,CAAC,MAAM,CAAC,CAAC;AAClE,CAAC;AAGD,KAAK,UAAU,aAAa,CAAC,SAAiB;IAC5C,IAAI,CAAC;QACH,MAAM,QAAQ,GAAG,IAAI,CAAC,KAAK,CACzB,MAAM,IAAA,mBAAQ,EAAC,mBAAI,CAAC,IAAI,CAAC,SAAS,EAAE,YAAY,CAAC,EAAE,OAAO,CAAC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EAChB,IAAqB;IAErB,IAAI,CAAC;QACH,MAAM,IAAA,oBAAU,EACd,QAAQ,EACR;YACE,MAAM,EAAE;gBACN,IAAI,EAAE,mBAAmB;gBACzB,OAAO,EAAE,IAAI,CAAC,OAAO;gBACrB,OAAO,EAAE,IAAI,CAAC,KAAK;aACpB;YACD,MAAM,EAAE,IAAI,CAAC,MAAM,IAAI,EAAE;SAC1B,EACD,IAAI,CACL,CAAC;IACJ,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,MAAM,iBAAiB,CAAC,QAAQ,CAAC,CAAC,KAAK,CAAC,GAAG,EAAE,CAAC,SAAS,CAAC,CAAC;QACzD,MAAM,KAAK,CAAC;IACd,CAAC;AACH,CAAC;AAGM,KAAK,UAAU,iBAAiB,CAAC,QAAgB;IACtD,MAAM,MAAM,GAAG,MAAM,cAAc,CAAC,QAAQ,CAAC,CAAC;IAC9C,IAAI,CAAC,MAAM;QAAE,OAAO;IACpB,MAAM,IAAA,oBAAU,EAAC,QAAQ,CAAC,CAAC;IAC3B,MAAM,IAAA,uBAAa,EAAC,QAAQ,CAAC,CAAC;AAChC,CAAC;AAEM,KAAK,UAAU,qBAAqB,CACzC,QAAgB;IAEhB,OAAO,cAAc,CAAC,QAAQ,CAAC,CAAC;AAClC,CAAC"}
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.readTarFile = readTarFile;
|
|
7
|
+
exports.readPublishedFiles = readPublishedFiles;
|
|
8
|
+
const node_child_process_1 = require("node:child_process");
|
|
9
|
+
const promises_1 = require("node:fs/promises");
|
|
10
|
+
const node_os_1 = require("node:os");
|
|
11
|
+
const node_path_1 = __importDefault(require("node:path"));
|
|
12
|
+
const node_util_1 = require("node:util");
|
|
13
|
+
const node_zlib_1 = require("node:zlib");
|
|
14
|
+
const execFileAsync = (0, node_util_1.promisify)(node_child_process_1.execFile);
|
|
15
|
+
const NPM_PACK_TIMEOUT_MS = 60_000;
|
|
16
|
+
const TAR_BLOCK_SIZE = 512;
|
|
17
|
+
const TAR_NAME_LENGTH = 100;
|
|
18
|
+
const TAR_SIZE_OFFSET = 124;
|
|
19
|
+
const TAR_SIZE_LENGTH = 12;
|
|
20
|
+
const TAR_TYPE_OFFSET = 156;
|
|
21
|
+
const TAR_PREFIX_OFFSET = 345;
|
|
22
|
+
const TAR_PREFIX_LENGTH = 155;
|
|
23
|
+
const OCTAL = 8;
|
|
24
|
+
const PACKAGE_ROOT = "package/";
|
|
25
|
+
const TEMP_PREFIX = "dms-store-pack-";
|
|
26
|
+
function readString(block, offset, length) {
|
|
27
|
+
const raw = block.subarray(offset, offset + length);
|
|
28
|
+
const end = raw.indexOf(0);
|
|
29
|
+
return raw.subarray(0, end === -1 ? raw.length : end).toString("utf-8");
|
|
30
|
+
}
|
|
31
|
+
function readHeader(block) {
|
|
32
|
+
const name = readString(block, 0, TAR_NAME_LENGTH);
|
|
33
|
+
if (!name)
|
|
34
|
+
return undefined;
|
|
35
|
+
const prefix = readString(block, TAR_PREFIX_OFFSET, TAR_PREFIX_LENGTH);
|
|
36
|
+
return {
|
|
37
|
+
name: prefix ? `${prefix}/${name}` : name,
|
|
38
|
+
size: Number.parseInt(readString(block, TAR_SIZE_OFFSET, TAR_SIZE_LENGTH).trim(), OCTAL) || 0,
|
|
39
|
+
type: readString(block, TAR_TYPE_OFFSET, 1),
|
|
40
|
+
};
|
|
41
|
+
}
|
|
42
|
+
function readTarFile(archive, filePath) {
|
|
43
|
+
const wanted = `${PACKAGE_ROOT}${filePath}`;
|
|
44
|
+
let offset = 0;
|
|
45
|
+
while (offset + TAR_BLOCK_SIZE <= archive.length) {
|
|
46
|
+
const header = readHeader(archive.subarray(offset, offset + TAR_BLOCK_SIZE));
|
|
47
|
+
if (!header)
|
|
48
|
+
return undefined;
|
|
49
|
+
const start = offset + TAR_BLOCK_SIZE;
|
|
50
|
+
if (header.name === wanted) {
|
|
51
|
+
return archive.subarray(start, start + header.size);
|
|
52
|
+
}
|
|
53
|
+
offset = start + Math.ceil(header.size / TAR_BLOCK_SIZE) * TAR_BLOCK_SIZE;
|
|
54
|
+
}
|
|
55
|
+
return undefined;
|
|
56
|
+
}
|
|
57
|
+
async function packRelease(spec, projectPath, destination) {
|
|
58
|
+
await execFileAsync("npm", ["pack", spec, "--pack-destination", destination, "--silent"], { cwd: projectPath, timeout: NPM_PACK_TIMEOUT_MS });
|
|
59
|
+
const [file] = await (0, promises_1.readdir)(destination);
|
|
60
|
+
if (!file)
|
|
61
|
+
throw new Error(`npm pack ${spec} wrote no archive`);
|
|
62
|
+
return (0, node_zlib_1.gunzipSync)(await (0, promises_1.readFile)(node_path_1.default.join(destination, file)));
|
|
63
|
+
}
|
|
64
|
+
async function readPublishedFiles(packageName, version, projectPath, filePaths) {
|
|
65
|
+
const destination = await (0, promises_1.mkdtemp)(node_path_1.default.join((0, node_os_1.tmpdir)(), TEMP_PREFIX));
|
|
66
|
+
try {
|
|
67
|
+
const archive = await packRelease(`${packageName}@${version}`, projectPath, destination);
|
|
68
|
+
const files = new Map();
|
|
69
|
+
for (const filePath of filePaths) {
|
|
70
|
+
const content = readTarFile(archive, filePath);
|
|
71
|
+
if (content)
|
|
72
|
+
files.set(filePath, content.toString("utf-8"));
|
|
73
|
+
}
|
|
74
|
+
return files;
|
|
75
|
+
}
|
|
76
|
+
finally {
|
|
77
|
+
await (0, promises_1.rm)(destination, { recursive: true, force: true });
|
|
78
|
+
}
|
|
79
|
+
}
|
|
80
|
+
//# sourceMappingURL=tarball.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tarball.js","sourceRoot":"","sources":["../../src/store/tarball.ts"],"names":[],"mappings":";;;;;AAsDA,kCAkBC;AAqBD,gDAsBC;AAnHD,2DAA8C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
package: string;
|
|
4
|
+
icon: string;
|
|
5
|
+
category: string;
|
|
6
|
+
}
|
|
7
|
+
export interface StoreCatalog {
|
|
8
|
+
version: number;
|
|
9
|
+
modules: StoreCatalogEntry[];
|
|
10
|
+
}
|
|
11
|
+
export interface StoreDeclaration {
|
|
12
|
+
key: string;
|
|
13
|
+
package: string;
|
|
14
|
+
range: string;
|
|
15
|
+
disabled: boolean;
|
|
16
|
+
config?: unknown;
|
|
17
|
+
}
|
|
18
|
+
export interface PackageRelease {
|
|
19
|
+
version: string;
|
|
20
|
+
interfaceRange?: string;
|
|
21
|
+
dependencies?: Record<string, string>;
|
|
22
|
+
implements?: string[];
|
|
23
|
+
}
|
|
24
|
+
export interface RuntimeModule {
|
|
25
|
+
id: string;
|
|
26
|
+
packageName?: string;
|
|
27
|
+
version?: string;
|
|
28
|
+
status: string;
|
|
29
|
+
localPath: string;
|
|
30
|
+
}
|
|
31
|
+
export type StoreOperationKind = "install" | "update" | "enable" | "disable" | "uninstall" | "apply";
|
|
32
|
+
export type StoreOperationStep = "resolve" | "dependencies" | "unload" | "load" | "save";
|
|
33
|
+
export interface StoreOperation {
|
|
34
|
+
moduleId: string;
|
|
35
|
+
kind: StoreOperationKind;
|
|
36
|
+
step: StoreOperationStep;
|
|
37
|
+
targetVersion?: string;
|
|
38
|
+
startedAt: number;
|
|
39
|
+
}
|
|
40
|
+
export type StoreModuleState = "available" | "busy" | "active" | "disabled" | "error" | "pending";
|
|
41
|
+
export type StoreFrontendState = "none" | "synced" | "pending" | "unknown";
|
|
42
|
+
export interface InterfaceImplementation {
|
|
43
|
+
name: string;
|
|
44
|
+
package: string;
|
|
45
|
+
}
|
|
46
|
+
export interface MissingInterface {
|
|
47
|
+
interfacePackage: string;
|
|
48
|
+
candidates: InterfaceImplementation[];
|
|
49
|
+
}
|
|
50
|
+
export interface FrontendBreak {
|
|
51
|
+
name: string;
|
|
52
|
+
range: string;
|
|
53
|
+
}
|
|
54
|
+
export interface FrontendRequirement {
|
|
55
|
+
range: string;
|
|
56
|
+
running: string;
|
|
57
|
+
target?: string;
|
|
58
|
+
command?: string;
|
|
59
|
+
breaks: FrontendBreak[];
|
|
60
|
+
}
|
|
61
|
+
export type FrontendVersionSource = "reported" | "project";
|
|
62
|
+
export interface StoreListingEntry {
|
|
63
|
+
id: string;
|
|
64
|
+
package: string;
|
|
65
|
+
icon: string;
|
|
66
|
+
category: string;
|
|
67
|
+
title: string;
|
|
68
|
+
description: string;
|
|
69
|
+
state: StoreModuleState;
|
|
70
|
+
installedVersion?: string;
|
|
71
|
+
declaredRange?: string;
|
|
72
|
+
latestVersion?: string;
|
|
73
|
+
updateAvailable: boolean;
|
|
74
|
+
compatible: boolean;
|
|
75
|
+
requiredInterfaceRange?: string;
|
|
76
|
+
error?: string;
|
|
77
|
+
operation?: StoreOperation;
|
|
78
|
+
frontend: StoreFrontendState;
|
|
79
|
+
frontendRange?: string;
|
|
80
|
+
frontendRequirement?: FrontendRequirement;
|
|
81
|
+
missingInterfaces: MissingInterface[];
|
|
82
|
+
dependents: string[];
|
|
83
|
+
}
|
|
84
|
+
export interface StoreListing {
|
|
85
|
+
enabled: boolean;
|
|
86
|
+
modules: StoreListingEntry[];
|
|
87
|
+
busy: boolean;
|
|
88
|
+
interfaceVersion: string;
|
|
89
|
+
dev: boolean;
|
|
90
|
+
configError?: string;
|
|
91
|
+
frontendVersion?: string;
|
|
92
|
+
frontendVersionSource?: FrontendVersionSource;
|
|
93
|
+
}
|
|
94
|
+
export interface StoreDependencyChoice {
|
|
95
|
+
interfacePackage: string;
|
|
96
|
+
package: string;
|
|
97
|
+
config?: Record<string, unknown>;
|
|
98
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/store/types.ts"],"names":[],"mappings":""}
|
|
@@ -47,7 +47,7 @@ describe("[integration] account deletion", () => {
|
|
|
47
47
|
const jobId = `deleted-${Date.now()}`;
|
|
48
48
|
const resourceKey = await storedExport(member.userId, jobId);
|
|
49
49
|
(0, chai_1.expect)(await (0, interface_file_storage_1.FileExists)(resourceKey)).to.equal(true);
|
|
50
|
-
const response = await (0, auth_1.authorizedClient)(member.accessToken).post("/settings/user/profile/account-deletion", { password: member.password, confirmation: member.email });
|
|
50
|
+
const response = await (0, auth_1.authorizedClient)(member.accessToken).post("/dms/pages/settings/user/profile/account-deletion", { password: member.password, confirmation: member.email });
|
|
51
51
|
(0, chai_1.expect)(response.status, JSON.stringify(response.data)).to.equal(HTTP_OK);
|
|
52
52
|
const exports = (0, interface_database_decorators_1.GetModel)(exportJobs_model_1.ExportJobModel, constants_1.DEFAULT_TENANT_ID);
|
|
53
53
|
(0, chai_1.expect)(await exports.get(jobId)).to.equal(undefined);
|
|
@@ -66,7 +66,7 @@ describe("[integration] account deletion", () => {
|
|
|
66
66
|
(0, chai_1.expect)(await attempts.listBurst(member.userId, epoch, 10)).to.have.length(2);
|
|
67
67
|
(0, chai_1.expect)(await (0, interface_database_decorators_1.GetModel)(db_1.SessionModel).getByUserId(member.userId)).to.not.be
|
|
68
68
|
.empty;
|
|
69
|
-
const response = await (0, auth_1.authorizedClient)(accessToken).post("/settings/user/profile/account-deletion", { password: member.password, confirmation: member.email });
|
|
69
|
+
const response = await (0, auth_1.authorizedClient)(accessToken).post("/dms/pages/settings/user/profile/account-deletion", { password: member.password, confirmation: member.email });
|
|
70
70
|
(0, chai_1.expect)(response.status, JSON.stringify(response.data)).to.equal(HTTP_OK);
|
|
71
71
|
(0, chai_1.expect)(await devices.listFingerprints(member.userId)).to.deep.equal([]);
|
|
72
72
|
(0, chai_1.expect)(await attempts.listBurst(member.userId, epoch, 10)).to.deep.equal([]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"account-deletion.test.js","sourceRoot":"","sources":["../../../src/test/integration/account-deletion.test.ts"],"names":[],"mappings":";;AAAA,+CAA6C;AAC7C,qCAAiC;AACjC,yCAAiC;AACjC,6DAAuD;AACvD,6FAAqE;AAC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E;QACrE,MAAM,IAAA,mBAAY,EAAC,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC,CAAC;QACpC,MAAM,MAAM,GAAG,MAAM,IAAA,mBAAY,GAAE,CAAC;QACpC,MAAM,KAAK,GAAG,WAAW,IAAI,CAAC,GAAG,EAAE,EAAE,CAAC;QACtC,MAAM,WAAW,GAAG,MAAM,YAAY,CAAC,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC;QAC7D,IAAA,aAAM,EAAC,MAAM,IAAA,mCAAU,EAAC,WAAW,CAAC,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC;QAErD,MAAM,QAAQ,GAAG,MAAM,IAAA,uBAAgB,EAAC,MAAM,CAAC,WAAW,CAAC,CAAC,IAAI,CAC9D,
|
|
1
|
+
{"version":3,"file":"account-deletion.test.js","sourceRoot":"","sources":["../../../src/test/integration/account-deletion.test.ts"],"names":[],"mappings":";;AAAA,+CAA6C;AAC7C,qCAAiC;AACjC,yCAAiC;AACjC,6DAAuD;AACvD,6FAAqE;AACrE,0DAA4E;AAC5E,mEAAwE;AACxE,6FAAwF;AACxF,+EAAgE;AAChE,+BAA8B;AAC9B,+EAA2E;AAC3E,mFAA+E;AAC/E,sFAA8E;AAC9E,yDAAgE;AAChE,0CAA4E;AAC5E,sCAA8C;AAK9C,MAAM,OAAO,GAAG,GAAG,CAAC;AACpB,MAAM,aAAa,GAAG,GAAG,CAAC;AAC1B,MAAM,gBAAgB,GAAG,KAAK,CAAC;AAC/B,MAAM,mBAAmB,GAAG,UAAU,CAAC;AAEvC,KAAK,UAAU,YAAY,CAAC,MAAc,EAAE,KAAa;IACvD,MAAM,SAAS,GAAG,IAAA,gBAAI,EAAC,IAAA,gBAAM,GAAE,EAAE,GAAG,KAAK,IAAI,gBAAgB,EAAE,CAAC,CAAC;IACjE,MAAM,IAAA,oBAAS,EAAC,SAAS,EAAE,YAAY,CAAC,CAAC;IACzC,MAAM,WAAW,GAAG,MAAM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,CAAC,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC,CAAC;IACtB,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,8CAA8C,EAAE,KAAK,IAAI,EAAE;QAC5D,MAAM,KAAK,GAAG,MAAM,IAAA,mBAAY,EAAC,EAAE,KAAK,EAAE,IAAI,EAAE,CAAC,CAAC;QAClD,MAAM,IAAI,GAAG,MAAM,IAAA,wCAAQ,EAAC,cAAS,CAAC,CAAC,GAAG,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC;QACzD,MAAM,OAAO,GAAG,MAAM,IAAA,kCAAa,EAAC,IAAK,CAAC,CAAC,IAAI,CAC7C,GAAG,EAAE,CAAC,SAAS,EACf,CAAC,KAAc,EAAE,EAAE,CAAC,KAAK,CAC1B,CAAC;QACF,IAAA,aAAM,EAAC,OAAO,CAAC,CAAC,EAAE,CAAC,EAAE,CAAC,UAAU,CAAC,0BAAU,CAAC,CAAC;QAC7C,IAAA,aAAM,EAAE,OAAsB,CAAC,SAAS,EAAE,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,aAAa,CAAC,CAAC;QACpE,IAAA,aAAM,EAAC,MAAM,IAAA,wCAAQ,EAAC,cAAS,CAAC,CAAC,GAAG,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,GAAG,CAAC,KAAK,CAAC,SAAS,CAAC,CAAC;IAC9E,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
|
|
@@ -7,7 +7,8 @@ const jsonwebtoken_1 = require("jsonwebtoken");
|
|
|
7
7
|
const auth_1 = require("../../helpers/auth");
|
|
8
8
|
const db_2 = require("../../helpers/db");
|
|
9
9
|
const http_1 = require("../../helpers/http");
|
|
10
|
-
const
|
|
10
|
+
const page_1 = require("@antelopejs/interface-dms/page");
|
|
11
|
+
const SECURITY = (0, page_1.pageRoutePath)("/settings/user/security");
|
|
11
12
|
const NEW_PASSWORD = "Rotated26!";
|
|
12
13
|
const HTTP_OK = 200;
|
|
13
14
|
const HTTP_UNAUTHORIZED = 401;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"auth-key-rotation.test.js","sourceRoot":"","sources":["../../../../src/test/integration/auth/auth-key-rotation.test.ts"],"names":[],"mappings":";;AAAA,6FAAqE;AACrE,0DAAiE;AAEjE,+BAA8B;AAC9B,+CAAsC;AACtC,6CAK4B;AAC5B,yCAAiD;AACjD,6CAAkD;
|
|
1
|
+
{"version":3,"file":"auth-key-rotation.test.js","sourceRoot":"","sources":["../../../../src/test/integration/auth/auth-key-rotation.test.ts"],"names":[],"mappings":";;AAAA,6FAAqE;AACrE,0DAAiE;AAEjE,+BAA8B;AAC9B,+CAAsC;AACtC,6CAK4B;AAC5B,yCAAiD;AACjD,6CAAkD;AAClD,yDAA+D;AAM/D,MAAM,QAAQ,GAAG,IAAA,oBAAa,EAAC,yBAAyB,CAAC,CAAC;AAC1D,MAAM,YAAY,GAAG,YAAY,CAAC;AAClC,MAAM,OAAO,GAAG,GAAG,CAAC;AACpB,MAAM,iBAAiB,GAAG,GAAG,CAAC;AAC9B,MAAM,aAAa,GAAG,MAAM,CAAC;AAoB7B,KAAK,UAAU,QAAQ,CAAC,WAAmB;IACzC,OAAO,CAAC,MAAM,IAAA,uBAAgB,EAAC,WAAW,CAAC,CAAC,GAAG,CAAC,cAAc,CAAC,CAAC,CAAC,MAAM,CAAC;AAC1E,CAAC;AAED,KAAK,UAAU,aAAa,CAAC,YAAoB;IAC/C,MAAM,QAAQ,GAAG,MAAM,IAAA,mBAAY,GAAE,CAAC,IAAI,CAAC,mBAAmB,EAAE;QAC9D,KAAK,EAAE,YAAY;KACpB,CAAC,CAAC;IACH,OAAO,QAAQ,CAAC,MAAM,CAAC;AACzB,CAAC;AAED,KAAK,UAAU,MAAM,CAAC,OAAuB;IAC3C,OAAO,IAAA,mBAAY,GAAE,CAAC,IAAI,CAAC,OAAO,CAAC,QAAQ,EAAE,OAAO,CAAC,OAAO,CAAC,CAAC;A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AAC;QACH,IAAA,aAAM,EAAC,CAAC,MAAM,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,iBAAiB,CAAC,CAAC;IACrE,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
|
|
@@ -4,7 +4,8 @@ const chai_1 = require("chai");
|
|
|
4
4
|
const auth_1 = require("../../helpers/auth");
|
|
5
5
|
const db_1 = require("../../helpers/db");
|
|
6
6
|
const emails_1 = require("../../helpers/emails");
|
|
7
|
-
const
|
|
7
|
+
const page_1 = require("@antelopejs/interface-dms/page");
|
|
8
|
+
const SECURITY = (0, page_1.pageRoutePath)("/settings/user/security");
|
|
8
9
|
const HTTP_OK = 200;
|
|
9
10
|
const HTTP_BAD_REQUEST = 400;
|
|
10
11
|
const HTTP_TOO_MANY_REQUESTS = 429;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"current-password.test.js","sourceRoot":"","sources":["../../../../src/test/integration/auth/current-password.test.ts"],"names":[],"mappings":";;AACA,+BAA8B;AAC9B,6CAI4B;AAC5B,yCAAiD;AACjD,iDAAqD;
|
|
1
|
+
{"version":3,"file":"current-password.test.js","sourceRoot":"","sources":["../../../../src/test/integration/auth/current-password.test.ts"],"names":[],"mappings":";;AACA,+BAA8B;AAC9B,6CAI4B;AAC5B,yCAAiD;AACjD,iDAAqD;AACrD,yDAA+D;AAM/D,MAAM,QAAQ,GAAG,IAAA,oBAAa,EAAC,yBAAyB,CAAC,CAAC;AAC1D,MAAM,OAAO,GAAG,GAAG,CAAC;AACpB,MAAM,gBAAgB,GAAG,GAAG,CAAC;AAC7B,MAAM,sBAAsB,GAAG,GAAG,CAAC;AACnC,MAAM,mBAAmB,GAAG,EAAE,CAAC;AAC/B,MAAM,cAAc,GAAG,oBAAoB,CAAC;AAC5C,MAAM,YAAY,GAAG,aAAa,CAAC;AACnC,MAAM,wBAAwB,GAAG,gCAAgC,CAAC;AAClE,MAA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AAE,OAAO,EAAE,EAAE,CAAC;YAC/D,YAAY,CACV,MAAM,cAAc,CAAC,cAAc,CAAC,EACpC,gBAAgB,EAChB,wBAAwB,CACzB,CAAC;QACJ,CAAC;IACH,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,iFAAiF,EAAE,KAAK,IAAI,EAAE;QAC/F,MAAM,KAAK,GAAG,MAAM,WAAW,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;QAC/C,IAAA,aAAM,EAAC,KAAK,CAAC,MAAM,EAAE,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;QACnE,YAAY,CACV,MAAM,WAAW,CAAC,cAAc,CAAC,EACjC,sBAAsB,EACtB,kBAAkB,CACnB,CAAC;IACJ,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
|
|
@@ -3,7 +3,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
const chai_1 = require("chai");
|
|
4
4
|
const auth_1 = require("../../helpers/auth");
|
|
5
5
|
const db_1 = require("../../helpers/db");
|
|
6
|
-
const
|
|
6
|
+
const page_1 = require("@antelopejs/interface-dms/page");
|
|
7
|
+
const SESSIONS_URL = (0, page_1.pageRoutePath)("/settings/user/security", "/sessions");
|
|
7
8
|
const LOGOUT_URL = "/api/auth/logout";
|
|
8
9
|
const ME_URL = "/api/auth/me";
|
|
9
10
|
const HTTP_OK = 200;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"session-revocation.test.js","sourceRoot":"","sources":["../../../../src/test/integration/auth/session-revocation.test.ts"],"names":[],"mappings":";;AAAA,+BAA8B;AAC9B,6CAK4B;AAC5B,yCAAiD;
|
|
1
|
+
{"version":3,"file":"session-revocation.test.js","sourceRoot":"","sources":["../../../../src/test/integration/auth/session-revocation.test.ts"],"names":[],"mappings":";;AAAA,+BAA8B;AAC9B,6CAK4B;AAC5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,WAAW,CAAC,WAAW,CAAC,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,iBAAiB,CAAC,CAAC;QAC5E,IAAA,aAAM,EAAC,MAAM,QAAQ,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC,CAAC,EAAE,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;IAC7D,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
|
|
@@ -6,6 +6,7 @@ const sign_in_country_1 = require("../../../utils/sign-in-country");
|
|
|
6
6
|
const auth_1 = require("../../helpers/auth");
|
|
7
7
|
const db_1 = require("../../helpers/db");
|
|
8
8
|
const http_1 = require("../../helpers/http");
|
|
9
|
+
const page_1 = require("@antelopejs/interface-dms/page");
|
|
9
10
|
const COUNTRY_HEADER = "CF-IPCountry";
|
|
10
11
|
const CHROME_ON_WINDOWS = "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/140.0.0.0 Safari/537.36";
|
|
11
12
|
const NEW_LOGIN_TITLE = "$dms.notifications.messages.new_login.title_browser_os";
|
|
@@ -28,7 +29,7 @@ describe("[integration] auth/sign-in country", () => {
|
|
|
28
29
|
(0, chai_1.expect)(response.status, JSON.stringify(response.data)).to.equal(HTTP_OK);
|
|
29
30
|
};
|
|
30
31
|
const newSignInNotices = async () => {
|
|
31
|
-
const response = await owner.get("/settings/user/notifications/list");
|
|
32
|
+
const response = await owner.get((0, page_1.pageRoutePath)("/settings/user/notifications", "/list"));
|
|
32
33
|
(0, chai_1.expect)(response.status).to.equal(HTTP_OK);
|
|
33
34
|
return response.data.filter((notification) => notification.title === NEW_LOGIN_TITLE);
|
|
34
35
|
};
|