@sincpro/mobile-ui 0.1.2 → 0.1.4
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/lib/Dialog/BottomSheet/BottomSheet.Root.d.ts +320 -0
- package/lib/Dialog/BottomSheet/BottomSheet.Root.js +380 -0
- package/lib/Dialog/BottomSheet/index.d.ts +1 -0
- package/lib/Dialog/BottomSheet/index.js +1 -0
- package/lib/Dialog/Confirmation.context.d.ts +21 -0
- package/lib/Dialog/Confirmation.context.js +67 -0
- package/lib/Dialog/Dialog.Confirmation.d.ts +12 -0
- package/lib/Dialog/Dialog.Confirmation.js +9 -0
- package/lib/Dialog/Dialog.EditValue.d.ts +25 -0
- package/lib/Dialog/Dialog.EditValue.js +16 -0
- package/lib/Dialog/index.d.ts +19 -0
- package/lib/Dialog/index.js +11 -0
- package/lib/Display/Display.Avatar.d.ts +52 -0
- package/lib/Display/Display.Avatar.js +40 -0
- package/lib/Display/Display.Badge.d.ts +108 -0
- package/lib/Display/Display.Badge.js +54 -0
- package/lib/Display/Display.CopyableText.d.ts +13 -0
- package/lib/Display/Display.CopyableText.js +14 -0
- package/lib/Display/Display.CountRecords.d.ts +8 -0
- package/lib/Display/Display.CountRecords.js +8 -0
- package/lib/Display/Display.Date.d.ts +18 -0
- package/lib/Display/Display.Date.js +13 -0
- package/lib/Display/Display.Divider.d.ts +44 -0
- package/lib/Display/Display.Divider.js +27 -0
- package/lib/Display/Display.Icon.d.ts +15 -0
- package/lib/Display/Display.Icon.js +35 -0
- package/lib/Display/Display.Logo.d.ts +55 -0
- package/lib/Display/Display.Logo.js +36 -0
- package/lib/Display/Display.MenuButton.d.ts +103 -0
- package/lib/Display/Display.MenuButton.js +50 -0
- package/lib/Display/Display.Monetary.d.ts +19 -0
- package/lib/Display/Display.Monetary.js +9 -0
- package/lib/Display/index.d.ts +22 -0
- package/lib/Display/index.js +25 -0
- package/lib/Feedback/ErrorBoundary.d.ts +18 -0
- package/lib/Feedback/ErrorBoundary.js +28 -0
- package/lib/Feedback/Feedback.DomainSplashScreen.d.ts +10 -0
- package/lib/Feedback/Feedback.DomainSplashScreen.js +67 -0
- package/lib/Feedback/Feedback.Empty.d.ts +6 -0
- package/lib/Feedback/Feedback.Empty.js +9 -0
- package/lib/Feedback/Feedback.Error.d.ts +9 -0
- package/lib/Feedback/Feedback.Error.js +10 -0
- package/lib/Feedback/Feedback.Loading.d.ts +8 -0
- package/lib/Feedback/Feedback.Loading.js +8 -0
- package/lib/Feedback/Feedback.Spinner.d.ts +11 -0
- package/lib/Feedback/Feedback.Spinner.js +8 -0
- package/lib/Feedback/Feedback.Splash.d.ts +11 -0
- package/lib/Feedback/Feedback.Splash.js +37 -0
- package/lib/Feedback/index.d.ts +13 -0
- package/lib/Feedback/index.js +14 -0
- package/lib/Form/Form.Button.d.ts +145 -0
- package/lib/Form/Form.Button.js +272 -0
- package/lib/Form/Form.Checkbox.d.ts +13 -0
- package/lib/Form/Form.Checkbox.js +30 -0
- package/lib/Form/Form.ControlledCheckbox.d.ts +9 -0
- package/lib/Form/Form.ControlledCheckbox.js +7 -0
- package/lib/Form/Form.ControlledDropdown.d.ts +14 -0
- package/lib/Form/Form.ControlledDropdown.js +4 -0
- package/lib/Form/Form.ControlledInput.d.ts +15 -0
- package/lib/Form/Form.ControlledInput.js +7 -0
- package/lib/Form/Form.ControlledMonetaryInput.d.ts +12 -0
- package/lib/Form/Form.ControlledMonetaryInput.js +7 -0
- package/lib/Form/Form.ControlledRadioButton.d.ts +9 -0
- package/lib/Form/Form.ControlledRadioButton.js +7 -0
- package/lib/Form/Form.Dropdown.d.ts +14 -0
- package/lib/Form/Form.Dropdown.js +85 -0
- package/lib/Form/Form.FilterButton.d.ts +12 -0
- package/lib/Form/Form.FilterButton.js +34 -0
- package/lib/Form/Form.FractionalQuantityInput.d.ts +13 -0
- package/lib/Form/Form.FractionalQuantityInput.js +118 -0
- package/lib/Form/Form.IconButton.d.ts +67 -0
- package/lib/Form/Form.IconButton.js +64 -0
- package/lib/Form/Form.Input.d.ts +9 -0
- package/lib/Form/Form.Input.js +38 -0
- package/lib/Form/Form.InputField.d.ts +10 -0
- package/lib/Form/Form.InputField.js +38 -0
- package/lib/Form/Form.MonetaryInput.d.ts +8 -0
- package/lib/Form/Form.MonetaryInput.js +27 -0
- package/lib/Form/Form.PasswordInput.d.ts +9 -0
- package/lib/Form/Form.PasswordInput.js +15 -0
- package/lib/Form/Form.QuantitySelector.d.ts +10 -0
- package/lib/Form/Form.QuantitySelector.js +36 -0
- package/lib/Form/Form.RadioButton.d.ts +7 -0
- package/lib/Form/Form.RadioButton.js +31 -0
- package/lib/Form/Form.SearchBar.d.ts +8 -0
- package/lib/Form/Form.SearchBar.js +22 -0
- package/lib/Form/Form.TextInput.d.ts +8 -0
- package/lib/Form/Form.TextInput.js +8 -0
- package/lib/Form/index.d.ts +41 -0
- package/lib/Form/index.js +42 -0
- package/lib/Navigation/Navigation.Header.d.ts +12 -0
- package/lib/Navigation/Navigation.Header.js +12 -0
- package/lib/Navigation/Navigation.HeaderToolbar.d.ts +15 -0
- package/lib/Navigation/Navigation.HeaderToolbar.js +18 -0
- package/lib/Navigation/Navigation.RowItem.d.ts +5 -0
- package/lib/Navigation/Navigation.RowItem.js +11 -0
- package/lib/Navigation/Navigation.TabIcon.d.ts +14 -0
- package/lib/Navigation/Navigation.TabIcon.js +9 -0
- package/lib/Navigation/Navigation.TabItem.d.ts +14 -0
- package/lib/Navigation/Navigation.TabItem.js +8 -0
- package/lib/Navigation/index.d.ts +11 -0
- package/lib/Navigation/index.js +13 -0
- package/lib/Typography/Typography.Heading.d.ts +12 -0
- package/lib/Typography/Typography.Heading.js +6 -0
- package/lib/Typography/Typography.Text.d.ts +27 -0
- package/lib/Typography/Typography.Text.js +21 -0
- package/lib/Typography/index.d.ts +7 -0
- package/lib/Typography/index.js +8 -0
- package/lib/icons/AddItemIcon.d.ts +4 -0
- package/lib/icons/AddItemIcon.js +4 -0
- package/lib/icons/ArrangeCircle.d.ts +4 -0
- package/lib/icons/ArrangeCircle.js +4 -0
- package/lib/icons/ArrowDownIcon.d.ts +3 -0
- package/lib/icons/ArrowDownIcon.js +6 -0
- package/lib/icons/ArrowUpIcon.d.ts +3 -0
- package/lib/icons/ArrowUpIcon.js +6 -0
- package/lib/icons/BoxIcon.d.ts +4 -0
- package/lib/icons/BoxIcon.js +4 -0
- package/lib/icons/BoxTimeIcon.d.ts +4 -0
- package/lib/icons/BoxTimeIcon.js +4 -0
- package/lib/icons/CalendarIcon.d.ts +4 -0
- package/lib/icons/CalendarIcon.js +4 -0
- package/lib/icons/CardIcon.d.ts +4 -0
- package/lib/icons/CardIcon.js +4 -0
- package/lib/icons/CashierIcon.d.ts +4 -0
- package/lib/icons/CashierIcon.js +4 -0
- package/lib/icons/CreditIcon.d.ts +7 -0
- package/lib/icons/CreditIcon.js +6 -0
- package/lib/icons/DuoIcon.d.ts +4 -0
- package/lib/icons/DuoIcon.js +4 -0
- package/lib/icons/HomeIcon.d.ts +4 -0
- package/lib/icons/HomeIcon.js +4 -0
- package/lib/icons/HomeIconOutlined.d.ts +4 -0
- package/lib/icons/HomeIconOutlined.js +4 -0
- package/lib/icons/LogoIcon.d.ts +4 -0
- package/lib/icons/LogoIcon.js +4 -0
- package/lib/icons/MoneyReceiveIcon.d.ts +4 -0
- package/lib/icons/MoneyReceiveIcon.js +4 -0
- package/lib/icons/OdooIcon.d.ts +6 -0
- package/lib/icons/OdooIcon.js +6 -0
- package/lib/icons/PinIcon.d.ts +4 -0
- package/lib/icons/PinIcon.js +4 -0
- package/lib/icons/PrinterIcon.d.ts +4 -0
- package/lib/icons/PrinterIcon.js +4 -0
- package/lib/icons/ProfileIcon.d.ts +4 -0
- package/lib/icons/ProfileIcon.js +4 -0
- package/lib/icons/SettingsIcon.d.ts +4 -0
- package/lib/icons/SettingsIcon.js +4 -0
- package/lib/icons/SinpeIcon.d.ts +4 -0
- package/lib/icons/SinpeIcon.js +4 -0
- package/lib/icons/ToggleOffIcon.d.ts +4 -0
- package/lib/icons/ToggleOffIcon.js +4 -0
- package/lib/icons/WalletMoneyIcon.d.ts +4 -0
- package/lib/icons/WalletMoneyIcon.js +4 -0
- package/lib/icons/icon_getters.d.ts +6 -0
- package/lib/icons/icon_getters.js +23 -0
- package/lib/icons/props.d.ts +4 -0
- package/lib/icons/props.js +1 -0
- package/lib/index.d.ts +20 -0
- package/lib/index.js +26 -0
- package/lib/layouts/AuthContainer.d.ts +9 -0
- package/lib/layouts/AuthContainer.js +13 -0
- package/lib/layouts/Container.d.ts +14 -0
- package/lib/layouts/Container.js +9 -0
- package/lib/layouts/GradientContainer.d.ts +8 -0
- package/lib/layouts/GradientContainer.js +8 -0
- package/lib/layouts/PlainLayout.d.ts +6 -0
- package/lib/layouts/PlainLayout.js +8 -0
- package/lib/layouts/ScrollContainer.d.ts +8 -0
- package/lib/layouts/ScrollContainer.js +8 -0
- package/lib/layouts/TabNavigatorLayout.d.ts +26 -0
- package/lib/layouts/TabNavigatorLayout.js +56 -0
- package/lib/notifications/index.d.ts +1 -0
- package/lib/notifications/index.js +1 -0
- package/lib/primitives/BaseButton.d.ts +146 -0
- package/lib/primitives/BaseButton.js +233 -0
- package/lib/primitives/Box.d.ts +7 -0
- package/lib/primitives/Box.js +8 -0
- package/lib/primitives/Row.d.ts +11 -0
- package/lib/primitives/Row.js +22 -0
- package/lib/primitives/Stack.d.ts +9 -0
- package/lib/primitives/Stack.js +14 -0
- package/lib/primitives/index.d.ts +3 -0
- package/lib/primitives/index.js +3 -0
- package/lib/providers/index.d.ts +0 -0
- package/lib/providers/index.js +2 -0
- package/lib/tailwind.preset.js +146 -0
- package/lib/theme/active.d.ts +3 -0
- package/lib/theme/active.js +8 -0
- package/lib/theme/components/ThemedActivityIndicator.d.ts +21 -0
- package/lib/theme/components/ThemedActivityIndicator.js +5 -0
- package/lib/theme/components/index.d.ts +9 -0
- package/lib/theme/components/index.js +9 -0
- package/lib/theme/css-vars.d.ts +7 -0
- package/lib/theme/css-vars.js +64 -0
- package/lib/theme/default.d.ts +2 -0
- package/lib/theme/default.js +79 -0
- package/lib/theme/define.d.ts +18 -0
- package/lib/theme/define.js +34 -0
- package/lib/theme/index.d.ts +7 -0
- package/lib/theme/index.js +6 -0
- package/lib/theme/theme.d.ts +13 -0
- package/lib/theme/theme.js +14 -0
- package/lib/theme/tw.d.ts +10 -0
- package/lib/theme/tw.js +14 -0
- package/lib/theme/types.d.ts +92 -0
- package/lib/theme/types.js +9 -0
- package/lib/theme/typography.d.ts +376 -0
- package/lib/theme/typography.js +234 -0
- package/lib/theme/useTheme.d.ts +1 -0
- package/lib/theme/useTheme.js +2 -0
- package/lib/utils/date.d.ts +70 -0
- package/lib/utils/date.js +126 -0
- package/lib/utils/icon.d.ts +1 -0
- package/lib/utils/icon.js +1 -0
- package/lib/utils/monetary.d.ts +3 -0
- package/lib/utils/monetary.js +31 -0
- package/lib/utils/quantity.d.ts +11 -0
- package/lib/utils/quantity.js +44 -0
- package/lib/utils/serializer.d.ts +2 -0
- package/lib/utils/serializer.js +44 -0
- package/lib/utils/timezone.d.ts +4 -0
- package/lib/utils/timezone.js +1 -0
- package/lib/views/AuthFormView.d.ts +11 -0
- package/lib/views/AuthFormView.js +21 -0
- package/lib/views/FormViewV2.context.d.ts +32 -0
- package/lib/views/FormViewV2.context.js +28 -0
- package/lib/views/FormViewV2.d.ts +62 -0
- package/lib/views/FormViewV2.js +85 -0
- package/lib/views/ListViewV2.context.d.ts +36 -0
- package/lib/views/ListViewV2.context.js +30 -0
- package/lib/views/ListViewV2.d.ts +131 -0
- package/lib/views/ListViewV2.js +206 -0
- package/lib/views/Wizard/Wizard.context.d.ts +26 -0
- package/lib/views/Wizard/Wizard.context.js +92 -0
- package/lib/views/Wizard/Wizard.d.ts +33 -0
- package/lib/views/Wizard/Wizard.js +86 -0
- package/lib/views/Wizard/index.d.ts +4 -0
- package/lib/views/Wizard/index.js +2 -0
- package/lib/views/types/IFormView.d.ts +22 -0
- package/lib/views/types/IFormView.js +1 -0
- package/lib/views/types/IListView.d.ts +34 -0
- package/lib/views/types/IListView.js +35 -0
- package/lib/views/types/UIItem.d.ts +21 -0
- package/lib/views/types/UIItem.js +1 -0
- package/lib/widgets/CircleButton.d.ts +15 -0
- package/lib/widgets/CircleButton.js +37 -0
- package/lib/widgets/GeoPermissionCard.d.ts +8 -0
- package/lib/widgets/GeoPermissionCard.js +19 -0
- package/lib/widgets/HomeHeader.d.ts +11 -0
- package/lib/widgets/HomeHeader.js +9 -0
- package/lib/widgets/JSONViewer.d.ts +4 -0
- package/lib/widgets/JSONViewer.js +146 -0
- package/lib/widgets/MenuCard.d.ts +13 -0
- package/lib/widgets/MenuCard.js +8 -0
- package/lib/widgets/MenuGrid.d.ts +17 -0
- package/lib/widgets/MenuGrid.js +6 -0
- package/lib/widgets/ScreenHeader.d.ts +21 -0
- package/lib/widgets/ScreenHeader.js +21 -0
- package/lib/widgets/TimeZoneSelector.d.ts +7 -0
- package/lib/widgets/TimeZoneSelector.js +19 -0
- package/lib/widgets/TimeZoneSelectorModal.d.ts +9 -0
- package/lib/widgets/TimeZoneSelectorModal.js +57 -0
- package/lib/widgets/index.d.ts +7 -0
- package/lib/widgets/index.js +6 -0
- package/package.json +23 -211
- package/lib/module/Dialog/BottomSheet/BottomSheet.Root.js +0 -481
- package/lib/module/Dialog/BottomSheet/BottomSheet.Root.js.map +0 -1
- package/lib/module/Dialog/BottomSheet/index.js +0 -4
- package/lib/module/Dialog/BottomSheet/index.js.map +0 -1
- package/lib/module/Dialog/Confirmation.context.js +0 -108
- package/lib/module/Dialog/Confirmation.context.js.map +0 -1
- package/lib/module/Dialog/Dialog.Confirmation.js +0 -69
- package/lib/module/Dialog/Dialog.Confirmation.js.map +0 -1
- package/lib/module/Dialog/Dialog.EditValue.js +0 -115
- package/lib/module/Dialog/Dialog.EditValue.js.map +0 -1
- package/lib/module/Dialog/index.js +0 -14
- package/lib/module/Dialog/index.js.map +0 -1
- package/lib/module/Display/Display.Avatar.js +0 -58
- package/lib/module/Display/Display.Avatar.js.map +0 -1
- package/lib/module/Display/Display.Badge.js +0 -72
- package/lib/module/Display/Display.Badge.js.map +0 -1
- package/lib/module/Display/Display.CopyableText.js +0 -30
- package/lib/module/Display/Display.CopyableText.js.map +0 -1
- package/lib/module/Display/Display.CountRecords.js +0 -27
- package/lib/module/Display/Display.CountRecords.js.map +0 -1
- package/lib/module/Display/Display.Date.js +0 -35
- package/lib/module/Display/Display.Date.js.map +0 -1
- package/lib/module/Display/Display.Divider.js +0 -43
- package/lib/module/Display/Display.Divider.js.map +0 -1
- package/lib/module/Display/Display.Icon.js +0 -83
- package/lib/module/Display/Display.Icon.js.map +0 -1
- package/lib/module/Display/Display.Logo.js +0 -54
- package/lib/module/Display/Display.Logo.js.map +0 -1
- package/lib/module/Display/Display.MenuButton.js +0 -101
- package/lib/module/Display/Display.MenuButton.js.map +0 -1
- package/lib/module/Display/Display.Monetary.js +0 -36
- package/lib/module/Display/Display.Monetary.js.map +0 -1
- package/lib/module/Display/index.js +0 -28
- package/lib/module/Display/index.js.map +0 -1
- package/lib/module/Feedback/ErrorBoundary.js +0 -43
- package/lib/module/Feedback/ErrorBoundary.js.map +0 -1
- package/lib/module/Feedback/Feedback.DomainSplashScreen.js +0 -101
- package/lib/module/Feedback/Feedback.DomainSplashScreen.js.map +0 -1
- package/lib/module/Feedback/Feedback.Empty.js +0 -31
- package/lib/module/Feedback/Feedback.Empty.js.map +0 -1
- package/lib/module/Feedback/Feedback.Error.js +0 -53
- package/lib/module/Feedback/Feedback.Error.js.map +0 -1
- package/lib/module/Feedback/Feedback.Loading.js +0 -24
- package/lib/module/Feedback/Feedback.Loading.js.map +0 -1
- package/lib/module/Feedback/Feedback.Spinner.js +0 -28
- package/lib/module/Feedback/Feedback.Spinner.js.map +0 -1
- package/lib/module/Feedback/Feedback.Splash.js +0 -59
- package/lib/module/Feedback/Feedback.Splash.js.map +0 -1
- package/lib/module/Feedback/index.js +0 -17
- package/lib/module/Feedback/index.js.map +0 -1
- package/lib/module/Form/Form.Button.js +0 -442
- package/lib/module/Form/Form.Button.js.map +0 -1
- package/lib/module/Form/Form.Checkbox.js +0 -71
- package/lib/module/Form/Form.Checkbox.js.map +0 -1
- package/lib/module/Form/Form.ControlledCheckbox.js +0 -29
- package/lib/module/Form/Form.ControlledCheckbox.js.map +0 -1
- package/lib/module/Form/Form.ControlledDropdown.js +0 -7
- package/lib/module/Form/Form.ControlledDropdown.js.map +0 -1
- package/lib/module/Form/Form.ControlledInput.js +0 -43
- package/lib/module/Form/Form.ControlledInput.js.map +0 -1
- package/lib/module/Form/Form.ControlledMonetaryInput.js +0 -34
- package/lib/module/Form/Form.ControlledMonetaryInput.js.map +0 -1
- package/lib/module/Form/Form.ControlledRadioButton.js +0 -28
- package/lib/module/Form/Form.ControlledRadioButton.js.map +0 -1
- package/lib/module/Form/Form.Dropdown.js +0 -163
- package/lib/module/Form/Form.Dropdown.js.map +0 -1
- package/lib/module/Form/Form.FilterButton.js +0 -59
- package/lib/module/Form/Form.FilterButton.js.map +0 -1
- package/lib/module/Form/Form.FractionalQuantityInput.js +0 -166
- package/lib/module/Form/Form.FractionalQuantityInput.js.map +0 -1
- package/lib/module/Form/Form.IconButton.js +0 -97
- package/lib/module/Form/Form.IconButton.js.map +0 -1
- package/lib/module/Form/Form.Input.js +0 -77
- package/lib/module/Form/Form.Input.js.map +0 -1
- package/lib/module/Form/Form.InputField.js +0 -63
- package/lib/module/Form/Form.InputField.js.map +0 -1
- package/lib/module/Form/Form.MonetaryInput.js +0 -65
- package/lib/module/Form/Form.MonetaryInput.js.map +0 -1
- package/lib/module/Form/Form.PasswordInput.js +0 -37
- package/lib/module/Form/Form.PasswordInput.js.map +0 -1
- package/lib/module/Form/Form.QuantitySelector.js +0 -78
- package/lib/module/Form/Form.QuantitySelector.js.map +0 -1
- package/lib/module/Form/Form.RadioButton.js +0 -56
- package/lib/module/Form/Form.RadioButton.js.map +0 -1
- package/lib/module/Form/Form.SearchBar.js +0 -63
- package/lib/module/Form/Form.SearchBar.js.map +0 -1
- package/lib/module/Form/Form.TextInput.js +0 -19
- package/lib/module/Form/Form.TextInput.js.map +0 -1
- package/lib/module/Form/index.js +0 -45
- package/lib/module/Form/index.js.map +0 -1
- package/lib/module/Navigation/Navigation.Header.js +0 -46
- package/lib/module/Navigation/Navigation.Header.js.map +0 -1
- package/lib/module/Navigation/Navigation.HeaderToolbar.js +0 -79
- package/lib/module/Navigation/Navigation.HeaderToolbar.js.map +0 -1
- package/lib/module/Navigation/Navigation.RowItem.js +0 -35
- package/lib/module/Navigation/Navigation.RowItem.js.map +0 -1
- package/lib/module/Navigation/Navigation.TabIcon.js +0 -28
- package/lib/module/Navigation/Navigation.TabIcon.js.map +0 -1
- package/lib/module/Navigation/Navigation.TabItem.js +0 -27
- package/lib/module/Navigation/Navigation.TabItem.js.map +0 -1
- package/lib/module/Navigation/index.js +0 -16
- package/lib/module/Navigation/index.js.map +0 -1
- package/lib/module/Typography/Typography.Heading.js +0 -15
- package/lib/module/Typography/Typography.Heading.js.map +0 -1
- package/lib/module/Typography/Typography.Text.js +0 -51
- package/lib/module/Typography/Typography.Text.js.map +0 -1
- package/lib/module/Typography/index.js +0 -11
- package/lib/module/Typography/index.js.map +0 -1
- package/lib/module/icons/AddItemIcon.js +0 -53
- package/lib/module/icons/AddItemIcon.js.map +0 -1
- package/lib/module/icons/ArrangeCircle.js +0 -50
- package/lib/module/icons/ArrangeCircle.js.map +0 -1
- package/lib/module/icons/ArrowDownIcon.js +0 -37
- package/lib/module/icons/ArrowDownIcon.js.map +0 -1
- package/lib/module/icons/ArrowUpIcon.js +0 -37
- package/lib/module/icons/ArrowUpIcon.js.map +0 -1
- package/lib/module/icons/BoxIcon.js +0 -35
- package/lib/module/icons/BoxIcon.js.map +0 -1
- package/lib/module/icons/BoxTimeIcon.js +0 -29
- package/lib/module/icons/BoxTimeIcon.js.map +0 -1
- package/lib/module/icons/CalendarIcon.js +0 -81
- package/lib/module/icons/CalendarIcon.js.map +0 -1
- package/lib/module/icons/CardIcon.js +0 -46
- package/lib/module/icons/CardIcon.js.map +0 -1
- package/lib/module/icons/CashierIcon.js +0 -20
- package/lib/module/icons/CashierIcon.js.map +0 -1
- package/lib/module/icons/CreditIcon.js +0 -43
- package/lib/module/icons/CreditIcon.js.map +0 -1
- package/lib/module/icons/DuoIcon.js +0 -41
- package/lib/module/icons/DuoIcon.js.map +0 -1
- package/lib/module/icons/HomeIcon.js +0 -20
- package/lib/module/icons/HomeIcon.js.map +0 -1
- package/lib/module/icons/HomeIconOutlined.js +0 -29
- package/lib/module/icons/HomeIconOutlined.js.map +0 -1
- package/lib/module/icons/LogoIcon.js +0 -38
- package/lib/module/icons/LogoIcon.js.map +0 -1
- package/lib/module/icons/MoneyReceiveIcon.js +0 -47
- package/lib/module/icons/MoneyReceiveIcon.js.map +0 -1
- package/lib/module/icons/OdooIcon.js +0 -24
- package/lib/module/icons/OdooIcon.js.map +0 -1
- package/lib/module/icons/PinIcon.js +0 -20
- package/lib/module/icons/PinIcon.js.map +0 -1
- package/lib/module/icons/PrinterIcon.js +0 -48
- package/lib/module/icons/PrinterIcon.js.map +0 -1
- package/lib/module/icons/ProfileIcon.js +0 -23
- package/lib/module/icons/ProfileIcon.js.map +0 -1
- package/lib/module/icons/SettingsIcon.js +0 -65
- package/lib/module/icons/SettingsIcon.js.map +0 -1
- package/lib/module/icons/SinpeIcon.js +0 -37
- package/lib/module/icons/SinpeIcon.js.map +0 -1
- package/lib/module/icons/ToggleOffIcon.js +0 -29
- package/lib/module/icons/ToggleOffIcon.js.map +0 -1
- package/lib/module/icons/WalletMoneyIcon.js +0 -42
- package/lib/module/icons/WalletMoneyIcon.js.map +0 -1
- package/lib/module/icons/icon_getters.js +0 -53
- package/lib/module/icons/icon_getters.js.map +0 -1
- package/lib/module/icons/props.js +0 -2
- package/lib/module/icons/props.js.map +0 -1
- package/lib/module/index.js +0 -34
- package/lib/module/index.js.map +0 -1
- package/lib/module/layouts/AuthContainer.js +0 -66
- package/lib/module/layouts/AuthContainer.js.map +0 -1
- package/lib/module/layouts/Container.js +0 -31
- package/lib/module/layouts/Container.js.map +0 -1
- package/lib/module/layouts/GradientContainer.js +0 -20
- package/lib/module/layouts/GradientContainer.js.map +0 -1
- package/lib/module/layouts/PlainLayout.js +0 -16
- package/lib/module/layouts/PlainLayout.js.map +0 -1
- package/lib/module/layouts/ScrollContainer.js +0 -37
- package/lib/module/layouts/ScrollContainer.js.map +0 -1
- package/lib/module/layouts/TabNavigatorLayout.js +0 -132
- package/lib/module/layouts/TabNavigatorLayout.js.map +0 -1
- package/lib/module/lib/date.js +0 -127
- package/lib/module/lib/date.js.map +0 -1
- package/lib/module/lib/icon.js +0 -2
- package/lib/module/lib/icon.js.map +0 -1
- package/lib/module/lib/monetary.js +0 -31
- package/lib/module/lib/monetary.js.map +0 -1
- package/lib/module/lib/quantity.js +0 -46
- package/lib/module/lib/quantity.js.map +0 -1
- package/lib/module/lib/serializer.js +0 -47
- package/lib/module/lib/serializer.js.map +0 -1
- package/lib/module/lib/timezone.js +0 -2
- package/lib/module/lib/timezone.js.map +0 -1
- package/lib/module/nativewind-env.d.js +0 -3
- package/lib/module/nativewind-env.d.js.map +0 -1
- package/lib/module/notifications/index.js +0 -5
- package/lib/module/notifications/index.js.map +0 -1
- package/lib/module/package.json +0 -1
- package/lib/module/primitives/BaseButton.js +0 -391
- package/lib/module/primitives/BaseButton.js.map +0 -1
- package/lib/module/primitives/Box.js +0 -19
- package/lib/module/primitives/Box.js.map +0 -1
- package/lib/module/primitives/Row.js +0 -37
- package/lib/module/primitives/Row.js.map +0 -1
- package/lib/module/primitives/Stack.js +0 -27
- package/lib/module/primitives/Stack.js.map +0 -1
- package/lib/module/primitives/index.js +0 -6
- package/lib/module/primitives/index.js.map +0 -1
- package/lib/module/providers/index.js +0 -3
- package/lib/module/providers/index.js.map +0 -1
- package/lib/module/theme/active.js +0 -13
- package/lib/module/theme/active.js.map +0 -1
- package/lib/module/theme/components/ThemedActivityIndicator.js +0 -30
- package/lib/module/theme/components/ThemedActivityIndicator.js.map +0 -1
- package/lib/module/theme/components/index.js +0 -13
- package/lib/module/theme/components/index.js.map +0 -1
- package/lib/module/theme/default.js +0 -91
- package/lib/module/theme/default.js.map +0 -1
- package/lib/module/theme/index.js +0 -6
- package/lib/module/theme/index.js.map +0 -1
- package/lib/module/theme/theme.js +0 -18
- package/lib/module/theme/theme.js.map +0 -1
- package/lib/module/theme/tw.js +0 -19
- package/lib/module/theme/tw.js.map +0 -1
- package/lib/module/theme/types.js +0 -2
- package/lib/module/theme/types.js.map +0 -1
- package/lib/module/theme/typography.js +0 -246
- package/lib/module/theme/typography.js.map +0 -1
- package/lib/module/theme/useTheme.js +0 -5
- package/lib/module/theme/useTheme.js.map +0 -1
- package/lib/module/views/AuthFormView.js +0 -46
- package/lib/module/views/AuthFormView.js.map +0 -1
- package/lib/module/views/FormViewV2.context.js +0 -47
- package/lib/module/views/FormViewV2.context.js.map +0 -1
- package/lib/module/views/FormViewV2.js +0 -220
- package/lib/module/views/FormViewV2.js.map +0 -1
- package/lib/module/views/ListViewV2.context.js +0 -51
- package/lib/module/views/ListViewV2.context.js.map +0 -1
- package/lib/module/views/ListViewV2.js +0 -503
- package/lib/module/views/ListViewV2.js.map +0 -1
- package/lib/module/views/Wizard/Wizard.context.js +0 -111
- package/lib/module/views/Wizard/Wizard.context.js.map +0 -1
- package/lib/module/views/Wizard/Wizard.js +0 -125
- package/lib/module/views/Wizard/Wizard.js.map +0 -1
- package/lib/module/views/Wizard/index.js +0 -5
- package/lib/module/views/Wizard/index.js.map +0 -1
- package/lib/module/views/types/IFormView.js +0 -4
- package/lib/module/views/types/IFormView.js.map +0 -1
- package/lib/module/views/types/IListView.js +0 -40
- package/lib/module/views/types/IListView.js.map +0 -1
- package/lib/module/views/types/UIItem.js +0 -2
- package/lib/module/views/types/UIItem.js.map +0 -1
- package/lib/module/widgets/CircleButton.js +0 -70
- package/lib/module/widgets/CircleButton.js.map +0 -1
- package/lib/module/widgets/GeoPermissionCard.js +0 -55
- package/lib/module/widgets/GeoPermissionCard.js.map +0 -1
- package/lib/module/widgets/HomeHeader.js +0 -42
- package/lib/module/widgets/HomeHeader.js.map +0 -1
- package/lib/module/widgets/JSONViewer.js +0 -196
- package/lib/module/widgets/JSONViewer.js.map +0 -1
- package/lib/module/widgets/MenuCard.js +0 -32
- package/lib/module/widgets/MenuCard.js.map +0 -1
- package/lib/module/widgets/MenuGrid.js +0 -20
- package/lib/module/widgets/MenuGrid.js.map +0 -1
- package/lib/module/widgets/ScreenHeader.js +0 -63
- package/lib/module/widgets/ScreenHeader.js.map +0 -1
- package/lib/module/widgets/TimeZoneSelector.js +0 -73
- package/lib/module/widgets/TimeZoneSelector.js.map +0 -1
- package/lib/module/widgets/TimeZoneSelectorModal.js +0 -187
- package/lib/module/widgets/TimeZoneSelectorModal.js.map +0 -1
- package/lib/module/widgets/index.js +0 -9
- package/lib/module/widgets/index.js.map +0 -1
- package/lib/typescript/Dialog/BottomSheet/BottomSheet.Root.d.ts +0 -321
- package/lib/typescript/Dialog/BottomSheet/BottomSheet.Root.d.ts.map +0 -1
- package/lib/typescript/Dialog/BottomSheet/index.d.ts +0 -2
- package/lib/typescript/Dialog/BottomSheet/index.d.ts.map +0 -1
- package/lib/typescript/Dialog/Confirmation.context.d.ts +0 -22
- package/lib/typescript/Dialog/Confirmation.context.d.ts.map +0 -1
- package/lib/typescript/Dialog/Dialog.Confirmation.d.ts +0 -13
- package/lib/typescript/Dialog/Dialog.Confirmation.d.ts.map +0 -1
- package/lib/typescript/Dialog/Dialog.EditValue.d.ts +0 -26
- package/lib/typescript/Dialog/Dialog.EditValue.d.ts.map +0 -1
- package/lib/typescript/Dialog/index.d.ts +0 -20
- package/lib/typescript/Dialog/index.d.ts.map +0 -1
- package/lib/typescript/Display/Display.Avatar.d.ts +0 -53
- package/lib/typescript/Display/Display.Avatar.d.ts.map +0 -1
- package/lib/typescript/Display/Display.Badge.d.ts +0 -109
- package/lib/typescript/Display/Display.Badge.d.ts.map +0 -1
- package/lib/typescript/Display/Display.CopyableText.d.ts +0 -14
- package/lib/typescript/Display/Display.CopyableText.d.ts.map +0 -1
- package/lib/typescript/Display/Display.CountRecords.d.ts +0 -9
- package/lib/typescript/Display/Display.CountRecords.d.ts.map +0 -1
- package/lib/typescript/Display/Display.Date.d.ts +0 -19
- package/lib/typescript/Display/Display.Date.d.ts.map +0 -1
- package/lib/typescript/Display/Display.Divider.d.ts +0 -45
- package/lib/typescript/Display/Display.Divider.d.ts.map +0 -1
- package/lib/typescript/Display/Display.Icon.d.ts +0 -16
- package/lib/typescript/Display/Display.Icon.d.ts.map +0 -1
- package/lib/typescript/Display/Display.Logo.d.ts +0 -56
- package/lib/typescript/Display/Display.Logo.d.ts.map +0 -1
- package/lib/typescript/Display/Display.MenuButton.d.ts +0 -104
- package/lib/typescript/Display/Display.MenuButton.d.ts.map +0 -1
- package/lib/typescript/Display/Display.Monetary.d.ts +0 -20
- package/lib/typescript/Display/Display.Monetary.d.ts.map +0 -1
- package/lib/typescript/Display/index.d.ts +0 -23
- package/lib/typescript/Display/index.d.ts.map +0 -1
- package/lib/typescript/Feedback/ErrorBoundary.d.ts +0 -19
- package/lib/typescript/Feedback/ErrorBoundary.d.ts.map +0 -1
- package/lib/typescript/Feedback/Feedback.DomainSplashScreen.d.ts +0 -12
- package/lib/typescript/Feedback/Feedback.DomainSplashScreen.d.ts.map +0 -1
- package/lib/typescript/Feedback/Feedback.Empty.d.ts +0 -7
- package/lib/typescript/Feedback/Feedback.Empty.d.ts.map +0 -1
- package/lib/typescript/Feedback/Feedback.Error.d.ts +0 -10
- package/lib/typescript/Feedback/Feedback.Error.d.ts.map +0 -1
- package/lib/typescript/Feedback/Feedback.Loading.d.ts +0 -10
- package/lib/typescript/Feedback/Feedback.Loading.d.ts.map +0 -1
- package/lib/typescript/Feedback/Feedback.Spinner.d.ts +0 -12
- package/lib/typescript/Feedback/Feedback.Spinner.d.ts.map +0 -1
- package/lib/typescript/Feedback/Feedback.Splash.d.ts +0 -12
- package/lib/typescript/Feedback/Feedback.Splash.d.ts.map +0 -1
- package/lib/typescript/Feedback/index.d.ts +0 -14
- package/lib/typescript/Feedback/index.d.ts.map +0 -1
- package/lib/typescript/Form/Form.Button.d.ts +0 -146
- package/lib/typescript/Form/Form.Button.d.ts.map +0 -1
- package/lib/typescript/Form/Form.Checkbox.d.ts +0 -14
- package/lib/typescript/Form/Form.Checkbox.d.ts.map +0 -1
- package/lib/typescript/Form/Form.ControlledCheckbox.d.ts +0 -10
- package/lib/typescript/Form/Form.ControlledCheckbox.d.ts.map +0 -1
- package/lib/typescript/Form/Form.ControlledDropdown.d.ts +0 -15
- package/lib/typescript/Form/Form.ControlledDropdown.d.ts.map +0 -1
- package/lib/typescript/Form/Form.ControlledInput.d.ts +0 -16
- package/lib/typescript/Form/Form.ControlledInput.d.ts.map +0 -1
- package/lib/typescript/Form/Form.ControlledMonetaryInput.d.ts +0 -13
- package/lib/typescript/Form/Form.ControlledMonetaryInput.d.ts.map +0 -1
- package/lib/typescript/Form/Form.ControlledRadioButton.d.ts +0 -10
- package/lib/typescript/Form/Form.ControlledRadioButton.d.ts.map +0 -1
- package/lib/typescript/Form/Form.Dropdown.d.ts +0 -15
- package/lib/typescript/Form/Form.Dropdown.d.ts.map +0 -1
- package/lib/typescript/Form/Form.FilterButton.d.ts +0 -13
- package/lib/typescript/Form/Form.FilterButton.d.ts.map +0 -1
- package/lib/typescript/Form/Form.FractionalQuantityInput.d.ts +0 -14
- package/lib/typescript/Form/Form.FractionalQuantityInput.d.ts.map +0 -1
- package/lib/typescript/Form/Form.IconButton.d.ts +0 -68
- package/lib/typescript/Form/Form.IconButton.d.ts.map +0 -1
- package/lib/typescript/Form/Form.Input.d.ts +0 -11
- package/lib/typescript/Form/Form.Input.d.ts.map +0 -1
- package/lib/typescript/Form/Form.InputField.d.ts +0 -11
- package/lib/typescript/Form/Form.InputField.d.ts.map +0 -1
- package/lib/typescript/Form/Form.MonetaryInput.d.ts +0 -9
- package/lib/typescript/Form/Form.MonetaryInput.d.ts.map +0 -1
- package/lib/typescript/Form/Form.PasswordInput.d.ts +0 -10
- package/lib/typescript/Form/Form.PasswordInput.d.ts.map +0 -1
- package/lib/typescript/Form/Form.QuantitySelector.d.ts +0 -12
- package/lib/typescript/Form/Form.QuantitySelector.d.ts.map +0 -1
- package/lib/typescript/Form/Form.RadioButton.d.ts +0 -8
- package/lib/typescript/Form/Form.RadioButton.d.ts.map +0 -1
- package/lib/typescript/Form/Form.SearchBar.d.ts +0 -10
- package/lib/typescript/Form/Form.SearchBar.d.ts.map +0 -1
- package/lib/typescript/Form/Form.TextInput.d.ts +0 -9
- package/lib/typescript/Form/Form.TextInput.d.ts.map +0 -1
- package/lib/typescript/Form/index.d.ts +0 -42
- package/lib/typescript/Form/index.d.ts.map +0 -1
- package/lib/typescript/Navigation/Navigation.Header.d.ts +0 -11
- package/lib/typescript/Navigation/Navigation.Header.d.ts.map +0 -1
- package/lib/typescript/Navigation/Navigation.HeaderToolbar.d.ts +0 -16
- package/lib/typescript/Navigation/Navigation.HeaderToolbar.d.ts.map +0 -1
- package/lib/typescript/Navigation/Navigation.RowItem.d.ts +0 -6
- package/lib/typescript/Navigation/Navigation.RowItem.d.ts.map +0 -1
- package/lib/typescript/Navigation/Navigation.TabIcon.d.ts +0 -15
- package/lib/typescript/Navigation/Navigation.TabIcon.d.ts.map +0 -1
- package/lib/typescript/Navigation/Navigation.TabItem.d.ts +0 -15
- package/lib/typescript/Navigation/Navigation.TabItem.d.ts.map +0 -1
- package/lib/typescript/Navigation/index.d.ts +0 -12
- package/lib/typescript/Navigation/index.d.ts.map +0 -1
- package/lib/typescript/Typography/Typography.Heading.d.ts +0 -13
- package/lib/typescript/Typography/Typography.Heading.d.ts.map +0 -1
- package/lib/typescript/Typography/Typography.Text.d.ts +0 -29
- package/lib/typescript/Typography/Typography.Text.d.ts.map +0 -1
- package/lib/typescript/Typography/index.d.ts +0 -8
- package/lib/typescript/Typography/index.d.ts.map +0 -1
- package/lib/typescript/icons/AddItemIcon.d.ts +0 -5
- package/lib/typescript/icons/AddItemIcon.d.ts.map +0 -1
- package/lib/typescript/icons/ArrangeCircle.d.ts +0 -5
- package/lib/typescript/icons/ArrangeCircle.d.ts.map +0 -1
- package/lib/typescript/icons/ArrowDownIcon.d.ts +0 -5
- package/lib/typescript/icons/ArrowDownIcon.d.ts.map +0 -1
- package/lib/typescript/icons/ArrowUpIcon.d.ts +0 -5
- package/lib/typescript/icons/ArrowUpIcon.d.ts.map +0 -1
- package/lib/typescript/icons/BoxIcon.d.ts +0 -5
- package/lib/typescript/icons/BoxIcon.d.ts.map +0 -1
- package/lib/typescript/icons/BoxTimeIcon.d.ts +0 -5
- package/lib/typescript/icons/BoxTimeIcon.d.ts.map +0 -1
- package/lib/typescript/icons/CalendarIcon.d.ts +0 -5
- package/lib/typescript/icons/CalendarIcon.d.ts.map +0 -1
- package/lib/typescript/icons/CardIcon.d.ts +0 -5
- package/lib/typescript/icons/CardIcon.d.ts.map +0 -1
- package/lib/typescript/icons/CashierIcon.d.ts +0 -5
- package/lib/typescript/icons/CashierIcon.d.ts.map +0 -1
- package/lib/typescript/icons/CreditIcon.d.ts +0 -8
- package/lib/typescript/icons/CreditIcon.d.ts.map +0 -1
- package/lib/typescript/icons/DuoIcon.d.ts +0 -5
- package/lib/typescript/icons/DuoIcon.d.ts.map +0 -1
- package/lib/typescript/icons/HomeIcon.d.ts +0 -5
- package/lib/typescript/icons/HomeIcon.d.ts.map +0 -1
- package/lib/typescript/icons/HomeIconOutlined.d.ts +0 -5
- package/lib/typescript/icons/HomeIconOutlined.d.ts.map +0 -1
- package/lib/typescript/icons/LogoIcon.d.ts +0 -5
- package/lib/typescript/icons/LogoIcon.d.ts.map +0 -1
- package/lib/typescript/icons/MoneyReceiveIcon.d.ts +0 -5
- package/lib/typescript/icons/MoneyReceiveIcon.d.ts.map +0 -1
- package/lib/typescript/icons/OdooIcon.d.ts +0 -7
- package/lib/typescript/icons/OdooIcon.d.ts.map +0 -1
- package/lib/typescript/icons/PinIcon.d.ts +0 -5
- package/lib/typescript/icons/PinIcon.d.ts.map +0 -1
- package/lib/typescript/icons/PrinterIcon.d.ts +0 -5
- package/lib/typescript/icons/PrinterIcon.d.ts.map +0 -1
- package/lib/typescript/icons/ProfileIcon.d.ts +0 -5
- package/lib/typescript/icons/ProfileIcon.d.ts.map +0 -1
- package/lib/typescript/icons/SettingsIcon.d.ts +0 -5
- package/lib/typescript/icons/SettingsIcon.d.ts.map +0 -1
- package/lib/typescript/icons/SinpeIcon.d.ts +0 -5
- package/lib/typescript/icons/SinpeIcon.d.ts.map +0 -1
- package/lib/typescript/icons/ToggleOffIcon.d.ts +0 -5
- package/lib/typescript/icons/ToggleOffIcon.d.ts.map +0 -1
- package/lib/typescript/icons/WalletMoneyIcon.d.ts +0 -5
- package/lib/typescript/icons/WalletMoneyIcon.d.ts.map +0 -1
- package/lib/typescript/icons/icon_getters.d.ts +0 -7
- package/lib/typescript/icons/icon_getters.d.ts.map +0 -1
- package/lib/typescript/icons/props.d.ts +0 -5
- package/lib/typescript/icons/props.d.ts.map +0 -1
- package/lib/typescript/index.d.ts +0 -21
- package/lib/typescript/index.d.ts.map +0 -1
- package/lib/typescript/layouts/AuthContainer.d.ts +0 -10
- package/lib/typescript/layouts/AuthContainer.d.ts.map +0 -1
- package/lib/typescript/layouts/Container.d.ts +0 -15
- package/lib/typescript/layouts/Container.d.ts.map +0 -1
- package/lib/typescript/layouts/GradientContainer.d.ts +0 -9
- package/lib/typescript/layouts/GradientContainer.d.ts.map +0 -1
- package/lib/typescript/layouts/PlainLayout.d.ts +0 -7
- package/lib/typescript/layouts/PlainLayout.d.ts.map +0 -1
- package/lib/typescript/layouts/ScrollContainer.d.ts +0 -9
- package/lib/typescript/layouts/ScrollContainer.d.ts.map +0 -1
- package/lib/typescript/layouts/TabNavigatorLayout.d.ts +0 -27
- package/lib/typescript/layouts/TabNavigatorLayout.d.ts.map +0 -1
- package/lib/typescript/lib/date.d.ts +0 -71
- package/lib/typescript/lib/date.d.ts.map +0 -1
- package/lib/typescript/lib/icon.d.ts +0 -2
- package/lib/typescript/lib/icon.d.ts.map +0 -1
- package/lib/typescript/lib/monetary.d.ts +0 -4
- package/lib/typescript/lib/monetary.d.ts.map +0 -1
- package/lib/typescript/lib/quantity.d.ts +0 -12
- package/lib/typescript/lib/quantity.d.ts.map +0 -1
- package/lib/typescript/lib/serializer.d.ts +0 -3
- package/lib/typescript/lib/serializer.d.ts.map +0 -1
- package/lib/typescript/lib/timezone.d.ts +0 -5
- package/lib/typescript/lib/timezone.d.ts.map +0 -1
- package/lib/typescript/notifications/index.d.ts +0 -2
- package/lib/typescript/notifications/index.d.ts.map +0 -1
- package/lib/typescript/package.json +0 -1
- package/lib/typescript/primitives/BaseButton.d.ts +0 -147
- package/lib/typescript/primitives/BaseButton.d.ts.map +0 -1
- package/lib/typescript/primitives/Box.d.ts +0 -8
- package/lib/typescript/primitives/Box.d.ts.map +0 -1
- package/lib/typescript/primitives/Row.d.ts +0 -12
- package/lib/typescript/primitives/Row.d.ts.map +0 -1
- package/lib/typescript/primitives/Stack.d.ts +0 -10
- package/lib/typescript/primitives/Stack.d.ts.map +0 -1
- package/lib/typescript/primitives/index.d.ts +0 -4
- package/lib/typescript/primitives/index.d.ts.map +0 -1
- package/lib/typescript/providers/index.d.ts +0 -1
- package/lib/typescript/providers/index.d.ts.map +0 -1
- package/lib/typescript/theme/active.d.ts +0 -4
- package/lib/typescript/theme/active.d.ts.map +0 -1
- package/lib/typescript/theme/components/ThemedActivityIndicator.d.ts +0 -22
- package/lib/typescript/theme/components/ThemedActivityIndicator.d.ts.map +0 -1
- package/lib/typescript/theme/components/index.d.ts +0 -10
- package/lib/typescript/theme/components/index.d.ts.map +0 -1
- package/lib/typescript/theme/default.d.ts +0 -3
- package/lib/typescript/theme/default.d.ts.map +0 -1
- package/lib/typescript/theme/index.d.ts +0 -5
- package/lib/typescript/theme/index.d.ts.map +0 -1
- package/lib/typescript/theme/theme.d.ts +0 -14
- package/lib/typescript/theme/theme.d.ts.map +0 -1
- package/lib/typescript/theme/tw.d.ts +0 -11
- package/lib/typescript/theme/tw.d.ts.map +0 -1
- package/lib/typescript/theme/types.d.ts +0 -93
- package/lib/typescript/theme/types.d.ts.map +0 -1
- package/lib/typescript/theme/typography.d.ts +0 -377
- package/lib/typescript/theme/typography.d.ts.map +0 -1
- package/lib/typescript/theme/useTheme.d.ts +0 -2
- package/lib/typescript/theme/useTheme.d.ts.map +0 -1
- package/lib/typescript/views/AuthFormView.d.ts +0 -10
- package/lib/typescript/views/AuthFormView.d.ts.map +0 -1
- package/lib/typescript/views/FormViewV2.context.d.ts +0 -33
- package/lib/typescript/views/FormViewV2.context.d.ts.map +0 -1
- package/lib/typescript/views/FormViewV2.d.ts +0 -61
- package/lib/typescript/views/FormViewV2.d.ts.map +0 -1
- package/lib/typescript/views/ListViewV2.context.d.ts +0 -37
- package/lib/typescript/views/ListViewV2.context.d.ts.map +0 -1
- package/lib/typescript/views/ListViewV2.d.ts +0 -132
- package/lib/typescript/views/ListViewV2.d.ts.map +0 -1
- package/lib/typescript/views/Wizard/Wizard.context.d.ts +0 -27
- package/lib/typescript/views/Wizard/Wizard.context.d.ts.map +0 -1
- package/lib/typescript/views/Wizard/Wizard.d.ts +0 -34
- package/lib/typescript/views/Wizard/Wizard.d.ts.map +0 -1
- package/lib/typescript/views/Wizard/index.d.ts +0 -5
- package/lib/typescript/views/Wizard/index.d.ts.map +0 -1
- package/lib/typescript/views/types/IFormView.d.ts +0 -23
- package/lib/typescript/views/types/IFormView.d.ts.map +0 -1
- package/lib/typescript/views/types/IListView.d.ts +0 -35
- package/lib/typescript/views/types/IListView.d.ts.map +0 -1
- package/lib/typescript/views/types/UIItem.d.ts +0 -22
- package/lib/typescript/views/types/UIItem.d.ts.map +0 -1
- package/lib/typescript/widgets/CircleButton.d.ts +0 -16
- package/lib/typescript/widgets/CircleButton.d.ts.map +0 -1
- package/lib/typescript/widgets/GeoPermissionCard.d.ts +0 -9
- package/lib/typescript/widgets/GeoPermissionCard.d.ts.map +0 -1
- package/lib/typescript/widgets/HomeHeader.d.ts +0 -10
- package/lib/typescript/widgets/HomeHeader.d.ts.map +0 -1
- package/lib/typescript/widgets/JSONViewer.d.ts +0 -6
- package/lib/typescript/widgets/JSONViewer.d.ts.map +0 -1
- package/lib/typescript/widgets/MenuCard.d.ts +0 -14
- package/lib/typescript/widgets/MenuCard.d.ts.map +0 -1
- package/lib/typescript/widgets/MenuGrid.d.ts +0 -18
- package/lib/typescript/widgets/MenuGrid.d.ts.map +0 -1
- package/lib/typescript/widgets/ScreenHeader.d.ts +0 -20
- package/lib/typescript/widgets/ScreenHeader.d.ts.map +0 -1
- package/lib/typescript/widgets/TimeZoneSelector.d.ts +0 -8
- package/lib/typescript/widgets/TimeZoneSelector.d.ts.map +0 -1
- package/lib/typescript/widgets/TimeZoneSelectorModal.d.ts +0 -10
- package/lib/typescript/widgets/TimeZoneSelectorModal.d.ts.map +0 -1
- package/lib/typescript/widgets/index.d.ts +0 -8
- package/lib/typescript/widgets/index.d.ts.map +0 -1
- package/sincpro_mobile_ui/Dialog/BottomSheet/BottomSheet.Root.tsx +0 -509
- package/sincpro_mobile_ui/Dialog/BottomSheet/index.ts +0 -1
- package/sincpro_mobile_ui/Dialog/Confirmation.context.tsx +0 -148
- package/sincpro_mobile_ui/Dialog/Dialog.Confirmation.tsx +0 -68
- package/sincpro_mobile_ui/Dialog/Dialog.EditValue.tsx +0 -134
- package/sincpro_mobile_ui/Dialog/index.ts +0 -23
- package/sincpro_mobile_ui/Display/Display.Avatar.tsx +0 -60
- package/sincpro_mobile_ui/Display/Display.Badge.tsx +0 -72
- package/sincpro_mobile_ui/Display/Display.CopyableText.tsx +0 -38
- package/sincpro_mobile_ui/Display/Display.CountRecords.tsx +0 -26
- package/sincpro_mobile_ui/Display/Display.Date.tsx +0 -59
- package/sincpro_mobile_ui/Display/Display.Divider.tsx +0 -40
- package/sincpro_mobile_ui/Display/Display.Icon.tsx +0 -69
- package/sincpro_mobile_ui/Display/Display.Logo.tsx +0 -51
- package/sincpro_mobile_ui/Display/Display.MenuButton.tsx +0 -103
- package/sincpro_mobile_ui/Display/Display.Monetary.tsx +0 -60
- package/sincpro_mobile_ui/Display/index.ts +0 -28
- package/sincpro_mobile_ui/Feedback/ErrorBoundary.tsx +0 -51
- package/sincpro_mobile_ui/Feedback/Feedback.DomainSplashScreen.tsx +0 -135
- package/sincpro_mobile_ui/Feedback/Feedback.Empty.tsx +0 -29
- package/sincpro_mobile_ui/Feedback/Feedback.Error.tsx +0 -47
- package/sincpro_mobile_ui/Feedback/Feedback.Loading.tsx +0 -27
- package/sincpro_mobile_ui/Feedback/Feedback.Spinner.tsx +0 -34
- package/sincpro_mobile_ui/Feedback/Feedback.Splash.tsx +0 -68
- package/sincpro_mobile_ui/Feedback/index.ts +0 -17
- package/sincpro_mobile_ui/Form/Form.Button.tsx +0 -461
- package/sincpro_mobile_ui/Form/Form.Checkbox.tsx +0 -89
- package/sincpro_mobile_ui/Form/Form.ControlledCheckbox.tsx +0 -34
- package/sincpro_mobile_ui/Form/Form.ControlledDropdown.tsx +0 -22
- package/sincpro_mobile_ui/Form/Form.ControlledInput.tsx +0 -53
- package/sincpro_mobile_ui/Form/Form.ControlledMonetaryInput.tsx +0 -41
- package/sincpro_mobile_ui/Form/Form.ControlledRadioButton.tsx +0 -33
- package/sincpro_mobile_ui/Form/Form.Dropdown.tsx +0 -171
- package/sincpro_mobile_ui/Form/Form.FilterButton.tsx +0 -59
- package/sincpro_mobile_ui/Form/Form.FractionalQuantityInput.tsx +0 -190
- package/sincpro_mobile_ui/Form/Form.IconButton.tsx +0 -102
- package/sincpro_mobile_ui/Form/Form.Input.tsx +0 -88
- package/sincpro_mobile_ui/Form/Form.InputField.tsx +0 -66
- package/sincpro_mobile_ui/Form/Form.MonetaryInput.tsx +0 -66
- package/sincpro_mobile_ui/Form/Form.PasswordInput.tsx +0 -42
- package/sincpro_mobile_ui/Form/Form.QuantitySelector.tsx +0 -81
- package/sincpro_mobile_ui/Form/Form.RadioButton.tsx +0 -52
- package/sincpro_mobile_ui/Form/Form.SearchBar.tsx +0 -64
- package/sincpro_mobile_ui/Form/Form.TextInput.tsx +0 -26
- package/sincpro_mobile_ui/Form/index.ts +0 -46
- package/sincpro_mobile_ui/Navigation/Navigation.Header.tsx +0 -50
- package/sincpro_mobile_ui/Navigation/Navigation.HeaderToolbar.tsx +0 -111
- package/sincpro_mobile_ui/Navigation/Navigation.RowItem.tsx +0 -33
- package/sincpro_mobile_ui/Navigation/Navigation.TabIcon.tsx +0 -45
- package/sincpro_mobile_ui/Navigation/Navigation.TabItem.tsx +0 -43
- package/sincpro_mobile_ui/Navigation/index.ts +0 -15
- package/sincpro_mobile_ui/Typography/Typography.Heading.tsx +0 -20
- package/sincpro_mobile_ui/Typography/Typography.Text.tsx +0 -78
- package/sincpro_mobile_ui/Typography/index.ts +0 -11
- package/sincpro_mobile_ui/icons/AddItemIcon.tsx +0 -46
- package/sincpro_mobile_ui/icons/ArrangeCircle.tsx +0 -50
- package/sincpro_mobile_ui/icons/ArrowDownIcon.tsx +0 -33
- package/sincpro_mobile_ui/icons/ArrowUpIcon.tsx +0 -33
- package/sincpro_mobile_ui/icons/BoxIcon.tsx +0 -32
- package/sincpro_mobile_ui/icons/BoxTimeIcon.tsx +0 -27
- package/sincpro_mobile_ui/icons/CalendarIcon.tsx +0 -85
- package/sincpro_mobile_ui/icons/CardIcon.tsx +0 -44
- package/sincpro_mobile_ui/icons/CashierIcon.tsx +0 -15
- package/sincpro_mobile_ui/icons/CreditIcon.tsx +0 -44
- package/sincpro_mobile_ui/icons/DuoIcon.tsx +0 -39
- package/sincpro_mobile_ui/icons/HomeIcon.tsx +0 -15
- package/sincpro_mobile_ui/icons/HomeIconOutlined.tsx +0 -24
- package/sincpro_mobile_ui/icons/LogoIcon.tsx +0 -39
- package/sincpro_mobile_ui/icons/MoneyReceiveIcon.tsx +0 -46
- package/sincpro_mobile_ui/icons/OdooIcon.tsx +0 -23
- package/sincpro_mobile_ui/icons/PinIcon.tsx +0 -15
- package/sincpro_mobile_ui/icons/PrinterIcon.tsx +0 -46
- package/sincpro_mobile_ui/icons/ProfileIcon.tsx +0 -19
- package/sincpro_mobile_ui/icons/SettingsIcon.tsx +0 -66
- package/sincpro_mobile_ui/icons/SinpeIcon.tsx +0 -29
- package/sincpro_mobile_ui/icons/ToggleOffIcon.tsx +0 -25
- package/sincpro_mobile_ui/icons/WalletMoneyIcon.tsx +0 -41
- package/sincpro_mobile_ui/icons/icon_getters.tsx +0 -27
- package/sincpro_mobile_ui/icons/props.ts +0 -4
- package/sincpro_mobile_ui/index.ts +0 -38
- package/sincpro_mobile_ui/layouts/AuthContainer.tsx +0 -73
- package/sincpro_mobile_ui/layouts/Container.tsx +0 -40
- package/sincpro_mobile_ui/layouts/GradientContainer.tsx +0 -22
- package/sincpro_mobile_ui/layouts/PlainLayout.tsx +0 -14
- package/sincpro_mobile_ui/layouts/ScrollContainer.tsx +0 -37
- package/sincpro_mobile_ui/layouts/TabNavigatorLayout.tsx +0 -154
- package/sincpro_mobile_ui/lib/date.ts +0 -149
- package/sincpro_mobile_ui/lib/icon.ts +0 -10
- package/sincpro_mobile_ui/lib/monetary.ts +0 -33
- package/sincpro_mobile_ui/lib/quantity.ts +0 -52
- package/sincpro_mobile_ui/lib/serializer.ts +0 -59
- package/sincpro_mobile_ui/lib/timezone.ts +0 -4
- package/sincpro_mobile_ui/nativewind-env.d.ts +0 -1
- package/sincpro_mobile_ui/notifications/index.ts +0 -2
- package/sincpro_mobile_ui/primitives/BaseButton.tsx +0 -404
- package/sincpro_mobile_ui/primitives/Box.tsx +0 -14
- package/sincpro_mobile_ui/primitives/Row.tsx +0 -55
- package/sincpro_mobile_ui/primitives/Stack.tsx +0 -29
- package/sincpro_mobile_ui/primitives/index.ts +0 -3
- package/sincpro_mobile_ui/providers/index.ts +0 -1
- package/sincpro_mobile_ui/theme/active.ts +0 -12
- package/sincpro_mobile_ui/theme/components/ThemedActivityIndicator.tsx +0 -29
- package/sincpro_mobile_ui/theme/components/index.ts +0 -10
- package/sincpro_mobile_ui/theme/default.ts +0 -81
- package/sincpro_mobile_ui/theme/globals.css +0 -67
- package/sincpro_mobile_ui/theme/index.ts +0 -4
- package/sincpro_mobile_ui/theme/theme.ts +0 -16
- package/sincpro_mobile_ui/theme/tw.ts +0 -16
- package/sincpro_mobile_ui/theme/types.ts +0 -109
- package/sincpro_mobile_ui/theme/typography.ts +0 -271
- package/sincpro_mobile_ui/theme/useTheme.ts +0 -3
- package/sincpro_mobile_ui/views/AuthFormView.tsx +0 -46
- package/sincpro_mobile_ui/views/FormViewV2.context.tsx +0 -79
- package/sincpro_mobile_ui/views/FormViewV2.tsx +0 -248
- package/sincpro_mobile_ui/views/ListViewV2.context.tsx +0 -87
- package/sincpro_mobile_ui/views/ListViewV2.tsx +0 -575
- package/sincpro_mobile_ui/views/Wizard/Wizard.context.tsx +0 -164
- package/sincpro_mobile_ui/views/Wizard/Wizard.tsx +0 -147
- package/sincpro_mobile_ui/views/Wizard/index.ts +0 -11
- package/sincpro_mobile_ui/views/types/IFormView.ts +0 -24
- package/sincpro_mobile_ui/views/types/IListView.ts +0 -78
- package/sincpro_mobile_ui/views/types/UIItem.ts +0 -23
- package/sincpro_mobile_ui/widgets/CircleButton.tsx +0 -63
- package/sincpro_mobile_ui/widgets/GeoPermissionCard.tsx +0 -62
- package/sincpro_mobile_ui/widgets/HomeHeader.tsx +0 -50
- package/sincpro_mobile_ui/widgets/JSONViewer.tsx +0 -192
- package/sincpro_mobile_ui/widgets/MenuCard.tsx +0 -37
- package/sincpro_mobile_ui/widgets/MenuGrid.tsx +0 -33
- package/sincpro_mobile_ui/widgets/ScreenHeader.tsx +0 -72
- package/sincpro_mobile_ui/widgets/TimeZoneSelector.tsx +0 -83
- package/sincpro_mobile_ui/widgets/TimeZoneSelectorModal.tsx +0 -179
- package/sincpro_mobile_ui/widgets/index.ts +0 -7
- /package/lib/{module/theme → theme}/globals.css +0 -0
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
import dayjs from "dayjs";
|
|
2
|
+
import timezone from "dayjs/plugin/timezone";
|
|
3
|
+
import utc from "dayjs/plugin/utc";
|
|
4
|
+
import { getLocales } from "expo-localization";
|
|
5
|
+
const DEFAULT_TIMEZONE = "America/Costa_Rica";
|
|
6
|
+
const DEFAULT_LOCALE = "es-CR";
|
|
7
|
+
dayjs.extend(utc);
|
|
8
|
+
dayjs.extend(timezone);
|
|
9
|
+
/**
|
|
10
|
+
* Formatea una fecha en la zona horaria indicada respetando la granularidad de la entrada.
|
|
11
|
+
*
|
|
12
|
+
* Reglas de detección:
|
|
13
|
+
* 1. Si `input` es un string 'YYYY-MM-DD' (solo fecha) => se interpreta como medianoche (00:00:00)
|
|
14
|
+
* en la zona horaria destino y se devuelve SOLO la parte de fecha (sin hora).
|
|
15
|
+
* 2. Si `input` incluye componente de tiempo (ISO completo o Date) => se convierte a la zona destino
|
|
16
|
+
* y se muestra fecha + hora (HH:MM) salvo que se fuerce lo contrario mediante `options.showTime`.
|
|
17
|
+
* 3. Cuando `options.showTime` es `true` o `false` se sobre‑escribe la auto‑detección.
|
|
18
|
+
* 4. Si `timezone` es null/undefined o inválido se retorna la cadena "Error de formateo".
|
|
19
|
+
*
|
|
20
|
+
* Localización:
|
|
21
|
+
* - Usa el primer locale del dispositivo (`expo-localization`) como predeterminado.
|
|
22
|
+
* - Puedes forzar uno diferente con `options.locale` (ej: 'es-CR', 'en-US').
|
|
23
|
+
*
|
|
24
|
+
* Seguridad de zona horaria:
|
|
25
|
+
* - El parse de una fecha sin hora NO se hace en la zona local del dispositivo para luego convertir,
|
|
26
|
+
* sino directamente en la zona destino para evitar corrimientos de día.
|
|
27
|
+
*
|
|
28
|
+
* Ejemplos:
|
|
29
|
+
* ```ts
|
|
30
|
+
* formatDate('2025-09-02', 'America/Costa_Rica');
|
|
31
|
+
* // => "2 de septiembre de 2025"
|
|
32
|
+
*
|
|
33
|
+
* formatDate('2025-09-02T18:30:00Z', 'America/Costa_Rica');
|
|
34
|
+
* // => "2 de septiembre de 2025, 12:30 p. m." (dependiendo del locale real)
|
|
35
|
+
*
|
|
36
|
+
* formatDate(new Date('2025-09-02T23:15:00Z'), 'Europe/Madrid');
|
|
37
|
+
* // => "3 de septiembre de 2025, 01:15" (cambio de día por zona +02)
|
|
38
|
+
*
|
|
39
|
+
* formatDate('2025-09-02', 'America/Costa_Rica', { showTime: true });
|
|
40
|
+
* // => "2 de septiembre de 2025, 12:00 a. m." (fuerza hora)
|
|
41
|
+
* ```
|
|
42
|
+
*
|
|
43
|
+
* @param input Fecha (string ISO, 'YYYY-MM-DD' o instancia Date)
|
|
44
|
+
* @param timezone Zona horaria IANA (ej: 'America/Costa_Rica', 'Asia/Tokyo'). Si es null/undefined usa Costa Rica
|
|
45
|
+
* @param options Opcional: locale forzado y/o bandera para mostrar hora
|
|
46
|
+
* @returns Cadena localizada o "Error de formateo" si no se puede procesar
|
|
47
|
+
*/
|
|
48
|
+
export function formatDate(input, timezone, options) {
|
|
49
|
+
// Usar timezone por defecto si no se proporciona
|
|
50
|
+
const effectiveTimezone = timezone || DEFAULT_TIMEZONE;
|
|
51
|
+
const fallbackLocale = DEFAULT_LOCALE.split("-")[0]; // "es" from "es-CR"
|
|
52
|
+
const deviceLocale = getLocales()?.[0]?.languageTag ?? fallbackLocale;
|
|
53
|
+
const usedLocale = options?.locale ?? deviceLocale;
|
|
54
|
+
try {
|
|
55
|
+
const rawStr = typeof input === "string" ? input : input.toISOString();
|
|
56
|
+
const isDateOnly = /^\d{4}-\d{2}-\d{2}$/.test(rawStr);
|
|
57
|
+
// Auto-detect showTime si no se pasa explicitamente
|
|
58
|
+
const effectiveShowTime = options?.showTime !== undefined
|
|
59
|
+
? options.showTime
|
|
60
|
+
: !isDateOnly && /T\d{2}:\d{2}/.test(rawStr); // tiene componente hora
|
|
61
|
+
const dateInstance = isDateOnly
|
|
62
|
+
? dayjs.tz(`${rawStr}T00:00:00`, effectiveTimezone)
|
|
63
|
+
: dayjs.utc(rawStr).tz(effectiveTimezone);
|
|
64
|
+
const dateInZone = dateInstance.toDate();
|
|
65
|
+
const formatOptions = {
|
|
66
|
+
year: "numeric",
|
|
67
|
+
month: "long",
|
|
68
|
+
day: "numeric",
|
|
69
|
+
timeZone: effectiveTimezone,
|
|
70
|
+
};
|
|
71
|
+
if (effectiveShowTime) {
|
|
72
|
+
formatOptions.hour = "2-digit";
|
|
73
|
+
formatOptions.minute = "2-digit";
|
|
74
|
+
}
|
|
75
|
+
return new Intl.DateTimeFormat(usedLocale, formatOptions).format(dateInZone);
|
|
76
|
+
}
|
|
77
|
+
catch (error) {
|
|
78
|
+
console.warn("Error formateando fecha:", error);
|
|
79
|
+
return "Error de formateo";
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* Formatea una fecha usando automáticamente el timezone por defecto (Costa Rica).
|
|
84
|
+
* Útil para casos donde no se tiene acceso al timezone del usuario.
|
|
85
|
+
*
|
|
86
|
+
* @param input Fecha (string ISO, 'YYYY-MM-DD' o instancia Date)
|
|
87
|
+
* @param options Opcional: locale forzado y/o bandera para mostrar hora
|
|
88
|
+
* @returns Cadena localizada en timezone de Costa Rica
|
|
89
|
+
*/
|
|
90
|
+
export function formatDateWithDefaultTimezone(input, options) {
|
|
91
|
+
return formatDate(input, DEFAULT_TIMEZONE, options);
|
|
92
|
+
}
|
|
93
|
+
/**
|
|
94
|
+
* Obtiene la fecha actual en formato YYYY-MM-DD en el timezone especificado.
|
|
95
|
+
* Útil para crear fechas de programación que respeten el timezone del usuario.
|
|
96
|
+
*
|
|
97
|
+
* @param timezone Zona horaria IANA. Si es null/undefined usa Costa Rica
|
|
98
|
+
* @returns Fecha actual en formato YYYY-MM-DD en el timezone especificado
|
|
99
|
+
*/
|
|
100
|
+
export function getCurrentDateInTimezone(timezone) {
|
|
101
|
+
const effectiveTimezone = timezone || DEFAULT_TIMEZONE;
|
|
102
|
+
try {
|
|
103
|
+
return dayjs().tz(effectiveTimezone).format("YYYY-MM-DD");
|
|
104
|
+
}
|
|
105
|
+
catch (error) {
|
|
106
|
+
console.warn("Error obteniendo fecha actual en timezone:", error);
|
|
107
|
+
return dayjs().format("YYYY-MM-DD"); // Fallback to local
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
/**
|
|
111
|
+
* Obtiene la fecha y hora actual en formato ISO en el timezone especificado.
|
|
112
|
+
* Útil para timestamps que necesiten reflejar el timezone del usuario.
|
|
113
|
+
*
|
|
114
|
+
* @param timezone Zona horaria IANA. Si es null/undefined usa Costa Rica
|
|
115
|
+
* @returns Fecha actual en formato ISO en el timezone especificado
|
|
116
|
+
*/
|
|
117
|
+
export function getCurrentDateTimeInTimezone(timezone) {
|
|
118
|
+
const effectiveTimezone = timezone || DEFAULT_TIMEZONE;
|
|
119
|
+
try {
|
|
120
|
+
return dayjs().tz(effectiveTimezone).toISOString();
|
|
121
|
+
}
|
|
122
|
+
catch (error) {
|
|
123
|
+
console.warn("Error obteniendo fecha/hora actual en timezone:", error);
|
|
124
|
+
return dayjs().toISOString(); // Fallback to local
|
|
125
|
+
}
|
|
126
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export type IconType = "ionicons" | "fontawesome" | "material" | "fontawesome5" | "simplelineicons" | "antdesign" | "custom" | "feather" | "MaterialCommunityIcons";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { Big } from "big.js";
|
|
2
|
+
export function parseToMonetaryNumber(input) {
|
|
3
|
+
if (input == null)
|
|
4
|
+
return 0;
|
|
5
|
+
const s = String(input).trim();
|
|
6
|
+
if (!/[0-9]/.test(s))
|
|
7
|
+
return 0;
|
|
8
|
+
const cleaned = s.replace(/[^0-9.-]+/g, "");
|
|
9
|
+
try {
|
|
10
|
+
return Number(new Big(cleaned).toString());
|
|
11
|
+
}
|
|
12
|
+
catch {
|
|
13
|
+
return 0;
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
export function formatTwoDecimals(value) {
|
|
17
|
+
const raw = parseToMonetaryNumber(value);
|
|
18
|
+
const rounded = new Big(raw).toFixed(2);
|
|
19
|
+
const num = Number(rounded);
|
|
20
|
+
return new Intl.NumberFormat("de-DE", {
|
|
21
|
+
minimumFractionDigits: 2,
|
|
22
|
+
maximumFractionDigits: 2,
|
|
23
|
+
}).format(num);
|
|
24
|
+
}
|
|
25
|
+
export function calculateDiscountedTotal(total, discount) {
|
|
26
|
+
if (discount === 0) {
|
|
27
|
+
return 0;
|
|
28
|
+
}
|
|
29
|
+
const result = (parseToMonetaryNumber(total) * discount) / 100;
|
|
30
|
+
return parseToMonetaryNumber(result);
|
|
31
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/** Redondea a la precisión indicada usando round half up */
|
|
2
|
+
export declare function roundTo(value: number, precision: number): number;
|
|
3
|
+
/** Normaliza la cantidad al múltiplo más cercano del incremento mínimo */
|
|
4
|
+
export declare function normalizeQuantity(value: number, minIncrement: number, precision: number): number;
|
|
5
|
+
/** Convierte un valor a entero escalado según precisión para cálculos seguros */
|
|
6
|
+
export declare function toScaledInt(value: number, precision: number): number;
|
|
7
|
+
export declare function fromScaledInt(scaled: number, precision: number): number;
|
|
8
|
+
/** Multiplicación segura evitando errores binarios típicos */
|
|
9
|
+
export declare function safeMul(a: number, b: number, precision: number): number;
|
|
10
|
+
/** Valida si un valor es múltiplo del incremento mínimo dentro de la precisión */
|
|
11
|
+
export declare function isMultipleOfIncrement(value: number, minIncrement: number, precision: number): boolean;
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { Big } from "big.js";
|
|
2
|
+
/** Redondea a la precisión indicada usando round half up */
|
|
3
|
+
export function roundTo(value, precision) {
|
|
4
|
+
if (isNaN(value))
|
|
5
|
+
return 0;
|
|
6
|
+
const factor = new Big(10).pow(precision);
|
|
7
|
+
return Number(new Big(value).times(factor).round(0, 1).div(factor).toString());
|
|
8
|
+
}
|
|
9
|
+
/** Normaliza la cantidad al múltiplo más cercano del incremento mínimo */
|
|
10
|
+
export function normalizeQuantity(value, minIncrement, precision) {
|
|
11
|
+
if (!isFinite(value))
|
|
12
|
+
return 0;
|
|
13
|
+
if (value < 0)
|
|
14
|
+
value = 0;
|
|
15
|
+
if (minIncrement <= 0)
|
|
16
|
+
return roundTo(value, precision);
|
|
17
|
+
const steps = Math.round(value / minIncrement);
|
|
18
|
+
const normalized = steps * minIncrement;
|
|
19
|
+
return roundTo(normalized, precision);
|
|
20
|
+
}
|
|
21
|
+
/** Convierte un valor a entero escalado según precisión para cálculos seguros */
|
|
22
|
+
export function toScaledInt(value, precision) {
|
|
23
|
+
if (!isFinite(value))
|
|
24
|
+
return 0;
|
|
25
|
+
const factor = Math.pow(10, precision);
|
|
26
|
+
return Math.round(value * factor);
|
|
27
|
+
}
|
|
28
|
+
export function fromScaledInt(scaled, precision) {
|
|
29
|
+
const factor = Math.pow(10, precision);
|
|
30
|
+
return scaled / factor;
|
|
31
|
+
}
|
|
32
|
+
/** Multiplicación segura evitando errores binarios típicos */
|
|
33
|
+
export function safeMul(a, b, precision) {
|
|
34
|
+
const factor = Math.pow(10, precision);
|
|
35
|
+
return (Math.round(a * factor) * Math.round(b * factor)) / (factor * factor);
|
|
36
|
+
}
|
|
37
|
+
/** Valida si un valor es múltiplo del incremento mínimo dentro de la precisión */
|
|
38
|
+
export function isMultipleOfIncrement(value, minIncrement, precision) {
|
|
39
|
+
if (minIncrement <= 0)
|
|
40
|
+
return true;
|
|
41
|
+
const scaledValue = toScaledInt(value, precision + 3); // extra precisión para reducir error
|
|
42
|
+
const scaledInc = toScaledInt(minIncrement, precision + 3);
|
|
43
|
+
return scaledValue % scaledInc === 0;
|
|
44
|
+
}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
export function safeJsonStringify(obj, pretty = false) {
|
|
2
|
+
const seen = new WeakSet();
|
|
3
|
+
if (pretty) {
|
|
4
|
+
return JSON.stringify(obj, (key, value) => {
|
|
5
|
+
if (key.startsWith("_")) {
|
|
6
|
+
return undefined;
|
|
7
|
+
}
|
|
8
|
+
if (value instanceof Map) {
|
|
9
|
+
return Object.fromEntries(value);
|
|
10
|
+
}
|
|
11
|
+
if (value instanceof Set) {
|
|
12
|
+
return Array.from(value);
|
|
13
|
+
}
|
|
14
|
+
if (typeof value === "object" && value !== null) {
|
|
15
|
+
if (seen.has(value)) {
|
|
16
|
+
return "[Circular]";
|
|
17
|
+
}
|
|
18
|
+
seen.add(value);
|
|
19
|
+
}
|
|
20
|
+
return value;
|
|
21
|
+
}, 2);
|
|
22
|
+
}
|
|
23
|
+
return JSON.stringify(obj, (key, value) => {
|
|
24
|
+
if (key.startsWith("_")) {
|
|
25
|
+
return undefined;
|
|
26
|
+
}
|
|
27
|
+
if (value instanceof Map) {
|
|
28
|
+
return Object.fromEntries(value);
|
|
29
|
+
}
|
|
30
|
+
if (value instanceof Set) {
|
|
31
|
+
return Array.from(value);
|
|
32
|
+
}
|
|
33
|
+
if (typeof value === "object" && value !== null) {
|
|
34
|
+
if (seen.has(value)) {
|
|
35
|
+
return "[Circular]";
|
|
36
|
+
}
|
|
37
|
+
seen.add(value);
|
|
38
|
+
}
|
|
39
|
+
return value;
|
|
40
|
+
});
|
|
41
|
+
}
|
|
42
|
+
export function safeJsonParse(json) {
|
|
43
|
+
return JSON.parse(json);
|
|
44
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { ReactNode } from "react";
|
|
2
|
+
import { type ImageSourcePropType } from "react-native";
|
|
3
|
+
interface AuthFormProps {
|
|
4
|
+
title?: string;
|
|
5
|
+
description?: string;
|
|
6
|
+
logoSource?: ImageSourcePropType;
|
|
7
|
+
onBack?: () => void;
|
|
8
|
+
FormNode: ReactNode;
|
|
9
|
+
}
|
|
10
|
+
declare function AuthFormView({ title, description, logoSource, onBack, FormNode }: AuthFormProps): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export default AuthFormView;
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { jsx as _jsx, jsxs as _jsxs } from "nativewind/jsx-runtime";
|
|
2
|
+
import { Display } from "../Display";
|
|
3
|
+
import AuthContainer from "../layouts/AuthContainer";
|
|
4
|
+
import { Typography } from "../Typography";
|
|
5
|
+
import { View } from "react-native";
|
|
6
|
+
const Logo = Display.Logo;
|
|
7
|
+
const Text = Typography.Text;
|
|
8
|
+
function AuthFormView({ title, description, logoSource, onBack, FormNode }) {
|
|
9
|
+
const renderTitle = () => {
|
|
10
|
+
if (!title)
|
|
11
|
+
return null;
|
|
12
|
+
return (_jsx(Text, { semibold: true, variant: "h4", children: title }));
|
|
13
|
+
};
|
|
14
|
+
const renderDescription = () => {
|
|
15
|
+
if (!description)
|
|
16
|
+
return null;
|
|
17
|
+
return _jsx(Text, { variant: "body", children: description });
|
|
18
|
+
};
|
|
19
|
+
return (_jsx(AuthContainer, { header: _jsx(Logo, { size: "large", source: logoSource }), onBackPress: onBack, children: _jsxs(View, { className: "m-4", children: [_jsxs(View, { className: "mb-5", children: [renderTitle(), renderDescription()] }), FormNode] }) }));
|
|
20
|
+
}
|
|
21
|
+
export default AuthFormView;
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { ReactNode } from "react";
|
|
2
|
+
interface FormViewContextValue<T> {
|
|
3
|
+
name: string;
|
|
4
|
+
description?: string;
|
|
5
|
+
item: T | null;
|
|
6
|
+
isLoading: boolean;
|
|
7
|
+
isEmpty: boolean;
|
|
8
|
+
hasError: boolean;
|
|
9
|
+
errorMessage?: string;
|
|
10
|
+
readonly: boolean;
|
|
11
|
+
showRefreshing: boolean;
|
|
12
|
+
setShowRefreshing: (value: boolean) => void;
|
|
13
|
+
onRefresh?: () => Promise<void>;
|
|
14
|
+
onRetry?: () => void;
|
|
15
|
+
onBack?: () => void;
|
|
16
|
+
}
|
|
17
|
+
export declare function FormViewProvider<T>({ name, description, item, isLoading, isEmpty, hasError, errorMessage, readonly, onRefresh, onRetry, onBack, children, }: {
|
|
18
|
+
name: string;
|
|
19
|
+
description?: string;
|
|
20
|
+
item: T | null;
|
|
21
|
+
isLoading?: boolean;
|
|
22
|
+
isEmpty?: boolean;
|
|
23
|
+
hasError?: boolean;
|
|
24
|
+
errorMessage?: string;
|
|
25
|
+
readonly?: boolean;
|
|
26
|
+
onRefresh?: () => Promise<void>;
|
|
27
|
+
onRetry?: () => void;
|
|
28
|
+
onBack?: () => void;
|
|
29
|
+
children: ReactNode;
|
|
30
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
31
|
+
export declare function useFormView<T>(): FormViewContextValue<T>;
|
|
32
|
+
export {};
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { jsx as _jsx } from "nativewind/jsx-runtime";
|
|
2
|
+
import { createContext, useContext, useState } from "react";
|
|
3
|
+
const Context = createContext(null);
|
|
4
|
+
export function FormViewProvider({ name, description, item, isLoading = false, isEmpty = false, hasError = false, errorMessage, readonly = false, onRefresh, onRetry, onBack, children, }) {
|
|
5
|
+
const [showRefreshing, setShowRefreshing] = useState(false);
|
|
6
|
+
return (_jsx(Context.Provider, { value: {
|
|
7
|
+
name,
|
|
8
|
+
description,
|
|
9
|
+
item,
|
|
10
|
+
isLoading,
|
|
11
|
+
isEmpty,
|
|
12
|
+
hasError,
|
|
13
|
+
errorMessage,
|
|
14
|
+
readonly,
|
|
15
|
+
showRefreshing,
|
|
16
|
+
setShowRefreshing,
|
|
17
|
+
onRefresh,
|
|
18
|
+
onRetry,
|
|
19
|
+
onBack,
|
|
20
|
+
}, children: children }));
|
|
21
|
+
}
|
|
22
|
+
export function useFormView() {
|
|
23
|
+
const context = useContext(Context);
|
|
24
|
+
if (!context) {
|
|
25
|
+
throw new Error("useFormView must be used within FormViewV2");
|
|
26
|
+
}
|
|
27
|
+
return context;
|
|
28
|
+
}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import { EVariantScreenHeader } from "../widgets/ScreenHeader";
|
|
2
|
+
import { ReactNode } from "react";
|
|
3
|
+
import { type ImageSourcePropType } from "react-native";
|
|
4
|
+
interface FormViewProps<T> {
|
|
5
|
+
name: string;
|
|
6
|
+
description?: string;
|
|
7
|
+
item: T | null;
|
|
8
|
+
isLoading?: boolean;
|
|
9
|
+
isEmpty?: boolean;
|
|
10
|
+
hasError?: boolean;
|
|
11
|
+
errorMessage?: string;
|
|
12
|
+
readonly?: boolean;
|
|
13
|
+
onRefresh?: () => Promise<void>;
|
|
14
|
+
onRetry?: () => void;
|
|
15
|
+
onBack?: () => void;
|
|
16
|
+
withContainer?: boolean;
|
|
17
|
+
children: ReactNode;
|
|
18
|
+
}
|
|
19
|
+
declare function FormViewRoot<T>({ name, description, item, isLoading, isEmpty, hasError, errorMessage, readonly, onRefresh, onRetry, onBack, withContainer, children, }: FormViewProps<T>): import("react/jsx-runtime").JSX.Element;
|
|
20
|
+
declare function Header({ variant, logoSource, children, }: {
|
|
21
|
+
variant?: EVariantScreenHeader;
|
|
22
|
+
logoSource?: ImageSourcePropType;
|
|
23
|
+
children?: ReactNode;
|
|
24
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
25
|
+
declare function HeaderActions({ children }: {
|
|
26
|
+
children: ReactNode;
|
|
27
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
28
|
+
declare function HeaderActionsBar({ children }: {
|
|
29
|
+
children: ReactNode;
|
|
30
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
31
|
+
declare function Content({ withMargin, children, }: {
|
|
32
|
+
withMargin?: boolean;
|
|
33
|
+
children: ReactNode;
|
|
34
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
35
|
+
declare function Form({ children }: {
|
|
36
|
+
children: ReactNode;
|
|
37
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
38
|
+
declare function Groups({ children }: {
|
|
39
|
+
children: ReactNode;
|
|
40
|
+
}): import("react/jsx-runtime").JSX.Element | null;
|
|
41
|
+
declare function Group({ children, withMargin, elevation, }: {
|
|
42
|
+
children: ReactNode;
|
|
43
|
+
withMargin?: boolean;
|
|
44
|
+
elevation?: "sm" | "md" | "lg";
|
|
45
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
46
|
+
declare function Footer({ children }: {
|
|
47
|
+
children: ReactNode;
|
|
48
|
+
}): import("react/jsx-runtime").JSX.Element | null;
|
|
49
|
+
export declare const FormViewV2: {
|
|
50
|
+
Root: typeof FormViewRoot;
|
|
51
|
+
Header: typeof Header & {
|
|
52
|
+
Actions: typeof HeaderActions;
|
|
53
|
+
ActionsBar: typeof HeaderActionsBar;
|
|
54
|
+
};
|
|
55
|
+
Content: typeof Content & {
|
|
56
|
+
Form: typeof Form;
|
|
57
|
+
Groups: typeof Groups;
|
|
58
|
+
Group: typeof Group;
|
|
59
|
+
};
|
|
60
|
+
Footer: typeof Footer;
|
|
61
|
+
};
|
|
62
|
+
export default FormViewV2;
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
import { jsx as _jsx, Fragment as _Fragment } from "nativewind/jsx-runtime";
|
|
2
|
+
import { ErrorBoundary, Feedback } from "../Feedback";
|
|
3
|
+
import Container from "../layouts/Container";
|
|
4
|
+
import { theme } from "../theme";
|
|
5
|
+
import { FormViewProvider, useFormView } from "../views/FormViewV2.context";
|
|
6
|
+
import ScreenHeader from "../widgets/ScreenHeader";
|
|
7
|
+
import React from "react";
|
|
8
|
+
import { RefreshControl, View } from "react-native";
|
|
9
|
+
import { KeyboardAwareScrollView } from "react-native-keyboard-controller";
|
|
10
|
+
function FormViewRoot({ name, description, item, isLoading = false, isEmpty = false, hasError = false, errorMessage, readonly = false, onRefresh, onRetry, onBack, withContainer = true, children, }) {
|
|
11
|
+
const Wrapper = withContainer ? Container : View;
|
|
12
|
+
const wrapperProps = withContainer ? {} : { style: { flex: 1 } };
|
|
13
|
+
return (_jsx(FormViewProvider, { description: description, errorMessage: errorMessage, hasError: hasError, isEmpty: isEmpty, isLoading: isLoading, item: item, name: name, onBack: onBack, onRefresh: onRefresh, onRetry: onRetry, readonly: readonly, children: _jsx(ErrorBoundary, { children: _jsx(Wrapper, { ...wrapperProps, children: children }) }) }));
|
|
14
|
+
}
|
|
15
|
+
function Header({ variant = "FLAT_HEADER" /* EVariantScreenHeader.FLAT_HEADER */, logoSource, children, }) {
|
|
16
|
+
const { name, description, onBack } = useFormView();
|
|
17
|
+
return (_jsx(_Fragment, { children: _jsx(ScreenHeader, { logoSource: logoSource, onBack: onBack, subtitle: description ? description : `Seleccionar ${name}`, title: name, variant: variant, children: children }) }));
|
|
18
|
+
}
|
|
19
|
+
function HeaderActions({ children }) {
|
|
20
|
+
return (_jsx(View, { className: "flex-row px-4 my-4 items-center justify-between flex-1 gap-2", children: children }));
|
|
21
|
+
}
|
|
22
|
+
function HeaderActionsBar({ children }) {
|
|
23
|
+
return (_jsx(View, { className: "bg-bg-card px-4 py-3 border-b border-border-default flex-row gap-2", children: children }));
|
|
24
|
+
}
|
|
25
|
+
function Content({ withMargin = false, children, }) {
|
|
26
|
+
const { name, isLoading, isEmpty, hasError, errorMessage, item, onRefresh, onRetry, onBack, showRefreshing, setShowRefreshing, } = useFormView();
|
|
27
|
+
const handleRefresh = React.useCallback(async () => {
|
|
28
|
+
setShowRefreshing(true);
|
|
29
|
+
if (onRefresh) {
|
|
30
|
+
await onRefresh();
|
|
31
|
+
}
|
|
32
|
+
setShowRefreshing(false);
|
|
33
|
+
}, [onRefresh, setShowRefreshing]);
|
|
34
|
+
const isCenteredContent = isLoading || isEmpty || !item || hasError;
|
|
35
|
+
return (_jsx(KeyboardAwareScrollView, { bottomOffset: 20, contentContainerStyle: {
|
|
36
|
+
flexGrow: 1,
|
|
37
|
+
justifyContent: isCenteredContent ? "center" : "flex-start",
|
|
38
|
+
alignItems: isCenteredContent ? "center" : "stretch",
|
|
39
|
+
}, keyboardShouldPersistTaps: "handled", refreshControl: _jsx(RefreshControl, { colors: [theme.primary], onRefresh: handleRefresh, refreshing: showRefreshing }), style: { flex: 1 }, children: isCenteredContent ? (_jsx(_Fragment, { children: isLoading ? (_jsx(Feedback.Loading, { message: `Cargando ${name}...` })) : hasError ? (_jsx(Feedback.Error, { message: errorMessage, onBack: onBack, onRetry: onRetry })) : (_jsx(Feedback.Empty, {})) })) : (_jsx(View, { style: withMargin ? { paddingHorizontal: 16 } : undefined, children: children })) }));
|
|
40
|
+
}
|
|
41
|
+
function Form({ children }) {
|
|
42
|
+
const { isEmpty, item } = useFormView();
|
|
43
|
+
if (isEmpty || !item) {
|
|
44
|
+
return _jsx(Feedback.Empty, {});
|
|
45
|
+
}
|
|
46
|
+
return _jsx(_Fragment, { children: children });
|
|
47
|
+
}
|
|
48
|
+
function Groups({ children }) {
|
|
49
|
+
const { isEmpty } = useFormView();
|
|
50
|
+
if (isEmpty) {
|
|
51
|
+
return null;
|
|
52
|
+
}
|
|
53
|
+
return _jsx(_Fragment, { children: children });
|
|
54
|
+
}
|
|
55
|
+
function Group({ children, withMargin = true, elevation = "md", }) {
|
|
56
|
+
const groupClass = withMargin
|
|
57
|
+
? "bg-bg-card mx-4 my-1 p-1 rounded-lg border border-border-light"
|
|
58
|
+
: "bg-bg-card p-1 rounded-lg border border-border-light";
|
|
59
|
+
return (_jsx(View, { className: groupClass, style: theme.shadow[elevation], children: children }));
|
|
60
|
+
}
|
|
61
|
+
function Footer({ children }) {
|
|
62
|
+
const { isEmpty, isLoading } = useFormView();
|
|
63
|
+
if (isEmpty || isLoading) {
|
|
64
|
+
return null;
|
|
65
|
+
}
|
|
66
|
+
return (_jsx(View, { className: "bg-bg-card px-4 py-3 border-t border-border-default", style: theme.shadow.sm, children: children }));
|
|
67
|
+
}
|
|
68
|
+
// Nested Header components
|
|
69
|
+
const HeaderWithSubComponents = Object.assign(Header, {
|
|
70
|
+
Actions: HeaderActions,
|
|
71
|
+
ActionsBar: HeaderActionsBar,
|
|
72
|
+
});
|
|
73
|
+
// Nested Content components
|
|
74
|
+
const ContentWithSubComponents = Object.assign(Content, {
|
|
75
|
+
Form,
|
|
76
|
+
Groups,
|
|
77
|
+
Group,
|
|
78
|
+
});
|
|
79
|
+
export const FormViewV2 = {
|
|
80
|
+
Root: FormViewRoot,
|
|
81
|
+
Header: HeaderWithSubComponents,
|
|
82
|
+
Content: ContentWithSubComponents,
|
|
83
|
+
Footer,
|
|
84
|
+
};
|
|
85
|
+
export default FormViewV2;
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { ReactNode } from "react";
|
|
2
|
+
interface ListViewContextValue<T> {
|
|
3
|
+
name: string;
|
|
4
|
+
description?: string;
|
|
5
|
+
items: T[];
|
|
6
|
+
isLoading: boolean;
|
|
7
|
+
hasError: boolean;
|
|
8
|
+
errorMessage?: string;
|
|
9
|
+
readonly: boolean;
|
|
10
|
+
showRefreshing: boolean;
|
|
11
|
+
setShowRefreshing: (value: boolean) => void;
|
|
12
|
+
onRefresh?: () => Promise<void>;
|
|
13
|
+
onRetry?: () => void;
|
|
14
|
+
onPressItem?: (item: T) => void;
|
|
15
|
+
onDeleteItem?: (item: T) => void;
|
|
16
|
+
onSearch?: (query: string) => void;
|
|
17
|
+
onBack?: () => void;
|
|
18
|
+
}
|
|
19
|
+
export declare function ListViewProvider<T>({ name, description, items, isLoading, hasError, errorMessage, readonly, onRefresh, onRetry, onPressItem, onDeleteItem, onSearch, onBack, children, }: {
|
|
20
|
+
name: string;
|
|
21
|
+
description?: string;
|
|
22
|
+
items: T[];
|
|
23
|
+
isLoading?: boolean;
|
|
24
|
+
hasError?: boolean;
|
|
25
|
+
errorMessage?: string;
|
|
26
|
+
readonly?: boolean;
|
|
27
|
+
onRefresh?: () => Promise<void>;
|
|
28
|
+
onRetry?: () => void;
|
|
29
|
+
onPressItem?: (item: T) => void;
|
|
30
|
+
onDeleteItem?: (item: T) => void;
|
|
31
|
+
onSearch?: (query: string) => void;
|
|
32
|
+
onBack?: () => void;
|
|
33
|
+
children: ReactNode;
|
|
34
|
+
}): import("react/jsx-runtime").JSX.Element;
|
|
35
|
+
export declare function useListView<T>(): ListViewContextValue<T>;
|
|
36
|
+
export {};
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { jsx as _jsx } from "nativewind/jsx-runtime";
|
|
2
|
+
import { createContext, useContext, useState } from "react";
|
|
3
|
+
const Context = createContext(null);
|
|
4
|
+
export function ListViewProvider({ name, description, items, isLoading = false, hasError = false, errorMessage, readonly = false, onRefresh, onRetry, onPressItem, onDeleteItem, onSearch, onBack, children, }) {
|
|
5
|
+
const [showRefreshing, setShowRefreshing] = useState(false);
|
|
6
|
+
return (_jsx(Context.Provider, { value: {
|
|
7
|
+
name,
|
|
8
|
+
description,
|
|
9
|
+
items,
|
|
10
|
+
isLoading,
|
|
11
|
+
hasError,
|
|
12
|
+
errorMessage,
|
|
13
|
+
readonly,
|
|
14
|
+
showRefreshing,
|
|
15
|
+
setShowRefreshing,
|
|
16
|
+
onRefresh,
|
|
17
|
+
onRetry,
|
|
18
|
+
onPressItem,
|
|
19
|
+
onDeleteItem,
|
|
20
|
+
onSearch,
|
|
21
|
+
onBack,
|
|
22
|
+
}, children: children }));
|
|
23
|
+
}
|
|
24
|
+
export function useListView() {
|
|
25
|
+
const context = useContext(Context);
|
|
26
|
+
if (!context) {
|
|
27
|
+
throw new Error("useListView must be used within ListViewV2");
|
|
28
|
+
}
|
|
29
|
+
return context;
|
|
30
|
+
}
|