amotify 0.1.31 → 0.1.32

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.
Files changed (95) hide show
  1. package/dist/@declaration/_.js +1 -1
  2. package/dist/@styles/componentClasses/_.css +68 -65
  3. package/dist/@styles/componentClasses/_.js +39 -39
  4. package/dist/@styles/index.css +68 -65
  5. package/dist/@styles/index.js +39 -39
  6. package/dist/@styles/init.css +1 -1
  7. package/dist/@styles/style.css +68 -65
  8. package/dist/@styles/style.js +39 -39
  9. package/dist/@styles/var.css +1 -1
  10. package/dist/@utils/GenerateClassName.js +470 -1
  11. package/dist/@utils/LaunchReactApp.js +78 -1
  12. package/dist/@utils/_.js +12 -1
  13. package/dist/@utils/collectForm.js +96 -1
  14. package/dist/@utils/color.js +103 -1
  15. package/dist/@utils/config.js +101 -1
  16. package/dist/@utils/fin.js +39 -1
  17. package/dist/@utils/getElement.js +13 -1
  18. package/dist/@utils/jsminEx.js +172 -1
  19. package/dist/@utils/pageTransit.js +33 -1
  20. package/dist/@utils/useRecycle.js +44 -1
  21. package/dist/@utils/useStore.js +54 -1
  22. package/dist/atoms/Box.js +20 -1
  23. package/dist/atoms/FAI.js +148 -1
  24. package/dist/atoms/Flex.js +34 -1
  25. package/dist/atoms/Grid.js +17 -1
  26. package/dist/atoms/Img.js +65 -1
  27. package/dist/atoms/Logo.js +359 -51
  28. package/dist/atoms/P.js +20 -1
  29. package/dist/atoms/Placeholder.js +44 -1
  30. package/dist/atoms/Span.js +20 -1
  31. package/dist/atoms/_.js +9 -1
  32. package/dist/chunk-JJ3PEWPN.js +60 -0
  33. package/dist/fn/Button.js +316 -1
  34. package/dist/fn/Cropper.js +1009 -1
  35. package/dist/fn/Effect/Fade.js +88 -1
  36. package/dist/fn/Effect/Pudding.js +22 -1
  37. package/dist/fn/Effect/Ripple.js +117 -3
  38. package/dist/fn/Effect/_.js +14 -1
  39. package/dist/fn/Input/AutoHeightText.js +112 -1
  40. package/dist/fn/Input/Checker.js +36 -1
  41. package/dist/fn/Input/Chips/Selector.js +472 -1
  42. package/dist/fn/Input/Chips/_.js +349 -1
  43. package/dist/fn/Input/Contenteditable.js +160 -1
  44. package/dist/fn/Input/DigitCharacters.js +275 -1
  45. package/dist/fn/Input/Filer.js +619 -1
  46. package/dist/fn/Input/Hidden.js +48 -1
  47. package/dist/fn/Input/List.js +450 -1
  48. package/dist/fn/Input/Parts.js +121 -1
  49. package/dist/fn/Input/Plain.js +12 -1
  50. package/dist/fn/Input/RichSelect.js +279 -1
  51. package/dist/fn/Input/Search.js +53 -1
  52. package/dist/fn/Input/Segmented.js +245 -1
  53. package/dist/fn/Input/Select.js +278 -1
  54. package/dist/fn/Input/Slider.js +538 -1
  55. package/dist/fn/Input/Switch.js +221 -1
  56. package/dist/fn/Input/Text.js +626 -1
  57. package/dist/fn/Input/TextArea.js +151 -1
  58. package/dist/fn/Input/Time/Picker.js +1457 -1
  59. package/dist/fn/Input/Time/_.js +867 -1
  60. package/dist/fn/Input/_.js +48 -1
  61. package/dist/fn/Input/core.js +626 -1
  62. package/dist/fn/Layout/PageNotFound.js +90 -1
  63. package/dist/fn/Layout/PageRouter.js +87 -1
  64. package/dist/fn/Layout/PageViewController.js +29 -1
  65. package/dist/fn/Layout/Plate.js +37 -1
  66. package/dist/fn/Layout/RootViewController.js +315 -1
  67. package/dist/fn/Layout/SwipeView.js +348 -1
  68. package/dist/fn/Layout/TabBar.js +72 -1
  69. package/dist/fn/Layout/_.js +22 -1
  70. package/dist/fn/Loader/_.js +104 -1
  71. package/dist/fn/Loader/corner.js +85 -1
  72. package/dist/fn/Loader/mini.js +125 -1
  73. package/dist/fn/Loader/top.js +73 -1
  74. package/dist/fn/Sheet.js +1101 -1
  75. package/dist/fn/Snackbar.js +216 -1
  76. package/dist/fn/Table/Data.js +974 -1
  77. package/dist/fn/Table/Drag.js +435 -1
  78. package/dist/fn/Table/Normal.js +136 -1
  79. package/dist/fn/Table/Parts.js +41 -1
  80. package/dist/fn/Table/Wrapper.js +60 -1
  81. package/dist/fn/Table/_.js +16 -1
  82. package/dist/fn/Table/cellStyling.js +51 -1
  83. package/dist/fn/Tooltips.js +58 -1
  84. package/dist/fn/_.js +10 -1
  85. package/dist/index.js +20 -1
  86. package/dist/mols/Accordion.js +152 -1
  87. package/dist/mols/Column.js +16 -1
  88. package/dist/mols/LinkifyText.js +42 -1
  89. package/dist/mols/List.js +42 -1
  90. package/dist/mols/Row.js +47 -1
  91. package/dist/mols/Text.js +67 -1
  92. package/dist/mols/_.js +6 -1
  93. package/dist/temps/_.js +1 -1
  94. package/dist/temps/designBook.js +3639 -20
  95. package/package.json +1 -1
