@indra-inter/neobrutalism-components 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (154) hide show
  1. package/README.md +1330 -0
  2. package/dist/module/assets/avatar-profile.png +0 -0
  3. package/dist/module/components/accordion/accordion.js +203 -0
  4. package/dist/module/components/accordion/accordion.js.map +1 -0
  5. package/dist/module/components/app-bar/app-bar.js +140 -0
  6. package/dist/module/components/app-bar/app-bar.js.map +1 -0
  7. package/dist/module/components/avatar/avatar.js +184 -0
  8. package/dist/module/components/avatar/avatar.js.map +1 -0
  9. package/dist/module/components/badge/badge.js +133 -0
  10. package/dist/module/components/badge/badge.js.map +1 -0
  11. package/dist/module/components/bottom-navigation/bottom-navigation.js +166 -0
  12. package/dist/module/components/bottom-navigation/bottom-navigation.js.map +1 -0
  13. package/dist/module/components/bottom-sheet/bottom-sheet.js +285 -0
  14. package/dist/module/components/bottom-sheet/bottom-sheet.js.map +1 -0
  15. package/dist/module/components/button/button.js +253 -0
  16. package/dist/module/components/button/button.js.map +1 -0
  17. package/dist/module/components/calendar/calendar.js +458 -0
  18. package/dist/module/components/calendar/calendar.js.map +1 -0
  19. package/dist/module/components/call-item/call-item.js +128 -0
  20. package/dist/module/components/call-item/call-item.js.map +1 -0
  21. package/dist/module/components/card/card.js +189 -0
  22. package/dist/module/components/card/card.js.map +1 -0
  23. package/dist/module/components/chat-list-item/chat-list-item.js +212 -0
  24. package/dist/module/components/chat-list-item/chat-list-item.js.map +1 -0
  25. package/dist/module/components/checkbox/checkbox.js +141 -0
  26. package/dist/module/components/checkbox/checkbox.js.map +1 -0
  27. package/dist/module/components/dialog/dialog.js +342 -0
  28. package/dist/module/components/dialog/dialog.js.map +1 -0
  29. package/dist/module/components/divider/divider.js +41 -0
  30. package/dist/module/components/divider/divider.js.map +1 -0
  31. package/dist/module/components/dropdown/dropdown-menu.js +214 -0
  32. package/dist/module/components/dropdown/dropdown-menu.js.map +1 -0
  33. package/dist/module/components/dropdown/dropdown.js +616 -0
  34. package/dist/module/components/dropdown/dropdown.js.map +1 -0
  35. package/dist/module/components/dropdown/types.js +4 -0
  36. package/dist/module/components/dropdown/types.js.map +1 -0
  37. package/dist/module/components/icon-button/icon-button.js +140 -0
  38. package/dist/module/components/icon-button/icon-button.js.map +1 -0
  39. package/dist/module/components/input/currency-input.js +60 -0
  40. package/dist/module/components/input/currency-input.js.map +1 -0
  41. package/dist/module/components/input/input.js +281 -0
  42. package/dist/module/components/input/input.js.map +1 -0
  43. package/dist/module/components/input/otp-input.js +196 -0
  44. package/dist/module/components/input/otp-input.js.map +1 -0
  45. package/dist/module/components/input/password-input.js +74 -0
  46. package/dist/module/components/input/password-input.js.map +1 -0
  47. package/dist/module/components/input/phone-input.js +68 -0
  48. package/dist/module/components/input/phone-input.js.map +1 -0
  49. package/dist/module/components/input/url-input.js +43 -0
  50. package/dist/module/components/input/url-input.js.map +1 -0
  51. package/dist/module/components/list-item/list-item.js +148 -0
  52. package/dist/module/components/list-item/list-item.js.map +1 -0
  53. package/dist/module/components/pin-code-field/pin-code-field.js +164 -0
  54. package/dist/module/components/pin-code-field/pin-code-field.js.map +1 -0
  55. package/dist/module/components/progress/progress.js +261 -0
  56. package/dist/module/components/progress/progress.js.map +1 -0
  57. package/dist/module/components/radio/radio.js +135 -0
  58. package/dist/module/components/radio/radio.js.map +1 -0
  59. package/dist/module/components/skeleton/skeleton.js +328 -0
  60. package/dist/module/components/skeleton/skeleton.js.map +1 -0
  61. package/dist/module/components/switch/switch.js +170 -0
  62. package/dist/module/components/switch/switch.js.map +1 -0
  63. package/dist/module/components/tabs/tabs.js +197 -0
  64. package/dist/module/components/tabs/tabs.js.map +1 -0
  65. package/dist/module/components/toast/toast-provider.js +117 -0
  66. package/dist/module/components/toast/toast-provider.js.map +1 -0
  67. package/dist/module/components/toast/toast.js +154 -0
  68. package/dist/module/components/toast/toast.js.map +1 -0
  69. package/dist/module/index.js +38 -0
  70. package/dist/module/index.js.map +1 -0
  71. package/dist/module/package.json +1 -0
  72. package/dist/module/theme/design-tokens.generated.js +379 -0
  73. package/dist/module/theme/design-tokens.generated.js.map +1 -0
  74. package/dist/module/theme/theme-provider.js +20 -0
  75. package/dist/module/theme/theme-provider.js.map +1 -0
  76. package/dist/module/theme/theme.js +56 -0
  77. package/dist/module/theme/theme.js.map +1 -0
  78. package/dist/typescript/components/accordion/accordion.d.ts +40 -0
  79. package/dist/typescript/components/accordion/accordion.d.ts.map +1 -0
  80. package/dist/typescript/components/app-bar/app-bar.d.ts +34 -0
  81. package/dist/typescript/components/app-bar/app-bar.d.ts.map +1 -0
  82. package/dist/typescript/components/avatar/avatar.d.ts +17 -0
  83. package/dist/typescript/components/avatar/avatar.d.ts.map +1 -0
  84. package/dist/typescript/components/badge/badge.d.ts +20 -0
  85. package/dist/typescript/components/badge/badge.d.ts.map +1 -0
  86. package/dist/typescript/components/bottom-navigation/bottom-navigation.d.ts +28 -0
  87. package/dist/typescript/components/bottom-navigation/bottom-navigation.d.ts.map +1 -0
  88. package/dist/typescript/components/bottom-sheet/bottom-sheet.d.ts +38 -0
  89. package/dist/typescript/components/bottom-sheet/bottom-sheet.d.ts.map +1 -0
  90. package/dist/typescript/components/button/button.d.ts +21 -0
  91. package/dist/typescript/components/button/button.d.ts.map +1 -0
  92. package/dist/typescript/components/calendar/calendar.d.ts +41 -0
  93. package/dist/typescript/components/calendar/calendar.d.ts.map +1 -0
  94. package/dist/typescript/components/call-item/call-item.d.ts +21 -0
  95. package/dist/typescript/components/call-item/call-item.d.ts.map +1 -0
  96. package/dist/typescript/components/card/card.d.ts +37 -0
  97. package/dist/typescript/components/card/card.d.ts.map +1 -0
  98. package/dist/typescript/components/chat-list-item/chat-list-item.d.ts +37 -0
  99. package/dist/typescript/components/chat-list-item/chat-list-item.d.ts.map +1 -0
  100. package/dist/typescript/components/checkbox/checkbox.d.ts +15 -0
  101. package/dist/typescript/components/checkbox/checkbox.d.ts.map +1 -0
  102. package/dist/typescript/components/dialog/dialog.d.ts +34 -0
  103. package/dist/typescript/components/dialog/dialog.d.ts.map +1 -0
  104. package/dist/typescript/components/divider/divider.d.ts +10 -0
  105. package/dist/typescript/components/divider/divider.d.ts.map +1 -0
  106. package/dist/typescript/components/dropdown/dropdown-menu.d.ts +27 -0
  107. package/dist/typescript/components/dropdown/dropdown-menu.d.ts.map +1 -0
  108. package/dist/typescript/components/dropdown/dropdown.d.ts +4 -0
  109. package/dist/typescript/components/dropdown/dropdown.d.ts.map +1 -0
  110. package/dist/typescript/components/dropdown/types.d.ts +52 -0
  111. package/dist/typescript/components/dropdown/types.d.ts.map +1 -0
  112. package/dist/typescript/components/icon-button/icon-button.d.ts +20 -0
  113. package/dist/typescript/components/icon-button/icon-button.d.ts.map +1 -0
  114. package/dist/typescript/components/input/currency-input.d.ts +10 -0
  115. package/dist/typescript/components/input/currency-input.d.ts.map +1 -0
  116. package/dist/typescript/components/input/input.d.ts +32 -0
  117. package/dist/typescript/components/input/input.d.ts.map +1 -0
  118. package/dist/typescript/components/input/otp-input.d.ts +23 -0
  119. package/dist/typescript/components/input/otp-input.d.ts.map +1 -0
  120. package/dist/typescript/components/input/password-input.d.ts +14 -0
  121. package/dist/typescript/components/input/password-input.d.ts.map +1 -0
  122. package/dist/typescript/components/input/phone-input.d.ts +13 -0
  123. package/dist/typescript/components/input/phone-input.d.ts.map +1 -0
  124. package/dist/typescript/components/input/url-input.d.ts +10 -0
  125. package/dist/typescript/components/input/url-input.d.ts.map +1 -0
  126. package/dist/typescript/components/list-item/list-item.d.ts +30 -0
  127. package/dist/typescript/components/list-item/list-item.d.ts.map +1 -0
  128. package/dist/typescript/components/pin-code-field/pin-code-field.d.ts +25 -0
  129. package/dist/typescript/components/pin-code-field/pin-code-field.d.ts.map +1 -0
  130. package/dist/typescript/components/progress/progress.d.ts +18 -0
  131. package/dist/typescript/components/progress/progress.d.ts.map +1 -0
  132. package/dist/typescript/components/radio/radio.d.ts +12 -0
  133. package/dist/typescript/components/radio/radio.d.ts.map +1 -0
  134. package/dist/typescript/components/skeleton/skeleton.d.ts +16 -0
  135. package/dist/typescript/components/skeleton/skeleton.d.ts.map +1 -0
  136. package/dist/typescript/components/switch/switch.d.ts +12 -0
  137. package/dist/typescript/components/switch/switch.d.ts.map +1 -0
  138. package/dist/typescript/components/tabs/tabs.d.ts +37 -0
  139. package/dist/typescript/components/tabs/tabs.d.ts.map +1 -0
  140. package/dist/typescript/components/toast/toast-provider.d.ts +22 -0
  141. package/dist/typescript/components/toast/toast-provider.d.ts.map +1 -0
  142. package/dist/typescript/components/toast/toast.d.ts +15 -0
  143. package/dist/typescript/components/toast/toast.d.ts.map +1 -0
  144. package/dist/typescript/index.d.ts +36 -0
  145. package/dist/typescript/index.d.ts.map +1 -0
  146. package/dist/typescript/package.json +1 -0
  147. package/dist/typescript/theme/design-tokens.generated.d.ts +375 -0
  148. package/dist/typescript/theme/design-tokens.generated.d.ts.map +1 -0
  149. package/dist/typescript/theme/theme-provider.d.ts +8 -0
  150. package/dist/typescript/theme/theme-provider.d.ts.map +1 -0
  151. package/dist/typescript/theme/theme.d.ts +52 -0
  152. package/dist/typescript/theme/theme.d.ts.map +1 -0
  153. package/package.json +88 -0
  154. package/tokens.css +132 -0
