@sincpro/mobile-ui 0.7.2 → 1.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +7 -5
- package/dist/Actions/Actions.Button.d.ts +91 -91
- package/dist/Actions/Actions.Button.js +36 -43
- package/dist/Actions/Actions.FAB.js +5 -5
- package/dist/Actions/Actions.FilterButton.js +3 -3
- package/dist/Actions/Actions.IconButton.d.ts +31 -31
- package/dist/Actions/Actions.IconButton.js +4 -4
- package/dist/Actions/index.d.ts +11 -11
- package/dist/Actions/index.js +5 -5
- package/dist/Dialog/BottomSheet/BottomSheet.Root.js +1 -1
- package/dist/Dialog/BottomSheet/index.d.ts +1 -1
- package/dist/Dialog/BottomSheet/index.js +1 -1
- package/dist/Dialog/Confirmation.context.js +3 -3
- package/dist/Dialog/Dialog.ActionSheet.js +6 -6
- package/dist/Dialog/Dialog.Confirmation.js +4 -4
- package/dist/Dialog/Dialog.EditValue.js +4 -4
- package/dist/Dialog/Dialog.Sheet.js +6 -4
- package/dist/Dialog/index.d.ts +5 -5
- package/dist/Dialog/index.js +5 -5
- package/dist/Display/Display.Accordion.js +5 -5
- package/dist/Display/Display.Avatar.d.ts +30 -30
- package/dist/Display/Display.Avatar.js +2 -2
- package/dist/Display/Display.AvatarGroup.js +3 -3
- package/dist/Display/Display.Badge.d.ts +3 -3
- package/dist/Display/Display.Badge.js +1 -1
- package/dist/Display/Display.Card.d.ts +15 -15
- package/dist/Display/Display.Card.js +4 -4
- package/dist/Display/Display.Carousel.js +2 -2
- package/dist/Display/Display.Chip.d.ts +3 -3
- package/dist/Display/Display.Chip.js +12 -12
- package/dist/Display/Display.CircleButton.d.ts +1 -1
- package/dist/Display/Display.CircleButton.js +3 -3
- package/dist/Display/Display.CopyableText.js +2 -2
- package/dist/Display/Display.CountRecords.js +2 -2
- package/dist/Display/Display.DataTable.js +2 -2
- package/dist/Display/Display.Date.d.ts +1 -1
- package/dist/Display/Display.Date.js +5 -5
- package/dist/Display/Display.Divider.d.ts +24 -24
- package/dist/Display/Display.Divider.js +1 -1
- package/dist/Display/Display.GradientSurface.d.ts +58 -39
- package/dist/Display/Display.GradientSurface.js +31 -15
- package/dist/Display/Display.Icon.d.ts +1 -1
- package/dist/Display/Display.Icon.js +1 -1
- package/dist/Display/Display.IconBadge.js +3 -3
- package/dist/Display/Display.Image.js +4 -4
- package/dist/Display/Display.KeyValue.js +2 -2
- package/dist/Display/Display.ListItem.js +5 -5
- package/dist/Display/Display.Logo.d.ts +3 -3
- package/dist/Display/Display.Logo.js +2 -2
- package/dist/Display/Display.MediaCard.js +4 -4
- package/dist/Display/Display.MediaEmbed.js +7 -7
- package/dist/Display/Display.MenuButton.d.ts +4 -4
- package/dist/Display/Display.MenuButton.js +6 -6
- package/dist/Display/Display.MenuCard.d.ts +1 -1
- package/dist/Display/Display.MenuCard.js +3 -3
- package/dist/Display/Display.MenuGrid.d.ts +1 -1
- package/dist/Display/Display.MenuGrid.js +1 -1
- package/dist/Display/Display.Monetary.d.ts +1 -1
- package/dist/Display/Display.Monetary.js +2 -2
- package/dist/Display/Display.Pattern.d.ts +33 -12
- package/dist/Display/Display.Pattern.js +60 -14
- package/dist/Display/Display.PriceTag.js +2 -2
- package/dist/Display/Display.ProductCard.js +7 -7
- package/dist/Display/Display.Rating.js +3 -3
- package/dist/Display/Display.SearchHistory.js +6 -6
- package/dist/Display/Display.SectionHeader.js +4 -4
- package/dist/Display/Display.Stat.js +2 -2
- package/dist/Display/Display.StatCard.js +4 -4
- package/dist/Display/Display.StatusDot.js +3 -3
- package/dist/Display/Display.Story.js +3 -3
- package/dist/Display/Display.StoryTray.js +5 -5
- package/dist/Display/Display.StoryViewer.js +4 -4
- package/dist/Display/Display.SwipeableRow.js +4 -4
- package/dist/Display/Display.Tag.js +2 -2
- package/dist/Display/Display.Timeline.js +4 -4
- package/dist/Display/Display.Tooltip.js +3 -3
- package/dist/Display/index.d.ts +45 -45
- package/dist/Display/index.js +42 -42
- package/dist/Feedback/ErrorBoundary.d.ts +1 -1
- package/dist/Feedback/ErrorBoundary.js +1 -1
- package/dist/Feedback/Feedback.Banner.d.ts +3 -3
- package/dist/Feedback/Feedback.Banner.js +5 -5
- package/dist/Feedback/Feedback.DomainSplashScreen.js +5 -4
- package/dist/Feedback/Feedback.Empty.js +3 -3
- package/dist/Feedback/Feedback.EmptyState.js +5 -5
- package/dist/Feedback/Feedback.Error.js +4 -4
- package/dist/Feedback/Feedback.Loading.d.ts +1 -1
- package/dist/Feedback/Feedback.Loading.js +2 -2
- package/dist/Feedback/Feedback.PermissionCard.js +5 -5
- package/dist/Feedback/Feedback.Progress.js +2 -2
- package/dist/Feedback/Feedback.ProgressCircle.js +1 -1
- package/dist/Feedback/Feedback.Skeleton.js +2 -2
- package/dist/Feedback/Feedback.Spinner.js +3 -3
- package/dist/Feedback/Feedback.Splash.d.ts +1 -1
- package/dist/Feedback/Feedback.Splash.js +7 -6
- package/dist/Feedback/Toast.context.js +7 -7
- package/dist/Feedback/index.d.ts +13 -13
- package/dist/Feedback/index.js +13 -13
- package/dist/Form/Form.Button.d.ts +2 -2
- package/dist/Form/Form.Button.js +1 -1
- package/dist/Form/Form.Checkbox.js +4 -4
- package/dist/Form/Form.ControlledCheckbox.js +1 -1
- package/dist/Form/Form.ControlledInput.js +1 -1
- package/dist/Form/Form.ControlledMonetaryInput.js +1 -1
- package/dist/Form/Form.ControlledRadioButton.js +1 -1
- package/dist/Form/Form.DatePicker.js +5 -5
- package/dist/Form/Form.Dropdown.js +7 -7
- package/dist/Form/Form.FAB.d.ts +2 -2
- package/dist/Form/Form.FAB.js +1 -1
- package/dist/Form/Form.FilterButton.d.ts +2 -2
- package/dist/Form/Form.FilterButton.js +1 -1
- package/dist/Form/Form.FractionalQuantityInput.js +4 -4
- package/dist/Form/Form.IconButton.d.ts +2 -2
- package/dist/Form/Form.IconButton.js +1 -1
- package/dist/Form/Form.Input.js +4 -4
- package/dist/Form/Form.InputField.d.ts +1 -1
- package/dist/Form/Form.InputField.js +3 -3
- package/dist/Form/Form.MonetaryInput.js +5 -4
- package/dist/Form/Form.PasswordInput.d.ts +1 -1
- package/dist/Form/Form.PasswordInput.js +3 -3
- package/dist/Form/Form.PinInput.js +5 -5
- package/dist/Form/Form.QuantitySelector.js +3 -3
- package/dist/Form/Form.RadioButton.js +4 -4
- package/dist/Form/Form.SearchBar.js +4 -4
- package/dist/Form/Form.Select.js +6 -6
- package/dist/Form/Form.Slider.js +3 -3
- package/dist/Form/Form.Switch.js +4 -4
- package/dist/Form/Form.TextInput.js +3 -3
- package/dist/Form/index.d.ts +27 -27
- package/dist/Form/index.js +25 -25
- package/dist/Navigation/Navigation.AppBar.d.ts +5 -4
- package/dist/Navigation/Navigation.AppBar.js +10 -10
- package/dist/Navigation/Navigation.BottomNav.d.ts +1 -1
- package/dist/Navigation/Navigation.BottomNav.js +25 -16
- package/dist/Navigation/Navigation.CollapsingHeader.d.ts +1 -1
- package/dist/Navigation/Navigation.CollapsingHeader.js +3 -3
- package/dist/Navigation/Navigation.FloatingBar.js +2 -2
- package/dist/Navigation/Navigation.Header.js +6 -6
- package/dist/Navigation/Navigation.HeaderToolbar.js +5 -5
- package/dist/Navigation/Navigation.Menu.js +6 -6
- package/dist/Navigation/Navigation.MenuSection.js +2 -2
- package/dist/Navigation/Navigation.RowItem.d.ts +1 -1
- package/dist/Navigation/Navigation.RowItem.js +2 -2
- package/dist/Navigation/Navigation.SearchBar.js +6 -6
- package/dist/Navigation/Navigation.SegmentedControl.js +4 -4
- package/dist/Navigation/Navigation.Steps.js +5 -5
- package/dist/Navigation/Navigation.TabIcon.js +2 -2
- package/dist/Navigation/Navigation.TabItem.js +2 -2
- package/dist/Navigation/Navigation.Tabs.js +5 -5
- package/dist/Navigation/index.d.ts +19 -19
- package/dist/Navigation/index.js +15 -15
- package/dist/Typography/Typography.Heading.d.ts +1 -1
- package/dist/Typography/Typography.Heading.js +1 -1
- package/dist/Typography/Typography.Text.d.ts +2 -2
- package/dist/Typography/Typography.Text.js +8 -6
- package/dist/Typography/index.d.ts +2 -2
- package/dist/Typography/index.js +2 -2
- package/dist/branding.d.ts +22 -0
- package/dist/branding.js +20 -3
- package/dist/icons/AddItemIcon.d.ts +1 -1
- package/dist/icons/ArrangeCircle.d.ts +1 -1
- package/dist/icons/ArrowDownIcon.d.ts +1 -1
- package/dist/icons/ArrowUpIcon.d.ts +1 -1
- package/dist/icons/BoxIcon.d.ts +1 -1
- package/dist/icons/BoxTimeIcon.d.ts +1 -1
- package/dist/icons/CalendarIcon.d.ts +1 -1
- package/dist/icons/CardIcon.d.ts +1 -1
- package/dist/icons/CashierIcon.d.ts +1 -1
- package/dist/icons/DuoIcon.d.ts +1 -1
- package/dist/icons/HomeIcon.d.ts +1 -1
- package/dist/icons/HomeIconOutlined.d.ts +1 -1
- package/dist/icons/LogoIcon.d.ts +1 -1
- package/dist/icons/MoneyReceiveIcon.d.ts +1 -1
- package/dist/icons/PinIcon.d.ts +1 -1
- package/dist/icons/PrinterIcon.d.ts +1 -1
- package/dist/icons/ProfileIcon.d.ts +1 -1
- package/dist/icons/SettingsIcon.d.ts +1 -1
- package/dist/icons/SinpeIcon.d.ts +1 -1
- package/dist/icons/ToggleOffIcon.d.ts +1 -1
- package/dist/icons/WalletMoneyIcon.d.ts +1 -1
- package/dist/index.d.ts +24 -23
- package/dist/index.js +26 -24
- package/dist/layouts/AuthContainer.d.ts +5 -2
- package/dist/layouts/AuthContainer.js +6 -6
- package/dist/layouts/Container.js +1 -1
- package/dist/layouts/GradientContainer.js +1 -1
- package/dist/layouts/ScrollContainer.js +1 -1
- package/dist/layouts/TabNavigatorLayout.js +4 -4
- package/dist/primitives/AspectRatio.js +1 -1
- package/dist/primitives/BaseButton.d.ts +85 -85
- package/dist/primitives/BaseButton.js +34 -50
- package/dist/primitives/Box.js +1 -1
- package/dist/primitives/Pressable.js +1 -1
- package/dist/primitives/Row.js +1 -1
- package/dist/primitives/Stack.js +1 -1
- package/dist/primitives/index.d.ts +6 -6
- package/dist/primitives/index.js +6 -6
- package/dist/theme/active.d.ts +1 -1
- package/dist/theme/active.js +14 -1
- package/dist/theme/build.d.ts +33 -0
- package/dist/theme/build.js +118 -0
- package/dist/theme/color.d.ts +26 -0
- package/dist/theme/color.js +109 -0
- package/dist/theme/components/index.d.ts +1 -1
- package/dist/theme/components/index.js +1 -1
- package/dist/theme/contrast.d.ts +29 -0
- package/dist/theme/contrast.js +57 -0
- package/dist/theme/css-vars.d.ts +3 -1
- package/dist/theme/css-vars.js +29 -3
- package/dist/theme/dark.d.ts +3 -4
- package/dist/theme/dark.js +91 -48
- package/dist/theme/default.d.ts +5 -1
- package/dist/theme/default.js +89 -41
- package/dist/theme/define.d.ts +4 -1
- package/dist/theme/define.js +4 -1
- package/dist/theme/globals.css +61 -46
- package/dist/theme/index.d.ts +14 -10
- package/dist/theme/index.js +13 -9
- package/dist/theme/theme.d.ts +1 -1
- package/dist/theme/theme.js +2 -2
- package/dist/theme/types.d.ts +77 -16
- package/dist/theme/types.js +13 -3
- package/dist/theme/typography.d.ts +4 -4
- package/dist/theme/typography.js +26 -28
- package/dist/theme/useTheme.d.ts +1 -1
- package/dist/theme/useTheme.js +1 -1
- package/dist/theme/validate.d.ts +16 -0
- package/dist/theme/validate.js +200 -0
- package/dist/tokens/index.d.ts +2 -2
- package/dist/tokens/index.js +2 -2
- package/dist/views/AppSplashView.d.ts +2 -2
- package/dist/views/AppSplashView.js +3 -3
- package/dist/views/AuthFormView.d.ts +1 -1
- package/dist/views/AuthFormView.js +3 -3
- package/dist/views/FormViewV2.d.ts +2 -2
- package/dist/views/FormViewV2.js +9 -9
- package/dist/views/ListViewV2.d.ts +3 -3
- package/dist/views/ListViewV2.js +16 -16
- package/dist/views/Wizard/Wizard.context.js +1 -1
- package/dist/views/Wizard/Wizard.d.ts +1 -1
- package/dist/views/Wizard/Wizard.js +1 -1
- package/dist/views/Wizard/index.d.ts +4 -4
- package/dist/views/Wizard/index.js +2 -2
- package/dist/views/types/IFormView.d.ts +1 -1
- package/dist/views/types/IListView.d.ts +1 -1
- package/dist/widgets/CircleButton.d.ts +2 -2
- package/dist/widgets/CircleButton.js +1 -1
- package/dist/widgets/GeoPermissionCard.js +3 -3
- package/dist/widgets/HomeHeader.js +3 -3
- package/dist/widgets/JSONViewer.js +2 -2
- package/dist/widgets/MenuCard.d.ts +2 -2
- package/dist/widgets/MenuCard.js +1 -1
- package/dist/widgets/MenuGrid.d.ts +3 -3
- package/dist/widgets/MenuGrid.js +1 -1
- package/dist/widgets/MenuSection.d.ts +2 -2
- package/dist/widgets/MenuSection.js +1 -1
- package/dist/widgets/PromoBanner.js +3 -3
- package/dist/widgets/PromoModal.js +3 -3
- package/dist/widgets/QuickActions.js +3 -3
- package/dist/widgets/ScreenHeader.js +2 -2
- package/dist/widgets/TimeZoneSelector.d.ts +1 -1
- package/dist/widgets/TimeZoneSelector.js +4 -4
- package/dist/widgets/TimeZoneSelectorModal.d.ts +1 -1
- package/dist/widgets/TimeZoneSelectorModal.js +5 -5
- package/dist/widgets/index.d.ts +16 -16
- package/dist/widgets/index.js +10 -10
- package/package.json +56 -50
- package/tailwind.preset.js +19 -0
- package/dist/icons/icon_getters.d.ts +0 -6
- package/dist/icons/icon_getters.js +0 -23
|
@@ -1,36 +1,36 @@
|
|
|
1
|
-
import BottomNav from "
|
|
2
|
-
import CollapsingHeader from "
|
|
3
|
-
import FloatingBar from "
|
|
4
|
-
import HeaderToolbar from "
|
|
5
|
-
import Menu from "
|
|
6
|
-
import { MenuSection } from "
|
|
7
|
-
import RowItem from "
|
|
8
|
-
import SearchBar from "
|
|
9
|
-
import SegmentedControl from "
|
|
10
|
-
import Steps from "
|
|
11
|
-
import TabIcon from "
|
|
12
|
-
export type { AppBarBackground } from "
|
|
13
|
-
export type { MenuSectionProps } from "
|
|
1
|
+
import BottomNav from "./Navigation.BottomNav.js";
|
|
2
|
+
import CollapsingHeader from "./Navigation.CollapsingHeader.js";
|
|
3
|
+
import FloatingBar from "./Navigation.FloatingBar.js";
|
|
4
|
+
import HeaderToolbar from "./Navigation.HeaderToolbar.js";
|
|
5
|
+
import Menu from "./Navigation.Menu.js";
|
|
6
|
+
import { MenuSection } from "./Navigation.MenuSection.js";
|
|
7
|
+
import RowItem from "./Navigation.RowItem.js";
|
|
8
|
+
import SearchBar from "./Navigation.SearchBar.js";
|
|
9
|
+
import SegmentedControl from "./Navigation.SegmentedControl.js";
|
|
10
|
+
import Steps from "./Navigation.Steps.js";
|
|
11
|
+
import TabIcon from "./Navigation.TabIcon.js";
|
|
12
|
+
export type { AppBarBackground } from "./Navigation.AppBar.js";
|
|
13
|
+
export type { MenuSectionProps } from "./Navigation.MenuSection.js";
|
|
14
14
|
export declare const Navigation: {
|
|
15
|
-
AppBar: (({ title, subtitle, onBack, leading, actions, subheader, variant, tone, accentBar, backVariant, border, safeArea, topSpacing, background, bottomDivider, className, testID, }: import("
|
|
16
|
-
Action: ({ icon, label, onPress, badge, accessibilityLabel, tone, onDark, bare, testID, }: import("
|
|
15
|
+
AppBar: (({ title, subtitle, onBack, leading, actions, subheader, variant, tone, accentBar, backVariant, border, safeArea, topSpacing, background, bottomDivider, className, testID, }: import("./Navigation.AppBar.js").AppBarProps) => import("react").JSX.Element) & {
|
|
16
|
+
Action: ({ icon, label, onPress, badge, accessibilityLabel, tone, onDark, bare, testID, }: import("./Navigation.AppBar.js").AppBarActionProps) => import("react").JSX.Element;
|
|
17
17
|
};
|
|
18
18
|
BottomNav: typeof BottomNav;
|
|
19
19
|
CollapsingHeader: typeof CollapsingHeader;
|
|
20
20
|
FloatingBar: typeof FloatingBar;
|
|
21
21
|
SearchBar: typeof SearchBar;
|
|
22
|
-
Header: ({ title, logo, logoSource, backButton, handleBackButton, className, }: import("
|
|
22
|
+
Header: ({ title, logo, logoSource, backButton, handleBackButton, className, }: import("./Navigation.Header.js").HeaderProps) => import("react").JSX.Element;
|
|
23
23
|
HeaderToolbar: typeof HeaderToolbar;
|
|
24
|
-
TabItem: import("react").FC<import("
|
|
24
|
+
TabItem: import("react").FC<import("./Navigation.TabItem.js").TabIconProps>;
|
|
25
25
|
TabIcon: typeof TabIcon;
|
|
26
26
|
RowItem: typeof RowItem;
|
|
27
27
|
SegmentedControl: typeof SegmentedControl;
|
|
28
|
-
Tabs: (({ value, defaultValue, onValueChange, variant, className, children, }: import("
|
|
28
|
+
Tabs: (({ value, defaultValue, onValueChange, variant, className, children, }: import("./Navigation.Tabs.js").TabsProps) => import("react").JSX.Element) & {
|
|
29
29
|
List: ({ children, className }: {
|
|
30
30
|
children: import("react").ReactNode;
|
|
31
31
|
className?: string;
|
|
32
32
|
}) => import("react").JSX.Element;
|
|
33
|
-
Trigger: ({ value, children, icon, iconLayout }: import("
|
|
33
|
+
Trigger: ({ value, children, icon, iconLayout }: import("./Navigation.Tabs.js").TabsTriggerProps) => import("react").JSX.Element;
|
|
34
34
|
Content: ({ value, children }: {
|
|
35
35
|
value: string;
|
|
36
36
|
children: import("react").ReactNode;
|
package/dist/Navigation/index.js
CHANGED
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
import AppBar from "
|
|
2
|
-
import BottomNav from "
|
|
3
|
-
import CollapsingHeader from "
|
|
4
|
-
import FloatingBar from "
|
|
5
|
-
import Header from "
|
|
6
|
-
import HeaderToolbar from "
|
|
7
|
-
import Menu from "
|
|
8
|
-
import { MenuSection } from "
|
|
9
|
-
import RowItem from "
|
|
10
|
-
import SearchBar from "
|
|
11
|
-
import SegmentedControl from "
|
|
12
|
-
import Steps from "
|
|
13
|
-
import TabIcon from "
|
|
14
|
-
import TabItem from "
|
|
15
|
-
import Tabs from "
|
|
1
|
+
import AppBar from "./Navigation.AppBar.js";
|
|
2
|
+
import BottomNav from "./Navigation.BottomNav.js";
|
|
3
|
+
import CollapsingHeader from "./Navigation.CollapsingHeader.js";
|
|
4
|
+
import FloatingBar from "./Navigation.FloatingBar.js";
|
|
5
|
+
import Header from "./Navigation.Header.js";
|
|
6
|
+
import HeaderToolbar from "./Navigation.HeaderToolbar.js";
|
|
7
|
+
import Menu from "./Navigation.Menu.js";
|
|
8
|
+
import { MenuSection } from "./Navigation.MenuSection.js";
|
|
9
|
+
import RowItem from "./Navigation.RowItem.js";
|
|
10
|
+
import SearchBar from "./Navigation.SearchBar.js";
|
|
11
|
+
import SegmentedControl from "./Navigation.SegmentedControl.js";
|
|
12
|
+
import Steps from "./Navigation.Steps.js";
|
|
13
|
+
import TabIcon from "./Navigation.TabIcon.js";
|
|
14
|
+
import TabItem from "./Navigation.TabItem.js";
|
|
15
|
+
import Tabs from "./Navigation.Tabs.js";
|
|
16
16
|
export const Navigation = {
|
|
17
17
|
AppBar,
|
|
18
18
|
BottomNav,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx } from "nativewind/jsx-runtime";
|
|
2
|
-
import { AppText } from "
|
|
2
|
+
import { AppText } from "./Typography.Text.js";
|
|
3
3
|
const Heading = ({ variant = "h1", ...props }) => {
|
|
4
4
|
return _jsx(AppText, { variant: variant, ...props });
|
|
5
5
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { typographyVariants } from "../theme/typography";
|
|
1
|
+
import { typographyVariants } from "../theme/typography.js";
|
|
2
2
|
import type React from "react";
|
|
3
3
|
import { type TextProps } from "react-native";
|
|
4
4
|
/**
|
|
@@ -9,7 +9,7 @@ import { type TextProps } from "react-native";
|
|
|
9
9
|
*
|
|
10
10
|
* Reason: Custom fonts (Montserrat) not in Tailwind, complex typography system
|
|
11
11
|
*
|
|
12
|
-
* @deprecated color prop - Use className instead: className="text-primary" or className="text-text-
|
|
12
|
+
* @deprecated color prop - Use className instead: e.g. className="text-text-primary" or className="text-text-accent"
|
|
13
13
|
*/
|
|
14
14
|
interface AppTextProps extends TextProps {
|
|
15
15
|
variant?: keyof typeof typographyVariants;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { jsx as _jsx } from "nativewind/jsx-runtime";
|
|
2
|
-
import { cn } from "../theme/tw";
|
|
3
|
-
import { fontFamilies, Typography, variantFontRole, } from "../theme/typography";
|
|
2
|
+
import { cn } from "../theme/tw.js";
|
|
3
|
+
import { fontFamilies, Typography, variantFontRole, } from "../theme/typography.js";
|
|
4
4
|
import { Text } from "react-native";
|
|
5
5
|
function AppText({ variant = "body", color, bold = false, italic = false, underline = false, align = "left", transform = "none", semibold = false, style, className, children, ...props }) {
|
|
6
6
|
const baseStyle = Typography.variants[variant];
|
|
@@ -9,10 +9,12 @@ function AppText({ variant = "body", color, bold = false, italic = false, underl
|
|
|
9
9
|
// `configureFonts(...)` (app/Storybook) takes effect. Falls back to the variant's baked
|
|
10
10
|
// family if a role is somehow missing.
|
|
11
11
|
const variantFamily = fontFamilies[variantFontRole[variant]] ?? baseStyle.fontFamily;
|
|
12
|
-
// `bold`/`semibold` map to the
|
|
13
|
-
// face (a configured title face, or
|
|
14
|
-
// forcing
|
|
15
|
-
const isBrandedFace = typeof variantFamily === "string" &&
|
|
12
|
+
// `bold`/`semibold` map to the IBM Plex Sans weights — but NOT when the active family is a
|
|
13
|
+
// branded face (a configured title face, or IBM Plex Mono): those carry their own weight, so
|
|
14
|
+
// forcing Plex Sans would erase the typeface. Keep the variant's family for those.
|
|
15
|
+
const isBrandedFace = typeof variantFamily === "string" &&
|
|
16
|
+
!variantFamily.startsWith("Inter_") &&
|
|
17
|
+
!variantFamily.startsWith("IBMPlexSans_");
|
|
16
18
|
const textStyle = {
|
|
17
19
|
...baseStyle,
|
|
18
20
|
...(color ? { color } : {}),
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { AppText } from "
|
|
1
|
+
import { AppText } from "./Typography.Text.js";
|
|
2
2
|
export declare const Typography: {
|
|
3
3
|
Text: typeof AppText;
|
|
4
|
-
Heading: import("react").FC<import("
|
|
4
|
+
Heading: import("react").FC<import("./Typography.Heading.js").TypographyProps>;
|
|
5
5
|
};
|
|
6
6
|
export { AppText };
|
|
7
7
|
export default Typography;
|
package/dist/Typography/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import Heading from "
|
|
2
|
-
import { AppText } from "
|
|
1
|
+
import Heading from "./Typography.Heading.js";
|
|
2
|
+
import { AppText } from "./Typography.Text.js";
|
|
3
3
|
export const Typography = {
|
|
4
4
|
Text: AppText,
|
|
5
5
|
Heading,
|
package/dist/branding.d.ts
CHANGED
|
@@ -1,6 +1,28 @@
|
|
|
1
1
|
import { type ImageSourcePropType } from "react-native";
|
|
2
|
+
/**
|
|
3
|
+
* Centralized brand assets. Set once at app boot via `setBranding({ ... })`. Components
|
|
4
|
+
* that need the brand logo or mesh symbol read these getters — no need to thread an
|
|
5
|
+
* asset through every consumer.
|
|
6
|
+
*
|
|
7
|
+
* @example
|
|
8
|
+
* // app boot (e.g. createAppShell / app entrypoint)
|
|
9
|
+
* setBranding({
|
|
10
|
+
* logo: require("./assets/logo.png"),
|
|
11
|
+
* mesh: require("./assets/brand-mesh.png"),
|
|
12
|
+
* meshSize: 56,
|
|
13
|
+
* });
|
|
14
|
+
*/
|
|
2
15
|
export interface BrandingConfig {
|
|
16
|
+
/** Brand logo (used by `Display.Logo`, `widgets.ScreenHeader`, etc.). */
|
|
3
17
|
logo?: ImageSourcePropType;
|
|
18
|
+
/** Brand symbol / icon used by `Display.Pattern kind="mesh"` as the tiled texture. */
|
|
19
|
+
mesh?: ImageSourcePropType;
|
|
20
|
+
/** Tile size in px (overrides `theme.pattern.size` for the brand mesh). */
|
|
21
|
+
meshSize?: number;
|
|
4
22
|
}
|
|
5
23
|
export declare function setBranding(config: BrandingConfig): void;
|
|
6
24
|
export declare function getBrandingLogo(): ImageSourcePropType | undefined;
|
|
25
|
+
export declare function getBrandingMesh(): ImageSourcePropType | undefined;
|
|
26
|
+
export declare function getBrandingMeshSize(): number | undefined;
|
|
27
|
+
/** Test-only — reset to initial empty state. Not part of the public API. */
|
|
28
|
+
export declare function __resetBranding(): void;
|
package/dist/branding.js
CHANGED
|
@@ -1,7 +1,24 @@
|
|
|
1
|
-
|
|
1
|
+
const state = { logo: undefined, mesh: undefined, meshSize: undefined };
|
|
2
2
|
export function setBranding(config) {
|
|
3
|
-
|
|
3
|
+
if (config.logo !== undefined)
|
|
4
|
+
state.logo = config.logo;
|
|
5
|
+
if (config.mesh !== undefined)
|
|
6
|
+
state.mesh = config.mesh;
|
|
7
|
+
if (config.meshSize !== undefined)
|
|
8
|
+
state.meshSize = config.meshSize;
|
|
4
9
|
}
|
|
5
10
|
export function getBrandingLogo() {
|
|
6
|
-
return
|
|
11
|
+
return state.logo;
|
|
12
|
+
}
|
|
13
|
+
export function getBrandingMesh() {
|
|
14
|
+
return state.mesh;
|
|
15
|
+
}
|
|
16
|
+
export function getBrandingMeshSize() {
|
|
17
|
+
return state.meshSize;
|
|
18
|
+
}
|
|
19
|
+
/** Test-only — reset to initial empty state. Not part of the public API. */
|
|
20
|
+
export function __resetBranding() {
|
|
21
|
+
state.logo = undefined;
|
|
22
|
+
state.mesh = undefined;
|
|
23
|
+
state.meshSize = undefined;
|
|
7
24
|
}
|
package/dist/icons/BoxIcon.d.ts
CHANGED
package/dist/icons/CardIcon.d.ts
CHANGED
package/dist/icons/DuoIcon.d.ts
CHANGED
package/dist/icons/HomeIcon.d.ts
CHANGED
package/dist/icons/LogoIcon.d.ts
CHANGED
package/dist/icons/PinIcon.d.ts
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -1,23 +1,24 @@
|
|
|
1
|
-
export { Actions } from "./Actions";
|
|
2
|
-
export { Dialog } from "./Dialog";
|
|
3
|
-
export { Display } from "./Display";
|
|
4
|
-
export { Feedback } from "./Feedback";
|
|
5
|
-
export { Form } from "./Form";
|
|
6
|
-
export { Navigation } from "./Navigation";
|
|
7
|
-
export { Typography } from "./Typography";
|
|
8
|
-
export { Box, Row, Stack } from "./primitives";
|
|
9
|
-
export { type BrandingConfig, getBrandingLogo, setBranding, } from "./branding";
|
|
10
|
-
export { cn, tv, type VariantProps } from "./theme/tw";
|
|
11
|
-
export { fontFamilies, fontSizes, fontWeights, letterSpacing, lineHeights, typographyVariants, } from "./theme/typography";
|
|
12
|
-
export { BottomInsetContext } from "./layouts/BottomInset";
|
|
13
|
-
export { default as Container } from "./layouts/Container";
|
|
14
|
-
export { default as GradientContainer } from "./layouts/GradientContainer";
|
|
15
|
-
export { default as PlainLayout } from "./layouts/PlainLayout";
|
|
16
|
-
export { default as ScrollContainer } from "./layouts/ScrollContainer";
|
|
17
|
-
export { default as TabNavigatorLayout } from "./layouts/TabNavigatorLayout";
|
|
18
|
-
export { default as
|
|
19
|
-
export { default as
|
|
20
|
-
export { default as
|
|
21
|
-
export { default as
|
|
22
|
-
export { default as
|
|
23
|
-
export
|
|
1
|
+
export { Actions } from "./Actions/index.js";
|
|
2
|
+
export { Dialog } from "./Dialog/index.js";
|
|
3
|
+
export { Display } from "./Display/index.js";
|
|
4
|
+
export { Feedback } from "./Feedback/index.js";
|
|
5
|
+
export { Form } from "./Form/index.js";
|
|
6
|
+
export { Navigation } from "./Navigation/index.js";
|
|
7
|
+
export { Typography } from "./Typography/index.js";
|
|
8
|
+
export { Box, Row, Stack } from "./primitives/index.js";
|
|
9
|
+
export { type BrandingConfig, getBrandingLogo, getBrandingMesh, getBrandingMeshSize, setBranding, } from "./branding.js";
|
|
10
|
+
export { cn, tv, type VariantProps } from "./theme/tw.js";
|
|
11
|
+
export { fontFamilies, fontSizes, fontWeights, letterSpacing, lineHeights, typographyVariants, } from "./theme/typography.js";
|
|
12
|
+
export { BottomInsetContext } from "./layouts/BottomInset.js";
|
|
13
|
+
export { default as Container } from "./layouts/Container.js";
|
|
14
|
+
export { default as GradientContainer } from "./layouts/GradientContainer.js";
|
|
15
|
+
export { default as PlainLayout } from "./layouts/PlainLayout.js";
|
|
16
|
+
export { default as ScrollContainer } from "./layouts/ScrollContainer.js";
|
|
17
|
+
export { default as TabNavigatorLayout } from "./layouts/TabNavigatorLayout.js";
|
|
18
|
+
export { default as AppSplashView } from "./views/AppSplashView.js";
|
|
19
|
+
export { default as AuthFormView } from "./views/AuthFormView.js";
|
|
20
|
+
export { default as FormViewV2 } from "./views/FormViewV2.js";
|
|
21
|
+
export { default as ListViewV2 } from "./views/ListViewV2.js";
|
|
22
|
+
export { default as JSONViewer } from "./widgets/JSONViewer.js";
|
|
23
|
+
export { default as ScreenHeader } from "./widgets/ScreenHeader.js";
|
|
24
|
+
export * from "./widgets/ScreenHeader.js";
|
package/dist/index.js
CHANGED
|
@@ -1,30 +1,32 @@
|
|
|
1
1
|
// Design System - Compound Components
|
|
2
|
-
export { Actions } from "./Actions";
|
|
3
|
-
export { Dialog } from "./Dialog";
|
|
4
|
-
export { Display } from "./Display";
|
|
5
|
-
export { Feedback } from "./Feedback";
|
|
6
|
-
export { Form } from "./Form";
|
|
7
|
-
export { Navigation } from "./Navigation";
|
|
8
|
-
export { Typography } from "./Typography";
|
|
2
|
+
export { Actions } from "./Actions/index.js";
|
|
3
|
+
export { Dialog } from "./Dialog/index.js";
|
|
4
|
+
export { Display } from "./Display/index.js";
|
|
5
|
+
export { Feedback } from "./Feedback/index.js";
|
|
6
|
+
export { Form } from "./Form/index.js";
|
|
7
|
+
export { Navigation } from "./Navigation/index.js";
|
|
8
|
+
export { Typography } from "./Typography/index.js";
|
|
9
9
|
// Primitives (NativeWind-based - Layout utilities)
|
|
10
|
-
export { Box, Row, Stack } from "./primitives";
|
|
11
|
-
// Branding (logo
|
|
12
|
-
|
|
10
|
+
export { Box, Row, Stack } from "./primitives/index.js";
|
|
11
|
+
// Branding (logo + brand mesh symbol, configurado una vez; Display.Logo y
|
|
12
|
+
// Display.Pattern leen de acá como fallback)
|
|
13
|
+
export { getBrandingLogo, getBrandingMesh, getBrandingMeshSize, setBranding, } from "./branding.js";
|
|
13
14
|
// Theme
|
|
14
|
-
export { cn, tv } from "./theme/tw";
|
|
15
|
-
export { fontFamilies, fontSizes, fontWeights, letterSpacing, lineHeights, typographyVariants, } from "./theme/typography";
|
|
15
|
+
export { cn, tv } from "./theme/tw.js";
|
|
16
|
+
export { fontFamilies, fontSizes, fontWeights, letterSpacing, lineHeights, typographyVariants, } from "./theme/typography.js";
|
|
16
17
|
// Layouts
|
|
17
|
-
export { BottomInsetContext } from "./layouts/BottomInset";
|
|
18
|
-
export { default as Container } from "./layouts/Container";
|
|
19
|
-
export { default as GradientContainer } from "./layouts/GradientContainer";
|
|
20
|
-
export { default as PlainLayout } from "./layouts/PlainLayout";
|
|
21
|
-
export { default as ScrollContainer } from "./layouts/ScrollContainer";
|
|
22
|
-
export { default as TabNavigatorLayout } from "./layouts/TabNavigatorLayout";
|
|
18
|
+
export { BottomInsetContext } from "./layouts/BottomInset.js";
|
|
19
|
+
export { default as Container } from "./layouts/Container.js";
|
|
20
|
+
export { default as GradientContainer } from "./layouts/GradientContainer.js";
|
|
21
|
+
export { default as PlainLayout } from "./layouts/PlainLayout.js";
|
|
22
|
+
export { default as ScrollContainer } from "./layouts/ScrollContainer.js";
|
|
23
|
+
export { default as TabNavigatorLayout } from "./layouts/TabNavigatorLayout.js";
|
|
23
24
|
// Views
|
|
24
|
-
export { default as
|
|
25
|
-
export { default as
|
|
26
|
-
export { default as
|
|
25
|
+
export { default as AppSplashView } from "./views/AppSplashView.js";
|
|
26
|
+
export { default as AuthFormView } from "./views/AuthFormView.js";
|
|
27
|
+
export { default as FormViewV2 } from "./views/FormViewV2.js";
|
|
28
|
+
export { default as ListViewV2 } from "./views/ListViewV2.js";
|
|
27
29
|
// Widgets
|
|
28
|
-
export { default as JSONViewer } from "./widgets/JSONViewer";
|
|
29
|
-
export { default as ScreenHeader } from "./widgets/ScreenHeader";
|
|
30
|
-
export * from "./widgets/ScreenHeader";
|
|
30
|
+
export { default as JSONViewer } from "./widgets/JSONViewer.js";
|
|
31
|
+
export { default as ScreenHeader } from "./widgets/ScreenHeader.js";
|
|
32
|
+
export * from "./widgets/ScreenHeader.js";
|
|
@@ -1,11 +1,14 @@
|
|
|
1
|
-
import type { AppBarBackground } from "../Navigation/Navigation.AppBar";
|
|
1
|
+
import type { AppBarBackground } from "../Navigation/Navigation.AppBar.js";
|
|
2
2
|
import { ReactNode } from "react";
|
|
3
3
|
interface AuthContainerProps {
|
|
4
4
|
header: ReactNode;
|
|
5
5
|
children: ReactNode;
|
|
6
6
|
onBackPress?: () => void;
|
|
7
7
|
className?: string;
|
|
8
|
-
/** Gradient +
|
|
8
|
+
/** Gradient + optional texture surface for the header area. Defaults to the `warm`
|
|
9
|
+
* preset. Set `background.pattern` to opt-in a texture (`dots` / `grid` /
|
|
10
|
+
* `diagonals`); compose `<Display.Pattern kind="mesh" />` outside if you want the
|
|
11
|
+
* brand symbol. */
|
|
9
12
|
background?: AppBarBackground;
|
|
10
13
|
}
|
|
11
14
|
declare function AuthContainer({ header, children, onBackPress, background, className, }: AuthContainerProps): import("react").JSX.Element;
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "nativewind/jsx-runtime";
|
|
2
|
-
import { Display } from "../Display";
|
|
3
|
-
import GradientSurface from "../Display/Display.GradientSurface";
|
|
4
|
-
import { Pattern } from "../Display/Display.Pattern";
|
|
5
|
-
import { useTheme } from "../theme";
|
|
6
|
-
import { cn } from "../theme/tw";
|
|
2
|
+
import { Display } from "../Display/index.js";
|
|
3
|
+
import GradientSurface from "../Display/Display.GradientSurface.js";
|
|
4
|
+
import { Pattern } from "../Display/Display.Pattern.js";
|
|
5
|
+
import { useTheme } from "../theme/index.js";
|
|
6
|
+
import { cn } from "../theme/tw.js";
|
|
7
7
|
import { Keyboard, TouchableOpacity, TouchableWithoutFeedback, useWindowDimensions, View, } from "react-native";
|
|
8
8
|
import { KeyboardAwareScrollView } from "react-native-keyboard-controller";
|
|
9
9
|
import { SafeAreaView } from "react-native-safe-area-context";
|
|
10
10
|
function AuthContainer({ header, children, onBackPress, background, className, }) {
|
|
11
11
|
const { height: screenHeight } = useWindowDimensions();
|
|
12
12
|
const theme = useTheme();
|
|
13
|
-
return (_jsxs(GradientSurface, { className: cn("flex-1", className), colors: background?.colors, end: background?.end ?? (background?.colors ? { x: 0, y: 1 } : undefined), preset: background?.surface ?? "
|
|
13
|
+
return (_jsxs(GradientSurface, { className: cn("flex-1", className), colors: background?.colors, end: background?.end ?? (background?.colors ? { x: 0, y: 1 } : undefined), preset: background?.surface ?? "warm", radius: "none", start: background?.start ?? (background?.colors ? { x: 0, y: 0 } : undefined), style: { flex: 1 }, children: [background?.pattern ? (_jsx(Pattern, { color: background.patternColor ?? "#FFFFFF", kind: background.pattern, opacity: background.patternOpacity ?? 0.18 })) : null, _jsx(SafeAreaView, { className: "flex-1", edges: ["top"], children: _jsxs(View, { className: "flex-1", children: [_jsx(TouchableWithoutFeedback, { onPress: Keyboard.dismiss, children: _jsxs(View, { className: "justify-center items-center relative", style: { height: screenHeight * 0.3 }, children: [onBackPress && (_jsx(TouchableOpacity, { className: "absolute top-4 left-4 p-2 z-[1]", onPress: onBackPress, children: _jsx(Display.Icon, { color: background?.textColor ?? theme.text.inverse, name: "arrow-back", size: 24, type: "ionicons" }) })), header] }) }), _jsx(View, { className: "flex-1 bg-bg-card rounded-t-3xl shadow-lg", style: { minHeight: screenHeight * 0.7 }, children: _jsx(KeyboardAwareScrollView, { bottomOffset: 50, bounces: false, className: "flex-1", contentContainerClassName: "flex-grow pb-10", keyboardShouldPersistTaps: "handled", showsVerticalScrollIndicator: false, children: _jsx(View, { className: "p-4", children: children }) }) })] }) })] }));
|
|
14
14
|
}
|
|
15
15
|
export default AuthContainer;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "nativewind/jsx-runtime";
|
|
2
|
-
import { cn } from "../theme/tw";
|
|
2
|
+
import { cn } from "../theme/tw.js";
|
|
3
3
|
import { StatusBar } from "react-native";
|
|
4
4
|
import { SafeAreaView } from "react-native-safe-area-context";
|
|
5
5
|
const Container = ({ children, style, barStyle = "light-content", statusBarHidden = false, edges = ["top", "bottom", "left", "right"], className, }) => {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx } from "nativewind/jsx-runtime";
|
|
2
|
-
import { theme } from "../theme";
|
|
2
|
+
import { theme } from "../theme/index.js";
|
|
3
3
|
import { LinearGradient } from "expo-linear-gradient";
|
|
4
4
|
const GradientContainer = ({ children, style, className }) => {
|
|
5
5
|
const gradientColors = theme.gradient.primary;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs } from "nativewind/jsx-runtime";
|
|
2
|
-
import { cn } from "../theme/tw";
|
|
2
|
+
import { cn } from "../theme/tw.js";
|
|
3
3
|
import { KeyboardAvoidingView, Platform, ScrollView, StatusBar, View } from "react-native";
|
|
4
4
|
import { SafeAreaView } from "react-native-safe-area-context";
|
|
5
5
|
function ScrollContainer({ children, contentContainerStyle = {}, className, }) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "nativewind/jsx-runtime";
|
|
2
|
-
import DisplayIcon from "../Display/Display.Icon";
|
|
3
|
-
import Container from "
|
|
4
|
-
import { Typography } from "../Typography";
|
|
2
|
+
import DisplayIcon from "../Display/Display.Icon.js";
|
|
3
|
+
import Container from "./Container.js";
|
|
4
|
+
import { Typography } from "../Typography/index.js";
|
|
5
5
|
import { Children, isValidElement } from "react";
|
|
6
6
|
import { TouchableOpacity, View } from "react-native";
|
|
7
7
|
import { useSafeAreaInsets } from "react-native-safe-area-context";
|
|
@@ -21,7 +21,7 @@ function TabNavigator({ items, currentPath, onTabPress, }) {
|
|
|
21
21
|
return;
|
|
22
22
|
}
|
|
23
23
|
onTabPress?.(path);
|
|
24
|
-
}, children: [_jsx(TabIcon, { focused: focused, Icon: Icon }), _jsx(Text, { className: `text-xs mt-1.5 font-medium ${focused ? "text-
|
|
24
|
+
}, children: [_jsx(TabIcon, { focused: focused, Icon: Icon }), _jsx(Text, { className: `text-xs mt-1.5 font-medium ${focused ? "text-text-accent" : "text-text-secondary"}`, children: label })] }, path));
|
|
25
25
|
}) }) }));
|
|
26
26
|
}
|
|
27
27
|
function Tabs({ children: tabsChildren }) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { jsx as _jsx } from "nativewind/jsx-runtime";
|
|
2
|
-
import { cn } from "../theme/tw";
|
|
2
|
+
import { cn } from "../theme/tw.js";
|
|
3
3
|
import { View } from "react-native";
|
|
4
4
|
function AspectRatio({ ratio = 1, className, style, children, ...rest }) {
|
|
5
5
|
return (_jsx(View, { className: cn(className), style: [{ aspectRatio: ratio }, style], ...rest, children: children }));
|