@kanso-labs/react-native-kanso-ui 0.9.0 → 0.11.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 +4 -3
- package/dist/autocomplete/index.js +15 -1
- package/dist/autocomplete/index.js.map +1 -1
- package/dist/button/group.d.ts +5 -0
- package/dist/button/group.js +115 -0
- package/dist/button/group.js.map +1 -0
- package/dist/button/index.d.ts +4 -1
- package/dist/button/index.js +44 -22
- package/dist/button/index.js.map +1 -1
- package/dist/button/slots.js +2 -1
- package/dist/button/slots.js.map +1 -1
- package/dist/calendar/index.js +351 -182
- package/dist/calendar/index.js.map +1 -1
- package/dist/calendar/styles.js +33 -2
- package/dist/calendar/styles.js.map +1 -1
- package/dist/carousel/arrangement.d.ts +5 -0
- package/dist/carousel/arrangement.js +123 -0
- package/dist/carousel/arrangement.js.map +1 -0
- package/dist/chequer/index.js +95 -0
- package/dist/chequer/index.js.map +1 -0
- package/dist/collection/index.d.ts +157 -0
- package/dist/collection/index.js +1358 -0
- package/dist/collection/index.js.map +1 -0
- package/dist/color-thumb/index.js +56 -0
- package/dist/color-thumb/index.js.map +1 -0
- package/dist/components/button/index.d.ts +4 -2
- package/dist/components/button/index.js +227 -188
- package/dist/components/button/index.js.map +1 -1
- package/dist/components/button-group/index.d.ts +87 -0
- package/dist/components/button-group/index.js +275 -0
- package/dist/components/button-group/index.js.map +1 -0
- package/dist/components/calendar/index.d.ts +11 -3
- package/dist/components/calendar/index.js +60 -45
- package/dist/components/calendar/index.js.map +1 -1
- package/dist/components/carousel/index.d.ts +72 -0
- package/dist/components/carousel/index.js +496 -0
- package/dist/components/carousel/index.js.map +1 -0
- package/dist/components/checkbox-group/index.d.ts +3 -4
- package/dist/components/checkbox-group/index.js +1 -1
- package/dist/components/checkbox-group/index.js.map +1 -1
- package/dist/components/chip/index.d.ts +4 -1
- package/dist/components/chip/index.js +229 -161
- package/dist/components/chip/index.js.map +1 -1
- package/dist/components/color-area/index.d.ts +85 -0
- package/dist/components/color-area/index.js +630 -0
- package/dist/components/color-area/index.js.map +1 -0
- package/dist/components/color-field/index.d.ts +144 -0
- package/dist/components/color-field/index.js +516 -0
- package/dist/components/color-field/index.js.map +1 -0
- package/dist/components/color-picker/index.d.ts +74 -0
- package/dist/components/color-picker/index.js +317 -0
- package/dist/components/color-picker/index.js.map +1 -0
- package/dist/components/color-slider/index.d.ts +82 -0
- package/dist/components/color-slider/index.js +456 -0
- package/dist/components/color-slider/index.js.map +1 -0
- package/dist/components/color-swatch/index.d.ts +46 -0
- package/dist/components/color-swatch/index.js +127 -0
- package/dist/components/color-swatch/index.js.map +1 -0
- package/dist/components/color-swatch-picker/index.d.ts +81 -0
- package/dist/components/color-swatch-picker/index.js +287 -0
- package/dist/components/color-swatch-picker/index.js.map +1 -0
- package/dist/components/color-wheel/index.d.ts +71 -0
- package/dist/components/color-wheel/index.js +407 -0
- package/dist/components/color-wheel/index.js.map +1 -0
- package/dist/components/combo-box/index.d.ts +193 -0
- package/dist/components/combo-box/index.js +616 -0
- package/dist/components/combo-box/index.js.map +1 -0
- package/dist/components/date-field/index.d.ts +120 -0
- package/dist/components/date-field/index.js +111 -0
- package/dist/components/date-field/index.js.map +1 -0
- package/dist/components/date-picker/index.d.ts +130 -0
- package/dist/components/date-picker/index.js +310 -0
- package/dist/components/date-picker/index.js.map +1 -0
- package/dist/components/date-range-picker/index.d.ts +139 -0
- package/dist/components/date-range-picker/index.js +421 -0
- package/dist/components/date-range-picker/index.js.map +1 -0
- package/dist/components/dialog/index.d.ts +5 -5
- package/dist/components/dialog/index.js +5 -5
- package/dist/components/dialog/index.js.map +1 -1
- package/dist/components/disclosure/index.d.ts +94 -0
- package/dist/components/disclosure/index.js +365 -0
- package/dist/components/disclosure/index.js.map +1 -0
- package/dist/components/disclosure-group/index.d.ts +61 -0
- package/dist/components/disclosure-group/index.js +100 -0
- package/dist/components/disclosure-group/index.js.map +1 -0
- package/dist/components/drop-zone/index.d.ts +113 -0
- package/dist/components/drop-zone/index.js +304 -0
- package/dist/components/drop-zone/index.js.map +1 -0
- package/dist/components/fab/index.d.ts +1 -1
- package/dist/components/fab/index.js +91 -76
- package/dist/components/fab/index.js.map +1 -1
- package/dist/components/form/index.d.ts +3 -2
- package/dist/components/form/index.js.map +1 -1
- package/dist/components/icon-button/index.d.ts +4 -2
- package/dist/components/icon-button/index.js +204 -171
- package/dist/components/icon-button/index.js.map +1 -1
- package/dist/components/list/index.d.ts +15 -158
- package/dist/components/list/index.js +21 -1047
- package/dist/components/list/index.js.map +1 -1
- package/dist/components/list-box/index.d.ts +73 -0
- package/dist/components/list-box/index.js +82 -0
- package/dist/components/list-box/index.js.map +1 -0
- package/dist/components/loading-indicator/index.d.ts +32 -0
- package/dist/components/loading-indicator/index.js +174 -0
- package/dist/components/loading-indicator/index.js.map +1 -0
- package/dist/components/menu/index.d.ts +3 -3
- package/dist/components/menu/index.js +3 -3
- package/dist/components/menu/index.js.map +1 -1
- package/dist/components/navigation-tree/index.d.ts +117 -0
- package/dist/components/navigation-tree/index.js +135 -0
- package/dist/components/navigation-tree/index.js.map +1 -0
- package/dist/components/number-field/index.js +132 -143
- package/dist/components/number-field/index.js.map +1 -1
- package/dist/components/popover/index.d.ts +2 -2
- package/dist/components/popover/index.js +2 -2
- package/dist/components/popover/index.js.map +1 -1
- package/dist/components/range-calendar/index.d.ts +69 -0
- package/dist/components/range-calendar/index.js +144 -0
- package/dist/components/range-calendar/index.js.map +1 -0
- package/dist/components/search-view/index.d.ts +79 -0
- package/dist/components/search-view/index.js +571 -0
- package/dist/components/search-view/index.js.map +1 -0
- package/dist/components/select/index.d.ts +152 -0
- package/dist/components/select/index.js +419 -0
- package/dist/components/select/index.js.map +1 -0
- package/dist/components/sheet/index.d.ts +16 -7
- package/dist/components/sheet/index.js +157 -152
- package/dist/components/sheet/index.js.map +1 -1
- package/dist/components/slider/index.d.ts +111 -0
- package/dist/components/slider/index.js +673 -0
- package/dist/components/slider/index.js.map +1 -0
- package/dist/components/split-button/index.d.ts +77 -0
- package/dist/components/split-button/index.js +354 -0
- package/dist/components/split-button/index.js.map +1 -0
- package/dist/components/table/index.d.ts +391 -0
- package/dist/components/table/index.js +1708 -0
- package/dist/components/table/index.js.map +1 -0
- package/dist/components/tabs/index.d.ts +196 -0
- package/dist/components/tabs/index.js +1137 -0
- package/dist/components/tabs/index.js.map +1 -0
- package/dist/components/time-field/index.d.ts +43 -0
- package/dist/components/time-field/index.js +107 -0
- package/dist/components/time-field/index.js.map +1 -0
- package/dist/components/time-picker/index.d.ts +65 -0
- package/dist/components/time-picker/index.js +1168 -0
- package/dist/components/time-picker/index.js.map +1 -0
- package/dist/components/token-field/index.d.ts +105 -0
- package/dist/components/token-field/index.js +574 -0
- package/dist/components/token-field/index.js.map +1 -0
- package/dist/components/tooltip/index.d.ts +102 -0
- package/dist/components/tooltip/index.js +223 -0
- package/dist/components/tooltip/index.js.map +1 -0
- package/dist/components/tree/index.d.ts +112 -0
- package/dist/components/tree/index.js +157 -0
- package/dist/components/tree/index.js.map +1 -0
- package/dist/disclosure/chevron.js +75 -0
- package/dist/disclosure/chevron.js.map +1 -0
- package/dist/disclosure/index.js +7 -0
- package/dist/disclosure/index.js.map +1 -0
- package/dist/drop/index.d.ts +54 -0
- package/dist/drop/index.js +161 -0
- package/dist/drop/index.js.map +1 -0
- package/dist/field/chevron.js +74 -0
- package/dist/field/chevron.js.map +1 -0
- package/dist/field/index.d.ts +2 -1
- package/dist/field/index.js +359 -154
- package/dist/field/index.js.map +1 -1
- package/dist/field/styles.js +18 -1
- package/dist/field/styles.js.map +1 -1
- package/dist/files/index.d.ts +18 -0
- package/dist/files/index.js +107 -0
- package/dist/files/index.js.map +1 -0
- package/dist/form/index.d.ts +5 -2
- package/dist/form/index.js +64 -85
- package/dist/form/index.js.map +1 -1
- package/dist/glyphs/index.js +128 -1
- package/dist/glyphs/index.js.map +1 -1
- package/dist/i18n/index.js +36 -1
- package/dist/i18n/index.js.map +1 -1
- package/dist/i18n/messages.js +1734 -34
- package/dist/i18n/messages.js.map +1 -1
- package/dist/index.d.ts +37 -3
- package/dist/index.js +36 -3
- package/dist/indicator/paths.js +23 -1
- package/dist/indicator/paths.js.map +1 -1
- package/dist/modal/index.js +92 -77
- package/dist/modal/index.js.map +1 -1
- package/dist/number/keyboard.js +16 -0
- package/dist/number/keyboard.js.map +1 -0
- package/dist/overlay/anchored.js +68 -38
- package/dist/overlay/anchored.js.map +1 -1
- package/dist/overlay/keyboard.js +57 -0
- package/dist/overlay/keyboard.js.map +1 -0
- package/dist/overlay/panel.js +173 -19
- package/dist/overlay/panel.js.map +1 -1
- package/dist/overlay/placement.js +13 -1
- package/dist/overlay/placement.js.map +1 -1
- package/dist/picker/index.js +322 -0
- package/dist/picker/index.js.map +1 -0
- package/dist/press/index.d.ts +2 -0
- package/dist/press/index.js +102 -100
- package/dist/press/index.js.map +1 -1
- package/dist/row/index.js +77 -69
- package/dist/row/index.js.map +1 -1
- package/dist/row/styles.js +13 -2
- package/dist/row/styles.js.map +1 -1
- package/dist/segments/field.js +277 -0
- package/dist/segments/field.js.map +1 -0
- package/dist/segments/index.js +574 -0
- package/dist/segments/index.js.map +1 -0
- package/dist/segments/styles.js +24 -0
- package/dist/segments/styles.js.map +1 -0
- package/dist/slider/index.js +145 -0
- package/dist/slider/index.js.map +1 -0
- package/dist/swatch/index.js +56 -0
- package/dist/swatch/index.js.map +1 -0
- package/package.json +11 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":["ComponentRef","ReactNode","Ref","HostInstance","LayoutChangeEvent","ScrollViewProps","StyleProp","TextProps","TextStyle","ViewProps","ViewStyle","GestureType","AnimatedStyle","SharedValue","EdgeInsets","createContext","use","useCallback","useEffect","useId","useMemo","useState","I18nManager","Text","NativeText","Pressable","ScrollView","StyleSheet","useWindowDimensions","View","Gesture","GestureDetector","GestureHandlerRootView","Animated","Easing","useAnimatedStyle","useReducedMotion","useSharedValue","withTiming","SafeAreaInsetsContext","ButtonSlots","ModalOpenProps","ModalTrigger","ResolvedTheme","ButtonSlotContext","useWindowSizeClass","useMessages","insetsOf","ModalWindow","NO_INSETS","panelRoleOf","useModalState","useModalTrigger","usePressFeedback","refsOf","useTheme","composeStyles","themedStyles","useTypeRole","SIDE_WIDTH","TOP_MARGIN","PARTIAL","DRAG_SLOP","FLING","BAR_WIDTH","BAR_HEIGHT","BAR_SPACE","BAR_SIDE","stylesOf","colors","radii","shadows","spacing","create","bar","backgroundColor","onSurfaceVariant","borderRadius","pill","height","width","body","gap","lg","paddingHorizontal","xl","paddingVertical","bodyText","color","container","surfaceContainerLow","boxShadow","elevation1","overflow","containerBottom","borderTopLeftRadius","borderTopRightRadius","containerSide","borderBottomStartRadius","borderTopStartRadius","flex","footer","alignItems","borderTopColor","outlineVariant","borderTopWidth","flexDirection","flexShrink","flexWrap","sm","justifyContent","minHeight","paddingBottom","paddingTop","handle","alignSelf","header","borderBottomColor","borderBottomWidth","md","rootBottom","bottom","left","position","right","rootSide","end","maxWidth","top","title","minWidth","SheetLayout","expanded","pan","setTitle","node","titleId","toggle","SheetLayoutContext","SheetTriggerContext","SheetBodyProps","ref","SheetContentProps","Omit","SheetOpenProps","children","isDismissable","isKeyboardDismissDisabled","style","SheetHandleProps","defaultOpen","isOpen","onOpenChange","SheetPartProps","SheetProps","SheetTitleProps","SheetWindowProps","close","setPresent","present","slots","Stops","partial","settles","bottomBoundsOf","insets","maxHeight","Math","max","settleOf","at","velocity","find","stop","findLast","reduce","nearest","abs","Sheet","t0","$","_c","t1","context","t2","t3","SheetBody","contentContainerStyle","onContentSizeChange","onLayout","props","scrollEnabled","undefined","layout","useLayout","styles","text","content","setContent","room","setRoom","measureContent","event","nativeEvent","measureRoom","scrolls","overflows","t4","Native","enabled","blocksExternalGesture","native","T0","T1","t5","t6","t7","t8","t9","SheetContent","outer","state","SheetFooter","SheetHandle","label","theme","corners","feedback","messages","dragHandle","handlers","ring","layer","SheetHeader","SheetTitle","role","SheetWindow","testID","full","setFull","setExpanded","stopsOf","stops","twoHeights","rest","motion","useSheetMotion","length","offset","useSheetDrag","Symbol","for","_temp","measure","labelledBy","t10","t11","scrim","t12","T2","t13","t14","t15","t16","sideInsetsOf","panel","t17","t18","t19","t20","t21","t22","was","paddingStart","lower","part","Error","reduceMotion","origin","lowest","follow","translation","set","min","get","settle","target","higher","duration","durationMedium1","easing","bezier","easingEmphasizedDecelerate","success","velocityY","Pan","activeOffsetY","runOnJS","onStart","translationY","onUpdate","translationY_0","onEnd","withTestId","shown","direction","isRTL","durationShort2","durationShort3","easingEmphasizedAccelerate","easingStandard","fade","enter","exit","gone","timer","setTimeout","clearTimeout","transform","translateY","progress","opacity","translateX","Body","Content","Footer","Handle","Header","Title","_c","NativeText"],"sources":["../../../src/components/sheet/index.tsx"],"sourcesContent":["import type { ComponentRef, ReactNode, Ref } from 'react'\nimport type {\n HostInstance,\n LayoutChangeEvent,\n ScrollViewProps,\n StyleProp,\n TextProps,\n TextStyle,\n ViewProps,\n ViewStyle,\n} from 'react-native'\nimport type { GestureType } from 'react-native-gesture-handler'\nimport type { AnimatedStyle, SharedValue } from 'react-native-reanimated'\nimport type { EdgeInsets } from 'react-native-safe-area-context'\n\nimport {\n createContext,\n use,\n useCallback,\n useEffect,\n useId,\n useMemo,\n useState,\n} from 'react'\nimport {\n I18nManager,\n Text as NativeText,\n Pressable,\n ScrollView,\n StyleSheet,\n useWindowDimensions,\n View,\n} from 'react-native'\nimport {\n Gesture,\n GestureDetector,\n GestureHandlerRootView,\n} from 'react-native-gesture-handler'\nimport Animated, {\n Easing,\n useAnimatedStyle,\n useReducedMotion,\n useSharedValue,\n withTiming,\n} from 'react-native-reanimated'\nimport { SafeAreaInsetsContext } from 'react-native-safe-area-context'\n\nimport type { ButtonSlots } from '../../button/slots'\nimport type { ModalOpenProps, ModalTrigger } from '../../modal'\nimport type { ResolvedTheme } from '../../theme/scope'\n\nimport { ButtonSlotContext } from '../../button/slots'\nimport { useWindowSizeClass } from '../../hooks/useWindowSizeClass'\nimport { useMessages } from '../../i18n/provider'\nimport {\n insetsOf,\n ModalWindow,\n NO_INSETS,\n panelRoleOf,\n useModalState,\n useModalTrigger,\n} from '../../modal'\nimport { usePressFeedback } from '../../press'\nimport { refsOf } from '../../ref'\nimport { useTheme } from '../../theme/scope'\nimport { composeStyles, themedStyles } from '../../theme/styles'\nimport { useTypeRole } from '../../typography/roles'\n\n// The bottom sheets and side sheets spec pages' modal sheets, as kanso-ui's\n// Sheet draws them: one component, which is a bottom sheet in a compact\n// window, below 600dp, and a side sheet from the medium window up. Both sit on\n// surface container low at the first elevation level, over the scrim. The\n// bottom sheet spans the window, with the 28dp corner on its top two corners,\n// and stops 72dp short of the window's top, the page's top margin, so a long\n// body scrolls. The side sheet is 400dp wide and as tall as the window, along\n// the end edge, with the 16dp corner on its two start corners, and turns over\n// with the layout under right-to-left.\n//\n// **The bottom sheet drags**, which web's does not: the spec page draws a\n// sheet that is dragged between heights and swiped down to go, and web\n// records leaving it out as a departure that native need not repeat. A sheet\n// taller than half the window opens at half its height, as Android's modal\n// bottom sheet does, and is dragged up to the whole of it and back; one no\n// taller opens whole. Let go, it settles on the nearest of those heights, or\n// one height on in the direction of a fling, and below the lowest it goes,\n// unless `isDismissable` is false, which holds it at the lowest. The drag is\n// Gesture Handler's pan, through the builder API both its 2.x and its 3\n// export. While the sheet is at half height its body does not scroll, so a\n// drag on it raises the sheet; once whole, a body with more than it can show\n// scrolls, and the sheet is dragged by the handle, header and actions. At\n// half height the actions are below the fold, where the drag brings them.\n//\n// **The handle is a control where the sheet has two heights**, as Android's\n// drag handle is: a press moves the sheet to the other one, and it says which\n// it is at as expanded or collapsed. It takes the press feedback every control\n// does, over a 48dp target, and is named \"Drag handle\" in the `I18nProvider`'s\n// locale, or the device's outside one, unless `aria-label` says otherwise. A sheet with one height has nothing for\n// it to do, and draws it as web does, as a mark the screen reader skips. The\n// side sheet draws no handle.\n//\n// **It is drawn in a React Native `Modal`**, through src/modal, as `Dialog`\n// is, so it keeps the `ThemeScope` around it, hosts its own overlays, and\n// takes its scrim, its back gesture and its focus handling from there. The\n// sheet's own panel is a Gesture Handler root, which Android needs for a\n// gesture inside a `Modal`'s window.\n//\n// **It animates out as well as in**, from the motion tokens: it arrives from\n// its edge over the medium duration on the emphasised decelerating curve and\n// leaves over the short one on the accelerating curve, while the scrim fades\n// on the standard one. Web only animates in, since React Aria keeps a closing\n// surface mounted only while a CSS animation runs. The side sheet fades as it\n// travels, as web's does; the bottom sheet does not, since its position is\n// also the drag's. Under reduced motion the sheet appears and leaves at once,\n// and the scrim still fades.\n//\n// **Its content sits inside the safe area** while its fill runs on under it:\n// the bottom sheet's above the home indicator and inside the side insets of a\n// phone held sideways, and the side sheet's under the status bar and over the\n// home indicator, inside the inset on its own edge.\n\n// The side sheet's width, web's and the side sheets page's.\nconst SIDE_WIDTH = 400\n\n// The bottom sheet's top margin once whole, the page's 72dp.\nconst TOP_MARGIN = 72\n\n// How much of the window a sheet with two heights shows at the lower one.\nconst PARTIAL = 0.5\n\n// How far a press travels before it is a drag, so a tap on the sheet's\n// content stays a tap.\nconst DRAG_SLOP = 8\n\n// A release faster than this, in dp a second, is a fling, which moves the\n// sheet one height on rather than to the nearest. Android's bottom sheet\n// takes the same speed as the one that hides it.\nconst FLING = 500\n\n// The handle's bar and the room above and below it, web's 32 by 4 with 22dp\n// either side, which with 8dp at its ends makes the 48dp target.\nconst BAR_WIDTH = 32\nconst BAR_HEIGHT = 4\nconst BAR_SPACE = 22\nconst BAR_SIDE = 8\n\nconst stylesOf = themedStyles(\n ({ colors, radii, shadows, spacing }: ResolvedTheme) =>\n StyleSheet.create({\n // The handle's bar, on on-surface variant.\n bar: {\n backgroundColor: colors.onSurfaceVariant,\n borderRadius: radii.pill,\n height: BAR_HEIGHT,\n width: BAR_WIDTH,\n },\n // The body's padding, web's: 24dp at the sides, 16dp at either end\n // and between whatever it holds.\n body: {\n gap: spacing.lg,\n paddingHorizontal: spacing.xl,\n paddingVertical: spacing.lg,\n },\n // The text a body is handed as a string, in body medium on on-surface\n // variant, as the stories on web set theirs.\n bodyText: {\n color: colors.onSurfaceVariant,\n },\n // Both sheets' container, whose corners clip the body's scroll.\n container: {\n backgroundColor: colors.surfaceContainerLow,\n boxShadow: shadows.elevation1,\n overflow: 'hidden',\n },\n // The bottom sheet's container: the window's width, rounded on top.\n containerBottom: {\n borderTopLeftRadius: radii.xl,\n borderTopRightRadius: radii.xl,\n width: '100%',\n },\n // The side sheet's container, as tall as the window and rounded on the\n // corners that face the screen it covers.\n containerSide: {\n borderBottomStartRadius: radii.lg,\n borderTopStartRadius: radii.lg,\n flex: 1,\n },\n // The actions, web's: leading, wrapping onto another row when they do\n // not fit on one, over a divider, in a bar 72dp tall at least.\n footer: {\n alignItems: 'center',\n borderTopColor: colors.outlineVariant,\n borderTopWidth: 1,\n flexDirection: 'row',\n flexShrink: 0,\n flexWrap: 'wrap',\n gap: spacing.sm,\n justifyContent: 'flex-start',\n minHeight: 72,\n paddingBottom: spacing.xl,\n paddingHorizontal: spacing.xl,\n paddingTop: spacing.lg,\n },\n // The handle's 48dp target, centred along the sheet's top edge.\n handle: {\n alignItems: 'center',\n alignSelf: 'center',\n borderRadius: radii.pill,\n flexShrink: 0,\n paddingHorizontal: BAR_SIDE,\n paddingVertical: BAR_SPACE,\n },\n // The headline and whatever shares its row, a close button for one,\n // over a divider.\n header: {\n alignItems: 'center',\n borderBottomColor: colors.outlineVariant,\n borderBottomWidth: 1,\n flexDirection: 'row',\n flexShrink: 0,\n gap: spacing.md,\n justifyContent: 'space-between',\n paddingHorizontal: spacing.xl,\n paddingVertical: spacing.sm,\n },\n // Where each sheet sits in the window. The panel is a Gesture Handler\n // root of its own, the size of the sheet, so a press beside it reaches\n // the scrim.\n rootBottom: {\n bottom: 0,\n left: 0,\n position: 'absolute',\n right: 0,\n },\n rootSide: {\n bottom: 0,\n end: 0,\n maxWidth: '100%',\n position: 'absolute',\n top: 0,\n width: SIDE_WIDTH,\n },\n // The headline gives way to whatever shares its row.\n title: {\n color: colors.onSurfaceVariant,\n flexShrink: 1,\n minWidth: 0,\n },\n }),\n)\n\n// What the content's parts read: which sheet is drawn, whether it is at its\n// whole height, the drag a scrolling body holds off, and the headline.\ntype SheetLayout = {\n readonly bottom: boolean\n readonly expanded: boolean\n // Gesture Handler 3 deprecates its gesture builder, and this type, for hooks\n // that version 2 does not have, and the peer range admits both, so the sheet\n // keeps the builder while it does.\n // oxlint-disable-next-line typescript/no-deprecated -- see above\n readonly pan: GestureType\n readonly setTitle: (node: HostInstance | null) => void\n readonly titleId: string\n /** What a press on the handle does, where the sheet has two heights. */\n readonly toggle: (() => void) | undefined\n}\n\nconst SheetLayoutContext = createContext<null | SheetLayout>(null)\nconst SheetTriggerContext = createContext<ModalTrigger | null>(null)\n\ntype SheetBodyProps = ScrollViewProps & {\n readonly ref?: Ref<ComponentRef<typeof ScrollView>>\n}\n\ntype SheetContentProps = Omit<ViewProps, 'children' | 'style'> &\n SheetOpenProps & {\n readonly children?: ReactNode\n /**\n * Whether a press on the scrim, outside the sheet, and a swipe down past\n * its lowest height close it. Android's back gesture is\n * `isKeyboardDismissDisabled`'s, and this says nothing about it.\n * @default true\n */\n readonly isDismissable?: boolean\n /**\n * Keeps Android's back gesture, VoiceOver's escape gesture, and Escape on\n * web, from closing the sheet.\n * @default false\n */\n readonly isKeyboardDismissDisabled?: boolean\n readonly ref?: Ref<ComponentRef<typeof View>>\n readonly style?: StyleProp<ViewStyle>\n }\n\ntype SheetHandleProps = Omit<ViewProps, 'children'> & {\n readonly ref?: Ref<ComponentRef<typeof View>>\n}\n\ntype SheetOpenProps = ModalOpenProps & {\n /** Whether the sheet starts open, when it keeps its own state. */\n readonly defaultOpen?: boolean\n /** Whether the sheet is open, when the call site holds the state. */\n readonly isOpen?: boolean\n /** Called with the new state as the sheet opens or closes. */\n readonly onOpenChange?: (isOpen: boolean) => void\n}\n\ntype SheetPartProps = ViewProps & {\n readonly ref?: Ref<ComponentRef<typeof View>>\n}\n\ntype SheetProps = SheetOpenProps & {\n /** The button that opens the sheet, and `Sheet.Content`. */\n readonly children?: ReactNode\n}\n\ntype SheetTitleProps = Omit<TextProps, 'role'> & {\n readonly ref?: Ref<HostInstance>\n}\n\n// What the window draws once the sheet is open, and what it needs from the\n// part that keeps the open state.\ntype SheetWindowProps = Omit<\n SheetContentProps,\n 'defaultOpen' | 'isOpen' | 'onOpenChange'\n> & {\n readonly close: () => void\n readonly isDismissable: boolean\n readonly isKeyboardDismissDisabled: boolean\n readonly isOpen: boolean\n readonly setPresent: (present: boolean) => void\n readonly slots: ButtonSlots\n}\n\n// The heights a bottom sheet rests at, as how far its panel is moved down:\n// whole, at half the window where it is taller than that, and gone.\ntype Stops = {\n /** The lower height, where the sheet has two. */\n readonly partial: null | number\n /** Every height a release can settle on, highest first. */\n readonly settles: readonly number[]\n}\n\n// The bottom sheet's room and padding: no taller than the window less the top\n// margin, or less the status bar where that is the taller, and its content\n// above the home indicator and inside the side insets.\nfunction bottomBoundsOf(insets: EdgeInsets, height: number): ViewStyle {\n return {\n ...insetsOf(insets),\n maxHeight: height - Math.max(TOP_MARGIN, insets.top),\n paddingTop: 0,\n }\n}\n\n/**\n * Where a bottom sheet let go comes to rest: one height on in the direction of\n * a fling, and the nearest height otherwise. Heights are how far the panel is\n * moved down, highest first, and the highest is always the whole sheet, 0.\n */\nfunction settleOf(at: number, velocity: number, settles: readonly number[]) {\n if (velocity > FLING) {\n return settles.find((stop) => stop > at) ?? settles.at(-1) ?? 0\n }\n\n if (velocity < -FLING) {\n return settles.findLast((stop) => stop < at) ?? 0\n }\n\n return settles.reduce(\n (nearest, stop) =>\n Math.abs(stop - at) < Math.abs(nearest - at) ? stop : nearest,\n 0,\n )\n}\n\n/**\n * A modal sheet along an edge of the screen, the bottom sheets and side sheets\n * spec pages' modal sheets, paired by window size as kanso-ui's are: a bottom\n * sheet in a compact window, dragged between heights and swiped down to go,\n * and a side sheet along the end edge from the medium window up. Pass\n * `isOpen` with `onOpenChange` to hold the open state, or `defaultOpen` to let\n * it keep its own.\n *\n * ```tsx\n * <Sheet>\n * <Button>Open</Button>\n * <Sheet.Content>\n * <Sheet.Handle />\n * <Sheet.Header>\n * <Sheet.Title>Headline</Sheet.Title>\n * </Sheet.Header>\n * <Sheet.Body>Supporting text</Sheet.Body>\n * <Sheet.Footer>\n * <Button slot=\"close\">Done</Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet>\n * ```\n *\n * Composed rather than configured by props, as web's is. A `Button` or\n * `IconButton` inside `Sheet` and outside its content opens it, and one given\n * `slot=\"close\"` anywhere inside the content closes it. A sheet nothing on the\n * screen opens leaves `Sheet` out and passes `isOpen` and `onOpenChange` to\n * `Sheet.Content` instead.\n */\nfunction Sheet({ children, defaultOpen, isOpen, onOpenChange }: SheetProps) {\n const { context, slots } = useModalTrigger({\n defaultOpen,\n isOpen,\n onOpenChange,\n })\n\n return (\n <SheetTriggerContext value={context}>\n <ButtonSlotContext value={slots}>{children}</ButtonSlotContext>\n </SheetTriggerContext>\n )\n}\n\n/**\n * What the sheet shows, as a body that scrolls when its content runs past the\n * room it has. A string is drawn in body medium on on-surface variant;\n * anything else draws itself. `style`, `ref` and `testID` land on the\n * `ScrollView`.\n *\n * A body its content runs past takes focus, as web's is a tab stop, so a\n * keyboard can scroll it when nothing inside it takes focus; a call site's\n * own `focusable` still wins. A bottom sheet's body scrolls only once the\n * sheet is at its whole height, and holds the sheet's drag off while it does.\n */\nfunction SheetBody({\n children,\n contentContainerStyle,\n onContentSizeChange,\n onLayout,\n scrollEnabled = true,\n ...props\n}: SheetBodyProps) {\n const layout = useLayout('Sheet.Body')\n const styles = stylesOf(useTheme())\n const text = useTypeRole('bodyMedium')\n const [content, setContent] = useState(0)\n const [room, setRoom] = useState(0)\n const measureContent = useCallback(\n (width: number, height: number) => {\n setContent(height)\n onContentSizeChange?.(width, height)\n },\n [onContentSizeChange],\n )\n const measureRoom = useCallback(\n (event: LayoutChangeEvent) => {\n setRoom(event.nativeEvent.layout.height)\n onLayout?.(event)\n },\n [onLayout],\n )\n const scrolls = scrollEnabled && layout.expanded\n const overflows = content > room\n // oxlint-disable-next-line react/capitalized-calls, typescript/no-deprecated -- a builder named after its gesture, not a component; see SheetLayout\n const native = Gesture.Native()\n .enabled(scrolls && overflows)\n .blocksExternalGesture(layout.pan)\n\n return (\n <GestureDetector gesture={native}>\n <ScrollView\n focusable={scrolls && overflows}\n onContentSizeChange={measureContent}\n onLayout={measureRoom}\n {...props}\n contentContainerStyle={composeStyles<ViewStyle>(\n styles.body,\n contentContainerStyle,\n )}\n scrollEnabled={scrolls}\n >\n {typeof children === 'string' ? (\n <NativeText style={composeStyles<TextStyle>(text, styles.bodyText)}>\n {children}\n </NativeText>\n ) : (\n children\n )}\n </ScrollView>\n </GestureDetector>\n )\n}\n\n/**\n * The sheet itself, and the scrim behind it. Everything the sheet shows goes\n * in here; the button that opens it stays outside it.\n *\n * Inside `Sheet`, the open state is the trigger's. On its own it is this\n * part's: `isOpen` with `onOpenChange` holds it, and a `slot=\"close\"` button,\n * the scrim, the swipe and the back gesture all report through\n * `onOpenChange`. `style`, `ref` and `testID` land on the container, and\n * `testID` names the drag `<testID>-drag` for Gesture Handler's test helpers.\n */\nfunction SheetContent({\n defaultOpen,\n isDismissable = true,\n isKeyboardDismissDisabled = false,\n isOpen,\n onOpenChange,\n ...props\n}: SheetContentProps) {\n const outer = use(SheetTriggerContext)\n const { close, present, setPresent, slots, state } = useModalState(outer, {\n defaultOpen,\n isOpen,\n onOpenChange,\n })\n\n if (!present) {\n return null\n }\n\n return (\n <SheetWindow\n {...props}\n close={close}\n isDismissable={isDismissable}\n isKeyboardDismissDisabled={isKeyboardDismissDisabled}\n isOpen={state.isOpen}\n setPresent={setPresent}\n slots={slots}\n />\n )\n}\n\n/**\n * The sheet's actions, leading and wrapping onto another row when they do not\n * fit on one, over a divider. On a bottom sheet at half height they are below\n * the fold until the sheet is raised. `style`, `ref` and `testID` land on its\n * view.\n */\nfunction SheetFooter({ style, ...props }: SheetPartProps) {\n useLayout('Sheet.Footer')\n const styles = stylesOf(useTheme())\n\n return (\n <View {...props} style={composeStyles<ViewStyle>(styles.footer, style)} />\n )\n}\n\n/**\n * The bottom sheet's drag handle, a 32 by 4dp bar centred along its top edge.\n * Where the sheet has two heights it is a button moving it to the other one,\n * named \"Drag handle\" in the `I18nProvider`'s locale, or the device's outside\n * one, unless `aria-label` says otherwise; elsewhere it is a mark a screen reader skips. A side sheet draws\n * none. `style`, `ref` and `testID` land on its view.\n */\nfunction SheetHandle({\n 'aria-label': label,\n style,\n ...props\n}: SheetHandleProps) {\n const layout = useLayout('Sheet.Handle')\n const theme = useTheme()\n const styles = stylesOf(theme)\n const { colors, radii } = theme\n const feedback = usePressFeedback({\n color: colors.onSurfaceVariant,\n corners: { borderRadius: radii.pill },\n })\n const { toggle } = layout\n const messages = useMessages()\n\n if (!layout.bottom) {\n return null\n }\n\n if (toggle === undefined) {\n return (\n <View\n aria-hidden\n {...props}\n style={composeStyles<ViewStyle>(styles.handle, style)}\n >\n <View style={styles.bar} />\n </View>\n )\n }\n\n return (\n <Pressable\n aria-expanded={layout.expanded}\n aria-label={label ?? messages.dragHandle}\n role=\"button\"\n {...props}\n {...feedback.handlers}\n onPress={toggle}\n style={composeStyles<ViewStyle>(styles.handle, feedback.ring, style)}\n >\n {feedback.layer}\n <View style={styles.bar} />\n </Pressable>\n )\n}\n\n/**\n * The sheet's header: its `Sheet.Title`, and anything beside it, such as a\n * close button, over a divider. `style`, `ref` and `testID` land on its view.\n */\nfunction SheetHeader({ style, ...props }: SheetPartProps) {\n useLayout('Sheet.Header')\n const styles = stylesOf(useTheme())\n\n return (\n <View {...props} style={composeStyles<ViewStyle>(styles.header, style)} />\n )\n}\n\n/**\n * Names the sheet: the container is labelled by it, and a screen reader is\n * sent to it once the sheet shows. In title large on on-surface variant.\n * `style`, `ref` and `testID` land on React Native's own Text.\n */\nfunction SheetTitle({ ref, style, ...props }: SheetTitleProps) {\n const layout = useLayout('Sheet.Title')\n const styles = stylesOf(useTheme())\n const role = useTypeRole('titleLarge')\n\n return (\n <NativeText\n {...props}\n nativeID={layout.titleId}\n ref={refsOf(layout.setTitle, ref)}\n role=\"heading\"\n style={composeStyles<TextStyle>(role, styles.title, style)}\n />\n )\n}\n\n/**\n * The open sheet, mounted from the moment it opens until its exit has run, so\n * each opening starts from its edge and at its first height.\n */\nfunction SheetWindow({\n children,\n close,\n isDismissable,\n isKeyboardDismissDisabled,\n isOpen,\n onLayout,\n setPresent,\n slots,\n style,\n testID,\n ...props\n}: SheetWindowProps) {\n const styles = stylesOf(useTheme())\n const insets = use(SafeAreaInsetsContext) ?? NO_INSETS\n const { height } = useWindowDimensions()\n const bottom = useWindowSizeClass() === 'compact'\n const titleId = useId()\n const [title, setTitle] = useState<HostInstance | null>(null)\n // The panel's height as laid out, before any drag moves it, and whether a\n // sheet with two heights is at the higher one.\n const [full, setFull] = useState<null | number>(null)\n const [expanded, setExpanded] = useState(false)\n const stops = stopsOf(bottom, full, height, isDismissable)\n const twoHeights = stops.partial !== null\n const rest = stops.partial !== null && !expanded ? stops.partial : 0\n const motion = useSheetMotion({ bottom, full, isOpen, rest, setPresent })\n const pan = useSheetDrag({\n close,\n enabled: bottom && isOpen && stops.settles.length > 1,\n expanded,\n full,\n isDismissable,\n offset: motion.offset,\n rest,\n setExpanded,\n stops,\n testID,\n })\n const toggle = useCallback(() => {\n setExpanded((was) => !was)\n }, [])\n const layout = useMemo<SheetLayout>(\n () => ({\n bottom,\n expanded: !twoHeights || expanded,\n pan,\n setTitle,\n titleId,\n toggle: twoHeights ? toggle : undefined,\n }),\n [bottom, expanded, pan, titleId, toggle, twoHeights],\n )\n const measure = useCallback(\n (event: LayoutChangeEvent) => {\n setFull(event.nativeEvent.layout.height)\n onLayout?.(event)\n },\n [onLayout],\n )\n const labelledBy = title === null ? undefined : titleId\n\n return (\n <ModalWindow\n isKeyboardDismissDisabled={isKeyboardDismissDisabled}\n labelledBy={labelledBy}\n onClose={close}\n onScrimPress={isDismissable && isOpen ? close : undefined}\n scrim={motion.scrim}\n title={title}\n >\n <GestureHandlerRootView\n style={bottom ? styles.rootBottom : styles.rootSide}\n >\n <GestureDetector gesture={pan}>\n <Animated.View\n {...panelRoleOf('dialog', labelledBy)}\n onAccessibilityEscape={\n isKeyboardDismissDisabled ? undefined : close\n }\n {...props}\n onLayout={measure}\n style={composeStyles<AnimatedStyle<ViewStyle>>(\n styles.container,\n bottom ? styles.containerBottom : styles.containerSide,\n bottom ? bottomBoundsOf(insets, height) : sideInsetsOf(insets),\n motion.panel,\n style,\n )}\n testID={testID}\n >\n <SheetLayoutContext value={layout}>\n <ButtonSlotContext value={slots}>{children}</ButtonSlotContext>\n </SheetLayoutContext>\n </Animated.View>\n </GestureDetector>\n </GestureHandlerRootView>\n </ModalWindow>\n )\n}\n\n// The side sheet's padding: its content under the status bar, over the home\n// indicator and inside the inset on its own edge. Its start edge faces the\n// screen it covers, which has none.\nfunction sideInsetsOf(insets: EdgeInsets): ViewStyle {\n return { ...insetsOf(insets), paddingStart: 0 }\n}\n\nfunction stopsOf(\n bottom: boolean,\n full: null | number,\n height: number,\n isDismissable: boolean,\n): Stops {\n if (!bottom || full === null) {\n return { partial: null, settles: [0] }\n }\n\n const lower = full - height * PARTIAL\n const partial = lower > 0 ? lower : null\n\n return {\n partial,\n settles: [\n 0,\n ...(partial === null ? [] : [partial]),\n ...(isDismissable ? [full] : []),\n ],\n }\n}\n\nfunction useLayout(part: string) {\n const layout = use(SheetLayoutContext)\n\n if (layout === null) {\n throw new Error(`${part} is drawn inside Sheet.Content.`)\n }\n\n return layout\n}\n\n/**\n * The bottom sheet's drag. The panel follows the finger, no higher than its\n * whole height and no lower than gone, or than its lowest height when it may\n * not be dismissed, and once let go it settles where `settleOf` says: below\n * the lowest height it closes, and at another height it moves the sheet there.\n */\nfunction useSheetDrag({\n close,\n enabled,\n expanded,\n full,\n isDismissable,\n offset,\n rest,\n setExpanded,\n stops,\n testID,\n}: {\n readonly close: () => void\n readonly enabled: boolean\n readonly expanded: boolean\n readonly full: null | number\n readonly isDismissable: boolean\n readonly offset: SharedValue<number>\n readonly rest: number\n readonly setExpanded: (expanded: boolean) => void\n readonly stops: Stops\n readonly testID: string | undefined\n}) {\n const { motion } = useTheme()\n const reduceMotion = useReducedMotion()\n // Where the panel stood when the drag was recognised. Gesture Handler\n // measures its translation from there, past the slop.\n const origin = useSharedValue(0)\n const lowest = stops.settles.at(-1) ?? 0\n\n function follow(translation: number) {\n offset.set(Math.min(lowest, Math.max(0, origin.get() + translation)))\n }\n\n function settle(target: number) {\n if (isDismissable && target === full) {\n close()\n return\n }\n\n const higher = target === 0\n if (stops.partial !== null && higher !== expanded) {\n setExpanded(higher)\n return\n }\n\n offset.set(\n reduceMotion\n ? target\n : withTiming(target, {\n duration: motion.durationMedium1,\n easing: Easing.bezier(...motion.easingEmphasizedDecelerate),\n }),\n )\n }\n\n // oxlint-disable-next-line react/capitalized-calls, typescript/no-deprecated -- a builder named after its gesture, not a component; see SheetLayout\n const pan = Gesture.Pan()\n .activeOffsetY([-DRAG_SLOP, DRAG_SLOP])\n .enabled(enabled)\n .runOnJS(true)\n .onStart(({ translationY }) => {\n origin.set(offset.get())\n follow(translationY)\n })\n .onUpdate(({ translationY }) => {\n follow(translationY)\n })\n .onEnd(({ velocityY }, success) => {\n settle(success ? settleOf(offset.get(), velocityY, stops.settles) : rest)\n })\n\n return testID === undefined ? pan : pan.withTestId(`${testID}-drag`)\n}\n\n/**\n * The scrim's and the panel's motion, and the timer that unmounts the sheet\n * once its exit has run. The bottom sheet's position is how far its panel is\n * moved down, which the drag sets too; it starts below the window and rises\n * to its height once that is measured. The side sheet's is how far it has\n * come in from its edge, which is the end edge, and so the left one under\n * right-to-left.\n */\nfunction useSheetMotion({\n bottom,\n full,\n isOpen,\n rest,\n setPresent,\n}: {\n readonly bottom: boolean\n readonly full: null | number\n readonly isOpen: boolean\n readonly rest: number\n readonly setPresent: (present: boolean) => void\n}) {\n const { motion } = useTheme()\n const reduceMotion = useReducedMotion()\n const { height } = useWindowDimensions()\n const offset = useSharedValue(height)\n const shown = useSharedValue(0)\n const scrim = useSharedValue(0)\n // A translation is not mirrored under a right-to-left layout, though the\n // side sheet's edge is, so it travels the other way there.\n const direction = I18nManager.isRTL ? -1 : 1\n\n useEffect(() => {\n const fade = {\n duration: motion.durationShort2,\n easing: Easing.bezier(...motion.easingStandard),\n }\n const enter = {\n duration: motion.durationMedium1,\n easing: Easing.bezier(...motion.easingEmphasizedDecelerate),\n }\n const exit = {\n duration: motion.durationShort3,\n easing: Easing.bezier(...motion.easingEmphasizedAccelerate),\n }\n\n if (isOpen) {\n scrim.set(withTiming(1, fade))\n if (!bottom) {\n shown.set(reduceMotion ? 1 : withTiming(1, enter))\n return undefined\n }\n if (full === null) {\n return undefined\n }\n // It rises from its own height below where it rests, not from the\n // bottom of the window, so it shows from the first frame.\n if (offset.get() > full) {\n offset.set(full)\n }\n offset.set(reduceMotion ? rest : withTiming(rest, enter))\n return undefined\n }\n\n scrim.set(withTiming(0, fade))\n if (bottom) {\n const gone = full ?? height\n offset.set(reduceMotion ? gone : withTiming(gone, exit))\n } else {\n shown.set(reduceMotion ? 0 : withTiming(0, exit))\n }\n const timer = setTimeout(\n () => {\n setPresent(false)\n },\n reduceMotion\n ? motion.durationShort2\n : Math.max(motion.durationShort2, motion.durationShort3),\n )\n\n return () => {\n clearTimeout(timer)\n }\n }, [\n bottom,\n full,\n height,\n isOpen,\n motion,\n offset,\n reduceMotion,\n rest,\n scrim,\n setPresent,\n shown,\n ])\n\n return {\n offset,\n panel: useAnimatedStyle(() => {\n 'worklet'\n if (bottom) {\n return { transform: [{ translateY: offset.get() }] }\n }\n\n const progress = shown.get()\n return {\n opacity: progress,\n transform: [{ translateX: (1 - progress) * SIDE_WIDTH * direction }],\n }\n }),\n scrim: useAnimatedStyle(() => {\n 'worklet'\n return { opacity: scrim.get() }\n }),\n }\n}\n\nSheet.Body = SheetBody\nSheet.Content = SheetContent\nSheet.Footer = SheetFooter\nSheet.Handle = SheetHandle\nSheet.Header = SheetHeader\nSheet.Title = SheetTitle\n\nexport {\n Sheet,\n SheetBody,\n SheetContent,\n SheetFooter,\n SheetHandle,\n SheetHeader,\n SheetTitle,\n}\nexport type {\n SheetBodyProps,\n SheetContentProps,\n SheetHandleProps,\n SheetPartProps,\n SheetProps,\n SheetTitleProps,\n}\n"],"mappings":";;;;;;;;;;;;;;;;;AAyHA,MAAM2D,aAAa;AAGnB,MAAMC,aAAa;AAGnB,MAAMC,UAAU;AAIhB,MAAMC,YAAY;AAKlB,MAAMC,QAAQ;AAId,MAAMC,YAAY;AAClB,MAAMC,aAAa;AACnB,MAAMC,YAAY;AAClB,MAAMC,WAAW;AAEjB,MAAMC,WAAWX,cACd,EAAEY,QAAQC,OAAOC,SAASC,cACzB7C,WAAW8C,OAAO;CAEhBC,KAAK;EACHC,iBAAiBN,OAAOO;EACxBC,cAAcP,MAAMQ;EACpBC,QAAQd;EACRe,OAAOhB;CACT;CAGAiB,MAAM;EACJC,KAAKV,QAAQW;EACbC,mBAAmBZ,QAAQa;EAC3BC,iBAAiBd,QAAQW;CAC3B;CAGAI,UAAU,EACRC,OAAOnB,OAAOO,iBAChB;CAEAa,WAAW;EACTd,iBAAiBN,OAAOqB;EACxBC,WAAWpB,QAAQqB;EACnBC,UAAU;CACZ;CAEAC,iBAAiB;EACfC,qBAAqBzB,MAAMe;EAC3BW,sBAAsB1B,MAAMe;EAC5BL,OAAO;CACT;CAGAiB,eAAe;EACbC,yBAAyB5B,MAAMa;EAC/BgB,sBAAsB7B,MAAMa;EAC5BiB,MAAM;CACR;CAGAC,QAAQ;EACNC,YAAY;EACZC,gBAAgBlC,OAAOmC;EACvBC,gBAAgB;EAChBC,eAAe;EACfC,YAAY;EACZC,UAAU;EACV1B,KAAKV,QAAQqC;EACbC,gBAAgB;EAChBC,WAAW;EACXC,eAAexC,QAAQa;EACvBD,mBAAmBZ,QAAQa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;CAIQ,MAAAC,KAAAtJ,uBAAiB;EAAA;EAEtB,IAAIsF,QAAM,OACD,EAAAqM,WAAa,CAAC,EAAAC,YAAcvE,OAAMoC,IAAK,EAAE,CAAC,EAAE;EAGrD,MAAAoC,WAAiBhB,MAAKpB,IAAK;EAAC,OACrB;GAAAqC,SACID;GAAQF,WACN,CAAC,EAAAI,aAAe,IAAIF,YAAYrQ,aAAasP,UAAU,CAAC;EACrE;CAAC,CACF;CACM,MAAAlG,KAAA5K,uBAAiB;EAAA;EAAA,OAEf,EAAA8R,SAAWhE,MAAK2B,IAAK,EAAE;CAAC,CAChC;CAAC,IAAAtE;CAAA,IAAAlC,EAAA,QAAAoE,UAAApE,EAAA,QAAAK,MAAAL,EAAA,QAAA2B,IAAA;EAjBGO,KAAA;GAAAkC;GAAAiB,OAEEhF;GAWLwE,OACKlD;EAIT;EAAC3B,EAAA,MAAAoE;EAAApE,EAAA,MAAAK;EAAAL,EAAA,MAAA2B;EAAA3B,EAAA,MAAAkC;CAAA,OAAAA,KAAAlC,EAAA;CAAA,OAlBMkC;AAkBN;AAGHpC,MAAMiJ,OAAOzI;AACbR,MAAMkJ,UAAUzG;AAChBzC,MAAMmJ,SAASvG;AACf5C,MAAMoJ,SAASvG;AACf7C,MAAMqJ,SAAS9F;AACfvD,MAAMsJ,QAAQ9F"}
|
|
1
|
+
{"version":3,"file":"index.js","names":["ComponentRef","ReactNode","Ref","HostInstance","LayoutChangeEvent","ScrollViewProps","StyleProp","TextProps","TextStyle","ViewProps","ViewStyle","GestureType","AnimatedStyle","SharedValue","EdgeInsets","createContext","use","useCallback","useEffect","useId","useMemo","useState","I18nManager","Text","NativeText","Pressable","ScrollView","StyleSheet","useWindowDimensions","View","Gesture","GestureDetector","GestureHandlerRootView","Animated","Easing","useAnimatedStyle","useReducedMotion","useSharedValue","withTiming","SafeAreaInsetsContext","ButtonSlots","ModalOpenProps","ModalTrigger","ResolvedTheme","ButtonSlotContext","useWindowSizeClass","useMessages","insetsOf","ModalWindow","NO_INSETS","panelRoleOf","useModalState","useModalTrigger","usePressFeedback","refsOf","useTheme","composeStyles","themedStyles","useTypeRole","SIDE_WIDTH","TOP_MARGIN","PARTIAL","DRAG_SLOP","FLING","BAR_WIDTH","BAR_HEIGHT","BAR_SPACE","BAR_SIDE","stylesOf","colors","radii","shadows","spacing","create","bar","backgroundColor","onSurfaceVariant","borderRadius","pill","height","width","body","gap","lg","paddingHorizontal","xl","paddingVertical","bodyText","color","container","surfaceContainerLow","boxShadow","elevation1","overflow","containerBottom","borderTopLeftRadius","borderTopRightRadius","containerSide","borderBottomStartRadius","borderTopStartRadius","flex","footer","alignItems","borderTopColor","outlineVariant","borderTopWidth","flexDirection","flexShrink","flexWrap","sm","justifyContent","minHeight","paddingBottom","paddingTop","handle","alignSelf","header","borderBottomColor","borderBottomWidth","md","rootBottom","bottom","left","position","right","rootSide","end","maxWidth","top","title","minWidth","SheetLayout","expanded","pan","setTitle","node","titleId","toggle","SheetLayoutContext","SheetTriggerContext","SheetBodyProps","ref","SheetContentProps","Omit","SheetOpenProps","children","initialHeight","isDismissable","isKeyboardDismissDisabled","style","SheetHandleProps","defaultOpen","isOpen","onOpenChange","SheetPartProps","SheetProps","SheetTitleProps","SheetWindowProps","close","setPresent","present","slots","Stops","partial","settles","bottomBoundsOf","insets","maxHeight","Math","max","settleOf","at","velocity","find","stop","findLast","reduce","nearest","abs","Sheet","t0","$","_c","t1","context","t2","t3","SheetBody","contentContainerStyle","onContentSizeChange","onLayout","props","scrollEnabled","undefined","layout","useLayout","styles","text","content","setContent","room","setRoom","measureContent","event","nativeEvent","measureRoom","scrolls","overflows","t4","Native","enabled","blocksExternalGesture","native","T0","T1","t5","t6","t7","t8","t9","SheetContent","outer","state","SheetFooter","SheetHandle","label","theme","corners","feedback","messages","dragHandle","handlers","ring","layer","SheetHeader","SheetTitle","role","SheetWindow","testID","full","setFull","setExpanded","stopsOf","stops","twoHeights","rest","motion","useSheetMotion","length","offset","useSheetDrag","Symbol","for","_temp","t10","measure","labelledBy","t11","t12","scrim","t13","T2","t14","t15","t16","t17","sideInsetsOf","panel","t18","t19","t20","t21","t22","t23","was","paddingStart","lower","part","Error","reduceMotion","origin","lowest","follow","translation","set","min","get","settle","target","higher","duration","durationMedium1","easing","bezier","easingEmphasizedDecelerate","success","velocityY","Pan","activeOffsetY","runOnJS","onStart","translationY","onUpdate","translationY_0","onEnd","withTestId","shown","direction","isRTL","durationShort2","durationShort3","easingEmphasizedAccelerate","easingStandard","fade","enter","exit","gone","timer","setTimeout","clearTimeout","transform","translateY","progress","opacity","translateX","Body","Content","Footer","Handle","Header","Title","_c","NativeText"],"sources":["../../../src/components/sheet/index.tsx"],"sourcesContent":["import type { ComponentRef, ReactNode, Ref } from 'react'\nimport type {\n HostInstance,\n LayoutChangeEvent,\n ScrollViewProps,\n StyleProp,\n TextProps,\n TextStyle,\n ViewProps,\n ViewStyle,\n} from 'react-native'\nimport type { GestureType } from 'react-native-gesture-handler'\nimport type { AnimatedStyle, SharedValue } from 'react-native-reanimated'\nimport type { EdgeInsets } from 'react-native-safe-area-context'\n\nimport {\n createContext,\n use,\n useCallback,\n useEffect,\n useId,\n useMemo,\n useState,\n} from 'react'\nimport {\n I18nManager,\n Text as NativeText,\n Pressable,\n ScrollView,\n StyleSheet,\n useWindowDimensions,\n View,\n} from 'react-native'\nimport {\n Gesture,\n GestureDetector,\n GestureHandlerRootView,\n} from 'react-native-gesture-handler'\nimport Animated, {\n Easing,\n useAnimatedStyle,\n useReducedMotion,\n useSharedValue,\n withTiming,\n} from 'react-native-reanimated'\nimport { SafeAreaInsetsContext } from 'react-native-safe-area-context'\n\nimport type { ButtonSlots } from '../../button/slots'\nimport type { ModalOpenProps, ModalTrigger } from '../../modal'\nimport type { ResolvedTheme } from '../../theme/scope'\n\nimport { ButtonSlotContext } from '../../button/slots'\nimport { useWindowSizeClass } from '../../hooks/useWindowSizeClass'\nimport { useMessages } from '../../i18n/provider'\nimport {\n insetsOf,\n ModalWindow,\n NO_INSETS,\n panelRoleOf,\n useModalState,\n useModalTrigger,\n} from '../../modal'\nimport { usePressFeedback } from '../../press'\nimport { refsOf } from '../../ref'\nimport { useTheme } from '../../theme/scope'\nimport { composeStyles, themedStyles } from '../../theme/styles'\nimport { useTypeRole } from '../../typography/roles'\n\n// The bottom sheets and side sheets spec pages' modal sheets, as kanso-ui's\n// Sheet draws them: one component, which is a bottom sheet in a compact\n// window, below 600dp, and a side sheet from the medium window up. Both sit on\n// surface container low at the first elevation level, over the scrim. The\n// bottom sheet spans the window, with the 28dp corner on its top two corners,\n// and stops 72dp short of the window's top, the page's top margin, so a long\n// body scrolls. The side sheet is 400dp wide and as tall as the window, along\n// the end edge, with the 16dp corner on its two start corners, and turns over\n// with the layout under right-to-left.\n//\n// **The bottom sheet drags**, which web's does not: the spec page draws a\n// sheet that is dragged between heights and swiped down to go, and web\n// records leaving it out as a departure that native need not repeat. A sheet\n// taller than half the window opens at half its height, as Android's modal\n// bottom sheet does, and is dragged up to the whole of it and back; one no\n// taller opens whole. `initialHeight=\"whole\"` opens one with two heights at\n// the higher, as web's sheet always opens, for a sheet whose actions are what\n// it is opened for, such as a form's save; the handle and the drag still take\n// it down to half from there. Let go, it settles on the nearest of those\n// heights, or one height on in the direction of a fling, and below the lowest\n// it goes, unless `isDismissable` is false, which holds it at the lowest. The\n// drag is Gesture Handler's pan, through the builder API both its 2.x and its\n// 3 export. While the sheet is at half height its body does not scroll, so a\n// drag on it raises the sheet; once whole, a body with more than it can show\n// scrolls, and the sheet is dragged by the handle, header and actions. At\n// half height the actions are below the fold, where the drag brings them.\n//\n// **The handle is a control where the sheet has two heights**, as Android's\n// drag handle is: a press moves the sheet to the other one, and it says which\n// it is at as expanded or collapsed. It takes the press feedback every control\n// does, over a 48dp target, and is named \"Drag handle\" in the `I18nProvider`'s\n// locale, or the device's outside one, unless `aria-label` says otherwise. A sheet with one height has nothing for\n// it to do, and draws it as web does, as a mark the screen reader skips. The\n// side sheet draws no handle.\n//\n// **It is drawn in a React Native `Modal`**, through src/modal, as `Dialog`\n// is, so it keeps the `ThemeScope` around it, hosts its own overlays, and\n// takes its scrim, its back gesture and its focus handling from there. The\n// sheet's own panel is a Gesture Handler root, which Android needs for a\n// gesture inside a `Modal`'s window.\n//\n// **It animates out as well as in**, from the motion tokens: it arrives from\n// its edge over the medium duration on the emphasised decelerating curve and\n// leaves over the short one on the accelerating curve, while the scrim fades\n// on the standard one. Web only animates in, since React Aria keeps a closing\n// surface mounted only while a CSS animation runs. The side sheet fades as it\n// travels, as web's does; the bottom sheet does not, since its position is\n// also the drag's. Under reduced motion the sheet appears and leaves at once,\n// and the scrim still fades.\n//\n// **Its content sits inside the safe area** while its fill runs on under it:\n// the bottom sheet's above the home indicator and inside the side insets of a\n// phone held sideways, and the side sheet's under the status bar and over the\n// home indicator, inside the inset on its own edge.\n\n// The side sheet's width, web's and the side sheets page's.\nconst SIDE_WIDTH = 400\n\n// The bottom sheet's top margin once whole, the page's 72dp.\nconst TOP_MARGIN = 72\n\n// How much of the window a sheet with two heights shows at the lower one.\nconst PARTIAL = 0.5\n\n// How far a press travels before it is a drag, so a tap on the sheet's\n// content stays a tap.\nconst DRAG_SLOP = 8\n\n// A release faster than this, in dp a second, is a fling, which moves the\n// sheet one height on rather than to the nearest. Android's bottom sheet\n// takes the same speed as the one that hides it.\nconst FLING = 500\n\n// The handle's bar and the room above and below it, web's 32 by 4 with 22dp\n// either side, which with 8dp at its ends makes the 48dp target.\nconst BAR_WIDTH = 32\nconst BAR_HEIGHT = 4\nconst BAR_SPACE = 22\nconst BAR_SIDE = 8\n\nconst stylesOf = themedStyles(\n ({ colors, radii, shadows, spacing }: ResolvedTheme) =>\n StyleSheet.create({\n // The handle's bar, on on-surface variant.\n bar: {\n backgroundColor: colors.onSurfaceVariant,\n borderRadius: radii.pill,\n height: BAR_HEIGHT,\n width: BAR_WIDTH,\n },\n // The body's padding, web's: 24dp at the sides, 16dp at either end\n // and between whatever it holds.\n body: {\n gap: spacing.lg,\n paddingHorizontal: spacing.xl,\n paddingVertical: spacing.lg,\n },\n // The text a body is handed as a string, in body medium on on-surface\n // variant, as the stories on web set theirs.\n bodyText: {\n color: colors.onSurfaceVariant,\n },\n // Both sheets' container, whose corners clip the body's scroll.\n container: {\n backgroundColor: colors.surfaceContainerLow,\n boxShadow: shadows.elevation1,\n overflow: 'hidden',\n },\n // The bottom sheet's container: the window's width, rounded on top.\n containerBottom: {\n borderTopLeftRadius: radii.xl,\n borderTopRightRadius: radii.xl,\n width: '100%',\n },\n // The side sheet's container, as tall as the window and rounded on the\n // corners that face the screen it covers.\n containerSide: {\n borderBottomStartRadius: radii.lg,\n borderTopStartRadius: radii.lg,\n flex: 1,\n },\n // The actions, web's: leading, wrapping onto another row when they do\n // not fit on one, over a divider, in a bar 72dp tall at least.\n footer: {\n alignItems: 'center',\n borderTopColor: colors.outlineVariant,\n borderTopWidth: 1,\n flexDirection: 'row',\n flexShrink: 0,\n flexWrap: 'wrap',\n gap: spacing.sm,\n justifyContent: 'flex-start',\n minHeight: 72,\n paddingBottom: spacing.xl,\n paddingHorizontal: spacing.xl,\n paddingTop: spacing.lg,\n },\n // The handle's 48dp target, centred along the sheet's top edge.\n handle: {\n alignItems: 'center',\n alignSelf: 'center',\n borderRadius: radii.pill,\n flexShrink: 0,\n paddingHorizontal: BAR_SIDE,\n paddingVertical: BAR_SPACE,\n },\n // The headline and whatever shares its row, a close button for one,\n // over a divider.\n header: {\n alignItems: 'center',\n borderBottomColor: colors.outlineVariant,\n borderBottomWidth: 1,\n flexDirection: 'row',\n flexShrink: 0,\n gap: spacing.md,\n justifyContent: 'space-between',\n paddingHorizontal: spacing.xl,\n paddingVertical: spacing.sm,\n },\n // Where each sheet sits in the window. The panel is a Gesture Handler\n // root of its own, the size of the sheet, so a press beside it reaches\n // the scrim.\n rootBottom: {\n bottom: 0,\n left: 0,\n position: 'absolute',\n right: 0,\n },\n rootSide: {\n bottom: 0,\n end: 0,\n maxWidth: '100%',\n position: 'absolute',\n top: 0,\n width: SIDE_WIDTH,\n },\n // The headline gives way to whatever shares its row.\n title: {\n color: colors.onSurfaceVariant,\n flexShrink: 1,\n minWidth: 0,\n },\n }),\n)\n\n// What the content's parts read: which sheet is drawn, whether it is at its\n// whole height, the drag a scrolling body holds off, and the headline.\ntype SheetLayout = {\n readonly bottom: boolean\n readonly expanded: boolean\n // Gesture Handler 3 deprecates its gesture builder, and this type, for hooks\n // that version 2 does not have, and the peer range admits both, so the sheet\n // keeps the builder while it does.\n // oxlint-disable-next-line typescript/no-deprecated -- see above\n readonly pan: GestureType\n readonly setTitle: (node: HostInstance | null) => void\n readonly titleId: string\n /** What a press on the handle does, where the sheet has two heights. */\n readonly toggle: (() => void) | undefined\n}\n\nconst SheetLayoutContext = createContext<null | SheetLayout>(null)\nconst SheetTriggerContext = createContext<ModalTrigger | null>(null)\n\ntype SheetBodyProps = ScrollViewProps & {\n readonly ref?: Ref<ComponentRef<typeof ScrollView>>\n}\n\ntype SheetContentProps = Omit<ViewProps, 'children' | 'style'> &\n SheetOpenProps & {\n readonly children?: ReactNode\n /**\n * The height a bottom sheet with two heights opens at each time: `half`,\n * where its content stays in reach of a drag, or `whole`, where its\n * actions are in view from the start. A sheet with one height, and a side\n * sheet, open whole whatever this says.\n * @default 'half'\n */\n readonly initialHeight?: 'half' | 'whole'\n /**\n * Whether a press on the scrim, outside the sheet, and a swipe down past\n * its lowest height close it. Android's back gesture is\n * `isKeyboardDismissDisabled`'s, and this says nothing about it.\n * @default true\n */\n readonly isDismissable?: boolean\n /**\n * Keeps Android's back gesture, VoiceOver's escape gesture, and Escape on\n * web, from closing the sheet.\n * @default false\n */\n readonly isKeyboardDismissDisabled?: boolean\n readonly ref?: Ref<ComponentRef<typeof View>>\n readonly style?: StyleProp<ViewStyle>\n }\n\ntype SheetHandleProps = Omit<ViewProps, 'children'> & {\n readonly ref?: Ref<ComponentRef<typeof View>>\n}\n\ntype SheetOpenProps = ModalOpenProps & {\n /** Whether the sheet starts open, when it keeps its own state. */\n readonly defaultOpen?: boolean\n /** Whether the sheet is open, when the call site holds the state. */\n readonly isOpen?: boolean\n /** Called with the new state as the sheet opens or closes. */\n readonly onOpenChange?: (isOpen: boolean) => void\n}\n\ntype SheetPartProps = ViewProps & {\n readonly ref?: Ref<ComponentRef<typeof View>>\n}\n\ntype SheetProps = SheetOpenProps & {\n /** The button that opens the sheet, and `Sheet.Content`. */\n readonly children?: ReactNode\n}\n\ntype SheetTitleProps = Omit<TextProps, 'role'> & {\n readonly ref?: Ref<HostInstance>\n}\n\n// What the window draws once the sheet is open, and what it needs from the\n// part that keeps the open state.\ntype SheetWindowProps = Omit<\n SheetContentProps,\n 'defaultOpen' | 'isOpen' | 'onOpenChange'\n> & {\n readonly close: () => void\n readonly isDismissable: boolean\n readonly isKeyboardDismissDisabled: boolean\n readonly isOpen: boolean\n readonly setPresent: (present: boolean) => void\n readonly slots: ButtonSlots\n}\n\n// The heights a bottom sheet rests at, as how far its panel is moved down:\n// whole, at half the window where it is taller than that, and gone.\ntype Stops = {\n /** The lower height, where the sheet has two. */\n readonly partial: null | number\n /** Every height a release can settle on, highest first. */\n readonly settles: readonly number[]\n}\n\n// The bottom sheet's room and padding: no taller than the window less the top\n// margin, or less the status bar where that is the taller, and its content\n// above the home indicator and inside the side insets.\nfunction bottomBoundsOf(insets: EdgeInsets, height: number): ViewStyle {\n return {\n ...insetsOf(insets),\n maxHeight: height - Math.max(TOP_MARGIN, insets.top),\n paddingTop: 0,\n }\n}\n\n/**\n * Where a bottom sheet let go comes to rest: one height on in the direction of\n * a fling, and the nearest height otherwise. Heights are how far the panel is\n * moved down, highest first, and the highest is always the whole sheet, 0.\n */\nfunction settleOf(at: number, velocity: number, settles: readonly number[]) {\n if (velocity > FLING) {\n return settles.find((stop) => stop > at) ?? settles.at(-1) ?? 0\n }\n\n if (velocity < -FLING) {\n return settles.findLast((stop) => stop < at) ?? 0\n }\n\n return settles.reduce(\n (nearest, stop) =>\n Math.abs(stop - at) < Math.abs(nearest - at) ? stop : nearest,\n 0,\n )\n}\n\n/**\n * A modal sheet along an edge of the screen, the bottom sheets and side sheets\n * spec pages' modal sheets, paired by window size as kanso-ui's are: a bottom\n * sheet in a compact window, dragged between heights and swiped down to go,\n * and a side sheet along the end edge from the medium window up. Pass\n * `isOpen` with `onOpenChange` to hold the open state, or `defaultOpen` to let\n * it keep its own.\n *\n * ```tsx\n * <Sheet>\n * <Button>Open</Button>\n * <Sheet.Content>\n * <Sheet.Handle />\n * <Sheet.Header>\n * <Sheet.Title>Headline</Sheet.Title>\n * </Sheet.Header>\n * <Sheet.Body>Supporting text</Sheet.Body>\n * <Sheet.Footer>\n * <Button slot=\"close\">Done</Button>\n * </Sheet.Footer>\n * </Sheet.Content>\n * </Sheet>\n * ```\n *\n * Composed rather than configured by props, as web's is. A `Button`,\n * `IconButton` or `Chip` inside `Sheet` and outside its content opens it, and\n * a button given `slot=\"close\"` anywhere inside the content closes it. A\n * sheet nothing on the screen opens leaves `Sheet` out and passes `isOpen`\n * and `onOpenChange` to `Sheet.Content` instead.\n */\nfunction Sheet({ children, defaultOpen, isOpen, onOpenChange }: SheetProps) {\n const { context, slots } = useModalTrigger({\n defaultOpen,\n isOpen,\n onOpenChange,\n })\n\n return (\n <SheetTriggerContext value={context}>\n <ButtonSlotContext value={slots}>{children}</ButtonSlotContext>\n </SheetTriggerContext>\n )\n}\n\n/**\n * What the sheet shows, as a body that scrolls when its content runs past the\n * room it has. A string is drawn in body medium on on-surface variant;\n * anything else draws itself. `style`, `ref` and `testID` land on the\n * `ScrollView`.\n *\n * A body its content runs past takes focus, as web's is a tab stop, so a\n * keyboard can scroll it when nothing inside it takes focus; a call site's\n * own `focusable` still wins. A bottom sheet's body scrolls only once the\n * sheet is at its whole height, and holds the sheet's drag off while it does.\n */\nfunction SheetBody({\n children,\n contentContainerStyle,\n onContentSizeChange,\n onLayout,\n scrollEnabled = true,\n ...props\n}: SheetBodyProps) {\n const layout = useLayout('Sheet.Body')\n const styles = stylesOf(useTheme())\n const text = useTypeRole('bodyMedium')\n const [content, setContent] = useState(0)\n const [room, setRoom] = useState(0)\n const measureContent = useCallback(\n (width: number, height: number) => {\n setContent(height)\n onContentSizeChange?.(width, height)\n },\n [onContentSizeChange],\n )\n const measureRoom = useCallback(\n (event: LayoutChangeEvent) => {\n setRoom(event.nativeEvent.layout.height)\n onLayout?.(event)\n },\n [onLayout],\n )\n const scrolls = scrollEnabled && layout.expanded\n const overflows = content > room\n // oxlint-disable-next-line react/capitalized-calls, typescript/no-deprecated -- a builder named after its gesture, not a component; see SheetLayout\n const native = Gesture.Native()\n .enabled(scrolls && overflows)\n .blocksExternalGesture(layout.pan)\n\n return (\n <GestureDetector gesture={native}>\n <ScrollView\n focusable={scrolls && overflows}\n onContentSizeChange={measureContent}\n onLayout={measureRoom}\n {...props}\n contentContainerStyle={composeStyles<ViewStyle>(\n styles.body,\n contentContainerStyle,\n )}\n scrollEnabled={scrolls}\n >\n {typeof children === 'string' ? (\n <NativeText style={composeStyles<TextStyle>(text, styles.bodyText)}>\n {children}\n </NativeText>\n ) : (\n children\n )}\n </ScrollView>\n </GestureDetector>\n )\n}\n\n/**\n * The sheet itself, and the scrim behind it. Everything the sheet shows goes\n * in here; the button that opens it stays outside it.\n *\n * Inside `Sheet`, the open state is the trigger's. On its own it is this\n * part's: `isOpen` with `onOpenChange` holds it, and a `slot=\"close\"` button,\n * the scrim, the swipe and the back gesture all report through\n * `onOpenChange`. `style`, `ref` and `testID` land on the container, and\n * `testID` names the drag `<testID>-drag` for Gesture Handler's test helpers.\n */\nfunction SheetContent({\n defaultOpen,\n isDismissable = true,\n isKeyboardDismissDisabled = false,\n isOpen,\n onOpenChange,\n ...props\n}: SheetContentProps) {\n const outer = use(SheetTriggerContext)\n const { close, present, setPresent, slots, state } = useModalState(outer, {\n defaultOpen,\n isOpen,\n onOpenChange,\n })\n\n if (!present) {\n return null\n }\n\n return (\n <SheetWindow\n {...props}\n close={close}\n isDismissable={isDismissable}\n isKeyboardDismissDisabled={isKeyboardDismissDisabled}\n isOpen={state.isOpen}\n setPresent={setPresent}\n slots={slots}\n />\n )\n}\n\n/**\n * The sheet's actions, leading and wrapping onto another row when they do not\n * fit on one, over a divider. On a bottom sheet at half height they are below\n * the fold until the sheet is raised, so a sheet opened for them takes\n * `initialHeight=\"whole\"` on `Sheet.Content`. `style`, `ref` and `testID`\n * land on its view.\n */\nfunction SheetFooter({ style, ...props }: SheetPartProps) {\n useLayout('Sheet.Footer')\n const styles = stylesOf(useTheme())\n\n return (\n <View {...props} style={composeStyles<ViewStyle>(styles.footer, style)} />\n )\n}\n\n/**\n * The bottom sheet's drag handle, a 32 by 4dp bar centred along its top edge.\n * Where the sheet has two heights it is a button moving it to the other one,\n * named \"Drag handle\" in the `I18nProvider`'s locale, or the device's outside\n * one, unless `aria-label` says otherwise; elsewhere it is a mark a screen reader skips. A side sheet draws\n * none. `style`, `ref` and `testID` land on its view.\n */\nfunction SheetHandle({\n 'aria-label': label,\n style,\n ...props\n}: SheetHandleProps) {\n const layout = useLayout('Sheet.Handle')\n const theme = useTheme()\n const styles = stylesOf(theme)\n const { colors, radii } = theme\n const feedback = usePressFeedback({\n color: colors.onSurfaceVariant,\n corners: { borderRadius: radii.pill },\n })\n const { toggle } = layout\n const messages = useMessages()\n\n if (!layout.bottom) {\n return null\n }\n\n if (toggle === undefined) {\n return (\n <View\n aria-hidden\n {...props}\n style={composeStyles<ViewStyle>(styles.handle, style)}\n >\n <View style={styles.bar} />\n </View>\n )\n }\n\n return (\n <Pressable\n aria-expanded={layout.expanded}\n aria-label={label ?? messages.dragHandle}\n role=\"button\"\n {...props}\n {...feedback.handlers}\n onPress={toggle}\n style={composeStyles<ViewStyle>(styles.handle, feedback.ring, style)}\n >\n {feedback.layer}\n <View style={styles.bar} />\n </Pressable>\n )\n}\n\n/**\n * The sheet's header: its `Sheet.Title`, and anything beside it, such as a\n * close button, over a divider. `style`, `ref` and `testID` land on its view.\n */\nfunction SheetHeader({ style, ...props }: SheetPartProps) {\n useLayout('Sheet.Header')\n const styles = stylesOf(useTheme())\n\n return (\n <View {...props} style={composeStyles<ViewStyle>(styles.header, style)} />\n )\n}\n\n/**\n * Names the sheet: the container is labelled by it, and a screen reader is\n * sent to it once the sheet shows. In title large on on-surface variant.\n * `style`, `ref` and `testID` land on React Native's own Text.\n */\nfunction SheetTitle({ ref, style, ...props }: SheetTitleProps) {\n const layout = useLayout('Sheet.Title')\n const styles = stylesOf(useTheme())\n const role = useTypeRole('titleLarge')\n\n return (\n <NativeText\n {...props}\n nativeID={layout.titleId}\n ref={refsOf(layout.setTitle, ref)}\n role=\"heading\"\n style={composeStyles<TextStyle>(role, styles.title, style)}\n />\n )\n}\n\n/**\n * The open sheet, mounted from the moment it opens until its exit has run, so\n * each opening starts from its edge and at its first height.\n */\nfunction SheetWindow({\n children,\n close,\n initialHeight = 'half',\n isDismissable,\n isKeyboardDismissDisabled,\n isOpen,\n onLayout,\n setPresent,\n slots,\n style,\n testID,\n ...props\n}: SheetWindowProps) {\n const styles = stylesOf(useTheme())\n const insets = use(SafeAreaInsetsContext) ?? NO_INSETS\n const { height } = useWindowDimensions()\n const bottom = useWindowSizeClass() === 'compact'\n const titleId = useId()\n const [title, setTitle] = useState<HostInstance | null>(null)\n // The panel's height as laid out, before any drag moves it, and whether a\n // sheet with two heights is at the higher one.\n const [full, setFull] = useState<null | number>(null)\n const [expanded, setExpanded] = useState(initialHeight === 'whole')\n const stops = stopsOf(bottom, full, height, isDismissable)\n const twoHeights = stops.partial !== null\n const rest = stops.partial !== null && !expanded ? stops.partial : 0\n const motion = useSheetMotion({ bottom, full, isOpen, rest, setPresent })\n const pan = useSheetDrag({\n close,\n enabled: bottom && isOpen && stops.settles.length > 1,\n expanded,\n full,\n isDismissable,\n offset: motion.offset,\n rest,\n setExpanded,\n stops,\n testID,\n })\n const toggle = useCallback(() => {\n setExpanded((was) => !was)\n }, [])\n const layout = useMemo<SheetLayout>(\n () => ({\n bottom,\n expanded: !twoHeights || expanded,\n pan,\n setTitle,\n titleId,\n toggle: twoHeights ? toggle : undefined,\n }),\n [bottom, expanded, pan, titleId, toggle, twoHeights],\n )\n const measure = useCallback(\n (event: LayoutChangeEvent) => {\n setFull(event.nativeEvent.layout.height)\n onLayout?.(event)\n },\n [onLayout],\n )\n const labelledBy = title === null ? undefined : titleId\n\n return (\n <ModalWindow\n isKeyboardDismissDisabled={isKeyboardDismissDisabled}\n labelledBy={labelledBy}\n onClose={close}\n onScrimPress={isDismissable && isOpen ? close : undefined}\n scrim={motion.scrim}\n title={title}\n >\n <GestureHandlerRootView\n style={bottom ? styles.rootBottom : styles.rootSide}\n >\n <GestureDetector gesture={pan}>\n <Animated.View\n {...panelRoleOf('dialog', labelledBy)}\n onAccessibilityEscape={\n isKeyboardDismissDisabled ? undefined : close\n }\n {...props}\n onLayout={measure}\n style={composeStyles<AnimatedStyle<ViewStyle>>(\n styles.container,\n bottom ? styles.containerBottom : styles.containerSide,\n bottom ? bottomBoundsOf(insets, height) : sideInsetsOf(insets),\n motion.panel,\n style,\n )}\n testID={testID}\n >\n <SheetLayoutContext value={layout}>\n <ButtonSlotContext value={slots}>{children}</ButtonSlotContext>\n </SheetLayoutContext>\n </Animated.View>\n </GestureDetector>\n </GestureHandlerRootView>\n </ModalWindow>\n )\n}\n\n// The side sheet's padding: its content under the status bar, over the home\n// indicator and inside the inset on its own edge. Its start edge faces the\n// screen it covers, which has none.\nfunction sideInsetsOf(insets: EdgeInsets): ViewStyle {\n return { ...insetsOf(insets), paddingStart: 0 }\n}\n\nfunction stopsOf(\n bottom: boolean,\n full: null | number,\n height: number,\n isDismissable: boolean,\n): Stops {\n if (!bottom || full === null) {\n return { partial: null, settles: [0] }\n }\n\n const lower = full - height * PARTIAL\n const partial = lower > 0 ? lower : null\n\n return {\n partial,\n settles: [\n 0,\n ...(partial === null ? [] : [partial]),\n ...(isDismissable ? [full] : []),\n ],\n }\n}\n\nfunction useLayout(part: string) {\n const layout = use(SheetLayoutContext)\n\n if (layout === null) {\n throw new Error(`${part} is drawn inside Sheet.Content.`)\n }\n\n return layout\n}\n\n/**\n * The bottom sheet's drag. The panel follows the finger, no higher than its\n * whole height and no lower than gone, or than its lowest height when it may\n * not be dismissed, and once let go it settles where `settleOf` says: below\n * the lowest height it closes, and at another height it moves the sheet there.\n */\nfunction useSheetDrag({\n close,\n enabled,\n expanded,\n full,\n isDismissable,\n offset,\n rest,\n setExpanded,\n stops,\n testID,\n}: {\n readonly close: () => void\n readonly enabled: boolean\n readonly expanded: boolean\n readonly full: null | number\n readonly isDismissable: boolean\n readonly offset: SharedValue<number>\n readonly rest: number\n readonly setExpanded: (expanded: boolean) => void\n readonly stops: Stops\n readonly testID: string | undefined\n}) {\n const { motion } = useTheme()\n const reduceMotion = useReducedMotion()\n // Where the panel stood when the drag was recognised. Gesture Handler\n // measures its translation from there, past the slop.\n const origin = useSharedValue(0)\n const lowest = stops.settles.at(-1) ?? 0\n\n function follow(translation: number) {\n offset.set(Math.min(lowest, Math.max(0, origin.get() + translation)))\n }\n\n function settle(target: number) {\n if (isDismissable && target === full) {\n close()\n return\n }\n\n const higher = target === 0\n if (stops.partial !== null && higher !== expanded) {\n setExpanded(higher)\n return\n }\n\n offset.set(\n reduceMotion\n ? target\n : withTiming(target, {\n duration: motion.durationMedium1,\n easing: Easing.bezier(...motion.easingEmphasizedDecelerate),\n }),\n )\n }\n\n // oxlint-disable-next-line react/capitalized-calls, typescript/no-deprecated -- a builder named after its gesture, not a component; see SheetLayout\n const pan = Gesture.Pan()\n .activeOffsetY([-DRAG_SLOP, DRAG_SLOP])\n .enabled(enabled)\n .runOnJS(true)\n .onStart(({ translationY }) => {\n origin.set(offset.get())\n follow(translationY)\n })\n .onUpdate(({ translationY }) => {\n follow(translationY)\n })\n .onEnd(({ velocityY }, success) => {\n settle(success ? settleOf(offset.get(), velocityY, stops.settles) : rest)\n })\n\n return testID === undefined ? pan : pan.withTestId(`${testID}-drag`)\n}\n\n/**\n * The scrim's and the panel's motion, and the timer that unmounts the sheet\n * once its exit has run. The bottom sheet's position is how far its panel is\n * moved down, which the drag sets too; it starts below the window and rises\n * to its height once that is measured. The side sheet's is how far it has\n * come in from its edge, which is the end edge, and so the left one under\n * right-to-left.\n */\nfunction useSheetMotion({\n bottom,\n full,\n isOpen,\n rest,\n setPresent,\n}: {\n readonly bottom: boolean\n readonly full: null | number\n readonly isOpen: boolean\n readonly rest: number\n readonly setPresent: (present: boolean) => void\n}) {\n const { motion } = useTheme()\n const reduceMotion = useReducedMotion()\n const { height } = useWindowDimensions()\n const offset = useSharedValue(height)\n const shown = useSharedValue(0)\n const scrim = useSharedValue(0)\n // A translation is not mirrored under a right-to-left layout, though the\n // side sheet's edge is, so it travels the other way there.\n const direction = I18nManager.isRTL ? -1 : 1\n\n useEffect(() => {\n const fade = {\n duration: motion.durationShort2,\n easing: Easing.bezier(...motion.easingStandard),\n }\n const enter = {\n duration: motion.durationMedium1,\n easing: Easing.bezier(...motion.easingEmphasizedDecelerate),\n }\n const exit = {\n duration: motion.durationShort3,\n easing: Easing.bezier(...motion.easingEmphasizedAccelerate),\n }\n\n if (isOpen) {\n scrim.set(withTiming(1, fade))\n if (!bottom) {\n shown.set(reduceMotion ? 1 : withTiming(1, enter))\n return undefined\n }\n if (full === null) {\n return undefined\n }\n // It rises from its own height below where it rests, not from the\n // bottom of the window, so it shows from the first frame.\n if (offset.get() > full) {\n offset.set(full)\n }\n offset.set(reduceMotion ? rest : withTiming(rest, enter))\n return undefined\n }\n\n scrim.set(withTiming(0, fade))\n if (bottom) {\n const gone = full ?? height\n offset.set(reduceMotion ? gone : withTiming(gone, exit))\n } else {\n shown.set(reduceMotion ? 0 : withTiming(0, exit))\n }\n const timer = setTimeout(\n () => {\n setPresent(false)\n },\n reduceMotion\n ? motion.durationShort2\n : Math.max(motion.durationShort2, motion.durationShort3),\n )\n\n return () => {\n clearTimeout(timer)\n }\n }, [\n bottom,\n full,\n height,\n isOpen,\n motion,\n offset,\n reduceMotion,\n rest,\n scrim,\n setPresent,\n shown,\n ])\n\n return {\n offset,\n panel: useAnimatedStyle(() => {\n 'worklet'\n if (bottom) {\n return { transform: [{ translateY: offset.get() }] }\n }\n\n const progress = shown.get()\n return {\n opacity: progress,\n transform: [{ translateX: (1 - progress) * SIDE_WIDTH * direction }],\n }\n }),\n scrim: useAnimatedStyle(() => {\n 'worklet'\n return { opacity: scrim.get() }\n }),\n }\n}\n\nSheet.Body = SheetBody\nSheet.Content = SheetContent\nSheet.Footer = SheetFooter\nSheet.Handle = SheetHandle\nSheet.Header = SheetHeader\nSheet.Title = SheetTitle\n\nexport {\n Sheet,\n SheetBody,\n SheetContent,\n SheetFooter,\n SheetHandle,\n SheetHeader,\n SheetTitle,\n}\nexport type {\n SheetBodyProps,\n SheetContentProps,\n SheetHandleProps,\n SheetPartProps,\n SheetProps,\n SheetTitleProps,\n}\n"],"mappings":";;;;;;;;;;;;;;;;;AA4HA,MAAM2D,aAAa;AAGnB,MAAMC,aAAa;AAGnB,MAAMC,UAAU;AAIhB,MAAMC,YAAY;AAKlB,MAAMC,QAAQ;AAId,MAAMC,YAAY;AAClB,MAAMC,aAAa;AACnB,MAAMC,YAAY;AAClB,MAAMC,WAAW;AAEjB,MAAMC,WAAWX,cACd,EAAEY,QAAQC,OAAOC,SAASC,cACzB7C,WAAW8C,OAAO;CAEhBC,KAAK;EACHC,iBAAiBN,OAAOO;EACxBC,cAAcP,MAAMQ;EACpBC,QAAQd;EACRe,OAAOhB;CACT;CAGAiB,MAAM;EACJC,KAAKV,QAAQW;EACbC,mBAAmBZ,QAAQa;EAC3BC,iBAAiBd,QAAQW;CAC3B;CAGAI,UAAU,EACRC,OAAOnB,OAAOO,iBAChB;CAEAa,WAAW;EACTd,iBAAiBN,OAAOqB;EACxBC,WAAWpB,QAAQqB;EACnBC,UAAU;CACZ;CAEAC,iBAAiB;EACfC,qBAAqBzB,MAAMe;EAC3BW,sBAAsB1B,MAAMe;EAC5BL,OAAO;CACT;CAGAiB,eAAe;EACbC,yBAA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1,111 @@
|
|
|
1
|
+
import { StyleProp, View, ViewStyle } from "react-native";
|
|
2
|
+
import { ComponentRef, ReactNode, Ref } from "react";
|
|
3
|
+
//#region src/components/slider/index.d.ts
|
|
4
|
+
type SliderProps = {
|
|
5
|
+
/**
|
|
6
|
+
* The slider's name for a screen reader, when no `label` is drawn: a
|
|
7
|
+
* slider that a row labels some other way leaves `label` out and passes
|
|
8
|
+
* this instead.
|
|
9
|
+
*/
|
|
10
|
+
readonly 'aria-label'?: string;
|
|
11
|
+
/** The value the slider starts at, when it keeps its own. */
|
|
12
|
+
readonly defaultValue?: number | number[];
|
|
13
|
+
/**
|
|
14
|
+
* How the value reads, in the indicator and to a screen reader, in the
|
|
15
|
+
* provider's locale.
|
|
16
|
+
*/
|
|
17
|
+
readonly formatOptions?: Intl.NumberFormatOptions;
|
|
18
|
+
/**
|
|
19
|
+
* The page's inset icon, at the start of the active part, from `md` up:
|
|
20
|
+
* the page gives it a size at M, L and XL alone. Drawn for a single
|
|
21
|
+
* handle, and only while the active part has room for it. It reads its
|
|
22
|
+
* colour and size through `useIconStyle()`.
|
|
23
|
+
*/
|
|
24
|
+
readonly icon?: ReactNode;
|
|
25
|
+
/**
|
|
26
|
+
* Draws the slider disabled, and takes no presses, drags or screen reader
|
|
27
|
+
* actions.
|
|
28
|
+
* @default false
|
|
29
|
+
*/
|
|
30
|
+
readonly isDisabled?: boolean;
|
|
31
|
+
/**
|
|
32
|
+
* What the slider sets. A slider that a row labels some other way leaves
|
|
33
|
+
* it out and passes `aria-label` instead.
|
|
34
|
+
*/
|
|
35
|
+
readonly label?: string;
|
|
36
|
+
/**
|
|
37
|
+
* The largest value.
|
|
38
|
+
* @default 100
|
|
39
|
+
*/
|
|
40
|
+
readonly maxValue?: number;
|
|
41
|
+
/**
|
|
42
|
+
* The smallest value.
|
|
43
|
+
* @default 0
|
|
44
|
+
*/
|
|
45
|
+
readonly minValue?: number;
|
|
46
|
+
/** Called with the value as it moves. */
|
|
47
|
+
readonly onChange?: (value: number | number[]) => void;
|
|
48
|
+
/** Called with the value once a drag, a press or an action has ended. */
|
|
49
|
+
readonly onChangeEnd?: (value: number | number[]) => void;
|
|
50
|
+
/**
|
|
51
|
+
* Along which axis the handle moves. A vertical slider is 240dp tall until
|
|
52
|
+
* `style` says otherwise.
|
|
53
|
+
* @default 'horizontal'
|
|
54
|
+
*/
|
|
55
|
+
readonly orientation?: 'horizontal' | 'vertical';
|
|
56
|
+
readonly ref?: Ref<ComponentRef<typeof View>>;
|
|
57
|
+
/**
|
|
58
|
+
* A stop at every step, the page's stops configuration, so the reader can
|
|
59
|
+
* see where the handle can land. Meant for a slider with a handful of
|
|
60
|
+
* steps: each stop is a 4dp dot, and a fine step draws a crowd of them.
|
|
61
|
+
* @default false
|
|
62
|
+
*/
|
|
63
|
+
readonly showStops?: boolean;
|
|
64
|
+
/**
|
|
65
|
+
* The page's sizes, by the track's thickness: 16dp at `xs`, 24dp at `sm`,
|
|
66
|
+
* 40dp at `md`, 56dp at `lg` and 96dp at `xl`, with the handle 44dp long
|
|
67
|
+
* up to `sm` and 52dp, 68dp and 108dp past it.
|
|
68
|
+
* @default 'xs'
|
|
69
|
+
*/
|
|
70
|
+
readonly size?: SliderSize;
|
|
71
|
+
/**
|
|
72
|
+
* The distance between two values the handle can land on.
|
|
73
|
+
* @default 1
|
|
74
|
+
*/
|
|
75
|
+
readonly step?: number;
|
|
76
|
+
readonly style?: StyleProp<ViewStyle>;
|
|
77
|
+
readonly testID?: string;
|
|
78
|
+
/**
|
|
79
|
+
* A name for each handle of a range slider, in order, since two handles
|
|
80
|
+
* named by the same label cannot be told apart.
|
|
81
|
+
*/
|
|
82
|
+
readonly thumbLabels?: readonly string[];
|
|
83
|
+
/**
|
|
84
|
+
* The value, for a call site holding it itself with `onChange`: a number
|
|
85
|
+
* for one handle, or an array of numbers for a handle each.
|
|
86
|
+
*/
|
|
87
|
+
readonly value?: number | number[];
|
|
88
|
+
};
|
|
89
|
+
type SliderSize = 'lg' | 'md' | 'sm' | 'xl' | 'xs';
|
|
90
|
+
/**
|
|
91
|
+
* A slider for one value, or for a range when the value is an array. Its
|
|
92
|
+
* state is React Stately's, as web's is: pass `value` with `onChange` to
|
|
93
|
+
* control it, or `defaultValue` to let it keep its own, with `minValue`,
|
|
94
|
+
* `maxValue` and `step` to shape it and `formatOptions` to say how it reads.
|
|
95
|
+
*
|
|
96
|
+
* ```tsx
|
|
97
|
+
* <Slider defaultValue={40} label="Label" />
|
|
98
|
+
* ```
|
|
99
|
+
*
|
|
100
|
+
* A press on the track moves the nearest handle there, and a drag carries
|
|
101
|
+
* it. A screen reader hears each handle as an adjustable control named by the
|
|
102
|
+
* label, which it moves a step at a time. `style`, `ref` and `testID` land on
|
|
103
|
+
* the slider as a whole, which is the view a layout positions and the one
|
|
104
|
+
* that gives a vertical slider its height. With a `testID`, the drag and the
|
|
105
|
+
* press are registered with Gesture Handler as `<testID>-pan` and
|
|
106
|
+
* `<testID>-tap`, which its `getByGestureTestId` finds in a test.
|
|
107
|
+
*/
|
|
108
|
+
declare function Slider({ 'aria-label': ariaLabel, defaultValue, formatOptions, icon, isDisabled, label, maxValue, minValue, onChange, onChangeEnd, orientation, ref, showStops, size, step, style, testID, thumbLabels, value }: SliderProps): import("react").JSX.Element;
|
|
109
|
+
//#endregion
|
|
110
|
+
export { Slider, type SliderProps, type SliderSize };
|
|
111
|
+
//# sourceMappingURL=index.d.ts.map
|