@astryxdesign/cli 0.7.17-canary.g4ea41ce → 0.7.17-canary.g5a3fd39
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +7 -2
- package/api/build/_adapter.d.mts +7 -6
- package/api/build/_adapter.mjs +18 -11
- package/api/build/build.type.mjs +1 -1
- package/api/build/kit/kind.d.mts +6 -0
- package/api/build/kit/kind.mjs +1 -1
- package/api/build/kit/rank.d.mts +7 -1
- package/api/build/kit/rank.mjs +15 -5
- package/api/build/kit/signals.mjs +58 -57
- package/api/build/kit/start.d.mts +2 -1
- package/api/build/kit/start.mjs +62 -9
- package/api/build/kit/words.d.mts +6 -2
- package/api/build/kit/words.mjs +7 -3
- package/api/component/__fixtures__/resolutions/modules.txt +2 -2
- package/api/component/_adapter.d.mts +30 -24
- package/api/component/_adapter.mjs +72 -31
- package/api/component/component.mjs +4 -4
- package/api/component/detail/detail.d.mts +2 -2
- package/api/component/detail/detail.mjs +1 -1
- package/api/component/list/list.d.mts +2 -2
- package/api/component/list/list.mjs +4 -4
- package/api/discover/_adapter.mjs +15 -15
- package/api/docs/_adapter.d.mts +13 -5
- package/api/docs/_adapter.mjs +37 -10
- package/api/doctor/_adapter.d.mts +32 -0
- package/api/doctor/_adapter.mjs +56 -1
- package/api/doctor/doctor.mjs +28 -5
- package/api/doctor/theme-checks.mjs +165 -83
- package/api/error.d.mts +4 -3
- package/api/error.mjs +3 -2
- package/api/hook/_adapter.d.mts +5 -4
- package/api/hook/_adapter.mjs +6 -5
- package/api/icon/_options.d.mts +17 -0
- package/api/icon/_options.mjs +54 -0
- package/api/icon/exportIconIndex.doc.d.mts +10 -0
- package/api/icon/exportIconIndex.doc.mjs +59 -0
- package/api/icon/icon.mjs +11 -34
- package/api/icon/icon.type.d.mts +49 -0
- package/api/icon/icon.type.mjs +24 -0
- package/api/icon/rankIconIndex.doc.d.mts +10 -0
- package/api/icon/rankIconIndex.doc.mjs +79 -0
- package/api/icon/search/icon-index.d.mts +41 -0
- package/api/icon/search/icon-index.mjs +139 -0
- package/api/icon/search/search.d.mts +18 -0
- package/api/icon/search/search.mjs +13 -0
- package/api/index.d.mts +1 -0
- package/api/index.mjs +1 -0
- package/api/search/_adapter.d.mts +8 -5
- package/api/search/_adapter.mjs +14 -10
- package/api/search/_gather-components.d.mts +4 -4
- package/api/search/_gather-components.mjs +4 -3
- package/api/search/_gather-hooks.d.mts +2 -2
- package/api/search/_gather-hooks.mjs +1 -1
- package/api/search/_lexical.mjs +12 -2
- package/api/search/_priority.d.mts +10 -2
- package/api/search/_priority.mjs +37 -7
- package/api/search/_score.d.mts +12 -3
- package/api/search/_score.mjs +6 -3
- package/api/search/_words.mjs +12 -3
- package/api/search/search.d.mts +7 -1
- package/api/search/search.mjs +37 -4
- package/api/swizzle/_adapter.d.mts +7 -5
- package/api/swizzle/_adapter.mjs +7 -3
- package/api/swizzle/copy/copy.mjs +5 -4
- package/api/theme/build/build.d.mts +5 -0
- package/api/theme/build/build.mjs +400 -21
- package/api/theme/build/family.mjs +18 -7
- package/api/theme/build/font-warning.mjs +5 -4
- package/api/theme/build/input-fields.d.mts +21 -6
- package/api/theme/build/input-fields.mjs +104 -13
- package/api/theme/build/typography-values.d.mts +22 -0
- package/api/theme/build/typography-values.mjs +172 -22
- package/api/theme/build/written-values.d.mts +7 -0
- package/api/theme/build/written-values.mjs +57 -8
- package/api/theme/generateTonalPalette.doc.mjs +1 -1
- package/api/theme/palette/generate/generator.d.mts +14 -2
- package/api/theme/palette/generate/generator.mjs +94 -8
- package/api/theme/theme.type.d.mts +21 -4
- package/api/theme/theme.type.mjs +14 -5
- package/api/theme/themePaletteGenerate.doc.mjs +1 -1
- package/api/theme/themeTemplate.doc.mjs +18 -3
- package/api/theme-edit/_adapter.d.mts +1 -1
- package/api/theme-edit/_adapter.mjs +1 -1
- package/api/theme-edit/_catalog.d.mts +10 -4
- package/api/theme-edit/_catalog.mjs +81 -22
- package/api/theme-edit/_check.mjs +402 -88
- package/api/theme-edit/_color.d.mts +11 -2
- package/api/theme-edit/_color.mjs +23 -7
- package/api/theme-edit/_compiler.mjs +11 -3
- package/api/theme-edit/_context.d.mts +87 -6
- package/api/theme-edit/_context.mjs +224 -17
- package/api/theme-edit/_css.mjs +4 -0
- package/api/theme-edit/_edit.mjs +331 -58
- package/api/theme-edit/_how-question.d.mts +11 -0
- package/api/theme-edit/_how-question.mjs +2514 -234
- package/api/theme-edit/_how.mjs +79 -14
- package/api/theme-edit/_missed.mjs +294 -32
- package/api/theme-edit/_normal.d.mts +3 -1
- package/api/theme-edit/_normal.mjs +4 -1
- package/api/theme-edit/_palette.mjs +36 -5
- package/api/theme-edit/_part-words.mjs +20 -2
- package/api/theme-edit/_parts.d.mts +12 -1
- package/api/theme-edit/_parts.mjs +116 -11
- package/api/theme-edit/_preview-app.mjs +40 -2
- package/api/theme-edit/_preview.d.mts +45 -5
- package/api/theme-edit/_preview.mjs +173 -21
- package/api/theme-edit/_settings.d.mts +20 -0
- package/api/theme-edit/_settings.mjs +1033 -94
- package/api/theme-edit/_tables.mjs +2 -2
- package/api/theme-edit/theme-edit.type.d.mts +6 -5
- package/api/theme-edit/theme-edit.type.mjs +8 -8
- package/api/upgrade/_adapter.mjs +13 -2
- package/assets/component-list.generated.json +1 -1
- package/assets/docs/tree/authoring.doc.mjs +1 -0
- package/assets/docs/tree/cli.doc.mjs +1 -0
- package/assets/docs/tree/computer-agent-guide.doc.mjs +1 -1
- package/assets/docs/tree/generate-a-palette.doc.mjs +2 -2
- package/assets/docs/tree/global.doc.mjs +1 -0
- package/assets/docs/tree/single-component.doc.mjs +40 -2
- package/assets/docs/tree/updates.doc.mjs +1 -1
- package/assets/docs/tree/who-answers.doc.mjs +2 -2
- package/assets/docs-routes.generated.json +1 -1
- package/assets/docs.generated.json +2 -2
- package/assets/search-catalog.generated.json +2 -2
- package/assets/self-audit.generated.json +1 -1
- package/assets/templates/blocks/components/Blockquote/BlockquoteShowcase.tsx +1 -1
- package/assets/templates/blocks/components/BreadcrumbItem/BreadcrumbItemShowcase.tsx +4 -4
- package/assets/templates/blocks/components/Breadcrumbs/BreadcrumbsCustomSeparator.tsx +1 -0
- package/assets/templates/blocks/components/Breadcrumbs/BreadcrumbsSupportingVariant.tsx +2 -2
- package/assets/templates/blocks/components/Card/CardElevations.tsx +1 -1
- package/assets/templates/blocks/components/Card/CardWithInnerLayout.tsx +19 -3
- package/assets/templates/blocks/components/Card/ClickableCardWithNestedButton.tsx +11 -1
- package/assets/templates/blocks/components/Card/SelectableCardElevated.tsx +1 -1
- package/assets/templates/blocks/components/Card/SelectableCardMulti.tsx +1 -1
- package/assets/templates/blocks/components/Center/CenterHorizontal.tsx +1 -1
- package/assets/templates/blocks/components/Center/CenterInsideACard.tsx +1 -1
- package/assets/templates/blocks/components/ChatComposer/ChatComposerFullFeatured.tsx +8 -0
- package/assets/templates/blocks/components/ChatComposerDrawer/ChatComposerDrawerWithProgress.tsx +8 -2
- package/assets/templates/blocks/components/ChatLayout/ChatLayoutPanelChat.tsx +1 -0
- package/assets/templates/blocks/components/ChatLayout/ChatLayoutShowcase.tsx +1 -1
- package/assets/templates/blocks/components/ChatMessageBubble/ChatMessageBubbleCustomContent.tsx +9 -1
- package/assets/templates/blocks/components/ChatMessageBubble/ChatMessageBubbleMetadata.tsx +12 -2
- package/assets/templates/blocks/components/ChatMessageMetadata/ChatMessageMetadataFooter.tsx +28 -7
- package/assets/templates/blocks/components/ChatMessageMetadata/ChatMessageMetadataShowcase.tsx +35 -7
- package/assets/templates/blocks/components/Collapsible/CollapsibleShowcase.tsx +1 -1
- package/assets/templates/blocks/components/CommandPaletteGroup/CommandPaletteGroupBasic.tsx +20 -4
- package/assets/templates/blocks/components/CommandPaletteList/CommandPaletteListBasic.tsx +15 -3
- package/assets/templates/blocks/components/CommandPaletteList/CommandPaletteListShowcase.tsx +29 -6
- package/assets/templates/blocks/components/ContextMenu/ContextMenuBasic.tsx +2 -2
- package/assets/templates/blocks/components/ContextMenu/ContextMenuBottomSheet.tsx +1 -1
- package/assets/templates/blocks/components/ContextMenu/ContextMenuShowcase.tsx +2 -2
- package/assets/templates/blocks/components/Divider/DividerFullBleed.tsx +1 -1
- package/assets/templates/blocks/components/Divider/DividerShowcase.tsx +1 -1
- package/assets/templates/blocks/components/Divider/DividerVariants.tsx +1 -1
- package/assets/templates/blocks/components/DropdownMenuGroup/DropdownMenuGroupShowcase.tsx +23 -4
- package/assets/templates/blocks/components/EmptyState/EmptyStateActions.tsx +18 -2
- package/assets/templates/blocks/components/EmptyState/EmptyStateCompact.tsx +20 -2
- package/assets/templates/blocks/components/EmptyState/EmptyStateContainer.tsx +16 -2
- package/assets/templates/blocks/components/EmptyState/EmptyStateShowcase.tsx +11 -1
- package/assets/templates/blocks/components/Heading/HeadingTruncation.tsx +12 -2
- package/assets/templates/blocks/components/InternationalizationProvider/useDirectionHookUsage.tsx +1 -1
- package/assets/templates/blocks/components/LayoutContent/LayoutContentBasic.tsx +1 -1
- package/assets/templates/blocks/components/LayoutContent/LayoutContentShowcase.tsx +1 -1
- package/assets/templates/blocks/components/LayoutFooter/LayoutFooterActions.tsx +17 -3
- package/assets/templates/blocks/components/LayoutFooter/LayoutFooterShowcase.tsx +17 -3
- package/assets/templates/blocks/components/LayoutHeader/LayoutHeaderShowcase.tsx +15 -3
- package/assets/templates/blocks/components/LayoutHeader/LayoutHeaderWithActions.tsx +9 -2
- package/assets/templates/blocks/components/LayoutPanel/LayoutPanelNavigation.tsx +1 -1
- package/assets/templates/blocks/components/LayoutPanel/LayoutPanelShowcase.tsx +1 -1
- package/assets/templates/blocks/components/MoreMenu/MoreMenuBottomSheet.tsx +1 -1
- package/assets/templates/blocks/components/MultiSelector/MultiSelectorGhostToolbar.tsx +14 -2
- package/assets/templates/blocks/components/Outline/OutlineDensity.tsx +2 -0
- package/assets/templates/blocks/components/OverflowList/OverflowListShowcase.tsx +6 -1
- package/assets/templates/blocks/components/Pagination/PaginationVariants.tsx +4 -0
- package/assets/templates/blocks/components/Popover/PopoverHookUsage.tsx +17 -2
- package/assets/templates/blocks/components/SegmentedControl/SegmentedControlFillLayout.tsx +1 -1
- package/assets/templates/blocks/components/Selector/SelectorGhostToolbar.tsx +14 -2
- package/assets/templates/blocks/components/Selector/SelectorOptionDescriptions.tsx +8 -1
- package/assets/templates/blocks/components/SideNav/SideNavWithHeaderMenu.tsx +2 -2
- package/assets/templates/blocks/components/SideNavHeading/SideNavHeadingShowcase.tsx +2 -0
- package/assets/templates/blocks/components/Switch/SwitchWithStatus.tsx +1 -1
- package/assets/templates/blocks/components/TabList/TabListTabsFillLayout.tsx +1 -1
- package/assets/templates/blocks/components/TabList/TabListTabsWithActions.tsx +12 -1
- package/assets/templates/blocks/components/Table/TableBulkActionsTable.tsx +11 -1
- package/assets/templates/blocks/components/Table/TableInCard.tsx +2 -2
- package/assets/templates/blocks/components/Text/TextTruncation.tsx +1 -1
- package/assets/templates/blocks/components/Text/TextWordBreak.tsx +12 -2
- package/assets/templates/blocks/components/Text/TextWrap.tsx +19 -4
- package/assets/templates/blocks/components/TextArea/TextAreaCharacterCount.tsx +1 -1
- package/assets/templates/blocks/components/TextArea/TextAreaShowcase.tsx +1 -1
- package/assets/templates/blocks/components/TextArea/TextAreaStates.tsx +1 -1
- package/assets/templates/blocks/components/TextArea/TextAreaValidation.tsx +1 -1
- package/assets/templates/blocks/components/TextArea/TextAreaWithIcon.tsx +1 -1
- package/assets/templates/blocks/components/TextInput/TextInputStatusVariant.tsx +2 -2
- package/assets/templates/blocks/components/Timestamp/TimestampAutoFormat.tsx +15 -1
- package/assets/templates/blocks/components/Timestamp/TimestampRelativeFormat.tsx +15 -1
- package/assets/templates/blocks/components/Toolbar/ToolbarCardHeader.tsx +8 -0
- package/assets/templates/blocks/components/Toolbar/ToolbarSizes.tsx +12 -1
- package/assets/templates/blocks/components/Toolbar/ToolbarThreeSlot.tsx +18 -3
- package/assets/templates/blocks/components/TopNav/TopNavCenteredNavigation.tsx +6 -0
- package/assets/templates/blocks/components/TopNav/TopNavEnterpriseDashboard.tsx +7 -1
- package/assets/templates/blocks/components/TopNav/TopNavMegaMenu.tsx +2 -2
- package/assets/templates/blocks/components/TopNav/TopNavShowcase.tsx +9 -0
- package/assets/templates/components.generated.json +1 -1
- package/assets/templates/pages/ai-chat/page.tsx +102 -6
- package/assets/templates/pages/canvas-editor/page.tsx +73 -2
- package/assets/templates/pages/centered-hero/page.tsx +10 -4
- package/assets/templates/pages/course-detail/page.tsx +46 -2
- package/assets/templates/pages/dashboard/page.tsx +45 -16
- package/assets/templates/pages/dashboard-cohort-funnel/page.tsx +31 -20
- package/assets/templates/pages/dashboard-comparison/page.tsx +9 -0
- package/assets/templates/pages/dashboard-composition/page.tsx +22 -9
- package/assets/templates/pages/dashboard-progress/page.tsx +27 -15
- package/assets/templates/pages/dashboard-scorecard/page.tsx +9 -0
- package/assets/templates/pages/detail-page/page.tsx +105 -77
- package/assets/templates/pages/documentation/page.tsx +15 -2
- package/assets/templates/pages/documentation-design/page.tsx +7 -34
- package/assets/templates/pages/documentation-technical/page.tsx +76 -12
- package/assets/templates/pages/editor/page.tsx +26 -21
- package/assets/templates/pages/file-explorer/page.tsx +35 -1
- package/assets/templates/pages/form-two-column/page.tsx +2 -3
- package/assets/templates/pages/form-wizard/page.tsx +31 -3
- package/assets/templates/pages/form-wizard-vertical/page.tsx +32 -3
- package/assets/templates/pages/gallery-hero/page.tsx +2 -1
- package/assets/templates/pages/ide/page.tsx +15 -1
- package/assets/templates/pages/incident-console/page.tsx +2 -1
- package/assets/templates/pages/incident-console/template.doc.mjs +1 -1
- package/assets/templates/pages/kanban-board/page.tsx +39 -2
- package/assets/templates/pages/payment-form/page.tsx +77 -39
- package/assets/templates/pages/product-gallery/page.tsx +16 -14
- package/assets/templates/pages/settings/page.tsx +35 -3
- package/assets/templates/pages/settings-dialog/page.tsx +34 -5
- package/assets/templates/pages/settings-sidebar/page.tsx +23 -3
- package/assets/templates/pages/shell-nav/page.tsx +28 -12
- package/assets/templates/pages/shell-side-nav/page.tsx +16 -1
- package/assets/templates/pages/shell-top-nav/page.tsx +27 -1
- package/assets/templates/pages/side-gallery/page.tsx +1 -1
- package/assets/templates/pages/table/page.tsx +2 -1
- package/assets/templates/pages/table/template.doc.mjs +1 -1
- package/assets/templates/pages/table-collapsible/page.tsx +1 -1
- package/assets/templates/pages/table-comparison/page.tsx +1 -1
- package/assets/templates/pages/table-filter/page.tsx +9 -2
- package/assets/templates/pages/table-grouped/page.tsx +16 -6
- package/assets/templates/pages/table-inbox/page.tsx +60 -1
- package/assets/templates/pages/table-page/page.tsx +10 -2
- package/assets/templates/pages/table-tree/page.tsx +95 -13
- package/assets/templates/pages/theme-showcase/page.tsx +107 -11
- package/assets/templates/pages/work-item-detail/page.tsx +88 -74
- package/assets/templates/pages/work-item-detail/template.doc.mjs +0 -1
- package/assets/templates/themes/gothic/gothicPaletteRefs.generated.ts +1 -1
- package/assets/templates/themes/gothic/gothicTheme.ts +5 -0
- package/assets/templates/themes/neutral/neutralTheme.ts +1 -1
- package/assets/templates/themes/y2k/y2kPaletteRefs.generated.ts +1 -1
- package/assets/templates/themes/y2k/y2kTheme.ts +1 -1
- package/authoring/debug/parse.d.mts +1 -1
- package/authoring/doctypes/_schema.d.mts +22 -8
- package/authoring/doctypes/_schema.mjs +31 -0
- package/authoring/doctypes/command/command.doc.mjs +24 -0
- package/authoring/doctypes/command/type.ts +31 -0
- package/authoring/doctypes/component/component.doc.mjs +1 -1
- package/authoring/doctypes/component/type.ts +8 -5
- package/authoring/doctypes/namespace/namespace.doc.mjs +6 -0
- package/authoring/doctypes/namespace/type.ts +4 -0
- package/authoring/doctypes/template/type.ts +0 -7
- package/authoring/index.d.ts +6 -1
- package/authoring/integration/integration.doc.mjs +7 -0
- package/authoring/integration/schema.d.mts +6 -0
- package/authoring/integration/schema.mjs +3 -0
- package/authoring/integration/type.ts +34 -0
- package/clients/cli/build-id.generated.json +1 -1
- package/clients/cli/commands/component.doc.mjs +1 -0
- package/clients/cli/commands/component.mjs +5 -1
- package/clients/cli/commands/docs.doc.mjs +1 -1
- package/clients/cli/commands/experimental/index.mjs +4 -1
- package/clients/cli/commands/experimental/theme.mjs +139 -64
- package/clients/cli/commands/experimental-render.doc.mjs +2 -0
- package/clients/cli/commands/experimental-theme-add.doc.mjs +2 -0
- package/clients/cli/commands/experimental-theme-compile.doc.mjs +1 -0
- package/clients/cli/commands/experimental-theme-editor-how.doc.mjs +1 -0
- package/clients/cli/commands/experimental-theme-editor-new.doc.mjs +3 -1
- package/clients/cli/commands/experimental-theme-editor-set.doc.mjs +3 -2
- package/clients/cli/commands/experimental-theme-editor-show.doc.mjs +2 -1
- package/clients/cli/commands/experimental-theme-editor-undo.doc.mjs +3 -2
- package/clients/cli/commands/experimental-theme-eject.doc.mjs +1 -0
- package/clients/cli/commands/experimental-theme-preview-add.doc.mjs +1 -0
- package/clients/cli/commands/experimental-theme-preview-app.doc.mjs +1 -0
- package/clients/cli/commands/experimental-theme-remove.doc.mjs +2 -0
- package/clients/cli/commands/experimental-theme-targets.doc.mjs +1 -0
- package/clients/cli/commands/experimental-theme-template.doc.mjs +1 -0
- package/clients/cli/commands/experimental-theme-use.doc.mjs +2 -0
- package/clients/cli/commands/gap-report.doc.mjs +1 -0
- package/clients/cli/commands/hook.doc.mjs +1 -1
- package/clients/cli/commands/init.doc.mjs +1 -1
- package/clients/cli/commands/integration-add.doc.mjs +1 -0
- package/clients/cli/commands/manifest.mjs +10 -3
- package/clients/cli/commands/swizzle.doc.mjs +8 -1
- package/clients/cli/commands/swizzle.mjs +13 -6
- package/clients/cli/commands/template.doc.mjs +3 -0
- package/clients/cli/commands/theme-add.doc.mjs +2 -1
- package/clients/cli/commands/theme-build.doc.mjs +2 -1
- package/clients/cli/commands/theme-eject.doc.mjs +1 -1
- package/clients/cli/commands/theme-palette-generate.doc.mjs +3 -2
- package/clients/cli/commands/theme-remove.doc.mjs +2 -1
- package/clients/cli/commands/theme-targets.doc.mjs +1 -0
- package/clients/cli/commands/theme-template.doc.mjs +1 -0
- package/clients/cli/commands/theme-use.doc.mjs +2 -1
- package/clients/cli/commands/theme.doc.mjs +7 -2
- package/clients/cli/commands/theme.mjs +21 -5
- package/clients/cli/index.mjs +167 -59
- package/clients/cli/lib/base-gate.mjs +522 -0
- package/clients/cli/lib/command-path.mjs +26 -0
- package/clients/cli/lib/define-command.mjs +161 -12
- package/clients/cli/lib/json-shim.mjs +34 -31
- package/clients/cli/lib/manifest.d.ts +14 -0
- package/clients/cli/lib/manifest.mjs +78 -22
- package/clients/cli/lib/root-args.mjs +79 -0
- package/clients/cli/lib/stray-option.mjs +21 -8
- package/clients/cli/lib/unknown-command.mjs +27 -6
- package/clients/cli/manifest.generated.json +1 -1
- package/clients/cli/run.mjs +13 -1
- package/foundation/agent-docs/computer-agent-text.mjs +1 -1
- package/foundation/bases/core-docs.d.mts +10 -0
- package/foundation/bases/core-docs.mjs +42 -0
- package/foundation/bases/core.d.mts +11 -0
- package/foundation/bases/core.mjs +32 -0
- package/foundation/bases/requirements.d.mts +128 -0
- package/foundation/bases/requirements.mjs +193 -0
- package/foundation/bases/resolve.d.mts +134 -0
- package/foundation/bases/resolve.mjs +295 -0
- package/foundation/bases/state.d.mts +24 -0
- package/foundation/bases/state.mjs +46 -0
- package/foundation/bases/steps.d.mts +49 -0
- package/foundation/bases/steps.mjs +88 -0
- package/foundation/config/project.d.mts +14 -0
- package/foundation/config/project.mjs +68 -1
- package/foundation/discovery/cli-self-docs.mjs +9 -1
- package/foundation/discovery/command-pointers.d.mts +28 -0
- package/foundation/discovery/command-pointers.mjs +31 -0
- package/foundation/discovery/component-discovery.d.mts +9 -8
- package/foundation/discovery/component-discovery.mjs +9 -4
- package/foundation/discovery/docs-discovery.d.mts +13 -5
- package/foundation/discovery/docs-discovery.mjs +25 -6
- package/foundation/discovery/hook-discovery.d.mts +6 -6
- package/foundation/discovery/hook-discovery.mjs +6 -4
- package/foundation/discovery/template-adapter.mjs +5 -0
- package/foundation/discovery/template-ids.d.mts +1 -1
- package/foundation/discovery/template-ids.mjs +5 -1
- package/foundation/discovery/theme-discovery.mjs +3 -0
- package/foundation/discovery/theme-imports.mjs +19 -1
- package/foundation/doc-compiler/tree.d.mts +4 -2
- package/foundation/doc-compiler/tree.mjs +46 -1
- package/foundation/env/package-manager.d.mts +7 -0
- package/foundation/env/package-manager.mjs +21 -0
- package/foundation/fonts/font-stylesheet.d.mts +8 -0
- package/foundation/fonts/font-stylesheet.mjs +26 -2
- package/foundation/fs/gather-cache.mjs +44 -13
- package/foundation/fs/own-modules.d.mts +29 -0
- package/foundation/fs/own-modules.mjs +57 -0
- package/foundation/fs/paths.d.mts +30 -2
- package/foundation/fs/paths.mjs +49 -2
- package/foundation/integrations/integrations.d.mts +4 -0
- package/foundation/integrations/integrations.mjs +6 -1
- package/foundation/release/choose.d.mts +7 -0
- package/foundation/release/choose.mjs +16 -2
- package/foundation/release/notices.d.mts +26 -0
- package/foundation/release/notices.mjs +48 -19
- package/foundation/release/project.d.mts +3 -2
- package/foundation/release/project.mjs +4 -5
- package/foundation/release/run-context.d.mts +7 -2
- package/foundation/release/run-context.mjs +6 -2
- package/foundation/render/css-cut.mjs +86 -6
- package/foundation/render/cut-short.d.mts +35 -0
- package/foundation/render/cut-short.mjs +124 -0
- package/foundation/render/font-probe.d.mts +27 -0
- package/foundation/render/font-probe.mjs +77 -0
- package/foundation/render/layers.d.mts +1 -9
- package/foundation/render/layers.mjs +2 -111
- package/foundation/render/page-worker.mjs +83 -6
- package/foundation/render/picture-chrome.mjs +24 -2
- package/foundation/render/picture-playwright.mjs +22 -2
- package/foundation/render/picture-window.d.mts +20 -4
- package/foundation/render/picture-window.mjs +137 -4
- package/foundation/response/base.d.ts +25 -0
- package/foundation/response/error-codes.d.mts +4 -1
- package/foundation/response/error-codes.d.ts +4 -1
- package/foundation/response/error-codes.doc.mjs +17 -0
- package/foundation/response/error-codes.mjs +21 -0
- package/foundation/response/json.d.mts +3 -1
- package/foundation/response/json.mjs +7 -2
- package/foundation/response/response-types.doc.mjs +2 -2
- package/foundation/suggest/name-index.d.mts +2 -1
- package/foundation/suggest/name-index.mjs +1 -1
- package/foundation/suggest/other-command.d.mts +4 -1
- package/foundation/suggest/other-command.mjs +23 -6
- package/foundation/text/string-utils.d.mts +7 -2
- package/foundation/text/string-utils.mjs +24 -10
- package/package.json +6 -6
- package/assets/templates/pages/access-denied/page.tsx +0 -101
- package/assets/templates/pages/access-denied/template.doc.mjs +0 -24
- package/assets/templates/pages/error-page/page.tsx +0 -130
- package/assets/templates/pages/error-page/template.doc.mjs +0 -22
- package/assets/templates/pages/not-found/page.tsx +0 -124
- package/assets/templates/pages/not-found/template.doc.mjs +0 -30
- package/assets/templates/pages/review-workspace/page.tsx +0 -551
- package/assets/templates/pages/review-workspace/template.doc.mjs +0 -31
- package/assets/templates/pages/run-console/page.tsx +0 -945
- package/assets/templates/pages/run-console/template.doc.mjs +0 -27
- package/assets/templates/pages/welcome-portal/page.tsx +0 -538
- package/assets/templates/pages/welcome-portal/template.doc.mjs +0 -38
|
@@ -11,10 +11,12 @@ import {
|
|
|
11
11
|
} from '@astryxdesign/core/Layout';
|
|
12
12
|
import {Center} from '@astryxdesign/core/Center';
|
|
13
13
|
import {Button} from '@astryxdesign/core/Button';
|
|
14
|
+
import {useToast} from '@astryxdesign/core/Toast';
|
|
14
15
|
|
|
15
16
|
export default function LayoutFooterActions() {
|
|
17
|
+
const showToast = useToast();
|
|
16
18
|
return (
|
|
17
|
-
<Center width={400}>
|
|
19
|
+
<Center width={400} maxWidth="100%">
|
|
18
20
|
<Layout
|
|
19
21
|
style={{width: '100%'}}
|
|
20
22
|
height="fill"
|
|
@@ -26,10 +28,22 @@ export default function LayoutFooterActions() {
|
|
|
26
28
|
footer={
|
|
27
29
|
<LayoutFooter hasDivider>
|
|
28
30
|
<HStack gap={2} hAlign="end">
|
|
29
|
-
<Button
|
|
31
|
+
<Button
|
|
32
|
+
onClick={() =>
|
|
33
|
+
showToast({
|
|
34
|
+
body: 'Demo: your changes would be discarded here',
|
|
35
|
+
})
|
|
36
|
+
}
|
|
37
|
+
label="Cancel"
|
|
38
|
+
variant="secondary">
|
|
30
39
|
Cancel
|
|
31
40
|
</Button>
|
|
32
|
-
<Button
|
|
41
|
+
<Button
|
|
42
|
+
onClick={() =>
|
|
43
|
+
showToast({body: 'Demo: your changes would be saved here'})
|
|
44
|
+
}
|
|
45
|
+
label="Save"
|
|
46
|
+
variant="primary">
|
|
33
47
|
Save
|
|
34
48
|
</Button>
|
|
35
49
|
</HStack>
|
|
@@ -13,10 +13,12 @@ import {
|
|
|
13
13
|
} from '@astryxdesign/core/Layout';
|
|
14
14
|
import {Center} from '@astryxdesign/core/Center';
|
|
15
15
|
import {Button} from '@astryxdesign/core/Button';
|
|
16
|
+
import {useToast} from '@astryxdesign/core/Toast';
|
|
16
17
|
|
|
17
18
|
export default function LayoutFooterShowcase() {
|
|
19
|
+
const showToast = useToast();
|
|
18
20
|
return (
|
|
19
|
-
<Center width={400}>
|
|
21
|
+
<Center width={400} maxWidth="100%">
|
|
20
22
|
<Layout
|
|
21
23
|
style={{width: '100%'}}
|
|
22
24
|
height="fill"
|
|
@@ -38,10 +40,22 @@ export default function LayoutFooterShowcase() {
|
|
|
38
40
|
footer={
|
|
39
41
|
<LayoutFooter hasDivider>
|
|
40
42
|
<HStack gap={2} hAlign="end">
|
|
41
|
-
<Button
|
|
43
|
+
<Button
|
|
44
|
+
onClick={() =>
|
|
45
|
+
showToast({
|
|
46
|
+
body: 'Demo: your changes would be discarded here',
|
|
47
|
+
})
|
|
48
|
+
}
|
|
49
|
+
label="Cancel"
|
|
50
|
+
variant="secondary">
|
|
42
51
|
Cancel
|
|
43
52
|
</Button>
|
|
44
|
-
<Button
|
|
53
|
+
<Button
|
|
54
|
+
onClick={() =>
|
|
55
|
+
showToast({body: 'Demo: your changes would be saved here'})
|
|
56
|
+
}
|
|
57
|
+
label="Save"
|
|
58
|
+
variant="primary">
|
|
45
59
|
Save
|
|
46
60
|
</Button>
|
|
47
61
|
</HStack>
|
|
@@ -14,10 +14,12 @@ import {
|
|
|
14
14
|
import {Center} from '@astryxdesign/core/Center';
|
|
15
15
|
import {Heading} from '@astryxdesign/core/Text';
|
|
16
16
|
import {Button} from '@astryxdesign/core/Button';
|
|
17
|
+
import {useToast} from '@astryxdesign/core/Toast';
|
|
17
18
|
|
|
18
19
|
export default function LayoutHeaderShowcase() {
|
|
20
|
+
const showToast = useToast();
|
|
19
21
|
return (
|
|
20
|
-
<Center width={400}>
|
|
22
|
+
<Center width={400} maxWidth="100%">
|
|
21
23
|
<Layout
|
|
22
24
|
style={{width: '100%'}}
|
|
23
25
|
height="fill"
|
|
@@ -26,10 +28,20 @@ export default function LayoutHeaderShowcase() {
|
|
|
26
28
|
<HStack gap={2} vAlign="center" hAlign="between">
|
|
27
29
|
<Heading level={4}>Dashboard</Heading>
|
|
28
30
|
<HStack gap={2}>
|
|
29
|
-
<Button
|
|
31
|
+
<Button
|
|
32
|
+
onClick={() =>
|
|
33
|
+
showToast({body: 'Demo: an export would start here'})
|
|
34
|
+
}
|
|
35
|
+
label="Export"
|
|
36
|
+
variant="secondary">
|
|
30
37
|
Export
|
|
31
38
|
</Button>
|
|
32
|
-
<Button
|
|
39
|
+
<Button
|
|
40
|
+
onClick={() =>
|
|
41
|
+
showToast({body: 'Demo: a new item form would open here'})
|
|
42
|
+
}
|
|
43
|
+
label="New Item"
|
|
44
|
+
variant="primary">
|
|
33
45
|
New Item
|
|
34
46
|
</Button>
|
|
35
47
|
</HStack>
|
|
@@ -12,10 +12,12 @@ import {
|
|
|
12
12
|
import {Center} from '@astryxdesign/core/Center';
|
|
13
13
|
import {Heading} from '@astryxdesign/core/Text';
|
|
14
14
|
import {Button} from '@astryxdesign/core/Button';
|
|
15
|
+
import {useToast} from '@astryxdesign/core/Toast';
|
|
15
16
|
|
|
16
17
|
export default function LayoutHeaderWithActions() {
|
|
18
|
+
const showToast = useToast();
|
|
17
19
|
return (
|
|
18
|
-
<Center width={400}>
|
|
20
|
+
<Center width={400} maxWidth="100%">
|
|
19
21
|
<Layout
|
|
20
22
|
style={{width: '100%'}}
|
|
21
23
|
height="fill"
|
|
@@ -23,7 +25,12 @@ export default function LayoutHeaderWithActions() {
|
|
|
23
25
|
<LayoutHeader hasDivider>
|
|
24
26
|
<HStack gap={2} vAlign="center" hAlign="between">
|
|
25
27
|
<Heading level={4}>Dashboard</Heading>
|
|
26
|
-
<Button
|
|
28
|
+
<Button
|
|
29
|
+
onClick={() =>
|
|
30
|
+
showToast({body: 'Demo: a new item form would open here'})
|
|
31
|
+
}
|
|
32
|
+
label="New Item"
|
|
33
|
+
variant="primary">
|
|
27
34
|
New Item
|
|
28
35
|
</Button>
|
|
29
36
|
</HStack>
|
|
@@ -20,7 +20,7 @@ export default function MoreMenuBottomSheet() {
|
|
|
20
20
|
gap: '16px',
|
|
21
21
|
width: 'min(100%, 360px)',
|
|
22
22
|
padding: '16px',
|
|
23
|
-
border: '1px solid
|
|
23
|
+
border: '1px solid var(--color-border-emphasized)',
|
|
24
24
|
borderRadius: '12px',
|
|
25
25
|
}}>
|
|
26
26
|
<div style={{display: 'flex', flexDirection: 'column', gap: '4px'}}>
|
|
@@ -6,14 +6,22 @@ import {useState} from 'react';
|
|
|
6
6
|
import {Button} from '@astryxdesign/core/Button';
|
|
7
7
|
import {HStack} from '@astryxdesign/core/Layout';
|
|
8
8
|
import {MultiSelector} from '@astryxdesign/core/MultiSelector';
|
|
9
|
+
import {useToast} from '@astryxdesign/core/Toast';
|
|
9
10
|
|
|
10
11
|
export default function MultiSelectorGhostToolbar() {
|
|
12
|
+
const showToast = useToast();
|
|
11
13
|
const [columns, setColumns] = useState<string[]>(['Name', 'Email']);
|
|
12
14
|
const [filters, setFilters] = useState<string[]>(['Active']);
|
|
13
15
|
|
|
14
16
|
return (
|
|
15
17
|
<HStack align="center" gap={2}>
|
|
16
|
-
<Button
|
|
18
|
+
<Button
|
|
19
|
+
onClick={() =>
|
|
20
|
+
showToast({body: 'Demo: the data would be refreshed here'})
|
|
21
|
+
}
|
|
22
|
+
label="Refresh"
|
|
23
|
+
variant="ghost"
|
|
24
|
+
/>
|
|
17
25
|
<MultiSelector
|
|
18
26
|
label="Columns"
|
|
19
27
|
isLabelHidden
|
|
@@ -36,7 +44,11 @@ export default function MultiSelectorGhostToolbar() {
|
|
|
36
44
|
status={{type: 'warning', message: 'Some filters hide archived rows'}}
|
|
37
45
|
statusVariant="tooltip"
|
|
38
46
|
/>
|
|
39
|
-
<Button
|
|
47
|
+
<Button
|
|
48
|
+
onClick={() => showToast({body: 'Demo: an export would start here'})}
|
|
49
|
+
label="Export"
|
|
50
|
+
variant="ghost"
|
|
51
|
+
/>
|
|
40
52
|
</HStack>
|
|
41
53
|
);
|
|
42
54
|
}
|
|
@@ -23,6 +23,7 @@ export default function OutlineDensity() {
|
|
|
23
23
|
Default
|
|
24
24
|
</Text>
|
|
25
25
|
<Outline
|
|
26
|
+
label="Table of contents, default density"
|
|
26
27
|
items={items}
|
|
27
28
|
density="default"
|
|
28
29
|
activeId="density-configuration"
|
|
@@ -33,6 +34,7 @@ export default function OutlineDensity() {
|
|
|
33
34
|
Compact
|
|
34
35
|
</Text>
|
|
35
36
|
<Outline
|
|
37
|
+
label="Table of contents, compact density"
|
|
36
38
|
items={items}
|
|
37
39
|
density="compact"
|
|
38
40
|
activeId="density-configuration"
|
|
@@ -7,7 +7,12 @@ import {Button} from '@astryxdesign/core/Button';
|
|
|
7
7
|
|
|
8
8
|
export default function OverflowListShowcase() {
|
|
9
9
|
return (
|
|
10
|
-
<div
|
|
10
|
+
<div
|
|
11
|
+
style={{
|
|
12
|
+
maxWidth: 400,
|
|
13
|
+
border: '1px dashed var(--color-border)',
|
|
14
|
+
padding: 8,
|
|
15
|
+
}}>
|
|
11
16
|
<OverflowList
|
|
12
17
|
gap={2}
|
|
13
18
|
overflowRenderer={overflowItems => (
|
|
@@ -15,18 +15,21 @@ export default function PaginationVariants() {
|
|
|
15
15
|
return (
|
|
16
16
|
<Stack direction="vertical" gap={5} hAlign="center" style={{width: '100%'}}>
|
|
17
17
|
<Pagination
|
|
18
|
+
label="Dots pagination"
|
|
18
19
|
page={dotsPage}
|
|
19
20
|
onChange={setDotsPage}
|
|
20
21
|
totalPages={8}
|
|
21
22
|
variant="dots"
|
|
22
23
|
/>
|
|
23
24
|
<Pagination
|
|
25
|
+
label="Compact pagination"
|
|
24
26
|
page={compactPage}
|
|
25
27
|
onChange={setCompactPage}
|
|
26
28
|
totalPages={10}
|
|
27
29
|
variant="compact"
|
|
28
30
|
/>
|
|
29
31
|
<Pagination
|
|
32
|
+
label="Count pagination"
|
|
30
33
|
page={countPage}
|
|
31
34
|
onChange={setCountPage}
|
|
32
35
|
totalItems={200}
|
|
@@ -34,6 +37,7 @@ export default function PaginationVariants() {
|
|
|
34
37
|
variant="count"
|
|
35
38
|
/>
|
|
36
39
|
<Pagination
|
|
40
|
+
label="Pages pagination"
|
|
37
41
|
page={pagesPage}
|
|
38
42
|
onChange={setPagesPage}
|
|
39
43
|
totalItems={200}
|
|
@@ -8,8 +8,10 @@ import {Card} from '@astryxdesign/core/Card';
|
|
|
8
8
|
import {Center} from '@astryxdesign/core/Center';
|
|
9
9
|
import {VStack} from '@astryxdesign/core/Layout';
|
|
10
10
|
import {Text} from '@astryxdesign/core/Text';
|
|
11
|
+
import {useToast} from '@astryxdesign/core/Toast';
|
|
11
12
|
|
|
12
13
|
export default function PopoverHookUsage() {
|
|
14
|
+
const showToast = useToast();
|
|
13
15
|
const popover = usePopover({dialogLabel: 'Quick actions'});
|
|
14
16
|
|
|
15
17
|
return (
|
|
@@ -26,8 +28,21 @@ export default function PopoverHookUsage() {
|
|
|
26
28
|
<Text type="body" weight="bold">
|
|
27
29
|
Quick actions
|
|
28
30
|
</Text>
|
|
29
|
-
<Button
|
|
30
|
-
|
|
31
|
+
<Button
|
|
32
|
+
onClick={() =>
|
|
33
|
+
showToast({body: 'Demo: a new task form would open here'})
|
|
34
|
+
}
|
|
35
|
+
label="Create task"
|
|
36
|
+
size="sm"
|
|
37
|
+
/>
|
|
38
|
+
<Button
|
|
39
|
+
onClick={() =>
|
|
40
|
+
showToast({body: 'Demo: share options would open here'})
|
|
41
|
+
}
|
|
42
|
+
label="Share report"
|
|
43
|
+
variant="secondary"
|
|
44
|
+
size="sm"
|
|
45
|
+
/>
|
|
31
46
|
</VStack>
|
|
32
47
|
</Card>,
|
|
33
48
|
{placement: 'below', alignment: 'center'},
|
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
export default function SegmentedControlFillLayout() {
|
|
12
12
|
const [value, setValue] = useState('weekly');
|
|
13
13
|
return (
|
|
14
|
-
<div style={{width: 400}}>
|
|
14
|
+
<div style={{width: 400, maxWidth: '100%'}}>
|
|
15
15
|
<SegmentedControl
|
|
16
16
|
value={value}
|
|
17
17
|
onChange={setValue}
|
|
@@ -6,14 +6,22 @@ import {useState} from 'react';
|
|
|
6
6
|
import {Button} from '@astryxdesign/core/Button';
|
|
7
7
|
import {HStack} from '@astryxdesign/core/Layout';
|
|
8
8
|
import {Selector} from '@astryxdesign/core/Selector';
|
|
9
|
+
import {useToast} from '@astryxdesign/core/Toast';
|
|
9
10
|
|
|
10
11
|
export default function SelectorGhostToolbar() {
|
|
12
|
+
const showToast = useToast();
|
|
11
13
|
const [view, setView] = useState<string | undefined>('week');
|
|
12
14
|
const [density, setDensity] = useState<string | undefined>('comfortable');
|
|
13
15
|
|
|
14
16
|
return (
|
|
15
17
|
<HStack align="center" gap={2}>
|
|
16
|
-
<Button
|
|
18
|
+
<Button
|
|
19
|
+
onClick={() =>
|
|
20
|
+
showToast({body: 'Demo: the calendar would jump to today here'})
|
|
21
|
+
}
|
|
22
|
+
label="Today"
|
|
23
|
+
variant="ghost"
|
|
24
|
+
/>
|
|
17
25
|
<Selector
|
|
18
26
|
label="Calendar view"
|
|
19
27
|
isLabelHidden
|
|
@@ -40,7 +48,11 @@ export default function SelectorGhostToolbar() {
|
|
|
40
48
|
status={{type: 'warning', message: 'This setting affects all users'}}
|
|
41
49
|
statusVariant="tooltip"
|
|
42
50
|
/>
|
|
43
|
-
<Button
|
|
51
|
+
<Button
|
|
52
|
+
onClick={() => showToast({body: 'Demo: an export would start here'})}
|
|
53
|
+
label="Export"
|
|
54
|
+
variant="ghost"
|
|
55
|
+
/>
|
|
44
56
|
</HStack>
|
|
45
57
|
);
|
|
46
58
|
}
|
|
@@ -8,6 +8,7 @@ import {InputGroup} from '@astryxdesign/core/InputGroup';
|
|
|
8
8
|
import {Button} from '@astryxdesign/core/Button';
|
|
9
9
|
import {Stack} from '@astryxdesign/core/Layout';
|
|
10
10
|
import {LockClosedIcon, GlobeAltIcon} from '@heroicons/react/24/outline';
|
|
11
|
+
import {useToast} from '@astryxdesign/core/Toast';
|
|
11
12
|
|
|
12
13
|
const VISIBILITY = [
|
|
13
14
|
{
|
|
@@ -25,6 +26,7 @@ const VISIBILITY = [
|
|
|
25
26
|
];
|
|
26
27
|
|
|
27
28
|
export default function SelectorOptionDescriptions() {
|
|
29
|
+
const showToast = useToast();
|
|
28
30
|
const [condensed, setCondensed] = useState<string | undefined>('private');
|
|
29
31
|
const [full, setFull] = useState<string | undefined>('private');
|
|
30
32
|
const [grouped, setGrouped] = useState<string | undefined>('private');
|
|
@@ -69,7 +71,12 @@ export default function SelectorOptionDescriptions() {
|
|
|
69
71
|
/>
|
|
70
72
|
)}
|
|
71
73
|
/>
|
|
72
|
-
<Button
|
|
74
|
+
<Button
|
|
75
|
+
onClick={() =>
|
|
76
|
+
showToast({body: 'Demo: your choice would be saved here'})
|
|
77
|
+
}
|
|
78
|
+
label="Save"
|
|
79
|
+
/>
|
|
73
80
|
</InputGroup>
|
|
74
81
|
</Stack>
|
|
75
82
|
);
|
|
@@ -87,8 +87,8 @@ export default function SideNavWithHeaderMenu() {
|
|
|
87
87
|
/>
|
|
88
88
|
}>
|
|
89
89
|
<SideNavSection title="Navigation">
|
|
90
|
-
<SideNavItem label="Dashboard" icon={HomeIcon} isSelected />
|
|
91
|
-
<SideNavItem label="Settings" icon={CogIcon} />
|
|
90
|
+
<SideNavItem href={'#'} label="Dashboard" icon={HomeIcon} isSelected />
|
|
91
|
+
<SideNavItem href={'#'} label="Settings" icon={CogIcon} />
|
|
92
92
|
</SideNavSection>
|
|
93
93
|
</SideNav>
|
|
94
94
|
);
|
|
@@ -27,6 +27,7 @@ export default function SideNavHeadingShowcase() {
|
|
|
27
27
|
return (
|
|
28
28
|
<HStack gap={6}>
|
|
29
29
|
<SideNav
|
|
30
|
+
aria-label="Side navigation with a heading"
|
|
30
31
|
header={
|
|
31
32
|
<SideNavHeading
|
|
32
33
|
heading="Analytics"
|
|
@@ -37,6 +38,7 @@ export default function SideNavHeadingShowcase() {
|
|
|
37
38
|
{null}
|
|
38
39
|
</SideNav>
|
|
39
40
|
<SideNav
|
|
41
|
+
aria-label="Side navigation with a heading, superheading and subheading"
|
|
40
42
|
header={
|
|
41
43
|
<SideNavHeading
|
|
42
44
|
heading="Analytics"
|
|
@@ -13,7 +13,7 @@ export default function SwitchWithStatus() {
|
|
|
13
13
|
const [twoFactor, setTwoFactor] = useState(true);
|
|
14
14
|
|
|
15
15
|
return (
|
|
16
|
-
<Center width={400}>
|
|
16
|
+
<Center width={400} maxWidth="100%">
|
|
17
17
|
<VStack gap={6} width="100%" style={{maxWidth: 400}}>
|
|
18
18
|
<Switch
|
|
19
19
|
label="Accept terms and conditions"
|
|
@@ -8,7 +8,7 @@ import {TabList, Tab} from '@astryxdesign/core/TabList';
|
|
|
8
8
|
export default function TabListTabsFillLayout() {
|
|
9
9
|
const [value, setValue] = useState('home');
|
|
10
10
|
return (
|
|
11
|
-
<div style={{width: 500}}>
|
|
11
|
+
<div style={{width: 500, maxWidth: '100%'}}>
|
|
12
12
|
<TabList value={value} onChange={setValue} layout="fill" hasDivider>
|
|
13
13
|
<Tab value="home" label="Home" />
|
|
14
14
|
<Tab value="projects" label="Projects" />
|
|
@@ -5,6 +5,7 @@
|
|
|
5
5
|
import {useState} from 'react';
|
|
6
6
|
import {TabList, Tab} from '@astryxdesign/core/TabList';
|
|
7
7
|
import {Button} from '@astryxdesign/core/Button';
|
|
8
|
+
import {useToast} from '@astryxdesign/core/Toast';
|
|
8
9
|
|
|
9
10
|
const FilterIcon = (
|
|
10
11
|
<svg
|
|
@@ -39,6 +40,7 @@ const PlusIcon = (
|
|
|
39
40
|
);
|
|
40
41
|
|
|
41
42
|
export default function TabListTabsWithActions() {
|
|
43
|
+
const showToast = useToast();
|
|
42
44
|
const [value, setValue] = useState('all');
|
|
43
45
|
return (
|
|
44
46
|
<TabList value={value} onChange={setValue} size="lg" hasDivider>
|
|
@@ -53,13 +55,22 @@ export default function TabListTabsWithActions() {
|
|
|
53
55
|
gap: 4,
|
|
54
56
|
}}>
|
|
55
57
|
<Button
|
|
58
|
+
onClick={() => showToast({body: 'Demo: filters would open here'})}
|
|
56
59
|
label="Filter"
|
|
57
60
|
variant="ghost"
|
|
58
61
|
size="lg"
|
|
59
62
|
icon={FilterIcon}
|
|
60
63
|
isIconOnly
|
|
61
64
|
/>
|
|
62
|
-
<Button
|
|
65
|
+
<Button
|
|
66
|
+
onClick={() =>
|
|
67
|
+
showToast({body: 'Demo: a new item form would open here'})
|
|
68
|
+
}
|
|
69
|
+
label="New item"
|
|
70
|
+
variant="primary"
|
|
71
|
+
size="lg"
|
|
72
|
+
icon={PlusIcon}
|
|
73
|
+
/>
|
|
63
74
|
</div>
|
|
64
75
|
</TabList>
|
|
65
76
|
);
|
|
@@ -12,6 +12,7 @@ import {
|
|
|
12
12
|
proportional,
|
|
13
13
|
} from '@astryxdesign/core/Table';
|
|
14
14
|
import type {TableColumn} from '@astryxdesign/core/Table';
|
|
15
|
+
import {useToast} from '@astryxdesign/core/Toast';
|
|
15
16
|
|
|
16
17
|
interface User extends Record<string, unknown> {
|
|
17
18
|
id: string;
|
|
@@ -35,6 +36,7 @@ const columns: TableColumn<User>[] = [
|
|
|
35
36
|
];
|
|
36
37
|
|
|
37
38
|
export default function TableBulkActionsTable() {
|
|
39
|
+
const showToast = useToast();
|
|
38
40
|
const [selectedKeys, setSelectedKeys] = useState<Set<string>>(new Set());
|
|
39
41
|
|
|
40
42
|
const {selectionConfig, selectionState} = useTableSelectionState<User>({
|
|
@@ -51,7 +53,15 @@ export default function TableBulkActionsTable() {
|
|
|
51
53
|
selection={selectionState}
|
|
52
54
|
startContent={
|
|
53
55
|
<>
|
|
54
|
-
<Button
|
|
56
|
+
<Button
|
|
57
|
+
label="Export"
|
|
58
|
+
variant="ghost"
|
|
59
|
+
onClick={() =>
|
|
60
|
+
showToast({
|
|
61
|
+
body: 'Demo: the selected rows would be exported here',
|
|
62
|
+
})
|
|
63
|
+
}
|
|
64
|
+
/>
|
|
55
65
|
<Button
|
|
56
66
|
label="Delete"
|
|
57
67
|
variant="ghost"
|
|
@@ -36,10 +36,10 @@ const columns: TableColumn<User>[] = [
|
|
|
36
36
|
export default function TableInCard() {
|
|
37
37
|
return (
|
|
38
38
|
<Card width={520}>
|
|
39
|
-
<VStack
|
|
39
|
+
<VStack paddingBlockEnd={3}>
|
|
40
40
|
<Heading level={3}>Team Members</Heading>
|
|
41
|
-
<Table data={users} columns={columns} idKey="id" hasHover />
|
|
42
41
|
</VStack>
|
|
42
|
+
<Table data={users} columns={columns} idKey="id" hasHover />
|
|
43
43
|
</Card>
|
|
44
44
|
);
|
|
45
45
|
}
|
|
@@ -27,7 +27,7 @@ export default function TextTruncation() {
|
|
|
27
27
|
<Text type="supporting" color="secondary" display="block">
|
|
28
28
|
{label}
|
|
29
29
|
</Text>
|
|
30
|
-
<div style={{border: '1px solid
|
|
30
|
+
<div style={{border: '1px solid var(--color-border)', padding: 8}}>
|
|
31
31
|
<Text type="body" maxLines={maxLines}>
|
|
32
32
|
{LONG_TEXT}
|
|
33
33
|
</Text>
|
|
@@ -17,7 +17,12 @@ export default function TextWordBreak() {
|
|
|
17
17
|
<Text type="label" display="block">
|
|
18
18
|
Break-word (default for multi-line)
|
|
19
19
|
</Text>
|
|
20
|
-
<div
|
|
20
|
+
<div
|
|
21
|
+
style={{
|
|
22
|
+
width: 200,
|
|
23
|
+
border: '1px solid var(--color-border)',
|
|
24
|
+
padding: 8,
|
|
25
|
+
}}>
|
|
21
26
|
<Text type="body" maxLines={2} wordBreak="break-word">
|
|
22
27
|
This is a verylongunbreakableword for a break-word example
|
|
23
28
|
</Text>
|
|
@@ -27,7 +32,12 @@ export default function TextWordBreak() {
|
|
|
27
32
|
<Text type="label" display="block">
|
|
28
33
|
Break-all (default for single-line)
|
|
29
34
|
</Text>
|
|
30
|
-
<div
|
|
35
|
+
<div
|
|
36
|
+
style={{
|
|
37
|
+
width: 200,
|
|
38
|
+
border: '1px solid var(--color-border)',
|
|
39
|
+
padding: 8,
|
|
40
|
+
}}>
|
|
31
41
|
<Text type="body" maxLines={2} wordBreak="break-all">
|
|
32
42
|
Breaks anywhere: abcdefghijklmnopqrstuvwxyz0123456789
|
|
33
43
|
</Text>
|
|
@@ -17,7 +17,12 @@ export default function TextWrap() {
|
|
|
17
17
|
<Text type="label" display="block">
|
|
18
18
|
Wrap (default)
|
|
19
19
|
</Text>
|
|
20
|
-
<div
|
|
20
|
+
<div
|
|
21
|
+
style={{
|
|
22
|
+
border: '1px solid var(--color-border)',
|
|
23
|
+
padding: 8,
|
|
24
|
+
width: 200,
|
|
25
|
+
}}>
|
|
21
26
|
<Text type="body" textWrap="wrap">
|
|
22
27
|
This text wraps normally at word boundaries when it reaches the
|
|
23
28
|
edge.
|
|
@@ -30,7 +35,7 @@ export default function TextWrap() {
|
|
|
30
35
|
</Text>
|
|
31
36
|
<div
|
|
32
37
|
style={{
|
|
33
|
-
border: '1px solid
|
|
38
|
+
border: '1px solid var(--color-border)',
|
|
34
39
|
padding: 8,
|
|
35
40
|
width: 200,
|
|
36
41
|
overflow: 'hidden',
|
|
@@ -44,7 +49,12 @@ export default function TextWrap() {
|
|
|
44
49
|
<Text type="label" display="block">
|
|
45
50
|
Balance
|
|
46
51
|
</Text>
|
|
47
|
-
<div
|
|
52
|
+
<div
|
|
53
|
+
style={{
|
|
54
|
+
border: '1px solid var(--color-border)',
|
|
55
|
+
padding: 8,
|
|
56
|
+
width: 200,
|
|
57
|
+
}}>
|
|
48
58
|
<Text type="body" textWrap="balance">
|
|
49
59
|
This text is balanced for better visual appearance across lines.
|
|
50
60
|
</Text>
|
|
@@ -54,7 +64,12 @@ export default function TextWrap() {
|
|
|
54
64
|
<Text type="label" display="block">
|
|
55
65
|
Pretty
|
|
56
66
|
</Text>
|
|
57
|
-
<div
|
|
67
|
+
<div
|
|
68
|
+
style={{
|
|
69
|
+
border: '1px solid var(--color-border)',
|
|
70
|
+
padding: 8,
|
|
71
|
+
width: 200,
|
|
72
|
+
}}>
|
|
58
73
|
<Text type="body" textWrap="pretty">
|
|
59
74
|
This text uses pretty wrap to avoid orphans at the end of
|
|
60
75
|
paragraphs.
|