@@ -1 +1,450 @@
1
- import{b as t,c,d as B}from"../../chunk-VY3566IV.js";import{jsx as l,jsxs as te}from"react/jsx-runtime";import{useState as X}from"react";import{$$ as b,$$fromRoot as ne}from"../../@utils/_";import D from"../../atoms/Box";import ie from"../../atoms/Flex";import oe from"../../atoms/FAI";import se from"../Button";import{BoxWrapper as re,SubmitForm as ce,CommonEffects as ue,DefaultStyles as de,Wrapper as pe}from"./core";import fe from"./Hidden";import{InputListClasses as s}from"../../@styles/componentClasses/_";function me(e){let{value:n,params:i}=e,{type:I,required:u,minSelect:a=0}=i,o=[];return u&&(n.length||I=="radio"&&o.push({type:"invalid",label:"\u9078\u629E\u3055\u308C\u3066\u3044\u307E\u305B\u3093"})),a&&n.length<a&&o.push({type:"invalid",label:`${a}\u500B\u4EE5\u4E0A\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044`}),{ok:!o.filter(({type:r})=>r=="invalid").length,notice:o}}const ye=e=>{let{value:n,options:i=[]}=e,I=b.is.exist(n)?b.flatArray(n):[],u=i.map(o=>{let{value:r,label:h}=o;return c(t({},o),{value:JSON.stringify(r),label:h})}),a=[];return I.forEach(o=>{let r=JSON.stringify(o);u.findIndex(k=>k.value==r)!=-1&&a.push(r)}),l(P.Core,c(t({},e),{value:a,options:u}))},P={Core:e=>{let N=e,{type:n,tone:i,required:I,componentID:u="",form:a,override:o,freeCSS:r,icon:h,iconType:k,enableFormSubmit:$,defaultActiveStyling:J,checkValidationAtFirst:W,onValidate:j,onUpdateValue:R,onUpdateValidValue:_,value:A,options:v,leftIndicator:z,rightIndicator:U,className:F,cellStyles:q,cellClassName:w,cellCheckedStyles:H,cellCheckedClassName:K}=N,T=B(N,["type","tone","required","componentID","form","override","freeCSS","icon","iconType","enableFormSubmit","defaultActiveStyling","checkValidationAtFirst","onValidate","onUpdateValue","onUpdateValidValue","value","options","leftIndicator","rightIndicator","className","cellStyles","cellClassName","cellCheckedStyles","cellCheckedClassName"]),S={componentID:u,dataValue:A,eventType:"init",eventID:b.uuid.gen()},[d,C]=X(S),[x,g]=X({ok:!1,notice:[]});return ue({type:"list",params:e,val_status:d,set_status:C,val_validate:x,set_validate:g,onUpdateValue:R,onUpdateValidValue:_,DefaultValidation:me}),te(re,{val_status:d,set_status:C,val_validate:x,params:e,children:[l(fe,c(t({"data-value":JSON.stringify(d.dataValue),form:a,"data-input-type":n,"data-validation":x.ok},T),{componentID:d.componentID})),l(P.List,{params:e,val_status:d,set_status:C})]})},List:e=>{let{params:n,val_status:i,set_status:I}=e,{componentID:u,type:a,tone:o,icon:r=!0,options:h,name:k,form:$,tabIndex:J,hideInput:W,disabled:j,className:R,cellStyles:_,cellClassName:A="",cellCheckedStyles:v,cellCheckedClassName:z="",enableFormSubmit:U,defaultActiveStyling:F=!0}=n,{dataValue:q}=i,w=r?l(D,{flexSizing:"none",children:n.iconType=="radio"?l(P.RadioIcon,{}):n.iconType=="checkbox"?l(P.CheckboxIcon,{}):null}):null,H=h.map((K,T)=>{let Q=K,{value:S,label:d,disabled:C=j,className:x="",checkedStyles:g,checkedClassName:N=""}=Q,ae=B(Q,["value","label","disabled","className","checkedStyles","checkedClassName"]),G=b.uuid.gen(),M=q.findIndex(p=>p===S)!=-1,L=t(t({},_),ae),O=[s("Label"),s("defaultActiveStyling_"+!!F),A,x];return M&&(L=c(t(t(t({},L),v),g),{freeCSS:t(t(t({},L.freeCSS),v==null?void 0:v.freeCSS),g==null?void 0:g.freeCSS)}),O=[...O,z,N]),[l("input",{type:a=="radio"?"radio":"checkbox",className:[s("Input"),s("defaultActiveStyling_"+!!F)].join(" "),name:"RadioCheckbox-"+k,"data-list-index":u+"-"+T,id:G,value:String(S),"data-form-name":$,disabled:C,checked:M,onFocus:p=>{if(C||a!="radio"||i.dataValue.length)return;let{value:f,checked:V}=p.target,m=[f];I(c(t({},i),{dataValue:m,eventType:"update",eventID:b.uuid.gen()}))},onChange:p=>{if(C)return;let{value:f,checked:V}=p.target,m=[];if(a=="radio")m=[f];else if(a=="checkbox"||a=="checker")if(V)m=[...i.dataValue,f];else{let y=[...i.dataValue];y.splice(i.dataValue.findIndex(le=>le==f),1),m=y}I(c(t({},i),{dataValue:m,eventType:"update",eventID:b.uuid.gen()}))},onKeyDown:p=>{let{key:f,shiftKey:V}=p;if((a=="checkbox"||a=="checker")&&f!="Tab"){if(f.match(/Arrow/)){p.preventDefault();let m=["ArrowLeft","ArrowUp"].includes(f)?-1:1,y=T+m;y<0?y=h.length-1:y>=h.length&&(y=0),ne(`input[data-list-index="${u}-${y}"]`).focus()}}U&&ce(p)},tabIndex:J},"List-"+JSON.stringify(S)),te(se.Label.Plain,c(t({htmlFor:G,className:O.join(" "),tabIndex:-1,display:"flex",ssEffectsOnActive:!1,verticalAlign:"center",gap:"1/3",flexWrap:!1},L),{children:[w,b.is.string(d)?l(D,{children:d}):d]}),"ListTrigger-"+JSON.stringify(S))]});return l(ie,{flexSizing:"auto",freeCSS:t({},n.freeCSS),className:[R,s("CellBase"),s("HideInput_"+W),s("IconIndicator_"+!!r),s("Tone_"+o)].join(" "),children:H})},RadioIcon:()=>l(D,{className:s("Icon"),backgroundColor:"1.layer.base",border:!0,transition:"middle",position:"relative",borderRadius:"sphere",flexCenter:!0}),CheckboxIcon:()=>l(D,{className:[s("Icon"),s("CheckboxIcon")].join(" "),borderRadius:"3.tone.tertiary",backgroundColor:"1.layer.base",border:!0,transition:"middle",fontColor:"white",position:"relative",flexCenter:!0,children:l(oe.Check,{className:s("I"),transition:"middle",opacity:"trans",freeCSS:{zIndex:8}})})},E=e=>{e=t({},e);let n=de.ListCell(e);return l(pe,{componentID:e.componentID,children:ye,params:n})},Y=e=>l(E,c(t({iconType:"radio",tone:e.tone},e),{type:"radio"})),Z=e=>l(E,c(t({iconType:"checkbox",tone:e.tone},e),{type:"checkbox"})),ee={Plain:E,Radio:Y,Checkbox:Z};export{Z as Checkbox,ee as List,Y as Radio,ee as default};
1
+ import {
2
+ __objRest,
3
+ __spreadProps,
4
+ __spreadValues
5
+ } from "../../chunk-JJ3PEWPN.js";
6
+ import { jsx, jsxs } from "react/jsx-runtime";
7
+ import {
8
+ useState
9
+ } from "react";
10
+ import {
11
+ $$,
12
+ $$fromRoot
13
+ } from "../../@utils/_";
14
+ import Box from "../../atoms/Box";
15
+ import Flex from "../../atoms/Flex";
16
+ import FAI from "../../atoms/FAI";
17
+ import Button from "../Button";
18
+ import {
19
+ BoxWrapper,
20
+ SubmitForm,
21
+ CommonEffects,
22
+ DefaultStyles,
23
+ Wrapper
24
+ } from "./core";
25
+ import Hidden from "./Hidden";
26
+ import { InputListClasses } from "../../@styles/componentClasses/_";
27
+ function DefaultValidation(props) {
28
+ let { value, params } = props;
29
+ let {
30
+ type,
31
+ required,
32
+ minSelect = 0
33
+ } = params;
34
+ let notice = [];
35
+ if (required) {
36
+ if (!value.length) {
37
+ if (type == "radio") {
38
+ notice.push({ type: "invalid", label: "\u9078\u629E\u3055\u308C\u3066\u3044\u307E\u305B\u3093" });
39
+ }
40
+ }
41
+ }
42
+ if (minSelect) {
43
+ if (value.length < minSelect) {
44
+ notice.push({ type: "invalid", label: `${minSelect}\u500B\u4EE5\u4E0A\u9078\u629E\u3057\u3066\u304F\u3060\u3055\u3044` });
45
+ }
46
+ }
47
+ return {
48
+ ok: !notice.filter(({ type: type2 }) => type2 == "invalid").length,
49
+ notice
50
+ };
51
+ }
52
+ const ListInput = (props) => {
53
+ let { value, options = [] } = props;
54
+ let Values = $$.is.exist(value) ? $$.flatArray(value) : [];
55
+ let DefaultOptions = options.map((option) => {
56
+ let { value: value2, label } = option;
57
+ return __spreadProps(__spreadValues({}, option), {
58
+ value: JSON.stringify(value2),
59
+ label
60
+ });
61
+ });
62
+ let DefaultValues = [];
63
+ Values.forEach((value2) => {
64
+ let Val = JSON.stringify(value2);
65
+ let Index = DefaultOptions.findIndex((option) => option.value == Val);
66
+ if (Index == -1)
67
+ return;
68
+ DefaultValues.push(Val);
69
+ });
70
+ return /* @__PURE__ */ jsx(
71
+ Comps.Core,
72
+ __spreadProps(__spreadValues({}, props), {
73
+ value: DefaultValues,
74
+ options: DefaultOptions
75
+ })
76
+ );
77
+ };
78
+ const Comps = {
79
+ Core: (params) => {
80
+ let _a = params, {
81
+ type,
82
+ tone,
83
+ required,
84
+ componentID = "",
85
+ form,
86
+ override,
87
+ freeCSS,
88
+ icon,
89
+ iconType,
90
+ enableFormSubmit,
91
+ defaultActiveStyling,
92
+ checkValidationAtFirst,
93
+ onValidate,
94
+ onUpdateValue,
95
+ onUpdateValidValue,
96
+ value,
97
+ options,
98
+ leftIndicator,
99
+ rightIndicator,
100
+ className,
101
+ cellStyles,
102
+ cellClassName,
103
+ cellCheckedStyles,
104
+ cellCheckedClassName
105
+ } = _a, others = __objRest(_a, [
106
+ "type",
107
+ "tone",
108
+ "required",
109
+ "componentID",
110
+ "form",
111
+ "override",
112
+ "freeCSS",
113
+ "icon",
114
+ "iconType",
115
+ "enableFormSubmit",
116
+ "defaultActiveStyling",
117
+ "checkValidationAtFirst",
118
+ "onValidate",
119
+ "onUpdateValue",
120
+ "onUpdateValidValue",
121
+ "value",
122
+ "options",
123
+ "leftIndicator",
124
+ "rightIndicator",
125
+ "className",
126
+ "cellStyles",
127
+ "cellClassName",
128
+ "cellCheckedStyles",
129
+ "cellCheckedClassName"
130
+ ]);
131
+ let Default_Status = {
132
+ componentID,
133
+ dataValue: value,
134
+ eventType: "init",
135
+ eventID: $$.uuid.gen()
136
+ };
137
+ let [val_status, set_status] = useState(Default_Status);
138
+ let [val_validate, set_validate] = useState({
139
+ ok: false,
140
+ notice: []
141
+ });
142
+ CommonEffects({
143
+ type: "list",
144
+ params,
145
+ val_status,
146
+ set_status,
147
+ val_validate,
148
+ set_validate,
149
+ onUpdateValue,
150
+ onUpdateValidValue,
151
+ DefaultValidation
152
+ });
153
+ return /* @__PURE__ */ jsxs(
154
+ BoxWrapper,
155
+ {
156
+ val_status,
157
+ set_status,
158
+ val_validate,
159
+ params,
160
+ children: [
161
+ /* @__PURE__ */ jsx(
162
+ Hidden,
163
+ __spreadProps(__spreadValues({
164
+ "data-value": JSON.stringify(val_status.dataValue),
165
+ form,
166
+ "data-input-type": type,
167
+ "data-validation": val_validate.ok
168
+ }, others), {
169
+ componentID: val_status.componentID
170
+ })
171
+ ),
172
+ /* @__PURE__ */ jsx(
173
+ Comps.List,
174
+ {
175
+ params,
176
+ val_status,
177
+ set_status
178
+ }
179
+ )
180
+ ]
181
+ }
182
+ );
183
+ },
184
+ List: (props) => {
185
+ let {
186
+ params,
187
+ val_status,
188
+ set_status
189
+ } = props;
190
+ let {
191
+ componentID,
192
+ type,
193
+ tone,
194
+ icon = true,
195
+ options,
196
+ name,
197
+ form,
198
+ tabIndex,
199
+ hideInput,
200
+ disabled: DefaultDisabled,
201
+ className: ListClassName,
202
+ cellStyles: DefaultCellStyles,
203
+ cellClassName: DefaultCellClassName = "",
204
+ cellCheckedStyles: DefaultCellCheckedStyles,
205
+ cellCheckedClassName: DefaultCellCheckedClassName = "",
206
+ enableFormSubmit,
207
+ defaultActiveStyling = true
208
+ } = params;
209
+ let {
210
+ dataValue
211
+ } = val_status;
212
+ let IconBox = icon ? /* @__PURE__ */ jsx(
213
+ Box,
214
+ {
215
+ flexSizing: "none",
216
+ children: params.iconType == "radio" ? /* @__PURE__ */ jsx(Comps.RadioIcon, {}) : params.iconType == "checkbox" ? /* @__PURE__ */ jsx(Comps.CheckboxIcon, {}) : null
217
+ }
218
+ ) : null;
219
+ let Cells = options.map((option, index) => {
220
+ let _a = option, {
221
+ value,
222
+ label,
223
+ disabled = DefaultDisabled,
224
+ className = "",
225
+ checkedStyles,
226
+ checkedClassName = ""
227
+ } = _a, styles = __objRest(_a, [
228
+ "value",
229
+ "label",
230
+ "disabled",
231
+ "className",
232
+ "checkedStyles",
233
+ "checkedClassName"
234
+ ]);
235
+ let CellID = $$.uuid.gen();
236
+ let Checked = dataValue.findIndex((v) => v === value) != -1;
237
+ let Styles = __spreadValues(__spreadValues({}, DefaultCellStyles), styles);
238
+ let ClassName = [
239
+ InputListClasses("Label"),
240
+ InputListClasses("defaultActiveStyling_" + !!defaultActiveStyling),
241
+ DefaultCellClassName,
242
+ className
243
+ ];
244
+ if (Checked) {
245
+ Styles = __spreadProps(__spreadValues(__spreadValues(__spreadValues({}, Styles), DefaultCellCheckedStyles), checkedStyles), {
246
+ freeCSS: __spreadValues(__spreadValues(__spreadValues({}, Styles.freeCSS), DefaultCellCheckedStyles == null ? void 0 : DefaultCellCheckedStyles.freeCSS), checkedStyles == null ? void 0 : checkedStyles.freeCSS)
247
+ });
248
+ ClassName = [
249
+ ...ClassName,
250
+ DefaultCellCheckedClassName,
251
+ checkedClassName
252
+ ];
253
+ }
254
+ return [
255
+ /* @__PURE__ */ jsx(
256
+ "input",
257
+ {
258
+ type: type == "radio" ? "radio" : "checkbox",
259
+ className: [
260
+ InputListClasses("Input"),
261
+ InputListClasses("defaultActiveStyling_" + !!defaultActiveStyling)
262
+ ].join(" "),
263
+ name: "RadioCheckbox-" + name,
264
+ "data-list-index": componentID + "-" + index,
265
+ id: CellID,
266
+ value: String(value),
267
+ "data-form-name": form,
268
+ disabled,
269
+ checked: Checked,
270
+ onFocus: (event) => {
271
+ if (disabled)
272
+ return;
273
+ if (type != "radio")
274
+ return;
275
+ if (val_status.dataValue.length)
276
+ return;
277
+ let { value: value2, checked } = event.target;
278
+ let nextValue = [value2];
279
+ set_status(__spreadProps(__spreadValues({}, val_status), {
280
+ dataValue: nextValue,
281
+ eventType: "update",
282
+ eventID: $$.uuid.gen()
283
+ }));
284
+ },
285
+ onChange: (event) => {
286
+ if (disabled)
287
+ return;
288
+ let { value: value2, checked } = event.target;
289
+ let nextValue = [];
290
+ if (type == "radio") {
291
+ nextValue = [value2];
292
+ } else if (type == "checkbox" || type == "checker") {
293
+ if (checked) {
294
+ nextValue = [...val_status.dataValue, value2];
295
+ } else {
296
+ let prevValue = [...val_status.dataValue];
297
+ prevValue.splice(val_status.dataValue.findIndex((v) => v == value2), 1);
298
+ nextValue = prevValue;
299
+ }
300
+ }
301
+ set_status(__spreadProps(__spreadValues({}, val_status), {
302
+ dataValue: nextValue,
303
+ eventType: "update",
304
+ eventID: $$.uuid.gen()
305
+ }));
306
+ },
307
+ onKeyDown: (event) => {
308
+ let { key, shiftKey } = event;
309
+ if (type == "checkbox" || type == "checker") {
310
+ if (key == "Tab") {
311
+ if (shiftKey) {
312
+ } else {
313
+ }
314
+ } else if (key.match(/Arrow/)) {
315
+ event.preventDefault();
316
+ let dir = ["ArrowLeft", "ArrowUp"].includes(key) ? -1 : 1;
317
+ let nextIndex = index + dir;
318
+ if (nextIndex < 0) {
319
+ nextIndex = options.length - 1;
320
+ } else if (nextIndex >= options.length) {
321
+ nextIndex = 0;
322
+ }
323
+ $$fromRoot(`input[data-list-index="${componentID}-${nextIndex}"]`).focus();
324
+ }
325
+ }
326
+ if (enableFormSubmit)
327
+ SubmitForm(event);
328
+ },
329
+ tabIndex
330
+ },
331
+ "List-" + JSON.stringify(value)
332
+ ),
333
+ /* @__PURE__ */ jsxs(
334
+ Button.Label.Plain,
335
+ __spreadProps(__spreadValues({
336
+ htmlFor: CellID,
337
+ className: ClassName.join(" "),
338
+ tabIndex: -1,
339
+ display: "flex",
340
+ ssEffectsOnActive: false,
341
+ verticalAlign: "center",
342
+ gap: "1/3",
343
+ flexWrap: false
344
+ }, Styles), {
345
+ children: [
346
+ IconBox,
347
+ $$.is.string(label) ? /* @__PURE__ */ jsx(Box, { children: label }) : label
348
+ ]
349
+ }),
350
+ "ListTrigger-" + JSON.stringify(value)
351
+ )
352
+ ];
353
+ });
354
+ return /* @__PURE__ */ jsx(
355
+ Flex,
356
+ {
357
+ flexSizing: "auto",
358
+ freeCSS: __spreadValues({}, params.freeCSS),
359
+ className: [
360
+ ListClassName,
361
+ InputListClasses("CellBase"),
362
+ InputListClasses("HideInput_" + hideInput),
363
+ InputListClasses("IconIndicator_" + !!icon),
364
+ InputListClasses("Tone_" + tone)
365
+ ].join(" "),
366
+ children: Cells
367
+ }
368
+ );
369
+ },
370
+ RadioIcon: () => /* @__PURE__ */ jsx(
371
+ Box,
372
+ {
373
+ className: InputListClasses("Icon"),
374
+ backgroundColor: "1.layer.base",
375
+ border: true,
376
+ transition: "middle",
377
+ position: "relative",
378
+ borderRadius: "sphere",
379
+ flexCenter: true
380
+ }
381
+ ),
382
+ CheckboxIcon: () => /* @__PURE__ */ jsx(
383
+ Box,
384
+ {
385
+ className: [
386
+ InputListClasses("Icon"),
387
+ InputListClasses("CheckboxIcon")
388
+ ].join(" "),
389
+ borderRadius: "3.tone.tertiary",
390
+ backgroundColor: "1.layer.base",
391
+ border: true,
392
+ transition: "middle",
393
+ fontColor: "white",
394
+ position: "relative",
395
+ flexCenter: true,
396
+ children: /* @__PURE__ */ jsx(
397
+ FAI.Check,
398
+ {
399
+ className: InputListClasses("I"),
400
+ transition: "middle",
401
+ opacity: "trans",
402
+ freeCSS: {
403
+ zIndex: 8
404
+ }
405
+ }
406
+ )
407
+ }
408
+ )
409
+ };
410
+ const Plain = (rawParams) => {
411
+ rawParams = __spreadValues({}, rawParams);
412
+ let params = DefaultStyles.ListCell(rawParams);
413
+ return /* @__PURE__ */ jsx(
414
+ Wrapper,
415
+ {
416
+ componentID: rawParams.componentID,
417
+ children: ListInput,
418
+ params
419
+ }
420
+ );
421
+ };
422
+ const Radio = (params) => /* @__PURE__ */ jsx(
423
+ Plain,
424
+ __spreadProps(__spreadValues({
425
+ iconType: "radio",
426
+ tone: params.tone
427
+ }, params), {
428
+ type: "radio"
429
+ })
430
+ );
431
+ const Checkbox = (params) => /* @__PURE__ */ jsx(
432
+ Plain,
433
+ __spreadProps(__spreadValues({
434
+ iconType: "checkbox",
435
+ tone: params.tone
436
+ }, params), {
437
+ type: "checkbox"
438
+ })
439
+ );
440
+ const List = {
441
+ Plain,
442
+ Radio,
443
+ Checkbox
444
+ };
445
+ export {
446
+ Checkbox,
447
+ List,
448
+ Radio,
449
+ List as default
450
+ };
@@ -1 +1,121 @@
1
- import{b as t,c as n,d}from"../../chunk-VY3566IV.js";import{jsx as a}from"react/jsx-runtime";import p from"../../atoms/Box";import s from"../../atoms/Span";import{DefaultStyles as c}from"./core";import{InputClasses as u}from"../../@styles/componentClasses/_";const I={RequiredSign:e=>a(s,t({fontColor:"white",fontSize:"0.xs",padding:["1/4","1/3"],backgroundColor:"nega",borderRadius:"3.tone.tertiary",children:"\u5FC5\u9808"},e)),RequiredShortSign:e=>a(s,t({fontColor:"nega",padding:["1/4","1/3"],borderRadius:"3.tone.tertiary",children:"*"},e)),OmitSign:e=>a(s,t({fontColor:"white",fontSize:"0.xs",padding:["1/4","1/3"],borderRadius:"3.tone.tertiary",backgroundColor:"6.layer.darkest",children:"\u7701\u7565\u53EF"},e)),LeftIndicator:e=>{let r=e,{tone:i}=r,o=d(r,["tone"]);return a(p,t(n(t({},c.Indicator(i)),{borderTopRightRadius:"2/3",borderBottomRightRadius:"2/3"}),o))},RightIndicator:e=>{let r=e,{tone:i}=r,o=d(r,["tone"]);return a(p,t(n(t({},c.Indicator(i)),{borderTopLeftRadius:"2/3",borderBottomLeftRadius:"2/3"}),o))},RightIcon:e=>{let r=e,{tone:i="border"}=r,o=d(r,["tone"]);return a(p,n(t(n(t({},c.IndicatorIcon),{right:"3/4",className:u("IndicatorIcon")}),o),{freeCSS:t({zIndex:6,pointerEvents:"none"},o.freeCSS)}))},LeftIcon:e=>{let r=e,{tone:i="border"}=r,o=d(r,["tone"]);return a(p,n(t(n(t({},c.IndicatorIcon),{left:"3/4",className:u("IndicatorIcon")}),o),{freeCSS:t({zIndex:6,pointerEvents:"none"},o.freeCSS)}))}};export{I as Parts,I as default};
1
+ import {
2
+ __objRest,
3
+ __spreadProps,
4
+ __spreadValues
5
+ } from "../../chunk-JJ3PEWPN.js";
6
+ import { jsx } from "react/jsx-runtime";
7
+ import Box from "../../atoms/Box";
8
+ import Span from "../../atoms/Span";
9
+ import {
10
+ DefaultStyles
11
+ } from "./core";
12
+ import { InputClasses } from "../../@styles/componentClasses/_";
13
+ const Parts = {
14
+ RequiredSign: (params) => {
15
+ return /* @__PURE__ */ jsx(
16
+ Span,
17
+ __spreadValues({
18
+ fontColor: "white",
19
+ fontSize: "0.xs",
20
+ padding: ["1/4", "1/3"],
21
+ backgroundColor: "nega",
22
+ borderRadius: "3.tone.tertiary",
23
+ children: "\u5FC5\u9808"
24
+ }, params)
25
+ );
26
+ },
27
+ RequiredShortSign: (params) => {
28
+ return /* @__PURE__ */ jsx(
29
+ Span,
30
+ __spreadValues({
31
+ fontColor: "nega",
32
+ padding: ["1/4", "1/3"],
33
+ borderRadius: "3.tone.tertiary",
34
+ children: "*"
35
+ }, params)
36
+ );
37
+ },
38
+ OmitSign: (params) => {
39
+ return /* @__PURE__ */ jsx(
40
+ Span,
41
+ __spreadValues({
42
+ fontColor: "white",
43
+ fontSize: "0.xs",
44
+ padding: ["1/4", "1/3"],
45
+ borderRadius: "3.tone.tertiary",
46
+ backgroundColor: "6.layer.darkest",
47
+ children: "\u7701\u7565\u53EF"
48
+ }, params)
49
+ );
50
+ },
51
+ LeftIndicator: (params) => {
52
+ let _a = params, {
53
+ tone
54
+ } = _a, others = __objRest(_a, [
55
+ "tone"
56
+ ]);
57
+ return /* @__PURE__ */ jsx(
58
+ Box,
59
+ __spreadValues(__spreadProps(__spreadValues({}, DefaultStyles.Indicator(tone)), {
60
+ borderTopRightRadius: "2/3",
61
+ borderBottomRightRadius: "2/3"
62
+ }), others)
63
+ );
64
+ },
65
+ RightIndicator: (params) => {
66
+ let _a = params, {
67
+ tone
68
+ } = _a, others = __objRest(_a, [
69
+ "tone"
70
+ ]);
71
+ return /* @__PURE__ */ jsx(
72
+ Box,
73
+ __spreadValues(__spreadProps(__spreadValues({}, DefaultStyles.Indicator(tone)), {
74
+ borderTopLeftRadius: "2/3",
75
+ borderBottomLeftRadius: "2/3"
76
+ }), others)
77
+ );
78
+ },
79
+ RightIcon: (params) => {
80
+ let _a = params, {
81
+ tone = "border"
82
+ } = _a, others = __objRest(_a, [
83
+ "tone"
84
+ ]);
85
+ return /* @__PURE__ */ jsx(
86
+ Box,
87
+ __spreadProps(__spreadValues(__spreadProps(__spreadValues({}, DefaultStyles.IndicatorIcon), {
88
+ right: "3/4",
89
+ className: InputClasses("IndicatorIcon")
90
+ }), others), {
91
+ freeCSS: __spreadValues({
92
+ zIndex: 6,
93
+ pointerEvents: "none"
94
+ }, others.freeCSS)
95
+ })
96
+ );
97
+ },
98
+ LeftIcon: (params) => {
99
+ let _a = params, {
100
+ tone = "border"
101
+ } = _a, others = __objRest(_a, [
102
+ "tone"
103
+ ]);
104
+ return /* @__PURE__ */ jsx(
105
+ Box,
106
+ __spreadProps(__spreadValues(__spreadProps(__spreadValues({}, DefaultStyles.IndicatorIcon), {
107
+ left: "3/4",
108
+ className: InputClasses("IndicatorIcon")
109
+ }), others), {
110
+ freeCSS: __spreadValues({
111
+ zIndex: 6,
112
+ pointerEvents: "none"
113
+ }, others.freeCSS)
114
+ })
115
+ );
116
+ }
117
+ };
118
+ export {
119
+ Parts,
120
+ Parts as default
121
+ };
@@ -1 +1,12 @@
1
- import{b as t}from"../../chunk-VY3566IV.js";import{jsx as n}from"react/jsx-runtime";import{GenerateClassName as p}from"../../@utils/_";const a=e=>n("input",t({},p(e)));export{a as _Plain,a as default};
1
+ import {
2
+ __spreadValues
3
+ } from "../../chunk-JJ3PEWPN.js";
4
+ import { jsx } from "react/jsx-runtime";
5
+ import {
6
+ GenerateClassName
7
+ } from "../../@utils/_";
8
+ const _Plain = (params) => /* @__PURE__ */ jsx("input", __spreadValues({}, GenerateClassName(params)));
9
+ export {
10
+ _Plain,
11
+ _Plain as default
12
+ };