@effectiveailabs/design-system 0.0.0-placeholder → 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +7 -0
- package/README.md +120 -3
- package/dist/components/AdaptiveGrid/AdaptiveGrid.d.ts +38 -0
- package/dist/components/AdaptiveGrid/AdaptiveGrid.js +15 -0
- package/dist/components/AdaptiveGrid/AdaptiveGrid.stylex.d.ts +104 -0
- package/dist/components/AdaptiveGrid/AdaptiveGrid.stylex.js +62 -0
- package/dist/components/Anchor/Anchor.d.ts +29 -0
- package/dist/components/Anchor/Anchor.js +56 -0
- package/dist/components/AnimatedNumber/AnimatedNumber.d.ts +16 -0
- package/dist/components/AnimatedNumber/AnimatedNumber.js +45 -0
- package/dist/components/AnimatedNumber/AnimatedNumber.stylex.d.ts +6 -0
- package/dist/components/AnimatedNumber/AnimatedNumber.stylex.js +7 -0
- package/dist/components/AnnotationPin/AnnotationOutlet.d.ts +15 -0
- package/dist/components/AnnotationPin/AnnotationOutlet.js +15 -0
- package/dist/components/AnnotationPin/AnnotationPin.d.ts +31 -0
- package/dist/components/AnnotationPin/AnnotationPin.js +99 -0
- package/dist/components/AnnotationPin/AnnotationPin.layout.d.ts +19 -0
- package/dist/components/AnnotationPin/AnnotationPin.layout.js +56 -0
- package/dist/components/AnnotationPin/AnnotationPin.stylex.d.ts +48 -0
- package/dist/components/AnnotationPin/AnnotationPin.stylex.js +39 -0
- package/dist/components/AnnotationPin/AnnotationScope.d.ts +26 -0
- package/dist/components/AnnotationPin/AnnotationScope.js +59 -0
- package/dist/components/AnnotationPin/AnnotationScope.layout.d.ts +15 -0
- package/dist/components/AnnotationPin/AnnotationScope.layout.js +68 -0
- package/dist/components/AnnotationPin/useRangeAnchor.d.ts +9 -0
- package/dist/components/AnnotationPin/useRangeAnchor.js +35 -0
- package/dist/components/App/App.d.ts +85 -0
- package/dist/components/App/App.js +515 -0
- package/dist/components/App/App.layout.d.ts +25 -0
- package/dist/components/App/App.layout.js +42 -0
- package/dist/components/App/App.stylex.d.ts +373 -0
- package/dist/components/App/App.stylex.js +352 -0
- package/dist/components/App/AppNavigationHeader.context.d.ts +9 -0
- package/dist/components/App/AppNavigationHeader.context.js +13 -0
- package/dist/components/Article/Article.d.ts +16 -0
- package/dist/components/Article/Article.js +14 -0
- package/dist/components/Article/Article.stylex.d.ts +49 -0
- package/dist/components/Article/Article.stylex.js +66 -0
- package/dist/components/Article/ArticleSection.d.ts +23 -0
- package/dist/components/Article/ArticleSection.js +26 -0
- package/dist/components/Autocomplete/Autocomplete.d.ts +13 -0
- package/dist/components/Autocomplete/Autocomplete.gridFocus.d.ts +9 -0
- package/dist/components/Autocomplete/Autocomplete.gridFocus.js +5 -0
- package/dist/components/Autocomplete/Autocomplete.js +68 -0
- package/dist/components/Avatar/Avatar.d.ts +30 -0
- package/dist/components/Avatar/Avatar.js +14 -0
- package/dist/components/Avatar/Avatar.stylex.d.ts +74 -0
- package/dist/components/Avatar/Avatar.stylex.js +71 -0
- package/dist/components/Avatar/Avatar.view.d.ts +7 -0
- package/dist/components/Avatar/Avatar.view.js +43 -0
- package/dist/components/Avatar/AvatarName.d.ts +7 -0
- package/dist/components/Avatar/AvatarName.js +17 -0
- package/dist/components/Avatar/avatarColor.d.ts +3 -0
- package/dist/components/Avatar/avatarColor.js +28 -0
- package/dist/components/Avatar/avatarInitials.d.ts +1 -0
- package/dist/components/Avatar/avatarInitials.js +37 -0
- package/dist/components/AvatarGroup/AvatarGroup.children.d.ts +11 -0
- package/dist/components/AvatarGroup/AvatarGroup.children.js +52 -0
- package/dist/components/AvatarGroup/AvatarGroup.context.d.ts +1 -0
- package/dist/components/AvatarGroup/AvatarGroup.context.js +2 -0
- package/dist/components/AvatarGroup/AvatarGroup.d.ts +16 -0
- package/dist/components/AvatarGroup/AvatarGroup.js +188 -0
- package/dist/components/AvatarGroup/AvatarGroup.stylex.d.ts +149 -0
- package/dist/components/AvatarGroup/AvatarGroup.stylex.js +132 -0
- package/dist/components/AvatarGroup/avatarGroupLayout.d.ts +14 -0
- package/dist/components/AvatarGroup/avatarGroupLayout.js +27 -0
- package/dist/components/Badge/Badge.d.ts +54 -0
- package/dist/components/Badge/Badge.js +149 -0
- package/dist/components/Badge/Badge.stylex.d.ts +278 -0
- package/dist/components/Badge/Badge.stylex.js +267 -0
- package/dist/components/BrandLogo/BrandLogo.d.ts +16 -0
- package/dist/components/BrandLogo/BrandLogo.js +19 -0
- package/dist/components/BrandLogo/BrandLogo.stylex.d.ts +23 -0
- package/dist/components/BrandLogo/BrandLogo.stylex.js +14 -0
- package/dist/components/BrandLogo/brandLogoArtwork.d.ts +10 -0
- package/dist/components/BrandLogo/brandLogoArtwork.js +30 -0
- package/dist/components/Breadcrumbs/Breadcrumbs.children.d.ts +14 -0
- package/dist/components/Breadcrumbs/Breadcrumbs.children.js +59 -0
- package/dist/components/Breadcrumbs/Breadcrumbs.d.ts +24 -0
- package/dist/components/Breadcrumbs/Breadcrumbs.headerContext.d.ts +20 -0
- package/dist/components/Breadcrumbs/Breadcrumbs.headerContext.js +14 -0
- package/dist/components/Breadcrumbs/Breadcrumbs.js +284 -0
- package/dist/components/Breadcrumbs/Breadcrumbs.layout.d.ts +10 -0
- package/dist/components/Breadcrumbs/Breadcrumbs.layout.js +29 -0
- package/dist/components/Breadcrumbs/Breadcrumbs.stylex.d.ts +200 -0
- package/dist/components/Breadcrumbs/Breadcrumbs.stylex.js +166 -0
- package/dist/components/Button/Button.appearance.d.ts +323 -0
- package/dist/components/Button/Button.appearance.js +57 -0
- package/dist/components/Button/Button.d.ts +102 -0
- package/dist/components/Button/Button.js +176 -0
- package/dist/components/Button/Button.stylex.d.ts +577 -0
- package/dist/components/Button/Button.stylex.js +590 -0
- package/dist/components/Button/ButtonProgress.d.ts +1 -0
- package/dist/components/Button/ButtonProgress.js +8 -0
- package/dist/components/Button/ButtonProgress.stylex.d.ts +22 -0
- package/dist/components/Button/ButtonProgress.stylex.js +14 -0
- package/dist/components/ButtonGroup/ButtonGroup.context.d.ts +74 -0
- package/dist/components/ButtonGroup/ButtonGroup.context.js +25 -0
- package/dist/components/ButtonGroup/ButtonGroup.d.ts +35 -0
- package/dist/components/ButtonGroup/ButtonGroup.js +49 -0
- package/dist/components/ButtonGroup/ButtonGroup.stylex.d.ts +111 -0
- package/dist/components/ButtonGroup/ButtonGroup.stylex.js +116 -0
- package/dist/components/CalculationSteps/CalculationSteps.d.ts +13 -0
- package/dist/components/CalculationSteps/CalculationSteps.format.d.ts +13 -0
- package/dist/components/CalculationSteps/CalculationSteps.format.js +44 -0
- package/dist/components/CalculationSteps/CalculationSteps.js +84 -0
- package/dist/components/CalculationSteps/CalculationSteps.stylex.d.ts +23 -0
- package/dist/components/CalculationSteps/CalculationSteps.stylex.js +22 -0
- package/dist/components/CalculationSteps/CalculationSteps.types.d.ts +131 -0
- package/dist/components/CalculationSteps/CalculationSteps.types.js +11 -0
- package/dist/components/Calendar/Calendar.d.ts +22 -0
- package/dist/components/Calendar/Calendar.js +119 -0
- package/dist/components/Calendar/Calendar.stylex.d.ts +196 -0
- package/dist/components/Calendar/Calendar.stylex.js +197 -0
- package/dist/components/Card/Card.context.d.ts +28 -0
- package/dist/components/Card/Card.context.js +40 -0
- package/dist/components/Card/Card.d.ts +39 -0
- package/dist/components/Card/Card.js +121 -0
- package/dist/components/Card/Card.stylex.d.ts +172 -0
- package/dist/components/Card/Card.stylex.js +185 -0
- package/dist/components/Chart/Chart.d.ts +24 -0
- package/dist/components/Chart/Chart.data.d.ts +119 -0
- package/dist/components/Chart/Chart.data.js +596 -0
- package/dist/components/Chart/Chart.describe.d.ts +46 -0
- package/dist/components/Chart/Chart.describe.js +359 -0
- package/dist/components/Chart/Chart.environment.d.ts +8 -0
- package/dist/components/Chart/Chart.environment.js +10 -0
- package/dist/components/Chart/Chart.format.d.ts +14 -0
- package/dist/components/Chart/Chart.format.js +108 -0
- package/dist/components/Chart/Chart.highcharts.d.ts +106 -0
- package/dist/components/Chart/Chart.highcharts.js +1001 -0
- package/dist/components/Chart/Chart.js +600 -0
- package/dist/components/Chart/Chart.load.d.ts +69 -0
- package/dist/components/Chart/Chart.load.js +136 -0
- package/dist/components/Chart/Chart.raw.d.ts +33 -0
- package/dist/components/Chart/Chart.raw.js +234 -0
- package/dist/components/Chart/Chart.rules.d.ts +31 -0
- package/dist/components/Chart/Chart.rules.js +72 -0
- package/dist/components/Chart/Chart.stylex.d.ts +260 -0
- package/dist/components/Chart/Chart.stylex.js +280 -0
- package/dist/components/Chart/Chart.types.d.ts +380 -0
- package/dist/components/Chart/Chart.types.js +23 -0
- package/dist/components/Chart/ChartDataTable.d.ts +9 -0
- package/dist/components/Chart/ChartDataTable.js +42 -0
- package/dist/components/Chart/ChartGhost.d.ts +17 -0
- package/dist/components/Chart/ChartGhost.js +13 -0
- package/dist/components/Chart/ChartHighcharts.d.ts +6 -0
- package/dist/components/Chart/ChartHighcharts.js +61 -0
- package/dist/components/Chart/ChartLegend.d.ts +23 -0
- package/dist/components/Chart/ChartLegend.js +111 -0
- package/dist/components/Chart/ChartMarks.d.ts +29 -0
- package/dist/components/Chart/ChartMarks.js +29 -0
- package/dist/components/Chart/ChartScrollbar.d.ts +13 -0
- package/dist/components/Chart/ChartScrollbar.js +63 -0
- package/dist/components/Chart/ChartTip.d.ts +5 -0
- package/dist/components/Chart/ChartTip.js +7 -0
- package/dist/components/Checkbox/Checkbox.d.ts +81 -0
- package/dist/components/Checkbox/Checkbox.js +52 -0
- package/dist/components/CodeBlock/CodeBlock.copy.d.ts +7 -0
- package/dist/components/CodeBlock/CodeBlock.copy.js +28 -0
- package/dist/components/CodeBlock/CodeBlock.copyButton.d.ts +20 -0
- package/dist/components/CodeBlock/CodeBlock.copyButton.js +40 -0
- package/dist/components/CodeBlock/CodeBlock.d.ts +88 -0
- package/dist/components/CodeBlock/CodeBlock.fence.d.ts +24 -0
- package/dist/components/CodeBlock/CodeBlock.fence.js +110 -0
- package/dist/components/CodeBlock/CodeBlock.js +148 -0
- package/dist/components/CodeBlock/CodeBlock.marks.d.ts +24 -0
- package/dist/components/CodeBlock/CodeBlock.marks.js +54 -0
- package/dist/components/CodeBlock/CodeBlock.ranges.d.ts +15 -0
- package/dist/components/CodeBlock/CodeBlock.ranges.js +30 -0
- package/dist/components/CodeBlock/CodeBlock.stylex.d.ts +221 -0
- package/dist/components/CodeBlock/CodeBlock.stylex.js +194 -0
- package/dist/components/CodeBlock/CodeBlock.tokens.d.ts +47 -0
- package/dist/components/CodeBlock/CodeBlock.tokens.js +103 -0
- package/dist/components/CodeBlock/CodeGroup.context.d.ts +5 -0
- package/dist/components/CodeBlock/CodeGroup.context.js +6 -0
- package/dist/components/CodeBlock/CodeGroup.d.ts +19 -0
- package/dist/components/CodeBlock/CodeGroup.js +39 -0
- package/dist/components/CodeBlock/CodeHighlightScope.d.ts +39 -0
- package/dist/components/CodeBlock/CodeHighlightScope.js +70 -0
- package/dist/components/CodeEntry/CodeEntry.d.ts +62 -0
- package/dist/components/CodeEntry/CodeEntry.js +86 -0
- package/dist/components/CodeField/CodeField.d.ts +32 -0
- package/dist/components/CodeField/CodeField.js +25 -0
- package/dist/components/CodeField/CodeField.stylex.d.ts +82 -0
- package/dist/components/CodeField/CodeField.stylex.js +88 -0
- package/dist/components/Collection/Collection.constants.d.ts +3 -0
- package/dist/components/Collection/Collection.constants.js +3 -0
- package/dist/components/Collection/Collection.context.d.ts +70 -0
- package/dist/components/Collection/Collection.context.js +39 -0
- package/dist/components/Collection/Collection.d.ts +119 -0
- package/dist/components/Collection/Collection.dnd.d.ts +19 -0
- package/dist/components/Collection/Collection.dnd.js +56 -0
- package/dist/components/Collection/Collection.dragScroll.d.ts +2 -0
- package/dist/components/Collection/Collection.dragScroll.js +93 -0
- package/dist/components/Collection/Collection.identity.d.ts +3 -0
- package/dist/components/Collection/Collection.identity.js +10 -0
- package/dist/components/Collection/Collection.js +479 -0
- package/dist/components/Collection/Collection.pageLoadMore.d.ts +2 -0
- package/dist/components/Collection/Collection.pageLoadMore.js +21 -0
- package/dist/components/Collection/Collection.stylex.d.ts +1033 -0
- package/dist/components/Collection/Collection.stylex.js +1095 -0
- package/dist/components/Collection/CollectionItemContent.d.ts +9 -0
- package/dist/components/Collection/CollectionItemContent.js +11 -0
- package/dist/components/Collection/CollectionVirtualizer.context.d.ts +9 -0
- package/dist/components/Collection/CollectionVirtualizer.context.js +2 -0
- package/dist/components/Collection/OutlinePreview.d.ts +12 -0
- package/dist/components/Collection/OutlinePreview.js +32 -0
- package/dist/components/CollectionViews/CollectionViews.context.d.ts +8 -0
- package/dist/components/CollectionViews/CollectionViews.context.js +9 -0
- package/dist/components/CollectionViews/CollectionViews.d.ts +42 -0
- package/dist/components/CollectionViews/CollectionViews.js +53 -0
- package/dist/components/ComboBox/ComboBox.collection.d.ts +5 -0
- package/dist/components/ComboBox/ComboBox.collection.js +40 -0
- package/dist/components/ComboBox/ComboBox.d.ts +50 -0
- package/dist/components/ComboBox/ComboBox.js +98 -0
- package/dist/components/ComboBox/ComboBox.stylex.d.ts +45 -0
- package/dist/components/ComboBox/ComboBox.stylex.js +34 -0
- package/dist/components/ContainerSize/ContainerSize.d.ts +27 -0
- package/dist/components/ContainerSize/ContainerSize.js +51 -0
- package/dist/components/ContainerSize/ContainerSize.stylex.d.ts +13 -0
- package/dist/components/ContainerSize/ContainerSize.stylex.js +16 -0
- package/dist/components/Content/Content.context.d.ts +3 -0
- package/dist/components/Content/Content.context.js +3 -0
- package/dist/components/Content/Content.d.ts +33 -0
- package/dist/components/Content/Content.js +36 -0
- package/dist/components/Content/Content.stylex.d.ts +65 -0
- package/dist/components/Content/Content.stylex.js +69 -0
- package/dist/components/Content/HeaderSlots.d.ts +9 -0
- package/dist/components/Content/HeaderSlots.js +22 -0
- package/dist/components/ContentOrientation/ContentOrientation.context.d.ts +2 -0
- package/dist/components/ContentOrientation/ContentOrientation.context.js +2 -0
- package/dist/components/ControlSize/ControlSize.context.d.ts +3 -0
- package/dist/components/ControlSize/ControlSize.context.js +6 -0
- package/dist/components/Countdown/Countdown.d.ts +16 -0
- package/dist/components/Countdown/Countdown.js +30 -0
- package/dist/components/Countdown/Countdown.stylex.d.ts +11 -0
- package/dist/components/Countdown/Countdown.stylex.js +10 -0
- package/dist/components/CoverageTower/CoverageTower.axis.d.ts +28 -0
- package/dist/components/CoverageTower/CoverageTower.axis.js +28 -0
- package/dist/components/CoverageTower/CoverageTower.block.d.ts +39 -0
- package/dist/components/CoverageTower/CoverageTower.block.js +112 -0
- package/dist/components/CoverageTower/CoverageTower.d.ts +14 -0
- package/dist/components/CoverageTower/CoverageTower.js +284 -0
- package/dist/components/CoverageTower/CoverageTower.layout.d.ts +158 -0
- package/dist/components/CoverageTower/CoverageTower.layout.js +243 -0
- package/dist/components/CoverageTower/CoverageTower.stylex.d.ts +404 -0
- package/dist/components/CoverageTower/CoverageTower.stylex.js +525 -0
- package/dist/components/CoverageTower/CoverageTower.types.d.ts +172 -0
- package/dist/components/CoverageTower/CoverageTower.types.js +3 -0
- package/dist/components/DateField/DateField.d.ts +61 -0
- package/dist/components/DateField/DateField.js +66 -0
- package/dist/components/DateRangeField/DateRangeField.d.ts +60 -0
- package/dist/components/DateRangeField/DateRangeField.js +68 -0
- package/dist/components/Dialog/Dialog.context.d.ts +6 -0
- package/dist/components/Dialog/Dialog.context.js +3 -0
- package/dist/components/Dialog/Dialog.d.ts +15 -0
- package/dist/components/Dialog/Dialog.js +25 -0
- package/dist/components/Dialog/Dialog.stylex.d.ts +23 -0
- package/dist/components/Dialog/Dialog.stylex.js +20 -0
- package/dist/components/Disclosure/Disclosure.d.ts +5 -0
- package/dist/components/Disclosure/Disclosure.js +119 -0
- package/dist/components/Disclosure/Disclosure.stylex.d.ts +161 -0
- package/dist/components/Disclosure/Disclosure.stylex.js +143 -0
- package/dist/components/Disclosure/Disclosure.types.d.ts +96 -0
- package/dist/components/Disclosure/Disclosure.types.js +4 -0
- package/dist/components/Disclosure/DisclosureGroup.context.d.ts +2 -0
- package/dist/components/Disclosure/DisclosureGroup.context.js +2 -0
- package/dist/components/Disclosure/DisclosureGroup.d.ts +5 -0
- package/dist/components/Disclosure/DisclosureGroup.js +10 -0
- package/dist/components/DismissButton/Dismiss.context.d.ts +3 -0
- package/dist/components/DismissButton/Dismiss.context.js +10 -0
- package/dist/components/DismissButton/DismissButton.d.ts +16 -0
- package/dist/components/DismissButton/DismissButton.js +9 -0
- package/dist/components/DropZone/DropZone.d.ts +10 -0
- package/dist/components/DropZone/DropZone.js +16 -0
- package/dist/components/DropZone/DropZone.stylex.d.ts +32 -0
- package/dist/components/DropZone/DropZone.stylex.js +27 -0
- package/dist/components/EditableText/EditableText.d.ts +21 -0
- package/dist/components/EditableText/EditableText.js +63 -0
- package/dist/components/EditableText/EditableText.stylex.d.ts +108 -0
- package/dist/components/EditableText/EditableText.stylex.js +95 -0
- package/dist/components/FieldRow/FieldRow.d.ts +20 -0
- package/dist/components/FieldRow/FieldRow.js +17 -0
- package/dist/components/FieldRow/FieldRow.stylex.d.ts +30 -0
- package/dist/components/FieldRow/FieldRow.stylex.js +52 -0
- package/dist/components/FileCollectionViewer/FileCollectionViewer.d.ts +74 -0
- package/dist/components/FileCollectionViewer/FileCollectionViewer.js +193 -0
- package/dist/components/FileCollectionViewer/FileCollectionViewer.stylex.d.ts +47 -0
- package/dist/components/FileCollectionViewer/FileCollectionViewer.stylex.js +53 -0
- package/dist/components/FileContent/FileContent.context.d.ts +51 -0
- package/dist/components/FileContent/FileContent.context.js +45 -0
- package/dist/components/FileContent/FileContent.d.ts +66 -0
- package/dist/components/FileContent/FileContent.js +80 -0
- package/dist/components/FileContent/FileContent.markers.d.ts +7 -0
- package/dist/components/FileContent/FileContent.markers.js +28 -0
- package/dist/components/FileContent/FileContent.stylex.d.ts +152 -0
- package/dist/components/FileContent/FileContent.stylex.js +155 -0
- package/dist/components/FileContent/FileContentViewport.d.ts +42 -0
- package/dist/components/FileContent/FileContentViewport.js +117 -0
- package/dist/components/FileContent/FileDetails.d.ts +11 -0
- package/dist/components/FileContent/FileDetails.js +53 -0
- package/dist/components/FileContent/FileOutline.previews.d.ts +70 -0
- package/dist/components/FileContent/FileOutline.previews.js +278 -0
- package/dist/components/FileContent/FileOutlineRows.d.ts +21 -0
- package/dist/components/FileContent/FileOutlineRows.js +166 -0
- package/dist/components/FileContent/FileSelectionToolbarLayer.d.ts +13 -0
- package/dist/components/FileContent/FileSelectionToolbarLayer.js +125 -0
- package/dist/components/FileContent/FileStructure.d.ts +51 -0
- package/dist/components/FileContent/FileStructure.js +37 -0
- package/dist/components/FileExplorer/FileExplorer.browser.d.ts +58 -0
- package/dist/components/FileExplorer/FileExplorer.browser.js +274 -0
- package/dist/components/FileExplorer/FileExplorer.columns.d.ts +37 -0
- package/dist/components/FileExplorer/FileExplorer.columns.js +144 -0
- package/dist/components/FileExplorer/FileExplorer.columns.stylex.d.ts +95 -0
- package/dist/components/FileExplorer/FileExplorer.columns.stylex.js +95 -0
- package/dist/components/FileExplorer/FileExplorer.d.ts +33 -0
- package/dist/components/FileExplorer/FileExplorer.groups.d.ts +14 -0
- package/dist/components/FileExplorer/FileExplorer.groups.js +129 -0
- package/dist/components/FileExplorer/FileExplorer.hits.d.ts +12 -0
- package/dist/components/FileExplorer/FileExplorer.hits.js +51 -0
- package/dist/components/FileExplorer/FileExplorer.js +180 -0
- package/dist/components/FileExplorer/FileExplorer.stylex.d.ts +141 -0
- package/dist/components/FileExplorer/FileExplorer.stylex.js +132 -0
- package/dist/components/FileField/FileField.d.ts +24 -0
- package/dist/components/FileField/FileField.js +37 -0
- package/dist/components/FileField/FileField.stylex.d.ts +17 -0
- package/dist/components/FileField/FileField.stylex.js +18 -0
- package/dist/components/FileIcon/FileIcon.d.ts +25 -0
- package/dist/components/FileIcon/FileIcon.js +33 -0
- package/dist/components/FilePicker/FilePicker.d.ts +40 -0
- package/dist/components/FilePicker/FilePicker.js +155 -0
- package/dist/components/FilePicker/MovePicker.d.ts +13 -0
- package/dist/components/FilePicker/MovePicker.js +19 -0
- package/dist/components/FileScope/FileHeader.stylex.d.ts +8 -0
- package/dist/components/FileScope/FileHeader.stylex.js +9 -0
- package/dist/components/FileScope/FileScope.actions.d.ts +45 -0
- package/dist/components/FileScope/FileScope.actions.js +240 -0
- package/dist/components/FileScope/FileScope.cache.d.ts +12 -0
- package/dist/components/FileScope/FileScope.cache.js +25 -0
- package/dist/components/FileScope/FileScope.d.ts +163 -0
- package/dist/components/FileScope/FileScope.drag.d.ts +27 -0
- package/dist/components/FileScope/FileScope.drag.js +88 -0
- package/dist/components/FileScope/FileScope.entryActions.d.ts +32 -0
- package/dist/components/FileScope/FileScope.entryActions.js +121 -0
- package/dist/components/FileScope/FileScope.entryActions.stylex.d.ts +9 -0
- package/dist/components/FileScope/FileScope.entryActions.stylex.js +24 -0
- package/dist/components/FileScope/FileScope.js +132 -0
- package/dist/components/FileScope/FileScope.match.d.ts +8 -0
- package/dist/components/FileScope/FileScope.match.js +76 -0
- package/dist/components/FileScope/FileScope.plainText.d.ts +6 -0
- package/dist/components/FileScope/FileScope.plainText.js +34 -0
- package/dist/components/FileScope/FileScope.plainText.stylex.d.ts +14 -0
- package/dist/components/FileScope/FileScope.plainText.stylex.js +15 -0
- package/dist/components/FileScope/FileScope.queue.d.ts +20 -0
- package/dist/components/FileScope/FileScope.queue.js +81 -0
- package/dist/components/FileScope/FileScope.relative.d.ts +7 -0
- package/dist/components/FileScope/FileScope.relative.js +32 -0
- package/dist/components/FileScope/FileScope.search.d.ts +33 -0
- package/dist/components/FileScope/FileScope.search.js +105 -0
- package/dist/components/FileScope/FileScope.search.stylex.d.ts +7 -0
- package/dist/components/FileScope/FileScope.search.stylex.js +8 -0
- package/dist/components/FileScope/FileScope.share.d.ts +13 -0
- package/dist/components/FileScope/FileScope.share.js +159 -0
- package/dist/components/FileScope/FileScope.share.stylex.d.ts +18 -0
- package/dist/components/FileScope/FileScope.share.stylex.js +21 -0
- package/dist/components/FileScope/FileScope.types.d.ts +586 -0
- package/dist/components/FileScope/FileScope.types.js +6 -0
- package/dist/components/FileScope/FileScope.utils.d.ts +20 -0
- package/dist/components/FileScope/FileScope.utils.js +157 -0
- package/dist/components/FileScope/FileSourceError.d.ts +17 -0
- package/dist/components/FileScope/FileSourceError.js +24 -0
- package/dist/components/FileScope/FileStore.d.ts +178 -0
- package/dist/components/FileScope/FileStore.js +849 -0
- package/dist/components/FileThumbnail/FileThumbnail.d.ts +25 -0
- package/dist/components/FileThumbnail/FileThumbnail.js +242 -0
- package/dist/components/FileThumbnail/FileThumbnail.stylex.d.ts +38 -0
- package/dist/components/FileThumbnail/FileThumbnail.stylex.js +44 -0
- package/dist/components/FileTree/FileTree.d.ts +77 -0
- package/dist/components/FileTree/FileTree.entries.d.ts +29 -0
- package/dist/components/FileTree/FileTree.entries.js +97 -0
- package/dist/components/FileTree/FileTree.js +800 -0
- package/dist/components/FileTree/FileTree.stylex.d.ts +46 -0
- package/dist/components/FileTree/FileTree.stylex.js +60 -0
- package/dist/components/FileTrigger/FileSelection.context.d.ts +2 -0
- package/dist/components/FileTrigger/FileSelection.context.js +2 -0
- package/dist/components/FileTrigger/FileSelection.d.ts +13 -0
- package/dist/components/FileTrigger/FileSelection.js +31 -0
- package/dist/components/FileTrigger/FileTrigger.d.ts +9 -0
- package/dist/components/FileTrigger/FileTrigger.js +22 -0
- package/dist/components/FileViewer/FileViewer.chrome.d.ts +66 -0
- package/dist/components/FileViewer/FileViewer.chrome.js +126 -0
- package/dist/components/FileViewer/FileViewer.compact.d.ts +90 -0
- package/dist/components/FileViewer/FileViewer.compact.js +124 -0
- package/dist/components/FileViewer/FileViewer.compact.stylex.d.ts +138 -0
- package/dist/components/FileViewer/FileViewer.compact.stylex.js +140 -0
- package/dist/components/FileViewer/FileViewer.controls.d.ts +66 -0
- package/dist/components/FileViewer/FileViewer.controls.js +27 -0
- package/dist/components/FileViewer/FileViewer.d.ts +79 -0
- package/dist/components/FileViewer/FileViewer.edit.d.ts +63 -0
- package/dist/components/FileViewer/FileViewer.edit.js +209 -0
- package/dist/components/FileViewer/FileViewer.embedded.d.ts +49 -0
- package/dist/components/FileViewer/FileViewer.embedded.js +107 -0
- package/dist/components/FileViewer/FileViewer.frame.d.ts +92 -0
- package/dist/components/FileViewer/FileViewer.frame.js +36 -0
- package/dist/components/FileViewer/FileViewer.goTo.d.ts +13 -0
- package/dist/components/FileViewer/FileViewer.goTo.js +30 -0
- package/dist/components/FileViewer/FileViewer.js +846 -0
- package/dist/components/FileViewer/FileViewer.links.d.ts +18 -0
- package/dist/components/FileViewer/FileViewer.links.js +10 -0
- package/dist/components/FileViewer/FileViewer.present.d.ts +10 -0
- package/dist/components/FileViewer/FileViewer.present.js +36 -0
- package/dist/components/FileViewer/FileViewer.selection.d.ts +15 -0
- package/dist/components/FileViewer/FileViewer.selection.js +26 -0
- package/dist/components/FileViewer/FileViewer.sidebar.d.ts +24 -0
- package/dist/components/FileViewer/FileViewer.sidebar.js +53 -0
- package/dist/components/FileViewer/FileViewer.sidebar.stylex.d.ts +87 -0
- package/dist/components/FileViewer/FileViewer.sidebar.stylex.js +95 -0
- package/dist/components/FileViewer/FileViewer.skeleton.d.ts +27 -0
- package/dist/components/FileViewer/FileViewer.skeleton.js +80 -0
- package/dist/components/FileViewer/FileViewer.skeleton.stylex.d.ts +86 -0
- package/dist/components/FileViewer/FileViewer.skeleton.stylex.js +70 -0
- package/dist/components/FileViewer/FileViewer.stylex.d.ts +309 -0
- package/dist/components/FileViewer/FileViewer.stylex.js +306 -0
- package/dist/components/FileViewer/FileViewer.view.d.ts +61 -0
- package/dist/components/FileViewer/FileViewer.view.js +205 -0
- package/dist/components/FileViewer/FileViewer.view.stylex.d.ts +105 -0
- package/dist/components/FileViewer/FileViewer.view.stylex.js +109 -0
- package/dist/components/FileViewer/FileViewerHeaderTarget.d.ts +12 -0
- package/dist/components/FileViewer/FileViewerHeaderTarget.js +21 -0
- package/dist/components/FilterForm/FilterForm.context.d.ts +3 -0
- package/dist/components/FilterForm/FilterForm.context.js +3 -0
- package/dist/components/FilterForm/FilterForm.d.ts +6 -0
- package/dist/components/FilterForm/FilterForm.editor.d.ts +12 -0
- package/dist/components/FilterForm/FilterForm.editor.js +119 -0
- package/dist/components/FilterForm/FilterForm.js +125 -0
- package/dist/components/FilterForm/FilterForm.model.d.ts +9 -0
- package/dist/components/FilterForm/FilterForm.model.js +84 -0
- package/dist/components/FilterForm/FilterForm.options.d.ts +19 -0
- package/dist/components/FilterForm/FilterForm.options.js +89 -0
- package/dist/components/FilterForm/FilterForm.stylex.d.ts +17 -0
- package/dist/components/FilterForm/FilterForm.stylex.js +18 -0
- package/dist/components/FilterForm/FilterForm.types.d.ts +70 -0
- package/dist/components/FilterForm/FilterForm.types.js +1 -0
- package/dist/components/FlowFrame/FlowFrame.d.ts +11 -0
- package/dist/components/FlowFrame/FlowFrame.js +26 -0
- package/dist/components/FlowFrame/FlowFrame.stylex.d.ts +8 -0
- package/dist/components/FlowFrame/FlowFrame.stylex.js +8 -0
- package/dist/components/FocusContinuity/FocusContinuity.d.ts +8 -0
- package/dist/components/FocusContinuity/FocusContinuity.js +162 -0
- package/dist/components/FolderIcon/FolderIcon.d.ts +31 -0
- package/dist/components/FolderIcon/FolderIcon.js +34 -0
- package/dist/components/FolderIcon/FolderIcon.stylex.d.ts +9 -0
- package/dist/components/FolderIcon/FolderIcon.stylex.js +11 -0
- package/dist/components/FolderLabel/FolderLabel.d.ts +11 -0
- package/dist/components/FolderLabel/FolderLabel.js +9 -0
- package/dist/components/FolderLabel/FolderLabel.stylex.d.ts +19 -0
- package/dist/components/FolderLabel/FolderLabel.stylex.js +20 -0
- package/dist/components/ForEach/ForEach.d.ts +30 -0
- package/dist/components/ForEach/ForEach.data.d.ts +17 -0
- package/dist/components/ForEach/ForEach.data.js +32 -0
- package/dist/components/ForEach/ForEach.js +26 -0
- package/dist/components/Form/Form.context.d.ts +2 -0
- package/dist/components/Form/Form.context.js +5 -0
- package/dist/components/Form/Form.d.ts +16 -0
- package/dist/components/Form/Form.js +16 -0
- package/dist/components/Form/Form.stylex.d.ts +11 -0
- package/dist/components/Form/Form.stylex.js +12 -0
- package/dist/components/FormField/FormField.d.ts +25 -0
- package/dist/components/FormField/FormField.js +27 -0
- package/dist/components/FormField/FormField.stylex.d.ts +986 -0
- package/dist/components/FormField/FormField.stylex.js +1012 -0
- package/dist/components/Grid/Grid.d.ts +44 -0
- package/dist/components/Grid/Grid.js +212 -0
- package/dist/components/Grid/Grid.sections.d.ts +16 -0
- package/dist/components/Grid/Grid.sections.js +34 -0
- package/dist/components/Grid/Grid.stylex.d.ts +231 -0
- package/dist/components/Grid/Grid.stylex.js +235 -0
- package/dist/components/Grid/Grid.template.d.ts +6 -0
- package/dist/components/Grid/Grid.template.js +6 -0
- package/dist/components/HStack/HStack.d.ts +21 -0
- package/dist/components/HStack/HStack.js +13 -0
- package/dist/components/HStack/HStack.stylex.d.ts +174 -0
- package/dist/components/HStack/HStack.stylex.js +122 -0
- package/dist/components/Heading/Heading.context.d.ts +6 -0
- package/dist/components/Heading/Heading.context.js +12 -0
- package/dist/components/Heading/Heading.d.ts +15 -0
- package/dist/components/Heading/Heading.js +70 -0
- package/dist/components/Icon/FilledIcon.d.ts +5 -0
- package/dist/components/Icon/FilledIcon.js +12 -0
- package/dist/components/Icon/FilledIcon.stylex.d.ts +6 -0
- package/dist/components/Icon/FilledIcon.stylex.js +5 -0
- package/dist/components/Icon/Icon.d.ts +47 -0
- package/dist/components/Icon/Icon.js +101 -0
- package/dist/components/Icon/Icon.registry.d.ts +147 -0
- package/dist/components/Icon/Icon.registry.js +98 -0
- package/dist/components/Icon/Icon.stylex.d.ts +74 -0
- package/dist/components/Icon/Icon.stylex.js +63 -0
- package/dist/components/Icon/IconSlot.d.ts +18 -0
- package/dist/components/Icon/IconSlot.js +84 -0
- package/dist/components/Icon/badgedGlyph.d.ts +14 -0
- package/dist/components/Icon/badgedGlyph.js +23 -0
- package/dist/components/Icon/custom/BrandMarks.d.ts +12 -0
- package/dist/components/Icon/custom/BrandMarks.js +46 -0
- package/dist/components/Icon/custom/FileIcons.d.ts +27 -0
- package/dist/components/Icon/custom/FileIcons.js +117 -0
- package/dist/components/Icon/custom/FolderSearchInput.d.ts +6 -0
- package/dist/components/Icon/custom/FolderSearchInput.js +20 -0
- package/dist/components/Icon/custom/HighlighterOff.d.ts +2 -0
- package/dist/components/Icon/custom/HighlighterOff.js +7 -0
- package/dist/components/Icon/custom/LinkMarks.d.ts +74 -0
- package/dist/components/Icon/custom/LinkMarks.js +112 -0
- package/dist/components/Icon/custom/MessageSquareSearch.d.ts +5 -0
- package/dist/components/Icon/custom/MessageSquareSearch.js +10 -0
- package/dist/components/Icon/custom/PageRegions.d.ts +2 -0
- package/dist/components/Icon/custom/PageRegions.js +12 -0
- package/dist/components/Icon/custom/PanelExpand.d.ts +5 -0
- package/dist/components/Icon/custom/PanelExpand.js +12 -0
- package/dist/components/Icon/custom/SquareDashedPlus.d.ts +2 -0
- package/dist/components/Icon/custom/SquareDashedPlus.js +6 -0
- package/dist/components/Icon/getFileIconName.d.ts +11 -0
- package/dist/components/Icon/getFileIconName.js +140 -0
- package/dist/components/Icon/getLinkIconName.d.ts +23 -0
- package/dist/components/Icon/getLinkIconName.js +142 -0
- package/dist/components/IconButton/IconButton.d.ts +53 -0
- package/dist/components/IconButton/IconButton.js +116 -0
- package/dist/components/IconButton/IconButton.stylex.d.ts +88 -0
- package/dist/components/IconButton/IconButton.stylex.js +85 -0
- package/dist/components/Image/Image.d.ts +20 -0
- package/dist/components/Image/Image.js +45 -0
- package/dist/components/Image/Image.stylex.d.ts +70 -0
- package/dist/components/Image/Image.stylex.js +71 -0
- package/dist/components/ImageRedactor/ImageRedactor.d.ts +26 -0
- package/dist/components/ImageRedactor/ImageRedactor.js +56 -0
- package/dist/components/ImageRedactor/ImageRedactor.stylex.d.ts +49 -0
- package/dist/components/ImageRedactor/ImageRedactor.stylex.js +51 -0
- package/dist/components/Indicator/Indicator.d.ts +23 -0
- package/dist/components/Indicator/Indicator.js +105 -0
- package/dist/components/Indicator/Indicator.stylex.d.ts +181 -0
- package/dist/components/Indicator/Indicator.stylex.js +176 -0
- package/dist/components/InlineAlert/InlineAlert.d.ts +23 -0
- package/dist/components/InlineAlert/InlineAlert.js +54 -0
- package/dist/components/InlineAlert/InlineAlert.stylex.d.ts +105 -0
- package/dist/components/InlineAlert/InlineAlert.stylex.js +104 -0
- package/dist/components/IntentScope/IntentScope.d.ts +17 -0
- package/dist/components/IntentScope/IntentScope.js +19 -0
- package/dist/components/IntentScope/intentCoordinator.d.ts +12 -0
- package/dist/components/IntentScope/intentCoordinator.js +64 -0
- package/dist/components/IntentScope/useIntent.d.ts +12 -0
- package/dist/components/IntentScope/useIntent.js +47 -0
- package/dist/components/JsonValueView/JsonBlock.d.ts +31 -0
- package/dist/components/JsonValueView/JsonBlock.js +25 -0
- package/dist/components/JsonValueView/JsonCopyButton.d.ts +20 -0
- package/dist/components/JsonValueView/JsonCopyButton.js +37 -0
- package/dist/components/JsonValueView/JsonValueControls.d.ts +17 -0
- package/dist/components/JsonValueView/JsonValueControls.js +16 -0
- package/dist/components/JsonValueView/JsonValueExpandedView.d.ts +21 -0
- package/dist/components/JsonValueView/JsonValueExpandedView.js +20 -0
- package/dist/components/JsonValueView/JsonValueView.d.ts +38 -0
- package/dist/components/JsonValueView/JsonValueView.frame.d.ts +12 -0
- package/dist/components/JsonValueView/JsonValueView.frame.js +13 -0
- package/dist/components/JsonValueView/JsonValueView.js +98 -0
- package/dist/components/JsonValueView/JsonValueView.stylex.d.ts +65 -0
- package/dist/components/JsonValueView/JsonValueView.stylex.js +49 -0
- package/dist/components/JsonValueView/JsonValueView.tokens.d.ts +22 -0
- package/dist/components/JsonValueView/JsonValueView.tokens.js +20 -0
- package/dist/components/JsonValueView/JsonValueView.value.d.ts +25 -0
- package/dist/components/JsonValueView/JsonValueView.value.js +107 -0
- package/dist/components/JsonValueView/useJsonValueViewState.d.ts +20 -0
- package/dist/components/JsonValueView/useJsonValueViewState.js +54 -0
- package/dist/components/Keyboard/Keyboard.d.ts +14 -0
- package/dist/components/Keyboard/Keyboard.js +72 -0
- package/dist/components/Keyboard/Keyboard.stylex.d.ts +63 -0
- package/dist/components/Keyboard/Keyboard.stylex.js +64 -0
- package/dist/components/LazyGrid/LazyGrid.d.ts +11 -0
- package/dist/components/LazyGrid/LazyGrid.js +23 -0
- package/dist/components/LazyHStack/LazyHStack.d.ts +18 -0
- package/dist/components/LazyHStack/LazyHStack.js +11 -0
- package/dist/components/LazyList/LazyList.d.ts +11 -0
- package/dist/components/LazyList/LazyList.js +10 -0
- package/dist/components/LazyStackRoot/LazyStackRoot.d.ts +4 -0
- package/dist/components/LazyStackRoot/LazyStackRoot.js +192 -0
- package/dist/components/LazyStackRoot/LazyStackRoot.range.d.ts +28 -0
- package/dist/components/LazyStackRoot/LazyStackRoot.range.js +42 -0
- package/dist/components/LazyStackRoot/LazyStackRoot.scroll.d.ts +7 -0
- package/dist/components/LazyStackRoot/LazyStackRoot.scroll.js +27 -0
- package/dist/components/LazyStackRoot/LazyStackRoot.sticky.d.ts +27 -0
- package/dist/components/LazyStackRoot/LazyStackRoot.sticky.js +64 -0
- package/dist/components/LazyStackRoot/LazyStackRoot.stylex.d.ts +110 -0
- package/dist/components/LazyStackRoot/LazyStackRoot.stylex.js +100 -0
- package/dist/components/LazyStackRoot/LazyStackRoot.types.d.ts +38 -0
- package/dist/components/LazyStackRoot/LazyStackRoot.types.js +1 -0
- package/dist/components/LazyTable/LazyTable.d.ts +11 -0
- package/dist/components/LazyTable/LazyTable.js +28 -0
- package/dist/components/LazyTable/LazyTable.layout.d.ts +43 -0
- package/dist/components/LazyTable/LazyTable.layout.js +213 -0
- package/dist/components/LazyTable/LazyTable.viewport.d.ts +5 -0
- package/dist/components/LazyTable/LazyTable.viewport.js +83 -0
- package/dist/components/LazyTree/LazyTree.d.ts +11 -0
- package/dist/components/LazyTree/LazyTree.js +10 -0
- package/dist/components/LazyVStack/LazyVStack.d.ts +18 -0
- package/dist/components/LazyVStack/LazyVStack.js +15 -0
- package/dist/components/Link/Link.adapter.d.ts +19 -0
- package/dist/components/Link/Link.adapter.js +18 -0
- package/dist/components/Link/Link.d.ts +52 -0
- package/dist/components/Link/Link.js +137 -0
- package/dist/components/Link/Link.stylex.d.ts +200 -0
- package/dist/components/Link/Link.stylex.js +206 -0
- package/dist/components/List/List.d.ts +16 -0
- package/dist/components/List/List.js +90 -0
- package/dist/components/List/List.stylex.d.ts +116 -0
- package/dist/components/List/List.stylex.js +116 -0
- package/dist/components/List/flattenHelpers.d.ts +19 -0
- package/dist/components/List/flattenHelpers.js +88 -0
- package/dist/components/LoadingOverlay/LoadingOverlay.d.ts +9 -0
- package/dist/components/LoadingOverlay/LoadingOverlay.js +16 -0
- package/dist/components/LoadingOverlay/LoadingOverlay.stylex.d.ts +23 -0
- package/dist/components/LoadingOverlay/LoadingOverlay.stylex.js +25 -0
- package/dist/components/LockedPreview/LockedPreview.d.ts +19 -0
- package/dist/components/LockedPreview/LockedPreview.js +11 -0
- package/dist/components/LockedPreview/LockedPreview.stylex.d.ts +26 -0
- package/dist/components/LockedPreview/LockedPreview.stylex.js +27 -0
- package/dist/components/Menu/Menu.collection.d.ts +3 -0
- package/dist/components/Menu/Menu.collection.js +130 -0
- package/dist/components/Menu/Menu.context.d.ts +7 -0
- package/dist/components/Menu/Menu.context.js +16 -0
- package/dist/components/Menu/Menu.d.ts +89 -0
- package/dist/components/Menu/Menu.identity.d.ts +3 -0
- package/dist/components/Menu/Menu.identity.js +3 -0
- package/dist/components/Menu/Menu.inlineRoom.d.ts +15 -0
- package/dist/components/Menu/Menu.inlineRoom.js +64 -0
- package/dist/components/Menu/Menu.js +235 -0
- package/dist/components/Menu/Menu.popoverTrigger.d.ts +10 -0
- package/dist/components/Menu/Menu.popoverTrigger.js +103 -0
- package/dist/components/Menu/Menu.stylex.d.ts +232 -0
- package/dist/components/Menu/Menu.stylex.js +265 -0
- package/dist/components/Menu/MenuItem.children.d.ts +5 -0
- package/dist/components/Menu/MenuItem.children.js +23 -0
- package/dist/components/Meter/Meter.d.ts +25 -0
- package/dist/components/Meter/Meter.js +34 -0
- package/dist/components/Meter/Meter.stylex.d.ts +49 -0
- package/dist/components/Meter/Meter.stylex.js +47 -0
- package/dist/components/Modal/Modal.d.ts +6 -0
- package/dist/components/Modal/Modal.js +14 -0
- package/dist/components/Modal/Modal.types.d.ts +40 -0
- package/dist/components/Modal/Modal.types.js +1 -0
- package/dist/components/Modal/Overlay.d.ts +11 -0
- package/dist/components/Modal/Overlay.js +63 -0
- package/dist/components/Modal/Overlay.stylex.d.ts +190 -0
- package/dist/components/Modal/Overlay.stylex.js +128 -0
- package/dist/components/Modal/OverlayBoundary.d.ts +5 -0
- package/dist/components/Modal/OverlayBoundary.js +17 -0
- package/dist/components/NavigationItem/NavigationItem.d.ts +64 -0
- package/dist/components/NavigationItem/NavigationItem.js +116 -0
- package/dist/components/NavigationItem/NavigationItem.navigationContext.d.ts +15 -0
- package/dist/components/NavigationItem/NavigationItem.navigationContext.js +20 -0
- package/dist/components/NavigationItem/NavigationItem.stylex.d.ts +30 -0
- package/dist/components/NavigationItem/NavigationItem.stylex.js +37 -0
- package/dist/components/NavigationRail/NavigationRail.context.d.ts +5 -0
- package/dist/components/NavigationRail/NavigationRail.context.js +9 -0
- package/dist/components/NavigationRail/NavigationRail.d.ts +12 -0
- package/dist/components/NavigationRail/NavigationRail.js +72 -0
- package/dist/components/NavigationRail/NavigationRail.stylex.d.ts +57 -0
- package/dist/components/NavigationRail/NavigationRail.stylex.js +58 -0
- package/dist/components/NavigationTree/NavigationTree.activeSections.d.ts +7 -0
- package/dist/components/NavigationTree/NavigationTree.activeSections.js +75 -0
- package/dist/components/NavigationTree/NavigationTree.d.ts +21 -0
- package/dist/components/NavigationTree/NavigationTree.js +273 -0
- package/dist/components/NavigationTree/NavigationTree.stylex.d.ts +245 -0
- package/dist/components/NavigationTree/NavigationTree.stylex.js +262 -0
- package/dist/components/NumberField/NumberField.d.ts +73 -0
- package/dist/components/NumberField/NumberField.js +112 -0
- package/dist/components/Option/Option.d.ts +18 -0
- package/dist/components/Option/Option.js +44 -0
- package/dist/components/Option/Option.stylex.d.ts +75 -0
- package/dist/components/Option/Option.stylex.js +74 -0
- package/dist/components/Page/NestedPageAuxiliary.d.ts +3 -0
- package/dist/components/Page/NestedPageAuxiliary.js +44 -0
- package/dist/components/Page/Page.d.ts +59 -0
- package/dist/components/Page/Page.js +265 -0
- package/dist/components/Page/Page.stylex.d.ts +333 -0
- package/dist/components/Page/Page.stylex.js +310 -0
- package/dist/components/Page/PageAuxiliary.context.d.ts +7 -0
- package/dist/components/Page/PageAuxiliary.context.js +2 -0
- package/dist/components/Page/PageAuxiliaryPanel.d.ts +32 -0
- package/dist/components/Page/PageAuxiliaryPanel.js +50 -0
- package/dist/components/Page/PageLabel.d.ts +26 -0
- package/dist/components/Page/PageLabel.js +56 -0
- package/dist/components/Page/PageScrollMotion.d.ts +24 -0
- package/dist/components/Page/PageScrollMotion.js +186 -0
- package/dist/components/Page/PageTitleRow.d.ts +21 -0
- package/dist/components/Page/PageTitleRow.js +50 -0
- package/dist/components/Page/PageTitleRow.stylex.d.ts +16 -0
- package/dist/components/Page/PageTitleRow.stylex.js +17 -0
- package/dist/components/Page/PageToolbar.context.d.ts +35 -0
- package/dist/components/Page/PageToolbar.context.js +43 -0
- package/dist/components/Page/PageToolbar.d.ts +13 -0
- package/dist/components/Page/PageToolbar.js +150 -0
- package/dist/components/Page/PageToolbar.motion.d.ts +5 -0
- package/dist/components/Page/PageToolbar.motion.js +27 -0
- package/dist/components/Page/PageToolbar.stylex.d.ts +41 -0
- package/dist/components/Page/PageToolbar.stylex.js +37 -0
- package/dist/components/Page/revealAuxiliary.d.ts +2 -0
- package/dist/components/Page/revealAuxiliary.js +56 -0
- package/dist/components/PageToolbar/PageToolbar.d.ts +7 -0
- package/dist/components/PageToolbar/PageToolbar.js +12 -0
- package/dist/components/Popover/OverflowPickerSearch.d.ts +7 -0
- package/dist/components/Popover/OverflowPickerSearch.js +10 -0
- package/dist/components/Popover/Popover.anchor.d.ts +12 -0
- package/dist/components/Popover/Popover.anchor.js +87 -0
- package/dist/components/Popover/Popover.context.d.ts +11 -0
- package/dist/components/Popover/Popover.context.js +11 -0
- package/dist/components/Popover/Popover.d.ts +69 -0
- package/dist/components/Popover/Popover.js +253 -0
- package/dist/components/Popover/Popover.pressTrigger.d.ts +12 -0
- package/dist/components/Popover/Popover.pressTrigger.js +54 -0
- package/dist/components/Popover/Popover.stylex.d.ts +98 -0
- package/dist/components/Popover/Popover.stylex.js +109 -0
- package/dist/components/Popover/Popover.viewport.d.ts +10 -0
- package/dist/components/Popover/Popover.viewport.js +61 -0
- package/dist/components/Popover/useHoverOpen.d.ts +24 -0
- package/dist/components/Popover/useHoverOpen.js +132 -0
- package/dist/components/Progress/Progress.d.ts +21 -0
- package/dist/components/Progress/Progress.js +20 -0
- package/dist/components/Progress/Progress.stylex.d.ts +90 -0
- package/dist/components/Progress/Progress.stylex.js +83 -0
- package/dist/components/RadioGroup/RadioGroup.children.d.ts +8 -0
- package/dist/components/RadioGroup/RadioGroup.children.js +64 -0
- package/dist/components/RadioGroup/RadioGroup.colors.d.ts +13 -0
- package/dist/components/RadioGroup/RadioGroup.colors.js +11 -0
- package/dist/components/RadioGroup/RadioGroup.d.ts +73 -0
- package/dist/components/RadioGroup/RadioGroup.js +85 -0
- package/dist/components/RadioGroup/RadioGroup.stylex.d.ts +87 -0
- package/dist/components/RadioGroup/RadioGroup.stylex.js +57 -0
- package/dist/components/ReflowContainer/ReflowContainer.d.ts +30 -0
- package/dist/components/ReflowContainer/ReflowContainer.js +106 -0
- package/dist/components/Region/Region.d.ts +50 -0
- package/dist/components/Region/Region.js +29 -0
- package/dist/components/RenderingTreatment/RenderingTreatment.context.d.ts +34 -0
- package/dist/components/RenderingTreatment/RenderingTreatment.context.js +49 -0
- package/dist/components/ResourceList/ResourceList.d.ts +7 -0
- package/dist/components/ResourceList/ResourceList.js +89 -0
- package/dist/components/ResourceList/ResourceList.model.d.ts +65 -0
- package/dist/components/ResourceList/ResourceList.model.js +372 -0
- package/dist/components/ResourceList/ResourceList.rows.d.ts +18 -0
- package/dist/components/ResourceList/ResourceList.rows.js +86 -0
- package/dist/components/ResourceList/ResourceList.stylex.d.ts +338 -0
- package/dist/components/ResourceList/ResourceList.stylex.js +272 -0
- package/dist/components/ResourceList/ResourceList.table.d.ts +22 -0
- package/dist/components/ResourceList/ResourceList.table.js +149 -0
- package/dist/components/ResourceList/ResourceList.types.d.ts +120 -0
- package/dist/components/ResourceList/ResourceList.types.js +18 -0
- package/dist/components/Reveal/Reveal.d.ts +36 -0
- package/dist/components/Reveal/Reveal.js +18 -0
- package/dist/components/Reveal/Reveal.stylex.d.ts +125 -0
- package/dist/components/Reveal/Reveal.stylex.js +155 -0
- package/dist/components/RotatingStatus/RotatingStatus.d.ts +17 -0
- package/dist/components/RotatingStatus/RotatingStatus.js +43 -0
- package/dist/components/RotatingStatus/RotatingStatus.stylex.d.ts +27 -0
- package/dist/components/RotatingStatus/RotatingStatus.stylex.js +28 -0
- package/dist/components/RouterProvider/RouterProvider.d.ts +22 -0
- package/dist/components/RouterProvider/RouterProvider.js +12 -0
- package/dist/components/RowButton/RowButton.d.ts +21 -0
- package/dist/components/RowButton/RowButton.js +16 -0
- package/dist/components/RowButton/RowButton.stylex.d.ts +71 -0
- package/dist/components/RowButton/RowButton.stylex.js +80 -0
- package/dist/components/SafeInsetArea/SafeInsetArea.context.d.ts +20 -0
- package/dist/components/SafeInsetArea/SafeInsetArea.context.js +229 -0
- package/dist/components/SafeInsetArea/SafeInsetArea.d.ts +10 -0
- package/dist/components/SafeInsetArea/SafeInsetArea.edges.d.ts +16 -0
- package/dist/components/SafeInsetArea/SafeInsetArea.edges.js +114 -0
- package/dist/components/SafeInsetArea/SafeInsetArea.js +30 -0
- package/dist/components/SafeInsetArea/SafeInsetArea.styles.d.ts +4 -0
- package/dist/components/SafeInsetArea/SafeInsetArea.styles.js +44 -0
- package/dist/components/SafeInsetArea/SafeInsetArea.stylex.d.ts +15 -0
- package/dist/components/SafeInsetArea/SafeInsetArea.stylex.js +15 -0
- package/dist/components/SafeInsetArea/SafeInsetArea.types.d.ts +71 -0
- package/dist/components/SafeInsetArea/SafeInsetArea.types.js +1 -0
- package/dist/components/ScrollArea/ScrollArea.d.ts +73 -0
- package/dist/components/ScrollArea/ScrollArea.js +176 -0
- package/dist/components/ScrollArea/ScrollArea.stylex.d.ts +222 -0
- package/dist/components/ScrollArea/ScrollArea.stylex.js +253 -0
- package/dist/components/ScrollArea/ScrollAreaEdgeEffect.d.ts +8 -0
- package/dist/components/ScrollArea/ScrollAreaEdgeEffect.js +13 -0
- package/dist/components/ScrollArea/ScrollAreaEdgeEffect.stylex.d.ts +60 -0
- package/dist/components/ScrollArea/ScrollAreaEdgeEffect.stylex.js +37 -0
- package/dist/components/ScrollArea/ScrollAreaMarker.d.ts +23 -0
- package/dist/components/ScrollArea/ScrollAreaMarker.js +14 -0
- package/dist/components/ScrollArea/ScrollAreaMarkers.d.ts +17 -0
- package/dist/components/ScrollArea/ScrollAreaMarkers.js +206 -0
- package/dist/components/ScrollArea/ScrollAreaMarkers.stylex.d.ts +166 -0
- package/dist/components/ScrollArea/ScrollAreaMarkers.stylex.js +194 -0
- package/dist/components/ScrollArea/ScrollAreaOutline.d.ts +20 -0
- package/dist/components/ScrollArea/ScrollAreaOutline.js +53 -0
- package/dist/components/ScrollArea/ScrollAreaScrollbar.d.ts +16 -0
- package/dist/components/ScrollArea/ScrollAreaScrollbar.js +137 -0
- package/dist/components/ScrollArea/navigateToScrollTarget.d.ts +5 -0
- package/dist/components/ScrollArea/navigateToScrollTarget.js +17 -0
- package/dist/components/ScrollArea/scrollbarGeometry.d.ts +6 -0
- package/dist/components/ScrollArea/scrollbarGeometry.js +7 -0
- package/dist/components/ScrollArea/useHasNoTabStops.d.ts +3 -0
- package/dist/components/ScrollArea/useHasNoTabStops.js +37 -0
- package/dist/components/ScrollArea/useHorizontalWheel.d.ts +3 -0
- package/dist/components/ScrollArea/useHorizontalWheel.js +40 -0
- package/dist/components/ScrollArea/useMarkerNavigation.d.ts +7 -0
- package/dist/components/ScrollArea/useMarkerNavigation.js +41 -0
- package/dist/components/ScrollArea/useMarkerRail.d.ts +16 -0
- package/dist/components/ScrollArea/useMarkerRail.js +37 -0
- package/dist/components/ScrollArea/useScrollArea.d.ts +22 -0
- package/dist/components/ScrollArea/useScrollArea.js +103 -0
- package/dist/components/ScrollArea/useScrollAreaMarkers.d.ts +38 -0
- package/dist/components/ScrollArea/useScrollAreaMarkers.js +154 -0
- package/dist/components/SearchField/SearchField.d.ts +29 -0
- package/dist/components/SearchField/SearchField.js +51 -0
- package/dist/components/SearchField/SearchField.stylex.d.ts +82 -0
- package/dist/components/SearchField/SearchField.stylex.js +60 -0
- package/dist/components/SecretField/SecretField.d.ts +66 -0
- package/dist/components/SecretField/SecretField.js +61 -0
- package/dist/components/Section/Section.d.ts +41 -0
- package/dist/components/Section/Section.data.d.ts +12 -0
- package/dist/components/Section/Section.data.js +16 -0
- package/dist/components/Section/Section.js +45 -0
- package/dist/components/Section/Section.stylex.d.ts +24 -0
- package/dist/components/Section/Section.stylex.js +26 -0
- package/dist/components/Select/Select.body.d.ts +14 -0
- package/dist/components/Select/Select.body.js +17 -0
- package/dist/components/Select/Select.collection.d.ts +7 -0
- package/dist/components/Select/Select.collection.js +67 -0
- package/dist/components/Select/Select.context.d.ts +1 -0
- package/dist/components/Select/Select.context.js +2 -0
- package/dist/components/Select/Select.d.ts +60 -0
- package/dist/components/Select/Select.js +118 -0
- package/dist/components/Select/Select.stylex.d.ts +131 -0
- package/dist/components/Select/Select.stylex.js +132 -0
- package/dist/components/Select/useSelectFormReset.d.ts +2 -0
- package/dist/components/Select/useSelectFormReset.js +25 -0
- package/dist/components/Separator/Separator.d.ts +26 -0
- package/dist/components/Separator/Separator.js +31 -0
- package/dist/components/Separator/Separator.stylex.d.ts +33 -0
- package/dist/components/Separator/Separator.stylex.js +34 -0
- package/dist/components/Sheet/Sheet.d.ts +24 -0
- package/dist/components/Sheet/Sheet.js +17 -0
- package/dist/components/Shortcuts/ShortcutIndicator.d.ts +5 -0
- package/dist/components/Shortcuts/ShortcutIndicator.js +10 -0
- package/dist/components/Shortcuts/Shortcuts.context.d.ts +9 -0
- package/dist/components/Shortcuts/Shortcuts.context.js +8 -0
- package/dist/components/Shortcuts/Shortcuts.d.ts +14 -0
- package/dist/components/Shortcuts/Shortcuts.js +50 -0
- package/dist/components/Shortcuts/Shortcuts.stylex.d.ts +29 -0
- package/dist/components/Shortcuts/Shortcuts.stylex.js +28 -0
- package/dist/components/Shortcuts/Shortcuts.types.d.ts +56 -0
- package/dist/components/Shortcuts/Shortcuts.types.js +1 -0
- package/dist/components/Shortcuts/ShortcutsHelp.d.ts +5 -0
- package/dist/components/Shortcuts/ShortcutsHelp.js +70 -0
- package/dist/components/Shortcuts/shortcutKeys.d.ts +6 -0
- package/dist/components/Shortcuts/shortcutKeys.js +61 -0
- package/dist/components/Shortcuts/shortcutRegistry.d.ts +36 -0
- package/dist/components/Shortcuts/shortcutRegistry.js +153 -0
- package/dist/components/Shortcuts/useShortcut.d.ts +12 -0
- package/dist/components/Shortcuts/useShortcut.js +127 -0
- package/dist/components/ShowMore/ShowMore.d.ts +18 -0
- package/dist/components/ShowMore/ShowMore.js +44 -0
- package/dist/components/ShowMore/ShowMore.lines.d.ts +23 -0
- package/dist/components/ShowMore/ShowMore.lines.js +49 -0
- package/dist/components/ShowMore/ShowMore.stylex.d.ts +24 -0
- package/dist/components/ShowMore/ShowMore.stylex.js +26 -0
- package/dist/components/Skeleton/Skeleton.d.ts +16 -0
- package/dist/components/Skeleton/Skeleton.js +8 -0
- package/dist/components/Skeleton/Skeleton.stylex.d.ts +68 -0
- package/dist/components/Skeleton/Skeleton.stylex.js +78 -0
- package/dist/components/Skeleton/useSkeleton.d.ts +87 -0
- package/dist/components/Skeleton/useSkeleton.js +34 -0
- package/dist/components/Slider/Slider.d.ts +44 -0
- package/dist/components/Slider/Slider.js +56 -0
- package/dist/components/Slider/Slider.stylex.d.ts +105 -0
- package/dist/components/Slider/Slider.stylex.js +70 -0
- package/dist/components/Slot/Slot.d.ts +17 -0
- package/dist/components/Slot/Slot.js +83 -0
- package/dist/components/Slot/Slot.resolve.d.ts +3 -0
- package/dist/components/Slot/Slot.resolve.js +22 -0
- package/dist/components/Slot/Slot.scope.d.ts +7 -0
- package/dist/components/Slot/Slot.scope.js +19 -0
- package/dist/components/Slot/Slot.types.d.ts +64 -0
- package/dist/components/Slot/Slot.types.js +1 -0
- package/dist/components/Spacer/Spacer.d.ts +5 -0
- package/dist/components/Spacer/Spacer.js +6 -0
- package/dist/components/Spacer/Spacer.stylex.d.ts +10 -0
- package/dist/components/Spacer/Spacer.stylex.js +10 -0
- package/dist/components/SplitLayout/SplitLayout.d.ts +43 -0
- package/dist/components/SplitLayout/SplitLayout.js +20 -0
- package/dist/components/SplitLayout/SplitLayout.stylex.d.ts +51 -0
- package/dist/components/SplitLayout/SplitLayout.stylex.js +77 -0
- package/dist/components/Stack/StackInsets.context.d.ts +14 -0
- package/dist/components/Stack/StackInsets.context.js +17 -0
- package/dist/components/Stack/StackPadding.stylex.d.ts +113 -0
- package/dist/components/Stack/StackPadding.stylex.js +154 -0
- package/dist/components/Stack/StackPropTypes.d.ts +30 -0
- package/dist/components/Stack/StackPropTypes.js +14 -0
- package/dist/components/StatCard/StatCard.d.ts +32 -0
- package/dist/components/StatCard/StatCard.js +15 -0
- package/dist/components/StatCard/StatCard.stylex.d.ts +101 -0
- package/dist/components/StatCard/StatCard.stylex.js +127 -0
- package/dist/components/StatCard/StatCard.vars.stylex.d.ts +22 -0
- package/dist/components/StatCard/StatCard.vars.stylex.js +26 -0
- package/dist/components/StepList/StepList.d.ts +52 -0
- package/dist/components/StepList/StepList.js +36 -0
- package/dist/components/StepList/StepList.stylex.d.ts +139 -0
- package/dist/components/StepList/StepList.stylex.js +134 -0
- package/dist/components/Stepper/Stepper.d.ts +49 -0
- package/dist/components/Stepper/Stepper.js +59 -0
- package/dist/components/Stepper/Stepper.stylex.d.ts +131 -0
- package/dist/components/Stepper/Stepper.stylex.js +147 -0
- package/dist/components/Stepper/useStepNamesFit.d.ts +12 -0
- package/dist/components/Stepper/useStepNamesFit.js +65 -0
- package/dist/components/Surface/Surface.colors.d.ts +4 -0
- package/dist/components/Surface/Surface.colors.js +34 -0
- package/dist/components/Surface/Surface.d.ts +41 -0
- package/dist/components/Surface/Surface.js +36 -0
- package/dist/components/Surface/Surface.stylex.d.ts +139 -0
- package/dist/components/Surface/Surface.stylex.js +121 -0
- package/dist/components/Switch/Switch.d.ts +50 -0
- package/dist/components/Switch/Switch.js +28 -0
- package/dist/components/TOC/TOC.activeEntry.d.ts +14 -0
- package/dist/components/TOC/TOC.activeEntry.js +89 -0
- package/dist/components/TOC/TOC.context.d.ts +33 -0
- package/dist/components/TOC/TOC.context.js +55 -0
- package/dist/components/TOC/TOC.d.ts +8 -0
- package/dist/components/TOC/TOC.js +49 -0
- package/dist/components/TOC/TOC.stylex.d.ts +60 -0
- package/dist/components/TOC/TOC.stylex.js +59 -0
- package/dist/components/Table/Table.d.ts +6 -0
- package/dist/components/Table/Table.data.d.ts +24 -0
- package/dist/components/Table/Table.data.js +224 -0
- package/dist/components/Table/Table.js +317 -0
- package/dist/components/Table/Table.layout.d.ts +33 -0
- package/dist/components/Table/Table.layout.js +246 -0
- package/dist/components/Table/Table.parts.d.ts +13 -0
- package/dist/components/Table/Table.parts.js +17 -0
- package/dist/components/Table/Table.stylex.d.ts +504 -0
- package/dist/components/Table/Table.stylex.js +468 -0
- package/dist/components/Table/Table.types.d.ts +114 -0
- package/dist/components/Table/Table.types.js +11 -0
- package/dist/components/Table/TableRowLink.d.ts +16 -0
- package/dist/components/Table/TableRowLink.js +39 -0
- package/dist/components/Tabs/NewTabAction.d.ts +7 -0
- package/dist/components/Tabs/NewTabAction.js +25 -0
- package/dist/components/Tabs/Tab.d.ts +11 -0
- package/dist/components/Tabs/Tab.js +10 -0
- package/dist/components/Tabs/TabActionButton.d.ts +14 -0
- package/dist/components/Tabs/TabActionButton.js +60 -0
- package/dist/components/Tabs/TabActions.d.ts +12 -0
- package/dist/components/Tabs/TabActions.js +119 -0
- package/dist/components/Tabs/TabOutlet.d.ts +9 -0
- package/dist/components/Tabs/TabOutlet.js +15 -0
- package/dist/components/Tabs/TabPanelTransition.d.ts +18 -0
- package/dist/components/Tabs/TabPanelTransition.js +20 -0
- package/dist/components/Tabs/Tabs.children.d.ts +16 -0
- package/dist/components/Tabs/Tabs.children.js +97 -0
- package/dist/components/Tabs/Tabs.d.ts +5 -0
- package/dist/components/Tabs/Tabs.js +270 -0
- package/dist/components/Tabs/Tabs.state.d.ts +19 -0
- package/dist/components/Tabs/Tabs.state.js +13 -0
- package/dist/components/Tabs/Tabs.stylex.d.ts +476 -0
- package/dist/components/Tabs/Tabs.stylex.js +376 -0
- package/dist/components/Tabs/Tabs.types.d.ts +99 -0
- package/dist/components/Tabs/Tabs.types.js +6 -0
- package/dist/components/Tabs/TabsPicker.d.ts +8 -0
- package/dist/components/Tabs/TabsPicker.js +21 -0
- package/dist/components/Tabs/useTabOverflow.d.ts +9 -0
- package/dist/components/Tabs/useTabOverflow.js +55 -0
- package/dist/components/Tabs/useTabReorder.d.ts +22 -0
- package/dist/components/Tabs/useTabReorder.js +133 -0
- package/dist/components/Tabs/useTabScrollRestoration.d.ts +4 -0
- package/dist/components/Tabs/useTabScrollRestoration.js +100 -0
- package/dist/components/Tabs/useTabs.d.ts +10 -0
- package/dist/components/Tabs/useTabs.js +43 -0
- package/dist/components/Tabs/useTabsPickerMotion.d.ts +6 -0
- package/dist/components/Tabs/useTabsPickerMotion.js +64 -0
- package/dist/components/TagGroup/CollapsedTagGroup.d.ts +13 -0
- package/dist/components/TagGroup/CollapsedTagGroup.js +205 -0
- package/dist/components/TagGroup/Tag.d.ts +22 -0
- package/dist/components/TagGroup/Tag.js +5 -0
- package/dist/components/TagGroup/TagCollection.d.ts +15 -0
- package/dist/components/TagGroup/TagCollection.js +30 -0
- package/dist/components/TagGroup/TagContents.d.ts +8 -0
- package/dist/components/TagGroup/TagContents.js +109 -0
- package/dist/components/TagGroup/TagGroup.children.d.ts +11 -0
- package/dist/components/TagGroup/TagGroup.children.js +59 -0
- package/dist/components/TagGroup/TagGroup.d.ts +29 -0
- package/dist/components/TagGroup/TagGroup.js +20 -0
- package/dist/components/TagGroup/TagGroup.stylex.d.ts +226 -0
- package/dist/components/TagGroup/TagGroup.stylex.js +162 -0
- package/dist/components/TagGroup/tagGroupLayout.d.ts +5 -0
- package/dist/components/TagGroup/tagGroupLayout.js +20 -0
- package/dist/components/Text/Text.d.ts +81 -0
- package/dist/components/Text/Text.js +124 -0
- package/dist/components/Text/Text.stylex.d.ts +239 -0
- package/dist/components/Text/Text.stylex.js +231 -0
- package/dist/components/Text/Text.truncation.d.ts +44 -0
- package/dist/components/Text/Text.truncation.js +365 -0
- package/dist/components/Text/Text.truncation.stylex.d.ts +42 -0
- package/dist/components/Text/Text.truncation.stylex.js +53 -0
- package/dist/components/TextArea/TextArea.d.ts +63 -0
- package/dist/components/TextArea/TextArea.js +43 -0
- package/dist/components/TextField/TextField.d.ts +67 -0
- package/dist/components/TextField/TextField.js +46 -0
- package/dist/components/TileButton/TileButton.d.ts +37 -0
- package/dist/components/TileButton/TileButton.js +23 -0
- package/dist/components/TileButton/TileButton.stylex.d.ts +68 -0
- package/dist/components/TileButton/TileButton.stylex.js +74 -0
- package/dist/components/TileButton/TileButton.vars.stylex.d.ts +10 -0
- package/dist/components/TileButton/TileButton.vars.stylex.js +13 -0
- package/dist/components/Time/Time.d.ts +25 -0
- package/dist/components/Time/Time.format.d.ts +22 -0
- package/dist/components/Time/Time.format.js +55 -0
- package/dist/components/Time/Time.js +31 -0
- package/dist/components/Time/Time.stylex.d.ts +14 -0
- package/dist/components/Time/Time.stylex.js +15 -0
- package/dist/components/TimeField/TimeField.d.ts +52 -0
- package/dist/components/TimeField/TimeField.js +53 -0
- package/dist/components/TimelineLanes/TimelineLanes.d.ts +71 -0
- package/dist/components/TimelineLanes/TimelineLanes.js +83 -0
- package/dist/components/TimelineLanes/TimelineLanes.scale.d.ts +14 -0
- package/dist/components/TimelineLanes/TimelineLanes.scale.js +35 -0
- package/dist/components/TimelineLanes/TimelineLanes.stylex.d.ts +280 -0
- package/dist/components/TimelineLanes/TimelineLanes.stylex.js +329 -0
- package/dist/components/Toast/Toast.context.d.ts +3 -0
- package/dist/components/Toast/Toast.context.js +8 -0
- package/dist/components/Toast/Toast.d.ts +5 -0
- package/dist/components/Toast/Toast.js +63 -0
- package/dist/components/Toast/Toast.stylex.d.ts +173 -0
- package/dist/components/Toast/Toast.stylex.js +137 -0
- package/dist/components/Toast/Toast.types.d.ts +31 -0
- package/dist/components/Toast/Toast.types.js +9 -0
- package/dist/components/Toast/ToastCountdown.d.ts +7 -0
- package/dist/components/Toast/ToastCountdown.js +48 -0
- package/dist/components/Toast/ToastView.d.ts +6 -0
- package/dist/components/Toast/ToastView.js +39 -0
- package/dist/components/Toast/createToastEntry.d.ts +9 -0
- package/dist/components/Toast/createToastEntry.js +33 -0
- package/dist/components/ToggleButton/ToggleButton.d.ts +45 -0
- package/dist/components/ToggleButton/ToggleButton.js +97 -0
- package/dist/components/ToggleButton/ToggleButton.stylex.d.ts +118 -0
- package/dist/components/ToggleButton/ToggleButton.stylex.js +109 -0
- package/dist/components/Toolbar/Toolbar.children.d.ts +19 -0
- package/dist/components/Toolbar/Toolbar.children.js +83 -0
- package/dist/components/Toolbar/Toolbar.d.ts +37 -0
- package/dist/components/Toolbar/Toolbar.js +180 -0
- package/dist/components/Toolbar/Toolbar.layout.d.ts +20 -0
- package/dist/components/Toolbar/Toolbar.layout.js +104 -0
- package/dist/components/Toolbar/Toolbar.menu.d.ts +27 -0
- package/dist/components/Toolbar/Toolbar.menu.js +213 -0
- package/dist/components/Toolbar/Toolbar.stylex.d.ts +69 -0
- package/dist/components/Toolbar/Toolbar.stylex.js +48 -0
- package/dist/components/Toolbar/ToolbarControl.context.d.ts +6 -0
- package/dist/components/Toolbar/ToolbarControl.context.js +9 -0
- package/dist/components/Toolbar/ToolbarControl.stylex.d.ts +42 -0
- package/dist/components/Toolbar/ToolbarControl.stylex.js +50 -0
- package/dist/components/Toolbar/ToolbarGroupLabel.d.ts +3 -0
- package/dist/components/Toolbar/ToolbarGroupLabel.js +22 -0
- package/dist/components/Toolbar/ToolbarMenuTrigger.d.ts +6 -0
- package/dist/components/Toolbar/ToolbarMenuTrigger.js +20 -0
- package/dist/components/Toolbar/ToolbarNote.d.ts +13 -0
- package/dist/components/Toolbar/ToolbarNote.js +8 -0
- package/dist/components/Tooltip/Tooltip.d.ts +43 -0
- package/dist/components/Tooltip/Tooltip.js +139 -0
- package/dist/components/Tooltip/Tooltip.stylex.d.ts +106 -0
- package/dist/components/Tooltip/Tooltip.stylex.js +105 -0
- package/dist/components/Tooltip/Tooltip.unavailableContext.d.ts +9 -0
- package/dist/components/Tooltip/Tooltip.unavailableContext.js +12 -0
- package/dist/components/TourLayer/TourLayer.d.ts +14 -0
- package/dist/components/TourLayer/TourLayer.js +17 -0
- package/dist/components/TourLayer/TourLayer.stylex.d.ts +10 -0
- package/dist/components/TourLayer/TourLayer.stylex.js +11 -0
- package/dist/components/Tree/Tree.d.ts +21 -0
- package/dist/components/Tree/Tree.js +88 -0
- package/dist/components/Tree/Tree.stylex.d.ts +101 -0
- package/dist/components/Tree/Tree.stylex.js +103 -0
- package/dist/components/Trigger/Trigger.d.ts +10 -0
- package/dist/components/Trigger/Trigger.js +23 -0
- package/dist/components/UnsavedChangesScope/UnsavedChangesScope.d.ts +44 -0
- package/dist/components/UnsavedChangesScope/UnsavedChangesScope.js +136 -0
- package/dist/components/VStack/VStack.d.ts +26 -0
- package/dist/components/VStack/VStack.js +11 -0
- package/dist/components/VStack/VStack.stylex.d.ts +174 -0
- package/dist/components/VStack/VStack.stylex.js +124 -0
- package/dist/components/VisuallyHidden/VisuallyHidden.d.ts +13 -0
- package/dist/components/VisuallyHidden/VisuallyHidden.js +11 -0
- package/dist/components/WelcomeDialog/WelcomeDialog.d.ts +28 -0
- package/dist/components/WelcomeDialog/WelcomeDialog.js +45 -0
- package/dist/components/WelcomeDialog/WelcomeDialog.stylex.d.ts +88 -0
- package/dist/components/WelcomeDialog/WelcomeDialog.stylex.js +106 -0
- package/dist/components/WindowSplitter/WindowSplitter.d.ts +43 -0
- package/dist/components/WindowSplitter/WindowSplitter.detached.d.ts +6 -0
- package/dist/components/WindowSplitter/WindowSplitter.detached.js +7 -0
- package/dist/components/WindowSplitter/WindowSplitter.drawer.d.ts +70 -0
- package/dist/components/WindowSplitter/WindowSplitter.drawer.js +88 -0
- package/dist/components/WindowSplitter/WindowSplitter.js +613 -0
- package/dist/components/WindowSplitter/WindowSplitter.peek.d.ts +33 -0
- package/dist/components/WindowSplitter/WindowSplitter.peek.js +90 -0
- package/dist/components/WindowSplitter/WindowSplitter.sizing.d.ts +11 -0
- package/dist/components/WindowSplitter/WindowSplitter.sizing.js +50 -0
- package/dist/components/WindowSplitter/WindowSplitter.stylex.d.ts +180 -0
- package/dist/components/WindowSplitter/WindowSplitter.stylex.js +163 -0
- package/dist/components/ZStack/ZStack.d.ts +41 -0
- package/dist/components/ZStack/ZStack.js +43 -0
- package/dist/components/ZStack/ZStack.stylex.d.ts +78 -0
- package/dist/components/ZStack/ZStack.stylex.js +42 -0
- package/dist/experimental/index.d.ts +48 -0
- package/dist/experimental/index.js +45 -0
- package/dist/files/index.d.ts +22 -0
- package/dist/files/index.js +19 -0
- package/dist/foundations/Color.context.d.ts +29 -0
- package/dist/foundations/Color.context.js +58 -0
- package/dist/foundations/Color.core.d.ts +70 -0
- package/dist/foundations/Color.core.js +323 -0
- package/dist/foundations/Color.d.ts +1 -0
- package/dist/foundations/Color.js +1 -0
- package/dist/foundations/Color.styles.stylex.d.ts +21 -0
- package/dist/foundations/Color.styles.stylex.js +34 -0
- package/dist/foundations/constants.stylex.d.ts +18 -0
- package/dist/foundations/constants.stylex.js +20 -0
- package/dist/foundations/textStyles.stylex.d.ts +87 -0
- package/dist/foundations/textStyles.stylex.js +88 -0
- package/dist/foundations/viewport.d.ts +5 -0
- package/dist/foundations/viewport.js +17 -0
- package/dist/index.d.ts +171 -0
- package/dist/index.js +189 -0
- package/dist/internal.d.ts +2 -0
- package/dist/internal.js +1 -0
- package/dist/theming/OverlayRegion.d.ts +15 -0
- package/dist/theming/OverlayRegion.js +36 -0
- package/dist/theming/ThemeRegion.d.ts +22 -0
- package/dist/theming/ThemeRegion.js +28 -0
- package/dist/theming/ThemeScope.context.d.ts +40 -0
- package/dist/theming/ThemeScope.context.js +76 -0
- package/dist/theming/ThemeScope.d.ts +35 -0
- package/dist/theming/ThemeScope.js +67 -0
- package/dist/theming/ThemeScope.stylex.d.ts +34 -0
- package/dist/theming/ThemeScope.stylex.js +54 -0
- package/dist/theming/color.d.ts +51 -0
- package/dist/theming/color.js +175 -0
- package/dist/theming/createTheme.d.ts +145 -0
- package/dist/theming/createTheme.js +1009 -0
- package/dist/theming/designTokens.d.ts +49 -0
- package/dist/theming/designTokens.js +138 -0
- package/dist/theming/effectiveTheme.d.ts +154 -0
- package/dist/theming/effectiveTheme.js +62 -0
- package/dist/theming/themeStylesheet.d.ts +20 -0
- package/dist/theming/themeStylesheet.js +106 -0
- package/dist/theming/tokens.d.ts +48 -0
- package/dist/theming/tokens.js +314 -0
- package/dist/theming/tokens.stylex.d.ts +592 -0
- package/dist/theming/tokens.stylex.js +1265 -0
- package/dist/utils/declarationError.d.ts +7 -0
- package/dist/utils/declarationError.js +16 -0
- package/dist/utils/deviceCache.d.ts +40 -0
- package/dist/utils/deviceCache.js +234 -0
- package/dist/utils/isSoftwareKeyboardLikely.d.ts +2 -0
- package/dist/utils/isSoftwareKeyboardLikely.js +12 -0
- package/dist/utils/performance.d.ts +3 -0
- package/dist/utils/performance.js +5 -0
- package/dist/utils/preferences.d.ts +35 -0
- package/dist/utils/preferences.js +77 -0
- package/dist/utils/preload.d.ts +10 -0
- package/dist/utils/preload.js +12 -0
- package/dist/utils/props.d.ts +5 -0
- package/dist/utils/props.js +10 -0
- package/dist/utils/resolveAutoFocus.d.ts +3 -0
- package/dist/utils/resolveAutoFocus.js +8 -0
- package/dist/utils/trackRegionActivity.d.ts +13 -0
- package/dist/utils/trackRegionActivity.js +72 -0
- package/dist/utils/useAutoFocus.d.ts +6 -0
- package/dist/utils/useAutoFocus.js +16 -0
- package/dist/utils/visuallyHidden.stylex.d.ts +15 -0
- package/dist/utils/visuallyHidden.stylex.js +15 -0
- package/package.json +139 -7
|
@@ -0,0 +1,209 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import * as stylex from '@stylexjs/stylex';
|
|
3
|
+
import { useEffect, useRef, useState } from 'react';
|
|
4
|
+
import { Button } from "../Button/Button.js";
|
|
5
|
+
import { Footer } from "../Content/Content.js";
|
|
6
|
+
import { Dialog } from "../Dialog/Dialog.js";
|
|
7
|
+
import { FileIcon } from "../FileIcon/FileIcon.js";
|
|
8
|
+
import { IconButton } from "../IconButton/IconButton.js";
|
|
9
|
+
import { TextField } from "../TextField/TextField.js";
|
|
10
|
+
import { InlineAlert } from "../InlineAlert/InlineAlert.js";
|
|
11
|
+
import { Modal } from "../Modal/Modal.js";
|
|
12
|
+
import { Text } from "../Text/Text.js";
|
|
13
|
+
import { useShortcut } from "../Shortcuts/useShortcut.js";
|
|
14
|
+
import { useUnsavedChanges, } from "../UnsavedChangesScope/UnsavedChangesScope.js";
|
|
15
|
+
import { fileSourceErrorKind, fileSourceErrorMessage } from "../FileScope/FileSourceError.js";
|
|
16
|
+
import { Menu, MenuItem } from "../Menu/Menu.js";
|
|
17
|
+
import { FrameControls, LabeledToggle } from "./FileViewer.chrome.js";
|
|
18
|
+
import { ViewerHeader, useViewerFrame } from "./FileViewer.frame.js";
|
|
19
|
+
import { styles } from "./FileViewer.stylex.js";
|
|
20
|
+
/**
|
|
21
|
+
* Editing the open file's text, for a renderer that declares `edit` on a source that can `write`.
|
|
22
|
+
* Edit hands the body `isEditing`; the body reports each change with `onDraftChange`, and Save
|
|
23
|
+
* writes the text it reads back. While there are unsaved changes, closing the viewer, opening
|
|
24
|
+
* another file or leaving the page asks first. A save that finds the file changed elsewhere
|
|
25
|
+
* offers to overwrite it, or to drop the changes and show what's there now. Search stays open
|
|
26
|
+
* while editing, searches the draft, and offers Replace and Replace all.
|
|
27
|
+
*/
|
|
28
|
+
export function useFileEditing({ store, entry, canEdit, search, editors, }) {
|
|
29
|
+
const [isEditing, setEditing] = useState(false);
|
|
30
|
+
// The file as it was when editing began, with its content: the body stays on it while the
|
|
31
|
+
// reader edits, so a newer version saved elsewhere doesn't replace the draft, and Save writes
|
|
32
|
+
// against it, so that version is a conflict to resolve rather than something overwritten.
|
|
33
|
+
const [edited, setEdited] = useState(null);
|
|
34
|
+
const [isDirty, setDirty] = useState(false);
|
|
35
|
+
const [isSaving, setSaving] = useState(false);
|
|
36
|
+
const [problem, setProblem] = useState(null);
|
|
37
|
+
const [blocked, setBlocked] = useState(null);
|
|
38
|
+
const draft = useRef(null);
|
|
39
|
+
const [replaceText, setReplaceText] = useState('');
|
|
40
|
+
// Replace stays folded under the search bar until the reader opens it.
|
|
41
|
+
const [isReplaceOpen, setReplaceOpen] = useState(false);
|
|
42
|
+
const [replace, setReplace] = useState(undefined);
|
|
43
|
+
const requestReplace = (scope) => setReplace((previous) => ({ id: (previous?.id ?? 0) + 1, text: replaceText, scope }));
|
|
44
|
+
// Each time editing ends without saving, the body draws the saved file afresh: a body such
|
|
45
|
+
// as CodeMirror keeps its own document, which would still hold the discarded changes.
|
|
46
|
+
const [discards, setDiscards] = useState(0);
|
|
47
|
+
const stop = () => {
|
|
48
|
+
setEditing(false);
|
|
49
|
+
setEdited(null);
|
|
50
|
+
setDirty(false);
|
|
51
|
+
setProblem(null);
|
|
52
|
+
draft.current = null;
|
|
53
|
+
};
|
|
54
|
+
const discard = () => {
|
|
55
|
+
stop();
|
|
56
|
+
setDiscards((count) => count + 1);
|
|
57
|
+
};
|
|
58
|
+
const guard = useUnsavedChanges({
|
|
59
|
+
isDirty: isEditing && (isDirty || isSaving),
|
|
60
|
+
onBlocked: setBlocked,
|
|
61
|
+
});
|
|
62
|
+
// Leaving the page loses the changes too.
|
|
63
|
+
useEffect(() => {
|
|
64
|
+
if (!isEditing || !(isDirty || isSaving))
|
|
65
|
+
return;
|
|
66
|
+
const prevent = (event) => {
|
|
67
|
+
event.preventDefault();
|
|
68
|
+
};
|
|
69
|
+
window.addEventListener('beforeunload', prevent);
|
|
70
|
+
return () => window.removeEventListener('beforeunload', prevent);
|
|
71
|
+
}, [isDirty, isEditing, isSaving]);
|
|
72
|
+
const save = async (overwrite = false) => {
|
|
73
|
+
const read = draft.current;
|
|
74
|
+
if (read === null) {
|
|
75
|
+
stop();
|
|
76
|
+
return;
|
|
77
|
+
}
|
|
78
|
+
setSaving(true);
|
|
79
|
+
setProblem(null);
|
|
80
|
+
try {
|
|
81
|
+
const base = edited?.entry ?? entry;
|
|
82
|
+
await store.write(base, new Blob([read()], { type: base.mediaType ?? 'text/plain' }), {
|
|
83
|
+
overwrite,
|
|
84
|
+
});
|
|
85
|
+
stop();
|
|
86
|
+
}
|
|
87
|
+
catch (error) {
|
|
88
|
+
setProblem(fileSourceErrorKind(error) === 'conflict'
|
|
89
|
+
? { kind: 'conflict' }
|
|
90
|
+
: { kind: 'error', message: fileSourceErrorMessage(error) });
|
|
91
|
+
}
|
|
92
|
+
finally {
|
|
93
|
+
setSaving(false);
|
|
94
|
+
}
|
|
95
|
+
};
|
|
96
|
+
const cancel = () => guard.request({ intent: 'explicit', proceed: discard });
|
|
97
|
+
/** Runs `action` once unsaved changes are discarded, or at once without any. */
|
|
98
|
+
const leave = (action) => guard.request({
|
|
99
|
+
intent: 'explicit',
|
|
100
|
+
proceed: () => {
|
|
101
|
+
if (isEditing)
|
|
102
|
+
discard();
|
|
103
|
+
action();
|
|
104
|
+
},
|
|
105
|
+
});
|
|
106
|
+
useShortcut({
|
|
107
|
+
id: `file.save:${entry.key}`,
|
|
108
|
+
label: 'Save',
|
|
109
|
+
category: 'File',
|
|
110
|
+
keys: ['mod', 's'],
|
|
111
|
+
allowInEditable: true,
|
|
112
|
+
isDisabled: !isEditing || isSaving,
|
|
113
|
+
onAction: () => void save(),
|
|
114
|
+
});
|
|
115
|
+
const chrome = isEditing ? (_jsx(EditChrome, { entry: entry, isDirty: isDirty, isSaving: isSaving, onCancel: cancel, onSave: () => void save(), search: search, editors: editors })) : null;
|
|
116
|
+
const hasMatches = search !== undefined && search.query.trim() !== '' && (search.matchCount ?? 0) > 0;
|
|
117
|
+
// Before the search field while editing: opens and folds Replace below it.
|
|
118
|
+
const replaceToggle = isEditing ? (_jsx(IconButton, { icon: isReplaceOpen ? 'ChevronDown' : 'ChevronRight', label: isReplaceOpen ? 'Hide replace' : 'Show replace', "aria-expanded": isReplaceOpen, variant: "plain", size: "small", onPress: () => setReplaceOpen(!isReplaceOpen) })) : null;
|
|
119
|
+
// Under the search bar in the file's column, while Replace is open.
|
|
120
|
+
const replaceRow = isEditing && search?.isSearching === true && isReplaceOpen ? (_jsxs("div", { ...stylex.props(styles.chrome, styles.headerRow), children: [_jsx("div", { ...stylex.props(styles.search), children: _jsx(TextField, { "aria-label": "Replace with", placeholder: "Replace with", size: "small", value: replaceText, onChange: setReplaceText }) }), _jsx(Button, { variant: "plain", size: "small", isDisabled: !hasMatches, onPress: () => requestReplace('match'), children: "Replace" }), _jsx(Button, { variant: "plain", size: "small", isDisabled: !hasMatches, onPress: () => requestReplace('all'), children: "Replace all" })] })) : null;
|
|
121
|
+
const notice = problem === null ? null : problem.kind === 'conflict' ? (_jsx("div", { ...stylex.props(styles.editNotice), children: _jsxs(InlineAlert, { tone: "warning", children: [_jsx(Text, { variant: "body", children: "This file changed since you opened it. Overwrite it with your version, or discard your changes and see what's there now." }), _jsxs("div", { ...stylex.props(styles.editNoticeActions), children: [_jsx(Button, { size: "small", isDisabled: isSaving, onPress: () => void save(true), children: "Overwrite" }), _jsx(Button, { size: "small", variant: "plain", isDisabled: isSaving, onPress: () => {
|
|
122
|
+
discard();
|
|
123
|
+
void store.reloadEntry(entry.key).catch(() => undefined);
|
|
124
|
+
}, children: "Discard my changes" })] })] }) })) : (_jsx("div", { ...stylex.props(styles.editNotice), children: _jsx(InlineAlert, { tone: "danger", onDismiss: () => setProblem(null), children: _jsx(Text, { variant: "body", children: problem.message ?? "Couldn't save. Your changes are still here." }) }) }));
|
|
125
|
+
const confirmation = (_jsx(Modal, { size: "small", isOpen: blocked !== null, onOpenChange: (isOpen) => {
|
|
126
|
+
if (isOpen || blocked === null)
|
|
127
|
+
return;
|
|
128
|
+
blocked.cancel();
|
|
129
|
+
setBlocked(null);
|
|
130
|
+
}, children: _jsx(Dialog, { role: "alertdialog", title: "Discard your changes?", description: `Your changes to ${entry.name} haven't been saved.`, children: _jsxs(Footer, { children: [_jsx(Button, { variant: "plain", onPress: () => {
|
|
131
|
+
blocked?.cancel();
|
|
132
|
+
setBlocked(null);
|
|
133
|
+
}, children: "Keep editing" }), _jsx(Button, { variant: "filled", tone: "danger", onPress: () => {
|
|
134
|
+
const action = blocked;
|
|
135
|
+
setBlocked(null);
|
|
136
|
+
discard();
|
|
137
|
+
action?.proceed();
|
|
138
|
+
}, children: "Discard" })] }) }) }));
|
|
139
|
+
return {
|
|
140
|
+
isEditing,
|
|
141
|
+
/**
|
|
142
|
+
* While a save is in flight the body takes no input: the saved version replaces it, so
|
|
143
|
+
* anything typed meanwhile would be lost.
|
|
144
|
+
*/
|
|
145
|
+
isSaving,
|
|
146
|
+
/** Changes when editing ends without saving; key the body on it to draw the saved file. */
|
|
147
|
+
bodyKey: discards,
|
|
148
|
+
/** Starts editing; `undefined` when the file can't be edited. */
|
|
149
|
+
onEdit: canEdit && !isEditing
|
|
150
|
+
? () => {
|
|
151
|
+
setEdited({ entry, content: store.content(entry) });
|
|
152
|
+
setEditing(true);
|
|
153
|
+
}
|
|
154
|
+
: undefined,
|
|
155
|
+
/** While editing, the file as it was when editing began, for the body to stay on. */
|
|
156
|
+
edited,
|
|
157
|
+
/** The unsaved text, or `null` when nothing has changed. */
|
|
158
|
+
readDraft: () => draft.current?.() ?? null,
|
|
159
|
+
/** Keeps `text` as the draft, such as while another editor opens on it. */
|
|
160
|
+
keepDraft: (text) => {
|
|
161
|
+
draft.current = () => text;
|
|
162
|
+
},
|
|
163
|
+
/** Asks before unsaved changes are lost, then ends editing and runs `action`. */
|
|
164
|
+
leave,
|
|
165
|
+
/** What the body receives while the renderer declares `edit`. */
|
|
166
|
+
bodyProps: {
|
|
167
|
+
isEditing,
|
|
168
|
+
onDraftChange: (read) => {
|
|
169
|
+
draft.current = read;
|
|
170
|
+
setDirty(true);
|
|
171
|
+
},
|
|
172
|
+
replace,
|
|
173
|
+
},
|
|
174
|
+
chrome,
|
|
175
|
+
replaceToggle,
|
|
176
|
+
replaceRow,
|
|
177
|
+
notice,
|
|
178
|
+
confirmation: blocked === null ? null : confirmation,
|
|
179
|
+
};
|
|
180
|
+
}
|
|
181
|
+
/**
|
|
182
|
+
* The header while editing: the file, Search, then Cancel and Save. The search bar, and Replace
|
|
183
|
+
* once it matches, are rows in the file's column below, so the file and its save stay in view.
|
|
184
|
+
*/
|
|
185
|
+
function EditChrome({ entry, isDirty, isSaving, onCancel, onSave, search, editors, }) {
|
|
186
|
+
const isSearching = search?.isSearching === true;
|
|
187
|
+
const frame = useViewerFrame();
|
|
188
|
+
return (_jsx(ViewerHeader, { children: _jsxs("div", { ...stylex.props(styles.chrome, frame?.isHeaderHosted === true && styles.chromeHosted), children: [_jsx(FrameControls, {}), _jsxs("div", { ...stylex.props(styles.identity), children: [_jsx("span", { ...stylex.props(styles.icon), children: _jsx(FileIcon, { filename: entry.name, mimeType: entry.mediaType ?? null, webUrl: entry.webUrl ?? null, size: "large" }) }), _jsxs("span", { ...stylex.props(styles.titleText), children: [_jsx(Text, { variant: "subheadline", truncation: "ellipsis", children: entry.name }), isSaving || isDirty ? (_jsx(Text, { variant: "footnote", tone: "secondary", children: isSaving ? 'Saving…' : 'Edited' })) : null] })] }), _jsxs("div", { ...stylex.props(styles.editActions), children: [editors === undefined || editors.others.length === 0 ? null : (_jsx(SwitchEditor, { editors: editors, isDisabled: isSaving })), search === undefined ? null : (
|
|
189
|
+
// A toggle, as in the reading header: selected while the search bar shows below.
|
|
190
|
+
_jsx(LabeledToggle, { icon: "Search", label: "Search in file", isSelected: isSearching, onChange: (open) => (open ? search.onOpen() : search.onDone()) })), _jsx(Button, { variant: "plain", size: "small", isDisabled: isSaving, onPress: onCancel, children: "Cancel" }), _jsx(Button, { variant: "filled", tone: "accent", size: "small",
|
|
191
|
+
// Disabled, not pending: the header says "Saving…", and a pending button's
|
|
192
|
+
// announcement would outlive the button, which goes once the save is done.
|
|
193
|
+
isDisabled: !isDirty || isSaving, onPress: onSave, children: "Save" })] })] }) }));
|
|
194
|
+
}
|
|
195
|
+
/**
|
|
196
|
+
* Edit in another of the file's editors, such as Code for a Markdown file's source: one button
|
|
197
|
+
* for one other editor, a menu for more. The edit goes with it, unsaved changes included.
|
|
198
|
+
*/
|
|
199
|
+
function SwitchEditor({ editors, isDisabled, }) {
|
|
200
|
+
const [only] = editors.others;
|
|
201
|
+
if (editors.others.length === 1 && only !== undefined) {
|
|
202
|
+
return (_jsx(IconButton, { icon: "ArrowLeftRight", label: `Edit in ${only.label}`, variant: "plain", size: "small", isDisabled: isDisabled, onPress: () => editors.onSwitch(only) }));
|
|
203
|
+
}
|
|
204
|
+
return (_jsxs(Menu.Trigger, { placement: "bottom end", children: [_jsx(IconButton, { icon: "ArrowLeftRight", label: "Switch editor", variant: "plain", size: "small", isDisabled: isDisabled }), _jsx(Menu, { onAction: (id) => {
|
|
205
|
+
const renderer = editors.others.find((candidate) => candidate.id === id);
|
|
206
|
+
if (renderer !== undefined)
|
|
207
|
+
editors.onSwitch(renderer);
|
|
208
|
+
}, children: editors.others.map((renderer) => (_jsxs(MenuItem, { id: renderer.id, children: ["Edit in ", renderer.label] }, renderer.id))) })] }));
|
|
209
|
+
}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { type FocusEvent, type PointerEvent, type RefObject } from 'react';
|
|
2
|
+
import type { FileEntry } from '../FileScope/FileScope.types.ts';
|
|
3
|
+
import { type SearchControlsProps } from './FileViewer.chrome.tsx';
|
|
4
|
+
import { type ChromeControls } from './FileViewer.controls.tsx';
|
|
5
|
+
/**
|
|
6
|
+
* The embed's chrome, floating over the top of the body: the file's name, always shown, and a
|
|
7
|
+
* toolbar shown on hover, focus and touch. Nothing reflows when it appears. Narrow, as on a phone,
|
|
8
|
+
* the toolbar is one More actions button holding every action, so it keeps clear of the file.
|
|
9
|
+
*/
|
|
10
|
+
export declare function EmbeddedChrome({ entry, controls, isNarrow, shouldFocusSearch, onOpenView, onFullScreen, }: {
|
|
11
|
+
readonly entry: FileEntry;
|
|
12
|
+
readonly controls: ChromeControls;
|
|
13
|
+
/** Under 600 pixels wide, measured on the embed itself. */
|
|
14
|
+
readonly isNarrow: boolean;
|
|
15
|
+
/** Focus Search when the toolbar returns after search closes. */
|
|
16
|
+
readonly shouldFocusSearch: boolean;
|
|
17
|
+
/** Opens the View sheet, from the narrow menu's View. */
|
|
18
|
+
readonly onOpenView: () => void;
|
|
19
|
+
readonly onFullScreen: () => void;
|
|
20
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
21
|
+
/**
|
|
22
|
+
* The room the embed's file keeps at its top for the row floating over it: the toolbar's height,
|
|
23
|
+
* a small control in a half-padded surface, and the row's inset above it.
|
|
24
|
+
*/
|
|
25
|
+
export declare const EMBED_TOP_INSET = "44px";
|
|
26
|
+
/** Search in the embed: a compact bar over the top of the body. */
|
|
27
|
+
export declare function EmbeddedSearch(props: SearchControlsProps): import("react/jsx-runtime").JSX.Element;
|
|
28
|
+
/**
|
|
29
|
+
* Whether the embed takes wheel and touch scrolling. Until the user clicks, taps or tabs in,
|
|
30
|
+
* scrolling passes through to the page around it, as with an embedded map. It lets go when focus
|
|
31
|
+
* leaves, when a mouse leaves, or on a tap outside.
|
|
32
|
+
*/
|
|
33
|
+
export declare function useScrollEngagement(rootRef: RefObject<HTMLElement | null>): {
|
|
34
|
+
isEngaged: boolean;
|
|
35
|
+
engage: () => void;
|
|
36
|
+
rootProps: {
|
|
37
|
+
onFocus: () => void;
|
|
38
|
+
onBlur: (event: FocusEvent<HTMLDivElement>) => void;
|
|
39
|
+
onPointerLeave: (event: PointerEvent<HTMLDivElement>) => void;
|
|
40
|
+
};
|
|
41
|
+
};
|
|
42
|
+
/**
|
|
43
|
+
* Covers the body until the embed is engaged, so wheel and touch scrolling reach the page. A
|
|
44
|
+
* click or tap engages it. Keyboard users engage by tabbing into the body, so it is hidden from
|
|
45
|
+
* assistive technology.
|
|
46
|
+
*/
|
|
47
|
+
export declare function ScrollShield({ onEngage }: {
|
|
48
|
+
readonly onEngage: () => void;
|
|
49
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
2
|
+
import * as stylex from '@stylexjs/stylex';
|
|
3
|
+
import { useEffect, useState } from 'react';
|
|
4
|
+
import { FileIcon } from "../FileIcon/FileIcon.js";
|
|
5
|
+
import { Icon } from "../Icon/Icon.js";
|
|
6
|
+
import { IconButton } from "../IconButton/IconButton.js";
|
|
7
|
+
import { Menu, MenuItem } from "../Menu/Menu.js";
|
|
8
|
+
import { Separator } from "../Separator/Separator.js";
|
|
9
|
+
import { Reveal } from "../Reveal/Reveal.js";
|
|
10
|
+
import { Surface } from "../Surface/Surface.js";
|
|
11
|
+
import { Text } from "../Text/Text.js";
|
|
12
|
+
import { Toolbar, ToolbarItem } from "../Toolbar/Toolbar.js";
|
|
13
|
+
import { Button } from "../Button/Button.js";
|
|
14
|
+
import { useFileScope } from "../FileScope/FileScope.js";
|
|
15
|
+
import { SearchControls } from "./FileViewer.chrome.js";
|
|
16
|
+
import { presentControl } from "./FileViewer.controls.js";
|
|
17
|
+
import { describeZoom, hasViewControl, viewControl } from "./FileViewer.view.js";
|
|
18
|
+
import { styles } from "./FileViewer.stylex.js";
|
|
19
|
+
/**
|
|
20
|
+
* The embed's chrome, floating over the top of the body: the file's name, always shown, and a
|
|
21
|
+
* toolbar shown on hover, focus and touch. Nothing reflows when it appears. Narrow, as on a phone,
|
|
22
|
+
* the toolbar is one More actions button holding every action, so it keeps clear of the file.
|
|
23
|
+
*/
|
|
24
|
+
export function EmbeddedChrome({ entry, controls, isNarrow, shouldFocusSearch, onOpenView, onFullScreen, }) {
|
|
25
|
+
const { viewerActions } = useFileScope();
|
|
26
|
+
return (_jsxs("div", { ...stylex.props(styles.embedTop), children: [_jsxs("span", { ...stylex.props(styles.nameChip), children: [_jsx(FileIcon, { filename: entry.name, mimeType: entry.mediaType ?? null, webUrl: entry.webUrl ?? null, size: "small" }), _jsx(Text, { variant: "caption", truncation: "ellipsis", children: entry.name })] }), _jsx(Reveal, { children: _jsx("div", { ...stylex.props(styles.embedToolbar), children: _jsx(Surface, { variant: "elevated", elevation: "medium", shape: "rounded", padding: "half", children: isNarrow ? (_jsx(NarrowMenu, { controls: controls, viewerActions: viewerActions, onOpenView: onOpenView, onFullScreen: onFullScreen })) : (_jsx(Toolbar, { "aria-label": "File", size: "small", children: wideActions(controls, viewerActions, shouldFocusSearch, onFullScreen) })) }) }) })] }));
|
|
27
|
+
}
|
|
28
|
+
function wideActions(controls, viewerActions, shouldFocusSearch, onFullScreen) {
|
|
29
|
+
const capabilities = controls.renderer?.capabilities ?? {};
|
|
30
|
+
return (_jsxs(_Fragment, { children: [capabilities.search === true ? (_jsx(IconButton, { icon: "Search", label: "Search in file", variant: "plain", autoFocus: shouldFocusSearch, onPress: controls.onSearch })) : null, hasViewControl(controls) ? (_jsx(ToolbarItem, { priority: "primary", children: viewControl(controls) })) : null, presentControl(controls), controls.onGoTo === undefined ? null : (
|
|
31
|
+
// Download already has a down arrow, so Go to takes a number sign.
|
|
32
|
+
_jsx(IconButton, { icon: "Hash", label: controls.goToUnit === 'page' ? 'Go to page…' : 'Go to line…', variant: "plain", onPress: controls.onGoTo })), controls.onDownload === undefined ? null : (_jsx(IconButton, { icon: "Download", label: "Download", variant: "plain", onPress: controls.onDownload })), controls.onCopyLink === undefined ? null : (_jsx(IconButton, { icon: "Link", label: "Copy link", variant: "plain", onPress: controls.onCopyLink })), viewerActions.map((action, index) => action.isPrimary === true ? (_jsx(IconButton, { icon: action.icon, label: action.label, variant: "plain", onPress: () => action.onAction(controls.file) }, `primary-${index}`)) : (_jsx(ToolbarItem, { priority: "overflow", children: _jsx(Button, { leadingIcon: action.icon, onPress: () => action.onAction(controls.file), children: action.label }) }, `overflow-${index}`))), _jsx(ToolbarItem, { priority: "primary", children: _jsx(IconButton, { icon: "Maximize2", label: "Full screen", variant: "plain", onPress: onFullScreen }) })] }));
|
|
33
|
+
}
|
|
34
|
+
/**
|
|
35
|
+
* The same actions in one More actions menu: finding first, then View, which opens the View
|
|
36
|
+
* sheet a narrow viewer uses, then the file's actions and Full screen.
|
|
37
|
+
*/
|
|
38
|
+
function NarrowMenu({ controls, viewerActions, onOpenView, onFullScreen, }) {
|
|
39
|
+
const capabilities = controls.renderer?.capabilities ?? {};
|
|
40
|
+
const item = (icon, label, onAction) => (_jsxs(MenuItem, { onAction: onAction, children: [_jsx(Icon, { name: icon, size: "small", tone: "inherit" }), label] }, label));
|
|
41
|
+
const finding = [
|
|
42
|
+
capabilities.search === true ? item('Search', 'Search in file', controls.onSearch) : null,
|
|
43
|
+
controls.onGoTo === undefined
|
|
44
|
+
? null
|
|
45
|
+
: item('Hash', controls.goToUnit === 'page' ? 'Go to page…' : 'Go to line…', controls.onGoTo),
|
|
46
|
+
].filter((node) => node !== null);
|
|
47
|
+
const file = [
|
|
48
|
+
capabilities.present === true ? item('Presentation', 'Present', controls.onPresent) : null,
|
|
49
|
+
controls.onDownload === undefined ? null : item('Download', 'Download', controls.onDownload),
|
|
50
|
+
controls.onCopyLink === undefined ? null : item('Link', 'Copy link', controls.onCopyLink),
|
|
51
|
+
...viewerActions.map((action) => item(action.icon, action.label, () => action.onAction(controls.file))),
|
|
52
|
+
item('Maximize2', 'Full screen', onFullScreen),
|
|
53
|
+
].filter((node) => node !== null);
|
|
54
|
+
return (_jsxs(Menu.Trigger, { children: [_jsx(IconButton, { icon: "Ellipsis", label: "More actions", variant: "plain", size: "small" }), _jsxs(Menu, { children: [finding, finding.length === 0 ? null : _jsx(Separator, {}), capabilities.zoom === true ? (_jsxs(_Fragment, { children: [_jsxs(MenuItem, { opens: "dialog", textValue: "View", detail: describeZoom(controls.zoom), onAction: onOpenView, children: [_jsx(Icon, { name: "ZoomIn", size: "small", tone: "inherit" }), "View"] }), _jsx(Separator, {})] })) : null, file] })] }));
|
|
55
|
+
}
|
|
56
|
+
/**
|
|
57
|
+
* The room the embed's file keeps at its top for the row floating over it: the toolbar's height,
|
|
58
|
+
* a small control in a half-padded surface, and the row's inset above it.
|
|
59
|
+
*/
|
|
60
|
+
export const EMBED_TOP_INSET = '44px';
|
|
61
|
+
/** Search in the embed: a compact bar over the top of the body. */
|
|
62
|
+
export function EmbeddedSearch(props) {
|
|
63
|
+
return (_jsx("div", { ...stylex.props(styles.embedTop), children: _jsx("div", { ...stylex.props(styles.embedSearch), children: _jsx(Surface, { variant: "elevated", elevation: "medium", shape: "rounded", padding: "half", children: _jsx("div", { ...stylex.props(styles.embedSearchRow), children: _jsx(SearchControls, { ...props }) }) }) }) }));
|
|
64
|
+
}
|
|
65
|
+
/**
|
|
66
|
+
* Whether the embed takes wheel and touch scrolling. Until the user clicks, taps or tabs in,
|
|
67
|
+
* scrolling passes through to the page around it, as with an embedded map. It lets go when focus
|
|
68
|
+
* leaves, when a mouse leaves, or on a tap outside.
|
|
69
|
+
*/
|
|
70
|
+
export function useScrollEngagement(rootRef) {
|
|
71
|
+
const [isEngaged, setEngaged] = useState(false);
|
|
72
|
+
useEffect(() => {
|
|
73
|
+
if (!isEngaged)
|
|
74
|
+
return;
|
|
75
|
+
const release = (event) => {
|
|
76
|
+
if (!(event.target instanceof Node) || !rootRef.current?.contains(event.target)) {
|
|
77
|
+
setEngaged(false);
|
|
78
|
+
}
|
|
79
|
+
};
|
|
80
|
+
document.addEventListener('pointerdown', release, true);
|
|
81
|
+
return () => document.removeEventListener('pointerdown', release, true);
|
|
82
|
+
}, [isEngaged, rootRef]);
|
|
83
|
+
return {
|
|
84
|
+
isEngaged,
|
|
85
|
+
engage: () => setEngaged(true),
|
|
86
|
+
rootProps: {
|
|
87
|
+
onFocus: () => setEngaged(true),
|
|
88
|
+
onBlur: (event) => {
|
|
89
|
+
if (!event.currentTarget.contains(event.relatedTarget))
|
|
90
|
+
setEngaged(false);
|
|
91
|
+
},
|
|
92
|
+
onPointerLeave: (event) => {
|
|
93
|
+
// A touch ends with a leave, so only a mouse or pen moving away lets go.
|
|
94
|
+
if (event.pointerType !== 'touch')
|
|
95
|
+
setEngaged(false);
|
|
96
|
+
},
|
|
97
|
+
},
|
|
98
|
+
};
|
|
99
|
+
}
|
|
100
|
+
/**
|
|
101
|
+
* Covers the body until the embed is engaged, so wheel and touch scrolling reach the page. A
|
|
102
|
+
* click or tap engages it. Keyboard users engage by tabbing into the body, so it is hidden from
|
|
103
|
+
* assistive technology.
|
|
104
|
+
*/
|
|
105
|
+
export function ScrollShield({ onEngage }) {
|
|
106
|
+
return (_jsx("div", { "aria-hidden": true, ...stylex.props(styles.shield), onPointerDown: onEngage, children: _jsx(Reveal, { children: _jsxs("span", { ...stylex.props(styles.shieldHint), children: [_jsx("span", { ...stylex.props(styles.hintFine), children: _jsx(Text, { variant: "caption", children: "Click to scroll" }) }), _jsx("span", { ...stylex.props(styles.hintCoarse), children: _jsx(Text, { variant: "caption", children: "Tap to scroll" }) })] }) }) }));
|
|
107
|
+
}
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import { type ReactNode, type RefObject } from 'react';
|
|
2
|
+
import type { FileStructure } from '../FileContent/FileStructure.ts';
|
|
3
|
+
import type { FileLocation, FilePagesKind } from '../FileScope/FileScope.types.ts';
|
|
4
|
+
/**
|
|
5
|
+
* What `FileCollectionViewer` adds to the viewer it shows: its list as the sidebar's Files
|
|
6
|
+
* section, and the ways between files. Private to the package.
|
|
7
|
+
*/
|
|
8
|
+
export type ViewerCollection = {
|
|
9
|
+
/** The collection measures itself; the viewer fills it, so it is compact when it is. */
|
|
10
|
+
readonly isCompact: boolean;
|
|
11
|
+
/** The Files section's content. */
|
|
12
|
+
readonly files: ReactNode;
|
|
13
|
+
/** How many files the list holds, beside the section's name; `undefined` while it loads. */
|
|
14
|
+
readonly fileCount: number | undefined;
|
|
15
|
+
/** The file after the open one, for the Next file card on a narrow viewer. */
|
|
16
|
+
readonly next: {
|
|
17
|
+
readonly name: string;
|
|
18
|
+
readonly mediaType: string | undefined;
|
|
19
|
+
readonly open: () => void;
|
|
20
|
+
} | undefined;
|
|
21
|
+
/** On a narrow viewer, shows the list in the file's place. */
|
|
22
|
+
readonly onShowFiles: () => void;
|
|
23
|
+
/** Back and Forward through the files opened; `undefined` when the app steps through them. */
|
|
24
|
+
readonly history: {
|
|
25
|
+
readonly canGoBack: boolean;
|
|
26
|
+
readonly canGoForward: boolean;
|
|
27
|
+
readonly back: () => void;
|
|
28
|
+
readonly forward: () => void;
|
|
29
|
+
} | undefined;
|
|
30
|
+
/**
|
|
31
|
+
* Where a text match opened the open file: the viewer goes there and makes the match there the
|
|
32
|
+
* active one. A new `id` is another opening, of the same place too.
|
|
33
|
+
*/
|
|
34
|
+
readonly jump: {
|
|
35
|
+
readonly location: FileLocation;
|
|
36
|
+
readonly id: number;
|
|
37
|
+
} | undefined;
|
|
38
|
+
};
|
|
39
|
+
export declare const ViewerCollectionContext: import("react").Context<ViewerCollection | null>;
|
|
40
|
+
/** The frame both viewers share: the header across the top, the sidebar, and the open file. */
|
|
41
|
+
export type ViewerFrame = {
|
|
42
|
+
readonly isCompact: boolean;
|
|
43
|
+
/** Whether the viewer has a sidebar to show: wide, standard, with a section to put in it. */
|
|
44
|
+
readonly hasSidebar: boolean;
|
|
45
|
+
readonly isSidebarOpen: boolean;
|
|
46
|
+
/**
|
|
47
|
+
* The sidebar would be empty: a viewer without a collection whose open file has no pages. It
|
|
48
|
+
* stays collapsed, without its button, and the reader's choice holds for the next paged file.
|
|
49
|
+
*/
|
|
50
|
+
readonly isSidebarEmpty: boolean;
|
|
51
|
+
readonly onSidebarOpenChange: (isOpen: boolean) => void;
|
|
52
|
+
/**
|
|
53
|
+
* The open file's renderer's `pages`, or else the first in scope that declares them; set
|
|
54
|
+
* whenever any does, so Pages stays as files change.
|
|
55
|
+
*/
|
|
56
|
+
readonly pagesKind: FilePagesKind | undefined;
|
|
57
|
+
/**
|
|
58
|
+
* Whether the open file is drawn as pages: `undefined` while none has opened, such as while one
|
|
59
|
+
* loads, so Pages says a file has none only once it knows.
|
|
60
|
+
*/
|
|
61
|
+
readonly isOpenFilePaged: boolean | undefined;
|
|
62
|
+
readonly onOpenedPagesKindChange: (kind: FilePagesKind | null | undefined) => void;
|
|
63
|
+
/** The open file's structure, as its body reports it. */
|
|
64
|
+
readonly structure: FileStructure | undefined;
|
|
65
|
+
readonly reportStructure: (structure: FileStructure | undefined) => void;
|
|
66
|
+
/** Takes the open file to a place, such as a page picked in Pages. */
|
|
67
|
+
readonly navigate: RefObject<(location: FileLocation) => void>;
|
|
68
|
+
/** The device cache keys' start for the open file's page previews. */
|
|
69
|
+
readonly previewCacheKey: string | undefined;
|
|
70
|
+
readonly onPreviewCacheKeyChange: (key: string | undefined) => void;
|
|
71
|
+
/** Where the open file's header goes, across the sidebar too; `null` until it mounts. */
|
|
72
|
+
readonly headerSlot: HTMLElement | null;
|
|
73
|
+
/** The header draws in `FileViewer`'s `headerTarget`, the app's, without an edge of its own. */
|
|
74
|
+
readonly isHeaderHosted: boolean;
|
|
75
|
+
readonly collection: ViewerCollection | null;
|
|
76
|
+
};
|
|
77
|
+
export declare const ViewerFrameContext: import("react").Context<ViewerFrame | null>;
|
|
78
|
+
export declare function useViewerFrame(): ViewerFrame | null;
|
|
79
|
+
/**
|
|
80
|
+
* The header of whatever the viewer shows, drawn across the top of the frame so it spans the
|
|
81
|
+
* sidebar. Its events still reach the viewer around it, as React portals pass them up.
|
|
82
|
+
*/
|
|
83
|
+
export declare function ViewerHeader({ children }: {
|
|
84
|
+
readonly children: ReactNode;
|
|
85
|
+
}): ReactNode;
|
|
86
|
+
/** A page's unit, as the sidebar, the pill and Contents name it. */
|
|
87
|
+
export declare function pageUnit(kind: FilePagesKind | undefined): {
|
|
88
|
+
one: string;
|
|
89
|
+
label: string;
|
|
90
|
+
};
|
|
91
|
+
/** The page a location is on, for a page location or a passage within one. */
|
|
92
|
+
export declare function pageOfLocation(location: FileLocation): number | undefined;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { createContext, useContext } from 'react';
|
|
3
|
+
import { createPortal } from 'react-dom';
|
|
4
|
+
import { ShortcutScopeExtension } from "../Shortcuts/Shortcuts.js";
|
|
5
|
+
export const ViewerCollectionContext = createContext(null);
|
|
6
|
+
export const ViewerFrameContext = createContext(null);
|
|
7
|
+
export function useViewerFrame() {
|
|
8
|
+
return useContext(ViewerFrameContext);
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* The header of whatever the viewer shows, drawn across the top of the frame so it spans the
|
|
12
|
+
* sidebar. Its events still reach the viewer around it, as React portals pass them up.
|
|
13
|
+
*/
|
|
14
|
+
export function ViewerHeader({ children }) {
|
|
15
|
+
const frame = useViewerFrame();
|
|
16
|
+
const slot = frame?.headerSlot ?? null;
|
|
17
|
+
if (frame?.isHeaderHosted !== true)
|
|
18
|
+
return slot === null ? children : createPortal(children, slot);
|
|
19
|
+
// In the app's element, outside the viewer's own: it waits for the element, and the viewer's
|
|
20
|
+
// shortcuts still answer while focus is in it.
|
|
21
|
+
return slot === null
|
|
22
|
+
? null
|
|
23
|
+
: createPortal(_jsx(ShortcutScopeExtension, { children: children }), slot);
|
|
24
|
+
}
|
|
25
|
+
/** A page's unit, as the sidebar, the pill and Contents name it. */
|
|
26
|
+
export function pageUnit(kind) {
|
|
27
|
+
return kind === 'slides' ? { one: 'Slide', label: 'Slides' } : { one: 'Page', label: 'Pages' };
|
|
28
|
+
}
|
|
29
|
+
/** The page a location is on, for a page location or a passage within one. */
|
|
30
|
+
export function pageOfLocation(location) {
|
|
31
|
+
if (location.kind === 'page')
|
|
32
|
+
return location.page;
|
|
33
|
+
if (location.kind === 'text' && location.within?.kind === 'page')
|
|
34
|
+
return location.within.page;
|
|
35
|
+
return undefined;
|
|
36
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/** The unit a file is navigated by: pages for documents, lines for text and code. */
|
|
2
|
+
export type GoToUnit = 'page' | 'line';
|
|
3
|
+
/** Go to page or Go to line, from the More menu. */
|
|
4
|
+
export declare function GoToDialog({ unit, count, current, onGo, }: {
|
|
5
|
+
readonly unit: GoToUnit;
|
|
6
|
+
readonly count: number;
|
|
7
|
+
/** Where the reader is now, shown as a hint. */
|
|
8
|
+
readonly current: number | undefined;
|
|
9
|
+
readonly onGo: (position: number) => void;
|
|
10
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export declare namespace GoToDialog {
|
|
12
|
+
var displayName: string;
|
|
13
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
+
import { useRef } from 'react';
|
|
3
|
+
import { Button } from "../Button/Button.js";
|
|
4
|
+
import { Content, Footer } from "../Content/Content.js";
|
|
5
|
+
import { Dialog } from "../Dialog/Dialog.js";
|
|
6
|
+
import { DismissButton } from "../DismissButton/DismissButton.js";
|
|
7
|
+
import { useDismiss } from "../DismissButton/Dismiss.context.js";
|
|
8
|
+
import { NumberField } from "../NumberField/NumberField.js";
|
|
9
|
+
/** Go to page or Go to line, from the More menu. */
|
|
10
|
+
export function GoToDialog({ unit, count, current, onGo, }) {
|
|
11
|
+
const dismiss = useDismiss();
|
|
12
|
+
const formRef = useRef(null);
|
|
13
|
+
const go = (value) => {
|
|
14
|
+
if (!Number.isFinite(value))
|
|
15
|
+
return;
|
|
16
|
+
onGo(Math.min(count, Math.max(1, Math.round(value))));
|
|
17
|
+
dismiss();
|
|
18
|
+
};
|
|
19
|
+
const label = unit === 'page' ? 'Page' : 'Line';
|
|
20
|
+
return (_jsxs(Dialog, { title: `Go to ${unit}`, children: [_jsx(Content, { children: _jsx("form", { ref: formRef, onSubmit: (event) => {
|
|
21
|
+
event.preventDefault();
|
|
22
|
+
// The field reports its value only when it commits, so read what is typed.
|
|
23
|
+
const typed = event.currentTarget.querySelector('input:not([type="hidden"])')?.value;
|
|
24
|
+
// Digits only: a committed value may be formatted, as in "1,200".
|
|
25
|
+
const digits = typed?.replace(/\D/g, '') ?? '';
|
|
26
|
+
if (digits !== '')
|
|
27
|
+
go(Number(digits));
|
|
28
|
+
}, children: _jsx(NumberField, { autoFocus: true, label: label, description: current === undefined ? `1 to ${count}` : `Now on ${unit} ${current} of ${count}`, minValue: 1, maxValue: count }) }) }), _jsxs(Footer, { children: [_jsx(DismissButton, { label: "Cancel" }), _jsx(Button, { variant: "filled", tone: "accent", onPress: () => formRef.current?.requestSubmit(), children: "Go" })] })] }));
|
|
29
|
+
}
|
|
30
|
+
GoToDialog.displayName = 'GoToDialog';
|