@ankhorage/zora 22.0.73 → 22.0.74
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 +6 -0
- package/README.md +1 -1
- package/dist/{features/authoring/allowedChildren.d.ts → constants/authoring.d.ts} +40 -1
- package/dist/constants/authoring.d.ts.map +1 -0
- package/dist/{features/authoring/allowedChildren.js → constants/authoring.js} +53 -1
- package/dist/constants/authoring.js.map +1 -0
- package/dist/features/accordion/accordionItemMeta.js +1 -1
- package/dist/features/accordion/accordionItemMeta.js.map +1 -1
- package/dist/features/accordion/accordionMeta.js.map +1 -1
- package/dist/features/activity-indicator/activityIndicatorMeta.js.map +1 -1
- package/dist/features/app-bar/appBarMeta.js.map +1 -1
- package/dist/features/auth/forgotPasswordFormMeta.js.map +1 -1
- package/dist/features/auth/oauthProviderButtonMeta.js.map +1 -1
- package/dist/features/auth/oauthProviderListMeta.js.map +1 -1
- package/dist/features/auth/otpFormMeta.js.map +1 -1
- package/dist/features/auth/signInFormMeta.js.map +1 -1
- package/dist/features/auth/signUpFormMeta.js.map +1 -1
- package/dist/features/bottom-sheet/bottomSheetMeta.js +1 -1
- package/dist/features/bottom-sheet/bottomSheetMeta.js.map +1 -1
- package/dist/features/breadcrumbs/breadcrumbsMeta.js.map +1 -1
- package/dist/features/button/adapters/inbound/Button.d.ts.map +1 -1
- package/dist/features/button/adapters/inbound/Button.js +2 -1
- package/dist/features/button/adapters/inbound/Button.js.map +1 -1
- package/dist/features/button/buttonGroupMeta.js.map +1 -1
- package/dist/features/button/buttonMeta.js +1 -1
- package/dist/features/button/buttonMeta.js.map +1 -1
- package/dist/features/card/adapters/inbound/Card.d.ts.map +1 -1
- package/dist/features/card/adapters/inbound/Card.js +2 -1
- package/dist/features/card/adapters/inbound/Card.js.map +1 -1
- package/dist/features/card/cardMeta.js +2 -2
- package/dist/features/card/cardMeta.js.map +1 -1
- package/dist/features/card/mediaCardMeta.js +1 -1
- package/dist/features/card/mediaCardMeta.js.map +1 -1
- package/dist/features/card/postCardMeta.js +1 -1
- package/dist/features/card/postCardMeta.js.map +1 -1
- package/dist/features/card/productCardMeta.js.map +1 -1
- package/dist/features/chat/chatListItemMeta.js.map +1 -1
- package/dist/features/chat/messageBubbleMeta.js +1 -1
- package/dist/features/chat/messageBubbleMeta.js.map +1 -1
- package/dist/features/collection-editor/meta.js.map +1 -1
- package/dist/features/content-rail/contentRailMeta.js +1 -1
- package/dist/features/content-rail/contentRailMeta.js.map +1 -1
- package/dist/features/date-picker/datePickerMeta.js.map +1 -1
- package/dist/features/dialog/dialogMeta.js +1 -1
- package/dist/features/dialog/dialogMeta.js.map +1 -1
- package/dist/features/empty-state/emptyStateMeta.js.map +1 -1
- package/dist/features/form/checkbox/checkboxMeta.js.map +1 -1
- package/dist/features/form/field/meta.js.map +1 -1
- package/dist/features/form/formActionsMeta.js.map +1 -1
- package/dist/features/form/formErrorMeta.js.map +1 -1
- package/dist/features/form/formMeta.js.map +1 -1
- package/dist/features/form/radio/adapters/inbound/RadioGroup.d.ts.map +1 -1
- package/dist/features/form/radio/adapters/inbound/RadioGroup.js +2 -1
- package/dist/features/form/radio/adapters/inbound/RadioGroup.js.map +1 -1
- package/dist/features/form/radio/radioMeta.js.map +1 -1
- package/dist/features/form/select/selectMeta.js.map +1 -1
- package/dist/features/form/switch/switchMeta.js.map +1 -1
- package/dist/features/form/text-input/textInputMeta.js.map +1 -1
- package/dist/features/game/{adapters/inbound → utils}/measureGameEntity.d.ts +1 -1
- package/dist/features/game/utils/measureGameEntity.d.ts.map +1 -0
- package/dist/features/game/utils/measureGameEntity.js.map +1 -0
- package/dist/features/game/utils/useGameEntityMeasurement.js +1 -1
- package/dist/features/game/utils/useGameEntityMeasurement.js.map +1 -1
- package/dist/features/gradient/gradientMeta.js +1 -1
- package/dist/features/gradient/gradientMeta.js.map +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/GraphNodeOverlay.d.ts +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/GraphNodeOverlay.d.ts.map +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/GraphNodeOverlay.js.map +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/GraphView.d.ts +1 -96
- package/dist/features/graph-view/adapters/inbound/web-artifact/GraphView.d.ts.map +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/GraphView.js.map +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/bindGraphEvents.d.ts +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/bindGraphEvents.d.ts.map +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/bindGraphEvents.js.map +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/createGraphController.d.ts +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/createGraphController.d.ts.map +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/createGraphController.js.map +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/createGraphRuntime.d.ts +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/createGraphRuntime.d.ts.map +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/createGraphRuntime.js.map +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/createRenderableGraphElements.d.ts +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/createRenderableGraphElements.d.ts.map +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/createRenderableGraphElements.js.map +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/fitGraphViewport.d.ts +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/fitGraphViewport.d.ts.map +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/fitGraphViewport.js.map +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/getGraphTopologyKey.d.ts +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/getGraphTopologyKey.d.ts.map +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/getGraphTopologyKey.js.map +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/readGraphRenderedNodes.d.ts +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/readGraphRenderedNodes.d.ts.map +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/readGraphRenderedNodes.js.map +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/runGraphLayout.d.ts +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/runGraphLayout.d.ts.map +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/runGraphLayout.js.map +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/syncGraphElements.d.ts +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/syncGraphElements.d.ts.map +1 -1
- package/dist/features/graph-view/adapters/inbound/web-artifact/syncGraphElements.js.map +1 -1
- package/dist/features/graph-view/public.d.ts +2 -1
- package/dist/features/graph-view/public.d.ts.map +1 -1
- package/dist/features/graph-view/public.js +1 -1
- package/dist/features/graph-view/public.js.map +1 -1
- package/dist/features/hero/heroMeta.js.map +1 -1
- package/dist/features/icon/iconMeta.js.map +1 -1
- package/dist/features/image/imageMeta.js.map +1 -1
- package/dist/features/keyboard-avoiding-view/keyboardAvoidingViewMeta.js +1 -1
- package/dist/features/keyboard-avoiding-view/keyboardAvoidingViewMeta.js.map +1 -1
- package/dist/features/layout/appShellMeta.js.map +1 -1
- package/dist/features/layout/gridMeta.js +1 -1
- package/dist/features/layout/gridMeta.js.map +1 -1
- package/dist/features/layout/screenMeta.js +1 -1
- package/dist/features/layout/screenMeta.js.map +1 -1
- package/dist/features/layout/scrollViewMeta.js +1 -1
- package/dist/features/layout/scrollViewMeta.js.map +1 -1
- package/dist/features/layout/viewMeta.js +1 -1
- package/dist/features/layout/viewMeta.js.map +1 -1
- package/dist/features/list/flatListMeta.js +1 -1
- package/dist/features/list/flatListMeta.js.map +1 -1
- package/dist/features/list/meta.js.map +1 -1
- package/dist/features/missing-element/missingElementMeta.js.map +1 -1
- package/dist/features/palette-item/paletteItemMeta.js.map +1 -1
- package/dist/features/popover-menu/popoverMenuMeta.js.map +1 -1
- package/dist/features/progress/progressMeta.js.map +1 -1
- package/dist/features/reader/meta.js +1 -1
- package/dist/features/reader/meta.js.map +1 -1
- package/dist/features/{authoring → registry}/bindableComponentMeta.d.ts.map +1 -1
- package/dist/features/registry/bindableComponentMeta.js.map +1 -0
- package/dist/features/registry/componentMeta.d.ts.map +1 -0
- package/dist/features/{authoring → registry}/componentMeta.js +1 -1
- package/dist/features/registry/componentMeta.js.map +1 -0
- package/dist/features/{authoring/utils → registry}/createManifestBindings.d.ts +1 -1
- package/dist/features/registry/createManifestBindings.d.ts.map +1 -0
- package/dist/features/registry/createManifestBindings.js.map +1 -0
- package/dist/features/{authoring/utils → registry}/finalizeFeatureMetadata.d.ts +1 -1
- package/dist/features/registry/finalizeFeatureMetadata.d.ts.map +1 -0
- package/dist/features/{authoring/utils → registry}/finalizeFeatureMetadata.js +1 -1
- package/dist/features/registry/finalizeFeatureMetadata.js.map +1 -0
- package/dist/features/{authoring → registry}/index.d.ts +1 -1
- package/dist/features/registry/index.d.ts.map +1 -0
- package/dist/features/{authoring → registry}/index.js +1 -1
- package/dist/features/registry/index.js.map +1 -0
- package/dist/features/registry/themeRecipeMeta.d.ts.map +1 -0
- package/dist/features/registry/themeRecipeMeta.js.map +1 -0
- package/dist/features/scanner/meta.js +1 -1
- package/dist/features/scanner/meta.js.map +1 -1
- package/dist/features/section/screenSectionMeta.js +1 -1
- package/dist/features/section/screenSectionMeta.js.map +1 -1
- package/dist/features/section/sectionHeaderMeta.js.map +1 -1
- package/dist/features/selection/meta.js.map +1 -1
- package/dist/features/skeleton/skeletonMeta.js.map +1 -1
- package/dist/features/surface/surfaceMeta.js +1 -1
- package/dist/features/surface/surfaceMeta.js.map +1 -1
- package/dist/features/tabs/tabPanelMeta.js +1 -1
- package/dist/features/tabs/tabPanelMeta.js.map +1 -1
- package/dist/features/theme/ThemeModeToggle.meta.js.map +1 -1
- package/dist/features/theme/composition/useZoraThemeRecipe.d.ts +3 -1
- package/dist/features/theme/composition/useZoraThemeRecipe.d.ts.map +1 -1
- package/dist/features/theme/composition/useZoraThemeRecipe.js +3 -2
- package/dist/features/theme/composition/useZoraThemeRecipe.js.map +1 -1
- package/dist/features/theme/utils/resolveZoraThemeRecipe.d.ts +3 -1
- package/dist/features/theme/utils/resolveZoraThemeRecipe.d.ts.map +1 -1
- package/dist/features/theme/utils/resolveZoraThemeRecipe.js +6 -6
- package/dist/features/theme/utils/resolveZoraThemeRecipe.js.map +1 -1
- package/dist/features/time-picker/timePickerMeta.js.map +1 -1
- package/dist/features/timeline/meta.js.map +1 -1
- package/dist/features/toast/toastMeta.js.map +1 -1
- package/dist/features/toast/toastProviderMeta.js.map +1 -1
- package/dist/features/tree-view/meta.js.map +1 -1
- package/dist/features/typography/adapters/inbound/Heading.d.ts.map +1 -1
- package/dist/features/typography/adapters/inbound/Heading.js +2 -1
- package/dist/features/typography/adapters/inbound/Heading.js.map +1 -1
- package/dist/features/typography/adapters/inbound/Text.d.ts.map +1 -1
- package/dist/features/typography/adapters/inbound/Text.js +2 -1
- package/dist/features/typography/adapters/inbound/Text.js.map +1 -1
- package/dist/features/typography/headingMeta.js +1 -1
- package/dist/features/typography/headingMeta.js.map +1 -1
- package/dist/features/typography/textMeta.js +1 -1
- package/dist/features/typography/textMeta.js.map +1 -1
- package/dist/index.d.ts +2 -2
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/types/auth.d.ts +1 -1
- package/dist/types/auth.d.ts.map +1 -1
- package/dist/types/auth.js.map +1 -1
- package/dist/types/avatar-group.d.ts +1 -1
- package/dist/types/avatar-group.d.ts.map +1 -1
- package/dist/types/avatar-group.js.map +1 -1
- package/dist/types/button-group.d.ts +1 -1
- package/dist/types/button-group.d.ts.map +1 -1
- package/dist/types/button-group.js.map +1 -1
- package/dist/types/chat.d.ts +1 -1
- package/dist/types/chat.d.ts.map +1 -1
- package/dist/types/chat.js.map +1 -1
- package/dist/types/gradient.d.ts +1 -1
- package/dist/types/gradient.d.ts.map +1 -1
- package/dist/types/gradient.js.map +1 -1
- package/dist/types/graph-view.d.ts +98 -0
- package/dist/types/graph-view.d.ts.map +1 -0
- package/dist/types/graph-view.js +2 -0
- package/dist/types/graph-view.js.map +1 -0
- package/dist/types/graphViewRuntime.d.ts +1 -1
- package/dist/types/graphViewRuntime.d.ts.map +1 -1
- package/dist/types/graphViewRuntime.js.map +1 -1
- package/dist/types/post-card.d.ts +1 -1
- package/dist/types/post-card.d.ts.map +1 -1
- package/dist/types/post-card.js.map +1 -1
- package/dist/types/radio.d.ts +1 -1
- package/dist/types/radio.d.ts.map +1 -1
- package/dist/types/radio.js.map +1 -1
- package/dist/types/scanner.d.ts +1 -1
- package/dist/types/scanner.d.ts.map +1 -1
- package/dist/types/scanner.js.map +1 -1
- package/dist/types/skeleton.d.ts +1 -1
- package/dist/types/skeleton.d.ts.map +1 -1
- package/dist/types/skeleton.js.map +1 -1
- package/dist/types/theme-mode-toggle.d.ts +1 -1
- package/dist/types/theme-mode-toggle.d.ts.map +1 -1
- package/dist/types/theme-mode-toggle.js.map +1 -1
- package/package.json +12 -12
- package/src/{features/authoring/allowedChildren.ts → constants/authoring.ts} +55 -0
- package/src/features/accordion/accordionItemMeta.ts +2 -2
- package/src/features/accordion/accordionMeta.ts +1 -1
- package/src/features/activity-indicator/activityIndicatorMeta.ts +1 -1
- package/src/features/app-bar/appBarMeta.ts +1 -1
- package/src/features/auth/forgotPasswordFormMeta.ts +1 -1
- package/src/features/auth/oauthProviderButtonMeta.ts +1 -1
- package/src/features/auth/oauthProviderListMeta.ts +1 -1
- package/src/features/auth/otpFormMeta.ts +1 -1
- package/src/features/auth/public.test.ts +21 -18
- package/src/features/auth/signInFormMeta.ts +1 -1
- package/src/features/auth/signUpFormMeta.ts +1 -1
- package/src/features/bottom-sheet/bottomSheetMeta.ts +1 -1
- package/src/features/breadcrumbs/breadcrumbsMeta.ts +1 -1
- package/src/features/button/adapters/inbound/Button.tsx +2 -1
- package/src/features/button/buttonGroupMeta.ts +1 -1
- package/src/features/button/buttonMeta.ts +2 -2
- package/src/features/card/adapters/inbound/Card.tsx +2 -1
- package/src/features/card/adapters/inbound/PostCard.test.tsx +4 -4
- package/src/features/card/adapters/inbound/ProductCard.test.tsx +9 -9
- package/src/features/card/cardMeta.ts +3 -3
- package/src/features/card/mediaCardMeta.ts +1 -1
- package/src/features/card/postCardMeta.ts +2 -2
- package/src/features/card/productCardMeta.ts +1 -1
- package/src/features/chat/adapters/inbound/ChatListItem.test.tsx +4 -4
- package/src/features/chat/chatListItemMeta.ts +1 -1
- package/src/features/chat/messageBubbleMeta.ts +2 -2
- package/src/features/collection-editor/meta.ts +1 -1
- package/src/features/content-rail/contentRailMeta.ts +2 -2
- package/src/features/date-picker/datePickerMeta.ts +1 -1
- package/src/features/date-picker/public.test.ts +4 -6
- package/src/features/dialog/dialogMeta.ts +1 -1
- package/src/features/empty-state/emptyStateMeta.ts +1 -1
- package/src/features/form/checkbox/checkboxMeta.ts +1 -1
- package/src/features/form/field/meta.ts +1 -1
- package/src/features/form/formActionsMeta.ts +1 -1
- package/src/features/form/formErrorMeta.ts +1 -1
- package/src/features/form/formMeta.ts +1 -1
- package/src/features/form/radio/adapters/inbound/RadioGroup.tsx +2 -1
- package/src/features/form/radio/radioMeta.ts +1 -1
- package/src/features/form/select/selectMeta.ts +1 -1
- package/src/features/form/switch/switchMeta.ts +1 -1
- package/src/features/form/text-input/textInputMeta.ts +1 -1
- package/src/features/game/{adapters/inbound → utils}/measureGameEntity.ts +1 -1
- package/src/features/game/utils/useGameEntityMeasurement.ts +1 -1
- package/src/features/gradient/gradientMeta.ts +2 -2
- package/src/features/gradient/public.test.ts +4 -6
- package/src/features/graph-view/adapters/inbound/web-artifact/GraphNodeOverlay.tsx +1 -1
- package/src/features/graph-view/adapters/inbound/web-artifact/GraphView.tsx +6 -116
- package/src/features/graph-view/adapters/inbound/web-artifact/bindGraphEvents.ts +1 -1
- package/src/features/graph-view/adapters/inbound/web-artifact/createGraphController.ts +1 -1
- package/src/features/graph-view/adapters/inbound/web-artifact/createGraphRuntime.test.ts +2 -2
- package/src/features/graph-view/adapters/inbound/web-artifact/createGraphRuntime.ts +8 -8
- package/src/features/graph-view/adapters/inbound/web-artifact/createRenderableGraphElements.test.ts +1 -1
- package/src/features/graph-view/adapters/inbound/web-artifact/createRenderableGraphElements.ts +1 -1
- package/src/features/graph-view/adapters/inbound/web-artifact/fitGraphViewport.ts +1 -1
- package/src/features/graph-view/adapters/inbound/web-artifact/getGraphTopologyKey.ts +1 -1
- package/src/features/graph-view/adapters/inbound/web-artifact/readGraphRenderedNodes.ts +1 -1
- package/src/features/graph-view/adapters/inbound/web-artifact/runGraphLayout.ts +1 -1
- package/src/features/graph-view/adapters/inbound/web-artifact/syncGraphElements.ts +1 -1
- package/src/features/graph-view/public.ts +18 -18
- package/src/features/hero/heroMeta.ts +1 -1
- package/src/features/icon/iconMeta.ts +1 -1
- package/src/features/icon/utils/meta.test.ts +8 -17
- package/src/features/image/imageMeta.ts +1 -1
- package/src/features/keyboard-avoiding-view/keyboardAvoidingViewMeta.ts +1 -1
- package/src/features/layout/appShellMeta.ts +1 -1
- package/src/features/layout/gridMeta.ts +2 -2
- package/src/features/layout/screenMeta.ts +2 -2
- package/src/features/layout/scrollViewMeta.ts +1 -1
- package/src/features/layout/viewMeta.ts +2 -2
- package/src/features/list/flatListMeta.ts +1 -1
- package/src/features/list/meta.ts +1 -1
- package/src/features/missing-element/MissingElement.test.ts +7 -6
- package/src/features/missing-element/missingElementMeta.ts +1 -1
- package/src/features/palette-item/paletteItemMeta.ts +1 -1
- package/src/features/popover-menu/popoverMenuMeta.ts +1 -1
- package/src/features/progress/progressMeta.ts +1 -1
- package/src/features/reader/meta.ts +2 -2
- package/src/features/{authoring → registry}/componentMeta.ts +1 -1
- package/src/features/{authoring/utils → registry}/createManifestBindings.ts +1 -1
- package/src/features/{authoring → registry}/featureManifest.test.ts +1 -1
- package/src/features/{authoring/utils → registry}/finalizeFeatureMetadata.ts +2 -2
- package/src/features/{authoring → registry}/index.ts +1 -1
- package/src/features/scanner/meta.ts +2 -2
- package/src/features/section/screenSectionMeta.ts +2 -2
- package/src/features/section/sectionHeaderMeta.ts +1 -1
- package/src/features/selection/meta.ts +1 -1
- package/src/features/skeleton/public.test.ts +6 -6
- package/src/features/skeleton/skeletonMeta.ts +1 -1
- package/src/features/surface/surfaceMeta.ts +1 -1
- package/src/features/tabs/tabPanelMeta.ts +1 -1
- package/src/features/theme/ThemeModeToggle.meta.ts +1 -1
- package/src/features/theme/composition/useZoraThemeRecipe.ts +4 -2
- package/src/features/theme/utils/resolveZoraThemeRecipe.test.ts +45 -8
- package/src/features/theme/utils/resolveZoraThemeRecipe.ts +11 -8
- package/src/features/time-picker/public.test.ts +4 -6
- package/src/features/time-picker/timePickerMeta.ts +1 -1
- package/src/features/timeline/meta.ts +1 -1
- package/src/features/toast/public.test.ts +4 -3
- package/src/features/toast/toastMeta.ts +1 -1
- package/src/features/toast/toastProviderMeta.ts +1 -1
- package/src/features/tree-view/meta.ts +1 -1
- package/src/features/typography/adapters/inbound/Heading.tsx +2 -1
- package/src/features/typography/adapters/inbound/Text.tsx +2 -1
- package/src/features/typography/headingMeta.ts +2 -2
- package/src/features/typography/textMeta.ts +2 -2
- package/src/features/uploader/public.test.ts +1 -1
- package/src/index.ts +33 -33
- package/src/structureOwnership.test.ts +3 -3
- package/src/types/auth.ts +1 -1
- package/src/types/avatar-group.ts +1 -1
- package/src/types/button-group.ts +1 -1
- package/src/types/chat.ts +1 -1
- package/src/types/gradient.ts +1 -1
- package/src/types/graph-view.ts +117 -0
- package/src/types/graphViewRuntime.ts +1 -1
- package/src/types/post-card.ts +1 -1
- package/src/types/radio.ts +1 -1
- package/src/types/scanner.ts +1 -1
- package/src/types/skeleton.ts +1 -1
- package/src/types/theme-mode-toggle.ts +1 -1
- package/web-dist/chunks/{Accordion-jd33dw92.js → Accordion-07rdw2vh.js} +1 -1
- package/web-dist/chunks/{Accordion-sn80af3k.js → Accordion-45ej9brb.js} +1 -1
- package/web-dist/chunks/{Accordion-qyckg9d2.js → Accordion-555gnfmw.js} +3 -3
- package/web-dist/chunks/{Accordion-ypdtx57y.js → Accordion-73m7z73v.js} +3 -3
- package/web-dist/chunks/{Accordion-s334j5tf.js → Accordion-8af800ts.js} +2 -2
- package/web-dist/chunks/{Accordion-7ycn5332.js → Accordion-9rnepkvk.js} +1 -1
- package/web-dist/chunks/{Accordion-1vbm971q.js → Accordion-avmgvcef.js} +1 -1
- package/web-dist/chunks/{Accordion-a03xpbc0.js → Accordion-b3qy1trj.js} +39 -7
- package/web-dist/chunks/Accordion-e1nn8m46.js +82 -0
- package/web-dist/chunks/{Accordion-eps4ej1m.js → Accordion-emczc5rg.js} +33 -5
- package/web-dist/chunks/{Accordion-wzybs1e3.js → Accordion-jhwsvx3g.js} +1 -1
- package/web-dist/chunks/{Accordion-qy22k9t8.js → Accordion-jj3bg8c1.js} +1 -1
- package/web-dist/chunks/{Accordion-nn80tt99.js → Accordion-mpnb4qqw.js} +2 -2
- package/web-dist/chunks/{Accordion-z5rdysmt.js → Accordion-nc5gnvnb.js} +33 -4
- package/web-dist/chunks/{Accordion-qkrwkab6.js → Accordion-nn38n7q4.js} +1 -1
- package/web-dist/chunks/{Accordion-zh8esf04.js → Accordion-pnvt10cv.js} +2 -2
- package/web-dist/chunks/{Accordion-4prv90j4.js → Accordion-qvt6qdqm.js} +1 -1
- package/web-dist/chunks/{Accordion-hk6zs4dc.js → Accordion-tj61sa5s.js} +2 -2
- package/web-dist/chunks/{Accordion-5r2dxq03.js → Accordion-v1dtv6v0.js} +1 -1
- package/web-dist/chunks/{Accordion-5t5sw5cp.js → Accordion-vmz8y01b.js} +4 -4
- package/web-dist/chunks/{Accordion-pssgp0pq.js → Accordion-ycmg06sq.js} +71 -4
- package/web-dist/chunks/{Accordion-h62mzp3n.js → Accordion-yz7b7njb.js} +2 -2
- package/web-dist/chunks/{Accordion-2ga47602.js → Accordion-zf3kzvef.js} +1 -1
- package/web-dist/components/accordion/Accordion.js +3 -3
- package/web-dist/components/accordion-item/AccordionItem.js +3 -3
- package/web-dist/components/app-bar/AppBar.js +4 -4
- package/web-dist/components/avatar/Avatar.js +3 -3
- package/web-dist/components/avatar-group/AvatarGroup.js +3 -3
- package/web-dist/components/barcode-scanner-view/BarcodeScannerView.js +6 -6
- package/web-dist/components/breadcrumbs/Breadcrumbs.js +3 -3
- package/web-dist/components/button/Button.js +2 -2
- package/web-dist/components/button-group/ButtonGroup.js +2 -2
- package/web-dist/components/camera-permission-view/CameraPermissionView.js +6 -6
- package/web-dist/components/card/Card.js +5 -5
- package/web-dist/components/chat-list-item/ChatListItem.js +4 -4
- package/web-dist/components/checkbox/Checkbox.js +3 -3
- package/web-dist/components/checkbox-group/CheckboxGroup.js +3 -3
- package/web-dist/components/chip/Chip.js +3 -3
- package/web-dist/components/chip-group/ChipGroup.js +3 -3
- package/web-dist/components/collection-editor/CollectionEditor.js +5 -5
- package/web-dist/components/content-rail/ContentRail.js +3 -3
- package/web-dist/components/data-table/DataTable.js +9 -9
- package/web-dist/components/date-picker/DatePicker.js +3 -3
- package/web-dist/components/dialog/Dialog.js +3 -3
- package/web-dist/components/empty-state/EmptyState.js +6 -6
- package/web-dist/components/field/Field.js +3 -3
- package/web-dist/components/flat-list/FlatList.js +4 -4
- package/web-dist/components/forgot-password-form/ForgotPasswordForm.js +7 -7
- package/web-dist/components/form/Form.js +5 -5
- package/web-dist/components/form-actions/FormActions.js +5 -5
- package/web-dist/components/form-error/FormError.js +5 -5
- package/web-dist/components/game/Game.js +1 -1
- package/web-dist/components/game-entity/GameEntity.js +1 -1
- package/web-dist/components/game-field/GameField.js +1 -1
- package/web-dist/components/game-input-zone/GameInputZone.js +1 -1
- package/web-dist/components/game-measurement-probe/GameMeasurementProbe.js +1 -1
- package/web-dist/components/game-overlay/GameOverlay.js +1 -1
- package/web-dist/components/graph-view/GraphView.d.ts +1 -96
- package/web-dist/components/heading/Heading.js +2 -2
- package/web-dist/components/hero/Hero.js +5 -5
- package/web-dist/components/icon-button/IconButton.js +2 -2
- package/web-dist/components/list/List.js +4 -4
- package/web-dist/components/list-item/ListItem.js +4 -4
- package/web-dist/components/list-section/ListSection.js +4 -4
- package/web-dist/components/media-card/MediaCard.js +5 -5
- package/web-dist/components/message-bubble/MessageBubble.js +4 -4
- package/web-dist/components/metric-card/MetricCard.js +5 -5
- package/web-dist/components/missing-element/MissingElement.js +2 -2
- package/web-dist/components/o-auth-provider-button/OAuthProviderButton.js +7 -7
- package/web-dist/components/o-auth-provider-list/OAuthProviderList.js +7 -7
- package/web-dist/components/otp-form/OtpForm.js +7 -7
- package/web-dist/components/pagination/Pagination.js +3 -3
- package/web-dist/components/palette-item/PaletteItem.js +5 -5
- package/web-dist/components/post-card/PostCard.js +5 -5
- package/web-dist/components/product-card/ProductCard.js +5 -5
- package/web-dist/components/progress/Progress.js +3 -3
- package/web-dist/components/progress-ring/ProgressRing.js +3 -3
- package/web-dist/components/radio/Radio.js +3 -3
- package/web-dist/components/radio-group/RadioGroup.js +3 -3
- package/web-dist/components/reader-surface/ReaderSurface.js +5 -5
- package/web-dist/components/scan-overlay/ScanOverlay.js +6 -6
- package/web-dist/components/screen-section/ScreenSection.js +3 -3
- package/web-dist/components/search-input/SearchInput.js +3 -3
- package/web-dist/components/section-header/SectionHeader.js +3 -3
- package/web-dist/components/section-list/SectionList.js +4 -4
- package/web-dist/components/select/Select.js +2 -2
- package/web-dist/components/sign-in-form/SignInForm.js +7 -7
- package/web-dist/components/sign-up-form/SignUpForm.js +7 -7
- package/web-dist/components/skeleton/Skeleton.js +8 -8
- package/web-dist/components/skeleton-card/SkeletonCard.js +8 -8
- package/web-dist/components/skeleton-list/SkeletonList.js +8 -8
- package/web-dist/components/skeleton-text/SkeletonText.js +8 -8
- package/web-dist/components/text/Text.js +2 -2
- package/web-dist/components/text-input/TextInput.js +3 -3
- package/web-dist/components/time-picker/TimePicker.js +3 -3
- package/web-dist/components/timeline/Timeline.js +2 -2
- package/web-dist/components/toolbar/Toolbar.js +5 -5
- package/web-dist/components/tree-item/TreeItem.js +5 -5
- package/web-dist/components/uploader/Uploader.js +7 -7
- package/web-dist/manifest.json +354 -354
- package/dist/features/authoring/allowedChildren.d.ts.map +0 -1
- package/dist/features/authoring/allowedChildren.js.map +0 -1
- package/dist/features/authoring/bindableComponentMeta.js.map +0 -1
- package/dist/features/authoring/componentMeta.d.ts.map +0 -1
- package/dist/features/authoring/componentMeta.js.map +0 -1
- package/dist/features/authoring/constants.d.ts +0 -40
- package/dist/features/authoring/constants.d.ts.map +0 -1
- package/dist/features/authoring/constants.js +0 -53
- package/dist/features/authoring/constants.js.map +0 -1
- package/dist/features/authoring/index.d.ts.map +0 -1
- package/dist/features/authoring/index.js.map +0 -1
- package/dist/features/authoring/themeRecipeMeta.d.ts.map +0 -1
- package/dist/features/authoring/themeRecipeMeta.js.map +0 -1
- package/dist/features/authoring/utils/createManifestBindings.d.ts.map +0 -1
- package/dist/features/authoring/utils/createManifestBindings.js.map +0 -1
- package/dist/features/authoring/utils/finalizeFeatureMetadata.d.ts.map +0 -1
- package/dist/features/authoring/utils/finalizeFeatureMetadata.js.map +0 -1
- package/dist/features/game/adapters/inbound/measureGameEntity.d.ts.map +0 -1
- package/dist/features/game/adapters/inbound/measureGameEntity.js.map +0 -1
- package/src/features/authoring/constants.ts +0 -56
- package/web-dist/chunks/Accordion-wvphg9x4.js +0 -246
- /package/dist/features/game/{adapters/inbound → utils}/measureGameEntity.js +0 -0
- /package/dist/features/{authoring → registry}/bindableComponentMeta.d.ts +0 -0
- /package/dist/features/{authoring → registry}/bindableComponentMeta.js +0 -0
- /package/dist/features/{authoring → registry}/componentMeta.d.ts +0 -0
- /package/dist/features/{authoring/utils → registry}/createManifestBindings.js +0 -0
- /package/dist/features/{authoring → registry}/themeRecipeMeta.d.ts +0 -0
- /package/dist/features/{authoring → registry}/themeRecipeMeta.js +0 -0
- /package/src/features/{authoring → registry}/authoringMeta.test.ts +0 -0
- /package/src/features/{authoring → registry}/bindableComponentMeta.test.ts +0 -0
- /package/src/features/{authoring → registry}/bindableComponentMeta.ts +0 -0
- /package/src/features/{authoring → registry}/componentMeta.test.ts +0 -0
- /package/src/features/{authoring → registry}/radioGroupReachability.test.ts +0 -0
- /package/src/features/{authoring → registry}/themeRecipeMeta.test.ts +0 -0
- /package/src/features/{authoring → registry}/themeRecipeMeta.ts +0 -0
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { describe, expect, test } from 'bun:test';
|
|
2
2
|
|
|
3
|
-
import {
|
|
3
|
+
import { postCardMeta } from '../../postCardMeta';
|
|
4
4
|
|
|
5
5
|
describe('PostCard', () => {
|
|
6
6
|
test('is registered as a public ZORA pattern', () => {
|
|
7
|
-
expect(
|
|
8
|
-
expect(
|
|
9
|
-
expect(
|
|
7
|
+
expect(postCardMeta.name).toBe('PostCard');
|
|
8
|
+
expect(postCardMeta.category).toBe('pattern');
|
|
9
|
+
expect(postCardMeta.directManifestNode).toBe(true);
|
|
10
10
|
});
|
|
11
11
|
});
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
import { describe, expect, test } from 'bun:test';
|
|
2
2
|
|
|
3
|
-
import {
|
|
3
|
+
import { productCardMeta } from '../../productCardMeta';
|
|
4
4
|
|
|
5
5
|
describe('ProductCard', () => {
|
|
6
6
|
test('is registered as a public ZORA pattern', () => {
|
|
7
|
-
expect(
|
|
8
|
-
expect(
|
|
9
|
-
expect(
|
|
10
|
-
expect(
|
|
11
|
-
expect(
|
|
7
|
+
expect(productCardMeta.name).toBe('ProductCard');
|
|
8
|
+
expect(productCardMeta.category).toBe('pattern');
|
|
9
|
+
expect(productCardMeta.directManifestNode).toBe(true);
|
|
10
|
+
expect(productCardMeta.allowedChildren).toEqual([]);
|
|
11
|
+
expect(productCardMeta.requirements).toBeUndefined();
|
|
12
12
|
});
|
|
13
13
|
|
|
14
14
|
test('has correct event metadata', () => {
|
|
15
|
-
expect(
|
|
16
|
-
expect(
|
|
17
|
-
expect(
|
|
15
|
+
expect(productCardMeta.events.press).toBeDefined();
|
|
16
|
+
expect(productCardMeta.events.primaryAction).toBeDefined();
|
|
17
|
+
expect(productCardMeta.events.secondaryAction).toBeDefined();
|
|
18
18
|
});
|
|
19
19
|
});
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import type { ZoraComponentMeta } from '../authoring';
|
|
2
1
|
import {
|
|
3
2
|
CHESS_ALLOWED_CHILDREN,
|
|
4
3
|
CONTAINER_ALLOWED_CHILDREN,
|
|
5
4
|
GAME_ALLOWED_CHILDREN,
|
|
6
5
|
TABLETOP_ALLOWED_CHILDREN,
|
|
7
|
-
} from '
|
|
8
|
-
import { COMPONENT_THEME_AUTHORING } from '
|
|
6
|
+
} from '../../constants/authoring';
|
|
7
|
+
import { COMPONENT_THEME_AUTHORING } from '../../constants/authoring';
|
|
8
|
+
import type { ZoraComponentMeta } from '../../types/authoring';
|
|
9
9
|
|
|
10
10
|
export const cardMeta = {
|
|
11
11
|
name: 'Card',
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
+
import { CONTAINER_ALLOWED_CHILDREN } from '../../constants/authoring';
|
|
1
2
|
import type { ZoraComponentMeta } from '../../types/authoring';
|
|
2
|
-
import { CONTAINER_ALLOWED_CHILDREN } from '../authoring/allowedChildren';
|
|
3
3
|
|
|
4
4
|
export const mediaCardMeta = {
|
|
5
5
|
name: 'MediaCard',
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
1
|
+
import { CONTAINER_ALLOWED_CHILDREN } from '../../constants/authoring';
|
|
2
|
+
import type { ZoraComponentMeta } from '../../types/authoring';
|
|
3
3
|
|
|
4
4
|
export const postCardMeta = {
|
|
5
5
|
name: 'PostCard',
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { describe, expect, test } from 'bun:test';
|
|
2
2
|
|
|
3
|
-
import {
|
|
3
|
+
import { chatListItemMeta } from '../../chatListItemMeta';
|
|
4
4
|
|
|
5
5
|
describe('ChatListItem', () => {
|
|
6
6
|
test('is registered as a public ZORA pattern', () => {
|
|
7
|
-
expect(
|
|
8
|
-
expect(
|
|
9
|
-
expect(
|
|
7
|
+
expect(chatListItemMeta.name).toBe('ChatListItem');
|
|
8
|
+
expect(chatListItemMeta.category).toBe('pattern');
|
|
9
|
+
expect(chatListItemMeta.directManifestNode).toBe(true);
|
|
10
10
|
});
|
|
11
11
|
});
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
1
|
+
import { CONTAINER_ALLOWED_CHILDREN } from '../../constants/authoring';
|
|
2
|
+
import type { ZoraComponentMeta } from '../../types/authoring';
|
|
3
3
|
|
|
4
4
|
export const messageBubbleMeta = {
|
|
5
5
|
name: 'MessageBubble',
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
1
|
+
import { CONTENT_RAIL_ALLOWED_CHILDREN } from '../../constants/authoring';
|
|
2
|
+
import type { ZoraComponentMeta } from '../../types/authoring';
|
|
3
3
|
import { CONTENT_RAIL_SPACING_VALUES } from './constants';
|
|
4
4
|
|
|
5
5
|
export const contentRailMeta = {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { expect, test } from 'bun:test';
|
|
2
2
|
|
|
3
|
-
import {
|
|
3
|
+
import { datePickerMeta } from './datePickerMeta';
|
|
4
4
|
|
|
5
5
|
test('DatePicker keeps one manifest contract across native and web presentation hosts', async () => {
|
|
6
6
|
const nativeSource = await Bun.file(
|
|
@@ -12,12 +12,10 @@ test('DatePicker keeps one manifest contract across native and web presentation
|
|
|
12
12
|
const contentSource = await Bun.file(
|
|
13
13
|
'src/features/date-picker/composition/DatePickerContent.tsx',
|
|
14
14
|
).text();
|
|
15
|
-
const meta = ZORA_COMPONENT_META.DatePicker;
|
|
16
15
|
|
|
17
|
-
expect(
|
|
18
|
-
expect(
|
|
19
|
-
expect(
|
|
20
|
-
expect(meta.bindings?.props?.value?.value.type).toBe('string');
|
|
16
|
+
expect(datePickerMeta.directManifestNode).toBe(true);
|
|
17
|
+
expect(datePickerMeta.props.value.type).toBe('string');
|
|
18
|
+
expect(datePickerMeta.events.valueChange.eventType).toBe('datePicker.valueChange');
|
|
21
19
|
expect(nativeSource).toContain('useBottomSheet()');
|
|
22
20
|
expect(webSource).toContain('<Popover');
|
|
23
21
|
expect(webSource).not.toContain('useBottomSheet');
|
|
@@ -7,6 +7,7 @@ import { View } from '../../../../layout/public';
|
|
|
7
7
|
import { withZoraThemeScope } from '../../../../theme/adapters/inbound/withZoraThemeScope';
|
|
8
8
|
import { useZoraThemeRecipe } from '../../../../theme/composition/useZoraThemeRecipe';
|
|
9
9
|
import { Text } from '../../../../typography/public';
|
|
10
|
+
import { radioGroupThemeRecipeMeta } from '../../themeRecipeMeta';
|
|
10
11
|
import { resolveRadioGroupThemeRecipe } from '../../utils/resolveRadioGroupThemeRecipe';
|
|
11
12
|
import { RadioOptionControl } from './RadioOptionControl';
|
|
12
13
|
|
|
@@ -25,7 +26,7 @@ function RadioGroupInner<TValue extends string>({
|
|
|
25
26
|
props.onValueChange?.(next);
|
|
26
27
|
};
|
|
27
28
|
const selectedProps = { ...props, value: props.value ?? localValue, onValueChange };
|
|
28
|
-
const themeFields = useZoraThemeRecipe(
|
|
29
|
+
const themeFields = useZoraThemeRecipe(radioGroupThemeRecipeMeta);
|
|
29
30
|
const recipe = resolveRadioGroupThemeRecipe({ ...props, themeFields });
|
|
30
31
|
if (props.presentation !== 'card') return <RadioGroupInline {...selectedProps} {...recipe} />;
|
|
31
32
|
const columns =
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { View } from 'react-native';
|
|
2
2
|
|
|
3
|
-
import type { GameMeasurementBounds } from '
|
|
3
|
+
import type { GameMeasurementBounds } from '../../../types/gameRuntime';
|
|
4
4
|
|
|
5
5
|
/*** Measure one rendered React Native or React Native Web game entity in window coordinates. */
|
|
6
6
|
export function measureGameEntity(
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { View } from 'react-native';
|
|
3
3
|
|
|
4
|
-
import { measureGameEntity } from '../adapters/inbound/measureGameEntity';
|
|
5
4
|
import { GameRuntimeContext } from '../composition/GameRuntimeContext';
|
|
5
|
+
import { measureGameEntity } from './measureGameEntity';
|
|
6
6
|
|
|
7
7
|
/*** Register one optional measurable GameEntity view inside its local Game scope. */
|
|
8
8
|
export function useGameEntityMeasurement(
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
1
|
+
import { CONTAINER_ALLOWED_CHILDREN } from '../../constants/authoring';
|
|
2
|
+
import type { ZoraComponentMeta } from '../../types/authoring';
|
|
3
3
|
|
|
4
4
|
export const gradientMeta = {
|
|
5
5
|
name: 'Gradient',
|
|
@@ -1,13 +1,11 @@
|
|
|
1
1
|
import { expect, test } from 'bun:test';
|
|
2
2
|
|
|
3
|
-
import {
|
|
3
|
+
import { gradientMeta } from './gradientMeta';
|
|
4
4
|
|
|
5
5
|
test('Gradient is a direct manifest container with serializable colors', () => {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
expect(
|
|
9
|
-
expect(meta?.allowedChildren.length).toBeGreaterThan(0);
|
|
10
|
-
expect(meta?.props.colors).toEqual({
|
|
6
|
+
expect(gradientMeta.directManifestNode).toBe(true);
|
|
7
|
+
expect(gradientMeta.allowedChildren.length).toBeGreaterThan(0);
|
|
8
|
+
expect(gradientMeta.props.colors).toEqual({
|
|
11
9
|
type: 'array',
|
|
12
10
|
category: 'Style',
|
|
13
11
|
label: 'Colors',
|
|
@@ -1,125 +1,15 @@
|
|
|
1
1
|
import type { CytoscapeOptions } from 'cytoscape';
|
|
2
2
|
import React from 'react';
|
|
3
3
|
|
|
4
|
+
import type {
|
|
5
|
+
GraphViewCallbacks,
|
|
6
|
+
GraphViewNode,
|
|
7
|
+
GraphViewProps,
|
|
8
|
+
GraphViewRenderedNode,
|
|
9
|
+
} from '../../../../../types/graph-view';
|
|
4
10
|
import { createGraphRuntime, type GraphRuntime } from './createGraphRuntime';
|
|
5
11
|
import { GraphNodeOverlay } from './GraphNodeOverlay';
|
|
6
12
|
|
|
7
|
-
export type GraphViewLayoutName = 'breadthfirst' | 'circle' | 'concentric' | 'elk' | 'grid';
|
|
8
|
-
export type GraphViewElementEventType =
|
|
9
|
-
'press' | 'double-press' | 'select' | 'unselect' | 'pointer-enter' | 'pointer-leave';
|
|
10
|
-
|
|
11
|
-
export interface GraphViewNode {
|
|
12
|
-
readonly id: string;
|
|
13
|
-
readonly label?: string;
|
|
14
|
-
readonly parentId?: string;
|
|
15
|
-
readonly classes?: string;
|
|
16
|
-
readonly data?: Readonly<Record<string, unknown>>;
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
export interface GraphViewEdge {
|
|
20
|
-
readonly id?: string;
|
|
21
|
-
readonly source: string;
|
|
22
|
-
readonly target: string;
|
|
23
|
-
readonly classes?: string;
|
|
24
|
-
readonly data?: Readonly<Record<string, unknown>>;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
export interface GraphViewStyleRule {
|
|
28
|
-
readonly selector: string;
|
|
29
|
-
readonly style: Readonly<Record<string, unknown>>;
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
export interface GraphViewPoint {
|
|
33
|
-
readonly x: number;
|
|
34
|
-
readonly y: number;
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
export interface GraphViewSize {
|
|
38
|
-
readonly width: number;
|
|
39
|
-
readonly height: number;
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
export interface GraphViewNodeRenderContext {
|
|
43
|
-
readonly hovered: boolean;
|
|
44
|
-
readonly node: GraphViewNode;
|
|
45
|
-
readonly selected: boolean;
|
|
46
|
-
readonly zoom: number;
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
export interface GraphViewRenderedNode {
|
|
50
|
-
readonly hovered: boolean;
|
|
51
|
-
readonly id: string;
|
|
52
|
-
readonly position: GraphViewPoint;
|
|
53
|
-
readonly selected: boolean;
|
|
54
|
-
readonly zoom: number;
|
|
55
|
-
}
|
|
56
|
-
|
|
57
|
-
export interface GraphViewViewport {
|
|
58
|
-
readonly zoom: number;
|
|
59
|
-
readonly pan: GraphViewPoint;
|
|
60
|
-
}
|
|
61
|
-
|
|
62
|
-
export interface GraphViewFitOptions {
|
|
63
|
-
/** Optimize existing layout spacing without rerunning its algorithm; whole-graph fits only. */
|
|
64
|
-
readonly optimizeSpacing?: boolean;
|
|
65
|
-
readonly nodeIds?: readonly string[];
|
|
66
|
-
readonly padding?: number;
|
|
67
|
-
}
|
|
68
|
-
|
|
69
|
-
export interface GraphViewElementEvent {
|
|
70
|
-
readonly id: string;
|
|
71
|
-
readonly type: GraphViewElementEventType;
|
|
72
|
-
}
|
|
73
|
-
|
|
74
|
-
export interface GraphViewController {
|
|
75
|
-
fit(options?: GraphViewFitOptions): void;
|
|
76
|
-
getViewport(): GraphViewViewport;
|
|
77
|
-
getZoomRange(): { readonly min: number; readonly max: number };
|
|
78
|
-
setPan(pan: GraphViewPoint): void;
|
|
79
|
-
setZoom(zoom: number): void;
|
|
80
|
-
zoomBy(factor: number): void;
|
|
81
|
-
}
|
|
82
|
-
|
|
83
|
-
export interface GraphViewProps {
|
|
84
|
-
readonly nodes: readonly GraphViewNode[];
|
|
85
|
-
readonly edges: readonly GraphViewEdge[];
|
|
86
|
-
readonly layout?: GraphViewLayoutName;
|
|
87
|
-
readonly layoutOptions?: Readonly<Record<string, unknown>>;
|
|
88
|
-
readonly spacingFactor?: number;
|
|
89
|
-
readonly styleRules?: readonly GraphViewStyleRule[];
|
|
90
|
-
readonly selectedNodeIds?: readonly string[];
|
|
91
|
-
readonly renderNode?: (context: GraphViewNodeRenderContext) => React.ReactNode;
|
|
92
|
-
readonly getNodeSize?: (node: GraphViewNode) => GraphViewSize | undefined;
|
|
93
|
-
readonly fitPadding?: number;
|
|
94
|
-
readonly minZoom?: number;
|
|
95
|
-
readonly maxZoom?: number;
|
|
96
|
-
readonly minReadableLabelSize?: number;
|
|
97
|
-
readonly maxFitLabelSize?: number;
|
|
98
|
-
/** Zoom values and bounds use the full-node fit as 1 when fit-relative is selected. */
|
|
99
|
-
readonly zoomMode?: 'absolute' | 'fit-relative';
|
|
100
|
-
/** Measure plain labels before layout instead of estimating width from character count. */
|
|
101
|
-
readonly sizeNodesToLabels?: boolean;
|
|
102
|
-
readonly className?: string;
|
|
103
|
-
readonly style?: React.CSSProperties;
|
|
104
|
-
readonly ariaLabel?: string;
|
|
105
|
-
readonly onReady?: (controller: GraphViewController) => void;
|
|
106
|
-
readonly onLayoutComplete?: (controller: GraphViewController) => void;
|
|
107
|
-
readonly onNodeEvent?: (event: GraphViewElementEvent) => void;
|
|
108
|
-
readonly onEdgeEvent?: (event: GraphViewElementEvent) => void;
|
|
109
|
-
readonly onViewportChange?: (viewport: GraphViewViewport) => void;
|
|
110
|
-
readonly onSpacingFactorChange?: (spacingFactor: number) => void;
|
|
111
|
-
}
|
|
112
|
-
|
|
113
|
-
export type GraphViewCallbacks = Pick<
|
|
114
|
-
GraphViewProps,
|
|
115
|
-
| 'onEdgeEvent'
|
|
116
|
-
| 'onLayoutComplete'
|
|
117
|
-
| 'onNodeEvent'
|
|
118
|
-
| 'onReady'
|
|
119
|
-
| 'onViewportChange'
|
|
120
|
-
| 'onSpacingFactorChange'
|
|
121
|
-
>;
|
|
122
|
-
|
|
123
13
|
type GraphContainer = NonNullable<CytoscapeOptions['container']>;
|
|
124
14
|
|
|
125
15
|
/***
|
|
@@ -4,7 +4,7 @@ import type {
|
|
|
4
4
|
GraphViewCallbacks,
|
|
5
5
|
GraphViewController,
|
|
6
6
|
GraphViewElementEventType,
|
|
7
|
-
} from '
|
|
7
|
+
} from '../../../../../types/graph-view';
|
|
8
8
|
|
|
9
9
|
/*** Bind stable Cytoscape events that always read the latest React callbacks. */
|
|
10
10
|
export function bindGraphEvents(
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import type { Core } from 'cytoscape';
|
|
2
2
|
|
|
3
|
+
import type { GraphViewController, GraphViewFitOptions } from '../../../../../types/graph-view';
|
|
3
4
|
import type { GraphRuntimeUpdate } from '../../../../../types/graphViewRuntime';
|
|
4
5
|
import { fitGraphViewport } from './fitGraphViewport';
|
|
5
|
-
import type { GraphViewController, GraphViewFitOptions } from './GraphView';
|
|
6
6
|
|
|
7
7
|
/*** Own viewport units and limits alongside the public controller, without exposing Cytoscape. */
|
|
8
8
|
export function createGraphController(
|
|
@@ -3,13 +3,13 @@ import './createGraphRuntime';
|
|
|
3
3
|
import { expect, test } from 'bun:test';
|
|
4
4
|
import cytoscape from 'cytoscape';
|
|
5
5
|
|
|
6
|
-
import { createGraphRuntime } from './createGraphRuntime';
|
|
7
6
|
import type {
|
|
8
7
|
GraphViewCallbacks,
|
|
9
8
|
GraphViewController,
|
|
10
9
|
GraphViewElementEvent,
|
|
11
10
|
GraphViewRenderedNode,
|
|
12
|
-
} from '
|
|
11
|
+
} from '../../../../../types/graph-view';
|
|
12
|
+
import { createGraphRuntime } from './createGraphRuntime';
|
|
13
13
|
|
|
14
14
|
test('explicit fit compacts once and controlled spacing acknowledgement does not rerun the algorithm', async () => {
|
|
15
15
|
const initial = Promise.withResolvers<GraphViewController>();
|
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
import cytoscape, { type Core, type CytoscapeOptions } from 'cytoscape';
|
|
2
2
|
|
|
3
|
+
import type {
|
|
4
|
+
GraphViewCallbacks,
|
|
5
|
+
GraphViewElementEventType,
|
|
6
|
+
GraphViewFitOptions,
|
|
7
|
+
GraphViewRenderedNode,
|
|
8
|
+
GraphViewSize,
|
|
9
|
+
GraphViewStyleRule,
|
|
10
|
+
} from '../../../../../types/graph-view';
|
|
3
11
|
import type { GraphRuntimeUpdate } from '../../../../../types/graphViewRuntime';
|
|
4
12
|
import { bindGraphEvents } from './bindGraphEvents';
|
|
5
13
|
import { compactGraphSpacing } from './compactGraphSpacing';
|
|
@@ -8,14 +16,6 @@ import { createGraphLoopSizer } from './createGraphLoopSizer';
|
|
|
8
16
|
import { createGraphResizeObserver, type GraphResizeObserver } from './createGraphResizeObserver';
|
|
9
17
|
import { getGraphGeometryKey } from './getGraphGeometryKey';
|
|
10
18
|
import { getGraphTopologyKey } from './getGraphTopologyKey';
|
|
11
|
-
import type {
|
|
12
|
-
GraphViewCallbacks,
|
|
13
|
-
GraphViewElementEventType,
|
|
14
|
-
GraphViewFitOptions,
|
|
15
|
-
GraphViewRenderedNode,
|
|
16
|
-
GraphViewSize,
|
|
17
|
-
GraphViewStyleRule,
|
|
18
|
-
} from './GraphView';
|
|
19
19
|
import { hasGraphLayoutChanged } from './hasGraphLayoutChanged';
|
|
20
20
|
import { readGraphRenderedNodes } from './readGraphRenderedNodes';
|
|
21
21
|
import { registerGraphLayouts } from './registerGraphLayouts';
|
package/src/features/graph-view/adapters/inbound/web-artifact/createRenderableGraphElements.test.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { expect, test } from 'bun:test';
|
|
2
2
|
|
|
3
|
+
import type { GraphViewEdge, GraphViewNode } from '../../../../../types/graph-view';
|
|
3
4
|
import { createRenderableGraphElements } from './createRenderableGraphElements';
|
|
4
|
-
import type { GraphViewEdge, GraphViewNode } from './GraphView';
|
|
5
5
|
|
|
6
6
|
test('omits compound ancestor and descendant edges without mutating source graph data', () => {
|
|
7
7
|
const nodes: readonly GraphViewNode[] = [
|
package/src/features/graph-view/adapters/inbound/web-artifact/createRenderableGraphElements.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { ElementDefinition } from 'cytoscape';
|
|
2
2
|
|
|
3
|
-
import type { GraphViewEdge, GraphViewNode } from '
|
|
3
|
+
import type { GraphViewEdge, GraphViewNode } from '../../../../../types/graph-view';
|
|
4
4
|
|
|
5
5
|
/*** Convert plain graph data into renderable Cytoscape elements without impossible compound edges. */
|
|
6
6
|
export function createRenderableGraphElements(
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { Core } from 'cytoscape';
|
|
2
2
|
|
|
3
|
-
import type { GraphViewFitOptions } from '
|
|
3
|
+
import type { GraphViewFitOptions } from '../../../../../types/graph-view';
|
|
4
4
|
|
|
5
5
|
/*** Fit the requested visible nodes and never include edge geometry in viewport bounds. */
|
|
6
6
|
export function fitGraphViewport(
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { Core } from 'cytoscape';
|
|
2
2
|
|
|
3
|
-
import type { GraphViewRenderedNode } from '
|
|
3
|
+
import type { GraphViewRenderedNode } from '../../../../../types/graph-view';
|
|
4
4
|
|
|
5
5
|
/*** Read React-overlay node state from Cytoscape's authoritative rendered positions. */
|
|
6
6
|
export function readGraphRenderedNodes(
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { Core, LayoutOptions, Layouts } from 'cytoscape';
|
|
2
2
|
|
|
3
|
-
import type { GraphViewLayoutName } from '
|
|
3
|
+
import type { GraphViewLayoutName } from '../../../../../types/graph-view';
|
|
4
4
|
import { runDetachedGraphLayout } from './runDetachedGraphLayout';
|
|
5
5
|
|
|
6
6
|
interface RunGraphLayoutInput {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { isRecord } from '@ankhorage/utility/object';
|
|
2
2
|
import type { Core } from 'cytoscape';
|
|
3
3
|
|
|
4
|
+
import type { GraphViewEdge, GraphViewNode } from '../../../../../types/graph-view';
|
|
4
5
|
import { createRenderableGraphElements } from './createRenderableGraphElements';
|
|
5
|
-
import type { GraphViewEdge, GraphViewNode } from './GraphView';
|
|
6
6
|
|
|
7
7
|
/***
|
|
8
8
|
* Reconciles graph data in one batch while retaining positions, selection and element identity.
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
export {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
} from './adapters/inbound/web-artifact/GraphView';
|
|
1
|
+
export type {
|
|
2
|
+
GraphViewCallbacks,
|
|
3
|
+
GraphViewController,
|
|
4
|
+
GraphViewEdge,
|
|
5
|
+
GraphViewElementEvent,
|
|
6
|
+
GraphViewElementEventType,
|
|
7
|
+
GraphViewFitOptions,
|
|
8
|
+
GraphViewLayoutName,
|
|
9
|
+
GraphViewNode,
|
|
10
|
+
GraphViewNodeRenderContext,
|
|
11
|
+
GraphViewPoint,
|
|
12
|
+
GraphViewProps,
|
|
13
|
+
GraphViewRenderedNode,
|
|
14
|
+
GraphViewSize,
|
|
15
|
+
GraphViewStyleRule,
|
|
16
|
+
GraphViewViewport,
|
|
17
|
+
} from '../../types/graph-view';
|
|
18
|
+
export { GraphView } from './adapters/inbound/web-artifact/GraphView';
|