@agimon-ai/po-native-components 0.0.0-alpha.217 → 0.0.0-alpha.219
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/dist/components/Button.mjs +12 -8
- package/dist/components/Button.mjs.map +1 -1
- package/dist/components/FileList.mjs +2 -2
- package/dist/components/FileList.mjs.map +1 -1
- package/dist/components/Sheet.d.mts.map +1 -1
- package/dist/components/Sheet.mjs +2 -2
- package/dist/components/Sheet.mjs.map +1 -1
- package/dist/components/Tabs.mjs +1 -1
- package/dist/components/Tabs.mjs.map +1 -1
- package/dist/icons/iconGlyphs.d.mts +12 -0
- package/dist/icons/iconGlyphs.d.mts.map +1 -1
- package/dist/icons/iconGlyphs.mjs +12 -0
- package/dist/icons/iconGlyphs.mjs.map +1 -1
- package/dist/icons/icons.d.mts +12 -0
- package/dist/icons/icons.d.mts.map +1 -1
- package/dist/icons/icons.mjs +4 -1
- package/dist/icons/icons.mjs.map +1 -1
- package/dist/index.d.mts +2 -2
- package/dist/index.mjs +2 -2
- package/dist/po-runtime-identity.json +1 -1
- package/locales/vi.json +0 -1
- package/locales/zh-CN.json +0 -1
- package/package.json +6 -6
|
@@ -16,7 +16,7 @@ const PRESSED_FILL_OPACITY = .85;
|
|
|
16
16
|
const RIPPLE_ALPHA_PERCENT = 20;
|
|
17
17
|
/** `hover:border-po-green/50`. */
|
|
18
18
|
const PRESSED_EDGE_ALPHA_PERCENT = 50;
|
|
19
|
-
/** The visual height of each size, from which hitSlop pads the tap target to 44pt. */
|
|
19
|
+
/** The visual height of each size, from which hitSlop pads the tap target to 44pt. Text sizes grow past it with large type. */
|
|
20
20
|
const SIZE_HEIGHT = {
|
|
21
21
|
xs: 24,
|
|
22
22
|
sm: 28,
|
|
@@ -153,21 +153,25 @@ const styles = StyleSheet.create((theme) => ({
|
|
|
153
153
|
},
|
|
154
154
|
size: {
|
|
155
155
|
xs: {
|
|
156
|
-
|
|
156
|
+
minHeight: SIZE_HEIGHT.xs,
|
|
157
157
|
paddingHorizontal: theme.spacing(1.5),
|
|
158
|
+
paddingVertical: theme.spacing(.5),
|
|
158
159
|
borderRadius: theme.borderRadius.DEFAULT
|
|
159
160
|
},
|
|
160
161
|
sm: {
|
|
161
|
-
|
|
162
|
-
paddingHorizontal: theme.spacing(2.5)
|
|
162
|
+
minHeight: SIZE_HEIGHT.sm,
|
|
163
|
+
paddingHorizontal: theme.spacing(2.5),
|
|
164
|
+
paddingVertical: theme.spacing(.5)
|
|
163
165
|
},
|
|
164
166
|
md: {
|
|
165
|
-
|
|
166
|
-
paddingHorizontal: theme.spacing(3)
|
|
167
|
+
minHeight: SIZE_HEIGHT.md,
|
|
168
|
+
paddingHorizontal: theme.spacing(3),
|
|
169
|
+
paddingVertical: theme.spacing(.5)
|
|
167
170
|
},
|
|
168
171
|
lg: {
|
|
169
|
-
|
|
170
|
-
paddingHorizontal: theme.spacing(3.5)
|
|
172
|
+
minHeight: SIZE_HEIGHT.lg,
|
|
173
|
+
paddingHorizontal: theme.spacing(3.5),
|
|
174
|
+
paddingVertical: theme.spacing(.5)
|
|
171
175
|
},
|
|
172
176
|
icon: {
|
|
173
177
|
width: SIZE_HEIGHT.icon,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Button.mjs","names":["IconColorContext","NativeColorToken","withAlpha","ReactNode","PressableProps","StyleProp","ViewStyle","StyleSheet","useUnistyles","fontOf","impactLight","wrapText","Spinner","ButtonVariant","ButtonSize","MIN_TAP_TARGET","DISABLED_OPACITY","PRESSED_FILL_OPACITY","RIPPLE_ALPHA_PERCENT","PRESSED_EDGE_ALPHA_PERCENT","SIZE_HEIGHT","Readonly","Record","xs","sm","md","lg","icon","card","INK","rest","pressed","primary","secondary","outline","ghost","subtle","danger","success","link","HAPTIC_VARIANTS","ReadonlySet","Set","ButtonProps","Omit","variant","size","loading","loadingLabel","children","style","Button","disabled","onPress","hitSlop","accessibilityState","props","theme","_styles","styles","useVariants","inactive","slop","Math","max","ink","busy","undefined","text","color","colors","borderless","event","has","button","borderColor","green","token","label","labelPressed","create","flexDirection","alignItems","justifyContent","gap","spacing","borderRadius","borderWidth","overflow","variants","backgroundColor","selected","border","panel","red","height","paddingHorizontal","DEFAULT","width","padding","alignSelf","minHeight","paddingVertical","uni__dependencies","opacity","deep","fontFamily","sans","fontWeight","medium","semibold","fontSize","lineHeight","base","textDecorationLine"],"sources":["../../src/components/Button.tsx"],"sourcesContent":["import { IconColorContext } from '@agimon-ai/po-native-components/shell';\nimport { type NativeColorToken, withAlpha } from '@agimon-ai/po-web-components/nativeTheme';\nimport type { ReactNode } from 'react';\nimport { Pressable, type PressableProps, type StyleProp, type ViewStyle } from 'react-native';\nimport { StyleSheet, useUnistyles } from 'react-native-unistyles';\n\nimport { fontOf } from '../lib/fonts';\nimport { impactLight } from '../lib/haptics';\nimport { wrapText } from '../lib/wrapText';\nimport { Spinner } from './Spinner';\n\nexport type ButtonVariant =\n | 'primary'\n | 'secondary'\n | 'outline'\n | 'ghost'\n | 'subtle'\n | 'danger'\n | 'danger-outline'\n | 'success'\n | 'link';\nexport type ButtonSize = 'xs' | 'sm' | 'md' | 'lg' | 'icon' | 'icon-md' | 'card';\n\n/** Apple's and Google's minimum tap target; a smaller visual box makes up the rest with hitSlop. */\nconst MIN_TAP_TARGET = 44;\nconst DISABLED_OPACITY = 0.4;\nconst PRESSED_FILL_OPACITY = 0.85;\nconst RIPPLE_ALPHA_PERCENT = 20;\n/** `hover:border-po-green/50`. */\nconst PRESSED_EDGE_ALPHA_PERCENT = 50;\n\n/** The visual height of each size, from which hitSlop pads the tap target to 44pt. */\nconst SIZE_HEIGHT: Readonly<Record<ButtonSize, number>> = {\n xs: 24,\n sm: 28,\n md: 32,\n lg: 36,\n icon: 24,\n 'icon-md': 32,\n card: MIN_TAP_TARGET,\n};\n\n/** The label ink of each variant, and the ink it lifts to while pressed (the web hover). */\nconst INK: Readonly<Record<ButtonVariant, { rest: NativeColorToken; pressed: NativeColorToken }>> = {\n primary: { rest: 'on-selected', pressed: 'on-selected' },\n secondary: { rest: 'magenta', pressed: 'magenta' },\n outline: { rest: 'dim', pressed: 'hi' },\n ghost: { rest: 'dim', pressed: 'hi' },\n subtle: { rest: 'dim', pressed: 'hi' },\n danger: { rest: 'rail', pressed: 'rail' },\n 'danger-outline': { rest: 'red', pressed: 'red' },\n success: { rest: 'rail', pressed: 'rail' },\n link: { rest: 'blue', pressed: 'blue' },\n};\n\n/** Presses that commit something get a light impact; the rest stay quiet. */\nconst HAPTIC_VARIANTS: ReadonlySet<ButtonVariant> = new Set(['primary', 'danger', 'success']);\n\nexport interface ButtonProps extends Omit<PressableProps, 'children' | 'style'> {\n variant?: ButtonVariant;\n size?: ButtonSize;\n /** Work is in flight: the button shows a spinner and stops accepting presses. */\n loading?: boolean;\n /** What the spinner announces while loading; omit it and the wait is silent. */\n loadingLabel?: string;\n /** A bare string is drawn as the label; elements (an icon, a card's lines) render as given. */\n children?: ReactNode;\n style?: StyleProp<ViewStyle>;\n}\n\n/** The one button: every variant is a theme token, a press dims or lifts it, and committing presses buzz once. */\nexport function Button({\n variant = 'outline',\n size = 'md',\n loading = false,\n loadingLabel,\n disabled,\n onPress,\n children,\n style,\n hitSlop,\n accessibilityState,\n ...props\n}: ButtonProps) {\n const { theme } = useUnistyles();\n styles.useVariants({ variant, size });\n const inactive = (disabled ?? false) || loading;\n const slop = Math.max(0, (MIN_TAP_TARGET - SIZE_HEIGHT[size]) / 2);\n const ink = INK[variant];\n return (\n <Pressable\n accessibilityRole={variant === 'link' ? 'link' : 'button'}\n accessibilityState={{ ...accessibilityState, disabled: inactive, busy: loading }}\n accessibilityValue={loading && loadingLabel !== undefined ? { text: loadingLabel } : undefined}\n disabled={inactive}\n hitSlop={hitSlop ?? slop}\n android_ripple={{ color: withAlpha(theme.colors[ink.pressed], RIPPLE_ALPHA_PERCENT), borderless: false }}\n onPress={(event) => {\n if (HAPTIC_VARIANTS.has(variant)) impactLight();\n onPress?.(event);\n }}\n style={({ pressed }) => [\n styles.button,\n pressed && styles.pressed,\n // Alpha mixes are computed in render from useUnistyles(), not in StyleSheet.create: on web Unistyles hands\n // the stylesheet CSS variables, which withAlpha cannot read.\n pressed && variant === 'outline' && { borderColor: withAlpha(theme.colors.green, PRESSED_EDGE_ALPHA_PERCENT) },\n inactive && styles.disabled,\n style,\n ]}\n {...props}\n >\n {({ pressed }) => {\n const token = pressed ? ink.pressed : ink.rest;\n return (\n <IconColorContext.Provider value={token}>\n {loading ? <Spinner color={token} /> : null}\n {wrapText(children, [styles.label, pressed && styles.labelPressed, { color: theme.colors[token] }])}\n </IconColorContext.Provider>\n );\n }}\n </Pressable>\n );\n}\n\nconst styles = StyleSheet.create((theme) => ({\n button: {\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'center',\n gap: theme.spacing(1.5),\n borderRadius: theme.borderRadius.md,\n borderWidth: 1,\n borderColor: 'transparent',\n overflow: 'hidden',\n variants: {\n variant: {\n primary: { backgroundColor: theme.colors.selected },\n secondary: { borderColor: theme.colors['edge-magenta'], backgroundColor: theme.colors['tint-magenta'] },\n outline: { borderColor: theme.colors.border },\n ghost: {},\n subtle: { backgroundColor: theme.colors.panel },\n danger: { backgroundColor: theme.colors.red },\n 'danger-outline': { borderColor: theme.colors['edge-red'], backgroundColor: theme.colors['tint-red'] },\n success: { backgroundColor: theme.colors.green },\n link: {},\n },\n size: {\n xs: { height: SIZE_HEIGHT.xs, paddingHorizontal: theme.spacing(1.5), borderRadius: theme.borderRadius.DEFAULT },\n sm: { height: SIZE_HEIGHT.sm, paddingHorizontal: theme.spacing(2.5) },\n md: { height: SIZE_HEIGHT.md, paddingHorizontal: theme.spacing(3) },\n lg: { height: SIZE_HEIGHT.lg, paddingHorizontal: theme.spacing(3.5) },\n icon: {\n width: SIZE_HEIGHT.icon,\n height: SIZE_HEIGHT.icon,\n padding: 0,\n borderRadius: theme.borderRadius.DEFAULT,\n },\n 'icon-md': { width: SIZE_HEIGHT['icon-md'], height: SIZE_HEIGHT['icon-md'], padding: 0 },\n card: {\n alignSelf: 'stretch',\n flexDirection: 'column',\n alignItems: 'stretch',\n justifyContent: 'flex-start',\n gap: theme.spacing(1),\n minHeight: SIZE_HEIGHT.card,\n paddingHorizontal: 11,\n paddingVertical: theme.spacing(2.5),\n },\n },\n },\n },\n pressed: {\n variants: {\n variant: {\n primary: { opacity: PRESSED_FILL_OPACITY },\n secondary: { opacity: PRESSED_FILL_OPACITY },\n outline: {},\n ghost: { backgroundColor: theme.colors.panel },\n subtle: { backgroundColor: theme.colors.deep },\n danger: { opacity: PRESSED_FILL_OPACITY },\n 'danger-outline': { opacity: PRESSED_FILL_OPACITY },\n success: { opacity: PRESSED_FILL_OPACITY },\n link: {},\n },\n },\n },\n disabled: { opacity: DISABLED_OPACITY },\n label: {\n fontFamily: fontOf(theme.fontFamily.sans),\n fontWeight: theme.fontWeight.medium,\n variants: {\n variant: {\n primary: { fontWeight: theme.fontWeight.semibold },\n secondary: { fontWeight: theme.fontWeight.semibold },\n outline: {},\n ghost: {},\n subtle: {},\n danger: { fontWeight: theme.fontWeight.semibold },\n 'danger-outline': { fontWeight: theme.fontWeight.semibold },\n success: { fontWeight: theme.fontWeight.semibold },\n link: {},\n },\n size: {\n xs: { fontSize: theme.fontSize.sm, lineHeight: theme.lineHeight.sm },\n sm: { fontSize: theme.fontSize.sm, lineHeight: theme.lineHeight.sm },\n md: { fontSize: theme.fontSize.base, lineHeight: theme.lineHeight.base },\n lg: { fontSize: theme.fontSize.base, lineHeight: theme.lineHeight.base },\n icon: { fontSize: theme.fontSize.base, lineHeight: theme.lineHeight.base },\n 'icon-md': { fontSize: theme.fontSize.base, lineHeight: theme.lineHeight.base },\n card: { fontSize: theme.fontSize.base, lineHeight: theme.lineHeight.base },\n },\n },\n },\n labelPressed: {\n variants: {\n variant: {\n primary: {},\n secondary: {},\n outline: {},\n ghost: {},\n subtle: {},\n danger: {},\n 'danger-outline': {},\n success: {},\n link: { textDecorationLine: 'underline' },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C;IAAK;IACvEtF,MAAM;KAAEoF,UAAUtD,MAAMsD,SAASE;KAAMD,YAAYvD,MAAMuD,WAAWC;IAAK;IACzE,WAAW;KAAEF,UAAUtD,MAAMsD,SAASE;KAAMD,YAAYvD,MAAMuD,WAAWC;IAAK;IAC9ErF,MAAM;KAAEmF,UAAUtD,MAAMsD,SAASE;KAAMD,YAAYvD,MAAMuD,WAAWC;IAAK;GAC3E;EACF;EAACV,mBAAA,CAAA,GAAA,CAAA;CACH;CACAxB,cAAc;EACZU,UAAU,EACR5C,SAAS;GACPb,SAAS,CAAC;GACVC,WAAW,CAAC;GACZC,SAAS,CAAC;GACVC,OAAO,CAAC;GACRC,QAAQ,CAAC;GACTC,QAAQ,CAAC;GACT,kBAAkB,CAAC;GACnBC,SAAS,CAAC;GACVC,MAAM,EAAE2E,oBAAoB,YAAY;EAC1C,EACF;EAACX,mBAAA,CAAA,CAAA;CACH;AACF,EAAE"}
|
|
1
|
+
{"version":3,"file":"Button.mjs","names":["IconColorContext","NativeColorToken","withAlpha","ReactNode","PressableProps","StyleProp","ViewStyle","StyleSheet","useUnistyles","fontOf","impactLight","wrapText","Spinner","ButtonVariant","ButtonSize","MIN_TAP_TARGET","DISABLED_OPACITY","PRESSED_FILL_OPACITY","RIPPLE_ALPHA_PERCENT","PRESSED_EDGE_ALPHA_PERCENT","SIZE_HEIGHT","Readonly","Record","xs","sm","md","lg","icon","card","INK","rest","pressed","primary","secondary","outline","ghost","subtle","danger","success","link","HAPTIC_VARIANTS","ReadonlySet","Set","ButtonProps","Omit","variant","size","loading","loadingLabel","children","style","Button","disabled","onPress","hitSlop","accessibilityState","props","theme","_styles","styles","useVariants","inactive","slop","Math","max","ink","busy","undefined","text","color","colors","borderless","event","has","button","borderColor","green","token","label","labelPressed","create","flexDirection","alignItems","justifyContent","gap","spacing","borderRadius","borderWidth","overflow","variants","backgroundColor","selected","border","panel","red","minHeight","paddingHorizontal","paddingVertical","DEFAULT","width","height","padding","alignSelf","uni__dependencies","opacity","deep","fontFamily","sans","fontWeight","medium","semibold","fontSize","lineHeight","base","textDecorationLine"],"sources":["../../src/components/Button.tsx"],"sourcesContent":["import { IconColorContext } from '@agimon-ai/po-native-components/shell';\nimport { type NativeColorToken, withAlpha } from '@agimon-ai/po-web-components/nativeTheme';\nimport type { ReactNode } from 'react';\nimport { Pressable, type PressableProps, type StyleProp, type ViewStyle } from 'react-native';\nimport { StyleSheet, useUnistyles } from 'react-native-unistyles';\n\nimport { fontOf } from '../lib/fonts';\nimport { impactLight } from '../lib/haptics';\nimport { wrapText } from '../lib/wrapText';\nimport { Spinner } from './Spinner';\n\nexport type ButtonVariant =\n | 'primary'\n | 'secondary'\n | 'outline'\n | 'ghost'\n | 'subtle'\n | 'danger'\n | 'danger-outline'\n | 'success'\n | 'link';\nexport type ButtonSize = 'xs' | 'sm' | 'md' | 'lg' | 'icon' | 'icon-md' | 'card';\n\n/** Apple's and Google's minimum tap target; a smaller visual box makes up the rest with hitSlop. */\nconst MIN_TAP_TARGET = 44;\nconst DISABLED_OPACITY = 0.4;\nconst PRESSED_FILL_OPACITY = 0.85;\nconst RIPPLE_ALPHA_PERCENT = 20;\n/** `hover:border-po-green/50`. */\nconst PRESSED_EDGE_ALPHA_PERCENT = 50;\n\n/** The visual height of each size, from which hitSlop pads the tap target to 44pt. Text sizes grow past it with large type. */\nconst SIZE_HEIGHT: Readonly<Record<ButtonSize, number>> = {\n xs: 24,\n sm: 28,\n md: 32,\n lg: 36,\n icon: 24,\n 'icon-md': 32,\n card: MIN_TAP_TARGET,\n};\n\n/** The label ink of each variant, and the ink it lifts to while pressed (the web hover). */\nconst INK: Readonly<Record<ButtonVariant, { rest: NativeColorToken; pressed: NativeColorToken }>> = {\n primary: { rest: 'on-selected', pressed: 'on-selected' },\n secondary: { rest: 'magenta', pressed: 'magenta' },\n outline: { rest: 'dim', pressed: 'hi' },\n ghost: { rest: 'dim', pressed: 'hi' },\n subtle: { rest: 'dim', pressed: 'hi' },\n danger: { rest: 'rail', pressed: 'rail' },\n 'danger-outline': { rest: 'red', pressed: 'red' },\n success: { rest: 'rail', pressed: 'rail' },\n link: { rest: 'blue', pressed: 'blue' },\n};\n\n/** Presses that commit something get a light impact; the rest stay quiet. */\nconst HAPTIC_VARIANTS: ReadonlySet<ButtonVariant> = new Set(['primary', 'danger', 'success']);\n\nexport interface ButtonProps extends Omit<PressableProps, 'children' | 'style'> {\n variant?: ButtonVariant;\n size?: ButtonSize;\n /** Work is in flight: the button shows a spinner and stops accepting presses. */\n loading?: boolean;\n /** What the spinner announces while loading; omit it and the wait is silent. */\n loadingLabel?: string;\n /** A bare string is drawn as the label; elements (an icon, a card's lines) render as given. */\n children?: ReactNode;\n style?: StyleProp<ViewStyle>;\n}\n\n/** The one button: every variant is a theme token, a press dims or lifts it, and committing presses buzz once. */\nexport function Button({\n variant = 'outline',\n size = 'md',\n loading = false,\n loadingLabel,\n disabled,\n onPress,\n children,\n style,\n hitSlop,\n accessibilityState,\n ...props\n}: ButtonProps) {\n const { theme } = useUnistyles();\n styles.useVariants({ variant, size });\n const inactive = (disabled ?? false) || loading;\n const slop = Math.max(0, (MIN_TAP_TARGET - SIZE_HEIGHT[size]) / 2);\n const ink = INK[variant];\n return (\n <Pressable\n accessibilityRole={variant === 'link' ? 'link' : 'button'}\n accessibilityState={{ ...accessibilityState, disabled: inactive, busy: loading }}\n accessibilityValue={loading && loadingLabel !== undefined ? { text: loadingLabel } : undefined}\n disabled={inactive}\n hitSlop={hitSlop ?? slop}\n android_ripple={{ color: withAlpha(theme.colors[ink.pressed], RIPPLE_ALPHA_PERCENT), borderless: false }}\n onPress={(event) => {\n if (HAPTIC_VARIANTS.has(variant)) impactLight();\n onPress?.(event);\n }}\n style={({ pressed }) => [\n styles.button,\n pressed && styles.pressed,\n // Alpha mixes are computed in render from useUnistyles(), not in StyleSheet.create: on web Unistyles hands\n // the stylesheet CSS variables, which withAlpha cannot read.\n pressed && variant === 'outline' && { borderColor: withAlpha(theme.colors.green, PRESSED_EDGE_ALPHA_PERCENT) },\n inactive && styles.disabled,\n style,\n ]}\n {...props}\n >\n {({ pressed }) => {\n const token = pressed ? ink.pressed : ink.rest;\n return (\n <IconColorContext.Provider value={token}>\n {loading ? <Spinner color={token} /> : null}\n {wrapText(children, [styles.label, pressed && styles.labelPressed, { color: theme.colors[token] }])}\n </IconColorContext.Provider>\n );\n }}\n </Pressable>\n );\n}\n\nconst styles = StyleSheet.create((theme) => ({\n button: {\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'center',\n gap: theme.spacing(1.5),\n borderRadius: theme.borderRadius.md,\n borderWidth: 1,\n borderColor: 'transparent',\n overflow: 'hidden',\n variants: {\n variant: {\n primary: { backgroundColor: theme.colors.selected },\n secondary: { borderColor: theme.colors['edge-magenta'], backgroundColor: theme.colors['tint-magenta'] },\n outline: { borderColor: theme.colors.border },\n ghost: {},\n subtle: { backgroundColor: theme.colors.panel },\n danger: { backgroundColor: theme.colors.red },\n 'danger-outline': { borderColor: theme.colors['edge-red'], backgroundColor: theme.colors['tint-red'] },\n success: { backgroundColor: theme.colors.green },\n link: {},\n },\n size: {\n // minHeight, not height: a label at a large Dynamic Type size wraps and grows instead of clipping.\n xs: {\n minHeight: SIZE_HEIGHT.xs,\n paddingHorizontal: theme.spacing(1.5),\n paddingVertical: theme.spacing(0.5),\n borderRadius: theme.borderRadius.DEFAULT,\n },\n sm: { minHeight: SIZE_HEIGHT.sm, paddingHorizontal: theme.spacing(2.5), paddingVertical: theme.spacing(0.5) },\n md: { minHeight: SIZE_HEIGHT.md, paddingHorizontal: theme.spacing(3), paddingVertical: theme.spacing(0.5) },\n lg: { minHeight: SIZE_HEIGHT.lg, paddingHorizontal: theme.spacing(3.5), paddingVertical: theme.spacing(0.5) },\n icon: {\n width: SIZE_HEIGHT.icon,\n height: SIZE_HEIGHT.icon,\n padding: 0,\n borderRadius: theme.borderRadius.DEFAULT,\n },\n 'icon-md': { width: SIZE_HEIGHT['icon-md'], height: SIZE_HEIGHT['icon-md'], padding: 0 },\n card: {\n alignSelf: 'stretch',\n flexDirection: 'column',\n alignItems: 'stretch',\n justifyContent: 'flex-start',\n gap: theme.spacing(1),\n minHeight: SIZE_HEIGHT.card,\n paddingHorizontal: 11,\n paddingVertical: theme.spacing(2.5),\n },\n },\n },\n },\n pressed: {\n variants: {\n variant: {\n primary: { opacity: PRESSED_FILL_OPACITY },\n secondary: { opacity: PRESSED_FILL_OPACITY },\n outline: {},\n ghost: { backgroundColor: theme.colors.panel },\n subtle: { backgroundColor: theme.colors.deep },\n danger: { opacity: PRESSED_FILL_OPACITY },\n 'danger-outline': { opacity: PRESSED_FILL_OPACITY },\n success: { opacity: PRESSED_FILL_OPACITY },\n link: {},\n },\n },\n },\n disabled: { opacity: DISABLED_OPACITY },\n label: {\n fontFamily: fontOf(theme.fontFamily.sans),\n fontWeight: theme.fontWeight.medium,\n variants: {\n variant: {\n primary: { fontWeight: theme.fontWeight.semibold },\n secondary: { fontWeight: theme.fontWeight.semibold },\n outline: {},\n ghost: {},\n subtle: {},\n danger: { fontWeight: theme.fontWeight.semibold },\n 'danger-outline': { fontWeight: theme.fontWeight.semibold },\n success: { fontWeight: theme.fontWeight.semibold },\n link: {},\n },\n size: {\n xs: { fontSize: theme.fontSize.sm, lineHeight: theme.lineHeight.sm },\n sm: { fontSize: theme.fontSize.sm, lineHeight: theme.lineHeight.sm },\n md: { fontSize: theme.fontSize.base, lineHeight: theme.lineHeight.base },\n lg: { fontSize: theme.fontSize.base, lineHeight: theme.lineHeight.base },\n icon: { fontSize: theme.fontSize.base, lineHeight: theme.lineHeight.base },\n 'icon-md': { fontSize: theme.fontSize.base, lineHeight: theme.lineHeight.base },\n card: { fontSize: theme.fontSize.base, lineHeight: theme.lineHeight.base },\n },\n },\n },\n labelPressed: {\n variants: {\n variant: {\n primary: {},\n secondary: {},\n outline: {},\n ghost: {},\n subtle: {},\n danger: {},\n 'danger-outline': {},\n success: {},\n link: { textDecorationLine: 'underline' },\n },\n },\n },\n}));\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AUtD,MAAMsD,SAASE;KAAMD,YAAYvD,MAAMuD,WAAWC;IAAK;IACvEvF,IAAI;KAAEqF,UAAUtD,MAAMsD,SAASE;KAAMD,YAAYvD,MAAMuD,WAAWC;IAAK;IACvEtF,MAAM;KAAEoF,UAAUtD,MAAMsD,SAASE;KAAMD,YAAYvD,MAAMuD,WAAWC;IAAK;IACzE,WAAW;KAAEF,UAAUtD,MAAMsD,SAASE;KAAMD,YAAYvD,MAAMuD,WAAWC;IAAK;IAC9ErF,MAAM;KAAEmF,UAAUtD,MAAMsD,SAASE;KAAMD,YAAYvD,MAAMuD,WAAWC;IAAK;GAC3E;EACF;EAACV,mBAAA,CAAA,GAAA,CAAA;CACH;CACAxB,cAAc;EACZU,UAAU,EACR5C,SAAS;GACPb,SAAS,CAAC;GACVC,WAAW,CAAC;GACZC,SAAS,CAAC;GACVC,OAAO,CAAC;GACRC,QAAQ,CAAC;GACTC,QAAQ,CAAC;GACT,kBAAkB,CAAC;GACnBC,SAAS,CAAC;GACVC,MAAM,EAAE2E,oBAAoB,YAAY;EAC1C,EACF;EAACX,mBAAA,CAAA,CAAA;CACH;AACF,EAAE"}
|
|
@@ -14,7 +14,7 @@ import { Text } from "react-native-unistyles/components/native/Text";
|
|
|
14
14
|
import { StyleSheet } from "react-native-unistyles";
|
|
15
15
|
import { createElement, useCallback, useEffect, useRef, useState } from "react";
|
|
16
16
|
import { Fragment as Fragment$1, jsx, jsxs } from "react/jsx-runtime";
|
|
17
|
-
import {
|
|
17
|
+
import { useT } from "@agimon-ai/po-core/native";
|
|
18
18
|
import { ScrollView } from "react-native-unistyles/components/native/ScrollView";
|
|
19
19
|
import { FlatList } from "react-native-unistyles/components/native/FlatList";
|
|
20
20
|
|
|
@@ -77,7 +77,7 @@ function FileList({ items, onOpen, loading, error, onRetry, grid = false, browse
|
|
|
77
77
|
}) : null,
|
|
78
78
|
grid ? /* @__PURE__ */ jsx(Text, {
|
|
79
79
|
style: styles.meta,
|
|
80
|
-
children:
|
|
80
|
+
children: sizeLabel(item.size)
|
|
81
81
|
}) : null
|
|
82
82
|
]
|
|
83
83
|
})]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FileList.mjs","names":["currentLocale","useT","fileKind","isFileLayout","sizeLabel","FileItem","FileKind","FileLayout","FileModified","FileSort","FileSortDirection","FileTreeRow","ComponentRef","ReactNode","useCallback","useEffect","useRef","useState","ListViewToken","StyleSheet","ChevronDownIcon","ChevronRightIcon","CloseIcon","FileIcon","FolderIcon","ImageIcon","SearchIcon","SlidersIcon","fileKindLabel","fontOf","Button","DropdownMenu","DropdownMenuCheckboxItem","DropdownMenuContent","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuTrigger","EmptyState","Input","SegmentedControl","Sheet","SheetContent","SheetList","FileBrowserControls","layout","onLayoutChange","query","onQueryChange","type","onTypeChange","modified","onModifiedChange","sort","onSortChange","direction","onDirectionChange","rows","onToggleDirectory","path","selected","onSelect","item","onCloseSelection","totalCount","onViewableImagesChange","paths","renderImage","compact","header","sheet","FileListProps","items","onOpen","loading","error","onRetry","label","emptyText","grid","browser","FileList","t","styles","list","length","meta","map","name","size","toLocaleString","Translate","ReturnType","layoutOptions","value","TYPES","const","modifiedOptions","sortOptions","ROW_HEIGHT","IMAGE_VIEWABILITY","itemVisiblePercentThreshold","MAX_DOTS","PREVIEW_HEIGHT","ListFailure","retained","onAction","undefined","FileBrowserList","b","LAYOUTS","MODIFIED","SORTS","onViewableItemsChanged","viewableItems","Omit","flatMap","isViewable","kind","depth","files","row","at","findIndex","file","List","FlatList","embedded","columns","head","toolbar","search","searchInput","chips","find","option","inset","indent","open","expanded","count","image","tile","chevronGutter","thumbnail","rowThumbnail","foot","shown","total","selection","titleRow","index","Math","max","actions","SelectionSlides","width","setWidth","scroller","ScrollView","placed","current","scrollTo","x","animated","step","by","next","event","nativeEvent","round","contentOffset","preview","page","abs","arrow","previous","flip","dots","dot","dotActive","create","theme","gap","spacing","padding","paddingBottom","uni__dependencies","paddingTop","paddingHorizontal","flexDirection","alignItems","flex","minWidth","borderWidth","borderColor","colors","border","borderRadius","DEFAULT","backgroundColor","deep","flexWrap","marginHorizontal","marginBottom","minHeight","justifyContent","paddingVertical","paddingRight","paddingLeft","maxWidth","height","overflow","sm","flexShrink","panel","position","top","left","right","transform","rotate","faint","green","fontFamily","sans","fontWeight","fontSize","base","color","text","mono","dim"],"sources":["../../src/components/FileList.tsx"],"sourcesContent":["import { currentLocale, useT } from '@agimon-ai/po-core/native';\nimport {\n fileKind,\n isFileLayout,\n sizeLabel,\n type FileItem,\n type FileKind,\n type FileLayout,\n type FileModified,\n type FileSort,\n type FileSortDirection,\n type FileTreeRow,\n} from '@agimon-ai/po-web-components/text';\nimport { type ComponentRef, type ReactNode, useCallback, useEffect, useRef, useState } from 'react';\nimport { FlatList, ScrollView, Text, View, type ListViewToken } from 'react-native';\nimport { StyleSheet } from 'react-native-unistyles';\n\nimport {\n ChevronDownIcon,\n ChevronRightIcon,\n CloseIcon,\n FileIcon,\n FolderIcon,\n ImageIcon,\n SearchIcon,\n SlidersIcon,\n} from '../icons/icons';\nimport { fileKindLabel } from '../lib/fileKindLabel';\nimport { fontOf } from '../lib/fonts';\nimport { Button } from './Button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n DropdownMenuTrigger,\n} from './DropdownMenu';\nimport { EmptyState } from './EmptyState';\nimport { Input } from './Input';\nimport { SegmentedControl } from './SegmentedControl';\nimport { Sheet, SheetContent } from './Sheet';\nimport { SheetList } from './SheetList';\n\nexport interface FileBrowserControls {\n layout: FileLayout;\n onLayoutChange: (layout: FileLayout) => void;\n query: string;\n onQueryChange: (query: string) => void;\n type: FileKind | 'any';\n onTypeChange: (type: FileKind | 'any') => void;\n modified: FileModified;\n onModifiedChange: (modified: FileModified) => void;\n sort: FileSort;\n onSortChange: (sort: FileSort) => void;\n direction: FileSortDirection;\n onDirectionChange: (direction: FileSortDirection) => void;\n rows: readonly FileTreeRow[];\n onToggleDirectory: (path: string) => void;\n selected?: FileItem;\n onSelect: (item: FileItem) => void;\n onCloseSelection: () => void;\n totalCount: number;\n onViewableImagesChange?: (paths: readonly string[]) => void;\n /** A loaded thumbnail or a placeholder for an image file; `compact` is a list row's small square. */\n renderImage?: (item: FileItem, compact: boolean) => ReactNode;\n /** Drawn first in the list, above the controls, such as the native dock's tab strip. */\n header?: ReactNode;\n /** Inside a bottom sheet with no scroll view of its own: the list is the sheet's only scroll owner. */\n sheet?: boolean;\n}\n\nexport interface FileListProps {\n items: readonly FileItem[];\n onOpen: (path: string) => void;\n loading?: boolean;\n error?: string;\n /** Offered beside a failed read as Try again. */\n onRetry?: () => void;\n /** Names the list for search and layout, such as \"artifacts\" or \"Personal\". */\n label: string;\n /** Guidance under the empty card's title: why the list is empty and what fills it. */\n emptyText: string;\n grid?: boolean;\n browser?: FileBrowserControls;\n}\n\n/** A folder of files on the phone: recent rows, or a browser with layouts, filters and a swipeable selection. Presentation only. */\nexport function FileList({\n items,\n onOpen,\n loading,\n error,\n onRetry,\n grid = false,\n browser,\n label,\n emptyText,\n}: FileListProps) {\n const t = useT();\n if (browser)\n return (\n <FileBrowserList\n label={label}\n emptyText={emptyText}\n items={items}\n onOpen={onOpen}\n loading={loading}\n error={error}\n onRetry={onRetry}\n browser={browser}\n />\n );\n return (\n <View testID={grid ? 'file-list-grid' : 'file-list-recent'} style={styles.list}>\n {error ? <ListFailure error={error} retained={items.length > 0} onRetry={onRetry} /> : null}\n {loading ? <Text style={styles.meta}>{t('nativeComponents.fileList.loading', 'Loading files...')}</Text> : null}\n {!loading && !error && items.length === 0 ? (\n <EmptyState\n size=\"compact\"\n surface=\"plain\"\n icon={<FolderIcon size={16} />}\n title={t('nativeComponents.fileList.emptyTitle', 'Nothing here yet')}\n description={emptyText}\n />\n ) : null}\n {items.map((item) => (\n <Button\n key={item.path}\n variant={grid ? 'outline' : 'ghost'}\n size=\"card\"\n accessibilityLabel={t('nativeComponents.fileList.open', 'Open {path}', { path: item.path })}\n testID={`file-${item.path}`}\n onPress={() => onOpen(item.path)}\n style={styles.item}\n >\n <FileIcon size={18} color=\"dim\" />\n <View style={styles.label}>\n <Text numberOfLines={1} style={styles.name}>\n {item.name}\n </Text>\n {grid || item.path !== item.name ? (\n <Text numberOfLines={1} style={styles.path}>\n {item.path}\n </Text>\n ) : null}\n {grid ? (\n <Text style={styles.meta}>\n {t('nativeComponents.fileList.bytes', '{size} bytes', {\n size: item.size.toLocaleString(currentLocale()),\n })}\n </Text>\n ) : null}\n </View>\n </Button>\n ))}\n </View>\n );\n}\n\ntype Translate = ReturnType<typeof useT>;\nconst layoutOptions = (t: Translate) => [\n { value: 'tree', label: t('nativeComponents.fileList.layout.tree', 'Tree') },\n { value: 'list', label: t('nativeComponents.fileList.layout.list', 'List') },\n { value: 'grid', label: t('nativeComponents.fileList.layout.grid', 'Grid') },\n];\nconst TYPES = ['any', 'Markdown', 'Image', 'Code', 'Data', 'Document', 'Other'] as const;\nconst modifiedOptions = (t: Translate) =>\n [\n { value: 'any', label: t('nativeComponents.fileList.modified.any', 'Any time') },\n { value: 'today', label: t('nativeComponents.fileList.modified.today', 'Today') },\n { value: '7days', label: t('nativeComponents.fileList.modified.7days', 'Last 7 days') },\n { value: '30days', label: t('nativeComponents.fileList.modified.30days', 'Last 30 days') },\n ] as const;\nconst sortOptions = (t: Translate) =>\n [\n { value: 'name', label: t('nativeComponents.fileList.sort.name', 'Name') },\n { value: 'modified', label: t('nativeComponents.fileList.sort.modified', 'Modified') },\n { value: 'size', label: t('nativeComponents.fileList.sort.size', 'Size') },\n ] as const;\nconst ROW_HEIGHT = 48;\nconst IMAGE_VIEWABILITY = { itemVisiblePercentThreshold: 1 };\n/** Past this the dots stop reading as positions; the counter beside the name still does. */\nconst MAX_DOTS = 7;\nconst PREVIEW_HEIGHT = 320;\n\n/** A failed read: kept files stay listed under it, as the approved RetainedContent target shows. */\nfunction ListFailure({ error, retained, onRetry }: { error: string; retained: boolean; onRetry?: () => void }) {\n const t = useT();\n return (\n <EmptyState\n size=\"compact\"\n surface=\"plain\"\n tone=\"error\"\n title={\n retained\n ? t('nativeComponents.fileList.refreshFailed', \"Couldn't refresh the file list\")\n : t('nativeComponents.fileList.loadFailed', \"Couldn't load the file list\")\n }\n description={retained ? t('nativeComponents.fileList.lastSeen', 'These are the files Po saw last.') : error}\n action={onRetry ? { label: t('nativeComponents.fileList.retry', 'Try again'), onAction: onRetry } : undefined}\n />\n );\n}\n\nfunction FileBrowserList({\n items,\n onOpen,\n loading,\n error,\n onRetry,\n browser: b,\n label,\n emptyText,\n}: FileListProps & { browser: FileBrowserControls }) {\n const t = useT();\n const LAYOUTS = layoutOptions(t);\n const MODIFIED = modifiedOptions(t);\n const SORTS = sortOptions(t);\n const grid = b.layout === 'grid';\n const onViewableImagesChange = b.onViewableImagesChange;\n const onViewableItemsChanged = useCallback(\n ({ viewableItems }: { viewableItems: (Omit<ListViewToken, 'item'> & { item: FileTreeRow })[] }) => {\n onViewableImagesChange?.(\n viewableItems.flatMap(({ item, isViewable }) =>\n isViewable && item.kind === 'file' && fileKind(item.item.path) === 'Image' ? [item.item.path] : [],\n ),\n );\n },\n [onViewableImagesChange],\n );\n const rows: readonly FileTreeRow[] =\n b.layout === 'tree' ? b.rows : items.map((item) => ({ kind: 'file', item, depth: 0 }));\n // Prev and next step through the files the person can see, in the order they see them.\n const files = rows.flatMap((row) => (row.kind === 'file' ? [row.item] : []));\n const at = b.selected ? files.findIndex((file) => file.path === b.selected?.path) : -1;\n const List = b.sheet ? SheetList<FileTreeRow> : FlatList<FileTreeRow>;\n const list = (\n <List\n {...(b.sheet ? { embedded: true } : {})}\n key={b.layout}\n testID=\"file-list-browser\"\n onViewableItemsChanged={onViewableItemsChanged}\n viewabilityConfig={IMAGE_VIEWABILITY}\n data={loading ? [] : rows}\n numColumns={grid ? 2 : 1}\n columnWrapperStyle={grid ? styles.columns : undefined}\n keyExtractor={(row) => (row.kind === 'dir' ? `dir:${row.path}` : row.item.path)}\n keyboardShouldPersistTaps=\"handled\"\n ListHeaderComponent={\n <>\n {b.header}\n <View style={styles.head}>\n <SegmentedControl\n accessibilityLabel={t('nativeComponents.fileList.layoutLabel', '{label} layout', { label })}\n options={LAYOUTS}\n value={b.layout}\n onValueChange={(value) => {\n if (isFileLayout(value)) b.onLayoutChange(value);\n }}\n />\n <View style={styles.toolbar}>\n <View style={styles.search}>\n <SearchIcon size={18} />\n <Input\n variant=\"bare\"\n accessibilityLabel={t('nativeComponents.fileList.search', 'Search {label}', { label })}\n placeholder={t('nativeComponents.fileList.search', 'Search {label}', { label })}\n value={b.query}\n onChangeText={b.onQueryChange}\n style={styles.searchInput}\n autoCapitalize=\"none\"\n />\n </View>\n <DropdownMenu>\n <DropdownMenuTrigger\n variant=\"outline\"\n accessibilityLabel={t('nativeComponents.fileList.filters', 'Filters')}\n >\n <SlidersIcon />\n {t('nativeComponents.fileList.filters', 'Filters')}\n </DropdownMenuTrigger>\n <DropdownMenuContent>\n <DropdownMenuLabel>{t('nativeComponents.fileList.typeHeading', 'Type')}</DropdownMenuLabel>\n {TYPES.map((type) => (\n <DropdownMenuCheckboxItem\n key={type}\n checked={b.type === type}\n onCheckedChange={() => b.onTypeChange(type)}\n >\n {type === 'any' ? t('nativeComponents.fileList.allTypes', 'All types') : fileKindLabel(type, t)}\n </DropdownMenuCheckboxItem>\n ))}\n <DropdownMenuSeparator />\n <DropdownMenuLabel>{t('nativeComponents.fileList.sort.modified', 'Modified')}</DropdownMenuLabel>\n {MODIFIED.map(({ value, label }) => (\n <DropdownMenuCheckboxItem\n key={value}\n checked={b.modified === value}\n onCheckedChange={() => b.onModifiedChange(value)}\n >\n {label}\n </DropdownMenuCheckboxItem>\n ))}\n <DropdownMenuSeparator />\n <DropdownMenuLabel>{t('nativeComponents.fileList.sortHeading', 'Sort')}</DropdownMenuLabel>\n {SORTS.map(({ value, label }) => (\n <DropdownMenuCheckboxItem\n key={value}\n checked={b.sort === value}\n onCheckedChange={() => b.onSortChange(value)}\n >\n {label}\n </DropdownMenuCheckboxItem>\n ))}\n <DropdownMenuCheckboxItem\n checked={b.direction === 'asc'}\n onCheckedChange={() => b.onDirectionChange('asc')}\n >\n {t('nativeComponents.fileList.ascending', 'Ascending')}\n </DropdownMenuCheckboxItem>\n <DropdownMenuCheckboxItem\n checked={b.direction === 'desc'}\n onCheckedChange={() => b.onDirectionChange('desc')}\n >\n {t('nativeComponents.fileList.descending', 'Descending')}\n </DropdownMenuCheckboxItem>\n </DropdownMenuContent>\n </DropdownMenu>\n </View>\n <View style={styles.chips}>\n {b.query ? (\n <Button\n variant=\"outline\"\n accessibilityLabel={t('nativeComponents.fileList.removeSearch', 'Remove search filter')}\n onPress={() => b.onQueryChange('')}\n >\n {t('nativeComponents.fileList.searchChip', 'Search: {query}', { query: b.query })}\n <CloseIcon />\n </Button>\n ) : null}\n {b.type !== 'any' ? (\n <Button\n variant=\"outline\"\n accessibilityLabel={t('nativeComponents.fileList.removeType', 'Remove type filter')}\n onPress={() => b.onTypeChange('any')}\n >\n {fileKindLabel(b.type, t)}\n <CloseIcon />\n </Button>\n ) : null}\n {b.modified !== 'any' ? (\n <Button\n variant=\"outline\"\n accessibilityLabel={t('nativeComponents.fileList.removeModified', 'Remove modified filter')}\n onPress={() => b.onModifiedChange('any')}\n >\n {MODIFIED.find((option) => option.value === b.modified)?.label}\n <CloseIcon />\n </Button>\n ) : null}\n </View>\n {error ? <ListFailure error={error} retained={items.length > 0} onRetry={onRetry} /> : null}\n {loading ? (\n <Text style={styles.meta}>{t('nativeComponents.fileList.loading', 'Loading files...')}</Text>\n ) : null}\n </View>\n </>\n }\n ListEmptyComponent={\n loading || error ? undefined : b.totalCount ? (\n <EmptyState\n size=\"compact\"\n surface=\"plain\"\n icon={<SearchIcon size={16} />}\n title={t('nativeComponents.fileList.noMatch', 'No files match')}\n secondaryAction={{\n label: t('nativeComponents.fileList.clearFilters', 'Clear filters'),\n onAction: () => {\n b.onQueryChange('');\n b.onTypeChange('any');\n b.onModifiedChange('any');\n },\n }}\n style={styles.inset}\n />\n ) : (\n <EmptyState\n size=\"compact\"\n surface=\"plain\"\n icon={<FolderIcon size={16} />}\n title={t('nativeComponents.fileList.emptyTitle', 'Nothing here yet')}\n description={emptyText}\n style={styles.inset}\n />\n )\n }\n renderItem={({ item: row }) => {\n if (row.kind === 'dir')\n return (\n <Button\n variant=\"ghost\"\n style={[styles.row, styles.indent(row.depth)]}\n accessibilityLabel={\n row.open\n ? t('nativeComponents.fileList.collapse', 'Collapse {path}', { path: row.path })\n : t('nativeComponents.fileList.expand', 'Expand {path}', { path: row.path })\n }\n accessibilityState={{ expanded: row.open }}\n onPress={() => b.onToggleDirectory(row.path)}\n >\n {row.open ? <ChevronDownIcon /> : <ChevronRightIcon />}\n <FolderIcon />\n <Text numberOfLines={1} style={[styles.name, styles.label]}>\n {row.name}\n </Text>\n <Text style={styles.meta}>{row.count}</Text>\n </Button>\n );\n const item = row.item;\n const image = fileKind(item.path) === 'Image';\n const selected = b.selected?.path === item.path;\n return (\n <Button\n variant=\"ghost\"\n size=\"card\"\n testID={`file-${item.path}`}\n accessibilityLabel={t('nativeComponents.fileList.select', 'Select {path}', { path: item.path })}\n accessibilityState={{ selected }}\n onPress={() => b.onSelect(item)}\n style={[grid ? styles.tile : styles.row, selected && styles.selected, !grid && styles.indent(row.depth)]}\n >\n {b.layout === 'tree' ? <View accessible={false} style={styles.chevronGutter} /> : null}\n {grid ? (\n <View style={styles.thumbnail}>\n {image && b.renderImage ? (\n b.renderImage(item, false)\n ) : image ? (\n <ImageIcon size={28} />\n ) : (\n <FileIcon size={28} />\n )}\n </View>\n ) : (\n // Every file row keeps the same slot, so names line up whether or not a picture loaded.\n <View style={styles.rowThumbnail}>\n {image && b.renderImage ? (\n b.renderImage(item, true)\n ) : image ? (\n <ImageIcon size={18} />\n ) : (\n <FileIcon size={18} />\n )}\n </View>\n )}\n <View style={styles.label}>\n <Text numberOfLines={1} style={styles.name}>\n {item.name}\n </Text>\n <Text numberOfLines={1} style={styles.path}>\n {item.path}\n </Text>\n </View>\n <Text style={styles.meta}>{sizeLabel(item.size)}</Text>\n </Button>\n );\n }}\n ListFooterComponent={\n <View style={styles.foot}>\n <Text style={styles.meta}>\n {t('nativeComponents.fileList.count', '{shown} of {total} files', {\n shown: items.length,\n total: b.totalCount,\n })}\n </Text>\n </View>\n }\n />\n );\n return (\n <>\n {list}\n <Sheet\n open={b.selected !== undefined}\n onOpenChange={(open) => {\n if (!open) b.onCloseSelection();\n }}\n >\n <SheetContent>\n {b.selected ? (\n <View style={styles.foot}>\n <View style={styles.selection} testID=\"file-selection\">\n <View style={styles.titleRow}>\n <Text accessibilityRole=\"header\" numberOfLines={1} style={[styles.name, styles.label]}>\n {b.selected.name}\n </Text>\n {files.length > 1 ? (\n <Text accessibilityLiveRegion=\"polite\" style={styles.meta}>\n {t('nativeComponents.fileList.position', '{index} of {total}', {\n index: Math.max(0, at) + 1,\n total: files.length,\n })}\n </Text>\n ) : null}\n </View>\n <SelectionSlides\n files={at < 0 ? [b.selected] : files}\n selected={b.selected}\n onSelect={b.onSelect}\n renderImage={b.renderImage}\n />\n <Text numberOfLines={2} style={styles.path}>\n {b.selected.path}\n </Text>\n <Text style={styles.meta}>\n {fileKindLabel(fileKind(b.selected.path), t)} · {sizeLabel(b.selected.size)}\n </Text>\n <View style={styles.actions}>\n <Button variant=\"outline\" onPress={b.onCloseSelection}>\n {t('nativeComponents.fileList.close', 'Close')}\n </Button>\n <Button\n variant=\"primary\"\n onPress={() => {\n if (b.selected) {\n b.onCloseSelection();\n onOpen(b.selected.path);\n }\n }}\n >\n {t('nativeComponents.fileList.openAction', 'Open')}\n </Button>\n </View>\n </View>\n </View>\n ) : null}\n </SheetContent>\n </Sheet>\n </>\n );\n}\n\n/** The selected file large; swiping and the arrows select its neighbours in the list. */\nfunction SelectionSlides({\n files,\n selected,\n onSelect,\n renderImage,\n}: {\n files: readonly FileItem[];\n selected: FileItem;\n onSelect: (item: FileItem) => void;\n renderImage?: FileBrowserControls['renderImage'];\n}) {\n const t = useT();\n const index = Math.max(\n 0,\n files.findIndex((file) => file.path === selected.path),\n );\n // A horizontal scroller does not stretch its pages, so each page takes the measured width.\n const [width, setWidth] = useState(0);\n const scroller = useRef<ComponentRef<typeof ScrollView>>(null);\n const placed = useRef(false);\n useEffect(() => {\n if (width === 0) return;\n // Opening lands on the tapped file; later steps glide.\n scroller.current?.scrollTo({ x: index * width, animated: placed.current });\n placed.current = true;\n }, [index, width]);\n const step = (by: number) => {\n const next = files[index + by];\n if (next) onSelect(next);\n };\n return (\n <View>\n <ScrollView\n ref={scroller}\n horizontal\n pagingEnabled\n showsHorizontalScrollIndicator={false}\n onLayout={(event) => setWidth(event.nativeEvent.layout.width)}\n onMomentumScrollEnd={(event) => {\n if (width > 0) step(Math.round(event.nativeEvent.contentOffset.x / width) - index);\n }}\n style={styles.preview}\n >\n {files.map((file, page) => (\n <View\n key={file.path}\n accessibilityElementsHidden={page !== index}\n importantForAccessibility={page === index ? 'auto' : 'no-hide-descendants'}\n style={[styles.page, { width }]}\n >\n {/* ponytail: only the open page and its neighbours mount; a long list never reads every picture. */}\n {Math.abs(page - index) > 1 ? null : fileKind(file.path) !== 'Image' ? (\n <FileIcon size={28} />\n ) : renderImage ? (\n renderImage(file, false)\n ) : (\n <ImageIcon size={28} />\n )}\n </View>\n ))}\n </ScrollView>\n {files.length > 1 ? (\n <>\n <Button\n variant=\"ghost\"\n size=\"icon-md\"\n accessibilityLabel={t('nativeComponents.fileList.previous', 'Previous file')}\n disabled={index === 0}\n onPress={() => step(-1)}\n style={[styles.arrow, styles.previous]}\n >\n <View style={styles.flip}>\n <ChevronRightIcon size={18} color=\"hi\" />\n </View>\n </Button>\n <Button\n variant=\"ghost\"\n size=\"icon-md\"\n accessibilityLabel={t('nativeComponents.fileList.next', 'Next file')}\n disabled={index === files.length - 1}\n onPress={() => step(1)}\n style={[styles.arrow, styles.next]}\n >\n <ChevronRightIcon size={18} color=\"hi\" />\n </Button>\n </>\n ) : null}\n {files.length > 1 && files.length <= MAX_DOTS ? (\n <View accessible={false} style={styles.dots}>\n {files.map((file, page) => (\n <View key={file.path} style={[styles.dot, page === index && styles.dotActive]} />\n ))}\n </View>\n ) : null}\n </View>\n );\n}\n\nconst styles = StyleSheet.create((theme) => ({\n head: { gap: theme.spacing(3), padding: theme.spacing(4), paddingBottom: theme.spacing(3) },\n foot: { gap: theme.spacing(3), padding: theme.spacing(4), paddingTop: theme.spacing(3) },\n inset: { paddingHorizontal: theme.spacing(4) },\n toolbar: { flexDirection: 'row', alignItems: 'center', gap: theme.spacing(2) },\n search: {\n flex: 1,\n minWidth: 0,\n flexDirection: 'row',\n alignItems: 'center',\n gap: theme.spacing(2),\n paddingHorizontal: theme.spacing(2),\n borderWidth: 1,\n borderColor: theme.colors.border,\n borderRadius: theme.borderRadius.DEFAULT,\n backgroundColor: theme.colors.deep,\n },\n searchInput: { flex: 1 },\n chips: { flexDirection: 'row', flexWrap: 'wrap', gap: theme.spacing(2) },\n row: {\n marginHorizontal: theme.spacing(4),\n marginBottom: theme.spacing(2),\n // A file row holds two lines; a fixed height pressed them against the border.\n minHeight: ROW_HEIGHT,\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-start',\n gap: theme.spacing(2),\n borderWidth: 1,\n borderColor: theme.colors['border-soft'],\n borderRadius: theme.borderRadius.DEFAULT,\n paddingVertical: theme.spacing(2),\n paddingRight: theme.spacing(3),\n },\n // Tree depth adds to the row's own inset; replacing it put the icon against the border.\n indent: (depth: number) => ({ paddingLeft: theme.spacing(3) + depth * 16 }),\n chevronGutter: { width: 16 },\n columns: { gap: theme.spacing(2), paddingHorizontal: theme.spacing(4) },\n tile: {\n flex: 1,\n maxWidth: '50%',\n flexDirection: 'column',\n alignItems: 'stretch',\n gap: theme.spacing(2),\n borderWidth: 1,\n borderColor: theme.colors['border-soft'],\n marginBottom: theme.spacing(2),\n },\n thumbnail: {\n height: 96,\n backgroundColor: theme.colors.deep,\n borderRadius: theme.borderRadius.DEFAULT,\n overflow: 'hidden',\n alignItems: 'center',\n justifyContent: 'center',\n },\n rowThumbnail: {\n width: 40,\n height: 40,\n borderRadius: theme.borderRadius.sm,\n overflow: 'hidden',\n alignItems: 'center',\n justifyContent: 'center',\n },\n selected: { backgroundColor: theme.colors['tint-green'], borderColor: theme.colors['edge-green'] },\n selection: {\n flexShrink: 0,\n padding: theme.spacing(3),\n gap: theme.spacing(2),\n borderWidth: 1,\n borderColor: theme.colors.border,\n borderRadius: theme.borderRadius.DEFAULT,\n backgroundColor: theme.colors.panel,\n },\n actions: { flexDirection: 'row', justifyContent: 'flex-end', gap: theme.spacing(2) },\n titleRow: { flexDirection: 'row', alignItems: 'center', gap: theme.spacing(2) },\n preview: {\n height: PREVIEW_HEIGHT,\n backgroundColor: theme.colors.deep,\n borderRadius: theme.borderRadius.DEFAULT,\n },\n page: { height: PREVIEW_HEIGHT, alignItems: 'center', justifyContent: 'center' },\n arrow: {\n position: 'absolute',\n top: PREVIEW_HEIGHT / 2 - 22,\n width: 44,\n height: 44,\n borderRadius: 22,\n backgroundColor: theme.colors.panel,\n },\n previous: { left: theme.spacing(2) },\n next: { right: theme.spacing(2) },\n flip: { transform: [{ rotate: '180deg' }] },\n dots: { flexDirection: 'row', justifyContent: 'center', gap: theme.spacing(2), paddingTop: theme.spacing(2) },\n dot: { width: 6, height: 6, borderRadius: 3, backgroundColor: theme.colors.faint },\n dotActive: { backgroundColor: theme.colors.green },\n list: { gap: theme.spacing(2) },\n // The card size stacks its children; a recent row reads like the browser's list row instead.\n item: {\n minHeight: 44,\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center',\n gap: theme.spacing(3),\n },\n label: { flex: 1, gap: theme.spacing(1), minWidth: 0 },\n name: {\n fontFamily: fontOf(theme.fontFamily.sans),\n fontWeight: '600',\n fontSize: theme.fontSize.base,\n color: theme.colors.text,\n },\n path: { fontFamily: fontOf(theme.fontFamily.mono), fontSize: theme.fontSize.sm, color: theme.colors.dim },\n meta: { fontFamily: fontOf(theme.fontFamily.sans), fontSize: theme.fontSize.sm, color: theme.colors.dim },\n}));\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAwFA,SAAgBgF,SAAS,EACvBT,OACAC,QACAC,SACAC,OACAC,SACAG,OAAO,OACPC,SACAH,OACAC,aACgB;CAChB,MAAMI,IAAIhF,KAAK;CACf,IAAI8E,SACF,OACE,oBAAC,iBAAD;EACSH;EACIC;EACJN;EACCC;EACCC;EACFC;EACEC;EACAI;CAAQ;CAGvB,OACE,qBAAC,MAAD;EAAM,QAAQD,OAAO,mBAAmB;EAAoB,OAAOI,OAAOC;YAA1E;GACGT,QAAQ,oBAAC,aAAD;IAAoBA;IAAO,UAAUH,MAAMa,SAAS;IAAYT;GAAQ,KAAM;GACtFF,UAAU,oBAAC,MAAD;IAAM,OAAOS,OAAOG;cAAOJ,EAAE,qCAAqC,kBAAkB;GAAQ,KAAI;GAC1G,CAACR,WAAW,CAACC,SAASH,MAAMa,WAAW,IACtC,oBAAC,YAAD;IACE,MAAK;IACL,SAAQ;IACR,MAAM,oBAAC,YAAD,EAAY,MAAM,GAAG;IAC3B,OAAOH,EAAE,wCAAwC,kBAAkB;IACnE,aAAaJ;GAAU,KAEvB;GACHN,MAAMe,KAAKzB,SACV,qBAAC,QAAD;IAEE,SAASiB,OAAO,YAAY;IAC5B,MAAK;IACL,oBAAoBG,EAAE,kCAAkC,eAAe,EAAEvB,MAAMG,KAAKH,KAAK,CAAC;IAC1F,QAAQ,QAAQG,KAAKH;IACrB,eAAec,OAAOX,KAAKH,IAAI;IAC/B,OAAOwB,OAAOrB;cAPhB,CASE,oBAAC,UAAD;KAAU,MAAM;KAAI,OAAM;IAAK,IAC/B,qBAAC,MAAD;KAAM,OAAOqB,OAAON;eAApB;MACE,oBAAC,MAAD;OAAM,eAAe;OAAG,OAAOM,OAAOK;iBACnC1B,KAAK0B;MACF;MACLT,QAA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AOoC;EAAG7C,mBAAA,CAAA,CAAA;CAAC;CACxGrG,MAAM;EAAE0I,YAAYlM,OAAOwJ,MAAM0C,WAAWC,IAAI;EAAGE,UAAU7C,MAAM6C,SAASd;EAAIgB,OAAO/C,MAAMc,OAAOoC;EAAG7C,mBAAA,CAAA,CAAA;CAAC;AAC1G,EAAE"}
|
|
1
|
+
{"version":3,"file":"FileList.mjs","names":["useT","fileKind","isFileLayout","sizeLabel","FileItem","FileKind","FileLayout","FileModified","FileSort","FileSortDirection","FileTreeRow","ComponentRef","ReactNode","useCallback","useEffect","useRef","useState","ListViewToken","StyleSheet","ChevronDownIcon","ChevronRightIcon","CloseIcon","FileIcon","FolderIcon","ImageIcon","SearchIcon","SlidersIcon","fileKindLabel","fontOf","Button","DropdownMenu","DropdownMenuCheckboxItem","DropdownMenuContent","DropdownMenuLabel","DropdownMenuSeparator","DropdownMenuTrigger","EmptyState","Input","SegmentedControl","Sheet","SheetContent","SheetList","FileBrowserControls","layout","onLayoutChange","query","onQueryChange","type","onTypeChange","modified","onModifiedChange","sort","onSortChange","direction","onDirectionChange","rows","onToggleDirectory","path","selected","onSelect","item","onCloseSelection","totalCount","onViewableImagesChange","paths","renderImage","compact","header","sheet","FileListProps","items","onOpen","loading","error","onRetry","label","emptyText","grid","browser","FileList","t","styles","list","length","meta","map","name","size","Translate","ReturnType","layoutOptions","value","TYPES","const","modifiedOptions","sortOptions","ROW_HEIGHT","IMAGE_VIEWABILITY","itemVisiblePercentThreshold","MAX_DOTS","PREVIEW_HEIGHT","ListFailure","retained","onAction","undefined","FileBrowserList","b","LAYOUTS","MODIFIED","SORTS","onViewableItemsChanged","viewableItems","Omit","flatMap","isViewable","kind","depth","files","row","at","findIndex","file","List","FlatList","embedded","columns","head","toolbar","search","searchInput","chips","find","option","inset","indent","open","expanded","count","image","tile","chevronGutter","thumbnail","rowThumbnail","foot","shown","total","selection","titleRow","index","Math","max","actions","SelectionSlides","width","setWidth","scroller","ScrollView","placed","current","scrollTo","x","animated","step","by","next","event","nativeEvent","round","contentOffset","preview","page","abs","arrow","previous","flip","dots","dot","dotActive","create","theme","gap","spacing","padding","paddingBottom","uni__dependencies","paddingTop","paddingHorizontal","flexDirection","alignItems","flex","minWidth","borderWidth","borderColor","colors","border","borderRadius","DEFAULT","backgroundColor","deep","flexWrap","marginHorizontal","marginBottom","minHeight","justifyContent","paddingVertical","paddingRight","paddingLeft","maxWidth","height","overflow","sm","flexShrink","panel","position","top","left","right","transform","rotate","faint","green","fontFamily","sans","fontWeight","fontSize","base","color","text","mono","dim"],"sources":["../../src/components/FileList.tsx"],"sourcesContent":["import { useT } from '@agimon-ai/po-core/native';\nimport {\n fileKind,\n isFileLayout,\n sizeLabel,\n type FileItem,\n type FileKind,\n type FileLayout,\n type FileModified,\n type FileSort,\n type FileSortDirection,\n type FileTreeRow,\n} from '@agimon-ai/po-web-components/text';\nimport { type ComponentRef, type ReactNode, useCallback, useEffect, useRef, useState } from 'react';\nimport { FlatList, ScrollView, Text, View, type ListViewToken } from 'react-native';\nimport { StyleSheet } from 'react-native-unistyles';\n\nimport {\n ChevronDownIcon,\n ChevronRightIcon,\n CloseIcon,\n FileIcon,\n FolderIcon,\n ImageIcon,\n SearchIcon,\n SlidersIcon,\n} from '../icons/icons';\nimport { fileKindLabel } from '../lib/fileKindLabel';\nimport { fontOf } from '../lib/fonts';\nimport { Button } from './Button';\nimport {\n DropdownMenu,\n DropdownMenuCheckboxItem,\n DropdownMenuContent,\n DropdownMenuLabel,\n DropdownMenuSeparator,\n DropdownMenuTrigger,\n} from './DropdownMenu';\nimport { EmptyState } from './EmptyState';\nimport { Input } from './Input';\nimport { SegmentedControl } from './SegmentedControl';\nimport { Sheet, SheetContent } from './Sheet';\nimport { SheetList } from './SheetList';\n\nexport interface FileBrowserControls {\n layout: FileLayout;\n onLayoutChange: (layout: FileLayout) => void;\n query: string;\n onQueryChange: (query: string) => void;\n type: FileKind | 'any';\n onTypeChange: (type: FileKind | 'any') => void;\n modified: FileModified;\n onModifiedChange: (modified: FileModified) => void;\n sort: FileSort;\n onSortChange: (sort: FileSort) => void;\n direction: FileSortDirection;\n onDirectionChange: (direction: FileSortDirection) => void;\n rows: readonly FileTreeRow[];\n onToggleDirectory: (path: string) => void;\n selected?: FileItem;\n onSelect: (item: FileItem) => void;\n onCloseSelection: () => void;\n totalCount: number;\n onViewableImagesChange?: (paths: readonly string[]) => void;\n /** A loaded thumbnail or a placeholder for an image file; `compact` is a list row's small square. */\n renderImage?: (item: FileItem, compact: boolean) => ReactNode;\n /** Drawn first in the list, above the controls, such as the native dock's tab strip. */\n header?: ReactNode;\n /** Inside a bottom sheet with no scroll view of its own: the list is the sheet's only scroll owner. */\n sheet?: boolean;\n}\n\nexport interface FileListProps {\n items: readonly FileItem[];\n onOpen: (path: string) => void;\n loading?: boolean;\n error?: string;\n /** Offered beside a failed read as Try again. */\n onRetry?: () => void;\n /** Names the list for search and layout, such as \"artifacts\" or \"Personal\". */\n label: string;\n /** Guidance under the empty card's title: why the list is empty and what fills it. */\n emptyText: string;\n grid?: boolean;\n browser?: FileBrowserControls;\n}\n\n/** A folder of files on the phone: recent rows, or a browser with layouts, filters and a swipeable selection. Presentation only. */\nexport function FileList({\n items,\n onOpen,\n loading,\n error,\n onRetry,\n grid = false,\n browser,\n label,\n emptyText,\n}: FileListProps) {\n const t = useT();\n if (browser)\n return (\n <FileBrowserList\n label={label}\n emptyText={emptyText}\n items={items}\n onOpen={onOpen}\n loading={loading}\n error={error}\n onRetry={onRetry}\n browser={browser}\n />\n );\n return (\n <View testID={grid ? 'file-list-grid' : 'file-list-recent'} style={styles.list}>\n {error ? <ListFailure error={error} retained={items.length > 0} onRetry={onRetry} /> : null}\n {loading ? <Text style={styles.meta}>{t('nativeComponents.fileList.loading', 'Loading files...')}</Text> : null}\n {!loading && !error && items.length === 0 ? (\n <EmptyState\n size=\"compact\"\n surface=\"plain\"\n icon={<FolderIcon size={16} />}\n title={t('nativeComponents.fileList.emptyTitle', 'Nothing here yet')}\n description={emptyText}\n />\n ) : null}\n {items.map((item) => (\n <Button\n key={item.path}\n variant={grid ? 'outline' : 'ghost'}\n size=\"card\"\n accessibilityLabel={t('nativeComponents.fileList.open', 'Open {path}', { path: item.path })}\n testID={`file-${item.path}`}\n onPress={() => onOpen(item.path)}\n style={styles.item}\n >\n <FileIcon size={18} color=\"dim\" />\n <View style={styles.label}>\n <Text numberOfLines={1} style={styles.name}>\n {item.name}\n </Text>\n {grid || item.path !== item.name ? (\n <Text numberOfLines={1} style={styles.path}>\n {item.path}\n </Text>\n ) : null}\n {grid ? <Text style={styles.meta}>{sizeLabel(item.size)}</Text> : null}\n </View>\n </Button>\n ))}\n </View>\n );\n}\n\ntype Translate = ReturnType<typeof useT>;\nconst layoutOptions = (t: Translate) => [\n { value: 'tree', label: t('nativeComponents.fileList.layout.tree', 'Tree') },\n { value: 'list', label: t('nativeComponents.fileList.layout.list', 'List') },\n { value: 'grid', label: t('nativeComponents.fileList.layout.grid', 'Grid') },\n];\nconst TYPES = ['any', 'Markdown', 'Image', 'Code', 'Data', 'Document', 'Other'] as const;\nconst modifiedOptions = (t: Translate) =>\n [\n { value: 'any', label: t('nativeComponents.fileList.modified.any', 'Any time') },\n { value: 'today', label: t('nativeComponents.fileList.modified.today', 'Today') },\n { value: '7days', label: t('nativeComponents.fileList.modified.7days', 'Last 7 days') },\n { value: '30days', label: t('nativeComponents.fileList.modified.30days', 'Last 30 days') },\n ] as const;\nconst sortOptions = (t: Translate) =>\n [\n { value: 'name', label: t('nativeComponents.fileList.sort.name', 'Name') },\n { value: 'modified', label: t('nativeComponents.fileList.sort.modified', 'Modified') },\n { value: 'size', label: t('nativeComponents.fileList.sort.size', 'Size') },\n ] as const;\nconst ROW_HEIGHT = 48;\nconst IMAGE_VIEWABILITY = { itemVisiblePercentThreshold: 1 };\n/** Past this the dots stop reading as positions; the counter beside the name still does. */\nconst MAX_DOTS = 7;\nconst PREVIEW_HEIGHT = 320;\n\n/** A failed read: kept files stay listed under it, as the approved RetainedContent target shows. */\nfunction ListFailure({ error, retained, onRetry }: { error: string; retained: boolean; onRetry?: () => void }) {\n const t = useT();\n return (\n <EmptyState\n size=\"compact\"\n surface=\"plain\"\n tone=\"error\"\n title={\n retained\n ? t('nativeComponents.fileList.refreshFailed', \"Couldn't refresh the file list\")\n : t('nativeComponents.fileList.loadFailed', \"Couldn't load the file list\")\n }\n description={retained ? t('nativeComponents.fileList.lastSeen', 'These are the files Po saw last.') : error}\n action={onRetry ? { label: t('nativeComponents.fileList.retry', 'Try again'), onAction: onRetry } : undefined}\n />\n );\n}\n\nfunction FileBrowserList({\n items,\n onOpen,\n loading,\n error,\n onRetry,\n browser: b,\n label,\n emptyText,\n}: FileListProps & { browser: FileBrowserControls }) {\n const t = useT();\n const LAYOUTS = layoutOptions(t);\n const MODIFIED = modifiedOptions(t);\n const SORTS = sortOptions(t);\n const grid = b.layout === 'grid';\n const onViewableImagesChange = b.onViewableImagesChange;\n const onViewableItemsChanged = useCallback(\n ({ viewableItems }: { viewableItems: (Omit<ListViewToken, 'item'> & { item: FileTreeRow })[] }) => {\n onViewableImagesChange?.(\n viewableItems.flatMap(({ item, isViewable }) =>\n isViewable && item.kind === 'file' && fileKind(item.item.path) === 'Image' ? [item.item.path] : [],\n ),\n );\n },\n [onViewableImagesChange],\n );\n const rows: readonly FileTreeRow[] =\n b.layout === 'tree' ? b.rows : items.map((item) => ({ kind: 'file', item, depth: 0 }));\n // Prev and next step through the files the person can see, in the order they see them.\n const files = rows.flatMap((row) => (row.kind === 'file' ? [row.item] : []));\n const at = b.selected ? files.findIndex((file) => file.path === b.selected?.path) : -1;\n const List = b.sheet ? SheetList<FileTreeRow> : FlatList<FileTreeRow>;\n const list = (\n <List\n {...(b.sheet ? { embedded: true } : {})}\n key={b.layout}\n testID=\"file-list-browser\"\n onViewableItemsChanged={onViewableItemsChanged}\n viewabilityConfig={IMAGE_VIEWABILITY}\n data={loading ? [] : rows}\n numColumns={grid ? 2 : 1}\n columnWrapperStyle={grid ? styles.columns : undefined}\n keyExtractor={(row) => (row.kind === 'dir' ? `dir:${row.path}` : row.item.path)}\n keyboardShouldPersistTaps=\"handled\"\n ListHeaderComponent={\n <>\n {b.header}\n <View style={styles.head}>\n <SegmentedControl\n accessibilityLabel={t('nativeComponents.fileList.layoutLabel', '{label} layout', { label })}\n options={LAYOUTS}\n value={b.layout}\n onValueChange={(value) => {\n if (isFileLayout(value)) b.onLayoutChange(value);\n }}\n />\n <View style={styles.toolbar}>\n <View style={styles.search}>\n <SearchIcon size={18} />\n <Input\n variant=\"bare\"\n accessibilityLabel={t('nativeComponents.fileList.search', 'Search {label}', { label })}\n placeholder={t('nativeComponents.fileList.search', 'Search {label}', { label })}\n value={b.query}\n onChangeText={b.onQueryChange}\n style={styles.searchInput}\n autoCapitalize=\"none\"\n />\n </View>\n <DropdownMenu>\n <DropdownMenuTrigger\n variant=\"outline\"\n accessibilityLabel={t('nativeComponents.fileList.filters', 'Filters')}\n >\n <SlidersIcon />\n {t('nativeComponents.fileList.filters', 'Filters')}\n </DropdownMenuTrigger>\n <DropdownMenuContent>\n <DropdownMenuLabel>{t('nativeComponents.fileList.typeHeading', 'Type')}</DropdownMenuLabel>\n {TYPES.map((type) => (\n <DropdownMenuCheckboxItem\n key={type}\n checked={b.type === type}\n onCheckedChange={() => b.onTypeChange(type)}\n >\n {type === 'any' ? t('nativeComponents.fileList.allTypes', 'All types') : fileKindLabel(type, t)}\n </DropdownMenuCheckboxItem>\n ))}\n <DropdownMenuSeparator />\n <DropdownMenuLabel>{t('nativeComponents.fileList.sort.modified', 'Modified')}</DropdownMenuLabel>\n {MODIFIED.map(({ value, label }) => (\n <DropdownMenuCheckboxItem\n key={value}\n checked={b.modified === value}\n onCheckedChange={() => b.onModifiedChange(value)}\n >\n {label}\n </DropdownMenuCheckboxItem>\n ))}\n <DropdownMenuSeparator />\n <DropdownMenuLabel>{t('nativeComponents.fileList.sortHeading', 'Sort')}</DropdownMenuLabel>\n {SORTS.map(({ value, label }) => (\n <DropdownMenuCheckboxItem\n key={value}\n checked={b.sort === value}\n onCheckedChange={() => b.onSortChange(value)}\n >\n {label}\n </DropdownMenuCheckboxItem>\n ))}\n <DropdownMenuCheckboxItem\n checked={b.direction === 'asc'}\n onCheckedChange={() => b.onDirectionChange('asc')}\n >\n {t('nativeComponents.fileList.ascending', 'Ascending')}\n </DropdownMenuCheckboxItem>\n <DropdownMenuCheckboxItem\n checked={b.direction === 'desc'}\n onCheckedChange={() => b.onDirectionChange('desc')}\n >\n {t('nativeComponents.fileList.descending', 'Descending')}\n </DropdownMenuCheckboxItem>\n </DropdownMenuContent>\n </DropdownMenu>\n </View>\n <View style={styles.chips}>\n {b.query ? (\n <Button\n variant=\"outline\"\n accessibilityLabel={t('nativeComponents.fileList.removeSearch', 'Remove search filter')}\n onPress={() => b.onQueryChange('')}\n >\n {t('nativeComponents.fileList.searchChip', 'Search: {query}', { query: b.query })}\n <CloseIcon />\n </Button>\n ) : null}\n {b.type !== 'any' ? (\n <Button\n variant=\"outline\"\n accessibilityLabel={t('nativeComponents.fileList.removeType', 'Remove type filter')}\n onPress={() => b.onTypeChange('any')}\n >\n {fileKindLabel(b.type, t)}\n <CloseIcon />\n </Button>\n ) : null}\n {b.modified !== 'any' ? (\n <Button\n variant=\"outline\"\n accessibilityLabel={t('nativeComponents.fileList.removeModified', 'Remove modified filter')}\n onPress={() => b.onModifiedChange('any')}\n >\n {MODIFIED.find((option) => option.value === b.modified)?.label}\n <CloseIcon />\n </Button>\n ) : null}\n </View>\n {error ? <ListFailure error={error} retained={items.length > 0} onRetry={onRetry} /> : null}\n {loading ? (\n <Text style={styles.meta}>{t('nativeComponents.fileList.loading', 'Loading files...')}</Text>\n ) : null}\n </View>\n </>\n }\n ListEmptyComponent={\n loading || error ? undefined : b.totalCount ? (\n <EmptyState\n size=\"compact\"\n surface=\"plain\"\n icon={<SearchIcon size={16} />}\n title={t('nativeComponents.fileList.noMatch', 'No files match')}\n secondaryAction={{\n label: t('nativeComponents.fileList.clearFilters', 'Clear filters'),\n onAction: () => {\n b.onQueryChange('');\n b.onTypeChange('any');\n b.onModifiedChange('any');\n },\n }}\n style={styles.inset}\n />\n ) : (\n <EmptyState\n size=\"compact\"\n surface=\"plain\"\n icon={<FolderIcon size={16} />}\n title={t('nativeComponents.fileList.emptyTitle', 'Nothing here yet')}\n description={emptyText}\n style={styles.inset}\n />\n )\n }\n renderItem={({ item: row }) => {\n if (row.kind === 'dir')\n return (\n <Button\n variant=\"ghost\"\n style={[styles.row, styles.indent(row.depth)]}\n accessibilityLabel={\n row.open\n ? t('nativeComponents.fileList.collapse', 'Collapse {path}', { path: row.path })\n : t('nativeComponents.fileList.expand', 'Expand {path}', { path: row.path })\n }\n accessibilityState={{ expanded: row.open }}\n onPress={() => b.onToggleDirectory(row.path)}\n >\n {row.open ? <ChevronDownIcon /> : <ChevronRightIcon />}\n <FolderIcon />\n <Text numberOfLines={1} style={[styles.name, styles.label]}>\n {row.name}\n </Text>\n <Text style={styles.meta}>{row.count}</Text>\n </Button>\n );\n const item = row.item;\n const image = fileKind(item.path) === 'Image';\n const selected = b.selected?.path === item.path;\n return (\n <Button\n variant=\"ghost\"\n size=\"card\"\n testID={`file-${item.path}`}\n accessibilityLabel={t('nativeComponents.fileList.select', 'Select {path}', { path: item.path })}\n accessibilityState={{ selected }}\n onPress={() => b.onSelect(item)}\n style={[grid ? styles.tile : styles.row, selected && styles.selected, !grid && styles.indent(row.depth)]}\n >\n {b.layout === 'tree' ? <View accessible={false} style={styles.chevronGutter} /> : null}\n {grid ? (\n <View style={styles.thumbnail}>\n {image && b.renderImage ? (\n b.renderImage(item, false)\n ) : image ? (\n <ImageIcon size={28} />\n ) : (\n <FileIcon size={28} />\n )}\n </View>\n ) : (\n // Every file row keeps the same slot, so names line up whether or not a picture loaded.\n <View style={styles.rowThumbnail}>\n {image && b.renderImage ? (\n b.renderImage(item, true)\n ) : image ? (\n <ImageIcon size={18} />\n ) : (\n <FileIcon size={18} />\n )}\n </View>\n )}\n <View style={styles.label}>\n <Text numberOfLines={1} style={styles.name}>\n {item.name}\n </Text>\n <Text numberOfLines={1} style={styles.path}>\n {item.path}\n </Text>\n </View>\n <Text style={styles.meta}>{sizeLabel(item.size)}</Text>\n </Button>\n );\n }}\n ListFooterComponent={\n <View style={styles.foot}>\n <Text style={styles.meta}>\n {t('nativeComponents.fileList.count', '{shown} of {total} files', {\n shown: items.length,\n total: b.totalCount,\n })}\n </Text>\n </View>\n }\n />\n );\n return (\n <>\n {list}\n <Sheet\n open={b.selected !== undefined}\n onOpenChange={(open) => {\n if (!open) b.onCloseSelection();\n }}\n >\n <SheetContent>\n {b.selected ? (\n <View style={styles.foot}>\n <View style={styles.selection} testID=\"file-selection\">\n <View style={styles.titleRow}>\n <Text accessibilityRole=\"header\" numberOfLines={1} style={[styles.name, styles.label]}>\n {b.selected.name}\n </Text>\n {files.length > 1 ? (\n <Text accessibilityLiveRegion=\"polite\" style={styles.meta}>\n {t('nativeComponents.fileList.position', '{index} of {total}', {\n index: Math.max(0, at) + 1,\n total: files.length,\n })}\n </Text>\n ) : null}\n </View>\n <SelectionSlides\n files={at < 0 ? [b.selected] : files}\n selected={b.selected}\n onSelect={b.onSelect}\n renderImage={b.renderImage}\n />\n <Text numberOfLines={2} style={styles.path}>\n {b.selected.path}\n </Text>\n <Text style={styles.meta}>\n {fileKindLabel(fileKind(b.selected.path), t)} · {sizeLabel(b.selected.size)}\n </Text>\n <View style={styles.actions}>\n <Button variant=\"outline\" onPress={b.onCloseSelection}>\n {t('nativeComponents.fileList.close', 'Close')}\n </Button>\n <Button\n variant=\"primary\"\n onPress={() => {\n if (b.selected) {\n b.onCloseSelection();\n onOpen(b.selected.path);\n }\n }}\n >\n {t('nativeComponents.fileList.openAction', 'Open')}\n </Button>\n </View>\n </View>\n </View>\n ) : null}\n </SheetContent>\n </Sheet>\n </>\n );\n}\n\n/** The selected file large; swiping and the arrows select its neighbours in the list. */\nfunction SelectionSlides({\n files,\n selected,\n onSelect,\n renderImage,\n}: {\n files: readonly FileItem[];\n selected: FileItem;\n onSelect: (item: FileItem) => void;\n renderImage?: FileBrowserControls['renderImage'];\n}) {\n const t = useT();\n const index = Math.max(\n 0,\n files.findIndex((file) => file.path === selected.path),\n );\n // A horizontal scroller does not stretch its pages, so each page takes the measured width.\n const [width, setWidth] = useState(0);\n const scroller = useRef<ComponentRef<typeof ScrollView>>(null);\n const placed = useRef(false);\n useEffect(() => {\n if (width === 0) return;\n // Opening lands on the tapped file; later steps glide.\n scroller.current?.scrollTo({ x: index * width, animated: placed.current });\n placed.current = true;\n }, [index, width]);\n const step = (by: number) => {\n const next = files[index + by];\n if (next) onSelect(next);\n };\n return (\n <View>\n <ScrollView\n ref={scroller}\n horizontal\n pagingEnabled\n showsHorizontalScrollIndicator={false}\n onLayout={(event) => setWidth(event.nativeEvent.layout.width)}\n onMomentumScrollEnd={(event) => {\n if (width > 0) step(Math.round(event.nativeEvent.contentOffset.x / width) - index);\n }}\n style={styles.preview}\n >\n {files.map((file, page) => (\n <View\n key={file.path}\n accessibilityElementsHidden={page !== index}\n importantForAccessibility={page === index ? 'auto' : 'no-hide-descendants'}\n style={[styles.page, { width }]}\n >\n {/* ponytail: only the open page and its neighbours mount; a long list never reads every picture. */}\n {Math.abs(page - index) > 1 ? null : fileKind(file.path) !== 'Image' ? (\n <FileIcon size={28} />\n ) : renderImage ? (\n renderImage(file, false)\n ) : (\n <ImageIcon size={28} />\n )}\n </View>\n ))}\n </ScrollView>\n {files.length > 1 ? (\n <>\n <Button\n variant=\"ghost\"\n size=\"icon-md\"\n accessibilityLabel={t('nativeComponents.fileList.previous', 'Previous file')}\n disabled={index === 0}\n onPress={() => step(-1)}\n style={[styles.arrow, styles.previous]}\n >\n <View style={styles.flip}>\n <ChevronRightIcon size={18} color=\"hi\" />\n </View>\n </Button>\n <Button\n variant=\"ghost\"\n size=\"icon-md\"\n accessibilityLabel={t('nativeComponents.fileList.next', 'Next file')}\n disabled={index === files.length - 1}\n onPress={() => step(1)}\n style={[styles.arrow, styles.next]}\n >\n <ChevronRightIcon size={18} color=\"hi\" />\n </Button>\n </>\n ) : null}\n {files.length > 1 && files.length <= MAX_DOTS ? (\n <View accessible={false} style={styles.dots}>\n {files.map((file, page) => (\n <View key={file.path} style={[styles.dot, page === index && styles.dotActive]} />\n ))}\n </View>\n ) : null}\n </View>\n );\n}\n\nconst styles = StyleSheet.create((theme) => ({\n head: { gap: theme.spacing(3), padding: theme.spacing(4), paddingBottom: theme.spacing(3) },\n foot: { gap: theme.spacing(3), padding: theme.spacing(4), paddingTop: theme.spacing(3) },\n inset: { paddingHorizontal: theme.spacing(4) },\n toolbar: { flexDirection: 'row', alignItems: 'center', gap: theme.spacing(2) },\n search: {\n flex: 1,\n minWidth: 0,\n flexDirection: 'row',\n alignItems: 'center',\n gap: theme.spacing(2),\n paddingHorizontal: theme.spacing(2),\n borderWidth: 1,\n borderColor: theme.colors.border,\n borderRadius: theme.borderRadius.DEFAULT,\n backgroundColor: theme.colors.deep,\n },\n searchInput: { flex: 1 },\n chips: { flexDirection: 'row', flexWrap: 'wrap', gap: theme.spacing(2) },\n row: {\n marginHorizontal: theme.spacing(4),\n marginBottom: theme.spacing(2),\n // A file row holds two lines; a fixed height pressed them against the border.\n minHeight: ROW_HEIGHT,\n flexDirection: 'row',\n alignItems: 'center',\n justifyContent: 'flex-start',\n gap: theme.spacing(2),\n borderWidth: 1,\n borderColor: theme.colors['border-soft'],\n borderRadius: theme.borderRadius.DEFAULT,\n paddingVertical: theme.spacing(2),\n paddingRight: theme.spacing(3),\n },\n // Tree depth adds to the row's own inset; replacing it put the icon against the border.\n indent: (depth: number) => ({ paddingLeft: theme.spacing(3) + depth * 16 }),\n chevronGutter: { width: 16 },\n columns: { gap: theme.spacing(2), paddingHorizontal: theme.spacing(4) },\n tile: {\n flex: 1,\n maxWidth: '50%',\n flexDirection: 'column',\n alignItems: 'stretch',\n gap: theme.spacing(2),\n borderWidth: 1,\n borderColor: theme.colors['border-soft'],\n marginBottom: theme.spacing(2),\n },\n thumbnail: {\n height: 96,\n backgroundColor: theme.colors.deep,\n borderRadius: theme.borderRadius.DEFAULT,\n overflow: 'hidden',\n alignItems: 'center',\n justifyContent: 'center',\n },\n rowThumbnail: {\n width: 40,\n height: 40,\n borderRadius: theme.borderRadius.sm,\n overflow: 'hidden',\n alignItems: 'center',\n justifyContent: 'center',\n },\n selected: { backgroundColor: theme.colors['tint-green'], borderColor: theme.colors['edge-green'] },\n selection: {\n flexShrink: 0,\n padding: theme.spacing(3),\n gap: theme.spacing(2),\n borderWidth: 1,\n borderColor: theme.colors.border,\n borderRadius: theme.borderRadius.DEFAULT,\n backgroundColor: theme.colors.panel,\n },\n actions: { flexDirection: 'row', justifyContent: 'flex-end', gap: theme.spacing(2) },\n titleRow: { flexDirection: 'row', alignItems: 'center', gap: theme.spacing(2) },\n preview: {\n height: PREVIEW_HEIGHT,\n backgroundColor: theme.colors.deep,\n borderRadius: theme.borderRadius.DEFAULT,\n },\n page: { height: PREVIEW_HEIGHT, alignItems: 'center', justifyContent: 'center' },\n arrow: {\n position: 'absolute',\n top: PREVIEW_HEIGHT / 2 - 22,\n width: 44,\n height: 44,\n borderRadius: 22,\n backgroundColor: theme.colors.panel,\n },\n previous: { left: theme.spacing(2) },\n next: { right: theme.spacing(2) },\n flip: { transform: [{ rotate: '180deg' }] },\n dots: { flexDirection: 'row', justifyContent: 'center', gap: theme.spacing(2), paddingTop: theme.spacing(2) },\n dot: { width: 6, height: 6, borderRadius: 3, backgroundColor: theme.colors.faint },\n dotActive: { backgroundColor: theme.colors.green },\n list: { gap: theme.spacing(2) },\n // The card size stacks its children; a recent row reads like the browser's list row instead.\n item: {\n minHeight: 44,\n flexDirection: 'row',\n justifyContent: 'flex-start',\n alignItems: 'center',\n gap: theme.spacing(3),\n },\n label: { flex: 1, gap: theme.spacing(1), minWidth: 0 },\n name: {\n fontFamily: fontOf(theme.fontFamily.sans),\n fontWeight: '600',\n fontSize: theme.fontSize.base,\n color: theme.colors.text,\n },\n path: { fontFamily: fontOf(theme.fontFamily.mono), fontSize: theme.fontSize.sm, color: theme.colors.dim },\n meta: { fontFamily: fontOf(theme.fontFamily.sans), fontSize: theme.fontSize.sm, color: theme.colors.dim },\n}));\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAwFA,SAAgB+E,SAAS,EACvBT,OACAC,QACAC,SACAC,OACAC,SACAG,OAAO,OACPC,SACAH,OACAC,aACgB;CAChB,MAAMI,IAAIhF,KAAK;CACf,IAAI8E,SACF,OACE,oBAAC,iBAAD;EACSH;EACIC;EACJN;EACCC;EACCC;EACFC;EACEC;EACAI;CAAQ;CAGvB,OACE,qBAAC,MAAD;EAAM,QAAQD,OAAO,mBAAmB;EAAoB,OAAOI,OAAOC;YAA1E;GACGT,QAAQ,oBAAC,aAAD;IAAoBA;IAAO,UAAUH,MAAMa,SAAS;IAAYT;GAAQ,KAAM;GACtFF,UAAU,oBAAC,MAAD;IAAM,OAAOS,OAAOG;cAAOJ,EAAE,qCAAqC,kBAAkB;GAAQ,KAAI;GAC1G,CAACR,WAAW,CAACC,SAASH,MAAMa,WAAW,IACtC,oBAAC,YAAD;IACE,MAAK;IACL,SAAQ;IACR,MAAM,oBAAC,YAAD,EAAY,MAAM,GAAG;IAC3B,OAAOH,EAAE,wCAAwC,kBAAkB;IACnE,aAAaJ;GAAU,KAEvB;GACHN,MAAMe,KAAKzB,SACV,qBAAC,QAAD;IAEE,SAASiB,OAAO,YAAY;IAC5B,MAAK;IACL,oBAAoBG,EAAE,kCAAkC,eAAe,EAAEvB,MAAMG,KAAKH,KAAK,CAAC;IAC1F,QAAQ,QAAQG,KAAKH;IACrB,eAAec,OAAOX,KAAKH,IAAI;IAC/B,OAAOwB,OAAOrB;cAPhB,CASE,oBAAC,UAAD;KAAU,MAAM;KAAI,OAAM;IAAK,IAC/B,qBAAC,MAAD;KAAM,OAAOqB,OAAON;eAApB;MACE,oBAAC,MAAD;OAAM,eAAe;OAAG,OAAOM,OAAOK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AAC;CACxGpG,MAAM;EAAEyI,YAAYjM,OAAOuJ,MAAM0C,WAAWC,IAAI;EAAGE,UAAU7C,MAAM6C,SAASd;EAAIgB,OAAO/C,MAAMc,OAAOoC;EAAG7C,mBAAA,CAAA,CAAA;CAAC;AAC1G,EAAE"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Sheet.d.mts","names":[],"sources":["../../src/components/Sheet.tsx"],"mappings":";;;;;iBA0BiB;;EAEf;EACA;EACA,gBAAgB;EAChB,WAAW;;wBAGG,QAAQ,MAAM,aAAqB,cAAc,YAAY,6BAAU,IAAA;;wBAOvE,eAAe,YAAY,SAAS,8BAAW,IAAA;;wBAc/C,aAAa,YAAY,SAAS,8BAAW,IAAA;iBAa5C;EACf,WAAW;;EAEX,SAAS;;EAET;;EAEA;;EAEA;;EAEA;;EAEA;;EAEA,aAAa;;;wBAIC,eACd,UACA,YACA,QACA,MACA,WACA,YACA,UACA,cACC,oCAAiB,IAAA;iBAyBH,uBAAuB,KAAK;EAC3C,WAAW;EACX,QAAQ,UAAU;;iBAGH,yBAAyB;;EAExC;;EAEA;;wBAGc,cACd,aACA,YAAY,gBACZ,OACA,aACG,SACF,mCAAgB,IAAA;wBAsBH,aAAa,UAAU,SAAS,4BAAS,IAAA;
|
|
1
|
+
{"version":3,"file":"Sheet.d.mts","names":[],"sources":["../../src/components/Sheet.tsx"],"mappings":";;;;;iBA0BiB;;EAEf;EACA;EACA,gBAAgB;EAChB,WAAW;;wBAGG,QAAQ,MAAM,aAAqB,cAAc,YAAY,6BAAU,IAAA;;wBAOvE,eAAe,YAAY,SAAS,8BAAW,IAAA;;wBAc/C,aAAa,YAAY,SAAS,8BAAW,IAAA;iBAa5C;EACf,WAAW;;EAEX,SAAS;;EAET;;EAEA;;EAEA;;EAEA;;EAEA;;EAEA,aAAa;;;wBAIC,eACd,UACA,YACA,QACA,MACA,WACA,YACA,UACA,cACC,oCAAiB,IAAA;iBAyBH,uBAAuB,KAAK;EAC3C,WAAW;EACX,QAAQ,UAAU;;iBAGH,yBAAyB;;EAExC;;EAEA;;wBAGc,cACd,aACA,YAAY,gBACZ,OACA,aACG,SACF,mCAAgB,IAAA;wBAsBH,aAAa,UAAU,SAAS,4BAAS,IAAA;wBAKzC,mBAAmB,UAAU,SAAS,4BAAS,IAAA;;wBAK/C,YAAY,OAAO,aAAa,SAAS,iCAAc,IAAA;wBAQvD,cAAc,OAAO,aAAa,SAAS,iCAAc,IAAA"}
|
|
@@ -100,7 +100,6 @@ function SheetHeader({ dismissible = true, closeLabel: closeLabelProp, style, ch
|
|
|
100
100
|
function SheetTitle({ style, ...props }) {
|
|
101
101
|
return /* @__PURE__ */ jsx(Text, {
|
|
102
102
|
accessibilityRole: "header",
|
|
103
|
-
numberOfLines: 1,
|
|
104
103
|
style: [styles.title, style],
|
|
105
104
|
...props
|
|
106
105
|
});
|
|
@@ -132,7 +131,8 @@ const styles = StyleSheet.create((theme) => ({
|
|
|
132
131
|
alignItems: "center",
|
|
133
132
|
gap: theme.spacing(2.5),
|
|
134
133
|
minWidth: 0,
|
|
135
|
-
|
|
134
|
+
minHeight: theme.spacing(11),
|
|
135
|
+
paddingVertical: theme.spacing(1.5),
|
|
136
136
|
borderBottomWidth: 1,
|
|
137
137
|
borderBottomColor: theme.colors.border,
|
|
138
138
|
paddingHorizontal: theme.spacing(4),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Sheet.mjs","names":["useT","NativeColorToken","createContext","ReactNode","useCallback","useContext","useMemo","StyleProp","TextProps","ViewProps","ViewStyle","StyleSheet","CloseIcon","fontOf","useControllable","wrapText","Button","ButtonProps","SheetFrame","SheetState","open","setOpen","SheetContext","undefined","SheetProps","defaultOpen","onOpenChange","children","Sheet","current","value","SheetTrigger","onPress","props","event","SheetClose","SheetContentProps","footer","scrollable","keep","onDismiss","snapPoints","backdrop","background","SheetContent","close","pinned","SheetPartProps","Omit","style","SheetHeaderProps","dismissible","closeLabel","SheetHeader","closeLabelProp","t","styles","header","SheetTitle","title","SheetDescription","description","SheetBody","body","SheetFooter","hint","create","theme","flexDirection","alignItems","gap","spacing","minWidth","height","borderBottomWidth","borderBottomColor","colors","border","paddingHorizontal","uni__dependencies","marginLeft","flexShrink","color","hi","fontFamily","sans","fontSize","lg","lineHeight","fontWeight","semibold","dim","sm","lineHeightRelaxed","paddingVertical","flexWrap","justifyContent","minHeight","borderTopWidth","borderTopColor","backgroundColor","deep","faint"],"sources":["../../src/components/Sheet.tsx"],"sourcesContent":["import { useT } from '@agimon-ai/po-core/native';\nimport type { NativeColorToken } from '@agimon-ai/po-web-components/nativeTheme';\nimport { createContext, type ReactNode, useCallback, useContext, useMemo } from 'react';\nimport { type StyleProp, Text, type TextProps, View, type ViewProps, type ViewStyle } from 'react-native';\nimport { StyleSheet } from 'react-native-unistyles';\n\nimport { CloseIcon } from '../icons/icons';\nimport { fontOf } from '../lib/fonts';\nimport { useControllable } from '../lib/useControllable';\nimport { wrapText } from '../lib/wrapText';\nimport { Button, type ButtonProps } from './Button';\nimport { SheetFrame } from './SheetFrame';\n\n/*\n * The web Sheet as a bottom sheet: the native shape for a detail view or a\n * short form over what the reader was looking at. `side` and `width` are\n * dropped; a phone sheet rises from the bottom edge and takes the width.\n */\n\ninterface SheetState {\n open: boolean;\n setOpen: (open: boolean) => void;\n}\n\nexport const SheetContext = createContext<SheetState>({ open: false, setOpen: () => undefined });\n\nexport interface SheetProps {\n /** Controlled mode; pair with onOpenChange. Omit it and the sheet keeps its own state. */\n open?: boolean;\n defaultOpen?: boolean;\n onOpenChange?: (open: boolean) => void;\n children?: ReactNode;\n}\n\nexport function Sheet({ open, defaultOpen = false, onOpenChange, children }: SheetProps) {\n const [current, setOpen] = useControllable(open, defaultOpen, onOpenChange);\n const value = useMemo(() => ({ open: current, setOpen }), [current, setOpen]);\n return <SheetContext.Provider value={value}>{children}</SheetContext.Provider>;\n}\n\n/** A Button that opens the enclosing sheet. */\nexport function SheetTrigger({ onPress, ...props }: ButtonProps) {\n const { setOpen } = useContext(SheetContext);\n return (\n <Button\n onPress={(event) => {\n onPress?.(event);\n setOpen(true);\n }}\n {...props}\n />\n );\n}\n\n/** A Button that closes the enclosing sheet. */\nexport function SheetClose({ onPress, ...props }: ButtonProps) {\n const { setOpen } = useContext(SheetContext);\n return (\n <Button\n onPress={(event) => {\n onPress?.(event);\n setOpen(false);\n }}\n {...props}\n />\n );\n}\n\nexport interface SheetContentProps {\n children?: ReactNode;\n /** Pinned actions outside the scrolling body. The footer carries the bottom safe area. */\n footer?: ReactNode;\n /** False when an embedded SheetList owns vertical scrolling. */\n scrollable?: boolean;\n /** The sheet holds unsaved work: a prompt arriving in the conversation leaves it open with a note. */\n keep?: boolean;\n /** Runs after the native modal is dismissed, including a caller-initiated close. */\n onDismiss?: () => void;\n /** Fixed heights such as `['58%']`; given, the sheet stops sizing itself to its content. */\n snapPoints?: (string | number)[];\n /** The dimmed overlay that closes the sheet on tap. Off leaves what is behind visible and usable. */\n backdrop?: boolean;\n /** The sheet and footer surface colour. */\n background?: NativeColorToken;\n}\n\n/** The sheet surface. Fields inside it switch to the sheet's own input so the keyboard lifts the sheet. */\nexport function SheetContent({\n children,\n scrollable = true,\n footer,\n keep,\n onDismiss,\n snapPoints,\n backdrop,\n background,\n}: SheetContentProps) {\n const { open, setOpen } = useContext(SheetContext);\n const value = useMemo(() => ({ open, setOpen }), [open, setOpen]);\n const close = useCallback(() => setOpen(false), [setOpen]);\n const pinned = useMemo(\n () => (footer === undefined ? undefined : <SheetContext.Provider value={value}>{footer}</SheetContext.Provider>),\n [footer, value],\n );\n return (\n <SheetFrame\n open={open}\n onClose={close}\n scrollable={scrollable}\n keep={keep}\n onDismiss={onDismiss}\n snapPoints={snapPoints}\n backdrop={backdrop}\n background={background}\n {...(pinned === undefined ? {} : { footer: pinned })}\n >\n <SheetContext.Provider value={value}>{children}</SheetContext.Provider>\n </SheetFrame>\n );\n}\n\nexport interface SheetPartProps extends Omit<ViewProps, 'children' | 'style'> {\n children?: ReactNode;\n style?: StyleProp<ViewStyle>;\n}\n\nexport interface SheetHeaderProps extends SheetPartProps {\n /** Show the close control at the right of the strip. On by default: a sheet is dismissed, not answered. */\n dismissible?: boolean;\n /** What the close control announces. */\n closeLabel?: string;\n}\n\nexport function SheetHeader({\n dismissible = true,\n closeLabel: closeLabelProp,\n style,\n children,\n ...props\n}: SheetHeaderProps) {\n const t = useT();\n const closeLabel = closeLabelProp ?? t('nativeComponents.dialog.close', 'close');\n const { setOpen } = useContext(SheetContext);\n return (\n <View style={[styles.header, style]} {...props}>\n {children}\n {dismissible ? (\n <Button\n variant=\"ghost\"\n size=\"icon\"\n accessibilityLabel={closeLabel}\n onPress={() => setOpen(false)}\n style={styles.close}\n >\n <CloseIcon size={12} color=\"faint\" />\n </Button>\n ) : null}\n </View>\n );\n}\n\nexport function SheetTitle({ style, ...props }: TextProps) {\n return <Text accessibilityRole=\"header\" numberOfLines={1} style={[styles.title, style]} {...props} />;\n}\n\nexport function SheetDescription({ style, ...props }: TextProps) {\n return <Text style={[styles.description, style]} {...props} />;\n}\n\n/** The scrolling middle; the sheet itself scrolls, so this only spaces its children. */\nexport function SheetBody({ style, children, ...props }: SheetPartProps) {\n return (\n <View style={[styles.body, style]} {...props}>\n {wrapText(children, styles.description)}\n </View>\n );\n}\n\nexport function SheetFooter({ style, children, ...props }: SheetPartProps) {\n return (\n <View style={[styles.footer, style]} {...props}>\n {wrapText(children, styles.hint)}\n </View>\n );\n}\n\nconst styles = StyleSheet.create((theme) => ({\n header: {\n flexDirection: 'row',\n alignItems: 'center',\n gap: theme.spacing(2.5),\n minWidth: 0,\n height: theme.spacing(11),\n borderBottomWidth: 1,\n borderBottomColor: theme.colors.border,\n paddingHorizontal: theme.spacing(4),\n },\n close: { marginLeft: 'auto' },\n title: {\n flexShrink: 1,\n color: theme.colors.hi,\n fontFamily: fontOf(theme.fontFamily.sans),\n fontSize: theme.fontSize.lg,\n lineHeight: theme.lineHeight.lg,\n fontWeight: theme.fontWeight.semibold,\n },\n description: {\n color: theme.colors.dim,\n fontFamily: fontOf(theme.fontFamily.sans),\n fontSize: theme.fontSize.sm,\n lineHeight: theme.lineHeightRelaxed.sm,\n },\n body: {\n gap: theme.spacing(3),\n paddingHorizontal: theme.spacing(4),\n paddingVertical: theme.spacing(3),\n },\n footer: {\n flexDirection: 'row',\n flexWrap: 'wrap',\n alignItems: 'center',\n justifyContent: 'space-between',\n gap: theme.spacing(2),\n minHeight: 34,\n borderTopWidth: 1,\n borderTopColor: theme.colors['border-soft'],\n backgroundColor: theme.colors.deep,\n paddingHorizontal: theme.spacing(4),\n paddingVertical: theme.spacing(1.5),\n },\n hint: {\n color: theme.colors.faint,\n fontFamily: fontOf(theme.fontFamily.sans),\n fontSize: theme.fontSize['2xs'],\n lineHeight: theme.lineHeight['2xs'],\n },\n}));\n"],"mappings":";;;;;;;;;;;;;;AAwBA,MAAasB,eAAepB,cAA0B;CAAEkB,MAAM;CAAOC,eAAeE;AAAU,CAAC;AAU/F,SAAgBK,MAAM,EAAER,MAAMK,cAAc,OAAOC,cAAcC,YAAwB;CACvF,MAAM,CAACE,SAASR,WAAWP,gBAAgBM,MAAMK,aAAaC,YAAY;CAC1E,MAAMI,QAAQxB,eAAe;EAAEc,MAAMS;EAASR;CAAQ,IAAI,CAACQ,SAASR,OAAO,CAAC;CAC5E,OAAO,oBAAC,aAAa,UAAd;EAA8BS;EAAQH;CAAgC;AAC/E;;AAGA,SAAgBI,aAAa,EAAEC,SAAS,GAAGC,SAAsB;CAC/D,MAAM,EAAEZ,YAAYhB,WAAWiB,YAAY;CAC3C,OACE,oBAAC,QAAD;EACE,UAAUY,UAAU;GAClBF,UAAUE,KAAK;GACfb,QAAQ,IAAI;EACd;EACA,GAAIY;CAAM;AAGhB;;AAGA,SAAgBE,WAAW,EAAEH,SAAS,GAAGC,SAAsB;CAC7D,MAAM,EAAEZ,YAAYhB,WAAWiB,YAAY;CAC3C,OACE,oBAAC,QAAD;EACE,UAAUY,UAAU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MiB,WAAWC,IAAI;EACxCC,UAAUnB,MAAMmB,SAASM;EACzBJ,YAAYrB,MAAM0B,kBAAkBD;EAAEb,mBAAA,CAAA,CAAA;CACxC;CACAhB,MAAM;EACJO,KAAKH,MAAMI,QAAQ,CAAC;EACpBO,mBAAmBX,MAAMI,QAAQ,CAAC;EAClCuB,iBAAiB3B,MAAMI,QAAQ,CAAC;EAACQ,mBAAA,CAAA,CAAA;CACnC;CACA1C,QAAQ;EACN+B,eAAe;EACf2B,UAAU;EACV1B,YAAY;EACZ2B,gBAAgB;EAChB1B,KAAKH,MAAMI,QAAQ,CAAC;EACpB0B,WAAW;EACXC,gBAAgB;EAChBC,gBAAgBhC,MAAMS,OAAO;EAC7BwB,iBAAiBjC,MAAMS,OAAOyB;EAC9BvB,mBAAmBX,MAAMI,QAAQ,CAAC;EAClCuB,iBAAiB3B,MAAMI,QAAQ,GAAG;EAACQ,mBAAA,CAAA,CAAA;CACrC;CACAd,MAAM;EACJiB,OAAOf,MAAMS,OAAO0B;EACpBlB,YAAYvE,OAAOsD,MAAMiB,WAAWC,IAAI;EACxCC,UAAUnB,MAAMmB,SAAS;EACzBE,YAAYrB,MAAMqB,WAAW;EAAMT,mBAAA,CAAA,CAAA;CACrC;AACF,EAAE"}
|
|
1
|
+
{"version":3,"file":"Sheet.mjs","names":["useT","NativeColorToken","createContext","ReactNode","useCallback","useContext","useMemo","StyleProp","TextProps","ViewProps","ViewStyle","StyleSheet","CloseIcon","fontOf","useControllable","wrapText","Button","ButtonProps","SheetFrame","SheetState","open","setOpen","SheetContext","undefined","SheetProps","defaultOpen","onOpenChange","children","Sheet","current","value","SheetTrigger","onPress","props","event","SheetClose","SheetContentProps","footer","scrollable","keep","onDismiss","snapPoints","backdrop","background","SheetContent","close","pinned","SheetPartProps","Omit","style","SheetHeaderProps","dismissible","closeLabel","SheetHeader","closeLabelProp","t","styles","header","SheetTitle","title","SheetDescription","description","SheetBody","body","SheetFooter","hint","create","theme","flexDirection","alignItems","gap","spacing","minWidth","minHeight","paddingVertical","borderBottomWidth","borderBottomColor","colors","border","paddingHorizontal","uni__dependencies","marginLeft","flexShrink","color","hi","fontFamily","sans","fontSize","lg","lineHeight","fontWeight","semibold","dim","sm","lineHeightRelaxed","flexWrap","justifyContent","borderTopWidth","borderTopColor","backgroundColor","deep","faint"],"sources":["../../src/components/Sheet.tsx"],"sourcesContent":["import { useT } from '@agimon-ai/po-core/native';\nimport type { NativeColorToken } from '@agimon-ai/po-web-components/nativeTheme';\nimport { createContext, type ReactNode, useCallback, useContext, useMemo } from 'react';\nimport { type StyleProp, Text, type TextProps, View, type ViewProps, type ViewStyle } from 'react-native';\nimport { StyleSheet } from 'react-native-unistyles';\n\nimport { CloseIcon } from '../icons/icons';\nimport { fontOf } from '../lib/fonts';\nimport { useControllable } from '../lib/useControllable';\nimport { wrapText } from '../lib/wrapText';\nimport { Button, type ButtonProps } from './Button';\nimport { SheetFrame } from './SheetFrame';\n\n/*\n * The web Sheet as a bottom sheet: the native shape for a detail view or a\n * short form over what the reader was looking at. `side` and `width` are\n * dropped; a phone sheet rises from the bottom edge and takes the width.\n */\n\ninterface SheetState {\n open: boolean;\n setOpen: (open: boolean) => void;\n}\n\nexport const SheetContext = createContext<SheetState>({ open: false, setOpen: () => undefined });\n\nexport interface SheetProps {\n /** Controlled mode; pair with onOpenChange. Omit it and the sheet keeps its own state. */\n open?: boolean;\n defaultOpen?: boolean;\n onOpenChange?: (open: boolean) => void;\n children?: ReactNode;\n}\n\nexport function Sheet({ open, defaultOpen = false, onOpenChange, children }: SheetProps) {\n const [current, setOpen] = useControllable(open, defaultOpen, onOpenChange);\n const value = useMemo(() => ({ open: current, setOpen }), [current, setOpen]);\n return <SheetContext.Provider value={value}>{children}</SheetContext.Provider>;\n}\n\n/** A Button that opens the enclosing sheet. */\nexport function SheetTrigger({ onPress, ...props }: ButtonProps) {\n const { setOpen } = useContext(SheetContext);\n return (\n <Button\n onPress={(event) => {\n onPress?.(event);\n setOpen(true);\n }}\n {...props}\n />\n );\n}\n\n/** A Button that closes the enclosing sheet. */\nexport function SheetClose({ onPress, ...props }: ButtonProps) {\n const { setOpen } = useContext(SheetContext);\n return (\n <Button\n onPress={(event) => {\n onPress?.(event);\n setOpen(false);\n }}\n {...props}\n />\n );\n}\n\nexport interface SheetContentProps {\n children?: ReactNode;\n /** Pinned actions outside the scrolling body. The footer carries the bottom safe area. */\n footer?: ReactNode;\n /** False when an embedded SheetList owns vertical scrolling. */\n scrollable?: boolean;\n /** The sheet holds unsaved work: a prompt arriving in the conversation leaves it open with a note. */\n keep?: boolean;\n /** Runs after the native modal is dismissed, including a caller-initiated close. */\n onDismiss?: () => void;\n /** Fixed heights such as `['58%']`; given, the sheet stops sizing itself to its content. */\n snapPoints?: (string | number)[];\n /** The dimmed overlay that closes the sheet on tap. Off leaves what is behind visible and usable. */\n backdrop?: boolean;\n /** The sheet and footer surface colour. */\n background?: NativeColorToken;\n}\n\n/** The sheet surface. Fields inside it switch to the sheet's own input so the keyboard lifts the sheet. */\nexport function SheetContent({\n children,\n scrollable = true,\n footer,\n keep,\n onDismiss,\n snapPoints,\n backdrop,\n background,\n}: SheetContentProps) {\n const { open, setOpen } = useContext(SheetContext);\n const value = useMemo(() => ({ open, setOpen }), [open, setOpen]);\n const close = useCallback(() => setOpen(false), [setOpen]);\n const pinned = useMemo(\n () => (footer === undefined ? undefined : <SheetContext.Provider value={value}>{footer}</SheetContext.Provider>),\n [footer, value],\n );\n return (\n <SheetFrame\n open={open}\n onClose={close}\n scrollable={scrollable}\n keep={keep}\n onDismiss={onDismiss}\n snapPoints={snapPoints}\n backdrop={backdrop}\n background={background}\n {...(pinned === undefined ? {} : { footer: pinned })}\n >\n <SheetContext.Provider value={value}>{children}</SheetContext.Provider>\n </SheetFrame>\n );\n}\n\nexport interface SheetPartProps extends Omit<ViewProps, 'children' | 'style'> {\n children?: ReactNode;\n style?: StyleProp<ViewStyle>;\n}\n\nexport interface SheetHeaderProps extends SheetPartProps {\n /** Show the close control at the right of the strip. On by default: a sheet is dismissed, not answered. */\n dismissible?: boolean;\n /** What the close control announces. */\n closeLabel?: string;\n}\n\nexport function SheetHeader({\n dismissible = true,\n closeLabel: closeLabelProp,\n style,\n children,\n ...props\n}: SheetHeaderProps) {\n const t = useT();\n const closeLabel = closeLabelProp ?? t('nativeComponents.dialog.close', 'close');\n const { setOpen } = useContext(SheetContext);\n return (\n <View style={[styles.header, style]} {...props}>\n {children}\n {dismissible ? (\n <Button\n variant=\"ghost\"\n size=\"icon\"\n accessibilityLabel={closeLabel}\n onPress={() => setOpen(false)}\n style={styles.close}\n >\n <CloseIcon size={12} color=\"faint\" />\n </Button>\n ) : null}\n </View>\n );\n}\n\nexport function SheetTitle({ style, ...props }: TextProps) {\n // No line cap: a title at a large Dynamic Type size wraps instead of truncating.\n return <Text accessibilityRole=\"header\" style={[styles.title, style]} {...props} />;\n}\n\nexport function SheetDescription({ style, ...props }: TextProps) {\n return <Text style={[styles.description, style]} {...props} />;\n}\n\n/** The scrolling middle; the sheet itself scrolls, so this only spaces its children. */\nexport function SheetBody({ style, children, ...props }: SheetPartProps) {\n return (\n <View style={[styles.body, style]} {...props}>\n {wrapText(children, styles.description)}\n </View>\n );\n}\n\nexport function SheetFooter({ style, children, ...props }: SheetPartProps) {\n return (\n <View style={[styles.footer, style]} {...props}>\n {wrapText(children, styles.hint)}\n </View>\n );\n}\n\nconst styles = StyleSheet.create((theme) => ({\n header: {\n flexDirection: 'row',\n alignItems: 'center',\n gap: theme.spacing(2.5),\n minWidth: 0,\n // minHeight, not height: a title and description at a large Dynamic Type size push the strip taller.\n minHeight: theme.spacing(11),\n paddingVertical: theme.spacing(1.5),\n borderBottomWidth: 1,\n borderBottomColor: theme.colors.border,\n paddingHorizontal: theme.spacing(4),\n },\n close: { marginLeft: 'auto' },\n title: {\n flexShrink: 1,\n color: theme.colors.hi,\n fontFamily: fontOf(theme.fontFamily.sans),\n fontSize: theme.fontSize.lg,\n lineHeight: theme.lineHeight.lg,\n fontWeight: theme.fontWeight.semibold,\n },\n description: {\n color: theme.colors.dim,\n fontFamily: fontOf(theme.fontFamily.sans),\n fontSize: theme.fontSize.sm,\n lineHeight: theme.lineHeightRelaxed.sm,\n },\n body: {\n gap: theme.spacing(3),\n paddingHorizontal: theme.spacing(4),\n paddingVertical: theme.spacing(3),\n },\n footer: {\n flexDirection: 'row',\n flexWrap: 'wrap',\n alignItems: 'center',\n justifyContent: 'space-between',\n gap: theme.spacing(2),\n minHeight: 34,\n borderTopWidth: 1,\n borderTopColor: theme.colors['border-soft'],\n backgroundColor: theme.colors.deep,\n paddingHorizontal: theme.spacing(4),\n paddingVertical: theme.spacing(1.5),\n },\n hint: {\n color: theme.colors.faint,\n fontFamily: fontOf(theme.fontFamily.sans),\n fontSize: theme.fontSize['2xs'],\n lineHeight: theme.lineHeight['2xs'],\n },\n}));\n"],"mappings":";;;;;;;;;;;;;;AAwBA,MAAasB,eAAepB,cAA0B;CAAEkB,MAAM;CAAOC,eAAeE;AAAU,CAAC;AAU/F,SAAgBK,MAAM,EAAER,MAAMK,cAAc,OAAOC,cAAcC,YAAwB;CACvF,MAAM,CAACE,SAASR,WAAWP,gBAAgBM,MAAMK,aAAaC,YAAY;CAC1E,MAAMI,QAAQxB,eAAe;EAAEc,MAAMS;EAASR;CAAQ,IAAI,CAACQ,SAASR,OAAO,CAAC;CAC5E,OAAO,oBAAC,aAAa,UAAd;EAA8BS;EAAQH;CAAgC;AAC/E;;AAGA,SAAgBI,aAAa,EAAEC,SAAS,GAAGC,SAAsB;CAC/D,MAAM,EAAEZ,YAAYhB,WAAWiB,YAAY;CAC3C,OACE,oBAAC,QAAD;EACE,UAAUY,UAAU;GAClBF,UAAUE,KAAK;GACfb,QAAQ,IAAI;EACd;EACA,GAAIY;CAAM;AAGhB;;AAGA,SAAgBE,WAAW,EAAEH,SAAS,GAAGC,SAAsB;CAC7D,MAAM,EAAEZ,YAAYhB,WAAWiB,YAAY;CAC3C,OACE,oBAAC,QAAD;EACE,U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MAAMU,OAAOe;EACpBP,YAAYxE,OAAOsD,MAAMkB,WAAWC,IAAI;EACxCC,UAAUpB,MAAMoB,SAASM;EACzBJ,YAAYtB,MAAM2B,kBAAkBD;EAAEb,mBAAA,CAAA,CAAA;CACxC;CACAjB,MAAM;EACJO,KAAKH,MAAMI,QAAQ,CAAC;EACpBQ,mBAAmBZ,MAAMI,QAAQ,CAAC;EAClCG,iBAAiBP,MAAMI,QAAQ,CAAC;EAACS,mBAAA,CAAA,CAAA;CACnC;CACA3C,QAAQ;EACN+B,eAAe;EACf2B,UAAU;EACV1B,YAAY;EACZ2B,gBAAgB;EAChB1B,KAAKH,MAAMI,QAAQ,CAAC;EACpBE,WAAW;EACXwB,gBAAgB;EAChBC,gBAAgB/B,MAAMU,OAAO;EAC7BsB,iBAAiBhC,MAAMU,OAAOuB;EAC9BrB,mBAAmBZ,MAAMI,QAAQ,CAAC;EAClCG,iBAAiBP,MAAMI,QAAQ,GAAG;EAACS,mBAAA,CAAA,CAAA;CACrC;CACAf,MAAM;EACJkB,OAAOhB,MAAMU,OAAOwB;EACpBhB,YAAYxE,OAAOsD,MAAMkB,WAAWC,IAAI;EACxCC,UAAUpB,MAAMoB,SAAS;EACzBE,YAAYtB,MAAMsB,WAAW;EAAMT,mBAAA,CAAA,CAAA;CACrC;AACF,EAAE"}
|
package/dist/components/Tabs.mjs
CHANGED
|
@@ -170,7 +170,7 @@ const styles = StyleSheet.create((theme) => ({
|
|
|
170
170
|
badge: {
|
|
171
171
|
alignItems: "center",
|
|
172
172
|
justifyContent: "center",
|
|
173
|
-
|
|
173
|
+
minHeight: BADGE_SIZE,
|
|
174
174
|
minWidth: BADGE_SIZE,
|
|
175
175
|
borderRadius: theme.borderRadius.full,
|
|
176
176
|
paddingHorizontal: theme.spacing(1),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Tabs.mjs","names":["createContext","ReactNode","useContext","useMemo","StyleProp","ViewProps","ViewStyle","StyleSheet","fontOf","selectionTick","useControllable","wrapText","TAB_HEIGHT","MIN_TAP_TARGET","DISABLED_OPACITY","BADGE_SIZE","TabsState","value","setValue","TabsContext","undefined","TabActiveContext","TabsProps","Omit","defaultValue","onValueChange","children","style","Tabs","props","current","next","context","styles","tabs","TabsListProps","TabsList","listScroll","list","TabsTriggerProps","disabled","accessibilityLabel","TabsTrigger","active","_styles","useVariants","selected","pressed","tab","label","labelPressed","TabsContentProps","TabsContent","content","contentText","TabBadgeProps","TabBadge","inherited","_styles2","badge","badgeText","create","theme","gap","spacing","uni__dependencies","flexGrow","flexDirection","alignItems","minHeight","minWidth","borderRadius","DEFAULT","paddingHorizontal","paddingVertical","variants","true","backgroundColor","colors","false","panel","opacity","fontFamily","sans","fontSize","base","lineHeight","color","green","fontWeight","semibold","dim","medium","hi","sm","justifyContent","height","full","idle","rail"],"sources":["../../src/components/Tabs.tsx"],"sourcesContent":["import { createContext, type ReactNode, useContext, useMemo } from 'react';\nimport { Pressable, ScrollView, type StyleProp, Text, View, type ViewProps, type ViewStyle } from 'react-native';\nimport { StyleSheet } from 'react-native-unistyles';\n\nimport { fontOf } from '../lib/fonts';\nimport { selectionTick } from '../lib/haptics';\nimport { useControllable } from '../lib/useControllable';\nimport { wrapText } from '../lib/wrapText';\n\n/*\n * The web Tabs on a horizontal ScrollView: a strip that scrolls when the tabs\n * outgrow the screen, the active tab in a green tint, and a selection tick on\n * each change. The panels swap in place.\n */\n\n/** `min-h-6`, padded to Apple's 44pt tap target by hitSlop. */\nconst TAB_HEIGHT = 24;\nconst MIN_TAP_TARGET = 44;\nconst DISABLED_OPACITY = 0.4;\nconst BADGE_SIZE = 15;\n\ninterface TabsState {\n value: string | undefined;\n setValue: (value: string) => void;\n}\n\nconst TabsContext = createContext<TabsState>({ value: undefined, setValue: () => undefined });\n/** Whether the enclosing trigger is active, so a TabBadge inverts without being told. */\nconst TabActiveContext = createContext(false);\n\nexport interface TabsProps extends Omit<ViewProps, 'children' | 'style'> {\n /** Controlled mode; pair with onValueChange. Omit it and the tabs keep their own state. */\n value?: string;\n defaultValue?: string;\n onValueChange?: (value: string) => void;\n children?: ReactNode;\n style?: StyleProp<ViewStyle>;\n}\n\nexport function Tabs({ value, defaultValue, onValueChange, children, style, ...props }: TabsProps) {\n const [current, setValue] = useControllable<string | undefined>(\n value,\n defaultValue,\n onValueChange as ((next: string | undefined) => void) | undefined,\n );\n const context = useMemo(() => ({ value: current, setValue }), [current, setValue]);\n return (\n <TabsContext.Provider value={context}>\n <View style={[styles.tabs, style]} {...props}>\n {children}\n </View>\n </TabsContext.Provider>\n );\n}\n\nexport interface TabsListProps {\n children?: ReactNode;\n style?: StyleProp<ViewStyle>;\n}\n\n/** The tab strip; it scrolls sideways when the tabs outgrow it. */\nexport function TabsList({ children, style }: TabsListProps) {\n return (\n <ScrollView\n horizontal\n showsHorizontalScrollIndicator={false}\n accessibilityRole=\"tablist\"\n style={styles.listScroll}\n contentContainerStyle={[styles.list, style]}\n >\n {children}\n </ScrollView>\n );\n}\n\nexport interface TabsTriggerProps {\n value: string;\n disabled?: boolean;\n /** The label; a bare string is drawn in the tab's type, and a TabBadge may follow it. */\n children?: ReactNode;\n accessibilityLabel?: string;\n style?: StyleProp<ViewStyle>;\n}\n\nexport function TabsTrigger({ value, disabled = false, children, accessibilityLabel, style }: TabsTriggerProps) {\n const tabs = useContext(TabsContext);\n const active = tabs.value === value;\n styles.useVariants({ active });\n return (\n <Pressable\n accessibilityRole=\"tab\"\n accessibilityLabel={accessibilityLabel}\n accessibilityState={{ selected: active, disabled }}\n disabled={disabled}\n hitSlop={(MIN_TAP_TARGET - TAB_HEIGHT) / 2}\n onPress={() => {\n if (active) return;\n selectionTick();\n tabs.setValue(value);\n }}\n style={({ pressed }) => [styles.tab, pressed && !active && styles.pressed, disabled && styles.disabled, style]}\n >\n {({ pressed }) => (\n <TabActiveContext.Provider value={active}>\n {wrapText(children, [styles.label, pressed && !active && styles.labelPressed])}\n </TabActiveContext.Provider>\n )}\n </Pressable>\n );\n}\n\nexport interface TabsContentProps extends Omit<ViewProps, 'children' | 'style'> {\n value: string;\n children?: ReactNode;\n style?: StyleProp<ViewStyle>;\n}\n\n/** The panel for one tab; only the active one renders. */\nexport function TabsContent({ value, children, style, ...props }: TabsContentProps) {\n const tabs = useContext(TabsContext);\n if (tabs.value !== value) return null;\n return (\n <View style={[styles.content, style]} {...props}>\n {wrapText(children, styles.contentText)}\n </View>\n );\n}\n\nexport interface TabBadgeProps {\n /** Defaults to the enclosing tab's state: it inverts on the active tab so it stays readable on the tint. */\n active?: boolean;\n children?: ReactNode;\n style?: StyleProp<ViewStyle>;\n}\n\n/** The count beside a tab's label. */\nexport function TabBadge({ active, children, style }: TabBadgeProps) {\n const inherited = useContext(TabActiveContext);\n styles.useVariants({ badge: (active ?? inherited) ? 'active' : 'idle' });\n return (\n <View style={[styles.badge, style]}>\n <Text style={styles.badgeText}>{children}</Text>\n </View>\n );\n}\n\nconst styles = StyleSheet.create((theme) => ({\n tabs: { gap: theme.spacing(2) },\n listScroll: { flexGrow: 0 },\n list: { flexDirection: 'row', alignItems: 'center', gap: theme.spacing(1) },\n tab: {\n flexDirection: 'row',\n alignItems: 'center',\n gap: theme.spacing(1.5),\n minHeight: TAB_HEIGHT,\n minWidth: TAB_HEIGHT,\n borderRadius: theme.borderRadius.DEFAULT,\n paddingHorizontal: theme.spacing(2),\n paddingVertical: theme.spacing(1),\n variants: {\n active: {\n true: { backgroundColor: theme.colors['tint-green'] },\n false: {},\n },\n },\n },\n pressed: { backgroundColor: theme.colors.panel },\n disabled: { opacity: DISABLED_OPACITY },\n label: {\n fontFamily: fontOf(theme.fontFamily.sans),\n fontSize: theme.fontSize.base,\n lineHeight: theme.lineHeight.base,\n variants: {\n active: {\n true: { color: theme.colors.green, fontWeight: theme.fontWeight.semibold },\n false: { color: theme.colors.dim, fontWeight: theme.fontWeight.medium },\n },\n },\n },\n labelPressed: { color: theme.colors.hi },\n content: { flexGrow: 1, minHeight: 0 },\n contentText: {\n color: theme.colors.dim,\n fontFamily: fontOf(theme.fontFamily.sans),\n fontSize: theme.fontSize.sm,\n lineHeight: theme.lineHeight.sm,\n },\n badge: {\n alignItems: 'center',\n justifyContent: 'center',\n height: BADGE_SIZE,\n minWidth: BADGE_SIZE,\n borderRadius: theme.borderRadius.full,\n paddingHorizontal: theme.spacing(1),\n variants: {\n badge: {\n active: { backgroundColor: theme.colors.green },\n idle: { backgroundColor: theme.colors.panel },\n },\n },\n },\n badgeText: {\n fontFamily: fontOf(theme.fontFamily.sans),\n fontSize: theme.fontSize['2xs'],\n lineHeight: theme.lineHeight['2xs'],\n fontWeight: theme.fontWeight.semibold,\n variants: {\n badge: {\n active: { color: theme.colors.rail },\n idle: { color: theme.colors.dim },\n },\n },\n },\n}));\n"],"mappings":";;;;;;;;;;;;;;AAgBA,MAAMY,aAAa;AAEnB,MAAME,mBAAmB;AACzB,MAAMC,aAAa;AAOnB,MAAMI,cAAcnB,cAAyB;CAAEiB,OAAOG;CAAWF,gBAAgBE;AAAU,CAAC;;AAE5F,MAAMC,mBAAmBrB,cAAc,KAAK;AAW5C,SAAgB4B,KAAK,EAAEX,OAAOO,cAAcC,eAAeC,UAAUC,OAAO,GAAGE,SAAoB;CACjG,MAAM,CAACC,SAASZ,YAAYR,gBAC1BO,OACAO,cACAC,aACF;CACA,MAAMO,UAAU7B,eAAe;EAAEc,OAAOa;EAASZ;CAAS,IAAI,CAACY,SAASZ,QAAQ,CAAC;CACjF,OACE,oBAAC,YAAY,UAAb;EAAsB,OAAOc;YAC3B,oBAAC,MAAD;GAAM,OAAO,CAACC,OAAOC,MAAMP,KAAK;GAAG,GAAIE;GACpCH;EACG;CACc;AAE1B;;AAQA,SAAgBU,SAAS,EAAEV,UAAUC,SAAwB;CAC3D,OACE,oBAAC,YAAD;EACE;EACA,gCAAgC;EAChC,mBAAkB;EAClB,OAAOM,OAAOI;EACd,uBAAuB,CAACJ,OAAOK,MAAMX,KAAK;EAEzCD;CACS;AAEhB;AAWA,SAAgBgB,YA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Ea,UAAU;EAAGG,WAAW;CAAE;CACrCf,aAAa;EACXiC,OAAOzB,MAAMgB,OAAOa;EACpBT,YAAY1E,OAAOsD,MAAMoB,WAAWC,IAAI;EACxCC,UAAUtB,MAAMsB,SAASU;EACzBR,YAAYxB,MAAMwB,WAAWQ;EAAE7B,mBAAA,CAAA,CAAA;CACjC;CACAN,OAAO;EACLS,YAAY;EACZ2B,gBAAgB;EAChBC,QAAQjF;EACRuD,UAAUvD;EACVwD,cAAcT,MAAMS,aAAa0B;EACjCxB,mBAAmBX,MAAME,QAAQ,CAAC;EAClCW,UAAU,EACRhB,OAAO;GACLhB,QAAQ,EAAEkC,iBAAiBf,MAAMgB,OAAOU,MAAM;GAC9CU,MAAM,EAAErB,iBAAiBf,MAAMgB,OAAOE,MAAM;EAC9C,EACF;EAACf,mBAAA,CAAA,GAAA,CAAA;CACH;CACAL,WAAW;EACTsB,YAAY1E,OAAOsD,MAAMoB,WAAWC,IAAI;EACxCC,UAAUtB,MAAMsB,SAAS;EACzBE,YAAYxB,MAAMwB,WAAW;EAC7BG,YAAY3B,MAAM2B,WAAWC;EAC7Bf,UAAU,EACRhB,OAAO;GACLhB,QAAQ,EAAE4C,OAAOzB,MAAMgB,OAAOqB,KAAK;GACnCD,MAAM,EAAEX,OAAOzB,MAAMgB,OAAOa,IAAI;EAClC,EACF;EAAC1B,mBAAA,CAAA,GAAA,CAAA;CACH;AACF,EAAE"}
|
|
1
|
+
{"version":3,"file":"Tabs.mjs","names":["createContext","ReactNode","useContext","useMemo","StyleProp","ViewProps","ViewStyle","StyleSheet","fontOf","selectionTick","useControllable","wrapText","TAB_HEIGHT","MIN_TAP_TARGET","DISABLED_OPACITY","BADGE_SIZE","TabsState","value","setValue","TabsContext","undefined","TabActiveContext","TabsProps","Omit","defaultValue","onValueChange","children","style","Tabs","props","current","next","context","styles","tabs","TabsListProps","TabsList","listScroll","list","TabsTriggerProps","disabled","accessibilityLabel","TabsTrigger","active","_styles","useVariants","selected","pressed","tab","label","labelPressed","TabsContentProps","TabsContent","content","contentText","TabBadgeProps","TabBadge","inherited","_styles2","badge","badgeText","create","theme","gap","spacing","uni__dependencies","flexGrow","flexDirection","alignItems","minHeight","minWidth","borderRadius","DEFAULT","paddingHorizontal","paddingVertical","variants","true","backgroundColor","colors","false","panel","opacity","fontFamily","sans","fontSize","base","lineHeight","color","green","fontWeight","semibold","dim","medium","hi","sm","justifyContent","full","idle","rail"],"sources":["../../src/components/Tabs.tsx"],"sourcesContent":["import { createContext, type ReactNode, useContext, useMemo } from 'react';\nimport { Pressable, ScrollView, type StyleProp, Text, View, type ViewProps, type ViewStyle } from 'react-native';\nimport { StyleSheet } from 'react-native-unistyles';\n\nimport { fontOf } from '../lib/fonts';\nimport { selectionTick } from '../lib/haptics';\nimport { useControllable } from '../lib/useControllable';\nimport { wrapText } from '../lib/wrapText';\n\n/*\n * The web Tabs on a horizontal ScrollView: a strip that scrolls when the tabs\n * outgrow the screen, the active tab in a green tint, and a selection tick on\n * each change. The panels swap in place.\n */\n\n/** `min-h-6`, padded to Apple's 44pt tap target by hitSlop. */\nconst TAB_HEIGHT = 24;\nconst MIN_TAP_TARGET = 44;\nconst DISABLED_OPACITY = 0.4;\nconst BADGE_SIZE = 15;\n\ninterface TabsState {\n value: string | undefined;\n setValue: (value: string) => void;\n}\n\nconst TabsContext = createContext<TabsState>({ value: undefined, setValue: () => undefined });\n/** Whether the enclosing trigger is active, so a TabBadge inverts without being told. */\nconst TabActiveContext = createContext(false);\n\nexport interface TabsProps extends Omit<ViewProps, 'children' | 'style'> {\n /** Controlled mode; pair with onValueChange. Omit it and the tabs keep their own state. */\n value?: string;\n defaultValue?: string;\n onValueChange?: (value: string) => void;\n children?: ReactNode;\n style?: StyleProp<ViewStyle>;\n}\n\nexport function Tabs({ value, defaultValue, onValueChange, children, style, ...props }: TabsProps) {\n const [current, setValue] = useControllable<string | undefined>(\n value,\n defaultValue,\n onValueChange as ((next: string | undefined) => void) | undefined,\n );\n const context = useMemo(() => ({ value: current, setValue }), [current, setValue]);\n return (\n <TabsContext.Provider value={context}>\n <View style={[styles.tabs, style]} {...props}>\n {children}\n </View>\n </TabsContext.Provider>\n );\n}\n\nexport interface TabsListProps {\n children?: ReactNode;\n style?: StyleProp<ViewStyle>;\n}\n\n/** The tab strip; it scrolls sideways when the tabs outgrow it. */\nexport function TabsList({ children, style }: TabsListProps) {\n return (\n <ScrollView\n horizontal\n showsHorizontalScrollIndicator={false}\n accessibilityRole=\"tablist\"\n style={styles.listScroll}\n contentContainerStyle={[styles.list, style]}\n >\n {children}\n </ScrollView>\n );\n}\n\nexport interface TabsTriggerProps {\n value: string;\n disabled?: boolean;\n /** The label; a bare string is drawn in the tab's type, and a TabBadge may follow it. */\n children?: ReactNode;\n accessibilityLabel?: string;\n style?: StyleProp<ViewStyle>;\n}\n\nexport function TabsTrigger({ value, disabled = false, children, accessibilityLabel, style }: TabsTriggerProps) {\n const tabs = useContext(TabsContext);\n const active = tabs.value === value;\n styles.useVariants({ active });\n return (\n <Pressable\n accessibilityRole=\"tab\"\n accessibilityLabel={accessibilityLabel}\n accessibilityState={{ selected: active, disabled }}\n disabled={disabled}\n hitSlop={(MIN_TAP_TARGET - TAB_HEIGHT) / 2}\n onPress={() => {\n if (active) return;\n selectionTick();\n tabs.setValue(value);\n }}\n style={({ pressed }) => [styles.tab, pressed && !active && styles.pressed, disabled && styles.disabled, style]}\n >\n {({ pressed }) => (\n <TabActiveContext.Provider value={active}>\n {wrapText(children, [styles.label, pressed && !active && styles.labelPressed])}\n </TabActiveContext.Provider>\n )}\n </Pressable>\n );\n}\n\nexport interface TabsContentProps extends Omit<ViewProps, 'children' | 'style'> {\n value: string;\n children?: ReactNode;\n style?: StyleProp<ViewStyle>;\n}\n\n/** The panel for one tab; only the active one renders. */\nexport function TabsContent({ value, children, style, ...props }: TabsContentProps) {\n const tabs = useContext(TabsContext);\n if (tabs.value !== value) return null;\n return (\n <View style={[styles.content, style]} {...props}>\n {wrapText(children, styles.contentText)}\n </View>\n );\n}\n\nexport interface TabBadgeProps {\n /** Defaults to the enclosing tab's state: it inverts on the active tab so it stays readable on the tint. */\n active?: boolean;\n children?: ReactNode;\n style?: StyleProp<ViewStyle>;\n}\n\n/** The count beside a tab's label. */\nexport function TabBadge({ active, children, style }: TabBadgeProps) {\n const inherited = useContext(TabActiveContext);\n styles.useVariants({ badge: (active ?? inherited) ? 'active' : 'idle' });\n return (\n <View style={[styles.badge, style]}>\n <Text style={styles.badgeText}>{children}</Text>\n </View>\n );\n}\n\nconst styles = StyleSheet.create((theme) => ({\n tabs: { gap: theme.spacing(2) },\n listScroll: { flexGrow: 0 },\n list: { flexDirection: 'row', alignItems: 'center', gap: theme.spacing(1) },\n tab: {\n flexDirection: 'row',\n alignItems: 'center',\n gap: theme.spacing(1.5),\n minHeight: TAB_HEIGHT,\n minWidth: TAB_HEIGHT,\n borderRadius: theme.borderRadius.DEFAULT,\n paddingHorizontal: theme.spacing(2),\n paddingVertical: theme.spacing(1),\n variants: {\n active: {\n true: { backgroundColor: theme.colors['tint-green'] },\n false: {},\n },\n },\n },\n pressed: { backgroundColor: theme.colors.panel },\n disabled: { opacity: DISABLED_OPACITY },\n label: {\n fontFamily: fontOf(theme.fontFamily.sans),\n fontSize: theme.fontSize.base,\n lineHeight: theme.lineHeight.base,\n variants: {\n active: {\n true: { color: theme.colors.green, fontWeight: theme.fontWeight.semibold },\n false: { color: theme.colors.dim, fontWeight: theme.fontWeight.medium },\n },\n },\n },\n labelPressed: { color: theme.colors.hi },\n content: { flexGrow: 1, minHeight: 0 },\n contentText: {\n color: theme.colors.dim,\n fontFamily: fontOf(theme.fontFamily.sans),\n fontSize: theme.fontSize.sm,\n lineHeight: theme.lineHeight.sm,\n },\n badge: {\n alignItems: 'center',\n justifyContent: 'center',\n minHeight: BADGE_SIZE,\n minWidth: BADGE_SIZE,\n borderRadius: theme.borderRadius.full,\n paddingHorizontal: theme.spacing(1),\n variants: {\n badge: {\n active: { backgroundColor: theme.colors.green },\n idle: { backgroundColor: theme.colors.panel },\n },\n },\n },\n badgeText: {\n fontFamily: fontOf(theme.fontFamily.sans),\n fontSize: theme.fontSize['2xs'],\n lineHeight: theme.lineHeight['2xs'],\n fontWeight: theme.fontWeight.semibold,\n variants: {\n badge: {\n active: { color: theme.colors.rail },\n idle: { color: theme.colors.dim },\n },\n },\n },\n}));\n"],"mappings":";;;;;;;;;;;;;;AAgBA,MAAMY,aAAa;AAEnB,MAAME,mBAAmB;AACzB,MAAMC,aAAa;AAOnB,MAAMI,cAAcnB,cAAyB;CAAEiB,OAAOG;CAAWF,gBAAgBE;AAAU,CAAC;;AAE5F,MAAMC,mBAAmBrB,cAAc,KAAK;AAW5C,SAAgB4B,KAAK,EAAEX,OAAOO,cAAcC,eAAeC,UAAUC,OAAO,GAAGE,SAAoB;CACjG,MAAM,CAACC,SAASZ,YAAYR,gBAC1BO,OACAO,cACAC,aACF;CACA,MAAMO,UAAU7B,eAAe;EAAEc,OAAOa;EAASZ;CAAS,IAAI,CAACY,SAASZ,QAAQ,CAAC;CACjF,OACE,oBAAC,YAAY,UAAb;EAAsB,OAAOc;YAC3B,oBAAC,MAAD;GAAM,OAAO,CAACC,OAAOC,MAAMP,KAAK;GAAG,GAAIE;GACpCH;EACG;CACc;AAE1B;;AAQA,SAAgBU,SAAS,EAAEV,UAAUC,SAAwB;CAC3D,OACE,oBAAC,YAAD;EACE;EACA,gCAAgC;EAChC,mBAAkB;EAClB,OAAOM,OAAOI;EACd,uBAAuB,CAACJ,OAAOK,MAAMX,KAAK;EAEzCD;CACS;AAEhB;AAWA,SAAgBgB,YAAY,EAAEzB,OAAOuB,WAAW,OAAOd,UAAUe,oBAAoBd,SAA2B;CAC9G,MAAMO,OAAOhC,WAAWiB,WAAW;CACnC,MAAMwB,SAAST,KAAKjB,UAAUA;CAAM,MAAA2B,UAAAX;CAAA;EAAA,MAAAA,SAAAW,QAAAC,YACjB,EAAEF,OAAO,CAAC;EAC7B,OACE,oBAAC,WAAD;GACE,mB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2B,gBAAgB;EAChB1B,WAAWtD;EACXuD,UAAUvD;EACVwD,cAAcT,MAAMS,aAAayB;EACjCvB,mBAAmBX,MAAME,QAAQ,CAAC;EAClCW,UAAU,EACRhB,OAAO;GACLhB,QAAQ,EAAEkC,iBAAiBf,MAAMgB,OAAOU,MAAM;GAC9CS,MAAM,EAAEpB,iBAAiBf,MAAMgB,OAAOE,MAAM;EAC9C,EACF;EAACf,mBAAA,CAAA,GAAA,CAAA;CACH;CACAL,WAAW;EACTsB,YAAY1E,OAAOsD,MAAMoB,WAAWC,IAAI;EACxCC,UAAUtB,MAAMsB,SAAS;EACzBE,YAAYxB,MAAMwB,WAAW;EAC7BG,YAAY3B,MAAM2B,WAAWC;EAC7Bf,UAAU,EACRhB,OAAO;GACLhB,QAAQ,EAAE4C,OAAOzB,MAAMgB,OAAOoB,KAAK;GACnCD,MAAM,EAAEV,OAAOzB,MAAMgB,OAAOa,IAAI;EAClC,EACF;EAAC1B,mBAAA,CAAA,GAAA,CAAA;CACH;AACF,EAAE"}
|
|
@@ -18,6 +18,10 @@ export declare const ICON_GLYPHS: {
|
|
|
18
18
|
readonly sf: "chevron.right";
|
|
19
19
|
readonly material: "chevron-right";
|
|
20
20
|
};
|
|
21
|
+
readonly ChevronLeft: {
|
|
22
|
+
readonly sf: "chevron.left";
|
|
23
|
+
readonly material: "chevron-left";
|
|
24
|
+
};
|
|
21
25
|
readonly ChevronUp: {
|
|
22
26
|
readonly sf: "chevron.up";
|
|
23
27
|
readonly material: "expand-less";
|
|
@@ -198,6 +202,14 @@ export declare const ICON_GLYPHS: {
|
|
|
198
202
|
readonly sf: "hand.raised";
|
|
199
203
|
readonly material: "pan-tool";
|
|
200
204
|
};
|
|
205
|
+
readonly Pointer: {
|
|
206
|
+
readonly sf: "cursorarrow";
|
|
207
|
+
readonly material: "near-me";
|
|
208
|
+
};
|
|
209
|
+
readonly Note: {
|
|
210
|
+
readonly sf: "note.text";
|
|
211
|
+
readonly material: "sticky-note-2";
|
|
212
|
+
};
|
|
201
213
|
readonly Pin: {
|
|
202
214
|
readonly sf: "mappin";
|
|
203
215
|
readonly material: "place";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"iconGlyphs.d.mts","names":[],"sources":["../../src/icons/iconGlyphs.ts"],"mappings":";;;;;;;qBAMa
|
|
1
|
+
{"version":3,"file":"iconGlyphs.d.mts","names":[],"sources":["../../src/icons/iconGlyphs.ts"],"mappings":";;;;;;;qBAMa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;YAyED,wBAAwB"}
|
|
@@ -18,6 +18,10 @@ const ICON_GLYPHS = {
|
|
|
18
18
|
sf: "chevron.right",
|
|
19
19
|
material: "chevron-right"
|
|
20
20
|
},
|
|
21
|
+
ChevronLeft: {
|
|
22
|
+
sf: "chevron.left",
|
|
23
|
+
material: "chevron-left"
|
|
24
|
+
},
|
|
21
25
|
ChevronUp: {
|
|
22
26
|
sf: "chevron.up",
|
|
23
27
|
material: "expand-less"
|
|
@@ -198,6 +202,14 @@ const ICON_GLYPHS = {
|
|
|
198
202
|
sf: "hand.raised",
|
|
199
203
|
material: "pan-tool"
|
|
200
204
|
},
|
|
205
|
+
Pointer: {
|
|
206
|
+
sf: "cursorarrow",
|
|
207
|
+
material: "near-me"
|
|
208
|
+
},
|
|
209
|
+
Note: {
|
|
210
|
+
sf: "note.text",
|
|
211
|
+
material: "sticky-note-2"
|
|
212
|
+
},
|
|
201
213
|
Pin: {
|
|
202
214
|
sf: "mappin",
|
|
203
215
|
material: "place"
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"iconGlyphs.mjs","names":[],"sources":["../../src/icons/iconGlyphs.ts"],"sourcesContent":["/**\n * The curated native icon set: the same names the web library re-exports from\n * lucide, each drawn with the platform's own family. iOS gets an SF Symbol,\n * Android and web get a Material Icons glyph. Kept free of React Native so a\n * unit test can check every glyph against the installed glyph map.\n */\nexport const ICON_GLYPHS = {\n Check: { sf: 'checkmark', material: 'check' },\n ChevronDown: { sf: 'chevron.down', material: 'expand-more' },\n ChevronRight: { sf: 'chevron.right', material: 'chevron-right' },\n ChevronUp: { sf: 'chevron.up', material: 'expand-less' },\n Alert: { sf: 'exclamationmark.circle', material: 'error-outline' },\n Copy: { sf: 'doc.on.doc', material: 'content-copy' },\n Message: { sf: 'message', material: 'chat-bubble-outline' },\n // Each platform's own overflow mark: a horizontal ellipsis on iOS, vertical dots on Android.\n Kebab: { sf: 'ellipsis', material: 'more-vert' },\n Menu: { sf: 'line.3.horizontal', material: 'menu' },\n Edit: { sf: 'pencil', material: 'edit' },\n Gear: { sf: 'gearshape', material: 'settings' },\n Send: { sf: 'paperplane', material: 'send' },\n Task: { sf: 'checkmark.square', material: 'check-box' },\n Trash: { sf: 'trash', material: 'delete-outline' },\n Wrench: { sf: 'wrench.and.screwdriver', material: 'build' },\n Close: { sf: 'xmark', material: 'close' },\n File: { sf: 'doc', material: 'insert-drive-file' },\n Search: { sf: 'magnifyingglass', material: 'search' },\n Image: { sf: 'photo', material: 'image' },\n Sliders: { sf: 'slider.horizontal.3', material: 'tune' },\n Folder: { sf: 'folder', material: 'folder' },\n Globe: { sf: 'globe', material: 'public' },\n Languages: { sf: 'translate', material: 'translate' },\n Branch: { sf: 'arrow.triangle.branch', material: 'call-split' },\n // ponytail: SF Symbols has no fork distinct from a branch, so iOS draws Fork as Branch. Swap in a custom symbol if the two must differ there.\n Fork: { sf: 'arrow.triangle.branch', material: 'fork-right' },\n Home: { sf: 'house', material: 'home' },\n Activity: { sf: 'waveform.path.ecg', material: 'monitor-heart' },\n ArrowRight: { sf: 'arrow.right', material: 'arrow-forward' },\n Plus: { sf: 'plus', material: 'add' },\n User: { sf: 'person', material: 'person-outline' },\n Users: { sf: 'person.2', material: 'group' },\n IdCard: { sf: 'person.text.rectangle', material: 'badge' },\n PlayCircle: { sf: 'play.circle', material: 'play-circle-outline' },\n Workflow: { sf: 'flowchart', material: 'account-tree' },\n Palette: { sf: 'paintpalette', material: 'palette' },\n Lightbulb: { sf: 'lightbulb', material: 'lightbulb-outline' },\n Sparkles: { sf: 'sparkles', material: 'auto-awesome' },\n Lock: { sf: 'lock', material: 'lock-outline' },\n Shield: { sf: 'checkmark.shield', material: 'verified-user' },\n Download: { sf: 'square.and.arrow.down', material: 'file-download' },\n Mic: { sf: 'mic', material: 'mic' },\n Monitor: { sf: 'laptopcomputer', material: 'laptop' },\n Server: { sf: 'server.rack', material: 'dns' },\n Smartphone: { sf: 'iphone', material: 'smartphone' },\n AudioLines: { sf: 'waveform', material: 'graphic-eq' },\n Stop: { sf: 'stop.fill', material: 'stop' },\n Terminal: { sf: 'apple.terminal', material: 'terminal' },\n Hand: { sf: 'hand.raised', material: 'pan-tool' },\n Pin: { sf: 'mappin', material: 'place' },\n Box: { sf: 'square', material: 'crop-square' },\n Undo: { sf: 'arrow.uturn.backward', material: 'undo' },\n Redo: { sf: 'arrow.uturn.forward', material: 'redo' },\n ArrowUpRight: { sf: 'arrow.up.right', material: 'north-east' },\n Highlighter: { sf: 'highlighter', material: 'border-color' },\n Eraser: { sf: 'eraser', material: 'auto-fix-normal' },\n Minus: { sf: 'minus', material: 'remove' },\n Fit: { sf: 'viewfinder', material: 'fit-screen' },\n Refresh: { sf: 'arrow.clockwise', material: 'refresh' },\n Calendar: { sf: 'calendar', material: 'event' },\n Play: { sf: 'play.fill', material: 'play-arrow' },\n Pause: { sf: 'pause.fill', material: 'pause' },\n Back10: { sf: 'gobackward.10', material: 'replay-10' },\n Forward10: { sf: 'goforward.10', material: 'forward-10' },\n StepBack: { sf: 'backward.frame', material: 'skip-previous' },\n StepForward: { sf: 'forward.frame', material: 'skip-next' },\n} as const;\n\nexport type IconName = keyof typeof ICON_GLYPHS;\n"],"mappings":";;;;;;;AAMA,MAAa,cAAc;CACzB,OAAO;EAAE,IAAI;EAAa,UAAU;CAAQ;CAC5C,aAAa;EAAE,IAAI;EAAgB,UAAU;CAAc;CAC3D,cAAc;EAAE,IAAI;EAAiB,UAAU;CAAgB;CAC/D,WAAW;EAAE,IAAI;EAAc,UAAU;CAAc;CACvD,OAAO;EAAE,IAAI;EAA0B,UAAU;CAAgB;CACjE,MAAM;EAAE,IAAI;EAAc,UAAU;CAAe;CACnD,SAAS;EAAE,IAAI;EAAW,UAAU;CAAsB;CAE1D,OAAO;EAAE,IAAI;EAAY,UAAU;CAAY;CAC/C,MAAM;EAAE,IAAI;EAAqB,UAAU;CAAO;CAClD,MAAM;EAAE,IAAI;EAAU,UAAU;CAAO;CACvC,MAAM;EAAE,IAAI;EAAa,UAAU;CAAW;CAC9C,MAAM;EAAE,IAAI;EAAc,UAAU;CAAO;CAC3C,MAAM;EAAE,IAAI;EAAoB,UAAU;CAAY;CACtD,OAAO;EAAE,IAAI;EAAS,UAAU;CAAiB;CACjD,QAAQ;EAAE,IAAI;EAA0B,UAAU;CAAQ;CAC1D,OAAO;EAAE,IAAI;EAAS,UAAU;CAAQ;CACxC,MAAM;EAAE,IAAI;EAAO,UAAU;CAAoB;CACjD,QAAQ;EAAE,IAAI;EAAmB,UAAU;CAAS;CACpD,OAAO;EAAE,IAAI;EAAS,UAAU;CAAQ;CACxC,SAAS;EAAE,IAAI;EAAuB,UAAU;CAAO;CACvD,QAAQ;EAAE,IAAI;EAAU,UAAU;CAAS;CAC3C,OAAO;EAAE,IAAI;EAAS,UAAU;CAAS;CACzC,WAAW;EAAE,IAAI;EAAa,UAAU;CAAY;CACpD,QAAQ;EAAE,IAAI;EAAyB,UAAU;CAAa;CAE9D,MAAM;EAAE,IAAI;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U;CAAa;CAC7D,aAAa;EAAE,IAAI;EAAe,UAAU;CAAe;CAC3D,QAAQ;EAAE,IAAI;EAAU,UAAU;CAAkB;CACpD,OAAO;EAAE,IAAI;EAAS,UAAU;CAAS;CACzC,KAAK;EAAE,IAAI;EAAc,UAAU;CAAa;CAChD,SAAS;EAAE,IAAI;EAAmB,UAAU;CAAU;CACtD,UAAU;EAAE,IAAI;EAAY,UAAU;CAAQ;CAC9C,MAAM;EAAE,IAAI;EAAa,UAAU;CAAa;CAChD,OAAO;EAAE,IAAI;EAAc,UAAU;CAAQ;CAC7C,QAAQ;EAAE,IAAI;EAAiB,UAAU;CAAY;CACrD,WAAW;EAAE,IAAI;EAAgB,UAAU;CAAa;CACxD,UAAU;EAAE,IAAI;EAAkB,UAAU;CAAgB;CAC5D,aAAa;EAAE,IAAI;EAAiB,UAAU;CAAY;AAC5D"}
|
|
1
|
+
{"version":3,"file":"iconGlyphs.mjs","names":[],"sources":["../../src/icons/iconGlyphs.ts"],"sourcesContent":["/**\n * The curated native icon set: the same names the web library re-exports from\n * lucide, each drawn with the platform's own family. iOS gets an SF Symbol,\n * Android and web get a Material Icons glyph. Kept free of React Native so a\n * unit test can check every glyph against the installed glyph map.\n */\nexport const ICON_GLYPHS = {\n Check: { sf: 'checkmark', material: 'check' },\n ChevronDown: { sf: 'chevron.down', material: 'expand-more' },\n ChevronRight: { sf: 'chevron.right', material: 'chevron-right' },\n ChevronLeft: { sf: 'chevron.left', material: 'chevron-left' },\n ChevronUp: { sf: 'chevron.up', material: 'expand-less' },\n Alert: { sf: 'exclamationmark.circle', material: 'error-outline' },\n Copy: { sf: 'doc.on.doc', material: 'content-copy' },\n Message: { sf: 'message', material: 'chat-bubble-outline' },\n // Each platform's own overflow mark: a horizontal ellipsis on iOS, vertical dots on Android.\n Kebab: { sf: 'ellipsis', material: 'more-vert' },\n Menu: { sf: 'line.3.horizontal', material: 'menu' },\n Edit: { sf: 'pencil', material: 'edit' },\n Gear: { sf: 'gearshape', material: 'settings' },\n Send: { sf: 'paperplane', material: 'send' },\n Task: { sf: 'checkmark.square', material: 'check-box' },\n Trash: { sf: 'trash', material: 'delete-outline' },\n Wrench: { sf: 'wrench.and.screwdriver', material: 'build' },\n Close: { sf: 'xmark', material: 'close' },\n File: { sf: 'doc', material: 'insert-drive-file' },\n Search: { sf: 'magnifyingglass', material: 'search' },\n Image: { sf: 'photo', material: 'image' },\n Sliders: { sf: 'slider.horizontal.3', material: 'tune' },\n Folder: { sf: 'folder', material: 'folder' },\n Globe: { sf: 'globe', material: 'public' },\n Languages: { sf: 'translate', material: 'translate' },\n Branch: { sf: 'arrow.triangle.branch', material: 'call-split' },\n // ponytail: SF Symbols has no fork distinct from a branch, so iOS draws Fork as Branch. Swap in a custom symbol if the two must differ there.\n Fork: { sf: 'arrow.triangle.branch', material: 'fork-right' },\n Home: { sf: 'house', material: 'home' },\n Activity: { sf: 'waveform.path.ecg', material: 'monitor-heart' },\n ArrowRight: { sf: 'arrow.right', material: 'arrow-forward' },\n Plus: { sf: 'plus', material: 'add' },\n User: { sf: 'person', material: 'person-outline' },\n Users: { sf: 'person.2', material: 'group' },\n IdCard: { sf: 'person.text.rectangle', material: 'badge' },\n PlayCircle: { sf: 'play.circle', material: 'play-circle-outline' },\n Workflow: { sf: 'flowchart', material: 'account-tree' },\n Palette: { sf: 'paintpalette', material: 'palette' },\n Lightbulb: { sf: 'lightbulb', material: 'lightbulb-outline' },\n Sparkles: { sf: 'sparkles', material: 'auto-awesome' },\n Lock: { sf: 'lock', material: 'lock-outline' },\n Shield: { sf: 'checkmark.shield', material: 'verified-user' },\n Download: { sf: 'square.and.arrow.down', material: 'file-download' },\n Mic: { sf: 'mic', material: 'mic' },\n Monitor: { sf: 'laptopcomputer', material: 'laptop' },\n Server: { sf: 'server.rack', material: 'dns' },\n Smartphone: { sf: 'iphone', material: 'smartphone' },\n AudioLines: { sf: 'waveform', material: 'graphic-eq' },\n Stop: { sf: 'stop.fill', material: 'stop' },\n Terminal: { sf: 'apple.terminal', material: 'terminal' },\n Hand: { sf: 'hand.raised', material: 'pan-tool' },\n Pointer: { sf: 'cursorarrow', material: 'near-me' },\n Note: { sf: 'note.text', material: 'sticky-note-2' },\n Pin: { sf: 'mappin', material: 'place' },\n Box: { sf: 'square', material: 'crop-square' },\n Undo: { sf: 'arrow.uturn.backward', material: 'undo' },\n Redo: { sf: 'arrow.uturn.forward', material: 'redo' },\n ArrowUpRight: { sf: 'arrow.up.right', material: 'north-east' },\n Highlighter: { sf: 'highlighter', material: 'border-color' },\n Eraser: { sf: 'eraser', material: 'auto-fix-normal' },\n Minus: { sf: 'minus', material: 'remove' },\n Fit: { sf: 'viewfinder', material: 'fit-screen' },\n Refresh: { sf: 'arrow.clockwise', material: 'refresh' },\n Calendar: { sf: 'calendar', material: 'event' },\n Play: { sf: 'play.fill', material: 'play-arrow' },\n Pause: { sf: 'pause.fill', material: 'pause' },\n Back10: { sf: 'gobackward.10', material: 'replay-10' },\n Forward10: { sf: 'goforward.10', material: 'forward-10' },\n StepBack: { sf: 'backward.frame', material: 'skip-previous' },\n StepForward: { sf: 'forward.frame', material: 'skip-next' },\n} as const;\n\nexport type IconName = keyof typeof ICON_GLYPHS;\n"],"mappings":";;;;;;;AAMA,MAAa,cAAc;CACzB,OAAO;EAAE,IAAI;EAAa,UAAU;CAAQ;CAC5C,aAAa;EAAE,IAAI;EAAgB,UAAU;CAAc;CAC3D,cAAc;EAAE,IAAI;EAAiB,UAAU;CAAgB;CAC/D,aAAa;EAAE,IAAI;EAAgB,UAAU;CAAe;CAC5D,WAAW;EAAE,IAAI;EAAc,UAAU;CAAc;CACvD,OAAO;EAAE,IAAI;EAA0B,UAAU;CAAgB;CACjE,MAAM;EAAE,IAAI;EAAc,UAAU;CAAe;CACnD,SAAS;EAAE,IAAI;EAAW,UAAU;CAAsB;CAE1D,OAAO;EAAE,IAAI;EAAY,UAAU;CAAY;CAC/C,MAAM;EAAE,IAAI;EAAqB,UAAU;CAAO;CAClD,MAAM;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;CAAgB;CAC5D,aAAa;EAAE,IAAI;EAAiB,UAAU;CAAY;AAC5D"}
|
package/dist/icons/icons.d.mts
CHANGED
|
@@ -22,6 +22,10 @@ export declare const ChevronRightIcon: {
|
|
|
22
22
|
({ size, color, accessibilityLabel, style }: IconProps): import("react").JSX.Element;
|
|
23
23
|
displayName: string;
|
|
24
24
|
};
|
|
25
|
+
export declare const ChevronLeftIcon: {
|
|
26
|
+
({ size, color, accessibilityLabel, style }: IconProps): import("react").JSX.Element;
|
|
27
|
+
displayName: string;
|
|
28
|
+
};
|
|
25
29
|
export declare const ChevronUpIcon: {
|
|
26
30
|
({ size, color, accessibilityLabel, style }: IconProps): import("react").JSX.Element;
|
|
27
31
|
displayName: string;
|
|
@@ -202,6 +206,14 @@ export declare const HandIcon: {
|
|
|
202
206
|
({ size, color, accessibilityLabel, style }: IconProps): import("react").JSX.Element;
|
|
203
207
|
displayName: string;
|
|
204
208
|
};
|
|
209
|
+
export declare const PointerIcon: {
|
|
210
|
+
({ size, color, accessibilityLabel, style }: IconProps): import("react").JSX.Element;
|
|
211
|
+
displayName: string;
|
|
212
|
+
};
|
|
213
|
+
export declare const NoteIcon: {
|
|
214
|
+
({ size, color, accessibilityLabel, style }: IconProps): import("react").JSX.Element;
|
|
215
|
+
displayName: string;
|
|
216
|
+
};
|
|
205
217
|
export declare const PinIcon: {
|
|
206
218
|
({ size, color, accessibilityLabel, style }: IconProps): import("react").JSX.Element;
|
|
207
219
|
displayName: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"icons.d.mts","names":[],"sources":["../../src/icons/icons.tsx"],"mappings":";;;iBAaiB;;EAEf;;EAEA,QAAQ;;EAER;EACA,QAAQ,UAAU;;qBAkCP;KA7B8D,MAAA,OAAA,oBAAA,SAAA,4BAAS,IAAA;;;qBA8BvE;KA9B8D,MAAA,OAAA,oBAAA,SAAA,4BAAS,IAAA;;;qBA+BvE;KA/B8D,MAAA,OAAA,oBAAA,SAAA,4BAAS,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
51
|
const ChevronRightIcon = createIcon("ChevronRight");
|
|
52
|
+
const ChevronLeftIcon = createIcon("ChevronLeft");
|
|
52
53
|
const ChevronUpIcon = createIcon("ChevronUp");
|
|
53
54
|
const AlertIcon = createIcon("Alert");
|
|
54
55
|
const CopyIcon = createIcon("Copy");
|
|
@@ -94,6 +95,8 @@ const AudioLinesIcon = createIcon("AudioLines");
|
|
|
94
95
|
const StopIcon = createIcon("Stop");
|
|
95
96
|
const TerminalIcon = createIcon("Terminal");
|
|
96
97
|
const HandIcon = createIcon("Hand");
|
|
98
|
+
const PointerIcon = createIcon("Pointer");
|
|
99
|
+
const NoteIcon = createIcon("Note");
|
|
97
100
|
const PinIcon = createIcon("Pin");
|
|
98
101
|
const BoxIcon = createIcon("Box");
|
|
99
102
|
const UndoIcon = createIcon("Undo");
|
|
@@ -113,5 +116,5 @@ const StepBackIcon = createIcon("StepBack");
|
|
|
113
116
|
const StepForwardIcon = createIcon("StepForward");
|
|
114
117
|
|
|
115
118
|
//#endregion
|
|
116
|
-
export { ActivityIcon, AlertIcon, ArrowRightIcon, ArrowUpRightIcon, AudioLinesIcon, Back10Icon, BoxIcon, BranchIcon, CalendarIcon, CheckIcon, ChevronDownIcon, ChevronRightIcon, ChevronUpIcon, CloseIcon, CopyIcon, DownloadIcon, EditIcon, EraserIcon, FileIcon, FitIcon, FolderIcon, ForkIcon, Forward10Icon, GearIcon, GlobeIcon, HandIcon, HighlighterIcon, HomeIcon, IdCardIcon, ImageIcon, KebabIcon, LanguagesIcon, LightbulbIcon, LockIcon, MenuIcon, MessageIcon, MicIcon, MinusIcon, MonitorIcon, PaletteIcon, PauseIcon, PinIcon, PlayCircleIcon, PlayIcon, PlusIcon, RedoIcon, RefreshIcon, SearchIcon, SendIcon, ServerIcon, ShieldIcon, SlidersIcon, SmartphoneIcon, SparklesIcon, StepBackIcon, StepForwardIcon, StopIcon, TaskIcon, TerminalIcon, TrashIcon, UndoIcon, UserIcon, UsersIcon, WorkflowIcon, WrenchIcon };
|
|
119
|
+
export { ActivityIcon, AlertIcon, ArrowRightIcon, ArrowUpRightIcon, AudioLinesIcon, Back10Icon, BoxIcon, BranchIcon, CalendarIcon, CheckIcon, ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon, ChevronUpIcon, CloseIcon, CopyIcon, DownloadIcon, EditIcon, EraserIcon, FileIcon, FitIcon, FolderIcon, ForkIcon, Forward10Icon, GearIcon, GlobeIcon, HandIcon, HighlighterIcon, HomeIcon, IdCardIcon, ImageIcon, KebabIcon, LanguagesIcon, LightbulbIcon, LockIcon, MenuIcon, MessageIcon, MicIcon, MinusIcon, MonitorIcon, NoteIcon, PaletteIcon, PauseIcon, PinIcon, PlayCircleIcon, PlayIcon, PlusIcon, PointerIcon, RedoIcon, RefreshIcon, SearchIcon, SendIcon, ServerIcon, ShieldIcon, SlidersIcon, SmartphoneIcon, SparklesIcon, StepBackIcon, StepForwardIcon, StopIcon, TaskIcon, TerminalIcon, TrashIcon, UndoIcon, UserIcon, UsersIcon, WorkflowIcon, WrenchIcon };
|
|
117
120
|
//# sourceMappingURL=icons.mjs.map
|
package/dist/icons/icons.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"icons.mjs","names":["IconColorContext","NativeColorToken","MaterialIcons","SymbolView","useContext","Platform","StyleProp","ViewStyle","useUnistyles","ICON_GLYPHS","IconName","DEFAULT_SIZE","DEFAULT_COLOR","IconProps","size","color","accessibilityLabel","style","createIcon","name","glyph","Icon","theme","inherited","tint","colors","a11y","undefined","accessible","importantForAccessibility","accessibilityElementsHidden","const","accessibilityRole","OS","sf","width","height","material","displayName","CheckIcon","ChevronDownIcon","ChevronRightIcon","ChevronUpIcon","AlertIcon","CopyIcon","MessageIcon","KebabIcon","MenuIcon","EditIcon","GearIcon","SendIcon","TaskIcon","TrashIcon","WrenchIcon","CloseIcon","FolderIcon","GlobeIcon","LanguagesIcon","BranchIcon","ForkIcon","HomeIcon","ActivityIcon","ArrowRightIcon","PlusIcon","UserIcon","UsersIcon","IdCardIcon","PlayCircleIcon","WorkflowIcon","PaletteIcon","LightbulbIcon","SparklesIcon","LockIcon","ShieldIcon","FileIcon","SearchIcon","ImageIcon","SlidersIcon","DownloadIcon","MicIcon","MonitorIcon","ServerIcon","SmartphoneIcon","AudioLinesIcon","StopIcon","TerminalIcon","HandIcon","PinIcon","BoxIcon","UndoIcon","RedoIcon","ArrowUpRightIcon","HighlighterIcon","EraserIcon","MinusIcon","FitIcon","RefreshIcon","CalendarIcon","PlayIcon","PauseIcon","Back10Icon","Forward10Icon","StepBackIcon","StepForwardIcon"],"sources":["../../src/icons/icons.tsx"],"sourcesContent":["import { IconColorContext } from '@agimon-ai/po-native-components/shell';\nimport type { NativeColorToken } from '@agimon-ai/po-web-components/nativeTheme';\nimport MaterialIcons from '@expo/vector-icons/MaterialIcons';\nimport { SymbolView } from 'expo-symbols';\nimport { useContext } from 'react';\nimport { Platform, type StyleProp, type ViewStyle } from 'react-native';\nimport { useUnistyles } from 'react-native-unistyles';\n\nimport { ICON_GLYPHS, type IconName } from './iconGlyphs';\n\nconst DEFAULT_SIZE = 16;\nconst DEFAULT_COLOR: NativeColorToken = 'dim';\n\nexport interface IconProps {\n /** Edge length in points. */\n size?: number;\n /** A theme token; defaults to the enclosing Button's label colour, else `dim`. */\n color?: NativeColorToken;\n /** Given one, the icon is announced as an image; without one it is hidden from screen readers. */\n accessibilityLabel?: string;\n style?: StyleProp<ViewStyle>;\n}\n\nfunction createIcon(name: IconName) {\n const glyph = ICON_GLYPHS[name];\n function Icon({ size = DEFAULT_SIZE, color, accessibilityLabel, style }: IconProps) {\n const { theme } = useUnistyles();\n const inherited = useContext(IconColorContext);\n const tint = theme.colors[color ?? inherited ?? DEFAULT_COLOR];\n const a11y =\n accessibilityLabel === undefined\n ? ({\n accessible: false,\n importantForAccessibility: 'no-hide-descendants',\n accessibilityElementsHidden: true,\n } as const)\n : ({ accessible: true, accessibilityRole: 'image', accessibilityLabel } as const);\n if (Platform.OS === 'ios') {\n return (\n <SymbolView\n name={glyph.sf}\n size={size}\n tintColor={tint}\n style={[{ width: size, height: size }, style]}\n {...a11y}\n />\n );\n }\n return <MaterialIcons name={glyph.material} size={size} color={tint} style={style} {...a11y} />;\n }\n Icon.displayName = `${name}Icon`;\n return Icon;\n}\n\nexport const CheckIcon = createIcon('Check');\nexport const ChevronDownIcon = createIcon('ChevronDown');\nexport const ChevronRightIcon = createIcon('ChevronRight');\nexport const ChevronUpIcon = createIcon('ChevronUp');\nexport const AlertIcon = createIcon('Alert');\nexport const CopyIcon = createIcon('Copy');\nexport const MessageIcon = createIcon('Message');\nexport const KebabIcon = createIcon('Kebab');\nexport const MenuIcon = createIcon('Menu');\nexport const EditIcon = createIcon('Edit');\nexport const GearIcon = createIcon('Gear');\nexport const SendIcon = createIcon('Send');\nexport const TaskIcon = createIcon('Task');\nexport const TrashIcon = createIcon('Trash');\nexport const WrenchIcon = createIcon('Wrench');\nexport const CloseIcon = createIcon('Close');\nexport const FolderIcon = createIcon('Folder');\nexport const GlobeIcon = createIcon('Globe');\nexport const LanguagesIcon = createIcon('Languages');\nexport const BranchIcon = createIcon('Branch');\nexport const ForkIcon = createIcon('Fork');\nexport const HomeIcon = createIcon('Home');\nexport const ActivityIcon = createIcon('Activity');\nexport const ArrowRightIcon = createIcon('ArrowRight');\nexport const PlusIcon = createIcon('Plus');\nexport const UserIcon = createIcon('User');\nexport const UsersIcon = createIcon('Users');\nexport const IdCardIcon = createIcon('IdCard');\nexport const PlayCircleIcon = createIcon('PlayCircle');\nexport const WorkflowIcon = createIcon('Workflow');\nexport const PaletteIcon = createIcon('Palette');\nexport const LightbulbIcon = createIcon('Lightbulb');\nexport const SparklesIcon = createIcon('Sparkles');\nexport const LockIcon = createIcon('Lock');\nexport const ShieldIcon = createIcon('Shield');\n\nexport const FileIcon = createIcon('File');\nexport const SearchIcon = createIcon('Search');\nexport const ImageIcon = createIcon('Image');\nexport const SlidersIcon = createIcon('Sliders');\nexport const DownloadIcon = createIcon('Download');\nexport const MicIcon = createIcon('Mic');\nexport const MonitorIcon = createIcon('Monitor');\nexport const ServerIcon = createIcon('Server');\nexport const SmartphoneIcon = createIcon('Smartphone');\nexport const AudioLinesIcon = createIcon('AudioLines');\nexport const StopIcon = createIcon('Stop');\nexport const TerminalIcon = createIcon('Terminal');\nexport const HandIcon = createIcon('Hand');\nexport const PinIcon = createIcon('Pin');\nexport const BoxIcon = createIcon('Box');\nexport const UndoIcon = createIcon('Undo');\nexport const RedoIcon = createIcon('Redo');\nexport const ArrowUpRightIcon = createIcon('ArrowUpRight');\nexport const HighlighterIcon = createIcon('Highlighter');\nexport const EraserIcon = createIcon('Eraser');\nexport const MinusIcon = createIcon('Minus');\nexport const FitIcon = createIcon('Fit');\nexport const RefreshIcon = createIcon('Refresh');\nexport const CalendarIcon = createIcon('Calendar');\nexport const PlayIcon = createIcon('Play');\nexport const PauseIcon = createIcon('Pause');\nexport const Back10Icon = createIcon('Back10');\nexport const Forward10Icon = createIcon('Forward10');\nexport const StepBackIcon = createIcon('StepBack');\nexport const StepForwardIcon = createIcon('StepForward');\n"],"mappings":";;;;;;;;;;AAUA,MAAMW,eAAe;AACrB,MAAMC,gBAAkC;AAYxC,SAASM,WAAWC,MAAgB;CAClC,MAAMC,QAAQX,YAAYU;CAC1B,SAASE,KAAK,EAAEP,OAAOH,cAAcI,OAAOC,oBAAoBC,SAAoB;EAClF,MAAM,EAAEK,UAAUd,aAAa;EAC/B,MAAMe,YAAYnB,WAAWJ,gBAAgB;EAC7C,MAAMwB,OAAOF,MAAMG,OAAOV,SAASQ,aAAaX;EAChD,MAAMc,OACJV,uBAAuBW,SAClB;GACCC,YAAY;GACZC,2BAA2B;GAC3BC,6BAA6B;EAC/B,IACC;GAAEF,YAAY;GAAMI,mBAAmB;GAAShB;EAAmB;EAC1E,IAAIX,SAAS4B,OAAO,OAClB,OACE,oBAAC,YAAD;GACE,MAAMb,MAAMc;GACNpB;GACN,WAAWU;GACX,OAAO,CAAC;IAAEW,OAAOrB;IAAMsB,QAAQtB;GAAK,GAAGG,KAAK;GAC5C,GAAIS;EAAK;EAIf,OAAO,oBAAC,eAAD;GAAe,MAAMN,MAAMiB;GAAgBvB;GAAM,OAAOU;GAAaP;GAAO,GAAIS;EAAK;CAC9F;CACAL,KAAKiB,cAAc,GAAGnB,KAAI;CAC1B,OAAOE;AACT;AAEA,MAAakB,YAAYrB,WAAW,OAAO;AAC3C,MAAasB,kBAAkBtB,WAAW,aAAa;AACvD,MAAauB,mBAAmBvB,WAAW,cAAc;AACzD,MAAawB,
|
|
1
|
+
{"version":3,"file":"icons.mjs","names":["IconColorContext","NativeColorToken","MaterialIcons","SymbolView","useContext","Platform","StyleProp","ViewStyle","useUnistyles","ICON_GLYPHS","IconName","DEFAULT_SIZE","DEFAULT_COLOR","IconProps","size","color","accessibilityLabel","style","createIcon","name","glyph","Icon","theme","inherited","tint","colors","a11y","undefined","accessible","importantForAccessibility","accessibilityElementsHidden","const","accessibilityRole","OS","sf","width","height","material","displayName","CheckIcon","ChevronDownIcon","ChevronRightIcon","ChevronLeftIcon","ChevronUpIcon","AlertIcon","CopyIcon","MessageIcon","KebabIcon","MenuIcon","EditIcon","GearIcon","SendIcon","TaskIcon","TrashIcon","WrenchIcon","CloseIcon","FolderIcon","GlobeIcon","LanguagesIcon","BranchIcon","ForkIcon","HomeIcon","ActivityIcon","ArrowRightIcon","PlusIcon","UserIcon","UsersIcon","IdCardIcon","PlayCircleIcon","WorkflowIcon","PaletteIcon","LightbulbIcon","SparklesIcon","LockIcon","ShieldIcon","FileIcon","SearchIcon","ImageIcon","SlidersIcon","DownloadIcon","MicIcon","MonitorIcon","ServerIcon","SmartphoneIcon","AudioLinesIcon","StopIcon","TerminalIcon","HandIcon","PointerIcon","NoteIcon","PinIcon","BoxIcon","UndoIcon","RedoIcon","ArrowUpRightIcon","HighlighterIcon","EraserIcon","MinusIcon","FitIcon","RefreshIcon","CalendarIcon","PlayIcon","PauseIcon","Back10Icon","Forward10Icon","StepBackIcon","StepForwardIcon"],"sources":["../../src/icons/icons.tsx"],"sourcesContent":["import { IconColorContext } from '@agimon-ai/po-native-components/shell';\nimport type { NativeColorToken } from '@agimon-ai/po-web-components/nativeTheme';\nimport MaterialIcons from '@expo/vector-icons/MaterialIcons';\nimport { SymbolView } from 'expo-symbols';\nimport { useContext } from 'react';\nimport { Platform, type StyleProp, type ViewStyle } from 'react-native';\nimport { useUnistyles } from 'react-native-unistyles';\n\nimport { ICON_GLYPHS, type IconName } from './iconGlyphs';\n\nconst DEFAULT_SIZE = 16;\nconst DEFAULT_COLOR: NativeColorToken = 'dim';\n\nexport interface IconProps {\n /** Edge length in points. */\n size?: number;\n /** A theme token; defaults to the enclosing Button's label colour, else `dim`. */\n color?: NativeColorToken;\n /** Given one, the icon is announced as an image; without one it is hidden from screen readers. */\n accessibilityLabel?: string;\n style?: StyleProp<ViewStyle>;\n}\n\nfunction createIcon(name: IconName) {\n const glyph = ICON_GLYPHS[name];\n function Icon({ size = DEFAULT_SIZE, color, accessibilityLabel, style }: IconProps) {\n const { theme } = useUnistyles();\n const inherited = useContext(IconColorContext);\n const tint = theme.colors[color ?? inherited ?? DEFAULT_COLOR];\n const a11y =\n accessibilityLabel === undefined\n ? ({\n accessible: false,\n importantForAccessibility: 'no-hide-descendants',\n accessibilityElementsHidden: true,\n } as const)\n : ({ accessible: true, accessibilityRole: 'image', accessibilityLabel } as const);\n if (Platform.OS === 'ios') {\n return (\n <SymbolView\n name={glyph.sf}\n size={size}\n tintColor={tint}\n style={[{ width: size, height: size }, style]}\n {...a11y}\n />\n );\n }\n return <MaterialIcons name={glyph.material} size={size} color={tint} style={style} {...a11y} />;\n }\n Icon.displayName = `${name}Icon`;\n return Icon;\n}\n\nexport const CheckIcon = createIcon('Check');\nexport const ChevronDownIcon = createIcon('ChevronDown');\nexport const ChevronRightIcon = createIcon('ChevronRight');\nexport const ChevronLeftIcon = createIcon('ChevronLeft');\nexport const ChevronUpIcon = createIcon('ChevronUp');\nexport const AlertIcon = createIcon('Alert');\nexport const CopyIcon = createIcon('Copy');\nexport const MessageIcon = createIcon('Message');\nexport const KebabIcon = createIcon('Kebab');\nexport const MenuIcon = createIcon('Menu');\nexport const EditIcon = createIcon('Edit');\nexport const GearIcon = createIcon('Gear');\nexport const SendIcon = createIcon('Send');\nexport const TaskIcon = createIcon('Task');\nexport const TrashIcon = createIcon('Trash');\nexport const WrenchIcon = createIcon('Wrench');\nexport const CloseIcon = createIcon('Close');\nexport const FolderIcon = createIcon('Folder');\nexport const GlobeIcon = createIcon('Globe');\nexport const LanguagesIcon = createIcon('Languages');\nexport const BranchIcon = createIcon('Branch');\nexport const ForkIcon = createIcon('Fork');\nexport const HomeIcon = createIcon('Home');\nexport const ActivityIcon = createIcon('Activity');\nexport const ArrowRightIcon = createIcon('ArrowRight');\nexport const PlusIcon = createIcon('Plus');\nexport const UserIcon = createIcon('User');\nexport const UsersIcon = createIcon('Users');\nexport const IdCardIcon = createIcon('IdCard');\nexport const PlayCircleIcon = createIcon('PlayCircle');\nexport const WorkflowIcon = createIcon('Workflow');\nexport const PaletteIcon = createIcon('Palette');\nexport const LightbulbIcon = createIcon('Lightbulb');\nexport const SparklesIcon = createIcon('Sparkles');\nexport const LockIcon = createIcon('Lock');\nexport const ShieldIcon = createIcon('Shield');\n\nexport const FileIcon = createIcon('File');\nexport const SearchIcon = createIcon('Search');\nexport const ImageIcon = createIcon('Image');\nexport const SlidersIcon = createIcon('Sliders');\nexport const DownloadIcon = createIcon('Download');\nexport const MicIcon = createIcon('Mic');\nexport const MonitorIcon = createIcon('Monitor');\nexport const ServerIcon = createIcon('Server');\nexport const SmartphoneIcon = createIcon('Smartphone');\nexport const AudioLinesIcon = createIcon('AudioLines');\nexport const StopIcon = createIcon('Stop');\nexport const TerminalIcon = createIcon('Terminal');\nexport const HandIcon = createIcon('Hand');\nexport const PointerIcon = createIcon('Pointer');\nexport const NoteIcon = createIcon('Note');\nexport const PinIcon = createIcon('Pin');\nexport const BoxIcon = createIcon('Box');\nexport const UndoIcon = createIcon('Undo');\nexport const RedoIcon = createIcon('Redo');\nexport const ArrowUpRightIcon = createIcon('ArrowUpRight');\nexport const HighlighterIcon = createIcon('Highlighter');\nexport const EraserIcon = createIcon('Eraser');\nexport const MinusIcon = createIcon('Minus');\nexport const FitIcon = createIcon('Fit');\nexport const RefreshIcon = createIcon('Refresh');\nexport const CalendarIcon = createIcon('Calendar');\nexport const PlayIcon = createIcon('Play');\nexport const PauseIcon = createIcon('Pause');\nexport const Back10Icon = createIcon('Back10');\nexport const Forward10Icon = createIcon('Forward10');\nexport const StepBackIcon = createIcon('StepBack');\nexport const StepForwardIcon = createIcon('StepForward');\n"],"mappings":";;;;;;;;;;AAUA,MAAMW,eAAe;AACrB,MAAMC,gBAAkC;AAYxC,SAASM,WAAWC,MAAgB;CAClC,MAAMC,QAAQX,YAAYU;CAC1B,SAASE,KAAK,EAAEP,OAAOH,cAAcI,OAAOC,oBAAoBC,SAAoB;EAClF,MAAM,EAAEK,UAAUd,aAAa;EAC/B,MAAMe,YAAYnB,WAAWJ,gBAAgB;EAC7C,MAAMwB,OAAOF,MAAMG,OAAOV,SAASQ,aAAaX;EAChD,MAAMc,OACJV,uBAAuBW,SAClB;GACCC,YAAY;GACZC,2BAA2B;GAC3BC,6BAA6B;EAC/B,IACC;GAAEF,YAAY;GAAMI,mBAAmB;GAAShB;EAAmB;EAC1E,IAAIX,SAAS4B,OAAO,OAClB,OACE,oBAAC,YAAD;GACE,MAAMb,MAAMc;GACNpB;GACN,WAAWU;GACX,OAAO,CAAC;IAAEW,OAAOrB;IAAMsB,QAAQtB;GAAK,GAAGG,KAAK;GAC5C,GAAIS;EAAK;EAIf,OAAO,oBAAC,eAAD;GAAe,MAAMN,MAAMiB;GAAgBvB;GAAM,OAAOU;GAAaP;GAAO,GAAIS;EAAK;CAC9F;CACAL,KAAKiB,cAAc,GAAGnB,KAAI;CAC1B,OAAOE;AACT;AAEA,MAAakB,YAAYrB,WA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ileLinkHandler, Markdown, MarkdownImageLoader, MarkdownProps, ReferenceRenderer } from "./components/Markdown.mjs";
|
|
23
23
|
import { LinkText, LinkTextProps } from "./components/LinkText.mjs";
|
|
24
24
|
import { List, ListProps, ListRow, ListRowProps } from "./components/List.mjs";
|
|
25
|
-
import { ActivityIcon, AlertIcon, ArrowRightIcon, ArrowUpRightIcon, AudioLinesIcon, Back10Icon, BoxIcon, BranchIcon, CalendarIcon, CheckIcon, ChevronDownIcon, ChevronRightIcon, ChevronUpIcon, CloseIcon, CopyIcon, DownloadIcon, EditIcon, EraserIcon, FileIcon, FitIcon, FolderIcon, ForkIcon, Forward10Icon, GearIcon, GlobeIcon, HandIcon, HighlighterIcon, HomeIcon, IconProps, IdCardIcon, ImageIcon, KebabIcon, LanguagesIcon, LightbulbIcon, LockIcon, MenuIcon, MessageIcon, MicIcon, MinusIcon, MonitorIcon, PaletteIcon, PauseIcon, PinIcon, PlayCircleIcon, PlayIcon, PlusIcon, RedoIcon, RefreshIcon, SearchIcon, SendIcon, ServerIcon, ShieldIcon, SlidersIcon, SmartphoneIcon, SparklesIcon, StepBackIcon, StepForwardIcon, StopIcon, TaskIcon, TerminalIcon, TrashIcon, UndoIcon, UserIcon, UsersIcon, WorkflowIcon, WrenchIcon } from "./icons/icons.mjs";
|
|
25
|
+
import { ActivityIcon, AlertIcon, ArrowRightIcon, ArrowUpRightIcon, AudioLinesIcon, Back10Icon, BoxIcon, BranchIcon, CalendarIcon, CheckIcon, ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon, ChevronUpIcon, CloseIcon, CopyIcon, DownloadIcon, EditIcon, EraserIcon, FileIcon, FitIcon, FolderIcon, ForkIcon, Forward10Icon, GearIcon, GlobeIcon, HandIcon, HighlighterIcon, HomeIcon, IconProps, IdCardIcon, ImageIcon, KebabIcon, LanguagesIcon, LightbulbIcon, LockIcon, MenuIcon, MessageIcon, MicIcon, MinusIcon, MonitorIcon, NoteIcon, PaletteIcon, PauseIcon, PinIcon, PlayCircleIcon, PlayIcon, PlusIcon, PointerIcon, RedoIcon, RefreshIcon, SearchIcon, SendIcon, ServerIcon, ShieldIcon, SlidersIcon, SmartphoneIcon, SparklesIcon, StepBackIcon, StepForwardIcon, StopIcon, TaskIcon, TerminalIcon, TrashIcon, UndoIcon, UserIcon, UsersIcon, WorkflowIcon, WrenchIcon } from "./icons/icons.mjs";
|
|
26
26
|
import { RailItem, RailItemProps } from "./components/RailItem.mjs";
|
|
27
27
|
import { ReferenceChip } from "./components/ReferenceChip.mjs";
|
|
28
28
|
import { STATUS_EDGE, StatusBadge, StatusBadgeProps, StatusBadgeSize, StatusTone } from "./components/StatusBadge.mjs";
|
|
@@ -49,4 +49,4 @@ import { HostTag } from "./components/HostTag.mjs";
|
|
|
49
49
|
import { InfoStrip } from "./components/InfoStrip.mjs";
|
|
50
50
|
import { AnsiSpan, BoundedFileSource, FileFilters, FileItem, FileKind, FileLayout, FileModified, FileRangeLoader, FileSort, FileSortDirection, FileStatus, FileStatusFilter, FileTextPreview, FileTreeRow, PresentedLine, ReviewComment, ageLabel, ansiSpans, boundedFileSource, buildReviewPrompt, collapseLines, fileAssetPath, fileKind, filePreviewMode, fileTree, filterFiles, hashlineBody, isFileLayout, modifiedLabel, newestFiles, readMediaBytes, resultTextLines, sizeLabel, sortFiles } from "@agimon-ai/po-web-components/text";
|
|
51
51
|
import { IconColorContext, LiveDuration, LiveDurationProps, LiveDurationReading, PoNativeProvider, PoNativeProviderProps, sheetsYielded, yieldSheets } from "@agimon-ai/po-native-components/shell";
|
|
52
|
-
export { ActivityIcon, AgentAvatar, type AgentState, AlertIcon, type AnnotationMark, AnnotationSurface, type AnnotationSurfaceProps, type AnsiSpan, ArrowRightIcon, ArrowUpRightIcon, AudioLinesIcon, Back10Icon, Badge, type BadgeProps, type BadgeSize, type BadgeTone, type BoundedFileSource, BoxIcon, BranchIcon, Button, type ButtonProps, type ButtonSize, type ButtonVariant, CalendarIcon, CheckIcon, ChevronDownIcon, ChevronRightIcon, ChevronUpIcon, CloseIcon, CodeBlock, type CodeBlockProps, ComputerRow, type ComputerRowProps, type ComputerStatus, CopyButton, type CopyButtonProps, CopyIcon, CountBadge, type CountBadgeProps, CtaCard, type CtaCardProps, Dialog, DialogBody, DialogClose, DialogContent, type DialogContentProps, DialogDescription, DialogFooter, type DialogFooterProps, type DialogFooterVariant, DialogHeader, type DialogHeaderProps, type DialogPartProps, type DialogProps, DialogTitle, DialogTrigger, type DialogWidth, Dot, type DotProps, type DotSize, type DotTone, DownloadIcon, DropdownMenu, DropdownMenuCheckboxItem, type DropdownMenuCheckboxItemProps, DropdownMenuContent, type DropdownMenuContentProps, DropdownMenuGroup, DropdownMenuItem, type DropdownMenuItemProps, type DropdownMenuItemVariant, DropdownMenuLabel, type DropdownMenuPartProps, type DropdownMenuProps, DropdownMenuRadioGroup, type DropdownMenuRadioGroupProps, DropdownMenuRadioItem, type DropdownMenuRadioItemProps, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuTrigger, EditIcon, EmptyState, type EmptyStateAction, type EmptyStateProps, type EmptyStateSize, EraserIcon, type FieldSize, type FieldVariant, type FileBrowserControls, type FileFilters, FileIcon, type FileItem, type FileKind, type FileLayout, type FileLinkHandler, FileList, type FileListProps, type FileModified, FilePathStrip, FilePreview, type FilePreviewProps, type FileRangeLoader, type FileSort, type FileSortDirection, type FileStatus, type FileStatusFilter, type FileTextPreview, type FileTreeRow, FileViewer, FileViewerHeader, type FileViewerProps, FitIcon, FolderIcon, ForkIcon, Forward10Icon, GearIcon, GlobeIcon, HandIcon, HashlineLines, type HashlineLinesProps, HighlighterIcon, HomeIcon, HostFilter, type HostFilterProps, HostTag, IconColorContext, type IconName, type IconProps, IdCardIcon, ImageIcon, InfoStrip, Input, type InputProps, KebabIcon, Label, type LabelProps, LanguagesIcon, LightbulbIcon, LinkText, type LinkTextProps, List, type ListProps, ListRow, type ListRowProps, LiveDuration, type LiveDurationProps, type LiveDurationReading, LoadingState, type LoadingStateProps, type LoadingStateSize, LockIcon, Markdown, type MarkdownImageLoader, type MarkdownProps, MenuIcon, MessageIcon, MessageItem, MessageItemBody, MessageItemGroup, type MessageItemGroupProps, MessageItemHeader, type MessageItemHeaderProps, type MessageItemPartProps, type MessageItemProps, type MessageItemState, MessageItemStatus, type MessageItemStatusProps, MicIcon, MinusIcon, MonitorIcon, PaletteIcon, Panel, PanelBody, PanelHeader, type PanelPartProps, PauseIcon, PinIcon, PlayCircleIcon, PlayIcon, PlusIcon, PoNativeProvider, type PoNativeProviderProps, type PresentedLine, RailItem, type RailItemProps, RedoIcon, ReferenceChip, type ReferenceRenderer, RefreshIcon, type ReviewComment, STATUS_EDGE, STATUS_GLYPH, STATUS_LABEL, SearchIcon, SectionLabel, SeekBar, type SeekBarProps, SegmentedControl, type SegmentedControlOption, type SegmentedControlProps, Select, type SelectOption, type SelectProps, SendIcon, ServerIcon, Sheet, SheetBody, SheetClose, SheetContent, type SheetContentProps, SheetDescription, SheetFooter, SheetHeader, type SheetHeaderProps, SheetList, type SheetListProps, type SheetPartProps, type SheetProps, SheetTitle, SheetTrigger, ShieldIcon, ShowMore, type ShowMoreProps, SlidersIcon, SmartphoneIcon, SparklesIcon, Spinner, type SpinnerProps, StatusBadge, type StatusBadgeProps, type StatusBadgeSize, type StatusTone, StepBackIcon, StepForwardIcon, StopIcon, Switch, type SwitchProps, SyntaxLine, type SyntaxLineProps, TabBadge, type TabBadgeProps, Tabs, TabsContent, type TabsContentProps, TabsList, type TabsListProps, type TabsProps, TabsTrigger, type TabsTriggerProps, TaskIcon, TerminalIcon, Textarea, type TextareaProps, type Tint, ToolPathLink, type ToolPathLinkProps, ToolResultImage, type ToolResultImageProps, TrashIcon, UndoIcon, UserIcon, UsersIcon, WorkflowIcon, WrenchIcon, ageLabel, agentInitials, ansiSpans, authorImageOpener, boundedFileSource, buildReviewPrompt, collapseLines, fileAssetPath, fileKind, filePreviewMode, fileTree, filterFiles, fontOf, hashlineBody, impactLight, isFileLayout, modifiedLabel, newestFiles, readMediaBytes, resultTextLines, selectionTick, sheetsYielded, sizeLabel, sortFiles, tintFor, toolTone, useMessageItem, useSyntaxLines, yieldSheets };
|
|
52
|
+
export { ActivityIcon, AgentAvatar, type AgentState, AlertIcon, type AnnotationMark, AnnotationSurface, type AnnotationSurfaceProps, type AnsiSpan, ArrowRightIcon, ArrowUpRightIcon, AudioLinesIcon, Back10Icon, Badge, type BadgeProps, type BadgeSize, type BadgeTone, type BoundedFileSource, BoxIcon, BranchIcon, Button, type ButtonProps, type ButtonSize, type ButtonVariant, CalendarIcon, CheckIcon, ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon, ChevronUpIcon, CloseIcon, CodeBlock, type CodeBlockProps, ComputerRow, type ComputerRowProps, type ComputerStatus, CopyButton, type CopyButtonProps, CopyIcon, CountBadge, type CountBadgeProps, CtaCard, type CtaCardProps, Dialog, DialogBody, DialogClose, DialogContent, type DialogContentProps, DialogDescription, DialogFooter, type DialogFooterProps, type DialogFooterVariant, DialogHeader, type DialogHeaderProps, type DialogPartProps, type DialogProps, DialogTitle, DialogTrigger, type DialogWidth, Dot, type DotProps, type DotSize, type DotTone, DownloadIcon, DropdownMenu, DropdownMenuCheckboxItem, type DropdownMenuCheckboxItemProps, DropdownMenuContent, type DropdownMenuContentProps, DropdownMenuGroup, DropdownMenuItem, type DropdownMenuItemProps, type DropdownMenuItemVariant, DropdownMenuLabel, type DropdownMenuPartProps, type DropdownMenuProps, DropdownMenuRadioGroup, type DropdownMenuRadioGroupProps, DropdownMenuRadioItem, type DropdownMenuRadioItemProps, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuTrigger, EditIcon, EmptyState, type EmptyStateAction, type EmptyStateProps, type EmptyStateSize, EraserIcon, type FieldSize, type FieldVariant, type FileBrowserControls, type FileFilters, FileIcon, type FileItem, type FileKind, type FileLayout, type FileLinkHandler, FileList, type FileListProps, type FileModified, FilePathStrip, FilePreview, type FilePreviewProps, type FileRangeLoader, type FileSort, type FileSortDirection, type FileStatus, type FileStatusFilter, type FileTextPreview, type FileTreeRow, FileViewer, FileViewerHeader, type FileViewerProps, FitIcon, FolderIcon, ForkIcon, Forward10Icon, GearIcon, GlobeIcon, HandIcon, HashlineLines, type HashlineLinesProps, HighlighterIcon, HomeIcon, HostFilter, type HostFilterProps, HostTag, IconColorContext, type IconName, type IconProps, IdCardIcon, ImageIcon, InfoStrip, Input, type InputProps, KebabIcon, Label, type LabelProps, LanguagesIcon, LightbulbIcon, LinkText, type LinkTextProps, List, type ListProps, ListRow, type ListRowProps, LiveDuration, type LiveDurationProps, type LiveDurationReading, LoadingState, type LoadingStateProps, type LoadingStateSize, LockIcon, Markdown, type MarkdownImageLoader, type MarkdownProps, MenuIcon, MessageIcon, MessageItem, MessageItemBody, MessageItemGroup, type MessageItemGroupProps, MessageItemHeader, type MessageItemHeaderProps, type MessageItemPartProps, type MessageItemProps, type MessageItemState, MessageItemStatus, type MessageItemStatusProps, MicIcon, MinusIcon, MonitorIcon, NoteIcon, PaletteIcon, Panel, PanelBody, PanelHeader, type PanelPartProps, PauseIcon, PinIcon, PlayCircleIcon, PlayIcon, PlusIcon, PoNativeProvider, type PoNativeProviderProps, PointerIcon, type PresentedLine, RailItem, type RailItemProps, RedoIcon, ReferenceChip, type ReferenceRenderer, RefreshIcon, type ReviewComment, STATUS_EDGE, STATUS_GLYPH, STATUS_LABEL, SearchIcon, SectionLabel, SeekBar, type SeekBarProps, SegmentedControl, type SegmentedControlOption, type SegmentedControlProps, Select, type SelectOption, type SelectProps, SendIcon, ServerIcon, Sheet, SheetBody, SheetClose, SheetContent, type SheetContentProps, SheetDescription, SheetFooter, SheetHeader, type SheetHeaderProps, SheetList, type SheetListProps, type SheetPartProps, type SheetProps, SheetTitle, SheetTrigger, ShieldIcon, ShowMore, type ShowMoreProps, SlidersIcon, SmartphoneIcon, SparklesIcon, Spinner, type SpinnerProps, StatusBadge, type StatusBadgeProps, type StatusBadgeSize, type StatusTone, StepBackIcon, StepForwardIcon, StopIcon, Switch, type SwitchProps, SyntaxLine, type SyntaxLineProps, TabBadge, type TabBadgeProps, Tabs, TabsContent, type TabsContentProps, TabsList, type TabsListProps, type TabsProps, TabsTrigger, type TabsTriggerProps, TaskIcon, TerminalIcon, Textarea, type TextareaProps, type Tint, ToolPathLink, type ToolPathLinkProps, ToolResultImage, type ToolResultImageProps, TrashIcon, UndoIcon, UserIcon, UsersIcon, WorkflowIcon, WrenchIcon, ageLabel, agentInitials, ansiSpans, authorImageOpener, boundedFileSource, buildReviewPrompt, collapseLines, fileAssetPath, fileKind, filePreviewMode, fileTree, filterFiles, fontOf, hashlineBody, impactLight, isFileLayout, modifiedLabel, newestFiles, readMediaBytes, resultTextLines, selectionTick, sheetsYielded, sizeLabel, sortFiles, tintFor, toolTone, useMessageItem, useSyntaxLines, yieldSheets };
|
package/dist/index.mjs
CHANGED
|
@@ -6,7 +6,7 @@ import { AnnotationSurface } from "./components/AnnotationSurface.mjs";
|
|
|
6
6
|
import { Badge } from "./components/Badge.mjs";
|
|
7
7
|
import { Spinner } from "./components/Spinner.mjs";
|
|
8
8
|
import { Button } from "./components/Button.mjs";
|
|
9
|
-
import { ActivityIcon, AlertIcon, ArrowRightIcon, ArrowUpRightIcon, AudioLinesIcon, Back10Icon, BoxIcon, BranchIcon, CalendarIcon, CheckIcon, ChevronDownIcon, ChevronRightIcon, ChevronUpIcon, CloseIcon, CopyIcon, DownloadIcon, EditIcon, EraserIcon, FileIcon, FitIcon, FolderIcon, ForkIcon, Forward10Icon, GearIcon, GlobeIcon, HandIcon, HighlighterIcon, HomeIcon, IdCardIcon, ImageIcon, KebabIcon, LanguagesIcon, LightbulbIcon, LockIcon, MenuIcon, MessageIcon, MicIcon, MinusIcon, MonitorIcon, PaletteIcon, PauseIcon, PinIcon, PlayCircleIcon, PlayIcon, PlusIcon, RedoIcon, RefreshIcon, SearchIcon, SendIcon, ServerIcon, ShieldIcon, SlidersIcon, SmartphoneIcon, SparklesIcon, StepBackIcon, StepForwardIcon, StopIcon, TaskIcon, TerminalIcon, TrashIcon, UndoIcon, UserIcon, UsersIcon, WorkflowIcon, WrenchIcon } from "./icons/icons.mjs";
|
|
9
|
+
import { ActivityIcon, AlertIcon, ArrowRightIcon, ArrowUpRightIcon, AudioLinesIcon, Back10Icon, BoxIcon, BranchIcon, CalendarIcon, CheckIcon, ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon, ChevronUpIcon, CloseIcon, CopyIcon, DownloadIcon, EditIcon, EraserIcon, FileIcon, FitIcon, FolderIcon, ForkIcon, Forward10Icon, GearIcon, GlobeIcon, HandIcon, HighlighterIcon, HomeIcon, IdCardIcon, ImageIcon, KebabIcon, LanguagesIcon, LightbulbIcon, LockIcon, MenuIcon, MessageIcon, MicIcon, MinusIcon, MonitorIcon, NoteIcon, PaletteIcon, PauseIcon, PinIcon, PlayCircleIcon, PlayIcon, PlusIcon, PointerIcon, RedoIcon, RefreshIcon, SearchIcon, SendIcon, ServerIcon, ShieldIcon, SlidersIcon, SmartphoneIcon, SparklesIcon, StepBackIcon, StepForwardIcon, StopIcon, TaskIcon, TerminalIcon, TrashIcon, UndoIcon, UserIcon, UsersIcon, WorkflowIcon, WrenchIcon } from "./icons/icons.mjs";
|
|
10
10
|
import { CopyButton } from "./components/CopyButton.mjs";
|
|
11
11
|
import { ShowMore } from "./components/ShowMore.mjs";
|
|
12
12
|
import { CodeBlock } from "./components/CodeBlock.mjs";
|
|
@@ -49,4 +49,4 @@ import { InfoStrip } from "./components/InfoStrip.mjs";
|
|
|
49
49
|
import { ageLabel, ansiSpans, boundedFileSource, buildReviewPrompt, collapseLines, fileAssetPath, fileKind, filePreviewMode, fileTree, filterFiles, hashlineBody, isFileLayout, modifiedLabel, newestFiles, readMediaBytes, resultTextLines, sizeLabel, sortFiles } from "@agimon-ai/po-web-components/text";
|
|
50
50
|
import { IconColorContext, LiveDuration, PoNativeProvider, sheetsYielded, yieldSheets } from "@agimon-ai/po-native-components/shell";
|
|
51
51
|
|
|
52
|
-
export { ActivityIcon, AgentAvatar, AlertIcon, AnnotationSurface, ArrowRightIcon, ArrowUpRightIcon, AudioLinesIcon, Back10Icon, Badge, BoxIcon, BranchIcon, Button, CalendarIcon, CheckIcon, ChevronDownIcon, ChevronRightIcon, ChevronUpIcon, CloseIcon, CodeBlock, ComputerRow, CopyButton, CopyIcon, CountBadge, CtaCard, Dialog, DialogBody, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogTitle, DialogTrigger, Dot, DownloadIcon, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuTrigger, EditIcon, EmptyState, EraserIcon, FileIcon, FileList, FilePathStrip, FilePreview, FileViewer, FileViewerHeader, FitIcon, FolderIcon, ForkIcon, Forward10Icon, GearIcon, GlobeIcon, HandIcon, HashlineLines, HighlighterIcon, HomeIcon, HostFilter, HostTag, IconColorContext, IdCardIcon, ImageIcon, InfoStrip, Input, KebabIcon, Label, LanguagesIcon, LightbulbIcon, LinkText, List, ListRow, LiveDuration, LoadingState, LockIcon, Markdown, MenuIcon, MessageIcon, MessageItem, MessageItemBody, MessageItemGroup, MessageItemHeader, MessageItemStatus, MicIcon, MinusIcon, MonitorIcon, PaletteIcon, Panel, PanelBody, PanelHeader, PauseIcon, PinIcon, PlayCircleIcon, PlayIcon, PlusIcon, PoNativeProvider, RailItem, RedoIcon, ReferenceChip, RefreshIcon, STATUS_EDGE, STATUS_GLYPH, STATUS_LABEL, SearchIcon, SectionLabel, SeekBar, SegmentedControl, Select, SendIcon, ServerIcon, Sheet, SheetBody, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetList, SheetTitle, SheetTrigger, ShieldIcon, ShowMore, SlidersIcon, SmartphoneIcon, SparklesIcon, Spinner, StatusBadge, StepBackIcon, StepForwardIcon, StopIcon, Switch, SyntaxLine, TabBadge, Tabs, TabsContent, TabsList, TabsTrigger, TaskIcon, TerminalIcon, Textarea, ToolPathLink, ToolResultImage, TrashIcon, UndoIcon, UserIcon, UsersIcon, WorkflowIcon, WrenchIcon, ageLabel, agentInitials, ansiSpans, authorImageOpener, boundedFileSource, buildReviewPrompt, collapseLines, fileAssetPath, fileKind, filePreviewMode, fileTree, filterFiles, fontOf, hashlineBody, impactLight, isFileLayout, modifiedLabel, newestFiles, readMediaBytes, resultTextLines, selectionTick, sheetsYielded, sizeLabel, sortFiles, tintFor, toolTone, useMessageItem, useSyntaxLines, yieldSheets };
|
|
52
|
+
export { ActivityIcon, AgentAvatar, AlertIcon, AnnotationSurface, ArrowRightIcon, ArrowUpRightIcon, AudioLinesIcon, Back10Icon, Badge, BoxIcon, BranchIcon, Button, CalendarIcon, CheckIcon, ChevronDownIcon, ChevronLeftIcon, ChevronRightIcon, ChevronUpIcon, CloseIcon, CodeBlock, ComputerRow, CopyButton, CopyIcon, CountBadge, CtaCard, Dialog, DialogBody, DialogClose, DialogContent, DialogDescription, DialogFooter, DialogHeader, DialogTitle, DialogTrigger, Dot, DownloadIcon, DropdownMenu, DropdownMenuCheckboxItem, DropdownMenuContent, DropdownMenuGroup, DropdownMenuItem, DropdownMenuLabel, DropdownMenuRadioGroup, DropdownMenuRadioItem, DropdownMenuSeparator, DropdownMenuShortcut, DropdownMenuTrigger, EditIcon, EmptyState, EraserIcon, FileIcon, FileList, FilePathStrip, FilePreview, FileViewer, FileViewerHeader, FitIcon, FolderIcon, ForkIcon, Forward10Icon, GearIcon, GlobeIcon, HandIcon, HashlineLines, HighlighterIcon, HomeIcon, HostFilter, HostTag, IconColorContext, IdCardIcon, ImageIcon, InfoStrip, Input, KebabIcon, Label, LanguagesIcon, LightbulbIcon, LinkText, List, ListRow, LiveDuration, LoadingState, LockIcon, Markdown, MenuIcon, MessageIcon, MessageItem, MessageItemBody, MessageItemGroup, MessageItemHeader, MessageItemStatus, MicIcon, MinusIcon, MonitorIcon, NoteIcon, PaletteIcon, Panel, PanelBody, PanelHeader, PauseIcon, PinIcon, PlayCircleIcon, PlayIcon, PlusIcon, PoNativeProvider, PointerIcon, RailItem, RedoIcon, ReferenceChip, RefreshIcon, STATUS_EDGE, STATUS_GLYPH, STATUS_LABEL, SearchIcon, SectionLabel, SeekBar, SegmentedControl, Select, SendIcon, ServerIcon, Sheet, SheetBody, SheetClose, SheetContent, SheetDescription, SheetFooter, SheetHeader, SheetList, SheetTitle, SheetTrigger, ShieldIcon, ShowMore, SlidersIcon, SmartphoneIcon, SparklesIcon, Spinner, StatusBadge, StepBackIcon, StepForwardIcon, StopIcon, Switch, SyntaxLine, TabBadge, Tabs, TabsContent, TabsList, TabsTrigger, TaskIcon, TerminalIcon, Textarea, ToolPathLink, ToolResultImage, TrashIcon, UndoIcon, UserIcon, UsersIcon, WorkflowIcon, WrenchIcon, ageLabel, agentInitials, ansiSpans, authorImageOpener, boundedFileSource, buildReviewPrompt, collapseLines, fileAssetPath, fileKind, filePreviewMode, fileTree, filterFiles, fontOf, hashlineBody, impactLight, isFileLayout, modifiedLabel, newestFiles, readMediaBytes, resultTextLines, selectionTick, sheetsYielded, sizeLabel, sortFiles, tintFor, toolTone, useMessageItem, useSyntaxLines, yieldSheets };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":1,"platformRequirements":{},"sourceFiles":["LICENSE","README.md","llms.txt","locales/vi.json","locales/zh-CN.json","package.json","src/components/AgentAvatar.stories.tsx","src/components/AgentAvatar.tsx","src/components/AnnotationSurface.tsx","src/components/Badge.stories.tsx","src/components/Badge.tsx","src/components/Button.stories.tsx","src/components/Button.tsx","src/components/CodeBlock.stories.tsx","src/components/CodeBlock.tsx","src/components/ComputerRow.stories.tsx","src/components/ComputerRow.tsx","src/components/CopyButton.tsx","src/components/CountBadge.stories.tsx","src/components/CountBadge.tsx","src/components/CtaCard.stories.tsx","src/components/CtaCard.tsx","src/components/Dialog.stories.tsx","src/components/Dialog.tsx","src/components/Dot.stories.tsx","src/components/Dot.tsx","src/components/DropdownMenu.stories.tsx","src/components/DropdownMenu.tsx","src/components/EmptyState.stories.tsx","src/components/EmptyState.tsx","src/components/FileList.stories.tsx","src/components/FileList.tsx","src/components/FilePreview.stories.tsx","src/components/FilePreview.tsx","src/components/FileViewer.stories.tsx","src/components/FileViewer.tsx","src/components/HashlineLines.tsx","src/components/HostFilter.stories.tsx","src/components/HostFilter.tsx","src/components/HostTag.stories.tsx","src/components/HostTag.tsx","src/components/InfoStrip.stories.tsx","src/components/InfoStrip.tsx","src/components/InlineReadingDesign.stories.tsx","src/components/Input.stories.tsx","src/components/Input.tsx","src/components/Label.stories.tsx","src/components/Label.tsx","src/components/LinkText.tsx","src/components/List.stories.tsx","src/components/List.tsx","src/components/LiveDuration.tsx","src/components/LoadingState.stories.tsx","src/components/LoadingState.tsx","src/components/Markdown.stories.tsx","src/components/Markdown.tsx","src/components/MessageItem.stories.tsx","src/components/MessageItem.tsx","src/components/NativeShellState.tsx","src/components/Panel.stories.tsx","src/components/Panel.tsx","src/components/PoNativeProvider.stories.tsx","src/components/PoNativeProvider.tsx","src/components/RailItem.stories.tsx","src/components/RailItem.tsx","src/components/ReferenceChip.stories.tsx","src/components/ReferenceChip.tsx","src/components/SectionLabel.stories.tsx","src/components/SectionLabel.tsx","src/components/SeekBar.stories.tsx","src/components/SeekBar.tsx","src/components/SegmentedControl.stories.tsx","src/components/SegmentedControl.tsx","src/components/Select.stories.tsx","src/components/Select.tsx","src/components/Sheet.stories.tsx","src/components/Sheet.tsx","src/components/SheetFrame.tsx","src/components/SheetList.tsx","src/components/ShowMore.tsx","src/components/Spinner.stories.tsx","src/components/Spinner.tsx","src/components/StatusBadge.stories.tsx","src/components/StatusBadge.tsx","src/components/Switch.stories.tsx","src/components/Switch.tsx","src/components/SyntaxLine.tsx","src/components/Tabs.stories.tsx","src/components/Tabs.tsx","src/components/Textarea.stories.tsx","src/components/Textarea.tsx","src/components/ToolPathLink.tsx","src/components/ToolResultImage.tsx","src/exports/index.ts","src/exports/shell.ts","src/icons/IconColorContext.ts","src/icons/iconGlyphs.ts","src/icons/icons.stories.tsx","src/icons/icons.tsx","src/lib/fileKindLabel.ts","src/lib/fonts.ts","src/lib/haptics.ts","src/lib/insideSheet.ts","src/lib/markdown.ts","src/lib/reading.ts","src/lib/tone.ts","src/lib/useControllable.ts","src/lib/useReadingPage.ts","src/lib/wrapText.tsx","src/unistyles.ts","tsdown.config.ts"],"sourceRevision":"
|
|
1
|
+
{"version":1,"platformRequirements":{},"sourceFiles":["LICENSE","README.md","llms.txt","locales/vi.json","locales/zh-CN.json","package.json","src/components/AgentAvatar.stories.tsx","src/components/AgentAvatar.tsx","src/components/AnnotationSurface.tsx","src/components/Badge.stories.tsx","src/components/Badge.tsx","src/components/Button.stories.tsx","src/components/Button.tsx","src/components/CodeBlock.stories.tsx","src/components/CodeBlock.tsx","src/components/ComputerRow.stories.tsx","src/components/ComputerRow.tsx","src/components/CopyButton.tsx","src/components/CountBadge.stories.tsx","src/components/CountBadge.tsx","src/components/CtaCard.stories.tsx","src/components/CtaCard.tsx","src/components/Dialog.stories.tsx","src/components/Dialog.tsx","src/components/Dot.stories.tsx","src/components/Dot.tsx","src/components/DropdownMenu.stories.tsx","src/components/DropdownMenu.tsx","src/components/EmptyState.stories.tsx","src/components/EmptyState.tsx","src/components/FileList.stories.tsx","src/components/FileList.tsx","src/components/FilePreview.stories.tsx","src/components/FilePreview.tsx","src/components/FileViewer.stories.tsx","src/components/FileViewer.tsx","src/components/HashlineLines.tsx","src/components/HostFilter.stories.tsx","src/components/HostFilter.tsx","src/components/HostTag.stories.tsx","src/components/HostTag.tsx","src/components/InfoStrip.stories.tsx","src/components/InfoStrip.tsx","src/components/InlineReadingDesign.stories.tsx","src/components/Input.stories.tsx","src/components/Input.tsx","src/components/Label.stories.tsx","src/components/Label.tsx","src/components/LinkText.tsx","src/components/List.stories.tsx","src/components/List.tsx","src/components/LiveDuration.tsx","src/components/LoadingState.stories.tsx","src/components/LoadingState.tsx","src/components/Markdown.stories.tsx","src/components/Markdown.tsx","src/components/MessageItem.stories.tsx","src/components/MessageItem.tsx","src/components/NativeShellState.tsx","src/components/Panel.stories.tsx","src/components/Panel.tsx","src/components/PoNativeProvider.stories.tsx","src/components/PoNativeProvider.tsx","src/components/RailItem.stories.tsx","src/components/RailItem.tsx","src/components/ReferenceChip.stories.tsx","src/components/ReferenceChip.tsx","src/components/SectionLabel.stories.tsx","src/components/SectionLabel.tsx","src/components/SeekBar.stories.tsx","src/components/SeekBar.tsx","src/components/SegmentedControl.stories.tsx","src/components/SegmentedControl.tsx","src/components/Select.stories.tsx","src/components/Select.tsx","src/components/Sheet.stories.tsx","src/components/Sheet.tsx","src/components/SheetFrame.tsx","src/components/SheetList.tsx","src/components/ShowMore.tsx","src/components/Spinner.stories.tsx","src/components/Spinner.tsx","src/components/StatusBadge.stories.tsx","src/components/StatusBadge.tsx","src/components/Switch.stories.tsx","src/components/Switch.tsx","src/components/SyntaxLine.tsx","src/components/Tabs.stories.tsx","src/components/Tabs.tsx","src/components/Textarea.stories.tsx","src/components/Textarea.tsx","src/components/ToolPathLink.tsx","src/components/ToolResultImage.tsx","src/exports/index.ts","src/exports/shell.ts","src/icons/IconColorContext.ts","src/icons/iconGlyphs.ts","src/icons/icons.stories.tsx","src/icons/icons.tsx","src/lib/fileKindLabel.ts","src/lib/fonts.ts","src/lib/haptics.ts","src/lib/insideSheet.ts","src/lib/markdown.ts","src/lib/reading.ts","src/lib/tone.ts","src/lib/useControllable.ts","src/lib/useReadingPage.ts","src/lib/wrapText.tsx","src/unistyles.ts","tsdown.config.ts"],"sourceRevision":"2a12e824bb920e85940dc1ef9b4787e4","manifestRevision":"c4d0f469621ef1e76a75de20bdb61ff0","outputFiles":["LICENSE","README.md","dist/components/AgentAvatar.mjs","dist/components/AnnotationSurface.mjs","dist/components/Badge.mjs","dist/components/Button.mjs","dist/components/CodeBlock.mjs","dist/components/ComputerRow.mjs","dist/components/CopyButton.mjs","dist/components/CountBadge.mjs","dist/components/CtaCard.mjs","dist/components/Dialog.mjs","dist/components/Dot.mjs","dist/components/DropdownMenu.mjs","dist/components/EmptyState.mjs","dist/components/FileList.mjs","dist/components/FilePreview.mjs","dist/components/FileViewer.mjs","dist/components/HashlineLines.mjs","dist/components/HostFilter.mjs","dist/components/HostTag.mjs","dist/components/InfoStrip.mjs","dist/components/Input.mjs","dist/components/Label.mjs","dist/components/LinkText.mjs","dist/components/List.mjs","dist/components/LiveDuration.mjs","dist/components/LoadingState.mjs","dist/components/Markdown.mjs","dist/components/MessageItem.mjs","dist/components/NativeShellState.mjs","dist/components/Panel.mjs","dist/components/PoNativeProvider.mjs","dist/components/RailItem.mjs","dist/components/ReferenceChip.mjs","dist/components/SectionLabel.mjs","dist/components/SeekBar.mjs","dist/components/SegmentedControl.mjs","dist/components/Select.mjs","dist/components/Sheet.mjs","dist/components/SheetFrame.mjs","dist/components/SheetList.mjs","dist/components/ShowMore.mjs","dist/components/Spinner.mjs","dist/components/StatusBadge.mjs","dist/components/Switch.mjs","dist/components/SyntaxLine.mjs","dist/components/Tabs.mjs","dist/components/Textarea.mjs","dist/components/ToolPathLink.mjs","dist/components/ToolResultImage.mjs","dist/icons/IconColorContext.mjs","dist/icons/iconGlyphs.mjs","dist/icons/icons.mjs","dist/index.mjs","dist/lib/fileKindLabel.mjs","dist/lib/fonts.mjs","dist/lib/haptics.mjs","dist/lib/insideSheet.mjs","dist/lib/markdown.mjs","dist/lib/reading.mjs","dist/lib/tone.mjs","dist/lib/useControllable.mjs","dist/lib/useReadingPage.mjs","dist/lib/wrapText.mjs","dist/shell.mjs","llms.txt","locales/vi.json","locales/zh-CN.json"],"outputRevision":"5bb9b9ed1c80a70faaaf83f652a9c0f2"}
|
package/locales/vi.json
CHANGED
|
@@ -23,7 +23,6 @@
|
|
|
23
23
|
"nativeComponents.fileKind.other": "Khác",
|
|
24
24
|
"nativeComponents.fileList.allTypes": "Mọi loại",
|
|
25
25
|
"nativeComponents.fileList.ascending": "Tăng dần",
|
|
26
|
-
"nativeComponents.fileList.bytes": "{size} byte",
|
|
27
26
|
"nativeComponents.fileList.clearFilters": "Xóa bộ lọc",
|
|
28
27
|
"nativeComponents.fileList.close": "Đóng",
|
|
29
28
|
"nativeComponents.fileList.collapse": "Thu gọn {path}",
|
package/locales/zh-CN.json
CHANGED
|
@@ -23,7 +23,6 @@
|
|
|
23
23
|
"nativeComponents.fileKind.other": "其他",
|
|
24
24
|
"nativeComponents.fileList.allTypes": "所有类型",
|
|
25
25
|
"nativeComponents.fileList.ascending": "升序",
|
|
26
|
-
"nativeComponents.fileList.bytes": "{size} 字节",
|
|
27
26
|
"nativeComponents.fileList.clearFilters": "清除筛选",
|
|
28
27
|
"nativeComponents.fileList.close": "关闭",
|
|
29
28
|
"nativeComponents.fileList.collapse": "折叠 {path}",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@agimon-ai/po-native-components",
|
|
3
|
-
"version": "0.0.0-alpha.
|
|
3
|
+
"version": "0.0.0-alpha.219",
|
|
4
4
|
"description": "Shared React Native components for Po and its native plugins: the web component library's look and API on native parts, tuned to the Po palette.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"ai",
|
|
@@ -52,12 +52,12 @@
|
|
|
52
52
|
"access": "public"
|
|
53
53
|
},
|
|
54
54
|
"dependencies": {
|
|
55
|
-
"@agimon-ai/po-web-components": "0.0.0-alpha.
|
|
55
|
+
"@agimon-ai/po-web-components": "0.0.0-alpha.219"
|
|
56
56
|
},
|
|
57
57
|
"devDependencies": {
|
|
58
|
-
"@agimon-ai/po-build": "0.0.0-alpha.
|
|
59
|
-
"@agimon-ai/po-core": "0.0.0-alpha.
|
|
60
|
-
"@agimon-ai/vibe-lint-plugin-po-web": "0.0.0-alpha.
|
|
58
|
+
"@agimon-ai/po-build": "0.0.0-alpha.219",
|
|
59
|
+
"@agimon-ai/po-core": "0.0.0-alpha.219",
|
|
60
|
+
"@agimon-ai/vibe-lint-plugin-po-web": "0.0.0-alpha.219",
|
|
61
61
|
"@babel/core": "7.29.7",
|
|
62
62
|
"@expo/vector-icons": "15.1.1",
|
|
63
63
|
"@fontsource-variable/ibm-plex-sans": "5.3.0",
|
|
@@ -88,7 +88,7 @@
|
|
|
88
88
|
"vitest": "5.0.4"
|
|
89
89
|
},
|
|
90
90
|
"peerDependencies": {
|
|
91
|
-
"@agimon-ai/po-core": "0.0.0-alpha.
|
|
91
|
+
"@agimon-ai/po-core": "0.0.0-alpha.219",
|
|
92
92
|
"@expo/vector-icons": "^15.0.0",
|
|
93
93
|
"@gorhom/bottom-sheet": "^5.2.0",
|
|
94
94
|
"@react-native-segmented-control/segmented-control": "^2.5.0",
|