@godxjp/ui 19.6.0 → 20.1.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/README.md +8 -2
- package/dist/app/theme-axes.d.ts +2 -0
- package/dist/app/theme-axes.js +45 -0
- package/dist/components/charts/chart-cartesian.d.ts +2 -1
- package/dist/components/charts/chart-cartesian.js +52 -3
- package/dist/components/charts/chart-category-axis.d.ts +55 -0
- package/dist/components/charts/chart-category-axis.js +93 -0
- package/dist/components/charts/chart-frame.d.ts +10 -1
- package/dist/components/charts/chart-frame.js +19 -3
- package/dist/components/charts/compact-bar-trend.d.ts +1 -1
- package/dist/components/charts/compact-bar-trend.js +2 -0
- package/dist/components/charts/pie-chart.d.ts +1 -1
- package/dist/components/charts/pie-chart.js +12 -1
- package/dist/components/charts/recharts-peer.d.ts +49 -0
- package/dist/components/charts/recharts-peer.js +45 -0
- package/dist/components/data-display/card.d.ts +14 -3
- package/dist/components/data-display/card.js +22 -4
- package/dist/components/data-display/code-block.js +6 -2
- package/dist/components/data-display/collapsible.d.ts +23 -4
- package/dist/components/data-display/collapsible.js +119 -4
- package/dist/components/data-display/data-table.d.ts +39 -4
- package/dist/components/data-display/data-table.js +802 -270
- package/dist/components/data-display/descriptions.d.ts +27 -6
- package/dist/components/data-display/descriptions.js +58 -17
- package/dist/components/data-display/index.d.ts +5 -1
- package/dist/components/data-display/index.js +4 -0
- package/dist/components/data-display/legend.d.ts +15 -0
- package/dist/components/data-display/legend.js +11 -0
- package/dist/components/data-display/list-row.d.ts +10 -1
- package/dist/components/data-display/list-row.js +8 -2
- package/dist/components/data-display/popover.d.ts +60 -7
- package/dist/components/data-display/popover.js +268 -39
- package/dist/components/data-display/progress.d.ts +50 -2
- package/dist/components/data-display/progress.js +57 -9
- package/dist/components/data-display/range-timeline.d.ts +38 -0
- package/dist/components/data-display/range-timeline.js +161 -0
- package/dist/components/data-display/scroll-area.js +13 -2
- package/dist/components/data-display/service-launcher-card.js +10 -10
- package/dist/components/data-display/table.d.ts +11 -3
- package/dist/components/data-display/table.js +48 -18
- package/dist/components/data-display/tree-list.js +4 -9
- package/dist/components/data-entry/calendar.d.ts +2 -2
- package/dist/components/data-entry/calendar.js +79 -33
- package/dist/components/data-entry/cascader.d.ts +1 -1
- package/dist/components/data-entry/cascader.js +188 -24
- package/dist/components/data-entry/checkbox.d.ts +19 -6
- package/dist/components/data-entry/checkbox.js +55 -16
- package/dist/components/data-entry/choice-option.d.ts +1 -1
- package/dist/components/data-entry/color-picker.d.ts +1 -1
- package/dist/components/data-entry/color-picker.js +17 -5
- package/dist/components/data-entry/control-appearance.d.ts +64 -0
- package/dist/components/data-entry/control-appearance.js +39 -0
- package/dist/components/data-entry/control-surface.d.ts +61 -0
- package/dist/components/data-entry/control-surface.js +39 -0
- package/dist/components/data-entry/date-picker.d.ts +1 -1
- package/dist/components/data-entry/date-picker.js +344 -113
- package/dist/components/data-entry/date-range-picker.d.ts +2 -2
- package/dist/components/data-entry/date-range-picker.js +278 -140
- package/dist/components/data-entry/field.js +0 -1
- package/dist/components/data-entry/form-field.d.ts +1 -1
- package/dist/components/data-entry/form-field.js +39 -4
- package/dist/components/data-entry/form.d.ts +4 -0
- package/dist/components/data-entry/form.js +5 -3
- package/dist/components/data-entry/index.d.ts +7 -3
- package/dist/components/data-entry/index.js +10 -1
- package/dist/components/data-entry/input-otp.d.ts +1 -1
- package/dist/components/data-entry/input.d.ts +12 -34
- package/dist/components/data-entry/input.js +92 -24
- package/dist/components/data-entry/label.d.ts +3 -2
- package/dist/components/data-entry/label.js +23 -10
- package/dist/components/data-entry/month-picker.d.ts +2 -2
- package/dist/components/data-entry/month-picker.js +47 -10
- package/dist/components/data-entry/month-range-picker.d.ts +2 -2
- package/dist/components/data-entry/month-range-picker.js +51 -11
- package/dist/components/data-entry/number-input.d.ts +7 -0
- package/dist/components/data-entry/number-input.js +147 -98
- package/dist/components/data-entry/password-input.d.ts +1 -1
- package/dist/components/data-entry/radio.d.ts +1 -1
- package/dist/components/data-entry/radio.js +61 -13
- package/dist/components/data-entry/search-input.d.ts +1 -1
- package/dist/components/data-entry/search-input.js +16 -2
- package/dist/components/data-entry/search-select.d.ts +2 -2
- package/dist/components/data-entry/search-select.js +209 -78
- package/dist/components/data-entry/select.d.ts +22 -4
- package/dist/components/data-entry/select.js +215 -163
- package/dist/components/data-entry/slider.d.ts +9 -1
- package/dist/components/data-entry/slider.js +87 -9
- package/dist/components/data-entry/switch.d.ts +3 -0
- package/dist/components/data-entry/switch.js +29 -3
- package/dist/components/data-entry/textarea.d.ts +14 -56
- package/dist/components/data-entry/textarea.js +80 -33
- package/dist/components/data-entry/time-picker.d.ts +2 -2
- package/dist/components/data-entry/time-picker.js +333 -109
- package/dist/components/data-entry/time-range-picker.d.ts +5 -0
- package/dist/components/data-entry/time-range-picker.js +89 -0
- package/dist/components/data-entry/transfer.d.ts +1 -1
- package/dist/components/data-entry/transfer.js +99 -31
- package/dist/components/data-entry/tree-select-strategy.d.ts +1 -1
- package/dist/components/data-entry/tree-select.d.ts +1 -1
- package/dist/components/data-entry/tree-select.js +197 -92
- package/dist/components/data-entry/tree-utils.d.ts +1 -1
- package/dist/components/data-entry/tree-utils.js +7 -14
- package/dist/components/data-entry/upload-files.d.ts +2 -0
- package/dist/components/data-entry/upload-files.js +31 -0
- package/dist/components/data-entry/upload-request.d.ts +4 -0
- package/dist/components/data-entry/upload-request.js +53 -0
- package/dist/components/data-entry/upload-types.d.ts +28 -0
- package/dist/components/data-entry/upload-types.js +2 -0
- package/dist/components/data-entry/upload.d.ts +2 -2
- package/dist/components/data-entry/upload.js +482 -117
- package/dist/components/feedback/dialog.d.ts +105 -38
- package/dist/components/feedback/dialog.js +268 -193
- package/dist/components/feedback/overlay-close-focus.d.ts +31 -0
- package/dist/components/feedback/overlay-close-focus.js +31 -0
- package/dist/components/feedback/overlay-header-tone.d.ts +1 -1
- package/dist/components/feedback/sheet.d.ts +53 -11
- package/dist/components/feedback/sheet.js +150 -81
- package/dist/components/feedback/tooltip.d.ts +51 -7
- package/dist/components/feedback/tooltip.js +107 -25
- package/dist/components/general/button.d.ts +1 -1
- package/dist/components/general/button.js +7 -3
- package/dist/components/general/index.d.ts +1 -0
- package/dist/components/general/index.js +2 -0
- package/dist/components/general/logo.d.ts +17 -0
- package/dist/components/general/logo.js +22 -16
- package/dist/components/general/typography.d.ts +3 -0
- package/dist/components/general/typography.js +15 -1
- package/dist/components/general/visually-hidden.d.ts +3 -0
- package/dist/components/general/visually-hidden.js +9 -0
- package/dist/components/layout/app-launcher.d.ts +34 -0
- package/dist/components/layout/app-launcher.js +228 -0
- package/dist/components/layout/app-shell.d.ts +3 -1
- package/dist/components/layout/app-shell.js +69 -12
- package/dist/components/layout/aspect-ratio.js +0 -1
- package/dist/components/layout/auth-divider.js +0 -1
- package/dist/components/layout/breadcrumb.d.ts +14 -2
- package/dist/components/layout/breadcrumb.js +46 -4
- package/dist/components/layout/flex.d.ts +1 -1
- package/dist/components/layout/flex.js +41 -3
- package/dist/components/layout/index.d.ts +3 -0
- package/dist/components/layout/index.js +5 -1
- package/dist/components/layout/nav-surface.d.ts +26 -0
- package/dist/components/layout/nav-surface.js +17 -0
- package/dist/components/layout/org-switcher.d.ts +5 -1
- package/dist/components/layout/org-switcher.js +25 -4
- package/dist/components/layout/page-container.d.ts +1 -1
- package/dist/components/layout/page-container.js +5 -3
- package/dist/components/layout/responsive-grid.d.ts +16 -2
- package/dist/components/layout/responsive-grid.js +29 -2
- package/dist/components/layout/separator.js +0 -1
- package/dist/components/layout/sidebar.js +4 -1
- package/dist/components/layout/split-pane.d.ts +14 -1
- package/dist/components/layout/split-pane.js +26 -13
- package/dist/components/layout/topbar-item.d.ts +3 -0
- package/dist/components/layout/topbar-item.js +19 -5
- package/dist/components/layout/topbar.d.ts +1 -1
- package/dist/components/layout/topbar.js +27 -6
- package/dist/components/navigation/app-setting-picker.js +21 -2
- package/dist/components/navigation/app-setting-toggle.d.ts +16 -0
- package/dist/components/navigation/app-setting-toggle.js +96 -0
- package/dist/components/navigation/dropdown-menu.d.ts +227 -18
- package/dist/components/navigation/dropdown-menu.js +402 -118
- package/dist/components/navigation/index.d.ts +2 -0
- package/dist/components/navigation/index.js +2 -0
- package/dist/components/navigation/pagination-utils.d.ts +2 -1
- package/dist/components/navigation/pagination.d.ts +2 -2
- package/dist/components/navigation/pagination.js +155 -83
- package/dist/components/navigation/steps.d.ts +2 -2
- package/dist/components/navigation/steps.js +29 -4
- package/dist/components/navigation/tabs.d.ts +29 -16
- package/dist/components/navigation/tabs.js +374 -144
- package/dist/components/ui/accordion.d.ts +50 -5
- package/dist/components/ui/accordion.js +239 -33
- package/dist/components/ui/aspect-ratio.d.ts +23 -2
- package/dist/components/ui/aspect-ratio.js +15 -13
- package/dist/components/ui/avatar.d.ts +29 -4
- package/dist/components/ui/avatar.js +111 -25
- package/dist/components/ui/hover-card.d.ts +42 -4
- package/dist/components/ui/hover-card.js +183 -27
- package/dist/components/ui/input-otp.d.ts +26 -28
- package/dist/components/ui/input-otp.js +50 -7
- package/dist/components/ui/label.js +0 -1
- package/dist/components/ui/password-input.d.ts +36 -2
- package/dist/components/ui/password-input.js +27 -7
- package/dist/components/ui/rating.d.ts +25 -0
- package/dist/components/ui/rating.js +67 -27
- package/dist/components/ui/segmented.d.ts +12 -3
- package/dist/components/ui/segmented.js +17 -2
- package/dist/components/ui/separator.d.ts +12 -2
- package/dist/components/ui/separator.js +30 -9
- package/dist/components/ui/tag-input.d.ts +45 -0
- package/dist/components/ui/tag-input.js +109 -27
- package/dist/components/ui/toggle-group.d.ts +50 -5
- package/dist/components/ui/toggle-group.js +79 -20
- package/dist/components/ui/toggle.d.ts +31 -5
- package/dist/components/ui/toggle.js +42 -3
- package/dist/form/form-context.d.ts +29 -0
- package/dist/form/form-context.js +44 -4
- package/dist/form/form-field-array.d.ts +22 -0
- package/dist/form/form-field-array.js +50 -0
- package/dist/form/form-field-control.d.ts +2 -1
- package/dist/form/form-field-control.js +116 -40
- package/dist/form/form-root.d.ts +2 -1
- package/dist/form/form-root.js +142 -23
- package/dist/form/index.d.ts +3 -1
- package/dist/form/index.js +12 -1
- package/dist/i18n/messages/en.json +64 -5
- package/dist/i18n/messages/ja.json +64 -5
- package/dist/i18n/messages/vi.json +64 -5
- package/dist/inertia/index.d.ts +20 -0
- package/dist/inertia/index.js +60 -1
- package/dist/lib/control-styles.d.ts +25 -3
- package/dist/lib/control-styles.js +9 -3
- package/dist/lib/datetime/picker-format.d.ts +8 -0
- package/dist/lib/datetime/picker-format.js +54 -0
- package/dist/lib/slot.d.ts +32 -0
- package/dist/lib/slot.js +22 -0
- package/dist/lib/variants.d.ts +22 -3
- package/dist/lib/variants.js +56 -1
- package/dist/props/components/app.prop.d.ts +25 -1
- package/dist/props/components/charts.prop.d.ts +21 -0
- package/dist/props/components/data-display.prop.d.ts +72 -4
- package/dist/props/components/data-entry.prop.d.ts +718 -46
- package/dist/props/components/form.prop.d.ts +142 -4
- package/dist/props/components/general.prop.d.ts +17 -1
- package/dist/props/components/index.d.ts +3 -3
- package/dist/props/components/layout.prop.d.ts +281 -11
- package/dist/props/components/navigation.prop.d.ts +114 -4
- package/dist/props/registry.d.ts +397 -11
- package/dist/props/registry.js +526 -11
- package/dist/props/vocabulary/content.prop.d.ts +1 -1
- package/dist/props/vocabulary/data.prop.d.ts +179 -1
- package/dist/props/vocabulary/index.d.ts +5 -5
- package/dist/props/vocabulary/interaction.prop.d.ts +68 -3
- package/dist/props/vocabulary/layout.prop.d.ts +57 -1
- package/dist/props/vocabulary/navigation.prop.d.ts +40 -0
- package/dist/props/vocabulary/shared.prop.d.ts +33 -0
- package/dist/styles/badge-layout.css +2 -1
- package/dist/styles/card-layout.css +26 -4
- package/dist/styles/chart-layout.css +15 -0
- package/dist/styles/control.css +657 -15
- package/dist/styles/core.css +5 -2
- package/dist/styles/data-display-layout.css +313 -6
- package/dist/styles/data-entry-layout.css +13 -0
- package/dist/styles/focus-ring.css +4 -0
- package/dist/styles/index.css +5 -2
- package/dist/styles/layout.css +327 -4
- package/dist/styles/navigation-layout.css +227 -0
- package/dist/styles/shell-layout.css +369 -13
- package/dist/styles/table-layout.css +95 -6
- package/dist/styles/text-layout.css +10 -4
- package/dist/tokens/base.css +2 -1
- package/dist/tokens/components/badge.css +1 -0
- package/dist/tokens/components/chart.css +6 -0
- package/dist/tokens/components/control.css +79 -2
- package/dist/tokens/components/data-display.css +20 -0
- package/dist/tokens/components/descriptions.css +11 -0
- package/dist/tokens/components/flex.css +8 -0
- package/dist/tokens/components/navigation.css +55 -0
- package/dist/tokens/components/shell.css +53 -3
- package/dist/tokens/components/table.css +14 -0
- package/dist/tokens/foundation.css +2 -0
- package/dist/tokens/semantic/layout.css +9 -0
- package/docs/COMPONENTS.md +9 -3
- package/docs/CONSUMER-RULES.md +13 -0
- package/docs/DESIGN-AUTHORITY.md +145 -83
- package/docs/DEVELOPMENT.md +4 -3
- package/docs/FORMS.md +151 -6
- package/docs/FRAME-COVERAGE-REPORT.md +32 -17
- package/docs/README.md +15 -15
- package/docs/STANDARDS-vocabulary-tokens.md +1 -1
- package/docs/TESTING.md +15 -6
- package/docs/WHAT-BELONGS-HERE.md +179 -0
- package/docs/charts/cjk-category-axis.tsx +81 -0
- package/docs/data-display/card/index.tsx +22 -0
- package/docs/data-display/data-table/examples/antd-parity.tsx +257 -0
- package/docs/data-display/data-table/index.tsx +23 -0
- package/docs/data-display/descriptions.tsx +41 -0
- package/docs/data-display/legend.tsx +145 -0
- package/docs/data-display/progress.tsx +32 -0
- package/docs/data-display/scroll-area.tsx +31 -25
- package/docs/data-display/table.tsx +104 -45
- package/docs/data-display/timeline.tsx +41 -0
- package/docs/data-entry/date-picker.tsx +85 -0
- package/docs/data-entry/date-range-picker.tsx +26 -0
- package/docs/data-entry/form-dynamic-fields.tsx +199 -0
- package/docs/data-entry/form.tsx +74 -4
- package/docs/data-entry/input-otp.tsx +24 -0
- package/docs/data-entry/input.tsx +46 -1
- package/docs/data-entry/month-range-picker.tsx +1 -1
- package/docs/data-entry/segmented.tsx +1 -1
- package/docs/data-entry/select.tsx +29 -2
- package/docs/data-entry/switch.tsx +41 -0
- package/docs/data-entry/textarea.tsx +38 -0
- package/docs/data-entry/time-picker.tsx +85 -1
- package/docs/data-entry/time-range-picker.tsx +55 -0
- package/docs/data-entry/transfer.tsx +17 -0
- package/docs/data-entry/upload.tsx +56 -12
- package/docs/feedback/sheet.tsx +1 -1
- package/docs/feedback/tooltip.tsx +1 -1
- package/docs/general/activity.tsx +2 -2
- package/docs/general/button/index.tsx +14 -1
- package/docs/general/typography.tsx +14 -1
- package/docs/layout/app-launcher.tsx +151 -0
- package/docs/layout/app-shell-arrangements.tsx +225 -0
- package/docs/layout/app-shell.tsx +11 -0
- package/docs/layout/aspect-ratio.tsx +1 -1
- package/docs/layout/flex.tsx +50 -0
- package/docs/layout/responsive-grid.tsx +21 -1
- package/docs/layout/topbar.tsx +5 -9
- package/docs/navigation/app-setting-picker.tsx +37 -1
- package/docs/navigation/app-setting-toggle.tsx +111 -0
- package/docs/navigation/breadcrumb.tsx +48 -0
- package/docs/navigation/dropdown-menu.tsx +21 -0
- package/docs/navigation/pagination.tsx +52 -0
- package/docs/navigation/steps.tsx +37 -0
- package/docs/navigation/tabs.tsx +97 -1
- package/docs/query/button-refetch.tsx +1 -0
- package/package.json +28 -8
- package/scripts/_agent-setup.mjs +182 -3
- package/scripts/consumer-rule.md +98 -0
- package/scripts/guinea-pig-skill.md +322 -0
- package/scripts/init-guinea-pig.mjs +84 -0
- package/scripts/postinstall.mjs +13 -2
- package/scripts/ui-audit.mjs +351 -37
- /package/dist/tokens/{antd.generated.css → derived.css} +0 -0
|
@@ -117,6 +117,29 @@ export default function Demo() {
|
|
|
117
117
|
subtitle="sortable · selectable · bulk actions · row actions · loading · clickable rows · empty state"
|
|
118
118
|
>
|
|
119
119
|
<Flex direction="col" gap="lg">
|
|
120
|
+
<Flex direction="col" gap="sm" id="text-action-width">
|
|
121
|
+
<Text weight="medium">日本語の行アクション</Text>
|
|
122
|
+
<DataTable
|
|
123
|
+
preset="action-collection"
|
|
124
|
+
columns={[
|
|
125
|
+
{ key: "partner", header: "取引先" },
|
|
126
|
+
{ key: "date", header: "期限日", width: "104px" },
|
|
127
|
+
{
|
|
128
|
+
key: "action",
|
|
129
|
+
header: "操作",
|
|
130
|
+
priority: "actions",
|
|
131
|
+
width: "104px",
|
|
132
|
+
render: () => (
|
|
133
|
+
<Button size="sm" variant="ghost">
|
|
134
|
+
対応する
|
|
135
|
+
</Button>
|
|
136
|
+
),
|
|
137
|
+
},
|
|
138
|
+
]}
|
|
139
|
+
data={invoices}
|
|
140
|
+
getRowId={(row) => row.id}
|
|
141
|
+
/>
|
|
142
|
+
</Flex>
|
|
120
143
|
{/* Primary: sorted (amount desc), one row preselected, clickable rows,
|
|
121
144
|
controlled density (comfortable), kebab row actions, pagination footer. */}
|
|
122
145
|
<DataTable
|
|
@@ -7,6 +7,7 @@ import {
|
|
|
7
7
|
CardTitle,
|
|
8
8
|
Descriptions,
|
|
9
9
|
} from "@godxjp/ui/data-display";
|
|
10
|
+
import type { CSSProperties } from "react";
|
|
10
11
|
import { Text } from "@godxjp/ui/general";
|
|
11
12
|
import { Flex, PageContainer } from "@godxjp/ui/layout";
|
|
12
13
|
|
|
@@ -137,6 +138,46 @@ export default function Demo() {
|
|
|
137
138
|
</Descriptions>
|
|
138
139
|
</CardContent>
|
|
139
140
|
</Card>
|
|
141
|
+
|
|
142
|
+
{/* ── The RULED property panel (gh#414) ─────────────────────────────
|
|
143
|
+
Two token knobs, both OFF by default, turn a horizontal Descriptions into the ruled
|
|
144
|
+
panel a detail page usually wants. They exist so a service stops hand-rolling a
|
|
145
|
+
`<Flex className="min-h-10 border-b">` row: the label column, the gaps and the value
|
|
146
|
+
type step were already Descriptions'; only the rule and the band height were missing.
|
|
147
|
+
The row gap goes to 0 in the same declaration — the gap is the space BETWEEN rules, so
|
|
148
|
+
leaving it would draw detached hairlines instead of a ruled list. */}
|
|
149
|
+
<Card>
|
|
150
|
+
<CardHeader>
|
|
151
|
+
<CardTitle level={2}>案件の詳細 · ruled rows</CardTitle>
|
|
152
|
+
<CardDescription>
|
|
153
|
+
一行ごとに罫線を引いた属性パネル。--descriptions-row-border と
|
|
154
|
+
--descriptions-row-min-height をテーマで一度設定するだけで、コンポーネントは同じです。
|
|
155
|
+
</CardDescription>
|
|
156
|
+
</CardHeader>
|
|
157
|
+
{/* The knobs are declared on the CARD BODY, not on the grid: custom properties inherit,
|
|
158
|
+
so one scope re-tunes every Descriptions inside it — which is how a service theme
|
|
159
|
+
would set them (once, globally), not per call site. */}
|
|
160
|
+
<CardContent
|
|
161
|
+
style={
|
|
162
|
+
{
|
|
163
|
+
"--descriptions-row-border": "1px solid hsl(var(--border))",
|
|
164
|
+
"--descriptions-row-min-height": "var(--band-height-lg)",
|
|
165
|
+
"--descriptions-row-gap": "0px",
|
|
166
|
+
} as CSSProperties
|
|
167
|
+
}
|
|
168
|
+
>
|
|
169
|
+
<Descriptions columns={1} layout="horizontal">
|
|
170
|
+
<Descriptions.Item label="案件名">2026年度 基幹システム更改</Descriptions.Item>
|
|
171
|
+
<Descriptions.Item label="担当">山田 太郎</Descriptions.Item>
|
|
172
|
+
<Descriptions.Item label="状態">
|
|
173
|
+
<Badge status="active" />
|
|
174
|
+
</Descriptions.Item>
|
|
175
|
+
<Descriptions.Item label="契約ID" mono>
|
|
176
|
+
CT-2026-0088
|
|
177
|
+
</Descriptions.Item>
|
|
178
|
+
</Descriptions>
|
|
179
|
+
</CardContent>
|
|
180
|
+
</Card>
|
|
140
181
|
</Flex>
|
|
141
182
|
</PageContainer>
|
|
142
183
|
);
|
|
@@ -0,0 +1,145 @@
|
|
|
1
|
+
import {
|
|
2
|
+
Card,
|
|
3
|
+
CardAction,
|
|
4
|
+
CardContent,
|
|
5
|
+
CardDescription,
|
|
6
|
+
CardHeader,
|
|
7
|
+
CardTitle,
|
|
8
|
+
Legend,
|
|
9
|
+
Progress,
|
|
10
|
+
} from "@godxjp/ui/data-display";
|
|
11
|
+
import { Text } from "@godxjp/ui/general";
|
|
12
|
+
import { Flex, PageContainer } from "@godxjp/ui/layout";
|
|
13
|
+
|
|
14
|
+
const COMPLIANCE = [
|
|
15
|
+
{ name: "株式会社山田製作所", over: 2, near: 3, done: 12 },
|
|
16
|
+
{ name: "佐藤食品株式会社", over: 1, near: 2, done: 9 },
|
|
17
|
+
{ name: "東海精密工業株式会社", over: 0, near: 3, done: 21 },
|
|
18
|
+
];
|
|
19
|
+
|
|
20
|
+
const STATUS_KEYS = [
|
|
21
|
+
{ tone: "destructive", label: "期限超過" },
|
|
22
|
+
{ tone: "warning", label: "期限間近" },
|
|
23
|
+
{ tone: "success", label: "対応済" },
|
|
24
|
+
] as const;
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* Legend — the KEY for a colour-coded surface: which tone means what, in words, once.
|
|
28
|
+
* Composed only from real @godxjp/ui components.
|
|
29
|
+
*/
|
|
30
|
+
export default function Demo() {
|
|
31
|
+
return (
|
|
32
|
+
<PageContainer title="Legend" subtitle="tone → 意味 のキー · 凡例">
|
|
33
|
+
<Flex direction="col" gap="lg">
|
|
34
|
+
<Card>
|
|
35
|
+
<CardHeader>
|
|
36
|
+
<CardTitle level={2}>Progress の breakdown と組む</CardTitle>
|
|
37
|
+
<CardDescription>
|
|
38
|
+
CardAction に置くと、カード見出しと同じ行に凡例が並びます。色の意味をカードで
|
|
39
|
+
一度だけ言い、各行では繰り返しません。
|
|
40
|
+
</CardDescription>
|
|
41
|
+
<CardAction>
|
|
42
|
+
<Legend items={[...STATUS_KEYS]} />
|
|
43
|
+
</CardAction>
|
|
44
|
+
</CardHeader>
|
|
45
|
+
<CardContent>
|
|
46
|
+
<Flex direction="col" gapRaw={11}>
|
|
47
|
+
{COMPLIANCE.map((row) => (
|
|
48
|
+
<Flex key={row.name} align="center" gapRaw={14}>
|
|
49
|
+
<Flex width={180}>
|
|
50
|
+
<Text weight="medium" truncate>
|
|
51
|
+
{row.name}
|
|
52
|
+
</Text>
|
|
53
|
+
</Flex>
|
|
54
|
+
<Flex fill direction="col">
|
|
55
|
+
<Progress
|
|
56
|
+
segments={[
|
|
57
|
+
{ value: row.over, tone: "destructive", label: "期限超過" },
|
|
58
|
+
{ value: row.near, tone: "warning", label: "期限間近" },
|
|
59
|
+
{ value: row.done, tone: "success", label: "対応済" },
|
|
60
|
+
]}
|
|
61
|
+
aria-label={row.name}
|
|
62
|
+
/>
|
|
63
|
+
</Flex>
|
|
64
|
+
<Flex width={150} justify="end" align="center" gapRaw={12}>
|
|
65
|
+
<Text tone="destructive" weight="semibold" tabular>
|
|
66
|
+
{row.over}
|
|
67
|
+
</Text>
|
|
68
|
+
<Text tone="warning" weight="semibold" tabular>
|
|
69
|
+
{row.near}
|
|
70
|
+
</Text>
|
|
71
|
+
<Text tone="success" weight="semibold" tabular>
|
|
72
|
+
{row.done}
|
|
73
|
+
</Text>
|
|
74
|
+
<Text tone="muted" tabular>
|
|
75
|
+
計 {row.over + row.near + row.done}
|
|
76
|
+
</Text>
|
|
77
|
+
</Flex>
|
|
78
|
+
</Flex>
|
|
79
|
+
))}
|
|
80
|
+
</Flex>
|
|
81
|
+
</CardContent>
|
|
82
|
+
</Card>
|
|
83
|
+
|
|
84
|
+
<Card>
|
|
85
|
+
<CardHeader>
|
|
86
|
+
<CardTitle level={2}>Tones</CardTitle>
|
|
87
|
+
<CardDescription>
|
|
88
|
+
vocabulary の 7 tone すべてに塗りがあります。色だけで意味を運ばないため label
|
|
89
|
+
は必須です(WCAG 1.4.1)。
|
|
90
|
+
</CardDescription>
|
|
91
|
+
</CardHeader>
|
|
92
|
+
<CardContent>
|
|
93
|
+
<Legend
|
|
94
|
+
items={[
|
|
95
|
+
{ tone: "default", label: "既定(primary)" },
|
|
96
|
+
{ tone: "success", label: "成功" },
|
|
97
|
+
{ tone: "warning", label: "注意" },
|
|
98
|
+
{ tone: "destructive", label: "危険" },
|
|
99
|
+
{ tone: "info", label: "情報" },
|
|
100
|
+
{ tone: "muted", label: "控えめ" },
|
|
101
|
+
{ tone: "neutral", label: "中立" },
|
|
102
|
+
]}
|
|
103
|
+
/>
|
|
104
|
+
</CardContent>
|
|
105
|
+
</Card>
|
|
106
|
+
|
|
107
|
+
<Card>
|
|
108
|
+
<CardHeader>
|
|
109
|
+
<CardTitle level={2}>Named legend</CardTitle>
|
|
110
|
+
<CardDescription>
|
|
111
|
+
aria-label を渡すと、その凡例が「何のキーか」を読み上げます。項目は list /
|
|
112
|
+
listitem として並びます。
|
|
113
|
+
</CardDescription>
|
|
114
|
+
</CardHeader>
|
|
115
|
+
<CardContent>
|
|
116
|
+
<Legend items={[...STATUS_KEYS]} aria-label="コンプライアンス状況の凡例" />
|
|
117
|
+
</CardContent>
|
|
118
|
+
</Card>
|
|
119
|
+
|
|
120
|
+
<Card>
|
|
121
|
+
<CardHeader>
|
|
122
|
+
<CardTitle level={2}>Wrapping</CardTitle>
|
|
123
|
+
<CardDescription>
|
|
124
|
+
狭い幅では折り返します(横スクロールしません)。凡例が視界の外に出ると、色の意味
|
|
125
|
+
そのものが失われるためです。
|
|
126
|
+
</CardDescription>
|
|
127
|
+
</CardHeader>
|
|
128
|
+
<CardContent>
|
|
129
|
+
<Flex width={240}>
|
|
130
|
+
<Legend
|
|
131
|
+
items={[
|
|
132
|
+
{ tone: "destructive", label: "期限超過" },
|
|
133
|
+
{ tone: "warning", label: "期限間近" },
|
|
134
|
+
{ tone: "success", label: "対応済" },
|
|
135
|
+
{ tone: "info", label: "確認中" },
|
|
136
|
+
{ tone: "muted", label: "対象外" },
|
|
137
|
+
]}
|
|
138
|
+
/>
|
|
139
|
+
</Flex>
|
|
140
|
+
</CardContent>
|
|
141
|
+
</Card>
|
|
142
|
+
</Flex>
|
|
143
|
+
</PageContainer>
|
|
144
|
+
);
|
|
145
|
+
}
|
|
@@ -33,6 +33,38 @@ export default function Demo() {
|
|
|
33
33
|
</CardContent>
|
|
34
34
|
</Card>
|
|
35
35
|
|
|
36
|
+
<Card>
|
|
37
|
+
<CardHeader>
|
|
38
|
+
<CardTitle level={2}>Breakdown(segments)</CardTitle>
|
|
39
|
+
<CardDescription>
|
|
40
|
+
1 つの合計を状態ごとに分割します。割合ではなく実数を渡すと、各スライスの比率は
|
|
41
|
+
コンポーネントが計算します。メーターより背の高いトラックになるのは、0.5rem の pill
|
|
42
|
+
上に 3 色を並べると比率が読めなくなるためです。role="img"
|
|
43
|
+
として、全スライスを 1 つの名前で読み上げます。
|
|
44
|
+
</CardDescription>
|
|
45
|
+
</CardHeader>
|
|
46
|
+
<CardContent>
|
|
47
|
+
<Flex direction="col" gap="md">
|
|
48
|
+
<Progress
|
|
49
|
+
segments={[
|
|
50
|
+
{ value: 2, tone: "destructive", label: "期限超過" },
|
|
51
|
+
{ value: 3, tone: "warning", label: "期限間近" },
|
|
52
|
+
{ value: 12, tone: "success", label: "対応済" },
|
|
53
|
+
]}
|
|
54
|
+
label="株式会社山田製作所"
|
|
55
|
+
/>
|
|
56
|
+
<Progress
|
|
57
|
+
segments={[
|
|
58
|
+
{ value: 0, tone: "destructive", label: "期限超過" },
|
|
59
|
+
{ value: 1, tone: "warning", label: "期限間近" },
|
|
60
|
+
{ value: 6, tone: "success", label: "対応済" },
|
|
61
|
+
]}
|
|
62
|
+
label="みどり農産株式会社(0 件のスライスは幅 0)"
|
|
63
|
+
/>
|
|
64
|
+
</Flex>
|
|
65
|
+
</CardContent>
|
|
66
|
+
</Card>
|
|
67
|
+
|
|
36
68
|
<Card>
|
|
37
69
|
<CardHeader>
|
|
38
70
|
<CardTitle level={2}>Over capacity</CardTitle>
|
|
@@ -11,12 +11,12 @@ import {
|
|
|
11
11
|
ScrollBar,
|
|
12
12
|
} from "@godxjp/ui/data-display";
|
|
13
13
|
import { Button, Text } from "@godxjp/ui/general";
|
|
14
|
-
import { Flex, PageContainer } from "@godxjp/ui/layout";
|
|
14
|
+
import { Flex, PageContainer, ResponsiveGrid } from "@godxjp/ui/layout";
|
|
15
15
|
|
|
16
16
|
/**
|
|
17
17
|
* ScrollArea — custom scrollbar container. ALWAYS set an explicit height/max-height
|
|
18
18
|
* (vertical) or width (horizontal) on the wrapper or the scrollbar never appears.
|
|
19
|
-
* `type` controls when the bar is visible; `
|
|
19
|
+
* `type` controls when the bar is visible; `ScrollArea orientation="horizontal"`
|
|
20
20
|
* adds a horizontal bar. Composed only from real @godxjp/ui components.
|
|
21
21
|
*/
|
|
22
22
|
const entries = Array.from(
|
|
@@ -244,31 +244,37 @@ export default function Demo() {
|
|
|
244
244
|
|
|
245
245
|
<Card>
|
|
246
246
|
<CardHeader>
|
|
247
|
-
<CardTitle level={2}>
|
|
248
|
-
|
|
249
|
-
</CardTitle>
|
|
250
|
-
<CardDescription>
|
|
251
|
-
横方向のバーは明示的に ScrollBar
|
|
252
|
-
を子要素として配置します。中身は幅を指定して溢れさせます。
|
|
253
|
-
</CardDescription>
|
|
247
|
+
<CardTitle level={2}>ScrollArea</CardTitle>
|
|
248
|
+
<CardDescription>orientation="horizontal"</CardDescription>
|
|
254
249
|
</CardHeader>
|
|
255
250
|
<CardContent>
|
|
256
|
-
<
|
|
257
|
-
<
|
|
258
|
-
|
|
259
|
-
<
|
|
260
|
-
<
|
|
261
|
-
{
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
251
|
+
<ScrollArea orientation="horizontal" type="always">
|
|
252
|
+
<ResponsiveGrid flow="columns">
|
|
253
|
+
{columns.map((column) => (
|
|
254
|
+
<Card key={column}>
|
|
255
|
+
<CardContent solo>
|
|
256
|
+
<Text tabular>{column}</Text>
|
|
257
|
+
</CardContent>
|
|
258
|
+
</Card>
|
|
259
|
+
))}
|
|
260
|
+
</ResponsiveGrid>
|
|
261
|
+
</ScrollArea>
|
|
262
|
+
</CardContent>
|
|
263
|
+
</Card>
|
|
264
|
+
|
|
265
|
+
<Card>
|
|
266
|
+
<CardHeader>
|
|
267
|
+
<CardTitle level={2}>個別の ScrollBar を追加する</CardTitle>
|
|
268
|
+
</CardHeader>
|
|
269
|
+
<CardContent>
|
|
270
|
+
<ScrollArea type="always">
|
|
271
|
+
<ResponsiveGrid flow="columns">
|
|
272
|
+
{columns.map((column) => (
|
|
273
|
+
<Text key={column}>{column}</Text>
|
|
274
|
+
))}
|
|
275
|
+
</ResponsiveGrid>
|
|
276
|
+
<ScrollBar orientation="horizontal" />
|
|
277
|
+
</ScrollArea>
|
|
272
278
|
</CardContent>
|
|
273
279
|
</Card>
|
|
274
280
|
|
|
@@ -46,31 +46,31 @@ export default function Demo() {
|
|
|
46
46
|
<TableHeader>
|
|
47
47
|
<TableRow>
|
|
48
48
|
<TableHead>勘定科目</TableHead>
|
|
49
|
-
<TableHead
|
|
50
|
-
<TableHead
|
|
49
|
+
<TableHead align="end">借方</TableHead>
|
|
50
|
+
<TableHead align="end">貸方</TableHead>
|
|
51
51
|
</TableRow>
|
|
52
52
|
</TableHeader>
|
|
53
53
|
<TableBody>
|
|
54
54
|
<TableRow>
|
|
55
55
|
<TableCell>売掛金</TableCell>
|
|
56
|
-
<TableCell
|
|
57
|
-
<TableCell
|
|
56
|
+
<TableCell numeric>¥482,000</TableCell>
|
|
57
|
+
<TableCell align="end">—</TableCell>
|
|
58
58
|
</TableRow>
|
|
59
59
|
{/* Built-in selected-row state — data-[state=selected]:bg-primary/[0.06]. */}
|
|
60
60
|
<TableRow data-state="selected">
|
|
61
61
|
<TableCell>売上高</TableCell>
|
|
62
|
-
<TableCell
|
|
63
|
-
<TableCell
|
|
62
|
+
<TableCell align="end">—</TableCell>
|
|
63
|
+
<TableCell numeric>¥438,182</TableCell>
|
|
64
64
|
</TableRow>
|
|
65
65
|
<TableRow>
|
|
66
66
|
<TableCell>仮受消費税</TableCell>
|
|
67
|
-
<TableCell
|
|
68
|
-
<TableCell
|
|
67
|
+
<TableCell align="end">—</TableCell>
|
|
68
|
+
<TableCell numeric>¥43,818</TableCell>
|
|
69
69
|
</TableRow>
|
|
70
70
|
<TableRow className="font-medium">
|
|
71
71
|
<TableCell>合計</TableCell>
|
|
72
|
-
<TableCell
|
|
73
|
-
<TableCell
|
|
72
|
+
<TableCell numeric>¥482,000</TableCell>
|
|
73
|
+
<TableCell numeric>¥482,000</TableCell>
|
|
74
74
|
</TableRow>
|
|
75
75
|
</TableBody>
|
|
76
76
|
</Table>
|
|
@@ -90,41 +90,41 @@ export default function Demo() {
|
|
|
90
90
|
<TableHeader>
|
|
91
91
|
<TableRow>
|
|
92
92
|
<TableHead>勘定科目</TableHead>
|
|
93
|
-
<TableHead
|
|
94
|
-
<TableHead
|
|
95
|
-
<TableHead
|
|
96
|
-
<TableHead
|
|
97
|
-
<TableHead
|
|
98
|
-
<TableHead
|
|
99
|
-
<TableHead
|
|
100
|
-
<TableHead
|
|
101
|
-
<TableHead
|
|
93
|
+
<TableHead align="end">1月</TableHead>
|
|
94
|
+
<TableHead align="end">2月</TableHead>
|
|
95
|
+
<TableHead align="end">3月</TableHead>
|
|
96
|
+
<TableHead align="end">4月</TableHead>
|
|
97
|
+
<TableHead align="end">5月</TableHead>
|
|
98
|
+
<TableHead align="end">6月</TableHead>
|
|
99
|
+
<TableHead align="end">7月</TableHead>
|
|
100
|
+
<TableHead align="end">8月</TableHead>
|
|
101
|
+
<TableHead align="end">9月</TableHead>
|
|
102
102
|
</TableRow>
|
|
103
103
|
</TableHeader>
|
|
104
104
|
<TableBody>
|
|
105
105
|
<TableRow>
|
|
106
106
|
<TableCell>売上高</TableCell>
|
|
107
|
-
<TableCell
|
|
108
|
-
<TableCell
|
|
109
|
-
<TableCell
|
|
110
|
-
<TableCell
|
|
111
|
-
<TableCell
|
|
112
|
-
<TableCell
|
|
113
|
-
<TableCell
|
|
114
|
-
<TableCell
|
|
115
|
-
<TableCell
|
|
107
|
+
<TableCell numeric>¥412,000</TableCell>
|
|
108
|
+
<TableCell numeric>¥438,182</TableCell>
|
|
109
|
+
<TableCell numeric>¥455,900</TableCell>
|
|
110
|
+
<TableCell numeric>¥471,300</TableCell>
|
|
111
|
+
<TableCell numeric>¥482,000</TableCell>
|
|
112
|
+
<TableCell numeric>¥499,540</TableCell>
|
|
113
|
+
<TableCell numeric>¥510,200</TableCell>
|
|
114
|
+
<TableCell numeric>¥528,770</TableCell>
|
|
115
|
+
<TableCell numeric>¥541,090</TableCell>
|
|
116
116
|
</TableRow>
|
|
117
117
|
<TableRow>
|
|
118
118
|
<TableCell>売上原価</TableCell>
|
|
119
|
-
<TableCell
|
|
120
|
-
<TableCell
|
|
121
|
-
<TableCell
|
|
122
|
-
<TableCell
|
|
123
|
-
<TableCell
|
|
124
|
-
<TableCell
|
|
125
|
-
<TableCell
|
|
126
|
-
<TableCell
|
|
127
|
-
<TableCell
|
|
119
|
+
<TableCell numeric>¥206,000</TableCell>
|
|
120
|
+
<TableCell numeric>¥219,091</TableCell>
|
|
121
|
+
<TableCell numeric>¥227,950</TableCell>
|
|
122
|
+
<TableCell numeric>¥235,650</TableCell>
|
|
123
|
+
<TableCell numeric>¥241,000</TableCell>
|
|
124
|
+
<TableCell numeric>¥249,770</TableCell>
|
|
125
|
+
<TableCell numeric>¥255,100</TableCell>
|
|
126
|
+
<TableCell numeric>¥264,385</TableCell>
|
|
127
|
+
<TableCell numeric>¥270,545</TableCell>
|
|
128
128
|
</TableRow>
|
|
129
129
|
</TableBody>
|
|
130
130
|
</Table>
|
|
@@ -150,23 +150,23 @@ export default function Demo() {
|
|
|
150
150
|
<TableRow>
|
|
151
151
|
<TableHead>倉庫</TableHead>
|
|
152
152
|
<TableHead>伝票番号</TableHead>
|
|
153
|
-
<TableHead
|
|
153
|
+
<TableHead align="end">個数</TableHead>
|
|
154
154
|
</TableRow>
|
|
155
155
|
</TableHeader>
|
|
156
156
|
<TableBody>
|
|
157
157
|
<TableRow>
|
|
158
158
|
<TableCell rowSpan={2}>東京第一</TableCell>
|
|
159
159
|
<TableCell>SH-2026-0412</TableCell>
|
|
160
|
-
<TableCell
|
|
160
|
+
<TableCell numeric>18</TableCell>
|
|
161
161
|
</TableRow>
|
|
162
162
|
<TableRow>
|
|
163
163
|
<TableCell>SH-2026-0413</TableCell>
|
|
164
|
-
<TableCell
|
|
164
|
+
<TableCell numeric>6</TableCell>
|
|
165
165
|
</TableRow>
|
|
166
166
|
<TableRow>
|
|
167
167
|
<TableCell>大阪南</TableCell>
|
|
168
168
|
<TableCell>SH-2026-0414</TableCell>
|
|
169
|
-
<TableCell
|
|
169
|
+
<TableCell numeric>24</TableCell>
|
|
170
170
|
</TableRow>
|
|
171
171
|
</TableBody>
|
|
172
172
|
</Table>
|
|
@@ -187,14 +187,14 @@ export default function Demo() {
|
|
|
187
187
|
<TableRow>
|
|
188
188
|
<TableHead>倉庫</TableHead>
|
|
189
189
|
<TableHead>伝票番号</TableHead>
|
|
190
|
-
<TableHead
|
|
190
|
+
<TableHead align="end">個数</TableHead>
|
|
191
191
|
</TableRow>
|
|
192
192
|
</TableHeader>
|
|
193
193
|
<TableBody>
|
|
194
194
|
<TableRow>
|
|
195
195
|
<TableCell>東京第一</TableCell>
|
|
196
196
|
<TableCell>SH-2026-0412</TableCell>
|
|
197
|
-
<TableCell
|
|
197
|
+
<TableCell numeric>18</TableCell>
|
|
198
198
|
</TableRow>
|
|
199
199
|
</TableBody>
|
|
200
200
|
</Table>
|
|
@@ -217,14 +217,73 @@ export default function Demo() {
|
|
|
217
217
|
<TableRow>
|
|
218
218
|
<TableHead>倉庫</TableHead>
|
|
219
219
|
<TableHead>伝票番号</TableHead>
|
|
220
|
-
<TableHead
|
|
220
|
+
<TableHead align="end">個数</TableHead>
|
|
221
221
|
</TableRow>
|
|
222
222
|
</TableHeader>
|
|
223
223
|
<TableBody>
|
|
224
224
|
<TableRow>
|
|
225
225
|
<TableCell>東京第一</TableCell>
|
|
226
226
|
<TableCell>SH-2026-0412</TableCell>
|
|
227
|
-
<TableCell
|
|
227
|
+
<TableCell numeric>18</TableCell>
|
|
228
|
+
</TableRow>
|
|
229
|
+
</TableBody>
|
|
230
|
+
</Table>
|
|
231
|
+
</CardContent>
|
|
232
|
+
</Card>
|
|
233
|
+
|
|
234
|
+
{/* ── The COLUMN AXES (gh#410) ──────────────────────────────────────
|
|
235
|
+
align · numeric · wrap · width. Every one of these was a className before, and the
|
|
236
|
+
alignment utility the catalog recommended was a physical direction this package lints
|
|
237
|
+
against. `wrap` is the one that is not cosmetic: a cell is `white-space: nowrap` by
|
|
238
|
+
default (right for a data grid) and that inherits into everything it holds, so a
|
|
239
|
+
free-text column can never break without it. */}
|
|
240
|
+
<Card>
|
|
241
|
+
<CardHeader>
|
|
242
|
+
<CardTitle level={2}>問い合わせ一覧 · column axes</CardTitle>
|
|
243
|
+
<CardDescription>
|
|
244
|
+
`width` fixes the id and status columns; the free-text subject takes `wrap` so a long
|
|
245
|
+
Japanese title breaks inside its cell instead of stretching the table into a scroll;
|
|
246
|
+
the count column takes `numeric`, which is tabular figures and end alignment as one
|
|
247
|
+
concept, and the status column takes `align="center"`.
|
|
248
|
+
</CardDescription>
|
|
249
|
+
</CardHeader>
|
|
250
|
+
<CardContent flush>
|
|
251
|
+
<Table>
|
|
252
|
+
<TableHeader>
|
|
253
|
+
<TableRow>
|
|
254
|
+
<TableHead width="7rem">受付番号</TableHead>
|
|
255
|
+
<TableHead wrap>件名</TableHead>
|
|
256
|
+
<TableHead width="6rem" align="center">
|
|
257
|
+
状態
|
|
258
|
+
</TableHead>
|
|
259
|
+
<TableHead width="5rem" numeric>
|
|
260
|
+
返信
|
|
261
|
+
</TableHead>
|
|
262
|
+
</TableRow>
|
|
263
|
+
</TableHeader>
|
|
264
|
+
<TableBody>
|
|
265
|
+
<TableRow>
|
|
266
|
+
<TableCell>INQ-2026-0188</TableCell>
|
|
267
|
+
<TableCell wrap>
|
|
268
|
+
請求書の宛名を法人名から屋号に変更したいのですが、過去分もまとめて再発行できますか
|
|
269
|
+
</TableCell>
|
|
270
|
+
<TableCell align="center">対応中</TableCell>
|
|
271
|
+
<TableCell numeric>3</TableCell>
|
|
272
|
+
</TableRow>
|
|
273
|
+
<TableRow>
|
|
274
|
+
<TableCell>INQ-2026-0189</TableCell>
|
|
275
|
+
<TableCell wrap>
|
|
276
|
+
ログイン時の二要素認証コードが届かない端末があるため、SMS
|
|
277
|
+
から認証アプリへ切り替える手順を知りたい
|
|
278
|
+
</TableCell>
|
|
279
|
+
<TableCell align="center">未対応</TableCell>
|
|
280
|
+
<TableCell numeric>0</TableCell>
|
|
281
|
+
</TableRow>
|
|
282
|
+
<TableRow>
|
|
283
|
+
<TableCell>INQ-2026-0190</TableCell>
|
|
284
|
+
<TableCell wrap>API のレート制限について</TableCell>
|
|
285
|
+
<TableCell align="center">完了</TableCell>
|
|
286
|
+
<TableCell numeric>12</TableCell>
|
|
228
287
|
</TableRow>
|
|
229
288
|
</TableBody>
|
|
230
289
|
</Table>
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { useTranslation } from "@godxjp/ui/i18n";
|
|
1
2
|
import {
|
|
2
3
|
Card,
|
|
3
4
|
CardContent,
|
|
@@ -5,6 +6,7 @@ import {
|
|
|
5
6
|
CardHeader,
|
|
6
7
|
CardTitle,
|
|
7
8
|
Timeline,
|
|
9
|
+
RangeTimeline,
|
|
8
10
|
type TimelineItem,
|
|
9
11
|
} from "@godxjp/ui/data-display";
|
|
10
12
|
import { Flex, PageContainer } from "@godxjp/ui/layout";
|
|
@@ -52,6 +54,11 @@ const approvalItems: TimelineItem[] = [
|
|
|
52
54
|
];
|
|
53
55
|
|
|
54
56
|
export default function Demo() {
|
|
57
|
+
const { t, locale } = useTranslation();
|
|
58
|
+
const dayLabel = (day: number) =>
|
|
59
|
+
new Intl.DateTimeFormat(locale, { month: "short", day: "numeric", timeZone: "UTC" }).format(
|
|
60
|
+
Date.UTC(2026, 8, day),
|
|
61
|
+
);
|
|
55
62
|
return (
|
|
56
63
|
<PageContainer title="Timeline" subtitle="現在のステップを強調する縦型のイベント一覧">
|
|
57
64
|
<Flex direction="col" gap="lg">
|
|
@@ -106,6 +113,40 @@ export default function Demo() {
|
|
|
106
113
|
<Timeline variant="status" items={approvalItems} />
|
|
107
114
|
</CardContent>
|
|
108
115
|
</Card>
|
|
116
|
+
<Card>
|
|
117
|
+
<CardHeader>
|
|
118
|
+
<CardTitle level={2}>RangeTimeline</CardTitle>
|
|
119
|
+
</CardHeader>
|
|
120
|
+
<CardContent>
|
|
121
|
+
<RangeTimeline
|
|
122
|
+
label={t("rangeTimeline.schedule")}
|
|
123
|
+
bands={[
|
|
124
|
+
{
|
|
125
|
+
label: new Intl.DateTimeFormat(locale, {
|
|
126
|
+
year: "numeric",
|
|
127
|
+
month: "long",
|
|
128
|
+
timeZone: "UTC",
|
|
129
|
+
}).format(Date.UTC(2026, 8, 1)),
|
|
130
|
+
units: 7,
|
|
131
|
+
},
|
|
132
|
+
]}
|
|
133
|
+
columns={Array.from({ length: 7 }, (_, index) => ({
|
|
134
|
+
label: dayLabel(index + 1),
|
|
135
|
+
units: 1,
|
|
136
|
+
}))}
|
|
137
|
+
rows={[
|
|
138
|
+
{
|
|
139
|
+
id: "example",
|
|
140
|
+
label: "期日確認",
|
|
141
|
+
start: 1,
|
|
142
|
+
end: 4,
|
|
143
|
+
startLabel: dayLabel(2),
|
|
144
|
+
endLabel: dayLabel(5),
|
|
145
|
+
},
|
|
146
|
+
]}
|
|
147
|
+
/>
|
|
148
|
+
</CardContent>
|
|
149
|
+
</Card>
|
|
109
150
|
</Flex>
|
|
110
151
|
</PageContainer>
|
|
111
152
|
);
|