@ezpg/app-ui 0.22.0 → 0.23.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/lib/module/adjust/axis-adjust.js +1 -1
- package/lib/module/adjust/axis-adjust.js.map +1 -1
- package/lib/module/adjust/axis-dial.js +2 -2
- package/lib/module/adjust/axis-dial.js.map +1 -1
- package/lib/module/adjust/axis-tabs.js +1 -1
- package/lib/module/adjust/axis-tabs.js.map +1 -1
- package/lib/module/adjust/dial-strip.js +6 -4
- package/lib/module/adjust/dial-strip.js.map +1 -1
- package/lib/module/adjust/store-sample.js +1 -1
- package/lib/module/blocks/chat-message/chat-message.js +1 -0
- package/lib/module/blocks/chat-message/chat-message.js.map +1 -1
- package/lib/module/blocks/choice-art/choice-art.js +2 -0
- package/lib/module/blocks/choice-art/choice-art.js.map +1 -1
- package/lib/module/blocks/color-tune/store-sample.js +13 -6
- package/lib/module/blocks/color-tune/store-sample.js.map +1 -1
- package/lib/module/blocks/color-tune/swatch-card.js +1 -1
- package/lib/module/blocks/color-tune/swatch-card.js.map +1 -1
- package/lib/module/blocks/detail-editor/compare-slider.js +1 -0
- package/lib/module/blocks/detail-editor/compare-slider.js.map +1 -1
- package/lib/module/blocks/detail-editor/detail-canvas.js +3 -0
- package/lib/module/blocks/detail-editor/detail-canvas.js.map +1 -1
- package/lib/module/blocks/detail-editor/layout-picker.js +4 -1
- package/lib/module/blocks/detail-editor/layout-picker.js.map +1 -1
- package/lib/module/blocks/detail-studio/action-chips.js +1 -0
- package/lib/module/blocks/detail-studio/action-chips.js.map +1 -1
- package/lib/module/blocks/detail-studio/adjust-tiles.js +1 -0
- package/lib/module/blocks/detail-studio/adjust-tiles.js.map +1 -1
- package/lib/module/blocks/detail-studio/image-prompt.js +1 -0
- package/lib/module/blocks/detail-studio/image-prompt.js.map +1 -1
- package/lib/module/blocks/detail-studio/section-kind-grid.js +2 -0
- package/lib/module/blocks/detail-studio/section-kind-grid.js.map +1 -1
- package/lib/module/blocks/detail-studio/text-format-panel.js +4 -0
- package/lib/module/blocks/detail-studio/text-format-panel.js.map +1 -1
- package/lib/module/blocks/draft-box/draft-box.js +3 -0
- package/lib/module/blocks/draft-box/draft-box.js.map +1 -1
- package/lib/module/blocks/oauth-buttons/oauth-buttons.js +1 -0
- package/lib/module/blocks/oauth-buttons/oauth-buttons.js.map +1 -1
- package/lib/module/blocks/order-block/order-block.js +19 -5
- package/lib/module/blocks/order-block/order-block.js.map +1 -1
- package/lib/module/blocks/product-tile/product-tile.js +4 -1
- package/lib/module/blocks/product-tile/product-tile.js.map +1 -1
- package/lib/module/blocks/question-accordion/question-accordion.js +1 -2
- package/lib/module/blocks/question-accordion/question-accordion.js.map +1 -1
- package/lib/module/blocks/question-pager/question-pager.js +2 -1
- package/lib/module/blocks/question-pager/question-pager.js.map +1 -1
- package/lib/module/blocks/review-card/review-card.js +4 -0
- package/lib/module/blocks/review-card/review-card.js.map +1 -1
- package/lib/module/blocks/send-bar/send-bar.js +1 -0
- package/lib/module/blocks/send-bar/send-bar.js.map +1 -1
- package/lib/module/blocks/stage-bar/stage-bar.js +3 -2
- package/lib/module/blocks/stage-bar/stage-bar.js.map +1 -1
- package/lib/module/blocks/stat-card/stat-card.js +4 -1
- package/lib/module/blocks/stat-card/stat-card.js.map +1 -1
- package/lib/module/blocks/step-screen/step-screen.js +5 -2
- package/lib/module/blocks/step-screen/step-screen.js.map +1 -1
- package/lib/module/blocks/store-top/store-top.js +8 -3
- package/lib/module/blocks/store-top/store-top.js.map +1 -1
- package/lib/module/blocks/summary-cards/summary-cards.js +10 -3
- package/lib/module/blocks/summary-cards/summary-cards.js.map +1 -1
- package/lib/module/blocks/task-tiles/task-tiles.js +3 -2
- package/lib/module/blocks/task-tiles/task-tiles.js.map +1 -1
- package/lib/module/components/amount-summary/amount-summary.js +7 -1
- package/lib/module/components/amount-summary/amount-summary.js.map +1 -1
- package/lib/module/components/button/button.js +6 -0
- package/lib/module/components/button/button.js.map +1 -1
- package/lib/module/components/calendar/calendar.js +7 -4
- package/lib/module/components/calendar/calendar.js.map +1 -1
- package/lib/module/components/chip/chip.js +2 -2
- package/lib/module/components/chip/chip.js.map +1 -1
- package/lib/module/components/circle-grid/circle-grid.js +1 -0
- package/lib/module/components/circle-grid/circle-grid.js.map +1 -1
- package/lib/module/components/credit/credit.js +2 -2
- package/lib/module/components/credit/credit.js.map +1 -1
- package/lib/module/components/dialog/dialog.js +2 -0
- package/lib/module/components/dialog/dialog.js.map +1 -1
- package/lib/module/components/empty-state/empty-state.js +1 -0
- package/lib/module/components/empty-state/empty-state.js.map +1 -1
- package/lib/module/components/fact-list/fact-list.js +1 -0
- package/lib/module/components/fact-list/fact-list.js.map +1 -1
- package/lib/module/components/field/field.js +4 -0
- package/lib/module/components/field/field.js.map +1 -1
- package/lib/module/components/filter-tabs/filter-tabs.js +2 -1
- package/lib/module/components/filter-tabs/filter-tabs.js.map +1 -1
- package/lib/module/components/list-row/list-row.js +23 -6
- package/lib/module/components/list-row/list-row.js.map +1 -1
- package/lib/module/components/page-header/page-header.js +1 -0
- package/lib/module/components/page-header/page-header.js.map +1 -1
- package/lib/module/components/pill/pill.js +1 -0
- package/lib/module/components/pill/pill.js.map +1 -1
- package/lib/module/components/segmented-control/segmented-control.js +2 -0
- package/lib/module/components/segmented-control/segmented-control.js.map +1 -1
- package/lib/module/components/segmented-tabs/segmented-tabs.js +3 -2
- package/lib/module/components/segmented-tabs/segmented-tabs.js.map +1 -1
- package/lib/module/components/status-steps/status-steps.js +2 -0
- package/lib/module/components/status-steps/status-steps.js.map +1 -1
- package/lib/module/components/text/figures.js +82 -0
- package/lib/module/components/text/figures.js.map +1 -0
- package/lib/module/components/text/index.js +1 -0
- package/lib/module/components/text/index.js.map +1 -1
- package/lib/module/components/text/metrics.js +5 -0
- package/lib/module/components/text/metrics.js.map +1 -0
- package/lib/module/components/text/text.js +31 -2
- package/lib/module/components/text/text.js.map +1 -1
- package/lib/module/components/tile-grid/tile-grid.js +3 -2
- package/lib/module/components/tile-grid/tile-grid.js.map +1 -1
- package/lib/module/components/toast/toast.js +4 -1
- package/lib/module/components/toast/toast.js.map +1 -1
- package/lib/module/components/value-rows/value-rows.js +8 -1
- package/lib/module/components/value-rows/value-rows.js.map +1 -1
- package/lib/module/internal/field-label.js +2 -0
- package/lib/module/internal/field-label.js.map +1 -1
- package/lib/module/internal/roll-text.js +10 -2
- package/lib/module/internal/roll-text.js.map +1 -1
- package/lib/module/internal/sample-tiles.js +2 -0
- package/lib/module/internal/sample-tiles.js.map +1 -1
- package/lib/module/sortable/section-board.js +2 -0
- package/lib/module/sortable/section-board.js.map +1 -1
- package/lib/module/templates/design-pick-template.js +1 -0
- package/lib/module/templates/design-pick-template.js.map +1 -1
- package/lib/module/templates/preview-edit-template.js +3 -0
- package/lib/module/templates/preview-edit-template.js.map +1 -1
- package/lib/module/templates/scroll-templates.js +12 -2
- package/lib/module/templates/scroll-templates.js.map +1 -1
- package/lib/module/templates/sheet-form-template.js +4 -0
- package/lib/module/templates/sheet-form-template.js.map +1 -1
- package/lib/module/theme/base.js +16 -9
- package/lib/module/theme/base.js.map +1 -1
- package/lib/module/theme/create-theme.js +6 -2
- package/lib/module/theme/create-theme.js.map +1 -1
- package/lib/module/theme/tokens.js +23 -2
- package/lib/module/theme/tokens.js.map +1 -1
- package/lib/typescript/src/adjust/dial-strip.d.ts.map +1 -1
- package/lib/typescript/src/blocks/chat-message/chat-message.d.ts.map +1 -1
- package/lib/typescript/src/blocks/choice-art/choice-art.d.ts.map +1 -1
- package/lib/typescript/src/blocks/color-tune/store-sample.d.ts.map +1 -1
- package/lib/typescript/src/blocks/detail-editor/compare-slider.d.ts.map +1 -1
- package/lib/typescript/src/blocks/detail-editor/detail-canvas.d.ts.map +1 -1
- package/lib/typescript/src/blocks/detail-editor/layout-picker.d.ts.map +1 -1
- package/lib/typescript/src/blocks/detail-studio/action-chips.d.ts.map +1 -1
- package/lib/typescript/src/blocks/detail-studio/adjust-tiles.d.ts.map +1 -1
- package/lib/typescript/src/blocks/detail-studio/image-prompt.d.ts.map +1 -1
- package/lib/typescript/src/blocks/detail-studio/section-kind-grid.d.ts.map +1 -1
- package/lib/typescript/src/blocks/detail-studio/text-format-panel.d.ts.map +1 -1
- package/lib/typescript/src/blocks/draft-box/draft-box.d.ts.map +1 -1
- package/lib/typescript/src/blocks/oauth-buttons/oauth-buttons.d.ts.map +1 -1
- package/lib/typescript/src/blocks/order-block/order-block.d.ts.map +1 -1
- package/lib/typescript/src/blocks/product-tile/product-tile.d.ts.map +1 -1
- package/lib/typescript/src/blocks/question-accordion/question-accordion.d.ts.map +1 -1
- package/lib/typescript/src/blocks/question-pager/question-pager.d.ts.map +1 -1
- package/lib/typescript/src/blocks/review-card/review-card.d.ts.map +1 -1
- package/lib/typescript/src/blocks/send-bar/send-bar.d.ts.map +1 -1
- package/lib/typescript/src/blocks/stage-bar/stage-bar.d.ts.map +1 -1
- package/lib/typescript/src/blocks/stat-card/stat-card.d.ts.map +1 -1
- package/lib/typescript/src/blocks/step-screen/step-screen.d.ts.map +1 -1
- package/lib/typescript/src/blocks/store-top/store-top.d.ts.map +1 -1
- package/lib/typescript/src/blocks/summary-cards/summary-cards.d.ts.map +1 -1
- package/lib/typescript/src/blocks/task-tiles/task-tiles.d.ts.map +1 -1
- package/lib/typescript/src/components/amount-summary/amount-summary.d.ts.map +1 -1
- package/lib/typescript/src/components/button/button.d.ts.map +1 -1
- package/lib/typescript/src/components/calendar/calendar.d.ts.map +1 -1
- package/lib/typescript/src/components/chip/chip.d.ts.map +1 -1
- package/lib/typescript/src/components/circle-grid/circle-grid.d.ts.map +1 -1
- package/lib/typescript/src/components/dialog/dialog.d.ts.map +1 -1
- package/lib/typescript/src/components/empty-state/empty-state.d.ts.map +1 -1
- package/lib/typescript/src/components/fact-list/fact-list.d.ts.map +1 -1
- package/lib/typescript/src/components/field/field.d.ts.map +1 -1
- package/lib/typescript/src/components/filter-tabs/filter-tabs.d.ts.map +1 -1
- package/lib/typescript/src/components/list-row/list-row.d.ts +3 -1
- package/lib/typescript/src/components/list-row/list-row.d.ts.map +1 -1
- package/lib/typescript/src/components/page-header/page-header.d.ts.map +1 -1
- package/lib/typescript/src/components/pill/pill.d.ts.map +1 -1
- package/lib/typescript/src/components/segmented-control/segmented-control.d.ts.map +1 -1
- package/lib/typescript/src/components/segmented-tabs/segmented-tabs.d.ts.map +1 -1
- package/lib/typescript/src/components/status-steps/status-steps.d.ts.map +1 -1
- package/lib/typescript/src/components/text/figures.d.ts +12 -0
- package/lib/typescript/src/components/text/figures.d.ts.map +1 -0
- package/lib/typescript/src/components/text/index.d.ts +1 -0
- package/lib/typescript/src/components/text/index.d.ts.map +1 -1
- package/lib/typescript/src/components/text/metrics.d.ts +6 -0
- package/lib/typescript/src/components/text/metrics.d.ts.map +1 -0
- package/lib/typescript/src/components/text/text.d.ts +2 -2
- package/lib/typescript/src/components/text/text.d.ts.map +1 -1
- package/lib/typescript/src/components/tile-grid/tile-grid.d.ts.map +1 -1
- package/lib/typescript/src/components/toast/toast.d.ts.map +1 -1
- package/lib/typescript/src/components/value-rows/value-rows.d.ts.map +1 -1
- package/lib/typescript/src/internal/field-label.d.ts.map +1 -1
- package/lib/typescript/src/internal/roll-text.d.ts +3 -2
- package/lib/typescript/src/internal/roll-text.d.ts.map +1 -1
- package/lib/typescript/src/internal/sample-tiles.d.ts +2 -0
- package/lib/typescript/src/internal/sample-tiles.d.ts.map +1 -1
- package/lib/typescript/src/sortable/section-board.d.ts.map +1 -1
- package/lib/typescript/src/templates/design-pick-template.d.ts.map +1 -1
- package/lib/typescript/src/templates/preview-edit-template.d.ts.map +1 -1
- package/lib/typescript/src/templates/scroll-templates.d.ts.map +1 -1
- package/lib/typescript/src/templates/sheet-form-template.d.ts.map +1 -1
- package/lib/typescript/src/theme/base.d.ts +9 -2
- package/lib/typescript/src/theme/base.d.ts.map +1 -1
- package/lib/typescript/src/theme/create-theme.d.ts.map +1 -1
- package/lib/typescript/src/theme/tokens.d.ts +3 -1
- package/lib/typescript/src/theme/tokens.d.ts.map +1 -1
- package/lib/typescript/src/types/index.d.ts +12 -0
- package/lib/typescript/src/types/index.d.ts.map +1 -1
- package/package.json +1 -1
- package/src/adjust/axis-adjust.tsx +1 -1
- package/src/adjust/axis-dial.tsx +2 -2
- package/src/adjust/axis-tabs.tsx +1 -1
- package/src/adjust/dial-strip.tsx +5 -3
- package/src/adjust/store-sample.tsx +1 -1
- package/src/blocks/chat-message/chat-message.tsx +1 -0
- package/src/blocks/choice-art/choice-art.tsx +2 -0
- package/src/blocks/color-tune/store-sample.tsx +11 -6
- package/src/blocks/color-tune/swatch-card.tsx +1 -1
- package/src/blocks/detail-editor/compare-slider.tsx +1 -0
- package/src/blocks/detail-editor/detail-canvas.tsx +3 -0
- package/src/blocks/detail-editor/layout-picker.tsx +3 -0
- package/src/blocks/detail-studio/action-chips.tsx +1 -0
- package/src/blocks/detail-studio/adjust-tiles.tsx +1 -0
- package/src/blocks/detail-studio/image-prompt.tsx +1 -0
- package/src/blocks/detail-studio/section-kind-grid.tsx +2 -0
- package/src/blocks/detail-studio/text-format-panel.tsx +4 -0
- package/src/blocks/draft-box/draft-box.tsx +3 -0
- package/src/blocks/oauth-buttons/oauth-buttons.tsx +1 -0
- package/src/blocks/order-block/order-block.tsx +20 -4
- package/src/blocks/product-tile/product-tile.tsx +4 -1
- package/src/blocks/question-accordion/question-accordion.tsx +0 -1
- package/src/blocks/question-pager/question-pager.tsx +2 -1
- package/src/blocks/review-card/review-card.tsx +4 -0
- package/src/blocks/send-bar/send-bar.tsx +1 -0
- package/src/blocks/stage-bar/stage-bar.tsx +3 -2
- package/src/blocks/stat-card/stat-card.tsx +2 -1
- package/src/blocks/step-screen/step-screen.tsx +5 -2
- package/src/blocks/store-top/store-top.tsx +7 -2
- package/src/blocks/summary-cards/summary-cards.tsx +4 -3
- package/src/blocks/task-tiles/task-tiles.tsx +2 -1
- package/src/components/amount-summary/amount-summary.tsx +9 -3
- package/src/components/button/button.tsx +6 -0
- package/src/components/calendar/calendar.tsx +5 -2
- package/src/components/chip/chip.tsx +2 -1
- package/src/components/circle-grid/circle-grid.tsx +5 -1
- package/src/components/credit/credit.tsx +2 -2
- package/src/components/dialog/dialog.tsx +2 -0
- package/src/components/empty-state/empty-state.tsx +1 -0
- package/src/components/fact-list/fact-list.tsx +1 -0
- package/src/components/field/field.tsx +4 -0
- package/src/components/filter-tabs/filter-tabs.tsx +2 -1
- package/src/components/list-row/list-row.tsx +40 -5
- package/src/components/page-header/page-header.tsx +1 -0
- package/src/components/pill/pill.tsx +1 -0
- package/src/components/segmented-control/segmented-control.tsx +2 -0
- package/src/components/segmented-tabs/segmented-tabs.tsx +2 -1
- package/src/components/status-steps/status-steps.tsx +2 -0
- package/src/components/text/figures.tsx +92 -0
- package/src/components/text/index.ts +7 -0
- package/src/components/text/metrics.ts +5 -0
- package/src/components/text/text.tsx +60 -16
- package/src/components/tile-grid/tile-grid.tsx +3 -2
- package/src/components/toast/toast.tsx +7 -1
- package/src/components/value-rows/value-rows.tsx +9 -1
- package/src/internal/field-label.tsx +2 -0
- package/src/internal/roll-text.tsx +12 -2
- package/src/internal/sample-tiles.tsx +2 -0
- package/src/sortable/section-board.tsx +2 -0
- package/src/templates/design-pick-template.tsx +1 -0
- package/src/templates/preview-edit-template.tsx +3 -0
- package/src/templates/scroll-templates.tsx +11 -2
- package/src/templates/sheet-form-template.tsx +4 -0
- package/src/theme/base.ts +9 -2
- package/src/theme/create-theme.ts +9 -2
- package/src/theme/tokens.ts +37 -3
- package/src/types/index.ts +13 -0
|
@@ -104,11 +104,13 @@ const useStyles = makeStyles((t) => ({
|
|
|
104
104
|
paddingVertical: 0,
|
|
105
105
|
fontFamily: t.fontFamily,
|
|
106
106
|
fontSize: t.typography.bodyLg.fontSize,
|
|
107
|
+
letterSpacing: t.typography.bodyLg.letterSpacing,
|
|
107
108
|
color: t.colors.foreground,
|
|
108
109
|
},
|
|
109
110
|
error: {
|
|
110
111
|
fontFamily: t.fontFamily,
|
|
111
112
|
fontSize: t.typography.label.fontSize,
|
|
113
|
+
letterSpacing: t.typography.label.letterSpacing,
|
|
112
114
|
lineHeight: t.typography.label.lineHeight,
|
|
113
115
|
paddingLeft: t.space[1],
|
|
114
116
|
color: t.colors.danger,
|
|
@@ -124,6 +126,7 @@ const useStyles = makeStyles((t) => ({
|
|
|
124
126
|
hint: {
|
|
125
127
|
fontFamily: t.fontFamily,
|
|
126
128
|
fontSize: t.typography.label.fontSize,
|
|
129
|
+
letterSpacing: t.typography.label.letterSpacing,
|
|
127
130
|
lineHeight: t.typography.label.lineHeight,
|
|
128
131
|
paddingLeft: t.space[1],
|
|
129
132
|
color: t.colors.mutedForeground,
|
|
@@ -131,6 +134,7 @@ const useStyles = makeStyles((t) => ({
|
|
|
131
134
|
warning: {
|
|
132
135
|
fontFamily: t.fontFamily,
|
|
133
136
|
fontSize: t.typography.label.fontSize,
|
|
137
|
+
letterSpacing: t.typography.label.letterSpacing,
|
|
134
138
|
lineHeight: t.typography.label.lineHeight,
|
|
135
139
|
paddingLeft: t.space[1],
|
|
136
140
|
color: t.colors.foreground,
|
|
@@ -51,11 +51,12 @@ const useStyles = makeStyles((t) => ({
|
|
|
51
51
|
label: {
|
|
52
52
|
fontFamily: t.fontFamily,
|
|
53
53
|
fontSize: t.typography.label.fontSize,
|
|
54
|
+
letterSpacing: t.typography.label.letterSpacing,
|
|
54
55
|
lineHeight: t.typography.label.lineHeight,
|
|
55
56
|
fontWeight: '500',
|
|
56
57
|
color: t.colors.faint,
|
|
57
58
|
},
|
|
58
|
-
strong: { fontWeight: '
|
|
59
|
+
strong: { fontWeight: '600' },
|
|
59
60
|
line: {
|
|
60
61
|
position: 'absolute',
|
|
61
62
|
left: 0,
|
|
@@ -14,6 +14,7 @@ import { makeStyles } from '../../utils/styles';
|
|
|
14
14
|
import { Photo } from '../photo/photo';
|
|
15
15
|
import { FlushRowContext } from '../../internal/flush-row';
|
|
16
16
|
import { haptic } from '../../internal/haptics';
|
|
17
|
+
import { Figures, Won, isFigureText, type FiguresScope } from '../text/figures';
|
|
17
18
|
|
|
18
19
|
export type ListRowTone = 'muted' | 'warning' | 'danger';
|
|
19
20
|
|
|
@@ -36,6 +37,7 @@ export type ListRowProps = Omit<
|
|
|
36
37
|
strong?: boolean;
|
|
37
38
|
titleSize?: 'md' | 'lg';
|
|
38
39
|
titleLines?: number;
|
|
40
|
+
titleFigures?: FiguresScope;
|
|
39
41
|
selection?: 'check' | 'radio';
|
|
40
42
|
selected?: boolean;
|
|
41
43
|
};
|
|
@@ -65,7 +67,6 @@ const useStyles = makeStyles((t) => ({
|
|
|
65
67
|
...t.typography.bodyLg,
|
|
66
68
|
fontFamily: t.fontFamily,
|
|
67
69
|
color: t.colors.foreground,
|
|
68
|
-
fontVariant: ['tabular-nums'],
|
|
69
70
|
},
|
|
70
71
|
meta: {
|
|
71
72
|
...t.typography.label,
|
|
@@ -107,6 +108,7 @@ const useStyles = makeStyles((t) => ({
|
|
|
107
108
|
checkOn: { borderColor: t.colors.primary, backgroundColor: t.colors.primary },
|
|
108
109
|
radioOn: { borderWidth: 6, borderColor: t.colors.primary },
|
|
109
110
|
strong: { color: t.colors.title, fontWeight: '600' },
|
|
111
|
+
strongFigure: { fontWeight: '500' },
|
|
110
112
|
titleLg: {
|
|
111
113
|
...t.typography.bodyLg,
|
|
112
114
|
color: t.colors.title,
|
|
@@ -130,6 +132,7 @@ export function ListRow({
|
|
|
130
132
|
strong = false,
|
|
131
133
|
titleSize = 'md',
|
|
132
134
|
titleLines = 1,
|
|
135
|
+
titleFigures,
|
|
133
136
|
selection,
|
|
134
137
|
selected = false,
|
|
135
138
|
onPress,
|
|
@@ -194,9 +197,31 @@ export function ListRow({
|
|
|
194
197
|
<Text
|
|
195
198
|
numberOfLines={titleLines}
|
|
196
199
|
maxFontSizeMultiplier={t.maxFontScale}
|
|
197
|
-
style={[
|
|
200
|
+
style={[
|
|
201
|
+
s.title,
|
|
202
|
+
strong && s.strong,
|
|
203
|
+
titleSize === 'lg' && s.titleLg,
|
|
204
|
+
(strong || titleSize === 'lg') &&
|
|
205
|
+
isFigureText(title) &&
|
|
206
|
+
s.strongFigure,
|
|
207
|
+
]}
|
|
198
208
|
>
|
|
199
|
-
{
|
|
209
|
+
{titleFigures ? (
|
|
210
|
+
<Figures
|
|
211
|
+
size={t.typography.bodyLg.fontSize}
|
|
212
|
+
tracking={t.typography.bodyLg.letterSpacing}
|
|
213
|
+
scope={titleFigures}
|
|
214
|
+
>
|
|
215
|
+
{title}
|
|
216
|
+
</Figures>
|
|
217
|
+
) : (
|
|
218
|
+
<Won
|
|
219
|
+
size={t.typography.bodyLg.fontSize}
|
|
220
|
+
tracking={t.typography.bodyLg.letterSpacing}
|
|
221
|
+
>
|
|
222
|
+
{title}
|
|
223
|
+
</Won>
|
|
224
|
+
)}
|
|
200
225
|
</Text>
|
|
201
226
|
{description ? (
|
|
202
227
|
<Text
|
|
@@ -218,9 +243,19 @@ export function ListRow({
|
|
|
218
243
|
{value ? (
|
|
219
244
|
<Text
|
|
220
245
|
maxFontSizeMultiplier={t.maxFontScale}
|
|
221
|
-
style={[
|
|
246
|
+
style={[
|
|
247
|
+
s.value,
|
|
248
|
+
strong && s.strong,
|
|
249
|
+
strong && s.money,
|
|
250
|
+
strong && isFigureText(value) && s.strongFigure,
|
|
251
|
+
]}
|
|
222
252
|
>
|
|
223
|
-
|
|
253
|
+
<Won
|
|
254
|
+
size={t.typography.bodyLg.fontSize}
|
|
255
|
+
tracking={t.typography.bodyLg.letterSpacing}
|
|
256
|
+
>
|
|
257
|
+
{value}
|
|
258
|
+
</Won>
|
|
224
259
|
</Text>
|
|
225
260
|
) : null}
|
|
226
261
|
{trailing ? renderIcon(trailing, icon) : null}
|
|
@@ -33,6 +33,7 @@ const useStyles = makeStyles((t) => ({
|
|
|
33
33
|
},
|
|
34
34
|
title: {
|
|
35
35
|
fontSize: t.typography.screenTitle.fontSize,
|
|
36
|
+
fontFamily: t.fontFamily,
|
|
36
37
|
lineHeight: t.typography.screenTitle.lineHeight,
|
|
37
38
|
fontWeight: t.typography.screenTitle.fontWeight,
|
|
38
39
|
letterSpacing: t.typography.screenTitle.letterSpacing,
|
|
@@ -39,6 +39,7 @@ const useStyles = makeStyles((t) => ({
|
|
|
39
39
|
label: {
|
|
40
40
|
fontFamily: t.fontFamily,
|
|
41
41
|
fontSize: t.typography.caption.fontSize,
|
|
42
|
+
letterSpacing: t.typography.caption.letterSpacing,
|
|
42
43
|
lineHeight: t.typography.caption.lineHeight,
|
|
43
44
|
fontWeight: '500',
|
|
44
45
|
color: t.colors.mutedForeground,
|
|
@@ -35,6 +35,8 @@ const useStyles = makeStyles((t) => ({
|
|
|
35
35
|
on: { backgroundColor: t.colors.surface, boxShadow: t.shadow.sm },
|
|
36
36
|
label: {
|
|
37
37
|
fontSize: t.typography.eyebrow.fontSize,
|
|
38
|
+
fontFamily: t.fontFamily,
|
|
39
|
+
letterSpacing: t.typography.eyebrow.letterSpacing,
|
|
38
40
|
lineHeight: t.typography.eyebrow.lineHeight,
|
|
39
41
|
color: t.colors.mutedForeground,
|
|
40
42
|
},
|
|
@@ -53,15 +53,16 @@ const useStyles = makeStyles((t) => ({
|
|
|
53
53
|
label: {
|
|
54
54
|
fontFamily: t.fontFamily,
|
|
55
55
|
fontSize: t.typography.body.fontSize,
|
|
56
|
+
letterSpacing: t.typography.body.letterSpacing,
|
|
56
57
|
lineHeight: t.typography.body.lineHeight,
|
|
57
58
|
color: t.colors.mutedForeground,
|
|
58
59
|
},
|
|
59
60
|
count: {
|
|
60
61
|
fontFamily: t.fontFamily,
|
|
61
62
|
fontSize: t.typography.eyebrow.fontSize,
|
|
63
|
+
letterSpacing: t.typography.eyebrow.letterSpacing,
|
|
62
64
|
lineHeight: t.typography.eyebrow.lineHeight,
|
|
63
65
|
color: t.colors.mutedForeground,
|
|
64
|
-
fontVariant: ['tabular-nums'],
|
|
65
66
|
},
|
|
66
67
|
strong: { fontWeight: '600' },
|
|
67
68
|
bar: {
|
|
@@ -120,6 +120,8 @@ const useStyles = makeStyles((t) => ({
|
|
|
120
120
|
due: { color: t.colors.warningText },
|
|
121
121
|
small: {
|
|
122
122
|
fontSize: t.typography.eyebrow.fontSize,
|
|
123
|
+
fontFamily: t.fontFamily,
|
|
124
|
+
letterSpacing: t.typography.eyebrow.letterSpacing,
|
|
123
125
|
lineHeight: t.typography.eyebrow.lineHeight,
|
|
124
126
|
},
|
|
125
127
|
}));
|
|
@@ -0,0 +1,92 @@
|
|
|
1
|
+
import { useContext } from 'react';
|
|
2
|
+
import { Text as RNText } from 'react-native';
|
|
3
|
+
import { useTheme } from '../../theme/theme-provider';
|
|
4
|
+
import { TextMetricsContext } from './metrics';
|
|
5
|
+
|
|
6
|
+
const MONEY = /^([+\-−]?\d[\d,]*(?:\.\d+)?)(만원|원)$/;
|
|
7
|
+
const FIGURE =
|
|
8
|
+
/^[₩$]?[+\-−]?\d[\d,.:\-–~/\s]*(원|%|개|명|박|인|점|건|회|일|분|시간|만원|P)?$/;
|
|
9
|
+
const RUN = /(\d[\d,.:]*)/;
|
|
10
|
+
const MORE = /^(.*\s외\s)(\d[\d,]*)(건|개)$/;
|
|
11
|
+
|
|
12
|
+
export type FigureProps = {
|
|
13
|
+
children: string;
|
|
14
|
+
size?: number;
|
|
15
|
+
tracking?: number;
|
|
16
|
+
};
|
|
17
|
+
|
|
18
|
+
export type FiguresScope = 'all' | 'more';
|
|
19
|
+
|
|
20
|
+
function px(value: number) {
|
|
21
|
+
return Math.round(value * 100) / 100;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
function useMetrics(size?: number, tracking?: number) {
|
|
25
|
+
const t = useTheme();
|
|
26
|
+
const context = useContext(TextMetricsContext);
|
|
27
|
+
return {
|
|
28
|
+
t,
|
|
29
|
+
size: size ?? context?.size ?? t.typography.body.fontSize,
|
|
30
|
+
tracking: tracking ?? context?.tracking ?? 0,
|
|
31
|
+
};
|
|
32
|
+
}
|
|
33
|
+
|
|
34
|
+
export function isFigureText(text: string | undefined | null): boolean {
|
|
35
|
+
return !!text && FIGURE.test(text.trim());
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
export function Won({ children, size, tracking }: FigureProps) {
|
|
39
|
+
const m = useMetrics(size, tracking);
|
|
40
|
+
const match = MONEY.exec(children.trim());
|
|
41
|
+
if (!match) return <>{children}</>;
|
|
42
|
+
const [, amount = '', unit = ''] = match;
|
|
43
|
+
const f = m.t.figure;
|
|
44
|
+
return (
|
|
45
|
+
<>
|
|
46
|
+
{amount.slice(0, -1)}
|
|
47
|
+
<RNText style={{ letterSpacing: px(m.tracking + f.unitGap * m.size) }}>
|
|
48
|
+
{amount.slice(-1)}
|
|
49
|
+
</RNText>
|
|
50
|
+
<RNText
|
|
51
|
+
style={{
|
|
52
|
+
fontSize: px(m.size * f.unitScale),
|
|
53
|
+
fontWeight: f.unitWeight,
|
|
54
|
+
letterSpacing: f.unitTracking,
|
|
55
|
+
}}
|
|
56
|
+
>
|
|
57
|
+
{unit}
|
|
58
|
+
</RNText>
|
|
59
|
+
</>
|
|
60
|
+
);
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
export function Figures({
|
|
64
|
+
children,
|
|
65
|
+
size,
|
|
66
|
+
tracking,
|
|
67
|
+
scope = 'all',
|
|
68
|
+
}: FigureProps & { scope?: FiguresScope }) {
|
|
69
|
+
const m = useMetrics(size, tracking);
|
|
70
|
+
const f = m.t.figure;
|
|
71
|
+
if (m.size < f.emphasisMinSize) return <>{children}</>;
|
|
72
|
+
const style = {
|
|
73
|
+
fontWeight: f.emphasisWeight,
|
|
74
|
+
letterSpacing: px(f.emphasisTracking * m.size),
|
|
75
|
+
};
|
|
76
|
+
const more = scope === 'more' ? MORE.exec(children) : null;
|
|
77
|
+
if (scope === 'more' && !more) return <>{children}</>;
|
|
78
|
+
const parts = more ? more.slice(1) : children.split(RUN);
|
|
79
|
+
return (
|
|
80
|
+
<>
|
|
81
|
+
{parts.map((part, i) =>
|
|
82
|
+
i % 2 === 1 ? (
|
|
83
|
+
<RNText key={i} style={style}>
|
|
84
|
+
{part}
|
|
85
|
+
</RNText>
|
|
86
|
+
) : (
|
|
87
|
+
part
|
|
88
|
+
)
|
|
89
|
+
)}
|
|
90
|
+
</>
|
|
91
|
+
);
|
|
92
|
+
}
|
|
@@ -1,8 +1,21 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
1
|
+
import {
|
|
2
|
+
isValidElement,
|
|
3
|
+
useMemo,
|
|
4
|
+
type ComponentRef,
|
|
5
|
+
type ReactNode,
|
|
6
|
+
type Ref,
|
|
7
|
+
} from 'react';
|
|
8
|
+
import {
|
|
9
|
+
StyleSheet,
|
|
10
|
+
Text as RNText,
|
|
11
|
+
type TextProps as RNTextProps,
|
|
12
|
+
type TextStyle,
|
|
13
|
+
} from 'react-native';
|
|
3
14
|
import type { TypographyVariant } from '../../types';
|
|
4
15
|
import { useTheme } from '../../theme/theme-provider';
|
|
5
16
|
import { makeStyles } from '../../utils/styles';
|
|
17
|
+
import { TextMetricsContext } from './metrics';
|
|
18
|
+
import { Won, isFigureText } from './figures';
|
|
6
19
|
|
|
7
20
|
export type TextTone =
|
|
8
21
|
'default' | 'muted' | 'primary' | 'point' | 'warning' | 'danger' | 'success';
|
|
@@ -36,34 +49,65 @@ const useStyles = makeStyles((t) => ({
|
|
|
36
49
|
regular: { fontWeight: '400' },
|
|
37
50
|
medium: { fontWeight: '500' },
|
|
38
51
|
semibold: { fontWeight: '600' },
|
|
52
|
+
figure: { fontWeight: t.figure.weight },
|
|
39
53
|
}));
|
|
40
54
|
|
|
55
|
+
const HEAVY = new Set(['600', '700', '800', '900', 'bold', 600, 700, 800, 900]);
|
|
56
|
+
|
|
57
|
+
function figureOf(children: ReactNode): string | null {
|
|
58
|
+
if (typeof children === 'string') return children;
|
|
59
|
+
if (typeof children === 'number') return String(children);
|
|
60
|
+
if (isValidElement<{ children?: unknown }>(children) && children.type === Won)
|
|
61
|
+
return typeof children.props.children === 'string'
|
|
62
|
+
? children.props.children
|
|
63
|
+
: null;
|
|
64
|
+
return null;
|
|
65
|
+
}
|
|
66
|
+
|
|
41
67
|
export function Text({
|
|
42
68
|
variant = 'body',
|
|
43
69
|
tone = 'default',
|
|
44
70
|
weight,
|
|
45
71
|
style,
|
|
72
|
+
children,
|
|
46
73
|
...rest
|
|
47
74
|
}: TextProps) {
|
|
48
75
|
const t = useTheme();
|
|
49
76
|
const s = useStyles();
|
|
77
|
+
const styles = [
|
|
78
|
+
s.font,
|
|
79
|
+
s[variant],
|
|
80
|
+
s[tone],
|
|
81
|
+
tone === 'default' &&
|
|
82
|
+
(variant === 'screenTitle' ||
|
|
83
|
+
variant === 'title' ||
|
|
84
|
+
variant === 'display' ||
|
|
85
|
+
weight === 'semibold') &&
|
|
86
|
+
s.heading,
|
|
87
|
+
weight && s[weight],
|
|
88
|
+
style,
|
|
89
|
+
];
|
|
90
|
+
const flat: TextStyle = StyleSheet.flatten(styles as TextStyle[]) ?? {};
|
|
91
|
+
const shown = figureOf(children);
|
|
92
|
+
const capped =
|
|
93
|
+
shown !== null && isFigureText(shown) && HEAVY.has(flat.fontWeight ?? '');
|
|
94
|
+
const size = flat.fontSize ?? t.typography[variant].fontSize;
|
|
95
|
+
const tracking = flat.letterSpacing ?? 0;
|
|
96
|
+
const metrics = useMemo(() => ({ size, tracking }), [size, tracking]);
|
|
50
97
|
return (
|
|
51
98
|
<RNText
|
|
52
99
|
maxFontSizeMultiplier={t.maxFontScale}
|
|
100
|
+
lineBreakStrategyIOS="hangul-word"
|
|
53
101
|
{...rest}
|
|
54
|
-
style={[
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
weight && s[weight],
|
|
65
|
-
style,
|
|
66
|
-
]}
|
|
67
|
-
/>
|
|
102
|
+
style={capped ? [...styles, s.figure] : styles}
|
|
103
|
+
>
|
|
104
|
+
{typeof children === 'string' || typeof children === 'number' ? (
|
|
105
|
+
children
|
|
106
|
+
) : (
|
|
107
|
+
<TextMetricsContext.Provider value={metrics}>
|
|
108
|
+
{children}
|
|
109
|
+
</TextMetricsContext.Provider>
|
|
110
|
+
)}
|
|
111
|
+
</RNText>
|
|
68
112
|
);
|
|
69
113
|
}
|
|
@@ -49,7 +49,7 @@ const NAME_TOP = 32;
|
|
|
49
49
|
const NAME_WIDTH = 88;
|
|
50
50
|
const NAME_SIZE = 16;
|
|
51
51
|
const NAME_LEADING = 21;
|
|
52
|
-
const NAME_TRACKING = -0.
|
|
52
|
+
const NAME_TRACKING = -0.19;
|
|
53
53
|
const CHECK = 22;
|
|
54
54
|
const CHECK_INSET = 12;
|
|
55
55
|
|
|
@@ -106,6 +106,7 @@ const useStyles = makeStyles((t) => ({
|
|
|
106
106
|
right: INSET_X,
|
|
107
107
|
fontFamily: t.fontFamily,
|
|
108
108
|
fontSize: t.typography.eyebrow.fontSize,
|
|
109
|
+
letterSpacing: t.typography.eyebrow.letterSpacing,
|
|
109
110
|
lineHeight: t.typography.eyebrow.lineHeight,
|
|
110
111
|
fontWeight: '400',
|
|
111
112
|
color: t.colors.faint,
|
|
@@ -122,7 +123,7 @@ const useStyles = makeStyles((t) => ({
|
|
|
122
123
|
fontWeight: '600',
|
|
123
124
|
color: t.colors.title,
|
|
124
125
|
},
|
|
125
|
-
strong: { fontWeight: '
|
|
126
|
+
strong: { fontWeight: '600' },
|
|
126
127
|
check: {
|
|
127
128
|
position: 'absolute',
|
|
128
129
|
left: CHECK_INSET,
|
|
@@ -143,12 +143,18 @@ const useStyles = makeStyles((t) => ({
|
|
|
143
143
|
paddingRight: t.space[2],
|
|
144
144
|
},
|
|
145
145
|
message: { ...t.typography.body, flexShrink: 1, fontFamily: t.fontFamily },
|
|
146
|
-
messageFill: {
|
|
146
|
+
messageFill: {
|
|
147
|
+
flex: 1,
|
|
148
|
+
fontSize: t.typography.label.fontSize,
|
|
149
|
+
fontFamily: t.fontFamily,
|
|
150
|
+
letterSpacing: t.typography.label.letterSpacing,
|
|
151
|
+
},
|
|
147
152
|
action: { paddingHorizontal: t.space[3], justifyContent: 'center' },
|
|
148
153
|
mark: { marginRight: t.space[2] },
|
|
149
154
|
actionLabel: {
|
|
150
155
|
fontFamily: t.fontFamily,
|
|
151
156
|
fontSize: t.typography.label.fontSize,
|
|
157
|
+
letterSpacing: t.typography.label.letterSpacing,
|
|
152
158
|
lineHeight: t.typography.label.lineHeight,
|
|
153
159
|
fontWeight: '600',
|
|
154
160
|
},
|
|
@@ -3,6 +3,7 @@ import { ChevronGlyph } from '../../internal/glyphs';
|
|
|
3
3
|
import { PressableBase } from '../../internal/pressable-base';
|
|
4
4
|
import { useTheme } from '../../theme/theme-provider';
|
|
5
5
|
import { makeStyles } from '../../utils/styles';
|
|
6
|
+
import { Won } from '../text/figures';
|
|
6
7
|
|
|
7
8
|
export type ValueTone = 'default' | 'warning' | 'success';
|
|
8
9
|
|
|
@@ -30,6 +31,7 @@ const useStyles = makeStyles((t) => ({
|
|
|
30
31
|
label: {
|
|
31
32
|
fontFamily: t.fontFamily,
|
|
32
33
|
fontSize: t.typography.label.fontSize,
|
|
34
|
+
letterSpacing: t.typography.label.letterSpacing,
|
|
33
35
|
lineHeight: t.typography.label.lineHeight,
|
|
34
36
|
color: t.colors.mutedForeground,
|
|
35
37
|
},
|
|
@@ -38,6 +40,7 @@ const useStyles = makeStyles((t) => ({
|
|
|
38
40
|
textAlign: 'right',
|
|
39
41
|
fontFamily: t.fontFamily,
|
|
40
42
|
fontSize: t.typography.label.fontSize,
|
|
43
|
+
letterSpacing: t.typography.label.letterSpacing,
|
|
41
44
|
lineHeight: t.typography.label.lineHeight,
|
|
42
45
|
color: t.colors.foreground,
|
|
43
46
|
},
|
|
@@ -72,7 +75,12 @@ export function ValueRows({ rows, style }: ValueRowsProps) {
|
|
|
72
75
|
{row.note ? (
|
|
73
76
|
<Text style={tone(row.note.tone)}>{`${row.note.text} `}</Text>
|
|
74
77
|
) : null}
|
|
75
|
-
|
|
78
|
+
<Won
|
|
79
|
+
size={t.typography.label.fontSize}
|
|
80
|
+
tracking={t.typography.label.letterSpacing}
|
|
81
|
+
>
|
|
82
|
+
{row.value}
|
|
83
|
+
</Won>
|
|
76
84
|
</Text>
|
|
77
85
|
{row.onPress ? (
|
|
78
86
|
<ChevronGlyph color={t.colors.ring} size={t.iconSize.sm} />
|
|
@@ -13,6 +13,7 @@ const useStyles = makeStyles((t) => ({
|
|
|
13
13
|
flexShrink: 1,
|
|
14
14
|
fontFamily: t.fontFamily,
|
|
15
15
|
fontSize: t.typography.body.fontSize,
|
|
16
|
+
letterSpacing: t.typography.body.letterSpacing,
|
|
16
17
|
lineHeight: t.typography.body.lineHeight,
|
|
17
18
|
fontWeight: '500',
|
|
18
19
|
color: t.colors.foreground,
|
|
@@ -22,6 +23,7 @@ const useStyles = makeStyles((t) => ({
|
|
|
22
23
|
marginLeft: 'auto',
|
|
23
24
|
fontFamily: t.fontFamily,
|
|
24
25
|
fontSize: t.typography.caption.fontSize,
|
|
26
|
+
letterSpacing: t.typography.caption.letterSpacing,
|
|
25
27
|
lineHeight: t.typography.caption.lineHeight,
|
|
26
28
|
color: t.colors.mutedForeground,
|
|
27
29
|
fontVariant: ['tabular-nums'],
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { useEffect, useRef } from 'react';
|
|
2
|
-
import type
|
|
2
|
+
import { StyleSheet, type StyleProp, type TextStyle } from 'react-native';
|
|
3
3
|
import Animated, {
|
|
4
4
|
interpolateColor,
|
|
5
5
|
type AnimatedStyle,
|
|
@@ -8,6 +8,7 @@ import Animated, {
|
|
|
8
8
|
withSequence,
|
|
9
9
|
withTiming,
|
|
10
10
|
} from 'react-native-reanimated';
|
|
11
|
+
import { Won } from '../components/text/figures';
|
|
11
12
|
import { useTheme } from '../theme/theme-provider';
|
|
12
13
|
import { timing } from './motion';
|
|
13
14
|
|
|
@@ -19,11 +20,13 @@ export function RollText({
|
|
|
19
20
|
style,
|
|
20
21
|
animatedStyle,
|
|
21
22
|
flash = false,
|
|
23
|
+
money = false,
|
|
22
24
|
}: {
|
|
23
25
|
children: string | number;
|
|
24
26
|
style?: StyleProp<TextStyle>;
|
|
25
27
|
animatedStyle?: StyleProp<AnimatedStyle<TextStyle>>;
|
|
26
28
|
flash?: boolean;
|
|
29
|
+
money?: boolean;
|
|
27
30
|
}) {
|
|
28
31
|
const t = useTheme();
|
|
29
32
|
const roll = useSharedValue(0);
|
|
@@ -54,6 +57,7 @@ export function RollText({
|
|
|
54
57
|
['transparent', tint]
|
|
55
58
|
),
|
|
56
59
|
}));
|
|
60
|
+
const flat = StyleSheet.flatten(style) ?? {};
|
|
57
61
|
return (
|
|
58
62
|
<Animated.Text
|
|
59
63
|
maxFontSizeMultiplier={t.maxFontScale}
|
|
@@ -64,7 +68,13 @@ export function RollText({
|
|
|
64
68
|
move,
|
|
65
69
|
]}
|
|
66
70
|
>
|
|
67
|
-
{
|
|
71
|
+
{money ? (
|
|
72
|
+
<Won size={flat.fontSize} tracking={flat.letterSpacing}>
|
|
73
|
+
{String(children)}
|
|
74
|
+
</Won>
|
|
75
|
+
) : (
|
|
76
|
+
children
|
|
77
|
+
)}
|
|
68
78
|
</Animated.Text>
|
|
69
79
|
);
|
|
70
80
|
}
|
|
@@ -87,6 +87,8 @@ export function useSampleStyle() {
|
|
|
87
87
|
const t = useTheme();
|
|
88
88
|
return {
|
|
89
89
|
fontSize: t.typography.screenTitle.fontSize,
|
|
90
|
+
fontFamily: t.fontFamily,
|
|
91
|
+
letterSpacing: t.typography.screenTitle.letterSpacing,
|
|
90
92
|
lineHeight: t.typography.screenTitle.lineHeight,
|
|
91
93
|
color: t.colors.title,
|
|
92
94
|
};
|
|
@@ -106,6 +106,8 @@ const useStyles = makeStyles((t) => ({
|
|
|
106
106
|
snippet: {
|
|
107
107
|
marginTop: t.space[1],
|
|
108
108
|
fontSize: t.typography.eyebrow.fontSize,
|
|
109
|
+
fontFamily: t.fontFamily,
|
|
110
|
+
letterSpacing: t.typography.eyebrow.letterSpacing,
|
|
109
111
|
lineHeight: t.typography.eyebrow.lineHeight,
|
|
110
112
|
},
|
|
111
113
|
faded: { opacity: t.opacity.disabled },
|
|
@@ -94,6 +94,7 @@ const useStyles = makeStyles((t) => ({
|
|
|
94
94
|
label: {
|
|
95
95
|
fontFamily: t.fontFamily,
|
|
96
96
|
fontSize: t.typography.label.fontSize,
|
|
97
|
+
letterSpacing: t.typography.label.letterSpacing,
|
|
97
98
|
lineHeight: t.typography.label.lineHeight,
|
|
98
99
|
fontWeight: '500',
|
|
99
100
|
color: t.colors.mutedForeground,
|
|
@@ -112,6 +112,7 @@ const useStyles = makeStyles((t) => ({
|
|
|
112
112
|
optionLabel: {
|
|
113
113
|
fontFamily: t.fontFamily,
|
|
114
114
|
fontSize: t.typography.eyebrow.fontSize,
|
|
115
|
+
letterSpacing: t.typography.eyebrow.letterSpacing,
|
|
115
116
|
lineHeight: t.typography.eyebrow.lineHeight,
|
|
116
117
|
fontWeight: '500',
|
|
117
118
|
color: t.colors.mutedForeground,
|
|
@@ -120,6 +121,7 @@ const useStyles = makeStyles((t) => ({
|
|
|
120
121
|
note: {
|
|
121
122
|
fontFamily: t.fontFamily,
|
|
122
123
|
fontSize: t.typography.eyebrow.fontSize,
|
|
124
|
+
letterSpacing: t.typography.eyebrow.letterSpacing,
|
|
123
125
|
lineHeight: t.typography.eyebrow.lineHeight,
|
|
124
126
|
fontWeight: '500',
|
|
125
127
|
color: t.colors.faint,
|
|
@@ -180,6 +182,7 @@ const useStyles = makeStyles((t) => ({
|
|
|
180
182
|
tileLabel: {
|
|
181
183
|
fontFamily: t.fontFamily,
|
|
182
184
|
fontSize: t.typography.eyebrow.fontSize,
|
|
185
|
+
letterSpacing: t.typography.eyebrow.letterSpacing,
|
|
183
186
|
lineHeight: t.typography.eyebrow.lineHeight,
|
|
184
187
|
fontWeight: '400',
|
|
185
188
|
color: t.colors.title,
|
|
@@ -7,6 +7,7 @@ import {
|
|
|
7
7
|
} from 'react-native';
|
|
8
8
|
import { Photo } from '../components/photo/photo';
|
|
9
9
|
import { Text } from '../components/text/text';
|
|
10
|
+
import { Won, isFigureText } from '../components/text/figures';
|
|
10
11
|
import { CopyGlyph } from '../internal/glyphs';
|
|
11
12
|
import { PressableBase } from '../internal/pressable-base';
|
|
12
13
|
import { useTheme } from '../theme/theme-provider';
|
|
@@ -83,6 +84,7 @@ const useStyles = makeStyles((t) => ({
|
|
|
83
84
|
flex: 1,
|
|
84
85
|
fontFamily: t.fontFamily,
|
|
85
86
|
fontSize: t.typography.screenTitle.fontSize,
|
|
87
|
+
letterSpacing: t.typography.screenTitle.letterSpacing,
|
|
86
88
|
lineHeight: t.typography.screenTitle.lineHeight,
|
|
87
89
|
fontWeight: '600',
|
|
88
90
|
color: t.colors.title,
|
|
@@ -95,13 +97,17 @@ const useStyles = makeStyles((t) => ({
|
|
|
95
97
|
heroCaptionText: {
|
|
96
98
|
fontFamily: t.fontFamily,
|
|
97
99
|
fontSize: t.typography.eyebrow.fontSize,
|
|
100
|
+
letterSpacing: t.typography.eyebrow.letterSpacing,
|
|
98
101
|
lineHeight: t.typography.eyebrow.lineHeight,
|
|
99
102
|
color: t.colors.mutedForeground,
|
|
100
103
|
},
|
|
101
104
|
heroBody: { marginTop: t.space[4] },
|
|
102
105
|
heroWarn: { color: t.colors.warningText, fontWeight: '500' },
|
|
106
|
+
heroFigure: { fontWeight: '500' },
|
|
103
107
|
heroSuffix: {
|
|
104
108
|
fontSize: t.typography.label.fontSize,
|
|
109
|
+
fontFamily: t.fontFamily,
|
|
110
|
+
letterSpacing: t.typography.label.letterSpacing,
|
|
105
111
|
fontWeight: '400',
|
|
106
112
|
color: t.colors.mutedForeground,
|
|
107
113
|
},
|
|
@@ -146,8 +152,11 @@ function ScrollTemplate({
|
|
|
146
152
|
<View style={s.hero}>
|
|
147
153
|
{hero.overline}
|
|
148
154
|
<View style={s.heroHead}>
|
|
149
|
-
<Text
|
|
150
|
-
|
|
155
|
+
<Text
|
|
156
|
+
accessibilityRole="header"
|
|
157
|
+
style={[s.heroTitle, isFigureText(hero.title) && s.heroFigure]}
|
|
158
|
+
>
|
|
159
|
+
<Won>{hero.title}</Won>
|
|
151
160
|
{hero.titleSuffix ? (
|
|
152
161
|
<Text style={s.heroSuffix}>{` ${hero.titleSuffix}`}</Text>
|
|
153
162
|
) : null}
|