@@ -0,0 +1,133 @@
1
+ "use strict";
2
+
3
+ import { Platform, StyleSheet, Text, View } from 'react-native';
4
+ import { cssInterop } from 'nativewind';
5
+ import { useTheme } from "../../theme/theme-provider.js";
6
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
7
+ export function Badge({
8
+ children,
9
+ leadingIcon,
10
+ radius,
11
+ rounded = 'rounded',
12
+ shadow = true,
13
+ shadowColor,
14
+ size = 'md',
15
+ style,
16
+ trailingIcon,
17
+ type = 'default',
18
+ ...props
19
+ }) {
20
+ const theme = useTheme();
21
+ const styles = createStyles(theme);
22
+ const resolvedRadius = radius ?? (rounded === 'sharp' ? 0 : 4);
23
+ const resolvedShadowColor = shadowColor ?? theme.shadow.color;
24
+ const usesAndroidHardShadow = Platform.OS === 'android' && shadow;
25
+ const usesIOSNativeShadow = Platform.OS === 'ios' && shadow;
26
+ return /*#__PURE__*/_jsxs(View, {
27
+ style: [styles.container, usesAndroidHardShadow && styles.androidShadowContainer],
28
+ children: [usesAndroidHardShadow && /*#__PURE__*/_jsx(View, {
29
+ pointerEvents: "none",
30
+ style: [styles.androidHardShadow, {
31
+ backgroundColor: resolvedShadowColor,
32
+ borderRadius: resolvedRadius
33
+ }],
34
+ testID: "badge-hard-shadow"
35
+ }), /*#__PURE__*/_jsxs(View, {
36
+ style: [styles.base, styles[type], styles[size], {
37
+ borderRadius: resolvedRadius
38
+ }, usesIOSNativeShadow && styles.iosShadow, usesIOSNativeShadow && {
39
+ shadowColor: resolvedShadowColor
40
+ }, style],
41
+ ...props,
42
+ children: [leadingIcon, /*#__PURE__*/_jsx(Text, {
43
+ style: [styles.label, styles[`${size}Label`], type === 'error' && styles.errorLabel],
44
+ children: children
45
+ }), trailingIcon]
46
+ })]
47
+ });
48
+ }
49
+ cssInterop(Badge, {
50
+ className: 'style'
51
+ });
52
+ function createStyles(theme) {
53
+ return StyleSheet.create({
54
+ container: {
55
+ alignSelf: 'flex-start'
56
+ },
57
+ base: {
58
+ alignItems: 'center',
59
+ borderColor: theme.border.color,
60
+ flexDirection: 'row',
61
+ gap: 4,
62
+ justifyContent: 'center'
63
+ },
64
+ default: {
65
+ backgroundColor: theme.colors.background
66
+ },
67
+ primary: {
68
+ backgroundColor: theme.colors.primary
69
+ },
70
+ info: {
71
+ backgroundColor: theme.colors.info
72
+ },
73
+ error: {
74
+ backgroundColor: theme.colors.destructive
75
+ },
76
+ warning: {
77
+ backgroundColor: theme.colors.warning
78
+ },
79
+ success: {
80
+ backgroundColor: theme.colors.success
81
+ },
82
+ sm: {
83
+ borderRadius: 4,
84
+ borderWidth: 1,
85
+ paddingHorizontal: 3,
86
+ paddingVertical: 0
87
+ },
88
+ md: {
89
+ borderRadius: 4,
90
+ borderWidth: 2,
91
+ paddingHorizontal: 6,
92
+ paddingVertical: 2
93
+ },
94
+ androidShadowContainer: {
95
+ paddingBottom: theme.shadow.xsOffset,
96
+ paddingRight: theme.shadow.xsOffset,
97
+ position: 'relative'
98
+ },
99
+ androidHardShadow: {
100
+ bottom: 0,
101
+ left: theme.shadow.xsOffset,
102
+ position: 'absolute',
103
+ right: 0,
104
+ top: theme.shadow.xsOffset
105
+ },
106
+ iosShadow: {
107
+ marginBottom: theme.shadow.xsOffset,
108
+ marginRight: theme.shadow.xsOffset,
109
+ shadowOffset: {
110
+ width: theme.shadow.xsOffset,
111
+ height: theme.shadow.xsOffset
112
+ },
113
+ shadowOpacity: 1,
114
+ shadowRadius: 0
115
+ },
116
+ label: {
117
+ color: theme.colors.primaryForeground,
118
+ fontWeight: '700'
119
+ },
120
+ smLabel: {
121
+ fontSize: theme.typography.xsSmall,
122
+ lineHeight: theme.typography.xsSmallLineHeight
123
+ },
124
+ mdLabel: {
125
+ fontSize: theme.typography.xs,
126
+ lineHeight: theme.typography.xsLineHeight
127
+ },
128
+ errorLabel: {
129
+ color: theme.colors.destructiveForeground
130
+ }
131
+ });
132
+ }
133
+ //# sourceMappingURL=badge.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["Platform","StyleSheet","Text","View","cssInterop","useTheme","jsx","_jsx","jsxs","_jsxs","Badge","children","leadingIcon","radius","rounded","shadow","shadowColor","size","style","trailingIcon","type","props","theme","styles","createStyles","resolvedRadius","resolvedShadowColor","color","usesAndroidHardShadow","OS","usesIOSNativeShadow","container","androidShadowContainer","pointerEvents","androidHardShadow","backgroundColor","borderRadius","testID","base","iosShadow","label","errorLabel","className","create","alignSelf","alignItems","borderColor","border","flexDirection","gap","justifyContent","default","colors","background","primary","info","error","destructive","warning","success","sm","borderWidth","paddingHorizontal","paddingVertical","md","paddingBottom","xsOffset","paddingRight","position","bottom","left","right","top","marginBottom","marginRight","shadowOffset","width","height","shadowOpacity","shadowRadius","primaryForeground","fontWeight","smLabel","fontSize","typography","xsSmall","lineHeight","xsSmallLineHeight","mdLabel","xs","xsLineHeight","destructiveForeground"],"sourceRoot":"../../../../src","sources":["components/badge/badge.tsx"],"mappings":";;AACA,SACEA,QAAQ,EACRC,UAAU,EACVC,IAAI,EACJC,IAAI,QAIC,cAAc;AACrB,SAASC,UAAU,QAAQ,YAAY;AAGvC,SAASC,QAAQ,QAAQ,+BAA4B;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AA0BtD,OAAO,SAASC,KAAKA,CAAC;EACpBC,QAAQ;EACRC,WAAW;EACXC,MAAM;EACNC,OAAO,GAAG,SAAS;EACnBC,MAAM,GAAG,IAAI;EACbC,WAAW;EACXC,IAAI,GAAG,IAAI;EACXC,KAAK;EACLC,YAAY;EACZC,IAAI,GAAG,SAAS;EAChB,GAAGC;AACO,CAAC,EAAE;EACb,MAAMC,KAAK,GAAGjB,QAAQ,CAAC,CAAC;EACxB,MAAMkB,MAAM,GAAGC,YAAY,CAACF,KAAK,CAAC;EAClC,MAAMG,cAAc,GAAGZ,MAAM,KAAKC,OAAO,KAAK,OAAO,GAAG,CAAC,GAAG,CAAC,CAAC;EAC9D,MAAMY,mBAAmB,GAAGV,WAAW,IAAIM,KAAK,CAACP,MAAM,CAACY,KAAK;EAC7D,MAAMC,qBAAqB,GAAG5B,QAAQ,CAAC6B,EAAE,KAAK,SAAS,IAAId,MAAM;EACjE,MAAMe,mBAAmB,GAAG9B,QAAQ,CAAC6B,EAAE,KAAK,KAAK,IAAId,MAAM;EAE3D,oBACEN,KAAA,CAACN,IAAI;IAACe,KAAK,EAAE,CAACK,MAAM,CAACQ,SAAS,EAAEH,qBAAqB,IAAIL,MAAM,CAACS,sBAAsB,CAAE;IAAArB,QAAA,GACrFiB,qBAAqB,iBACpBrB,IAAA,CAACJ,IAAI;MACH8B,aAAa,EAAC,MAAM;MACpBf,KAAK,EAAE,CACLK,MAAM,CAACW,iBAAiB,EACxB;QAAEC,eAAe,EAAET,m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,KAAK,EAAE;MACLb,KAAK,EAAEL,KAAK,CAAC8B,MAAM,CAAC4B,iBAAiB;MACrCC,UAAU,EAAE;IACd,CAAC;IACDC,OAAO,EAAE;MACPC,QAAQ,EAAE7D,KAAK,CAAC8D,UAAU,CAACC,OAAO;MAClCC,UAAU,EAAEhE,KAAK,CAAC8D,UAAU,CAACG;IAC/B,CAAC;IACDC,OAAO,EAAE;MACPL,QAAQ,EAAE7D,KAAK,CAAC8D,UAAU,CAACK,EAAE;MAC7BH,UAAU,EAAEhE,KAAK,CAAC8D,UAAU,CAACM;IAC/B,CAAC;IACDjD,UAAU,EAAE;MACVd,KAAK,EAAEL,KAAK,CAAC8B,MAAM,CAACuC;IACtB;EACA,CAAC,CAAC;AACJ","ignoreList":[]}
@@ -0,0 +1,166 @@
1
+ "use strict";
2
+
3
+ import { Pressable, StyleSheet, Text, View } from 'react-native';
4
+ import { useSafeAreaInsets } from 'react-native-safe-area-context';
5
+ import { useTheme } from "../../theme/theme-provider.js";
6
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
7
+ export function BottomNavigation({
8
+ accessibilityLabel = 'Bottom navigation',
9
+ containerStyle,
10
+ contentStyle,
11
+ indicatorRadius = 0,
12
+ items,
13
+ onValueChange,
14
+ radius,
15
+ safeArea = true,
16
+ shadow = true,
17
+ shadowColor,
18
+ shadowVariant = 'primary',
19
+ style,
20
+ value
21
+ }) {
22
+ const theme = useTheme();
23
+ const insets = useSafeAreaInsets();
24
+ const styles = createStyles(theme);
25
+ const resolvedRadius = radius ?? theme.border.radius;
26
+ const resolvedShadowColor = shadowColor ?? resolveShadowColor(shadowVariant, theme);
27
+ return /*#__PURE__*/_jsx(View, {
28
+ style: containerStyle,
29
+ children: /*#__PURE__*/_jsx(View, {
30
+ accessibilityLabel: accessibilityLabel,
31
+ accessibilityRole: "tablist",
32
+ style: [styles.root, {
33
+ paddingBottom: safeArea ? Math.max(insets.bottom, theme.spacing.md) : theme.spacing.md
34
+ }, style],
35
+ testID: "bottom-navigation",
36
+ children: /*#__PURE__*/_jsxs(View, {
37
+ style: [styles.shadowContainer, !shadow && styles.shadowContainerWithoutShadow],
38
+ testID: "bottom-navigation-shadow-container",
39
+ children: [shadow ? /*#__PURE__*/_jsx(View, {
40
+ pointerEvents: "none",
41
+ style: [styles.hardShadow, {
42
+ backgroundColor: resolvedShadowColor,
43
+ borderRadius: resolvedRadius
44
+ }],
45
+ testID: "bottom-navigation-hard-shadow"
46
+ }) : null, /*#__PURE__*/_jsx(View, {
47
+ style: [styles.content, {
48
+ borderRadius: resolvedRadius
49
+ }, contentStyle],
50
+ testID: "bottom-navigation-content",
51
+ children: items.map(item => {
52
+ const selected = item.value === value;
53
+ return /*#__PURE__*/_jsxs(Pressable, {
54
+ accessibilityLabel: item.accessibilityLabel ?? item.label,
55
+ accessibilityRole: "tab",
56
+ accessibilityState: {
57
+ disabled: item.disabled,
58
+ selected
59
+ },
60
+ disabled: item.disabled,
61
+ onPress: () => onValueChange?.(item.value),
62
+ style: [styles.item, selected && [styles.selectedItem, {
63
+ borderBottomLeftRadius: indicatorRadius,
64
+ borderBottomRightRadius: indicatorRadius
65
+ }], item.disabled && styles.disabledItem],
66
+ testID: `bottom-navigation-item-${item.value}`,
67
+ children: [/*#__PURE__*/_jsx(View, {
68
+ style: styles.icon,
69
+ children: selected && item.activeIcon ? item.activeIcon : item.icon
70
+ }), /*#__PURE__*/_jsx(Text, {
71
+ numberOfLines: 1,
72
+ style: [styles.label, selected && styles.selectedLabel, item.disabled && styles.disabledLabel],
73
+ children: item.label
74
+ })]
75
+ }, item.value);
76
+ })
77
+ })]
78
+ })
79
+ })
80
+ });
81
+ }
82
+ function resolveShadowColor(variant, theme) {
83
+ const colors = {
84
+ default: theme.shadow.color,
85
+ destructive: theme.colors.destructive,
86
+ info: theme.colors.info,
87
+ primary: theme.colors.primary,
88
+ secondary: theme.colors.secondary,
89
+ success: theme.colors.success,
90
+ warning: theme.colors.warning
91
+ };
92
+ return colors[variant];
93
+ }
94
+ function createStyles(theme) {
95
+ return StyleSheet.create({
96
+ root: {
97
+ backgroundColor: theme.colors.background,
98
+ paddingHorizontal: 14,
99
+ paddingTop: theme.spacing.xs,
100
+ width: '100%'
101
+ },
102
+ shadowContainer: {
103
+ paddingBottom: theme.shadow.offset,
104
+ paddingRight: theme.shadow.offset,
105
+ position: 'relative'
106
+ },
107
+ shadowContainerWithoutShadow: {
108
+ paddingBottom: 0,
109
+ paddingRight: 0
110
+ },
111
+ hardShadow: {
112
+ bottom: 0,
113
+ left: theme.shadow.offset,
114
+ position: 'absolute',
115
+ right: 0,
116
+ top: theme.shadow.offset
117
+ },
118
+ content: {
119
+ backgroundColor: theme.colors.background,
120
+ borderColor: theme.border.color,
121
+ borderWidth: theme.border.width,
122
+ flexDirection: 'row',
123
+ minHeight: 64,
124
+ overflow: 'hidden',
125
+ paddingHorizontal: theme.spacing.md,
126
+ paddingVertical: 6,
127
+ width: '100%'
128
+ },
129
+ item: {
130
+ alignItems: 'center',
131
+ borderBottomColor: 'transparent',
132
+ borderBottomWidth: 0,
133
+ flex: 1,
134
+ gap: 4,
135
+ justifyContent: 'center',
136
+ minWidth: 0
137
+ },
138
+ selectedItem: {
139
+ borderBottomColor: theme.colors.primary,
140
+ borderBottomWidth: theme.border.width
141
+ },
142
+ disabledItem: {
143
+ opacity: 0.5
144
+ },
145
+ icon: {
146
+ alignItems: 'center',
147
+ height: 24,
148
+ justifyContent: 'center',
149
+ width: 24
150
+ },
151
+ label: {
152
+ color: theme.colors.foreground,
153
+ fontSize: theme.typography.sm,
154
+ fontWeight: '500',
155
+ lineHeight: 20
156
+ },
157
+ selectedLabel: {
158
+ color: theme.colors.primary,
159
+ fontWeight: '700'
160
+ },
161
+ disabledLabel: {
162
+ color: theme.colors.mutedForeground
163
+ }
164
+ });
165
+ }
166
+ //# sourceMappingURL=bottom-navigation.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["Pressable","StyleSheet","Text","View","useSafeAreaInsets","useTheme","jsx","_jsx","jsxs","_jsxs","BottomNavigation","accessibilityLabel","containerStyle","contentStyle","indicatorRadius","items","onValueChange","radius","safeArea","shadow","shadowColor","shadowVariant","style","value","theme","insets","styles","createStyles","resolvedRadius","border","resolvedShadowColor","resolveShadowColor","children","accessibilityRole","root","paddingBottom","Math","max","bottom","spacing","md","testID","shadowContainer","shadowContainerWithoutShadow","pointerEvents","hardShadow","backgroundColor","borderRadius","content","map","item","selected","label","accessibilityState","disabled","onPress","selectedItem","borderBottomLeftRadius","borderBottomRightRadius","disabledItem","icon","activeIcon","numberOfLines","selectedLabel","disabledLabel","variant","colors","default","color","destructive","info","primary","secondary","success","warning","create","background","paddingHorizontal","paddingTop","xs","width","offset","paddingRight","position","left","right","top","borderColor","borderWidth","flexDirection","minHeight","overflow","paddingVertical","alignItems","borderBottomColor","borderBottomWidth","flex","gap","justifyContent","minWidth","opacity","height","foreground","fontSize","typography","sm","fontWeight","lineHeight","mutedForeground"],"sourceRoot":"../../../../src","sources":["components/bottom-navigation/bottom-navigation.tsx"],"mappings":";;AACA,SACEA,SAAS,EACTC,UAAU,EACVC,IAAI,EACJC,IAAI,QAGC,cAAc;AACrB,SAASC,iBAAiB,QAAQ,gCAAgC;AAGlE,SAASC,QAAQ,QAAQ,+BAA4B;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AA4BtD,OAAO,SAASC,gBAAgBA,CAAC;EAC/BC,kBAAkB,GAAG,mBAAmB;EACxCC,cAAc;EACdC,YAAY;EACZC,eAAe,GAAG,CAAC;EACnBC,KAAK;EACLC,aAAa;EACbC,MAAM;EACNC,QAAQ,GAAG,IAAI;EACfC,MAAM,GAAG,IAAI;EACbC,WAAW;EACXC,aAAa,GAAG,SAAS;EACzBC,KAAK;EACLC;AACqB,CAAC,EAAE;EACxB,MAAMC,KAAK,GAAGnB,QAAQ,CAAC,CAAC;EACxB,MAAMoB,MAAM,GAAGrB,iBAAiB,CAAC,CAAC;EAClC,M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d,CAAC;IACD1C,aAAa,EAAE;MACbI,KAAK,EAAE5C,KAAK,CAAC0C,MAAM,CAAC0C;IACtB;EACF,CAAC,CAAC;AACJ","ignoreList":[]}
@@ -0,0 +1,285 @@
1
+ "use strict";
2
+
3
+ import { Fragment, useCallback, useEffect, useMemo, useRef, useState } from 'react';
4
+ import { Animated, Easing, Keyboard, PanResponder, Platform, StyleSheet, View, useWindowDimensions } from 'react-native';
5
+ import * as DialogPrimitive from '@rn-primitives/dialog';
6
+ import { FullWindowOverlay as NativeFullWindowOverlay } from 'react-native-screens';
7
+ import { useSafeAreaInsets } from 'react-native-safe-area-context';
8
+ import { useTheme } from "../../theme/theme-provider.js";
9
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
10
+ const FullWindowOverlay = Platform.OS === 'ios' ? NativeFullWindowOverlay : Fragment;
11
+ export function BottomSheet({
12
+ animation = 'slide',
13
+ animationDuration = 220,
14
+ bottomPadding,
15
+ children,
16
+ dragToDismiss = false,
17
+ keyboardVerticalOffset = 0,
18
+ onCloseComplete,
19
+ onOpenChange,
20
+ open,
21
+ radius,
22
+ shadow = true
23
+ }) {
24
+ const theme = useTheme();
25
+ const insets = useSafeAreaInsets();
26
+ const {
27
+ height: windowHeight
28
+ } = useWindowDimensions();
29
+ const componentStyles = createStyles(theme);
30
+ const [keyboardBottom, setKeyboardBottom] = useState(0);
31
+ const [isPresent, setIsPresent] = useState(open);
32
+ const animationProgress = useRef(new Animated.Value(0)).current;
33
+ const dragTranslation = useRef(new Animated.Value(0)).current;
34
+ const onCloseCompleteRef = useRef(onCloseComplete);
35
+ const resolvedRadius = radius ?? theme.border.radius;
36
+ const resolvedBottomPadding = bottomPadding ?? Math.max(insets.bottom, theme.spacing.lg);
37
+ const resetDragPosition = useCallback(() => {
38
+ Animated.spring(dragTranslation, {
39
+ toValue: 0,
40
+ useNativeDriver: true
41
+ }).start();
42
+ }, [dragTranslation]);
43
+ useEffect(() => {
44
+ onCloseCompleteRef.current = onCloseComplete;
45
+ }, [onCloseComplete]);
46
+ const panResponder = useMemo(() => PanResponder.create({
47
+ onMoveShouldSetPanResponder: (_event, gestureState) => gestureState.dy > 6 && Math.abs(gestureState.dy) > Math.abs(gestureState.dx),
48
+ onPanResponderMove: (_event, gestureState) => {
49
+ dragTranslation.setValue(Math.max(0, gestureState.dy));
50
+ },
51
+ onPanResponderRelease: (_event, gestureState) => {
52
+ if (gestureState.dy > 80 || gestureState.vy > 0.8) {
53
+ onOpenChange(false);
54
+ return;
55
+ }
56
+ resetDragPosition();
57
+ },
58
+ onPanResponderTerminate: resetDragPosition
59
+ }), [dragTranslation, onOpenChange, resetDragPosition]);
60
+ useEffect(() => {
61
+ const showEvent = Platform.OS === 'ios' ? 'keyboardWillShow' : 'keyboardDidShow';
62
+ const hideEvent = Platform.OS === 'ios' ? 'keyboardWillHide' : 'keyboardDidHide';
63
+ const showSubscription = Keyboard.addListener(showEvent, event => {
64
+ setKeyboardBottom(event.endCoordinates.height);
65
+ });
66
+ const hideSubscription = Keyboard.addListener(hideEvent, () => {
67
+ setKeyboardBottom(0);
68
+ });
69
+ return () => {
70
+ showSubscription.remove();
71
+ hideSubscription.remove();
72
+ };
73
+ }, []);
74
+ useEffect(() => {
75
+ if (!open) {
76
+ return;
77
+ }
78
+ dragTranslation.stopAnimation();
79
+ dragTranslation.setValue(0);
80
+ }, [dragTranslation, open]);
81
+ useEffect(() => {
82
+ animationProgress.stopAnimation();
83
+ if (animation === 'none') {
84
+ animationProgress.setValue(open ? 1 : 0);
85
+ setIsPresent(open);
86
+ if (!open && isPresent) {
87
+ onCloseCompleteRef.current?.();
88
+ }
89
+ return;
90
+ }
91
+ if (open) {
92
+ setIsPresent(true);
93
+ Animated.timing(animationProgress, {
94
+ duration: animationDuration,
95
+ easing: Easing.out(Easing.cubic),
96
+ toValue: 1,
97
+ useNativeDriver: true
98
+ }).start();
99
+ return;
100
+ }
101
+ if (!isPresent) {
102
+ return;
103
+ }
104
+ Animated.timing(animationProgress, {
105
+ duration: animationDuration,
106
+ easing: Easing.in(Easing.cubic),
107
+ toValue: 0,
108
+ useNativeDriver: true
109
+ }).start();
110
+ const unmountTimeout = setTimeout(() => {
111
+ setIsPresent(false);
112
+ onCloseCompleteRef.current?.();
113
+ }, animationDuration);
114
+ return () => clearTimeout(unmountTimeout);
115
+ }, [animation, animationDuration, animationProgress, isPresent, open]);
116
+ const slideTranslation = animation === 'slide' ? animationProgress.interpolate({
117
+ inputRange: [0, 1],
118
+ outputRange: [windowHeight, 0]
119
+ }) : dragTranslation;
120
+ const animatedStyle = {
121
+ transform: [{
122
+ translateY: animation === 'slide' ? Animated.add(slideTranslation, dragTranslation) : dragTranslation
123
+ }]
124
+ };
125
+ return /*#__PURE__*/_jsx(DialogPrimitive.Root, {
126
+ onOpenChange: onOpenChange,
127
+ open: open,
128
+ children: /*#__PURE__*/_jsx(DialogPrimitive.Portal, {
129
+ forceMount: isPresent ? true : undefined,
130
+ children: /*#__PURE__*/_jsxs(FullWindowOverlay, {
131
+ children: [/*#__PURE__*/_jsx(DialogPrimitive.Overlay, {
132
+ closeOnPress: open,
133
+ forceMount: isPresent ? true : undefined,
134
+ pointerEvents: open ? 'auto' : 'none',
135
+ style: componentStyles.overlay,
136
+ testID: "bottom-sheet-overlay"
137
+ }), /*#__PURE__*/_jsx(View, {
138
+ pointerEvents: "box-none",
139
+ style: componentStyles.viewport,
140
+ testID: "bottom-sheet-viewport",
141
+ children: /*#__PURE__*/_jsx(View, {
142
+ pointerEvents: "box-none",
143
+ style: [componentStyles.positioner, {
144
+ bottom: Math.max(0, keyboardBottom - keyboardVerticalOffset)
145
+ }],
146
+ testID: "bottom-sheet-positioner",
147
+ children: /*#__PURE__*/_jsx(Animated.View, {
148
+ pointerEvents: open ? 'auto' : 'none',
149
+ style: [componentStyles.animatedSurface, animatedStyle],
150
+ ...(dragToDismiss ? panResponder.panHandlers : {}),
151
+ children: /*#__PURE__*/_jsx(DialogPrimitive.Content, {
152
+ forceMount: isPresent ? true : undefined,
153
+ style: [componentStyles.surface, shadow && componentStyles.surfaceShadow, {
154
+ borderTopLeftRadius: resolvedRadius,
155
+ borderTopRightRadius: resolvedRadius,
156
+ paddingBottom: resolvedBottomPadding
157
+ }],
158
+ testID: "bottom-sheet-content",
159
+ children: children
160
+ })
161
+ })
162
+ })
163
+ })]
164
+ })
165
+ })
166
+ });
167
+ }
168
+ export function BottomSheetHeader({
169
+ title,
170
+ titleNumberOfLines = 2
171
+ }) {
172
+ const componentStyles = createStyles(useTheme());
173
+ return /*#__PURE__*/_jsxs(View, {
174
+ style: componentStyles.header,
175
+ children: [/*#__PURE__*/_jsx(View, {
176
+ style: componentStyles.handle,
177
+ testID: "bottom-sheet-handle"
178
+ }), /*#__PURE__*/_jsx(DialogPrimitive.Title, {
179
+ ellipsizeMode: "tail",
180
+ numberOfLines: titleNumberOfLines,
181
+ style: componentStyles.title,
182
+ children: title
183
+ })]
184
+ });
185
+ }
186
+ export function BottomSheetBody({
187
+ children,
188
+ style,
189
+ ...props
190
+ }) {
191
+ const componentStyles = createStyles(useTheme());
192
+ return /*#__PURE__*/_jsx(View, {
193
+ style: [componentStyles.body, style],
194
+ ...props,
195
+ children: children
196
+ });
197
+ }
198
+ export function BottomSheetFooter({
199
+ children,
200
+ style,
201
+ ...props
202
+ }) {
203
+ const componentStyles = createStyles(useTheme());
204
+ return /*#__PURE__*/_jsx(View, {
205
+ style: [componentStyles.footer, style],
206
+ ...props,
207
+ children: children
208
+ });
209
+ }
210
+ function createStyles(theme) {
211
+ return StyleSheet.create({
212
+ overlay: {
213
+ ...StyleSheet.absoluteFill,
214
+ backgroundColor: 'rgba(0, 0, 0, 0.5)'
215
+ },
216
+ viewport: {
217
+ ...StyleSheet.absoluteFill,
218
+ justifyContent: 'flex-end'
219
+ },
220
+ positioner: {
221
+ alignItems: 'center',
222
+ bottom: 0,
223
+ justifyContent: 'flex-end',
224
+ left: 0,
225
+ position: 'absolute',
226
+ right: 0,
227
+ width: '100%'
228
+ },
229
+ animatedSurface: {
230
+ width: '100%'
231
+ },
232
+ surface: {
233
+ backgroundColor: theme.colors.surface,
234
+ borderColor: theme.border.color,
235
+ borderTopLeftRadius: theme.border.radius,
236
+ borderTopRightRadius: theme.border.radius,
237
+ borderTopWidth: theme.border.width,
238
+ overflow: 'hidden',
239
+ width: '100%'
240
+ },
241
+ surfaceShadow: {
242
+ elevation: 6,
243
+ shadowColor: theme.shadow.color,
244
+ shadowOffset: {
245
+ height: -theme.shadow.offset,
246
+ width: 0
247
+ },
248
+ shadowOpacity: 0.25,
249
+ shadowRadius: theme.shadow.offset
250
+ },
251
+ header: {
252
+ alignItems: 'center',
253
+ gap: theme.spacing.md,
254
+ paddingHorizontal: theme.spacing.md,
255
+ paddingTop: theme.spacing.md
256
+ },
257
+ handle: {
258
+ backgroundColor: theme.colors.foreground,
259
+ borderRadius: 999,
260
+ height: 5,
261
+ opacity: 0.25,
262
+ width: 100
263
+ },
264
+ title: {
265
+ color: theme.colors.foreground,
266
+ fontSize: 20,
267
+ fontWeight: '700',
268
+ lineHeight: 28,
269
+ textAlign: 'center',
270
+ width: '100%'
271
+ },
272
+ body: {
273
+ gap: theme.spacing.md,
274
+ paddingHorizontal: theme.spacing.md
275
+ },
276
+ footer: {
277
+ flexDirection: 'row',
278
+ gap: theme.spacing.sm,
279
+ paddingBottom: 0,
280
+ paddingHorizontal: theme.spacing.md,
281
+ paddingTop: theme.spacing.md
282
+ }
283
+ });
284
+ }
285
+ //# sourceMappingURL=bottom-sheet.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"names":["Fragment","useCallback","useEffect","useMemo","useRef","useState","Animated","Easing","Keyboard","PanResponder","Platform","StyleSheet","View","useWindowDimensions","DialogPrimitive","FullWindowOverlay","NativeFullWindowOverlay","useSafeAreaInsets","useTheme","jsx","_jsx","jsxs","_jsxs","OS","BottomSheet","animation","animationDuration","bottomPadding","children","dragToDismiss","keyboardVerticalOffset","onCloseComplete","onOpenChange","open","radius","shadow","theme","insets","height","windowHeight","componentStyles","createStyles","keyboardBottom","setKeyboardBottom","isPresent","setIsPresent","animationProgress","Value","current","dragTranslation","onCloseCompleteRef","resolvedRadius","border","resolvedBottomPadding","Math","max","bottom","spacing","lg","resetDragPosition","spring","toValue","useNativeDriver","start","panResponder","create","onMoveShouldSetPanResponder","_event","gestureState","dy","abs","dx","onPanResponderMove","setValue","onPanResponderRelease","vy","onPanResponderTerminate","showEvent","hideEvent","showSubscription","addListener","event","endCoordinates","hideSubscription","remove","stopAnimation","timing","duration","easing","out","cubic","in","unmountTimeout","setTimeout","clearTimeout","slideTranslation","interpolate","inputRange","outputRange","animatedStyle","transform","translateY","add","Root","Portal","forceMount","undefined","Overlay","closeOnPress","pointerEvents","style","overlay","testID","viewport","positioner","animatedSurface","panHandlers","Content","surface","surfaceShadow","borderTopLeftRadius","borderTopRightRadius","paddingBottom","BottomSheetHeader","title","titleNumberOfLines","header","handle","Title","ellipsizeMode","numberOfLines","BottomSheetBody","props","body","BottomSheetFooter","footer","absoluteFill","backgroundColor","justifyContent","alignItems","left","position","right","width","colors","borderColor","color","borderTopWidth","overflow","elevation","shadowColor","shadowOffset","offset","shadowOpacity","shadowRadius","gap","md","paddingHorizontal","paddingTop","foreground","borderRadius","opacity","fontSize","fontWeight","lineHeight","textAlign","flexDirection","sm"],"sourceRoot":"../../../../src","sources":["components/bottom-sheet/bottom-sheet.tsx"],"mappings":";;AAAA,SACEA,QAAQ,EACRC,WAAW,EACXC,SAAS,EACTC,OAAO,EACPC,MAAM,EACNC,QAAQ,QAEH,OAAO;AACd,SACEC,QAAQ,EACRC,MAAM,EACNC,QAAQ,EACRC,YAAY,EACZC,QAAQ,EACRC,UAAU,EACVC,IAAI,EACJC,mBAAmB,QAId,cAAc;AACrB,OAAO,KAAKC,eAAe,MAAM,uBAAuB;AACxD,SAASC,iBAAiB,IAAIC,uBAAuB,QAAQ,sBAAsB;AACnF,SAASC,iBAAiB,QAAQ,gCAAgC;AAGlE,SAASC,QAAQ,QAAQ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