@multiplatform.one/components 8.2.2 → 8.4.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/README.md +18 -3
- package/dist/cjs/Chip/index.cjs +1 -1
- package/dist/cjs/Chip/index.native.js +1 -1
- package/dist/cjs/Chip/index.native.js.map +1 -1
- package/dist/cjs/DrillStack/DrillBar.cjs +124 -0
- package/dist/cjs/DrillStack/DrillBar.native.js +133 -0
- package/dist/cjs/DrillStack/DrillBar.native.js.map +1 -0
- package/dist/cjs/DrillStack/context.cjs +66 -0
- package/dist/cjs/DrillStack/context.native.js +73 -0
- package/dist/cjs/DrillStack/context.native.js.map +1 -0
- package/dist/cjs/DrillStack/drillMotion.cjs +68 -0
- package/dist/cjs/DrillStack/drillMotion.native.js +72 -0
- package/dist/cjs/DrillStack/drillMotion.native.js.map +1 -0
- package/dist/cjs/DrillStack/drillSlide.cjs +171 -0
- package/dist/cjs/DrillStack/drillSlide.native.js +36 -0
- package/dist/cjs/DrillStack/drillSlide.native.js.map +1 -0
- package/dist/cjs/DrillStack/index.cjs +158 -0
- package/dist/cjs/DrillStack/index.native.js +294 -0
- package/dist/cjs/DrillStack/index.native.js.map +1 -0
- package/dist/cjs/DropdownMenu/index.cjs +288 -41
- package/dist/cjs/DropdownMenu/index.native.js +334 -44
- package/dist/cjs/DropdownMenu/index.native.js.map +1 -1
- package/dist/cjs/Material/blur.native.js +5 -1
- package/dist/cjs/Material/blur.native.js.map +1 -1
- package/dist/cjs/MiddleEllipsisText/index.cjs +79 -0
- package/dist/cjs/MiddleEllipsisText/index.native.js +46 -0
- package/dist/cjs/MiddleEllipsisText/index.native.js.map +1 -0
- package/dist/cjs/MiddleEllipsisText/middleSplit.cjs +43 -0
- package/dist/cjs/MiddleEllipsisText/middleSplit.native.js +48 -0
- package/dist/cjs/MiddleEllipsisText/middleSplit.native.js.map +1 -0
- package/dist/cjs/MiddleEllipsisText/types.cjs +18 -0
- package/dist/cjs/MiddleEllipsisText/types.native.js +21 -0
- package/dist/cjs/MiddleEllipsisText/types.native.js.map +1 -0
- package/dist/cjs/ScrollView/useRevealFocusedField.native.js +3 -2
- package/dist/cjs/ScrollView/useRevealFocusedField.native.js.map +1 -1
- package/dist/cjs/SheetModal/index.cjs +10 -1
- package/dist/cjs/SheetModal/index.native.js +14 -5
- package/dist/cjs/SheetModal/index.native.js.map +1 -1
- package/dist/cjs/SheetScrollView/index.cjs +306 -0
- package/dist/cjs/SheetScrollView/index.native.js +361 -0
- package/dist/cjs/SheetScrollView/index.native.js.map +1 -0
- package/dist/cjs/SheetScrollView/sheetDrag.cjs +30 -0
- package/dist/cjs/SheetScrollView/sheetDrag.native.js +40 -0
- package/dist/cjs/SheetScrollView/sheetDrag.native.js.map +1 -0
- package/dist/cjs/SheetScrollView/sheetHandoff.cjs +225 -0
- package/dist/cjs/SheetScrollView/sheetHandoff.native.js +242 -0
- package/dist/cjs/SheetScrollView/sheetHandoff.native.js.map +1 -0
- package/dist/cjs/Tabs/index.cjs +27 -47
- package/dist/cjs/Tabs/index.native.js +28 -48
- package/dist/cjs/Tabs/index.native.js.map +1 -1
- package/dist/cjs/Tooltip/index.native.js +9 -1
- package/dist/cjs/Tooltip/index.native.js.map +1 -1
- package/dist/cjs/appShell/AppShell.cjs +91 -107
- package/dist/cjs/appShell/AppShell.native.js +100 -114
- package/dist/cjs/appShell/AppShell.native.js.map +1 -1
- package/dist/cjs/appShell/Springboard.cjs +2 -2
- package/dist/cjs/appShell/Springboard.native.js +2 -2
- package/dist/cjs/appShell/Springboard.native.js.map +1 -1
- package/dist/cjs/appShell/SystemBar.cjs +147 -55
- package/dist/cjs/appShell/SystemBar.native.js +152 -59
- package/dist/cjs/appShell/SystemBar.native.js.map +1 -1
- package/dist/cjs/appShell/TabHost.native.js +5 -2
- package/dist/cjs/appShell/TabHost.native.js.map +1 -1
- package/dist/cjs/appShell/stackBack.cjs +49 -0
- package/dist/cjs/appShell/stackBack.native.js +55 -0
- package/dist/cjs/appShell/stackBack.native.js.map +1 -0
- package/dist/cjs/appShell/systemBarFit.cjs +12 -2
- package/dist/cjs/appShell/systemBarFit.native.js +16 -2
- package/dist/cjs/appShell/systemBarFit.native.js.map +1 -1
- package/dist/cjs/code/CodeBlock/index.cjs +21 -12
- package/dist/cjs/code/CodeBlock/index.native.js +21 -12
- package/dist/cjs/code/CodeBlock/index.native.js.map +1 -1
- package/dist/cjs/code/HoldSelect/index.cjs +69 -0
- package/dist/cjs/code/HoldSelect/index.native.js +132 -0
- package/dist/cjs/code/HoldSelect/index.native.js.map +1 -0
- package/dist/cjs/code/HoldSelect/tapGate.cjs +88 -0
- package/dist/cjs/code/HoldSelect/tapGate.native.js +95 -0
- package/dist/cjs/code/HoldSelect/tapGate.native.js.map +1 -0
- package/dist/cjs/code/LogView.cjs +14 -3
- package/dist/cjs/code/LogView.native.js +15 -3
- package/dist/cjs/code/LogView.native.js.map +1 -1
- package/dist/cjs/code/PayloadView/index.cjs +404 -0
- package/dist/cjs/code/PayloadView/index.native.js +443 -0
- package/dist/cjs/code/PayloadView/index.native.js.map +1 -0
- package/dist/cjs/code/PayloadView/payloadModel.cjs +281 -0
- package/dist/cjs/code/PayloadView/payloadModel.native.js +348 -0
- package/dist/cjs/code/PayloadView/payloadModel.native.js.map +1 -0
- package/dist/cjs/code/index.cjs +3 -1
- package/dist/cjs/code/index.native.js +2 -0
- package/dist/cjs/code/index.native.js.map +1 -1
- package/dist/cjs/componentColors.cjs +5 -4
- package/dist/cjs/componentColors.native.js +5 -4
- package/dist/cjs/componentColors.native.js.map +1 -1
- package/dist/cjs/images/RemoteArt/index.cjs +50 -0
- package/dist/cjs/images/RemoteArt/index.native.js +73 -0
- package/dist/cjs/images/RemoteArt/index.native.js.map +1 -0
- package/dist/cjs/images/RemoteArt/remoteArtCache.cjs +179 -0
- package/dist/cjs/images/RemoteArt/remoteArtCache.native.js +222 -0
- package/dist/cjs/images/RemoteArt/remoteArtCache.native.js.map +1 -0
- package/dist/cjs/images/RemoteArt/svgMarkup.cjs +119 -0
- package/dist/cjs/images/RemoteArt/svgMarkup.native.js +225 -0
- package/dist/cjs/images/RemoteArt/svgMarkup.native.js.map +1 -0
- package/dist/cjs/images/RemoteArt/types.cjs +18 -0
- package/dist/cjs/images/RemoteArt/types.native.js +21 -0
- package/dist/cjs/images/RemoteArt/types.native.js.map +1 -0
- package/dist/cjs/images/index.cjs +13 -1
- package/dist/cjs/images/index.native.js +12 -0
- package/dist/cjs/images/index.native.js.map +1 -1
- package/dist/cjs/index.cjs +8 -0
- package/dist/cjs/index.native.js +8 -0
- package/dist/cjs/index.native.js.map +1 -1
- package/dist/cjs/layouts/AsyncBoundary.cjs +21 -1
- package/dist/cjs/layouts/AsyncBoundary.native.js +21 -1
- package/dist/cjs/layouts/AsyncBoundary.native.js.map +1 -1
- package/dist/cjs/layouts/asyncFailure.cjs +15 -15
- package/dist/cjs/layouts/asyncFailure.native.js +15 -15
- package/dist/cjs/layouts/asyncFailure.native.js.map +1 -1
- package/dist/cjs/layouts/attachments.cjs +47 -8
- package/dist/cjs/layouts/attachments.native.js +49 -8
- package/dist/cjs/layouts/attachments.native.js.map +1 -1
- package/dist/cjs/layouts/page.cjs +89 -13
- package/dist/cjs/layouts/page.native.js +93 -14
- package/dist/cjs/layouts/page.native.js.map +1 -1
- package/dist/cjs/layouts/screenScroll.cjs +8 -4
- package/dist/cjs/layouts/screenScroll.native.js +12 -4
- package/dist/cjs/layouts/screenScroll.native.js.map +1 -1
- package/dist/cjs/layouts/tags.cjs +2 -1
- package/dist/cjs/layouts/tags.native.js +2 -1
- package/dist/cjs/layouts/tags.native.js.map +1 -1
- package/dist/cjs/views/Dashboard.cjs +18 -5
- package/dist/cjs/views/Dashboard.native.js +18 -5
- package/dist/cjs/views/Dashboard.native.js.map +1 -1
- package/dist/cjs/views/FilePreview.cjs +624 -0
- package/dist/cjs/views/FilePreview.native.js +675 -0
- package/dist/cjs/views/FilePreview.native.js.map +1 -0
- package/dist/cjs/views/List.cjs +1 -0
- package/dist/cjs/views/List.native.js +1 -0
- package/dist/cjs/views/List.native.js.map +1 -1
- package/dist/cjs/views/ListGroup.cjs +277 -20
- package/dist/cjs/views/ListGroup.native.js +290 -23
- package/dist/cjs/views/ListGroup.native.js.map +1 -1
- package/dist/cjs/views/ListRow.cjs +70 -12
- package/dist/cjs/views/ListRow.native.js +72 -12
- package/dist/cjs/views/ListRow.native.js.map +1 -1
- package/dist/cjs/views/index.cjs +13 -0
- package/dist/cjs/views/index.native.js +13 -0
- package/dist/cjs/views/index.native.js.map +1 -1
- package/dist/esm/Chip/index.mjs +3 -3
- package/dist/esm/Chip/index.mjs.map +1 -1
- package/dist/esm/Chip/index.native.js +3 -3
- package/dist/esm/Chip/index.native.js.map +1 -1
- package/dist/esm/DrillStack/DrillBar.mjs +99 -0
- package/dist/esm/DrillStack/DrillBar.mjs.map +1 -0
- package/dist/esm/DrillStack/DrillBar.native.js +105 -0
- package/dist/esm/DrillStack/DrillBar.native.js.map +1 -0
- package/dist/esm/DrillStack/context.mjs +39 -0
- package/dist/esm/DrillStack/context.mjs.map +1 -0
- package/dist/esm/DrillStack/context.native.js +43 -0
- package/dist/esm/DrillStack/context.native.js.map +1 -0
- package/dist/esm/DrillStack/drillMotion.mjs +41 -0
- package/dist/esm/DrillStack/drillMotion.mjs.map +1 -0
- package/dist/esm/DrillStack/drillMotion.native.js +42 -0
- package/dist/esm/DrillStack/drillMotion.native.js.map +1 -0
- package/dist/esm/DrillStack/drillSlide.mjs +144 -0
- package/dist/esm/DrillStack/drillSlide.mjs.map +1 -0
- package/dist/esm/DrillStack/drillSlide.native.js +7 -0
- package/dist/esm/DrillStack/drillSlide.native.js.map +1 -0
- package/dist/esm/DrillStack/index.mjs +131 -0
- package/dist/esm/DrillStack/index.mjs.map +1 -0
- package/dist/esm/DrillStack/index.native.js +260 -0
- package/dist/esm/DrillStack/index.native.js.map +1 -0
- package/dist/esm/DropdownMenu/index.mjs +264 -17
- package/dist/esm/DropdownMenu/index.mjs.map +1 -1
- package/dist/esm/DropdownMenu/index.native.js +306 -16
- package/dist/esm/DropdownMenu/index.native.js.map +1 -1
- package/dist/esm/Material/blur.native.js +5 -1
- package/dist/esm/Material/blur.native.js.map +1 -1
- package/dist/esm/MiddleEllipsisText/index.mjs +53 -0
- package/dist/esm/MiddleEllipsisText/index.mjs.map +1 -0
- package/dist/esm/MiddleEllipsisText/index.native.js +18 -0
- package/dist/esm/MiddleEllipsisText/index.native.js.map +1 -0
- package/dist/esm/MiddleEllipsisText/middleSplit.mjs +18 -0
- package/dist/esm/MiddleEllipsisText/middleSplit.mjs.map +1 -0
- package/dist/esm/MiddleEllipsisText/middleSplit.native.js +20 -0
- package/dist/esm/MiddleEllipsisText/middleSplit.native.js.map +1 -0
- package/dist/esm/MiddleEllipsisText/types.mjs +2 -0
- package/dist/esm/MiddleEllipsisText/types.mjs.map +1 -0
- package/dist/esm/MiddleEllipsisText/types.native.js +2 -0
- package/dist/esm/MiddleEllipsisText/types.native.js.map +1 -0
- package/dist/esm/ScrollView/useRevealFocusedField.native.js +3 -2
- package/dist/esm/ScrollView/useRevealFocusedField.native.js.map +1 -1
- package/dist/esm/SheetModal/index.mjs +10 -1
- package/dist/esm/SheetModal/index.mjs.map +1 -1
- package/dist/esm/SheetModal/index.native.js +14 -5
- package/dist/esm/SheetModal/index.native.js.map +1 -1
- package/dist/esm/SheetScrollView/index.mjs +277 -0
- package/dist/esm/SheetScrollView/index.mjs.map +1 -0
- package/dist/esm/SheetScrollView/index.native.js +329 -0
- package/dist/esm/SheetScrollView/index.native.js.map +1 -0
- package/dist/esm/SheetScrollView/sheetDrag.mjs +5 -0
- package/dist/esm/SheetScrollView/sheetDrag.mjs.map +1 -0
- package/dist/esm/SheetScrollView/sheetDrag.native.js +12 -0
- package/dist/esm/SheetScrollView/sheetDrag.native.js.map +1 -0
- package/dist/esm/SheetScrollView/sheetHandoff.mjs +190 -0
- package/dist/esm/SheetScrollView/sheetHandoff.mjs.map +1 -0
- package/dist/esm/SheetScrollView/sheetHandoff.native.js +204 -0
- package/dist/esm/SheetScrollView/sheetHandoff.native.js.map +1 -0
- package/dist/esm/Tabs/index.mjs +27 -49
- package/dist/esm/Tabs/index.mjs.map +1 -1
- package/dist/esm/Tabs/index.native.js +28 -50
- package/dist/esm/Tabs/index.native.js.map +1 -1
- package/dist/esm/Tooltip/index.native.js +10 -2
- package/dist/esm/Tooltip/index.native.js.map +1 -1
- package/dist/esm/appShell/AppShell.mjs +91 -107
- package/dist/esm/appShell/AppShell.mjs.map +1 -1
- package/dist/esm/appShell/AppShell.native.js +100 -114
- package/dist/esm/appShell/AppShell.native.js.map +1 -1
- package/dist/esm/appShell/MpoTabHost.mjs.map +1 -1
- package/dist/esm/appShell/Springboard.mjs +1 -1
- package/dist/esm/appShell/Springboard.mjs.map +1 -1
- package/dist/esm/appShell/Springboard.native.js +1 -1
- package/dist/esm/appShell/Springboard.native.js.map +1 -1
- package/dist/esm/appShell/SystemBar.mjs +147 -58
- package/dist/esm/appShell/SystemBar.mjs.map +1 -1
- package/dist/esm/appShell/SystemBar.native.js +152 -62
- package/dist/esm/appShell/SystemBar.native.js.map +1 -1
- package/dist/esm/appShell/TabHost.native.js +5 -2
- package/dist/esm/appShell/TabHost.native.js.map +1 -1
- package/dist/esm/appShell/stackBack.mjs +23 -0
- package/dist/esm/appShell/stackBack.mjs.map +1 -0
- package/dist/esm/appShell/stackBack.native.js +26 -0
- package/dist/esm/appShell/stackBack.native.js.map +1 -0
- package/dist/esm/appShell/systemBarFit.mjs +12 -2
- package/dist/esm/appShell/systemBarFit.mjs.map +1 -1
- package/dist/esm/appShell/systemBarFit.native.js +16 -2
- package/dist/esm/appShell/systemBarFit.native.js.map +1 -1
- package/dist/esm/code/CodeBlock/index.mjs +21 -12
- package/dist/esm/code/CodeBlock/index.mjs.map +1 -1
- package/dist/esm/code/CodeBlock/index.native.js +21 -12
- package/dist/esm/code/CodeBlock/index.native.js.map +1 -1
- package/dist/esm/code/HoldSelect/index.mjs +42 -0
- package/dist/esm/code/HoldSelect/index.mjs.map +1 -0
- package/dist/esm/code/HoldSelect/index.native.js +102 -0
- package/dist/esm/code/HoldSelect/index.native.js.map +1 -0
- package/dist/esm/code/HoldSelect/tapGate.mjs +61 -0
- package/dist/esm/code/HoldSelect/tapGate.mjs.map +1 -0
- package/dist/esm/code/HoldSelect/tapGate.native.js +65 -0
- package/dist/esm/code/HoldSelect/tapGate.native.js.map +1 -0
- package/dist/esm/code/LogView.mjs +13 -3
- package/dist/esm/code/LogView.mjs.map +1 -1
- package/dist/esm/code/LogView.native.js +14 -3
- package/dist/esm/code/LogView.native.js.map +1 -1
- package/dist/esm/code/PayloadView/index.mjs +377 -0
- package/dist/esm/code/PayloadView/index.mjs.map +1 -0
- package/dist/esm/code/PayloadView/index.native.js +413 -0
- package/dist/esm/code/PayloadView/index.native.js.map +1 -0
- package/dist/esm/code/PayloadView/payloadModel.mjs +245 -0
- package/dist/esm/code/PayloadView/payloadModel.mjs.map +1 -0
- package/dist/esm/code/PayloadView/payloadModel.native.js +309 -0
- package/dist/esm/code/PayloadView/payloadModel.native.js.map +1 -0
- package/dist/esm/code/index.mjs +2 -0
- package/dist/esm/code/index.mjs.map +1 -1
- package/dist/esm/code/index.native.js +2 -0
- package/dist/esm/code/index.native.js.map +1 -1
- package/dist/esm/componentColors.mjs +5 -4
- package/dist/esm/componentColors.mjs.map +1 -1
- package/dist/esm/componentColors.native.js +5 -4
- package/dist/esm/componentColors.native.js.map +1 -1
- package/dist/esm/images/RemoteArt/index.mjs +25 -0
- package/dist/esm/images/RemoteArt/index.mjs.map +1 -0
- package/dist/esm/images/RemoteArt/index.native.js +45 -0
- package/dist/esm/images/RemoteArt/index.native.js.map +1 -0
- package/dist/esm/images/RemoteArt/remoteArtCache.mjs +150 -0
- package/dist/esm/images/RemoteArt/remoteArtCache.mjs.map +1 -0
- package/dist/esm/images/RemoteArt/remoteArtCache.native.js +190 -0
- package/dist/esm/images/RemoteArt/remoteArtCache.native.js.map +1 -0
- package/dist/esm/images/RemoteArt/svgMarkup.mjs +93 -0
- package/dist/esm/images/RemoteArt/svgMarkup.mjs.map +1 -0
- package/dist/esm/images/RemoteArt/svgMarkup.native.js +196 -0
- package/dist/esm/images/RemoteArt/svgMarkup.native.js.map +1 -0
- package/dist/esm/images/RemoteArt/types.mjs +2 -0
- package/dist/esm/images/RemoteArt/types.mjs.map +1 -0
- package/dist/esm/images/RemoteArt/types.native.js +2 -0
- package/dist/esm/images/RemoteArt/types.native.js.map +1 -0
- package/dist/esm/images/index.mjs +3 -0
- package/dist/esm/images/index.mjs.map +1 -1
- package/dist/esm/images/index.native.js +3 -0
- package/dist/esm/images/index.native.js.map +1 -1
- package/dist/esm/index.mjs +4 -1
- package/dist/esm/index.mjs.map +1 -1
- package/dist/esm/index.native.js +4 -1
- package/dist/esm/index.native.js.map +1 -1
- package/dist/esm/layouts/AsyncBoundary.mjs +22 -2
- package/dist/esm/layouts/AsyncBoundary.mjs.map +1 -1
- package/dist/esm/layouts/AsyncBoundary.native.js +22 -2
- package/dist/esm/layouts/AsyncBoundary.native.js.map +1 -1
- package/dist/esm/layouts/asyncFailure.mjs +15 -15
- package/dist/esm/layouts/asyncFailure.mjs.map +1 -1
- package/dist/esm/layouts/asyncFailure.native.js +15 -15
- package/dist/esm/layouts/asyncFailure.native.js.map +1 -1
- package/dist/esm/layouts/attachments.mjs +48 -9
- package/dist/esm/layouts/attachments.mjs.map +1 -1
- package/dist/esm/layouts/attachments.native.js +50 -9
- package/dist/esm/layouts/attachments.native.js.map +1 -1
- package/dist/esm/layouts/page.mjs +94 -18
- package/dist/esm/layouts/page.mjs.map +1 -1
- package/dist/esm/layouts/page.native.js +96 -17
- package/dist/esm/layouts/page.native.js.map +1 -1
- package/dist/esm/layouts/screenScroll.mjs +8 -4
- package/dist/esm/layouts/screenScroll.mjs.map +1 -1
- package/dist/esm/layouts/screenScroll.native.js +12 -4
- package/dist/esm/layouts/screenScroll.native.js.map +1 -1
- package/dist/esm/layouts/tags.mjs +2 -1
- package/dist/esm/layouts/tags.mjs.map +1 -1
- package/dist/esm/layouts/tags.native.js +2 -1
- package/dist/esm/layouts/tags.native.js.map +1 -1
- package/dist/esm/views/Dashboard.mjs +19 -6
- package/dist/esm/views/Dashboard.mjs.map +1 -1
- package/dist/esm/views/Dashboard.native.js +19 -6
- package/dist/esm/views/Dashboard.native.js.map +1 -1
- package/dist/esm/views/FilePreview.mjs +588 -0
- package/dist/esm/views/FilePreview.mjs.map +1 -0
- package/dist/esm/views/FilePreview.native.js +636 -0
- package/dist/esm/views/FilePreview.native.js.map +1 -0
- package/dist/esm/views/List.mjs +2 -2
- package/dist/esm/views/List.mjs.map +1 -1
- package/dist/esm/views/List.native.js +2 -2
- package/dist/esm/views/List.native.js.map +1 -1
- package/dist/esm/views/ListGroup.mjs +278 -21
- package/dist/esm/views/ListGroup.mjs.map +1 -1
- package/dist/esm/views/ListGroup.native.js +291 -24
- package/dist/esm/views/ListGroup.native.js.map +1 -1
- package/dist/esm/views/ListRow.mjs +65 -8
- package/dist/esm/views/ListRow.mjs.map +1 -1
- package/dist/esm/views/ListRow.native.js +67 -8
- package/dist/esm/views/ListRow.native.js.map +1 -1
- package/dist/esm/views/index.mjs +2 -1
- package/dist/esm/views/index.mjs.map +1 -1
- package/dist/esm/views/index.native.js +2 -1
- package/dist/esm/views/index.native.js.map +1 -1
- package/dist/jsx/Accordion/index.native.js +1 -1
- package/dist/jsx/Accordion/index.native.js.map +1 -1
- package/dist/jsx/Alert/index.native.js.map +1 -1
- package/dist/jsx/AnimateHeight/index.native.js.map +1 -1
- package/dist/jsx/Avatar/getInitials.native.js.map +1 -1
- package/dist/jsx/Avatar/index.native.js.map +1 -1
- package/dist/jsx/Badge/index.native.js.map +1 -1
- package/dist/jsx/Button.native.js.map +1 -1
- package/dist/jsx/Card.native.js.map +1 -1
- package/dist/jsx/CardFooter.native.js.map +1 -1
- package/dist/jsx/CardHeader.native.js.map +1 -1
- package/dist/jsx/Carousel/geometry.native.js.map +1 -1
- package/dist/jsx/Carousel/index.native.js +3 -3
- package/dist/jsx/Carousel/index.native.js.map +1 -1
- package/dist/jsx/ChatTurn/index.native.js.map +1 -1
- package/dist/jsx/CheckGlyph/MenuCheckColumn.native.js.map +1 -1
- package/dist/jsx/CheckGlyph/index.native.js.map +1 -1
- package/dist/jsx/Chip/index.mjs +3 -3
- package/dist/jsx/Chip/index.mjs.map +1 -1
- package/dist/jsx/Chip/index.native.js +1 -1
- package/dist/jsx/Chip/index.native.js.map +1 -1
- package/dist/jsx/ChoiceChips/index.native.js +1 -1
- package/dist/jsx/ChoiceChips/index.native.js.map +1 -1
- package/dist/jsx/Collapsible.native.js.map +1 -1
- package/dist/jsx/ContextMenu/index.native.js.map +1 -1
- package/dist/jsx/CopyField/CopyMenuButton.native.js +1 -1
- package/dist/jsx/CopyField/CopyMenuButton.native.js.map +1 -1
- package/dist/jsx/CopyField/index.native.js.map +1 -1
- package/dist/jsx/Dialog.native.js +1 -1
- package/dist/jsx/Dialog.native.js.map +1 -1
- package/dist/jsx/Diff/diff.native.js.map +1 -1
- package/dist/jsx/Diff/index.native.js.map +1 -1
- package/dist/jsx/DotIndicator/index.native.js.map +1 -1
- package/dist/jsx/DrillStack/DrillBar.mjs +99 -0
- package/dist/jsx/DrillStack/DrillBar.mjs.map +1 -0
- package/dist/jsx/DrillStack/DrillBar.native.js +133 -0
- package/dist/jsx/DrillStack/DrillBar.native.js.map +1 -0
- package/dist/jsx/DrillStack/context.mjs +39 -0
- package/dist/jsx/DrillStack/context.mjs.map +1 -0
- package/dist/jsx/DrillStack/context.native.js +73 -0
- package/dist/jsx/DrillStack/context.native.js.map +1 -0
- package/dist/jsx/DrillStack/drillMotion.mjs +41 -0
- package/dist/jsx/DrillStack/drillMotion.mjs.map +1 -0
- package/dist/jsx/DrillStack/drillMotion.native.js +72 -0
- package/dist/jsx/DrillStack/drillMotion.native.js.map +1 -0
- package/dist/jsx/DrillStack/drillSlide.mjs +144 -0
- package/dist/jsx/DrillStack/drillSlide.mjs.map +1 -0
- package/dist/jsx/DrillStack/drillSlide.native.js +36 -0
- package/dist/jsx/DrillStack/drillSlide.native.js.map +1 -0
- package/dist/jsx/DrillStack/index.mjs +131 -0
- package/dist/jsx/DrillStack/index.mjs.map +1 -0
- package/dist/jsx/DrillStack/index.native.js +294 -0
- package/dist/jsx/DrillStack/index.native.js.map +1 -0
- package/dist/jsx/DropDownPanel/index.native.js.map +1 -1
- package/dist/jsx/DropdownMenu/index.mjs +264 -17
- package/dist/jsx/DropdownMenu/index.mjs.map +1 -1
- package/dist/jsx/DropdownMenu/index.native.js +334 -44
- package/dist/jsx/DropdownMenu/index.native.js.map +1 -1
- package/dist/jsx/DropdownMenu/menuSettle.native.js.map +1 -1
- package/dist/jsx/ElapsedProgress/index.native.js.map +1 -1
- package/dist/jsx/ErrorBoundary/index.native.js.map +1 -1
- package/dist/jsx/Heading.native.js.map +1 -1
- package/dist/jsx/Kbd/index.native.js.map +1 -1
- package/dist/jsx/Kbd/keys.native.js.map +1 -1
- package/dist/jsx/Lightbox/MediaControl.native.js.map +1 -1
- package/dist/jsx/Lightbox/index.gnome.native.js.map +1 -1
- package/dist/jsx/Lightbox/index.native.js +1 -1
- package/dist/jsx/Lightbox/shared.native.js.map +1 -1
- package/dist/jsx/Lightbox/useLightbox.native.js.map +1 -1
- package/dist/jsx/MachineLiteral/index.native.js.map +1 -1
- package/dist/jsx/Material/blur.native.js +5 -1
- package/dist/jsx/Material/blur.native.js.map +1 -1
- package/dist/jsx/Material/index.native.js.map +1 -1
- package/dist/jsx/Meter/index.native.js +1 -1
- package/dist/jsx/Meter/index.native.js.map +1 -1
- package/dist/jsx/Meter/meter.native.js.map +1 -1
- package/dist/jsx/MiddleEllipsisText/index.mjs +53 -0
- package/dist/jsx/MiddleEllipsisText/index.mjs.map +1 -0
- package/dist/jsx/MiddleEllipsisText/index.native.js +46 -0
- package/dist/jsx/MiddleEllipsisText/index.native.js.map +1 -0
- package/dist/jsx/MiddleEllipsisText/middleSplit.mjs +18 -0
- package/dist/jsx/MiddleEllipsisText/middleSplit.mjs.map +1 -0
- package/dist/jsx/MiddleEllipsisText/middleSplit.native.js +48 -0
- package/dist/jsx/MiddleEllipsisText/middleSplit.native.js.map +1 -0
- package/dist/jsx/MiddleEllipsisText/types.mjs +2 -0
- package/dist/jsx/MiddleEllipsisText/types.mjs.map +1 -0
- package/dist/jsx/MiddleEllipsisText/types.native.js +21 -0
- package/dist/jsx/MiddleEllipsisText/types.native.js.map +1 -0
- package/dist/jsx/OverflowRow/index.native.js +1 -1
- package/dist/jsx/OverflowRow/index.native.js.map +1 -1
- package/dist/jsx/Pagination.native.js +1 -1
- package/dist/jsx/Pagination.native.js.map +1 -1
- package/dist/jsx/Popover.native.js +1 -1
- package/dist/jsx/Popover.native.js.map +1 -1
- package/dist/jsx/ProgressSteps/index.native.js.map +1 -1
- package/dist/jsx/Quote/index.native.js.map +1 -1
- package/dist/jsx/SchemeToggle/index.native.js +1 -1
- package/dist/jsx/SchemeToggle/index.native.js.map +1 -1
- package/dist/jsx/ScrollView/revealFocusedField.native.js.map +1 -1
- package/dist/jsx/ScrollView/useRevealFocusedField.native.js +3 -2
- package/dist/jsx/ScrollView/useRevealFocusedField.native.js.map +1 -1
- package/dist/jsx/Separator/index.native.js.map +1 -1
- package/dist/jsx/Sheet.native.js.map +1 -1
- package/dist/jsx/SheetModal/SheetHeader.native.js.map +1 -1
- package/dist/jsx/SheetModal/SheetNavigation.native.js.map +1 -1
- package/dist/jsx/SheetModal/detents.native.js.map +1 -1
- package/dist/jsx/SheetModal/index.mjs +10 -1
- package/dist/jsx/SheetModal/index.mjs.map +1 -1
- package/dist/jsx/SheetModal/index.native.js +14 -5
- package/dist/jsx/SheetModal/index.native.js.map +1 -1
- package/dist/jsx/SheetModal/useSheetFrameFocus.native.js.map +1 -1
- package/dist/jsx/SheetScrollView/index.mjs +277 -0
- package/dist/jsx/SheetScrollView/index.mjs.map +1 -0
- package/dist/jsx/SheetScrollView/index.native.js +361 -0
- package/dist/jsx/SheetScrollView/index.native.js.map +1 -0
- package/dist/jsx/SheetScrollView/sheetDrag.mjs +5 -0
- package/dist/jsx/SheetScrollView/sheetDrag.mjs.map +1 -0
- package/dist/jsx/SheetScrollView/sheetDrag.native.js +40 -0
- package/dist/jsx/SheetScrollView/sheetDrag.native.js.map +1 -0
- package/dist/jsx/SheetScrollView/sheetHandoff.mjs +190 -0
- package/dist/jsx/SheetScrollView/sheetHandoff.mjs.map +1 -0
- package/dist/jsx/SheetScrollView/sheetHandoff.native.js +242 -0
- package/dist/jsx/SheetScrollView/sheetHandoff.native.js.map +1 -0
- package/dist/jsx/Skeleton/index.native.js.map +1 -1
- package/dist/jsx/SkipLink/index.native.js.map +1 -1
- package/dist/jsx/SortableList/SortableHandle.native.js.map +1 -1
- package/dist/jsx/SortableList/index.native.js.map +1 -1
- package/dist/jsx/SortableList/useSortableRows.native.js.map +1 -1
- package/dist/jsx/SortableList/useUserOrder.native.js.map +1 -1
- package/dist/jsx/SwipeDismissRow/index.native.js.map +1 -1
- package/dist/jsx/Tabs/index.mjs +27 -49
- package/dist/jsx/Tabs/index.mjs.map +1 -1
- package/dist/jsx/Tabs/index.native.js +29 -49
- package/dist/jsx/Tabs/index.native.js.map +1 -1
- package/dist/jsx/Text.native.js.map +1 -1
- package/dist/jsx/ThemePresetPicker/index.native.js +1 -1
- package/dist/jsx/ThemePresetPicker/index.native.js.map +1 -1
- package/dist/jsx/Toast/index.native.js.map +1 -1
- package/dist/jsx/Toast/store.native.js.map +1 -1
- package/dist/jsx/Tooltip/index.native.js +9 -1
- package/dist/jsx/Tooltip/index.native.js.map +1 -1
- package/dist/jsx/Tooltip/nativePress.native.js.map +1 -1
- package/dist/jsx/Tooltip/tooltipShared.native.js.map +1 -1
- package/dist/jsx/TreeSelect/index.native.js +2 -2
- package/dist/jsx/TreeSelect/index.native.js.map +1 -1
- package/dist/jsx/TreeSelect/treeSelectModel.native.js.map +1 -1
- package/dist/jsx/Video/PlayerChrome.native.js.map +1 -1
- package/dist/jsx/Video/VideoFrame.native.js.map +1 -1
- package/dist/jsx/Video/types.native.js.map +1 -1
- package/dist/jsx/Wheel/index.native.js.map +1 -1
- package/dist/jsx/Wizard/index.native.js +2 -2
- package/dist/jsx/Wizard/index.native.js.map +1 -1
- package/dist/jsx/actions/ActionBar.native.js.map +1 -1
- package/dist/jsx/actions/DangerSection.native.js.map +1 -1
- package/dist/jsx/actions/DestructiveAction.native.js.map +1 -1
- package/dist/jsx/actions/HeaderActions.native.js +2 -2
- package/dist/jsx/actions/HeaderActions.native.js.map +1 -1
- package/dist/jsx/actions/StandardAction.native.js +1 -1
- package/dist/jsx/actions/StandardAction.native.js.map +1 -1
- package/dist/jsx/actions/devWarn.native.js.map +1 -1
- package/dist/jsx/actions/index.native.js.map +1 -1
- package/dist/jsx/actions/severity.native.js.map +1 -1
- package/dist/jsx/appShell/AppShell.mjs +91 -107
- package/dist/jsx/appShell/AppShell.mjs.map +1 -1
- package/dist/jsx/appShell/AppShell.native.js +101 -115
- package/dist/jsx/appShell/AppShell.native.js.map +1 -1
- package/dist/jsx/appShell/BottomChromeClearance.native.js.map +1 -1
- package/dist/jsx/appShell/Dock.native.js.map +1 -1
- package/dist/jsx/appShell/MpoTabHost.mjs.map +1 -1
- package/dist/jsx/appShell/MpoTabHost.native.js.map +1 -1
- package/dist/jsx/appShell/ScopeMenu.native.js +1 -1
- package/dist/jsx/appShell/ScopeMenu.native.js.map +1 -1
- package/dist/jsx/appShell/SettingsSplit.native.js +1 -1
- package/dist/jsx/appShell/SettingsSplit.native.js.map +1 -1
- package/dist/jsx/appShell/Springboard.mjs +1 -1
- package/dist/jsx/appShell/Springboard.mjs.map +1 -1
- package/dist/jsx/appShell/Springboard.native.js +3 -3
- package/dist/jsx/appShell/Springboard.native.js.map +1 -1
- package/dist/jsx/appShell/SystemBar.mjs +147 -58
- package/dist/jsx/appShell/SystemBar.mjs.map +1 -1
- package/dist/jsx/appShell/SystemBar.native.js +152 -59
- package/dist/jsx/appShell/SystemBar.native.js.map +1 -1
- package/dist/jsx/appShell/TabBar.native.js +1 -1
- package/dist/jsx/appShell/TabBar.native.js.map +1 -1
- package/dist/jsx/appShell/TabHost.native.js +5 -2
- package/dist/jsx/appShell/TabHost.native.js.map +1 -1
- package/dist/jsx/appShell/appTile.native.js +1 -1
- package/dist/jsx/appShell/appTile.native.js.map +1 -1
- package/dist/jsx/appShell/bottomChrome.native.js.map +1 -1
- package/dist/jsx/appShell/index.native.js.map +1 -1
- package/dist/jsx/appShell/stackBack.mjs +23 -0
- package/dist/jsx/appShell/stackBack.mjs.map +1 -0
- package/dist/jsx/appShell/stackBack.native.js +55 -0
- package/dist/jsx/appShell/stackBack.native.js.map +1 -0
- package/dist/jsx/appShell/systemBarFit.mjs +12 -2
- package/dist/jsx/appShell/systemBarFit.mjs.map +1 -1
- package/dist/jsx/appShell/systemBarFit.native.js +16 -2
- package/dist/jsx/appShell/systemBarFit.native.js.map +1 -1
- package/dist/jsx/charts/Axis.native.js.map +1 -1
- package/dist/jsx/charts/BarChart.native.js.map +1 -1
- package/dist/jsx/charts/ChartDataView.native.js +2 -2
- package/dist/jsx/charts/ChartDataView.native.js.map +1 -1
- package/dist/jsx/charts/ChartSurface.native.js.map +1 -1
- package/dist/jsx/charts/LineChart.native.js.map +1 -1
- package/dist/jsx/charts/PieChart.native.js.map +1 -1
- package/dist/jsx/charts/Sparkline.native.js.map +1 -1
- package/dist/jsx/charts/accessibility.native.js.map +1 -1
- package/dist/jsx/charts/chartHeight.native.js.map +1 -1
- package/dist/jsx/charts/composeChart.native.js.map +1 -1
- package/dist/jsx/charts/index.native.js.map +1 -1
- package/dist/jsx/charts/math.native.js.map +1 -1
- package/dist/jsx/charts/series.native.js.map +1 -1
- package/dist/jsx/charts/svg.native.js.map +1 -1
- package/dist/jsx/charts/types.native.js.map +1 -1
- package/dist/jsx/charts/useChartTheme.native.js.map +1 -1
- package/dist/jsx/code/Code/index.native.js.map +1 -1
- package/dist/jsx/code/CodeBlock/index.mjs +21 -12
- package/dist/jsx/code/CodeBlock/index.mjs.map +1 -1
- package/dist/jsx/code/CodeBlock/index.native.js +28 -19
- package/dist/jsx/code/CodeBlock/index.native.js.map +1 -1
- package/dist/jsx/code/HighlightedCode/index.native.js.map +1 -1
- package/dist/jsx/code/Highlighter/houseSyntaxTheme.native.js.map +1 -1
- package/dist/jsx/code/Highlighter/index.native.js.map +1 -1
- package/dist/jsx/code/Highlighter/namedGroupMatchAll.native.js.map +1 -1
- package/dist/jsx/code/HoldSelect/index.mjs +42 -0
- package/dist/jsx/code/HoldSelect/index.mjs.map +1 -0
- package/dist/jsx/code/HoldSelect/index.native.js +132 -0
- package/dist/jsx/code/HoldSelect/index.native.js.map +1 -0
- package/dist/jsx/code/HoldSelect/tapGate.mjs +61 -0
- package/dist/jsx/code/HoldSelect/tapGate.mjs.map +1 -0
- package/dist/jsx/code/HoldSelect/tapGate.native.js +95 -0
- package/dist/jsx/code/HoldSelect/tapGate.native.js.map +1 -0
- package/dist/jsx/code/LogView.mjs +13 -3
- package/dist/jsx/code/LogView.mjs.map +1 -1
- package/dist/jsx/code/LogView.native.js +15 -3
- package/dist/jsx/code/LogView.native.js.map +1 -1
- package/dist/jsx/code/PayloadView/index.mjs +377 -0
- package/dist/jsx/code/PayloadView/index.mjs.map +1 -0
- package/dist/jsx/code/PayloadView/index.native.js +443 -0
- package/dist/jsx/code/PayloadView/index.native.js.map +1 -0
- package/dist/jsx/code/PayloadView/payloadModel.mjs +245 -0
- package/dist/jsx/code/PayloadView/payloadModel.mjs.map +1 -0
- package/dist/jsx/code/PayloadView/payloadModel.native.js +348 -0
- package/dist/jsx/code/PayloadView/payloadModel.native.js.map +1 -0
- package/dist/jsx/code/Pre/index.native.js.map +1 -1
- package/dist/jsx/code/index.mjs +2 -0
- package/dist/jsx/code/index.mjs.map +1 -1
- package/dist/jsx/code/index.native.js +7 -5
- package/dist/jsx/code/index.native.js.map +1 -1
- package/dist/jsx/componentColors.mjs +5 -4
- package/dist/jsx/componentColors.mjs.map +1 -1
- package/dist/jsx/componentColors.native.js +5 -4
- package/dist/jsx/componentColors.native.js.map +1 -1
- package/dist/jsx/feedback/ConfirmDialog.native.js.map +1 -1
- package/dist/jsx/feedback/NotifyHost.native.js +2 -2
- package/dist/jsx/feedback/NotifyHost.native.js.map +1 -1
- package/dist/jsx/feedback/copy.native.js.map +1 -1
- package/dist/jsx/feedback/index.native.js.map +1 -1
- package/dist/jsx/feedback/notify.native.js.map +1 -1
- package/dist/jsx/feedback/route.native.js.map +1 -1
- package/dist/jsx/feedback/store.native.js.map +1 -1
- package/dist/jsx/formLayouts/FormLayouts.native.js +1 -1
- package/dist/jsx/formLayouts/FormLayouts.native.js.map +1 -1
- package/dist/jsx/formLayouts/PreferencePanel.native.js +2 -2
- package/dist/jsx/formLayouts/PreferencePanel.native.js.map +1 -1
- package/dist/jsx/formLayouts/index.native.js.map +1 -1
- package/dist/jsx/hooks/index.native.js +1 -1
- package/dist/jsx/hooks/index.native.js.map +1 -1
- package/dist/jsx/hooks/useClipboard.native.js.map +1 -1
- package/dist/jsx/hooks/useDocumentTitle.native.js.map +1 -1
- package/dist/jsx/icons/CheckRegular.native.js.map +1 -1
- package/dist/jsx/icons/MinusRegular.native.js.map +1 -1
- package/dist/jsx/icons/index.native.js.map +1 -1
- package/dist/jsx/icons/lucide.native.js.map +1 -1
- package/dist/jsx/icons/themed.native.js.map +1 -1
- package/dist/jsx/images/Image/ImageFrame.native.js +1 -1
- package/dist/jsx/images/Image/ImageFrame.native.js.map +1 -1
- package/dist/jsx/images/Image/framing.native.js.map +1 -1
- package/dist/jsx/images/Image/index.native.js +1 -1
- package/dist/jsx/images/Image/mediaRadius.native.js.map +1 -1
- package/dist/jsx/images/Image/shared.native.js +1 -1
- package/dist/jsx/images/Image/shared.native.js.map +1 -1
- package/dist/jsx/images/Image/types.native.js.map +1 -1
- package/dist/jsx/images/RemoteArt/index.mjs +25 -0
- package/dist/jsx/images/RemoteArt/index.mjs.map +1 -0
- package/dist/jsx/images/RemoteArt/index.native.js +73 -0
- package/dist/jsx/images/RemoteArt/index.native.js.map +1 -0
- package/dist/jsx/images/RemoteArt/remoteArtCache.mjs +150 -0
- package/dist/jsx/images/RemoteArt/remoteArtCache.mjs.map +1 -0
- package/dist/jsx/images/RemoteArt/remoteArtCache.native.js +222 -0
- package/dist/jsx/images/RemoteArt/remoteArtCache.native.js.map +1 -0
- package/dist/jsx/images/RemoteArt/svgMarkup.mjs +93 -0
- package/dist/jsx/images/RemoteArt/svgMarkup.mjs.map +1 -0
- package/dist/jsx/images/RemoteArt/svgMarkup.native.js +225 -0
- package/dist/jsx/images/RemoteArt/svgMarkup.native.js.map +1 -0
- package/dist/jsx/images/RemoteArt/types.mjs +2 -0
- package/dist/jsx/images/RemoteArt/types.mjs.map +1 -0
- package/dist/jsx/images/RemoteArt/types.native.js +21 -0
- package/dist/jsx/images/RemoteArt/types.native.js.map +1 -0
- package/dist/jsx/images/index.mjs +3 -0
- package/dist/jsx/images/index.mjs.map +1 -1
- package/dist/jsx/images/index.native.js +12 -0
- package/dist/jsx/images/index.native.js.map +1 -1
- package/dist/jsx/index.gnome.native.js +22 -22
- package/dist/jsx/index.gnome.native.js.map +1 -1
- package/dist/jsx/index.js +4 -1
- package/dist/jsx/index.js.map +1 -1
- package/dist/jsx/index.mjs +4 -1
- package/dist/jsx/index.mjs.map +1 -1
- package/dist/jsx/index.native.js +51 -43
- package/dist/jsx/index.native.js.map +1 -1
- package/dist/jsx/knobImmuneExports.native.js.map +1 -1
- package/dist/jsx/layouts/AsyncBoundary.mjs +22 -2
- package/dist/jsx/layouts/AsyncBoundary.mjs.map +1 -1
- package/dist/jsx/layouts/AsyncBoundary.native.js +23 -3
- package/dist/jsx/layouts/AsyncBoundary.native.js.map +1 -1
- package/dist/jsx/layouts/Debug/index.native.js.map +1 -1
- package/dist/jsx/layouts/EmptyState.native.js +1 -1
- package/dist/jsx/layouts/EmptyState.native.js.map +1 -1
- package/dist/jsx/layouts/IdentityPlate.native.js +1 -1
- package/dist/jsx/layouts/IdentityPlate.native.js.map +1 -1
- package/dist/jsx/layouts/KeyboardAvoidingWrapper/behavior.native.js.map +1 -1
- package/dist/jsx/layouts/PageTemplates.native.js.map +1 -1
- package/dist/jsx/layouts/PaneScaffold.native.js.map +1 -1
- package/dist/jsx/layouts/SafeAreaWrapper/insets.native.js.map +1 -1
- package/dist/jsx/layouts/StatusDot.native.js.map +1 -1
- package/dist/jsx/layouts/StatusGlyphStrip.native.js +1 -1
- package/dist/jsx/layouts/StatusGlyphStrip.native.js.map +1 -1
- package/dist/jsx/layouts/ViewSwitcher.native.js.map +1 -1
- package/dist/jsx/layouts/asyncFailure.mjs +15 -15
- package/dist/jsx/layouts/asyncFailure.mjs.map +1 -1
- package/dist/jsx/layouts/asyncFailure.native.js +15 -15
- package/dist/jsx/layouts/asyncFailure.native.js.map +1 -1
- package/dist/jsx/layouts/attachments.mjs +48 -9
- package/dist/jsx/layouts/attachments.mjs.map +1 -1
- package/dist/jsx/layouts/attachments.native.js +50 -9
- package/dist/jsx/layouts/attachments.native.js.map +1 -1
- package/dist/jsx/layouts/barTitleSpan.native.js.map +1 -1
- package/dist/jsx/layouts/bottomAccessory.native.js.map +1 -1
- package/dist/jsx/layouts/breadcrumbs.native.js.map +1 -1
- package/dist/jsx/layouts/index.native.js +3 -3
- package/dist/jsx/layouts/index.native.js.map +1 -1
- package/dist/jsx/layouts/page.mjs +94 -18
- package/dist/jsx/layouts/page.mjs.map +1 -1
- package/dist/jsx/layouts/page.native.js +95 -16
- package/dist/jsx/layouts/page.native.js.map +1 -1
- package/dist/jsx/layouts/pageHeadingScope.native.js.map +1 -1
- package/dist/jsx/layouts/screenScroll.mjs +8 -4
- package/dist/jsx/layouts/screenScroll.mjs.map +1 -1
- package/dist/jsx/layouts/screenScroll.native.js +12 -4
- package/dist/jsx/layouts/screenScroll.native.js.map +1 -1
- package/dist/jsx/layouts/shellSidebarSlot.native.js.map +1 -1
- package/dist/jsx/layouts/sidebar.native.js +1 -1
- package/dist/jsx/layouts/sidebar.native.js.map +1 -1
- package/dist/jsx/layouts/tags.mjs +2 -1
- package/dist/jsx/layouts/tags.mjs.map +1 -1
- package/dist/jsx/layouts/tags.native.js +4 -3
- package/dist/jsx/layouts/tags.native.js.map +1 -1
- package/dist/jsx/layouts/timeline.native.js +2 -2
- package/dist/jsx/layouts/timeline.native.js.map +1 -1
- package/dist/jsx/layouts/toolbar.native.js +1 -1
- package/dist/jsx/layouts/toolbar.native.js.map +1 -1
- package/dist/jsx/shared/actionScan.native.js.map +1 -1
- package/dist/jsx/shared/i18n.native.js.map +1 -1
- package/dist/jsx/shared/restoreRetries.native.js.map +1 -1
- package/dist/jsx/shared/t.native.js.map +1 -1
- package/dist/jsx/shared/textRidesText.native.js.map +1 -1
- package/dist/jsx/shared/useReturnFocusOnClose.native.js.map +1 -1
- package/dist/jsx/surfaces.native.js +1 -1
- package/dist/jsx/surfaces.native.js.map +1 -1
- package/dist/jsx/tamagui.native.js +1 -1
- package/dist/jsx/tamagui.native.js.map +1 -1
- package/dist/jsx/testSetup.native.js.map +1 -1
- package/dist/jsx/utils/unwrapText.native.js.map +1 -1
- package/dist/jsx/views/Calendar.native.js +1 -1
- package/dist/jsx/views/Calendar.native.js.map +1 -1
- package/dist/jsx/views/CardGrid.native.js.map +1 -1
- package/dist/jsx/views/Dashboard.mjs +19 -6
- package/dist/jsx/views/Dashboard.mjs.map +1 -1
- package/dist/jsx/views/Dashboard.native.js +20 -7
- package/dist/jsx/views/Dashboard.native.js.map +1 -1
- package/dist/jsx/views/FilePreview.mjs +588 -0
- package/dist/jsx/views/FilePreview.mjs.map +1 -0
- package/dist/jsx/views/FilePreview.native.js +675 -0
- package/dist/jsx/views/FilePreview.native.js.map +1 -0
- package/dist/jsx/views/Gantt.native.js +2 -2
- package/dist/jsx/views/Gantt.native.js.map +1 -1
- package/dist/jsx/views/GanttDateGrip.native.js.map +1 -1
- package/dist/jsx/views/ImageGrid.native.js +2 -2
- package/dist/jsx/views/ImageGrid.native.js.map +1 -1
- package/dist/jsx/views/Kanban.native.js +1 -1
- package/dist/jsx/views/List.mjs +2 -2
- package/dist/jsx/views/List.mjs.map +1 -1
- package/dist/jsx/views/List.native.js +1 -0
- package/dist/jsx/views/List.native.js.map +1 -1
- package/dist/jsx/views/ListGroup.mjs +278 -21
- package/dist/jsx/views/ListGroup.mjs.map +1 -1
- package/dist/jsx/views/ListGroup.native.js +290 -23
- package/dist/jsx/views/ListGroup.native.js.map +1 -1
- package/dist/jsx/views/ListRow.mjs +65 -8
- package/dist/jsx/views/ListRow.mjs.map +1 -1
- package/dist/jsx/views/ListRow.native.js +72 -12
- package/dist/jsx/views/ListRow.native.js.map +1 -1
- package/dist/jsx/views/Matrix.native.js +2 -2
- package/dist/jsx/views/Matrix.native.js.map +1 -1
- package/dist/jsx/views/ReportBuilder.native.js +2 -2
- package/dist/jsx/views/ReportBuilder.native.js.map +1 -1
- package/dist/jsx/views/ShortcutCard.native.js.map +1 -1
- package/dist/jsx/views/TreeView.native.js.map +1 -1
- package/dist/jsx/views/calendarMath.native.js.map +1 -1
- package/dist/jsx/views/ganttIntervals.native.js.map +1 -1
- package/dist/jsx/views/ganttMath.native.js.map +1 -1
- package/dist/jsx/views/index.mjs +2 -1
- package/dist/jsx/views/index.mjs.map +1 -1
- package/dist/jsx/views/index.native.js +14 -1
- package/dist/jsx/views/index.native.js.map +1 -1
- package/dist/jsx/views/kanbanDnd.native.js.map +1 -1
- package/dist/jsx/views/matrixMath.native.js.map +1 -1
- package/dist/jsx/views/sameNameScope.native.js.map +1 -1
- package/dist/jsx/views/treeViewDnd.native.js.map +1 -1
- package/dist/jsx/views/treeViewLayout.native.js.map +1 -1
- package/dist/jsx/views/treeViewMotion.native.js.map +1 -1
- package/dist/jsx/views/treeViewReveal.native.js.map +1 -1
- package/dist/jsx/views/usePageFlowLoadMore.native.js.map +1 -1
- package/dist/jsx/views/widgetChrome.native.js.map +1 -1
- package/package.json +8 -11
- package/src/Chip/index.tsx +4 -3
- package/src/DrillStack/DrillBar.tsx +87 -0
- package/src/DrillStack/DrillStack.native.spec.tsx +194 -0
- package/src/DrillStack/DrillStack.spec.tsx +200 -0
- package/src/DrillStack/DrillStack.stories.tsx +108 -0
- package/src/DrillStack/context.ts +71 -0
- package/src/DrillStack/drillMotion.ts +59 -0
- package/src/DrillStack/drillSlide.native.ts +11 -0
- package/src/DrillStack/drillSlide.ts +157 -0
- package/src/DrillStack/index.native.tsx +293 -0
- package/src/DrillStack/index.tsx +146 -0
- package/src/DropdownMenu/DropdownMenu.stories.tsx +144 -0
- package/src/DropdownMenu/DropdownMenu.sub.native.spec.tsx +91 -0
- package/src/DropdownMenu/DropdownMenu.sub.spec.tsx +335 -0
- package/src/DropdownMenu/DropdownMenu.triggerSizing.spec.tsx +44 -0
- package/src/DropdownMenu/index.tsx +360 -14
- package/src/Material/blur.native.tsx +7 -1
- package/src/MiddleEllipsisText/MiddleEllipsisText.native.spec.tsx +36 -0
- package/src/MiddleEllipsisText/MiddleEllipsisText.spec.tsx +40 -0
- package/src/MiddleEllipsisText/MiddleEllipsisText.stories.tsx +55 -0
- package/src/MiddleEllipsisText/index.native.tsx +12 -0
- package/src/MiddleEllipsisText/index.tsx +53 -0
- package/src/MiddleEllipsisText/middleSplit.spec.ts +40 -0
- package/src/MiddleEllipsisText/middleSplit.ts +22 -0
- package/src/MiddleEllipsisText/types.ts +11 -0
- package/src/OverflowRow/OverflowRow.native.spec.tsx +10 -0
- package/src/OverflowRow/OverflowRow.stories.tsx +46 -17
- package/src/ScrollView/useRevealFocusedField.native.ts +2 -2
- package/src/SheetModal/SheetModal.elevation.spec.tsx +4 -4
- package/src/SheetModal/SheetModal.fill.spec.tsx +47 -0
- package/src/SheetModal/index.native.tsx +11 -3
- package/src/SheetModal/index.tsx +8 -0
- package/src/SheetScrollView/SheetScrollView.native-press.spec.tsx +58 -0
- package/src/SheetScrollView/SheetScrollView.spec.tsx +292 -0
- package/src/SheetScrollView/SheetScrollView.stories.tsx +99 -0
- package/src/SheetScrollView/index.tsx +399 -0
- package/src/SheetScrollView/sheetDrag.native.ts +15 -0
- package/src/SheetScrollView/sheetDrag.ts +9 -0
- package/src/SheetScrollView/sheetHandoff.spec.ts +357 -0
- package/src/SheetScrollView/sheetHandoff.ts +315 -0
- package/src/Tabs/Tabs.edgeFades.spec.tsx +77 -0
- package/src/Tabs/Tabs.fades.native.spec.tsx +23 -21
- package/src/Tabs/Tabs.measurement.spec.tsx +3 -3
- package/src/Tabs/Tabs.native.spec.tsx +1 -1
- package/src/Tabs/index.tsx +42 -60
- package/src/Tooltip/Tooltip.holdCue.native.spec.tsx +71 -0
- package/src/Tooltip/Tooltip.spec.tsx +1 -1
- package/src/Tooltip/index.native.tsx +6 -1
- package/src/appShell/AppShell.native.spec.tsx +104 -0
- package/src/appShell/AppShell.spec.tsx +49 -0
- package/src/appShell/AppShell.stackBack.native-press.spec.tsx +61 -0
- package/src/appShell/AppShell.stackBack.spec.tsx +112 -0
- package/src/appShell/AppShell.stories.tsx +51 -1
- package/src/appShell/AppShell.tsx +66 -80
- package/src/appShell/MpoTabHost.tsx +6 -0
- package/src/appShell/Springboard.spec.tsx +1 -1
- package/src/appShell/Springboard.tsx +1 -1
- package/src/appShell/SystemBar.phoneWidth.spec.tsx +17 -0
- package/src/appShell/SystemBar.spec.tsx +155 -3
- package/src/appShell/SystemBar.stories.tsx +48 -3
- package/src/appShell/SystemBar.tsx +172 -48
- package/src/appShell/TabHost.native.tsx +4 -2
- package/src/appShell/stackBack.ts +31 -0
- package/src/appShell/systemBarFit.ts +10 -7
- package/src/checkedRow.native-press.spec.tsx +4 -4
- package/src/checkedRow.spec.tsx +2 -2
- package/src/code/CodeBlock/codeBlock.stories.ts +21 -0
- package/src/code/CodeBlock/index.tsx +24 -17
- package/src/code/HoldSelect/holdSelect.spec.tsx +128 -0
- package/src/code/HoldSelect/index.native.tsx +86 -0
- package/src/code/HoldSelect/index.tsx +53 -0
- package/src/code/HoldSelect/tapGate.ts +87 -0
- package/src/code/LogView.follow.spec.tsx +104 -0
- package/src/code/LogView.tsx +29 -4
- package/src/code/PayloadView/PayloadView.spec.tsx +239 -0
- package/src/code/PayloadView/PayloadView.stories.tsx +67 -0
- package/src/code/PayloadView/index.tsx +424 -0
- package/src/code/PayloadView/payloadModel.ts +234 -0
- package/src/code/index.ts +2 -0
- package/src/componentColors.spec.ts +3 -3
- package/src/componentColors.ts +5 -4
- package/src/elevatedGround.spec.tsx +7 -7
- package/src/images/RemoteArt/RemoteArt.native.spec.tsx +118 -0
- package/src/images/RemoteArt/RemoteArt.spec.tsx +32 -0
- package/src/images/RemoteArt/RemoteArt.stories.tsx +61 -0
- package/src/images/RemoteArt/index.native.tsx +50 -0
- package/src/images/RemoteArt/index.tsx +26 -0
- package/src/images/RemoteArt/remoteArtCache.ts +180 -0
- package/src/images/RemoteArt/svgMarkup.spec.ts +54 -0
- package/src/images/RemoteArt/svgMarkup.ts +153 -0
- package/src/images/RemoteArt/types.ts +12 -0
- package/src/images/index.ts +6 -0
- package/src/index.ts +6 -0
- package/src/layouts/AsyncBoundary.reason.spec.tsx +64 -23
- package/src/layouts/AsyncBoundary.stories.tsx +1 -0
- package/src/layouts/AsyncBoundary.tsx +21 -2
- package/src/layouts/Attachments.stories.tsx +69 -1
- package/src/layouts/ScreenToolbar.stories.tsx +54 -1
- package/src/layouts/Sidebar.spec.tsx +6 -1
- package/src/layouts/asyncFailure.spec.ts +28 -13
- package/src/layouts/asyncFailure.ts +17 -19
- package/src/layouts/attachments.tsx +63 -11
- package/src/layouts/heroBarTitle.native-press.spec.tsx +132 -0
- package/src/layouts/page.tsx +136 -16
- package/src/layouts/screenScroll.tsx +21 -14
- package/src/layouts/tags.tsx +2 -1
- package/src/layouts/toolbarLeadingClip.spec.tsx +120 -0
- package/src/overlayElevation.spec.tsx +1 -1
- package/src/overlayGround.spec.tsx +77 -0
- package/src/views/Dashboard.stories.tsx +21 -0
- package/src/views/Dashboard.tsx +34 -7
- package/src/views/FilePreview.tsx +640 -0
- package/src/views/Kanban.spec.tsx +6 -1
- package/src/views/List.selection.spec.tsx +42 -0
- package/src/views/List.spec.tsx +1 -26
- package/src/views/List.tsx +1 -0
- package/src/views/ListGroup.states.spec.tsx +274 -0
- package/src/views/ListGroup.stories.tsx +195 -3
- package/src/views/ListGroup.tsx +368 -31
- package/src/views/ListRow.spec.tsx +146 -0
- package/src/views/ListRow.stories.tsx +111 -0
- package/src/views/ListRow.tsx +91 -7
- package/src/views/ReportBuilder.spec.tsx +9 -4
- package/src/views/TreeView.spec.tsx +6 -1
- package/src/views/dataIdentity.spec.tsx +5 -0
- package/src/views/filePreview.spec.tsx +282 -0
- package/src/views/index.ts +17 -0
- package/src/views/kpiNotMeasured.spec.tsx +56 -0
- package/types/Chip/index.d.ts.map +1 -1
- package/types/DrillStack/DrillBar.d.ts +13 -0
- package/types/DrillStack/DrillBar.d.ts.map +1 -0
- package/types/DrillStack/context.d.ts +34 -0
- package/types/DrillStack/context.d.ts.map +1 -0
- package/types/DrillStack/drillMotion.d.ts +26 -0
- package/types/DrillStack/drillMotion.d.ts.map +1 -0
- package/types/DrillStack/drillSlide.d.ts +23 -0
- package/types/DrillStack/drillSlide.d.ts.map +1 -0
- package/types/DrillStack/drillSlide.native.d.ts +6 -0
- package/types/DrillStack/drillSlide.native.d.ts.map +1 -0
- package/types/DrillStack/index.d.ts +21 -0
- package/types/DrillStack/index.d.ts.map +1 -0
- package/types/DrillStack/index.native.d.ts +25 -0
- package/types/DrillStack/index.native.d.ts.map +1 -0
- package/types/DropdownMenu/index.d.ts +37 -2
- package/types/DropdownMenu/index.d.ts.map +1 -1
- package/types/Material/blur.native.d.ts.map +1 -1
- package/types/MiddleEllipsisText/index.d.ts +5 -0
- package/types/MiddleEllipsisText/index.d.ts.map +1 -0
- package/types/MiddleEllipsisText/index.native.d.ts +4 -0
- package/types/MiddleEllipsisText/index.native.d.ts.map +1 -0
- package/types/MiddleEllipsisText/middleSplit.d.ts +14 -0
- package/types/MiddleEllipsisText/middleSplit.d.ts.map +1 -0
- package/types/MiddleEllipsisText/types.d.ts +8 -0
- package/types/MiddleEllipsisText/types.d.ts.map +1 -0
- package/types/SheetModal/index.d.ts +6 -1
- package/types/SheetModal/index.d.ts.map +1 -1
- package/types/SheetModal/index.native.d.ts +1 -1
- package/types/SheetModal/index.native.d.ts.map +1 -1
- package/types/SheetScrollView/index.d.ts +100 -0
- package/types/SheetScrollView/index.d.ts.map +1 -0
- package/types/SheetScrollView/sheetDrag.d.ts +7 -0
- package/types/SheetScrollView/sheetDrag.d.ts.map +1 -0
- package/types/SheetScrollView/sheetDrag.native.d.ts +3 -0
- package/types/SheetScrollView/sheetDrag.native.d.ts.map +1 -0
- package/types/SheetScrollView/sheetHandoff.d.ts +168 -0
- package/types/SheetScrollView/sheetHandoff.d.ts.map +1 -0
- package/types/Tabs/index.d.ts +9 -1
- package/types/Tabs/index.d.ts.map +1 -1
- package/types/Tooltip/index.native.d.ts.map +1 -1
- package/types/appShell/AppShell.d.ts +5 -1
- package/types/appShell/AppShell.d.ts.map +1 -1
- package/types/appShell/MpoTabHost.d.ts +6 -0
- package/types/appShell/MpoTabHost.d.ts.map +1 -1
- package/types/appShell/Springboard.d.ts.map +1 -1
- package/types/appShell/SystemBar.d.ts +39 -2
- package/types/appShell/SystemBar.d.ts.map +1 -1
- package/types/appShell/TabHost.native.d.ts +1 -1
- package/types/appShell/TabHost.native.d.ts.map +1 -1
- package/types/appShell/stackBack.d.ts +3 -0
- package/types/appShell/stackBack.d.ts.map +1 -0
- package/types/appShell/systemBarFit.d.ts +1 -0
- package/types/appShell/systemBarFit.d.ts.map +1 -1
- package/types/code/CodeBlock/index.d.ts +3 -1
- package/types/code/CodeBlock/index.d.ts.map +1 -1
- package/types/code/HoldSelect/index.d.ts +16 -0
- package/types/code/HoldSelect/index.d.ts.map +1 -0
- package/types/code/HoldSelect/index.native.d.ts +17 -0
- package/types/code/HoldSelect/index.native.d.ts.map +1 -0
- package/types/code/HoldSelect/tapGate.d.ts +41 -0
- package/types/code/HoldSelect/tapGate.d.ts.map +1 -0
- package/types/code/LogView.d.ts +3 -1
- package/types/code/LogView.d.ts.map +1 -1
- package/types/code/PayloadView/index.d.ts +16 -0
- package/types/code/PayloadView/index.d.ts.map +1 -0
- package/types/code/PayloadView/payloadModel.d.ts +80 -0
- package/types/code/PayloadView/payloadModel.d.ts.map +1 -0
- package/types/code/index.d.ts +2 -0
- package/types/code/index.d.ts.map +1 -1
- package/types/componentColors.d.ts +4 -4
- package/types/componentColors.d.ts.map +1 -1
- package/types/images/RemoteArt/index.d.ts +4 -0
- package/types/images/RemoteArt/index.d.ts.map +1 -0
- package/types/images/RemoteArt/index.native.d.ts +4 -0
- package/types/images/RemoteArt/index.native.d.ts.map +1 -0
- package/types/images/RemoteArt/remoteArtCache.d.ts +38 -0
- package/types/images/RemoteArt/remoteArtCache.d.ts.map +1 -0
- package/types/images/RemoteArt/svgMarkup.d.ts +22 -0
- package/types/images/RemoteArt/svgMarkup.d.ts.map +1 -0
- package/types/images/RemoteArt/types.d.ts +12 -0
- package/types/images/RemoteArt/types.d.ts.map +1 -0
- package/types/images/index.d.ts +2 -0
- package/types/images/index.d.ts.map +1 -1
- package/types/index.d.ts +5 -0
- package/types/index.d.ts.map +1 -1
- package/types/layouts/AsyncBoundary.d.ts +3 -1
- package/types/layouts/AsyncBoundary.d.ts.map +1 -1
- package/types/layouts/asyncFailure.d.ts +4 -1
- package/types/layouts/asyncFailure.d.ts.map +1 -1
- package/types/layouts/attachments.d.ts.map +1 -1
- package/types/layouts/page.d.ts.map +1 -1
- package/types/layouts/screenScroll.d.ts +4 -2
- package/types/layouts/screenScroll.d.ts.map +1 -1
- package/types/layouts/tags.d.ts.map +1 -1
- package/types/views/Dashboard.d.ts +7 -1
- package/types/views/Dashboard.d.ts.map +1 -1
- package/types/views/FilePreview.d.ts +62 -0
- package/types/views/FilePreview.d.ts.map +1 -0
- package/types/views/List.d.ts +1 -1
- package/types/views/List.d.ts.map +1 -1
- package/types/views/ListGroup.d.ts +61 -4
- package/types/views/ListGroup.d.ts.map +1 -1
- package/types/views/ListRow.d.ts +37 -2
- package/types/views/ListRow.d.ts.map +1 -1
- package/types/views/index.d.ts +1 -0
- package/types/views/index.d.ts.map +1 -1
- package/dist/cjs/hooks/useHoldCue.cjs +0 -52
- package/dist/cjs/hooks/useHoldCue.native.js +0 -60
- package/dist/cjs/hooks/useHoldCue.native.js.map +0 -1
- package/dist/esm/hooks/useHoldCue.mjs +0 -26
- package/dist/esm/hooks/useHoldCue.mjs.map +0 -1
- package/dist/esm/hooks/useHoldCue.native.js +0 -31
- package/dist/esm/hooks/useHoldCue.native.js.map +0 -1
- package/dist/jsx/hooks/useHoldCue.mjs +0 -26
- package/dist/jsx/hooks/useHoldCue.mjs.map +0 -1
- package/dist/jsx/hooks/useHoldCue.native.js +0 -60
- package/dist/jsx/hooks/useHoldCue.native.js.map +0 -1
- package/src/hooks/useHoldCue.ts +0 -23
- package/types/hooks/useHoldCue.d.ts +0 -8
- package/types/hooks/useHoldCue.d.ts.map +0 -1
|
@@ -0,0 +1,640 @@
|
|
|
1
|
+
import { overlaySizeClass } from "@multiplatform.one/forms";
|
|
2
|
+
import { Surface, useResolvedKnobs } from "@multiplatform.one/theme";
|
|
3
|
+
import {
|
|
4
|
+
CaretRightIcon,
|
|
5
|
+
CopyIcon,
|
|
6
|
+
DownloadSimpleIcon,
|
|
7
|
+
FileCodeIcon,
|
|
8
|
+
FileIcon,
|
|
9
|
+
FileTextIcon,
|
|
10
|
+
ShareNetworkIcon,
|
|
11
|
+
} from "@phosphor-icons/react";
|
|
12
|
+
import { createContext, useContext, useEffect, useMemo, useState, type ReactNode } from "react";
|
|
13
|
+
import { Share } from "react-native";
|
|
14
|
+
import { isWeb, Text, View, VisuallyHidden, XStack, YStack, useWindowDimensions } from "tamagui";
|
|
15
|
+
import { HeaderActions, type HeaderAction } from "../actions/HeaderActions";
|
|
16
|
+
import { OverlayHeader } from "../actions/StandardAction";
|
|
17
|
+
import { type HighlightLine, useShikiTokens } from "../code/Highlighter";
|
|
18
|
+
import { componentColors } from "../componentColors";
|
|
19
|
+
import { ScrollView } from "../ScrollView";
|
|
20
|
+
import { Dialog } from "../Dialog";
|
|
21
|
+
import { useCopyFeedback } from "../feedback/copy";
|
|
22
|
+
import { NotifyRegion } from "../feedback/NotifyHost";
|
|
23
|
+
import { AsyncBoundary } from "../layouts/AsyncBoundary";
|
|
24
|
+
import { useTranslation } from "../shared/i18n";
|
|
25
|
+
import { SheetModal } from "../SheetModal";
|
|
26
|
+
import { DialogContent, DialogOverlay } from "../surfaces";
|
|
27
|
+
import { ListGroupItem } from "./ListGroup";
|
|
28
|
+
import { ListRow, ListRowMeta, listLeadingIconSize } from "./ListRow";
|
|
29
|
+
|
|
30
|
+
export interface PreviewFile {
|
|
31
|
+
name: string;
|
|
32
|
+
path?: string;
|
|
33
|
+
meta?: string;
|
|
34
|
+
/** Text contents. Omitted for a binary, or when `url` is fetched on open. */
|
|
35
|
+
content?: string;
|
|
36
|
+
/** Fetched as text when the viewer opens and `content` is absent. */
|
|
37
|
+
url?: string;
|
|
38
|
+
/** Shiki language for the viewer ("yaml", "json"). Read from the name when omitted. */
|
|
39
|
+
language?: string;
|
|
40
|
+
/** `binary` files never preview. Read from the name and contents when omitted. */
|
|
41
|
+
kind?: "text" | "binary";
|
|
42
|
+
thumbnail?: ReactNode;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
export const FILE_PREVIEW_LINES = 3;
|
|
46
|
+
|
|
47
|
+
const textExtensions = new Set([
|
|
48
|
+
"txt",
|
|
49
|
+
"md",
|
|
50
|
+
"markdown",
|
|
51
|
+
"log",
|
|
52
|
+
"csv",
|
|
53
|
+
"tsv",
|
|
54
|
+
"json",
|
|
55
|
+
"jsonc",
|
|
56
|
+
"yaml",
|
|
57
|
+
"yml",
|
|
58
|
+
"toml",
|
|
59
|
+
"ini",
|
|
60
|
+
"conf",
|
|
61
|
+
"cfg",
|
|
62
|
+
"xml",
|
|
63
|
+
"html",
|
|
64
|
+
"css",
|
|
65
|
+
"js",
|
|
66
|
+
"jsx",
|
|
67
|
+
"mjs",
|
|
68
|
+
"cjs",
|
|
69
|
+
"ts",
|
|
70
|
+
"tsx",
|
|
71
|
+
"py",
|
|
72
|
+
"rb",
|
|
73
|
+
"go",
|
|
74
|
+
"rs",
|
|
75
|
+
"java",
|
|
76
|
+
"kt",
|
|
77
|
+
"swift",
|
|
78
|
+
"c",
|
|
79
|
+
"h",
|
|
80
|
+
"cpp",
|
|
81
|
+
"sh",
|
|
82
|
+
"sql",
|
|
83
|
+
"graphql",
|
|
84
|
+
"dockerfile",
|
|
85
|
+
"makefile",
|
|
86
|
+
]);
|
|
87
|
+
|
|
88
|
+
const languageByExtension: Record<string, string> = {
|
|
89
|
+
yml: "yaml",
|
|
90
|
+
md: "markdown",
|
|
91
|
+
sh: "bash",
|
|
92
|
+
mjs: "javascript",
|
|
93
|
+
cjs: "javascript",
|
|
94
|
+
js: "javascript",
|
|
95
|
+
jsx: "jsx",
|
|
96
|
+
ts: "typescript",
|
|
97
|
+
tsx: "tsx",
|
|
98
|
+
py: "python",
|
|
99
|
+
rb: "ruby",
|
|
100
|
+
rs: "rust",
|
|
101
|
+
kt: "kotlin",
|
|
102
|
+
jsonc: "json",
|
|
103
|
+
};
|
|
104
|
+
|
|
105
|
+
/** A file whose contents are credentials: its row never prints them. */
|
|
106
|
+
const secretNames = [
|
|
107
|
+
/^\.env(\.(?!example$|sample$|template$)[^/]+)?$/i,
|
|
108
|
+
/\.(pem|key|p12|pfx|keystore|jks)$/i,
|
|
109
|
+
/^id_(rsa|dsa|ecdsa|ed25519)(\.pub)?$/i,
|
|
110
|
+
/^\.(npmrc|netrc|pgpass|htpasswd)$/i,
|
|
111
|
+
/^(credentials|secrets?)(\.[a-z]+)?$/i,
|
|
112
|
+
];
|
|
113
|
+
|
|
114
|
+
function baseName(name: string): string {
|
|
115
|
+
return name.slice(name.lastIndexOf("/") + 1);
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
function extensionOf(name: string): string {
|
|
119
|
+
const base = baseName(name).toLowerCase();
|
|
120
|
+
if (base === "dockerfile" || base === "makefile") return base;
|
|
121
|
+
const dot = base.lastIndexOf(".");
|
|
122
|
+
return dot > 0 ? base.slice(dot + 1) : "";
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
export function isSecretFileName(name: string): boolean {
|
|
126
|
+
const base = baseName(name);
|
|
127
|
+
return secretNames.some((pattern) => pattern.test(base));
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
export function isTextFile(file: PreviewFile): boolean {
|
|
131
|
+
if (file.kind) return file.kind === "text";
|
|
132
|
+
if (file.content != null) return !file.content.includes("\u0000");
|
|
133
|
+
return textExtensions.has(extensionOf(file.name)) || isSecretFileName(file.name);
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
/** LC-146 round 109: a row never prints a binary's bytes or a credential. */
|
|
137
|
+
export function filePreviewLines(file: PreviewFile, count = FILE_PREVIEW_LINES): string[] {
|
|
138
|
+
if (!isTextFile(file) || isSecretFileName(file.name) || !file.content) return [];
|
|
139
|
+
const lines = file.content.replace(/\r\n?/g, "\n").split("\n");
|
|
140
|
+
while (lines.length && !lines[lines.length - 1].trim()) lines.pop();
|
|
141
|
+
return lines.slice(0, count);
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
export function fileLanguage(file: PreviewFile): string {
|
|
145
|
+
if (file.language) return file.language;
|
|
146
|
+
const ext = extensionOf(file.name);
|
|
147
|
+
return languageByExtension[ext] ?? (textExtensions.has(ext) ? ext : "text");
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
/** A row opens the viewer only for text it can show: never a binary, a credential or a file with nothing to read. */
|
|
151
|
+
export function isViewableFile(file: PreviewFile): boolean {
|
|
152
|
+
return (
|
|
153
|
+
isTextFile(file) && !isSecretFileName(file.name) && (file.content != null || Boolean(file.url))
|
|
154
|
+
);
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
const proseLanguages = new Set(["text", "txt", "markdown", "log"]);
|
|
158
|
+
|
|
159
|
+
function isProse(file: PreviewFile): boolean {
|
|
160
|
+
return proseLanguages.has(fileLanguage(file));
|
|
161
|
+
}
|
|
162
|
+
|
|
163
|
+
export function fileKey(file: PreviewFile): string {
|
|
164
|
+
return `${file.path ?? file.url ?? ""}/${file.name}`;
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
function FileGlyph({ file }: { file: PreviewFile }) {
|
|
168
|
+
if (!isTextFile(file)) return <FileIcon />;
|
|
169
|
+
return isProse(file) ? <FileTextIcon /> : <FileCodeIcon />;
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
export interface FilePreviewRowProps {
|
|
173
|
+
file: PreviewFile;
|
|
174
|
+
/** Opens the viewer. Omitted: the nearest `FileViewerHost`, else the row's own `FileViewer`. */
|
|
175
|
+
onOpen?: (file: PreviewFile) => void;
|
|
176
|
+
/** The trailing action of a row the viewer cannot show. */
|
|
177
|
+
onDownload?: (file: PreviewFile) => void;
|
|
178
|
+
selected?: boolean;
|
|
179
|
+
lines?: number;
|
|
180
|
+
/** Nesting depth under the row above: each level steps one leading-icon column in. */
|
|
181
|
+
indent?: number;
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
/** LC-146 round 109: one row of its group, never a card inside it (LC-169). */
|
|
185
|
+
export function FilePreviewRow({
|
|
186
|
+
file,
|
|
187
|
+
onOpen,
|
|
188
|
+
onDownload,
|
|
189
|
+
selected,
|
|
190
|
+
lines = FILE_PREVIEW_LINES,
|
|
191
|
+
indent = 0,
|
|
192
|
+
}: FilePreviewRowProps) {
|
|
193
|
+
const { knobProps } = useResolvedKnobs();
|
|
194
|
+
const host = useFileViewerHost();
|
|
195
|
+
const [open, setOpen] = useState(false);
|
|
196
|
+
const preview = filePreviewLines(file, lines);
|
|
197
|
+
const viewable = isViewableFile(file);
|
|
198
|
+
const owned = onOpen == null && host == null;
|
|
199
|
+
const iconSize = listLeadingIconSize(knobProps.sizeToken);
|
|
200
|
+
const caption = knobProps.textRole.caption;
|
|
201
|
+
let press: (() => void) | undefined;
|
|
202
|
+
if (viewable) press = () => (onOpen ? onOpen(file) : host ? host.open(file) : setOpen(true));
|
|
203
|
+
else if (onDownload) press = () => onDownload(file);
|
|
204
|
+
const hostSelected = host?.file != null && fileKey(host.file) === fileKey(file);
|
|
205
|
+
const trailing = viewable ? CaretRightIcon : onDownload ? DownloadSimpleIcon : null;
|
|
206
|
+
const TrailingIcon = trailing;
|
|
207
|
+
return (
|
|
208
|
+
<>
|
|
209
|
+
<ListGroupItem
|
|
210
|
+
onPress={press}
|
|
211
|
+
selected={selected ?? (hostSelected || (owned && open))}
|
|
212
|
+
aria-label={file.meta ? `${file.name}, ${file.meta}` : file.name}
|
|
213
|
+
{...({
|
|
214
|
+
"data-file-row": preview.length ? "preview" : "plain",
|
|
215
|
+
"data-file-action": viewable ? "view" : onDownload ? "download" : "none",
|
|
216
|
+
} as Record<string, unknown>)}
|
|
217
|
+
>
|
|
218
|
+
{Array.from({ length: indent }, (_, level) => (
|
|
219
|
+
<View key={level} flexShrink={0} width={iconSize} />
|
|
220
|
+
))}
|
|
221
|
+
<YStack flex={1} minWidth={0} gap="$1">
|
|
222
|
+
<XStack>
|
|
223
|
+
<ListRow
|
|
224
|
+
{...(file.thumbnail
|
|
225
|
+
? { media: file.thumbnail }
|
|
226
|
+
: { icon: <FileGlyph file={file} /> })}
|
|
227
|
+
title={file.name}
|
|
228
|
+
subtitle={file.meta}
|
|
229
|
+
/>
|
|
230
|
+
</XStack>
|
|
231
|
+
{preview.length ? (
|
|
232
|
+
<XStack {...knobProps.gap} paddingBottom="$1">
|
|
233
|
+
<View flexShrink={0} width={file.thumbnail ? "$true" : iconSize} />
|
|
234
|
+
<YStack
|
|
235
|
+
aria-hidden
|
|
236
|
+
flex={1}
|
|
237
|
+
minWidth={0}
|
|
238
|
+
backgroundColor="$backgroundPress"
|
|
239
|
+
borderRadius={knobProps.borderRadius.borderRadius}
|
|
240
|
+
borderWidth={0}
|
|
241
|
+
paddingHorizontal="$3"
|
|
242
|
+
paddingVertical="$2"
|
|
243
|
+
overflow="hidden"
|
|
244
|
+
{...({ "data-file-preview": "", "data-code-well": "" } as Record<string, unknown>)}
|
|
245
|
+
>
|
|
246
|
+
{preview.map((line, index) => (
|
|
247
|
+
<Text
|
|
248
|
+
key={index}
|
|
249
|
+
fontFamily="$mono"
|
|
250
|
+
letterSpacing={0}
|
|
251
|
+
fontSize={caption.fontSize}
|
|
252
|
+
lineHeight={caption.lineHeight}
|
|
253
|
+
color={caption.color}
|
|
254
|
+
numberOfLines={1}
|
|
255
|
+
whiteSpace="pre"
|
|
256
|
+
userSelect="none"
|
|
257
|
+
{...({ "data-preview-line": "" } as Record<string, unknown>)}
|
|
258
|
+
>
|
|
259
|
+
{line || " "}
|
|
260
|
+
</Text>
|
|
261
|
+
))}
|
|
262
|
+
</YStack>
|
|
263
|
+
</XStack>
|
|
264
|
+
) : null}
|
|
265
|
+
</YStack>
|
|
266
|
+
{TrailingIcon ? (
|
|
267
|
+
<ListRowMeta>
|
|
268
|
+
<TrailingIcon size={14} aria-hidden />
|
|
269
|
+
</ListRowMeta>
|
|
270
|
+
) : null}
|
|
271
|
+
</ListGroupItem>
|
|
272
|
+
{owned && viewable ? <FileViewer file={file} open={open} onOpenChange={setOpen} /> : null}
|
|
273
|
+
</>
|
|
274
|
+
);
|
|
275
|
+
}
|
|
276
|
+
|
|
277
|
+
function useFileText(file: PreviewFile | null, open: boolean) {
|
|
278
|
+
const [state, setState] = useState<{ text?: string; error?: string; loading: boolean }>({
|
|
279
|
+
loading: false,
|
|
280
|
+
});
|
|
281
|
+
const url = file?.content == null ? file?.url : undefined;
|
|
282
|
+
useEffect(() => {
|
|
283
|
+
if (!open || !url) return;
|
|
284
|
+
let live = true;
|
|
285
|
+
setState({ loading: true });
|
|
286
|
+
fetch(url)
|
|
287
|
+
.then((response) => {
|
|
288
|
+
if (!response.ok) throw new Error(String(response.status));
|
|
289
|
+
return response.text();
|
|
290
|
+
})
|
|
291
|
+
.then((text) => live && setState({ text, loading: false }))
|
|
292
|
+
.catch((error: unknown) => live && setState({ error: String(error), loading: false }));
|
|
293
|
+
return () => {
|
|
294
|
+
live = false;
|
|
295
|
+
};
|
|
296
|
+
}, [open, url]);
|
|
297
|
+
if (!file) return { loading: false };
|
|
298
|
+
if (file.content != null) return { text: file.content, loading: false };
|
|
299
|
+
return state;
|
|
300
|
+
}
|
|
301
|
+
|
|
302
|
+
/** Desktop browsers without the Web Share API save the file instead. */
|
|
303
|
+
function shareFile(file: PreviewFile, text: string) {
|
|
304
|
+
if (isWeb && (typeof navigator === "undefined" || typeof navigator.share !== "function")) {
|
|
305
|
+
const href = URL.createObjectURL(new Blob([text], { type: "text/plain" }));
|
|
306
|
+
const link = document.createElement("a");
|
|
307
|
+
link.href = href;
|
|
308
|
+
link.download = file.name;
|
|
309
|
+
link.click();
|
|
310
|
+
URL.revokeObjectURL(href);
|
|
311
|
+
return;
|
|
312
|
+
}
|
|
313
|
+
void Share.share({ title: file.name, message: text }).catch(() => {});
|
|
314
|
+
}
|
|
315
|
+
|
|
316
|
+
/** Slash, colon and comma become break points so a long path wraps between segments. */
|
|
317
|
+
function withBreaks(content: string): ReactNode {
|
|
318
|
+
if (!isWeb || !/[/:,=&?]/.test(content)) return content;
|
|
319
|
+
const pieces = content.split(/([/:,=&?])/);
|
|
320
|
+
const parts: string[] = [];
|
|
321
|
+
for (let index = 0; index < pieces.length; index += 2)
|
|
322
|
+
parts.push(pieces[index] + (pieces[index + 1] ?? ""));
|
|
323
|
+
return parts.map((part, index) => (
|
|
324
|
+
<span key={index}>
|
|
325
|
+
{part}
|
|
326
|
+
{index < parts.length - 1 ? <wbr /> : null}
|
|
327
|
+
</span>
|
|
328
|
+
));
|
|
329
|
+
}
|
|
330
|
+
|
|
331
|
+
function FileBody({ file, text }: { file: PreviewFile; text: string }) {
|
|
332
|
+
const { knobProps } = useResolvedKnobs();
|
|
333
|
+
const source = text.replace(/\n+$/, "");
|
|
334
|
+
const tokens = useShikiTokens(source, fileLanguage(file));
|
|
335
|
+
const lines: HighlightLine[] = tokens ?? source.split("\n").map((content) => [{ content }]);
|
|
336
|
+
const numbered = !isProse(file);
|
|
337
|
+
const digits = String(lines.length).length;
|
|
338
|
+
const mono = {
|
|
339
|
+
fontFamily: "$mono",
|
|
340
|
+
letterSpacing: 0,
|
|
341
|
+
fontSize: knobProps.sizeToken,
|
|
342
|
+
} as const;
|
|
343
|
+
return (
|
|
344
|
+
<YStack
|
|
345
|
+
{...knobProps.panelPadding}
|
|
346
|
+
{...({ "data-register": "code" } as Record<string, unknown>)}
|
|
347
|
+
>
|
|
348
|
+
{lines.map((line, index) => (
|
|
349
|
+
<XStack key={index} gap="$4" {...({ "data-code-line": "" } as Record<string, unknown>)}>
|
|
350
|
+
{numbered ? (
|
|
351
|
+
<Text
|
|
352
|
+
{...mono}
|
|
353
|
+
color={knobProps.textRole.caption.color}
|
|
354
|
+
whiteSpace="pre"
|
|
355
|
+
flexShrink={0}
|
|
356
|
+
userSelect="none"
|
|
357
|
+
{...({ "data-line-number": "" } as Record<string, unknown>)}
|
|
358
|
+
>
|
|
359
|
+
{String(index + 1).padStart(digits, " ")}
|
|
360
|
+
</Text>
|
|
361
|
+
) : null}
|
|
362
|
+
<Text
|
|
363
|
+
{...mono}
|
|
364
|
+
flex={1}
|
|
365
|
+
minWidth={0}
|
|
366
|
+
color={knobProps.textRole.headline.color}
|
|
367
|
+
whiteSpace="pre-wrap"
|
|
368
|
+
{...(isWeb ? { style: { overflowWrap: "anywhere" } as never } : null)}
|
|
369
|
+
>
|
|
370
|
+
{line.some((token) => token.content.length)
|
|
371
|
+
? line.map((token, tokenIndex) => (
|
|
372
|
+
<Text
|
|
373
|
+
key={tokenIndex}
|
|
374
|
+
{...mono}
|
|
375
|
+
color={token.color}
|
|
376
|
+
{...(token.fontStyle && token.fontStyle & 1 ? { fontStyle: "italic" } : null)}
|
|
377
|
+
{...(token.fontStyle && token.fontStyle & 2 ? { fontWeight: "bold" } : null)}
|
|
378
|
+
>
|
|
379
|
+
{withBreaks(token.content)}
|
|
380
|
+
</Text>
|
|
381
|
+
))
|
|
382
|
+
: " "}
|
|
383
|
+
</Text>
|
|
384
|
+
</XStack>
|
|
385
|
+
))}
|
|
386
|
+
</YStack>
|
|
387
|
+
);
|
|
388
|
+
}
|
|
389
|
+
|
|
390
|
+
function useFileViewerParts(file: PreviewFile | null, open: boolean, onClose: () => void) {
|
|
391
|
+
const { t } = useTranslation();
|
|
392
|
+
const { knobProps } = useResolvedKnobs();
|
|
393
|
+
const { region, copy } = useCopyFeedback();
|
|
394
|
+
const { text, error, loading } = useFileText(file, open);
|
|
395
|
+
|
|
396
|
+
const actions = useMemo<HeaderAction[]>(() => {
|
|
397
|
+
if (!file || text == null) return [];
|
|
398
|
+
return [
|
|
399
|
+
{ key: "copy", icon: CopyIcon, label: t("Copy"), onPress: () => void copy(text) },
|
|
400
|
+
{
|
|
401
|
+
key: "share",
|
|
402
|
+
icon: ShareNetworkIcon,
|
|
403
|
+
label: t("Share"),
|
|
404
|
+
onPress: () => shareFile(file, text),
|
|
405
|
+
},
|
|
406
|
+
];
|
|
407
|
+
}, [copy, file, t, text]);
|
|
408
|
+
|
|
409
|
+
if (!file) return null;
|
|
410
|
+
const title = (
|
|
411
|
+
<YStack flex={1} minWidth={0}>
|
|
412
|
+
<Text role="heading" numberOfLines={1} {...knobProps.heading}>
|
|
413
|
+
{file.name}
|
|
414
|
+
</Text>
|
|
415
|
+
{file.path ? (
|
|
416
|
+
<Text numberOfLines={1} {...knobProps.textRole.caption}>
|
|
417
|
+
{file.path}
|
|
418
|
+
</Text>
|
|
419
|
+
) : null}
|
|
420
|
+
</YStack>
|
|
421
|
+
);
|
|
422
|
+
const header = (
|
|
423
|
+
<OverlayHeader
|
|
424
|
+
title={title}
|
|
425
|
+
onClose={onClose}
|
|
426
|
+
testID="file-viewer"
|
|
427
|
+
actions={actions.length ? <HeaderActions actions={actions} /> : null}
|
|
428
|
+
/>
|
|
429
|
+
);
|
|
430
|
+
const body = (
|
|
431
|
+
<AsyncBoundary
|
|
432
|
+
loading={loading}
|
|
433
|
+
error={error ? t("Couldn't load this file") : null}
|
|
434
|
+
empty={!loading && !error && text === ""}
|
|
435
|
+
emptyTitle={t("Empty file")}
|
|
436
|
+
>
|
|
437
|
+
{text != null && isTextFile(file) ? (
|
|
438
|
+
<FileBody file={file} text={text} />
|
|
439
|
+
) : (
|
|
440
|
+
<YStack {...knobProps.panelPadding} alignItems="center" gap="$2">
|
|
441
|
+
<FileIcon size={40} aria-hidden />
|
|
442
|
+
<Text {...knobProps.textRole.caption}>{file.meta ?? file.name}</Text>
|
|
443
|
+
</YStack>
|
|
444
|
+
)}
|
|
445
|
+
</AsyncBoundary>
|
|
446
|
+
);
|
|
447
|
+
return { header, body, region };
|
|
448
|
+
}
|
|
449
|
+
|
|
450
|
+
export interface FileViewerProps {
|
|
451
|
+
file: PreviewFile | null;
|
|
452
|
+
open: boolean;
|
|
453
|
+
onOpenChange: (open: boolean) => void;
|
|
454
|
+
}
|
|
455
|
+
|
|
456
|
+
/** LC-146 round 109: a full-height sheet at compact width, a trailing drawer at regular width. */
|
|
457
|
+
export function FileViewer({ file, open, onOpenChange }: FileViewerProps) {
|
|
458
|
+
const { width } = useWindowDimensions();
|
|
459
|
+
const sizeClass = overlaySizeClass(width);
|
|
460
|
+
const close = () => onOpenChange(false);
|
|
461
|
+
const parts = useFileViewerParts(file, open, close);
|
|
462
|
+
if (!file || !parts) return null;
|
|
463
|
+
const { header, body, region } = parts;
|
|
464
|
+
|
|
465
|
+
if (!isWeb || sizeClass === "compact") {
|
|
466
|
+
return (
|
|
467
|
+
<SheetModal
|
|
468
|
+
open={open}
|
|
469
|
+
onOpenChange={onOpenChange}
|
|
470
|
+
header={header}
|
|
471
|
+
fill
|
|
472
|
+
flush
|
|
473
|
+
snapPoint={isWeb ? 100 : 94}
|
|
474
|
+
>
|
|
475
|
+
<View
|
|
476
|
+
testID="file-viewer-body"
|
|
477
|
+
flex={1}
|
|
478
|
+
minHeight={0}
|
|
479
|
+
backgroundColor={componentColors.code.background}
|
|
480
|
+
{...({ "data-file-viewer": "sheet" } as Record<string, unknown>)}
|
|
481
|
+
>
|
|
482
|
+
<ScrollView flex={1}>{body}</ScrollView>
|
|
483
|
+
</View>
|
|
484
|
+
<NotifyRegion scope="field" region={region} size="$3" />
|
|
485
|
+
</SheetModal>
|
|
486
|
+
);
|
|
487
|
+
}
|
|
488
|
+
|
|
489
|
+
const panelWidth = Math.round(Math.min(Math.max(width * 0.5, 480), 880));
|
|
490
|
+
return (
|
|
491
|
+
<Dialog modal open={open} onOpenChange={onOpenChange}>
|
|
492
|
+
<Dialog.Portal>
|
|
493
|
+
<DialogOverlay key="overlay" opacity={0.3} onPress={close} />
|
|
494
|
+
<DialogContent
|
|
495
|
+
key="content"
|
|
496
|
+
position="fixed"
|
|
497
|
+
top={0}
|
|
498
|
+
bottom={0}
|
|
499
|
+
right={0}
|
|
500
|
+
width={panelWidth}
|
|
501
|
+
height="100%"
|
|
502
|
+
maxHeight="100%"
|
|
503
|
+
margin={0}
|
|
504
|
+
padding={0}
|
|
505
|
+
gap={0}
|
|
506
|
+
x={0}
|
|
507
|
+
y={0}
|
|
508
|
+
borderTopRightRadius={0}
|
|
509
|
+
borderBottomRightRadius={0}
|
|
510
|
+
aria-label={file.name}
|
|
511
|
+
{...({ "data-file-viewer": "drawer", "data-panel-width": panelWidth } as Record<
|
|
512
|
+
string,
|
|
513
|
+
unknown
|
|
514
|
+
>)}
|
|
515
|
+
>
|
|
516
|
+
<VisuallyHidden>
|
|
517
|
+
<Dialog.Title>{file.name}</Dialog.Title>
|
|
518
|
+
</VisuallyHidden>
|
|
519
|
+
<FilePanelChrome header={header} body={body} region={region} />
|
|
520
|
+
</DialogContent>
|
|
521
|
+
</Dialog.Portal>
|
|
522
|
+
</Dialog>
|
|
523
|
+
);
|
|
524
|
+
}
|
|
525
|
+
|
|
526
|
+
function FilePanelChrome({
|
|
527
|
+
header,
|
|
528
|
+
body,
|
|
529
|
+
region,
|
|
530
|
+
}: {
|
|
531
|
+
header: ReactNode;
|
|
532
|
+
body: ReactNode;
|
|
533
|
+
region: ReturnType<typeof useCopyFeedback>["region"];
|
|
534
|
+
}) {
|
|
535
|
+
const { knobProps } = useResolvedKnobs();
|
|
536
|
+
return (
|
|
537
|
+
<>
|
|
538
|
+
<XStack
|
|
539
|
+
{...knobProps.panelPadding}
|
|
540
|
+
borderBottomWidth={1}
|
|
541
|
+
borderColor={componentColors.surface.border}
|
|
542
|
+
>
|
|
543
|
+
<Surface bar>{header}</Surface>
|
|
544
|
+
</XStack>
|
|
545
|
+
<ScrollView
|
|
546
|
+
testID="file-viewer-body"
|
|
547
|
+
flex={1}
|
|
548
|
+
backgroundColor={componentColors.code.background}
|
|
549
|
+
>
|
|
550
|
+
{body}
|
|
551
|
+
</ScrollView>
|
|
552
|
+
<NotifyRegion scope="field" region={region} size="$3" />
|
|
553
|
+
</>
|
|
554
|
+
);
|
|
555
|
+
}
|
|
556
|
+
|
|
557
|
+
interface FileViewerHostValue {
|
|
558
|
+
file: PreviewFile | null;
|
|
559
|
+
open: (file: PreviewFile) => void;
|
|
560
|
+
close: () => void;
|
|
561
|
+
}
|
|
562
|
+
|
|
563
|
+
const FileViewerHostContext = createContext<FileViewerHostValue | null>(null);
|
|
564
|
+
|
|
565
|
+
export function useFileViewerHost(): FileViewerHostValue | null {
|
|
566
|
+
return useContext(FileViewerHostContext);
|
|
567
|
+
}
|
|
568
|
+
|
|
569
|
+
/** The list column's share of a regular window while a file is open beside it. */
|
|
570
|
+
export function fileListColumnWidth(width: number): number {
|
|
571
|
+
return Math.round(Math.min(Math.max(width * 0.36, 360), 560));
|
|
572
|
+
}
|
|
573
|
+
|
|
574
|
+
function FilePanel({ file, onClose }: { file: PreviewFile; onClose: () => void }) {
|
|
575
|
+
const parts = useFileViewerParts(file, true, onClose);
|
|
576
|
+
if (!parts) return null;
|
|
577
|
+
return (
|
|
578
|
+
<YStack
|
|
579
|
+
flex={1}
|
|
580
|
+
minWidth={0}
|
|
581
|
+
minHeight={0}
|
|
582
|
+
borderLeftWidth={1}
|
|
583
|
+
borderColor={componentColors.surface.border}
|
|
584
|
+
backgroundColor={componentColors.surface.background}
|
|
585
|
+
role="region"
|
|
586
|
+
aria-label={file.name}
|
|
587
|
+
{...({ "data-file-viewer": "panel" } as Record<string, unknown>)}
|
|
588
|
+
>
|
|
589
|
+
<FilePanelChrome {...parts} />
|
|
590
|
+
</YStack>
|
|
591
|
+
);
|
|
592
|
+
}
|
|
593
|
+
|
|
594
|
+
/**
|
|
595
|
+
* LC-146 round 109: owns the open file for every row under it. At regular web
|
|
596
|
+
* width the file opens in a panel beside the list, which narrows to a capped
|
|
597
|
+
* column and stays usable; at compact width it opens in the full-height sheet.
|
|
598
|
+
*/
|
|
599
|
+
export function FileViewerHost({ children }: { children: ReactNode }) {
|
|
600
|
+
const { width } = useWindowDimensions();
|
|
601
|
+
const inline = isWeb && overlaySizeClass(width) === "regular";
|
|
602
|
+
const [file, setFile] = useState<PreviewFile | null>(null);
|
|
603
|
+
const value = useMemo<FileViewerHostValue>(
|
|
604
|
+
() => ({ file, open: setFile, close: () => setFile(null) }),
|
|
605
|
+
[file],
|
|
606
|
+
);
|
|
607
|
+
const listWidth = fileListColumnWidth(width);
|
|
608
|
+
return (
|
|
609
|
+
<FileViewerHostContext.Provider value={value}>
|
|
610
|
+
<XStack
|
|
611
|
+
flex={1}
|
|
612
|
+
minHeight={0}
|
|
613
|
+
width="100%"
|
|
614
|
+
{...({ "data-file-viewer-host": inline && file ? "split" : "single" } as Record<
|
|
615
|
+
string,
|
|
616
|
+
unknown
|
|
617
|
+
>)}
|
|
618
|
+
>
|
|
619
|
+
<YStack
|
|
620
|
+
minWidth={0}
|
|
621
|
+
minHeight={0}
|
|
622
|
+
{...(inline && file
|
|
623
|
+
? { width: listWidth, flexShrink: 0 }
|
|
624
|
+
: { flexGrow: 1, flexShrink: 1, flexBasis: "auto" })}
|
|
625
|
+
{...({ "data-file-list-column": "" } as Record<string, unknown>)}
|
|
626
|
+
>
|
|
627
|
+
{children}
|
|
628
|
+
</YStack>
|
|
629
|
+
{inline && file ? <FilePanel file={file} onClose={value.close} /> : null}
|
|
630
|
+
</XStack>
|
|
631
|
+
{inline ? null : (
|
|
632
|
+
<FileViewer
|
|
633
|
+
file={file}
|
|
634
|
+
open={file != null}
|
|
635
|
+
onOpenChange={(next) => !next && setFile(null)}
|
|
636
|
+
/>
|
|
637
|
+
)}
|
|
638
|
+
</FileViewerHostContext.Provider>
|
|
639
|
+
);
|
|
640
|
+
}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { createDefaultThemeConfig } from "@multiplatform.one/theme";
|
|
1
2
|
import { cleanup, fireEvent, screen } from "@testing-library/react";
|
|
2
3
|
import { renderWithProviders } from "@multiplatform.one/test-utils";
|
|
3
4
|
import { Preset } from "@multiplatform.one/theme";
|
|
@@ -5,6 +6,10 @@ import { afterEach, describe, expect, it, vi } from "vitest";
|
|
|
5
6
|
import * as KanbanModule from "./Kanban";
|
|
6
7
|
import { Kanban, type KanbanColumn } from "./Kanban";
|
|
7
8
|
|
|
9
|
+
// LC-05: the selection fills are `$selectFill` / `$selectPress`, keys only
|
|
10
|
+
// MPO's themes define (FZ-8400), so these render under MPO's own config.
|
|
11
|
+
createDefaultThemeConfig({});
|
|
12
|
+
|
|
8
13
|
vi.mock("@tanstack/react-virtual", () => ({
|
|
9
14
|
useVirtualizer: (opts: { count: number; estimateSize: () => number }) => {
|
|
10
15
|
const size = opts.estimateSize();
|
|
@@ -68,7 +73,7 @@ describe("Kanban design law (SB-M-302 / LC-60)", () => {
|
|
|
68
73
|
const card = result.getByText("Task 1").closest("[data-kanban-card]")!;
|
|
69
74
|
fireEvent.click(card);
|
|
70
75
|
expect(card).toHaveAttribute("data-kanban-focused", "true");
|
|
71
|
-
expect(card.className).toContain("_bg-
|
|
76
|
+
expect(card.className).toContain("_bg-selectFill");
|
|
72
77
|
});
|
|
73
78
|
it("declares the column status dot as R-PILL and paints it only when color is set", () => {
|
|
74
79
|
const { container } = renderWithProviders(
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { cleanup, fireEvent, screen } from "@testing-library/react";
|
|
2
|
+
import { renderWithProviders } from "@multiplatform.one/test-utils";
|
|
3
|
+
import { createDefaultThemeConfig } from "@multiplatform.one/theme";
|
|
4
|
+
import { afterEach, describe, expect, it } from "vitest";
|
|
5
|
+
import { List, ListRow } from "./List";
|
|
6
|
+
import { componentColors } from "../componentColors";
|
|
7
|
+
|
|
8
|
+
// LC-05: the selection fills are `$selectFill` / `$selectPress`, keys only
|
|
9
|
+
// MPO's themes define (FZ-8400), so this renders under MPO's own config.
|
|
10
|
+
createDefaultThemeConfig({});
|
|
11
|
+
|
|
12
|
+
afterEach(cleanup);
|
|
13
|
+
|
|
14
|
+
const documents = [
|
|
15
|
+
{ id: "1", title: "Q3 Vendor Contract" },
|
|
16
|
+
{ id: "2", title: "Onboarding Checklist" },
|
|
17
|
+
{ id: "3", title: "Invoice 1842" },
|
|
18
|
+
];
|
|
19
|
+
|
|
20
|
+
describe("List keyboard selection chrome (LC-71)", () => {
|
|
21
|
+
it("marks the filled row data-selected and the keyboard row data-focused", () => {
|
|
22
|
+
renderWithProviders(
|
|
23
|
+
<List
|
|
24
|
+
items={documents}
|
|
25
|
+
aria-label="Documents"
|
|
26
|
+
renderItem={(item) => <ListRow title={item.title} />}
|
|
27
|
+
height={300}
|
|
28
|
+
estimateSize={50}
|
|
29
|
+
/>,
|
|
30
|
+
);
|
|
31
|
+
const container = screen.getByRole("list");
|
|
32
|
+
fireEvent.keyDown(container, { key: "ArrowDown" });
|
|
33
|
+
const focused = container.querySelector("[data-focused]");
|
|
34
|
+
expect(focused).not.toBeNull();
|
|
35
|
+
expect(focused).toHaveAttribute("data-selected");
|
|
36
|
+
expect(focused!.textContent).toContain("Q3 Vendor Contract");
|
|
37
|
+
expect(focused!.className).toContain(`_bg-${componentColors.selection.background.slice(1)}`);
|
|
38
|
+
expect(screen.getByText("Q3 Vendor Contract").className).toContain(
|
|
39
|
+
`_col-${componentColors.selection.ink.slice(1)}`,
|
|
40
|
+
);
|
|
41
|
+
});
|
|
42
|
+
});
|