@ankhorage/zora 0.6.0 → 0.6.2
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/CHANGELOG.md +12 -0
- package/README.md +44 -1
- package/dist/components/card/Card.d.ts.map +1 -1
- package/dist/components/card/Card.js +2 -1
- package/dist/components/card/Card.js.map +1 -1
- package/dist/components/checkbox/CheckboxGroup.d.ts.map +1 -1
- package/dist/components/checkbox/CheckboxGroup.js +2 -1
- package/dist/components/checkbox/CheckboxGroup.js.map +1 -1
- package/dist/components/drawer/Drawer.d.ts.map +1 -1
- package/dist/components/drawer/Drawer.js +2 -1
- package/dist/components/drawer/Drawer.js.map +1 -1
- package/dist/components/form/FormError.d.ts.map +1 -1
- package/dist/components/form/FormError.js +3 -2
- package/dist/components/form/FormError.js.map +1 -1
- package/dist/components/form/FormField.d.ts.map +1 -1
- package/dist/components/form/FormField.js +2 -1
- package/dist/components/form/FormField.js.map +1 -1
- package/dist/components/input/Input.js +3 -3
- package/dist/components/input/Input.js.map +1 -1
- package/dist/components/input/types.d.ts +4 -4
- package/dist/components/input/types.d.ts.map +1 -1
- package/dist/components/input/types.js.map +1 -1
- package/dist/components/modal/Modal.d.ts.map +1 -1
- package/dist/components/modal/Modal.js +2 -1
- package/dist/components/modal/Modal.js.map +1 -1
- package/dist/components/radio/RadioGroup.d.ts.map +1 -1
- package/dist/components/radio/RadioGroup.js +2 -1
- package/dist/components/radio/RadioGroup.js.map +1 -1
- package/dist/components/tabs/Tabs.d.ts.map +1 -1
- package/dist/components/tabs/Tabs.js +3 -2
- package/dist/components/tabs/Tabs.js.map +1 -1
- package/dist/components/text/Text.d.ts +4 -0
- package/dist/components/text/Text.d.ts.map +1 -0
- package/dist/components/text/Text.js +47 -0
- package/dist/components/text/Text.js.map +1 -0
- package/dist/components/text/index.d.ts +3 -0
- package/dist/components/text/index.d.ts.map +1 -0
- package/dist/components/text/index.js +2 -0
- package/dist/components/text/index.js.map +1 -0
- package/dist/components/text/resolveTextRecipe.d.ts +15 -0
- package/dist/components/text/resolveTextRecipe.d.ts.map +1 -0
- package/dist/components/text/resolveTextRecipe.js +110 -0
- package/dist/components/text/resolveTextRecipe.js.map +1 -0
- package/dist/components/text/types.d.ts +26 -0
- package/dist/components/text/types.d.ts.map +1 -0
- package/dist/components/text/types.js +2 -0
- package/dist/components/text/types.js.map +1 -0
- package/dist/components/textarea/Textarea.js +3 -3
- package/dist/components/textarea/Textarea.js.map +1 -1
- package/dist/components/textarea/types.d.ts +4 -4
- package/dist/components/textarea/types.d.ts.map +1 -1
- package/dist/components/textarea/types.js.map +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/layout/page-header/PageHeader.d.ts.map +1 -1
- package/dist/layout/page-header/PageHeader.js +2 -1
- package/dist/layout/page-header/PageHeader.js.map +1 -1
- package/dist/patterns/collection-editor/CollectionEditor.d.ts.map +1 -1
- package/dist/patterns/collection-editor/CollectionEditor.js +2 -1
- package/dist/patterns/collection-editor/CollectionEditor.js.map +1 -1
- package/dist/patterns/form-field/FormField.d.ts.map +1 -1
- package/dist/patterns/form-field/FormField.js +2 -1
- package/dist/patterns/form-field/FormField.js.map +1 -1
- package/dist/patterns/form-field/index.d.ts +0 -1
- package/dist/patterns/form-field/index.d.ts.map +1 -1
- package/dist/patterns/form-field/index.js.map +1 -1
- package/dist/patterns/section-header/SectionHeader.d.ts.map +1 -1
- package/dist/patterns/section-header/SectionHeader.js +2 -1
- package/dist/patterns/section-header/SectionHeader.js.map +1 -1
- package/dist/patterns/settings-row/SettingsRow.d.ts.map +1 -1
- package/dist/patterns/settings-row/SettingsRow.js +2 -1
- package/dist/patterns/settings-row/SettingsRow.js.map +1 -1
- package/dist/patterns/tile-grid/PaletteItem.d.ts.map +1 -1
- package/dist/patterns/tile-grid/PaletteItem.js +2 -1
- package/dist/patterns/tile-grid/PaletteItem.js.map +1 -1
- package/package.json +2 -2
- package/src/components/card/Card.tsx +2 -1
- package/src/components/checkbox/CheckboxGroup.tsx +2 -1
- package/src/components/drawer/Drawer.tsx +2 -1
- package/src/components/form/FormError.tsx +3 -2
- package/src/components/form/FormField.tsx +2 -1
- package/src/components/input/Input.tsx +5 -5
- package/src/components/input/types.ts +4 -4
- package/src/components/modal/Modal.tsx +2 -1
- package/src/components/radio/RadioGroup.tsx +2 -1
- package/src/components/tabs/Tabs.tsx +3 -6
- package/src/components/text/Text.tsx +93 -0
- package/src/components/text/index.ts +2 -0
- package/src/components/text/resolveTextRecipe.test.ts +333 -0
- package/src/components/text/resolveTextRecipe.ts +169 -0
- package/src/components/text/types.ts +38 -0
- package/src/components/textarea/Textarea.tsx +5 -5
- package/src/components/textarea/types.ts +4 -4
- package/src/index.ts +2 -0
- package/src/layout/page-header/PageHeader.tsx +2 -1
- package/src/patterns/collection-editor/CollectionEditor.tsx +2 -1
- package/src/patterns/form-field/FormField.tsx +2 -1
- package/src/patterns/form-field/index.ts +0 -1
- package/src/patterns/section-header/SectionHeader.tsx +2 -1
- package/src/patterns/settings-row/SettingsRow.tsx +2 -1
- package/src/patterns/tile-grid/PaletteItem.tsx +2 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"resolveTextRecipe.d.ts","sourceRoot":"","sources":["../../../src/components/text/resolveTextRecipe.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,SAAS,EACd,KAAK,UAAU,EAGf,KAAK,UAAU,EAChB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAE9C,OAAO,KAAK,EAAE,SAAS,EAAE,QAAQ,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAU5E,UAAU,uBAAuB;IAC/B,KAAK,EAAE,SAAS,CAAC;IACjB,UAAU,EAAE,UAAU,CAAC;IACvB,OAAO,CAAC,EAAE,UAAU,CAAC,WAAW,CAAC,CAAC;IAClC,IAAI,CAAC,EAAE,UAAU,CAAC,QAAQ,CAAC,CAAC;IAC5B,MAAM,CAAC,EAAE,UAAU,CAAC,UAAU,CAAC,CAAC;IAChC,KAAK,CAAC,EAAE,UAAU,CAAC,SAAS,CAAC,CAAC;IAC9B,MAAM,CAAC,EAAE,OAAO,CAAC;CAClB;AA0GD,wBAAgB,gBAAgB,CAAC,EAC/B,KAAK,EACL,UAAU,EACV,OAAO,EACP,IAAI,EACJ,MAAM,EACN,KAAK,EACL,MAAc,GACf,EAAE,uBAAuB,GAAG,SAAS,CA2BrC"}
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
import { resolveResponsive, } from '@ankhorage/surface';
|
|
2
|
+
function isMediumBreakpointOrLarger(breakpoint) {
|
|
3
|
+
return breakpoint === 'md' || breakpoint === 'lg' || breakpoint === 'xl';
|
|
4
|
+
}
|
|
5
|
+
function resolveWeight(theme, weight) {
|
|
6
|
+
return theme.typography.weights[weight];
|
|
7
|
+
}
|
|
8
|
+
function resolveFontFamily({ theme, variant, weight, italic, }) {
|
|
9
|
+
if (variant === 'code') {
|
|
10
|
+
return 'monospace';
|
|
11
|
+
}
|
|
12
|
+
return theme.typography.fonts[italic ? 'italic' : 'normal'][weight];
|
|
13
|
+
}
|
|
14
|
+
function resolveVariantRecipe(theme, variant, breakpoint) {
|
|
15
|
+
switch (variant) {
|
|
16
|
+
case 'lead':
|
|
17
|
+
return {
|
|
18
|
+
fontSize: isMediumBreakpointOrLarger(breakpoint)
|
|
19
|
+
? theme.typography.sizes.l
|
|
20
|
+
: theme.typography.sizes.m,
|
|
21
|
+
lineHeight: isMediumBreakpointOrLarger(breakpoint) ? 28 : 24,
|
|
22
|
+
weight: 'regular',
|
|
23
|
+
};
|
|
24
|
+
case 'bodySmall':
|
|
25
|
+
return {
|
|
26
|
+
fontSize: theme.typography.sizes.s,
|
|
27
|
+
lineHeight: 20,
|
|
28
|
+
weight: 'regular',
|
|
29
|
+
};
|
|
30
|
+
case 'caption':
|
|
31
|
+
return {
|
|
32
|
+
fontSize: theme.typography.sizes.xs,
|
|
33
|
+
lineHeight: 16,
|
|
34
|
+
weight: 'regular',
|
|
35
|
+
};
|
|
36
|
+
case 'label':
|
|
37
|
+
return {
|
|
38
|
+
fontSize: theme.typography.sizes.s,
|
|
39
|
+
lineHeight: 18,
|
|
40
|
+
weight: 'medium',
|
|
41
|
+
};
|
|
42
|
+
case 'eyebrow':
|
|
43
|
+
return {
|
|
44
|
+
fontSize: theme.typography.sizes.xs,
|
|
45
|
+
lineHeight: 16,
|
|
46
|
+
weight: 'semiBold',
|
|
47
|
+
textTransform: 'uppercase',
|
|
48
|
+
letterSpacing: 0.8,
|
|
49
|
+
};
|
|
50
|
+
case 'code':
|
|
51
|
+
return {
|
|
52
|
+
fontSize: theme.typography.sizes.s,
|
|
53
|
+
lineHeight: 20,
|
|
54
|
+
weight: 'regular',
|
|
55
|
+
};
|
|
56
|
+
case 'body':
|
|
57
|
+
default:
|
|
58
|
+
return {
|
|
59
|
+
fontSize: theme.typography.sizes.m,
|
|
60
|
+
lineHeight: 24,
|
|
61
|
+
weight: 'regular',
|
|
62
|
+
};
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
function resolveToneColor(theme, tone) {
|
|
66
|
+
switch (tone) {
|
|
67
|
+
case 'muted':
|
|
68
|
+
return theme.semantics.content.muted;
|
|
69
|
+
case 'subtle':
|
|
70
|
+
return theme.semantics.content.subtle;
|
|
71
|
+
case 'inverse':
|
|
72
|
+
return theme.semantics.content.inverse;
|
|
73
|
+
case 'primary':
|
|
74
|
+
return theme.semantics.brand.base;
|
|
75
|
+
case 'danger':
|
|
76
|
+
return theme.semantics.danger.base;
|
|
77
|
+
case 'success':
|
|
78
|
+
return theme.semantics.success.base;
|
|
79
|
+
case 'warning':
|
|
80
|
+
return theme.semantics.warning.base;
|
|
81
|
+
case 'default':
|
|
82
|
+
default:
|
|
83
|
+
return theme.semantics.content.default;
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
export function resolveTextStyle({ theme, breakpoint, variant, tone, weight, align, italic = false, }) {
|
|
87
|
+
const resolvedVariant = resolveResponsive(variant, breakpoint) ?? 'body';
|
|
88
|
+
const resolvedTone = resolveResponsive(tone, breakpoint) ?? 'default';
|
|
89
|
+
const resolvedAlign = resolveResponsive(align, breakpoint);
|
|
90
|
+
const recipe = resolveVariantRecipe(theme, resolvedVariant, breakpoint);
|
|
91
|
+
const resolvedWeight = resolveWeight(theme, resolveResponsive(weight, breakpoint) ?? recipe.weight);
|
|
92
|
+
return {
|
|
93
|
+
color: resolveToneColor(theme, resolvedTone),
|
|
94
|
+
elevation: 0,
|
|
95
|
+
fontFamily: resolveFontFamily({
|
|
96
|
+
theme,
|
|
97
|
+
variant: resolvedVariant,
|
|
98
|
+
weight: resolvedWeight,
|
|
99
|
+
italic,
|
|
100
|
+
}),
|
|
101
|
+
fontSize: recipe.fontSize,
|
|
102
|
+
fontStyle: italic ? 'italic' : 'normal',
|
|
103
|
+
fontWeight: resolvedWeight,
|
|
104
|
+
letterSpacing: recipe.letterSpacing,
|
|
105
|
+
lineHeight: recipe.lineHeight,
|
|
106
|
+
textAlign: resolvedAlign,
|
|
107
|
+
textTransform: recipe.textTransform,
|
|
108
|
+
};
|
|
109
|
+
}
|
|
110
|
+
//# sourceMappingURL=resolveTextRecipe.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"resolveTextRecipe.js","sourceRoot":"","sources":["../../../src/components/text/resolveTextRecipe.ts"],"names":[],"mappings":"AAAA,OAAO,EAIL,iBAAiB,GAElB,MAAM,oBAAoB,CAAC;AAuB5B,SAAS,0BAA0B,CAAC,UAAsB;IACxD,OAAO,UAAU,KAAK,IAAI,IAAI,UAAU,KAAK,IAAI,IAAI,UAAU,KAAK,IAAI,CAAC;AAC3E,CAAC;AAED,SAAS,aAAa,CAAC,KAAgB,EAAE,MAAkB;IACzD,OAAO,KAAK,CAAC,UAAU,CAAC,O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AO,CAAC;IAC3C,CAAC;AACH,CAAC;AAED,MAAM,UAAU,gBAAgB,CAAC,EAC/B,KAAK,EACL,UAAU,EACV,OAAO,EACP,IAAI,EACJ,MAAM,EACN,KAAK,EACL,MAAM,GAAG,KAAK,GACU;IACxB,MAAM,eAAe,GAAG,iBAAiB,CAAC,OAAO,EAAE,UAAU,CAAC,IAAI,MAAM,CAAC;IACzE,MAAM,YAAY,GAAG,iBAAiB,CAAC,IAAI,EAAE,UAAU,CAAC,IAAI,SAAS,CAAC;IACtE,MAAM,aAAa,GAAG,iBAAiB,CAAC,KAAK,EAAE,UAAU,CAAC,CAAC;IAC3D,MAAM,MAAM,GAAG,oBAAoB,CAAC,KAAK,EAAE,eAAe,EAAE,UAAU,CAAC,CAAC;IACxE,MAAM,cAAc,GAAG,aAAa,CAClC,KAAK,EACL,iBAAiB,CAAC,MAAM,EAAE,UAAU,CAAC,IAAI,MAAM,CAAC,MAAM,CACvD,CAAC;IAEF,OAAO;QACL,KAAK,EAAE,gBAAgB,CAAC,KAAK,EAAE,YAAY,CAAC;QAC5C,SAAS,EAAE,CAAC;QACZ,UAAU,EAAE,iBAAiB,CAAC;YAC5B,KAAK;YACL,OAAO,EAAE,eAAe;YACxB,MAAM,EAAE,cAAc;YACtB,MAAM;SACP,CAAC;QACF,QAAQ,EAAE,MAAM,CAAC,QAAQ;QACzB,SAAS,EAAE,MAAM,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,QAAQ;QACvC,UAAU,EAAE,cAAc;QAC1B,aAAa,EAAE,MAAM,CAAC,aAAa;QACnC,UAAU,EAAE,MAAM,CAAC,UAAU;QAC7B,SAAS,EAAE,aAAa;QACxB,aAAa,EAAE,MAAM,CAAC,aAAa;KACpC,CAAC;AACJ,CAAC","sourcesContent":["import {\n type AnkhTheme,\n type Breakpoint,\n type FontWeight,\n resolveResponsive,\n type Responsive,\n} from '@ankhorage/surface';\nimport type { TextStyle } from 'react-native';\n\nimport type { TextAlign, TextTone, TextVariant, TextWeight } from './types';\n\ninterface VariantRecipe {\n fontSize: number;\n lineHeight: number;\n weight: TextWeight;\n textTransform?: TextStyle['textTransform'];\n letterSpacing?: number;\n}\n\ninterface ResolveTextStyleOptions {\n theme: AnkhTheme;\n breakpoint: Breakpoint;\n variant?: Responsive<TextVariant>;\n tone?: Responsive<TextTone>;\n weight?: Responsive<TextWeight>;\n align?: Responsive<TextAlign>;\n italic?: boolean;\n}\n\nfunction isMediumBreakpointOrLarger(breakpoint: Breakpoint): boolean {\n return breakpoint === 'md' || breakpoint === 'lg' || breakpoint === 'xl';\n}\n\nfunction resolveWeight(theme: AnkhTheme, weight: TextWeight): FontWeight {\n return theme.typography.weights[weight];\n}\n\nfunction resolveFontFamily({\n theme,\n variant,\n weight,\n italic,\n}: {\n theme: AnkhTheme;\n variant: TextVariant;\n weight: FontWeight;\n italic: boolean;\n}): string | undefined {\n if (variant === 'code') {\n return 'monospace';\n }\n\n return theme.typography.fonts[italic ? 'italic' : 'normal'][weight];\n}\n\nfunction resolveVariantRecipe(\n theme: AnkhTheme,\n variant: TextVariant,\n breakpoint: Breakpoint,\n): VariantRecipe {\n switch (variant) {\n case 'lead':\n return {\n fontSize: isMediumBreakpointOrLarger(breakpoint)\n ? theme.typography.sizes.l\n : theme.typography.sizes.m,\n lineHeight: isMediumBreakpointOrLarger(breakpoint) ? 28 : 24,\n weight: 'regular',\n };\n case 'bodySmall':\n return {\n fontSize: theme.typography.sizes.s,\n lineHeight: 20,\n weight: 'regular',\n };\n case 'caption':\n return {\n fontSize: theme.typography.sizes.xs,\n lineHeight: 16,\n weight: 'regular',\n };\n case 'label':\n return {\n fontSize: theme.typography.sizes.s,\n lineHeight: 18,\n weight: 'medium',\n };\n case 'eyebrow':\n return {\n fontSize: theme.typography.sizes.xs,\n lineHeight: 16,\n weight: 'semiBold',\n textTransform: 'uppercase',\n letterSpacing: 0.8,\n };\n case 'code':\n return {\n fontSize: theme.typography.sizes.s,\n lineHeight: 20,\n weight: 'regular',\n };\n case 'body':\n default:\n return {\n fontSize: theme.typography.sizes.m,\n lineHeight: 24,\n weight: 'regular',\n };\n }\n}\n\nfunction resolveToneColor(theme: AnkhTheme, tone: TextTone): string {\n switch (tone) {\n case 'muted':\n return theme.semantics.content.muted;\n case 'subtle':\n return theme.semantics.content.subtle;\n case 'inverse':\n return theme.semantics.content.inverse;\n case 'primary':\n return theme.semantics.brand.base;\n case 'danger':\n return theme.semantics.danger.base;\n case 'success':\n return theme.semantics.success.base;\n case 'warning':\n return theme.semantics.warning.base;\n case 'default':\n default:\n return theme.semantics.content.default;\n }\n}\n\nexport function resolveTextStyle({\n theme,\n breakpoint,\n variant,\n tone,\n weight,\n align,\n italic = false,\n}: ResolveTextStyleOptions): TextStyle {\n const resolvedVariant = resolveResponsive(variant, breakpoint) ?? 'body';\n const resolvedTone = resolveResponsive(tone, breakpoint) ?? 'default';\n const resolvedAlign = resolveResponsive(align, breakpoint);\n const recipe = resolveVariantRecipe(theme, resolvedVariant, breakpoint);\n const resolvedWeight = resolveWeight(\n theme,\n resolveResponsive(weight, breakpoint) ?? recipe.weight,\n );\n\n return {\n color: resolveToneColor(theme, resolvedTone),\n elevation: 0,\n fontFamily: resolveFontFamily({\n theme,\n variant: resolvedVariant,\n weight: resolvedWeight,\n italic,\n }),\n fontSize: recipe.fontSize,\n fontStyle: italic ? 'italic' : 'normal',\n fontWeight: resolvedWeight,\n letterSpacing: recipe.letterSpacing,\n lineHeight: recipe.lineHeight,\n textAlign: resolvedAlign,\n textTransform: recipe.textTransform,\n };\n}\n"]}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import type { Responsive } from '@ankhorage/surface';
|
|
2
|
+
import type React from 'react';
|
|
3
|
+
import type { AccessibilityRole, TextStyle } from 'react-native';
|
|
4
|
+
export type TextVariant = 'body' | 'lead' | 'bodySmall' | 'caption' | 'label' | 'eyebrow' | 'code';
|
|
5
|
+
export type TextTone = 'default' | 'muted' | 'subtle' | 'inverse' | 'primary' | 'danger' | 'success' | 'warning';
|
|
6
|
+
export type TextWeight = 'regular' | 'medium' | 'semiBold' | 'bold';
|
|
7
|
+
export type TextAlign = NonNullable<TextStyle['textAlign']>;
|
|
8
|
+
export interface TextProps {
|
|
9
|
+
children?: React.ReactNode;
|
|
10
|
+
text?: string;
|
|
11
|
+
i18nKey?: string;
|
|
12
|
+
variant?: Responsive<TextVariant>;
|
|
13
|
+
tone?: Responsive<TextTone>;
|
|
14
|
+
align?: Responsive<TextAlign>;
|
|
15
|
+
weight?: Responsive<TextWeight>;
|
|
16
|
+
italic?: boolean;
|
|
17
|
+
numberOfLines?: number;
|
|
18
|
+
ellipsizeMode?: 'head' | 'middle' | 'tail' | 'clip';
|
|
19
|
+
selectable?: boolean;
|
|
20
|
+
accessibilityLabel?: string;
|
|
21
|
+
accessibilityHint?: string;
|
|
22
|
+
accessibilityRole?: AccessibilityRole;
|
|
23
|
+
nativeID?: string;
|
|
24
|
+
testID?: string;
|
|
25
|
+
}
|
|
26
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/components/text/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AACrD,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,KAAK,EAAE,iBAAiB,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAEjE,MAAM,MAAM,WAAW,GAAG,MAAM,GAAG,MAAM,GAAG,WAAW,GAAG,SAAS,GAAG,OAAO,GAAG,SAAS,GAAG,MAAM,CAAC;AAEnG,MAAM,MAAM,QAAQ,GAChB,SAAS,GACT,OAAO,GACP,QAAQ,GACR,SAAS,GACT,SAAS,GACT,QAAQ,GACR,SAAS,GACT,SAAS,CAAC;AAEd,MAAM,MAAM,UAAU,GAAG,SAAS,GAAG,QAAQ,GAAG,UAAU,GAAG,MAAM,CAAC;AAEpE,MAAM,MAAM,SAAS,GAAG,WAAW,CAAC,SAAS,CAAC,WAAW,CAAC,CAAC,CAAC;AAE5D,MAAM,WAAW,SAAS;IACxB,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,UAAU,CAAC,WAAW,CAAC,CAAC;IAClC,IAAI,CAAC,EAAE,UAAU,CAAC,QAAQ,CAAC,CAAC;IAC5B,KAAK,CAAC,EAAE,UAAU,CAAC,SAAS,CAAC,CAAC;IAC9B,MAAM,CAAC,EAAE,UAAU,CAAC,UAAU,CAAC,CAAC;IAChC,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,aAAa,CAAC,EAAE,MAAM,GAAG,QAAQ,GAAG,MAAM,GAAG,MAAM,CAAC;IACpD,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,iBAAiB,CAAC,EAAE,iBAAiB,CAAC;IACtC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/components/text/types.ts"],"names":[],"mappings":"","sourcesContent":["import type { Responsive } from '@ankhorage/surface';\nimport type React from 'react';\nimport type { AccessibilityRole, TextStyle } from 'react-native';\n\nexport type TextVariant = 'body' | 'lead' | 'bodySmall' | 'caption' | 'label' | 'eyebrow' | 'code';\n\nexport type TextTone =\n | 'default'\n | 'muted'\n | 'subtle'\n | 'inverse'\n | 'primary'\n | 'danger'\n | 'success'\n | 'warning';\n\nexport type TextWeight = 'regular' | 'medium' | 'semiBold' | 'bold';\n\nexport type TextAlign = NonNullable<TextStyle['textAlign']>;\n\nexport interface TextProps {\n children?: React.ReactNode;\n text?: string;\n i18nKey?: string;\n variant?: Responsive<TextVariant>;\n tone?: Responsive<TextTone>;\n align?: Responsive<TextAlign>;\n weight?: Responsive<TextWeight>;\n italic?: boolean;\n numberOfLines?: number;\n ellipsizeMode?: 'head' | 'middle' | 'tail' | 'clip';\n selectable?: boolean;\n accessibilityLabel?: string;\n accessibilityHint?: string;\n accessibilityRole?: AccessibilityRole;\n nativeID?: string;\n testID?: string;\n}\n"]}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import
|
|
1
|
+
import * as Surface from '@ankhorage/surface';
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { resolveIconSize } from '../../internal/recipes';
|
|
4
4
|
export function Textarea({ size = 'l', leadingIcon, trailingIcon, ...props }) {
|
|
5
|
-
const { theme } = useTheme();
|
|
5
|
+
const { theme } = Surface.useTheme();
|
|
6
6
|
const iconSize = resolveIconSize(size);
|
|
7
7
|
const iconColor = theme.semantics.content.muted;
|
|
8
|
-
return (<
|
|
8
|
+
return (<Surface.Textarea {...props} leadingAccessory={leadingIcon ? (<Surface.Icon color={iconColor} name={leadingIcon.name} provider={leadingIcon.provider} size={iconSize}/>) : undefined} size={size} trailingAccessory={trailingIcon ? (<Surface.Icon color={iconColor} name={trailingIcon.name} provider={trailingIcon.provider} size={iconSize}/>) : undefined}/>);
|
|
9
9
|
}
|
|
10
10
|
//# sourceMappingURL=Textarea.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Textarea.js","sourceRoot":"","sources":["../../../src/components/textarea/Textarea.tsx"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"Textarea.js","sourceRoot":"","sources":["../../../src/components/textarea/Textarea.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,OAAO,MAAM,oBAAoB,CAAC;AAC9C,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AAGzD,MAAM,UAAU,QAAQ,CAAC,EAAE,IAAI,GAAG,GAAG,EAAE,WAAW,EAAE,YAAY,EAAE,GAAG,KAAK,EAAiB;IACzF,MAAM,EAAE,KAAK,EAAE,GAAG,OAAO,CAAC,QAAQ,EAAE,CAAC;IACrC,MAAM,QAAQ,GAAG,eAAe,CAAC,IAAI,CAAC,CAAC;IACvC,MAAM,SAAS,GAAG,KAAK,CAAC,SAAS,CAAC,OAAO,CAAC,KAAK,CAAC;IAEhD,OAAO,CACL,CAAC,OAAO,CAAC,QAAQ,CACf,IAAI,KAAK,CAAC,CACV,gBAAgB,CAAC,CACf,WAAW,CAAC,CAAC,CAAC,CACZ,CAAC,OAAO,CAAC,IAAI,CACX,KAAK,CAAC,CAAC,SAAS,CAAC,CACjB,IAAI,CAAC,CAAC,WAAW,CAAC,IAAI,CAAC,CACvB,QAAQ,CAAC,CAAC,WAAW,CAAC,QAAQ,CAAC,CAC/B,IAAI,CAAC,CAAC,QAAQ,CAAC,EACf,CACH,CAAC,CAAC,CAAC,SACN,CAAC,CACD,IAAI,CAAC,CAAC,IAAI,CAAC,CACX,iBAAiB,CAAC,CAChB,YAAY,CAAC,CAAC,CAAC,CACb,CAAC,OAAO,CAAC,IAAI,CACX,KAAK,CAAC,CAAC,SAAS,CAAC,CACjB,IAAI,CAAC,CAAC,YAAY,CAAC,IAAI,CAAC,CACxB,QAAQ,CAAC,CAAC,YAAY,CAAC,QAAQ,CAAC,CAChC,IAAI,CAAC,CAAC,QAAQ,CAAC,EACf,CACH,CAAC,CAAC,CAAC,SACN,CAAC,EACD,CACH,CAAC;AACJ,CAAC","sourcesContent":["import * as Surface from '@ankhorage/surface';\nimport React from 'react';\n\nimport { resolveIconSize } from '../../internal/recipes';\nimport type { TextareaProps } from './types';\n\nexport function Textarea({ size = 'l', leadingIcon, trailingIcon, ...props }: TextareaProps) {\n const { theme } = Surface.useTheme();\n const iconSize = resolveIconSize(size);\n const iconColor = theme.semantics.content.muted;\n\n return (\n <Surface.Textarea\n {...props}\n leadingAccessory={\n leadingIcon ? (\n <Surface.Icon\n color={iconColor}\n name={leadingIcon.name}\n provider={leadingIcon.provider}\n size={iconSize}\n />\n ) : undefined\n }\n size={size}\n trailingAccessory={\n trailingIcon ? (\n <Surface.Icon\n color={iconColor}\n name={trailingIcon.name}\n provider={trailingIcon.provider}\n size={iconSize}\n />\n ) : undefined\n }\n />\n );\n}\n"]}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import type
|
|
1
|
+
import type * as Surface from '@ankhorage/surface';
|
|
2
2
|
import type { ZoraControlSize } from '../../internal/recipes';
|
|
3
|
-
export interface TextareaProps extends Omit<
|
|
3
|
+
export interface TextareaProps extends Omit<Surface.TextareaProps, 'leadingAccessory' | 'size' | 'trailingAccessory'> {
|
|
4
4
|
size?: ZoraControlSize;
|
|
5
|
-
leadingIcon?: ButtonIconSpec;
|
|
6
|
-
trailingIcon?: ButtonIconSpec;
|
|
5
|
+
leadingIcon?: Surface.ButtonIconSpec;
|
|
6
|
+
trailingIcon?: Surface.ButtonIconSpec;
|
|
7
7
|
}
|
|
8
8
|
//# sourceMappingURL=types.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/components/textarea/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/components/textarea/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,OAAO,MAAM,oBAAoB,CAAC;AAEnD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AAE9D,MAAM,WAAW,aAAc,SAAQ,IAAI,CACzC,OAAO,CAAC,aAAa,EACrB,kBAAkB,GAAG,MAAM,GAAG,mBAAmB,CAClD;IACC,IAAI,CAAC,EAAE,eAAe,CAAC;IACvB,WAAW,CAAC,EAAE,OAAO,CAAC,cAAc,CAAC;IACrC,YAAY,CAAC,EAAE,OAAO,CAAC,cAAc,CAAC;CACvC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/components/textarea/types.ts"],"names":[],"mappings":"","sourcesContent":["import type
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/components/textarea/types.ts"],"names":[],"mappings":"","sourcesContent":["import type * as Surface from '@ankhorage/surface';\n\nimport type { ZoraControlSize } from '../../internal/recipes';\n\nexport interface TextareaProps extends Omit<\n Surface.TextareaProps,\n 'leadingAccessory' | 'size' | 'trailingAccessory'\n> {\n size?: ZoraControlSize;\n leadingIcon?: Surface.ButtonIconSpec;\n trailingIcon?: Surface.ButtonIconSpec;\n}\n"]}
|
package/dist/index.d.ts
CHANGED
|
@@ -24,6 +24,8 @@ export type { SelectOption, SelectProps } from './components/select';
|
|
|
24
24
|
export { Select } from './components/select';
|
|
25
25
|
export type { TabItem, TabsProps } from './components/tabs';
|
|
26
26
|
export { Tabs } from './components/tabs';
|
|
27
|
+
export type { TextAlign, TextProps, TextTone, TextVariant, TextWeight } from './components/text';
|
|
28
|
+
export { Text } from './components/text';
|
|
27
29
|
export type { TextareaProps } from './components/textarea';
|
|
28
30
|
export { Textarea } from './components/textarea';
|
|
29
31
|
export type { ToolbarActionProps, ToolbarProps } from './components/toolbar';
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AACrD,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAC3C,YAAY,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AACvD,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAC7C,YAAY,EAAE,SAAS,EAAE,MAA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yBAAyB,CAAC;AAChE,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AACtD,YAAY,EAAE,gBAAgB,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AAC5E,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAC7D,YAAY,EAAE,YAAY,EAAE,mBAAmB,EAAE,aAAa,EAAE,MAAM,sBAAsB,CAAC;AAC7F,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAC1D,cAAc,SAAS,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -11,6 +11,7 @@ export { Modal } from './components/modal';
|
|
|
11
11
|
export { Radio, RadioGroup } from './components/radio';
|
|
12
12
|
export { Select } from './components/select';
|
|
13
13
|
export { Tabs } from './components/tabs';
|
|
14
|
+
export { Text } from './components/text';
|
|
14
15
|
export { Textarea } from './components/textarea';
|
|
15
16
|
export { Toolbar, ToolbarAction } from './components/toolbar';
|
|
16
17
|
export { AppShell } from './layout/app-shell';
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAE3C,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAE7C,OAAO,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AAEzC,OAAO,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAEhE,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAmB7C,OAAO,EACL,IAAI,EACJ,WAAW,EACX,SAAS,EACT,SAAS,EACT,eAAe,EACf,iBAAiB,EACjB,aAAa,EACb,cAAc,EACd,aAAa,GACd,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;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M,mBAAmB,CAAC;AAE3C,OAAO,EAAE,KAAK,EAAE,MAAM,kBAAkB,CAAC;AAEzC,OAAO,EAAE,eAAe,EAAE,MAAM,6BAA6B,CAAC;AAE9D,OAAO,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAE1D,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAEtD,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAEtD,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAE7D,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAC1D,cAAc,SAAS,CAAC","sourcesContent":["export type { BadgeProps } from './components/badge';\nexport { Badge } from './components/badge';\nexport type { ButtonProps } from './components/button';\nexport { Button } from './components/button';\nexport type { CardProps } from './components/card';\nexport { Card } from './components/card';\nexport type { CheckboxGroupOption, CheckboxGroupProps, CheckboxProps } from './components/checkbox';\nexport { Checkbox, CheckboxGroup } from './components/checkbox';\nexport type { DrawerProps } from './components/drawer';\nexport { Drawer } from './components/drawer';\nexport type {\n FormActionsProps,\n FormErrorProps,\n FormErrors,\n FormFieldConfig,\n FormFieldControlProps,\n FormFieldInputType,\n FormFieldProps,\n FormFieldValue,\n FormFieldWrapperProps,\n FormProps,\n FormValidationErrors,\n FormValidationResult,\n FormValues,\n UseFormControllerOptions,\n UseFormControllerResult,\n ValidationRule,\n} from './components/form';\nexport {\n Form,\n FormActions,\n FormError,\n FormField,\n hasRequiredRule,\n useFormController,\n validateField,\n validateFields,\n validateValue,\n} from './components/form';\nexport type { IconProps } from './components/icon';\nexport { Icon } from './components/icon';\nexport type { IconButtonProps } from './components/icon-button';\nexport { IconButton } from './components/icon-button';\nexport type { InputProps } from './components/input';\nexport { Input } from './components/input';\nexport type { ModalProps } from './components/modal';\nexport { Modal } from './components/modal';\nexport type { RadioGroupOption, RadioGroupProps, RadioProps } from './components/radio';\nexport { Radio, RadioGroup } from './components/radio';\nexport type { SelectOption, SelectProps } from './components/select';\nexport { Select } from './components/select';\nexport type { TabItem, TabsProps } from './components/tabs';\nexport { Tabs } from './components/tabs';\nexport type { TextareaProps } from './components/textarea';\nexport { Textarea } from './components/textarea';\nexport type { ToolbarActionProps, ToolbarProps } from './components/toolbar';\nexport { Toolbar, ToolbarAction } from './components/toolbar';\nexport type { AppShellProps } from './layout/app-shell';\nexport { AppShell } from './layout/app-shell';\nexport type { AuthLayoutProps } from './layout/auth-layout';\nexport { AuthLayout } from './layout/auth-layout';\nexport type { PageProps } from './layout/page';\nexport { Page } from './layout/page';\nexport type { PageHeaderProps } from './layout/page-header';\nexport { PageHeader } from './layout/page-header';\nexport type { PageSectionProps } from './layout/page-section';\nexport { PageSection } from './layout/page-section';\nexport type { SettingsLayoutProps } from './layout/settings-layout';\nexport { SettingsLayout } from './layout/settings-layout';\nexport type { SidebarLayoutProps } from './layout/sidebar-layout';\nexport { SidebarLayout } from './layout/sidebar-layout';\nexport type { TopbarLayoutProps } from './layout/topbar-layout';\nexport { TopbarLayout } from './layout/topbar-layout';\nexport type {\n AuthFormBaseProps,\n AuthIdentifierKind,\n ForgotPasswordFormProps,\n ForgotPasswordFormValues,\n OtpFormProps,\n OtpFormValues,\n SignInFormProps,\n SignInFormValues,\n SignUpFormField,\n SignUpFormProps,\n SignUpFormValues,\n} from './patterns/auth';\nexport { ForgotPasswordForm, OtpForm, SignInForm, SignUpForm } from './patterns/auth';\nexport type {\n CollectionEditorProps,\n CollectionEditorRenderItemProps,\n} from './patterns/collection-editor';\nexport { CollectionEditor } from './patterns/collection-editor';\nexport type { ConfirmDialogProps } from './patterns/confirm-dialog';\nexport { ConfirmDialog } from './patterns/confirm-dialog';\nexport type { DisclosureSectionProps } from './patterns/disclosure-section';\nexport { DisclosureSection } from './patterns/disclosure-section';\nexport type { EmptyStateAction, EmptyStateProps } from './patterns/empty-state';\nexport { EmptyState } from './patterns/empty-state';\nexport type { InspectorFieldProps } from './patterns/inspector-field';\nexport { InspectorField } from './patterns/inspector-field';\nexport type { NoticeProps } from './patterns/notice';\nexport { Notice } from './patterns/notice';\nexport type { PanelProps } from './patterns/panel';\nexport { Panel } from './patterns/panel';\nexport type { ResponsivePanelProps } from './patterns/responsive-panel';\nexport { ResponsivePanel } from './patterns/responsive-panel';\nexport type { SectionHeaderProps } from './patterns/section-header';\nexport { SectionHeader } from './patterns/section-header';\nexport type { SettingsRowProps } from './patterns/settings-row';\nexport { SettingsRow } from './patterns/settings-row';\nexport type { SwitchFieldProps } from './patterns/switch-field';\nexport { SwitchField } from './patterns/switch-field';\nexport type { PaletteItemProps, TileGridProps } from './patterns/tile-grid';\nexport { PaletteItem, TileGrid } from './patterns/tile-grid';\nexport type { TreeItemNode, TreeItemRenderProps, TreeViewProps } from './patterns/tree-view';\nexport { TreeItem, TreeView } from './patterns/tree-view';\nexport * from './theme';\n"]}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAE3C,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAE7C,OAAO,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AAEzC,OAAO,EAAE,QAAQ,EAAE,aAAa,EAAE,MAAM,uBAAuB,CAAC;AAEhE,OAAO,EAAE,MAAM,EAAE,MAAM,qBAAqB,CAAC;AAmB7C,OAAO,EACL,IAAI,EACJ,WAAW,EACX,SAAS,EACT,SAAS,EACT,eAAe,EACf,iBAAiB,EACjB,aAAa,EACb,cAAc,EACd,aAAa,GACd,MAAM,mBAAmB,CAAC;AAE3B,OAAO,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AAEzC,OAAO,EAAE,UAAU,EAAE,MAAM,0BAA0B,CAAC;AAEtD,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAE3C,OAAO,EAAE,KAAK,EAAE,MAAM,oB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e,EAAE,MAAM,6BAA6B,CAAC;AAE9D,OAAO,EAAE,aAAa,EAAE,MAAM,2BAA2B,CAAC;AAE1D,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAEtD,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAC;AAEtD,OAAO,EAAE,WAAW,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAE7D,OAAO,EAAE,QAAQ,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAC1D,cAAc,SAAS,CAAC","sourcesContent":["export type { BadgeProps } from './components/badge';\nexport { Badge } from './components/badge';\nexport type { ButtonProps } from './components/button';\nexport { Button } from './components/button';\nexport type { CardProps } from './components/card';\nexport { Card } from './components/card';\nexport type { CheckboxGroupOption, CheckboxGroupProps, CheckboxProps } from './components/checkbox';\nexport { Checkbox, CheckboxGroup } from './components/checkbox';\nexport type { DrawerProps } from './components/drawer';\nexport { Drawer } from './components/drawer';\nexport type {\n FormActionsProps,\n FormErrorProps,\n FormErrors,\n FormFieldConfig,\n FormFieldControlProps,\n FormFieldInputType,\n FormFieldProps,\n FormFieldValue,\n FormFieldWrapperProps,\n FormProps,\n FormValidationErrors,\n FormValidationResult,\n FormValues,\n UseFormControllerOptions,\n UseFormControllerResult,\n ValidationRule,\n} from './components/form';\nexport {\n Form,\n FormActions,\n FormError,\n FormField,\n hasRequiredRule,\n useFormController,\n validateField,\n validateFields,\n validateValue,\n} from './components/form';\nexport type { IconProps } from './components/icon';\nexport { Icon } from './components/icon';\nexport type { IconButtonProps } from './components/icon-button';\nexport { IconButton } from './components/icon-button';\nexport type { InputProps } from './components/input';\nexport { Input } from './components/input';\nexport type { ModalProps } from './components/modal';\nexport { Modal } from './components/modal';\nexport type { RadioGroupOption, RadioGroupProps, RadioProps } from './components/radio';\nexport { Radio, RadioGroup } from './components/radio';\nexport type { SelectOption, SelectProps } from './components/select';\nexport { Select } from './components/select';\nexport type { TabItem, TabsProps } from './components/tabs';\nexport { Tabs } from './components/tabs';\nexport type { TextAlign, TextProps, TextTone, TextVariant, TextWeight } from './components/text';\nexport { Text } from './components/text';\nexport type { TextareaProps } from './components/textarea';\nexport { Textarea } from './components/textarea';\nexport type { ToolbarActionProps, ToolbarProps } from './components/toolbar';\nexport { Toolbar, ToolbarAction } from './components/toolbar';\nexport type { AppShellProps } from './layout/app-shell';\nexport { AppShell } from './layout/app-shell';\nexport type { AuthLayoutProps } from './layout/auth-layout';\nexport { AuthLayout } from './layout/auth-layout';\nexport type { PageProps } from './layout/page';\nexport { Page } from './layout/page';\nexport type { PageHeaderProps } from './layout/page-header';\nexport { PageHeader } from './layout/page-header';\nexport type { PageSectionProps } from './layout/page-section';\nexport { PageSection } from './layout/page-section';\nexport type { SettingsLayoutProps } from './layout/settings-layout';\nexport { SettingsLayout } from './layout/settings-layout';\nexport type { SidebarLayoutProps } from './layout/sidebar-layout';\nexport { SidebarLayout } from './layout/sidebar-layout';\nexport type { TopbarLayoutProps } from './layout/topbar-layout';\nexport { TopbarLayout } from './layout/topbar-layout';\nexport type {\n AuthFormBaseProps,\n AuthIdentifierKind,\n ForgotPasswordFormProps,\n ForgotPasswordFormValues,\n OtpFormProps,\n OtpFormValues,\n SignInFormProps,\n SignInFormValues,\n SignUpFormField,\n SignUpFormProps,\n SignUpFormValues,\n} from './patterns/auth';\nexport { ForgotPasswordForm, OtpForm, SignInForm, SignUpForm } from './patterns/auth';\nexport type {\n CollectionEditorProps,\n CollectionEditorRenderItemProps,\n} from './patterns/collection-editor';\nexport { CollectionEditor } from './patterns/collection-editor';\nexport type { ConfirmDialogProps } from './patterns/confirm-dialog';\nexport { ConfirmDialog } from './patterns/confirm-dialog';\nexport type { DisclosureSectionProps } from './patterns/disclosure-section';\nexport { DisclosureSection } from './patterns/disclosure-section';\nexport type { EmptyStateAction, EmptyStateProps } from './patterns/empty-state';\nexport { EmptyState } from './patterns/empty-state';\nexport type { InspectorFieldProps } from './patterns/inspector-field';\nexport { InspectorField } from './patterns/inspector-field';\nexport type { NoticeProps } from './patterns/notice';\nexport { Notice } from './patterns/notice';\nexport type { PanelProps } from './patterns/panel';\nexport { Panel } from './patterns/panel';\nexport type { ResponsivePanelProps } from './patterns/responsive-panel';\nexport { ResponsivePanel } from './patterns/responsive-panel';\nexport type { SectionHeaderProps } from './patterns/section-header';\nexport { SectionHeader } from './patterns/section-header';\nexport type { SettingsRowProps } from './patterns/settings-row';\nexport { SettingsRow } from './patterns/settings-row';\nexport type { SwitchFieldProps } from './patterns/switch-field';\nexport { SwitchField } from './patterns/switch-field';\nexport type { PaletteItemProps, TileGridProps } from './patterns/tile-grid';\nexport { PaletteItem, TileGrid } from './patterns/tile-grid';\nexport type { TreeItemNode, TreeItemRenderProps, TreeViewProps } from './patterns/tree-view';\nexport { TreeItem, TreeView } from './patterns/tree-view';\nexport * from './theme';\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PageHeader.d.ts","sourceRoot":"","sources":["../../../src/layout/page-header/PageHeader.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"PageHeader.d.ts","sourceRoot":"","sources":["../../../src/layout/page-header/PageHeader.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,SAAS,CAAC;AAE/C,wBAAgB,UAAU,CAAC,EACzB,KAAK,EACL,WAAW,EACX,OAAO,EACP,OAAO,EACP,IAAI,EACJ,MAAM,GACP,EAAE,eAAe,qBA4BjB"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { Box, Heading, Stack
|
|
1
|
+
import { Box, Heading, Stack } from '@ankhorage/surface';
|
|
2
2
|
import React from 'react';
|
|
3
|
+
import { Text } from '../../components/text';
|
|
3
4
|
export function PageHeader({ title, description, eyebrow, actions, meta, testID, }) {
|
|
4
5
|
return (<Stack align={{ base: 'flex-start', md: 'center' }} direction={{ base: 'column', md: 'row' }} gap="l" justify="space-between" testID={testID}>
|
|
5
6
|
<Box flex={1}>
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PageHeader.js","sourceRoot":"","sources":["../../../src/layout/page-header/PageHeader.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,OAAO,EAAE,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"PageHeader.js","sourceRoot":"","sources":["../../../src/layout/page-header/PageHeader.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AACzD,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAG7C,MAAM,UAAU,UAAU,CAAC,EACzB,KAAK,EACL,WAAW,EACX,OAAO,EACP,OAAO,EACP,IAAI,EACJ,MAAM,GACU;IAChB,OAAO,CACL,CAAC,KAAK,CACJ,KAAK,CAAC,CAAC,EAAE,IAAI,EAAE,YAAY,EAAE,EAAE,EAAE,QAAQ,EAAE,CAAC,CAC5C,SAAS,CAAC,CAAC,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,EAAE,KAAK,EAAE,CAAC,CACzC,GAAG,CAAC,GAAG,CACP,OAAO,CAAC,eAAe,CACvB,MAAM,CAAC,CAAC,MAAM,CAAC,CAEf;MAAA,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,CACX;QAAA,CAAC,KAAK,CAAC,GAAG,CAAC,GAAG,CACZ;UAAA,CAAC,OAAO,CAAC,CAAC,CAAC,CACT,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,SAAS,CAAC,MAAM,CAAC,UAAU,CACpD;cAAA,CAAC,OAAO,CACV;YAAA,EAAE,IAAI,CAAC,CACR,CAAC,CAAC,CAAC,IAAI,CACR;UAAA,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,EAAE,OAAO,CACnC;UAAA,CAAC,WAAW,CAAC,CAAC,CAAC,CACb,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,MAAM,CAC/B;cAAA,CAAC,WAAW,CACd;YAAA,EAAE,IAAI,CAAC,CACR,CAAC,CAAC,CAAC,IAAI,CACR;UAAA,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,EAAE,GAAG,CAAC,CAAC,CAAC,CAAC,IAAI,CAC1C;QAAA,EAAE,KAAK,CACT;MAAA,EAAE,GAAG,CACL;MAAA,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,OAAO,CAAC,EAAE,GAAG,CAAC,CAAC,CAAC,CAAC,IAAI,CACxC;IAAA,EAAE,KAAK,CAAC,CACT,CAAC;AACJ,CAAC","sourcesContent":["import { Box, Heading, Stack } from '@ankhorage/surface';\nimport React from 'react';\n\nimport { Text } from '../../components/text';\nimport type { PageHeaderProps } from './types';\n\nexport function PageHeader({\n title,\n description,\n eyebrow,\n actions,\n meta,\n testID,\n}: PageHeaderProps) {\n return (\n <Stack\n align={{ base: 'flex-start', md: 'center' }}\n direction={{ base: 'column', md: 'row' }}\n gap=\"l\"\n justify=\"space-between\"\n testID={testID}\n >\n <Box flex={1}>\n <Stack gap=\"s\">\n {eyebrow ? (\n <Text tone=\"muted\" variant=\"caption\" weight=\"semiBold\">\n {eyebrow}\n </Text>\n ) : null}\n <Heading level={1}>{title}</Heading>\n {description ? (\n <Text tone=\"muted\" variant=\"body\">\n {description}\n </Text>\n ) : null}\n {meta ? <Box pt=\"xs\">{meta}</Box> : null}\n </Stack>\n </Box>\n {actions ? <Box>{actions}</Box> : null}\n </Stack>\n );\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CollectionEditor.d.ts","sourceRoot":"","sources":["../../../src/patterns/collection-editor/CollectionEditor.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"CollectionEditor.d.ts","sourceRoot":"","sources":["../../../src/patterns/collection-editor/CollectionEditor.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAM1B,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,SAAS,CAAC;AAErD,wBAAgB,gBAAgB,CAAC,KAAK,EAAE,EACtC,KAAK,EACL,WAAW,EACX,KAAK,EACL,UAAU,EACV,KAAK,EACL,QAAQ,EACR,MAAM,EACN,QAAqB,EACrB,UAA4B,EAC5B,QAAQ,EACR,MAAM,GACP,EAAE,qBAAqB,CAAC,KAAK,CAAC,qBA+E9B"}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import { Box, Stack
|
|
1
|
+
import { Box, Stack } from '@ankhorage/surface';
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { Button } from '../../components/button';
|
|
4
4
|
import { IconButton } from '../../components/icon-button';
|
|
5
|
+
import { Text } from '../../components/text';
|
|
5
6
|
import { Panel } from '../panel';
|
|
6
7
|
export function CollectionEditor({ title, description, items, renderItem, onAdd, onRemove, onMove, addLabel = 'Add Item', emptyLabel = 'No items yet.', disabled, testID, }) {
|
|
7
8
|
const isEmpty = items.length === 0;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"CollectionEditor.js","sourceRoot":"","sources":["../../../src/patterns/collection-editor/CollectionEditor.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"CollectionEditor.js","sourceRoot":"","sources":["../../../src/patterns/collection-editor/CollectionEditor.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAChD,OAAO,KAAK,MAAM,OA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AAG,CACR,QAAQ,CAAC,OAAO,EAElB;sBAAA,CAAC,UAAU,CACT,IAAI,CAAC,CAAC,EAAE,IAAI,EAAE,oBAAoB,EAAE,CAAC,CACrC,KAAK,CAAC,WAAW,CACjB,QAAQ,CAAC,CAAC,QAAQ,IAAI,KAAK,KAAK,KAAK,CAAC,MAAM,GAAG,CAAC,CAAC,CACjD,OAAO,CAAC,CAAC,GAAG,EAAE,CAAC,MAAM,CAAC,KAAK,EAAE,KAAK,GAAG,CAAC,CAAC,CAAC,CACxC,IAAI,CAAC,GAAG,CACR,QAAQ,CAAC,OAAO,EAEpB;oBAAA,GAAG,CACJ,CAAC,CAAC,CAAC,IAAI,CACR;kBAAA,CAAC,QAAQ,CAAC,CAAC,CAAC,CACV,CAAC,UAAU,CACT,IAAI,CAAC,CAAC,EAAE,IAAI,EAAE,eAAe,EAAE,CAAC,CAChC,KAAK,CAAC,QAAQ,CACd,IAAI,CAAC,QAAQ,CACb,QAAQ,CAAC,CAAC,QAAQ,CAAC,CACnB,OAAO,CAAC,CAAC,GAAG,EAAE,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,CAC/B,IAAI,CAAC,GAAG,CACR,QAAQ,CAAC,OAAO,EAChB,CACH,CAAC,CAAC,CAAC,IAAI,CACV;gBAAA,EAAE,KAAK,CACT;cAAA,EAAE,KAAK,CACT;YAAA,EAAE,GAAG,CAAC,CACP,CAAC,CACH,CACH;MAAA,EAAE,KAAK,CACT;IAAA,EAAE,KAAK,CAAC,CACT,CAAC;AACJ,CAAC","sourcesContent":["import { Box, Stack } from '@ankhorage/surface';\nimport React from 'react';\n\nimport { Button } from '../../components/button';\nimport { IconButton } from '../../components/icon-button';\nimport { Text } from '../../components/text';\nimport { Panel } from '../panel';\nimport type { CollectionEditorProps } from './types';\n\nexport function CollectionEditor<TItem>({\n title,\n description,\n items,\n renderItem,\n onAdd,\n onRemove,\n onMove,\n addLabel = 'Add Item',\n emptyLabel = 'No items yet.',\n disabled,\n testID,\n}: CollectionEditorProps<TItem>) {\n const isEmpty = items.length === 0;\n\n return (\n <Panel\n compact\n description={description}\n testID={testID}\n title={title}\n actions={\n onAdd ? (\n <Button emphasis=\"soft\" size=\"s\" disabled={disabled} onPress={onAdd}>\n {addLabel}\n </Button>\n ) : null\n }\n >\n <Stack gap=\"s\">\n {isEmpty ? (\n <Box py=\"m\">\n <Text align=\"center\" tone=\"muted\">\n {emptyLabel}\n </Text>\n </Box>\n ) : (\n items.map((item, index) => (\n <Box key={index} bg=\"subtle\" p=\"s\" radius=\"m\" borderColor=\"border\" borderWidth={1}>\n <Stack direction=\"row\" gap=\"m\" align=\"center\">\n <Box flex={1}>\n {renderItem({\n item,\n index,\n remove: () => onRemove?.(index),\n moveUp: () => onMove?.(index, index - 1),\n moveDown: () => onMove?.(index, index + 1),\n canMoveUp: index > 0,\n canMoveDown: index < items.length - 1,\n })}\n </Box>\n <Stack direction=\"row\" gap=\"xs\">\n {onMove ? (\n <>\n <IconButton\n icon={{ name: 'arrow-up-outline' }}\n label=\"Move Up\"\n disabled={disabled ?? index === 0}\n onPress={() => onMove(index, index - 1)}\n size=\"s\"\n emphasis=\"ghost\"\n />\n <IconButton\n icon={{ name: 'arrow-down-outline' }}\n label=\"Move Down\"\n disabled={disabled ?? index === items.length - 1}\n onPress={() => onMove(index, index + 1)}\n size=\"s\"\n emphasis=\"ghost\"\n />\n </>\n ) : null}\n {onRemove ? (\n <IconButton\n icon={{ name: 'trash-outline' }}\n label=\"Remove\"\n tone=\"danger\"\n disabled={disabled}\n onPress={() => onRemove(index)}\n size=\"s\"\n emphasis=\"ghost\"\n />\n ) : null}\n </Stack>\n </Stack>\n </Box>\n ))\n )}\n </Stack>\n </Panel>\n );\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FormField.d.ts","sourceRoot":"","sources":["../../../src/patterns/form-field/FormField.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"FormField.d.ts","sourceRoot":"","sources":["../../../src/patterns/form-field/FormField.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAE9C,wBAAgB,SAAS,CAAC,EAAE,KAAK,EAAE,WAAW,EAAE,UAAU,EAAE,QAAQ,EAAE,GAAG,KAAK,EAAE,EAAE,cAAc,qBAqB/F"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { Field, Stack
|
|
1
|
+
import { Field, Stack } from '@ankhorage/surface';
|
|
2
2
|
import React from 'react';
|
|
3
|
+
import { Text } from '../../components/text';
|
|
3
4
|
export function FormField({ label, description, helperText, children, ...props }) {
|
|
4
5
|
return (<Field {...props} helperText={helperText} label={<Stack gap="xs">
|
|
5
6
|
<Text variant="label" weight="semiBold">
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"FormField.js","sourceRoot":"","sources":["../../../src/patterns/form-field/FormField.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"FormField.js","sourceRoot":"","sources":["../../../src/patterns/form-field/FormField.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAG7C,MAAM,UAAU,SAAS,CAAC,EAAE,KAAK,EAAE,WAAW,EAAE,UAAU,EAAE,QAAQ,EAAE,GAAG,KAAK,EAAkB;IAC9F,OAAO,CACL,CAAC,KAAK,CACJ,IAAI,KAAK,CAAC,CACV,UAAU,CAAC,CAAC,UAAU,CAAC,CACvB,KAAK,CAAC,CACJ,CAAC,KAAK,CAAC,GAAG,CAAC,IAAI,CACb;UAAA,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,MAAM,CAAC,UAAU,CACrC;YAAA,CAAC,KAAK,CACR;UAAA,EAAE,IAAI,CACN;UAAA,CAAC,WAAW,CAAC,CAAC,CAAC,CACb,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,WAAW,CACpC;cAAA,CAAC,WAAW,CACd;YAAA,EAAE,IAAI,CAAC,CACR,CAAC,CAAC,CAAC,IAAI,CACV;QAAA,EAAE,KAAK,CACT,CAAC,CAED;MAAA,CAAC,QAAQ,CACX;IAAA,EAAE,KAAK,CAAC,CACT,CAAC;AACJ,CAAC","sourcesContent":["import { Field, Stack } from '@ankhorage/surface';\nimport React from 'react';\n\nimport { Text } from '../../components/text';\nimport type { FormFieldProps } from './types';\n\nexport function FormField({ label, description, helperText, children, ...props }: FormFieldProps) {\n return (\n <Field\n {...props}\n helperText={helperText}\n label={\n <Stack gap=\"xs\">\n <Text variant=\"label\" weight=\"semiBold\">\n {label}\n </Text>\n {description ? (\n <Text tone=\"muted\" variant=\"bodySmall\">\n {description}\n </Text>\n ) : null}\n </Stack>\n }\n >\n {children}\n </Field>\n );\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/patterns/form-field/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/patterns/form-field/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/patterns/form-field/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC","sourcesContent":["export { FormField } from './FormField';\
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/patterns/form-field/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,aAAa,CAAC","sourcesContent":["export { FormField } from './FormField';\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SectionHeader.d.ts","sourceRoot":"","sources":["../../../src/patterns/section-header/SectionHeader.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"SectionHeader.d.ts","sourceRoot":"","sources":["../../../src/patterns/section-header/SectionHeader.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAG1B,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,SAAS,CAAC;AAElD,wBAAgB,aAAa,CAAC,EAC5B,KAAK,EACL,WAAW,EACX,OAAO,EACP,OAAO,EACP,MAAM,GACP,EAAE,kBAAkB,qBA2BpB"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { Box, Heading, Stack
|
|
1
|
+
import { Box, Heading, Stack } from '@ankhorage/surface';
|
|
2
2
|
import React from 'react';
|
|
3
|
+
import { Text } from '../../components/text';
|
|
3
4
|
export function SectionHeader({ title, description, eyebrow, actions, testID, }) {
|
|
4
5
|
return (<Stack align={{ base: 'flex-start', md: 'center' }} direction={{ base: 'column', md: 'row' }} gap="m" justify="space-between" testID={testID}>
|
|
5
6
|
<Box flex={1}>
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SectionHeader.js","sourceRoot":"","sources":["../../../src/patterns/section-header/SectionHeader.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,OAAO,EAAE,KAAK,EAAE,
|
|
1
|
+
{"version":3,"file":"SectionHeader.js","sourceRoot":"","sources":["../../../src/patterns/section-header/SectionHeader.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AACzD,OAAO,KAAK,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KAAK,CAAC,CACT,CAAC;AACJ,CAAC","sourcesContent":["import { Box, Heading, Stack } from '@ankhorage/surface';\nimport React from 'react';\n\nimport { Text } from '../../components/text';\nimport type { SectionHeaderProps } from './types';\n\nexport function SectionHeader({\n title,\n description,\n eyebrow,\n actions,\n testID,\n}: SectionHeaderProps) {\n return (\n <Stack\n align={{ base: 'flex-start', md: 'center' }}\n direction={{ base: 'column', md: 'row' }}\n gap=\"m\"\n justify=\"space-between\"\n testID={testID}\n >\n <Box flex={1}>\n <Stack gap=\"xs\">\n {eyebrow ? (\n <Text tone=\"muted\" variant=\"caption\" weight=\"semiBold\">\n {eyebrow}\n </Text>\n ) : null}\n <Heading level={3}>{title}</Heading>\n {description ? (\n <Text tone=\"muted\" variant=\"bodySmall\">\n {description}\n </Text>\n ) : null}\n </Stack>\n </Box>\n {actions ? <Box>{actions}</Box> : null}\n </Stack>\n );\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SettingsRow.d.ts","sourceRoot":"","sources":["../../../src/patterns/settings-row/SettingsRow.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"SettingsRow.d.ts","sourceRoot":"","sources":["../../../src/patterns/settings-row/SettingsRow.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAEhD,wBAAgB,WAAW,CAAC,EAC1B,KAAK,EACL,WAAW,EACX,IAAI,EACJ,OAAO,EACP,OAAO,EACP,QAAgB,EAChB,MAAM,GACP,EAAE,gBAAgB,qBAyBlB"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { Box
|
|
1
|
+
import { Box } from '@ankhorage/surface';
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { Card } from '../../components/card';
|
|
4
|
+
import { Text } from '../../components/text';
|
|
4
5
|
export function SettingsRow({ title, description, meta, control, onPress, disabled = false, testID, }) {
|
|
5
6
|
// Prevent nested interactive elements:
|
|
6
7
|
// If a control is present (likely contains buttons), the row itself must not be clickable
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SettingsRow.js","sourceRoot":"","sources":["../../../src/patterns/settings-row/SettingsRow.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,
|
|
1
|
+
{"version":3,"file":"SettingsRow.js","sourceRoot":"","sources":["../../../src/patterns/settings-row/SettingsRow.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,MAAM,oBAAoB,CAAC;AACzC,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAC7C,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAG7C,MAAM,UAAU,WAAW,CAAC,EAC1B,KAAK,EACL,WAAW,EACX,IAAI,EACJ,OAAO,EACP,OAAO,EACP,QAAQ,GAAG,KAAK,EAChB,MAAM,GACW;IACjB,uCAAuC;IACvC,0FAA0F;IAC1F,MAAM,aAAa,GAAG,OAAO,CAAC,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC;IAEnD,OAAO,CACL,CAAC,IAAI,CACH,OAAO,CACP,OAAO,CAAC,CAAC,OAAO,CAAC,CACjB,WAAW,CAAC,CAAC,WAAW,CAAC,CACzB,QAAQ,CAAC,CAAC,QAAQ,CAAC,CACnB,OAAO,CAAC,CAAC,aAAa,CAAC,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,SAAS,CAAC,CAC7C,MAAM,CAAC,CAAC,MAAM,CAAC,CACf,KAAK,CAAC,CAAC,KAAK,CAAC,CACb,IAAI,CAAC,QAAQ,CAEb;MAAA,CAAC,IAAI,CAAC,CAAC,CAAC,CACN,CAAC,GAAG,CAAC,EAAE,CAAC,IAAI,CACV;UAAA,CAAC,IAAI,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,SAAS,CAClC;YAAA,CAAC,IAAI,CACP;UAAA,EAAE,IAAI,CACR;QAAA,EAAE,GAAG,CAAC,CACP,CAAC,CAAC,CAAC,IAAI,CACV;IAAA,EAAE,IAAI,CAAC,CACR,CAAC;AACJ,CAAC","sourcesContent":["import { Box } from '@ankhorage/surface';\nimport React from 'react';\n\nimport { Card } from '../../components/card';\nimport { Text } from '../../components/text';\nimport type { SettingsRowProps } from './types';\n\nexport function SettingsRow({\n title,\n description,\n meta,\n control,\n onPress,\n disabled = false,\n testID,\n}: SettingsRowProps) {\n // Prevent nested interactive elements:\n // If a control is present (likely contains buttons), the row itself must not be clickable\n const isInteractive = Boolean(onPress) && !control;\n\n return (\n <Card\n compact\n actions={control}\n description={description}\n disabled={disabled}\n onPress={isInteractive ? onPress : undefined}\n testID={testID}\n title={title}\n tone=\"subtle\"\n >\n {meta ? (\n <Box pt=\"xs\">\n <Text tone=\"muted\" variant=\"caption\">\n {meta}\n </Text>\n </Box>\n ) : null}\n </Card>\n );\n}\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PaletteItem.d.ts","sourceRoot":"","sources":["../../../src/patterns/tile-grid/PaletteItem.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;
|
|
1
|
+
{"version":3,"file":"PaletteItem.d.ts","sourceRoot":"","sources":["../../../src/patterns/tile-grid/PaletteItem.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,MAAM,OAAO,CAAC;AAI1B,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAC;AAEhD,wBAAgB,WAAW,CAAC,EAC1B,KAAK,EACL,WAAW,EACX,IAAI,EACJ,KAAK,EACL,QAAQ,EACR,QAAQ,EACR,OAAO,EACP,MAAM,GACP,EAAE,gBAAgB,qBAiClB"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { Box, Heading,
|
|
1
|
+
import { Box, Heading, useTheme } from '@ankhorage/surface';
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { Card } from '../../components/card';
|
|
4
|
+
import { Text } from '../../components/text';
|
|
4
5
|
export function PaletteItem({ title, description, icon, badge, selected, disabled, onPress, testID, }) {
|
|
5
6
|
const { theme } = useTheme();
|
|
6
7
|
return (<Card compact disabled={disabled} onPress={onPress} testID={testID} tone={selected ? 'default' : 'subtle'} style={selected
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PaletteItem.js","sourceRoot":"","sources":["../../../src/patterns/tile-grid/PaletteItem.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"PaletteItem.js","sourceRoot":"","sources":["../../../src/patterns/tile-grid/PaletteItem.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,GAAG,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAC5D,OAAO,KAAK,MAAM,OAAO,CAAC;AAE1B,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAC7C,OAAO,EAAE,IAAI,EAAE,MAAM,uBAAuB,CAAC;AAG7C,MAAM,UAAU,WAAW,CAAC,EAC1B,KAAK,EACL,WAAW,EACX,IAAI,EACJ,KAAK,EACL,QAAQ,EACR,QAAQ,EACR,OAAO,EACP,MAAM,GACW;IACjB,MAAM,EAAE,KAAK,EAAE,GAAG,QAAQ,EAAE,CAAC;IAE7B,OAAO,CACL,CAAC,IAAI,CACH,OAAO,CACP,QAAQ,CAAC,CAAC,QAAQ,CAAC,CACnB,OAAO,CAAC,CAAC,OAAO,CAAC,CACjB,MAAM,CAAC,CAAC,MAAM,CAAC,CACf,IAAI,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,SAAS,CAAC,CAAC,CAAC,QAAQ,CAAC,CACtC,KAAK,CAAC,CACJ,QAAQ;YACN,CAAC,CAAC;gBACE,WAAW,EAAE,KAAK,CAAC,MAAM,CAAC,OAAO;gBACjC,WAAW,EAAE,CAAC;aACf;YACH,CAAC,CAAC,SACN,CAAC,CAED;MAAA,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,EAAE,UAAU,EAAE,QAAQ,EAAE,CAAC,CAC1C;QAAA,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,CAAC,CAAC,oBAAoB,CAAC,EAAE,GAAG,CAAC,CAAC,CAAC,CAAC,IAAI,CACvD;QAAA,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,QAAQ,CAC/B;UAAA,CAAC,KAAK,CACR;QAAA,EAAE,OAAO,CACT;QAAA,CAAC,WAAW,CAAC,CAAC,CAAC,CACb,CAAC,IAAI,CAAC,KAAK,CAAC,QAAQ,CAAC,IAAI,CAAC,OAAO,CAAC,OAAO,CAAC,SAAS,CACjD;YAAA,CAAC,WAAW,CACd;UAAA,EAAE,IAAI,CAAC,CACR,CAAC,CAAC,CAAC,IAAI,CACR;QAAA,CAAC,KAAK,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,EAAE,CAAC,IAAI,CAAC,CAAC,KAAK,CAAC,EAAE,GAAG,CAAC,CAAC,CAAC,CAAC,IAAI,CAC5C;MAAA,EAAE,GAAG,CACP;IAAA,EAAE,IAAI,CAAC,CACR,CAAC;AACJ,CAAC","sourcesContent":["import { Box, Heading, useTheme } from '@ankhorage/surface';\nimport React from 'react';\n\nimport { Card } from '../../components/card';\nimport { Text } from '../../components/text';\nimport type { PaletteItemProps } from './types';\n\nexport function PaletteItem({\n title,\n description,\n icon,\n badge,\n selected,\n disabled,\n onPress,\n testID,\n}: PaletteItemProps) {\n const { theme } = useTheme();\n\n return (\n <Card\n compact\n disabled={disabled}\n onPress={onPress}\n testID={testID}\n tone={selected ? 'default' : 'subtle'}\n style={\n selected\n ? {\n borderColor: theme.colors.primary,\n borderWidth: 2,\n }\n : undefined\n }\n >\n <Box p=\"xs\" style={{ alignItems: 'center' }}>\n {icon ? <Box pb=\"s\">{/* Icon spec here */}</Box> : null}\n <Heading level={5} align=\"center\">\n {title}\n </Heading>\n {description ? (\n <Text align=\"center\" tone=\"muted\" variant=\"caption\">\n {description}\n </Text>\n ) : null}\n {badge ? <Box pt=\"xs\">{badge}</Box> : null}\n </Box>\n </Card>\n );\n}\n"]}
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ankhorage/zora",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "0.6.
|
|
4
|
+
"version": "0.6.2",
|
|
5
5
|
"description": "Opinionated React Native and React Native Web UI kit built on @ankhorage/surface.",
|
|
6
6
|
"homepage": "https://github.com/ankhorage/zora#readme",
|
|
7
7
|
"bugs": {
|
|
@@ -43,7 +43,7 @@
|
|
|
43
43
|
}
|
|
44
44
|
},
|
|
45
45
|
"dependencies": {
|
|
46
|
-
"@ankhorage/surface": "^0.1.
|
|
46
|
+
"@ankhorage/surface": "^0.1.11"
|
|
47
47
|
},
|
|
48
48
|
"files": [
|
|
49
49
|
"dist",
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import { Box, Card as SurfaceCard, Heading, Stack
|
|
1
|
+
import { Box, Card as SurfaceCard, Heading, Stack } from '@ankhorage/surface';
|
|
2
2
|
import React from 'react';
|
|
3
3
|
|
|
4
4
|
import { resolveCardVariant } from '../../internal/recipes';
|
|
5
|
+
import { Text } from '../text';
|
|
5
6
|
import type { CardProps } from './types';
|
|
6
7
|
|
|
7
8
|
export function Card({
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import { Checkbox, Stack
|
|
1
|
+
import { Checkbox, Stack } from '@ankhorage/surface';
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { View } from 'react-native';
|
|
4
4
|
|
|
5
|
+
import { Text } from '../text';
|
|
5
6
|
import type { CheckboxGroupOption, CheckboxGroupProps } from './types';
|
|
6
7
|
|
|
7
8
|
export function CheckboxGroup<TValue extends string>({
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { Box, Drawer as SurfaceDrawer, Heading, Stack
|
|
1
|
+
import { Box, Drawer as SurfaceDrawer, Heading, Stack } from '@ankhorage/surface';
|
|
2
2
|
import React, { useCallback, useEffect, useRef } from 'react';
|
|
3
3
|
|
|
4
|
+
import { Text } from '../text';
|
|
4
5
|
import type { DrawerProps } from './types';
|
|
5
6
|
|
|
6
7
|
function useStableCallback(callback: (() => void) | undefined): (() => void) | undefined {
|