@sincpro/mobile-ui 3.0.1 → 3.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/Actions/Actions.Button.d.ts +6 -6
- package/dist/Actions/Actions.Button.js +650 -180
- package/dist/Actions/Actions.Dock.d.ts +1 -1
- package/dist/Actions/Actions.Dock.js +297 -18
- package/dist/Actions/Actions.FAB.js +100 -12
- package/dist/Actions/Actions.FilterButton.d.ts +17 -0
- package/dist/Actions/Actions.FilterButton.js +263 -33
- package/dist/Actions/Actions.IconButton.d.ts +1 -0
- package/dist/Actions/Actions.IconButton.js +196 -33
- package/dist/Actions/index.js +13 -13
- package/dist/Dialog/Confirmation.context.js +82 -16
- package/dist/Dialog/Dialog.ActionSheet.js +200 -41
- package/dist/Dialog/Dialog.Confirmation.js +168 -31
- package/dist/Dialog/Dialog.EditValue.js +437 -62
- package/dist/Dialog/Dialog.Sheet.d.ts +7 -3
- package/dist/Dialog/Dialog.Sheet.js +267 -15
- package/dist/Dialog/OverlayHost.d.ts +24 -0
- package/dist/Dialog/OverlayHost.js +230 -0
- package/dist/Dialog/SheetSurface.d.ts +43 -0
- package/dist/Dialog/SheetSurface.js +495 -0
- package/dist/Dialog/dialog-actions.d.ts +17 -0
- package/dist/Dialog/dialog-actions.js +59 -0
- package/dist/Dialog/index.d.ts +4 -1
- package/dist/Dialog/index.js +8 -7
- package/dist/Dialog/overlay.store.d.ts +24 -0
- package/dist/Dialog/overlay.store.js +59 -0
- package/dist/Dialog/requestConfirmation.js +20 -10
- package/dist/Display/Display.Accordion.js +185 -13
- package/dist/Display/Display.AmountSummary.js +206 -15
- package/dist/Display/Display.Avatar.js +93 -31
- package/dist/Display/Display.AvatarGroup.js +132 -17
- package/dist/Display/Display.Badge.d.ts +18 -2
- package/dist/Display/Display.Badge.js +117 -49
- package/dist/Display/Display.Card.js +163 -26
- package/dist/Display/Display.Carousel.js +459 -105
- package/dist/Display/Display.Chip.d.ts +4 -1
- package/dist/Display/Display.Chip.js +165 -31
- package/dist/Display/Display.CircleButton.d.ts +1 -0
- package/dist/Display/Display.CircleButton.js +86 -27
- package/dist/Display/Display.CopyableText.js +289 -66
- package/dist/Display/Display.CountRecords.js +60 -3
- package/dist/Display/Display.DataTable.js +123 -13
- package/dist/Display/Display.Date.js +243 -33
- package/dist/Display/Display.Divider.d.ts +10 -10
- package/dist/Display/Display.Divider.js +67 -20
- package/dist/Display/Display.ExpoImage.js +97 -8
- package/dist/Display/Display.GradientSurface.d.ts +9 -4
- package/dist/Display/Display.GradientSurface.js +196 -46
- package/dist/Display/Display.Icon.js +129 -15
- package/dist/Display/Display.IconBadge.js +95 -25
- package/dist/Display/Display.Image.d.ts +7 -1
- package/dist/Display/Display.Image.js +344 -39
- package/dist/Display/Display.KeyValue.js +90 -5
- package/dist/Display/Display.ListGroup.js +181 -9
- package/dist/Display/Display.ListItem.js +324 -28
- package/dist/Display/Display.Logo.js +84 -29
- package/dist/Display/Display.MediaCard.js +125 -4
- package/dist/Display/Display.MediaEmbed.d.ts +0 -5
- package/dist/Display/Display.MediaEmbed.js +170 -26
- package/dist/Display/Display.MenuButton.d.ts +2 -2
- package/dist/Display/Display.MenuButton.js +380 -94
- package/dist/Display/Display.MenuCard.js +122 -18
- package/dist/Display/Display.MenuGrid.js +43 -3
- package/dist/Display/Display.Monetary.js +90 -5
- package/dist/Display/Display.Pattern.js +306 -47
- package/dist/Display/Display.PriceTag.js +117 -14
- package/dist/Display/Display.ProductCard.js +154 -4
- package/dist/Display/Display.Rating.js +92 -11
- package/dist/Display/Display.SearchHistory.js +132 -6
- package/dist/Display/Display.SectionHeader.d.ts +5 -1
- package/dist/Display/Display.SectionHeader.js +125 -12
- package/dist/Display/Display.Stat.js +62 -3
- package/dist/Display/Display.StatCard.js +131 -7
- package/dist/Display/Display.StatusBadge.d.ts +29 -0
- package/dist/Display/Display.StatusBadge.js +68 -0
- package/dist/Display/Display.StatusDot.js +93 -18
- package/dist/Display/Display.Story.js +285 -35
- package/dist/Display/Display.StoryTray.js +354 -34
- package/dist/Display/Display.StoryViewer.js +571 -72
- package/dist/Display/Display.SwipeableRow.js +148 -20
- package/dist/Display/Display.Tag.d.ts +4 -1
- package/dist/Display/Display.Tag.js +66 -4
- package/dist/Display/Display.Timeline.js +102 -13
- package/dist/Display/Display.Tooltip.js +122 -26
- package/dist/Display/chevron.d.ts +6 -0
- package/dist/Display/chevron.js +32 -0
- package/dist/Display/count-badge.d.ts +21 -0
- package/dist/Display/count-badge.js +124 -0
- package/dist/Display/group-title.d.ts +10 -0
- package/dist/Display/group-title.js +53 -0
- package/dist/Display/icon-font.d.ts +3 -0
- package/dist/Display/icon-font.ios.d.ts +3 -0
- package/dist/Display/icon-font.ios.js +4 -0
- package/dist/Display/icon-font.js +7 -0
- package/dist/Display/icon-glyphs.d.ts +2 -0
- package/dist/Display/icon-glyphs.js +87 -0
- package/dist/Display/icon-map.d.ts +15 -11
- package/dist/Display/icon-map.js +344 -84
- package/dist/Display/icon-registry.d.ts +21 -0
- package/dist/Display/icon-registry.js +21 -0
- package/dist/Display/index.d.ts +6 -1
- package/dist/Display/index.js +53 -48
- package/dist/Display/pill.d.ts +16 -0
- package/dist/Display/pill.js +47 -0
- package/dist/Feedback/ErrorBoundary.js +35 -23
- package/dist/Feedback/Feedback.Banner.js +202 -24
- package/dist/Feedback/Feedback.DomainSplashScreen.js +246 -70
- package/dist/Feedback/Feedback.Empty.js +54 -3
- package/dist/Feedback/Feedback.EmptyState.js +114 -5
- package/dist/Feedback/Feedback.Error.d.ts +1 -1
- package/dist/Feedback/Feedback.Error.js +130 -5
- package/dist/Feedback/Feedback.Loading.d.ts +1 -1
- package/dist/Feedback/Feedback.Loading.js +70 -3
- package/dist/Feedback/Feedback.PermissionCard.js +161 -5
- package/dist/Feedback/Feedback.Progress.js +199 -41
- package/dist/Feedback/Feedback.ProgressCircle.js +184 -12
- package/dist/Feedback/Feedback.Skeleton.js +149 -36
- package/dist/Feedback/Feedback.Spinner.js +407 -79
- package/dist/Feedback/Feedback.Splash.js +240 -33
- package/dist/Feedback/Feedback.State.d.ts +17 -0
- package/dist/Feedback/Feedback.State.js +104 -0
- package/dist/Feedback/Toast.context.js +883 -167
- package/dist/Feedback/index.d.ts +3 -0
- package/dist/Feedback/index.js +15 -13
- package/dist/Form/Form.Checkbox.js +212 -22
- package/dist/Form/Form.ControlledCheckbox.d.ts +1 -1
- package/dist/Form/Form.ControlledCheckbox.js +46 -4
- package/dist/Form/Form.ControlledDropdown.d.ts +1 -1
- package/dist/Form/Form.ControlledDropdown.js +62 -4
- package/dist/Form/Form.ControlledInput.d.ts +4 -3
- package/dist/Form/Form.ControlledInput.js +72 -4
- package/dist/Form/Form.ControlledMonetaryInput.d.ts +6 -3
- package/dist/Form/Form.ControlledMonetaryInput.js +50 -4
- package/dist/Form/Form.ControlledRadioButton.d.ts +2 -2
- package/dist/Form/Form.ControlledRadioButton.js +45 -4
- package/dist/Form/Form.DatePicker.js +507 -107
- package/dist/Form/Form.Dropdown.js +303 -52
- package/dist/Form/Form.ErrorSummary.js +236 -44
- package/dist/Form/Form.Field.d.ts +24 -0
- package/dist/Form/Form.Field.js +55 -0
- package/dist/Form/Form.FractionalQuantityInput.js +508 -96
- package/dist/Form/Form.Input.d.ts +17 -3
- package/dist/Form/Form.Input.js +497 -29
- package/dist/Form/Form.KeyboardForm.d.ts +22 -8
- package/dist/Form/Form.KeyboardForm.js +83 -8
- package/dist/Form/Form.KeyboardToolbarHost.d.ts +14 -0
- package/dist/Form/Form.KeyboardToolbarHost.js +223 -0
- package/dist/Form/Form.MonetaryInput.js +164 -17
- package/dist/Form/Form.PickerField.d.ts +31 -0
- package/dist/Form/Form.PickerField.js +539 -0
- package/dist/Form/Form.PinInput.js +150 -15
- package/dist/Form/Form.QuantitySelector.js +229 -25
- package/dist/Form/Form.RadioButton.d.ts +1 -0
- package/dist/Form/Form.RadioButton.js +26 -29
- package/dist/Form/Form.Select.d.ts +2 -1
- package/dist/Form/Form.Select.js +388 -60
- package/dist/Form/Form.Slider.js +133 -10
- package/dist/Form/Form.Switch.js +99 -4
- package/dist/Form/choice-row.d.ts +15 -0
- package/dist/Form/choice-row.js +236 -0
- package/dist/Form/index.d.ts +11 -6
- package/dist/Form/index.js +26 -27
- package/dist/Form/input-text.d.ts +7 -0
- package/dist/Form/input-text.js +18 -0
- package/dist/Navigation/Navigation.AppBar.d.ts +3 -4
- package/dist/Navigation/Navigation.AppBar.js +535 -99
- package/dist/Navigation/Navigation.BottomNav.js +363 -98
- package/dist/Navigation/Navigation.CollapsingHeader.d.ts +28 -13
- package/dist/Navigation/Navigation.CollapsingHeader.js +369 -36
- package/dist/Navigation/Navigation.FloatingBar.js +71 -11
- package/dist/Navigation/Navigation.Menu.js +309 -95
- package/dist/Navigation/Navigation.MenuSection.js +80 -11
- package/dist/Navigation/Navigation.RowItem.d.ts +4 -2
- package/dist/Navigation/Navigation.RowItem.js +93 -8
- package/dist/Navigation/Navigation.Search.js +241 -27
- package/dist/Navigation/Navigation.SearchBar.d.ts +7 -1
- package/dist/Navigation/Navigation.SearchBar.js +218 -29
- package/dist/Navigation/Navigation.SearchSuggestions.js +77 -3
- package/dist/Navigation/Navigation.SegmentedControl.js +152 -14
- package/dist/Navigation/Navigation.Steps.js +105 -11
- package/dist/Navigation/Navigation.Tabs.js +449 -41
- package/dist/Navigation/index.d.ts +9 -4
- package/dist/Navigation/index.js +13 -13
- package/dist/Typography/Typography.Heading.js +33 -3
- package/dist/Typography/Typography.SelectableText.js +95 -7
- package/dist/Typography/Typography.Text.d.ts +4 -2
- package/dist/Typography/Typography.Text.js +217 -7
- package/dist/Typography/index.js +3 -3
- package/dist/branding.js +29 -13
- package/dist/icons/AddItemIcon.js +76 -2
- package/dist/icons/ArrangeCircle.js +82 -2
- package/dist/icons/ArrowDownIcon.js +63 -3
- package/dist/icons/ArrowUpIcon.js +63 -3
- package/dist/icons/BoxIcon.js +64 -2
- package/dist/icons/BoxTimeIcon.js +63 -2
- package/dist/icons/CalendarIcon.js +145 -2
- package/dist/icons/CardIcon.js +80 -2
- package/dist/icons/CashierIcon.js +39 -2
- package/dist/icons/CreditIcon.js +76 -3
- package/dist/icons/DuoIcon.js +75 -2
- package/dist/icons/HomeIcon.js +39 -2
- package/dist/icons/HomeIconOutlined.js +53 -2
- package/dist/icons/LogoIcon.js +87 -2
- package/dist/icons/MoneyReceiveIcon.js +86 -2
- package/dist/icons/PinIcon.js +39 -2
- package/dist/icons/ProfileIcon.js +47 -2
- package/dist/icons/SettingsIcon.js +114 -2
- package/dist/icons/SinpeIcon.js +60 -2
- package/dist/icons/ToggleOffIcon.js +53 -2
- package/dist/icons/WalletMoneyIcon.js +81 -2
- package/dist/index.d.ts +1 -0
- package/dist/index.js +8 -2
- package/dist/layouts/AuthContainer.d.ts +4 -5
- package/dist/layouts/AuthContainer.js +231 -7
- package/dist/layouts/BottomInset.js +4 -1
- package/dist/layouts/Container.d.ts +2 -2
- package/dist/layouts/Container.js +45 -3
- package/dist/layouts/GradientContainer.js +37 -5
- package/dist/layouts/PlainLayout.js +19 -3
- package/dist/layouts/ScrollContainer.d.ts +14 -9
- package/dist/layouts/ScrollContainer.js +125 -4
- package/dist/layouts/edges.d.ts +2 -0
- package/dist/layouts/edges.js +1 -0
- package/dist/primitives/AspectRatio.js +75 -3
- package/dist/primitives/Box.js +45 -3
- package/dist/primitives/Pressable.js +95 -5
- package/dist/primitives/Row.js +84 -13
- package/dist/primitives/Spacer.js +42 -5
- package/dist/primitives/Stack.js +66 -7
- package/dist/primitives/index.js +1 -1
- package/dist/theme/active.d.ts +2 -0
- package/dist/theme/active.js +33 -18
- package/dist/theme/build.js +118 -87
- package/dist/theme/color.js +87 -87
- package/dist/theme/components/ThemedActivityIndicator.d.ts +2 -15
- package/dist/theme/components/ThemedActivityIndicator.js +35 -3
- package/dist/theme/components/index.js +1 -0
- package/dist/theme/contrast.js +32 -33
- package/dist/theme/css-vars.js +71 -75
- package/dist/theme/dark.js +116 -97
- package/dist/theme/default.js +116 -97
- package/dist/theme/define.js +16 -12
- package/dist/theme/index.d.ts +1 -0
- package/dist/theme/index.js +7 -6
- package/dist/theme/on-dark-surface.d.ts +12 -0
- package/dist/theme/on-dark-surface.js +13 -0
- package/dist/theme/theme.js +1 -0
- package/dist/theme/tw.js +3 -1
- package/dist/theme/types.js +0 -18
- package/dist/theme/typography.d.ts +1 -1
- package/dist/theme/typography.js +337 -303
- package/dist/theme/useTheme.d.ts +4 -0
- package/dist/theme/useTheme.js +7 -3
- package/dist/theme/useThemeVars.d.ts +9 -0
- package/dist/theme/useThemeVars.js +23 -0
- package/dist/theme/validate.js +175 -166
- package/dist/tokens/index.js +1 -1
- package/dist/tokens/motion.js +30 -13
- package/dist/utils/async.d.ts +14 -0
- package/dist/utils/async.js +22 -0
- package/dist/utils/criteria.js +66 -85
- package/dist/utils/date.d.ts +8 -2
- package/dist/utils/date.js +63 -50
- package/dist/utils/image.js +8 -8
- package/dist/utils/intl.d.ts +1 -0
- package/dist/utils/intl.js +13 -0
- package/dist/utils/keys.js +3 -5
- package/dist/utils/monetary.d.ts +1 -0
- package/dist/utils/monetary.js +28 -24
- package/dist/utils/progress.js +2 -3
- package/dist/utils/quantity.js +25 -26
- package/dist/utils/reorder.js +11 -20
- package/dist/utils/search.d.ts +4 -0
- package/dist/utils/search.js +12 -0
- package/dist/utils/serializer.js +38 -38
- package/dist/utils/useReducedMotion.js +32 -30
- package/dist/views/AppSplashView.js +117 -3
- package/dist/views/AuthFormView.d.ts +4 -5
- package/dist/views/AuthFormView.js +119 -11
- package/dist/views/FormViewV2.context.js +75 -23
- package/dist/views/FormViewV2.d.ts +4 -5
- package/dist/views/FormViewV2.js +658 -92
- package/dist/views/ListViewV2.context.js +91 -47
- package/dist/views/ListViewV2.d.ts +84 -43
- package/dist/views/ListViewV2.js +1350 -200
- package/dist/views/Wizard/Wizard.context.js +248 -84
- package/dist/views/Wizard/Wizard.js +260 -67
- package/dist/views/types/IListView.js +34 -31
- package/dist/widgets/CollectionOptions.js +557 -138
- package/dist/widgets/FilterBar.js +159 -7
- package/dist/widgets/FilterBuilder.js +375 -102
- package/dist/widgets/JSONViewer.js +275 -129
- package/dist/widgets/PromoBanner.js +336 -42
- package/dist/widgets/PromoModal.d.ts +2 -2
- package/dist/widgets/PromoModal.js +389 -62
- package/dist/widgets/QueryChoice.js +150 -8
- package/dist/widgets/QuickActions.js +120 -31
- package/dist/widgets/ReorderableList.js +399 -128
- package/dist/widgets/TimeZoneSelectorModal.js +458 -51
- package/dist/widgets/index.js +3 -3
- package/package.json +6 -1
- package/tailwind.preset.js +7 -5
- package/dist/Form/Form.InputField.d.ts +0 -10
- package/dist/Form/Form.InputField.js +0 -38
- package/dist/Form/Form.KeyboardToolbar.d.ts +0 -22
- package/dist/Form/Form.KeyboardToolbar.js +0 -66
- package/dist/Form/Form.PasswordInput.d.ts +0 -9
- package/dist/Form/Form.PasswordInput.js +0 -17
- package/dist/Form/Form.TextInput.d.ts +0 -8
- package/dist/Form/Form.TextInput.js +0 -8
- package/dist/primitives/BaseButton.d.ts +0 -150
- package/dist/primitives/BaseButton.js +0 -229
- package/dist/utils/useSheetTranslation.d.ts +0 -5
- package/dist/utils/useSheetTranslation.js +0 -23
|
@@ -1,58 +1,466 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { c as _c } from "react/compiler-runtime";
|
|
2
2
|
import Icon from "../Display/Display.Icon.js";
|
|
3
3
|
import { useTheme } from "../theme/index.js";
|
|
4
4
|
import { cn } from "../theme/tw.js";
|
|
5
5
|
import { Typography } from "../Typography/index.js";
|
|
6
|
-
import { createContext, useCallback, useContext, useState } from "react";
|
|
6
|
+
import { createContext, useCallback, useContext, useMemo, useState } from "react";
|
|
7
7
|
import { TouchableOpacity, View } from "react-native";
|
|
8
|
+
import { jsx as _jsx, jsxs as _jsxs } from "nativewind/jsx-runtime";
|
|
8
9
|
const TabsContext = createContext(null);
|
|
9
10
|
function useTabs() {
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
11
|
+
const ctx = useContext(TabsContext);
|
|
12
|
+
if (!ctx) {
|
|
13
|
+
throw new Error("Tabs.* debe usarse dentro de <Tabs>");
|
|
14
|
+
}
|
|
15
|
+
return ctx;
|
|
15
16
|
}
|
|
16
|
-
function TabsRoot(
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
17
|
+
function TabsRoot(t0) {
|
|
18
|
+
const $ = _c(15);
|
|
19
|
+
const {
|
|
20
|
+
value,
|
|
21
|
+
defaultValue,
|
|
22
|
+
onValueChange,
|
|
23
|
+
variant: t1,
|
|
24
|
+
className,
|
|
25
|
+
children
|
|
26
|
+
} = t0;
|
|
27
|
+
const variant = t1 === undefined ? "underline" : t1;
|
|
28
|
+
const [internal, setInternal] = useState(defaultValue ?? "");
|
|
29
|
+
const current = value ?? internal;
|
|
30
|
+
let t2;
|
|
31
|
+
if ($[0] !== onValueChange || $[1] !== value) {
|
|
32
|
+
t2 = next => {
|
|
33
|
+
if (value === undefined) {
|
|
34
|
+
setInternal(next);
|
|
35
|
+
}
|
|
36
|
+
onValueChange?.(next);
|
|
37
|
+
};
|
|
38
|
+
$[0] = onValueChange;
|
|
39
|
+
$[1] = value;
|
|
40
|
+
$[2] = t2;
|
|
41
|
+
} else {
|
|
42
|
+
t2 = $[2];
|
|
43
|
+
}
|
|
44
|
+
const setValue = t2;
|
|
45
|
+
let t3;
|
|
46
|
+
if ($[3] !== current || $[4] !== setValue || $[5] !== variant) {
|
|
47
|
+
t3 = {
|
|
48
|
+
value: current,
|
|
49
|
+
setValue,
|
|
50
|
+
variant
|
|
51
|
+
};
|
|
52
|
+
$[3] = current;
|
|
53
|
+
$[4] = setValue;
|
|
54
|
+
$[5] = variant;
|
|
55
|
+
$[6] = t3;
|
|
56
|
+
} else {
|
|
57
|
+
t3 = $[6];
|
|
58
|
+
}
|
|
59
|
+
const context = t3;
|
|
60
|
+
let t4;
|
|
61
|
+
if ($[7] !== className) {
|
|
62
|
+
t4 = cn("flex-1", className);
|
|
63
|
+
$[7] = className;
|
|
64
|
+
$[8] = t4;
|
|
65
|
+
} else {
|
|
66
|
+
t4 = $[8];
|
|
67
|
+
}
|
|
68
|
+
let t5;
|
|
69
|
+
if ($[9] !== children || $[10] !== t4) {
|
|
70
|
+
t5 = _jsx(View, {
|
|
71
|
+
className: t4,
|
|
72
|
+
children: children
|
|
73
|
+
});
|
|
74
|
+
$[9] = children;
|
|
75
|
+
$[10] = t4;
|
|
76
|
+
$[11] = t5;
|
|
77
|
+
} else {
|
|
78
|
+
t5 = $[11];
|
|
79
|
+
}
|
|
80
|
+
let t6;
|
|
81
|
+
if ($[12] !== context || $[13] !== t5) {
|
|
82
|
+
t6 = _jsx(TabsContext.Provider, {
|
|
83
|
+
value: context,
|
|
84
|
+
children: t5
|
|
85
|
+
});
|
|
86
|
+
$[12] = context;
|
|
87
|
+
$[13] = t5;
|
|
88
|
+
$[14] = t6;
|
|
89
|
+
} else {
|
|
90
|
+
t6 = $[14];
|
|
91
|
+
}
|
|
92
|
+
return t6;
|
|
25
93
|
}
|
|
26
|
-
function TabsList(
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
94
|
+
function TabsList(t0) {
|
|
95
|
+
const $ = _c(11);
|
|
96
|
+
const {
|
|
97
|
+
children,
|
|
98
|
+
className
|
|
99
|
+
} = t0;
|
|
100
|
+
const {
|
|
101
|
+
variant
|
|
102
|
+
} = useTabs();
|
|
103
|
+
if (variant === "filled") {
|
|
104
|
+
let t1;
|
|
105
|
+
if ($[0] !== className) {
|
|
106
|
+
t1 = cn("flex-row rounded-xl p-1", className);
|
|
107
|
+
$[0] = className;
|
|
108
|
+
$[1] = t1;
|
|
109
|
+
} else {
|
|
110
|
+
t1 = $[1];
|
|
111
|
+
}
|
|
112
|
+
let t2;
|
|
113
|
+
if ($[2] === Symbol.for("react.memo_cache_sentinel")) {
|
|
114
|
+
t2 = {
|
|
115
|
+
backgroundColor: "#E5E7EB"
|
|
116
|
+
};
|
|
117
|
+
$[2] = t2;
|
|
118
|
+
} else {
|
|
119
|
+
t2 = $[2];
|
|
30
120
|
}
|
|
31
|
-
|
|
121
|
+
let t3;
|
|
122
|
+
if ($[3] !== children || $[4] !== t1) {
|
|
123
|
+
t3 = _jsx(View, {
|
|
124
|
+
accessibilityRole: "tablist",
|
|
125
|
+
className: t1,
|
|
126
|
+
style: t2,
|
|
127
|
+
children: children
|
|
128
|
+
});
|
|
129
|
+
$[3] = children;
|
|
130
|
+
$[4] = t1;
|
|
131
|
+
$[5] = t3;
|
|
132
|
+
} else {
|
|
133
|
+
t3 = $[5];
|
|
134
|
+
}
|
|
135
|
+
return t3;
|
|
136
|
+
}
|
|
137
|
+
let t1;
|
|
138
|
+
if ($[6] !== className) {
|
|
139
|
+
t1 = cn("flex-row border-b border-border-default", className);
|
|
140
|
+
$[6] = className;
|
|
141
|
+
$[7] = t1;
|
|
142
|
+
} else {
|
|
143
|
+
t1 = $[7];
|
|
144
|
+
}
|
|
145
|
+
let t2;
|
|
146
|
+
if ($[8] !== children || $[9] !== t1) {
|
|
147
|
+
t2 = _jsx(View, {
|
|
148
|
+
accessibilityRole: "tablist",
|
|
149
|
+
className: t1,
|
|
150
|
+
children: children
|
|
151
|
+
});
|
|
152
|
+
$[8] = children;
|
|
153
|
+
$[9] = t1;
|
|
154
|
+
$[10] = t2;
|
|
155
|
+
} else {
|
|
156
|
+
t2 = $[10];
|
|
157
|
+
}
|
|
158
|
+
return t2;
|
|
32
159
|
}
|
|
33
|
-
function TabsTrigger(
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
160
|
+
function TabsTrigger(t0) {
|
|
161
|
+
const $ = _c(68);
|
|
162
|
+
const {
|
|
163
|
+
value,
|
|
164
|
+
children,
|
|
165
|
+
icon,
|
|
166
|
+
iconLayout: t1
|
|
167
|
+
} = t0;
|
|
168
|
+
const iconLayout = t1 === undefined ? "left" : t1;
|
|
169
|
+
const theme = useTheme();
|
|
170
|
+
const {
|
|
171
|
+
value: active,
|
|
172
|
+
setValue,
|
|
173
|
+
variant
|
|
174
|
+
} = useTabs();
|
|
175
|
+
const selected = active === value;
|
|
176
|
+
const iconColor = selected ? theme.text.accent : theme.text.secondary;
|
|
177
|
+
if (variant === "filled") {
|
|
178
|
+
let t2;
|
|
179
|
+
if ($[0] !== selected) {
|
|
180
|
+
t2 = {
|
|
181
|
+
selected
|
|
182
|
+
};
|
|
183
|
+
$[0] = selected;
|
|
184
|
+
$[1] = t2;
|
|
185
|
+
} else {
|
|
186
|
+
t2 = $[1];
|
|
187
|
+
}
|
|
188
|
+
let t3;
|
|
189
|
+
if ($[2] !== setValue || $[3] !== value) {
|
|
190
|
+
t3 = () => setValue(value);
|
|
191
|
+
$[2] = setValue;
|
|
192
|
+
$[3] = value;
|
|
193
|
+
$[4] = t3;
|
|
194
|
+
} else {
|
|
195
|
+
t3 = $[4];
|
|
196
|
+
}
|
|
197
|
+
let t4;
|
|
198
|
+
if ($[5] !== selected || $[6] !== theme.bg || $[7] !== theme.shadow) {
|
|
199
|
+
t4 = selected ? {
|
|
200
|
+
backgroundColor: theme.bg.card,
|
|
201
|
+
...theme.shadow.sm
|
|
202
|
+
} : {};
|
|
203
|
+
$[5] = selected;
|
|
204
|
+
$[6] = theme.bg;
|
|
205
|
+
$[7] = theme.shadow;
|
|
206
|
+
$[8] = t4;
|
|
207
|
+
} else {
|
|
208
|
+
t4 = $[8];
|
|
209
|
+
}
|
|
210
|
+
const t5 = iconLayout === "left" && icon ? "flex-row gap-1.5" : "gap-1";
|
|
211
|
+
let t6;
|
|
212
|
+
if ($[9] !== t5) {
|
|
213
|
+
t6 = cn("items-center", t5);
|
|
214
|
+
$[9] = t5;
|
|
215
|
+
$[10] = t6;
|
|
216
|
+
} else {
|
|
217
|
+
t6 = $[10];
|
|
218
|
+
}
|
|
219
|
+
let t7;
|
|
220
|
+
if ($[11] !== icon || $[12] !== iconColor || $[13] !== iconLayout) {
|
|
221
|
+
t7 = icon && iconLayout === "top" && _jsx(Icon, {
|
|
222
|
+
color: iconColor,
|
|
223
|
+
name: icon,
|
|
224
|
+
size: 16
|
|
225
|
+
});
|
|
226
|
+
$[11] = icon;
|
|
227
|
+
$[12] = iconColor;
|
|
228
|
+
$[13] = iconLayout;
|
|
229
|
+
$[14] = t7;
|
|
230
|
+
} else {
|
|
231
|
+
t7 = $[14];
|
|
232
|
+
}
|
|
233
|
+
let t8;
|
|
234
|
+
if ($[15] !== icon || $[16] !== iconColor || $[17] !== iconLayout) {
|
|
235
|
+
t8 = icon && iconLayout === "left" && _jsx(Icon, {
|
|
236
|
+
color: iconColor,
|
|
237
|
+
name: icon,
|
|
238
|
+
size: 14
|
|
239
|
+
});
|
|
240
|
+
$[15] = icon;
|
|
241
|
+
$[16] = iconColor;
|
|
242
|
+
$[17] = iconLayout;
|
|
243
|
+
$[18] = t8;
|
|
244
|
+
} else {
|
|
245
|
+
t8 = $[18];
|
|
246
|
+
}
|
|
247
|
+
let t9;
|
|
248
|
+
if ($[19] !== iconColor) {
|
|
249
|
+
t9 = {
|
|
250
|
+
color: iconColor
|
|
251
|
+
};
|
|
252
|
+
$[19] = iconColor;
|
|
253
|
+
$[20] = t9;
|
|
254
|
+
} else {
|
|
255
|
+
t9 = $[20];
|
|
256
|
+
}
|
|
257
|
+
let t10;
|
|
258
|
+
if ($[21] !== children || $[22] !== selected || $[23] !== t9) {
|
|
259
|
+
t10 = _jsx(Typography.Text, {
|
|
260
|
+
semibold: selected,
|
|
261
|
+
style: t9,
|
|
262
|
+
variant: "bodySmall",
|
|
263
|
+
children: children
|
|
264
|
+
});
|
|
265
|
+
$[21] = children;
|
|
266
|
+
$[22] = selected;
|
|
267
|
+
$[23] = t9;
|
|
268
|
+
$[24] = t10;
|
|
269
|
+
} else {
|
|
270
|
+
t10 = $[24];
|
|
271
|
+
}
|
|
272
|
+
let t11;
|
|
273
|
+
if ($[25] !== t10 || $[26] !== t6 || $[27] !== t7 || $[28] !== t8) {
|
|
274
|
+
t11 = _jsxs(View, {
|
|
275
|
+
className: t6,
|
|
276
|
+
children: [t7, t8, t10]
|
|
277
|
+
});
|
|
278
|
+
$[25] = t10;
|
|
279
|
+
$[26] = t6;
|
|
280
|
+
$[27] = t7;
|
|
281
|
+
$[28] = t8;
|
|
282
|
+
$[29] = t11;
|
|
283
|
+
} else {
|
|
284
|
+
t11 = $[29];
|
|
285
|
+
}
|
|
286
|
+
let t12;
|
|
287
|
+
if ($[30] !== t11 || $[31] !== t2 || $[32] !== t3 || $[33] !== t4) {
|
|
288
|
+
t12 = _jsx(TouchableOpacity, {
|
|
289
|
+
accessibilityRole: "tab",
|
|
290
|
+
accessibilityState: t2,
|
|
291
|
+
activeOpacity: 0.7,
|
|
292
|
+
className: "flex-1 items-center justify-center rounded-lg py-2",
|
|
293
|
+
onPress: t3,
|
|
294
|
+
style: t4,
|
|
295
|
+
children: t11
|
|
296
|
+
});
|
|
297
|
+
$[30] = t11;
|
|
298
|
+
$[31] = t2;
|
|
299
|
+
$[32] = t3;
|
|
300
|
+
$[33] = t4;
|
|
301
|
+
$[34] = t12;
|
|
302
|
+
} else {
|
|
303
|
+
t12 = $[34];
|
|
304
|
+
}
|
|
305
|
+
return t12;
|
|
306
|
+
}
|
|
307
|
+
let t2;
|
|
308
|
+
if ($[35] !== selected) {
|
|
309
|
+
t2 = {
|
|
310
|
+
selected
|
|
311
|
+
};
|
|
312
|
+
$[35] = selected;
|
|
313
|
+
$[36] = t2;
|
|
314
|
+
} else {
|
|
315
|
+
t2 = $[36];
|
|
316
|
+
}
|
|
317
|
+
let t3;
|
|
318
|
+
if ($[37] !== setValue || $[38] !== value) {
|
|
319
|
+
t3 = () => setValue(value);
|
|
320
|
+
$[37] = setValue;
|
|
321
|
+
$[38] = value;
|
|
322
|
+
$[39] = t3;
|
|
323
|
+
} else {
|
|
324
|
+
t3 = $[39];
|
|
325
|
+
}
|
|
326
|
+
const t4 = iconLayout === "top" && icon ? "items-center gap-1" : "flex-row items-center gap-1.5";
|
|
327
|
+
let t5;
|
|
328
|
+
if ($[40] !== t4) {
|
|
329
|
+
t5 = cn("py-3", t4);
|
|
330
|
+
$[40] = t4;
|
|
331
|
+
$[41] = t5;
|
|
332
|
+
} else {
|
|
333
|
+
t5 = $[41];
|
|
334
|
+
}
|
|
335
|
+
let t6;
|
|
336
|
+
if ($[42] !== icon || $[43] !== iconColor || $[44] !== iconLayout) {
|
|
337
|
+
t6 = icon && iconLayout === "top" && _jsx(Icon, {
|
|
338
|
+
color: iconColor,
|
|
339
|
+
name: icon,
|
|
340
|
+
size: 18
|
|
341
|
+
});
|
|
342
|
+
$[42] = icon;
|
|
343
|
+
$[43] = iconColor;
|
|
344
|
+
$[44] = iconLayout;
|
|
345
|
+
$[45] = t6;
|
|
346
|
+
} else {
|
|
347
|
+
t6 = $[45];
|
|
348
|
+
}
|
|
349
|
+
let t7;
|
|
350
|
+
if ($[46] !== icon || $[47] !== iconColor || $[48] !== iconLayout) {
|
|
351
|
+
t7 = icon && iconLayout === "left" && _jsx(Icon, {
|
|
352
|
+
color: iconColor,
|
|
353
|
+
name: icon,
|
|
354
|
+
size: 14
|
|
355
|
+
});
|
|
356
|
+
$[46] = icon;
|
|
357
|
+
$[47] = iconColor;
|
|
358
|
+
$[48] = iconLayout;
|
|
359
|
+
$[49] = t7;
|
|
360
|
+
} else {
|
|
361
|
+
t7 = $[49];
|
|
362
|
+
}
|
|
363
|
+
let t8;
|
|
364
|
+
if ($[50] !== iconColor) {
|
|
365
|
+
t8 = {
|
|
366
|
+
color: iconColor
|
|
367
|
+
};
|
|
368
|
+
$[50] = iconColor;
|
|
369
|
+
$[51] = t8;
|
|
370
|
+
} else {
|
|
371
|
+
t8 = $[51];
|
|
372
|
+
}
|
|
373
|
+
let t9;
|
|
374
|
+
if ($[52] !== children || $[53] !== selected || $[54] !== t8) {
|
|
375
|
+
t9 = _jsx(Typography.Text, {
|
|
376
|
+
semibold: selected,
|
|
377
|
+
style: t8,
|
|
378
|
+
children: children
|
|
379
|
+
});
|
|
380
|
+
$[52] = children;
|
|
381
|
+
$[53] = selected;
|
|
382
|
+
$[54] = t8;
|
|
383
|
+
$[55] = t9;
|
|
384
|
+
} else {
|
|
385
|
+
t9 = $[55];
|
|
386
|
+
}
|
|
387
|
+
let t10;
|
|
388
|
+
if ($[56] !== t5 || $[57] !== t6 || $[58] !== t7 || $[59] !== t9) {
|
|
389
|
+
t10 = _jsxs(View, {
|
|
390
|
+
className: t5,
|
|
391
|
+
children: [t6, t7, t9]
|
|
392
|
+
});
|
|
393
|
+
$[56] = t5;
|
|
394
|
+
$[57] = t6;
|
|
395
|
+
$[58] = t7;
|
|
396
|
+
$[59] = t9;
|
|
397
|
+
$[60] = t10;
|
|
398
|
+
} else {
|
|
399
|
+
t10 = $[60];
|
|
400
|
+
}
|
|
401
|
+
const t11 = selected ? theme.primary : "transparent";
|
|
402
|
+
let t12;
|
|
403
|
+
if ($[61] !== t11) {
|
|
404
|
+
t12 = _jsx(View, {
|
|
405
|
+
className: "h-0.5 w-full",
|
|
406
|
+
style: {
|
|
407
|
+
backgroundColor: t11
|
|
408
|
+
}
|
|
409
|
+
});
|
|
410
|
+
$[61] = t11;
|
|
411
|
+
$[62] = t12;
|
|
412
|
+
} else {
|
|
413
|
+
t12 = $[62];
|
|
414
|
+
}
|
|
415
|
+
let t13;
|
|
416
|
+
if ($[63] !== t10 || $[64] !== t12 || $[65] !== t2 || $[66] !== t3) {
|
|
417
|
+
t13 = _jsxs(TouchableOpacity, {
|
|
418
|
+
accessibilityRole: "tab",
|
|
419
|
+
accessibilityState: t2,
|
|
420
|
+
activeOpacity: 0.7,
|
|
421
|
+
className: "flex-1 items-center",
|
|
422
|
+
onPress: t3,
|
|
423
|
+
children: [t10, t12]
|
|
424
|
+
});
|
|
425
|
+
$[63] = t10;
|
|
426
|
+
$[64] = t12;
|
|
427
|
+
$[65] = t2;
|
|
428
|
+
$[66] = t3;
|
|
429
|
+
$[67] = t13;
|
|
430
|
+
} else {
|
|
431
|
+
t13 = $[67];
|
|
432
|
+
}
|
|
433
|
+
return t13;
|
|
45
434
|
}
|
|
46
|
-
function TabsContent(
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
435
|
+
function TabsContent(t0) {
|
|
436
|
+
const $ = _c(2);
|
|
437
|
+
const {
|
|
438
|
+
value,
|
|
439
|
+
children
|
|
440
|
+
} = t0;
|
|
441
|
+
const {
|
|
442
|
+
value: active
|
|
443
|
+
} = useTabs();
|
|
444
|
+
if (active !== value) {
|
|
445
|
+
return null;
|
|
446
|
+
}
|
|
447
|
+
let t1;
|
|
448
|
+
if ($[0] !== children) {
|
|
449
|
+
t1 = _jsx(View, {
|
|
450
|
+
className: "flex-1",
|
|
451
|
+
children: children
|
|
452
|
+
});
|
|
453
|
+
$[0] = children;
|
|
454
|
+
$[1] = t1;
|
|
455
|
+
} else {
|
|
456
|
+
t1 = $[1];
|
|
457
|
+
}
|
|
458
|
+
return t1;
|
|
51
459
|
}
|
|
52
460
|
const Tabs = Object.assign(TabsRoot, {
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
461
|
+
List: TabsList,
|
|
462
|
+
Trigger: TabsTrigger,
|
|
463
|
+
Content: TabsContent
|
|
56
464
|
});
|
|
57
465
|
export default Tabs;
|
|
58
466
|
export { Tabs };
|
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
import BottomNav from "./Navigation.BottomNav.js";
|
|
2
|
-
import CollapsingHeader from "./Navigation.CollapsingHeader.js";
|
|
3
2
|
import FloatingBar from "./Navigation.FloatingBar.js";
|
|
4
3
|
import Menu from "./Navigation.Menu.js";
|
|
5
4
|
import { MenuSection } from "./Navigation.MenuSection.js";
|
|
6
|
-
import RowItem from "./Navigation.RowItem.js";
|
|
7
5
|
import SearchBar from "./Navigation.SearchBar.js";
|
|
8
6
|
import SearchSuggestions from "./Navigation.SearchSuggestions.js";
|
|
9
7
|
import SegmentedControl from "./Navigation.SegmentedControl.js";
|
|
@@ -18,7 +16,12 @@ export declare const Navigation: {
|
|
|
18
16
|
Action: ({ icon, label, onPress, badge, accessibilityLabel, tone, onDark, bare, testID, }: import("./Navigation.AppBar.js").AppBarActionProps) => import("react").JSX.Element;
|
|
19
17
|
};
|
|
20
18
|
BottomNav: typeof BottomNav;
|
|
21
|
-
CollapsingHeader:
|
|
19
|
+
CollapsingHeader: (({ title, subtitle, scrollY, onBack, actions, largeHeight, safeArea, testID, }: import("./Navigation.CollapsingHeader.js").CollapsingHeaderProps) => import("react").JSX.Element) & {
|
|
20
|
+
Root: ({ children }: {
|
|
21
|
+
children: import("react").ReactNode;
|
|
22
|
+
}) => import("react").JSX.Element;
|
|
23
|
+
ScrollView: (props: Omit<import("react-native").ScrollViewProps, "onScroll">) => import("react").JSX.Element;
|
|
24
|
+
};
|
|
22
25
|
FloatingBar: typeof FloatingBar;
|
|
23
26
|
SearchBar: typeof SearchBar;
|
|
24
27
|
Search: {
|
|
@@ -30,7 +33,9 @@ export declare const Navigation: {
|
|
|
30
33
|
Suggestions: (props: import("./Navigation.SearchSuggestions.js").SearchSuggestionsProps) => import("react").JSX.Element;
|
|
31
34
|
};
|
|
32
35
|
SearchSuggestions: typeof SearchSuggestions;
|
|
33
|
-
RowItem:
|
|
36
|
+
RowItem: import("react").MemoExoticComponent<({ item, className, onPress: onPressProp, readonly: readonlyProp, }: import("../views/types/IListView").IRowItemProps<any> & {
|
|
37
|
+
className?: string;
|
|
38
|
+
}) => import("react").JSX.Element>;
|
|
34
39
|
SegmentedControl: typeof SegmentedControl;
|
|
35
40
|
Tabs: (({ value, defaultValue, onValueChange, variant, className, children, }: import("./Navigation.Tabs.js").TabsProps) => import("react").JSX.Element) & {
|
|
36
41
|
List: ({ children, className }: {
|
package/dist/Navigation/index.js
CHANGED
|
@@ -12,18 +12,18 @@ import SegmentedControl from "./Navigation.SegmentedControl.js";
|
|
|
12
12
|
import Steps from "./Navigation.Steps.js";
|
|
13
13
|
import Tabs from "./Navigation.Tabs.js";
|
|
14
14
|
export const Navigation = {
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
15
|
+
AppBar,
|
|
16
|
+
BottomNav,
|
|
17
|
+
CollapsingHeader,
|
|
18
|
+
FloatingBar,
|
|
19
|
+
SearchBar,
|
|
20
|
+
Search,
|
|
21
|
+
SearchSuggestions,
|
|
22
|
+
RowItem,
|
|
23
|
+
SegmentedControl,
|
|
24
|
+
Tabs,
|
|
25
|
+
Menu,
|
|
26
|
+
MenuSection,
|
|
27
|
+
Steps
|
|
28
28
|
};
|
|
29
29
|
export default Navigation;
|
|
@@ -1,6 +1,36 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { c as _c } from "react/compiler-runtime";
|
|
2
2
|
import { AppText } from "./Typography.Text.js";
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
import { jsx as _jsx } from "nativewind/jsx-runtime";
|
|
4
|
+
const Heading = t0 => {
|
|
5
|
+
const $ = _c(6);
|
|
6
|
+
let props;
|
|
7
|
+
let t1;
|
|
8
|
+
if ($[0] !== t0) {
|
|
9
|
+
({
|
|
10
|
+
variant: t1,
|
|
11
|
+
...props
|
|
12
|
+
} = t0);
|
|
13
|
+
$[0] = t0;
|
|
14
|
+
$[1] = props;
|
|
15
|
+
$[2] = t1;
|
|
16
|
+
} else {
|
|
17
|
+
props = $[1];
|
|
18
|
+
t1 = $[2];
|
|
19
|
+
}
|
|
20
|
+
const variant = t1 === undefined ? "h1" : t1;
|
|
21
|
+
let t2;
|
|
22
|
+
if ($[3] !== props || $[4] !== variant) {
|
|
23
|
+
t2 = _jsx(AppText, {
|
|
24
|
+
accessibilityRole: "header",
|
|
25
|
+
variant: variant,
|
|
26
|
+
...props
|
|
27
|
+
});
|
|
28
|
+
$[3] = props;
|
|
29
|
+
$[4] = variant;
|
|
30
|
+
$[5] = t2;
|
|
31
|
+
} else {
|
|
32
|
+
t2 = $[5];
|
|
33
|
+
}
|
|
34
|
+
return t2;
|
|
5
35
|
};
|
|
6
36
|
export default Heading;
|