@ankhorage/zora 1.3.0 → 1.4.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +12 -0
- package/README.md +208 -0
- package/dist/components/app-bar/meta.d.ts +9 -0
- package/dist/components/app-bar/meta.d.ts.map +1 -0
- package/dist/components/app-bar/meta.js +9 -0
- package/dist/components/app-bar/meta.js.map +1 -0
- package/dist/components/avatar/meta.d.ts +9 -0
- package/dist/components/avatar/meta.d.ts.map +1 -0
- package/dist/components/avatar/meta.js +9 -0
- package/dist/components/avatar/meta.js.map +1 -0
- package/dist/components/avatar-group/meta.d.ts +9 -0
- package/dist/components/avatar-group/meta.d.ts.map +1 -0
- package/dist/components/avatar-group/meta.js +9 -0
- package/dist/components/avatar-group/meta.js.map +1 -0
- package/dist/components/badge/meta.d.ts +9 -0
- package/dist/components/badge/meta.d.ts.map +1 -0
- package/dist/components/badge/meta.js +9 -0
- package/dist/components/badge/meta.js.map +1 -0
- package/dist/components/button/meta.d.ts +45 -0
- package/dist/components/button/meta.d.ts.map +1 -0
- package/dist/components/button/meta.js +45 -0
- package/dist/components/button/meta.js.map +1 -0
- package/dist/components/card/meta.d.ts +44 -0
- package/dist/components/card/meta.d.ts.map +1 -0
- package/dist/components/card/meta.js +45 -0
- package/dist/components/card/meta.js.map +1 -0
- package/dist/components/checkbox/meta.d.ts +17 -0
- package/dist/components/checkbox/meta.d.ts.map +1 -0
- package/dist/components/checkbox/meta.js +17 -0
- package/dist/components/checkbox/meta.js.map +1 -0
- package/dist/components/chip/meta.d.ts +9 -0
- package/dist/components/chip/meta.d.ts.map +1 -0
- package/dist/components/chip/meta.js +9 -0
- package/dist/components/chip/meta.js.map +1 -0
- package/dist/components/chip-group/meta.d.ts +9 -0
- package/dist/components/chip-group/meta.d.ts.map +1 -0
- package/dist/components/chip-group/meta.js +9 -0
- package/dist/components/chip-group/meta.js.map +1 -0
- package/dist/components/drawer/meta.d.ts +9 -0
- package/dist/components/drawer/meta.d.ts.map +1 -0
- package/dist/components/drawer/meta.js +9 -0
- package/dist/components/drawer/meta.js.map +1 -0
- package/dist/components/form/index.d.ts +1 -1
- package/dist/components/form/index.d.ts.map +1 -1
- package/dist/components/form/index.js.map +1 -1
- package/dist/components/form/meta.d.ts +79 -0
- package/dist/components/form/meta.d.ts.map +1 -0
- package/dist/components/form/meta.js +79 -0
- package/dist/components/form/meta.js.map +1 -0
- package/dist/components/form/types.d.ts +2 -1
- package/dist/components/form/types.d.ts.map +1 -1
- package/dist/components/form/types.js.map +1 -1
- package/dist/components/heading/meta.d.ts +69 -0
- package/dist/components/heading/meta.d.ts.map +1 -0
- package/dist/components/heading/meta.js +66 -0
- package/dist/components/heading/meta.js.map +1 -0
- package/dist/components/icon/meta.d.ts +9 -0
- package/dist/components/icon/meta.d.ts.map +1 -0
- package/dist/components/icon/meta.js +9 -0
- package/dist/components/icon/meta.js.map +1 -0
- package/dist/components/icon-button/meta.d.ts +9 -0
- package/dist/components/icon-button/meta.d.ts.map +1 -0
- package/dist/components/icon-button/meta.js +9 -0
- package/dist/components/icon-button/meta.js.map +1 -0
- package/dist/components/image/meta.d.ts +9 -0
- package/dist/components/image/meta.d.ts.map +1 -0
- package/dist/components/image/meta.js +9 -0
- package/dist/components/image/meta.js.map +1 -0
- package/dist/components/input/meta.d.ts +45 -0
- package/dist/components/input/meta.d.ts.map +1 -0
- package/dist/components/input/meta.js +45 -0
- package/dist/components/input/meta.js.map +1 -0
- package/dist/components/media-card/meta.d.ts +9 -0
- package/dist/components/media-card/meta.d.ts.map +1 -0
- package/dist/components/media-card/meta.js +9 -0
- package/dist/components/media-card/meta.js.map +1 -0
- package/dist/components/metric-card/meta.d.ts +9 -0
- package/dist/components/metric-card/meta.d.ts.map +1 -0
- package/dist/components/metric-card/meta.js +9 -0
- package/dist/components/metric-card/meta.js.map +1 -0
- package/dist/components/modal/meta.d.ts +9 -0
- package/dist/components/modal/meta.d.ts.map +1 -0
- package/dist/components/modal/meta.js +9 -0
- package/dist/components/modal/meta.js.map +1 -0
- package/dist/components/navigation-item/meta.d.ts +9 -0
- package/dist/components/navigation-item/meta.d.ts.map +1 -0
- package/dist/components/navigation-item/meta.js +9 -0
- package/dist/components/navigation-item/meta.js.map +1 -0
- package/dist/components/navigation-list/meta.d.ts +9 -0
- package/dist/components/navigation-list/meta.d.ts.map +1 -0
- package/dist/components/navigation-list/meta.js +9 -0
- package/dist/components/navigation-list/meta.js.map +1 -0
- package/dist/components/progress/meta.d.ts +9 -0
- package/dist/components/progress/meta.d.ts.map +1 -0
- package/dist/components/progress/meta.js +9 -0
- package/dist/components/progress/meta.js.map +1 -0
- package/dist/components/radio/meta.d.ts +17 -0
- package/dist/components/radio/meta.d.ts.map +1 -0
- package/dist/components/radio/meta.js +17 -0
- package/dist/components/radio/meta.js.map +1 -0
- package/dist/components/rating/meta.d.ts +9 -0
- package/dist/components/rating/meta.d.ts.map +1 -0
- package/dist/components/rating/meta.js +9 -0
- package/dist/components/rating/meta.js.map +1 -0
- package/dist/components/search-bar/meta.d.ts +9 -0
- package/dist/components/search-bar/meta.d.ts.map +1 -0
- package/dist/components/search-bar/meta.js +9 -0
- package/dist/components/search-bar/meta.js.map +1 -0
- package/dist/components/select/meta.d.ts +9 -0
- package/dist/components/select/meta.d.ts.map +1 -0
- package/dist/components/select/meta.js +9 -0
- package/dist/components/select/meta.js.map +1 -0
- package/dist/components/tabs/meta.d.ts +9 -0
- package/dist/components/tabs/meta.d.ts.map +1 -0
- package/dist/components/tabs/meta.js +9 -0
- package/dist/components/tabs/meta.js.map +1 -0
- package/dist/components/text/meta.d.ts +71 -0
- package/dist/components/text/meta.d.ts.map +1 -0
- package/dist/components/text/meta.js +68 -0
- package/dist/components/text/meta.js.map +1 -0
- package/dist/components/textarea/meta.d.ts +45 -0
- package/dist/components/textarea/meta.d.ts.map +1 -0
- package/dist/components/textarea/meta.js +45 -0
- package/dist/components/textarea/meta.js.map +1 -0
- package/dist/components/toolbar/meta.d.ts +17 -0
- package/dist/components/toolbar/meta.d.ts.map +1 -0
- package/dist/components/toolbar/meta.js +17 -0
- package/dist/components/toolbar/meta.js.map +1 -0
- package/dist/foundation/meta.d.ts +93 -0
- package/dist/foundation/meta.d.ts.map +1 -0
- package/dist/foundation/meta.js +84 -0
- package/dist/foundation/meta.js.map +1 -0
- package/dist/index.d.ts +5 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -0
- package/dist/index.js.map +1 -1
- package/dist/layout/app-shell/meta.d.ts +9 -0
- package/dist/layout/app-shell/meta.d.ts.map +1 -0
- package/dist/layout/app-shell/meta.js +9 -0
- package/dist/layout/app-shell/meta.js.map +1 -0
- package/dist/layout/auth-layout/meta.d.ts +33 -0
- package/dist/layout/auth-layout/meta.d.ts.map +1 -0
- package/dist/layout/auth-layout/meta.js +34 -0
- package/dist/layout/auth-layout/meta.js.map +1 -0
- package/dist/layout/page/meta.d.ts +19 -0
- package/dist/layout/page/meta.d.ts.map +1 -0
- package/dist/layout/page/meta.js +20 -0
- package/dist/layout/page/meta.js.map +1 -0
- package/dist/layout/page-header/meta.d.ts +38 -0
- package/dist/layout/page-header/meta.d.ts.map +1 -0
- package/dist/layout/page-header/meta.js +38 -0
- package/dist/layout/page-header/meta.js.map +1 -0
- package/dist/layout/page-section/meta.d.ts +28 -0
- package/dist/layout/page-section/meta.d.ts.map +1 -0
- package/dist/layout/page-section/meta.js +29 -0
- package/dist/layout/page-section/meta.js.map +1 -0
- package/dist/layout/settings-layout/meta.d.ts +9 -0
- package/dist/layout/settings-layout/meta.d.ts.map +1 -0
- package/dist/layout/settings-layout/meta.js +9 -0
- package/dist/layout/settings-layout/meta.js.map +1 -0
- package/dist/layout/sidebar-layout/meta.d.ts +9 -0
- package/dist/layout/sidebar-layout/meta.d.ts.map +1 -0
- package/dist/layout/sidebar-layout/meta.js +9 -0
- package/dist/layout/sidebar-layout/meta.js.map +1 -0
- package/dist/layout/topbar-layout/meta.d.ts +9 -0
- package/dist/layout/topbar-layout/meta.d.ts.map +1 -0
- package/dist/layout/topbar-layout/meta.js +9 -0
- package/dist/layout/topbar-layout/meta.js.map +1 -0
- package/dist/metadata/allowedChildren.d.ts +4 -0
- package/dist/metadata/allowedChildren.d.ts.map +1 -0
- package/dist/metadata/allowedChildren.js +26 -0
- package/dist/metadata/allowedChildren.js.map +1 -0
- package/dist/metadata/componentMeta.d.ts +3 -0
- package/dist/metadata/componentMeta.d.ts.map +1 -0
- package/dist/metadata/componentMeta.js +143 -0
- package/dist/metadata/componentMeta.js.map +1 -0
- package/dist/metadata/index.d.ts +3 -0
- package/dist/metadata/index.d.ts.map +1 -0
- package/dist/metadata/index.js +2 -0
- package/dist/metadata/index.js.map +1 -0
- package/dist/metadata/types.d.ts +49 -0
- package/dist/metadata/types.d.ts.map +1 -0
- package/dist/metadata/types.js +2 -0
- package/dist/metadata/types.js.map +1 -0
- package/dist/patterns/auth/meta.d.ts +33 -0
- package/dist/patterns/auth/meta.d.ts.map +1 -0
- package/dist/patterns/auth/meta.js +34 -0
- package/dist/patterns/auth/meta.js.map +1 -0
- package/dist/patterns/collection-editor/meta.d.ts +9 -0
- package/dist/patterns/collection-editor/meta.d.ts.map +1 -0
- package/dist/patterns/collection-editor/meta.js +9 -0
- package/dist/patterns/collection-editor/meta.js.map +1 -0
- package/dist/patterns/confirm-dialog/meta.d.ts +9 -0
- package/dist/patterns/confirm-dialog/meta.d.ts.map +1 -0
- package/dist/patterns/confirm-dialog/meta.js +9 -0
- package/dist/patterns/confirm-dialog/meta.js.map +1 -0
- package/dist/patterns/disclosure-section/meta.d.ts +9 -0
- package/dist/patterns/disclosure-section/meta.d.ts.map +1 -0
- package/dist/patterns/disclosure-section/meta.js +9 -0
- package/dist/patterns/disclosure-section/meta.js.map +1 -0
- package/dist/patterns/empty-state/meta.d.ts +33 -0
- package/dist/patterns/empty-state/meta.d.ts.map +1 -0
- package/dist/patterns/empty-state/meta.js +33 -0
- package/dist/patterns/empty-state/meta.js.map +1 -0
- package/dist/patterns/filter-bar/meta.d.ts +9 -0
- package/dist/patterns/filter-bar/meta.d.ts.map +1 -0
- package/dist/patterns/filter-bar/meta.js +9 -0
- package/dist/patterns/filter-bar/meta.js.map +1 -0
- package/dist/patterns/hero/Hero.d.ts +4 -0
- package/dist/patterns/hero/Hero.d.ts.map +1 -0
- package/dist/patterns/hero/Hero.js +59 -0
- package/dist/patterns/hero/Hero.js.map +1 -0
- package/dist/patterns/hero/index.d.ts +3 -0
- package/dist/patterns/hero/index.d.ts.map +1 -0
- package/dist/patterns/hero/index.js +2 -0
- package/dist/patterns/hero/index.js.map +1 -0
- package/dist/patterns/hero/meta.d.ts +101 -0
- package/dist/patterns/hero/meta.d.ts.map +1 -0
- package/dist/patterns/hero/meta.js +94 -0
- package/dist/patterns/hero/meta.js.map +1 -0
- package/dist/patterns/hero/types.d.ts +27 -0
- package/dist/patterns/hero/types.d.ts.map +1 -0
- package/dist/patterns/hero/types.js +2 -0
- package/dist/patterns/hero/types.js.map +1 -0
- package/dist/patterns/image-preview/meta.d.ts +9 -0
- package/dist/patterns/image-preview/meta.d.ts.map +1 -0
- package/dist/patterns/image-preview/meta.js +9 -0
- package/dist/patterns/image-preview/meta.js.map +1 -0
- package/dist/patterns/image-upload-field/meta.d.ts +9 -0
- package/dist/patterns/image-upload-field/meta.d.ts.map +1 -0
- package/dist/patterns/image-upload-field/meta.js +9 -0
- package/dist/patterns/image-upload-field/meta.js.map +1 -0
- package/dist/patterns/inspector-field/meta.d.ts +9 -0
- package/dist/patterns/inspector-field/meta.d.ts.map +1 -0
- package/dist/patterns/inspector-field/meta.js +9 -0
- package/dist/patterns/inspector-field/meta.js.map +1 -0
- package/dist/patterns/list/meta.d.ts +25 -0
- package/dist/patterns/list/meta.d.ts.map +1 -0
- package/dist/patterns/list/meta.js +26 -0
- package/dist/patterns/list/meta.js.map +1 -0
- package/dist/patterns/notice/meta.d.ts +34 -0
- package/dist/patterns/notice/meta.d.ts.map +1 -0
- package/dist/patterns/notice/meta.js +35 -0
- package/dist/patterns/notice/meta.js.map +1 -0
- package/dist/patterns/panel/meta.d.ts +44 -0
- package/dist/patterns/panel/meta.d.ts.map +1 -0
- package/dist/patterns/panel/meta.js +45 -0
- package/dist/patterns/panel/meta.js.map +1 -0
- package/dist/patterns/responsive-panel/meta.d.ts +9 -0
- package/dist/patterns/responsive-panel/meta.d.ts.map +1 -0
- package/dist/patterns/responsive-panel/meta.js +9 -0
- package/dist/patterns/responsive-panel/meta.js.map +1 -0
- package/dist/patterns/section-header/meta.d.ts +33 -0
- package/dist/patterns/section-header/meta.d.ts.map +1 -0
- package/dist/patterns/section-header/meta.js +33 -0
- package/dist/patterns/section-header/meta.js.map +1 -0
- package/dist/patterns/selection/meta.d.ts +17 -0
- package/dist/patterns/selection/meta.d.ts.map +1 -0
- package/dist/patterns/selection/meta.js +18 -0
- package/dist/patterns/selection/meta.js.map +1 -0
- package/dist/patterns/settings-row/meta.d.ts +39 -0
- package/dist/patterns/settings-row/meta.d.ts.map +1 -0
- package/dist/patterns/settings-row/meta.js +39 -0
- package/dist/patterns/settings-row/meta.js.map +1 -0
- package/dist/patterns/switch-field/meta.d.ts +9 -0
- package/dist/patterns/switch-field/meta.d.ts.map +1 -0
- package/dist/patterns/switch-field/meta.js +9 -0
- package/dist/patterns/switch-field/meta.js.map +1 -0
- package/dist/patterns/theme-composer/meta.d.ts +9 -0
- package/dist/patterns/theme-composer/meta.d.ts.map +1 -0
- package/dist/patterns/theme-composer/meta.js +9 -0
- package/dist/patterns/theme-composer/meta.js.map +1 -0
- package/dist/patterns/tile-grid/meta.d.ts +17 -0
- package/dist/patterns/tile-grid/meta.d.ts.map +1 -0
- package/dist/patterns/tile-grid/meta.js +18 -0
- package/dist/patterns/tile-grid/meta.js.map +1 -0
- package/dist/patterns/timeline/meta.d.ts +9 -0
- package/dist/patterns/timeline/meta.d.ts.map +1 -0
- package/dist/patterns/timeline/meta.js +9 -0
- package/dist/patterns/timeline/meta.js.map +1 -0
- package/dist/patterns/tree-view/meta.d.ts +17 -0
- package/dist/patterns/tree-view/meta.d.ts.map +1 -0
- package/dist/patterns/tree-view/meta.js +18 -0
- package/dist/patterns/tree-view/meta.js.map +1 -0
- package/dist/patterns/zora-drawer-content/meta.d.ts +9 -0
- package/dist/patterns/zora-drawer-content/meta.d.ts.map +1 -0
- package/dist/patterns/zora-drawer-content/meta.js +9 -0
- package/dist/patterns/zora-drawer-content/meta.js.map +1 -0
- package/dist/patterns/zora-tab-bar/meta.d.ts +9 -0
- package/dist/patterns/zora-tab-bar/meta.d.ts.map +1 -0
- package/dist/patterns/zora-tab-bar/meta.js +9 -0
- package/dist/patterns/zora-tab-bar/meta.js.map +1 -0
- package/package.json +1 -1
- package/src/components/app-bar/meta.ts +10 -0
- package/src/components/avatar/meta.ts +10 -0
- package/src/components/avatar-group/meta.ts +10 -0
- package/src/components/badge/meta.ts +10 -0
- package/src/components/button/meta.ts +46 -0
- package/src/components/card/meta.ts +46 -0
- package/src/components/checkbox/meta.ts +19 -0
- package/src/components/chip/meta.ts +10 -0
- package/src/components/chip-group/meta.ts +10 -0
- package/src/components/drawer/meta.ts +10 -0
- package/src/components/form/index.ts +0 -1
- package/src/components/form/meta.ts +83 -0
- package/src/components/form/types.ts +1 -1
- package/src/components/heading/meta.ts +67 -0
- package/src/components/icon/meta.ts +10 -0
- package/src/components/icon-button/meta.ts +10 -0
- package/src/components/image/meta.ts +10 -0
- package/src/components/input/meta.ts +46 -0
- package/src/components/media-card/meta.ts +10 -0
- package/src/components/metric-card/meta.ts +10 -0
- package/src/components/modal/meta.ts +10 -0
- package/src/components/navigation-item/meta.ts +10 -0
- package/src/components/navigation-list/meta.ts +10 -0
- package/src/components/progress/meta.ts +10 -0
- package/src/components/radio/meta.ts +19 -0
- package/src/components/rating/meta.ts +10 -0
- package/src/components/search-bar/meta.ts +10 -0
- package/src/components/select/meta.ts +10 -0
- package/src/components/tabs/meta.ts +10 -0
- package/src/components/text/meta.ts +69 -0
- package/src/components/textarea/meta.ts +46 -0
- package/src/components/toolbar/meta.ts +19 -0
- package/src/foundation/meta.ts +85 -0
- package/src/index.ts +15 -1
- package/src/layout/app-shell/meta.ts +10 -0
- package/src/layout/auth-layout/meta.ts +35 -0
- package/src/layout/page/meta.ts +21 -0
- package/src/layout/page-header/meta.ts +39 -0
- package/src/layout/page-section/meta.ts +30 -0
- package/src/layout/settings-layout/meta.ts +10 -0
- package/src/layout/sidebar-layout/meta.ts +10 -0
- package/src/layout/topbar-layout/meta.ts +10 -0
- package/src/metadata/allowedChildren.ts +27 -0
- package/src/metadata/componentMeta.test.ts +205 -0
- package/src/metadata/componentMeta.ts +149 -0
- package/src/metadata/index.ts +13 -0
- package/src/metadata/types.ts +74 -0
- package/src/patterns/auth/meta.ts +39 -0
- package/src/patterns/collection-editor/meta.ts +10 -0
- package/src/patterns/confirm-dialog/meta.ts +10 -0
- package/src/patterns/disclosure-section/meta.ts +10 -0
- package/src/patterns/empty-state/meta.ts +34 -0
- package/src/patterns/filter-bar/meta.ts +10 -0
- package/src/patterns/hero/Hero.tsx +112 -0
- package/src/patterns/hero/index.ts +2 -0
- package/src/patterns/hero/meta.ts +95 -0
- package/src/patterns/hero/types.ts +30 -0
- package/src/patterns/image-preview/meta.ts +10 -0
- package/src/patterns/image-upload-field/meta.ts +10 -0
- package/src/patterns/inspector-field/meta.ts +10 -0
- package/src/patterns/list/meta.ts +30 -0
- package/src/patterns/notice/meta.ts +36 -0
- package/src/patterns/panel/meta.ts +46 -0
- package/src/patterns/responsive-panel/meta.ts +10 -0
- package/src/patterns/section-header/meta.ts +34 -0
- package/src/patterns/selection/meta.ts +21 -0
- package/src/patterns/settings-row/meta.ts +40 -0
- package/src/patterns/switch-field/meta.ts +10 -0
- package/src/patterns/theme-composer/meta.ts +10 -0
- package/src/patterns/tile-grid/meta.ts +21 -0
- package/src/patterns/timeline/meta.ts +10 -0
- package/src/patterns/tree-view/meta.ts +21 -0
- package/src/patterns/zora-drawer-content/meta.ts +10 -0
- package/src/patterns/zora-tab-bar/meta.ts +10 -0
|
@@ -0,0 +1,149 @@
|
|
|
1
|
+
import { appBarMeta } from '../components/app-bar/meta';
|
|
2
|
+
import { avatarMeta } from '../components/avatar/meta';
|
|
3
|
+
import { avatarGroupMeta } from '../components/avatar-group/meta';
|
|
4
|
+
import { badgeMeta } from '../components/badge/meta';
|
|
5
|
+
import { buttonMeta } from '../components/button/meta';
|
|
6
|
+
import { cardMeta } from '../components/card/meta';
|
|
7
|
+
import { checkboxGroupMeta, checkboxMeta } from '../components/checkbox/meta';
|
|
8
|
+
import { chipMeta } from '../components/chip/meta';
|
|
9
|
+
import { chipGroupMeta } from '../components/chip-group/meta';
|
|
10
|
+
import { drawerMeta } from '../components/drawer/meta';
|
|
11
|
+
import { formActionsMeta, formErrorMeta, formFieldMeta, formMeta } from '../components/form/meta';
|
|
12
|
+
import { headingMeta } from '../components/heading/meta';
|
|
13
|
+
import { iconMeta } from '../components/icon/meta';
|
|
14
|
+
import { iconButtonMeta } from '../components/icon-button/meta';
|
|
15
|
+
import { imageMeta } from '../components/image/meta';
|
|
16
|
+
import { inputMeta } from '../components/input/meta';
|
|
17
|
+
import { mediaCardMeta } from '../components/media-card/meta';
|
|
18
|
+
import { metricCardMeta } from '../components/metric-card/meta';
|
|
19
|
+
import { modalMeta } from '../components/modal/meta';
|
|
20
|
+
import { navigationItemMeta } from '../components/navigation-item/meta';
|
|
21
|
+
import { navigationListMeta } from '../components/navigation-list/meta';
|
|
22
|
+
import { progressMeta } from '../components/progress/meta';
|
|
23
|
+
import { radioGroupMeta, radioMeta } from '../components/radio/meta';
|
|
24
|
+
import { ratingMeta } from '../components/rating/meta';
|
|
25
|
+
import { searchBarMeta } from '../components/search-bar/meta';
|
|
26
|
+
import { selectMeta } from '../components/select/meta';
|
|
27
|
+
import { tabsMeta } from '../components/tabs/meta';
|
|
28
|
+
import { textMeta } from '../components/text/meta';
|
|
29
|
+
import { textareaMeta } from '../components/textarea/meta';
|
|
30
|
+
import { toolbarActionMeta, toolbarMeta } from '../components/toolbar/meta';
|
|
31
|
+
import { foundationMetas } from '../foundation/meta';
|
|
32
|
+
import { appShellMeta } from '../layout/app-shell/meta';
|
|
33
|
+
import { authLayoutMeta } from '../layout/auth-layout/meta';
|
|
34
|
+
import { pageMeta } from '../layout/page/meta';
|
|
35
|
+
import { pageHeaderMeta } from '../layout/page-header/meta';
|
|
36
|
+
import { pageSectionMeta } from '../layout/page-section/meta';
|
|
37
|
+
import { settingsLayoutMeta } from '../layout/settings-layout/meta';
|
|
38
|
+
import { sidebarLayoutMeta } from '../layout/sidebar-layout/meta';
|
|
39
|
+
import { topbarLayoutMeta } from '../layout/topbar-layout/meta';
|
|
40
|
+
import {
|
|
41
|
+
forgotPasswordFormMeta,
|
|
42
|
+
otpFormMeta,
|
|
43
|
+
signInFormMeta,
|
|
44
|
+
signUpFormMeta,
|
|
45
|
+
} from '../patterns/auth/meta';
|
|
46
|
+
import { collectionEditorMeta } from '../patterns/collection-editor/meta';
|
|
47
|
+
import { confirmDialogMeta } from '../patterns/confirm-dialog/meta';
|
|
48
|
+
import { disclosureSectionMeta } from '../patterns/disclosure-section/meta';
|
|
49
|
+
import { emptyStateMeta } from '../patterns/empty-state/meta';
|
|
50
|
+
import { filterBarMeta } from '../patterns/filter-bar/meta';
|
|
51
|
+
import { heroMeta } from '../patterns/hero/meta';
|
|
52
|
+
import { imagePreviewMeta } from '../patterns/image-preview/meta';
|
|
53
|
+
import { imageUploadFieldMeta } from '../patterns/image-upload-field/meta';
|
|
54
|
+
import { inspectorFieldMeta } from '../patterns/inspector-field/meta';
|
|
55
|
+
import { listMeta, listRowMeta, listSectionMeta } from '../patterns/list/meta';
|
|
56
|
+
import { noticeMeta } from '../patterns/notice/meta';
|
|
57
|
+
import { panelMeta } from '../patterns/panel/meta';
|
|
58
|
+
import { responsivePanelMeta } from '../patterns/responsive-panel/meta';
|
|
59
|
+
import { sectionHeaderMeta } from '../patterns/section-header/meta';
|
|
60
|
+
import { selectableItemMeta, selectionProviderMeta } from '../patterns/selection/meta';
|
|
61
|
+
import { settingsRowMeta } from '../patterns/settings-row/meta';
|
|
62
|
+
import { switchFieldMeta } from '../patterns/switch-field/meta';
|
|
63
|
+
import { themeComposerMeta } from '../patterns/theme-composer/meta';
|
|
64
|
+
import { paletteItemMeta, tileGridMeta } from '../patterns/tile-grid/meta';
|
|
65
|
+
import { timelineMeta } from '../patterns/timeline/meta';
|
|
66
|
+
import { treeItemMeta, treeViewMeta } from '../patterns/tree-view/meta';
|
|
67
|
+
import { zoraDrawerContentMeta } from '../patterns/zora-drawer-content/meta';
|
|
68
|
+
import { zoraTabBarMeta } from '../patterns/zora-tab-bar/meta';
|
|
69
|
+
import type { ZoraComponentMetaRegistry } from './types';
|
|
70
|
+
|
|
71
|
+
export const ZORA_COMPONENT_META: ZoraComponentMetaRegistry = {
|
|
72
|
+
...foundationMetas,
|
|
73
|
+
AppBar: appBarMeta,
|
|
74
|
+
Avatar: avatarMeta,
|
|
75
|
+
AvatarGroup: avatarGroupMeta,
|
|
76
|
+
Badge: badgeMeta,
|
|
77
|
+
Button: buttonMeta,
|
|
78
|
+
Card: cardMeta,
|
|
79
|
+
Checkbox: checkboxMeta,
|
|
80
|
+
CheckboxGroup: checkboxGroupMeta,
|
|
81
|
+
Chip: chipMeta,
|
|
82
|
+
ChipGroup: chipGroupMeta,
|
|
83
|
+
Drawer: drawerMeta,
|
|
84
|
+
Form: formMeta,
|
|
85
|
+
FormActions: formActionsMeta,
|
|
86
|
+
FormError: formErrorMeta,
|
|
87
|
+
FormField: formFieldMeta,
|
|
88
|
+
Heading: headingMeta,
|
|
89
|
+
Icon: iconMeta,
|
|
90
|
+
IconButton: iconButtonMeta,
|
|
91
|
+
Image: imageMeta,
|
|
92
|
+
Input: inputMeta,
|
|
93
|
+
MediaCard: mediaCardMeta,
|
|
94
|
+
MetricCard: metricCardMeta,
|
|
95
|
+
Modal: modalMeta,
|
|
96
|
+
NavigationItem: navigationItemMeta,
|
|
97
|
+
NavigationList: navigationListMeta,
|
|
98
|
+
Progress: progressMeta,
|
|
99
|
+
Radio: radioMeta,
|
|
100
|
+
RadioGroup: radioGroupMeta,
|
|
101
|
+
Rating: ratingMeta,
|
|
102
|
+
SearchBar: searchBarMeta,
|
|
103
|
+
Select: selectMeta,
|
|
104
|
+
Tabs: tabsMeta,
|
|
105
|
+
Text: textMeta,
|
|
106
|
+
Textarea: textareaMeta,
|
|
107
|
+
Toolbar: toolbarMeta,
|
|
108
|
+
ToolbarAction: toolbarActionMeta,
|
|
109
|
+
AppShell: appShellMeta,
|
|
110
|
+
AuthLayout: authLayoutMeta,
|
|
111
|
+
Page: pageMeta,
|
|
112
|
+
PageHeader: pageHeaderMeta,
|
|
113
|
+
PageSection: pageSectionMeta,
|
|
114
|
+
SettingsLayout: settingsLayoutMeta,
|
|
115
|
+
SidebarLayout: sidebarLayoutMeta,
|
|
116
|
+
TopbarLayout: topbarLayoutMeta,
|
|
117
|
+
ForgotPasswordForm: forgotPasswordFormMeta,
|
|
118
|
+
OtpForm: otpFormMeta,
|
|
119
|
+
SignInForm: signInFormMeta,
|
|
120
|
+
SignUpForm: signUpFormMeta,
|
|
121
|
+
CollectionEditor: collectionEditorMeta,
|
|
122
|
+
ConfirmDialog: confirmDialogMeta,
|
|
123
|
+
DisclosureSection: disclosureSectionMeta,
|
|
124
|
+
EmptyState: emptyStateMeta,
|
|
125
|
+
FilterBar: filterBarMeta,
|
|
126
|
+
Hero: heroMeta,
|
|
127
|
+
ImagePreview: imagePreviewMeta,
|
|
128
|
+
ImageUploadField: imageUploadFieldMeta,
|
|
129
|
+
InspectorField: inspectorFieldMeta,
|
|
130
|
+
List: listMeta,
|
|
131
|
+
ListRow: listRowMeta,
|
|
132
|
+
ListSection: listSectionMeta,
|
|
133
|
+
Notice: noticeMeta,
|
|
134
|
+
Panel: panelMeta,
|
|
135
|
+
ResponsivePanel: responsivePanelMeta,
|
|
136
|
+
SectionHeader: sectionHeaderMeta,
|
|
137
|
+
SelectableItem: selectableItemMeta,
|
|
138
|
+
SelectionProvider: selectionProviderMeta,
|
|
139
|
+
SettingsRow: settingsRowMeta,
|
|
140
|
+
SwitchField: switchFieldMeta,
|
|
141
|
+
ThemeComposer: themeComposerMeta,
|
|
142
|
+
PaletteItem: paletteItemMeta,
|
|
143
|
+
TileGrid: tileGridMeta,
|
|
144
|
+
Timeline: timelineMeta,
|
|
145
|
+
TreeItem: treeItemMeta,
|
|
146
|
+
TreeView: treeViewMeta,
|
|
147
|
+
ZoraDrawerContent: zoraDrawerContentMeta,
|
|
148
|
+
ZoraTabBar: zoraTabBarMeta,
|
|
149
|
+
};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
export { ZORA_COMPONENT_META } from './componentMeta';
|
|
2
|
+
export type {
|
|
3
|
+
ZoraComponentBlueprint,
|
|
4
|
+
ZoraComponentCategory,
|
|
5
|
+
ZoraComponentI18nMeta,
|
|
6
|
+
ZoraComponentMeta,
|
|
7
|
+
ZoraComponentMetaRegistry,
|
|
8
|
+
ZoraComponentPropArrayItemSchema,
|
|
9
|
+
ZoraComponentPropSchema,
|
|
10
|
+
ZoraComponentPropType,
|
|
11
|
+
ZoraComponentPropValue,
|
|
12
|
+
ZoraComponentSlotMeta,
|
|
13
|
+
} from './types';
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
export type ZoraComponentCategory = 'foundation' | 'component' | 'pattern' | 'layout';
|
|
2
|
+
|
|
3
|
+
export type ZoraComponentPropType =
|
|
4
|
+
| 'string'
|
|
5
|
+
| 'number'
|
|
6
|
+
| 'boolean'
|
|
7
|
+
| 'enum'
|
|
8
|
+
| 'color'
|
|
9
|
+
| 'spacing'
|
|
10
|
+
| 'radius'
|
|
11
|
+
| 'shadow'
|
|
12
|
+
| 'typographySize'
|
|
13
|
+
| 'typographyWeight'
|
|
14
|
+
| 'action'
|
|
15
|
+
| 'imageAsset'
|
|
16
|
+
| 'array';
|
|
17
|
+
|
|
18
|
+
export type ZoraComponentPropValue =
|
|
19
|
+
| string
|
|
20
|
+
| number
|
|
21
|
+
| boolean
|
|
22
|
+
| null
|
|
23
|
+
| readonly ZoraComponentPropValue[]
|
|
24
|
+
| { readonly [key: string]: ZoraComponentPropValue };
|
|
25
|
+
|
|
26
|
+
export interface ZoraComponentPropArrayItemSchema {
|
|
27
|
+
key: string;
|
|
28
|
+
schema: ZoraComponentPropSchema;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
export interface ZoraComponentPropSchema {
|
|
32
|
+
type: ZoraComponentPropType;
|
|
33
|
+
category: string;
|
|
34
|
+
label?: string;
|
|
35
|
+
enum?: readonly (string | number)[];
|
|
36
|
+
default?: ZoraComponentPropValue;
|
|
37
|
+
itemSchema?: readonly ZoraComponentPropArrayItemSchema[];
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
export interface ZoraComponentBlueprint {
|
|
41
|
+
label: string;
|
|
42
|
+
icon?: {
|
|
43
|
+
name: string;
|
|
44
|
+
provider?: string;
|
|
45
|
+
};
|
|
46
|
+
defaultProps?: Readonly<Record<string, ZoraComponentPropValue>>;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
export interface ZoraComponentI18nMeta {
|
|
50
|
+
fields: readonly {
|
|
51
|
+
keyProp: string;
|
|
52
|
+
defaultTextProp: string;
|
|
53
|
+
}[];
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
export interface ZoraComponentSlotMeta {
|
|
57
|
+
label?: string;
|
|
58
|
+
allowedChildren?: readonly string[];
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
export interface ZoraComponentMeta {
|
|
62
|
+
name: string;
|
|
63
|
+
category: ZoraComponentCategory;
|
|
64
|
+
description?: string;
|
|
65
|
+
directManifestNode: boolean;
|
|
66
|
+
allowedChildren: readonly string[];
|
|
67
|
+
blueprint?: ZoraComponentBlueprint;
|
|
68
|
+
i18n?: ZoraComponentI18nMeta;
|
|
69
|
+
slots?: Readonly<Record<string, ZoraComponentSlotMeta>>;
|
|
70
|
+
note?: string;
|
|
71
|
+
props: Readonly<Record<string, ZoraComponentPropSchema>>;
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
export type ZoraComponentMetaRegistry = Readonly<Record<string, ZoraComponentMeta>>;
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import type { ZoraComponentMeta } from '../../metadata';
|
|
2
|
+
|
|
3
|
+
const AUTH_NOTE = 'Auth pattern component; not represented as a manifest node in v1.';
|
|
4
|
+
|
|
5
|
+
export const forgotPasswordFormMeta = {
|
|
6
|
+
name: 'ForgotPasswordForm',
|
|
7
|
+
category: 'pattern',
|
|
8
|
+
directManifestNode: false,
|
|
9
|
+
allowedChildren: [],
|
|
10
|
+
note: AUTH_NOTE,
|
|
11
|
+
props: {},
|
|
12
|
+
} as const satisfies ZoraComponentMeta;
|
|
13
|
+
|
|
14
|
+
export const otpFormMeta = {
|
|
15
|
+
name: 'OtpForm',
|
|
16
|
+
category: 'pattern',
|
|
17
|
+
directManifestNode: false,
|
|
18
|
+
allowedChildren: [],
|
|
19
|
+
note: AUTH_NOTE,
|
|
20
|
+
props: {},
|
|
21
|
+
} as const satisfies ZoraComponentMeta;
|
|
22
|
+
|
|
23
|
+
export const signInFormMeta = {
|
|
24
|
+
name: 'SignInForm',
|
|
25
|
+
category: 'pattern',
|
|
26
|
+
directManifestNode: false,
|
|
27
|
+
allowedChildren: [],
|
|
28
|
+
note: AUTH_NOTE,
|
|
29
|
+
props: {},
|
|
30
|
+
} as const satisfies ZoraComponentMeta;
|
|
31
|
+
|
|
32
|
+
export const signUpFormMeta = {
|
|
33
|
+
name: 'SignUpForm',
|
|
34
|
+
category: 'pattern',
|
|
35
|
+
directManifestNode: false,
|
|
36
|
+
allowedChildren: [],
|
|
37
|
+
note: AUTH_NOTE,
|
|
38
|
+
props: {},
|
|
39
|
+
} as const satisfies ZoraComponentMeta;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { ZoraComponentMeta } from '../../metadata';
|
|
2
|
+
|
|
3
|
+
export const collectionEditorMeta = {
|
|
4
|
+
name: 'CollectionEditor',
|
|
5
|
+
category: 'pattern',
|
|
6
|
+
directManifestNode: false,
|
|
7
|
+
allowedChildren: [],
|
|
8
|
+
note: 'Specialized editing pattern; not represented as a manifest node in v1.',
|
|
9
|
+
props: {},
|
|
10
|
+
} as const satisfies ZoraComponentMeta;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { ZoraComponentMeta } from '../../metadata';
|
|
2
|
+
|
|
3
|
+
export const confirmDialogMeta = {
|
|
4
|
+
name: 'ConfirmDialog',
|
|
5
|
+
category: 'pattern',
|
|
6
|
+
directManifestNode: false,
|
|
7
|
+
allowedChildren: [],
|
|
8
|
+
note: 'Dialog pattern; not represented as a manifest node in v1.',
|
|
9
|
+
props: {},
|
|
10
|
+
} as const satisfies ZoraComponentMeta;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { ZoraComponentMeta } from '../../metadata';
|
|
2
|
+
|
|
3
|
+
export const disclosureSectionMeta = {
|
|
4
|
+
name: 'DisclosureSection',
|
|
5
|
+
category: 'pattern',
|
|
6
|
+
directManifestNode: false,
|
|
7
|
+
allowedChildren: [],
|
|
8
|
+
note: 'Disclosure pattern; not represented as a manifest node in v1.',
|
|
9
|
+
props: {},
|
|
10
|
+
} as const satisfies ZoraComponentMeta;
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import type { ZoraComponentMeta } from '../../metadata';
|
|
2
|
+
|
|
3
|
+
export const emptyStateMeta = {
|
|
4
|
+
name: 'EmptyState',
|
|
5
|
+
category: 'pattern',
|
|
6
|
+
directManifestNode: true,
|
|
7
|
+
allowedChildren: [],
|
|
8
|
+
blueprint: {
|
|
9
|
+
label: 'Empty state',
|
|
10
|
+
defaultProps: {
|
|
11
|
+
title: 'Nothing here yet',
|
|
12
|
+
description: 'Try adding your first item.',
|
|
13
|
+
},
|
|
14
|
+
},
|
|
15
|
+
props: {
|
|
16
|
+
title: {
|
|
17
|
+
type: 'string',
|
|
18
|
+
category: 'Content',
|
|
19
|
+
label: 'Title',
|
|
20
|
+
default: 'Nothing here yet',
|
|
21
|
+
},
|
|
22
|
+
description: {
|
|
23
|
+
type: 'string',
|
|
24
|
+
category: 'Content',
|
|
25
|
+
label: 'Description',
|
|
26
|
+
default: 'Try adding your first item.',
|
|
27
|
+
},
|
|
28
|
+
eyebrow: {
|
|
29
|
+
type: 'string',
|
|
30
|
+
category: 'Content',
|
|
31
|
+
label: 'Eyebrow',
|
|
32
|
+
},
|
|
33
|
+
},
|
|
34
|
+
} as const satisfies ZoraComponentMeta;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { ZoraComponentMeta } from '../../metadata';
|
|
2
|
+
|
|
3
|
+
export const filterBarMeta = {
|
|
4
|
+
name: 'FilterBar',
|
|
5
|
+
category: 'pattern',
|
|
6
|
+
directManifestNode: false,
|
|
7
|
+
allowedChildren: [],
|
|
8
|
+
note: 'Filtering pattern; not represented as a manifest node in v1.',
|
|
9
|
+
props: {},
|
|
10
|
+
} as const satisfies ZoraComponentMeta;
|
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
|
|
3
|
+
import { Button } from '../../components/button';
|
|
4
|
+
import { Card } from '../../components/card';
|
|
5
|
+
import { Heading } from '../../components/heading';
|
|
6
|
+
import { Text } from '../../components/text';
|
|
7
|
+
import { Box, Stack } from '../../foundation';
|
|
8
|
+
import { withZoraThemeScope } from '../../theme/withZoraThemeScope';
|
|
9
|
+
import type { HeroAction, HeroAlign, HeroLayout, HeroProps } from './types';
|
|
10
|
+
|
|
11
|
+
function HeroInner({
|
|
12
|
+
themeId: _themeId,
|
|
13
|
+
mode: _mode,
|
|
14
|
+
title,
|
|
15
|
+
description,
|
|
16
|
+
eyebrow,
|
|
17
|
+
primaryAction,
|
|
18
|
+
secondaryAction,
|
|
19
|
+
media,
|
|
20
|
+
footer,
|
|
21
|
+
align = 'start',
|
|
22
|
+
layout = 'split',
|
|
23
|
+
tone = 'subtle',
|
|
24
|
+
compact = false,
|
|
25
|
+
testID,
|
|
26
|
+
}: HeroProps) {
|
|
27
|
+
const hasActions = primaryAction !== undefined || secondaryAction !== undefined;
|
|
28
|
+
const hasMedia = media !== undefined;
|
|
29
|
+
const direction = resolveDirection(layout, hasMedia);
|
|
30
|
+
const contentAlign = resolveContentAlign(align);
|
|
31
|
+
const textAlign = align === 'center' ? 'center' : undefined;
|
|
32
|
+
const mediaFirst = layout === 'mediaFirst';
|
|
33
|
+
|
|
34
|
+
const content = (
|
|
35
|
+
<Box flex={1}>
|
|
36
|
+
<Stack align={contentAlign} gap={compact ? 's' : 'm'}>
|
|
37
|
+
<Stack align={contentAlign} gap="xs">
|
|
38
|
+
{eyebrow !== undefined ? (
|
|
39
|
+
<Text align={textAlign} tone="primary" variant="eyebrow">
|
|
40
|
+
{eyebrow}
|
|
41
|
+
</Text>
|
|
42
|
+
) : null}
|
|
43
|
+
<Heading
|
|
44
|
+
align={textAlign}
|
|
45
|
+
level={1}
|
|
46
|
+
size={{ base: 'h2', md: compact ? 'h2' : 'display' }}
|
|
47
|
+
>
|
|
48
|
+
{title}
|
|
49
|
+
</Heading>
|
|
50
|
+
{description !== undefined ? (
|
|
51
|
+
<Text
|
|
52
|
+
tone="muted"
|
|
53
|
+
align={textAlign}
|
|
54
|
+
variant={{ base: 'body', md: compact ? 'body' : 'lead' }}
|
|
55
|
+
>
|
|
56
|
+
{description}
|
|
57
|
+
</Text>
|
|
58
|
+
) : null}
|
|
59
|
+
</Stack>
|
|
60
|
+
|
|
61
|
+
{hasActions ? (
|
|
62
|
+
<Stack
|
|
63
|
+
align={contentAlign}
|
|
64
|
+
direction={{ base: 'column', md: 'row' }}
|
|
65
|
+
gap="s"
|
|
66
|
+
justify={align === 'center' ? 'center' : 'flex-start'}
|
|
67
|
+
>
|
|
68
|
+
{primaryAction !== undefined ? renderAction(primaryAction, 'primary') : null}
|
|
69
|
+
{secondaryAction !== undefined ? renderAction(secondaryAction, 'secondary') : null}
|
|
70
|
+
</Stack>
|
|
71
|
+
) : null}
|
|
72
|
+
|
|
73
|
+
{footer}
|
|
74
|
+
</Stack>
|
|
75
|
+
</Box>
|
|
76
|
+
);
|
|
77
|
+
|
|
78
|
+
const mediaSlot = hasMedia ? <Box flex={1}>{media}</Box> : null;
|
|
79
|
+
|
|
80
|
+
return (
|
|
81
|
+
<Card compact={compact} testID={testID} tone={tone}>
|
|
82
|
+
<Stack align="center" direction={direction} gap={compact ? 'm' : 'l'}>
|
|
83
|
+
{mediaFirst ? mediaSlot : content}
|
|
84
|
+
{mediaFirst ? content : mediaSlot}
|
|
85
|
+
</Stack>
|
|
86
|
+
</Card>
|
|
87
|
+
);
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
function renderAction(action: HeroAction, role: 'primary' | 'secondary') {
|
|
91
|
+
return (
|
|
92
|
+
<Button
|
|
93
|
+
disabled={action.disabled}
|
|
94
|
+
emphasis={action.emphasis ?? (role === 'primary' ? 'solid' : 'soft')}
|
|
95
|
+
onPress={action.onPress}
|
|
96
|
+
tone={action.tone ?? (role === 'primary' ? 'primary' : 'neutral')}
|
|
97
|
+
>
|
|
98
|
+
{action.label}
|
|
99
|
+
</Button>
|
|
100
|
+
);
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
function resolveContentAlign(align: HeroAlign) {
|
|
104
|
+
return align === 'center' ? 'center' : 'flex-start';
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
function resolveDirection(layout: HeroLayout, hasMedia: boolean) {
|
|
108
|
+
if (!hasMedia || layout === 'stack') return 'column' as const;
|
|
109
|
+
return { base: 'column', md: 'row' } as const;
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
export const Hero = withZoraThemeScope(HeroInner);
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
import type { ZoraComponentMeta } from '../../metadata';
|
|
2
|
+
|
|
3
|
+
export const heroMeta = {
|
|
4
|
+
name: 'Hero',
|
|
5
|
+
category: 'pattern',
|
|
6
|
+
description: 'Landing-page and section hero with title copy, actions, and optional media.',
|
|
7
|
+
directManifestNode: true,
|
|
8
|
+
allowedChildren: [],
|
|
9
|
+
blueprint: {
|
|
10
|
+
label: 'Hero',
|
|
11
|
+
icon: { name: 'sparkles-outline' },
|
|
12
|
+
defaultProps: {
|
|
13
|
+
eyebrow: 'New release',
|
|
14
|
+
title: 'Build product screens faster',
|
|
15
|
+
description: 'Use a responsive hero pattern with strong defaults and structured actions.',
|
|
16
|
+
align: 'start',
|
|
17
|
+
layout: 'split',
|
|
18
|
+
tone: 'subtle',
|
|
19
|
+
},
|
|
20
|
+
},
|
|
21
|
+
i18n: {
|
|
22
|
+
fields: [
|
|
23
|
+
{ keyProp: 'eyebrowI18nKey', defaultTextProp: 'eyebrow' },
|
|
24
|
+
{ keyProp: 'titleI18nKey', defaultTextProp: 'title' },
|
|
25
|
+
{ keyProp: 'descriptionI18nKey', defaultTextProp: 'description' },
|
|
26
|
+
],
|
|
27
|
+
},
|
|
28
|
+
slots: {
|
|
29
|
+
media: {
|
|
30
|
+
label: 'Media',
|
|
31
|
+
allowedChildren: ['Image', 'Card', 'MetricCard', 'MediaCard'],
|
|
32
|
+
},
|
|
33
|
+
footer: {
|
|
34
|
+
label: 'Footer',
|
|
35
|
+
allowedChildren: ['Badge', 'Text', 'AvatarGroup'],
|
|
36
|
+
},
|
|
37
|
+
},
|
|
38
|
+
props: {
|
|
39
|
+
eyebrow: {
|
|
40
|
+
type: 'string',
|
|
41
|
+
category: 'Content',
|
|
42
|
+
label: 'Eyebrow',
|
|
43
|
+
default: 'New release',
|
|
44
|
+
},
|
|
45
|
+
title: {
|
|
46
|
+
type: 'string',
|
|
47
|
+
category: 'Content',
|
|
48
|
+
label: 'Title',
|
|
49
|
+
default: 'Build product screens faster',
|
|
50
|
+
},
|
|
51
|
+
description: {
|
|
52
|
+
type: 'string',
|
|
53
|
+
category: 'Content',
|
|
54
|
+
label: 'Description',
|
|
55
|
+
default: 'Use a responsive hero pattern with strong defaults and structured actions.',
|
|
56
|
+
},
|
|
57
|
+
align: {
|
|
58
|
+
type: 'enum',
|
|
59
|
+
category: 'Layout',
|
|
60
|
+
label: 'Alignment',
|
|
61
|
+
enum: ['start', 'center'],
|
|
62
|
+
default: 'start',
|
|
63
|
+
},
|
|
64
|
+
layout: {
|
|
65
|
+
type: 'enum',
|
|
66
|
+
category: 'Layout',
|
|
67
|
+
label: 'Layout',
|
|
68
|
+
enum: ['stack', 'split', 'mediaFirst'],
|
|
69
|
+
default: 'split',
|
|
70
|
+
},
|
|
71
|
+
tone: {
|
|
72
|
+
type: 'enum',
|
|
73
|
+
category: 'Appearance',
|
|
74
|
+
label: 'Tone',
|
|
75
|
+
enum: ['default', 'subtle', 'outline'],
|
|
76
|
+
default: 'subtle',
|
|
77
|
+
},
|
|
78
|
+
compact: {
|
|
79
|
+
type: 'boolean',
|
|
80
|
+
category: 'Layout',
|
|
81
|
+
label: 'Compact',
|
|
82
|
+
default: false,
|
|
83
|
+
},
|
|
84
|
+
primaryAction: {
|
|
85
|
+
type: 'action',
|
|
86
|
+
category: 'Actions',
|
|
87
|
+
label: 'Primary action',
|
|
88
|
+
},
|
|
89
|
+
secondaryAction: {
|
|
90
|
+
type: 'action',
|
|
91
|
+
category: 'Actions',
|
|
92
|
+
label: 'Secondary action',
|
|
93
|
+
},
|
|
94
|
+
},
|
|
95
|
+
} as const satisfies ZoraComponentMeta;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import type React from 'react';
|
|
2
|
+
|
|
3
|
+
import type { ZoraEmphasis, ZoraTone } from '../../internal/recipes';
|
|
4
|
+
import type { ZoraBaseProps } from '../../theme/ZoraBaseProps';
|
|
5
|
+
|
|
6
|
+
export type HeroAlign = 'start' | 'center';
|
|
7
|
+
export type HeroLayout = 'stack' | 'split' | 'mediaFirst';
|
|
8
|
+
export type HeroTone = 'default' | 'subtle' | 'outline';
|
|
9
|
+
|
|
10
|
+
export interface HeroAction {
|
|
11
|
+
label: React.ReactNode;
|
|
12
|
+
onPress: () => void;
|
|
13
|
+
tone?: ZoraTone;
|
|
14
|
+
emphasis?: ZoraEmphasis;
|
|
15
|
+
disabled?: boolean;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export interface HeroProps extends ZoraBaseProps {
|
|
19
|
+
title: React.ReactNode;
|
|
20
|
+
description?: React.ReactNode;
|
|
21
|
+
eyebrow?: React.ReactNode;
|
|
22
|
+
primaryAction?: HeroAction;
|
|
23
|
+
secondaryAction?: HeroAction;
|
|
24
|
+
media?: React.ReactNode;
|
|
25
|
+
footer?: React.ReactNode;
|
|
26
|
+
align?: HeroAlign;
|
|
27
|
+
layout?: HeroLayout;
|
|
28
|
+
tone?: HeroTone;
|
|
29
|
+
compact?: boolean;
|
|
30
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { ZoraComponentMeta } from '../../metadata';
|
|
2
|
+
|
|
3
|
+
export const imagePreviewMeta = {
|
|
4
|
+
name: 'ImagePreview',
|
|
5
|
+
category: 'pattern',
|
|
6
|
+
directManifestNode: false,
|
|
7
|
+
allowedChildren: [],
|
|
8
|
+
note: 'Media pattern; not represented as a manifest node in v1.',
|
|
9
|
+
props: {},
|
|
10
|
+
} as const satisfies ZoraComponentMeta;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { ZoraComponentMeta } from '../../metadata';
|
|
2
|
+
|
|
3
|
+
export const imageUploadFieldMeta = {
|
|
4
|
+
name: 'ImageUploadField',
|
|
5
|
+
category: 'pattern',
|
|
6
|
+
directManifestNode: false,
|
|
7
|
+
allowedChildren: [],
|
|
8
|
+
note: 'Media upload pattern; not represented as a manifest node in v1.',
|
|
9
|
+
props: {},
|
|
10
|
+
} as const satisfies ZoraComponentMeta;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import type { ZoraComponentMeta } from '../../metadata';
|
|
2
|
+
|
|
3
|
+
export const inspectorFieldMeta = {
|
|
4
|
+
name: 'InspectorField',
|
|
5
|
+
category: 'pattern',
|
|
6
|
+
directManifestNode: false,
|
|
7
|
+
allowedChildren: [],
|
|
8
|
+
note: 'Inspector pattern; not represented as a manifest node in v1.',
|
|
9
|
+
props: {},
|
|
10
|
+
} as const satisfies ZoraComponentMeta;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import type { ZoraComponentMeta } from '../../metadata';
|
|
2
|
+
|
|
3
|
+
const LIST_NOTE = 'List pattern component; not represented as a manifest node in v1.';
|
|
4
|
+
|
|
5
|
+
export const listMeta = {
|
|
6
|
+
name: 'List',
|
|
7
|
+
category: 'pattern',
|
|
8
|
+
directManifestNode: false,
|
|
9
|
+
allowedChildren: [],
|
|
10
|
+
note: LIST_NOTE,
|
|
11
|
+
props: {},
|
|
12
|
+
} as const satisfies ZoraComponentMeta;
|
|
13
|
+
|
|
14
|
+
export const listRowMeta = {
|
|
15
|
+
name: 'ListRow',
|
|
16
|
+
category: 'pattern',
|
|
17
|
+
directManifestNode: false,
|
|
18
|
+
allowedChildren: [],
|
|
19
|
+
note: LIST_NOTE,
|
|
20
|
+
props: {},
|
|
21
|
+
} as const satisfies ZoraComponentMeta;
|
|
22
|
+
|
|
23
|
+
export const listSectionMeta = {
|
|
24
|
+
name: 'ListSection',
|
|
25
|
+
category: 'pattern',
|
|
26
|
+
directManifestNode: false,
|
|
27
|
+
allowedChildren: [],
|
|
28
|
+
note: LIST_NOTE,
|
|
29
|
+
props: {},
|
|
30
|
+
} as const satisfies ZoraComponentMeta;
|