@newtonedev/components 0.1.13 → 0.1.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/composites/actions/Button/Button.d.ts +17 -20
- package/dist/composites/actions/Button/Button.d.ts.map +1 -1
- package/dist/composites/actions/Button/Button.styles.d.ts +12 -24
- package/dist/composites/actions/Button/Button.styles.d.ts.map +1 -1
- package/dist/composites/actions/Button/Button.types.d.ts +14 -13
- package/dist/composites/actions/Button/Button.types.d.ts.map +1 -1
- package/dist/composites/actions/Button/index.d.ts +1 -1
- package/dist/composites/actions/Button/index.d.ts.map +1 -1
- package/dist/composites/branding/LogoMonogram/LogoMonogram.d.ts +10 -0
- package/dist/composites/branding/LogoMonogram/LogoMonogram.d.ts.map +1 -0
- package/dist/composites/branding/LogoMonogram/LogoMonogram.types.d.ts +35 -0
- package/dist/composites/branding/LogoMonogram/LogoMonogram.types.d.ts.map +1 -0
- package/dist/composites/branding/LogoMonogram/index.d.ts +3 -0
- package/dist/composites/branding/LogoMonogram/index.d.ts.map +1 -0
- package/dist/composites/branding/LogoWordmark/LogoWordmark.d.ts +9 -0
- package/dist/composites/branding/LogoWordmark/LogoWordmark.d.ts.map +1 -0
- package/dist/composites/branding/LogoWordmark/LogoWordmark.types.d.ts +26 -0
- package/dist/composites/branding/LogoWordmark/LogoWordmark.types.d.ts.map +1 -0
- package/dist/composites/branding/LogoWordmark/index.d.ts +3 -0
- package/dist/composites/branding/LogoWordmark/index.d.ts.map +1 -0
- package/dist/composites/display/Chip/Chip.d.ts +25 -0
- package/dist/composites/display/Chip/Chip.d.ts.map +1 -0
- package/dist/composites/display/Chip/Chip.styles.d.ts +29 -0
- package/dist/composites/display/Chip/Chip.styles.d.ts.map +1 -0
- package/dist/composites/display/Chip/Chip.types.d.ts +63 -0
- package/dist/composites/display/Chip/Chip.types.d.ts.map +1 -0
- package/dist/composites/display/Chip/index.d.ts +3 -0
- package/dist/composites/display/Chip/index.d.ts.map +1 -0
- package/dist/composites/form-controls/Select/Select.d.ts.map +1 -1
- package/dist/composites/form-controls/Select/Select.styles.d.ts +2 -2
- package/dist/composites/form-controls/Select/Select.styles.d.ts.map +1 -1
- package/dist/composites/form-controls/Select/SelectOption.d.ts.map +1 -1
- package/dist/composites/form-controls/TextInput/TextInput.d.ts.map +1 -1
- package/dist/composites/form-controls/TextInput/TextInput.styles.d.ts +2 -2
- package/dist/composites/form-controls/TextInput/TextInput.styles.d.ts.map +1 -1
- package/dist/composites/form-controls/Toggle/Toggle.d.ts.map +1 -1
- package/dist/composites/form-controls/Toggle/Toggle.styles.d.ts +2 -2
- package/dist/composites/form-controls/Toggle/Toggle.styles.d.ts.map +1 -1
- package/dist/composites/layout/AppShell/AppShell.d.ts.map +1 -1
- package/dist/composites/layout/AppShell/AppShell.styles.d.ts +2 -2
- package/dist/composites/layout/AppShell/AppShell.styles.d.ts.map +1 -1
- package/dist/composites/layout/Card/Card.d.ts.map +1 -1
- package/dist/composites/layout/Card/Card.styles.d.ts +2 -2
- package/dist/composites/layout/Card/Card.styles.d.ts.map +1 -1
- package/dist/composites/layout/ContentCard/ContentCard.d.ts +33 -0
- package/dist/composites/layout/ContentCard/ContentCard.d.ts.map +1 -0
- package/dist/composites/layout/ContentCard/ContentCard.styles.d.ts +10 -0
- package/dist/composites/layout/ContentCard/ContentCard.styles.d.ts.map +1 -0
- package/dist/composites/layout/ContentCard/ContentCard.types.d.ts +52 -0
- package/dist/composites/layout/ContentCard/ContentCard.types.d.ts.map +1 -0
- package/dist/composites/layout/ContentCard/index.d.ts +3 -0
- package/dist/composites/layout/ContentCard/index.d.ts.map +1 -0
- package/dist/composites/layout/Divider/Divider.d.ts +25 -0
- package/dist/composites/layout/Divider/Divider.d.ts.map +1 -0
- package/dist/composites/layout/Divider/Divider.styles.d.ts +8 -0
- package/dist/composites/layout/Divider/Divider.styles.d.ts.map +1 -0
- package/dist/composites/layout/Divider/Divider.types.d.ts +25 -0
- package/dist/composites/layout/Divider/Divider.types.d.ts.map +1 -0
- package/dist/composites/layout/Divider/index.d.ts +3 -0
- package/dist/composites/layout/Divider/index.d.ts.map +1 -0
- package/dist/composites/layout/Navbar/Navbar.d.ts.map +1 -1
- package/dist/composites/layout/Navbar/Navbar.styles.d.ts +4 -3
- package/dist/composites/layout/Navbar/Navbar.styles.d.ts.map +1 -1
- package/dist/composites/layout/Sidebar/Sidebar.d.ts.map +1 -1
- package/dist/composites/layout/Sidebar/Sidebar.styles.d.ts +4 -3
- package/dist/composites/layout/Sidebar/Sidebar.styles.d.ts.map +1 -1
- package/dist/composites/overlays/Popover/Popover.d.ts.map +1 -1
- package/dist/composites/overlays/Popover/Popover.styles.d.ts +2 -2
- package/dist/composites/overlays/Popover/Popover.styles.d.ts.map +1 -1
- package/dist/composites/range-inputs/ColorScaleSlider/ColorScaleSlider.d.ts.map +1 -1
- package/dist/composites/range-inputs/ColorScaleSlider/ColorScaleSlider.styles.d.ts +2 -2
- package/dist/composites/range-inputs/ColorScaleSlider/ColorScaleSlider.styles.d.ts.map +1 -1
- package/dist/composites/range-inputs/HueSlider/HueSlider.styles.d.ts +2 -2
- package/dist/composites/range-inputs/HueSlider/HueSlider.styles.d.ts.map +1 -1
- package/dist/composites/range-inputs/Slider/Slider.styles.d.ts +2 -2
- package/dist/composites/range-inputs/Slider/Slider.styles.d.ts.map +1 -1
- package/dist/index.cjs +935 -523
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +13 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +860 -473
- package/dist/index.js.map +1 -1
- package/dist/primitives/Frame/Frame.d.ts +1 -35
- package/dist/primitives/Frame/Frame.d.ts.map +1 -1
- package/dist/primitives/Frame/Frame.styles.d.ts +13 -4
- package/dist/primitives/Frame/Frame.styles.d.ts.map +1 -1
- package/dist/primitives/Frame/Frame.types.d.ts +99 -1
- package/dist/primitives/Frame/Frame.types.d.ts.map +1 -1
- package/dist/primitives/Frame/index.d.ts +1 -1
- package/dist/primitives/Frame/index.d.ts.map +1 -1
- package/dist/primitives/Icon/Icon.d.ts.map +1 -1
- package/dist/primitives/Icon/Icon.types.d.ts +2 -2
- package/dist/primitives/Icon/Icon.types.d.ts.map +1 -1
- package/dist/primitives/Text/Text.d.ts +5 -3
- package/dist/primitives/Text/Text.d.ts.map +1 -1
- package/dist/primitives/Text/Text.spans.d.ts.map +1 -1
- package/dist/primitives/Text/Text.types.d.ts +3 -6
- package/dist/primitives/Text/Text.types.d.ts.map +1 -1
- package/dist/primitives/Wrapper/Wrapper.d.ts +1 -1
- package/dist/primitives/Wrapper/Wrapper.d.ts.map +1 -1
- package/dist/primitives/Wrapper/Wrapper.styles.d.ts +9 -1
- package/dist/primitives/Wrapper/Wrapper.styles.d.ts.map +1 -1
- package/dist/primitives/Wrapper/Wrapper.types.d.ts +31 -1
- package/dist/primitives/Wrapper/Wrapper.types.d.ts.map +1 -1
- package/dist/registry/registry.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/composites/actions/Button/Button.styles.ts +90 -182
- package/src/composites/actions/Button/Button.tsx +37 -33
- package/src/composites/actions/Button/Button.types.ts +16 -15
- package/src/composites/actions/Button/index.ts +1 -1
- package/src/composites/branding/LogoMonogram/LogoMonogram.tsx +29 -0
- package/src/composites/branding/LogoMonogram/LogoMonogram.types.ts +35 -0
- package/src/composites/branding/LogoMonogram/index.ts +2 -0
- package/src/composites/branding/LogoWordmark/LogoWordmark.tsx +29 -0
- package/src/composites/branding/LogoWordmark/LogoWordmark.types.ts +25 -0
- package/src/composites/branding/LogoWordmark/index.ts +2 -0
- package/src/composites/display/Chip/Chip.styles.ts +189 -0
- package/src/composites/display/Chip/Chip.tsx +97 -0
- package/src/composites/display/Chip/Chip.types.ts +74 -0
- package/src/composites/display/Chip/index.ts +2 -0
- package/src/composites/form-controls/Select/Select.styles.ts +10 -10
- package/src/composites/form-controls/Select/Select.tsx +9 -6
- package/src/composites/form-controls/Select/SelectOption.tsx +10 -7
- package/src/composites/form-controls/TextInput/TextInput.styles.ts +12 -8
- package/src/composites/form-controls/TextInput/TextInput.tsx +7 -4
- package/src/composites/form-controls/Toggle/Toggle.styles.ts +10 -7
- package/src/composites/form-controls/Toggle/Toggle.tsx +4 -3
- package/src/composites/layout/AppShell/AppShell.styles.ts +8 -3
- package/src/composites/layout/AppShell/AppShell.tsx +6 -2
- package/src/composites/layout/Card/Card.styles.ts +10 -4
- package/src/composites/layout/Card/Card.tsx +4 -3
- package/src/composites/layout/ContentCard/ContentCard.styles.ts +44 -0
- package/src/composites/layout/ContentCard/ContentCard.tsx +71 -0
- package/src/composites/layout/ContentCard/ContentCard.types.ts +60 -0
- package/src/composites/layout/ContentCard/index.ts +2 -0
- package/src/composites/layout/Divider/Divider.styles.ts +30 -0
- package/src/composites/layout/Divider/Divider.tsx +46 -0
- package/src/composites/layout/Divider/Divider.types.ts +28 -0
- package/src/composites/layout/Divider/index.ts +2 -0
- package/src/composites/layout/Navbar/Navbar.styles.ts +7 -5
- package/src/composites/layout/Navbar/Navbar.tsx +4 -3
- package/src/composites/layout/Sidebar/Sidebar.styles.ts +7 -5
- package/src/composites/layout/Sidebar/Sidebar.tsx +4 -3
- package/src/composites/overlays/Popover/Popover.styles.ts +7 -5
- package/src/composites/overlays/Popover/Popover.tsx +4 -3
- package/src/composites/range-inputs/ColorScaleSlider/ColorScaleSlider.styles.ts +5 -5
- package/src/composites/range-inputs/ColorScaleSlider/ColorScaleSlider.tsx +4 -3
- package/src/composites/range-inputs/HueSlider/HueSlider.styles.ts +7 -7
- package/src/composites/range-inputs/HueSlider/HueSlider.tsx +1 -1
- package/src/composites/range-inputs/Slider/Slider.styles.ts +9 -9
- package/src/composites/range-inputs/Slider/Slider.tsx +1 -1
- package/src/index.ts +49 -10
- package/src/primitives/Frame/Frame.styles.ts +55 -12
- package/src/primitives/Frame/Frame.tsx +139 -140
- package/src/primitives/Frame/Frame.types.ts +119 -1
- package/src/primitives/Frame/index.ts +4 -0
- package/src/primitives/Icon/Icon.tsx +9 -6
- package/src/primitives/Icon/Icon.types.ts +2 -2
- package/src/primitives/Text/Text.spans.ts +9 -5
- package/src/primitives/Text/Text.tsx +26 -15
- package/src/primitives/Text/Text.types.ts +3 -6
- package/src/primitives/Wrapper/Wrapper.styles.ts +32 -0
- package/src/primitives/Wrapper/Wrapper.tsx +22 -3
- package/src/primitives/Wrapper/Wrapper.types.ts +45 -0
- package/src/registry/registry.ts +5 -21
- package/dist/_COMPONENT_TEMPLATE/ComponentName.d.ts +0 -70
- package/dist/_COMPONENT_TEMPLATE/ComponentName.d.ts.map +0 -1
- package/dist/_COMPONENT_TEMPLATE/ComponentName.styles.d.ts +0 -23
- package/dist/_COMPONENT_TEMPLATE/ComponentName.styles.d.ts.map +0 -1
- package/dist/_COMPONENT_TEMPLATE/ComponentName.types.d.ts +0 -45
- package/dist/_COMPONENT_TEMPLATE/ComponentName.types.d.ts.map +0 -1
- package/dist/_COMPONENT_TEMPLATE/index.d.ts +0 -3
- package/dist/_COMPONENT_TEMPLATE/index.d.ts.map +0 -1
|
@@ -1,37 +1,34 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { ButtonProps } from './Button.types';
|
|
3
3
|
/**
|
|
4
|
-
* Button — A composite component
|
|
4
|
+
* Button — A composite component that inherits its color theme from the
|
|
5
|
+
* nearest parent Frame's `theme` prop (defaults to 'primary').
|
|
5
6
|
*
|
|
6
|
-
* **
|
|
7
|
-
* -
|
|
8
|
-
* -
|
|
9
|
-
* -
|
|
10
|
-
* - Text (primitive) — handles typography with theme tokens
|
|
7
|
+
* **Variants:**
|
|
8
|
+
* - `primary` — Filled background (highest visual weight)
|
|
9
|
+
* - `secondary` — Outlined with subtle hover
|
|
10
|
+
* - `ghost` — No border, transparent, subtle hover
|
|
11
11
|
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
14
|
-
*
|
|
15
|
-
*
|
|
12
|
+
* **Sizes (fixed heights):**
|
|
13
|
+
* - `sm` — 40px
|
|
14
|
+
* - `md` — 48px
|
|
15
|
+
* - `lg` — 56px
|
|
16
|
+
* - `xl` — 64px
|
|
16
17
|
*
|
|
17
18
|
* @example
|
|
18
19
|
* ```tsx
|
|
19
|
-
* <Button variant="primary"
|
|
20
|
+
* <Button variant="primary" size="md" onPress={() => console.log('Pressed')}>
|
|
20
21
|
* Click me
|
|
21
22
|
* </Button>
|
|
22
23
|
* ```
|
|
23
24
|
*
|
|
24
25
|
* @example
|
|
25
26
|
* ```tsx
|
|
26
|
-
*
|
|
27
|
-
*
|
|
28
|
-
* </Button>
|
|
29
|
-
*
|
|
30
|
-
*
|
|
31
|
-
* @example
|
|
32
|
-
* ```tsx
|
|
33
|
-
* <Button icon="delete" variant="tertiary" semantic="neutral" size="sm" onPress={handleDelete} />
|
|
27
|
+
* // Inherits theme from parent Frame
|
|
28
|
+
* <Frame theme="error">
|
|
29
|
+
* <Button variant="primary">Delete</Button>
|
|
30
|
+
* </Frame>
|
|
34
31
|
* ```
|
|
35
32
|
*/
|
|
36
|
-
export declare function Button({ children, icon, iconPosition, variant,
|
|
33
|
+
export declare function Button({ children, icon, iconPosition, variant, size, disabled, loading, fullWidth, style, textStyle, ...pressableProps }: ButtonProps): React.JSX.Element;
|
|
37
34
|
//# sourceMappingURL=Button.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Button.d.ts","sourceRoot":"","sources":["../../../../src/composites/actions/Button/Button.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;
|
|
1
|
+
{"version":3,"file":"Button.d.ts","sourceRoot":"","sources":["../../../../src/composites/actions/Button/Button.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAQlD;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AACH,wBAAgB,MAAM,CAAC,EACrB,QAAQ,EACR,IAAI,EACJ,YAAqB,EACrB,OAAmB,EACnB,IAAW,EACX,QAAgB,EAChB,OAAe,EACf,SAAiB,EACjB,KAAK,EACL,SAAS,EACT,GAAG,cAAc,EAClB,EAAE,WAAW,qBAuEb"}
|
|
@@ -1,6 +1,11 @@
|
|
|
1
1
|
import type { UseTokensResult } from 'newtone-api';
|
|
2
|
-
import type {
|
|
2
|
+
import type { ThemeName } from 'newtone-api';
|
|
3
|
+
import type { ButtonVariant, ButtonSize } from './Button.types';
|
|
3
4
|
import type { TextSize } from '../../../primitives/Text/Text.types';
|
|
5
|
+
/**
|
|
6
|
+
* Fixed heights per size (px)
|
|
7
|
+
*/
|
|
8
|
+
export declare const BUTTON_HEIGHTS: Record<ButtonSize, number>;
|
|
4
9
|
/**
|
|
5
10
|
* Configuration returned by getButtonConfig
|
|
6
11
|
*/
|
|
@@ -15,6 +20,7 @@ export interface ButtonConfig {
|
|
|
15
20
|
borderColor?: string;
|
|
16
21
|
};
|
|
17
22
|
sizeTokens: {
|
|
23
|
+
height: number;
|
|
18
24
|
padding: number;
|
|
19
25
|
gap: number;
|
|
20
26
|
borderRadius: number;
|
|
@@ -28,38 +34,20 @@ export interface ButtonConfig {
|
|
|
28
34
|
export interface ButtonPadding {
|
|
29
35
|
paddingLeft: number;
|
|
30
36
|
paddingRight: number;
|
|
31
|
-
paddingTop: number;
|
|
32
|
-
paddingBottom: number;
|
|
33
37
|
}
|
|
34
38
|
/**
|
|
35
39
|
* Compute asymmetric button padding based on icon/text presence.
|
|
36
40
|
*
|
|
37
41
|
* Text appears visually closer to borders than icons, so we add 8px extra
|
|
38
42
|
* horizontal padding on the text side for optical balance.
|
|
39
|
-
*
|
|
40
|
-
* @param size - Button size (determines base padding)
|
|
41
|
-
* @param hasIcon - Whether button has an icon
|
|
42
|
-
* @param hasText - Whether button has text
|
|
43
|
-
* @param iconPosition - Icon position relative to text
|
|
44
|
-
* @returns Padding object with all four sides
|
|
45
43
|
*/
|
|
46
44
|
export declare function computeButtonPadding(size: ButtonSize, hasIcon: boolean, hasText: boolean, iconPosition: 'left' | 'right'): ButtonPadding;
|
|
47
45
|
/**
|
|
48
|
-
* Compute button configuration based on variant,
|
|
49
|
-
*
|
|
50
|
-
* This function ONLY computes variant colors + size tokens.
|
|
51
|
-
* Layout concerns (flexbox, spacing, alignment) are handled by Wrapper primitive.
|
|
52
|
-
* Typography concerns (font, size, weight) are handled by Text primitive.
|
|
53
|
-
*
|
|
54
|
-
* Elevation-aware: neutral primary uses backgroundInteractive for consistent contrast.
|
|
55
|
-
* Semantic variants use proper PaletteTokens — no opacity hacks.
|
|
46
|
+
* Compute button configuration based on variant, size, and state.
|
|
56
47
|
*
|
|
57
|
-
*
|
|
58
|
-
*
|
|
59
|
-
*
|
|
60
|
-
* @param disabled - Whether button is disabled
|
|
61
|
-
* @param tokens - Resolved tokens for current elevation
|
|
62
|
-
* @returns ButtonConfig with variantColors and sizeTokens
|
|
48
|
+
* Colors are derived from the inherited theme (via FrameContext) rather than
|
|
49
|
+
* hardcoded to the primary palette. The `theme` parameter comes from the
|
|
50
|
+
* nearest Frame's `theme` prop, defaulting to 'primary'.
|
|
63
51
|
*/
|
|
64
|
-
export declare function getButtonConfig(variant: ButtonVariant,
|
|
52
|
+
export declare function getButtonConfig(variant: ButtonVariant, size: ButtonSize, disabled: boolean, tokens: UseTokensResult, theme: ThemeName): ButtonConfig;
|
|
65
53
|
//# sourceMappingURL=Button.styles.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Button.styles.d.ts","sourceRoot":"","sources":["../../../../src/composites/actions/Button/Button.styles.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"Button.styles.d.ts","sourceRoot":"","sources":["../../../../src/composites/actions/Button/Button.styles.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AACnD,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC;AAC7C,OAAO,KAAK,EAAE,aAAa,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAChE,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,qCAAqC,CAAC;AAEpE;;GAEG;AACH,eAAO,MAAM,cAAc,EAAE,MAAM,CAAC,UAAU,EAAE,MAAM,CAKrD,CAAC;AAEF;;GAEG;AACH,MAAM,WAAW,YAAY;IAC3B,aAAa,EAAE;QACb,EAAE,EAAE,MAAM,CAAC;QACX,SAAS,EAAE,MAAM,CAAC;QAClB,SAAS,EAAE,MAAM,CAAC;QAClB,SAAS,EAAE,MAAM,CAAC;QAClB,SAAS,EAAE,MAAM,CAAC;QAClB,WAAW,EAAE,MAAM,CAAC;QACpB,WAAW,CAAC,EAAE,MAAM,CAAC;KACtB,CAAC;IACF,UAAU,EAAE;QACV,MAAM,EAAE,MAAM,CAAC;QACf,OAAO,EAAE,MAAM,CAAC;QAChB,GAAG,EAAE,MAAM,CAAC;QACZ,YAAY,EAAE,MAAM,CAAC;QACrB,QAAQ,EAAE,QAAQ,CAAC;QACnB,QAAQ,EAAE,MAAM,CAAC;KAClB,CAAC;CACH;AAED;;GAEG;AACH,MAAM,WAAW,aAAa;IAC5B,WAAW,EAAE,MAAM,CAAC;IACpB,YAAY,EAAE,MAAM,CAAC;CACtB;AAED;;;;;GAKG;AACH,wBAAgB,oBAAoB,CAClC,IAAI,EAAE,UAAU,EAChB,OAAO,EAAE,OAAO,EAChB,OAAO,EAAE,OAAO,EAChB,YAAY,EAAE,MAAM,GAAG,OAAO,GAC7B,aAAa,CA+Bf;AAED;;;;;;GAMG;AACH,wBAAgB,eAAe,CAC7B,OAAO,EAAE,aAAa,EACtB,IAAI,EAAE,UAAU,EAChB,QAAQ,EAAE,OAAO,EACjB,MAAM,EAAE,eAAe,EACvB,KAAK,EAAE,SAAS,GACf,YAAY,CAed"}
|
|
@@ -1,16 +1,12 @@
|
|
|
1
1
|
import type { PressableProps, ViewStyle, TextStyle } from 'react-native';
|
|
2
2
|
/**
|
|
3
|
-
* Visual
|
|
3
|
+
* Visual variant for the Button component (describes visual weight)
|
|
4
4
|
*/
|
|
5
|
-
export type ButtonVariant = 'primary' | 'secondary' | '
|
|
6
|
-
/**
|
|
7
|
-
* Semantic meaning for the Button component (describes color purpose)
|
|
8
|
-
*/
|
|
9
|
-
export type ButtonSemantic = 'neutral' | 'accent' | 'success' | 'error' | 'warning';
|
|
5
|
+
export type ButtonVariant = 'primary' | 'secondary' | 'ghost';
|
|
10
6
|
/**
|
|
11
7
|
* Size presets for the Button component
|
|
12
8
|
*/
|
|
13
|
-
export type ButtonSize = 'sm' | 'md' | 'lg';
|
|
9
|
+
export type ButtonSize = 'sm' | 'md' | 'lg' | 'xl';
|
|
14
10
|
/**
|
|
15
11
|
* Icon position relative to button text
|
|
16
12
|
*/
|
|
@@ -35,15 +31,10 @@ export interface ButtonProps extends Omit<PressableProps, 'children' | 'style'>
|
|
|
35
31
|
*/
|
|
36
32
|
readonly iconPosition?: ButtonIconPosition;
|
|
37
33
|
/**
|
|
38
|
-
* Visual
|
|
34
|
+
* Visual variant (describes visual weight: filled, outlined, ghost)
|
|
39
35
|
* @default 'primary'
|
|
40
36
|
*/
|
|
41
37
|
readonly variant?: ButtonVariant;
|
|
42
|
-
/**
|
|
43
|
-
* Semantic meaning (describes color purpose: neutral, accent, success, error, warning)
|
|
44
|
-
* @default 'neutral'
|
|
45
|
-
*/
|
|
46
|
-
readonly semantic?: ButtonSemantic;
|
|
47
38
|
/**
|
|
48
39
|
* Size preset
|
|
49
40
|
* @default 'md'
|
|
@@ -54,6 +45,16 @@ export interface ButtonProps extends Omit<PressableProps, 'children' | 'style'>
|
|
|
54
45
|
* @default false
|
|
55
46
|
*/
|
|
56
47
|
readonly disabled?: boolean;
|
|
48
|
+
/**
|
|
49
|
+
* Loading state — disables interaction and dims content.
|
|
50
|
+
* @default false
|
|
51
|
+
*/
|
|
52
|
+
readonly loading?: boolean;
|
|
53
|
+
/**
|
|
54
|
+
* Full-width mode — stretches button to fill container width.
|
|
55
|
+
* @default false
|
|
56
|
+
*/
|
|
57
|
+
readonly fullWidth?: boolean;
|
|
57
58
|
/**
|
|
58
59
|
* Custom style overrides for container
|
|
59
60
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Button.types.d.ts","sourceRoot":"","sources":["../../../../src/composites/actions/Button/Button.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAEzE;;GAEG;AACH,MAAM,MAAM,aAAa,GAAG,SAAS,GAAG,WAAW,GAAG,
|
|
1
|
+
{"version":3,"file":"Button.types.d.ts","sourceRoot":"","sources":["../../../../src/composites/actions/Button/Button.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAEzE;;GAEG;AACH,MAAM,MAAM,aAAa,GAAG,SAAS,GAAG,WAAW,GAAG,OAAO,CAAC;AAE9D;;GAEG;AACH,MAAM,MAAM,UAAU,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,CAAC;AAEnD;;GAEG;AACH,MAAM,MAAM,kBAAkB,GAAG,MAAM,GAAG,OAAO,CAAC;AAElD;;GAEG;AACH,MAAM,WAAW,WAAY,SAAQ,IAAI,CAAC,cAAc,EAAE,UAAU,GAAG,OAAO,CAAC;IAC7E;;;OAGG;IACH,QAAQ,CAAC,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAEpC;;;OAGG;IACH,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAC;IAEvB;;;OAGG;IACH,QAAQ,CAAC,YAAY,CAAC,EAAE,kBAAkB,CAAC;IAE3C;;;OAGG;IACH,QAAQ,CAAC,OAAO,CAAC,EAAE,aAAa,CAAC;IAEjC;;;OAGG;IACH,QAAQ,CAAC,IAAI,CAAC,EAAE,UAAU,CAAC;IAE3B;;;OAGG;IACH,QAAQ,CAAC,QAAQ,CAAC,EAAE,OAAO,CAAC;IAE5B;;;OAGG;IACH,QAAQ,CAAC,OAAO,CAAC,EAAE,OAAO,CAAC;IAE3B;;;OAGG;IACH,QAAQ,CAAC,SAAS,CAAC,EAAE,OAAO,CAAC;IAE7B;;OAEG;IACH,QAAQ,CAAC,KAAK,CAAC,EAAE,SAAS,GAAG,SAAS,EAAE,CAAC;IAEzC;;OAEG;IACH,QAAQ,CAAC,SAAS,CAAC,EAAE,SAAS,GAAG,SAAS,EAAE,CAAC;CAC9C"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/composites/actions/Button/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,YAAY,EAAE,WAAW,EAAE,aAAa,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/composites/actions/Button/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AAClC,YAAY,EAAE,WAAW,EAAE,aAAa,EAAE,UAAU,EAAE,kBAAkB,EAAE,MAAM,gBAAgB,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { LogoMonogramProps } from './LogoMonogram.types';
|
|
3
|
+
/**
|
|
4
|
+
* Newtone monogram — the "N" symbol mark rendered as an SVG.
|
|
5
|
+
*
|
|
6
|
+
* The fill color is derived from `colorValue` (0 = black, 255 = white),
|
|
7
|
+
* allowing smooth animated transitions between light and dark contexts.
|
|
8
|
+
*/
|
|
9
|
+
export declare function LogoMonogram({ colorValue, size }: LogoMonogramProps): React.JSX.Element;
|
|
10
|
+
//# sourceMappingURL=LogoMonogram.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"LogoMonogram.d.ts","sourceRoot":"","sources":["../../../../src/composites/branding/LogoMonogram/LogoMonogram.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAE9D;;;;;GAKG;AACH,wBAAgB,YAAY,CAAC,EAAE,UAAc,EAAE,IAAS,EAAE,EAAE,iBAAiB,qBAmB5E"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Props for LogoMonogram — the Newtone "N" symbol mark.
|
|
3
|
+
*
|
|
4
|
+
* Renders a single-color SVG monogram that scales to the given size.
|
|
5
|
+
* The `colorValue` prop controls the grayscale fill, enabling smooth
|
|
6
|
+
* transitions between light and dark backgrounds.
|
|
7
|
+
*
|
|
8
|
+
* @example
|
|
9
|
+
* ```tsx
|
|
10
|
+
* <LogoMonogram colorValue={0} />
|
|
11
|
+
* ```
|
|
12
|
+
*
|
|
13
|
+
* @example
|
|
14
|
+
* ```tsx
|
|
15
|
+
* <LogoMonogram colorValue={255} size={48} />
|
|
16
|
+
* ```
|
|
17
|
+
*/
|
|
18
|
+
export interface LogoMonogramProps {
|
|
19
|
+
/**
|
|
20
|
+
* Grayscale fill value (0–255).
|
|
21
|
+
*
|
|
22
|
+
* - `0` produces black (for light backgrounds)
|
|
23
|
+
* - `255` produces white (for dark backgrounds)
|
|
24
|
+
*
|
|
25
|
+
* @default 0
|
|
26
|
+
*/
|
|
27
|
+
readonly colorValue?: number;
|
|
28
|
+
/**
|
|
29
|
+
* Width and height of the SVG in pixels.
|
|
30
|
+
*
|
|
31
|
+
* @default 32
|
|
32
|
+
*/
|
|
33
|
+
readonly size?: number;
|
|
34
|
+
}
|
|
35
|
+
//# sourceMappingURL=LogoMonogram.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"LogoMonogram.types.d.ts","sourceRoot":"","sources":["../../../../src/composites/branding/LogoMonogram/LogoMonogram.types.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AACH,MAAM,WAAW,iBAAiB;IAChC;;;;;;;OAOG;IACH,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,CAAC;IAE7B;;;;OAIG;IACH,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAC;CACxB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/composites/branding/LogoMonogram/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,YAAY,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { LogoWordmarkProps } from './LogoWordmark.types';
|
|
3
|
+
/**
|
|
4
|
+
* Newtone wordmark — the full "NEWTONE" text rendered as an SVG.
|
|
5
|
+
*
|
|
6
|
+
* Fixed height of 32px with proportional width derived from the viewBox.
|
|
7
|
+
*/
|
|
8
|
+
export declare function LogoWordmark({ fill }: LogoWordmarkProps): React.JSX.Element;
|
|
9
|
+
//# sourceMappingURL=LogoWordmark.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"LogoWordmark.d.ts","sourceRoot":"","sources":["../../../../src/composites/branding/LogoWordmark/LogoWordmark.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AAE9D;;;;GAIG;AACH,wBAAgB,YAAY,CAAC,EAAE,IAAc,EAAE,EAAE,iBAAiB,qBAoBjE"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Props for LogoWordmark — the full "NEWTONE" text logo.
|
|
3
|
+
*
|
|
4
|
+
* Renders an SVG wordmark at a fixed 32px height with configurable fill color.
|
|
5
|
+
*
|
|
6
|
+
* @example
|
|
7
|
+
* ```tsx
|
|
8
|
+
* <LogoWordmark />
|
|
9
|
+
* ```
|
|
10
|
+
*
|
|
11
|
+
* @example
|
|
12
|
+
* ```tsx
|
|
13
|
+
* <LogoWordmark fill="white" />
|
|
14
|
+
* ```
|
|
15
|
+
*/
|
|
16
|
+
export interface LogoWordmarkProps {
|
|
17
|
+
/**
|
|
18
|
+
* Fill color for the wordmark paths.
|
|
19
|
+
*
|
|
20
|
+
* Accepts any valid CSS color string (hex, rgb, named color).
|
|
21
|
+
*
|
|
22
|
+
* @default "black"
|
|
23
|
+
*/
|
|
24
|
+
readonly fill?: string;
|
|
25
|
+
}
|
|
26
|
+
//# sourceMappingURL=LogoWordmark.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"LogoWordmark.types.d.ts","sourceRoot":"","sources":["../../../../src/composites/branding/LogoWordmark/LogoWordmark.types.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;GAcG;AACH,MAAM,WAAW,iBAAiB;IAChC;;;;;;OAMG;IACH,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAC;CACxB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/composites/branding/LogoWordmark/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,YAAY,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC"}
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { ChipProps } from './Chip.types';
|
|
3
|
+
/**
|
|
4
|
+
* Chip — A pill-shaped label for tags, filters, badges, and status indicators.
|
|
5
|
+
*
|
|
6
|
+
* **Composition Architecture:**
|
|
7
|
+
* - Pressable (RN primitive) — handles interaction (when onPress is provided)
|
|
8
|
+
* - Wrapper (primitive) — handles layout (direction, gap, padding, alignment)
|
|
9
|
+
* - Icon (primitive) — handles optional leading icon
|
|
10
|
+
* - Text (primitive) — handles typography with theme tokens
|
|
11
|
+
*
|
|
12
|
+
* @example
|
|
13
|
+
* ```tsx
|
|
14
|
+
* // Static label
|
|
15
|
+
* <Chip>Design Systems</Chip>
|
|
16
|
+
*
|
|
17
|
+
* // Interactive filter chip
|
|
18
|
+
* <Chip selected={isActive} onPress={() => toggle()}>Color Science</Chip>
|
|
19
|
+
*
|
|
20
|
+
* // With icon
|
|
21
|
+
* <Chip icon="check" semantic="success">Verified</Chip>
|
|
22
|
+
* ```
|
|
23
|
+
*/
|
|
24
|
+
export declare function Chip({ children, variant, size, semantic, selected, onPress, disabled, icon, style, }: ChipProps): React.JSX.Element;
|
|
25
|
+
//# sourceMappingURL=Chip.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Chip.d.ts","sourceRoot":"","sources":["../../../../src/composites/display/Chip/Chip.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAO9C;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,wBAAgB,IAAI,CAAC,EACnB,QAAQ,EACR,OAAkB,EAClB,IAAW,EACX,QAAoB,EACpB,QAAgB,EAChB,OAAO,EACP,QAAgB,EAChB,IAAI,EACJ,KAAK,GACN,EAAE,SAAS,qBAwDX"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import type { UseTokensResult } from 'newtone-api';
|
|
2
|
+
import type { ChipVariant, ChipSemantic, ChipSize } from './Chip.types';
|
|
3
|
+
import type { TextRole } from '../../../primitives/Text';
|
|
4
|
+
/**
|
|
5
|
+
* Configuration returned by getChipConfig
|
|
6
|
+
*/
|
|
7
|
+
export interface ChipConfig {
|
|
8
|
+
colors: {
|
|
9
|
+
bg: string;
|
|
10
|
+
hoveredBg: string;
|
|
11
|
+
pressedBg: string;
|
|
12
|
+
textColor: string;
|
|
13
|
+
iconColor: string;
|
|
14
|
+
borderWidth: number;
|
|
15
|
+
borderColor: string;
|
|
16
|
+
};
|
|
17
|
+
sizeTokens: {
|
|
18
|
+
paddingX: number;
|
|
19
|
+
paddingY: number;
|
|
20
|
+
gap: number;
|
|
21
|
+
textRole: TextRole;
|
|
22
|
+
iconSize: number;
|
|
23
|
+
};
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Compute chip configuration based on variant, semantic, size, and state.
|
|
27
|
+
*/
|
|
28
|
+
export declare function getChipConfig(variant: ChipVariant, semantic: ChipSemantic, size: ChipSize, selected: boolean, disabled: boolean, tokens: UseTokensResult): ChipConfig;
|
|
29
|
+
//# sourceMappingURL=Chip.styles.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Chip.styles.d.ts","sourceRoot":"","sources":["../../../../src/composites/display/Chip/Chip.styles.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,aAAa,CAAC;AACnD,OAAO,KAAK,EAAE,WAAW,EAAE,YAAY,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC;AACxE,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,0BAA0B,CAAC;AAEzD;;GAEG;AACH,MAAM,WAAW,UAAU;IACzB,MAAM,EAAE;QACN,EAAE,EAAE,MAAM,CAAC;QACX,SAAS,EAAE,MAAM,CAAC;QAClB,SAAS,EAAE,MAAM,CAAC;QAClB,SAAS,EAAE,MAAM,CAAC;QAClB,SAAS,EAAE,MAAM,CAAC;QAClB,WAAW,EAAE,MAAM,CAAC;QACpB,WAAW,EAAE,MAAM,CAAC;KACrB,CAAC;IACF,UAAU,EAAE;QACV,QAAQ,EAAE,MAAM,CAAC;QACjB,QAAQ,EAAE,MAAM,CAAC;QACjB,GAAG,EAAE,MAAM,CAAC;QACZ,QAAQ,EAAE,QAAQ,CAAC;QACnB,QAAQ,EAAE,MAAM,CAAC;KAClB,CAAC;CACH;AAqJD;;GAEG;AACH,wBAAgB,aAAa,CAC3B,OAAO,EAAE,WAAW,EACpB,QAAQ,EAAE,YAAY,EACtB,IAAI,EAAE,QAAQ,EACd,QAAQ,EAAE,OAAO,EACjB,QAAQ,EAAE,OAAO,EACjB,MAAM,EAAE,eAAe,GACtB,UAAU,CAKZ"}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import type { ViewStyle } from 'react-native';
|
|
2
|
+
/**
|
|
3
|
+
* Visual variant for the Chip component
|
|
4
|
+
*/
|
|
5
|
+
export type ChipVariant = 'filled' | 'tinted' | 'outlined';
|
|
6
|
+
/**
|
|
7
|
+
* Semantic meaning for the Chip component (describes color purpose)
|
|
8
|
+
*/
|
|
9
|
+
export type ChipSemantic = 'neutral' | 'accent' | 'success' | 'error' | 'warning';
|
|
10
|
+
/**
|
|
11
|
+
* Size presets for the Chip component
|
|
12
|
+
*/
|
|
13
|
+
export type ChipSize = 'sm' | 'md';
|
|
14
|
+
/**
|
|
15
|
+
* Props for the Chip component
|
|
16
|
+
*/
|
|
17
|
+
export interface ChipProps {
|
|
18
|
+
/**
|
|
19
|
+
* Chip label content.
|
|
20
|
+
*/
|
|
21
|
+
readonly children: React.ReactNode;
|
|
22
|
+
/**
|
|
23
|
+
* Visual variant (describes visual treatment)
|
|
24
|
+
* @default 'tinted'
|
|
25
|
+
*/
|
|
26
|
+
readonly variant?: ChipVariant;
|
|
27
|
+
/**
|
|
28
|
+
* Size preset
|
|
29
|
+
* @default 'md'
|
|
30
|
+
*/
|
|
31
|
+
readonly size?: ChipSize;
|
|
32
|
+
/**
|
|
33
|
+
* Semantic meaning (describes color purpose)
|
|
34
|
+
* @default 'neutral'
|
|
35
|
+
*/
|
|
36
|
+
readonly semantic?: ChipSemantic;
|
|
37
|
+
/**
|
|
38
|
+
* Selected state — overrides appearance to "strong" with bold weight.
|
|
39
|
+
* Useful for filter bars and toggle groups.
|
|
40
|
+
* @default false
|
|
41
|
+
*/
|
|
42
|
+
readonly selected?: boolean;
|
|
43
|
+
/**
|
|
44
|
+
* Press handler — makes the chip interactive.
|
|
45
|
+
* When provided, the chip renders as a Pressable.
|
|
46
|
+
*/
|
|
47
|
+
readonly onPress?: () => void;
|
|
48
|
+
/**
|
|
49
|
+
* Disabled state
|
|
50
|
+
* @default false
|
|
51
|
+
*/
|
|
52
|
+
readonly disabled?: boolean;
|
|
53
|
+
/**
|
|
54
|
+
* Material Symbol icon name (e.g. 'check', 'close').
|
|
55
|
+
* Renders a leading icon before the label.
|
|
56
|
+
*/
|
|
57
|
+
readonly icon?: string;
|
|
58
|
+
/**
|
|
59
|
+
* Custom style overrides for container
|
|
60
|
+
*/
|
|
61
|
+
readonly style?: ViewStyle | ViewStyle[];
|
|
62
|
+
}
|
|
63
|
+
//# sourceMappingURL=Chip.types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Chip.types.d.ts","sourceRoot":"","sources":["../../../../src/composites/display/Chip/Chip.types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAE9C;;GAEG;AACH,MAAM,MAAM,WAAW,GAAG,QAAQ,GAAG,QAAQ,GAAG,UAAU,CAAC;AAE3D;;GAEG;AACH,MAAM,MAAM,YAAY,GAAG,SAAS,GAAG,QAAQ,GAAG,SAAS,GAAG,OAAO,GAAG,SAAS,CAAC;AAElF;;GAEG;AACH,MAAM,MAAM,QAAQ,GAAG,IAAI,GAAG,IAAI,CAAC;AAEnC;;GAEG;AACH,MAAM,WAAW,SAAS;IACxB;;OAEG;IACH,QAAQ,CAAC,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAEnC;;;OAGG;IACH,QAAQ,CAAC,OAAO,CAAC,EAAE,WAAW,CAAC;IAE/B;;;OAGG;IACH,QAAQ,CAAC,IAAI,CAAC,EAAE,QAAQ,CAAC;IAEzB;;;OAGG;IACH,QAAQ,CAAC,QAAQ,CAAC,EAAE,YAAY,CAAC;IAEjC;;;;OAIG;IACH,QAAQ,CAAC,QAAQ,CAAC,EAAE,OAAO,CAAC;IAE5B;;;OAGG;IACH,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,IAAI,CAAC;IAE9B;;;OAGG;IACH,QAAQ,CAAC,QAAQ,CAAC,EAAE,OAAO,CAAC;IAE5B;;;OAGG;IACH,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAC;IAEvB;;OAEG;IACH,QAAQ,CAAC,KAAK,CAAC,EAAE,SAAS,GAAG,SAAS,EAAE,CAAC;CAC1C"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/composites/display/Chip/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AAC9B,YAAY,EAAE,SAAS,EAAE,WAAW,EAAE,YAAY,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Select.d.ts","sourceRoot":"","sources":["../../../../src/composites/form-controls/Select/Select.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAkB,MAAM,OAAO,CAAC;AAEvC,OAAO,KAAK,EAAE,WAAW,EAAgB,MAAM,gBAAgB,CAAC;AAsBhE,wBAAgB,MAAM,CAAC,EACrB,OAAO,EACP,KAAK,EACL,aAAa,EACb,KAAK,EACL,WAAW,EACX,QAAgB,EAChB,YAAY,EACZ,WAAW,EACX,IAAW,EACX,KAAK,GACN,EAAE,WAAW,
|
|
1
|
+
{"version":3,"file":"Select.d.ts","sourceRoot":"","sources":["../../../../src/composites/form-controls/Select/Select.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAkB,MAAM,OAAO,CAAC;AAEvC,OAAO,KAAK,EAAE,WAAW,EAAgB,MAAM,gBAAgB,CAAC;AAsBhE,wBAAgB,MAAM,CAAC,EACrB,OAAO,EACP,KAAK,EACL,aAAa,EACb,KAAK,EACL,WAAW,EACX,QAAgB,EAChB,YAAY,EACZ,WAAW,EACX,IAAW,EACX,KAAK,GACN,EAAE,WAAW,qBAoHb"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { ResolvedTokens,
|
|
2
|
-
export declare function getSelectStyles(tokens: ResolvedTokens,
|
|
1
|
+
import type { ResolvedTokens, ThemeName, AppearanceName } from 'newtone-api';
|
|
2
|
+
export declare function getSelectStyles(tokens: ResolvedTokens, disabled: boolean, size: 'sm' | 'md', isOpen: boolean, theme?: ThemeName, appearance?: AppearanceName): {
|
|
3
3
|
container: {
|
|
4
4
|
gap: number;
|
|
5
5
|
zIndex: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Select.styles.d.ts","sourceRoot":"","sources":["../../../../src/composites/form-controls/Select/Select.styles.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,
|
|
1
|
+
{"version":3,"file":"Select.styles.d.ts","sourceRoot":"","sources":["../../../../src/composites/form-controls/Select/Select.styles.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAoB,SAAS,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAE/F,wBAAgB,eAAe,CAC7B,MAAM,EAAE,cAAc,EACtB,QAAQ,EAAE,OAAO,EACjB,IAAI,EAAE,IAAI,GAAG,IAAI,EACjB,MAAM,EAAE,OAAO,EACf,KAAK,GAAE,SAAqB,EAC5B,UAAU,GAAE,cAAuB;;;;;;;;oBAkB4B,GAAG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;oBA+BH,GAAG;;;;;;;;EASnE"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SelectOption.d.ts","sourceRoot":"","sources":["../../../../src/composites/form-controls/Select/SelectOption.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,KAAK,EAAE,YAAY,IAAI,gBAAgB,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAIpF,UAAU,oBAAoB;IAC5B,QAAQ,CAAC,MAAM,EAAE,gBAAgB,CAAC;IAClC,QAAQ,CAAC,UAAU,EAAE,OAAO,CAAC;IAC7B,QAAQ,CAAC,SAAS,EAAE,OAAO,CAAC;IAC5B,QAAQ,CAAC,QAAQ,EAAE,MAAM,IAAI,CAAC;IAC9B,QAAQ,CAAC,YAAY,CAAC,EAAE,WAAW,CAAC,cAAc,CAAC,CAAC;IACpD,QAAQ,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,CAAC;CAC5B;AAED,wBAAgB,eAAe,CAAC,EAC9B,MAAM,EACN,UAAU,EACV,SAAS,EACT,QAAQ,EACR,YAAY,EACZ,IAAI,GACL,EAAE,oBAAoB,
|
|
1
|
+
{"version":3,"file":"SelectOption.d.ts","sourceRoot":"","sources":["../../../../src/composites/form-controls/Select/SelectOption.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,KAAK,EAAE,YAAY,IAAI,gBAAgB,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAIpF,UAAU,oBAAoB;IAC5B,QAAQ,CAAC,MAAM,EAAE,gBAAgB,CAAC;IAClC,QAAQ,CAAC,UAAU,EAAE,OAAO,CAAC;IAC7B,QAAQ,CAAC,SAAS,EAAE,OAAO,CAAC;IAC5B,QAAQ,CAAC,QAAQ,EAAE,MAAM,IAAI,CAAC;IAC9B,QAAQ,CAAC,YAAY,CAAC,EAAE,WAAW,CAAC,cAAc,CAAC,CAAC;IACpD,QAAQ,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,CAAC;CAC5B;AAED,wBAAgB,eAAe,CAAC,EAC9B,MAAM,EACN,UAAU,EACV,SAAS,EACT,QAAQ,EACR,YAAY,EACZ,IAAI,GACL,EAAE,oBAAoB,qBAmFtB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TextInput.d.ts","sourceRoot":"","sources":["../../../../src/composites/form-controls/TextInput/TextInput.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAIxD,wBAAgB,SAAS,CAAC,EACxB,KAAK,EACL,QAAgB,EAChB,KAAK,EACL,GAAG,cAAc,EAClB,EAAE,cAAc,
|
|
1
|
+
{"version":3,"file":"TextInput.d.ts","sourceRoot":"","sources":["../../../../src/composites/form-controls/TextInput/TextInput.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AAIxD,wBAAgB,SAAS,CAAC,EACxB,KAAK,EACL,QAAgB,EAChB,KAAK,EACL,GAAG,cAAc,EAClB,EAAE,cAAc,qBAsBhB"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { ResolvedTokens,
|
|
2
|
-
export declare function getTextInputStyles(tokens: ResolvedTokens,
|
|
1
|
+
import type { ResolvedTokens, ThemeName, AppearanceName } from 'newtone-api';
|
|
2
|
+
export declare function getTextInputStyles(tokens: ResolvedTokens, disabled: boolean, theme?: ThemeName, appearance?: AppearanceName): {
|
|
3
3
|
container: {
|
|
4
4
|
gap: number;
|
|
5
5
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TextInput.styles.d.ts","sourceRoot":"","sources":["../../../../src/composites/form-controls/TextInput/TextInput.styles.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,
|
|
1
|
+
{"version":3,"file":"TextInput.styles.d.ts","sourceRoot":"","sources":["../../../../src/composites/form-controls/TextInput/TextInput.styles.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAoB,SAAS,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAE/F,wBAAgB,kBAAkB,CAChC,MAAM,EAAE,cAAc,EACtB,QAAQ,EAAE,OAAO,EACjB,KAAK,GAAE,SAAqB,EAC5B,UAAU,GAAE,cAAuB;;;;;;;oBAU4B,GAAG;;;;;;;;;;;;;;;EAgBnE"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Toggle.d.ts","sourceRoot":"","sources":["../../../../src/composites/form-controls/Toggle/Toggle.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAIlD,wBAAgB,MAAM,CAAC,EACrB,KAAK,EACL,aAAa,EACb,KAAK,EACL,QAAgB,EAChB,KAAK,GACN,EAAE,WAAW,
|
|
1
|
+
{"version":3,"file":"Toggle.d.ts","sourceRoot":"","sources":["../../../../src/composites/form-controls/Toggle/Toggle.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAIlD,wBAAgB,MAAM,CAAC,EACrB,KAAK,EACL,aAAa,EACb,KAAK,EACL,QAAgB,EAChB,KAAK,GACN,EAAE,WAAW,qBA8Bb"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { ResolvedTokens,
|
|
2
|
-
export declare function getToggleStyles(tokens: ResolvedTokens,
|
|
1
|
+
import type { ResolvedTokens, ThemeName, AppearanceName } from 'newtone-api';
|
|
2
|
+
export declare function getToggleStyles(tokens: ResolvedTokens, value: boolean, disabled: boolean, theme?: ThemeName, appearance?: AppearanceName): {
|
|
3
3
|
container: {
|
|
4
4
|
flexDirection: "row";
|
|
5
5
|
alignItems: "center";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Toggle.styles.d.ts","sourceRoot":"","sources":["../../../../src/composites/form-controls/Toggle/Toggle.styles.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,
|
|
1
|
+
{"version":3,"file":"Toggle.styles.d.ts","sourceRoot":"","sources":["../../../../src/composites/form-controls/Toggle/Toggle.styles.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAoB,SAAS,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAO/F,wBAAgB,eAAe,CAC7B,MAAM,EAAE,cAAc,EACtB,KAAK,EAAE,OAAO,EACd,QAAQ,EAAE,OAAO,EACjB,KAAK,GAAE,SAAqB,EAC5B,UAAU,GAAE,cAAuB;;;;;;;;;;oBAc4B,GAAG;;;;;;;;;;;;;;;;;;EAqBnE"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AppShell.d.ts","sourceRoot":"","sources":["../../../../src/composites/layout/AppShell/AppShell.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAItD,wBAAgB,QAAQ,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,EAAE,aAAa,
|
|
1
|
+
{"version":3,"file":"AppShell.d.ts","sourceRoot":"","sources":["../../../../src/composites/layout/AppShell/AppShell.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AAItD,wBAAgB,QAAQ,CAAC,EAAE,OAAO,EAAE,QAAQ,EAAE,EAAE,aAAa,qBAc5D"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { ResolvedTokens,
|
|
2
|
-
export declare function getAppShellStyles(tokens: ResolvedTokens,
|
|
1
|
+
import type { ResolvedTokens, ThemeName, AppearanceName } from 'newtone-api';
|
|
2
|
+
export declare function getAppShellStyles(tokens: ResolvedTokens, theme?: ThemeName, appearance?: AppearanceName): {
|
|
3
3
|
container: {
|
|
4
4
|
flex: number;
|
|
5
5
|
flexDirection: "row";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"AppShell.styles.d.ts","sourceRoot":"","sources":["../../../../src/composites/layout/AppShell/AppShell.styles.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,
|
|
1
|
+
{"version":3,"file":"AppShell.styles.d.ts","sourceRoot":"","sources":["../../../../src/composites/layout/AppShell/AppShell.styles.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAoB,SAAS,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAE/F,wBAAgB,iBAAiB,CAC/B,MAAM,EAAE,cAAc,EACtB,KAAK,GAAE,SAAqB,EAC5B,UAAU,GAAE,cAAuB;;;;;;;;;;;;;EAiBpC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Card.d.ts","sourceRoot":"","sources":["../../../../src/composites/layout/Card/Card.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAI9C,wBAAgB,IAAI,CAAC,EACnB,QAAQ,EACR,SAAa,EACb,KAAK,EACL,QAAgB,GACjB,EAAE,SAAS,
|
|
1
|
+
{"version":3,"file":"Card.d.ts","sourceRoot":"","sources":["../../../../src/composites/layout/Card/Card.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAI9C,wBAAgB,IAAI,CAAC,EACnB,QAAQ,EACR,SAAa,EACb,KAAK,EACL,QAAgB,GACjB,EAAE,SAAS,qBAcX"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import type { ResolvedTokens,
|
|
2
|
-
export declare function getCardStyles(tokens: ResolvedTokens,
|
|
1
|
+
import type { ResolvedTokens, ThemeName, AppearanceName } from 'newtone-api';
|
|
2
|
+
export declare function getCardStyles(tokens: ResolvedTokens, disabled: boolean, theme?: ThemeName, appearance?: AppearanceName): {
|
|
3
3
|
container: {
|
|
4
4
|
backgroundColor: string;
|
|
5
5
|
borderWidth: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Card.styles.d.ts","sourceRoot":"","sources":["../../../../src/composites/layout/Card/Card.styles.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAE,
|
|
1
|
+
{"version":3,"file":"Card.styles.d.ts","sourceRoot":"","sources":["../../../../src/composites/layout/Card/Card.styles.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,cAAc,EAAoB,SAAS,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAE/F,wBAAgB,aAAa,CAC3B,MAAM,EAAE,cAAc,EACtB,QAAQ,EAAE,OAAO,EACjB,KAAK,GAAE,SAAqB,EAC5B,UAAU,GAAE,cAAuB;;;;;;;;;EAapC"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import type { ContentCardProps } from './ContentCard.types';
|
|
3
|
+
/**
|
|
4
|
+
* ContentCard — A content container with three visual treatments.
|
|
5
|
+
*
|
|
6
|
+
* **Variants:**
|
|
7
|
+
* - `elevated` — raised surface with tinted background (hero cards, featured content)
|
|
8
|
+
* - `bordered` — outlined container (related items, previews)
|
|
9
|
+
* - `flat` — bottom-border only (list rows, compact items)
|
|
10
|
+
*
|
|
11
|
+
* Delegates to Frame for layout, elevation, appearance, and interactivity.
|
|
12
|
+
*
|
|
13
|
+
* @example
|
|
14
|
+
* ```tsx
|
|
15
|
+
* // Elevated hero card
|
|
16
|
+
* <ContentCard variant="elevated" href="/articles/intro">
|
|
17
|
+
* <Text role="heading" weight="bold">Featured Article</Text>
|
|
18
|
+
* <Text role="body" color="secondary">Article excerpt...</Text>
|
|
19
|
+
* </ContentCard>
|
|
20
|
+
*
|
|
21
|
+
* // Bordered card
|
|
22
|
+
* <ContentCard variant="bordered" onPress={() => navigate(slug)}>
|
|
23
|
+
* <Text role="body" weight="bold">Related Article</Text>
|
|
24
|
+
* </ContentCard>
|
|
25
|
+
*
|
|
26
|
+
* // Flat list item
|
|
27
|
+
* <ContentCard variant="flat" href={`/articles/${slug}`}>
|
|
28
|
+
* <Text role="body" weight="bold">{title}</Text>
|
|
29
|
+
* </ContentCard>
|
|
30
|
+
* ```
|
|
31
|
+
*/
|
|
32
|
+
export declare function ContentCard({ children, variant, href, onPress, padding, gap, disabled, style, }: ContentCardProps): React.JSX.Element;
|
|
33
|
+
//# sourceMappingURL=ContentCard.d.ts.map
|