@serendie/ui 2.3.0-dev.202512090256 → 2.3.0-dev.202601080645

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 CHANGED
@@ -79,7 +79,7 @@ export default function ClientComponent() {
79
79
 
80
80
  ### テーマ切り替え
81
81
 
82
- Serendie Design Systemには5つのカラーテーマがあり、デザイントークンもそれに対応します。htmlタグなどに、`data-panda-theme`属性 (`konjo`, `asagi`, `sumire`, `tsutusji`, `kurikawa`)を付与することでカラーテーマを切り替えることができます。
82
+ Serendie Design Systemには5つのカラーテーマがあり、デザイントークンもそれに対応します。htmlタグなどに、`data-panda-theme`属性 (`konjo`, `asagi`, `sumire`, `tsutsuji`, `kurikawa`)を付与することでカラーテーマを切り替えることができます。
83
83
  各テーマについては[こちら](https://serendie.design/foundations/theming/)を参照してください。
84
84
 
85
85
  ```html
@@ -1,4 +1,5 @@
1
- import { default as React } from 'react';
1
+ import { default as React, ComponentProps } from 'react';
2
+ import { RecipeVariantProps } from '../../../styled-system/types';
2
3
  export declare const ButtonStyle: import('../../../styled-system/types').RecipeRuntimeFn<{
3
4
  styleType: {
4
5
  filled: {
@@ -112,9 +113,19 @@ export declare const ButtonStyle: import('../../../styled-system/types').RecipeR
112
113
  };
113
114
  };
114
115
  }>;
116
+ type ExclusiveIconProps = ({
117
+ leftIcon?: React.ReactElement;
118
+ } & {
119
+ rightIcon?: never;
120
+ }) | ({
121
+ leftIcon?: never;
122
+ } & {
123
+ rightIcon?: React.ReactElement;
124
+ });
115
125
  type ButtonLoadingProps = {
116
126
  isLoading?: boolean;
117
127
  };
128
+ export type ButtonProps = ComponentProps<"button"> & RecipeVariantProps<typeof ButtonStyle> & ExclusiveIconProps & ButtonLoadingProps;
118
129
  export declare const Button: React.ForwardRefExoticComponent<(Omit<React.ClassAttributes<HTMLButtonElement> & React.ButtonHTMLAttributes<HTMLButtonElement> & {
119
130
  styleType?: "filled" | "outlined" | "ghost" | "rectangle" | undefined;
120
131
  size?: "small" | "medium" | undefined;
@@ -1,85 +1,86 @@
1
- import { jsx as e, jsxs as a, Fragment as v } from "react/jsx-runtime";
2
- import { SerendieSymbolCalendar as O, SerendieSymbolArrowRight as j, SerendieSymbolChevronDown as H, SerendieSymbolChevronLeft as V, SerendieSymbolChevronRight as A } from "@serendie/symbols";
3
- import { forwardRef as L, useState as q } from "react";
4
- import { datePickerStyles as x } from "./styles.js";
5
- import { textFieldRecipe as D } from "../../recipes/textFieldRecipe.js";
6
- import { Portal as B } from "../../node_modules/@ark-ui/react/dist/components/portal/portal.js";
7
- import { DatePickerRoot as b } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-root.js";
8
- import { DatePickerLabel as J } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-label.js";
9
- import { DatePickerControl as Y } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-control.js";
10
- import { cx as h } from "../../styled-system/css/cx.js";
11
- import { DatePickerTrigger as _ } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-trigger.js";
1
+ import { jsx as e, jsxs as i, Fragment as x } from "react/jsx-runtime";
2
+ import { SerendieSymbolCalendar as q, SerendieSymbolArrowRight as A, SerendieSymbolChevronDown as L, SerendieSymbolChevronLeft as B, SerendieSymbolChevronRight as J } from "@serendie/symbols";
3
+ import { forwardRef as Y, useState as _ } from "react";
4
+ import { datePickerStyles as T } from "./styles.js";
5
+ import { textFieldRecipe as b } from "../../recipes/textFieldRecipe.js";
6
+ import { useTranslations as z } from "../../i18n/index.js";
7
+ import { Portal as E } from "../../node_modules/@ark-ui/react/dist/components/portal/portal.js";
8
+ import { DatePickerRoot as y } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-root.js";
9
+ import { DatePickerLabel as G } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-label.js";
10
+ import { DatePickerControl as K } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-control.js";
11
+ import { cx as f } from "../../styled-system/css/cx.js";
12
+ import { DatePickerTrigger as Q } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-trigger.js";
12
13
  import { css as t } from "../../styled-system/css/css.js";
13
- import { DatePickerInput as f } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-input.js";
14
- import { DatePickerPositioner as z } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-positioner.js";
15
- import { DatePickerContent as E } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-content.js";
16
- import { DatePickerView as G } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-view.js";
17
- import { DatePickerContext as K } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-context.js";
18
- import { DatePickerViewControl as Q } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-view-control.js";
19
- import { DatePickerYearSelect as U } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-year-select.js";
20
- import { DatePickerPrevTrigger as X } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-prev-trigger.js";
21
- import { DatePickerMonthSelect as Z } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-month-select.js";
22
- import { DatePickerNextTrigger as $ } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-next-trigger.js";
23
- import { DatePickerTable as M } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-table.js";
24
- import { DatePickerTableHead as ee } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-table-head.js";
25
- import { DatePickerTableRow as y } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-table-row.js";
26
- import { DatePickerTableHeader as re } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-table-header.js";
27
- import { DatePickerTableBody as ie } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-table-body.js";
28
- import { DatePickerTableCell as ae } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-table-cell.js";
29
- import { DatePickerTableCellTrigger as te } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-table-cell-trigger.js";
30
- const je = L(
14
+ import { DatePickerInput as P } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-input.js";
15
+ import { DatePickerPositioner as U } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-positioner.js";
16
+ import { DatePickerContent as X } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-content.js";
17
+ import { DatePickerView as Z } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-view.js";
18
+ import { DatePickerContext as $ } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-context.js";
19
+ import { DatePickerViewControl as M } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-view-control.js";
20
+ import { DatePickerYearSelect as ee } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-year-select.js";
21
+ import { DatePickerPrevTrigger as re } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-prev-trigger.js";
22
+ import { DatePickerMonthSelect as ae } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-month-select.js";
23
+ import { DatePickerNextTrigger as ie } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-next-trigger.js";
24
+ import { DatePickerTable as te } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-table.js";
25
+ import { DatePickerTableHead as oe } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-table-head.js";
26
+ import { DatePickerTableRow as C } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-table-row.js";
27
+ import { DatePickerTableHeader as le } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-table-header.js";
28
+ import { DatePickerTableBody as se } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-table-body.js";
29
+ import { DatePickerTableCell as ne } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-table-cell.js";
30
+ import { DatePickerTableCellTrigger as ce } from "../../node_modules/@ark-ui/react/dist/components/date-picker/date-picker-table-cell-trigger.js";
31
+ const Be = Y(
31
32
  ({
32
- placeholder: r = "日付を選択",
33
+ placeholder: r,
33
34
  label: o,
34
35
  required: l,
35
36
  requiredLabel: s,
36
37
  invalid: n,
37
- invalidMessage: c,
38
- selectionMode: p = "single",
39
- startPlaceholder: S = "開始日",
40
- endPlaceholder: T = "終了日",
41
- locale: P = "ja-JP",
42
- isCalendarOnly: w = !1,
43
- ...m
44
- }, N) => {
45
- const R = x(), [F, I] = D.splitVariantProps({
46
- ...m
47
- }), i = D(F), [g, d] = q(!1), W = p === "range";
48
- return w ? /* @__PURE__ */ e(
49
- b,
38
+ invalidMessage: m,
39
+ selectionMode: h = "single",
40
+ startPlaceholder: S,
41
+ endPlaceholder: w,
42
+ locale: u = "ja-JP",
43
+ isCalendarOnly: R = !1,
44
+ ...c
45
+ }, k) => {
46
+ const d = z(), F = r ?? d("datePicker.selectDate"), I = S ?? d("datePicker.startDate"), W = w ?? d("datePicker.endDate"), O = T(), [j, H] = b.splitVariantProps({
47
+ ...c
48
+ }), a = b(j), [N, p] = _(!1), V = h === "range";
49
+ return R ? /* @__PURE__ */ e(
50
+ y,
50
51
  {
51
- locale: P,
52
- ...I,
53
- ref: N,
54
- selectionMode: p,
52
+ locale: u,
53
+ ...H,
54
+ ref: k,
55
+ selectionMode: h,
55
56
  open: !0,
56
- className: i.root,
57
- children: /* @__PURE__ */ e(C, {})
57
+ className: a.root,
58
+ children: /* @__PURE__ */ e(v, {})
58
59
  }
59
- ) : /* @__PURE__ */ a(
60
- b,
60
+ ) : /* @__PURE__ */ i(
61
+ y,
61
62
  {
62
- locale: P,
63
- ...m,
64
- ref: N,
65
- selectionMode: p,
66
- className: i.root,
67
- open: g,
68
- onOpenChange: (u) => {
69
- var k;
70
- d(u.open), (k = m.onOpenChange) == null || k.call(m, u);
63
+ locale: u,
64
+ ...c,
65
+ ref: k,
66
+ selectionMode: h,
67
+ className: a.root,
68
+ open: N,
69
+ onOpenChange: (g) => {
70
+ var D;
71
+ p(g.open), (D = c.onOpenChange) == null || D.call(c, g);
71
72
  },
72
73
  children: [
73
- /* @__PURE__ */ a(v, { children: [
74
- o && /* @__PURE__ */ a(J, { className: i.label, children: [
74
+ /* @__PURE__ */ i(x, { children: [
75
+ o && /* @__PURE__ */ i(G, { className: a.label, children: [
75
76
  o,
76
- l && /* @__PURE__ */ e("span", { className: i.labelRequired, children: s ?? "必須" })
77
+ l && /* @__PURE__ */ e("span", { className: a.labelRequired, children: s ?? d("common.required") })
77
78
  ] }),
78
- /* @__PURE__ */ a(
79
- Y,
79
+ /* @__PURE__ */ i(
80
+ K,
80
81
  {
81
- className: h(
82
- i.inputWrapper,
82
+ className: f(
83
+ a.inputWrapper,
83
84
  t({
84
85
  _expanded: {
85
86
  outlineWidth: "sd.system.dimension.border.thick",
@@ -87,11 +88,11 @@ const je = L(
87
88
  }
88
89
  })
89
90
  ),
90
- "data-expanded": g ? !0 : void 0,
91
+ "data-expanded": N ? !0 : void 0,
91
92
  "data-Invalid": n,
92
93
  children: [
93
- /* @__PURE__ */ e("div", { className: i.leftContent, children: /* @__PURE__ */ e(_, { className: t({ display: "flex" }), children: /* @__PURE__ */ e(O, {}) }) }),
94
- W ? /* @__PURE__ */ a(
94
+ /* @__PURE__ */ e("div", { className: a.leftContent, children: /* @__PURE__ */ e(Q, { className: t({ display: "flex" }), children: /* @__PURE__ */ e(q, {}) }) }),
95
+ V ? /* @__PURE__ */ i(
95
96
  "div",
96
97
  {
97
98
  className: t({
@@ -101,69 +102,69 @@ const je = L(
101
102
  }),
102
103
  children: [
103
104
  /* @__PURE__ */ e(
104
- f,
105
+ P,
105
106
  {
106
107
  index: 0,
107
- placeholder: S,
108
- className: h(
109
- i.input,
108
+ placeholder: I,
109
+ className: f(
110
+ a.input,
110
111
  t({
111
112
  minWidth: "100%",
112
113
  borderRadius: "sd.system.dimension.radius.medium"
113
114
  })
114
115
  ),
115
- onFocus: () => d(!0)
116
+ onFocus: () => p(!0)
116
117
  }
117
118
  ),
118
- /* @__PURE__ */ e(j, {}),
119
+ /* @__PURE__ */ e(A, {}),
119
120
  /* @__PURE__ */ e(
120
- f,
121
+ P,
121
122
  {
122
123
  index: 1,
123
- placeholder: T,
124
- className: h(
125
- i.input,
124
+ placeholder: W,
125
+ className: f(
126
+ a.input,
126
127
  t({
127
128
  minWidth: "100%",
128
129
  borderRadius: "sd.system.dimension.radius.medium"
129
130
  })
130
131
  ),
131
- onFocus: () => d(!0)
132
+ onFocus: () => p(!0)
132
133
  }
133
134
  )
134
135
  ]
135
136
  }
136
137
  ) : /* @__PURE__ */ e(
137
- f,
138
+ P,
138
139
  {
139
- placeholder: r,
140
- className: i.input,
141
- onFocus: () => d(!0)
140
+ placeholder: F,
141
+ className: a.input,
142
+ onFocus: () => p(!0)
142
143
  }
143
144
  ),
144
145
  /* @__PURE__ */ e("div", {})
145
146
  ]
146
147
  }
147
148
  ),
148
- n && c && /* @__PURE__ */ e("div", { className: i.messageField, children: /* @__PURE__ */ e("p", { className: i.invalidMessage, children: c }) })
149
+ n && m && /* @__PURE__ */ e("div", { className: a.messageField, children: /* @__PURE__ */ e("p", { className: a.invalidMessage, children: m }) })
149
150
  ] }),
150
- /* @__PURE__ */ e(B, { children: /* @__PURE__ */ e(z, { className: R.positioner, children: /* @__PURE__ */ e(C, {}) }) })
151
+ /* @__PURE__ */ e(E, { children: /* @__PURE__ */ e(U, { className: O.positioner, children: /* @__PURE__ */ e(v, {}) }) })
151
152
  ]
152
153
  }
153
154
  );
154
155
  }
155
- ), C = () => {
156
- const r = x();
157
- return /* @__PURE__ */ e(E, { className: r.content, children: /* @__PURE__ */ e(G, { view: "day", className: r.view, children: /* @__PURE__ */ e(K, { children: (o) => /* @__PURE__ */ a(v, { children: [
158
- /* @__PURE__ */ a(Q, { className: r.viewControl, children: [
159
- /* @__PURE__ */ a("div", { className: r.selectWrapper, children: [
160
- /* @__PURE__ */ e(U, { className: r.select }),
161
- /* @__PURE__ */ e(H, { className: r.selectIcon })
156
+ ), v = () => {
157
+ const r = T();
158
+ return /* @__PURE__ */ e(X, { className: r.content, children: /* @__PURE__ */ e(Z, { view: "day", className: r.view, children: /* @__PURE__ */ e($, { children: (o) => /* @__PURE__ */ i(x, { children: [
159
+ /* @__PURE__ */ i(M, { className: r.viewControl, children: [
160
+ /* @__PURE__ */ i("div", { className: r.selectWrapper, children: [
161
+ /* @__PURE__ */ e(ee, { className: r.select }),
162
+ /* @__PURE__ */ e(L, { className: r.selectIcon })
162
163
  ] }),
163
- /* @__PURE__ */ a("div", { className: t({ display: "flex", alignItems: "center" }), children: [
164
- /* @__PURE__ */ e(X, { className: r.prevTrigger, children: /* @__PURE__ */ e(V, {}) }),
164
+ /* @__PURE__ */ i("div", { className: t({ display: "flex", alignItems: "center" }), children: [
165
+ /* @__PURE__ */ e(re, { className: r.prevTrigger, children: /* @__PURE__ */ e(B, {}) }),
165
166
  /* @__PURE__ */ e(
166
- Z,
167
+ ae,
167
168
  {
168
169
  className: t({
169
170
  appearance: "none",
@@ -171,36 +172,36 @@ const je = L(
171
172
  })
172
173
  }
173
174
  ),
174
- /* @__PURE__ */ e($, { className: r.nextTrigger, children: /* @__PURE__ */ e(A, {}) })
175
+ /* @__PURE__ */ e(ie, { className: r.nextTrigger, children: /* @__PURE__ */ e(J, {}) })
175
176
  ] })
176
177
  ] }),
177
- /* @__PURE__ */ a(M, { className: r.table, children: [
178
- /* @__PURE__ */ e(ee, { children: /* @__PURE__ */ e(y, { children: o.weekDays.map((l, s) => /* @__PURE__ */ e(
179
- re,
178
+ /* @__PURE__ */ i(te, { className: r.table, children: [
179
+ /* @__PURE__ */ e(oe, { children: /* @__PURE__ */ e(C, { children: o.weekDays.map((l, s) => /* @__PURE__ */ e(
180
+ le,
180
181
  {
181
182
  className: r.tableHeader,
182
183
  children: l.narrow
183
184
  },
184
185
  s
185
186
  )) }) }),
186
- /* @__PURE__ */ e(ie, { children: o.weeks.map((l, s) => /* @__PURE__ */ e(y, { children: l.map((n, c) => /* @__PURE__ */ e(
187
- ae,
187
+ /* @__PURE__ */ e(se, { children: o.weeks.map((l, s) => /* @__PURE__ */ e(C, { children: l.map((n, m) => /* @__PURE__ */ e(
188
+ ne,
188
189
  {
189
190
  value: n,
190
191
  className: r.tableCell,
191
192
  children: /* @__PURE__ */ e(
192
- te,
193
+ ce,
193
194
  {
194
195
  className: r.tableCellTrigger,
195
196
  children: n.day
196
197
  }
197
198
  )
198
199
  },
199
- c
200
+ m
200
201
  )) }, s)) })
201
202
  ] })
202
203
  ] }) }) }) });
203
204
  };
204
205
  export {
205
- je as DatePicker
206
+ Be as DatePicker
206
207
  };
@@ -1,5 +1,6 @@
1
1
  import { DialogRootProps } from '@ark-ui/react';
2
2
  import { RecipeVariantProps } from '../../../styled-system/css';
3
+ import { ButtonProps } from '../Button';
3
4
  declare const ModalDialogStyle: import('../../../styled-system/types').SlotRecipeRuntimeFn<"title" | "description" | "content" | "backdrop" | "contentInner" | "closeTrigger" | "buttonWrapper", import('../../../styled-system/types').SlotRecipeVariantRecord<"title" | "description" | "content" | "backdrop" | "contentInner" | "closeTrigger" | "buttonWrapper">>;
4
5
  type Props = {
5
6
  isOpen: boolean;
@@ -9,6 +10,7 @@ type Props = {
9
10
  cancelButtonLabel?: string;
10
11
  submitButtonLabel: string;
11
12
  onButtonClick: () => void;
13
+ submitButtonProps?: ButtonProps;
12
14
  };
13
15
  export type ModalDialogProps = Props & DialogRootProps & RecipeVariantProps<typeof ModalDialogStyle>;
14
16
  export declare const ModalDialog: React.FC<ModalDialogProps>;
@@ -1,16 +1,17 @@
1
- import { jsx as e, jsxs as t } from "react/jsx-runtime";
1
+ import { jsx as e, jsxs as o } from "react/jsx-runtime";
2
2
  import { Button as i } from "../Button/Button.js";
3
- import { Portal as c } from "../../node_modules/@ark-ui/react/dist/components/portal/portal.js";
4
- import { sva as g } from "../../styled-system/css/sva.js";
5
- import { DialogRoot as y } from "../../node_modules/@ark-ui/react/dist/components/dialog/dialog-root.js";
6
- import { DialogBackdrop as x } from "../../node_modules/@ark-ui/react/dist/components/dialog/dialog-backdrop.js";
7
- import { DialogPositioner as f } from "../../node_modules/@ark-ui/react/dist/components/dialog/dialog-positioner.js";
8
- import { DialogContent as h } from "../../node_modules/@ark-ui/react/dist/components/dialog/dialog-content.js";
9
- import { cx as u } from "../../styled-system/css/cx.js";
10
- import { DialogTitle as b } from "../../node_modules/@ark-ui/react/dist/components/dialog/dialog-title.js";
11
- import { DialogDescription as D } from "../../node_modules/@ark-ui/react/dist/components/dialog/dialog-description.js";
12
- import { DialogCloseTrigger as v } from "../../node_modules/@ark-ui/react/dist/components/dialog/dialog-close-trigger.js";
13
- const I = g({
3
+ import { useTranslations as y } from "../../i18n/index.js";
4
+ import { Portal as x } from "../../node_modules/@ark-ui/react/dist/components/portal/portal.js";
5
+ import { sva as f } from "../../styled-system/css/sva.js";
6
+ import { DialogRoot as h } from "../../node_modules/@ark-ui/react/dist/components/dialog/dialog-root.js";
7
+ import { DialogBackdrop as u } from "../../node_modules/@ark-ui/react/dist/components/dialog/dialog-backdrop.js";
8
+ import { DialogPositioner as b } from "../../node_modules/@ark-ui/react/dist/components/dialog/dialog-positioner.js";
9
+ import { DialogContent as D } from "../../node_modules/@ark-ui/react/dist/components/dialog/dialog-content.js";
10
+ import { cx as v } from "../../styled-system/css/cx.js";
11
+ import { DialogTitle as I } from "../../node_modules/@ark-ui/react/dist/components/dialog/dialog-title.js";
12
+ import { DialogDescription as k } from "../../node_modules/@ark-ui/react/dist/components/dialog/dialog-description.js";
13
+ import { DialogCloseTrigger as C } from "../../node_modules/@ark-ui/react/dist/components/dialog/dialog-close-trigger.js";
14
+ const N = f({
14
15
  slots: [
15
16
  "backdrop",
16
17
  "content",
@@ -74,31 +75,32 @@ const I = g({
74
75
  }
75
76
  }
76
77
  }
77
- }), R = ({
78
+ }), q = ({
78
79
  isOpen: n,
79
- title: d,
80
- cancelButtonLabel: a,
80
+ title: a,
81
+ cancelButtonLabel: d,
81
82
  submitButtonLabel: r,
82
83
  onButtonClick: m,
84
+ submitButtonProps: l,
83
85
  children: p,
84
- className: l,
85
- ...o
86
+ className: c,
87
+ ...t
86
88
  }) => {
87
- const s = I(o);
88
- return /* @__PURE__ */ e(y, { open: n, ...o, children: /* @__PURE__ */ t(c, { children: [
89
- /* @__PURE__ */ e(x, { className: s.backdrop }),
90
- /* @__PURE__ */ e(f, { children: /* @__PURE__ */ t(h, { className: u(s.content, l), children: [
91
- /* @__PURE__ */ t("div", { className: s.contentInner, children: [
92
- /* @__PURE__ */ e(b, { className: s.title, children: d }),
93
- /* @__PURE__ */ e(D, { className: s.description, children: p })
89
+ const g = y(), s = N(t);
90
+ return /* @__PURE__ */ e(h, { open: n, ...t, children: /* @__PURE__ */ o(x, { children: [
91
+ /* @__PURE__ */ e(u, { className: s.backdrop }),
92
+ /* @__PURE__ */ e(b, { children: /* @__PURE__ */ o(D, { className: v(s.content, c), children: [
93
+ /* @__PURE__ */ o("div", { className: s.contentInner, children: [
94
+ /* @__PURE__ */ e(I, { className: s.title, children: a }),
95
+ /* @__PURE__ */ e(k, { className: s.description, children: p })
94
96
  ] }),
95
- /* @__PURE__ */ t("div", { className: s.buttonWrapper, children: [
96
- /* @__PURE__ */ e(i, { onClick: m, children: r }),
97
- /* @__PURE__ */ e(v, { asChild: !0, children: /* @__PURE__ */ e(i, { styleType: "ghost", children: a || "閉じる" }) })
97
+ /* @__PURE__ */ o("div", { className: s.buttonWrapper, children: [
98
+ /* @__PURE__ */ e(i, { ...l, onClick: m, children: r }),
99
+ /* @__PURE__ */ e(C, { asChild: !0, children: /* @__PURE__ */ e(i, { styleType: "ghost", children: d || g("modalDialog.close") }) })
98
100
  ] })
99
101
  ] }) })
100
102
  ] }) });
101
103
  };
102
104
  export {
103
- R as ModalDialog
105
+ q as ModalDialog
104
106
  };
@@ -1,16 +1,17 @@
1
- import { jsx as e, jsxs as T, Fragment as g } from "react/jsx-runtime";
2
- import { SerendieSymbolChevronLeft as S, SerendieSymbolChevronRight as C } from "@serendie/symbols";
3
- import _, { useState as I } from "react";
1
+ import { jsx as e, jsxs as C, Fragment as c } from "react/jsx-runtime";
2
+ import { SerendieSymbolChevronLeft as _, SerendieSymbolChevronRight as I } from "@serendie/symbols";
3
+ import N, { useState as j } from "react";
4
4
  import { IconButton as m } from "../IconButton/IconButton.js";
5
- import { sva as N } from "../../styled-system/css/sva.js";
6
- import { PaginationRoot as j } from "../../node_modules/@ark-ui/react/dist/components/pagination/pagination-root.js";
7
- import { cx as z } from "../../styled-system/css/cx.js";
8
- import { PaginationContext as R } from "../../node_modules/@ark-ui/react/dist/components/pagination/pagination-context.js";
9
- import { PaginationPrevTrigger as w } from "../../node_modules/@ark-ui/react/dist/components/pagination/pagination-prev-trigger.js";
10
- import { PaginationItem as O } from "../../node_modules/@ark-ui/react/dist/components/pagination/pagination-item.js";
11
- import { PaginationEllipsis as W } from "../../node_modules/@ark-ui/react/dist/components/pagination/pagination-ellipsis.js";
12
- import { PaginationNextTrigger as F } from "../../node_modules/@ark-ui/react/dist/components/pagination/pagination-next-trigger.js";
13
- const L = N({
5
+ import { useTranslations as z } from "../../i18n/index.js";
6
+ import { sva as R } from "../../styled-system/css/sva.js";
7
+ import { PaginationRoot as w } from "../../node_modules/@ark-ui/react/dist/components/pagination/pagination-root.js";
8
+ import { cx as O } from "../../styled-system/css/cx.js";
9
+ import { PaginationContext as W } from "../../node_modules/@ark-ui/react/dist/components/pagination/pagination-context.js";
10
+ import { PaginationPrevTrigger as F } from "../../node_modules/@ark-ui/react/dist/components/pagination/pagination-prev-trigger.js";
11
+ import { PaginationItem as L } from "../../node_modules/@ark-ui/react/dist/components/pagination/pagination-item.js";
12
+ import { PaginationEllipsis as B } from "../../node_modules/@ark-ui/react/dist/components/pagination/pagination-ellipsis.js";
13
+ import { PaginationNextTrigger as E } from "../../node_modules/@ark-ui/react/dist/components/pagination/pagination-next-trigger.js";
14
+ const M = R({
14
15
  slots: ["root", "item", "ellipsis", "prevTrigger", "nextTrigger"],
15
16
  base: {
16
17
  root: {
@@ -80,102 +81,104 @@ const L = N({
80
81
  defaultVariants: {
81
82
  size: "medium"
82
83
  }
83
- }), Q = _.forwardRef(
84
+ }), Z = N.forwardRef(
84
85
  ({
85
86
  count: d,
86
- pageSize: c = 1,
87
- page: o,
88
- onPageChange: n,
89
- siblingCount: p = 2,
90
- className: h,
91
- size: y = "medium",
92
- ...f
93
- }, u) => {
94
- const [b, P] = I(1), i = L({ size: y }), v = {
87
+ pageSize: p = 1,
88
+ page: r,
89
+ onPageChange: l,
90
+ siblingCount: h = 2,
91
+ className: y,
92
+ size: f = "medium",
93
+ ...u
94
+ }, P) => {
95
+ const [b, v] = j(1), a = M({ size: f }), x = (t) => {
96
+ r || v(t.page), l == null || l(t);
97
+ }, i = z(), T = {
95
98
  count: d,
96
- pageSize: c,
97
- siblingCount: p,
98
- ...o ? { page: o } : { page: b },
99
- onPageChange: (t) => {
100
- o || P(t.page), n == null || n(t);
101
- }
99
+ pageSize: p,
100
+ siblingCount: h,
101
+ ...r ? { page: r } : { page: b },
102
+ onPageChange: x
102
103
  };
103
104
  return /* @__PURE__ */ e(
104
- j,
105
+ w,
105
106
  {
106
- ref: u,
107
- className: z(i.root, h),
108
- ...v,
109
- ...f,
110
- children: /* @__PURE__ */ e(R, { children: (t) => {
111
- const r = t.page <= 1, x = Math.ceil(d / c), a = t.page >= x;
112
- return /* @__PURE__ */ T(g, { children: [
107
+ ref: P,
108
+ className: O(a.root, y),
109
+ ...T,
110
+ ...u,
111
+ children: /* @__PURE__ */ e(W, { children: (t) => {
112
+ const n = t.page <= 1, S = Math.ceil(d / p), o = t.page >= S;
113
+ return /* @__PURE__ */ C(c, { children: [
113
114
  /* @__PURE__ */ e(
114
- w,
115
+ F,
115
116
  {
116
- className: i.prevTrigger,
117
- disabled: r,
117
+ className: a.prevTrigger,
118
+ disabled: n,
118
119
  asChild: !0,
119
120
  children: /* @__PURE__ */ e(
120
121
  m,
121
122
  {
122
- icon: /* @__PURE__ */ e(S, {}),
123
+ icon: /* @__PURE__ */ e(_, {}),
123
124
  shape: "rectangle",
124
125
  styleType: "ghost",
125
126
  size: "small",
126
- "aria-label": r ? "最初のページです" : "前のページへ",
127
- disabled: r,
128
- title: r ? "最初のページです" : "前のページへ"
127
+ "aria-label": i(n ? "pagination.firstPage" : "pagination.previousPage"),
128
+ disabled: n,
129
+ title: i(n ? "pagination.firstPage" : "pagination.previousPage")
129
130
  }
130
131
  )
131
132
  }
132
133
  ),
133
134
  t.pages.map(
134
- (s, l) => s.type === "page" ? /* @__PURE__ */ e(
135
- O,
135
+ (s, g) => s.type === "page" ? /* @__PURE__ */ e(
136
+ L,
136
137
  {
137
138
  ...s,
138
- className: i.item,
139
+ className: a.item,
139
140
  asChild: !0,
140
141
  children: /* @__PURE__ */ e(
141
142
  m,
142
143
  {
143
- icon: /* @__PURE__ */ e(g, { children: s.value }),
144
+ icon: /* @__PURE__ */ e(c, { children: s.value }),
144
145
  shape: "rectangle",
145
146
  styleType: "ghost",
146
147
  size: "small",
147
- "aria-label": `ページ${s.value}へ移動`,
148
- title: `ページ${s.value}へ移動`
148
+ "aria-label": i("pagination.goToPage", {
149
+ page: s.value
150
+ }),
151
+ title: i("pagination.goToPage", { page: s.value })
149
152
  }
150
153
  )
151
154
  },
152
- l
155
+ g
153
156
  ) : /* @__PURE__ */ e(
154
- W,
157
+ B,
155
158
  {
156
- index: l,
157
- className: i.ellipsis,
159
+ index: g,
160
+ className: a.ellipsis,
158
161
  children: "…"
159
162
  },
160
- l
163
+ g
161
164
  )
162
165
  ),
163
166
  /* @__PURE__ */ e(
164
- F,
167
+ E,
165
168
  {
166
- className: i.nextTrigger,
167
- disabled: a,
169
+ className: a.nextTrigger,
170
+ disabled: o,
168
171
  asChild: !0,
169
172
  children: /* @__PURE__ */ e(
170
173
  m,
171
174
  {
172
- icon: /* @__PURE__ */ e(C, {}),
175
+ icon: /* @__PURE__ */ e(I, {}),
173
176
  shape: "rectangle",
174
177
  styleType: "ghost",
175
178
  size: "small",
176
- "aria-label": a ? "最後のページです" : "次のページへ",
177
- disabled: a,
178
- title: a ? "最後のページです" : "次のページへ"
179
+ "aria-label": i(o ? "pagination.lastPage" : "pagination.nextPage"),
180
+ disabled: o,
181
+ title: i(o ? "pagination.lastPage" : "pagination.nextPage")
179
182
  }
180
183
  )
181
184
  }
@@ -187,6 +190,6 @@ const L = N({
187
190
  }
188
191
  );
189
192
  export {
190
- Q as Pagination,
191
- L as PaginationStyle
193
+ Z as Pagination,
194
+ M as PaginationStyle
192
195
  };
@@ -1,38 +1,39 @@
1
1
  import { jsx as o } from "react/jsx-runtime";
2
- import { forwardRef as n, useState as d } from "react";
3
- import { TextField as m } from "../TextField/TextField.js";
4
- import { SerendieSymbolEyeHidden as p, SerendieSymbolEye as y } from "@serendie/symbols";
5
- import { IconButton as g } from "../IconButton/IconButton.js";
6
- const w = n(
7
- ({ disableToggle: s = !1, disabled: e, ...r }, i) => {
8
- const [t, l] = d(!1);
2
+ import { forwardRef as m, useState as p } from "react";
3
+ import { TextField as w } from "../TextField/TextField.js";
4
+ import { SerendieSymbolEyeHidden as y, SerendieSymbolEye as c } from "@serendie/symbols";
5
+ import { IconButton as f } from "../IconButton/IconButton.js";
6
+ import { useTranslations as g } from "../../i18n/index.js";
7
+ const P = m(
8
+ ({ disableToggle: r = !1, disabled: t, ...i }, a) => {
9
+ const e = g(), [s, d] = p(!1), l = r ? void 0 : /* @__PURE__ */ o(
10
+ f,
11
+ {
12
+ type: "button",
13
+ onClick: () => {
14
+ d((n) => !n);
15
+ },
16
+ styleType: "ghost",
17
+ size: "small",
18
+ shape: "circle",
19
+ "aria-label": e(s ? "passwordField.hidePassword" : "passwordField.showPassword"),
20
+ disabled: t,
21
+ icon: s ? /* @__PURE__ */ o(y, {}) : /* @__PURE__ */ o(c, {})
22
+ }
23
+ );
9
24
  return /* @__PURE__ */ o(
10
- m,
25
+ w,
11
26
  {
12
- type: t ? "text" : "password",
13
- rightContent: s ? void 0 : /* @__PURE__ */ o(
14
- g,
15
- {
16
- type: "button",
17
- onClick: () => {
18
- l((a) => !a);
19
- },
20
- styleType: "ghost",
21
- size: "small",
22
- shape: "circle",
23
- "aria-label": t ? "パスワードを隠す" : "パスワードを表示",
24
- disabled: e,
25
- icon: t ? /* @__PURE__ */ o(p, {}) : /* @__PURE__ */ o(y, {})
26
- }
27
- ),
28
- disabled: e,
29
- ...r,
30
- ref: i
27
+ type: s ? "text" : "password",
28
+ rightContent: l,
29
+ disabled: t,
30
+ ...i,
31
+ ref: a
31
32
  }
32
33
  );
33
34
  }
34
35
  );
35
- w.displayName = "PasswordField";
36
+ P.displayName = "PasswordField";
36
37
  export {
37
- w as PasswordField
38
+ P as PasswordField
38
39
  };
@@ -1,21 +1,22 @@
1
1
  import { jsxs as i, jsx as e } from "react/jsx-runtime";
2
- import { SerendieSymbolChevronDown as S } from "@serendie/symbols";
3
- import { List as v } from "../List/List.js";
4
- import { ListItem as w } from "../List/ListItem.js";
5
- import { createListCollection as _ } from "../../node_modules/@ark-ui/react/dist/components/collection/list-collection.js";
6
- import { Portal as C } from "../../node_modules/@ark-ui/react/dist/components/portal/portal.js";
7
- import { sva as T } from "../../styled-system/css/sva.js";
8
- import { SelectRoot as N } from "../../node_modules/@ark-ui/react/dist/components/select/select-root.js";
9
- import { cx as z } from "../../styled-system/css/cx.js";
10
- import { SelectLabel as R } from "../../node_modules/@ark-ui/react/dist/components/select/select-label.js";
11
- import { css as d } from "../../styled-system/css/css.js";
12
- import { SelectControl as V } from "../../node_modules/@ark-ui/react/dist/components/select/select-control.js";
13
- import { SelectTrigger as L } from "../../node_modules/@ark-ui/react/dist/components/select/select-trigger.js";
14
- import { SelectValueText as P } from "../../node_modules/@ark-ui/react/dist/components/select/select-value-text.js";
15
- import { SelectPositioner as B } from "../../node_modules/@ark-ui/react/dist/components/select/select-positioner.js";
16
- import { SelectContent as I } from "../../node_modules/@ark-ui/react/dist/components/select/select-content.js";
17
- import { SelectItem as O } from "../../node_modules/@ark-ui/react/dist/components/select/select-item.js";
18
- const l = T({
2
+ import { SerendieSymbolChevronDown as v } from "@serendie/symbols";
3
+ import { List as w } from "../List/List.js";
4
+ import { ListItem as _ } from "../List/ListItem.js";
5
+ import { useTranslations as T } from "../../i18n/index.js";
6
+ import { createListCollection as C } from "../../node_modules/@ark-ui/react/dist/components/collection/list-collection.js";
7
+ import { Portal as N } from "../../node_modules/@ark-ui/react/dist/components/portal/portal.js";
8
+ import { sva as z } from "../../styled-system/css/sva.js";
9
+ import { SelectRoot as R } from "../../node_modules/@ark-ui/react/dist/components/select/select-root.js";
10
+ import { cx as V } from "../../styled-system/css/cx.js";
11
+ import { SelectLabel as L } from "../../node_modules/@ark-ui/react/dist/components/select/select-label.js";
12
+ import { css as r } from "../../styled-system/css/css.js";
13
+ import { SelectControl as P } from "../../node_modules/@ark-ui/react/dist/components/select/select-control.js";
14
+ import { SelectTrigger as B } from "../../node_modules/@ark-ui/react/dist/components/select/select-trigger.js";
15
+ import { SelectValueText as I } from "../../node_modules/@ark-ui/react/dist/components/select/select-value-text.js";
16
+ import { SelectPositioner as O } from "../../node_modules/@ark-ui/react/dist/components/select/select-positioner.js";
17
+ import { SelectContent as j } from "../../node_modules/@ark-ui/react/dist/components/select/select-content.js";
18
+ import { SelectItem as A } from "../../node_modules/@ark-ui/react/dist/components/select/select-item.js";
19
+ const l = z({
19
20
  slots: ["root", "valueText", "trigger", "content", "item", "iconBox"],
20
21
  base: {
21
22
  root: {
@@ -156,9 +157,9 @@ const l = T({
156
157
  defaultVariants: {
157
158
  size: "medium"
158
159
  }
159
- }), M = ({
160
+ }), oe = ({
160
161
  placeholder: c = "",
161
- label: r,
162
+ label: d,
162
163
  required: p,
163
164
  requiredLabel: y,
164
165
  invalid: a,
@@ -167,18 +168,18 @@ const l = T({
167
168
  items: u = [],
168
169
  ...x
169
170
  }) => {
170
- const [t, h] = l.splitVariantProps(x), o = l(t), { collection: j, ...b } = h, n = _({
171
+ const h = T(), [t, b] = l.splitVariantProps(x), o = l(t), { collection: W, ...f } = b, n = C({
171
172
  items: u,
172
173
  itemToString: (s) => s.label,
173
174
  itemToValue: (s) => s.value
174
175
  });
175
176
  return /* @__PURE__ */ i(
176
- N,
177
+ R,
177
178
  {
178
- ...b,
179
+ ...f,
179
180
  collection: n,
180
181
  invalid: a,
181
- className: z(o.root, g),
182
+ className: V(o.root, g),
182
183
  positioning: {
183
184
  sameWidth: !0,
184
185
  offset: {
@@ -187,45 +188,45 @@ const l = T({
187
188
  }
188
189
  },
189
190
  children: [
190
- r && t.size != "small" && // smallの場合はラベルを表示しない
191
+ d && t.size != "small" && // smallの場合はラベルを表示しない
191
192
  /* @__PURE__ */ i(
192
- R,
193
+ L,
193
194
  {
194
- className: d({
195
+ className: r({
195
196
  textStyle: {
196
197
  base: "sd.system.typography.label.medium_compact",
197
198
  expanded: "sd.system.typography.label.medium_expanded"
198
199
  }
199
200
  }),
200
201
  children: [
201
- r,
202
+ d,
202
203
  p && /* @__PURE__ */ e(
203
204
  "span",
204
205
  {
205
- className: d({
206
+ className: r({
206
207
  pl: "sd.system.dimension.spacing.extraSmall",
207
208
  color: "sd.system.color.impression.negative"
208
209
  }),
209
- children: y ?? "必須"
210
+ children: y ?? h("common.required")
210
211
  }
211
212
  )
212
213
  ]
213
214
  }
214
215
  ),
215
- /* @__PURE__ */ e(V, { children: /* @__PURE__ */ i(L, { className: o.trigger, children: [
216
+ /* @__PURE__ */ e(P, { children: /* @__PURE__ */ i(B, { className: o.trigger, children: [
216
217
  /* @__PURE__ */ e(
217
- P,
218
+ I,
218
219
  {
219
220
  placeholder: c,
220
221
  className: o.valueText
221
222
  }
222
223
  ),
223
- /* @__PURE__ */ e(S, { className: o.iconBox })
224
+ /* @__PURE__ */ e(v, { className: o.iconBox })
224
225
  ] }) }),
225
226
  a && m && /* @__PURE__ */ e(
226
227
  "div",
227
228
  {
228
- className: d({
229
+ className: r({
229
230
  textStyle: {
230
231
  base: "sd.system.typography.body.extraSmall_compact",
231
232
  expanded: "sd.system.typography.body.extraSmall_expanded"
@@ -235,20 +236,20 @@ const l = T({
235
236
  children: m
236
237
  }
237
238
  ),
238
- /* @__PURE__ */ e(C, { children: /* @__PURE__ */ e(B, { children: /* @__PURE__ */ e(I, { className: o.content, children: /* @__PURE__ */ e(v, { children: n.items.map((s, f) => /* @__PURE__ */ e(O, { item: s, children: /* @__PURE__ */ e(
239
- w,
239
+ /* @__PURE__ */ e(N, { children: /* @__PURE__ */ e(O, { children: /* @__PURE__ */ e(j, { className: o.content, children: /* @__PURE__ */ e(w, { children: n.items.map((s, S) => /* @__PURE__ */ e(A, { item: s, children: /* @__PURE__ */ e(
240
+ _,
240
241
  {
241
242
  title: s.label,
242
243
  value: s.value,
243
244
  className: o.item,
244
245
  size: t.size == "small" ? "small" : void 0
245
246
  }
246
- ) }, f)) }) }) }) })
247
+ ) }, S)) }) }) }) })
247
248
  ]
248
249
  }
249
250
  );
250
251
  };
251
252
  export {
252
- M as Select,
253
+ oe as Select,
253
254
  l as SelectStyle
254
255
  };
@@ -1,9 +1,10 @@
1
- import { jsxs as i, jsx as s } from "react/jsx-runtime";
2
- import _ from "../../node_modules/merge-refs/dist/esm/index.js";
3
- import c, { forwardRef as w } from "react";
4
- import { sva as C } from "../../styled-system/css/sva.js";
5
- import { cx as N } from "../../styled-system/css/cx.js";
6
- const p = C({
1
+ import { jsxs as a, jsx as s } from "react/jsx-runtime";
2
+ import w from "../../node_modules/merge-refs/dist/esm/index.js";
3
+ import c, { forwardRef as C } from "react";
4
+ import { useTranslations as N } from "../../i18n/index.js";
5
+ import { sva as R } from "../../styled-system/css/sva.js";
6
+ import { cx as T } from "../../styled-system/css/cx.js";
7
+ const p = R({
7
8
  slots: [
8
9
  "root",
9
10
  "label",
@@ -102,7 +103,7 @@ const p = C({
102
103
  }
103
104
  }
104
105
  }
105
- }), A = w(
106
+ }), I = C(
106
107
  ({
107
108
  placeholder: y,
108
109
  label: r,
@@ -110,44 +111,44 @@ const p = C({
110
111
  required: d,
111
112
  requiredLabel: u,
112
113
  invalidMessage: o,
113
- invalid: a,
114
- disabled: l,
114
+ invalid: i,
115
+ disabled: n,
115
116
  className: g,
116
- ...n
117
+ ...l
117
118
  }, h) => {
118
- const x = c.useRef(null), b = _(x, h), [f, S] = p.splitVariantProps(n), e = p(f), v = t || a && o, m = n.id || c.useId();
119
- return /* @__PURE__ */ i("div", { className: N(e.root, g), children: [
120
- r ? /* @__PURE__ */ i("label", { className: e.label, htmlFor: m, children: [
119
+ const x = N(), b = c.useRef(null), f = w(b, h), [S, v] = p.splitVariantProps(l), e = p(S), _ = t || i && o, m = l.id || c.useId();
120
+ return /* @__PURE__ */ a("div", { className: T(e.root, g), children: [
121
+ r ? /* @__PURE__ */ a("label", { className: e.label, htmlFor: m, children: [
121
122
  r,
122
- d && /* @__PURE__ */ s("span", { className: e.required, children: u ?? "必須" })
123
+ d && /* @__PURE__ */ s("span", { className: e.required, children: u ?? x("common.required") })
123
124
  ] }) : null,
124
125
  /* @__PURE__ */ s(
125
126
  "div",
126
127
  {
127
128
  className: e.wrapper,
128
- "data-invalid": a ? !0 : void 0,
129
- "data-disabled": l ? !0 : void 0,
129
+ "data-invalid": i ? !0 : void 0,
130
+ "data-disabled": n ? !0 : void 0,
130
131
  children: /* @__PURE__ */ s(
131
132
  "textarea",
132
133
  {
133
- ref: b,
134
+ ref: f,
134
135
  id: m,
135
136
  placeholder: y,
136
137
  required: d,
137
- disabled: l,
138
+ disabled: n,
138
139
  className: e.textarea,
139
- ...S
140
+ ...v
140
141
  }
141
142
  )
142
143
  }
143
144
  ),
144
- v && /* @__PURE__ */ i("div", { className: e.messageField, children: [
145
+ _ && /* @__PURE__ */ a("div", { className: e.messageField, children: [
145
146
  t && /* @__PURE__ */ s("p", { className: e.description, children: t }),
146
- a && o && /* @__PURE__ */ s("p", { className: e.invalidMessage, children: o })
147
+ i && o && /* @__PURE__ */ s("p", { className: e.invalidMessage, children: o })
147
148
  ] })
148
149
  ] });
149
150
  }
150
151
  );
151
152
  export {
152
- A as TextArea
153
+ I as TextArea
153
154
  };
@@ -2,72 +2,72 @@ import { jsxs as a, jsx as e } from "react/jsx-runtime";
2
2
  import { SerendieSymbolAlertCircle as A, SerendieSymbolClose as W } from "@serendie/symbols";
3
3
  import z from "../../node_modules/merge-refs/dist/esm/index.js";
4
4
  import m, { forwardRef as B } from "react";
5
- import { textFieldRecipe as x } from "../../recipes/textFieldRecipe.js";
5
+ import { textFieldRecipe as F } from "../../recipes/textFieldRecipe.js";
6
6
  import { useTranslations as D } from "../../i18n/index.js";
7
7
  import { cx as E } from "../../styled-system/css/cx.js";
8
- import { css as b } from "../../styled-system/css/css.js";
8
+ import { css as V } from "../../styled-system/css/css.js";
9
9
  const U = B(
10
10
  ({
11
- placeholder: F,
11
+ placeholder: b,
12
12
  label: d,
13
13
  description: i,
14
14
  required: u,
15
15
  requiredLabel: S,
16
- invalidMessage: n,
16
+ invalidMessage: c,
17
17
  invalid: r,
18
- type: V = "text",
19
- disabled: c,
18
+ type: w = "text",
19
+ disabled: n,
20
20
  onChange: h,
21
21
  value: f,
22
- className: w,
22
+ className: y,
23
23
  leftContent: N,
24
24
  rightContent: p,
25
- ...s
26
- }, y) => {
27
- const C = D(), o = m.useRef(null), P = z(o, y), [_, j] = x.splitVariantProps({
28
- ...s
29
- }), t = x(_), I = i || r && n, [T, k] = m.useState(s.defaultValue || f), v = s.id || m.useId(), q = () => {
30
- var R;
31
- const l = {
25
+ ...l
26
+ }, C) => {
27
+ const v = D(), o = m.useRef(null), P = z(o, C), [_, j] = F.splitVariantProps({
28
+ ...l
29
+ }), t = F(_), I = i || r && c, [T, k] = m.useState(l.defaultValue || f), g = l.id || m.useId(), q = () => {
30
+ var x;
31
+ const s = {
32
32
  target: { value: "" }
33
33
  };
34
- g(l), (R = s.onReset) == null || R.call(s, l), o.current && (o.current.value = "");
35
- }, g = (l) => {
36
- k(l.target.value), h && h(l);
34
+ R(s), (x = l.onReset) == null || x.call(l, s), o.current && (o.current.value = "");
35
+ }, R = (s) => {
36
+ k(s.target.value), h && h(s);
37
37
  };
38
- return /* @__PURE__ */ a("div", { className: E(t.root, w), children: [
39
- d ? /* @__PURE__ */ a("label", { className: t.label, htmlFor: v, children: [
38
+ return /* @__PURE__ */ a("div", { className: E(t.root, y), children: [
39
+ d ? /* @__PURE__ */ a("label", { className: t.label, htmlFor: g, children: [
40
40
  d,
41
- u && /* @__PURE__ */ e("span", { className: t.labelRequired, children: S ?? C("common.required") })
41
+ u && /* @__PURE__ */ e("span", { className: t.labelRequired, children: S ?? v("common.required") })
42
42
  ] }) : null,
43
43
  /* @__PURE__ */ a(
44
44
  "div",
45
45
  {
46
46
  className: t.inputWrapper,
47
47
  "data-invalid": r ? !0 : void 0,
48
- "data-disabled": c ? !0 : void 0,
48
+ "data-disabled": n ? !0 : void 0,
49
49
  children: [
50
50
  N ? /* @__PURE__ */ e("div", { className: t.leftContent, children: N }) : /* @__PURE__ */ e("div", {}),
51
51
  /* @__PURE__ */ e(
52
52
  "input",
53
53
  {
54
54
  ref: P,
55
- id: v,
56
- placeholder: F,
55
+ id: g,
56
+ placeholder: b,
57
57
  required: u,
58
- disabled: c,
58
+ disabled: n,
59
59
  value: f,
60
- type: V,
60
+ type: w,
61
61
  className: t.input,
62
- onChange: g,
62
+ onChange: R,
63
63
  ...j
64
64
  }
65
65
  ),
66
- p ? /* @__PURE__ */ e("div", { className: t.rightContent, children: p }) : /* @__PURE__ */ e("div", { className: t.icon, children: !c && /* disabledの場合はアイコンを表示しない */
66
+ p ? /* @__PURE__ */ e("div", { className: t.rightContent, children: p }) : /* @__PURE__ */ e("div", { className: t.icon, children: !n && /* disabledの場合はアイコンを表示しない */
67
67
  (r ? /* @__PURE__ */ e(
68
68
  "span",
69
69
  {
70
- className: b({
70
+ className: V({
71
71
  color: "sd.system.color.impression.negative"
72
72
  }),
73
73
  children: /* @__PURE__ */ e(A, { width: 20, height: 20 })
@@ -75,9 +75,9 @@ const U = B(
75
75
  ) : T ? /* @__PURE__ */ e(
76
76
  "button",
77
77
  {
78
- className: b({ cursor: "pointer" }),
78
+ className: V({ cursor: "pointer" }),
79
79
  onClick: q,
80
- "aria-label": "値をクリア",
80
+ "aria-label": v("textField.clearValue"),
81
81
  children: /* @__PURE__ */ e(W, { width: 20, height: 20 })
82
82
  }
83
83
  ) : null) })
@@ -86,7 +86,7 @@ const U = B(
86
86
  ),
87
87
  I && /* @__PURE__ */ a("div", { className: t.messageField, children: [
88
88
  i && /* @__PURE__ */ e("p", { className: t.description, children: i }),
89
- r && n && /* @__PURE__ */ e("p", { className: t.invalidMessage, children: n })
89
+ r && c && /* @__PURE__ */ e("p", { className: t.invalidMessage, children: c })
90
90
  ] })
91
91
  ] });
92
92
  }
@@ -1,10 +1,34 @@
1
1
  export declare const dictionary: {
2
2
  readonly ja: {
3
3
  readonly "common.required": "必須";
4
+ readonly "textField.clearValue": "値をクリア";
5
+ readonly "passwordField.hidePassword": "パスワードを隠す";
6
+ readonly "passwordField.showPassword": "パスワードを表示";
7
+ readonly "datePicker.selectDate": "日付を選択";
8
+ readonly "datePicker.startDate": "開始日";
9
+ readonly "datePicker.endDate": "終了日";
4
10
  readonly "pagination.page": "{{page}}ページ目";
11
+ readonly "pagination.firstPage": "最初のページです";
12
+ readonly "pagination.previousPage": "前のページへ";
13
+ readonly "pagination.lastPage": "最後のページです";
14
+ readonly "pagination.nextPage": "次のページへ";
15
+ readonly "pagination.goToPage": "ページ{{page}}へ移動";
16
+ readonly "modalDialog.close": "閉じる";
5
17
  };
6
18
  readonly en: {
7
19
  readonly "common.required": "Required";
20
+ readonly "textField.clearValue": "Clear value";
21
+ readonly "passwordField.hidePassword": "Hide password";
22
+ readonly "passwordField.showPassword": "Show password";
23
+ readonly "datePicker.selectDate": "Select date";
24
+ readonly "datePicker.startDate": "Start date";
25
+ readonly "datePicker.endDate": "End date";
8
26
  readonly "pagination.page": "Page {{page}}";
27
+ readonly "pagination.firstPage": "This is the first page";
28
+ readonly "pagination.previousPage": "Go to previous page";
29
+ readonly "pagination.lastPage": "This is the last page";
30
+ readonly "pagination.nextPage": "Go to next page";
31
+ readonly "pagination.goToPage": "Go to page {{page}}";
32
+ readonly "modalDialog.close": "Close";
9
33
  };
10
34
  };
@@ -1,13 +1,37 @@
1
- const e = {
1
+ const a = {
2
2
  ja: {
3
3
  "common.required": "必須",
4
- "pagination.page": "{{page}}ページ目"
4
+ "textField.clearValue": "値をクリア",
5
+ "passwordField.hidePassword": "パスワードを隠す",
6
+ "passwordField.showPassword": "パスワードを表示",
7
+ "datePicker.selectDate": "日付を選択",
8
+ "datePicker.startDate": "開始日",
9
+ "datePicker.endDate": "終了日",
10
+ "pagination.page": "{{page}}ページ目",
11
+ "pagination.firstPage": "最初のページです",
12
+ "pagination.previousPage": "前のページへ",
13
+ "pagination.lastPage": "最後のページです",
14
+ "pagination.nextPage": "次のページへ",
15
+ "pagination.goToPage": "ページ{{page}}へ移動",
16
+ "modalDialog.close": "閉じる"
5
17
  },
6
18
  en: {
7
19
  "common.required": "Required",
8
- "pagination.page": "Page {{page}}"
20
+ "textField.clearValue": "Clear value",
21
+ "passwordField.hidePassword": "Hide password",
22
+ "passwordField.showPassword": "Show password",
23
+ "datePicker.selectDate": "Select date",
24
+ "datePicker.startDate": "Start date",
25
+ "datePicker.endDate": "End date",
26
+ "pagination.page": "Page {{page}}",
27
+ "pagination.firstPage": "This is the first page",
28
+ "pagination.previousPage": "Go to previous page",
29
+ "pagination.lastPage": "This is the last page",
30
+ "pagination.nextPage": "Go to next page",
31
+ "pagination.goToPage": "Go to page {{page}}",
32
+ "modalDialog.close": "Close"
9
33
  }
10
34
  };
11
35
  export {
12
- e as dictionary
36
+ a as dictionary
13
37
  };
package/package.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "name": "@serendie/ui",
3
3
  "description": "Adaptive UI component library as part of Serendie Design System by Mitsubishi Electric",
4
4
  "license": "MIT",
5
- "version": "2.3.0-dev.202512090256",
5
+ "version": "2.3.0-dev.202601080645",
6
6
  "type": "module",
7
7
  "types": "./dist/index.d.ts",
8
8
  "sideEffects": [