@alepha/ui 0.25.2 → 0.26.0
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/LICENSE +21 -0
- package/README.md +136 -2
- package/dist/components/account/account-connections.d.ts +16 -0
- package/dist/components/account/account-connections.d.ts.map +1 -0
- package/dist/components/account/account-connections.js +76 -0
- package/dist/components/account/account-connections.js.map +1 -0
- package/dist/components/account/account-delete-dialog.d.ts +44 -0
- package/dist/components/account/account-delete-dialog.d.ts.map +1 -0
- package/dist/components/account/account-delete-dialog.js +126 -0
- package/dist/components/account/account-delete-dialog.js.map +1 -0
- package/dist/components/account/account-header.d.ts +33 -0
- package/dist/components/account/account-header.d.ts.map +1 -0
- package/dist/components/account/account-header.js +41 -0
- package/dist/components/account/account-header.js.map +1 -0
- package/dist/components/account/account-keys.d.ts +23 -0
- package/dist/components/account/account-keys.d.ts.map +1 -0
- package/dist/components/account/account-keys.js +168 -0
- package/dist/components/account/account-keys.js.map +1 -0
- package/dist/components/account/account-layout.d.ts +32 -0
- package/dist/components/account/account-layout.d.ts.map +1 -0
- package/dist/components/account/account-layout.js +53 -0
- package/dist/components/account/account-layout.js.map +1 -0
- package/dist/components/account/account-password-dialog.d.ts +31 -0
- package/dist/components/account/account-password-dialog.d.ts.map +1 -0
- package/dist/components/account/account-password-dialog.js +120 -0
- package/dist/components/account/account-password-dialog.js.map +1 -0
- package/dist/components/account/account-profile.d.ts +27 -0
- package/dist/components/account/account-profile.d.ts.map +1 -0
- package/dist/components/account/account-profile.js +217 -0
- package/dist/components/account/account-profile.js.map +1 -0
- package/dist/components/account/account-router-options.d.ts +77 -0
- package/dist/components/account/account-router-options.d.ts.map +1 -0
- package/dist/components/account/account-router-options.js +22 -0
- package/dist/components/account/account-router-options.js.map +1 -0
- package/dist/components/account/account-router-page.d.ts +49 -0
- package/dist/components/account/account-router-page.d.ts.map +1 -0
- package/dist/components/account/account-router-page.js +61 -0
- package/dist/components/account/account-router-page.js.map +1 -0
- package/dist/components/account/account-router.d.ts +214 -0
- package/dist/components/account/account-router.d.ts.map +1 -0
- package/dist/components/account/account-router.js +216 -0
- package/dist/components/account/account-router.js.map +1 -0
- package/dist/components/account/account-security.d.ts +22 -0
- package/dist/components/account/account-security.d.ts.map +1 -0
- package/dist/components/account/account-security.js +107 -0
- package/dist/components/account/account-security.js.map +1 -0
- package/dist/components/account/account-sessions.d.ts +17 -0
- package/dist/components/account/account-sessions.d.ts.map +1 -0
- package/dist/components/account/account-sessions.js +108 -0
- package/dist/components/account/account-sessions.js.map +1 -0
- package/dist/components/action-error-toaster/action-error-toaster.d.ts +39 -0
- package/dist/components/action-error-toaster/action-error-toaster.d.ts.map +1 -0
- package/dist/components/action-error-toaster/action-error-toaster.js +40 -0
- package/dist/components/action-error-toaster/action-error-toaster.js.map +1 -0
- package/dist/components/admin/admin-analytics-query-panel.d.ts +16 -0
- package/dist/components/admin/admin-analytics-query-panel.d.ts.map +1 -0
- package/dist/components/admin/admin-analytics-query-panel.js +117 -0
- package/dist/components/admin/admin-analytics-query-panel.js.map +1 -0
- package/dist/components/admin/admin-analytics-results.d.ts +15 -0
- package/dist/components/admin/admin-analytics-results.d.ts.map +1 -0
- package/dist/components/admin/admin-analytics-results.js +56 -0
- package/dist/components/admin/admin-analytics-results.js.map +1 -0
- package/dist/components/admin/admin-analytics.d.ts +9 -0
- package/dist/components/admin/admin-analytics.d.ts.map +1 -0
- package/dist/components/admin/admin-analytics.js +66 -0
- package/dist/components/admin/admin-analytics.js.map +1 -0
- package/dist/components/admin/admin-audits.d.ts +4 -0
- package/dist/components/admin/admin-audits.d.ts.map +1 -0
- package/dist/components/admin/admin-audits.js +173 -0
- package/dist/components/admin/admin-audits.js.map +1 -0
- package/dist/components/admin/admin-files.d.ts +4 -0
- package/dist/components/admin/admin-files.d.ts.map +1 -0
- package/dist/components/admin/admin-files.js +237 -0
- package/dist/components/admin/admin-files.js.map +1 -0
- package/dist/components/admin/admin-jobs-executions-panel.d.ts +11 -0
- package/dist/components/admin/admin-jobs-executions-panel.d.ts.map +1 -0
- package/dist/components/admin/admin-jobs-executions-panel.js +200 -0
- package/dist/components/admin/admin-jobs-executions-panel.js.map +1 -0
- package/dist/components/admin/admin-jobs-status-badge.d.ts +9 -0
- package/dist/components/admin/admin-jobs-status-badge.d.ts.map +1 -0
- package/dist/components/admin/admin-jobs-status-badge.js +26 -0
- package/dist/components/admin/admin-jobs-status-badge.js.map +1 -0
- package/dist/components/admin/admin-jobs.d.ts +4 -0
- package/dist/components/admin/admin-jobs.d.ts.map +1 -0
- package/dist/components/admin/admin-jobs.js +248 -0
- package/dist/components/admin/admin-jobs.js.map +1 -0
- package/dist/components/admin/admin-keys-token-dialog.d.ts +15 -0
- package/dist/components/admin/admin-keys-token-dialog.d.ts.map +1 -0
- package/dist/components/admin/admin-keys-token-dialog.js +66 -0
- package/dist/components/admin/admin-keys-token-dialog.js.map +1 -0
- package/dist/components/admin/admin-keys.d.ts +4 -0
- package/dist/components/admin/admin-keys.d.ts.map +1 -0
- package/dist/components/admin/admin-keys.js +161 -0
- package/dist/components/admin/admin-keys.js.map +1 -0
- package/dist/components/admin/admin-layout.d.ts +33 -0
- package/dist/components/admin/admin-layout.d.ts.map +1 -0
- package/dist/components/admin/admin-layout.js +101 -0
- package/dist/components/admin/admin-layout.js.map +1 -0
- package/dist/components/admin/admin-notifications.d.ts +4 -0
- package/dist/components/admin/admin-notifications.d.ts.map +1 -0
- package/dist/components/admin/admin-notifications.js +99 -0
- package/dist/components/admin/admin-notifications.js.map +1 -0
- package/dist/components/admin/admin-page.d.ts +16 -0
- package/dist/components/admin/admin-page.d.ts.map +1 -0
- package/dist/components/admin/admin-page.js +15 -0
- package/dist/components/admin/admin-page.js.map +1 -0
- package/dist/components/admin/admin-parameters.d.ts +26 -0
- package/dist/components/admin/admin-parameters.d.ts.map +1 -0
- package/dist/components/admin/admin-parameters.js +560 -0
- package/dist/components/admin/admin-parameters.js.map +1 -0
- package/dist/components/admin/admin-payments.d.ts +4 -0
- package/dist/components/admin/admin-payments.d.ts.map +1 -0
- package/dist/components/admin/admin-payments.js +72 -0
- package/dist/components/admin/admin-payments.js.map +1 -0
- package/dist/components/admin/admin-router-options.d.ts +135 -0
- package/dist/components/admin/admin-router-options.d.ts.map +1 -0
- package/dist/components/admin/admin-router-options.js +29 -0
- package/dist/components/admin/admin-router-options.js.map +1 -0
- package/dist/components/admin/admin-router-page.d.ts +54 -0
- package/dist/components/admin/admin-router-page.d.ts.map +1 -0
- package/dist/components/admin/admin-router-page.js +66 -0
- package/dist/components/admin/admin-router-page.js.map +1 -0
- package/dist/components/admin/admin-router.d.ts +169 -0
- package/dist/components/admin/admin-router.d.ts.map +1 -0
- package/dist/components/admin/admin-router.js +346 -0
- package/dist/components/admin/admin-router.js.map +1 -0
- package/dist/components/admin/admin-sessions.d.ts +4 -0
- package/dist/components/admin/admin-sessions.d.ts.map +1 -0
- package/dist/components/admin/admin-sessions.js +124 -0
- package/dist/components/admin/admin-sessions.js.map +1 -0
- package/dist/components/admin/admin-user-cell.d.ts +37 -0
- package/dist/components/admin/admin-user-cell.d.ts.map +1 -0
- package/dist/components/admin/admin-user-cell.js +35 -0
- package/dist/components/admin/admin-user-cell.js.map +1 -0
- package/dist/components/admin/admin-user-detail-audits-tab.d.ts +15 -0
- package/dist/components/admin/admin-user-detail-audits-tab.d.ts.map +1 -0
- package/dist/components/admin/admin-user-detail-audits-tab.js +55 -0
- package/dist/components/admin/admin-user-detail-audits-tab.js.map +1 -0
- package/dist/components/admin/admin-user-detail-identity-aside.d.ts +14 -0
- package/dist/components/admin/admin-user-detail-identity-aside.d.ts.map +1 -0
- package/dist/components/admin/admin-user-detail-identity-aside.js +162 -0
- package/dist/components/admin/admin-user-detail-identity-aside.js.map +1 -0
- package/dist/components/admin/admin-user-detail-overview-tab.d.ts +26 -0
- package/dist/components/admin/admin-user-detail-overview-tab.d.ts.map +1 -0
- package/dist/components/admin/admin-user-detail-overview-tab.js +60 -0
- package/dist/components/admin/admin-user-detail-overview-tab.js.map +1 -0
- package/dist/components/admin/admin-user-detail-password-dialog.d.ts +15 -0
- package/dist/components/admin/admin-user-detail-password-dialog.d.ts.map +1 -0
- package/dist/components/admin/admin-user-detail-password-dialog.js +47 -0
- package/dist/components/admin/admin-user-detail-password-dialog.js.map +1 -0
- package/dist/components/admin/admin-user-detail-password-schema.d.ts +10 -0
- package/dist/components/admin/admin-user-detail-password-schema.d.ts.map +1 -0
- package/dist/components/admin/admin-user-detail-password-schema.js +13 -0
- package/dist/components/admin/admin-user-detail-password-schema.js.map +1 -0
- package/dist/components/admin/admin-user-detail-profile-policy.d.ts +56 -0
- package/dist/components/admin/admin-user-detail-profile-policy.d.ts.map +1 -0
- package/dist/components/admin/admin-user-detail-profile-policy.js +73 -0
- package/dist/components/admin/admin-user-detail-profile-policy.js.map +1 -0
- package/dist/components/admin/admin-user-detail-profile-schema.d.ts +18 -0
- package/dist/components/admin/admin-user-detail-profile-schema.d.ts.map +1 -0
- package/dist/components/admin/admin-user-detail-profile-schema.js +21 -0
- package/dist/components/admin/admin-user-detail-profile-schema.js.map +1 -0
- package/dist/components/admin/admin-user-detail-security-tab.d.ts +20 -0
- package/dist/components/admin/admin-user-detail-security-tab.d.ts.map +1 -0
- package/dist/components/admin/admin-user-detail-security-tab.js +70 -0
- package/dist/components/admin/admin-user-detail-security-tab.js.map +1 -0
- package/dist/components/admin/admin-user-detail-sessions-tab.d.ts +25 -0
- package/dist/components/admin/admin-user-detail-sessions-tab.d.ts.map +1 -0
- package/dist/components/admin/admin-user-detail-sessions-tab.js +64 -0
- package/dist/components/admin/admin-user-detail-sessions-tab.js.map +1 -0
- package/dist/components/admin/admin-user-detail.d.ts +39 -0
- package/dist/components/admin/admin-user-detail.d.ts.map +1 -0
- package/dist/components/admin/admin-user-detail.js +386 -0
- package/dist/components/admin/admin-user-detail.js.map +1 -0
- package/dist/components/admin/admin-users-roles-picker.d.ts +23 -0
- package/dist/components/admin/admin-users-roles-picker.d.ts.map +1 -0
- package/dist/components/admin/admin-users-roles-picker.js +77 -0
- package/dist/components/admin/admin-users-roles-picker.js.map +1 -0
- package/dist/components/admin/admin-users-status-filter.d.ts +13 -0
- package/dist/components/admin/admin-users-status-filter.d.ts.map +1 -0
- package/dist/components/admin/admin-users-status-filter.js +41 -0
- package/dist/components/admin/admin-users-status-filter.js.map +1 -0
- package/dist/components/admin/admin-users.d.ts +16 -0
- package/dist/components/admin/admin-users.d.ts.map +1 -0
- package/dist/components/admin/admin-users.js +325 -0
- package/dist/components/admin/admin-users.js.map +1 -0
- package/dist/components/admin/admin-workflows-execution-sheet.d.ts +11 -0
- package/dist/components/admin/admin-workflows-execution-sheet.d.ts.map +1 -0
- package/dist/components/admin/admin-workflows-execution-sheet.js +190 -0
- package/dist/components/admin/admin-workflows-execution-sheet.js.map +1 -0
- package/dist/components/admin/admin-workflows-executions-panel.d.ts +9 -0
- package/dist/components/admin/admin-workflows-executions-panel.d.ts.map +1 -0
- package/dist/components/admin/admin-workflows-executions-panel.js +153 -0
- package/dist/components/admin/admin-workflows-executions-panel.js.map +1 -0
- package/dist/components/admin/admin-workflows-status-badge.d.ts +12 -0
- package/dist/components/admin/admin-workflows-status-badge.d.ts.map +1 -0
- package/dist/components/admin/admin-workflows-status-badge.js +30 -0
- package/dist/components/admin/admin-workflows-status-badge.js.map +1 -0
- package/dist/components/admin/admin-workflows.d.ts +4 -0
- package/dist/components/admin/admin-workflows.d.ts.map +1 -0
- package/dist/components/admin/admin-workflows.js +145 -0
- package/dist/components/admin/admin-workflows.js.map +1 -0
- package/dist/components/admin/diff-lines.d.ts +13 -0
- package/dist/components/admin/diff-lines.d.ts.map +1 -0
- package/dist/components/admin/diff-lines.js +57 -0
- package/dist/components/admin/diff-lines.js.map +1 -0
- package/dist/components/admin/parameter-diff-dialog.d.ts +36 -0
- package/dist/components/admin/parameter-diff-dialog.d.ts.map +1 -0
- package/dist/components/admin/parameter-diff-dialog.js +58 -0
- package/dist/components/admin/parameter-diff-dialog.js.map +1 -0
- package/dist/components/admin/parameter-history-item.d.ts +17 -0
- package/dist/components/admin/parameter-history-item.d.ts.map +1 -0
- package/dist/components/admin/parameter-history-item.js +177 -0
- package/dist/components/admin/parameter-history-item.js.map +1 -0
- package/dist/components/admin/parameter-json-dialog.d.ts +13 -0
- package/dist/components/admin/parameter-json-dialog.d.ts.map +1 -0
- package/dist/components/admin/parameter-json-dialog.js +63 -0
- package/dist/components/admin/parameter-json-dialog.js.map +1 -0
- package/dist/components/admin/parameter-save-dialog.d.ts +26 -0
- package/dist/components/admin/parameter-save-dialog.d.ts.map +1 -0
- package/dist/components/admin/parameter-save-dialog.js +74 -0
- package/dist/components/admin/parameter-save-dialog.js.map +1 -0
- package/dist/components/admin/use-confirmed-action.d.ts +53 -0
- package/dist/components/admin/use-confirmed-action.d.ts.map +1 -0
- package/dist/components/admin/use-confirmed-action.js +50 -0
- package/dist/components/admin/use-confirmed-action.js.map +1 -0
- package/dist/components/alepha-table/alepha-table.d.ts +218 -0
- package/dist/components/alepha-table/alepha-table.d.ts.map +1 -0
- package/dist/components/alepha-table/alepha-table.js +565 -0
- package/dist/components/alepha-table/alepha-table.js.map +1 -0
- package/dist/components/alepha-table/use-table-selection.d.ts +34 -0
- package/dist/components/alepha-table/use-table-selection.d.ts.map +1 -0
- package/dist/components/alepha-table/use-table-selection.js +45 -0
- package/dist/components/alepha-table/use-table-selection.js.map +1 -0
- package/dist/components/app-actions/app-actions.d.ts +74 -0
- package/dist/components/app-actions/app-actions.d.ts.map +1 -0
- package/dist/components/app-actions/app-actions.js +77 -0
- package/dist/components/app-actions/app-actions.js.map +1 -0
- package/dist/components/app-shell/app-shell.d.ts +135 -0
- package/dist/components/app-shell/app-shell.d.ts.map +1 -0
- package/dist/components/app-shell/app-shell.js +276 -0
- package/dist/components/app-shell/app-shell.js.map +1 -0
- package/dist/components/auth/auth-login.d.ts +40 -0
- package/dist/components/auth/auth-login.d.ts.map +1 -0
- package/dist/components/auth/auth-login.js +237 -0
- package/dist/components/auth/auth-login.js.map +1 -0
- package/dist/components/auth/auth-register.d.ts +35 -0
- package/dist/components/auth/auth-register.d.ts.map +1 -0
- package/dist/components/auth/auth-register.js +478 -0
- package/dist/components/auth/auth-register.js.map +1 -0
- package/dist/components/auth/auth-reset-password.d.ts +21 -0
- package/dist/components/auth/auth-reset-password.d.ts.map +1 -0
- package/dist/components/auth/auth-reset-password.js +283 -0
- package/dist/components/auth/auth-reset-password.js.map +1 -0
- package/dist/components/auth/auth-router.d.ts +245 -0
- package/dist/components/auth/auth-router.d.ts.map +1 -0
- package/dist/components/auth/auth-router.js +117 -0
- package/dist/components/auth/auth-router.js.map +1 -0
- package/dist/components/auth/auth-verify-email.d.ts +19 -0
- package/dist/components/auth/auth-verify-email.d.ts.map +1 -0
- package/dist/components/auth/auth-verify-email.js +124 -0
- package/dist/components/auth/auth-verify-email.js.map +1 -0
- package/dist/components/auth/provider-labels.d.ts +9 -0
- package/dist/components/auth/provider-labels.d.ts.map +1 -0
- package/dist/components/auth/provider-labels.js +20 -0
- package/dist/components/auth/provider-labels.js.map +1 -0
- package/dist/components/auto-form/auto-form.d.ts +219 -0
- package/dist/components/auto-form/auto-form.d.ts.map +1 -0
- package/dist/components/auto-form/auto-form.js +412 -0
- package/dist/components/auto-form/auto-form.js.map +1 -0
- package/dist/components/brand-icon/brand-icon.d.ts +18 -0
- package/dist/components/brand-icon/brand-icon.d.ts.map +1 -0
- package/dist/components/brand-icon/brand-icon.js +84 -0
- package/dist/components/brand-icon/brand-icon.js.map +1 -0
- package/dist/components/button-dark/button-dark.d.ts +25 -0
- package/dist/components/button-dark/button-dark.d.ts.map +1 -0
- package/dist/components/button-dark/button-dark.js +44 -0
- package/dist/components/button-dark/button-dark.js.map +1 -0
- package/dist/components/button-language/button-language.d.ts +24 -0
- package/dist/components/button-language/button-language.d.ts.map +1 -0
- package/dist/components/button-language/button-language.js +50 -0
- package/dist/components/button-language/button-language.js.map +1 -0
- package/dist/components/button-theme/button-theme.d.ts +33 -0
- package/dist/components/button-theme/button-theme.d.ts.map +1 -0
- package/dist/components/button-theme/button-theme.js +90 -0
- package/dist/components/button-theme/button-theme.js.map +1 -0
- package/dist/components/button-user/button-user.d.ts +147 -0
- package/dist/components/button-user/button-user.d.ts.map +1 -0
- package/dist/components/button-user/button-user.js +147 -0
- package/dist/components/button-user/button-user.js.map +1 -0
- package/dist/components/captcha/turnstile-widget.d.ts +59 -0
- package/dist/components/captcha/turnstile-widget.d.ts.map +1 -0
- package/dist/components/captcha/turnstile-widget.js +97 -0
- package/dist/components/captcha/turnstile-widget.js.map +1 -0
- package/dist/components/control/control.d.ts +200 -0
- package/dist/components/control/control.d.ts.map +1 -0
- package/dist/components/control/control.js +300 -0
- package/dist/components/control/control.js.map +1 -0
- package/dist/components/control-array/control-array.d.ts +77 -0
- package/dist/components/control-array/control-array.d.ts.map +1 -0
- package/dist/components/control-array/control-array.js +444 -0
- package/dist/components/control-array/control-array.js.map +1 -0
- package/dist/components/control-base/field-i18n.d.ts +30 -0
- package/dist/components/control-base/field-i18n.d.ts.map +1 -0
- package/dist/components/control-base/field-i18n.js +27 -0
- package/dist/components/control-base/field-i18n.js.map +1 -0
- package/dist/components/control-base/form-field.d.ts +128 -0
- package/dist/components/control-base/form-field.d.ts.map +1 -0
- package/dist/components/control-base/form-field.js +208 -0
- package/dist/components/control-base/form-field.js.map +1 -0
- package/dist/components/control-base/grid.d.ts +18 -0
- package/dist/components/control-base/grid.d.ts.map +1 -0
- package/dist/components/control-base/grid.js +46 -0
- package/dist/components/control-base/grid.js.map +1 -0
- package/dist/components/control-base/icon-hint.d.ts +9 -0
- package/dist/components/control-base/icon-hint.d.ts.map +1 -0
- package/dist/components/control-base/icon-hint.js +35 -0
- package/dist/components/control-base/icon-hint.js.map +1 -0
- package/dist/components/control-date/control-date.d.ts +34 -0
- package/dist/components/control-date/control-date.d.ts.map +1 -0
- package/dist/components/control-date/control-date.js +111 -0
- package/dist/components/control-date/control-date.js.map +1 -0
- package/dist/components/control-number/control-number.d.ts +38 -0
- package/dist/components/control-number/control-number.d.ts.map +1 -0
- package/dist/components/control-number/control-number.js +77 -0
- package/dist/components/control-number/control-number.js.map +1 -0
- package/dist/components/control-object/control-object.d.ts +45 -0
- package/dist/components/control-object/control-object.d.ts.map +1 -0
- package/dist/components/control-object/control-object.js +110 -0
- package/dist/components/control-object/control-object.js.map +1 -0
- package/dist/components/control-password/control-password.d.ts +28 -0
- package/dist/components/control-password/control-password.d.ts.map +1 -0
- package/dist/components/control-password/control-password.js +65 -0
- package/dist/components/control-password/control-password.js.map +1 -0
- package/dist/components/control-select/control-select.d.ts +128 -0
- package/dist/components/control-select/control-select.d.ts.map +1 -0
- package/dist/components/control-select/control-select.js +363 -0
- package/dist/components/control-select/control-select.js.map +1 -0
- package/dist/components/control-upload/control-upload.d.ts +67 -0
- package/dist/components/control-upload/control-upload.d.ts.map +1 -0
- package/dist/components/control-upload/control-upload.js +294 -0
- package/dist/components/control-upload/control-upload.js.map +1 -0
- package/dist/components/file-image/file-image.d.ts +31 -0
- package/dist/components/file-image/file-image.d.ts.map +1 -0
- package/dist/components/file-image/file-image.js +27 -0
- package/dist/components/file-image/file-image.js.map +1 -0
- package/dist/components/language-toggle/language-toggle.d.ts +8 -0
- package/dist/components/language-toggle/language-toggle.d.ts.map +1 -0
- package/dist/components/language-toggle/language-toggle.js +49 -0
- package/dist/components/language-toggle/language-toggle.js.map +1 -0
- package/dist/components/markdown-view/markdown-view.css +114 -0
- package/dist/components/markdown-view/markdown-view.d.ts +21 -0
- package/dist/components/markdown-view/markdown-view.d.ts.map +1 -0
- package/dist/components/markdown-view/markdown-view.js +104 -0
- package/dist/components/markdown-view/markdown-view.js.map +1 -0
- package/dist/components/nav-shell/nav-page.d.ts +24 -0
- package/dist/components/nav-shell/nav-page.d.ts.map +1 -0
- package/dist/components/nav-shell/nav-page.js +28 -0
- package/dist/components/nav-shell/nav-page.js.map +1 -0
- package/dist/components/nav-shell/nav-shell.d.ts +26 -0
- package/dist/components/nav-shell/nav-shell.d.ts.map +1 -0
- package/dist/components/nav-shell/nav-shell.js +53 -0
- package/dist/components/nav-shell/nav-shell.js.map +1 -0
- package/dist/components/nav-shell/nav-tree-util.d.ts +65 -0
- package/dist/components/nav-shell/nav-tree-util.d.ts.map +1 -0
- package/dist/components/nav-shell/nav-tree-util.js +87 -0
- package/dist/components/nav-shell/nav-tree-util.js.map +1 -0
- package/dist/components/nav-shell/spotlight.d.ts +37 -0
- package/dist/components/nav-shell/spotlight.d.ts.map +1 -0
- package/dist/components/nav-shell/spotlight.js +102 -0
- package/dist/components/nav-shell/spotlight.js.map +1 -0
- package/dist/components/nav-shell/use-nav-breadcrumbs.d.ts +24 -0
- package/dist/components/nav-shell/use-nav-breadcrumbs.d.ts.map +1 -0
- package/dist/components/nav-shell/use-nav-breadcrumbs.js +36 -0
- package/dist/components/nav-shell/use-nav-breadcrumbs.js.map +1 -0
- package/dist/components/nav-shell/use-nav-entries.d.ts +45 -0
- package/dist/components/nav-shell/use-nav-entries.d.ts.map +1 -0
- package/dist/components/nav-shell/use-nav-entries.js +60 -0
- package/dist/components/nav-shell/use-nav-entries.js.map +1 -0
- package/dist/components/nav-shell/use-nav-tree.d.ts +21 -0
- package/dist/components/nav-shell/use-nav-tree.d.ts.map +1 -0
- package/dist/components/nav-shell/use-nav-tree.js +48 -0
- package/dist/components/nav-shell/use-nav-tree.js.map +1 -0
- package/dist/components/settings/settings-danger-section.d.ts +35 -0
- package/dist/components/settings/settings-danger-section.d.ts.map +1 -0
- package/dist/components/settings/settings-danger-section.js +42 -0
- package/dist/components/settings/settings-danger-section.js.map +1 -0
- package/dist/components/settings/settings-heading.d.ts +36 -0
- package/dist/components/settings/settings-heading.d.ts.map +1 -0
- package/dist/components/settings/settings-heading.js +39 -0
- package/dist/components/settings/settings-heading.js.map +1 -0
- package/dist/components/settings/settings-layout.d.ts +81 -0
- package/dist/components/settings/settings-layout.d.ts.map +1 -0
- package/dist/components/settings/settings-layout.js +56 -0
- package/dist/components/settings/settings-layout.js.map +1 -0
- package/dist/components/settings/settings-nav.d.ts +85 -0
- package/dist/components/settings/settings-nav.d.ts.map +1 -0
- package/dist/components/settings/settings-nav.js +91 -0
- package/dist/components/settings/settings-nav.js.map +1 -0
- package/dist/components/settings/settings-row.d.ts +45 -0
- package/dist/components/settings/settings-row.d.ts.map +1 -0
- package/dist/components/settings/settings-row.js +44 -0
- package/dist/components/settings/settings-row.js.map +1 -0
- package/dist/components/settings/settings-section.d.ts +36 -0
- package/dist/components/settings/settings-section.d.ts.map +1 -0
- package/dist/components/settings/settings-section.js +36 -0
- package/dist/components/settings/settings-section.js.map +1 -0
- package/dist/components/ui/accordion.d.ts +7 -0
- package/dist/components/ui/accordion.d.ts.map +1 -0
- package/dist/components/ui/accordion.js +55 -0
- package/dist/components/ui/accordion.js.map +1 -0
- package/dist/components/ui/alert-dialog.d.ts +19 -0
- package/dist/components/ui/alert-dialog.d.ts.map +1 -0
- package/dist/components/ui/alert-dialog.js +96 -0
- package/dist/components/ui/alert-dialog.js.map +1 -0
- package/dist/components/ui/alert.d.ts +11 -0
- package/dist/components/ui/alert.d.ts.map +1 -0
- package/dist/components/ui/alert.js +44 -0
- package/dist/components/ui/alert.js.map +1 -0
- package/dist/components/ui/aspect-ratio.d.ts +5 -0
- package/dist/components/ui/aspect-ratio.d.ts.map +1 -0
- package/dist/components/ui/aspect-ratio.js +15 -0
- package/dist/components/ui/aspect-ratio.js.map +1 -0
- package/dist/components/ui/avatar.d.ts +12 -0
- package/dist/components/ui/avatar.d.ts.map +1 -0
- package/dist/components/ui/avatar.js +52 -0
- package/dist/components/ui/avatar.js.map +1 -0
- package/dist/components/ui/badge.d.ts +8 -0
- package/dist/components/ui/badge.d.ts.map +1 -0
- package/dist/components/ui/badge.js +31 -0
- package/dist/components/ui/badge.js.map +1 -0
- package/dist/components/ui/breadcrumb.d.ts +11 -0
- package/dist/components/ui/breadcrumb.d.ts.map +1 -0
- package/dist/components/ui/breadcrumb.js +73 -0
- package/dist/components/ui/breadcrumb.js.map +1 -0
- package/dist/components/ui/button-group.d.ts +11 -0
- package/dist/components/ui/button-group.d.ts.map +1 -0
- package/dist/components/ui/button-group.js +43 -0
- package/dist/components/ui/button-group.js.map +1 -0
- package/dist/components/ui/button.d.ts +18 -0
- package/dist/components/ui/button.d.ts.map +1 -0
- package/dist/components/ui/button.js +60 -0
- package/dist/components/ui/button.js.map +1 -0
- package/dist/components/ui/calendar.d.ts +11 -0
- package/dist/components/ui/calendar.d.ts.map +1 -0
- package/dist/components/ui/calendar.js +119 -0
- package/dist/components/ui/calendar.js.map +1 -0
- package/dist/components/ui/card.d.ts +12 -0
- package/dist/components/ui/card.d.ts.map +1 -0
- package/dist/components/ui/card.js +57 -0
- package/dist/components/ui/card.js.map +1 -0
- package/dist/components/ui/carousel.d.ts +29 -0
- package/dist/components/ui/carousel.d.ts.map +1 -0
- package/dist/components/ui/carousel.js +134 -0
- package/dist/components/ui/carousel.js.map +1 -0
- package/dist/components/ui/chart.d.ts +45 -0
- package/dist/components/ui/chart.d.ts.map +1 -0
- package/dist/components/ui/chart.js +151 -0
- package/dist/components/ui/chart.js.map +1 -0
- package/dist/components/ui/checkbox.d.ts +4 -0
- package/dist/components/ui/checkbox.d.ts.map +1 -0
- package/dist/components/ui/checkbox.js +22 -0
- package/dist/components/ui/checkbox.js.map +1 -0
- package/dist/components/ui/collapsible.d.ts +6 -0
- package/dist/components/ui/collapsible.d.ts.map +1 -0
- package/dist/components/ui/collapsible.js +26 -0
- package/dist/components/ui/collapsible.js.map +1 -0
- package/dist/components/ui/combobox.d.ts +25 -0
- package/dist/components/ui/combobox.d.ts.map +1 -0
- package/dist/components/ui/combobox.js +164 -0
- package/dist/components/ui/combobox.js.map +1 -0
- package/dist/components/ui/command.d.ts +20 -0
- package/dist/components/ui/command.d.ts.map +1 -0
- package/dist/components/ui/command.js +89 -0
- package/dist/components/ui/command.js.map +1 -0
- package/dist/components/ui/context-menu.d.ts +30 -0
- package/dist/components/ui/context-menu.d.ts.map +1 -0
- package/dist/components/ui/context-menu.js +134 -0
- package/dist/components/ui/context-menu.js.map +1 -0
- package/dist/components/ui/dialog.d.ts +18 -0
- package/dist/components/ui/dialog.d.ts.map +1 -0
- package/dist/components/ui/dialog.js +93 -0
- package/dist/components/ui/dialog.js.map +1 -0
- package/dist/components/ui/direction.d.ts +2 -0
- package/dist/components/ui/direction.d.ts.map +1 -0
- package/dist/components/ui/direction.js +3 -0
- package/dist/components/ui/drawer.d.ts +17 -0
- package/dist/components/ui/drawer.d.ts.map +1 -0
- package/dist/components/ui/drawer.js +125 -0
- package/dist/components/ui/drawer.js.map +1 -0
- package/dist/components/ui/dropdown-menu.d.ts +30 -0
- package/dist/components/ui/dropdown-menu.d.ts.map +1 -0
- package/dist/components/ui/dropdown-menu.js +138 -0
- package/dist/components/ui/dropdown-menu.js.map +1 -0
- package/dist/components/ui/empty.d.ts +12 -0
- package/dist/components/ui/empty.d.ts.map +1 -0
- package/dist/components/ui/empty.js +61 -0
- package/dist/components/ui/empty.js.map +1 -0
- package/dist/components/ui/hover-card.d.ts +6 -0
- package/dist/components/ui/hover-card.d.ts.map +1 -0
- package/dist/components/ui/hover-card.js +38 -0
- package/dist/components/ui/hover-card.js.map +1 -0
- package/dist/components/ui/input-group.d.ts +19 -0
- package/dist/components/ui/input-group.d.ts.map +1 -0
- package/dist/components/ui/input-group.js +80 -0
- package/dist/components/ui/input-group.js.map +1 -0
- package/dist/components/ui/input-otp.d.ts +12 -0
- package/dist/components/ui/input-otp.d.ts.map +1 -0
- package/dist/components/ui/input-otp.js +49 -0
- package/dist/components/ui/input-otp.js.map +1 -0
- package/dist/components/ui/input.d.ts +4 -0
- package/dist/components/ui/input.d.ts.map +1 -0
- package/dist/components/ui/input.js +16 -0
- package/dist/components/ui/input.js.map +1 -0
- package/dist/components/ui/item.d.ts +23 -0
- package/dist/components/ui/item.d.ts.map +1 -0
- package/dist/components/ui/item.js +122 -0
- package/dist/components/ui/item.js.map +1 -0
- package/dist/components/ui/kbd.d.ts +4 -0
- package/dist/components/ui/kbd.d.ts.map +1 -0
- package/dist/components/ui/kbd.js +21 -0
- package/dist/components/ui/kbd.js.map +1 -0
- package/dist/components/ui/label.d.ts +4 -0
- package/dist/components/ui/label.d.ts.map +1 -0
- package/dist/components/ui/label.js +15 -0
- package/dist/components/ui/label.js.map +1 -0
- package/dist/components/ui/menubar.d.ts +30 -0
- package/dist/components/ui/menubar.d.ts.map +1 -0
- package/dist/components/ui/menubar.js +137 -0
- package/dist/components/ui/menubar.js.map +1 -0
- package/dist/components/ui/navigation-menu.d.ts +12 -0
- package/dist/components/ui/navigation-menu.d.ts.map +1 -0
- package/dist/components/ui/navigation-menu.js +84 -0
- package/dist/components/ui/navigation-menu.js.map +1 -0
- package/dist/components/ui/pagination.d.ts +18 -0
- package/dist/components/ui/pagination.d.ts.map +1 -0
- package/dist/components/ui/pagination.js +87 -0
- package/dist/components/ui/pagination.js.map +1 -0
- package/dist/components/ui/popover.d.ts +10 -0
- package/dist/components/ui/popover.d.ts.map +1 -0
- package/dist/components/ui/popover.js +56 -0
- package/dist/components/ui/popover.js.map +1 -0
- package/dist/components/ui/progress.d.ts +8 -0
- package/dist/components/ui/progress.d.ts.map +1 -0
- package/dist/components/ui/progress.js +46 -0
- package/dist/components/ui/progress.js.map +1 -0
- package/dist/components/ui/radio-group.d.ts +6 -0
- package/dist/components/ui/radio-group.d.ts.map +1 -0
- package/dist/components/ui/radio-group.js +29 -0
- package/dist/components/ui/radio-group.js.map +1 -0
- package/dist/components/ui/resizable.d.ts +8 -0
- package/dist/components/ui/resizable.d.ts.map +1 -0
- package/dist/components/ui/resizable.js +30 -0
- package/dist/components/ui/resizable.js.map +1 -0
- package/dist/components/ui/scroll-area.d.ts +5 -0
- package/dist/components/ui/scroll-area.d.ts.map +1 -0
- package/dist/components/ui/scroll-area.js +38 -0
- package/dist/components/ui/scroll-area.js.map +1 -0
- package/dist/components/ui/segmented.d.ts +46 -0
- package/dist/components/ui/segmented.d.ts.map +1 -0
- package/dist/components/ui/segmented.js +119 -0
- package/dist/components/ui/segmented.js.map +1 -0
- package/dist/components/ui/select.d.ts +16 -0
- package/dist/components/ui/select.d.ts.map +1 -0
- package/dist/components/ui/select.js +99 -0
- package/dist/components/ui/select.js.map +1 -0
- package/dist/components/ui/separator.d.ts +4 -0
- package/dist/components/ui/separator.d.ts.map +1 -0
- package/dist/components/ui/separator.js +17 -0
- package/dist/components/ui/separator.js.map +1 -0
- package/dist/components/ui/sheet.d.ts +15 -0
- package/dist/components/ui/sheet.d.ts.map +1 -0
- package/dist/components/ui/sheet.js +90 -0
- package/dist/components/ui/sheet.js.map +1 -0
- package/dist/components/ui/sidebar.d.ts +64 -0
- package/dist/components/ui/sidebar.d.ts.map +1 -0
- package/dist/components/ui/sidebar.js +388 -0
- package/dist/components/ui/sidebar.js.map +1 -0
- package/dist/components/ui/skeleton.d.ts +3 -0
- package/dist/components/ui/skeleton.d.ts.map +1 -0
- package/dist/components/ui/skeleton.js +14 -0
- package/dist/components/ui/skeleton.js.map +1 -0
- package/dist/components/ui/slider.d.ts +4 -0
- package/dist/components/ui/slider.d.ts.map +1 -0
- package/dist/components/ui/slider.js +35 -0
- package/dist/components/ui/slider.js.map +1 -0
- package/dist/components/ui/sonner.d.ts +4 -0
- package/dist/components/ui/sonner.d.ts.map +1 -0
- package/dist/components/ui/sonner.js +33 -0
- package/dist/components/ui/sonner.js.map +1 -0
- package/dist/components/ui/spinner.d.ts +3 -0
- package/dist/components/ui/spinner.d.ts.map +1 -0
- package/dist/components/ui/spinner.js +17 -0
- package/dist/components/ui/spinner.js.map +1 -0
- package/dist/components/ui/switch.d.ts +6 -0
- package/dist/components/ui/switch.d.ts.map +1 -0
- package/dist/components/ui/switch.js +21 -0
- package/dist/components/ui/switch.js.map +1 -0
- package/dist/components/ui/table.d.ts +11 -0
- package/dist/components/ui/table.d.ts.map +1 -0
- package/dist/components/ui/table.js +68 -0
- package/dist/components/ui/table.js.map +1 -0
- package/dist/components/ui/tabs.d.ts +11 -0
- package/dist/components/ui/tabs.d.ts.map +1 -0
- package/dist/components/ui/tabs.js +47 -0
- package/dist/components/ui/tabs.js.map +1 -0
- package/dist/components/ui/textarea.d.ts +4 -0
- package/dist/components/ui/textarea.d.ts.map +1 -0
- package/dist/components/ui/textarea.js +14 -0
- package/dist/components/ui/textarea.js.map +1 -0
- package/dist/components/ui/toggle-group.d.ts +12 -0
- package/dist/components/ui/toggle-group.d.ts.map +1 -0
- package/dist/components/ui/toggle-group.js +54 -0
- package/dist/components/ui/toggle-group.js.map +1 -0
- package/dist/components/ui/toggle.d.ts +9 -0
- package/dist/components/ui/toggle.d.ts.map +1 -0
- package/dist/components/ui/toggle.js +38 -0
- package/dist/components/ui/toggle.js.map +1 -0
- package/dist/components/ui/tooltip.d.ts +7 -0
- package/dist/components/ui/tooltip.d.ts.map +1 -0
- package/dist/components/ui/tooltip.js +43 -0
- package/dist/components/ui/tooltip.js.map +1 -0
- package/dist/components/use-dialog/use-dialog.d.ts +61 -0
- package/dist/components/use-dialog/use-dialog.d.ts.map +1 -0
- package/dist/components/use-dialog/use-dialog.js +139 -0
- package/dist/components/use-dialog/use-dialog.js.map +1 -0
- package/dist/components/use-toast/use-toast.d.ts +37 -0
- package/dist/components/use-toast/use-toast.d.ts.map +1 -0
- package/dist/components/use-toast/use-toast.js +32 -0
- package/dist/components/use-toast/use-toast.js.map +1 -0
- package/dist/hooks/use-mobile.d.ts +2 -0
- package/dist/hooks/use-mobile.d.ts.map +1 -0
- package/dist/hooks/use-mobile.js +20 -0
- package/dist/hooks/use-mobile.js.map +1 -0
- package/dist/lib/i18n-fr.d.ts +46 -0
- package/dist/lib/i18n-fr.d.ts.map +1 -0
- package/dist/lib/i18n-fr.js +505 -0
- package/dist/lib/i18n-fr.js.map +1 -0
- package/dist/lib/resize-image.d.ts +50 -0
- package/dist/lib/resize-image.d.ts.map +1 -0
- package/dist/lib/resize-image.js +68 -0
- package/dist/lib/resize-image.js.map +1 -0
- package/dist/lib/utils.d.ts +3 -0
- package/dist/lib/utils.d.ts.map +1 -0
- package/dist/lib/utils.js +10 -0
- package/dist/lib/utils.js.map +1 -0
- package/dist/styles.css +254 -0
- package/package.json +46 -15
- package/src/components/account/account-connections.tsx +9 -1
- package/src/components/account/account-keys.tsx +1 -1
- package/src/components/account/account-layout.tsx +6 -3
- package/src/components/account/account-profile.tsx +238 -125
- package/src/components/account/account-router-options.tsx +14 -0
- package/src/components/account/account-router.tsx +20 -1
- package/src/components/account/account-security.tsx +1 -1
- package/src/components/admin/admin-router-options.tsx +20 -0
- package/src/components/alepha-table/alepha-table.tsx +23 -7
- package/src/components/app-actions/app-actions.tsx +7 -2
- package/src/components/auth/auth-register.tsx +55 -17
- package/src/components/auto-form/__tests__/auto-form-settings-card.browser.spec.tsx +237 -0
- package/src/components/auto-form/auto-form.tsx +113 -27
- package/src/components/button-user/button-user.tsx +76 -17
- package/src/components/control/control.tsx +33 -8
- package/src/components/control-base/form-field.tsx +60 -3
- package/src/components/markdown-view/__tests__/markdown-view-raw-html.browser.spec.tsx +48 -0
- package/src/components/markdown-view/markdown-view.tsx +14 -6
- package/src/components/nav-shell/__tests__/nav-tree-util.spec.ts +88 -0
- package/src/components/nav-shell/nav-tree-util.ts +48 -0
- package/src/components/nav-shell/use-nav-entries.ts +11 -2
- package/src/components/settings/settings-heading.tsx +55 -0
- package/src/components/settings/settings-layout.tsx +66 -7
- package/src/components/settings/settings-nav.tsx +48 -4
- package/src/components/settings/settings-section.tsx +2 -14
- package/src/components/ui/segmented.tsx +19 -2
- package/src/lib/__tests__/rehype-safe-img.spec.ts +0 -121
- package/src/lib/rehype-safe-img.ts +0 -150
|
@@ -20,6 +20,33 @@ export interface SettingsLayoutProps {
|
|
|
20
20
|
*/
|
|
21
21
|
children: ReactNode;
|
|
22
22
|
|
|
23
|
+
/**
|
|
24
|
+
* Bound the shell to its parent's height and give the content column its
|
|
25
|
+
* own scrollbar, instead of letting the document scroll.
|
|
26
|
+
*
|
|
27
|
+
* Turn it on when this layout is mounted inside a host that has already
|
|
28
|
+
* taken the viewport height and hidden its own overflow — an application
|
|
29
|
+
* shell built as `h-svh … overflow-hidden`, which is the usual shape for an
|
|
30
|
+
* app with a fixed header. In that host the default (below) has no scrollbar
|
|
31
|
+
* to give: the document cannot scroll, so anything past the fold is simply
|
|
32
|
+
* unreachable.
|
|
33
|
+
*
|
|
34
|
+
* The mode is deliberately not auto-detected. Reading the ancestor chain for
|
|
35
|
+
* a clipping parent is a layout-effect away from a flash of the wrong shape
|
|
36
|
+
* on every mount, and the host already knows the answer at boot.
|
|
37
|
+
*
|
|
38
|
+
* It serves both kinds of page at once, which is why there is one flag
|
|
39
|
+
* rather than two:
|
|
40
|
+
*
|
|
41
|
+
* - A natural-height page (a stack of {@link SettingsSection} cards) exceeds
|
|
42
|
+
* the column and scrolls it — the same reading experience as the default,
|
|
43
|
+
* just against a nearer scroll root.
|
|
44
|
+
* - A page that opts into `flex-1 min-h-0` is bounded by the column instead,
|
|
45
|
+
* so it can hand the scroll to a child. That is what lets a table keep its
|
|
46
|
+
* filters and pagination bar pinned while only its rows move.
|
|
47
|
+
*/
|
|
48
|
+
fill?: boolean;
|
|
49
|
+
|
|
23
50
|
className?: string;
|
|
24
51
|
}
|
|
25
52
|
|
|
@@ -34,20 +61,52 @@ export interface SettingsLayoutProps {
|
|
|
34
61
|
* rail included. `min-w-0` lets it shrink and lets the child's own
|
|
35
62
|
* `overflow` handle it.
|
|
36
63
|
*
|
|
37
|
-
*
|
|
38
|
-
* `overflow-auto` would
|
|
39
|
-
* {@link
|
|
40
|
-
*
|
|
64
|
+
* By default there is no scroll container here and the page scrolls, because
|
|
65
|
+
* a nested `overflow-auto` would strand the sticky rail against the wrong
|
|
66
|
+
* scroll root. Pass {@link SettingsLayoutProps.fill} when the host has already
|
|
67
|
+
* claimed the viewport height and clipped its own overflow, so there is no
|
|
68
|
+
* page scroll left to inherit.
|
|
69
|
+
*
|
|
70
|
+
* `md:items-start` becomes `md:items-stretch` under `fill` so the content
|
|
71
|
+
* column is as tall as the row rather than as tall as its content — a column
|
|
72
|
+
* sized by its content can never be the thing that scrolls. The rail is
|
|
73
|
+
* unaffected either way: it carries its own `md:self-start`, which outranks
|
|
74
|
+
* whatever the row aligns to.
|
|
75
|
+
*
|
|
76
|
+
* ⚠️ **`fill` engages at `md` and up only, and the root keeps a scrollbar at
|
|
77
|
+
* every width.** Below `md` the rail is not a rail: it stacks above the
|
|
78
|
+
* content as a full list of links, which on a phone is most of the viewport.
|
|
79
|
+
* Splitting what little is left into a second bounded pane gives a page a few
|
|
80
|
+
* hundred pixels it cannot grow out of — a table lands in a box too short to
|
|
81
|
+
* show a row, and because that table owns its own scroll, nothing above it can
|
|
82
|
+
* scroll to make room. So the mobile shape stays the default one: the root
|
|
83
|
+
* scrolls, rail and content together. At `md` and up the row is bounded, so
|
|
84
|
+
* the root's scrollbar never has anything to show and the content column is
|
|
85
|
+
* the scroll root instead.
|
|
41
86
|
*/
|
|
42
87
|
export const SettingsLayout = (props: SettingsLayoutProps) => {
|
|
43
88
|
return (
|
|
44
89
|
<div
|
|
45
|
-
className={cn(
|
|
90
|
+
className={cn(
|
|
91
|
+
"mx-auto w-full max-w-5xl p-4 md:pt-10",
|
|
92
|
+
props.fill && "flex h-full min-h-0 flex-col overflow-y-auto",
|
|
93
|
+
props.className,
|
|
94
|
+
)}
|
|
46
95
|
>
|
|
47
96
|
{props.header ? <div className="mb-6">{props.header}</div> : null}
|
|
48
|
-
<div
|
|
97
|
+
<div
|
|
98
|
+
className={cn(
|
|
99
|
+
"flex flex-col gap-6 md:flex-row md:items-start",
|
|
100
|
+
props.fill && "md:min-h-0 md:flex-1 md:items-stretch",
|
|
101
|
+
)}
|
|
102
|
+
>
|
|
49
103
|
{props.nav}
|
|
50
|
-
<div
|
|
104
|
+
<div
|
|
105
|
+
className={cn(
|
|
106
|
+
"flex min-w-0 flex-1 flex-col gap-8",
|
|
107
|
+
props.fill && "md:min-h-0 md:overflow-y-auto",
|
|
108
|
+
)}
|
|
109
|
+
>
|
|
51
110
|
{props.children}
|
|
52
111
|
</div>
|
|
53
112
|
</div>
|
|
@@ -43,6 +43,14 @@ export interface SettingsNavProps {
|
|
|
43
43
|
*/
|
|
44
44
|
items: SettingsNavItem[];
|
|
45
45
|
|
|
46
|
+
/**
|
|
47
|
+
* Entry height, matching `SidebarMenuButton`'s own sizes: `sm` is `h-7` with
|
|
48
|
+
* `text-xs`, `default` is `h-8` with `text-sm`.
|
|
49
|
+
*
|
|
50
|
+
* @default "sm"
|
|
51
|
+
*/
|
|
52
|
+
size?: "sm" | "default";
|
|
53
|
+
|
|
46
54
|
className?: string;
|
|
47
55
|
}
|
|
48
56
|
|
|
@@ -63,8 +71,41 @@ export interface SettingsNavProps {
|
|
|
63
71
|
* ({@link SettingsNavItem} is structurally a subset of `NavEntry`, so no
|
|
64
72
|
* mapping is needed); a parameterised one passes its own
|
|
65
73
|
* `router.path(name, { params })` list.
|
|
74
|
+
*
|
|
75
|
+
* ### Why this is not built out of `SidebarMenuButton`
|
|
76
|
+
*
|
|
77
|
+
* It reads like the obvious reuse — this rail is a small sidebar, and the
|
|
78
|
+
* sizes and metrics below are deliberately `SidebarMenuButton`'s, so the two
|
|
79
|
+
* look like one family. But the component itself cannot be mounted here:
|
|
80
|
+
*
|
|
81
|
+
* - `SidebarMenuButton` calls `useSidebar()`, which **throws** outside a
|
|
82
|
+
* `SidebarProvider`. Nothing about a static rail needs that provider — it
|
|
83
|
+
* exists to hold collapse state — and mounting one to get a button also
|
|
84
|
+
* registers a global ⌘B handler and starts writing the sidebar cookie. On a
|
|
85
|
+
* page that already sits inside `AppShell` that is a *second* provider, so
|
|
86
|
+
* ⌘B would toggle the wrong sidebar.
|
|
87
|
+
* - Making `useSidebar` tolerate a missing provider, or exporting the button's
|
|
88
|
+
* `cva` to share it, both mean editing `components/ui/sidebar.tsx` — which
|
|
89
|
+
* `yarn w @alepha/ui sync` overwrites wholesale from the upstream registry.
|
|
90
|
+
* The patch would vanish on the next refresh, silently.
|
|
91
|
+
*
|
|
92
|
+
* So the metrics are shared by being written the same, and the coupling is
|
|
93
|
+
* not. If the sizes below ever drift from `sidebarMenuButtonVariants`, that is
|
|
94
|
+
* the thing to re-align.
|
|
66
95
|
*/
|
|
67
96
|
export const SettingsNav = (props: SettingsNavProps) => {
|
|
97
|
+
const size = props.size ?? "sm";
|
|
98
|
+
|
|
99
|
+
/*
|
|
100
|
+
`[&_svg]:size-4` is load-bearing, not cosmetic: `useNavEntries` hands over
|
|
101
|
+
`createElement(Icon)` with no className, and a bare lucide icon defaults to
|
|
102
|
+
24px — half again the height of the text it sits next to.
|
|
103
|
+
*/
|
|
104
|
+
const entry = cn(
|
|
105
|
+
"flex items-center gap-2 whitespace-nowrap rounded-md px-2 text-left [&_svg]:size-4 [&_svg]:shrink-0",
|
|
106
|
+
size === "sm" ? "h-7 text-xs" : "h-8 text-sm",
|
|
107
|
+
);
|
|
108
|
+
|
|
68
109
|
const groups = useMemo(() => {
|
|
69
110
|
const ordered: Array<{ key: string; label?: string }> = [];
|
|
70
111
|
const byKey = new Map<string, SettingsNavItem[]>();
|
|
@@ -91,9 +132,11 @@ export const SettingsNav = (props: SettingsNavProps) => {
|
|
|
91
132
|
)}
|
|
92
133
|
>
|
|
93
134
|
{groups.map((group) => (
|
|
94
|
-
<div key={group.key} className="flex flex-col gap-
|
|
135
|
+
<div key={group.key} className="flex flex-col gap-0.5">
|
|
95
136
|
{group.label ? (
|
|
96
|
-
|
|
137
|
+
// `px-2` matches the entries below, so the heading and the labels
|
|
138
|
+
// it heads share a left edge.
|
|
139
|
+
<span className="px-2 font-semibold text-[11px] text-muted-foreground uppercase tracking-wider">
|
|
97
140
|
{group.label}
|
|
98
141
|
</span>
|
|
99
142
|
) : null}
|
|
@@ -102,7 +145,7 @@ export const SettingsNav = (props: SettingsNavProps) => {
|
|
|
102
145
|
<span
|
|
103
146
|
key={item.name}
|
|
104
147
|
aria-disabled="true"
|
|
105
|
-
className="
|
|
148
|
+
className={cn(entry, "text-muted-foreground/50")}
|
|
106
149
|
>
|
|
107
150
|
{item.icon}
|
|
108
151
|
{item.label}
|
|
@@ -113,7 +156,8 @@ export const SettingsNav = (props: SettingsNavProps) => {
|
|
|
113
156
|
href={item.href}
|
|
114
157
|
aria-current={item.active ? "page" : undefined}
|
|
115
158
|
className={cn(
|
|
116
|
-
|
|
159
|
+
entry,
|
|
160
|
+
"transition-colors",
|
|
117
161
|
item.active
|
|
118
162
|
? "bg-muted font-medium"
|
|
119
163
|
: "text-muted-foreground hover:bg-muted/60",
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { SettingsHeading } from "@alepha/ui/components/settings/settings-heading";
|
|
1
2
|
import { Card } from "@alepha/ui/components/ui/card";
|
|
2
3
|
import { cn } from "@alepha/ui/lib/utils";
|
|
3
4
|
import type { ReactNode } from "react";
|
|
@@ -40,22 +41,9 @@ export interface SettingsSectionProps {
|
|
|
40
41
|
* exactly that and they are the ones that look wrong next to these.
|
|
41
42
|
*/
|
|
42
43
|
export const SettingsSection = (props: SettingsSectionProps) => {
|
|
43
|
-
const hasHeading = props.title != null || props.description != null;
|
|
44
|
-
|
|
45
44
|
return (
|
|
46
45
|
<div className={cn("flex flex-col gap-2", props.className)}>
|
|
47
|
-
{
|
|
48
|
-
<div className="flex flex-col gap-0.5">
|
|
49
|
-
{props.title != null ? (
|
|
50
|
-
<span className="text-sm">{props.title}</span>
|
|
51
|
-
) : null}
|
|
52
|
-
{props.description != null ? (
|
|
53
|
-
<span className="text-muted-foreground text-xs">
|
|
54
|
-
{props.description}
|
|
55
|
-
</span>
|
|
56
|
-
) : null}
|
|
57
|
-
</div>
|
|
58
|
-
) : null}
|
|
46
|
+
<SettingsHeading title={props.title} description={props.description} />
|
|
59
47
|
<Card className="gap-0 divide-y rounded-lg border bg-card py-0">
|
|
60
48
|
{props.children}
|
|
61
49
|
</Card>
|
|
@@ -115,9 +115,26 @@ export function Segmented(props: SegmentedProps) {
|
|
|
115
115
|
if (!el || !container) return;
|
|
116
116
|
const elRect = el.getBoundingClientRect();
|
|
117
117
|
const parentRect = container.getBoundingClientRect();
|
|
118
|
+
// ⚠️ Subtract the container's border, or it is counted twice and the thumb
|
|
119
|
+
// sits one border-width down and to the right of the segment it covers.
|
|
120
|
+
//
|
|
121
|
+
// `getBoundingClientRect()` measures the BORDER box, so this delta includes
|
|
122
|
+
// the border. The thumb is `position: absolute`, whose containing block is
|
|
123
|
+
// the padding box — an origin that already starts inside that same border.
|
|
124
|
+
// Applying a border-box delta from a padding-box origin adds it a second
|
|
125
|
+
// time.
|
|
126
|
+
//
|
|
127
|
+
// At the default 1px border it is a 1px drift on both axes, which reads as
|
|
128
|
+
// the active surface being off-centre: 4px of gap above it and 2px below.
|
|
129
|
+
// Visible, and easy to misdiagnose as missing padding — but padding cannot
|
|
130
|
+
// be the fix, because the drift is equal on the horizontal axis where the
|
|
131
|
+
// box is not symmetric to begin with.
|
|
132
|
+
const parentStyle = getComputedStyle(container);
|
|
133
|
+
const borderLeft = Number.parseFloat(parentStyle.borderLeftWidth) || 0;
|
|
134
|
+
const borderTop = Number.parseFloat(parentStyle.borderTopWidth) || 0;
|
|
118
135
|
setThumb({
|
|
119
|
-
left: elRect.left - parentRect.left,
|
|
120
|
-
top: elRect.top - parentRect.top,
|
|
136
|
+
left: elRect.left - parentRect.left - borderLeft,
|
|
137
|
+
top: elRect.top - parentRect.top - borderTop,
|
|
121
138
|
width: elRect.width,
|
|
122
139
|
height: elRect.height,
|
|
123
140
|
});
|
|
@@ -1,121 +0,0 @@
|
|
|
1
|
-
import { describe, expect, it } from "vitest";
|
|
2
|
-
import { parseSafeImg } from "../rehype-safe-img.ts";
|
|
3
|
-
|
|
4
|
-
/**
|
|
5
|
-
* This is the whole XSS surface of the markdown reader, so it is tested
|
|
6
|
-
* directly rather than through a render.
|
|
7
|
-
*
|
|
8
|
-
* The reader deliberately does NOT use `rehype-raw`: folio content is
|
|
9
|
-
* user-authored, and this codebase escapes raw HTML everywhere else on
|
|
10
|
-
* purpose. `parseSafeImg` is the single exception carved out for `<img>`,
|
|
11
|
-
* which is what MDXEditor emits once an image has been resized — so what it
|
|
12
|
-
* accepts, and only that, becomes renderable markup.
|
|
13
|
-
*/
|
|
14
|
-
describe("parseSafeImg", () => {
|
|
15
|
-
describe("accepts", () => {
|
|
16
|
-
it("a relative assets/ image", () => {
|
|
17
|
-
expect(parseSafeImg('<img src="assets/photo.webp" />')).toEqual({
|
|
18
|
-
src: "assets/photo.webp",
|
|
19
|
-
});
|
|
20
|
-
});
|
|
21
|
-
|
|
22
|
-
it("a same-origin file URL", () => {
|
|
23
|
-
expect(parseSafeImg('<img src="/api/files/abc" />')).toEqual({
|
|
24
|
-
src: "/api/files/abc",
|
|
25
|
-
});
|
|
26
|
-
});
|
|
27
|
-
|
|
28
|
-
it("the allowlisted attributes", () => {
|
|
29
|
-
expect(
|
|
30
|
-
parseSafeImg(
|
|
31
|
-
'<img src="assets/a.png" alt="A cat" title="Tip" width="600" height="400">',
|
|
32
|
-
),
|
|
33
|
-
).toEqual({
|
|
34
|
-
src: "assets/a.png",
|
|
35
|
-
alt: "A cat",
|
|
36
|
-
title: "Tip",
|
|
37
|
-
width: "600",
|
|
38
|
-
height: "400",
|
|
39
|
-
});
|
|
40
|
-
});
|
|
41
|
-
|
|
42
|
-
it("single-quoted and unquoted attribute values", () => {
|
|
43
|
-
expect(parseSafeImg("<img src='assets/a.png' width=600>")).toEqual({
|
|
44
|
-
src: "assets/a.png",
|
|
45
|
-
width: "600",
|
|
46
|
-
});
|
|
47
|
-
});
|
|
48
|
-
});
|
|
49
|
-
|
|
50
|
-
describe("drops attributes outside the allowlist", () => {
|
|
51
|
-
it("an inline event handler", () => {
|
|
52
|
-
expect(
|
|
53
|
-
parseSafeImg('<img src="assets/a.png" onerror="alert(1)">'),
|
|
54
|
-
).toEqual({ src: "assets/a.png" });
|
|
55
|
-
});
|
|
56
|
-
|
|
57
|
-
it("onload, style, class and srcset", () => {
|
|
58
|
-
expect(
|
|
59
|
-
parseSafeImg(
|
|
60
|
-
'<img src="assets/a.png" onload="x()" style="position:fixed" class="evil" srcset="https://evil.test/a 1x">',
|
|
61
|
-
),
|
|
62
|
-
).toEqual({ src: "assets/a.png" });
|
|
63
|
-
});
|
|
64
|
-
|
|
65
|
-
it("a non-numeric width", () => {
|
|
66
|
-
// Width reaches a DOM attribute, so anything but digits is refused
|
|
67
|
-
// rather than passed along to be interpreted.
|
|
68
|
-
expect(parseSafeImg('<img src="assets/a.png" width="600px">')).toEqual({
|
|
69
|
-
src: "assets/a.png",
|
|
70
|
-
});
|
|
71
|
-
});
|
|
72
|
-
});
|
|
73
|
-
|
|
74
|
-
describe("refuses the whole element", () => {
|
|
75
|
-
const rejected = [
|
|
76
|
-
["a javascript: src", '<img src="javascript:alert(1)">'],
|
|
77
|
-
["an uppercase JavaScript: src", '<img src="JaVaScRiPt:alert(1)">'],
|
|
78
|
-
[
|
|
79
|
-
"a javascript: src with an embedded newline",
|
|
80
|
-
'<img src="java\nscript:alert(1)">',
|
|
81
|
-
],
|
|
82
|
-
["a data: src", '<img src="data:image/svg+xml;base64,PHN2Zz4=">'],
|
|
83
|
-
["a remote http src", '<img src="http://evil.test/a.png">'],
|
|
84
|
-
["a remote https src", '<img src="https://evil.test/a.png">'],
|
|
85
|
-
["a protocol-relative src", '<img src="//evil.test/a.png">'],
|
|
86
|
-
["a src that escapes the folio", '<img src="../../etc/passwd">'],
|
|
87
|
-
["no src at all", '<img alt="nothing">'],
|
|
88
|
-
["an empty src", '<img src="">'],
|
|
89
|
-
] as const;
|
|
90
|
-
|
|
91
|
-
for (const [label, html] of rejected) {
|
|
92
|
-
it(label, () => {
|
|
93
|
-
expect(parseSafeImg(html)).toBeUndefined();
|
|
94
|
-
});
|
|
95
|
-
}
|
|
96
|
-
});
|
|
97
|
-
|
|
98
|
-
describe("refuses anything that is not a lone img", () => {
|
|
99
|
-
const rejected = [
|
|
100
|
-
["a script tag", "<script>alert(1)</script>"],
|
|
101
|
-
["an iframe", '<iframe src="/x"></iframe>'],
|
|
102
|
-
["an svg", '<svg onload="alert(1)"></svg>'],
|
|
103
|
-
[
|
|
104
|
-
"an img followed by a script",
|
|
105
|
-
'<img src="assets/a.png"><script>x</script>',
|
|
106
|
-
],
|
|
107
|
-
["a tag that merely starts with img", '<image src="assets/a.png">'],
|
|
108
|
-
["plain text", "not html at all"],
|
|
109
|
-
[
|
|
110
|
-
"an anchor wrapping an img",
|
|
111
|
-
'<a href="/x"><img src="assets/a.png"></a>',
|
|
112
|
-
],
|
|
113
|
-
] as const;
|
|
114
|
-
|
|
115
|
-
for (const [label, html] of rejected) {
|
|
116
|
-
it(label, () => {
|
|
117
|
-
expect(parseSafeImg(html)).toBeUndefined();
|
|
118
|
-
});
|
|
119
|
-
}
|
|
120
|
-
});
|
|
121
|
-
});
|
|
@@ -1,150 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* The attributes an `<img>` may carry through. Everything else — event
|
|
3
|
-
* handlers, `style`, `class`, `srcset`, `usemap` — is dropped.
|
|
4
|
-
*/
|
|
5
|
-
const ALLOWED = new Set(["src", "alt", "title", "width", "height"]);
|
|
6
|
-
|
|
7
|
-
/**
|
|
8
|
-
* One `<img …>` tag and nothing else: optional whitespace, the tag, its
|
|
9
|
-
* attributes, an optional self-closing slash, and the end of the string.
|
|
10
|
-
*
|
|
11
|
-
* Anchored at both ends deliberately. A pattern that merely *found* an
|
|
12
|
-
* `<img>` would accept `<img src="a"><script>…</script>` and promote the
|
|
13
|
-
* whole raw node, carrying the script into the document as markup.
|
|
14
|
-
*/
|
|
15
|
-
const LONE_IMG = /^\s*<img\s+([^>]*?)\/?>\s*$/i;
|
|
16
|
-
|
|
17
|
-
/**
|
|
18
|
-
* `name="value"`, `name='value'` or `name=value`.
|
|
19
|
-
*/
|
|
20
|
-
const ATTRIBUTE = /([a-zA-Z-]+)\s*=\s*(?:"([^"]*)"|'([^']*)'|([^\s"'>]+))/g;
|
|
21
|
-
|
|
22
|
-
/**
|
|
23
|
-
* A `src` this reader is willing to load.
|
|
24
|
-
*
|
|
25
|
-
* Allowed: a relative `assets/…` path (what folio content stores) and a
|
|
26
|
-
* same-origin absolute path (`/api/files/…`). Nothing else — no `data:`,
|
|
27
|
-
* no `javascript:`, no remote host, and no `//` protocol-relative URL,
|
|
28
|
-
* which is a remote host wearing a local-looking prefix.
|
|
29
|
-
*/
|
|
30
|
-
const isSafeSrc = (src: string): boolean => {
|
|
31
|
-
// Drop every C0 control character and space before looking for a scheme.
|
|
32
|
-
// Browsers ignore them while parsing a URL, so a literal tab or newline
|
|
33
|
-
// inside the attribute would otherwise walk `java\nscript:` past a naive
|
|
34
|
-
// prefix check and still execute.
|
|
35
|
-
//
|
|
36
|
-
// Done by code point rather than by a regex character class: a class
|
|
37
|
-
// spanning control characters is unreadable and linters reject it
|
|
38
|
-
// outright. The bound says what it means.
|
|
39
|
-
let stripped = "";
|
|
40
|
-
for (const character of src) {
|
|
41
|
-
if ((character.codePointAt(0) ?? 0) > 0x20) stripped += character;
|
|
42
|
-
}
|
|
43
|
-
const normalized = stripped.toLowerCase();
|
|
44
|
-
if (!normalized) return false;
|
|
45
|
-
if (normalized.includes(":")) return false;
|
|
46
|
-
if (normalized.startsWith("//")) return false;
|
|
47
|
-
// `..` would address something outside the folio's own assets.
|
|
48
|
-
if (normalized.includes("..")) return false;
|
|
49
|
-
return normalized.startsWith("assets/") || normalized.startsWith("/");
|
|
50
|
-
};
|
|
51
|
-
|
|
52
|
-
/**
|
|
53
|
-
* Parse a raw HTML string into the attributes of a safe `<img>`, or
|
|
54
|
-
* `undefined` if it is anything else.
|
|
55
|
-
*
|
|
56
|
-
* Exported and tested directly because this is the entire XSS surface of the
|
|
57
|
-
* markdown reader: `MarkdownView` renders user-authored content and does NOT
|
|
58
|
-
* use `rehype-raw`, so raw HTML is escaped to text everywhere except here.
|
|
59
|
-
*
|
|
60
|
-
* Deliberately string-based rather than `innerHTML`-based: this runs during
|
|
61
|
-
* SSR where there is no DOM, and a parser that only ever produces an
|
|
62
|
-
* allowlisted attribute bag cannot be tricked into producing a different
|
|
63
|
-
* element.
|
|
64
|
-
*/
|
|
65
|
-
export const parseSafeImg = (
|
|
66
|
-
html: string,
|
|
67
|
-
): Record<string, string> | undefined => {
|
|
68
|
-
const match = LONE_IMG.exec(html);
|
|
69
|
-
if (!match) return undefined;
|
|
70
|
-
|
|
71
|
-
const attributes: Record<string, string> = {};
|
|
72
|
-
ATTRIBUTE.lastIndex = 0;
|
|
73
|
-
let found: RegExpExecArray | null = ATTRIBUTE.exec(match[1]);
|
|
74
|
-
while (found) {
|
|
75
|
-
const name = found[1].toLowerCase();
|
|
76
|
-
const value = found[2] ?? found[3] ?? found[4] ?? "";
|
|
77
|
-
if (ALLOWED.has(name)) {
|
|
78
|
-
// `width`/`height` reach a DOM attribute, so only digits pass —
|
|
79
|
-
// anything else is refused rather than handed over to be interpreted.
|
|
80
|
-
if (name === "width" || name === "height") {
|
|
81
|
-
if (/^\d+$/.test(value)) attributes[name] = value;
|
|
82
|
-
} else {
|
|
83
|
-
attributes[name] = value;
|
|
84
|
-
}
|
|
85
|
-
}
|
|
86
|
-
found = ATTRIBUTE.exec(match[1]);
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
if (!attributes.src || !isSafeSrc(attributes.src)) return undefined;
|
|
90
|
-
return attributes;
|
|
91
|
-
};
|
|
92
|
-
|
|
93
|
-
/**
|
|
94
|
-
* Minimal shape of the hast nodes this plugin walks. Typed locally rather
|
|
95
|
-
* than pulled from `@types/hast` — the package is not a dependency here, and
|
|
96
|
-
* this is the whole of what the transform touches.
|
|
97
|
-
*/
|
|
98
|
-
interface RawNode {
|
|
99
|
-
type: string;
|
|
100
|
-
value?: string;
|
|
101
|
-
tagName?: string;
|
|
102
|
-
properties?: Record<string, unknown>;
|
|
103
|
-
children?: RawNode[];
|
|
104
|
-
}
|
|
105
|
-
|
|
106
|
-
/**
|
|
107
|
-
* Promote `<img …>` raw HTML into a real element, and leave every other raw
|
|
108
|
-
* node alone.
|
|
109
|
-
*
|
|
110
|
-
* ## Why not `rehype-raw`
|
|
111
|
-
*
|
|
112
|
-
* `rehype-raw` re-parses ALL raw HTML into elements, which is the correct
|
|
113
|
-
* tool when the markdown is trusted. Folio content is written by users and
|
|
114
|
-
* rendered to other project members, so enabling it would turn every
|
|
115
|
-
* markdown surface in the app into an HTML injection point — against the
|
|
116
|
-
* explicit posture of the rest of this codebase.
|
|
117
|
-
*
|
|
118
|
-
* This plugin is the narrow alternative: exactly one tag, an attribute
|
|
119
|
-
* allowlist, and a `src` scheme check. It exists because MDXEditor
|
|
120
|
-
* serialises a *resized* image as `<img width="600" src="…" />` (an
|
|
121
|
-
* un-resized one stays plain `` markdown), so without it a resize
|
|
122
|
-
* would render as escaped text.
|
|
123
|
-
*
|
|
124
|
-
* React-markdown converts any surviving raw node to a text node, so anything
|
|
125
|
-
* this transform declines keeps the existing, safe behaviour.
|
|
126
|
-
*/
|
|
127
|
-
export const rehypeSafeImg = () => {
|
|
128
|
-
const visit = (node: RawNode): void => {
|
|
129
|
-
const children = node.children;
|
|
130
|
-
if (!children) return;
|
|
131
|
-
for (let i = 0; i < children.length; i++) {
|
|
132
|
-
const child = children[i];
|
|
133
|
-
if (child.type === "raw" && typeof child.value === "string") {
|
|
134
|
-
const attributes = parseSafeImg(child.value);
|
|
135
|
-
if (attributes) {
|
|
136
|
-
children[i] = {
|
|
137
|
-
type: "element",
|
|
138
|
-
tagName: "img",
|
|
139
|
-
properties: attributes,
|
|
140
|
-
children: [],
|
|
141
|
-
};
|
|
142
|
-
}
|
|
143
|
-
continue;
|
|
144
|
-
}
|
|
145
|
-
visit(child);
|
|
146
|
-
}
|
|
147
|
-
};
|
|
148
|
-
|
|
149
|
-
return (tree: RawNode): void => visit(tree);
|
|
150
|
-
};
|