ingred-ui 33.12.0 → 33.12.1
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/dist/components/DataTable/internal/Table/Row.d.ts +6 -7
- package/dist/index.es.js +424 -424
- package/dist/index.es.js.map +1 -1
- package/dist/index.js +424 -424
- package/dist/index.js.map +1 -1
- package/package.json +13 -6
package/dist/index.es.js
CHANGED
|
@@ -1170,7 +1170,7 @@ object-assign
|
|
|
1170
1170
|
z-index: 1;
|
|
1171
1171
|
`,Qc=e=>{var{value:n,multiple:r=!1,disabled:s=!1,placeholder:c="選択してください",size:u="medium",variant:h="light",tagVariant:g,tagOverflow:f="truncate",showBulkActions:b=!1,selectAllLabel:v="すべて選択",clearAllLabel:x="すべてクリア",searchable:y=!1,searchPlaceholder:w="検索",noResultsMessage:C="見つかりませんでした",showOptionsOnlyWhenSearching:E=!1,searchPromptMessage:I="キーワードを入力してください",error:k=!1,applyButtonText:M="適用",cancelButtonText:$="キャンセル",children:A,onChange:L,onTempChange:V,width:H,minWidth:O,placement:S,middleware:R}=e,z=D(e,["value","multiple","disabled","placeholder","size","variant","tagVariant","tagOverflow","showBulkActions","selectAllLabel","clearAllLabel","searchable","searchPlaceholder","noResultsMessage","showOptionsOnlyWhenSearching","searchPromptMessage","error","applyButtonText","cancelButtonText","children","onChange","onTempChange","width","minWidth","placement","middleware"]);const[N,T]=i(!1),[Z,B]=i(""),[P,_]=i([]),[G,j]=i(!1),F=o(null),Y=l((()=>g||("light"===h?"dark":"light")),[h,g]),W=l((()=>r?Array.isArray(n)?n:[]:void 0!==n?[n]:[]),[n,r]),X=l((()=>{if(!A)return[];const e=[],t=n=>{p.forEach(n,(n=>{if(!m(n))return;const r=n;if(r.type&&"string"!=typeof r.type){const n=r.type.displayName||r.type.name;if("Select2Option"===n){const t=r.props.value,n=r.props.children,i=!!r.props.disabled,o=r.props.prepend,a=r.props.append;void 0!==t&&e.push({value:t,label:String(n),disabled:i,prepend:o,append:a})}else"Select2OptionGroup"===n&&r.props.children&&t(r.props.children)}}))};return t(A),e}),[A]),J=d((e=>{null==L||L(e)}),[L]),U=d((e=>{s||(T(e),e&&r&&_([...W]),e||B(""))}),[s,r,W]),Q=d((e=>{e.disabled||(J(e.value),T(!1),B(""))}),[J]),q=d(((e,t)=>{t.disabled||_((n=>e?[...n,t.value]:n.filter((e=>e!==t.value))))}),[]),K=d((()=>{r&&J(P),T(!1),B("")}),[J,r,P]),ee=d((()=>{T(!1),B("")}),[]),te=d((e=>{if(r&&Array.isArray(n)){const t=n.filter((t=>t!==e));J(t)}}),[r,n,J]),ne=d((e=>{B(e.target.value)}),[]),re=d((e=>{e.stopPropagation(),B("")}),[]),ie=d((()=>{s||U(!N)}),[s,U,N]),oe=l((()=>X.find((e=>e.value===n))),[X,n]),ae=l((()=>r&&Array.isArray(n)?X.filter((e=>n.includes(e.value))):[]),[r,X,n]),se=E&&y&&""===Z.trim(),ce=l((()=>new Set(r?[...W,...P]:W)),[r,W,P]),de=l((()=>{if(!y||!Z)return X;const e=Z.trim();if(!e)return X;const t=e.includes(","),n=e.startsWith('"')&&e.endsWith('"'),r=ys(e);return X.filter((i=>{const o=i.label.toLowerCase();return n?r.some((e=>o===e.toLowerCase())):t?r.some((e=>o.includes(e.toLowerCase()))):o.includes(e.toLowerCase())}))}),[X,Z,y]),ue=l((()=>X.filter((e=>ce.has(e.value)))),[X,ce]),pe=se?ue:de,me=d((()=>{const e=pe.filter((e=>!e.disabled)).map((e=>e.value));_((t=>[...new Set([...t,...e])]))}),[pe]),he=d((()=>{_([])}),[]),ge=d((()=>{F.current&&"wrap"!==f&&j(F.current.scrollWidth>F.current.clientWidth)}),[f]);a((()=>{if(!window.ResizeObserver)return;if(!F.current)return;ge();const e=new window.ResizeObserver((()=>{F.current&&ge()}));return e.observe(F.current),()=>{e.disconnect()}}),[ge,ae,f]),a((()=>{r&&Array.isArray(n)&&_(n)}),[r,n]),a((()=>{r&&"function"==typeof V&&V(P)}),[r,P]);const fe=l((()=>b&&r?t.createElement(Jc,null,t.createElement(Sc,{content:v,positionPriority:["top"],offset:[0,8],disabled:0===pe.length},t.createElement(cl,{icon:t.createElement(le,{name:"check_thin",color:"currentColor"}),size:"small",color:"secondaryDark",disabled:0===pe.length,onClick:me})),t.createElement(Sc,{content:x,positionPriority:["top"],offset:[0,8],disabled:0===pe.length},t.createElement(cl,{icon:t.createElement(le,{name:"close",color:"currentColor"}),size:"small",color:"secondaryDark",disabled:0===pe.length,onClick:he}))):null),[b,r,v,x,pe,me,he]),be=l((()=>y&&b&&r?t.createElement(Wc,null,t.createElement(Xc,null,t.createElement(Yc,{autoFocus:!0,placeholder:w,value:Z,onChange:ne}),Z&&t.createElement(Uc,{type:"button","aria-label":"検索をリセット",onClick:re},t.createElement(le,{name:"close_circle",type:"fill",color:"currentColor"}))),fe):y?t.createElement(Wc,null,t.createElement(Xc,null,t.createElement(Yc,{autoFocus:!0,placeholder:w,value:Z,onChange:ne}),Z&&t.createElement(Uc,{type:"button","aria-label":"検索をリセット",onClick:re},t.createElement(le,{name:"close_circle",type:"fill",color:"currentColor"})))):b&&r?fe:null),[y,b,r,Z,w,ne,re,fe]),ve=l((()=>r?t.createElement(Za,null,t.createElement(cl,{color:"clear",size:"small",onClick:ee},$),t.createElement(cl,{color:"primary",size:"small",onClick:K},M)):null),[r,K,ee,M,$]),xe=z,ye="string"==typeof xe["aria-label"]||"string"==typeof xe["aria-labelledby"],we=t.createElement(Nc,Object.assign({$disabled:s,$error:k,$hasValue:r?Array.isArray(n)&&n.length>0:!!oe,$isOpen:N,$multiple:r,$size:u,$variant:h,"aria-expanded":N,"aria-invalid":k,"aria-label":ye?void 0:c,disabled:s,role:"combobox",type:"button"},z),r&&Array.isArray(n)&&0===n.length?t.createElement(jc,{$disabled:s,$variant:h},c):!r&&t.createElement(Zc,null,oe?t.createElement(t.Fragment,null,oe.prepend&&t.createElement(Pc,{$size:u,$disabled:s},t.isValidElement(oe.prepend)&&oe.prepend.type===le?t.cloneElement(oe.prepend,{size:parseInt(Dc[u].iconSize,10),color:oe.prepend.props.color||"currentColor"}):oe.prepend),t.createElement(Bc,null,oe.label)):t.createElement(jc,{$disabled:s,$variant:h},c)),t.createElement(Fc,{$disabled:s,$size:u,$multiple:r},t.createElement(le,{name:"arrow_down",color:"currentColor"})));return t.createElement(Rc,null,t.createElement(zc,{$disabled:s,$error:k,$isOpen:N,$size:u,$variant:h,$tagOverflow:f,"data-disabled":s,"data-overflowing":"wrap"!==f&&G,style:{cursor:r||s?"default":"pointer"}},t.createElement(Da,null,t.createElement(Sa,{noResultsMessage:y?C:void 0,open:N,stickyFooter:ve,stickyHeader:be,trigger:we,width:H,minWidth:O,placement:S,middleware:R,onOpenChange:U},(()=>{if(se&&0===pe.length)return t.createElement(Ca,{message:I});const e=se||y&&!!Z?new Set(pe.map((e=>e.value))):void 0;if(A){const i=((e,i)=>{const o=[];let a=null;const l=(e,o,a)=>{const l=e.props.value,s=!!e.props.disabled,c=e.props.children,d=e.props.prepend,u=e.props.append;if(i&&!i.has(l))return null;const p=r?P.includes(l):l===n;return t.createElement(Ro,{key:`${o}-${a}`,checked:p,closeOnChange:!r,disabled:s,tabIndex:0,prepend:d,append:u,onChange:()=>{r?q(!p,{value:l,label:String(c),disabled:s,prepend:d,append:u}):Q({value:l,label:String(c),disabled:s,prepend:d,append:u})}},c)},s=()=>{if(null===a)return;const e=a,n=e.options.map(((t,n)=>l(t,`option-${e.label}`,n))).filter(Boolean);0!==n.length&&(o.push(t.createElement(Ra,{key:`heading-${e.label}`},e.label)),o.push(...n))};return p.forEach(e,(e=>{if(!m(e))return;const n=e;if(n.type&&"string"!=typeof n.type){const e=n.type.displayName||n.type.name;if("Select2OptionGroup"===e)null!==a&&s(),a={label:n.props.label,options:[]},n.props.children&&p.forEach(n.props.children,(e=>{if(m(e)){const t=e;"Select2Option"===(t.type.displayName||t.type.name)&&null!==a&&a.options.push(t)}}));else if("Select2Separator"===e)o.length>0&&o.push(t.createElement(Ta,{key:`separator-${o.length}`}));else if("Select2Option"===e)if(null!==a)a.options.push(n);else{const e=n.props.value;if(i&&!i.has(e))return;o.push(l(n,"option",o.length))}else o.push(n)}})),null!==a&&s(),o})(A,e);return 0===i.length?t.createElement(Ca,{message:C}):i}return pe.length>0?pe.map((e=>{const i=r?P.includes(e.value):e.value===n;return t.createElement(Ro,{key:e.value.toString(),checked:i,closeOnChange:!r,disabled:e.disabled,tabIndex:0,prepend:e.prepend,append:e.append,onChange:()=>{r?q(!i,e):Q(e)}},e.label)})):t.createElement(Ca,{message:C})})())),r&&t.createElement(Tc,{$tagOverflow:f},t.createElement(_c,{ref:F,$tagOverflow:f,"data-testid":"tag-container",onClick:ie},ae.map((e=>{const n=s?void 0:()=>te(e.value);return t.createElement(Gc,{key:e.value.toString(),disabled:s,label:e.label,size:u,variant:Y,onRemove:n})}))))))},qc=e=>null;qc.displayName="Select2Option";const Kc=e=>null;Kc.displayName="Select2OptionGroup";const ed=()=>null;ed.displayName="Select2Separator";const td=v(ke)`
|
|
1172
1172
|
${W}
|
|
1173
|
-
`,nd=e.forwardRef((function({children:t,size:n="md"},r){const i=ne();return e.createElement(de,{ref:r,display:"flex",alignItems:"center"},e.createElement(Ua,{pr:.5},e.createElement(le,{name:"alert",type:"fill",color:i.palette.danger.base,size:"sm"===n?"sm-md":n})),e.createElement(td,{color:i.palette.danger.base,size:n},t))})),rd=e=>{const{inputType:t,selectedValues:n,selectedRadioValue:r,startDate:i,endDate:o,value:a,isRangeOperator:l}=e;return"checkbox"===t?n:"radio"===t?[r]:l?[i,o]:[a]},id=(e,t)=>{const n=xt(e).find((e=>e.value===t));return(null==n?void 0:n.label)||t},od=e=>{const{conditionConfig:t,inputType:n,operator:r,values:i,dateFormat:o}=e;return i.map((e=>{if("checkbox"===n||"radio"===n){const n=((e,t)=>{if(t){const n=e.operators.find((e=>e.value===t));if(null==n?void 0:n.options)return n.options}return e.options||[]})(t,r).find((t=>t.value===e));return(null==n?void 0:n.label)||String(e)}if("date"===n&&o){const t=String(e);if(!t||""===t.trim())return t;const n=_a(t,"YYYY-MM-DD");return n.isValid()?n.format(o):t}return String(e)}))},ad=e=>{const{inputType:t,operator:n,selectedValues:r,selectedRadioValue:i,startDate:o,endDate:a,value:l,isRangeOperator:s,customValidation:c}=e;if("checkbox"===t){if(0===r.length)return{isValid:!1,errorMessage:"少なくとも1つの項目を選択してください"}}else if("radio"===t){if(""===i||null==i)return{isValid:!1,errorMessage:"項目を選択してください"}}else if(s){if(!o||!a)return{isValid:!1,errorMessage:"開始日と終了日の両方を選択してください"}}else if(!l||""===l.trim())return{isValid:!1,errorMessage:"date"===t?"日付を選択してください":"値を入力してください"};if(c){let e;return e="checkbox"===t?r:"radio"===t?[i]:s?[o,a]:[l],c(e,n)}return s&&new Date(o)>new Date(a)?{isValid:!1,errorMessage:"開始日は終了日より前である必要があります"}:{isValid:!0,errorMessage:""}},ld=e=>{const{inputType:t,selectedValues:n,selectedRadioValue:r,startDate:i,endDate:o,value:a,isRangeOperator:l}=e;return"checkbox"===t?n.length>0:"radio"===t?""!==r&&null!=r:l?!(!i||!o):!(!a||""===a.trim())},sd=e=>!1!==e.required,cd=(e,t)=>{const n=ft(t,e.conditionKey);return n?{condition:e,conditionConfig:n}:null},dd=e=>{const{condition:t,conditionConfig:n}=e,r=yt(n,t.operator),i=wt(n,t.operator);return ld({inputType:r,selectedValues:t.selectedValues,selectedRadioValue:t.selectedRadioValue,startDate:t.startDate,endDate:t.endDate,value:t.value,isRangeOperator:i})},ud=e=>{const{condition:t,conditionConfig:n}=e,r=yt(n,t.operator),i=wt(n,t.operator);return ad({inputType:r,operator:t.operator,selectedValues:t.selectedValues,selectedRadioValue:t.selectedRadioValue,startDate:t.startDate,endDate:t.endDate,value:t.value,isRangeOperator:i,customValidation:n.customValidation})},pd=({option:e})=>{var n;return e.icon?t.createElement(le,{name:e.icon,type:null!==(n=e.iconType)&&void 0!==n?n:"line",color:e.iconColor}):null};pd.displayName="OptionValueIcon";const md=({options:e,selectedValues:n,onValueToggle:r,disabled:i=!1})=>t.createElement(_t,null,e.map((e=>t.createElement(Ro,{key:String(e.value),checked:n.includes(e.value),disabled:i,prepend:e.icon?t.createElement(pd,{option:e}):void 0,onChange:t=>r(e.value,t)},e.label))));md.displayName="CheckboxValueInput";const hd=({options:e,selectedRadioValue:n,onRadioChange:r,disabled:i=!1})=>t.createElement(_t,null,e.map((e=>t.createElement(Ro,{key:String(e.value),checked:n===e.value,disabled:i,prepend:e.icon?t.createElement(pd,{option:e}):void 0,onChange:t=>{i||t&&r(e.value)}},e.label))));hd.displayName="RadioValueInput";const gd=640,fd=["日","月","火","水","木","金","土"],bd={components:{ConfirmModal:{defaultProps:{confirmText:"確認",cancelText:"キャンセル"}},FullSizeConfirmModal:{defaultProps:{confirmText:"確認",cancelText:"キャンセル"}},FileUploader:{defaultProps:{title:"ファイルをドラッグ&ドロップ、またはここをクリック"}},ItemEmpty:{defaultProps:{title:"見つかりませんでした。"}},Select:{defaultProps:{placeholder:"選択...",emptyMessage:"見つかりません"}},CreatableSelect:{defaultProps:{placeholder:"選択...",emptyMessage:"見つかりません",addMessage:"次の文字列を追加する"}},MultipleFilter:{defaultProps:{placeholder:"新しいフィルターを追加してください"}},FilterCard:{defaultProps:{applyButtonTitle:"適用",inputErrorText:"入力してください",formPlaceholder:"検索",sectionTitle:"セクション"}},EditFilterCard:{defaultProps:{}},DatePicker:{defaultProps:{monthFormat:"YYYY年MM月",weekConfig:{start:0,labels:[...fd]}}},DateRangePicker:{defaultProps:{monthFormat:"YYYY年MM月",weekConfig:{start:0,labels:[...fd]},applyButtonText:"適用",cancelButtonText:"キャンセル"}},WeekTime:{defaultProps:{weekList:["月","火","水","木","金","土","日"]}},WeekTimeSelector:{defaultProps:{weekList:["月","火","水","木","金","土","日"]}},DualListBox:{defaultProps:{selectedItemTitle:"個選択済み"}}}},vd={components:{ConfirmModal:{defaultProps:{confirmText:"确认",cancelText:"取消"}},FullSizeConfirmModal:{defaultProps:{confirmText:"确认",cancelText:"取消"}},FileUploader:{defaultProps:{title:"把文件拖入, 同样支持点击上传。"}},ItemEmpty:{defaultProps:{title:"未找到。"}}}},xd={components:{DatePicker:{defaultProps:{monthFormat:"MMM YYYY",weekConfig:{start:0,labels:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]}}},DateRangePicker:{defaultProps:{monthFormat:"MMM YYYY",weekConfig:{start:0,labels:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]},applyButtonText:"Apply",cancelButtonText:"Cancel"}},WeekTime:{defaultProps:{weekList:["Mon","Tue","Wed","Thu","Fri","Sat","Sun"]}},WeekTimeSelector:{defaultProps:{weekList:["Mon","Tue","Wed","Thu","Fri","Sat","Sun"]}},DualListBox:{defaultProps:{selectedItemTitle:"selected"}}}},yd=e.createContext({locale:xd}),wd=({locale:t,children:n})=>e.createElement(yd.Provider,{value:{locale:t}},n);function Cd(e){var n,r;const{name:i,props:o}=e,a=t.useContext(yd).locale,l=Object.assign({},o);if(!a||!a.components)return l;const s=null===(r=null===(n=a.components)||void 0===n?void 0:n[i])||void 0===r?void 0:r.defaultProps;for(const e in s)void 0===l[e]&&(l[e]=s[e]);return l}const Ed=n((function(e,n){const r=Cd({props:e,name:"DatePicker"}),{date:o,format:a="YYYY-MM-DD",disabled:s=!1,size:c="medium",variant:u="light",width:p,monthFormat:m,weekConfig:h,showDateFields:g=!1,showTimeFields:f=!1,timeFieldProps:b,useCalendarRange:v=!1,isOutsideRange:x,error:y=!1,errorText:w,defaultPresetButton:C,presetButtons:E,onPresetButtonClick:I,onDateChange:k,onDatesChange:M,endDate:$}=r,A=ne(),[L,V]=i(!1),{context:H,refs:O,strategy:S,x:D,y:R}=ho({placement:"bottom-start",open:L,onOpenChange:V,middleware:[hr(10),mr(),gr({padding:8})]}),z=po(H),N=Eo(H),{getReferenceProps:T,getFloatingProps:Z}=fo([z,N]),B=d((()=>{s||V((e=>!e))}),[s]),P=d((e=>{k(e),V(!1)}),[k]),_=l((()=>t.createElement(le,{name:"date_range",color:s?A.palette.neutral.base:A.palette.text.accent})),[s,A]),G=l((()=>"100%"===p||"string"==typeof p&&p.includes("100%")?{width:"100%"}:{width:"fit-content"}),[p]);return t.createElement(de,{ref:n,style:G},t.createElement("div",Object.assign({ref:O.setReference},T()),t.createElement(PC,{date:o,format:a,error:y,errorText:w,disabled:s,size:c,variant:u,width:p,append:_,onDateChange:k,onAppendClick:B})),L&&t.createElement(no,null,t.createElement(oo,{context:H,modal:!1,initialFocus:-1,returnFocus:!1},v?t.createElement(am,Object.assign({ref:O.setFloating,startDate:o,endDate:$||o,monthFormat:m,weekConfig:h,defaultPresetButton:C,presetButtons:E,showDateFields:g,showTimeFields:f,timeFieldProps:b,dateFieldFormat:a,isOutsideRange:x,style:{position:S,top:null!=R?R:0,left:null!=D?D:0,zIndex:A.depth.calendarRange,overflow:"hidden",maxWidth:"min(640px, calc(100vw - 16px))"},onPresetButtonClick:I,onDatesChange:M},Z())):t.createElement(Tp,Object.assign({ref:O.setFloating,date:o,monthFormat:m,weekConfig:h,defaultPresetButton:C,presetButtons:E,showDateFields:g,showTimeFields:f,timeFieldProps:b,dateFieldFormat:a,isOutsideRange:x,style:{position:S,top:null!=R?R:0,left:null!=D?D:0,zIndex:A.depth.calendar,overflow:"hidden",maxWidth:"min(640px, calc(100vw - 16px))"},onPresetButtonClick:I,onDateChange:P},Z())))))}));var Id=g(Ed);const kd=({startDate:e,endDate:n,onStartDateChange:r,onEndDateChange:i,format:o="YYYY-MM-DD",disabled:a=!1})=>{const s=l((()=>{if(e&&""!==e.trim()){const t=_a(e,"YYYY-MM-DD");return t.isValid()?t:_a()}return _a()}),[e]),c=l((()=>{if(n&&""!==n.trim()){const e=_a(n,"YYYY-MM-DD");return e.isValid()?e:_a()}return _a()}),[n]);return t.createElement(zt,null,t.createElement(Tt,null,t.createElement(Pt,{htmlFor:"start-date-picker"},"開始日"),t.createElement(Id,{date:s,format:o,variant:"dark",width:"100%",disabled:a,onDateChange:e=>{r(e.format("YYYY-MM-DD"))}})),t.createElement(Tt,null,t.createElement(Pt,{htmlFor:"end-date-picker"},"終了日"),t.createElement(Id,{date:c,format:o,variant:"dark",width:"100%",disabled:a,onDateChange:e=>{i(e.format("YYYY-MM-DD"))}})))};kd.displayName="DateRangeInput";const Md=({inputType:e,value:n,placeholder:r,onValueChange:i,onKeyDown:o,format:a="YYYY-MM-DD",inputRef:s,disabled:c=!1})=>{const d=l((()=>{if("date"===e&&n&&""!==n.trim()){const e=_a(n,"YYYY-MM-DD");return e.isValid()?e:_a()}return _a()}),[e,n]),u=e=>{const t=e.format("YYYY-MM-DD");i(t)};return"date"===e?t.createElement(Bt,null,t.createElement(Id,{date:d,format:a,variant:"dark",width:"100%",disabled:c,onDateChange:u})):t.createElement(Zt,null,t.createElement(va,{ref:s,type:"text",value:n,placeholder:r,fullWidth:!0,variant:"dark",disabled:c,onChange:e=>i(e.target.value),onKeyDown:o}))};Md.displayName="TextValueInput";const $d=({filterConfig:e,operator:n,value:r,selectedValues:i,selectedRadioValue:o,startDate:a,endDate:l,onValueChange:s,onValueToggle:c,onRadioChange:d,onStartDateChange:u,onEndDateChange:p,onKeyDown:m,isRangeOperator:h,textInputRef:g,disabled:f=!1})=>{const b=nt(e,n);return"checkbox"===b?t.createElement(md,{options:it(e,n),selectedValues:i,disabled:f,onValueToggle:c}):"radio"===b?t.createElement(hd,{options:it(e,n),selectedRadioValue:o,disabled:f,onRadioChange:d}):h(n)?t.createElement(kd,{startDate:a,endDate:l,format:ot(e),disabled:f,onStartDateChange:u,onEndDateChange:p}):t.createElement(Md,{inputType:b,inputRef:"text"===b?g:void 0,value:r,placeholder:rt(e),format:"date"===b?ot(e):void 0,disabled:f,onValueChange:s,onKeyDown:m})};$d.displayName="ConfigPanelValueInput";const Ad=(e,t,n)=>{if(!t)return((e,t)=>{const n=vt(e),r=yt(e,n);let i="",o="",a="";return wt(e,n)?(o=t,a=t):"date"===r&&(i=t),{id:`condition_${e.conditionKey}`,conditionKey:e.conditionKey,conditionLabel:e.conditionLabel,operator:n,value:i,selectedValues:[],selectedRadioValue:"",startDate:o,endDate:a}})(e,n);let r="",i=[],o="",a="",l="";if((t.isRange||!1)&&t.values.length>=2)a="string"==typeof t.values[0]?t.values[0]:"",l="string"==typeof t.values[1]?t.values[1]:"";else if(t.values.length>0){const e=t.values[0];"string"==typeof e&&(r=e),i=t.values,o=e}return{id:`condition_${e.conditionKey}`,conditionKey:t.conditionKey,conditionLabel:t.conditionLabel,operator:t.operator,value:r,selectedValues:i,selectedRadioValue:o,startDate:a,endDate:l}},Ld={xs:{iconSize:12,height:"18px",pillHeight:"18px",gap:"2px",padding:e=>.5*e.spacing+"px",signalPaddingLeft:"2px",signalPaddingRight:"4px",dotSize:12,fontSize:"11px"},small:{iconSize:14,height:"22px",pillHeight:"20px",gap:"2px",padding:e=>.75*e.spacing+"px",signalPaddingLeft:"4px",signalPaddingRight:"6px",dotSize:14,fontSize:"12px"},medium:{iconSize:16,height:"24px",pillHeight:"24px",gap:"4px",padding:e=>`${e.spacing}px`,signalPaddingLeft:"4px",signalPaddingRight:"6px",dotSize:16,fontSize:"13px"}},Vd={normal:{primary:e=>e.palette.primary.highlight,secondaryDark:e=>e.palette.neutral.softLight,success:e=>e.palette.success.softLight||e.palette.success.lighter,warning:e=>e.palette.warning.highlight,danger:e=>e.palette.danger.highlight,inverse:e=>e.palette.black},pill:{primary:e=>e.palette.primary.base,secondaryDark:e=>e.palette.neutral.softLight,success:e=>e.palette.success.base,warning:e=>e.palette.warning.base,danger:e=>e.palette.danger.base,inverse:e=>e.palette.black},signal:{primary:e=>e.palette.primary.base,secondaryDark:e=>e.palette.neutral.base,success:e=>e.palette.success.base,warning:e=>e.palette.warning.base,danger:e=>e.palette.danger.base,inverse:e=>e.palette.black}},Hd={normal:{primary:e=>e.palette.text.accent,secondaryDark:e=>e.palette.text.secondary,success:e=>e.palette.success.darker,warning:e=>e.palette.warning.ultraDark,danger:e=>e.palette.danger.base,inverse:e=>e.palette.text.white},pill:{primary:e=>e.palette.text.white,secondaryDark:e=>e.palette.text.secondary,success:e=>e.palette.text.white,warning:e=>e.palette.warning.ultraDark,danger:e=>e.palette.text.white,inverse:e=>e.palette.text.white},signal:{primary:e=>e.palette.text.accent,secondaryDark:e=>e.palette.text.secondary,success:e=>e.palette.success.darker,warning:e=>e.palette.warning.ultraDark,danger:e=>e.palette.danger.darker,inverse:e=>e.palette.text.primary}},Od=(e,t,n)=>Vd[n][e](t),Sd=(e,t,n)=>Hd[n][e](t),Dd={primary:e=>e.palette.primary.base,secondaryDark:e=>e.palette.neutral.light,success:e=>e.palette.success.base,warning:e=>e.palette.warning.base,danger:e=>e.palette.danger.base,inverse:e=>e.palette.neutral.light},Rd=(e,t)=>Dd[e](t),zd={primary:e=>e.palette.primary.ultraLight,secondaryDark:e=>e.palette.neutral.ultraLight,success:e=>e.palette.success.ultraLight,warning:e=>e.palette.warning.ultraLight,danger:e=>e.palette.danger.ultraLight,inverse:e=>e.palette.neutral.pure},Nd=(e,t)=>zd[e](t),Td=y`
|
|
1173
|
+
`,nd=e.forwardRef((function({children:t,size:n="md"},r){const i=ne();return e.createElement(de,{ref:r,display:"flex",alignItems:"center"},e.createElement(Ua,{pr:.5},e.createElement(le,{name:"alert",type:"fill",color:i.palette.danger.base,size:"sm"===n?"sm-md":n})),e.createElement(td,{color:i.palette.danger.base,size:n},t))})),rd=e=>{const{inputType:t,selectedValues:n,selectedRadioValue:r,startDate:i,endDate:o,value:a,isRangeOperator:l}=e;return"checkbox"===t?n:"radio"===t?[r]:l?[i,o]:[a]},id=(e,t)=>{const n=xt(e).find((e=>e.value===t));return(null==n?void 0:n.label)||t},od=e=>{const{conditionConfig:t,inputType:n,operator:r,values:i,dateFormat:o}=e;return i.map((e=>{if("checkbox"===n||"radio"===n){const n=((e,t)=>{if(t){const n=e.operators.find((e=>e.value===t));if(null==n?void 0:n.options)return n.options}return e.options||[]})(t,r).find((t=>t.value===e));return(null==n?void 0:n.label)||String(e)}if("date"===n&&o){const t=String(e);if(!t||""===t.trim())return t;const n=_a(t,"YYYY-MM-DD");return n.isValid()?n.format(o):t}return String(e)}))},ad=e=>{const{inputType:t,operator:n,selectedValues:r,selectedRadioValue:i,startDate:o,endDate:a,value:l,isRangeOperator:s,customValidation:c}=e;if("checkbox"===t){if(0===r.length)return{isValid:!1,errorMessage:"少なくとも1つの項目を選択してください"}}else if("radio"===t){if(""===i||null==i)return{isValid:!1,errorMessage:"項目を選択してください"}}else if(s){if(!o||!a)return{isValid:!1,errorMessage:"開始日と終了日の両方を選択してください"}}else if(!l||""===l.trim())return{isValid:!1,errorMessage:"date"===t?"日付を選択してください":"値を入力してください"};if(c){let e;return e="checkbox"===t?r:"radio"===t?[i]:s?[o,a]:[l],c(e,n)}return s&&new Date(o)>new Date(a)?{isValid:!1,errorMessage:"開始日は終了日より前である必要があります"}:{isValid:!0,errorMessage:""}},ld=e=>{const{inputType:t,selectedValues:n,selectedRadioValue:r,startDate:i,endDate:o,value:a,isRangeOperator:l}=e;return"checkbox"===t?n.length>0:"radio"===t?""!==r&&null!=r:l?!(!i||!o):!(!a||""===a.trim())},sd=e=>!1!==e.required,cd=(e,t)=>{const n=ft(t,e.conditionKey);return n?{condition:e,conditionConfig:n}:null},dd=e=>{const{condition:t,conditionConfig:n}=e,r=yt(n,t.operator),i=wt(n,t.operator);return ld({inputType:r,selectedValues:t.selectedValues,selectedRadioValue:t.selectedRadioValue,startDate:t.startDate,endDate:t.endDate,value:t.value,isRangeOperator:i})},ud=e=>{const{condition:t,conditionConfig:n}=e,r=yt(n,t.operator),i=wt(n,t.operator);return ad({inputType:r,operator:t.operator,selectedValues:t.selectedValues,selectedRadioValue:t.selectedRadioValue,startDate:t.startDate,endDate:t.endDate,value:t.value,isRangeOperator:i,customValidation:n.customValidation})},pd=({option:e})=>{var n;return e.icon?t.createElement(le,{name:e.icon,type:null!==(n=e.iconType)&&void 0!==n?n:"line",color:e.iconColor}):null};pd.displayName="OptionValueIcon";const md=({options:e,selectedValues:n,onValueToggle:r,disabled:i=!1})=>t.createElement(_t,null,e.map((e=>t.createElement(Ro,{key:String(e.value),checked:n.includes(e.value),disabled:i,prepend:e.icon?t.createElement(pd,{option:e}):void 0,onChange:t=>r(e.value,t)},e.label))));md.displayName="CheckboxValueInput";const hd=({options:e,selectedRadioValue:n,onRadioChange:r,disabled:i=!1})=>t.createElement(_t,null,e.map((e=>t.createElement(Ro,{key:String(e.value),checked:n===e.value,disabled:i,prepend:e.icon?t.createElement(pd,{option:e}):void 0,onChange:t=>{i||t&&r(e.value)}},e.label))));hd.displayName="RadioValueInput";const gd=640,fd=["日","月","火","水","木","金","土"],bd={components:{ConfirmModal:{defaultProps:{confirmText:"確認",cancelText:"キャンセル"}},FullSizeConfirmModal:{defaultProps:{confirmText:"確認",cancelText:"キャンセル"}},FileUploader:{defaultProps:{title:"ファイルをドラッグ&ドロップ、またはここをクリック"}},ItemEmpty:{defaultProps:{title:"見つかりませんでした。"}},Select:{defaultProps:{placeholder:"選択...",emptyMessage:"見つかりません"}},CreatableSelect:{defaultProps:{placeholder:"選択...",emptyMessage:"見つかりません",addMessage:"次の文字列を追加する"}},MultipleFilter:{defaultProps:{placeholder:"新しいフィルターを追加してください"}},FilterCard:{defaultProps:{applyButtonTitle:"適用",inputErrorText:"入力してください",formPlaceholder:"検索",sectionTitle:"セクション"}},EditFilterCard:{defaultProps:{}},DatePicker:{defaultProps:{monthFormat:"YYYY年MM月",weekConfig:{start:0,labels:[...fd]}}},DateRangePicker:{defaultProps:{monthFormat:"YYYY年MM月",weekConfig:{start:0,labels:[...fd]},applyButtonText:"適用",cancelButtonText:"キャンセル"}},WeekTime:{defaultProps:{weekList:["月","火","水","木","金","土","日"]}},WeekTimeSelector:{defaultProps:{weekList:["月","火","水","木","金","土","日"]}},DualListBox:{defaultProps:{selectedItemTitle:"個選択済み"}}}},vd={components:{ConfirmModal:{defaultProps:{confirmText:"确认",cancelText:"取消"}},FullSizeConfirmModal:{defaultProps:{confirmText:"确认",cancelText:"取消"}},FileUploader:{defaultProps:{title:"把文件拖入, 同样支持点击上传。"}},ItemEmpty:{defaultProps:{title:"未找到。"}}}},xd={components:{DatePicker:{defaultProps:{monthFormat:"MMM YYYY",weekConfig:{start:0,labels:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]}}},DateRangePicker:{defaultProps:{monthFormat:"MMM YYYY",weekConfig:{start:0,labels:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"]},applyButtonText:"Apply",cancelButtonText:"Cancel"}},WeekTime:{defaultProps:{weekList:["Mon","Tue","Wed","Thu","Fri","Sat","Sun"]}},WeekTimeSelector:{defaultProps:{weekList:["Mon","Tue","Wed","Thu","Fri","Sat","Sun"]}},DualListBox:{defaultProps:{selectedItemTitle:"selected"}}}},yd=e.createContext({locale:xd}),wd=({locale:t,children:n})=>e.createElement(yd.Provider,{value:{locale:t}},n);function Cd(e){var n,r;const{name:i,props:o}=e,a=t.useContext(yd).locale,l=Object.assign({},o);if(!a||!a.components)return l;const s=null===(r=null===(n=a.components)||void 0===n?void 0:n[i])||void 0===r?void 0:r.defaultProps;for(const e in s)void 0===l[e]&&(l[e]=s[e]);return l}const Ed=n((function(e,n){const r=Cd({props:e,name:"DatePicker"}),{date:o,format:a="YYYY-MM-DD",disabled:s=!1,size:c="medium",variant:u="light",width:p,monthFormat:m,weekConfig:h,showDateFields:g=!1,showTimeFields:f=!1,timeFieldProps:b,useCalendarRange:v=!1,isOutsideRange:x,error:y=!1,errorText:w,defaultPresetButton:C,presetButtons:E,onPresetButtonClick:I,onDateChange:k,onDatesChange:M,endDate:$}=r,A=ne(),[L,V]=i(!1),{context:H,refs:O,strategy:S,x:D,y:R}=ho({placement:"bottom-start",open:L,onOpenChange:V,middleware:[hr(10),mr(),gr({padding:8})]}),z=po(H),N=Eo(H),{getReferenceProps:T,getFloatingProps:Z}=fo([z,N]),B=d((()=>{s||V((e=>!e))}),[s]),P=d((e=>{k(e),V(!1)}),[k]),_=l((()=>t.createElement(le,{name:"date_range",color:s?A.palette.neutral.base:A.palette.text.accent})),[s,A]),G=l((()=>"100%"===p||"string"==typeof p&&p.includes("100%")?{width:"100%"}:{width:"fit-content"}),[p]);return t.createElement(de,{ref:n,style:G},t.createElement("div",Object.assign({ref:O.setReference},T()),t.createElement(_C,{date:o,format:a,error:y,errorText:w,disabled:s,size:c,variant:u,width:p,append:_,onDateChange:k,onAppendClick:B})),L&&t.createElement(no,null,t.createElement(oo,{context:H,modal:!1,initialFocus:-1,returnFocus:!1},v?t.createElement(am,Object.assign({ref:O.setFloating,startDate:o,endDate:$||o,monthFormat:m,weekConfig:h,defaultPresetButton:C,presetButtons:E,showDateFields:g,showTimeFields:f,timeFieldProps:b,dateFieldFormat:a,isOutsideRange:x,style:{position:S,top:null!=R?R:0,left:null!=D?D:0,zIndex:A.depth.calendarRange,overflow:"hidden",maxWidth:"min(640px, calc(100vw - 16px))"},onPresetButtonClick:I,onDatesChange:M},Z())):t.createElement(Tp,Object.assign({ref:O.setFloating,date:o,monthFormat:m,weekConfig:h,defaultPresetButton:C,presetButtons:E,showDateFields:g,showTimeFields:f,timeFieldProps:b,dateFieldFormat:a,isOutsideRange:x,style:{position:S,top:null!=R?R:0,left:null!=D?D:0,zIndex:A.depth.calendar,overflow:"hidden",maxWidth:"min(640px, calc(100vw - 16px))"},onPresetButtonClick:I,onDateChange:P},Z())))))}));var Id=g(Ed);const kd=({startDate:e,endDate:n,onStartDateChange:r,onEndDateChange:i,format:o="YYYY-MM-DD",disabled:a=!1})=>{const s=l((()=>{if(e&&""!==e.trim()){const t=_a(e,"YYYY-MM-DD");return t.isValid()?t:_a()}return _a()}),[e]),c=l((()=>{if(n&&""!==n.trim()){const e=_a(n,"YYYY-MM-DD");return e.isValid()?e:_a()}return _a()}),[n]);return t.createElement(zt,null,t.createElement(Tt,null,t.createElement(Pt,{htmlFor:"start-date-picker"},"開始日"),t.createElement(Id,{date:s,format:o,variant:"dark",width:"100%",disabled:a,onDateChange:e=>{r(e.format("YYYY-MM-DD"))}})),t.createElement(Tt,null,t.createElement(Pt,{htmlFor:"end-date-picker"},"終了日"),t.createElement(Id,{date:c,format:o,variant:"dark",width:"100%",disabled:a,onDateChange:e=>{i(e.format("YYYY-MM-DD"))}})))};kd.displayName="DateRangeInput";const Md=({inputType:e,value:n,placeholder:r,onValueChange:i,onKeyDown:o,format:a="YYYY-MM-DD",inputRef:s,disabled:c=!1})=>{const d=l((()=>{if("date"===e&&n&&""!==n.trim()){const e=_a(n,"YYYY-MM-DD");return e.isValid()?e:_a()}return _a()}),[e,n]),u=e=>{const t=e.format("YYYY-MM-DD");i(t)};return"date"===e?t.createElement(Bt,null,t.createElement(Id,{date:d,format:a,variant:"dark",width:"100%",disabled:c,onDateChange:u})):t.createElement(Zt,null,t.createElement(va,{ref:s,type:"text",value:n,placeholder:r,fullWidth:!0,variant:"dark",disabled:c,onChange:e=>i(e.target.value),onKeyDown:o}))};Md.displayName="TextValueInput";const $d=({filterConfig:e,operator:n,value:r,selectedValues:i,selectedRadioValue:o,startDate:a,endDate:l,onValueChange:s,onValueToggle:c,onRadioChange:d,onStartDateChange:u,onEndDateChange:p,onKeyDown:m,isRangeOperator:h,textInputRef:g,disabled:f=!1})=>{const b=nt(e,n);return"checkbox"===b?t.createElement(md,{options:it(e,n),selectedValues:i,disabled:f,onValueToggle:c}):"radio"===b?t.createElement(hd,{options:it(e,n),selectedRadioValue:o,disabled:f,onRadioChange:d}):h(n)?t.createElement(kd,{startDate:a,endDate:l,format:ot(e),disabled:f,onStartDateChange:u,onEndDateChange:p}):t.createElement(Md,{inputType:b,inputRef:"text"===b?g:void 0,value:r,placeholder:rt(e),format:"date"===b?ot(e):void 0,disabled:f,onValueChange:s,onKeyDown:m})};$d.displayName="ConfigPanelValueInput";const Ad=(e,t,n)=>{if(!t)return((e,t)=>{const n=vt(e),r=yt(e,n);let i="",o="",a="";return wt(e,n)?(o=t,a=t):"date"===r&&(i=t),{id:`condition_${e.conditionKey}`,conditionKey:e.conditionKey,conditionLabel:e.conditionLabel,operator:n,value:i,selectedValues:[],selectedRadioValue:"",startDate:o,endDate:a}})(e,n);let r="",i=[],o="",a="",l="";if((t.isRange||!1)&&t.values.length>=2)a="string"==typeof t.values[0]?t.values[0]:"",l="string"==typeof t.values[1]?t.values[1]:"";else if(t.values.length>0){const e=t.values[0];"string"==typeof e&&(r=e),i=t.values,o=e}return{id:`condition_${e.conditionKey}`,conditionKey:t.conditionKey,conditionLabel:t.conditionLabel,operator:t.operator,value:r,selectedValues:i,selectedRadioValue:o,startDate:a,endDate:l}},Ld={xs:{iconSize:12,height:"18px",pillHeight:"18px",gap:"2px",padding:e=>.5*e.spacing+"px",signalPaddingLeft:"2px",signalPaddingRight:"4px",dotSize:12,fontSize:"11px"},small:{iconSize:14,height:"22px",pillHeight:"20px",gap:"2px",padding:e=>.75*e.spacing+"px",signalPaddingLeft:"4px",signalPaddingRight:"6px",dotSize:14,fontSize:"12px"},medium:{iconSize:16,height:"24px",pillHeight:"24px",gap:"4px",padding:e=>`${e.spacing}px`,signalPaddingLeft:"4px",signalPaddingRight:"6px",dotSize:16,fontSize:"13px"}},Vd={normal:{primary:e=>e.palette.primary.highlight,secondaryDark:e=>e.palette.neutral.softLight,success:e=>e.palette.success.softLight||e.palette.success.lighter,warning:e=>e.palette.warning.highlight,danger:e=>e.palette.danger.highlight,inverse:e=>e.palette.black},pill:{primary:e=>e.palette.primary.base,secondaryDark:e=>e.palette.neutral.softLight,success:e=>e.palette.success.base,warning:e=>e.palette.warning.base,danger:e=>e.palette.danger.base,inverse:e=>e.palette.black},signal:{primary:e=>e.palette.primary.base,secondaryDark:e=>e.palette.neutral.base,success:e=>e.palette.success.base,warning:e=>e.palette.warning.base,danger:e=>e.palette.danger.base,inverse:e=>e.palette.black}},Hd={normal:{primary:e=>e.palette.text.accent,secondaryDark:e=>e.palette.text.secondary,success:e=>e.palette.success.darker,warning:e=>e.palette.warning.ultraDark,danger:e=>e.palette.danger.base,inverse:e=>e.palette.text.white},pill:{primary:e=>e.palette.text.white,secondaryDark:e=>e.palette.text.secondary,success:e=>e.palette.text.white,warning:e=>e.palette.warning.ultraDark,danger:e=>e.palette.text.white,inverse:e=>e.palette.text.white},signal:{primary:e=>e.palette.text.accent,secondaryDark:e=>e.palette.text.secondary,success:e=>e.palette.success.darker,warning:e=>e.palette.warning.ultraDark,danger:e=>e.palette.danger.darker,inverse:e=>e.palette.text.primary}},Od=(e,t,n)=>Vd[n][e](t),Sd=(e,t,n)=>Hd[n][e](t),Dd={primary:e=>e.palette.primary.base,secondaryDark:e=>e.palette.neutral.light,success:e=>e.palette.success.base,warning:e=>e.palette.warning.base,danger:e=>e.palette.danger.base,inverse:e=>e.palette.neutral.light},Rd=(e,t)=>Dd[e](t),zd={primary:e=>e.palette.primary.ultraLight,secondaryDark:e=>e.palette.neutral.ultraLight,success:e=>e.palette.success.ultraLight,warning:e=>e.palette.warning.ultraLight,danger:e=>e.palette.danger.ultraLight,inverse:e=>e.palette.neutral.pure},Nd=(e,t)=>zd[e](t),Td=y`
|
|
1174
1174
|
display: inline-flex;
|
|
1175
1175
|
align-items: center;
|
|
1176
1176
|
justify-content: center;
|
|
@@ -1636,7 +1636,7 @@ object-assign
|
|
|
1636
1636
|
background-color: transparent;
|
|
1637
1637
|
color: ${({theme:e})=>e.palette.neutral.lighter};
|
|
1638
1638
|
}
|
|
1639
|
-
`,kp=g((function({selected:e,value:n,selectable:r,onClickDate:i,children:o,isSaturday:a=!1,isSundayOrHoliday:l=!1,isToday:s=!1}){return t.createElement(wp,{isToday:s},r?t.createElement(Ep,{type:"button",selected:e,isSaturday:a,isSundayOrHoliday:l,onClick:()=>{null==i||i(n)}},o):t.createElement(Ip,{type:"button",isSaturday:a,isSundayOrHoliday:l},o))})),Mp=e=>(e=>{try{const t=e.year(),n=pl(t),r=e.format("YYYY/M/D");return n.some((e=>e.date===r))}catch(e){return!1}})(e),$p=e=>e.format("YYYY-MM-DD")===_a().format("YYYY-MM-DD"),Ap=(e,t)=>_a(new Date(e.year(),e.month(),t)),Lp=e=>(e=>{const t=e.day(),n=0===t,r=6===t,i=Mp(e);return{dayOfWeek:t,isSunday:n,isSaturday:r,isHoliday:i,isSundayOrHoliday:n||i}})(e),Vp=(e,t)=>!t(e),Hp=e=>Array.from(new Array(e.daysInMonth()),((e,t)=>t+1)),Op=(e,t=0)=>(e.startOf("month").day()-t+7)%7,Sp=({date:e,weekList:n,weekStart:r=0,monthFormat:i,current:o,isOutsideRange:a,onDateChange:l,onPreviousMonth:s,onNextMonth:c})=>t.createElement(ep,null,t.createElement(ap,null,t.createElement(op,null,t.createElement(ip,null,t.createElement(rp,{weight:"bold",size:"xl"},o.format(i))),t.createElement("div",{style:{display:"flex",gap:"8px"}},t.createElement(cl,{size:"small",color:"clear",icon:t.createElement(le,{name:"arrow_left",size:"md",color:"currentColor"}),type:"button","aria-label":"前の月",onClick:s}),t.createElement(Sc,{content:"今日を選択"},t.createElement(cl,{size:"small",color:"clear",icon:t.createElement(le,{name:"calendar",size:"md",color:"currentColor"}),type:"button","aria-label":"今日を選択",onClick:()=>l(_a())})),t.createElement(cl,{size:"small",color:"clear",icon:t.createElement(le,{name:"arrow_right",size:"md",color:"currentColor"}),type:"button","aria-label":"次の月",onClick:c})))),t.createElement(tp,null,null==n?void 0:n.map((e=>t.createElement(np,{key:e},e))),Array.from(new Array(Op(o,r)),((e,n)=>t.createElement(np,{key:`empty-${n}`}))),Hp(o).map((n=>{const r=Ap(o,n),i=Lp(r),s=e.format("YYYY-MM-DD")===r.format("YYYY-MM-DD"),c=Vp(r,a);return t.createElement(kp,{key:n,value:r,selectable:c,selected:s,isSaturday:i.isSaturday,isSundayOrHoliday:i.isSundayOrHoliday,isToday:$p(r),onClickDate:l},n)})))),Dp=e=>{const[t,n]=i(e),r=d((()=>{n((e=>e.subtract(1,"month")))}),[]),o=d((()=>{n((e=>e.add(1,"month")))}),[]);return{currentMonth:t,goToPreviousMonth:r,goToNextMonth:o,goToMonth:d((e=>{n(e)}),[])}};function Rp(e){return(Math.trunc(e)%7+7)%7}function zp(e){const{weekConfig:t,fallbackLabels:n,fallbackStart:r}=e;if(void 0!==t){if(7!==t.labels.length)throw new Error("ingred-ui Calendar: weekConfig.labels must contain exactly 7 entries");return Object.assign(Object.assign({},t),{start:Rp(t.start)})}return{start:Rp(r),labels:n}}const Np=n((function(e,n){var{date:r,monthFormat:i="YYYY年M月",weekConfig:o,defaultPresetButton:s,presetButtons:c,onPresetButtonClick:u,showDateFields:p=!1,dateFieldFormat:m="YYYY-MM-DD",showTimeFields:h=!1,timeFieldProps:g,labelSuffix:f,isOutsideRange:b=(()=>!1),onDateChange:v}=e,x=D(e,["date","monthFormat","weekConfig","defaultPresetButton","presetButtons","onPresetButtonClick","showDateFields","dateFieldFormat","showTimeFields","timeFieldProps","labelSuffix","isOutsideRange","onDateChange"]);const[y,w]=t.useState(0),{currentMonth:C,goToPreviousMonth:E,goToNextMonth:I,goToMonth:k}=Dp(r),M=d((e=>{const t=r.hour(e.hour()).minute(e.minute()).second(0).millisecond(0);v(t)}),[r,v]),$=l((()=>p?t.createElement(bp,null,t.createElement(gp,null,t.createElement(xp,null,t.createElement(vp,null,"日付"),f),t.createElement(fp,null,t.createElement(
|
|
1639
|
+
`,kp=g((function({selected:e,value:n,selectable:r,onClickDate:i,children:o,isSaturday:a=!1,isSundayOrHoliday:l=!1,isToday:s=!1}){return t.createElement(wp,{isToday:s},r?t.createElement(Ep,{type:"button",selected:e,isSaturday:a,isSundayOrHoliday:l,onClick:()=>{null==i||i(n)}},o):t.createElement(Ip,{type:"button",isSaturday:a,isSundayOrHoliday:l},o))})),Mp=e=>(e=>{try{const t=e.year(),n=pl(t),r=e.format("YYYY/M/D");return n.some((e=>e.date===r))}catch(e){return!1}})(e),$p=e=>e.format("YYYY-MM-DD")===_a().format("YYYY-MM-DD"),Ap=(e,t)=>_a(new Date(e.year(),e.month(),t)),Lp=e=>(e=>{const t=e.day(),n=0===t,r=6===t,i=Mp(e);return{dayOfWeek:t,isSunday:n,isSaturday:r,isHoliday:i,isSundayOrHoliday:n||i}})(e),Vp=(e,t)=>!t(e),Hp=e=>Array.from(new Array(e.daysInMonth()),((e,t)=>t+1)),Op=(e,t=0)=>(e.startOf("month").day()-t+7)%7,Sp=({date:e,weekList:n,weekStart:r=0,monthFormat:i,current:o,isOutsideRange:a,onDateChange:l,onPreviousMonth:s,onNextMonth:c})=>t.createElement(ep,null,t.createElement(ap,null,t.createElement(op,null,t.createElement(ip,null,t.createElement(rp,{weight:"bold",size:"xl"},o.format(i))),t.createElement("div",{style:{display:"flex",gap:"8px"}},t.createElement(cl,{size:"small",color:"clear",icon:t.createElement(le,{name:"arrow_left",size:"md",color:"currentColor"}),type:"button","aria-label":"前の月",onClick:s}),t.createElement(Sc,{content:"今日を選択"},t.createElement(cl,{size:"small",color:"clear",icon:t.createElement(le,{name:"calendar",size:"md",color:"currentColor"}),type:"button","aria-label":"今日を選択",onClick:()=>l(_a())})),t.createElement(cl,{size:"small",color:"clear",icon:t.createElement(le,{name:"arrow_right",size:"md",color:"currentColor"}),type:"button","aria-label":"次の月",onClick:c})))),t.createElement(tp,null,null==n?void 0:n.map((e=>t.createElement(np,{key:e},e))),Array.from(new Array(Op(o,r)),((e,n)=>t.createElement(np,{key:`empty-${n}`}))),Hp(o).map((n=>{const r=Ap(o,n),i=Lp(r),s=e.format("YYYY-MM-DD")===r.format("YYYY-MM-DD"),c=Vp(r,a);return t.createElement(kp,{key:n,value:r,selectable:c,selected:s,isSaturday:i.isSaturday,isSundayOrHoliday:i.isSundayOrHoliday,isToday:$p(r),onClickDate:l},n)})))),Dp=e=>{const[t,n]=i(e),r=d((()=>{n((e=>e.subtract(1,"month")))}),[]),o=d((()=>{n((e=>e.add(1,"month")))}),[]);return{currentMonth:t,goToPreviousMonth:r,goToNextMonth:o,goToMonth:d((e=>{n(e)}),[])}};function Rp(e){return(Math.trunc(e)%7+7)%7}function zp(e){const{weekConfig:t,fallbackLabels:n,fallbackStart:r}=e;if(void 0!==t){if(7!==t.labels.length)throw new Error("ingred-ui Calendar: weekConfig.labels must contain exactly 7 entries");return Object.assign(Object.assign({},t),{start:Rp(t.start)})}return{start:Rp(r),labels:n}}const Np=n((function(e,n){var{date:r,monthFormat:i="YYYY年M月",weekConfig:o,defaultPresetButton:s,presetButtons:c,onPresetButtonClick:u,showDateFields:p=!1,dateFieldFormat:m="YYYY-MM-DD",showTimeFields:h=!1,timeFieldProps:g,labelSuffix:f,isOutsideRange:b=(()=>!1),onDateChange:v}=e,x=D(e,["date","monthFormat","weekConfig","defaultPresetButton","presetButtons","onPresetButtonClick","showDateFields","dateFieldFormat","showTimeFields","timeFieldProps","labelSuffix","isOutsideRange","onDateChange"]);const[y,w]=t.useState(0),{currentMonth:C,goToPreviousMonth:E,goToNextMonth:I,goToMonth:k}=Dp(r),M=d((e=>{const t=r.hour(e.hour()).minute(e.minute()).second(0).millisecond(0);v(t)}),[r,v]),$=l((()=>p?t.createElement(bp,null,t.createElement(gp,null,t.createElement(xp,null,t.createElement(vp,null,"日付"),f),t.createElement(fp,null,t.createElement(_C,{date:r,format:m,size:"medium",variant:"dark",onDateChange:v}),h&&t.createElement(hL,Object.assign({size:(null==g?void 0:g.size)||"medium",time:r,variant:"dark",width:(null==g?void 0:g.width)||"80px",onTimeChange:M},g))))):null),[p,h,g,r,m,f,v,M]);a((()=>{k(r)}),[r,k]);const{labels:A,start:L}=zp({weekConfig:o,fallbackLabels:[...fd],fallbackStart:0});return t.createElement(qu,Object.assign({ref:n},x),t.createElement(lp,null,t.createElement(sp,null,t.createElement(Ku,null,t.createElement(Sp,{date:r,current:C,monthFormat:i,weekList:A,weekStart:L,isOutsideRange:b,onDateChange:e=>{v(e),w((e=>e+1))},onPreviousMonth:E,onNextMonth:I})),t.createElement(yp,{key:y,defaultPresetButton:s,presetButtons:c,dateFields:$,onPresetButtonClick:u}))))}));var Tp=g(Np);const Zp="none",Bp="start",Pp="start_only",_p="end",Gp="between",jp="start",Fp="end",Yp=(e,t,n,r)=>{const i=((e,t,n)=>{const r=_a(new Date(t.year(),t.month(),n));return e.format("YYYY-MM-DD")===r.format("YYYY-MM-DD")})(e,n,r),o=((e,t,n)=>{const r=_a(new Date(t.year(),t.month(),n));return e.format("YYYY-MM-DD")===r.format("YYYY-MM-DD")})(t,n,r),a=((e,t,n,r)=>{const i=_a(new Date(n.year(),n.month(),r)),o=e.format("YYYY-MM-DD"),a=t.format("YYYY-MM-DD");return o!==a&&i.isAfter(o,"day")&&i.isBefore(a,"day")})(e,t,n,r),l=e.isSame(t,"day");switch(!0){case i&&l:return Pp;case i&&!l:return Bp;case o&&!l:return _p;case a:return Gp;default:return Zp}},Wp=v(up)``,Xp=v.button`
|
|
1640
1640
|
background-color: transparent;
|
|
1641
1641
|
border: none;
|
|
1642
1642
|
height: ${({theme:e})=>4*e.spacing}px;
|
|
@@ -1720,7 +1720,7 @@ object-assign
|
|
|
1720
1720
|
background-color: transparent;
|
|
1721
1721
|
color: ${({theme:e})=>e.palette.neutral.lighter};
|
|
1722
1722
|
}
|
|
1723
|
-
`,rm=g((function({state:e,value:n,selectable:r,onClickDate:i,children:o,isSaturday:a=!1,isSundayOrHoliday:l=!1,isToday:s=!1}){return t.createElement(Wp,{"data-state":e,isToday:s},(({state:e,value:n,selectable:r,onClickDate:i,children:o,isSaturday:a=!1,isSundayOrHoliday:l=!1})=>{const s=()=>{null==i||i(n)};if(!r)return t.createElement(nm,{type:"button",isSaturday:a,isSundayOrHoliday:l},o);switch(e){case Pp:return t.createElement(qp,{type:"button",isSaturday:a,isSundayOrHoliday:l,onClick:s},o);case Bp:return t.createElement(Kp,{type:"button",isSaturday:a,isSundayOrHoliday:l,onClick:s},o);case _p:return t.createElement(em,{type:"button",isSaturday:a,isSundayOrHoliday:l,onClick:s},o);case Gp:return t.createElement(tm,{type:"button",isSaturday:a,isSundayOrHoliday:l,onClick:s},o);default:return t.createElement(Jp,{type:"button",isSaturday:a,isSundayOrHoliday:l,onClick:s},o)}})({state:e,value:n,selectable:r,onClickDate:i,children:o,isSaturday:a,isSundayOrHoliday:l}))})),im=({startDate:e,endDate:n,monthFormat:r,weekList:o,weekStart:a=0,current:l,isOutsideRange:s,onDatesChange:c,onPreviousMonth:u,onNextMonth:p,onTodayClick:m})=>{const[h,g]=i(jp),f=d((t=>{if(e&&n&&!e.isSame(n,"day"))return null==c||c({startDate:t,endDate:t}),void g(Fp);switch(h){case jp:null==c||c({startDate:t,endDate:t}),g(Fp);break;case Fp:e&&t.isBefore(e)?null==c||c({startDate:t,endDate:e}):null==c||c({startDate:e,endDate:t}),g(jp)}}),[h,c,n,e]);return t.createElement(ep,null,t.createElement(ap,null,t.createElement(op,null,t.createElement(ip,null,t.createElement(rp,{weight:"bold",size:"xl"},l.format(r))),t.createElement("div",{style:{display:"flex",gap:"8px"}},t.createElement(cl,{size:"small",color:"clear",type:"button",icon:t.createElement(le,{name:"arrow_left",size:"md",color:"currentColor"}),"aria-label":"前の月",onClick:u}),t.createElement(Sc,{content:"今日に戻る"},t.createElement(cl,{size:"small",color:"clear",type:"button",icon:t.createElement(le,{name:"calendar",size:"md",color:"currentColor"}),"aria-label":"今日に戻る",onClick:m})),t.createElement(cl,{size:"small",color:"clear",type:"button",icon:t.createElement(le,{name:"arrow_right",size:"md",color:"currentColor"}),"aria-label":"次の月",onClick:p})))),t.createElement(tp,null,null==o?void 0:o.map((e=>t.createElement(np,{key:e},e))),Array.from(new Array(Op(l,a)),((e,n)=>t.createElement(np,{key:`empty-${n}`}))),Hp(l).map((r=>{const i=Ap(l,r),o=Lp(i),a=Vp(i,s);return t.createElement(rm,{key:r,value:i,state:Yp(e,n,l,r),selectable:a,isSaturday:o.isSaturday,isSundayOrHoliday:o.isSundayOrHoliday,isToday:$p(i),onClickDate:f},r)}))))},om=n((function(e,n){var{startDate:r,endDate:i,monthFormat:o="YYYY年M月",weekConfig:s,defaultPresetButton:c,presetButtons:u,onPresetButtonClick:p,showDateFields:m=!1,dateFieldFormat:h="YYYY-MM-DD",showTimeFields:g=!1,timeFieldProps:f,startLabelSuffix:b,endLabelSuffix:v,onApply:x,onCancel:y,applyButtonText:w="適用",cancelButtonText:C="キャンセル",isOutsideRange:E=(()=>!1),onDatesChange:I}=e,k=D(e,["startDate","endDate","monthFormat","weekConfig","defaultPresetButton","presetButtons","onPresetButtonClick","showDateFields","dateFieldFormat","showTimeFields","timeFieldProps","startLabelSuffix","endLabelSuffix","onApply","onCancel","applyButtonText","cancelButtonText","isOutsideRange","onDatesChange"]);const[M,$]=t.useState(0),{currentMonth:A,goToPreviousMonth:L,goToNextMonth:V,goToMonth:H}=Dp(r);a((()=>{H(r)}),[r,H]);const O=d((()=>{const e=_a();null==I||I({startDate:e,endDate:e}),H(e),$((e=>e+1))}),[I,H]),S=d((e=>{null==I||I({startDate:e,endDate:i})}),[i,I]),R=d((e=>{null==I||I({startDate:r,endDate:e})}),[r,I]),z=d((e=>{const t=r.hour(e.hour()).minute(e.minute()).second(0).millisecond(0);null==I||I({startDate:t,endDate:i})}),[r,i,I]),N=d((e=>{const t=i.hour(e.hour()).minute(e.minute()).second(0).millisecond(0);null==I||I({startDate:r,endDate:t})}),[r,i,I]),T=l((()=>m?t.createElement(bp,null,t.createElement(gp,null,t.createElement(xp,null,t.createElement(vp,null,"開始日時"),b),t.createElement(fp,null,t.createElement(
|
|
1723
|
+
`,rm=g((function({state:e,value:n,selectable:r,onClickDate:i,children:o,isSaturday:a=!1,isSundayOrHoliday:l=!1,isToday:s=!1}){return t.createElement(Wp,{"data-state":e,isToday:s},(({state:e,value:n,selectable:r,onClickDate:i,children:o,isSaturday:a=!1,isSundayOrHoliday:l=!1})=>{const s=()=>{null==i||i(n)};if(!r)return t.createElement(nm,{type:"button",isSaturday:a,isSundayOrHoliday:l},o);switch(e){case Pp:return t.createElement(qp,{type:"button",isSaturday:a,isSundayOrHoliday:l,onClick:s},o);case Bp:return t.createElement(Kp,{type:"button",isSaturday:a,isSundayOrHoliday:l,onClick:s},o);case _p:return t.createElement(em,{type:"button",isSaturday:a,isSundayOrHoliday:l,onClick:s},o);case Gp:return t.createElement(tm,{type:"button",isSaturday:a,isSundayOrHoliday:l,onClick:s},o);default:return t.createElement(Jp,{type:"button",isSaturday:a,isSundayOrHoliday:l,onClick:s},o)}})({state:e,value:n,selectable:r,onClickDate:i,children:o,isSaturday:a,isSundayOrHoliday:l}))})),im=({startDate:e,endDate:n,monthFormat:r,weekList:o,weekStart:a=0,current:l,isOutsideRange:s,onDatesChange:c,onPreviousMonth:u,onNextMonth:p,onTodayClick:m})=>{const[h,g]=i(jp),f=d((t=>{if(e&&n&&!e.isSame(n,"day"))return null==c||c({startDate:t,endDate:t}),void g(Fp);switch(h){case jp:null==c||c({startDate:t,endDate:t}),g(Fp);break;case Fp:e&&t.isBefore(e)?null==c||c({startDate:t,endDate:e}):null==c||c({startDate:e,endDate:t}),g(jp)}}),[h,c,n,e]);return t.createElement(ep,null,t.createElement(ap,null,t.createElement(op,null,t.createElement(ip,null,t.createElement(rp,{weight:"bold",size:"xl"},l.format(r))),t.createElement("div",{style:{display:"flex",gap:"8px"}},t.createElement(cl,{size:"small",color:"clear",type:"button",icon:t.createElement(le,{name:"arrow_left",size:"md",color:"currentColor"}),"aria-label":"前の月",onClick:u}),t.createElement(Sc,{content:"今日に戻る"},t.createElement(cl,{size:"small",color:"clear",type:"button",icon:t.createElement(le,{name:"calendar",size:"md",color:"currentColor"}),"aria-label":"今日に戻る",onClick:m})),t.createElement(cl,{size:"small",color:"clear",type:"button",icon:t.createElement(le,{name:"arrow_right",size:"md",color:"currentColor"}),"aria-label":"次の月",onClick:p})))),t.createElement(tp,null,null==o?void 0:o.map((e=>t.createElement(np,{key:e},e))),Array.from(new Array(Op(l,a)),((e,n)=>t.createElement(np,{key:`empty-${n}`}))),Hp(l).map((r=>{const i=Ap(l,r),o=Lp(i),a=Vp(i,s);return t.createElement(rm,{key:r,value:i,state:Yp(e,n,l,r),selectable:a,isSaturday:o.isSaturday,isSundayOrHoliday:o.isSundayOrHoliday,isToday:$p(i),onClickDate:f},r)}))))},om=n((function(e,n){var{startDate:r,endDate:i,monthFormat:o="YYYY年M月",weekConfig:s,defaultPresetButton:c,presetButtons:u,onPresetButtonClick:p,showDateFields:m=!1,dateFieldFormat:h="YYYY-MM-DD",showTimeFields:g=!1,timeFieldProps:f,startLabelSuffix:b,endLabelSuffix:v,onApply:x,onCancel:y,applyButtonText:w="適用",cancelButtonText:C="キャンセル",isOutsideRange:E=(()=>!1),onDatesChange:I}=e,k=D(e,["startDate","endDate","monthFormat","weekConfig","defaultPresetButton","presetButtons","onPresetButtonClick","showDateFields","dateFieldFormat","showTimeFields","timeFieldProps","startLabelSuffix","endLabelSuffix","onApply","onCancel","applyButtonText","cancelButtonText","isOutsideRange","onDatesChange"]);const[M,$]=t.useState(0),{currentMonth:A,goToPreviousMonth:L,goToNextMonth:V,goToMonth:H}=Dp(r);a((()=>{H(r)}),[r,H]);const O=d((()=>{const e=_a();null==I||I({startDate:e,endDate:e}),H(e),$((e=>e+1))}),[I,H]),S=d((e=>{null==I||I({startDate:e,endDate:i})}),[i,I]),R=d((e=>{null==I||I({startDate:r,endDate:e})}),[r,I]),z=d((e=>{const t=r.hour(e.hour()).minute(e.minute()).second(0).millisecond(0);null==I||I({startDate:t,endDate:i})}),[r,i,I]),N=d((e=>{const t=i.hour(e.hour()).minute(e.minute()).second(0).millisecond(0);null==I||I({startDate:r,endDate:t})}),[r,i,I]),T=l((()=>m?t.createElement(bp,null,t.createElement(gp,null,t.createElement(xp,null,t.createElement(vp,null,"開始日時"),b),t.createElement(fp,null,t.createElement(_C,{date:r,format:h,size:"medium",variant:"dark",onDateChange:S}),g&&t.createElement(hL,Object.assign({size:(null==f?void 0:f.size)||"medium",time:r,variant:"dark",width:(null==f?void 0:f.width)||"80px",onTimeChange:z},f)))),t.createElement(gp,null,t.createElement(xp,null,t.createElement(vp,null,"終了日時"),v),t.createElement(fp,null,t.createElement(_C,{date:i,format:h,size:"medium",variant:"dark",onDateChange:R}),g&&t.createElement(hL,Object.assign({size:(null==f?void 0:f.size)||"medium",time:i,variant:"dark",width:(null==f?void 0:f.width)||"80px",onTimeChange:N},f))))):null),[m,g,f,r,i,h,b,v,S,R,z,N]),Z=Boolean(u||T),{labels:B,start:P}=zp({weekConfig:s,fallbackLabels:[...fd],fallbackStart:0}),_=Z?t.createElement(yp,{key:M,defaultPresetButton:c,presetButtons:u,dateFields:T,onPresetButtonClick:p}):null,G=t.createElement(Ku,null,t.createElement(im,{startDate:r,endDate:i,monthFormat:o,weekList:B,weekStart:P,current:A,isOutsideRange:E,onDatesChange:e=>{null==I||I(e),$((e=>e+1))},onPreviousMonth:L,onNextMonth:V,onTodayClick:O}));return t.createElement(qu,Object.assign({ref:n},k),t.createElement(lp,null,t.createElement(sp,null,G,_,x?t.createElement(cp,null,t.createElement(Za,null,y?t.createElement(cl,{color:"clear",size:"small",type:"button",onClick:y},C):null,t.createElement(cl,{color:"primary",size:"small",type:"button",onClick:x},w))):null)))}));var am=g(om);const lm=v.div`
|
|
1724
1724
|
border-radius: ${({theme:e})=>e.radius}px;
|
|
1725
1725
|
background-color: ${({theme:e})=>e.palette.background.default};
|
|
1726
1726
|
width: ${({width:e})=>e||"auto"};
|
|
@@ -2321,17 +2321,17 @@ object-assign
|
|
|
2321
2321
|
&:last-of-type {
|
|
2322
2322
|
border-right: none;
|
|
2323
2323
|
}
|
|
2324
|
-
`,cy={small:"8px",medium:"12px",large:"16px"},dy=v.tr`
|
|
2325
|
-
background-color: ${({highlighted:e,theme:t})=>e?t.palette.primary.highlight:"none"};
|
|
2324
|
+
`,cy={small:"8px",medium:"12px",large:"16px"},dy=e=>cy[e],uy=v.tr`
|
|
2325
|
+
background-color: ${({$highlighted:e,theme:t})=>e?t.palette.primary.highlight:"none"};
|
|
2326
2326
|
|
|
2327
2327
|
&:hover {
|
|
2328
|
-
${({disableHoverHighlight:e
|
|
2328
|
+
${({$disableHoverHighlight:e,$highlighted:t,theme:n})=>e?"":y`
|
|
2329
2329
|
background-color: ${t?"none":n.palette.neutral.highlight};
|
|
2330
2330
|
`}
|
|
2331
2331
|
}
|
|
2332
2332
|
|
|
2333
2333
|
& > th {
|
|
2334
|
-
${({isStickyHeader:e})=>e?y`
|
|
2334
|
+
${({$isStickyHeader:e})=>e?y`
|
|
2335
2335
|
position: sticky;
|
|
2336
2336
|
top: 0;
|
|
2337
2337
|
z-index: 1;
|
|
@@ -2339,10 +2339,10 @@ object-assign
|
|
|
2339
2339
|
}
|
|
2340
2340
|
|
|
2341
2341
|
& > td {
|
|
2342
|
-
padding-top: ${({verticalSpacing:e})=>
|
|
2343
|
-
padding-bottom: ${({verticalSpacing:e})=>
|
|
2342
|
+
padding-top: ${({$verticalSpacing:e})=>dy(e)};
|
|
2343
|
+
padding-bottom: ${({$verticalSpacing:e})=>dy(e)};
|
|
2344
2344
|
}
|
|
2345
|
-
`,
|
|
2345
|
+
`,py=v.table`
|
|
2346
2346
|
width: 100%;
|
|
2347
2347
|
border-collapse: separate;
|
|
2348
2348
|
border-spacing: 0;
|
|
@@ -2359,7 +2359,7 @@ object-assign
|
|
|
2359
2359
|
& > tbody > tr:first-of-type > td {
|
|
2360
2360
|
border-top: none;
|
|
2361
2361
|
}
|
|
2362
|
-
`,
|
|
2362
|
+
`,my=({horizontalScrollable:t,children:n})=>e.createElement(py,{horizontalScrollable:t},n);my.Header=({children:t})=>e.createElement("thead",null,t),my.Body=({children:t})=>e.createElement("tbody",null,t),my.Row=t=>{var{highlighted:n=!1,verticalSpacing:r="medium",isStickyHeader:i=!1,disableHoverHighlight:o=!1,children:a}=t,l=D(t,["highlighted","verticalSpacing","isStickyHeader","disableHoverHighlight","children"]);return e.createElement(uy,Object.assign({$highlighted:n,$verticalSpacing:r,$isStickyHeader:i,$disableHoverHighlight:o},l),a)},my.Cell=t=>{var{width:n="auto",enableRuledLine:r=!1,children:i}=t,o=D(t,["width","enableRuledLine","children"]);return e.createElement(sy,Object.assign({width:n,enableRuledLine:r},o),i)};const hy=e=>e,gy=(e,t)=>e.sort(((e,n)=>{const r=((e,t,n=hy)=>{const r=n(e),i=n(t);return i===r?0:i<r?-1:1})(e,n,t.getValue);return t.isDesc?r:-r})),fy=v.button`
|
|
2363
2363
|
width: 28px;
|
|
2364
2364
|
height: 28px;
|
|
2365
2365
|
margin: 0 4px;
|
|
@@ -2371,7 +2371,7 @@ object-assign
|
|
|
2371
2371
|
background-color: ${({active:e,theme:t})=>e?t.palette.primary.base:t.palette.primary.highlight};
|
|
2372
2372
|
cursor: ${({active:e})=>e?"default":"pointer"};
|
|
2373
2373
|
}
|
|
2374
|
-
`,
|
|
2374
|
+
`,by=({index:t,isActiveIndex:n,onClick:r})=>e.createElement(fy,{disabled:n,active:n,type:"button","aria-label":`${t} ページ目`,"aria-current":n?"page":void 0,onClick:r},e.createElement(ke,{component:"span",weight:"bold",size:"xs",color:n?"white":"primary"},t)),vy=v.button`
|
|
2375
2375
|
width: 28px;
|
|
2376
2376
|
height: 28px;
|
|
2377
2377
|
padding: 0 5px;
|
|
@@ -2389,7 +2389,7 @@ object-assign
|
|
|
2389
2389
|
background-color: ${({disabled:e,theme:t})=>e?t.palette.neutral.softLight:t.palette.primary.highlight};
|
|
2390
2390
|
cursor: ${({disabled:e})=>e?"default":"pointer"};
|
|
2391
2391
|
}
|
|
2392
|
-
`,
|
|
2392
|
+
`,xy=({isRight:t,disabled:n,onClick:r})=>{const i=ne();return e.createElement(vy,{disabled:n,type:"button","aria-label":t?"次のページへ":"前のページへ",onClick:r},e.createElement(le,{name:t?"arrow_right":"arrow_left",size:"md",color:n?i.palette.text.disabled:i.palette.icon.active}))},yy=v.div`
|
|
2393
2393
|
width: 28px;
|
|
2394
2394
|
height: 28px;
|
|
2395
2395
|
margin: 0 ${({theme:e})=>.5*e.spacing}px;
|
|
@@ -2399,26 +2399,26 @@ object-assign
|
|
|
2399
2399
|
letter-spacing: 1.5px;
|
|
2400
2400
|
font-size: 12px;
|
|
2401
2401
|
font-weight: bold;
|
|
2402
|
-
`,
|
|
2402
|
+
`,wy=()=>e.createElement(yy,null,"..."),Cy=({pagerCount:t,index:n,onClick:r})=>{const i=((e,t)=>{switch(!0){case t<4:return 3;case e-3<t:return e-2;default:return t}})(t,n),o=e=>()=>r(e);return e.createElement(e.Fragment,null,e.createElement(by,{index:1,isActiveIndex:1===n,onClick:o(1)}),3!==i&&e.createElement(wy,null),((e,t)=>{switch(e){case 3:return[e-1,e,e+1,e+2];case t-2:return[e-2,e-1,e,e+1];default:return[e-1,e,e+1]}})(i,t).map((t=>e.createElement(by,{key:t,index:t,isActiveIndex:n===t,onClick:o(t)}))),i!==t-2&&e.createElement(wy,null),e.createElement(by,{index:t,isActiveIndex:n===t,onClick:o(t)}))},Ey=e.forwardRef((function({per:t,total:n,index:r=1,onClick:i},o){const a=Math.ceil(n/t),l=1===r||0===n,s=r===a||0===n,c=e=>()=>i(e);return e.createElement(de,{ref:o,display:"flex",alignItems:"center",role:"navigation","aria-label":"ページネーション"},e.createElement(xy,{isRight:!1,disabled:l,onClick:c(r-1)}),a<7?[...Array(a)].map(((t,n)=>e.createElement(by,{key:n,index:n+1,isActiveIndex:r===n+1,onClick:c(n+1)}))):e.createElement(Cy,{pagerCount:a,index:r,onClick:i}),e.createElement(xy,{isRight:!0,disabled:s,onClick:c(r+1)}))}));function Iy(e,{per:t,index:n}){return e.slice((n-1)*t,n*t)}const ky=(t=100,n=1)=>e.useState({per:t,index:n}),My=v.div`
|
|
2403
2403
|
display: flex;
|
|
2404
2404
|
flex-direction: column;
|
|
2405
2405
|
align-items: center;
|
|
2406
2406
|
width: 100%;
|
|
2407
2407
|
padding: ${({theme:e})=>5*e.spacing}px
|
|
2408
2408
|
${({theme:e})=>4*e.spacing}px ${({theme:e})=>7*e.spacing}px;
|
|
2409
|
-
|
|
2409
|
+
`,$y=v.img`
|
|
2410
2410
|
width: ${({width:e})=>e}px;
|
|
2411
2411
|
height: auto;
|
|
2412
|
-
`;const
|
|
2412
|
+
`;const Ay=e.forwardRef((function(t,n){const r=Cd({props:t,name:"ItemEmpty"}),{title:i="Not found.",subtitle:o,emptyImage:a,imageWidth:l=80}=r;return e.createElement(My,{ref:n},e.createElement($y,{src:a||"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAANoAAADvCAYAAACUqsrFAAAACXBIWXMAACxKAAAsSgF3enRNAAAUg0lEQVR4nO2df4wcR5XH3+6Md5d4Z3aOc3BErKwvhphcBE5O4hIdsWNAlmIpgaAz/xxIJAjp+AfwgcQPI5REkSLdHzkCJ51AgOxE8BcBwhnEjyCyDkGXBCGvc4KLgeS8xob4+DU7s4bd9a7n9No13p7u6pmp7qo31d3fjzSyp12eqamub7+qV69ejXU6HQKjodlqN4joRvXle9Wf4Wtd+P1MQiWPRd6fUi9mnr+G3zfqtVOa/wuEgNAECAmKxbRdvW4bQVVOKBHOd18QoAwQmgOarfbekLD4z1mPq7uoRDenXiy+pgf1KhQQmgWarXZXVPx6e+5/0KXhaCC8Rr0250F9cg+ElpJmq32XEtZdnlusrLDFe1y95mDt0gGhGaAs10ElriTnRNH5JhEdadRrj5f096cCQhtAs9Vmx8Xd6lVky2VK19I93KjX5vNVdXkgtATU0PDugsy5XMPezIdZeBha6oHQQig3PAvsPlivVCwqwR3BskEvENqGwA6qV1nnXrZ5hB9YENwlSi00CEyE0guOyio0CGwklFpwpRNas9W+W80jIDB5unO4h8vmNCmN0FRYFN/kXR5Up+yw4A426rUjZWmHwgtNDRNZYO/xoDqgl2NKcIVfhyu00DBMzA33F304WUihqWiOIyPaigLSscABAkUNYh73oA5WUVZsHiLLHRwg8GSz1b6viD+uMBZNzcWOIGSqEJxQ1q0wc7dCWDQVVT8PkRUG9gzPqdFJIci9RWu22rzo/GkPqgLc8IjyTObaUZJbocFtXyp4KHlXnqNKcik0JbI5LD6XCl7k3pvXeVvu5mhqPnYKIisdvBZ6PK/ztlwJTW3GnMMCdKk5nMclgNwMHdWT7LAHVQF+8EijXsuNdcuFRYPIgIb3NFvt3AQle2/Rmq02exY/5EFVgJ/kwv3vtdDUEwvuezCIE8oj6a3YvB06QmTAgG4kScPXRvNSaCraAyIDJuxSAQxe4t3QEY4PkBEvvZFeWTSIDFjAS2+kNxZNRXwc96AqoBj8S6Ne82Yo6YVFUyLD8UDAJp/2KVxr5BYNAcLAId4EIvtg0R6HyIAjZnxx+49UaCrqA7k9gEtmfJiWjExoKhIfoVVAgl3qoT4yRjJHU+ng5rHdBQjzjlGdVDoqi/Y4RAZGwBH1kBdHXGjKhMP5AUbBjEpJKI7o0FEdNPGkT11sZZ3o6TNVOvnHSvC+NtGh/ddeoC2v6G2XF/5YoR8uVHuuvWV2jV73yvWea2eXxoNy7dWxy9fK8pnclt95aRP9ZunS8/vV0xfp1m1rsc/zgPsb9ZroLm0xixZKcOoVYZEx3PG4s0ThcsNci3beMn0mX+uKjOG/6z7PA+5VQRJixFvLHV6eC/2/i5XYNe5wU5OTl9+vrBGtrseKBdei5dqr+u8p+mcy59f0n/f7v4z5aNX4oS8mNhGhqSGjl658XSeameLOFnoSV4hev3WN/vvcxZ5yr986TlOT1Z5yRAk9mLhjThT3M4noiglWWm85CoaUbDm9Exq7/O+TGkJKDR293SfE84gw3Hf27ei1clNVojtfVw06Vxf+O1+LlrtjZ5Ui/S94z9eL/JkMtxs/pMJMVIi2vCIuPk84KOWFdO4MUanB7nX6JRngYU13bsGdhDvLdVsKd8iOGOeWOvTEi2t0utkJnCvsDPmbGW+Fxhxr1Gt7XX+JU6HlaWGa5xs9QyaQibX1dVo6/+e8NOKbXZ/L5nqOdp8Lkf3XmbGBZeqTHbrhStvfDFzx6xbRmdbg+3rDlR2qT1qvBDtGnA4hnQlNOUCs5/1gkb3za4NvyC1Xj9FjB7wesoAQX/35GP3bs4Pv64dvJvrwLdZHYbOuHSMuLZqTSj/0zOCbYQIvxvIcjb2P7F3TTfLB8Dz/8sVgjsbLAjtfWaW3zmp8/hn4wvwYve8mJ1aNHSPOztF20quUNbO+/YWt2TNnhytbrVaoUd/ct8zyGtEPj2+4uS+5sCG2tHB7fuvkhrA4EGBi06ah2nNqku/DhYHl2itEXzw+5sKq8RTnoCsD4cq9lgtrpiO6XgT8a0+2aq0V6x9Lyqo52SRq/dGt8jSIWbNDe/QhPtc0Bj9DpmC4rJKlPXdvr9ChhH/78ok1Or24YcHyaNVcdDUnCVF01uxdu6p06Da7LvnwwiyQa8/ds5XgpYMfmu//z14Tlre5mtVeJT03O7Qnu8jCERJJEQ9gtO357l1VumYmEgCtrJoDulbNKlYXrJut9pwLoR14bDwmNLZmn3+b/ccZ8BMePkatWm2S6Nl7Lrqwapw9a7tNq2bNoqltB7myZiA/jMCq3WXzA20OHa2bW+ozN5ttuPdAAr/QzccdeiCtOkSsDB2VS/RPVmoUIikK5GcfuMKa0DgI9rGfrdHickdF7lfpDVfBIZIW1+35t5/9c48HkoJokY4LDyTZTOZjqwVEPY02rVm3U5Da5MgLrst2gxlKhev2FLZq1vq1LaFZHzZKzc26nSLMuSUsWqfFdXsKz9Xebmu/WmahKZe+9RQFmJuBJIStmhWniA2LZn3YKOlpvCYiXJ5XbJ3GHC0tEu0pbNWsjNZstIBVNygJW7M7d1Yvdw7eYf3uXZsQmpUBqfYUtGqzNjJmZfI6qvz538haiTASnkZQDAQ9kJ9p1GuZLFtWi+alNWMv13Nn1ulHp9ZpoQnHhs+w84TvE790jpR+CFq1zP08q0Vr2kxVYMOa/eL3FwMXc5ggYHV7b8BqeINil37rPkdf2Ei59qrpsWCItHVaX6dw2UHxfsOUNalrnn4XPwS/cqL3Xr3x6grte40+uFiHoFW7KcuBhqktmho2Ws0HYsOaPbUQT9T43Nnea90NiiuR9Z2VyMbFLuFOw/zfUoe+9NMLwVN4UFn+O1/TMUxZk7rm6XcxP9Lcq+fPrRutuwlatUxOvyxDR6spumx5GrmzRIl2PFOSNi/qOoqubNL/NynrAh9/F98rk3U3QQ9kpv6eRWhW52cuPY1RlzN7waKJPrvorkcTjSZ9blLZpP8/TFmTuubpdzGzM/ruN1U1u+dCVm1XlsXrVEJTX2htkdrmuhmP8cPwvOPADfFd2HfsjGfV5fcHbtBl4I1f486o+1xdWd01k7Imdc3T7+J5c3RjKN+vpDliEnmwaqmcISpdweG0XxrF9n4zdgh0g1rfcFUF62KeY+N+Ce1Xe6RRr6Waq6XtgtbmZy6iQBB9ny9s3C+2ag8eW3WdWyR1v0/7C60JDTGNwBYCc7XZtPM0Y6HZnJ+5sGY8DHnox6vB0y3J/Qz8web9EpqrpTIyaSyatcPbbFuz6DpSv7UeMHpc3C8Bq5aq/6cRmpVho1SEPhKi5ous90vAqokJzYpFczE3g3cxX7i6X46tWqoEVCMRmktrFl1DSlpUBX7g4n65tmppts0YCU05QjLHN7r0NEYXbJMWVYEfuLpfjq2asefRaMFapS140vRLwmC/GZDCYWT//aZnqZkOHTMPGyXWzdibxVswTPc3gdHg6n45tGrGOjC105kyAkl4Gjmv4JdPXLjsMuZc8IgU8ReX98thtIjx0U6iFk0qT2N4Wwyv08Cy+Yvr++XIqhl7HsUe9aPM09iE0LzF9f0SzpiViKnQUh9igZhGMCpcWDXlGBwaEYs26jyNs0Oc/glGg8T98sGqDf2LsuS2k7RmvGmRNxPyDbxuy3iQVxD4i9T9cmDVjByDJl7HVIdoS59vxmE9OLUzP0jdLwceSCOhOR9TYW4GfEE4Z38PToWG0zqBT4xyrmZis423x9jKOvyTM+v0/LlLkQM8judFzWjkN0cWfOtkb7bbblKaaLIXlM1nWeaJX63TL/5wkZbXOnTdX4/Tnu3xZET9YKsWzS3CVu19N3VMc4sY+SycWTRb1ixIF72wcSMuZSK+ECsXvVmk1miiWYtRNr9luS/85Oyl8rzIzXvXvqop1w+LVs3IZ+FMaLbmZpy5NsrpZu+NYauXFE0QvY6y+SzLLCzGN4VywtxzmqS5/RjFXM2J0GzOzXRZhrHHrJwkJVblYaQJo5irORGaTU+jbvwd3bPE8zWet0UFOKmuo2z+y5I6rET3kG0YzNG6SFu1ofejNVtt3n9z76BytvebIRofhLHZHzLuVzvWqNeGdhBaH4TZXjdjz9NH3jQReKf4iFbkBSk3NvuDRQ/kQKyaBpfrZhz/BpGBLjb6g+RczWrXdREFEl1nwdCx3NjuD1JWzVqPdWXNoussfJolKC+2+4OUVTMR2ql+/+jCmunWWbIeKgjyi6v+kNIDaXTMrhWhIaYR5JmUVq1p8pOtDB1dRejrJrvRg+tAeXDZH1yvq2WupWtrFl7QTDrdH5QHV/3B9VzNNIFqrLDt0zoBGBWGp4a+uVGvzQ1b1UwWDXMzUCRcWjVToS2E30jtnubD6njbxHNn1gPPEyg3LvuDwVytrxc+iqnQLn+4lDXjjX6cVJP3of3gxfUgzg2UF9f9YVir1qjXZIQmZc14o18Y3n/E0QGgnEj0hyGs2kKswABSCQ1zM1BkhrBqRtaMUggtWA2XzGyl23+UtAEQFB+p/jDAqhlFhVAaiyZtzaKbPHntRJe0BZQDqf4wwKoZWzSj1b5GvTb/0DPnY9dd5mnkyOyt05uCyS83KGfBAuVFsj8kRfa/ZXvnV3vrZp9ltGA9/cB57YmfOK0TFBXdLuzaJP3rbz+6+eMmP9n0cRA7ThRZh0GR0c3V2iv0/ukHzrtJN6esWezYprRzM3bJ4vhb4Jrusb38SrO4rZurcc4oIjpo8jlDDx2nHzg/FxVamphGXWbapF2ynIjl6Mm1YK2EhggiPfrCWpBU02XZV02P0Z079Vl0OWKBNyKG90ixl4wn8NHf56os2q23HcKJfLgcZ9L6+22VxDrr0MVAcupJPuhi6VObh9ouM5RFs2nNwlmHu+h2yXJW2i/99MLlzsLwTeObpyN8U12W5fpwvbh+YfhpyREL0Y2IK+q6RFm0Wy/c18Jl+e98zRQbVm3YoaO1uVk0yzAl7JJNapDwzRt03VXZfvUbNWi3DXSJVVfUUNIU3VyNhTbsXG2g0GzPzXRET32khGvUJ0ux7rqrsrr68abEpMMWotddldXVy3Vb+NpuzOyMPdd/Vqs2TE2sehqjO2K5ge7UZKXlkyB1nSa6YNnvuquyXC+uX5Q7dsZPNumejCJVFu22wRu3VWJtwWXTHt2bxar1dYa4WDfrHsPEBxbMTI4ZH7sDwCj7m25djYjuX/rU5phBCjNIaFY8jQAUhbQeyEQbKjE3AyBvpJ2r9RusIgoEAA1p5mpaocGaAZBMGquWZNGcWTNe2X/ox6v04LHVxMVOAGzhqr+ZWrWY0Fxas+jKfr/IAgB87m+mVk1n0UTnZkkRBAD43t9MrFqP0FzPzXC+GZDEdX8zsWpRiybuaUQufSCJ7f42rFW7/K1Snkbk0geSuO5vw1q1y5EhiAIBIB3DRIsEFg3rZgCkZxir1h06IgoEgAwMmquNw5oBkJ1BVm1c54p0ac14EZEXDTmXA58Icm4JyXmAOyT7W5JVIyW02OKaS2vGK/W8aMgpDTgJJv94AIrQ39iqbauPRVfE2arpYx1dzs34x4bhRD04HQa4Qrq/bf+rca2msFoMgADiQtNtI28glQFwhC/9TVxo+3ZUejIkcUJL5AwBrvClv3EVpqMXXefe+7tXV+j8aocm+VyrMX9yJHLyFl3mX2DGQrNDpxf9mXdL9rekFPcstB3Ri/sfXXZWEd/53NsmA+8RSAdvtLz90WVqrWDZJgwe3xE4Zo1j14A5EFkyLLQXfa3cqIDYzIHI+sNCW/K5gqMCYhseiGww2snIPTfH0zYXmV/+7iI9/VJ8gtzd+oA5WzL9RHbrtRV67ZXlmp185+dr9HI73hYQmuLBJ1bpu/8Tt2AQWzL9RHb79VU6tK98genHz6xrhQZniII7BXcOHRhGxoHIzIDQQkBswwGRmQOhRYDY+gORpQNC0wCx6YHI0gOhJQCx9QKRZQOutD50O0+SN5Lj2soQG9lcJvrnb65AZBmA0AbQT2wf+/6qV3WVBiIbHgwdh6DfMLKsQGRmQGhDArFtAJGZA6EZALFBZGnBI9oQ7mQcv7dUwgDa6ckxeueN6DJpQKulAJ0NmIKhIwACQGgACAChASAAhAaAABAaAAJAaAAIAKEBIACEBoAAEBoAAkBoAAgAoQEgAIQGgAAQGgACQGgACAChASAAhAaAABAaAAJgq7Bl+AiovKc5uGlbxYNaFAsIzTL//tQqzZ/156D0NDz1wSvyV2nPwdARAAEgNAAEgNAAEABzNAEO7fH3qGI+Fef0Ig55dw2EJsCh2/zN7PvUwkU6vRg/KB/YBUNHAASA0AAQAEIDQAAIDQABIDQABIDQABAAQgNAAAgNAAEgNAAEgNAAEABCA0AACA0AASA0AASA0AR4/mV/Uxv4XLciAaFZRpfYhvd8+cjRk+vUiiQSuvFqdAkXoFUtc+u1caH9x3MXvLMci8sd+tj3VmLXd+/AFkUXQGiWee2V43RVbSz2obc/uuyN2FhkXB/dzurdmgcFyA4eXw74wJ4J+uS3e60FD9H+4Qt/oXftqtIdO6vUmBpN3Y6+sB4MZaNDRubAjVW6qh5/SIDsQGgO2L2jEgwhn34pniLgKyfWgpdvvGbLOL33Zn9zm+QdDB0dcWjfRNB588DmiTH6xL4Jmp6ENXMFhOYI7rSf/cdJuv16vwcN/DA4/E9TwdwSuANDR4ew2Niy7b++QoefveBVqnB22Nxzyyba7/mDoCiglQXgtTV+vdzq0PGz68Gfo4LFz2tlsGCyQGiCsEdvfx1NXkbwWANAAAgNAAEgNAAEgNAAEABCA0AACA0AASA0AASA0AAQAEIDQAAIDQABIDQABIDQABAAQgNAAAgNAAEgNAAEgNAAEABCA0AACA0AASA0AASA0AAQAEIDQABtSqbjZ+KprAEAg1mKH9AToBXah76eUBoAkAoMHQEQAEIDQAAIDQABeI52hIjm0NgAOIKI/h/xGDgoob3NqwAAAABJRU5ErkJggg==",width:l,alt:""}),e.createElement(Ua,{pt:2,pb:1},e.createElement(ke,{weight:"bold",size:"md",align:"center"},i)),o&&e.createElement(ke,{size:"sm"},o))})),Ly=v.div`
|
|
2413
2413
|
padding-top: ${({theme:e})=>1.5*e.spacing}px;
|
|
2414
2414
|
padding-left: ${({theme:e})=>3*e.spacing}px;
|
|
2415
2415
|
background-color: ${({theme:e})=>e.palette.neutral.highlight};
|
|
2416
2416
|
border-bottom: 1px solid ${({theme:e})=>e.palette.divider};
|
|
2417
2417
|
border-radius: ${({theme:e})=>`${e.radius}px ${e.radius}px`} 0 0;
|
|
2418
|
-
`,
|
|
2418
|
+
`,Vy=v.ul`
|
|
2419
2419
|
list-style: none;
|
|
2420
2420
|
display: flex;
|
|
2421
|
-
`,
|
|
2421
|
+
`,Hy=v.li`
|
|
2422
2422
|
min-width: ${({theme:e})=>10*e.spacing}px;
|
|
2423
2423
|
/* MEMO: Use negative margin to cover the border of Container */
|
|
2424
2424
|
margin-bottom: -1px;
|
|
@@ -2428,7 +2428,7 @@ object-assign
|
|
|
2428
2428
|
border-radius: ${({theme:e})=>`${e.radius}px ${e.radius}px`} 0 0;
|
|
2429
2429
|
background-color: ${({active:e,theme:t})=>e?t.palette.background.default:"none"};
|
|
2430
2430
|
cursor: pointer;
|
|
2431
|
-
`,
|
|
2431
|
+
`,Oy=({items:t,value:n,onChange:r})=>{const i=e=>()=>{r(e)};return e.createElement(Ly,null,e.createElement(Vy,null,t.map((t=>e.createElement(Hy,{key:t.value,active:t.value===n,onClick:i(t.value)},e.createElement(ke,{size:"sm",color:t.value===n?"initial":"secondary",align:"center"},t.label))))))};function Sy(e,t){const n=o(!1);a((()=>{n.current?e():n.current=!0}),t)}function Dy(e,t){var n;return!!t&&!(null===(n=t[e])||void 0===n?void 0:n.disabledCheck)}function Ry(e,t,n,r){if(0===n)return!1;const i=e[n],o=null==r?void 0:r.selector(i),a=e[n-1],l=null==r?void 0:r.selector(a);return!(r&&!r.enableMergeCell||i[t]!==a[t]||o!==l)}function zy(e,t,n,r){if(r&&!r.enableMergeCell)return 1;const i=e[n],o=null==r?void 0:r.selector(i);let a=1;for(let l=n+1;l<e.length;l++){const n=e[l],s=null==r?void 0:r.selector(n);if(n[t]!==i[t]||s!==o)break;a++}return a}function Ny({sourceData:e,tabs:t,currentTabIndex:n}){let r=e;return t&&t[n]&&(r=t[n].filter(r)),r}function Ty({sourceData:e,sortState:t,filterState:n,enablePagination:r,tabs:i,currentTabIndex:o}){const a=Ny({sourceData:e,tabs:i,currentTabIndex:o}),l=gy(a,t);if(r){return Iy(l,n)}return l}var Zy=e.forwardRef((({data:t,dataKey:n,columns:r,enablePagination:i=!1,onSelectRowsChange:o,onRadioChange:a,tabs:l,itemEmptyProps:s,per:c,defaultSortField:d,defaultSortOrder:u="desc",selectedRows:p=[],selectedRow:m,enableRuledLine:h=!1,verticalSpacing:g="medium",fullWidth:f=!1,disableCheckWhenClickRow:b=!1,tableMaxHeight:v="none",horizontalScrollable:x=!1,labelRowsPerPage:y="Rows per page:",labelDisplayedRows:w=(({from:e,to:t,total:n})=>`${e}-${t} of ${n}`)},C)=>{const E=!!o,[I,k]=e.useState(!1),M=p.length>0&&!I,$=!!a,A=!!l,[L,V]=e.useState(0),H=r.some((e=>e.enableMergeCell)),O=r.find((e=>e.name===d)),S=(null==O?void 0:O.sortable)?O:r.find((e=>!0===e.sortable)),[D,R]=(z={isDesc:"desc"===u,name:(null==S?void 0:S.name)||"",getValue:null==S?void 0:S.selector},e.useState(z));var z;const[N,T]=ky(c),[Z,B]=e.useState(Ty({sourceData:t,sortState:D,filterState:N,enablePagination:i,tabs:l,currentTabIndex:L})),P=e.useMemo((()=>Ny({sourceData:t,tabs:l,currentTabIndex:L}).length),[t,l,L]);Sy((()=>{const e=Ty({sourceData:t,sortState:D,filterState:N,enablePagination:i,tabs:l,currentTabIndex:L});B(e)}),[t,D,N,i,A,l,L]),Sy((()=>{const e={index:1,per:N.per};T(e);const n=Ty({sourceData:t,sortState:D,filterState:e,enablePagination:i,tabs:l,currentTabIndex:L});B(n)}),[t,L]);const _=(e,t)=>()=>{R(((e,t,n)=>({isDesc:e.name===n&&!e.isDesc,getValue:t,name:n}))(D,e,t))},G=e=>()=>{o&&(p.includes(e)?o(p.filter((t=>t!==e))):o([...p,e]))},j=e=>()=>{a&&a(e)};return e.createElement(jx,{ref:C},e.createElement(Fx,{fullWidth:f},!!l&&e.createElement(Oy,{value:L,items:l.map(((e,t)=>({label:e.label,value:t}))),onChange:e=>{V(e)}}),e.createElement(Yx,{maxHeight:v,horizontalScrollable:x,tabIndex:"none"!==v||x?0:void 0},e.createElement(my,{horizontalScrollable:x},e.createElement(my.Header,null,e.createElement(my.Row,{isStickyHeader:"none"!==v},(!A||Dy(L,l))&&e.createElement(e.Fragment,null,E&&e.createElement(Kx,{header:!0,selected:p.length>0,indeterminate:M,onClick:()=>{o&&(p.length>0?(o([]),k(!1)):(o(Z.filter((e=>!e.selectDisabled)).map((e=>e[n]))),k(!0)))}}),$&&e.createElement(ly,{header:!0})),r.map((t=>{return e.createElement(Ux,{key:t.name,sortable:t.sortable&&!H,order:(n=D,r=t.name,n.name===r?n.isDesc?"desc":"asc":null),width:t.width,enableRuledLine:h,onClick:t.sortable&&!H?_(t.selector,t.name):void 0},t.headerCell||t.name);var n,r})))),e.createElement(my.Body,null,Z.length>0?Z.map(((t,i)=>e.createElement(e.Fragment,{key:i},E||$?e.createElement(e.Fragment,null,E&&e.createElement(my.Row,Object.assign({verticalSpacing:g,highlighted:!t.selectDisabled&&(p.includes(t[n])||m===t[n]),disableHoverHighlight:H},!b&&{onClick:G(t[n])}),(!A||Dy(L,l))&&!Ry(Z,n,i)&&e.createElement(Kx,Object.assign({selected:p.includes(t[n]),rowSpan:zy(Z,n,i)},b&&{onClick:G(t[n])})),r.map((r=>Ry(Z,n,i,r)?null:e.createElement(my.Cell,{key:r.name,enableRuledLine:h,rowSpan:zy(Z,n,i,r)},r.renderCell?r.renderCell(t):e.createElement(ke,{align:r.align},r.selector(t)))))),$&&e.createElement(my.Row,Object.assign({verticalSpacing:g,highlighted:!t.selectDisabled&&(p.includes(t[n])||m===t[n]),disableHoverHighlight:H},!b&&{onClick:j(t[n])}),(!A||Dy(L,l))&&!Ry(Z,n,i)&&e.createElement(ly,{selected:t[n]===m,rowSpan:zy(Z,n,i),onClick:j(t[n])}),r.map((r=>Ry(Z,n,i,r)?null:e.createElement(my.Cell,{key:r.name,enableRuledLine:h,rowSpan:zy(Z,n,i,r)},r.renderCell?r.renderCell(t):e.createElement(ke,{align:r.align},r.selector(t))))))):e.createElement(my.Row,{verticalSpacing:g,highlighted:!t.selectDisabled&&(p.includes(t[n])||m===t[n]),disableHoverHighlight:H},r.map((r=>Ry(Z,n,i,r)?null:e.createElement(my.Cell,{key:r.name,enableRuledLine:h,rowSpan:zy(Z,n,i,r)},r.renderCell?r.renderCell(t):e.createElement(ke,{align:r.align},r.selector(t))))))))):e.createElement("tr",null,e.createElement("td",{colSpan:r.length+(!E&&!$||A&&!Dy(L,l)?0:1)},e.createElement(Ay,Object.assign({},s)))))))),i&&e.createElement(Ua,{p:3},e.createElement(de,{display:"flex",alignItems:"center",justifyContent:"space-between"},e.createElement(Ey,{per:N.per,total:P,index:N.index,onClick:e=>{T({index:e,per:N.per})}}),e.createElement(Xx,{per:N.per,total:P,index:N.index,labelRowsPerPage:y,labelDisplayedRows:w,onChange:e=>{T({index:1,per:e})}}))))}));const By=!0,Py=!0;function _y(e,t){return!!t.reorder&&(void 0!==e.reorderable?e.reorderable:e.sortable)}function Gy(e,t){return!!t.visibility&&(void 0!==e.visibilityEditable?e.visibilityEditable:e.sortable)}function jy(e,t,n){const r=[...e].sort(((e,t)=>e.order-t.order));let i=0;const o=r.map((e=>(e=>!_y(e,n))(e)?e.id:t[i++]));return e.map((e=>{const t=o.indexOf(e.id);return t>=0?Object.assign(Object.assign({},e),{order:t}):e}))}const Fy=s({rowIds:[],enableRowSelection:!0,hasRowControls:!1,checkedRows:[],isSmallLayout:!1,totalCount:0,currentPage:0,pageSize:100,pageSizeOptions:[10,50,100,200],columns:[],columnEditFeatures:{reorder:!0,visibility:!0},columnWidths:[],rowSpacing:0,setRowIds:()=>{},setCheckedRows:()=>{},setCurrentPage:()=>{},setPageSize:()=>{},setColumns:()=>{},setColumnWidth:()=>{},setRowSpacing:()=>{}}),Yy=s({showStickyRightEdgeDecoration:!0}),Wy=s({registerColumnSticky:()=>{},getStickyRightOffset:()=>{},rightStickyColumnIndex:null,getRightStickyZIndexHead:e=>3,getRightStickyZIndexBody:e=>1}),Xy=s({index:0}),Jy=e=>e<1e3?String(e):e.toLocaleString("en-US"),Uy=e=>({toolbarActions:e.filter((e=>{const t="displayIn"in e?e.displayIn:void 0;return"toolbar"===(null!=t?t:"toolbar")})),dropdownActions:e.filter((e=>{const t="displayIn"in e?e.displayIn:void 0;return"dropdown"===(null!=t?t:"toolbar")}))}),Qy=(e,t,n=!1)=>{var r,i;if(n)return t.length>0;let o=!1;if("checked"===e.enabledWhen||void 0===e.enabledWhen)o=0===t.length;else if("unchecked"===e.enabledWhen)o=t.length>0;else if("custom"===e.enabledWhen)return null!==(i=null===(r=e.disabled)||void 0===r?void 0:r.call(e,t))&&void 0!==i&&i;return e.disabled&&(o=o||e.disabled(t)),o},qy=(e,t)=>{var n;if("singleButton"===e.type)return`single-${e.label||`action-${t}`}`;if("groupButton"===e.type){return`group-${(null===(n=e.items[0])||void 0===n?void 0:n.label)||""||`action-${t}`}`}return"separator"===e.type?`separator-${t}`:"heading"===e.type?`heading-${e.label||`action-${t}`}`:"divider"===e.type?`divider-${t}`:`action-${t}`},Ky=(e,t,n)=>`group-${t}-item-${e.label||`item-${n}`}`,ew=(e,t,n,r)=>{var i;let o=e.label;if(!o&&e.icon&&"object"==typeof e.icon&&null!==e.icon){const t=null===(i=e.icon)||void 0===i?void 0:i.props;(null==t?void 0:t.name)&&(o=`icon-${t.name}`)}return o||(o=`item-${r}`),`${t}-${n}-${o}`},tw=v.button`
|
|
2432
2432
|
display: flex;
|
|
2433
2433
|
gap: 4px;
|
|
2434
2434
|
box-sizing: border-box;
|
|
@@ -2463,7 +2463,7 @@ object-assign
|
|
|
2463
2463
|
background: ${({theme:e})=>e.palette.neutral.highlight};
|
|
2464
2464
|
box-shadow: ${P["3dShadowActive"]};
|
|
2465
2465
|
}
|
|
2466
|
-
`,
|
|
2466
|
+
`,nw=v.div`
|
|
2467
2467
|
position: relative;
|
|
2468
2468
|
display: flex;
|
|
2469
2469
|
flex-direction: column;
|
|
@@ -2487,7 +2487,7 @@ object-assign
|
|
|
2487
2487
|
border-inline: 1px solid ${t.palette.divider};
|
|
2488
2488
|
}
|
|
2489
2489
|
`}
|
|
2490
|
-
`,
|
|
2490
|
+
`,rw=v(t.forwardRef((function({className:e,children:n},r){return t.createElement("div",{ref:r,className:e},n)})))`
|
|
2491
2491
|
flex-grow: 1;
|
|
2492
2492
|
min-height: 0;
|
|
2493
2493
|
overflow: auto;
|
|
@@ -2504,7 +2504,7 @@ object-assign
|
|
|
2504
2504
|
/* separate + sticky は安全側だが tr の下線が出ない。collapse で行境界を tr に任せる */
|
|
2505
2505
|
border-collapse: collapse;
|
|
2506
2506
|
}
|
|
2507
|
-
`,
|
|
2507
|
+
`,iw=v.div`
|
|
2508
2508
|
display: flex;
|
|
2509
2509
|
flex-wrap: wrap;
|
|
2510
2510
|
align-items: center;
|
|
@@ -2514,7 +2514,7 @@ object-assign
|
|
|
2514
2514
|
flex-shrink: 0;
|
|
2515
2515
|
padding: 8px ${({isSmallLayout:e})=>e?12:16}px;
|
|
2516
2516
|
background: ${({theme:e})=>e.palette.neutral.ultraLight};
|
|
2517
|
-
`;v(
|
|
2517
|
+
`;v(tw)`
|
|
2518
2518
|
display: flex;
|
|
2519
2519
|
|
|
2520
2520
|
em {
|
|
@@ -2532,25 +2532,25 @@ object-assign
|
|
|
2532
2532
|
margin: 0;
|
|
2533
2533
|
border: 0;
|
|
2534
2534
|
border-left: 1px dashed ${({theme:e})=>e.palette.divider};
|
|
2535
|
-
`;const
|
|
2535
|
+
`;const ow=v.span`
|
|
2536
2536
|
display: inline-flex;
|
|
2537
2537
|
align-items: center;
|
|
2538
2538
|
flex-wrap: nowrap;
|
|
2539
2539
|
gap: 4px;
|
|
2540
2540
|
min-width: 0;
|
|
2541
|
-
`,
|
|
2541
|
+
`,aw=v.span`
|
|
2542
2542
|
${W}
|
|
2543
2543
|
font-variant-numeric: tabular-nums;
|
|
2544
2544
|
color: ${({theme:e})=>e.palette.black};
|
|
2545
|
-
`,
|
|
2545
|
+
`,lw=v.span`
|
|
2546
2546
|
${W}
|
|
2547
2547
|
color: ${({theme:e})=>e.palette.text.secondary};
|
|
2548
|
-
`,
|
|
2548
|
+
`,sw=v.span`
|
|
2549
2549
|
display: inline-flex;
|
|
2550
2550
|
flex-shrink: 0;
|
|
2551
2551
|
align-items: center;
|
|
2552
2552
|
line-height: 0;
|
|
2553
|
-
`,
|
|
2553
|
+
`,cw=v.button`
|
|
2554
2554
|
display: flex;
|
|
2555
2555
|
align-items: center;
|
|
2556
2556
|
gap: 4px;
|
|
@@ -2575,24 +2575,24 @@ object-assign
|
|
|
2575
2575
|
&:where([aria-expanded="true"]) {
|
|
2576
2576
|
background: ${({theme:e})=>e.palette.primary.highlight};
|
|
2577
2577
|
}
|
|
2578
|
-
`,
|
|
2578
|
+
`,dw=v.div`
|
|
2579
2579
|
display: flex;
|
|
2580
2580
|
flex-wrap: nowrap;
|
|
2581
2581
|
align-items: center;
|
|
2582
2582
|
gap: 8px;
|
|
2583
2583
|
flex: 0 0 auto;
|
|
2584
|
-
`,
|
|
2584
|
+
`,uw=v.div`
|
|
2585
2585
|
display: flex;
|
|
2586
2586
|
justify-content: flex-end;
|
|
2587
2587
|
align-items: center;
|
|
2588
2588
|
flex-shrink: 0;
|
|
2589
2589
|
padding: 8px ${({isSmallLayout:e})=>e?12:16}px;
|
|
2590
2590
|
background: ${({theme:e})=>e.palette.neutral.ultraLight};
|
|
2591
|
-
`,
|
|
2591
|
+
`,pw=v(tw)``,mw=v.thead`
|
|
2592
2592
|
position: relative;
|
|
2593
2593
|
z-index: 2;
|
|
2594
2594
|
background: transparent;
|
|
2595
|
-
`,
|
|
2595
|
+
`,hw=v.th`
|
|
2596
2596
|
height: 1px; /* 子要素の高さ 100% を有効にする。table-layout: fixed になっている必要がある */
|
|
2597
2597
|
text-align: left;
|
|
2598
2598
|
font-weight: 700;
|
|
@@ -2639,7 +2639,7 @@ object-assign
|
|
|
2639
2639
|
inset 0 -1px 0 0 ${t.palette.divider},
|
|
2640
2640
|
inset 1px 0 0 0 ${t.palette.divider};
|
|
2641
2641
|
`}
|
|
2642
|
-
`,
|
|
2642
|
+
`,gw=v.td`
|
|
2643
2643
|
${({$stickyRightOffset:e,theme:t,$stickyZIndex:n,$showStickyEdgeDecoration:r})=>void 0!==e&&y`
|
|
2644
2644
|
position: sticky;
|
|
2645
2645
|
right: ${e}px;
|
|
@@ -2649,7 +2649,7 @@ object-assign
|
|
|
2649
2649
|
box-shadow: inset 1px 0 0 0 ${t.palette.divider};
|
|
2650
2650
|
`}
|
|
2651
2651
|
`}
|
|
2652
|
-
`,
|
|
2652
|
+
`,fw=v.div`
|
|
2653
2653
|
position: relative;
|
|
2654
2654
|
display: flex;
|
|
2655
2655
|
flex-direction: column;
|
|
@@ -2661,7 +2661,7 @@ object-assign
|
|
|
2661
2661
|
${({isSmallLayout:e})=>(e?6:10)-3}px;
|
|
2662
2662
|
height: 100%;
|
|
2663
2663
|
margin: 0 5px;
|
|
2664
|
-
`,
|
|
2664
|
+
`,bw=v.button`
|
|
2665
2665
|
--color: ${({theme:e})=>e.palette.divider};
|
|
2666
2666
|
position: absolute;
|
|
2667
2667
|
inset: 0 -6px 0 auto;
|
|
@@ -2725,7 +2725,7 @@ object-assign
|
|
|
2725
2725
|
left: auto;
|
|
2726
2726
|
border-right: 0;
|
|
2727
2727
|
}
|
|
2728
|
-
`,
|
|
2728
|
+
`,vw=v.div`
|
|
2729
2729
|
position: fixed;
|
|
2730
2730
|
z-index: 100;
|
|
2731
2731
|
inset: 0;
|
|
@@ -2738,17 +2738,17 @@ object-assign
|
|
|
2738
2738
|
&[data-max="true"] {
|
|
2739
2739
|
cursor: w-resize;
|
|
2740
2740
|
}
|
|
2741
|
-
`,
|
|
2741
|
+
`,xw=y`
|
|
2742
2742
|
display: flex;
|
|
2743
2743
|
align-items: center;
|
|
2744
2744
|
font-weight: 700;
|
|
2745
2745
|
font-size: 13px;
|
|
2746
2746
|
line-height: 16px;
|
|
2747
2747
|
color: ${({theme:e})=>e.palette.black};
|
|
2748
|
-
`,
|
|
2749
|
-
${
|
|
2750
|
-
`,
|
|
2751
|
-
${
|
|
2748
|
+
`,yw=v.div`
|
|
2749
|
+
${xw}
|
|
2750
|
+
`,ww=v.button`
|
|
2751
|
+
${xw}
|
|
2752
2752
|
width: fit-content;
|
|
2753
2753
|
padding: 0;
|
|
2754
2754
|
border: 0;
|
|
@@ -2760,7 +2760,7 @@ object-assign
|
|
|
2760
2760
|
> span {
|
|
2761
2761
|
flex-shrink: 0;
|
|
2762
2762
|
}
|
|
2763
|
-
`,
|
|
2763
|
+
`,Cw=v.tr`
|
|
2764
2764
|
background: ${({theme:e})=>e.palette.background.default};
|
|
2765
2765
|
transition: background 0.2s;
|
|
2766
2766
|
border-bottom: 1px solid ${({theme:e})=>e.palette.divider};
|
|
@@ -2796,9 +2796,9 @@ object-assign
|
|
|
2796
2796
|
padding-block: 20px;
|
|
2797
2797
|
}
|
|
2798
2798
|
}
|
|
2799
|
-
`,
|
|
2799
|
+
`,Ew=v.td`
|
|
2800
2800
|
padding-right: 0;
|
|
2801
|
-
`,
|
|
2801
|
+
`,Iw=v.th`
|
|
2802
2802
|
height: 1px;
|
|
2803
2803
|
position: sticky;
|
|
2804
2804
|
top: 0;
|
|
@@ -2807,9 +2807,9 @@ object-assign
|
|
|
2807
2807
|
box-shadow:
|
|
2808
2808
|
inset 0 1px 0 0 ${({theme:e})=>e.palette.divider},
|
|
2809
2809
|
inset 0 -1px 0 0 ${({theme:e})=>e.palette.divider};
|
|
2810
|
-
`,Iw=v.div`
|
|
2811
|
-
display: flex;
|
|
2812
2810
|
`,kw=v.div`
|
|
2811
|
+
display: flex;
|
|
2812
|
+
`,Mw=v.div`
|
|
2813
2813
|
display: grid;
|
|
2814
2814
|
/* td は横 sticky 用に position を触らない。スピナー等の absolute はここを基準に */
|
|
2815
2815
|
position: relative;
|
|
@@ -2819,20 +2819,20 @@ object-assign
|
|
|
2819
2819
|
grid-area: 1 / 1 / 2 / 2;
|
|
2820
2820
|
content: "${" "}";
|
|
2821
2821
|
}
|
|
2822
|
-
|
|
2822
|
+
`,$w=v.div`
|
|
2823
2823
|
position: absolute;
|
|
2824
2824
|
inset: 0 auto 0 16px;
|
|
2825
2825
|
height: fit-content;
|
|
2826
2826
|
margin: auto 0;
|
|
2827
|
-
|
|
2827
|
+
`,Aw=v.div`
|
|
2828
2828
|
grid-area: 1 / 1 / 2 / 2;
|
|
2829
2829
|
overflow-wrap: anywhere;
|
|
2830
2830
|
word-break: normal;
|
|
2831
2831
|
line-break: strict;
|
|
2832
|
-
&:where(${
|
|
2832
|
+
&:where(${Mw}:has( ${$w} ) *) {
|
|
2833
2833
|
visibility: hidden;
|
|
2834
2834
|
}
|
|
2835
|
-
`,
|
|
2835
|
+
`,Lw=v.div`
|
|
2836
2836
|
display: flex;
|
|
2837
2837
|
justify-content: space-between;
|
|
2838
2838
|
align-items: center;
|
|
@@ -2842,7 +2842,7 @@ object-assign
|
|
|
2842
2842
|
a {
|
|
2843
2843
|
color: ${({theme:e})=>e.palette.primary.base};
|
|
2844
2844
|
}
|
|
2845
|
-
`,
|
|
2845
|
+
`,Vw=v.div`
|
|
2846
2846
|
@media (any-hover: hover) {
|
|
2847
2847
|
visibility: hidden;
|
|
2848
2848
|
|
|
@@ -2850,35 +2850,35 @@ object-assign
|
|
|
2850
2850
|
visibility: visible;
|
|
2851
2851
|
}
|
|
2852
2852
|
|
|
2853
|
-
&:where(${
|
|
2853
|
+
&:where(${Lw}:hover *) {
|
|
2854
2854
|
visibility: visible;
|
|
2855
2855
|
}
|
|
2856
2856
|
}
|
|
2857
|
-
`,
|
|
2857
|
+
`,Hw=v.div`
|
|
2858
2858
|
display: flex;
|
|
2859
2859
|
align-items: center;
|
|
2860
2860
|
gap: 8px;
|
|
2861
2861
|
flex: 0 1 auto;
|
|
2862
2862
|
min-width: min-content;
|
|
2863
2863
|
margin-inline-end: auto;
|
|
2864
|
-
`,
|
|
2864
|
+
`,Ow=v.span`
|
|
2865
2865
|
font-size: 13px;
|
|
2866
2866
|
color: ${({theme:e})=>e.palette.black};
|
|
2867
2867
|
margin-inline: 4px 0;
|
|
2868
|
-
`,
|
|
2868
|
+
`,Sw=(e,t)=>"danger"===e?null==t?void 0:t.palette.danger.dark:"primary"===e?null==t?void 0:t.palette.primary.dark:null==t?void 0:t.palette.text.secondary;v(tw)`
|
|
2869
2869
|
background: ${({color:e,theme:t})=>((e,t)=>"danger"===e?null==t?void 0:t.palette.danger.highlight:"primary"===e?null==t?void 0:t.palette.primary.highlight:null==t?void 0:t.palette.background.default)(e,t)};
|
|
2870
|
-
color: ${({color:e,theme:t})=>
|
|
2870
|
+
color: ${({color:e,theme:t})=>Sw(e,t)};
|
|
2871
2871
|
&:hover:not(:disabled) {
|
|
2872
2872
|
background: ${({color:e,theme:t})=>((e,t)=>"danger"===e?null==t?void 0:t.palette.danger.lighter:"primary"===e?null==t?void 0:t.palette.primary.softLight:null==t?void 0:t.palette.neutral.highlight)(e,t)};
|
|
2873
2873
|
}
|
|
2874
|
-
`,v(
|
|
2874
|
+
`,v(tw)``,v.button`
|
|
2875
2875
|
width: 100%;
|
|
2876
2876
|
text-align: left;
|
|
2877
2877
|
background: none;
|
|
2878
2878
|
border: none;
|
|
2879
2879
|
padding: 8px 12px;
|
|
2880
2880
|
font-size: 13px;
|
|
2881
|
-
color: ${({color:e,theme:t})=>
|
|
2881
|
+
color: ${({color:e,theme:t})=>Sw(e,t)};
|
|
2882
2882
|
cursor: pointer;
|
|
2883
2883
|
&:hover:not(:disabled) {
|
|
2884
2884
|
background: ${({theme:e})=>e.palette.neutral.highlight};
|
|
@@ -2887,16 +2887,16 @@ object-assign
|
|
|
2887
2887
|
color: ${({theme:e})=>e.palette.text.disabled};
|
|
2888
2888
|
cursor: not-allowed;
|
|
2889
2889
|
}
|
|
2890
|
-
`;const
|
|
2890
|
+
`;const Dw=v.span`
|
|
2891
2891
|
display: inline-block;
|
|
2892
2892
|
height: 18px;
|
|
2893
2893
|
border-left: 1px dashed ${({theme:e})=>e.palette.divider};
|
|
2894
2894
|
vertical-align: middle;
|
|
2895
|
-
`,
|
|
2895
|
+
`,Rw=v.div`
|
|
2896
2896
|
display: flex;
|
|
2897
2897
|
align-items: center;
|
|
2898
2898
|
gap: 8px;
|
|
2899
|
-
`,
|
|
2899
|
+
`,zw=v(tw)`
|
|
2900
2900
|
display: flex;
|
|
2901
2901
|
align-items: center;
|
|
2902
2902
|
gap: 4px;
|
|
@@ -2912,7 +2912,7 @@ object-assign
|
|
|
2912
2912
|
&:hover:not(:disabled) {
|
|
2913
2913
|
background: ${({theme:e})=>e.palette.neutral.highlight};
|
|
2914
2914
|
}
|
|
2915
|
-
`,zw=()=>{const{columns:e,setColumns:n,isSmallLayout:r}=c(jy),[o,s]=i(!1),[u,p]=i(e.map((e=>e.filtered||!1))),m=l((()=>e.filter((e=>e.filtered)).length),[e]),h=d((()=>{p(e.map((e=>e.filtered||!1)))}),[e]),g=d(((e,t)=>{p((n=>n.map(((n,r)=>e===r?t:n))))}),[p]),f=d((()=>{h(),s(!1)}),[h]),b=d((()=>{const t=structuredClone(e).map(((e,t)=>Object.assign(Object.assign({},e),{filtered:u[t]})));n(t),s(!1)}),[e,n,u]),v=d((e=>{s(e),e||h()}),[s,h]);return a((()=>h()),[e,h]),t.createElement(Da,null,t.createElement(Sa,{width:360,trigger:t.createElement(sw,{type:"button",disabled:0===m},t.createElement(le,{name:"filter",color:"currentColor"}),r?m:`${m}列に適用中`),open:o,onOpenChange:v},t.createElement(Ra,null,"フィルタが適用されている列"),e.map(((e,n)=>!0===e.filtered?t.createElement(_o,{key:e.id,checked:u[n],onChange:e=>g(n,e)},e.label):null)),t.createElement(Na,{prepend:t.createElement(le,{name:"question"})},"リセットしたいフィルタのボタンをオフにしてください"),t.createElement(Ta,null),t.createElement(Za,null,t.createElement(cl,{type:"button",size:"small",color:"clear",onClick:f},"キャンセル"),t.createElement(cl,{type:"button",size:"small",onClick:b},"適用"))))},Nw=()=>{const{columns:e,setColumns:n,columnEditFeatures:r}=c(jy),i=l((()=>[...e].sort(((e,t)=>e.order-t.order))),[e]),o=l((()=>i.map((e=>e.id))),[i]),a=l((()=>i.filter((e=>Py(e,r))).map((e=>e.id))),[i,r]),s=d((t=>{r.reorder&&n(Gy(e,t,r))}),[r,e,n]),u=d((t=>{r.visibility&&n(e.map((e=>e.id===t?Object.assign(Object.assign({},e),{visible:!e.visible}):e)))}),[r.visibility,e,n]),p=d(((e,t)=>{if(t)return()=>u(e)}),[u]),m=(h=r).reorder&&h.visibility?"カラムの並び順、表示・非表示を切り替えます。":h.reorder?"カラムの並び順を変更します。":"カラムの表示・非表示を切り替えます。";var h;const g=i.map((e=>(e=>{const n=Py(e,r),i=_y(e,r),o=p(e.id,i),a=t.createElement(_o,{disabled:!i,checked:e.visible,onChange:o},e.label);return n?t.createElement(ia,{key:e.id,id:e.id},a):t.createElement(sa,{key:e.id,id:e.id},a)})(e)));return t.createElement(Sa,{width:328,trigger:t.createElement(Wo,null,"カラムを編集")},r.reorder&&a.length>0?t.createElement(ea,{order:a,displayOrder:o,onOrderChange:s},g):g,t.createElement(Na,{prepend:t.createElement(le,{name:"question"})},m))},Tw=()=>{const{pageSize:e,pageSizeOptions:n,setPageSize:r}=c(jy);return t.createElement(Sa,{width:136,trigger:t.createElement(Wo,{append:e},"件数を変更")},n.map((n=>t.createElement(Ro,{key:n,closeOnChange:!0,checked:e===n,onChange:()=>r(n)},n,"件"))))},Zw=[{value:-2,label:"より狭くする"},{value:-1,label:"狭くする"},{value:0,label:"標準"},{value:1,label:"広くする"},{value:2,label:"より広くする"}],Bw=()=>{const{rowSpacing:e,setRowSpacing:n}=c(jy),r=l((()=>{var t;return(null===(t=Zw.find((t=>t.value===e)))||void 0===t?void 0:t.label)||"標準"}),[e]);return t.createElement(Sa,{width:168,trigger:t.createElement(Wo,{append:r},"表示密度を変更")},Zw.map((({value:r,label:i})=>t.createElement(Ro,{key:r,closeOnChange:!0,checked:e===r,onChange:()=>(e=>{n(e)})(r)},i))))},Pw="small",_w="secondaryLight",Gw=({rangeStart:e,rangeEnd:n,totalCount:r,locationSuffix:i})=>t.createElement(cl,{inline:!0,type:"button","aria-label":`表示件数を変更${i}`,size:Pw,color:_w},t.createElement(iw,null,0===r?t.createElement(t.Fragment,null,t.createElement(ow,null,"0"),t.createElement(aw,null," / "),t.createElement(ow,null,"0")):t.createElement(t.Fragment,null,t.createElement(ow,null,Xy(e)),t.createElement(aw,null,"-"),t.createElement(ow,null,Xy(n)),t.createElement(aw,null,"/"),t.createElement(ow,null,Xy(r))),t.createElement(lw,null,t.createElement(le,{name:"arrow_down",size:"sm-md",color:"currentColor"})))),jw=({location:e="toolbar"})=>{const n=(e=>"footer"===e?"(下部)":"")(e),{totalCount:r,currentPage:i,pageSize:o,pageSizeOptions:a,setCurrentPage:s,setPageSize:u}=c(jy),p=d((e=>{s(0),u(e)}),[s,u]),m=l((()=>Math.ceil(r/o)-1),[r,o]),h=Math.min(i*o+1,r),g=Math.min((i+1)*o,r);return t.createElement(Xu,{minSize:"fit-content"},t.createElement(cl,{inline:!0,type:"button","aria-label":`前のページへ${n}`,size:Pw,color:_w,disabled:0===i||0===r,icon:t.createElement(le,{name:"arrow_left",size:"md",color:"currentColor"}),onClick:()=>s(Math.max(i-1,0))}),t.createElement(Da,null,t.createElement(Sa,{width:296,trigger:t.createElement(Gw,{rangeStart:h,rangeEnd:g,totalCount:r,locationSuffix:n})},t.createElement(Ra,null,"表示件数を変更"),a.map((e=>t.createElement(Ro,{key:e,checked:o===e,onChange:()=>p(e)},e))))),t.createElement(cl,{inline:!0,type:"button","aria-label":`次のページへ${n}`,size:Pw,color:_w,disabled:i===m||0===r,icon:t.createElement(le,{name:"arrow_right",size:"md",color:"currentColor"}),onClick:()=>s(Math.min(i+1,m))}))},Fw=({tableActions:e,customTableActionArea:n})=>{const{isSmallLayout:r,columns:o,columnEditFeatures:a,rowIds:s,checkedRows:u,setCheckedRows:p,hasRowControls:m}=c(jy),h=ne(),g=l((()=>s.length>0&&u.length===s.length),[u,s]),f=l((()=>0!==u.length&&u.length!==s.length),[u,s]),[b,v]=i(!1),[x,y]=i(!1),[w,C]=i(!1),E=l((()=>o.some((e=>void 0!==e.filtered))),[o]),I=d((()=>{p(g?[]:s)}),[g,s,p]),k=d(((e,n)=>((e,n,r,i)=>{if(n&&t.isValidElement(e)){let o=r?n.enabled:n.disabled||"currentColor";return"success"===o?o=i.palette.success.base:"danger"===o?o=i.palette.danger.base:"primary"===o?o=i.palette.primary.base:"warning"===o&&(o=i.palette.warning.base),t.cloneElement(e,Object.assign(Object.assign({},e.props),{color:o}))}return e})(e,n,u.length>0,h)),[u.length,h]),M=d(((e,n,r)=>{var i;return"singleButton"===e.type?t.createElement(cl,{key:Qy(e,n),icon:k(e.icon,e.dynamicIconColor),color:null!==(i=e.color)&&void 0!==i?i:"secondaryLight",size:"small",inline:r,style:e.style,disabled:Uy(e,u),onClick:()=>e.onClick(u)},e.label):"groupButton"===e.type?t.createElement(Qu,{key:Qy(e,n),size:"small"},e.items.map(((e,r)=>{var i;return t.createElement(cl,{key:qy(e,n,r),icon:k(e.icon,e.dynamicIconColor),color:null!==(i=e.color)&&void 0!==i?i:"secondaryLight",style:e.style,disabled:Uy(e,u),onClick:()=>e.onClick(u)},e.label)}))):"separator"===e.type?t.createElement(Sw,{key:Qy(e,n)}):"heading"===e.type?t.createElement("span",{key:Qy(e,n),style:{padding:"8px",fontSize:"14px",fontWeight:"bold"}},e.label):t.createElement(Sw,{key:Qy(e,n)})}),[u,k]),$=d(((e,n=!1)=>{const r=[],i=new Set;return e.forEach(((o,a)=>{if("singleButton"!==o.type&&"groupButton"!==o.type||!o.headingLabel||i.has(o.headingLabel))"singleButton"!==o.type&&"groupButton"!==o.type||o.headingLabel?"separator"===o.type?r.push(t.createElement(Ta,{key:`separator-${a}`})):"heading"===o.type?r.push(t.createElement(Ra,{key:`heading-${o.label||a}`},o.label)):"divider"===o.type&&r.push(t.createElement(Ta,{key:`divider-${a}`})):"singleButton"===o.type?r.push(t.createElement(Dt,{key:`single-${o.label||a}`,prepend:k(o.icon,o.dynamicIconColor),disabled:Uy(o,u,n),onClick:()=>{o.onClick(u),n?C(!1):y(!1)}},o.label)):"groupButton"===o.type&&o.items.forEach(((e,i)=>{r.push(t.createElement(Dt,{key:Ky(e,"mobile-group",a,i),prepend:k(e.icon,e.dynamicIconColor),disabled:Uy(e,u,n),onClick:()=>{e.onClick(u),n?C(!1):y(!1)}},e.label))}));else{i.add(o.headingLabel);const a=e.filter((e=>("singleButton"===e.type||"groupButton"===e.type)&&e.headingLabel===o.headingLabel));r.push(t.createElement(Ra,{key:`group-${o.headingLabel}-heading`},o.headingLabel)),a.forEach(((e,i)=>{"singleButton"===e.type?r.push(t.createElement(Dt,{key:`group-${e.headingLabel}-${e.label||i}`,prepend:k(e.icon,e.dynamicIconColor),disabled:Uy(e,u,n),onClick:()=>{e.onClick(u),n?C(!1):y(!1)}},e.label)):"groupButton"===e.type&&e.items.forEach(((e,a)=>{r.push(t.createElement(Dt,{key:Ky(e,`group-${o.headingLabel}-group`,i,a),prepend:k(e.icon,e.dynamicIconColor),disabled:Uy(e,u,n),onClick:()=>{e.onClick(u),n?C(!1):y(!1)}},e.label))}))}))}})),r}),[u,y,C,k]);let A=null;if(n)A=n({isSmallLayout:r,checkedRows:u});else if(e&&e.length>0){const{checkedActions:n,uncheckedActions:i}={checkedActions:(L=e).filter((e=>{const t="enabledWhen"in e?e.enabledWhen:void 0;return"checked"===t||void 0===t})),uncheckedActions:L.filter((e=>"unchecked"===("enabledWhen"in e?e.enabledWhen:void 0)))};if(r)A=t.createElement(Dw,null,n.length>0&&t.createElement(Da,null,t.createElement(Sa,{open:x,trigger:t.createElement(Rw,{type:"button",disabled:0===u.length},t.createElement("span",{style:{color:0===u.length?"inherit":h.palette.primary.base,fontWeight:700}},0===u.length?"-":u.length),"件を操作",t.createElement(le,{name:"arrow_down",size:"sm-md",color:"currentColor"})),width:200,onOpenChange:y},$(n))),i.length>0&&t.createElement(Da,null,t.createElement(Sa,{open:w,trigger:t.createElement(cl,{type:"button",color:"secondaryLight",size:"small",icon:t.createElement(le,{name:"more_vert",color:"currentColor"}),disabled:u.length>0}),width:200,onOpenChange:C},$(i,!0))));else{const{dropdownActions:e}=Jy(n),{dropdownActions:r}=Jy(i),o=()=>{const r=[];return n.forEach(((n,i)=>{var o;const a=null!==(o=n.displayIn)&&void 0!==o?o:"toolbar";if("toolbar"===a)r.push(M(n,i,!0));else if("dropdown"===a){r.some((e=>t.isValidElement(e)&&"checked-dropdown"===e.key))||r.push(t.createElement(Da,{key:"checked-dropdown"},t.createElement(Sa,{open:x,trigger:t.createElement(cl,{type:"button",color:"secondaryLight",size:"small",icon:t.createElement(le,{name:"more_vert",color:"currentColor"}),disabled:0===u.length}),width:200,onOpenChange:y},e.map(((e,n)=>"singleButton"===e.type?t.createElement(Dt,{key:`checked-single-${e.label||n}`,prepend:k(e.icon,e.dynamicIconColor),disabled:Uy(e,u),onClick:()=>{e.onClick(u),y(!1)}},e.label):"groupButton"===e.type?e.items.map(((e,r)=>t.createElement(Dt,{key:Ky(e,"checked-group",n,r),prepend:k(e.icon,e.dynamicIconColor),disabled:Uy(e,u),onClick:()=>{e.onClick(u),y(!1)}},e.label))):"separator"===e.type?t.createElement(Ta,{key:`checked-separator-sep-${n}`}):"heading"===e.type?t.createElement(Ra,{key:`checked-heading-${e.label||`heading${n}`}`},e.label):t.createElement(Ta,{key:`checked-divider-div-${n}`}))))))}})),r},a=()=>{const e=[];return i.forEach(((n,i)=>{var o;const a=null!==(o=n.displayIn)&&void 0!==o?o:"toolbar";if("toolbar"===a)e.push(M(n,i,!0));else if("dropdown"===a){e.some((e=>t.isValidElement(e)&&"unchecked-dropdown"===e.key))||e.push(t.createElement(Da,{key:"unchecked-dropdown"},t.createElement(Sa,{open:w,trigger:t.createElement(cl,{type:"button",color:"secondaryLight",size:"small",icon:t.createElement(le,{name:"more_vert",color:"currentColor"}),disabled:u.length>0}),width:200,onOpenChange:C},r.map(((e,n)=>"singleButton"===e.type?t.createElement(Dt,{key:`unchecked-single-${e.label||n}`,prepend:k(e.icon,e.dynamicIconColor),disabled:Uy(e,u,!0),onClick:()=>{e.onClick(u),C(!1)}},e.label):"groupButton"===e.type?e.items.map(((e,r)=>t.createElement(Dt,{key:Ky(e,"unchecked-group",n,r),prepend:k(e.icon,e.dynamicIconColor),disabled:Uy(e,u,!0),onClick:()=>{e.onClick(u),C(!1)}},e.label))):"separator"===e.type?t.createElement(Ta,{key:`unchecked-separator-sep-${n}`}):"heading"===e.type?t.createElement(Ra,{key:`unchecked-heading-${e.label||`heading${n}`}`},e.label):t.createElement(Ta,{key:`unchecked-divider-div-${n}`}))))))}})),e};A=t.createElement(Dw,null,o(),n.length>0&&i.length>0&&t.createElement(Sw,null),a())}}var L;return t.createElement(rw,{isSmallLayout:r},t.createElement(Vw,null,m&&t.createElement(t.Fragment,null,t.createElement(Kd,{checked:g||f,indeterminate:f,disabled:0===s.length,"aria-label":"すべての行を選択",onChange:I}),!r&&t.createElement(Hw,null,t.createElement("span",{style:{color:h.palette.primary.base,fontWeight:700}},0===u.length?"-":u.length),"件を")),A),t.createElement(cw,null,E&&t.createElement(zw,null),t.createElement(jw,null),t.createElement(Da,null,t.createElement(Sa,{open:b,width:316,trigger:t.createElement(cl,{type:"button",color:"secondaryLight",size:"small",icon:t.createElement(le,{name:"setting",color:"currentColor"})}),onOpenChange:v},function(e,t){return!(!t.reorder&&!t.visibility)&&e.some((e=>Py(e,t)||_y(e,t)))}(o,a)&&t.createElement(Nw,null),t.createElement(Tw,null),t.createElement(Bw,null)))))},Yw=()=>{const{isSmallLayout:e}=c(jy);return t.createElement(dw,{isSmallLayout:e},t.createElement(jw,{location:"footer"}))},Ww=({children:e})=>{const[n,r]=i(!0),l=o(null),s=d((()=>{const e=l.current;if(!e)return;const{scrollLeft:t,scrollWidth:n,clientWidth:i}=e,o=Math.max(0,n-i),a=o>.5&&!(t>=o-1);r((e=>e===a?e:a))}),[]);return a((()=>{const e=l.current;if(!e)return;s(),e.addEventListener("scroll",s,{passive:!0});const t=new ResizeObserver(s);t.observe(e);const n=e.firstElementChild;return n instanceof HTMLElement&&t.observe(n),()=>{e.removeEventListener("scroll",s),t.disconnect()}}),[s]),t.createElement(Fy.Provider,{value:{showStickyRightEdgeDecoration:n}},t.createElement(nw,{ref:l},t.createElement("table",null,e)))},Xw=({bordered:e,currentPage:n,pageSize:r,pageSizeOptions:s,totalCount:c,columns:u,onPageChange:p,onPageSizeChange:m,onColumnsChange:h,onCheckedRowsChange:g,children:f,tableActions:b,customTableActionArea:v,enableRowSelection:x=!0,columnEditFeatures:y,showBottomPagination:w=!1})=>{const C=l((()=>{return{reorder:null!==(t=null==(e=y)?void 0:e.reorder)&&void 0!==t?t:Zy,visibility:null!==(n=null==e?void 0:e.visibility)&&void 0!==n?n:By};var e,t,n}),[y]),[E,I]=i(!1),[k,M]=i([]),[$,A]=i([]),[L,V]=i([]),[H,O]=i(0),S=o(null),D=d(((e,t)=>{const n=[...L];n[e]=t,V(n)}),[L,V]);a((()=>{if(!S.current)return;const e=()=>{var e;S.current&&I((null===(e=S.current)||void 0===e?void 0:e.clientWidth)<F.TABLET)},t=new ResizeObserver(e);return e(),t.observe(S.current),()=>{t.disconnect()}}),[]);const R=d((e=>{A(e),null==g||g(e)}),[A,g]),z=o(n);a((()=>{z.current!==n&&R([]),z.current=n}),[n,R]),a((()=>{if(0===$.length)return;const e=$.filter((e=>k.includes(e)));e.length!==$.length&&R(e)}),[k,$,R]);const N=l((()=>Math.ceil(c/r)-1),[c,r]);a((()=>{n>N&&p(N)}),[n,N,p]);const T=x&&!!b,[Z,B]=i(null),P=d(((e,t)=>{B((n=>void 0===t?n===e?null:n:null!==n&&n!==e?("production"!==process.env.NODE_ENV&&console.warn(`[DataTable2] sticky="right" は 1 列のみです。既に列 index ${String(n)} で使用されているため、列 ${String(e)} の登録は無視しました。`),n):e))}),[]),_=l((()=>{const e=u.filter((e=>e.visible)).length;return{registerColumnSticky:P,getStickyRightOffset:t=>{var n;if(null===Z||t!==Z)return;let r=0;for(let i=t+1;i<e;i++)r+=null!==(n=L[i])&&void 0!==n?n:0;return r},rightStickyColumnIndex:Z,getRightStickyZIndexHead:e=>3,getRightStickyZIndexBody:e=>1}}),[L,u,P,Z]);return t.createElement(tw,{ref:S,bordered:e},t.createElement(jy.Provider,{value:{isSmallLayout:E,rowIds:k,enableRowSelection:x,hasRowControls:T,checkedRows:$,totalCount:c,currentPage:n,pageSize:r,pageSizeOptions:s,columns:u,columnEditFeatures:C,columnWidths:L,rowSpacing:H,setRowIds:M,setCheckedRows:R,setCurrentPage:p,setPageSize:m,setColumns:h,setColumnWidth:D,setRowSpacing:O}},t.createElement(Yy.Provider,{value:_},t.createElement(Fw,{tableActions:b,customTableActionArea:v}),t.createElement(Ww,null,f),w&&t.createElement(Yw,null))))},Jw=({children:e})=>{const{hasRowControls:n,columns:r}=c(jy),i=l((()=>p.toArray(e).map(((e,t)=>{const n=r[t];return{id:n.id,index:t,order:n.order,visible:n.visible,child:e}})).filter((e=>void 0!==e.id))),[e,r]),o=l((()=>i.sort(((e,t)=>e.order-t.order)).filter((e=>e.visible))),[i]);return t.createElement(t.Fragment,null,t.createElement("colgroup",null,n&&t.createElement("col",{style:{width:34}}),o.map((({id:e,child:n})=>m(n)?t.createElement("col",{key:e,style:{width:n.props.width}}):null))),t.createElement(pw,null,t.createElement("tr",null,n&&t.createElement(Ew,{"aria-label":"empty cell"}),o.map((({id:e,index:n,child:r})=>t.createElement(Wy.Provider,{key:e,value:{index:n}},r))))))},Uw=({className:e,sticky:n,isResizable:r,width:l,minWidth:s=32,maxWidth:u=1/0,children:p,onWidthChange:m})=>{const{isSmallLayout:h,setColumnWidth:g}=c(jy),{registerColumnSticky:f,getStickyRightOffset:b,rightStickyColumnIndex:v,getRightStickyZIndexHead:x}=c(Yy),{showStickyRightEdgeDecoration:y}=c(Fy),w=c(Wy),[C,E]=i(!1);a((()=>(f(w.index,"right"===n?"right":void 0),()=>{f(w.index,void 0)})),[n,w.index,f]);const I=b(w.index),M=void 0!==I&&w.index===v&&y,$=void 0!==I?x(w.index):void 0,A=o(null),L=o(null),V=o(0),H=o(0),O=d((e=>{E(!0),L.current&&null===A.current&&(A.current=e.pointerId,H.current=l||L.current.clientWidth,V.current=e.clientX)}),[l]),S=d((e=>{if(!m)return;if(A.current!==e.pointerId)return;e.cancelable&&e.preventDefault();const t=e.clientX-V.current,n=((e,t,n)=>Math.min(Math.max(e,t),n))(H.current+t,s,u);m(n),g(w.index,n)}),[m,s,u,g,w.index]),D=d((()=>{E(!1),A.current=null}),[]);return a((()=>{if(C)return document.addEventListener("pointermove",S),document.addEventListener("pointerup",D),()=>{document.removeEventListener("pointermove",S),document.removeEventListener("pointerup",D)}}),[C,S,D]),t.createElement(mw,{ref:L,className:e,"data-dragging":C,$stickyRightOffset:I,$stickyZIndex:$,$showStickyEdgeDecoration:M,style:{minWidth:isFinite(s)&&s<=u?s:void 0,maxWidth:isFinite(s)&&s<=u?u:void 0}},t.createElement(gw,{isSmallLayout:h},p,r&&t.createElement(fw,{type:"button","aria-label":"resize the column",onPointerDown:O}),C&&k(t.createElement(bw,{"data-min":l&&s>=l,"data-max":l&&u<=l}),document.body)))},Qw=({showSortButton:e,sortButtonDirection:n,onSortChange:r,children:i})=>{const o=l((()=>"asc"===n?"desc":"desc"!==n?"asc":void 0),[n]),a=d((()=>{null==r||r(o)}),[r,o]),s=l((()=>"asc"===n?"sort_up":"desc"===n?"sort_down":"sort_inactive"),[n]);return e?t.createElement(yw,{type:"button",onClick:a},i,t.createElement(le,{name:s,size:"md"})):t.createElement(xw,null,i)},qw=({children:e})=>{const{rowIds:n,setRowIds:r}=c(jy);return a((()=>{const t=[];p.forEach(e,(e=>{if(!m(e))return;const n=e.props;"string"==typeof n.id&&t.push(n.id)})),t.length===n.length&&t.every((e=>n.includes(e)))||r(t)}),[e,n,r]),t.createElement("tbody",null,e)},Kw=({id:e,children:n})=>{const{isSmallLayout:r,columns:i,hasRowControls:o,checkedRows:a,setCheckedRows:s,rowSpacing:u}=c(jy),m=l((()=>a.includes(e)),[e,a]),h=d((()=>{const t=a.includes(e)?a.filter((t=>t!==e)):[...a,e];s(t)}),[e,a,s]),g=l((()=>p.toArray(n).map(((e,t)=>{const n=i[t];return{id:n.id,index:t,order:n.order,visible:n.visible,child:e}})).filter((e=>void 0!==e.id))),[n,i]),f=l((()=>g.sort(((e,t)=>e.order-t.order)).filter((e=>e.visible))),[g]);return t.createElement(ww,{"data-highlighted":m,"data-spacing":u,isSmallLayout:r},o&&t.createElement(Cw,null,t.createElement(Iw,null,t.createElement(Kd,{checked:m,"aria-label":"この行を選択",onChange:h}),t.createElement("input",{type:"checkbox","aria-label":"この行を選択"}))),f.map((({id:e,index:n,child:r})=>t.createElement(Wy.Provider,{key:e,value:{index:n}},r))))},eC=({loading:e,sticky:n,children:r})=>{const{getStickyRightOffset:i,rightStickyColumnIndex:o,getRightStickyZIndexBody:a}=c(Yy),{showStickyRightEdgeDecoration:l}=c(Fy),s=c(Wy),d=i(s.index),u=void 0!==d&&s.index===o&&l,p=void 0!==d?a(s.index):void 0;return t.createElement(hw,{$stickyRightOffset:d,$stickyZIndex:p,$showStickyEdgeDecoration:u},t.createElement(kw,null,t.createElement($w,null,r),e&&t.createElement(Mw,null,t.createElement(rl,{width:"20px"}))))},tC=({prepend:e,children:n,onClick:r})=>{const{isSmallLayout:i}=c(jy);return i?t.createElement(Dt,{prepend:e,onClick:r},n):t.createElement(uw,{type:"button",onClick:r},e,n)},nC=({label:e,value:n,children:r,onChange:o})=>{const[l,s]=i(n),[c,d]=i(!1),u=()=>{d(!1),o(l)};return a((()=>{s(n)}),[n]),t.createElement(Aw,null,r,t.createElement(Lw,null,t.createElement(Da,null,t.createElement(Sa,{width:252,trigger:t.createElement(cl,{type:"button",color:"primarySubtle",size:"small",inline:!0,icon:t.createElement(le,{name:"pencil",color:"currentColor"})}),open:c,onOpenChange:d},t.createElement(Ra,null,e),t.createElement(ya,{value:l,onChange:e=>s(e.target.value),onEnter:u}),t.createElement(Ta,null),t.createElement(Za,null,t.createElement(cl,{type:"button",color:"clear",size:"small",onClick:()=>{d(!1),s(n)}},"キャンセル"),t.createElement(cl,{type:"button",color:"primary",size:"small",onClick:u},"適用"))))))},rC=({label:e,value:n,options:r,children:o,onChange:a})=>{const[l,s]=i(!1);return t.createElement(Aw,null,o,t.createElement(Lw,null,t.createElement(Da,null,t.createElement(Sa,{width:252,trigger:t.createElement(cl,{type:"button",color:"primarySubtle",size:"small",inline:!0,icon:t.createElement(le,{name:"pencil",color:"currentColor"})}),open:l,onOpenChange:s},t.createElement(Ra,null,e),r.map((e=>t.createElement(Ro,{key:e,closeOnChange:!0,checked:n===e,onChange:()=>a(e)},e)))))))},iC=e=>{if(!e)return[];const t=[];let n=0,r=!isNaN(Number(e[0]));for(let i=1;i<=e.length;i++){const o=e[i],a=!isNaN(Number(o))&&" "!==o;a===r&&" "!==o&&i!==e.length||(t.push({start:n,end:i-1,value:e.slice(n,i),editable:r}),n=i,r=a)}return t},oC=e=>e.map((e=>e.value)).join(""),aC=(e,t,n)=>{if(4===e)return"year";if(2===e){const e=(t.match(/[YMD]+/g)||[]).map(((e,t)=>({token:e,length:e.length,index:t}))),r=e[n];if(r){if(r.token.includes("Y"))return"year";if(r.token.includes("M"))return"month";if(r.token.includes("D"))return"day"}}return"unknown"},lC=(e,t,n,r)=>{if(0===t){const t=parseInt(e);return"month"===n?t>=2:"day"===n&&t>=4}return t+1===r},sC={Backspace:"Backspace",Delete:"Delete",ArrowLeft:"ArrowLeft",ArrowRight:"ArrowRight",ArrowUp:"ArrowUp",ArrowDown:"ArrowDown",Tab:"Tab",0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},cC=["Numpad0","Numpad1","Numpad2","Numpad3","Numpad4","Numpad5","Numpad6","Numpad7","Numpad8","Numpad9"],dC=Object.keys(sC).filter((e=>!isNaN(Number(e)))),uC=Object.values(sC),pC=e=>cC.includes(e),mC=e=>{const t=e.match(/Numpad(\d)/);return t?t[1]:null},hC=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|YYYY|YY?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,gC=/\d\d/,fC=/-?\d\d?/,bC=/\d*[^-_:/,()\s\d]+/;let vC={},xC=function(e){return(e=+e)+(e>68?1900:2e3)};const yC=function(e){return function(t){this[e]=+t}},wC=[/[+-]\d\d:?(\d\d)?|Z/,function(e){(this.zone||(this.zone={})).offset=function(e){if(!e)return 0;if("Z"===e)return 0;const t=e.match(/([+-]|\d\d)/g),n=60*t[1]+(+t[2]||0);return 0===n?0:"+"===t[0]?-n:n}(e)}],CC=e=>{const t=vC[e];return t&&(t.indexOf?t:t.s.concat(t.f))},EC=(e,t)=>{let n;const{meridiem:r}=vC;if(r){for(let i=1;i<=24;i+=1)if(e.indexOf(r(i,0,t))>-1){n=i>12;break}}else n=e===(t?"pm":"PM");return n},IC={A:[bC,function(e){this.afternoon=EC(e,!1)}],a:[bC,function(e){this.afternoon=EC(e,!0)}],S:[/\d/,function(e){this.milliseconds=100*+e}],SS:[gC,function(e){this.milliseconds=10*+e}],SSS:[/\d{3}/,function(e){this.milliseconds=+e}],s:[fC,yC("seconds")],ss:[fC,yC("seconds")],m:[fC,yC("minutes")],mm:[fC,yC("minutes")],H:[fC,yC("hours")],h:[fC,yC("hours")],HH:[fC,yC("hours")],hh:[fC,yC("hours")],D:[fC,yC("day")],DD:[gC,yC("day")],Do:[bC,function(e){const{ordinal:t}=vC;if([this.day]=e.match(/\d+/),t)for(let n=1;n<=31;n+=1)t(n).replace(/\[|\]/g,"")===e&&(this.day=n)}],M:[fC,yC("month")],MM:[gC,yC("month")],MMM:[bC,function(e){const t=CC("months"),n=(CC("monthsShort")||t.map((e=>e.slice(0,3)))).indexOf(e)+1;if(n<1)throw new Error;this.month=n%12||n}],MMMM:[bC,function(e){const t=CC("months").indexOf(e)+1;if(t<1)throw new Error;this.month=t%12||t}],Y:[/[+-]?\d+/,yC("year")],YY:[gC,function(e){this.year=xC(e)}],YYYY:[/\d{4}/,yC("year")],Z:wC,ZZ:wC};const kC=(e,t,n)=>{try{if(["x","X"].indexOf(t)>-1)return new Date(("X"===t?1e3:1)*e);const r=function(e){const t=e.match(hC),{length:n}=t;for(let e=0;e<n;e+=1){const n=t[e],r=IC[n],i=r&&r[0],o=r&&r[1];t[e]=o?{regex:i,parser:o}:n.replace(/^\[|\]$/g,"")}return function(e){const r={};for(let i=0,o=0;i<n;i+=1){const n=t[i];if("string"==typeof n)o+=n.length;else{const{regex:t,parser:i}=n,a=e.slice(o),l=t.exec(a)[0];i.call(r,l),e=e.replace(l,"")}}return function(e){const{afternoon:t}=e;if(void 0!==t){const{hours:n}=e;t?n<12&&(e.hours+=12):12===n&&(e.hours=0),delete e.afternoon}}(r),r}}(t),{year:i,month:o,day:a,hours:l,minutes:s,seconds:c,milliseconds:d,zone:u}=r(e),p=new Date,m=i||p.getFullYear(),h=o-1,g=l||0,f=s||0,b=c||0,v=d||0;return u?new Date(Date.UTC(m,h,a,g,f,b,v+60*u.offset*1e3)):n?new Date(Date.UTC(m,h,a,g,f,b,v)):new Date(m,h,a,g,f,b,v)}catch(e){return new Date("")}};var MC=(e,t,n)=>{n.p.customParseFormat=!0,e&&e.parseTwoDigitYear&&({parseTwoDigitYear:xC}=e);const r=t.prototype,i=r.parse;r.parse=function(e){const{date:t,utc:r,args:o}=e;this.$u=r;const a=o[1];if("string"==typeof a){const e=!0===o[2],i=!0===o[3],l=e||i;let s=o[2];i&&([,,s]=o),vC=this.$locale(),!e&&s&&(vC=n.Ls[s]),this.$d=kC(t,a,r),this.init(),s&&!0!==s&&(this.$L=this.locale(s).$L),l&&t!=this.format(a)&&(this.$d=new Date("")),vC={}}else if(a instanceof Array){const e=a.length;for(let t=1;t<=e;t+=1){o[1]=a[t-1];const r=n.apply(this,o);if(r.isValid()){this.$d=r.$d,this.$L=r.$L,this.init();break}t===e&&(this.$d=new Date(""))}}else i.call(this,e)}};const $C=({date:e,format:t="YYYY-MM-DD",onDateChange:n})=>{_a.extend(MC);const r=o(null),[l,s]=i(null==e?void 0:e.format(t)),[c,u]=i(iC(l)),[p,m]=i({start:0,end:c.length-1,current:0}),[h,g]=i(0),f=d((()=>{setTimeout((()=>{var e,t,n;if(0===c.length)return;const i=null!==(t=null===(e=r.current)||void 0===e?void 0:e.selectionStart)&&void 0!==t?t:0,o=c[c.length-1].end+1,a=i>=o?o:i,l=c.findIndex((e=>a>=e.start&&a<=e.end+1));-1!==l&&(m((e=>c[l].editable?e.current===l?e:Object.assign(Object.assign({},e),{current:l}):Object.assign(Object.assign({},e),{current:l+1}))),null===(n=r.current)||void 0===n||n.setSelectionRange(c[l].start,c[l].end+1))}))}),[c]),b=d((()=>{}),[]),v=d((()=>{m((e=>Object.assign(Object.assign({},e),{current:0}))),g(0)}),[]),x=d((e=>{if(0===c.length)return;const r=pC(e.code),i=r?mC(e.code):null;if(!uC.includes(e.key)&&!r)return;if(e.key===sC.ArrowLeft||e.key===sC.ArrowRight){e.preventDefault();const t=e=>{const t=p.current;if(e===sC.ArrowLeft){for(let e=t-1;e>=0;e--)if(c[e].editable)return e-t}else if(e===sC.ArrowRight)for(let e=t+1;e<c.length;e++)if(c[e].editable)return e-t;return 0},n=e.key;m((e=>Object.assign(Object.assign({},e),{current:e.current+t(n)})))}if(e.key===sC.ArrowUp||e.key===sC.ArrowDown){e.preventDefault();const r=e.key===sC.ArrowUp?1:-1,i=Number(c[p.current].value)+r,o=String(i).padStart(c[p.current].value.length,"0"),a=[...c];a[p.current].value=o,u(a);const l=oC(a),d=_a(l,t);s(d.format(t)),d.isValid()&&n&&n(d)}const o=r?i:e.key;if((dC.includes(e.key)||r)&&o){e.preventDefault(),0===h&&(c[p.current].value="".padStart(c[p.current].value.length,"0"));const r=`${c[p.current].value.slice(1)}${o}`,i=[...c];i[p.current].value=r,u(i),g(h+1);const a=aC(c[p.current].value.length,t,p.current);if(lC(o,h,a,c[p.current].value.length)){g(0);for(let e=p.current+1;e<c.length;e++)if(c[e].editable){m((t=>Object.assign(Object.assign({},t),{current:e})));break}const e=oC(c),r=_a(e,t);s(r.format(t)),n&&n(r)}else{const e=oC(c);if(!_a(e,t,!0).isValid())return void s(e);const r=_a(e,t);s(r.format(t)),n&&n(r)}}}),[c,t,n,p]),y=d((()=>{f()}),[f]),w=d((e=>{e.preventDefault();const r=e.clipboardData.getData("text").trim(),i=/[Hh]|mm|ss/.test(t),o=[];o.push(t),o.push("YYYY年M月D日","YYYY年MM月DD日"),i&&o.push("YYYY年M月D日 HH:mm","YYYY年MM月DD日 HH:mm","YYYY年M月D日 HH:mm:ss","YYYY年MM月DD日 HH:mm:ss"),o.push("YYYY-MM-DD","YYYY-M-DD","YYYY-MM-D","YYYY-M-D"),i&&o.push("YYYY-MM-DD HH:mm","YYYY-M-DD HH:mm","YYYY-MM-D HH:mm","YYYY-M-D HH:mm","YYYY-MM-DD HH:mm:ss","YYYY-M-DD HH:mm:ss","YYYY-MM-D HH:mm:ss","YYYY-M-D HH:mm:ss"),o.push("YYYY/MM/DD","YYYY/M/DD","YYYY/MM/D","YYYY/M/D"),i&&o.push("YYYY/MM/DD HH:mm","YYYY/M/DD HH:mm","YYYY/MM/D HH:mm","YYYY/M/D HH:mm","YYYY/MM/DD HH:mm:ss","YYYY/M/DD HH:mm:ss","YYYY/MM/D HH:mm:ss","YYYY/M/D HH:mm:ss");const a=r.match(/(\d{4})[-/年](\d{1,2})[-/月](\d{1,2})/);if(a){const e=parseInt(a[1],10),t=parseInt(a[2],10),n=parseInt(a[3],10);if(!(e>=1900&&e<=2100&&t>=1&&t<=12&&n>=1&&n<=31))return;if(n>_a(`${e}-${t}-01`).daysInMonth())return}let l=null;const s=_a(r);if(s.isValid())l=s;else for(const e of o){const t=_a(r,e,!0);if(t.isValid()){l=t;break}}if(!l||!l.isValid())return;const c=l.year(),d=l.month()+1,u=l.date();if(c>=1900&&c<=2100&&d>=1&&d<=12&&u>=1&&u<=31){if(i){const e=r.match(/(\d{1,2}):(\d{1,2})(?::(\d{1,2}))?/);if(e){const t=parseInt(e[1],10),n=parseInt(e[2],10),r=e[3]?parseInt(e[3],10):0;if(!(!isNaN(t)&&!isNaN(n)&&!isNaN(r)&&t>=0&&t<=23&&n>=0&&n<=59&&r>=0&&r<=59))return}}n&&n(l)}}),[t,n]);return a((()=>{var e;if(0===c.length)return;const t=c[p.current];t&&(null===(e=r.current)||void 0===e||e.setSelectionRange(t.start,t.end+1))}),[p,c]),a((()=>{s(null==e?void 0:e.format(t)),u(iC(null==e?void 0:e.format(t)))}),[e,t]),{ref:r,value:l,onFocus:b,onBlur:v,onKeyDown:x,onMouseDown:y,onPaste:w}},AC=e=>[...e.split("")].reduce(((e,t)=>{const n=t.charCodeAt(0);return e+(n>=12288&&n<=65376?2:1)}),0),LC=n((function(e,n){var{error:r=!1,errorText:i,format:o="YYYY-MM-DD",disabled:a=!1,size:s="medium",variant:c="light",width:d,append:u,onAppendClick:p}=e,m=D(e,["error","errorText","format","disabled","size","variant","width","append","onAppendClick"]);Ae("DateField","DateField は非推奨です。代わりに DateField2 を使用してください。");const h=$C(Object.assign({format:o},m)),{ref:g}=h,f=D(h,["ref"]),b=Vc(n,g),v=l((()=>9*AC(o)*(parseInt(ca[s].fontSize)/13)+"px"),[o,s]),x=null!=d?d:v;return t.createElement(t.Fragment,null,t.createElement(va,Object.assign({ref:b,readOnly:!0,error:r||!!i,disabled:a,size:s,variant:c,width:x,append:u,onAppendClick:p},f)),i&&t.createElement(Ua,{pt:1},t.createElement(nd,null,i)))}));var VC=g(LC);const HC=v.div`
|
|
2915
|
+
`,Nw=()=>{const{columns:e,setColumns:n,isSmallLayout:r}=c(Fy),[o,s]=i(!1),[u,p]=i(e.map((e=>e.filtered||!1))),m=l((()=>e.filter((e=>e.filtered)).length),[e]),h=d((()=>{p(e.map((e=>e.filtered||!1)))}),[e]),g=d(((e,t)=>{p((n=>n.map(((n,r)=>e===r?t:n))))}),[p]),f=d((()=>{h(),s(!1)}),[h]),b=d((()=>{const t=structuredClone(e).map(((e,t)=>Object.assign(Object.assign({},e),{filtered:u[t]})));n(t),s(!1)}),[e,n,u]),v=d((e=>{s(e),e||h()}),[s,h]);return a((()=>h()),[e,h]),t.createElement(Da,null,t.createElement(Sa,{width:360,trigger:t.createElement(cw,{type:"button",disabled:0===m},t.createElement(le,{name:"filter",color:"currentColor"}),r?m:`${m}列に適用中`),open:o,onOpenChange:v},t.createElement(Ra,null,"フィルタが適用されている列"),e.map(((e,n)=>!0===e.filtered?t.createElement(_o,{key:e.id,checked:u[n],onChange:e=>g(n,e)},e.label):null)),t.createElement(Na,{prepend:t.createElement(le,{name:"question"})},"リセットしたいフィルタのボタンをオフにしてください"),t.createElement(Ta,null),t.createElement(Za,null,t.createElement(cl,{type:"button",size:"small",color:"clear",onClick:f},"キャンセル"),t.createElement(cl,{type:"button",size:"small",onClick:b},"適用"))))},Tw=()=>{const{columns:e,setColumns:n,columnEditFeatures:r}=c(Fy),i=l((()=>[...e].sort(((e,t)=>e.order-t.order))),[e]),o=l((()=>i.map((e=>e.id))),[i]),a=l((()=>i.filter((e=>_y(e,r))).map((e=>e.id))),[i,r]),s=d((t=>{r.reorder&&n(jy(e,t,r))}),[r,e,n]),u=d((t=>{r.visibility&&n(e.map((e=>e.id===t?Object.assign(Object.assign({},e),{visible:!e.visible}):e)))}),[r.visibility,e,n]),p=d(((e,t)=>{if(t)return()=>u(e)}),[u]),m=(h=r).reorder&&h.visibility?"カラムの並び順、表示・非表示を切り替えます。":h.reorder?"カラムの並び順を変更します。":"カラムの表示・非表示を切り替えます。";var h;const g=i.map((e=>(e=>{const n=_y(e,r),i=Gy(e,r),o=p(e.id,i),a=t.createElement(_o,{disabled:!i,checked:e.visible,onChange:o},e.label);return n?t.createElement(ia,{key:e.id,id:e.id},a):t.createElement(sa,{key:e.id,id:e.id},a)})(e)));return t.createElement(Sa,{width:328,trigger:t.createElement(Wo,null,"カラムを編集")},r.reorder&&a.length>0?t.createElement(ea,{order:a,displayOrder:o,onOrderChange:s},g):g,t.createElement(Na,{prepend:t.createElement(le,{name:"question"})},m))},Zw=()=>{const{pageSize:e,pageSizeOptions:n,setPageSize:r}=c(Fy);return t.createElement(Sa,{width:136,trigger:t.createElement(Wo,{append:e},"件数を変更")},n.map((n=>t.createElement(Ro,{key:n,closeOnChange:!0,checked:e===n,onChange:()=>r(n)},n,"件"))))},Bw=[{value:-2,label:"より狭くする"},{value:-1,label:"狭くする"},{value:0,label:"標準"},{value:1,label:"広くする"},{value:2,label:"より広くする"}],Pw=()=>{const{rowSpacing:e,setRowSpacing:n}=c(Fy),r=l((()=>{var t;return(null===(t=Bw.find((t=>t.value===e)))||void 0===t?void 0:t.label)||"標準"}),[e]);return t.createElement(Sa,{width:168,trigger:t.createElement(Wo,{append:r},"表示密度を変更")},Bw.map((({value:r,label:i})=>t.createElement(Ro,{key:r,closeOnChange:!0,checked:e===r,onChange:()=>(e=>{n(e)})(r)},i))))},_w="small",Gw="secondaryLight",jw=n((function(e,n){var{rangeStart:r,rangeEnd:i,totalCount:o,locationSuffix:a}=e,l=D(e,["rangeStart","rangeEnd","totalCount","locationSuffix"]);return t.createElement(cl,Object.assign({},l,{ref:n,inline:!0,type:"button","aria-label":`表示件数を変更${a}`,size:_w,color:Gw}),t.createElement(ow,null,0===o?t.createElement(t.Fragment,null,t.createElement(aw,null,"0"),t.createElement(lw,null," / "),t.createElement(aw,null,"0")):t.createElement(t.Fragment,null,t.createElement(aw,null,Jy(r)),t.createElement(lw,null,"-"),t.createElement(aw,null,Jy(i)),t.createElement(lw,null,"/"),t.createElement(aw,null,Jy(o))),t.createElement(sw,null,t.createElement(le,{name:"arrow_down",size:"sm-md",color:"currentColor"}))))})),Fw=({location:e="toolbar"})=>{const n=(e=>"footer"===e?"(下部)":"")(e),{totalCount:r,currentPage:i,pageSize:o,pageSizeOptions:a,setCurrentPage:s,setPageSize:u}=c(Fy),p=d((e=>{s(0),u(e)}),[s,u]),m=l((()=>Math.ceil(r/o)-1),[r,o]),h=Math.min(i*o+1,r),g=Math.min((i+1)*o,r);return t.createElement(Xu,{minSize:"fit-content"},t.createElement(cl,{inline:!0,type:"button","aria-label":`前のページへ${n}`,size:_w,color:Gw,disabled:0===i||0===r,icon:t.createElement(le,{name:"arrow_left",size:"md",color:"currentColor"}),onClick:()=>s(Math.max(i-1,0))}),t.createElement(Da,null,t.createElement(Sa,{width:296,trigger:t.createElement(jw,{rangeStart:h,rangeEnd:g,totalCount:r,locationSuffix:n})},t.createElement(Ra,null,"表示件数を変更"),a.map((e=>t.createElement(Ro,{key:e,checked:o===e,onChange:()=>p(e)},e))))),t.createElement(cl,{inline:!0,type:"button","aria-label":`次のページへ${n}`,size:_w,color:Gw,disabled:i===m||0===r,icon:t.createElement(le,{name:"arrow_right",size:"md",color:"currentColor"}),onClick:()=>s(Math.min(i+1,m))}))},Yw=({tableActions:e,customTableActionArea:n})=>{const{isSmallLayout:r,columns:o,columnEditFeatures:a,rowIds:s,checkedRows:u,setCheckedRows:p,hasRowControls:m}=c(Fy),h=ne(),g=l((()=>s.length>0&&u.length===s.length),[u,s]),f=l((()=>0!==u.length&&u.length!==s.length),[u,s]),[b,v]=i(!1),[x,y]=i(!1),[w,C]=i(!1),E=l((()=>o.some((e=>void 0!==e.filtered))),[o]),I=d((()=>{p(g?[]:s)}),[g,s,p]),k=d(((e,n)=>((e,n,r,i)=>{if(n&&t.isValidElement(e)){let o=r?n.enabled:n.disabled||"currentColor";return"success"===o?o=i.palette.success.base:"danger"===o?o=i.palette.danger.base:"primary"===o?o=i.palette.primary.base:"warning"===o&&(o=i.palette.warning.base),t.cloneElement(e,Object.assign(Object.assign({},e.props),{color:o}))}return e})(e,n,u.length>0,h)),[u.length,h]),M=d(((e,n,r)=>{var i;return"singleButton"===e.type?t.createElement(cl,{key:qy(e,n),icon:k(e.icon,e.dynamicIconColor),color:null!==(i=e.color)&&void 0!==i?i:"secondaryLight",size:"small",inline:r,style:e.style,disabled:Qy(e,u),onClick:()=>e.onClick(u)},e.label):"groupButton"===e.type?t.createElement(Qu,{key:qy(e,n),size:"small"},e.items.map(((e,r)=>{var i;return t.createElement(cl,{key:Ky(e,n,r),icon:k(e.icon,e.dynamicIconColor),color:null!==(i=e.color)&&void 0!==i?i:"secondaryLight",style:e.style,disabled:Qy(e,u),onClick:()=>e.onClick(u)},e.label)}))):"separator"===e.type?t.createElement(Dw,{key:qy(e,n)}):"heading"===e.type?t.createElement("span",{key:qy(e,n),style:{padding:"8px",fontSize:"14px",fontWeight:"bold"}},e.label):t.createElement(Dw,{key:qy(e,n)})}),[u,k]),$=d(((e,n=!1)=>{const r=[],i=new Set;return e.forEach(((o,a)=>{if("singleButton"!==o.type&&"groupButton"!==o.type||!o.headingLabel||i.has(o.headingLabel))"singleButton"!==o.type&&"groupButton"!==o.type||o.headingLabel?"separator"===o.type?r.push(t.createElement(Ta,{key:`separator-${a}`})):"heading"===o.type?r.push(t.createElement(Ra,{key:`heading-${o.label||a}`},o.label)):"divider"===o.type&&r.push(t.createElement(Ta,{key:`divider-${a}`})):"singleButton"===o.type?r.push(t.createElement(Dt,{key:`single-${o.label||a}`,prepend:k(o.icon,o.dynamicIconColor),disabled:Qy(o,u,n),onClick:()=>{o.onClick(u),n?C(!1):y(!1)}},o.label)):"groupButton"===o.type&&o.items.forEach(((e,i)=>{r.push(t.createElement(Dt,{key:ew(e,"mobile-group",a,i),prepend:k(e.icon,e.dynamicIconColor),disabled:Qy(e,u,n),onClick:()=>{e.onClick(u),n?C(!1):y(!1)}},e.label))}));else{i.add(o.headingLabel);const a=e.filter((e=>("singleButton"===e.type||"groupButton"===e.type)&&e.headingLabel===o.headingLabel));r.push(t.createElement(Ra,{key:`group-${o.headingLabel}-heading`},o.headingLabel)),a.forEach(((e,i)=>{"singleButton"===e.type?r.push(t.createElement(Dt,{key:`group-${e.headingLabel}-${e.label||i}`,prepend:k(e.icon,e.dynamicIconColor),disabled:Qy(e,u,n),onClick:()=>{e.onClick(u),n?C(!1):y(!1)}},e.label)):"groupButton"===e.type&&e.items.forEach(((e,a)=>{r.push(t.createElement(Dt,{key:ew(e,`group-${o.headingLabel}-group`,i,a),prepend:k(e.icon,e.dynamicIconColor),disabled:Qy(e,u,n),onClick:()=>{e.onClick(u),n?C(!1):y(!1)}},e.label))}))}))}})),r}),[u,y,C,k]);let A=null;if(n)A=n({isSmallLayout:r,checkedRows:u});else if(e&&e.length>0){const{checkedActions:n,uncheckedActions:i}={checkedActions:(L=e).filter((e=>{const t="enabledWhen"in e?e.enabledWhen:void 0;return"checked"===t||void 0===t})),uncheckedActions:L.filter((e=>"unchecked"===("enabledWhen"in e?e.enabledWhen:void 0)))};if(r)A=t.createElement(Rw,null,n.length>0&&t.createElement(Da,null,t.createElement(Sa,{open:x,trigger:t.createElement(zw,{type:"button",disabled:0===u.length},t.createElement("span",{style:{color:0===u.length?"inherit":h.palette.primary.base,fontWeight:700}},0===u.length?"-":u.length),"件を操作",t.createElement(le,{name:"arrow_down",size:"sm-md",color:"currentColor"})),width:200,onOpenChange:y},$(n))),i.length>0&&t.createElement(Da,null,t.createElement(Sa,{open:w,trigger:t.createElement(cl,{type:"button",color:"secondaryLight",size:"small",icon:t.createElement(le,{name:"more_vert",color:"currentColor"}),disabled:u.length>0}),width:200,onOpenChange:C},$(i,!0))));else{const{dropdownActions:e}=Uy(n),{dropdownActions:r}=Uy(i),o=()=>{const r=[];return n.forEach(((n,i)=>{var o;const a=null!==(o=n.displayIn)&&void 0!==o?o:"toolbar";if("toolbar"===a)r.push(M(n,i,!0));else if("dropdown"===a){r.some((e=>t.isValidElement(e)&&"checked-dropdown"===e.key))||r.push(t.createElement(Da,{key:"checked-dropdown"},t.createElement(Sa,{open:x,trigger:t.createElement(cl,{type:"button",color:"secondaryLight",size:"small",icon:t.createElement(le,{name:"more_vert",color:"currentColor"}),disabled:0===u.length}),width:200,onOpenChange:y},e.map(((e,n)=>"singleButton"===e.type?t.createElement(Dt,{key:`checked-single-${e.label||n}`,prepend:k(e.icon,e.dynamicIconColor),disabled:Qy(e,u),onClick:()=>{e.onClick(u),y(!1)}},e.label):"groupButton"===e.type?e.items.map(((e,r)=>t.createElement(Dt,{key:ew(e,"checked-group",n,r),prepend:k(e.icon,e.dynamicIconColor),disabled:Qy(e,u),onClick:()=>{e.onClick(u),y(!1)}},e.label))):"separator"===e.type?t.createElement(Ta,{key:`checked-separator-sep-${n}`}):"heading"===e.type?t.createElement(Ra,{key:`checked-heading-${e.label||`heading${n}`}`},e.label):t.createElement(Ta,{key:`checked-divider-div-${n}`}))))))}})),r},a=()=>{const e=[];return i.forEach(((n,i)=>{var o;const a=null!==(o=n.displayIn)&&void 0!==o?o:"toolbar";if("toolbar"===a)e.push(M(n,i,!0));else if("dropdown"===a){e.some((e=>t.isValidElement(e)&&"unchecked-dropdown"===e.key))||e.push(t.createElement(Da,{key:"unchecked-dropdown"},t.createElement(Sa,{open:w,trigger:t.createElement(cl,{type:"button",color:"secondaryLight",size:"small",icon:t.createElement(le,{name:"more_vert",color:"currentColor"}),disabled:u.length>0}),width:200,onOpenChange:C},r.map(((e,n)=>"singleButton"===e.type?t.createElement(Dt,{key:`unchecked-single-${e.label||n}`,prepend:k(e.icon,e.dynamicIconColor),disabled:Qy(e,u,!0),onClick:()=>{e.onClick(u),C(!1)}},e.label):"groupButton"===e.type?e.items.map(((e,r)=>t.createElement(Dt,{key:ew(e,"unchecked-group",n,r),prepend:k(e.icon,e.dynamicIconColor),disabled:Qy(e,u,!0),onClick:()=>{e.onClick(u),C(!1)}},e.label))):"separator"===e.type?t.createElement(Ta,{key:`unchecked-separator-sep-${n}`}):"heading"===e.type?t.createElement(Ra,{key:`unchecked-heading-${e.label||`heading${n}`}`},e.label):t.createElement(Ta,{key:`unchecked-divider-div-${n}`}))))))}})),e};A=t.createElement(Rw,null,o(),n.length>0&&i.length>0&&t.createElement(Dw,null),a())}}var L;return t.createElement(iw,{isSmallLayout:r},t.createElement(Hw,null,m&&t.createElement(t.Fragment,null,t.createElement(Kd,{checked:g||f,indeterminate:f,disabled:0===s.length,"aria-label":"すべての行を選択",onChange:I}),!r&&t.createElement(Ow,null,t.createElement("span",{style:{color:h.palette.primary.base,fontWeight:700}},0===u.length?"-":u.length),"件を")),A),t.createElement(dw,null,E&&t.createElement(Nw,null),t.createElement(Fw,null),t.createElement(Da,null,t.createElement(Sa,{open:b,width:316,trigger:t.createElement(cl,{type:"button",color:"secondaryLight",size:"small",icon:t.createElement(le,{name:"setting",color:"currentColor"})}),onOpenChange:v},function(e,t){return!(!t.reorder&&!t.visibility)&&e.some((e=>_y(e,t)||Gy(e,t)))}(o,a)&&t.createElement(Tw,null),t.createElement(Zw,null),t.createElement(Pw,null)))))},Ww=()=>{const{isSmallLayout:e}=c(Fy);return t.createElement(uw,{isSmallLayout:e},t.createElement(Fw,{location:"footer"}))},Xw=({children:e})=>{const[n,r]=i(!0),l=o(null),s=d((()=>{const e=l.current;if(!e)return;const{scrollLeft:t,scrollWidth:n,clientWidth:i}=e,o=Math.max(0,n-i),a=o>.5&&!(t>=o-1);r((e=>e===a?e:a))}),[]);return a((()=>{const e=l.current;if(!e)return;s(),e.addEventListener("scroll",s,{passive:!0});const t=new ResizeObserver(s);t.observe(e);const n=e.firstElementChild;return n instanceof HTMLElement&&t.observe(n),()=>{e.removeEventListener("scroll",s),t.disconnect()}}),[s]),t.createElement(Yy.Provider,{value:{showStickyRightEdgeDecoration:n}},t.createElement(rw,{ref:l},t.createElement("table",null,e)))},Jw=({bordered:e,currentPage:n,pageSize:r,pageSizeOptions:s,totalCount:c,columns:u,onPageChange:p,onPageSizeChange:m,onColumnsChange:h,onCheckedRowsChange:g,children:f,tableActions:b,customTableActionArea:v,enableRowSelection:x=!0,columnEditFeatures:y,showBottomPagination:w=!1})=>{const C=l((()=>{return{reorder:null!==(t=null==(e=y)?void 0:e.reorder)&&void 0!==t?t:By,visibility:null!==(n=null==e?void 0:e.visibility)&&void 0!==n?n:Py};var e,t,n}),[y]),[E,I]=i(!1),[k,M]=i([]),[$,A]=i([]),[L,V]=i([]),[H,O]=i(0),S=o(null),D=d(((e,t)=>{const n=[...L];n[e]=t,V(n)}),[L,V]);a((()=>{if(!S.current)return;const e=()=>{var e;S.current&&I((null===(e=S.current)||void 0===e?void 0:e.clientWidth)<F.TABLET)},t=new ResizeObserver(e);return e(),t.observe(S.current),()=>{t.disconnect()}}),[]);const R=d((e=>{A(e),null==g||g(e)}),[A,g]),z=o(n);a((()=>{z.current!==n&&R([]),z.current=n}),[n,R]),a((()=>{if(0===$.length)return;const e=$.filter((e=>k.includes(e)));e.length!==$.length&&R(e)}),[k,$,R]);const N=l((()=>Math.ceil(c/r)-1),[c,r]);a((()=>{n>N&&p(N)}),[n,N,p]);const T=x&&!!b,[Z,B]=i(null),P=d(((e,t)=>{B((n=>void 0===t?n===e?null:n:null!==n&&n!==e?("production"!==process.env.NODE_ENV&&console.warn(`[DataTable2] sticky="right" は 1 列のみです。既に列 index ${String(n)} で使用されているため、列 ${String(e)} の登録は無視しました。`),n):e))}),[]),_=l((()=>{const e=u.filter((e=>e.visible)).length;return{registerColumnSticky:P,getStickyRightOffset:t=>{var n;if(null===Z||t!==Z)return;let r=0;for(let i=t+1;i<e;i++)r+=null!==(n=L[i])&&void 0!==n?n:0;return r},rightStickyColumnIndex:Z,getRightStickyZIndexHead:e=>3,getRightStickyZIndexBody:e=>1}}),[L,u,P,Z]);return t.createElement(nw,{ref:S,bordered:e},t.createElement(Fy.Provider,{value:{isSmallLayout:E,rowIds:k,enableRowSelection:x,hasRowControls:T,checkedRows:$,totalCount:c,currentPage:n,pageSize:r,pageSizeOptions:s,columns:u,columnEditFeatures:C,columnWidths:L,rowSpacing:H,setRowIds:M,setCheckedRows:R,setCurrentPage:p,setPageSize:m,setColumns:h,setColumnWidth:D,setRowSpacing:O}},t.createElement(Wy.Provider,{value:_},t.createElement(Yw,{tableActions:b,customTableActionArea:v}),t.createElement(Xw,null,f),w&&t.createElement(Ww,null))))},Uw=({children:e})=>{const{hasRowControls:n,columns:r}=c(Fy),i=l((()=>p.toArray(e).map(((e,t)=>{const n=r[t];return{id:n.id,index:t,order:n.order,visible:n.visible,child:e}})).filter((e=>void 0!==e.id))),[e,r]),o=l((()=>i.sort(((e,t)=>e.order-t.order)).filter((e=>e.visible))),[i]);return t.createElement(t.Fragment,null,t.createElement("colgroup",null,n&&t.createElement("col",{style:{width:34}}),o.map((({id:e,child:n})=>m(n)?t.createElement("col",{key:e,style:{width:n.props.width}}):null))),t.createElement(mw,null,t.createElement("tr",null,n&&t.createElement(Iw,{"aria-label":"empty cell"}),o.map((({id:e,index:n,child:r})=>t.createElement(Xy.Provider,{key:e,value:{index:n}},r))))))},Qw=({className:e,sticky:n,isResizable:r,width:l,minWidth:s=32,maxWidth:u=1/0,children:p,onWidthChange:m})=>{const{isSmallLayout:h,setColumnWidth:g}=c(Fy),{registerColumnSticky:f,getStickyRightOffset:b,rightStickyColumnIndex:v,getRightStickyZIndexHead:x}=c(Wy),{showStickyRightEdgeDecoration:y}=c(Yy),w=c(Xy),[C,E]=i(!1);a((()=>(f(w.index,"right"===n?"right":void 0),()=>{f(w.index,void 0)})),[n,w.index,f]);const I=b(w.index),M=void 0!==I&&w.index===v&&y,$=void 0!==I?x(w.index):void 0,A=o(null),L=o(null),V=o(0),H=o(0),O=d((e=>{E(!0),L.current&&null===A.current&&(A.current=e.pointerId,H.current=l||L.current.clientWidth,V.current=e.clientX)}),[l]),S=d((e=>{if(!m)return;if(A.current!==e.pointerId)return;e.cancelable&&e.preventDefault();const t=e.clientX-V.current,n=((e,t,n)=>Math.min(Math.max(e,t),n))(H.current+t,s,u);m(n),g(w.index,n)}),[m,s,u,g,w.index]),D=d((()=>{E(!1),A.current=null}),[]);return a((()=>{if(C)return document.addEventListener("pointermove",S),document.addEventListener("pointerup",D),()=>{document.removeEventListener("pointermove",S),document.removeEventListener("pointerup",D)}}),[C,S,D]),t.createElement(hw,{ref:L,className:e,"data-dragging":C,$stickyRightOffset:I,$stickyZIndex:$,$showStickyEdgeDecoration:M,style:{minWidth:isFinite(s)&&s<=u?s:void 0,maxWidth:isFinite(s)&&s<=u?u:void 0}},t.createElement(fw,{isSmallLayout:h},p,r&&t.createElement(bw,{type:"button","aria-label":"resize the column",onPointerDown:O}),C&&k(t.createElement(vw,{"data-min":l&&s>=l,"data-max":l&&u<=l}),document.body)))},qw=({showSortButton:e,sortButtonDirection:n,onSortChange:r,children:i})=>{const o=l((()=>"asc"===n?"desc":"desc"!==n?"asc":void 0),[n]),a=d((()=>{null==r||r(o)}),[r,o]),s=l((()=>"asc"===n?"sort_up":"desc"===n?"sort_down":"sort_inactive"),[n]);return e?t.createElement(ww,{type:"button",onClick:a},i,t.createElement(le,{name:s,size:"md"})):t.createElement(yw,null,i)},Kw=({children:e})=>{const{rowIds:n,setRowIds:r}=c(Fy);return a((()=>{const t=[];p.forEach(e,(e=>{if(!m(e))return;const n=e.props;"string"==typeof n.id&&t.push(n.id)})),t.length===n.length&&t.every((e=>n.includes(e)))||r(t)}),[e,n,r]),t.createElement("tbody",null,e)},eC=({id:e,children:n})=>{const{isSmallLayout:r,columns:i,hasRowControls:o,checkedRows:a,setCheckedRows:s,rowSpacing:u}=c(Fy),m=l((()=>a.includes(e)),[e,a]),h=d((()=>{const t=a.includes(e)?a.filter((t=>t!==e)):[...a,e];s(t)}),[e,a,s]),g=l((()=>p.toArray(n).map(((e,t)=>{const n=i[t];return{id:n.id,index:t,order:n.order,visible:n.visible,child:e}})).filter((e=>void 0!==e.id))),[n,i]),f=l((()=>g.sort(((e,t)=>e.order-t.order)).filter((e=>e.visible))),[g]);return t.createElement(Cw,{"data-highlighted":m,"data-spacing":u,isSmallLayout:r},o&&t.createElement(Ew,null,t.createElement(kw,null,t.createElement(Kd,{checked:m,"aria-label":"この行を選択",onChange:h}),t.createElement("input",{type:"checkbox","aria-label":"この行を選択"}))),f.map((({id:e,index:n,child:r})=>t.createElement(Xy.Provider,{key:e,value:{index:n}},r))))},tC=({loading:e,sticky:n,children:r})=>{const{getStickyRightOffset:i,rightStickyColumnIndex:o,getRightStickyZIndexBody:a}=c(Wy),{showStickyRightEdgeDecoration:l}=c(Yy),s=c(Xy),d=i(s.index),u=void 0!==d&&s.index===o&&l,p=void 0!==d?a(s.index):void 0;return t.createElement(gw,{$stickyRightOffset:d,$stickyZIndex:p,$showStickyEdgeDecoration:u},t.createElement(Mw,null,t.createElement(Aw,null,r),e&&t.createElement($w,null,t.createElement(rl,{width:"20px"}))))},nC=({prepend:e,children:n,onClick:r})=>{const{isSmallLayout:i}=c(Fy);return i?t.createElement(Dt,{prepend:e,onClick:r},n):t.createElement(pw,{type:"button",onClick:r},e,n)},rC=({label:e,value:n,children:r,onChange:o})=>{const[l,s]=i(n),[c,d]=i(!1),u=()=>{d(!1),o(l)};return a((()=>{s(n)}),[n]),t.createElement(Lw,null,r,t.createElement(Vw,null,t.createElement(Da,null,t.createElement(Sa,{width:252,trigger:t.createElement(cl,{type:"button",color:"primarySubtle",size:"small",inline:!0,icon:t.createElement(le,{name:"pencil",color:"currentColor"})}),open:c,onOpenChange:d},t.createElement(Ra,null,e),t.createElement(ya,{value:l,onChange:e=>s(e.target.value),onEnter:u}),t.createElement(Ta,null),t.createElement(Za,null,t.createElement(cl,{type:"button",color:"clear",size:"small",onClick:()=>{d(!1),s(n)}},"キャンセル"),t.createElement(cl,{type:"button",color:"primary",size:"small",onClick:u},"適用"))))))},iC=({label:e,value:n,options:r,children:o,onChange:a})=>{const[l,s]=i(!1);return t.createElement(Lw,null,o,t.createElement(Vw,null,t.createElement(Da,null,t.createElement(Sa,{width:252,trigger:t.createElement(cl,{type:"button",color:"primarySubtle",size:"small",inline:!0,icon:t.createElement(le,{name:"pencil",color:"currentColor"})}),open:l,onOpenChange:s},t.createElement(Ra,null,e),r.map((e=>t.createElement(Ro,{key:e,closeOnChange:!0,checked:n===e,onChange:()=>a(e)},e)))))))},oC=e=>{if(!e)return[];const t=[];let n=0,r=!isNaN(Number(e[0]));for(let i=1;i<=e.length;i++){const o=e[i],a=!isNaN(Number(o))&&" "!==o;a===r&&" "!==o&&i!==e.length||(t.push({start:n,end:i-1,value:e.slice(n,i),editable:r}),n=i,r=a)}return t},aC=e=>e.map((e=>e.value)).join(""),lC=(e,t,n)=>{if(4===e)return"year";if(2===e){const e=(t.match(/[YMD]+/g)||[]).map(((e,t)=>({token:e,length:e.length,index:t}))),r=e[n];if(r){if(r.token.includes("Y"))return"year";if(r.token.includes("M"))return"month";if(r.token.includes("D"))return"day"}}return"unknown"},sC=(e,t,n,r)=>{if(0===t){const t=parseInt(e);return"month"===n?t>=2:"day"===n&&t>=4}return t+1===r},cC={Backspace:"Backspace",Delete:"Delete",ArrowLeft:"ArrowLeft",ArrowRight:"ArrowRight",ArrowUp:"ArrowUp",ArrowDown:"ArrowDown",Tab:"Tab",0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9"},dC=["Numpad0","Numpad1","Numpad2","Numpad3","Numpad4","Numpad5","Numpad6","Numpad7","Numpad8","Numpad9"],uC=Object.keys(cC).filter((e=>!isNaN(Number(e)))),pC=Object.values(cC),mC=e=>dC.includes(e),hC=e=>{const t=e.match(/Numpad(\d)/);return t?t[1]:null},gC=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|YYYY|YY?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,fC=/\d\d/,bC=/-?\d\d?/,vC=/\d*[^-_:/,()\s\d]+/;let xC={},yC=function(e){return(e=+e)+(e>68?1900:2e3)};const wC=function(e){return function(t){this[e]=+t}},CC=[/[+-]\d\d:?(\d\d)?|Z/,function(e){(this.zone||(this.zone={})).offset=function(e){if(!e)return 0;if("Z"===e)return 0;const t=e.match(/([+-]|\d\d)/g),n=60*t[1]+(+t[2]||0);return 0===n?0:"+"===t[0]?-n:n}(e)}],EC=e=>{const t=xC[e];return t&&(t.indexOf?t:t.s.concat(t.f))},IC=(e,t)=>{let n;const{meridiem:r}=xC;if(r){for(let i=1;i<=24;i+=1)if(e.indexOf(r(i,0,t))>-1){n=i>12;break}}else n=e===(t?"pm":"PM");return n},kC={A:[vC,function(e){this.afternoon=IC(e,!1)}],a:[vC,function(e){this.afternoon=IC(e,!0)}],S:[/\d/,function(e){this.milliseconds=100*+e}],SS:[fC,function(e){this.milliseconds=10*+e}],SSS:[/\d{3}/,function(e){this.milliseconds=+e}],s:[bC,wC("seconds")],ss:[bC,wC("seconds")],m:[bC,wC("minutes")],mm:[bC,wC("minutes")],H:[bC,wC("hours")],h:[bC,wC("hours")],HH:[bC,wC("hours")],hh:[bC,wC("hours")],D:[bC,wC("day")],DD:[fC,wC("day")],Do:[vC,function(e){const{ordinal:t}=xC;if([this.day]=e.match(/\d+/),t)for(let n=1;n<=31;n+=1)t(n).replace(/\[|\]/g,"")===e&&(this.day=n)}],M:[bC,wC("month")],MM:[fC,wC("month")],MMM:[vC,function(e){const t=EC("months"),n=(EC("monthsShort")||t.map((e=>e.slice(0,3)))).indexOf(e)+1;if(n<1)throw new Error;this.month=n%12||n}],MMMM:[vC,function(e){const t=EC("months").indexOf(e)+1;if(t<1)throw new Error;this.month=t%12||t}],Y:[/[+-]?\d+/,wC("year")],YY:[fC,function(e){this.year=yC(e)}],YYYY:[/\d{4}/,wC("year")],Z:CC,ZZ:CC};const MC=(e,t,n)=>{try{if(["x","X"].indexOf(t)>-1)return new Date(("X"===t?1e3:1)*e);const r=function(e){const t=e.match(gC),{length:n}=t;for(let e=0;e<n;e+=1){const n=t[e],r=kC[n],i=r&&r[0],o=r&&r[1];t[e]=o?{regex:i,parser:o}:n.replace(/^\[|\]$/g,"")}return function(e){const r={};for(let i=0,o=0;i<n;i+=1){const n=t[i];if("string"==typeof n)o+=n.length;else{const{regex:t,parser:i}=n,a=e.slice(o),l=t.exec(a)[0];i.call(r,l),e=e.replace(l,"")}}return function(e){const{afternoon:t}=e;if(void 0!==t){const{hours:n}=e;t?n<12&&(e.hours+=12):12===n&&(e.hours=0),delete e.afternoon}}(r),r}}(t),{year:i,month:o,day:a,hours:l,minutes:s,seconds:c,milliseconds:d,zone:u}=r(e),p=new Date,m=i||p.getFullYear(),h=o-1,g=l||0,f=s||0,b=c||0,v=d||0;return u?new Date(Date.UTC(m,h,a,g,f,b,v+60*u.offset*1e3)):n?new Date(Date.UTC(m,h,a,g,f,b,v)):new Date(m,h,a,g,f,b,v)}catch(e){return new Date("")}};var $C=(e,t,n)=>{n.p.customParseFormat=!0,e&&e.parseTwoDigitYear&&({parseTwoDigitYear:yC}=e);const r=t.prototype,i=r.parse;r.parse=function(e){const{date:t,utc:r,args:o}=e;this.$u=r;const a=o[1];if("string"==typeof a){const e=!0===o[2],i=!0===o[3],l=e||i;let s=o[2];i&&([,,s]=o),xC=this.$locale(),!e&&s&&(xC=n.Ls[s]),this.$d=MC(t,a,r),this.init(),s&&!0!==s&&(this.$L=this.locale(s).$L),l&&t!=this.format(a)&&(this.$d=new Date("")),xC={}}else if(a instanceof Array){const e=a.length;for(let t=1;t<=e;t+=1){o[1]=a[t-1];const r=n.apply(this,o);if(r.isValid()){this.$d=r.$d,this.$L=r.$L,this.init();break}t===e&&(this.$d=new Date(""))}}else i.call(this,e)}};const AC=({date:e,format:t="YYYY-MM-DD",onDateChange:n})=>{_a.extend($C);const r=o(null),[l,s]=i(null==e?void 0:e.format(t)),[c,u]=i(oC(l)),[p,m]=i({start:0,end:c.length-1,current:0}),[h,g]=i(0),f=d((()=>{setTimeout((()=>{var e,t,n;if(0===c.length)return;const i=null!==(t=null===(e=r.current)||void 0===e?void 0:e.selectionStart)&&void 0!==t?t:0,o=c[c.length-1].end+1,a=i>=o?o:i,l=c.findIndex((e=>a>=e.start&&a<=e.end+1));-1!==l&&(m((e=>c[l].editable?e.current===l?e:Object.assign(Object.assign({},e),{current:l}):Object.assign(Object.assign({},e),{current:l+1}))),null===(n=r.current)||void 0===n||n.setSelectionRange(c[l].start,c[l].end+1))}))}),[c]),b=d((()=>{}),[]),v=d((()=>{m((e=>Object.assign(Object.assign({},e),{current:0}))),g(0)}),[]),x=d((e=>{if(0===c.length)return;const r=mC(e.code),i=r?hC(e.code):null;if(!pC.includes(e.key)&&!r)return;if(e.key===cC.ArrowLeft||e.key===cC.ArrowRight){e.preventDefault();const t=e=>{const t=p.current;if(e===cC.ArrowLeft){for(let e=t-1;e>=0;e--)if(c[e].editable)return e-t}else if(e===cC.ArrowRight)for(let e=t+1;e<c.length;e++)if(c[e].editable)return e-t;return 0},n=e.key;m((e=>Object.assign(Object.assign({},e),{current:e.current+t(n)})))}if(e.key===cC.ArrowUp||e.key===cC.ArrowDown){e.preventDefault();const r=e.key===cC.ArrowUp?1:-1,i=Number(c[p.current].value)+r,o=String(i).padStart(c[p.current].value.length,"0"),a=[...c];a[p.current].value=o,u(a);const l=aC(a),d=_a(l,t);s(d.format(t)),d.isValid()&&n&&n(d)}const o=r?i:e.key;if((uC.includes(e.key)||r)&&o){e.preventDefault(),0===h&&(c[p.current].value="".padStart(c[p.current].value.length,"0"));const r=`${c[p.current].value.slice(1)}${o}`,i=[...c];i[p.current].value=r,u(i),g(h+1);const a=lC(c[p.current].value.length,t,p.current);if(sC(o,h,a,c[p.current].value.length)){g(0);for(let e=p.current+1;e<c.length;e++)if(c[e].editable){m((t=>Object.assign(Object.assign({},t),{current:e})));break}const e=aC(c),r=_a(e,t);s(r.format(t)),n&&n(r)}else{const e=aC(c);if(!_a(e,t,!0).isValid())return void s(e);const r=_a(e,t);s(r.format(t)),n&&n(r)}}}),[c,t,n,p]),y=d((()=>{f()}),[f]),w=d((e=>{e.preventDefault();const r=e.clipboardData.getData("text").trim(),i=/[Hh]|mm|ss/.test(t),o=[];o.push(t),o.push("YYYY年M月D日","YYYY年MM月DD日"),i&&o.push("YYYY年M月D日 HH:mm","YYYY年MM月DD日 HH:mm","YYYY年M月D日 HH:mm:ss","YYYY年MM月DD日 HH:mm:ss"),o.push("YYYY-MM-DD","YYYY-M-DD","YYYY-MM-D","YYYY-M-D"),i&&o.push("YYYY-MM-DD HH:mm","YYYY-M-DD HH:mm","YYYY-MM-D HH:mm","YYYY-M-D HH:mm","YYYY-MM-DD HH:mm:ss","YYYY-M-DD HH:mm:ss","YYYY-MM-D HH:mm:ss","YYYY-M-D HH:mm:ss"),o.push("YYYY/MM/DD","YYYY/M/DD","YYYY/MM/D","YYYY/M/D"),i&&o.push("YYYY/MM/DD HH:mm","YYYY/M/DD HH:mm","YYYY/MM/D HH:mm","YYYY/M/D HH:mm","YYYY/MM/DD HH:mm:ss","YYYY/M/DD HH:mm:ss","YYYY/MM/D HH:mm:ss","YYYY/M/D HH:mm:ss");const a=r.match(/(\d{4})[-/年](\d{1,2})[-/月](\d{1,2})/);if(a){const e=parseInt(a[1],10),t=parseInt(a[2],10),n=parseInt(a[3],10);if(!(e>=1900&&e<=2100&&t>=1&&t<=12&&n>=1&&n<=31))return;if(n>_a(`${e}-${t}-01`).daysInMonth())return}let l=null;const s=_a(r);if(s.isValid())l=s;else for(const e of o){const t=_a(r,e,!0);if(t.isValid()){l=t;break}}if(!l||!l.isValid())return;const c=l.year(),d=l.month()+1,u=l.date();if(c>=1900&&c<=2100&&d>=1&&d<=12&&u>=1&&u<=31){if(i){const e=r.match(/(\d{1,2}):(\d{1,2})(?::(\d{1,2}))?/);if(e){const t=parseInt(e[1],10),n=parseInt(e[2],10),r=e[3]?parseInt(e[3],10):0;if(!(!isNaN(t)&&!isNaN(n)&&!isNaN(r)&&t>=0&&t<=23&&n>=0&&n<=59&&r>=0&&r<=59))return}}n&&n(l)}}),[t,n]);return a((()=>{var e;if(0===c.length)return;const t=c[p.current];t&&(null===(e=r.current)||void 0===e||e.setSelectionRange(t.start,t.end+1))}),[p,c]),a((()=>{s(null==e?void 0:e.format(t)),u(oC(null==e?void 0:e.format(t)))}),[e,t]),{ref:r,value:l,onFocus:b,onBlur:v,onKeyDown:x,onMouseDown:y,onPaste:w}},LC=e=>[...e.split("")].reduce(((e,t)=>{const n=t.charCodeAt(0);return e+(n>=12288&&n<=65376?2:1)}),0),VC=n((function(e,n){var{error:r=!1,errorText:i,format:o="YYYY-MM-DD",disabled:a=!1,size:s="medium",variant:c="light",width:d,append:u,onAppendClick:p}=e,m=D(e,["error","errorText","format","disabled","size","variant","width","append","onAppendClick"]);Ae("DateField","DateField は非推奨です。代わりに DateField2 を使用してください。");const h=AC(Object.assign({format:o},m)),{ref:g}=h,f=D(h,["ref"]),b=Vc(n,g),v=l((()=>9*LC(o)*(parseInt(ca[s].fontSize)/13)+"px"),[o,s]),x=null!=d?d:v;return t.createElement(t.Fragment,null,t.createElement(va,Object.assign({ref:b,readOnly:!0,error:r||!!i,disabled:a,size:s,variant:c,width:x,append:u,onAppendClick:p},f)),i&&t.createElement(Ua,{pt:1},t.createElement(nd,null,i)))}));var HC=g(VC);const OC=v.div`
|
|
2916
2916
|
display: flex;
|
|
2917
2917
|
align-items: center;
|
|
2918
2918
|
width: fit-content;
|
|
@@ -2959,9 +2959,9 @@ object-assign
|
|
|
2959
2959
|
box-shadow: none !important;
|
|
2960
2960
|
}
|
|
2961
2961
|
}
|
|
2962
|
-
`,
|
|
2962
|
+
`,SC=v.span`
|
|
2963
2963
|
${W}
|
|
2964
|
-
`,
|
|
2964
|
+
`,DC=n((function(e,n){var{format:r="YYYY-MM-DD",error:i=!1,errorText:o,disabled:a=!1,size:s="medium",variant:c="light",startWidth:d,endWidth:u,append:p,onAppendClick:m}=e,h=D(e,["format","error","errorText","disabled","size","variant","startWidth","endWidth","append","onAppendClick"]);Ae("DateRangeField","DateRangeField は非推奨です。代わりに DateRangeField2 を使用してください。");const g=l((()=>9*LC(r)*(parseInt(ca[s].fontSize)/13)+"px"),[r,s]),f=l((()=>`${9*LC(r)*(parseInt(ca[s].fontSize)/13)+(p?32:0)}px`),[r,s,p]),b=null!=d?d:g,v=null!=u?u:f,x=e=>t=>{var n,r;const{startDate:i,endDate:o}=h.date;e===jp?null===(n=h.onDatesChange)||void 0===n||n.call(h,{endDate:o,startDate:t}):null===(r=h.onDatesChange)||void 0===r||r.call(h,{startDate:i,endDate:t})},y=AC(Object.assign(Object.assign({},h),{format:r,date:h.date.startDate,onDateChange:x(jp)})),{ref:w}=y,C=D(y,["ref"]),E=AC(Object.assign(Object.assign({},h),{format:r,date:h.date.endDate,onDateChange:x(Fp)})),{ref:I}=E,k=D(E,["ref"]),M=Vc(n,w),$=Vc(n,I);return t.createElement(t.Fragment,null,t.createElement(OC,{error:i||!!o,disabled:a,$size:s,$variant:c},t.createElement(va,Object.assign({ref:M,readOnly:!0,disabled:a,width:b,size:s,variant:c,error:i||!!o,style:{border:"none",background:"transparent",textAlign:"center",boxShadow:"none"}},C)),t.createElement(SC,null,"-"),t.createElement(va,Object.assign({ref:$,readOnly:!0,disabled:a,width:v,size:s,variant:c,error:i||!!o,style:{border:"none",background:"transparent",textAlign:"center",boxShadow:"none"},append:p,onAppendClick:m},k))),o&&t.createElement(Ua,{pt:1},t.createElement(nd,null,o)))}));var RC=g(DC);const zC=({date:e,format:t="YYYY-MM-DD",disabled:n=!1,onDateChange:r})=>{var l;_a.extend($C);const[s,c]=i(null!==(l=null==e?void 0:e.format(t))&&void 0!==l?l:""),[u,p]=i(oC(s)),[m,h]=i(null),g=o(null),f=o(0),[b,v]=i(!1),x=o([]),y=o(null),w=d((e=>{g.current=e,h(e)}),[]),C=d((e=>{w(e),f.current=0;const t=x.current[e];t&&t!==document.activeElement&&t.focus()}),[w]);a((()=>{var n;const r=null!==(n=null==e?void 0:e.format(t))&&void 0!==n?n:"";c(r),p(oC(r))}),[e,t]);const E=d(((e,t)=>{for(let n=e+t;n>=0&&n<u.length;n+=t)if(u[n].editable)return n;return null}),[u]),I=d((e=>{const n=g.current;if(null===n)return;const i=u[n];if(!(null==i?void 0:i.editable))return;const o=f.current;let a=i.value;0===o&&(a="".padStart(i.value.length,"0"));const l=`${a.slice(1)}${e}`,s=[...u];s[n]=Object.assign(Object.assign({},s[n]),{value:l}),p(s);const d=o+1;f.current=d;const m=u.slice(0,n+1).filter((e=>e.editable)).length-1,h=lC(i.value.length,t,m);if(sC(e,o,h,i.value.length)){const e=aC(s);if(!_a(e,t,!0).isValid())return void c(e);f.current=0;const i=E(n,1);null!==i&&C(i);const o=_a(e,t,!0),a=o.format(t);c(a),p(oC(a)),null==r||r(o)}else{const e=aC(s);if(!_a(e,t,!0).isValid())return void c(e);const n=_a(e,t);c(n.format(t)),null==r||r(n)}}),[u,t,r,E,C]),k=d((e=>t=>{x.current[e]=t}),[]),M=d((e=>()=>{v(!0),w(e),f.current=0}),[w]),$=d((e=>t=>{const n=t.relatedTarget;y.current&&n&&y.current.contains(n)||g.current===e&&(v(!1),w(null),f.current=0)}),[w]),A=d((e=>n=>{const i=u[e];if(!(null==i?void 0:i.editable))return;if(n.ctrlKey||n.metaKey||n.altKey)return;if(n.key===cC.ArrowUp||n.key===cC.ArrowDown){n.preventDefault();const i=n.key===cC.ArrowUp?1:-1,o=Number(u[e].value)+i,a=String(o).padStart(u[e].value.length,"0"),l=[...u];l[e]=Object.assign(Object.assign({},l[e]),{value:a}),p(l);const s=aC(l),d=_a(s,t),m=d.format(t);return c(m),p(oC(m)),void(d.isValid()&&(null==r||r(d)))}if(n.key===cC.Backspace||n.key===cC.Delete){n.preventDefault(),n.stopPropagation();const t=n.key===cC.Backspace,r="0".repeat(i.value.length);if(i.value===r&&0===f.current){if(t){const t=E(e,-1);null!==t&&C(t)}return}const o=[...u];return o[e]=Object.assign(Object.assign({},o[e]),{value:r}),p(o),f.current=0,void c(aC(o))}if(mC(n.code)){n.preventDefault();const e=hC(n.code);e&&I(e)}}),[u,t,r,I,E,C]),L=d((e=>e=>{const t=e.nativeEvent;if(e.preventDefault(),"deleteContentBackward"!==t.inputType&&"deleteContentForward"!==t.inputType&&null!=t.data){const e=t.data;/^\d$/.test(e)&&I(e)}}),[I]),V=d((e=>{var r;const i=u[e];if(!(!n&&(null==i?void 0:i.editable)))return{ref:k(e),"aria-hidden":!0};const o=u.slice(0,e+1).filter((e=>e.editable)).length-1,a=(null!==(r=t.match(/[YMDHms]+/g))&&void 0!==r?r:[])[o],l=(()=>{if(a)return a.includes("Y")?"年":a.includes("M")?"月":a.includes("D")?"日":a.includes("H")||a.includes("h")?"時":a.includes("m")?"分":a.includes("s")?"秒":void 0})();return{ref:k(e),role:"spinbutton",contentEditable:!0,suppressContentEditableWarning:!0,inputMode:"numeric",tabIndex:0,enterKeyHint:"next",spellCheck:!1,autoCorrect:"off",style:{caretColor:"transparent"},"aria-label":l,onFocus:M(e),onBlur:$(e),onKeyDown:A(e),onBeforeInput:L(e),onPointerDown(e){e.stopPropagation()},onMouseDown(e){e.stopPropagation()}}}),[u,n,t,k,M,$,A,L]),H=d((e=>{const t=g.current;if(null!==t)if(e.key!==cC.ArrowLeft&&e.key!==cC.ArrowRight){if(e.key===cC.Tab){const n=e.shiftKey?-1:1,r=E(t,n);null!==r&&(e.preventDefault(),C(r))}}else{e.preventDefault();const n=e.key===cC.ArrowLeft?-1:1,r=E(t,n);null!==r&&C(r)}}),[E,C]),O=d((e=>{e.preventDefault();const n=e.clipboardData.getData("text").trim(),i=/[Hh]|mm|ss/.test(t),o=[t];o.push("YYYY年M月D日","YYYY年MM月DD日"),i&&o.push("YYYY年M月D日 HH:mm","YYYY年MM月DD日 HH:mm","YYYY年M月D日 HH:mm:ss","YYYY年MM月DD日 HH:mm:ss"),o.push("YYYY-MM-DD","YYYY-M-DD","YYYY-MM-D","YYYY-M-D","YYYY/MM/DD","YYYY/M/DD","YYYY/MM/D","YYYY/M/D"),i&&o.push("YYYY-MM-DD HH:mm","YYYY-M-DD HH:mm","YYYY-MM-D HH:mm","YYYY-M-D HH:mm","YYYY/MM/DD HH:mm","YYYY/M/DD HH:mm","YYYY/MM/D HH:mm","YYYY/M/D HH:mm");const a=n.match(/(\d{4})[-/年](\d{1,2})[-/月](\d{1,2})/);if(a){const[,e,t,n]=a,r=parseInt(e,10),i=parseInt(t,10),o=parseInt(n,10);if(r<1900||r>2100||i<1||i>12||o<1||o>31)return;if(o>_a(`${r}-${i}-01`).daysInMonth())return}let l=null;const s=_a(n);if(s.isValid())l=s;else for(const e of o){const t=_a(n,e,!0);if(t.isValid()){l=t;break}}if(!(null==l?void 0:l.isValid()))return;const c=l.year(),d=l.month()+1,u=l.date();if(!(c<1900||c>2100||d<1||d>12||u<1||u>31)){if(i){const e=n.match(/(\d{1,2}):(\d{1,2})(?::(\d{1,2}))?/);if(e){const t=parseInt(e[1],10),n=parseInt(e[2],10),r=e[3]?parseInt(e[3],10):0;if(t<0||t>23||n<0||n>59||r<0||r>59)return}}null==r||r(l)}}),[t,r]);return{value:s,sections:u,focusedIndex:m,isFocused:b,getSegmentProps:V,groupProps:{ref:y,onKeyDown:H,onPaste:O}}},NC=v.div`
|
|
2965
2965
|
position: relative;
|
|
2966
2966
|
display: inline-flex;
|
|
2967
2967
|
align-items: center;
|
|
@@ -3000,10 +3000,10 @@ object-assign
|
|
|
3000
3000
|
transition:
|
|
3001
3001
|
border-color 0.2s ease,
|
|
3002
3002
|
box-shadow 0.2s ease;
|
|
3003
|
-
`,
|
|
3003
|
+
`,TC=v.div`
|
|
3004
3004
|
display: inline-flex;
|
|
3005
3005
|
align-items: center;
|
|
3006
|
-
`,
|
|
3006
|
+
`,ZC=v.span`
|
|
3007
3007
|
${W}
|
|
3008
3008
|
display: inline-block;
|
|
3009
3009
|
padding: ${({$editable:e})=>e?"4px 2px":"4px 0"};
|
|
@@ -3019,13 +3019,13 @@ object-assign
|
|
|
3019
3019
|
`;v.span`
|
|
3020
3020
|
${W}
|
|
3021
3021
|
padding: 0 1px;
|
|
3022
|
-
`;const
|
|
3022
|
+
`;const BC=v.span`
|
|
3023
3023
|
display: inline-flex;
|
|
3024
3024
|
align-items: center;
|
|
3025
3025
|
margin-left: auto;
|
|
3026
3026
|
padding-left: 4px;
|
|
3027
3027
|
cursor: pointer;
|
|
3028
|
-
`,
|
|
3028
|
+
`,PC=n((function({date:e,error:n=!1,errorText:r,format:i="YYYY-MM-DD",name:o,disabled:a=!1,size:l="medium",variant:s="light",width:c,append:u,onAppendClick:p,onDateChange:m},h){const g=ba(),{value:f,sections:b,focusedIndex:v,isFocused:x,getSegmentProps:y,groupProps:w}=zC({date:e,format:i,disabled:a,onDateChange:m}),C=d((e=>{e.stopPropagation(),null==p||p()}),[p]);return t.createElement(t.Fragment,null,t.createElement(NC,{ref:h,$disabled:a,$error:n||!!r,$focused:x,$isIOS:g,$size:l,$variant:s,$width:null!=c?c:"fit-content"},t.createElement(TC,Object.assign({},w),b.map(((e,n)=>t.createElement(ZC,Object.assign({key:`${e.start}-${e.end}`,$editable:e.editable,$focused:x&&v===n},y(n)),e.value)))),u&&t.createElement(BC,{onClick:C},u),t.createElement("input",{type:"hidden",name:o,value:f,disabled:a})),r&&t.createElement(Ua,{pt:1},t.createElement(nd,null,r)))}));var _C=g(PC);const GC=v.div`
|
|
3029
3029
|
display: inline-flex;
|
|
3030
3030
|
align-items: center;
|
|
3031
3031
|
width: fit-content;
|
|
@@ -3059,10 +3059,10 @@ object-assign
|
|
|
3059
3059
|
transition:
|
|
3060
3060
|
border-color 0.2s ease,
|
|
3061
3061
|
box-shadow 0.2s ease;
|
|
3062
|
-
`,
|
|
3062
|
+
`,jC=v.span`
|
|
3063
3063
|
${W}
|
|
3064
3064
|
padding: 4px 0;
|
|
3065
|
-
`,
|
|
3065
|
+
`,FC=n((function({date:e,format:n="YYYY-MM-DD",error:r=!1,errorText:i,disabled:o=!1,size:a="medium",variant:l="light",startWidth:s,endWidth:c,startName:u,endName:p,append:m,onAppendClick:h,onDatesChange:g},f){const b=d((t=>n=>{t===jp?null==g||g({startDate:n,endDate:e.endDate}):null==g||g({startDate:e.startDate,endDate:n})}),[e,g]),v=zC({date:e.startDate,format:n,disabled:o,onDateChange:b(jp)}),x=zC({date:e.endDate,format:n,disabled:o,onDateChange:b(Fp)}),y=null!=s?s:"fit-content",w=null!=c?c:"fit-content",C=r||!!i,E=ba(),I=d((e=>{e.stopPropagation(),null==h||h()}),[h]);return t.createElement(t.Fragment,null,t.createElement(GC,{ref:f,$disabled:o,$error:C,$focused:v.isFocused||x.isFocused,$isIOS:E,$size:a,$variant:l},t.createElement(NC,{$disabled:o,$error:!1,$focused:v.isFocused,$isIOS:E,$size:a,$variant:l,$width:y,style:{border:"none",background:"transparent",boxShadow:"none"}},t.createElement(TC,Object.assign({},v.groupProps),v.sections.map(((e,n)=>t.createElement(ZC,Object.assign({key:`s-${e.start}-${e.end}`,$editable:e.editable,$focused:v.isFocused&&v.focusedIndex===n},v.getSegmentProps(n)),e.value))))),t.createElement(jC,null,"-"),t.createElement(NC,{$disabled:o,$error:!1,$focused:x.isFocused,$isIOS:E,$size:a,$variant:l,$width:w,style:{border:"none",background:"transparent",boxShadow:"none"}},t.createElement(TC,Object.assign({},x.groupProps),x.sections.map(((e,n)=>t.createElement(ZC,Object.assign({key:`e-${e.start}-${e.end}`,$editable:e.editable,$focused:x.isFocused&&x.focusedIndex===n},x.getSegmentProps(n)),e.value)))),m&&t.createElement(BC,{onClick:I},m))),t.createElement("input",{type:"hidden",name:u,value:v.value,disabled:o}),t.createElement("input",{type:"hidden",name:p,value:x.value,disabled:o}),i&&t.createElement(Ua,{pt:1},t.createElement(nd,null,i)))}));var YC=g(FC);const WC=n((function(t,n){const r=Cd({props:t,name:"DateRangePicker"}),{startDate:a,endDate:s,error:c=!1,errorText:u,disabled:p=!1,size:m="medium",variant:h="light",monthFormat:g,weekConfig:f,showDateFields:b=!1,showTimeFields:v=!1,timeFieldProps:x,format:y="YYYY-MM-DD",applyButtonText:w,cancelButtonText:C,isOutsideRange:E=(()=>!1),defaultPresetButton:I,presetButtons:k,onPresetButtonClick:M,onDatesChange:$}=r,[A,L]=i(!1),V=o(null),H=d((e=>{e&&!A&&(V.current={startDate:a.clone(),endDate:s.clone()}),L(e)}),[A,a,s]),{context:O,refs:S,strategy:D,x:R,y:z}=ho({placement:"bottom-start",open:A,onOpenChange:H,middleware:[hr(10),mr(),gr({padding:20})]}),N=Vc(n,o(null)),T=po(O),Z=Eo(O),{getReferenceProps:B,getFloatingProps:P}=fo([T,Z]),_=ne(),G=d((()=>{p||H(!A)}),[p,H,A]),j=d((()=>{L(!1)}),[]),F=d((()=>{const e=V.current;e&&$({startDate:e.startDate,endDate:e.endDate}),L(!1)}),[$]),Y=l((()=>e.createElement(le,{name:"date_range",color:p?_.palette.neutral.base:_.palette.text.accent})),[p,_]);return e.createElement(de,{ref:N},e.createElement("div",Object.assign({ref:S.setReference},B(),{style:{width:"fit-content"}}),e.createElement(YC,{date:{startDate:a,endDate:s},error:c,errorText:u,disabled:p,size:m,variant:h,format:y,append:Y,onDatesChange:$,onAppendClick:G})),A&&e.createElement(no,null,e.createElement(oo,{context:O,modal:!1,initialFocus:-1,returnFocus:!1},e.createElement(am,Object.assign({ref:S.setFloating,startDate:a,endDate:s,applyButtonText:w,cancelButtonText:C,defaultPresetButton:I,presetButtons:k,showDateFields:b,showTimeFields:v,timeFieldProps:x,dateFieldFormat:"YYYY-MM-DD",monthFormat:g,weekConfig:f,style:{position:D,top:null!=z?z:0,left:null!=R?R:0,zIndex:_.depth.calendarRange,overflow:"hidden",maxWidth:"min(640px, calc(100vw - 32px))"},isOutsideRange:E,onApply:j,onCancel:F,onDatesChange:$,onPresetButtonClick:M},P())))))}));var XC=e.memo(WC);const JC=(e,t)=>{if("number"==typeof e)return e;const n=parseFloat(e);if(e.includes("vw"))return n/100*window.innerWidth;if(e.includes("vh"))return n/100*window.innerHeight;if(e.includes("%")){return n/100*("left"===t||"right"===t?window.innerWidth:window.innerHeight)}return e.includes("px")?n:isNaN(n)?("production"!==process.env.NODE_ENV&&console.error(`Drawer: 無効なサイズ値です: "${e}". デフォルト値を使用します。`),400):("production"!==process.env.NODE_ENV&&console.warn(`Drawer: 文字列サイズには単位を指定してください。"${e}" → "${e}px" を推奨`),n)},UC=v.div`
|
|
3066
3066
|
position: fixed;
|
|
3067
3067
|
top: 0;
|
|
3068
3068
|
left: 0;
|
|
@@ -3073,7 +3073,7 @@ object-assign
|
|
|
3073
3073
|
opacity: ${({shouldShow:e})=>e?1:0};
|
|
3074
3074
|
transition: opacity ${({transitionDuration:e})=>e}ms
|
|
3075
3075
|
ease-out;
|
|
3076
|
-
`,
|
|
3076
|
+
`,QC=v.div`
|
|
3077
3077
|
position: fixed;
|
|
3078
3078
|
top: ${({direction:e})=>"bottom"===e?"auto":0};
|
|
3079
3079
|
bottom: ${({direction:e})=>0};
|
|
@@ -3090,7 +3090,7 @@ object-assign
|
|
|
3090
3090
|
transform: ${({direction:e,shouldShow:t})=>((e,t)=>{if(t)return"translate3d(0, 0, 0)";switch(e){case"left":return"translate3d(-100%, 0, 0)";case"right":return"translate3d(100%, 0, 0)";case"bottom":return"translate3d(0, 100%, 0)";default:return"translate3d(0, 0, 0)"}})(e,t)};
|
|
3091
3091
|
transition: transform ${({transitionDuration:e})=>e}ms
|
|
3092
3092
|
cubic-bezier(0.23, 1, 0.32, 1);
|
|
3093
|
-
`,
|
|
3093
|
+
`,qC=v.div`
|
|
3094
3094
|
position: absolute;
|
|
3095
3095
|
z-index: 10;
|
|
3096
3096
|
background-color: transparent;
|
|
@@ -3114,7 +3114,7 @@ object-assign
|
|
|
3114
3114
|
width: 32px;
|
|
3115
3115
|
}
|
|
3116
3116
|
`}
|
|
3117
|
-
`,
|
|
3117
|
+
`,KC=v.div`
|
|
3118
3118
|
background: ${({theme:e,active:t})=>t?e.palette.neutral.base:e.palette.neutral.lighter};
|
|
3119
3119
|
border-radius: ${({theme:e})=>e.radius/4}px;
|
|
3120
3120
|
position: absolute;
|
|
@@ -3134,26 +3134,26 @@ object-assign
|
|
|
3134
3134
|
top: 50%;
|
|
3135
3135
|
transform: translateY(-50%);
|
|
3136
3136
|
`}
|
|
3137
|
-
`,
|
|
3137
|
+
`,eE=v.div`
|
|
3138
3138
|
position: sticky;
|
|
3139
3139
|
top: 0;
|
|
3140
3140
|
background-color: ${({theme:e})=>e.palette.background.default};
|
|
3141
3141
|
z-index: 1;
|
|
3142
3142
|
border-bottom: 1px solid ${({theme:e})=>e.palette.neutral.softLight};
|
|
3143
3143
|
padding: ${({theme:e})=>2*e.spacing}px;
|
|
3144
|
-
`,
|
|
3144
|
+
`,tE=v.div`
|
|
3145
3145
|
flex: 1;
|
|
3146
3146
|
overflow: auto;
|
|
3147
|
-
`,
|
|
3147
|
+
`,nE=v.div`
|
|
3148
3148
|
position: sticky;
|
|
3149
3149
|
bottom: 0;
|
|
3150
3150
|
background-color: ${({theme:e})=>e.palette.background.default};
|
|
3151
3151
|
z-index: 1;
|
|
3152
3152
|
border-top: 1px solid ${({theme:e})=>e.palette.neutral.softLight};
|
|
3153
3153
|
padding: ${({theme:e})=>2*e.spacing}px;
|
|
3154
|
-
`,
|
|
3154
|
+
`,rE=({isOpen:e,direction:n,onClose:r,size:l="40vw",resizable:s=!1,minSize:c="20vw",maxSize:u="90vw",onResize:p,stickyHeader:m,stickyFooter:h,confirmOnClose:g,allowBackgroundScroll:f=!1,children:b})=>{const v=300,x=JC(l,n),y=JC(c,n),w=JC(u,n),C=Math.min(y,w),E=Math.max(y,w),I=Math.max(C,Math.min(x,E));"production"!==process.env.NODE_ENV&&(y>w&&console.warn(`Drawer: minSize (${y}px) が maxSize (${w}px) より大きいです。自動補正します。`),(x<C||x>E)&&console.warn(`Drawer: size (${x}px) が min/max の範囲外です。自動補正します。`));const[k,M]=i(!1),[$,A]=i(!1),[L,V]=i(I),H=o(!1),O=o(0),S=o(0),D=o(!1),[R,z]=i(!1),[N,T]=i(null),[Z,B]=i(!1),P=t.useMemo((()=>{if(!g)return null;const e="string"==typeof g?{message:g}:g;return{title:e.title||"確認",message:e.message||"変更内容が保存されていません。閉じてもよろしいですか?",confirmText:e.confirmText||"変更を破棄して閉じる",cancelText:e.cancelText||"編集を続ける",buttonColor:e.buttonColor||"danger"}}),[g]);a((()=>{const e=JC(l,n),t=JC(c,n),r=JC(u,n),i=Math.min(t,r),o=Math.max(t,r),a=Math.max(i,Math.min(e,o));"production"!==process.env.NODE_ENV&&(t>r&&console.warn(`Drawer: minSize (${t}px) が maxSize (${r}px) より大きいです。自動補正します。`),(e<i||e>o)&&console.warn(`Drawer: size (${e}px) が min/max の範囲外です。自動補正します。`)),V(a)}),[l,c,u,n]),a((()=>{if(e){M(!0);const e=setTimeout((()=>{A(!0)}),16);return()=>clearTimeout(e)}if(k){A(!1);const e=setTimeout((()=>{M(!1)}),v);return()=>clearTimeout(e)}}),[e,k]),a((()=>{if(!f&&e){const e=document.body.style.overflow;return document.body.style.overflow="hidden",()=>{document.body.style.overflow=e}}}),[e,f]);const _=d((e=>{if(!H.current)return;const t="left"===n||"right"===n;let r;if(e instanceof TouchEvent){const n=e.touches[0]||e.changedTouches[0];r=t?n.clientX:n.clientY}else r=t?e.clientX:e.clientY;let i=r-O.current;"right"===n&&(i=-i),"bottom"===n&&(i=-i);let o=S.current+i;o=Math.max(C,Math.min(E,o)),V(o),null==p||p(o)}),[n,C,E,p]),G=d((()=>{H.current=!1,document.body.style.userSelect="",document.body.style.cursor="",D.current=!0,setTimeout((()=>{D.current=!1}),100)}),[]),j=d((e=>{if(!s)return;e.preventDefault(),e.stopPropagation(),H.current=!0;const t="left"===n||"right"===n;let r;r="touches"in e&&e.touches.length>0?t?e.touches[0].clientX:e.touches[0].clientY:"changedTouches"in e&&e.changedTouches.length>0?t?e.changedTouches[0].clientX:e.changedTouches[0].clientY:t?e.clientX:e.clientY,O.current=r,S.current=L,document.body.style.userSelect="none",document.body.style.cursor=t?"ew-resize":"ns-resize"}),[s,n,L]),F=d((e=>{j(e),B(!0)}),[j]),Y=d((()=>{B(!1)}),[]),W=d((()=>{B(!1)}),[]);a((()=>{if(!s)return;const e=e=>{H.current&&_(e)},t=()=>{H.current&&G()},n=e=>{H.current&&_(e)},r=()=>{H.current&&G()};return window.addEventListener("mousemove",e),window.addEventListener("mouseup",t),window.addEventListener("touchmove",n),window.addEventListener("touchend",r),()=>{window.removeEventListener("mousemove",e),window.removeEventListener("mouseup",t),window.removeEventListener("touchmove",n),window.removeEventListener("touchend",r)}}),[s,_,G]);const X=d((e=>{P?(T(e),z(!0)):null==r||r(e)}),[P,r]);a((()=>{const t=t=>{"Escape"===t.key&&e&&!R&&X("escapeKey")};return e&&window.addEventListener("keydown",t),()=>{window.removeEventListener("keydown",t)}}),[e,R,X]);return k?t.createElement(t.Fragment,null,P&&t.createElement(Ah,{isOpen:R,title:P.title,confirmText:P.confirmText,cancelText:P.cancelText,buttonColor:P.buttonColor,onConfirm:()=>{z(!1),N&&r&&r(N),T(null)},onClose:()=>(z(!1),void T(null))},P.message),t.createElement(Mh,null,f?t.createElement(QC,{direction:n,currentSize:L,shouldShow:$,transitionDuration:v},s&&t.createElement(KC,{direction:n,"data-testid":"resize-bar",active:Z}),s&&t.createElement(qC,{direction:n,"data-testid":"resize-handle",onMouseDown:j,onTouchStart:F,onTouchEnd:Y,onTouchCancel:W,onMouseEnter:()=>B(!0),onMouseLeave:()=>B(!1)}),m&&t.createElement(eE,null,m),t.createElement(tE,null,b),h&&t.createElement(nE,null,h)):t.createElement(UC,{shouldShow:$,transitionDuration:v,onClick:e=>{H.current||D.current||e.target===e.currentTarget&&X("backdropClick")}},t.createElement(QC,{direction:n,currentSize:L,shouldShow:$,transitionDuration:v},s&&t.createElement(KC,{direction:n,"data-testid":"resize-bar",active:Z}),s&&t.createElement(qC,{direction:n,"data-testid":"resize-handle",onMouseDown:j,onTouchStart:F,onTouchEnd:Y,onTouchCancel:W,onMouseEnter:()=>B(!0),onMouseLeave:()=>B(!1)}),m&&t.createElement(eE,null,m),t.createElement(tE,null,b),h&&t.createElement(nE,null,h))))):null},iE={small:{arrowIconSize:16,arrowButtonPadding:"6px"},medium:{arrowIconSize:18,arrowButtonPadding:"8px"},large:{arrowIconSize:20,arrowButtonPadding:"10px"}},oE=v.div`
|
|
3155
3155
|
display: inline-flex;
|
|
3156
|
-
`,
|
|
3156
|
+
`,aE=v(cl)`
|
|
3157
3157
|
border-top-right-radius: 0px;
|
|
3158
3158
|
border-bottom-right-radius: 0px;
|
|
3159
3159
|
border-right: 0;
|
|
@@ -3161,13 +3161,13 @@ object-assign
|
|
|
3161
3161
|
&:disabled {
|
|
3162
3162
|
border-right: 0;
|
|
3163
3163
|
}
|
|
3164
|
-
`,
|
|
3164
|
+
`,lE=v(cl)`
|
|
3165
3165
|
border-top-left-radius: 0px;
|
|
3166
3166
|
border-bottom-left-radius: 0px;
|
|
3167
3167
|
border-left: 1px solid
|
|
3168
3168
|
${({theme:e,color:t})=>"primary"===t?e.palette.primary.darker:e.palette.divider};
|
|
3169
3169
|
padding: 0
|
|
3170
|
-
${({size:e="medium"})=>
|
|
3170
|
+
${({size:e="medium"})=>iE[e].arrowButtonPadding};
|
|
3171
3171
|
min-width: auto;
|
|
3172
3172
|
|
|
3173
3173
|
&:active:not([disabled]) {
|
|
@@ -3178,68 +3178,68 @@ object-assign
|
|
|
3178
3178
|
&:disabled {
|
|
3179
3179
|
border-left: 1px solid ${({theme:e})=>e.palette.divider};
|
|
3180
3180
|
}
|
|
3181
|
-
`,
|
|
3182
|
-
padding-right: ${({size:e="medium"})=>
|
|
3181
|
+
`,sE=v(cl)`
|
|
3182
|
+
padding-right: ${({size:e="medium"})=>iE[e].arrowButtonPadding};
|
|
3183
3183
|
min-width: auto;
|
|
3184
|
-
`,
|
|
3184
|
+
`,cE=v.span`
|
|
3185
3185
|
display: flex;
|
|
3186
3186
|
align-items: center;
|
|
3187
3187
|
width: 100%;
|
|
3188
3188
|
justify-content: space-between;
|
|
3189
|
-
`,
|
|
3189
|
+
`,dE=v.span`
|
|
3190
3190
|
display: flex;
|
|
3191
3191
|
align-items: center;
|
|
3192
|
-
`,
|
|
3192
|
+
`,uE=({size:t="medium",color:n="primary",onClick:r,split:i=!1,contents:o=[],disabled:a=!1,children:l,icon:s,selectedValue:c,menuWidth:d=200,loading:u=!1,toggleAriaLabel:p="メニューを開く"})=>{const m=ne(),h=!!u,g="string"==typeof u?u:u?"Loading...":void 0,f=((e,t)=>e?m.palette.text.disabled:"primary"===t?m.palette.white:m.palette.black)(a||h,n),b=e.useMemo((()=>({small:"16px",medium:"18px",large:"20px"}[t])),[t]),v=void 0!==c?c:l,x=e.useMemo((()=>e.createElement(le,{name:"arrow_bottom",size:iE[t].arrowIconSize,color:f})),[t,f]),y=e.useMemo((()=>h?e.createElement(rl,{width:b}):null),[h,b]),w=!!s,C=!!v,E=h?w?y:void 0:s,I=h?!w&&C||w&&C?g:void 0:v,k=h?w?y:void 0:s,M=(()=>{if(h&&(!w||C))return C?g:void 0})(),$=i?e.createElement(oE,null,e.createElement(aE,{size:t,color:n,inline:!0,disabled:a||h,icon:E,onClick:r},I),e.createElement(lE,{size:t,color:n,inline:!0,disabled:a||h,"data-testid":"menu-toggle","aria-label":p},x)):e.createElement(sE,{size:t,color:n,disabled:a||h,"data-testid":"menu-toggle",icon:k,"aria-label":C?void 0:p},e.createElement(cE,null,h?M?e.createElement(e.Fragment,null,"string"==typeof M?e.createElement(Ya,null,M):M,e.createElement(dE,null,e.createElement(Ua,{pr:.5}),x)):e.createElement(dE,null,e.createElement(Ua,{pr:.5}),x):e.createElement(e.Fragment,null,v&&e.createElement(Ya,null,v),e.createElement(dE,null,e.createElement(Ua,{pr:.5}),x))));return e.createElement(Da,null,e.createElement(Sa,{trigger:$,width:d},o.map(((t,n)=>e.createElement(e.Fragment,{key:`${n}-${t.text}`},t.divideTop&&e.createElement(Ta,null),(t=>"heading"===t.type?e.createElement(Ra,null,t.text):"helpText"===t.type?e.createElement(Na,{prepend:t.prepend},t.text):void 0!==t.checked?e.createElement(Ro,{closeOnChange:!0,checked:t.checked,color:t.color,disabled:t.disabled,prepend:t.icon,onChange:t.onChange},t.text):e.createElement(Dt,{closeOnClick:!0,color:t.color,disabled:t.disabled,prepend:t.icon,onClick:t.onClick},t.text))(t))))))},pE=v.div`
|
|
3193
3193
|
background-color: ${({theme:e})=>e.palette.background.default};
|
|
3194
3194
|
border: 1px solid ${({theme:e})=>e.palette.divider};
|
|
3195
3195
|
border-radius: ${({theme:e})=>e.radius}px;
|
|
3196
3196
|
display: flex;
|
|
3197
3197
|
height: 512px;
|
|
3198
3198
|
overflow: hidden;
|
|
3199
|
-
`,
|
|
3199
|
+
`,mE=v.ul`
|
|
3200
3200
|
flex: 1;
|
|
3201
3201
|
overflow-y: scroll;
|
|
3202
|
-
`,
|
|
3202
|
+
`,hE=v.li`
|
|
3203
3203
|
border-bottom: ${({isLastIndex:e,theme:t})=>e&&void 0!==e?"none":`1px solid ${t.palette.divider}`};
|
|
3204
3204
|
list-style: none;
|
|
3205
|
-
`,
|
|
3205
|
+
`,gE=v(hE)`
|
|
3206
3206
|
padding: ${({theme:e})=>2*e.spacing}px;
|
|
3207
|
-
`,
|
|
3207
|
+
`,fE=v(hE)`
|
|
3208
3208
|
border-bottom: 1px solid ${({theme:e})=>e.palette.divider};
|
|
3209
|
-
`,
|
|
3209
|
+
`,bE=v(be)`
|
|
3210
3210
|
border-bottom: none;
|
|
3211
|
-
`,
|
|
3211
|
+
`,vE=v.div`
|
|
3212
3212
|
padding-left: ${({theme:e})=>e.spacing/2}px;
|
|
3213
|
-
`,
|
|
3213
|
+
`,xE=({children:e,disableCheckbox:n=!1,item:r,onAdd:i,onRemove:o})=>{var a;return t.createElement(de,{display:"flex",justifyContent:"space-between"},r.items||n?e:t.createElement(Kd,{checked:null!==(a=null==r?void 0:r.selected)&&void 0!==a&&a,onClick:()=>{r.selected?null==o||o(r):null==i||i(r)}},e))},yE=({disableCheckbox:e,items:n,onAdd:r,onRemove:i})=>t.createElement(mE,null,n.map(((o,a)=>t.createElement(t.Fragment,null,o.items?t.createElement(fE,{key:o.id},t.createElement(bE,{title:t.createElement(vE,null,t.createElement(xE,{item:o,onAdd:r,onRemove:i},o.content))},t.createElement(yE,{disableCheckbox:e,items:o.items,onAdd:r,onRemove:i}))):t.createElement(gE,{key:o.id,isLastIndex:a+1===n.length},t.createElement(xE,{disableCheckbox:e,item:o,onAdd:r,onRemove:i},o.content)))))),wE=v.div`
|
|
3214
3214
|
flex: 1;
|
|
3215
3215
|
overflow-y: scroll;
|
|
3216
|
-
`,
|
|
3216
|
+
`,CE=v.div`
|
|
3217
3217
|
background-color: ${({theme:e})=>e.palette.neutral.softLight};
|
|
3218
3218
|
border-bottom: 1px solid ${({theme:e})=>e.palette.divider};
|
|
3219
3219
|
border-radius: ${({theme:e})=>`0 ${e.spacing}px 0 0`};
|
|
3220
3220
|
padding: ${({theme:e})=>`${1.5*e.spacing}px ${2*e.spacing}px`};
|
|
3221
3221
|
position: sticky;
|
|
3222
3222
|
top: 0;
|
|
3223
|
-
`,
|
|
3223
|
+
`,EE=v.ul``,IE=v.li`
|
|
3224
3224
|
border-bottom: ${({isLastIndex:e,theme:t})=>e?"none":`1px solid ${t.palette.divider}`};
|
|
3225
3225
|
padding: ${({theme:e})=>2*e.spacing}px;
|
|
3226
3226
|
list-style: none;
|
|
3227
3227
|
display: flex;
|
|
3228
3228
|
justify-content: space-between;
|
|
3229
|
-
`,
|
|
3229
|
+
`,kE=v.button`
|
|
3230
3230
|
background: transparent;
|
|
3231
3231
|
border: none;
|
|
3232
3232
|
cursor: pointer;
|
|
3233
|
-
`,
|
|
3233
|
+
`,ME=v.div`
|
|
3234
3234
|
display: flex;
|
|
3235
3235
|
align-items: center;
|
|
3236
3236
|
justify-content: center;
|
|
3237
3237
|
gap: ${({theme:e})=>2*e.spacing}px;
|
|
3238
|
-
|
|
3238
|
+
`,$E=({items:e,selectedItemTitle:n,onRemove:r})=>{const i=ne();return t.createElement(wE,null,t.createElement(CE,null,t.createElement(ke,{size:"sm",weight:"bold"},t.createElement(ke,{color:"primary",component:"span",size:"sm",weight:"bold"},e.length," "),n)),t.createElement(EE,null,e.map(((n,o)=>t.createElement(IE,{key:n.id,isLastIndex:o+1===e.length},n.content,t.createElement(ME,null,r&&t.createElement(kE,{type:"button","aria-label":"選択を解除",onClick:()=>r(n)},t.createElement(le,{color:i.palette.black,name:"close_circle",type:"fill"}))))))))},AE=(e,t)=>{const n=[];return e.forEach((e=>{if(e.items)return void n.push(Object.assign(Object.assign({},e),{items:AE(e.items,t)}));t.find((t=>t.id===e.id))?n.push(Object.assign(Object.assign({},e),{selected:!0})):n.push(e)})),n},LE=e.forwardRef((function(t,n){const{candidateItems:r,selectedItems:i,selectedItemTitle:o,disableCheckbox:a,onAdd:l,onRemove:s}=Cd({props:t,name:"DualListBox"}),c=ne(),d=e.useMemo((()=>AE(r,i)),[r,i]);return e.createElement(pE,{ref:n},e.createElement(yE,{disableCheckbox:a,items:d,onAdd:l,onRemove:s}),e.createElement(zh,{color:c.palette.divider,orientation:"vertical"}),e.createElement($E,{items:i,selectedItemTitle:o,onRemove:s}))})),VE=v.div`
|
|
3239
3239
|
container-type: inline-size;
|
|
3240
3240
|
line-break: anywhere;
|
|
3241
3241
|
height: 100%;
|
|
3242
|
-
`,
|
|
3242
|
+
`,HE=v.ul`
|
|
3243
3243
|
display: none;
|
|
3244
3244
|
padding: 0;
|
|
3245
3245
|
margin: 0;
|
|
@@ -3269,7 +3269,7 @@ object-assign
|
|
|
3269
3269
|
border-bottom-color: ${({theme:e})=>e.palette.primary.base};
|
|
3270
3270
|
}
|
|
3271
3271
|
}
|
|
3272
|
-
`,
|
|
3272
|
+
`,OE=v.span`
|
|
3273
3273
|
display: grid;
|
|
3274
3274
|
place-items: center;
|
|
3275
3275
|
min-width: 16px;
|
|
@@ -3281,7 +3281,7 @@ object-assign
|
|
|
3281
3281
|
border-radius: 999%;
|
|
3282
3282
|
color: ${({theme:e})=>e.palette.white};
|
|
3283
3283
|
background: ${({theme:e})=>e.palette.primary.base};
|
|
3284
|
-
`,
|
|
3284
|
+
`,SE=v.div`
|
|
3285
3285
|
position: relative;
|
|
3286
3286
|
display: grid;
|
|
3287
3287
|
grid-template-columns: repeat(2, 1fr);
|
|
@@ -3310,7 +3310,7 @@ object-assign
|
|
|
3310
3310
|
content: none;
|
|
3311
3311
|
}
|
|
3312
3312
|
}
|
|
3313
|
-
`,
|
|
3313
|
+
`,DE=v.div`
|
|
3314
3314
|
display: flex;
|
|
3315
3315
|
flex-direction: column;
|
|
3316
3316
|
height: 100%;
|
|
@@ -3320,14 +3320,14 @@ object-assign
|
|
|
3320
3320
|
display: ${({isShow:e})=>e?"block":"none"};
|
|
3321
3321
|
height: auto;
|
|
3322
3322
|
}
|
|
3323
|
-
`,
|
|
3323
|
+
`,RE=v.div.attrs({tabIndex:0})`
|
|
3324
3324
|
flex-grow: 1;
|
|
3325
3325
|
overflow-y: auto;
|
|
3326
3326
|
|
|
3327
3327
|
@media (max-width: ${F.MOBILE}px) {
|
|
3328
3328
|
overflow: initial;
|
|
3329
3329
|
}
|
|
3330
|
-
`,
|
|
3330
|
+
`,zE=v.div`
|
|
3331
3331
|
display: grid;
|
|
3332
3332
|
grid-template:
|
|
3333
3333
|
${({hasMenu:e=!1,hasCustomFilterHeader:t=!1})=>t?e?'"custom custom menu"\n "count buttons buttons"':'"custom custom custom"\n "count buttons buttons"':e?'"search search menu"\n "count buttons buttons"':'"search search search"\n "count buttons buttons"'} /
|
|
@@ -3345,7 +3345,7 @@ object-assign
|
|
|
3345
3345
|
top: 36.5px;
|
|
3346
3346
|
z-index: 1;
|
|
3347
3347
|
}
|
|
3348
|
-
`,
|
|
3348
|
+
`,NE=v.div`
|
|
3349
3349
|
grid-area: search;
|
|
3350
3350
|
position: relative;
|
|
3351
3351
|
display: flex;
|
|
@@ -3376,7 +3376,7 @@ object-assign
|
|
|
3376
3376
|
color: ${({theme:e})=>e.palette.text.disabled};
|
|
3377
3377
|
}
|
|
3378
3378
|
}
|
|
3379
|
-
`,
|
|
3379
|
+
`,TE=v.button`
|
|
3380
3380
|
position: absolute;
|
|
3381
3381
|
right: 6px;
|
|
3382
3382
|
flex-shrink: 0;
|
|
@@ -3387,21 +3387,21 @@ object-assign
|
|
|
3387
3387
|
background: transparent;
|
|
3388
3388
|
color: ${({theme:e})=>e.palette.black};
|
|
3389
3389
|
cursor: pointer;
|
|
3390
|
-
`,
|
|
3390
|
+
`,ZE=v.div`
|
|
3391
3391
|
grid-area: custom;
|
|
3392
3392
|
width: 100%;
|
|
3393
|
-
`,
|
|
3393
|
+
`,BE=v(cl)`
|
|
3394
3394
|
grid-area: menu;
|
|
3395
3395
|
width: 28px;
|
|
3396
3396
|
min-width: 28px;
|
|
3397
|
-
`,
|
|
3397
|
+
`,PE=v.div`
|
|
3398
3398
|
grid-area: count;
|
|
3399
3399
|
/* UI/Text 13 */
|
|
3400
3400
|
font-size: 13px;
|
|
3401
3401
|
line-height: 16px;
|
|
3402
3402
|
display: flex;
|
|
3403
3403
|
color: ${({theme:e})=>e.palette.black};
|
|
3404
|
-
`,
|
|
3404
|
+
`,_E=v.div`
|
|
3405
3405
|
grid-area: buttons;
|
|
3406
3406
|
display: flex;
|
|
3407
3407
|
`;v.button`
|
|
@@ -3414,7 +3414,7 @@ object-assign
|
|
|
3414
3414
|
color: ${({theme:e})=>e.palette.primary.base};
|
|
3415
3415
|
background: transparent;
|
|
3416
3416
|
cursor: pointer;
|
|
3417
|
-
`;const
|
|
3417
|
+
`;const GE=DE,jE=v.div`
|
|
3418
3418
|
@media (max-width: ${F.MOBILE}px) {
|
|
3419
3419
|
display: flex;
|
|
3420
3420
|
position: sticky;
|
|
@@ -3429,21 +3429,21 @@ object-assign
|
|
|
3429
3429
|
border-bottom: 1px solid ${({theme:e})=>e.palette.divider};
|
|
3430
3430
|
border-left: 1px solid ${({theme:e})=>e.palette.divider};
|
|
3431
3431
|
background: ${({theme:e})=>e.palette.neutral.highlight};
|
|
3432
|
-
`,
|
|
3432
|
+
`,FE=RE,YE=v.div`
|
|
3433
3433
|
display: flex;
|
|
3434
3434
|
align-items: center;
|
|
3435
3435
|
gap: 8px;
|
|
3436
|
-
`,
|
|
3437
|
-
${
|
|
3436
|
+
`,WE="\n display: flex;\n align-items: center;\n gap: 2px;\n padding: 2px 4px;\n border-radius: 4px;\n /* UI/Text 12 bold */\n font-weight: 700;\n font-size: 12px;\n line-height: 14px;\n",XE=v.div`
|
|
3437
|
+
${WE}
|
|
3438
3438
|
color: ${({theme:e})=>e.palette.primary.base};
|
|
3439
3439
|
background: ${({theme:e})=>e.palette.primary.highlight};
|
|
3440
|
-
`,
|
|
3441
|
-
${
|
|
3440
|
+
`,JE=v.div`
|
|
3441
|
+
${WE}
|
|
3442
3442
|
color: ${({theme:e})=>e.palette.danger.base};
|
|
3443
3443
|
background: ${({theme:e})=>e.palette.danger.highlight};
|
|
3444
|
-
`,
|
|
3444
|
+
`,UE=v.div`
|
|
3445
3445
|
width: fit-content;
|
|
3446
|
-
`,
|
|
3446
|
+
`,QE=v.p`
|
|
3447
3447
|
position: sticky;
|
|
3448
3448
|
top: 0;
|
|
3449
3449
|
z-index: 1;
|
|
@@ -3465,14 +3465,14 @@ object-assign
|
|
|
3465
3465
|
top: 81.5px;
|
|
3466
3466
|
z-index: 1;
|
|
3467
3467
|
}
|
|
3468
|
-
`,
|
|
3468
|
+
`,qE=v.div`
|
|
3469
3469
|
display: flex;
|
|
3470
3470
|
|
|
3471
3471
|
@media (any-hover: hover) {
|
|
3472
3472
|
opacity: 0;
|
|
3473
3473
|
visibility: hidden;
|
|
3474
3474
|
}
|
|
3475
|
-
`,
|
|
3475
|
+
`,KE=v.div`
|
|
3476
3476
|
display: flex;
|
|
3477
3477
|
align-items: center;
|
|
3478
3478
|
justify-content: space-between;
|
|
@@ -3491,13 +3491,13 @@ object-assign
|
|
|
3491
3491
|
background: ${({theme:e})=>e.palette.neutral.highlight};
|
|
3492
3492
|
}
|
|
3493
3493
|
|
|
3494
|
-
&:hover ${
|
|
3494
|
+
&:hover ${qE} {
|
|
3495
3495
|
visibility: visible;
|
|
3496
3496
|
opacity: 1;
|
|
3497
3497
|
}
|
|
3498
3498
|
|
|
3499
3499
|
@media (any-hover: hover) {
|
|
3500
|
-
&:not(:hover) ${
|
|
3500
|
+
&:not(:hover) ${qE}:has(button[aria-pressed="true"]) {
|
|
3501
3501
|
visibility: visible;
|
|
3502
3502
|
opacity: 1;
|
|
3503
3503
|
|
|
@@ -3512,7 +3512,7 @@ object-assign
|
|
|
3512
3512
|
}
|
|
3513
3513
|
}
|
|
3514
3514
|
}
|
|
3515
|
-
`,
|
|
3515
|
+
`,eI=v.div`
|
|
3516
3516
|
display: flex;
|
|
3517
3517
|
align-items: center;
|
|
3518
3518
|
justify-content: space-between;
|
|
@@ -3528,7 +3528,7 @@ object-assign
|
|
|
3528
3528
|
&:hover {
|
|
3529
3529
|
background: ${({theme:e})=>e.palette.neutral.highlight};
|
|
3530
3530
|
}
|
|
3531
|
-
`,
|
|
3531
|
+
`,tI=v.button`
|
|
3532
3532
|
flex-shrink: 0;
|
|
3533
3533
|
aspect-ratio: 1;
|
|
3534
3534
|
padding: 0;
|
|
@@ -3536,7 +3536,7 @@ object-assign
|
|
|
3536
3536
|
background: transparent;
|
|
3537
3537
|
color: ${({theme:e})=>e.palette.black};
|
|
3538
3538
|
cursor: pointer;
|
|
3539
|
-
`,
|
|
3539
|
+
`,nI=v.div`
|
|
3540
3540
|
padding: 8px 16px;
|
|
3541
3541
|
margin: -1px 0 0;
|
|
3542
3542
|
background: ${({theme:e})=>e.palette.neutral.highlight};
|
|
@@ -3544,7 +3544,7 @@ object-assign
|
|
|
3544
3544
|
font-size: 12px;
|
|
3545
3545
|
line-height: 14px;
|
|
3546
3546
|
color: ${({theme:e})=>e.palette.black};
|
|
3547
|
-
`,
|
|
3547
|
+
`,rI=v.div`
|
|
3548
3548
|
position: sticky;
|
|
3549
3549
|
z-index: 1;
|
|
3550
3550
|
top: 0;
|
|
@@ -3561,10 +3561,10 @@ object-assign
|
|
|
3561
3561
|
background: ${({theme:e})=>e.palette.neutral.highlight};
|
|
3562
3562
|
}
|
|
3563
3563
|
|
|
3564
|
-
${
|
|
3564
|
+
${KE} + & {
|
|
3565
3565
|
margin-top: -1px;
|
|
3566
3566
|
}
|
|
3567
|
-
`,
|
|
3567
|
+
`,iI=v.button`
|
|
3568
3568
|
display: flex;
|
|
3569
3569
|
align-items: center;
|
|
3570
3570
|
gap: ${({theme:e})=>e.spacing/2}px;
|
|
@@ -3586,7 +3586,7 @@ object-assign
|
|
|
3586
3586
|
inset: 0;
|
|
3587
3587
|
display: block;
|
|
3588
3588
|
}
|
|
3589
|
-
`,
|
|
3589
|
+
`,oI=v.div`
|
|
3590
3590
|
position: relative;
|
|
3591
3591
|
grid-area: buttons;
|
|
3592
3592
|
display: flex;
|
|
@@ -3601,27 +3601,27 @@ object-assign
|
|
|
3601
3601
|
opacity: 1;
|
|
3602
3602
|
transition: opacity 0.2s;
|
|
3603
3603
|
}
|
|
3604
|
-
`,
|
|
3604
|
+
`,aI=v.div`
|
|
3605
3605
|
transition: rotate 0.2s;
|
|
3606
3606
|
pointer-events: none;
|
|
3607
3607
|
|
|
3608
3608
|
[aria-expanded="true"] ~ & {
|
|
3609
3609
|
rotate: 180deg;
|
|
3610
3610
|
}
|
|
3611
|
-
`,
|
|
3611
|
+
`,lI=v.span`
|
|
3612
3612
|
flex-shrink: 0;
|
|
3613
3613
|
width: 20px;
|
|
3614
3614
|
transition:
|
|
3615
3615
|
margin 0.2s,
|
|
3616
3616
|
opacity 0.2s;
|
|
3617
|
-
`,
|
|
3617
|
+
`,sI=v.span`
|
|
3618
3618
|
flex-shrink: 0;
|
|
3619
3619
|
width: 20px;
|
|
3620
3620
|
margin-left: auto;
|
|
3621
3621
|
transition:
|
|
3622
3622
|
margin 0.2s,
|
|
3623
3623
|
opacity 0.2s;
|
|
3624
|
-
`,
|
|
3624
|
+
`,cI=v.button`
|
|
3625
3625
|
position: sticky;
|
|
3626
3626
|
top: -1px;
|
|
3627
3627
|
z-index: 1;
|
|
@@ -3642,16 +3642,16 @@ object-assign
|
|
|
3642
3642
|
background: ${({theme:e})=>e.palette.neutral.highlight};
|
|
3643
3643
|
}
|
|
3644
3644
|
|
|
3645
|
-
&:not([aria-expanded="true"]) ${
|
|
3645
|
+
&:not([aria-expanded="true"]) ${lI} {
|
|
3646
3646
|
margin-left: -20px;
|
|
3647
3647
|
opacity: 0;
|
|
3648
3648
|
}
|
|
3649
3649
|
|
|
3650
|
-
&[aria-expanded="true"] ${
|
|
3650
|
+
&[aria-expanded="true"] ${sI} {
|
|
3651
3651
|
margin-right: -20px;
|
|
3652
3652
|
opacity: 0;
|
|
3653
3653
|
}
|
|
3654
|
-
`,
|
|
3654
|
+
`,dI=v.div`
|
|
3655
3655
|
display: flex;
|
|
3656
3656
|
justify-content: center;
|
|
3657
3657
|
align-items: center;
|
|
@@ -3659,9 +3659,9 @@ object-assign
|
|
|
3659
3659
|
color: ${({theme:e})=>e.palette.neutral.base};
|
|
3660
3660
|
font-size: 13px;
|
|
3661
3661
|
line-height: 16px;
|
|
3662
|
-
`,
|
|
3662
|
+
`,uI=({id:e,children:n,isIncluded:r=!1,isExcluded:i=!1,disableInclude:o,disableExclude:a})=>{const{onIncludedChange:l,onExcludedChange:s,includedIds:d,excludedIds:u}=c(pI),p=c(hI),m=p>=2,h=(e,t)=>e?t:z.gray[900],g=!o&&t.createElement(cl,{type:"button",size:"small",color:"secondaryLight","aria-pressed":r,"aria-label":"追加",icon:t.createElement(le,{name:"check_thin",color:h(r,z.blue[500])}),onClick:()=>{r?l(d.filter((t=>t!==e))):i?(s(u.filter((t=>t!==e))),l([...d,e])):l([...d,e])}}),f=!a&&t.createElement(cl,{type:"button",size:"small",color:"secondaryLight","aria-pressed":i,"aria-label":"除外",icon:t.createElement(le,{name:"forbid",color:h(i,z.red[500])}),onClick:()=>{i?s(u.filter((t=>t!==e))):r?(l(d.filter((t=>t!==e))),s([...u,e])):s([...u,e])}});return t.createElement(KE,{$depth:p,$nested:m},n,t.createElement(qE,null,o||a?t.createElement(t.Fragment,null,g,f):t.createElement(Qu,{size:"small",color:"secondaryLight"},g,f)))};uI.displayName="DualListBox2Item";const pI=s({filterWords:[],includedIds:[],excludedIds:[],activeSection:null,onIncludedChange:e=>{},onExcludedChange:e=>{},setActiveSection:e=>{}}),mI=s({groupName:""}),hI=s(0),gI=(e,t)=>{p.forEach(e,(e=>{if(t(e),!m(e))return;const n=e.props;n.children&&gI(n.children,t)}))},fI=e=>{const t=[];return gI(e,(e=>{if(m(e)&&"string"!=typeof e.type&&"symbol"!=typeof e.type&&e.type&&"function"==typeof e.type&&"displayName"in e.type&&e.type.displayName===uI.displayName){const n=e.props,r=n.label||(e=>{let t="";const n=e=>{"string"==typeof e||"number"==typeof e?t+=String(e):m(e)&&e.props.children?n(e.props.children):Array.isArray(e)&&e.forEach(n)};return n(e),t})(n.children);t.push({id:n.id,label:r,groupName:n.groupName})}})),t},bI=e=>e.reduce(((e,t)=>{const n=e.find((e=>e.groupName===t.groupName));return n?n.items.push({id:t.id,label:t.label,selectedContent:t.selectedContent}):e.push({groupName:t.groupName,items:[{id:t.id,label:t.label,selectedContent:t.selectedContent}]}),e}),[]),vI=e=>e.reduce(((e,t)=>{const n=e.find((e=>e.groupName===t.groupName));return n?n.items.push(t):e.push({groupName:t.groupName,items:[t]}),e}),[]),xI=({label:e,children:n,onOpen:r,onClose:i})=>{const{activeSection:o,setActiveSection:a}=c(pI),s=l((()=>o===e),[e,o]),u=l((()=>null!==o&&o!==e),[e,o]),p=d((()=>{const t=!s;a(t?e:null),t&&r&&r(),!t&&i&&i()}),[e,s,a,r,i]);return u?null:t.createElement(mI.Provider,{value:{groupName:e}},t.createElement(cI,{type:"button","aria-label":`${e}を開く`,"aria-expanded":s,onClick:p},t.createElement(lI,null,t.createElement(le,{name:"arrow_left",color:z.gray[900]})),t.createElement("div",null,e),t.createElement(sI,null,t.createElement(le,{name:"arrow_right",color:z.gray[900]}))),s&&n)};xI.displayName="DualListBox2Section";const yI=v(Wo)`
|
|
3663
3663
|
margin-right: 16px;
|
|
3664
|
-
`,
|
|
3664
|
+
`,wI=({pageSize:e,pageSizeOptions:n,onPageSizeChange:r})=>t.createElement(Sa,{width:136,trigger:t.createElement(yI,{append:e},"件数を変更")},n.map((n=>t.createElement(Ro,{key:n,closeOnChange:!0,checked:e===n,onChange:()=>r(n)},n,"件")))),CI=({label:e,disableInclude:n,disableExclude:r,children:o,onOpen:a,onClose:s,onInclude:u,onExclude:p})=>{const[m,h]=i(!1),g=d((()=>{const e=!m;h(e),e&&a&&a(),!e&&s&&s()}),[m,a,s]),f=c(hI),{includedIds:b,excludedIds:v,onIncludedChange:x,onExcludedChange:y}=c(pI),w=l((()=>(e=>fI(e).map((e=>e.id)))(o)),[o]),C=!(n||void 0===u&&w.every((e=>b.includes(e)))),E=!(r||void 0===p&&w.every((e=>v.includes(e)))),I=d((()=>{u?u():w.every((e=>b.includes(e)))||(x(Array.from(new Set([...b,...w]))),y(v.filter((e=>!w.includes(e)))))}),[u,w,b,v,x,y]),k=d((()=>{p?p():w.every((e=>v.includes(e)))||(y(Array.from(new Set([...v,...w]))),x(b.filter((e=>!w.includes(e)))))}),[p,w,b,v,x,y]),M=C&&t.createElement(cl,{type:"button",size:"small",color:"secondaryLight","aria-label":"追加",icon:t.createElement(le,{name:"check_thin",color:z.blue[500]}),onClick:I}),$=E&&t.createElement(cl,{type:"button",size:"small",color:"secondaryLight","aria-label":"除外",icon:t.createElement(le,{name:"forbid",color:z.red[500]}),onClick:k});return t.createElement(t.Fragment,null,t.createElement(rI,{$depth:f},t.createElement(iI,{type:"button","aria-label":`${e}を開く`,"aria-expanded":m,onClick:g},f>=1&&t.createElement(le,{name:"corner_down_right",size:"md",color:z.gray[400]}),e),t.createElement(oI,null,C&&E?t.createElement(Qu,{size:"small",color:"secondaryLight"},M,$):t.createElement(t.Fragment,null,M,$)),t.createElement(aI,null,t.createElement(le,{name:"arrow_down",color:z.gray[900]}))),m&&t.createElement(hI.Provider,{value:f+1},o))};CI.displayName="DualListBox2Accordion";const EI=t.memo((({id:e,children:n})=>{const{includedIds:r,excludedIds:i,onIncludedChange:o,onExcludedChange:a}=c(pI),s=l((()=>r.includes(e)),[r,e]),u=l((()=>i.includes(e)),[i,e]),p=d((()=>{s&&o(r.filter((t=>t!==e))),u&&a(i.filter((t=>t!==e)))}),[s,u,r,i,o,a,e]);return t.createElement(eI,null,n,t.createElement(tI,{type:"button","aria-label":"解除",onClick:p},t.createElement(le,{name:"close_circle",type:"fill",color:"currentColor"})))}));EI.displayName="DualListBox2SelectedItem";const II=({label:e})=>t.createElement(nI,null,e),kI=[],MI=()=>!0,$I=n((({included:e,excluded:n,disableInclude:r,disableExclude:s,menuButtons:c,children:u,loading:p,onIncludedChange:h,onExcludedChange:g,onActiveSectionChange:f,onLoadMore:v,pageSize:x=50,pageSizeOptions:y=[10,50,100,200],onPageSizeChange:w,filter:C="",onFilterChange:E,renderFilterHeader:I,placement:k,middleware:M},$)=>{const[A,L]=i(0),[V,H]=i(null),[O,S]=i(!1),D=o(null),R=!!I,N=l((()=>fI(u)),[u]),T=l((()=>(e=>{const t={};return gI(e,(e=>{if(m(e)&&"string"!=typeof e.type&&"symbol"!=typeof e.type&&e.type&&"function"==typeof e.type&&"displayName"in e.type&&e.type.displayName===uI.displayName){const n=e.props;t[n.id]=n.children}})),t})(u)),[u]),{currentFilter:Z,filterWords:B,filteredChildren:P,matchesFilter:_,handleFilterChange:G,handleFilterReset:j}=function({children:e,externalFilter:n,onFilterChange:r,allItems:o}){const[a,s]=i(""),c=r?n:a,u=d((e=>{const t=e.target.value;r?r(t):s(t)}),[r]),p=d((()=>{r?r(""):s("")}),[r]),h=l((()=>{const e=c.trim();return e?e.split(/\s+/):[]}),[c]),g=d((e=>0===h.length||h.every((t=>e.toLowerCase().includes(t.toLowerCase())))),[h]),f=d((e=>{if(!m(e))return e;if(e.type!==uI)return e;const t=o.find((t=>t.id===e.props.id));return t&&g(t.label)?e:null}),[o,g]),b=d((e=>t.Children.toArray(e).filter(m).map((e=>{if(e.type===uI)return f(e);if("string"!=typeof e.type&&"symbol"!=typeof e.type&&"displayName"in e.type&&e.type.displayName===CI.displayName){const n=e,r=b(n.props.children);return 0===r.length?null:t.cloneElement(n,Object.assign(Object.assign({},n.props),{children:r}))}if("string"!=typeof e.type&&"symbol"!=typeof e.type&&"displayName"in e.type&&e.type.displayName===xI.displayName){const n=e,r=b(n.props.children);return t.cloneElement(n,Object.assign(Object.assign({},n.props),{children:r}))}return e})).filter(Boolean)),[f]),v=l((()=>0===h.length?e:b(e)),[e,h,b]);return{currentFilter:c,filterWords:h,filteredChildren:v,matchesFilter:g,handleFilterChange:u,handleFilterReset:p}}({children:u,externalFilter:C,onFilterChange:E,allItems:N}),F=R?u:P,Y=R?kI:B,W=R?MI:_,X=d((e=>{H(e),null==f||f(e),null!==e||R||j()}),[j,R,f]),J=l((()=>{let e=!1;return gI(u,(t=>{m(t)&&"string"!=typeof t.type&&"symbol"!=typeof t.type&&"displayName"in t.type&&t.type.displayName===xI.displayName&&(e=!0)})),e}),[u]),U=l((()=>e.map((e=>e.id))),[e]),Q=l((()=>n.map((e=>e.id))),[n]),q=l((()=>N.map((e=>e.id))),[N]),K=l((()=>q.filter((e=>{const t=N.find((t=>t.id===e));return!!t&&W(t.label)}))),[q,N,W]),ee=l((()=>{if(!J)return[];if(null===V)return[];const e=[];return gI(u,(t=>{if(!m(t)||"string"==typeof t.type||"symbol"==typeof t.type||!("displayName"in t.type)||t.type.displayName!==xI.displayName)return;const n=t.props;n.label===V&&gI(n.children,(t=>{m(t)&&"string"!=typeof t.type&&"symbol"!=typeof t.type&&"displayName"in t.type&&t.type.displayName===uI.displayName&&e.push(t.props.id)}))})),e}),[V,u,J]),te=l((()=>ee.filter((e=>{const t=N.find((t=>t.id===e));return!!t&&W(t.label)}))),[ee,N,W]),ne=l((()=>{if(J){if(null===V)return!0;return!!te.every((e=>U.includes(e)))}return!!K.every((e=>U.includes(e)))}),[J,V,K,te,U]),re=l((()=>{if(J){if(null===V)return!0;return!!te.every((e=>Q.includes(e)))}return!!K.every((e=>Q.includes(e)))}),[J,V,K,te,Q]),ie=d((()=>{e.length&&h([]),n.length&&g([])}),[e,n,h,g]),oe=d((()=>{if(J){if(null===V)return;return h(Array.from(new Set([...U,...te]))),void g(Q.filter((e=>!te.includes(e))))}h(Array.from(new Set([...U,...K]))),g(Q.filter((e=>!K.includes(e))))}),[K,h,g,J,V,U,Q,te]),ae=d((()=>{if(J){if(null===V)return;return g(Array.from(new Set([...Q,...te]))),void h(U.filter((e=>!te.includes(e))))}g(Array.from(new Set([...Q,...K]))),h(U.filter((e=>!K.includes(e))))}),[K,h,g,J,V,U,Q,te]),se=!r&&t.createElement(cl,{type:"button",size:"small",color:"secondaryLight",icon:t.createElement(le,{name:"check_thin",color:ne?z.gray[400]:z.blue[500]}),disabled:ne,onClick:oe},"全て追加"),ce=!s&&t.createElement(cl,{type:"button",size:"small",color:"secondaryLight",icon:t.createElement(le,{name:"forbid",color:re?z.gray[400]:z.red[500]}),disabled:re,onClick:ae},"全て除外"),de=d((async e=>{if(e[0].isIntersecting&&!O&&v){S(!0);try{await v()}finally{S(!1)}}}),[O,v]);return a((()=>{if("undefined"==typeof IntersectionObserver)return;const e=new IntersectionObserver(de,{root:null,rootMargin:"100px",threshold:.1}),t=D.current;return t&&e.observe(t),()=>{t&&e.unobserve(t)}}),[de]),t.createElement(VE,{ref:$,role:"region","aria-label":"アイテムの追加、除外選択エリア"},t.createElement(HE,{role:"tablist","aria-label":"リストの表示切り替え"},t.createElement("li",null,t.createElement("button",{type:"button",role:"tab","aria-selected":0===A,"aria-expanded":0===A,"aria-controls":"list-items-panel",onClick:()=>L(0)},"リストアイテム")),t.createElement("li",null,t.createElement("button",{type:"button",role:"tab","aria-selected":1===A,"aria-expanded":1===A,"aria-controls":"selected-items-panel",onClick:()=>L(1)},"選択済みアイテム",(e.length>0||n.length>0)&&t.createElement(OE,null,e.length+n.length)))),t.createElement(SE,null,t.createElement(pI.Provider,{value:{filterWords:Y,includedIds:U,excludedIds:Q,activeSection:V,onIncludedChange:h,onExcludedChange:g,setActiveSection:X}},t.createElement(DE,{isShow:0===A,id:"list-items-panel",role:"tabpanel","aria-labelledby":"list-items-tab"},t.createElement(zE,{hasMenu:!(!c&&!w),hasCustomFilterHeader:R},R?t.createElement(ZE,null,I()):t.createElement(NE,null,t.createElement(le,{name:"search",size:"sm",color:z.gray[600]}),t.createElement("input",{"aria-label":"アイテムを検索",disabled:J&&null===V,placeholder:"検索",type:"text",value:Z,onChange:G}),Z&&t.createElement(TE,{type:"button","aria-label":"検索をリセット",onClick:j},t.createElement(le,{name:"close_circle",type:"fill",color:"currentColor"}))),(c||w)&&t.createElement(Da,null,t.createElement(Sa,{trigger:t.createElement(BE,{type:"button",size:"small",color:"secondaryLight",icon:t.createElement(le,{name:"more_vert",color:z.gray[900]})}),placement:k,middleware:M},w&&t.createElement(wI,{pageSize:x,pageSizeOptions:y,onPageSizeChange:w}),c)),t.createElement(PE,null,p?t.createElement(rl,{width:"16px"}):t.createElement(t.Fragment,null,J&&null===V?"-":J?te.length.toLocaleString("en-US"):K.length.toLocaleString("en-US"),"件")),t.createElement(_E,null,r||s?t.createElement(t.Fragment,null,se,ce):t.createElement(Qu,{size:"small",color:"secondaryLight"},se,ce))),t.createElement(RE,null,F,t.createElement("div",{ref:D,style:{height:"20px"}},p&&t.createElement(dI,null,"読み込み中...")))),t.createElement(GE,{isShow:1===A},t.createElement(jE,null,t.createElement(YE,null,0!==e.length&&t.createElement(XE,null,t.createElement(le,{name:"check_thin",color:z.blue[500]}),e.length),0!==n.length&&t.createElement(JE,null,t.createElement(le,{name:"forbid",color:z.red[500]}),n.length)),t.createElement(UE,null,t.createElement(cl,{type:"button",color:"secondaryLight",size:"small",disabled:!e.length&&!n.length,onClick:ie},"選択をクリア"))),t.createElement(FE,null,!!e.length&&t.createElement(QE,null,t.createElement(le,{name:"check_thin",color:z.blue[500]}),"追加"),bI(e).map((e=>t.createElement(b,{key:e.groupName||"_"},e.groupName&&t.createElement(II,{label:e.groupName}),e.items.map((e=>t.createElement(EI,{key:e.id,id:e.id},T[e.id]||e.selectedContent||e.label)))))),!!n.length&&t.createElement(QE,null,t.createElement(le,{name:"forbid",color:z.red[500]}),"除外"),bI(n).map((e=>t.createElement(b,{key:e.groupName||"_"},e.groupName&&t.createElement(II,{label:e.groupName}),e.items.map((e=>t.createElement(EI,{key:e.id,id:e.id},T[e.id]||e.selectedContent||e.label)))))))))))}));$I.displayName="DualListBox2";const AI=v.div`
|
|
3665
3665
|
display: flex;
|
|
3666
3666
|
justify-content: center;
|
|
3667
3667
|
align-items: center;
|
|
@@ -3679,39 +3679,39 @@ object-assign
|
|
|
3679
3679
|
border: 2px solid ${({theme:e})=>e.palette.primary.base};
|
|
3680
3680
|
background-color: ${({theme:e})=>e.palette.background.hint};
|
|
3681
3681
|
}
|
|
3682
|
-
`,
|
|
3682
|
+
`,LI=v.div``,VI=e.forwardRef((function(t,n){const r=Cd({props:t,name:"FileUploader"}),{accept:i,title:o="Click or Drag & Drop file.",width:a,description:l,onSelectFiles:s}=r,c=e.useRef(null),[d,u]=e.useState(!1),p=e.useCallback((e=>{e.preventDefault(),e.stopPropagation(),u(!1),s(e,e.dataTransfer.files)}),[u,s]),m=e.useCallback((e=>{e.preventDefault(),e.stopPropagation(),u(!0)}),[u]),h=e.useCallback((()=>{u(!1)}),[u]),g=e.useCallback((e=>{s(e,e.target.files)}),[s]);return e.createElement(AI,{ref:n,width:a,filesDraggedOver:d,onDrop:p,onDragOver:m,onDragLeave:h,onClick:()=>{var e;null===(e=c.current)||void 0===e||e.click()}},e.createElement("input",{ref:c,multiple:!0,"aria-label":"file-uploader",type:"file",accept:i,onChange:g}),e.createElement(LI,null,e.createElement(de,{display:"flex"},e.createElement(le,{name:"folder_open",size:"md",color:"active"}),e.createElement(ke,{weight:"bold",color:"primary"},o)),l&&e.createElement(e.Fragment,null,e.createElement(Ua,{pt:2.5}),e.createElement(ke,{weight:"bold",align:"center",size:"sm",color:"secondary"},l))))})),HI={small:{height:"28px",borderRadius:"4px",iconSize:"20px",arrowIconSize:"16px",padding:"0 2px 0 6px"},medium:{height:"32px",borderRadius:"6px",iconSize:"22px",arrowIconSize:"18px",padding:"0 2px 0 6px"},large:{height:"40px",borderRadius:"6px",iconSize:"24px",arrowIconSize:"20px",padding:"0 4px 0 8px"}},OI=e=>({light:{background:e.palette.background.default},dark:{background:e.palette.neutral.ultraLight}}),SI=y`
|
|
3683
3683
|
border: 1px solid ${({theme:e})=>e.palette.divider};
|
|
3684
3684
|
background-color: ${({theme:e})=>e.palette.background.default};
|
|
3685
|
-
`,SI=e=>y`
|
|
3686
|
-
height: ${VI[e].height};
|
|
3687
|
-
border-radius: ${VI[e].borderRadius};
|
|
3688
3685
|
`,DI=e=>y`
|
|
3686
|
+
height: ${HI[e].height};
|
|
3687
|
+
border-radius: ${HI[e].borderRadius};
|
|
3688
|
+
`,RI=e=>y`
|
|
3689
3689
|
/* 左側のアイコン */
|
|
3690
3690
|
span:first-child {
|
|
3691
|
-
width: ${
|
|
3692
|
-
height: ${
|
|
3691
|
+
width: ${HI[e].iconSize};
|
|
3692
|
+
height: ${HI[e].iconSize};
|
|
3693
3693
|
svg {
|
|
3694
|
-
width: ${
|
|
3695
|
-
height: ${
|
|
3694
|
+
width: ${HI[e].iconSize};
|
|
3695
|
+
height: ${HI[e].iconSize};
|
|
3696
3696
|
}
|
|
3697
3697
|
}
|
|
3698
3698
|
/* 右側の矢印アイコン */
|
|
3699
3699
|
span:last-child {
|
|
3700
|
-
width: ${
|
|
3701
|
-
height: ${
|
|
3700
|
+
width: ${HI[e].arrowIconSize};
|
|
3701
|
+
height: ${HI[e].arrowIconSize};
|
|
3702
3702
|
svg {
|
|
3703
|
-
width: ${
|
|
3704
|
-
height: ${
|
|
3703
|
+
width: ${HI[e].arrowIconSize};
|
|
3704
|
+
height: ${HI[e].arrowIconSize};
|
|
3705
3705
|
}
|
|
3706
3706
|
}
|
|
3707
|
-
padding: ${
|
|
3708
|
-
`,
|
|
3707
|
+
padding: ${HI[e].padding};
|
|
3708
|
+
`,zI=v.div`
|
|
3709
3709
|
position: relative;
|
|
3710
3710
|
display: grid;
|
|
3711
3711
|
grid-template-columns: auto 1fr;
|
|
3712
3712
|
align-items: center;
|
|
3713
3713
|
gap: 0;
|
|
3714
|
-
${
|
|
3714
|
+
${SI}
|
|
3715
3715
|
overflow: hidden;
|
|
3716
3716
|
transition:
|
|
3717
3717
|
border-color 0.2s ease,
|
|
@@ -3756,15 +3756,15 @@ object-assign
|
|
|
3756
3756
|
}
|
|
3757
3757
|
|
|
3758
3758
|
&[data-size="small"] {
|
|
3759
|
-
${
|
|
3759
|
+
${DI("small")}
|
|
3760
3760
|
}
|
|
3761
3761
|
|
|
3762
3762
|
&[data-size="medium"] {
|
|
3763
|
-
${
|
|
3763
|
+
${DI("medium")}
|
|
3764
3764
|
}
|
|
3765
3765
|
|
|
3766
3766
|
&[data-size="large"] {
|
|
3767
|
-
${
|
|
3767
|
+
${DI("large")}
|
|
3768
3768
|
}
|
|
3769
3769
|
|
|
3770
3770
|
&[data-small="true"] {
|
|
@@ -3773,7 +3773,7 @@ object-assign
|
|
|
3773
3773
|
border-radius: 0px;
|
|
3774
3774
|
background-color: transparent;
|
|
3775
3775
|
}
|
|
3776
|
-
`,
|
|
3776
|
+
`,NI=v.button`
|
|
3777
3777
|
flex-shrink: 0;
|
|
3778
3778
|
position: relative;
|
|
3779
3779
|
z-index: 1;
|
|
@@ -3785,7 +3785,7 @@ object-assign
|
|
|
3785
3785
|
border-right: 1px solid ${({theme:e})=>e.palette.divider};
|
|
3786
3786
|
outline-offset: -1px;
|
|
3787
3787
|
color: ${({disabled:e,theme:t})=>e?t.palette.text.disabled:t.palette.black};
|
|
3788
|
-
background: ${({disabled:e,$variant:t="light",theme:n})=>{if(e)return n.palette.neutral.softLight;return
|
|
3788
|
+
background: ${({disabled:e,$variant:t="light",theme:n})=>{if(e)return n.palette.neutral.softLight;return OI(n)[t].background}};
|
|
3789
3789
|
cursor: ${({disabled:e})=>e?"not-allowed":"pointer"};
|
|
3790
3790
|
transition: all 0.2s ease;
|
|
3791
3791
|
|
|
@@ -3796,19 +3796,19 @@ object-assign
|
|
|
3796
3796
|
}
|
|
3797
3797
|
|
|
3798
3798
|
/* サイズバリエーション */
|
|
3799
|
-
&:where(${
|
|
3800
|
-
${
|
|
3799
|
+
&:where(${zI}[data-size="small"] *) {
|
|
3800
|
+
${RI("small")}
|
|
3801
3801
|
}
|
|
3802
3802
|
|
|
3803
|
-
&:where(${
|
|
3804
|
-
${
|
|
3803
|
+
&:where(${zI}[data-size="medium"] *) {
|
|
3804
|
+
${RI("medium")}
|
|
3805
3805
|
}
|
|
3806
3806
|
|
|
3807
|
-
&:where(${
|
|
3808
|
-
${
|
|
3807
|
+
&:where(${zI}[data-size="large"] *) {
|
|
3808
|
+
${RI("large")}
|
|
3809
3809
|
}
|
|
3810
3810
|
|
|
3811
|
-
&:where(${
|
|
3811
|
+
&:where(${zI.toString()}[data-small="true"] *) {
|
|
3812
3812
|
display: none;
|
|
3813
3813
|
}
|
|
3814
3814
|
`;v(Ro)`
|
|
@@ -3820,7 +3820,7 @@ object-assign
|
|
|
3820
3820
|
width: 22px;
|
|
3821
3821
|
height: 22px;
|
|
3822
3822
|
}
|
|
3823
|
-
`;const
|
|
3823
|
+
`;const TI=s({isSmall:!1,disabled:!1}),ZI=({label:e,size:n="medium",variant:r="dark",onRemove:i})=>{const{disabled:o}=t.useContext(TI),a=o?void 0:i;return t.createElement(ze,{label:e,size:n,variant:r,disabled:o,onRemove:a})},BI=({selectedIndex:e,selectOptions:n,onSelectChange:r,children:l,size:s="medium",variant:c="light",disabled:u=!1,error:p=!1,isOpen:m=!1})=>{const[h,g]=i(!1),[f,b]=i(!1),v=o(null),x=n.map((e=>Object.assign(Object.assign({},e),{icon:t.isValidElement(e.icon)&&e.icon.type===le?t.cloneElement(e.icon,{color:e.icon.props.color||"currentColor"}):e.icon}))),y=d((e=>{r(e),g(!1)}),[r,g]),w=d((()=>{u||g(!h)}),[u,h,g]),C=d((e=>{u||g(e)}),[u,g]);return a((()=>{if(!window.ResizeObserver)return;if(!v.current)return;const e=new window.ResizeObserver((()=>{v.current&&b(v.current.clientWidth<130)}));return e.observe(v.current),()=>{e.disconnect()}}),[b]),t.createElement(zI,{ref:v,"data-small":f,"data-size":s,"data-disabled":u,$isOpen:m,$error:p,$disabled:u},t.createElement(Da,null,t.createElement(Sa,{open:!u&&h,trigger:t.createElement(NI,{$variant:c,type:"button",disabled:u,"aria-label":"フィルターのタイプを選ぶ",onClick:w},x[e].icon,t.createElement(le,{name:"arrow_down",color:"currentColor"})),onOpenChange:C},x.map((({label:n,icon:r},i)=>t.createElement(Ro,{key:n,prepend:r,checked:e===i,disabled:u,onChange:()=>y(i)},n))))),t.createElement(TI.Provider,{value:{isSmall:f,disabled:u}},l))};v.button`
|
|
3824
3824
|
box-sizing: border-box;
|
|
3825
3825
|
display: flex;
|
|
3826
3826
|
align-items: center;
|
|
@@ -3836,12 +3836,12 @@ object-assign
|
|
|
3836
3836
|
isolation: isolate;
|
|
3837
3837
|
z-index: 1;
|
|
3838
3838
|
}
|
|
3839
|
-
`;const
|
|
3839
|
+
`;const PI={small:"12px",medium:"13px",large:"14px"};v.span`
|
|
3840
3840
|
flex-grow: 1;
|
|
3841
3841
|
overflow: hidden;
|
|
3842
3842
|
text-overflow: ellipsis;
|
|
3843
3843
|
white-space: nowrap;
|
|
3844
|
-
font-size: ${({$size:e})=>
|
|
3844
|
+
font-size: ${({$size:e})=>PI[e]};
|
|
3845
3845
|
`,v.span`
|
|
3846
3846
|
flex-shrink: 0;
|
|
3847
3847
|
width: 18px;
|
|
@@ -3885,7 +3885,7 @@ object-assign
|
|
|
3885
3885
|
border-color: #007bff;
|
|
3886
3886
|
}
|
|
3887
3887
|
}
|
|
3888
|
-
`;const
|
|
3888
|
+
`;const _I=v.div`
|
|
3889
3889
|
position: relative;
|
|
3890
3890
|
display: flex;
|
|
3891
3891
|
align-items: center;
|
|
@@ -3893,7 +3893,7 @@ object-assign
|
|
|
3893
3893
|
width: calc(100% + 46px);
|
|
3894
3894
|
height: 100%;
|
|
3895
3895
|
margin-left: -46px;
|
|
3896
|
-
background-color: ${({$variant:e,theme:t})=>
|
|
3896
|
+
background-color: ${({$variant:e,theme:t})=>OI(t)[e].background};
|
|
3897
3897
|
|
|
3898
3898
|
&::before {
|
|
3899
3899
|
content: "";
|
|
@@ -3915,7 +3915,7 @@ object-assign
|
|
|
3915
3915
|
&:where([data-overflowing="true"])::before {
|
|
3916
3916
|
opacity: 1;
|
|
3917
3917
|
}
|
|
3918
|
-
`,
|
|
3918
|
+
`,GI=v.div`
|
|
3919
3919
|
position: relative;
|
|
3920
3920
|
display: flex;
|
|
3921
3921
|
align-items: center;
|
|
@@ -3933,7 +3933,7 @@ object-assign
|
|
|
3933
3933
|
&::-webkit-scrollbar {
|
|
3934
3934
|
display: none;
|
|
3935
3935
|
}
|
|
3936
|
-
`,
|
|
3936
|
+
`,jI=v.button`
|
|
3937
3937
|
position: absolute;
|
|
3938
3938
|
inset: 0;
|
|
3939
3939
|
box-sizing: border-box;
|
|
@@ -3944,7 +3944,7 @@ object-assign
|
|
|
3944
3944
|
height: 100%;
|
|
3945
3945
|
padding: 0 8px 0 54px;
|
|
3946
3946
|
border: 0;
|
|
3947
|
-
background-color: ${({$variant:e,theme:t})=>
|
|
3947
|
+
background-color: ${({$variant:e,theme:t})=>OI(t)[e].background};
|
|
3948
3948
|
outline-offset: -1px;
|
|
3949
3949
|
cursor: pointer;
|
|
3950
3950
|
transition: background-color 0.2s ease;
|
|
@@ -3952,10 +3952,10 @@ object-assign
|
|
|
3952
3952
|
svg {
|
|
3953
3953
|
transition: color 0.2s ease;
|
|
3954
3954
|
}
|
|
3955
|
-
`,
|
|
3955
|
+
`,FI=v.span`
|
|
3956
3956
|
flex-shrink: 0;
|
|
3957
3957
|
width: 18px;
|
|
3958
|
-
`,
|
|
3958
|
+
`,YI=v(ya).attrs({$insetFocusRingPadding:!1})`
|
|
3959
3959
|
position: sticky;
|
|
3960
3960
|
top: 0;
|
|
3961
3961
|
z-index: 1;
|
|
@@ -3966,29 +3966,29 @@ object-assign
|
|
|
3966
3966
|
color: ${({theme:e})=>e.palette.icon.line};
|
|
3967
3967
|
}
|
|
3968
3968
|
}
|
|
3969
|
-
`,
|
|
3969
|
+
`,WI=v.div`
|
|
3970
3970
|
display: flex;
|
|
3971
3971
|
justify-content: center;
|
|
3972
3972
|
align-items: center;
|
|
3973
3973
|
padding: 16px 0;
|
|
3974
|
-
`,
|
|
3974
|
+
`,XI=v.div`
|
|
3975
3975
|
display: flex;
|
|
3976
3976
|
align-items: center;
|
|
3977
3977
|
gap: 8px;
|
|
3978
|
-
`,
|
|
3978
|
+
`,JI=v.div`
|
|
3979
3979
|
flex: 1;
|
|
3980
3980
|
position: relative;
|
|
3981
3981
|
display: flex;
|
|
3982
3982
|
align-items: center;
|
|
3983
3983
|
|
|
3984
|
-
${
|
|
3984
|
+
${YI} {
|
|
3985
3985
|
flex: 1;
|
|
3986
3986
|
}
|
|
3987
3987
|
|
|
3988
|
-
${
|
|
3988
|
+
${YI} input {
|
|
3989
3989
|
padding-right: 28px;
|
|
3990
3990
|
}
|
|
3991
|
-
`,
|
|
3991
|
+
`,UI=v.button`
|
|
3992
3992
|
position: absolute;
|
|
3993
3993
|
right: 8px;
|
|
3994
3994
|
flex-shrink: 0;
|
|
@@ -4000,7 +4000,7 @@ object-assign
|
|
|
4000
4000
|
color: ${({theme:e})=>e.palette.black};
|
|
4001
4001
|
cursor: pointer;
|
|
4002
4002
|
z-index: 1;
|
|
4003
|
-
`,
|
|
4003
|
+
`,QI=v.div`
|
|
4004
4004
|
display: inline-flex;
|
|
4005
4005
|
gap: 0;
|
|
4006
4006
|
|
|
@@ -4019,12 +4019,12 @@ object-assign
|
|
|
4019
4019
|
border-bottom-left-radius: 0;
|
|
4020
4020
|
border-top-left-radius: 0;
|
|
4021
4021
|
}
|
|
4022
|
-
`,
|
|
4022
|
+
`,qI=({values:e,options:n,selectedIndex:r,selectOptions:s,onChange:c,onSelectChange:u,size:p="medium",variant:m="dark",tagVariant:h,searchPlaceholder:g="検索",noResultsMessage:f="見つかりませんでした",showOptionsOnlyWhenSearching:b=!1,searchPromptMessage:v="キーワードを入力してください",filterLocally:x=!0,onSearchChange:y,isLoading:w=!1,disabled:C=!1,applyButtonText:E="適用",cancelButtonText:I="キャンセル",error:k=!1,placement:M,middleware:$})=>{const[A,L]=i(""),[V,H]=i(!1),[O,S]=i(e),[D,R]=i(!1),z=l((()=>h||("light"===m?"dark":"light")),[m,h]),[N,T]=i(!1),Z=o(null),B=d((()=>{Z.current&&T(Z.current.clientWidth<Z.current.scrollWidth)}),[]),P=d((e=>{const t=e.trim();if(!t)return n.map((e=>Array.isArray(e)?e:[e]));const r=t.includes(","),i=t.startsWith('"')&&t.endsWith('"'),o=ys(t);return n.filter((e=>{if(!Array.isArray(e)){const n=e.toLowerCase();return i?o.some((e=>n===e.toLowerCase())):r?o.some((e=>n.includes(e.toLowerCase()))):n.includes(t.toLowerCase())}return i?e.some((e=>o.some((t=>e.toLowerCase()===t.toLowerCase())))):r?e.some((e=>o.some((t=>e.toLowerCase().includes(t.toLowerCase()))))):e.some((e=>e.toLowerCase().includes(t.toLowerCase())))})).map((e=>Array.isArray(e)?e:[e]))}),[n]),_=b&&""===A.trim(),G=l((()=>x?P(A):n.map((e=>Array.isArray(e)?e:[e]))),[A,P,x,n]),j=l((()=>Array.from(new Set([...e,...O])).map((e=>[e]))),[e,O]),F=_?j:G,Y=d((e=>{O.includes(e)?S(O.filter((t=>t!==e))):S([...O,e])}),[O]),W=d((()=>{if(V)return;if(!A.trim())return;const e=x?P(A):F;1===e.length&&(Y(e[0][0]),L(""),null==y||y(""))}),[V,A,P,Y,x,F,y]),X=d((e=>{L(e.target.value),null==y||y(e.target.value)}),[y]),J=o(null),U=d((e=>{var t;e.stopPropagation(),L(""),null==y||y(""),null===(t=J.current)||void 0===t||t.focus()}),[y]),Q=d((e=>{e.key}),[]),q=d((t=>{const n=e.filter((e=>e!==t));c(n),S(n)}),[e,c]),K=d((t=>{R(t),t&&S(e),L(""),null==y||y("")}),[e,y]),ee=d((()=>{c(O),R(!1)}),[c,O]),te=d((()=>{S(e),R(!1)}),[e]),ne=d((()=>{const e=F.map((e=>e[0])),t=[...new Set([...O,...e])];S(t)}),[F,O]),re=d((()=>{S([])}),[]),ie=l((()=>t.createElement(XI,null,t.createElement(JI,null,t.createElement(YI,{ref:J,autoFocus:!0,value:A,placeholder:g,onChange:X,onKeyDown:Q,onCompositionStart:()=>H(!0),onCompositionEnd:()=>H(!1),onEnter:W}),A&&t.createElement(UI,{type:"button","aria-label":"検索をリセット",onClick:U},t.createElement(le,{name:"close_circle",type:"fill",color:"currentColor"}))),t.createElement(QI,null,t.createElement(Sc,{content:"すべて選択",positionPriority:["top"],offset:[0,8],disabled:0===F.length},t.createElement(cl,{"aria-label":"すべて選択",icon:t.createElement(le,{name:"check_thin",color:"currentColor"}),size:"small",color:"secondaryDark",disabled:0===F.length,onClick:ne})),t.createElement(Sc,{content:"すべてクリア",positionPriority:["top"],offset:[0,8],disabled:0===F.length},t.createElement(cl,{"aria-label":"すべてクリア",icon:t.createElement(le,{name:"close",color:"currentColor"}),size:"small",color:"secondaryDark",disabled:0===F.length,onClick:re}))))),[A,g,X,Q,W,ne,re,U,F]),oe=l((()=>t.createElement(Za,null,t.createElement(cl,{size:"small",color:"clear",onClick:te},I),t.createElement(cl,{size:"small",onClick:ee},E))),[te,ee,E,I]);a((()=>{if(!window.ResizeObserver)return;if(!Z.current)return;const e=new window.ResizeObserver((()=>{Z.current&&B()}));return e.observe(Z.current),B(),()=>{e.disconnect()}}),[B]);return t.createElement(BI,{variant:m,size:p,selectedIndex:r,selectOptions:s,disabled:C,error:k,isOpen:D,onSelectChange:u},t.createElement(_I,{$variant:m,$size:p,"data-overflowing":N},t.createElement(Da,null,t.createElement(Sa,{open:D&&!C,trigger:t.createElement(jI,{type:"button",$variant:m,$size:p,disabled:C,"aria-label":"タグを追加",onClick:()=>{C||R(!D)}},t.createElement(FI,null,t.createElement(le,{name:"arrow_down",color:"currentColor"}))),stickyHeader:ie,stickyFooter:oe,noResultsMessage:f,placement:M,middleware:$,onOpenChange:e=>!C&&K(e)},_&&0===F.length?t.createElement(Ca,{message:v}):!_&&w?t.createElement(WI,{role:"status","aria-label":"読み込み中"},t.createElement(rl,{width:"24px"})):0===F.length?t.createElement(Ca,{message:f}):F.map((e=>t.createElement(Ro,{key:e[0],checked:O.includes(e[0]),closeOnChange:!1,onChange:()=>Y(e[0])},e[0]))))),t.createElement(GI,{ref:Z},e.map((e=>t.createElement(ZI,{key:e,label:e,size:p,variant:z,onRemove:()=>q(e)}))))))},KI=v.div`
|
|
4023
4023
|
min-width: 0;
|
|
4024
4024
|
width: calc(100% + 46px);
|
|
4025
4025
|
height: 100%;
|
|
4026
4026
|
margin-left: -46px;
|
|
4027
|
-
`,
|
|
4027
|
+
`,ek=v.button`
|
|
4028
4028
|
box-sizing: border-box;
|
|
4029
4029
|
display: flex;
|
|
4030
4030
|
align-items: center;
|
|
@@ -4032,7 +4032,7 @@ object-assign
|
|
|
4032
4032
|
height: 100%;
|
|
4033
4033
|
padding: 0 8px 0 54px;
|
|
4034
4034
|
border: 0;
|
|
4035
|
-
background: ${({$variant:e,theme:t})=>
|
|
4035
|
+
background: ${({$variant:e,theme:t})=>OI(t)[e].background};
|
|
4036
4036
|
outline-offset: -1px;
|
|
4037
4037
|
text-align: left;
|
|
4038
4038
|
color: ${({theme:e})=>e.palette.black};
|
|
@@ -4042,16 +4042,16 @@ object-assign
|
|
|
4042
4042
|
isolation: isolate;
|
|
4043
4043
|
z-index: 1;
|
|
4044
4044
|
}
|
|
4045
|
-
`,
|
|
4045
|
+
`,tk={small:"12px",medium:"13px",large:"14px"},nk=v.span`
|
|
4046
4046
|
flex-grow: 1;
|
|
4047
4047
|
overflow: hidden;
|
|
4048
4048
|
text-overflow: ellipsis;
|
|
4049
4049
|
white-space: nowrap;
|
|
4050
|
-
font-size: ${({$size:e})=>
|
|
4051
|
-
`,
|
|
4050
|
+
font-size: ${({$size:e})=>tk[e]};
|
|
4051
|
+
`,rk=v.span`
|
|
4052
4052
|
flex-shrink: 0;
|
|
4053
4053
|
width: 18px;
|
|
4054
|
-
`,
|
|
4054
|
+
`,ik=v(ya).attrs({$insetFocusRingPadding:!1})`
|
|
4055
4055
|
input {
|
|
4056
4056
|
&::placeholder {
|
|
4057
4057
|
color: ${({$placeholderColor:e,theme:t})=>e||t.palette.icon.line};
|
|
@@ -4112,7 +4112,7 @@ object-assign
|
|
|
4112
4112
|
align-items: center;
|
|
4113
4113
|
pointer-events: none;
|
|
4114
4114
|
}
|
|
4115
|
-
`;const
|
|
4115
|
+
`;const ok=v.div`
|
|
4116
4116
|
max-height: 180px;
|
|
4117
4117
|
overflow: auto;
|
|
4118
4118
|
scrollbar-width: none;
|
|
@@ -4135,24 +4135,24 @@ object-assign
|
|
|
4135
4135
|
box-shadow: ${P.dropdown};
|
|
4136
4136
|
z-index: 1000;
|
|
4137
4137
|
|
|
4138
|
-
${
|
|
4138
|
+
${ok}:not(:last-child) {
|
|
4139
4139
|
border-top: 1px solid ${({theme:e})=>e.palette.neutral.lighter};
|
|
4140
4140
|
}
|
|
4141
|
-
`;const
|
|
4141
|
+
`;const ak=v.div`
|
|
4142
4142
|
position: relative;
|
|
4143
4143
|
display: flex;
|
|
4144
4144
|
align-items: center;
|
|
4145
4145
|
gap: 8px;
|
|
4146
4146
|
|
|
4147
|
-
${
|
|
4147
|
+
${ik} {
|
|
4148
4148
|
flex: 1;
|
|
4149
4149
|
position: relative;
|
|
4150
4150
|
}
|
|
4151
4151
|
|
|
4152
|
-
${
|
|
4152
|
+
${ik} input {
|
|
4153
4153
|
padding-right: 28px;
|
|
4154
4154
|
}
|
|
4155
|
-
`,
|
|
4155
|
+
`,lk=v.button`
|
|
4156
4156
|
position: absolute;
|
|
4157
4157
|
right: 8px;
|
|
4158
4158
|
flex-shrink: 0;
|
|
@@ -4164,7 +4164,7 @@ object-assign
|
|
|
4164
4164
|
color: ${({theme:e})=>e.palette.black};
|
|
4165
4165
|
cursor: pointer;
|
|
4166
4166
|
z-index: 1;
|
|
4167
|
-
`,
|
|
4167
|
+
`,sk=({value:e,options:n,selectedIndex:r,selectOptions:s,onChange:c,onSelectChange:u,size:p="medium",variant:m="dark",searchPlaceholder:h="絞り込む",noResultsMessage:g="見つかりませんでした",disabled:f=!1,error:b=!1,placement:v,middleware:x})=>{const[y,w]=i(0),[C,E]=i(""),[I,k]=i(""),[M,$]=i(!1),[A,L]=i(!1),V=o(null);a((()=>{if(!window.ResizeObserver)return;if(!V.current)return;const e=new window.ResizeObserver((()=>{V.current&&w(V.current.offsetWidth)}));return e.observe(V.current),()=>{e.disconnect()}}),[]);const H=l((()=>{const e=I.trim();return""===e?n:n.filter((t=>t.toLowerCase().includes(e.toLowerCase())))}),[n,I]),O=d((e=>{E(e.target.value),M||k(e.target.value)}),[M]),S=d((e=>{e.stopPropagation(),E(""),k("")}),[]),D=d((e=>{"Enter"!==e.key||k(C)}),[C]),R=d((e=>{L(e),e||(E(""),k(""))}),[]),z=d((e=>{c(e),L(!1)}),[c]),N=d((()=>{f||L(!A)}),[f,A]),T=d((e=>{f||R(e)}),[f,R]),Z=l((()=>t.createElement(ak,null,t.createElement(ik,{autoFocus:!0,value:C,placeholder:h,disabled:f,onChange:O,onKeyDown:D,onCompositionStart:()=>$(!0),onCompositionEnd:()=>$(!1)}),C&&t.createElement(lk,{type:"button","aria-label":"検索をリセット",onClick:S},t.createElement(le,{name:"close_circle",type:"fill",color:"currentColor"})))),[C,h,f,O,D,S]);return t.createElement(BI,{variant:m,size:p,selectedIndex:r,selectOptions:s,disabled:f,error:b,isOpen:A,onSelectChange:u},t.createElement(KI,{ref:V},t.createElement(Da,null,t.createElement(Sa,{open:A&&!f,minWidth:y,trigger:t.createElement(ek,{type:"button",$size:p,$variant:m,disabled:f,onClick:N},t.createElement(nk,{$size:p},e),t.createElement(rk,null,t.createElement(le,{name:"arrow_down",color:"currentColor"}))),stickyHeader:Z,placement:v,middleware:x,onOpenChange:T},H.length>0?H.map((n=>t.createElement(Ro,{key:n,checked:n===e,disabled:f,onChange:()=>z(n)},n))):t.createElement(Ca,{message:g})))))},ck=v.div`
|
|
4168
4168
|
display: flex;
|
|
4169
4169
|
align-items: center;
|
|
4170
4170
|
min-height: 100%;
|
|
@@ -4172,30 +4172,30 @@ object-assign
|
|
|
4172
4172
|
border-radius: 0 4px 4px 0;
|
|
4173
4173
|
overflow: auto;
|
|
4174
4174
|
scrollbar-width: none;
|
|
4175
|
-
background: ${({$variant:e,theme:t})=>
|
|
4175
|
+
background: ${({$variant:e,theme:t})=>OI(t)[e].background};
|
|
4176
4176
|
|
|
4177
4177
|
&::-webkit-scrollbar {
|
|
4178
4178
|
display: none;
|
|
4179
4179
|
}
|
|
4180
4180
|
|
|
4181
|
-
&:where(${
|
|
4181
|
+
&:where(${zI}[data-small="true"] *) {
|
|
4182
4182
|
display: none;
|
|
4183
4183
|
}
|
|
4184
|
-
`,
|
|
4184
|
+
`,dk=v.div`
|
|
4185
4185
|
flex-grow: 1;
|
|
4186
4186
|
display: flex;
|
|
4187
4187
|
gap: 5px;
|
|
4188
4188
|
white-space: nowrap;
|
|
4189
|
-
`,
|
|
4189
|
+
`,uk={small:"26px",medium:"30px",large:"38px"},pk=v.button`
|
|
4190
4190
|
position: absolute;
|
|
4191
4191
|
inset: 0 0 0 auto;
|
|
4192
4192
|
display: none;
|
|
4193
4193
|
place-items: center;
|
|
4194
|
-
width: ${({$size:e="medium"})=>
|
|
4194
|
+
width: ${({$size:e="medium"})=>uk[e]};
|
|
4195
4195
|
border: 0;
|
|
4196
4196
|
outline-offset: -1px;
|
|
4197
4197
|
color: ${({theme:e})=>e.palette.black};
|
|
4198
|
-
background-color: ${({$variant:e,theme:t})=>
|
|
4198
|
+
background-color: ${({$variant:e,theme:t})=>OI(t)[e].background};
|
|
4199
4199
|
box-shadow: -2px 0px 4px rgba(4, 28, 51, 0.16);
|
|
4200
4200
|
cursor: pointer;
|
|
4201
4201
|
transition: background-color 0.2s ease;
|
|
@@ -4211,10 +4211,10 @@ object-assign
|
|
|
4211
4211
|
display: grid;
|
|
4212
4212
|
}
|
|
4213
4213
|
|
|
4214
|
-
&:where(${
|
|
4214
|
+
&:where(${zI}[data-small="true"] *) {
|
|
4215
4215
|
position: static;
|
|
4216
4216
|
display: grid;
|
|
4217
|
-
width: ${({$size:e="medium"})=>
|
|
4217
|
+
width: ${({$size:e="medium"})=>uk[e]};
|
|
4218
4218
|
aspect-ratio: 1;
|
|
4219
4219
|
border: 1px solid ${({theme:e})=>e.palette.divider};
|
|
4220
4220
|
border-radius: 4px;
|
|
@@ -4227,7 +4227,7 @@ object-assign
|
|
|
4227
4227
|
}
|
|
4228
4228
|
}
|
|
4229
4229
|
|
|
4230
|
-
&:where(${
|
|
4230
|
+
&:where(${zI}[data-small="true"] *:active:not(:disabled)) {
|
|
4231
4231
|
padding-top: 4px;
|
|
4232
4232
|
background: ${Z.neutral.highlight};
|
|
4233
4233
|
box-shadow: ${No(2,.04,Z.black)};
|
|
@@ -4242,7 +4242,7 @@ object-assign
|
|
|
4242
4242
|
background-color: transparent;
|
|
4243
4243
|
pointer-events: none;
|
|
4244
4244
|
}
|
|
4245
|
-
`,
|
|
4245
|
+
`,mk=v.div`
|
|
4246
4246
|
position: relative;
|
|
4247
4247
|
flex-grow: 1;
|
|
4248
4248
|
min-width: 100px;
|
|
@@ -4268,7 +4268,7 @@ object-assign
|
|
|
4268
4268
|
width: 20px;
|
|
4269
4269
|
color: ${({theme:e})=>e.palette.icon.line};
|
|
4270
4270
|
pointer-events: none;
|
|
4271
|
-
`;const
|
|
4271
|
+
`;const hk=v.div`
|
|
4272
4272
|
display: grid;
|
|
4273
4273
|
grid-template:
|
|
4274
4274
|
"title title"
|
|
@@ -4296,7 +4296,7 @@ object-assign
|
|
|
4296
4296
|
"bottom";
|
|
4297
4297
|
gap: 16px;
|
|
4298
4298
|
}
|
|
4299
|
-
`,
|
|
4299
|
+
`,gk=v((({className:e,children:n})=>t.createElement("div",{className:e},t.createElement(hk,null,n))))`
|
|
4300
4300
|
container-type: inline-size;
|
|
4301
4301
|
position: absolute;
|
|
4302
4302
|
inset: 20px;
|
|
@@ -4305,7 +4305,7 @@ object-assign
|
|
|
4305
4305
|
align-items: center;
|
|
4306
4306
|
justify-content: center;
|
|
4307
4307
|
pointer-events: none;
|
|
4308
|
-
`,
|
|
4308
|
+
`,fk=v.div`
|
|
4309
4309
|
grid-area: title;
|
|
4310
4310
|
padding: 8px 16px;
|
|
4311
4311
|
margin: 0 -16px;
|
|
@@ -4314,20 +4314,20 @@ object-assign
|
|
|
4314
4314
|
font-size: 16px;
|
|
4315
4315
|
color: ${({theme:e})=>e.palette.black};
|
|
4316
4316
|
background: ${({theme:e})=>e.palette.neutral.ultraLight};
|
|
4317
|
-
`,
|
|
4317
|
+
`,bk=v.div`
|
|
4318
4318
|
grid-area: left;
|
|
4319
4319
|
min-width: 0;
|
|
4320
|
-
`,
|
|
4320
|
+
`,vk=v.div`
|
|
4321
4321
|
grid-area: right;
|
|
4322
4322
|
min-width: 0;
|
|
4323
|
-
`,
|
|
4323
|
+
`,xk=v.p`
|
|
4324
4324
|
margin: 0 0 4px;
|
|
4325
4325
|
/* UI/Text 13 bold */
|
|
4326
4326
|
font-weight: 700;
|
|
4327
4327
|
font-size: 13px;
|
|
4328
4328
|
line-height: 16px;
|
|
4329
4329
|
color: ${({theme:e})=>e.palette.black};
|
|
4330
|
-
`,
|
|
4330
|
+
`,yk=v.button`
|
|
4331
4331
|
display: grid;
|
|
4332
4332
|
grid-template:
|
|
4333
4333
|
"spacer spacer" 0
|
|
@@ -4361,7 +4361,7 @@ object-assign
|
|
|
4361
4361
|
box-shadow: 0 0 0 3px
|
|
4362
4362
|
${({theme:e})=>`${e.palette.primary.softLight}66`};
|
|
4363
4363
|
}
|
|
4364
|
-
`,
|
|
4364
|
+
`,wk=v.div`
|
|
4365
4365
|
grid-area: spacer;
|
|
4366
4366
|
display: flex;
|
|
4367
4367
|
gap: 2px;
|
|
@@ -4372,7 +4372,7 @@ object-assign
|
|
|
4372
4372
|
font-size: 13px;
|
|
4373
4373
|
line-height: 16px;
|
|
4374
4374
|
text-align: left;
|
|
4375
|
-
`,
|
|
4375
|
+
`,Ck=v.div`
|
|
4376
4376
|
grid-area: label;
|
|
4377
4377
|
display: flex;
|
|
4378
4378
|
gap: 2px;
|
|
@@ -4383,12 +4383,12 @@ object-assign
|
|
|
4383
4383
|
line-height: 16px;
|
|
4384
4384
|
text-align: left;
|
|
4385
4385
|
color: ${({theme:e})=>e.palette.black};
|
|
4386
|
-
`,
|
|
4386
|
+
`,Ek=v.div`
|
|
4387
4387
|
grid-area: downArrow;
|
|
4388
4388
|
display: flex;
|
|
4389
4389
|
align-items: center;
|
|
4390
4390
|
justify-content: center;
|
|
4391
|
-
`,
|
|
4391
|
+
`,Ik=v.div`
|
|
4392
4392
|
position: relative;
|
|
4393
4393
|
display: flex;
|
|
4394
4394
|
gap: 6px;
|
|
@@ -4407,14 +4407,14 @@ object-assign
|
|
|
4407
4407
|
box-shadow: 0 0 0 3px
|
|
4408
4408
|
${({theme:e})=>`${e.palette.primary.softLight}66`};
|
|
4409
4409
|
}
|
|
4410
|
-
`,
|
|
4410
|
+
`,kk=v.button`
|
|
4411
4411
|
position: absolute;
|
|
4412
4412
|
inset: 0;
|
|
4413
4413
|
border: 0;
|
|
4414
4414
|
padding: 0;
|
|
4415
4415
|
background: transparent;
|
|
4416
4416
|
cursor: text;
|
|
4417
|
-
`,
|
|
4417
|
+
`,Mk=v.div`
|
|
4418
4418
|
isolation: isolate;
|
|
4419
4419
|
display: grid;
|
|
4420
4420
|
grid-template-columns: 0px min-content;
|
|
@@ -4432,12 +4432,12 @@ object-assign
|
|
|
4432
4432
|
outline: none;
|
|
4433
4433
|
background: transparent;
|
|
4434
4434
|
}
|
|
4435
|
-
|
|
4435
|
+
`,$k=v.div`
|
|
4436
4436
|
visibility: hidden;
|
|
4437
4437
|
white-space: pre;
|
|
4438
4438
|
grid-area: 1 / 2;
|
|
4439
4439
|
font: inherit;
|
|
4440
|
-
|
|
4440
|
+
`,Ak=v.button`
|
|
4441
4441
|
position: absolute;
|
|
4442
4442
|
inset: 0 8px 0 auto;
|
|
4443
4443
|
display: grid;
|
|
@@ -4448,7 +4448,7 @@ object-assign
|
|
|
4448
4448
|
color: ${({theme:e})=>e.palette.black};
|
|
4449
4449
|
background: transparent;
|
|
4450
4450
|
cursor: pointer;
|
|
4451
|
-
`,
|
|
4451
|
+
`,Lk=v.ul`
|
|
4452
4452
|
grid-area: bottom;
|
|
4453
4453
|
display: flex;
|
|
4454
4454
|
gap: 8px;
|
|
@@ -4456,7 +4456,7 @@ object-assign
|
|
|
4456
4456
|
padding: 16px 0 0;
|
|
4457
4457
|
border-top: 1px solid ${({theme:e})=>e.palette.neutral.softLight};
|
|
4458
4458
|
list-style: none;
|
|
4459
|
-
`,
|
|
4459
|
+
`,Vk=({isOpen:e,title:n,values:r,selectedIndex:s,selectOptions:c,onApply:u,onClose:p,menuIconSize:m})=>{const[h,g]=i(""),[f,b]=i(!1),[v,x]=i([]),[y,w]=i(0),[E,I]=i(!1),k=C(),M=d((e=>{const t=e.trim();""===t||v.includes(t)||x([...v,t]),g("")}),[v]),$=l((()=>c.map((e=>Object.assign(Object.assign({},e),{icon:t.cloneElement(e.icon,{size:m,color:k.palette.black})})))),[c,m,k.palette.black]),A=l((()=>$.reduce(((e,t)=>t.label.length>e.label.length?t:e),$[0])),[$]),L=o(null),V=d((e=>{w(e),I(!1)}),[]),H=d((()=>{var e;null===(e=L.current)||void 0===e||e.focus()}),[]),O=d((e=>{const t=[...v];t.splice(e,1),x(t)}),[v]),S=d((e=>{f||e.target instanceof HTMLInputElement&&("Backspace"!==e.key||0!==e.target.selectionStart?"Enter"===e.key&&M(e.target.value):x(v.slice(0,-1)))}),[v,f,M]),D=d((()=>{x([]),g(""),b(!1)}),[]),R=d((()=>{p()}),[p]),z=d((()=>{u(v,y),p()}),[v,y,u,p]),N=d((e=>{g(e.target.value)}),[]),T=d((()=>{b(!0)}),[]),Z=d((()=>{b(!1)}),[]),B=d((()=>{M(h)}),[h,M]),P=l((()=>v.map(((e,n)=>t.createElement(ZI,{key:e,size:"medium",variant:"light",label:e,onRemove:()=>O(n)})))),[v,O]),_=l((()=>$.map((({label:e,icon:n},r)=>t.createElement(Ro,{key:e,prepend:n,checked:y===r,onChange:()=>V(r)},e)))),[$,y,V]),G=l((()=>t.createElement(t.Fragment,null,t.cloneElement($[y].icon,{size:m}),$[y].label)),[$,y,m]);return a((()=>{e&&(x(r),w(s))}),[e,s,r]),t.createElement($h,{isOpen:e,onClose:p},t.createElement(Lc,{in:e},t.createElement(gk,null,t.createElement(fk,null,n),t.createElement(bk,null,t.createElement(xk,null,"条件"),t.createElement(Da,null,t.createElement(Sa,{open:E,trigger:t.createElement(yk,null,t.createElement(wk,{role:"presentation"},A.icon,A.label),t.createElement(Ck,null,G),t.createElement(Ek,null,t.createElement(le,{name:"arrow_down",color:"currentColor"}))),onOpenChange:I},_))),t.createElement(vk,null,t.createElement(xk,null,"値"),t.createElement(Ik,null,t.createElement(kk,{type:"button",onClick:H}),P,t.createElement(Mk,null,t.createElement("input",{ref:L,type:"text","aria-label":"フィルターする値",value:h,onChange:N,onCompositionStart:T,onCompositionEnd:Z,onKeyDown:S,onBlur:B}),t.createElement($k,null,h)),t.createElement(Ak,{type:"button",onClick:D},t.createElement(le,{name:"close_circle",type:"fill",color:"currentColor"})))),t.createElement(Lk,null,t.createElement("li",null,t.createElement(cl,{size:"small",color:"clear",onClick:R},"キャンセル")),t.createElement("li",null,t.createElement(cl,{size:"small",onClick:z},"適用"))))))},Hk=({title:e,values:n,selectedIndex:r,selectOptions:s,onChange:u,onSelectChange:p,size:m="medium",variant:h="dark",tagVariant:g,menuIconSize:f=22,disabled:b=!1,error:v=!1})=>{const{isSmall:x}=c(TI),[y,w]=i(""),[C,E]=i(!1),[I,k]=i(!1),[M,$]=i(!1),[A,L]=i(!1),V=o(null),H=l((()=>g||("light"===h?"dark":"light")),[h,g]),O=o(null),S=o(null),D=d((()=>{O.current&&E(O.current.clientWidth<O.current.scrollWidth)}),[E]),R=d((()=>{if(!O.current||!V.current)return;const e=V.current.getBoundingClientRect(),t=O.current.getBoundingClientRect(),n=Number(window.getComputedStyle(O.current).paddingRight.replace("px",""));return t.right-n-e.left}),[]),z=d((e=>{const t=e.trim();""!==t?n.includes(t)?w(""):(u([...n,t],r),w(""),requestAnimationFrame((()=>{D(),R()}))):w("")}),[n,u,r,D,R]),N=d((e=>{if(!I&&e.target instanceof HTMLInputElement)return"Backspace"===e.key&&0===e.target.selectionStart?(u(n.slice(0,-1),r),void requestAnimationFrame((()=>{D(),R()}))):void("Enter"===e.key&&z(e.target.value))}),[I,u,n,r,D,R,z]),T=d((e=>{const t=[...n];t.splice(e,1),u(t,r),requestAnimationFrame((()=>{D(),R()}))}),[n,u,r]),Z=d(((e,t)=>{u(e,t),p(t),requestAnimationFrame((()=>{D(),R()}))}),[u,p]),B=d((e=>{w(e.target.value)}),[]),P=d((()=>{k(!0)}),[]),_=d((()=>{k(!1)}),[]),G=d((()=>{$(!0)}),[]),j=d((()=>{$(!1)}),[]),F=d((()=>{b||L(!0)}),[b]),Y=d((()=>{L(!1)}),[]),W=d((()=>{Y(),z(y)}),[Y,y,z]);a((()=>{if(!window.ResizeObserver)return;if(!O.current)return;const e=new window.ResizeObserver((()=>{O.current&&(D(),R())}));return e.observe(O.current),()=>{e.disconnect()}}),[D,R]);const X=l((()=>n.map(((e,n)=>t.createElement(ZI,{key:e,size:m,variant:H,label:e,onRemove:()=>T(n)})))),[n,m,H,T]),J={small:18,medium:20,large:22}[m];return t.createElement(t.Fragment,null,t.createElement(BI,{variant:h,size:m,selectedIndex:r,selectOptions:s,disabled:b,error:v,isOpen:A,onSelectChange:p},t.createElement(ck,{ref:O,$size:m,$variant:h},t.createElement(dk,{ref:S},X,t.createElement(mk,null,t.createElement("input",{ref:V,"aria-label":"フィルターする値",disabled:b,type:"text",value:y,enterKeyHint:"enter",onChange:B,onCompositionEnd:_,onCompositionStart:P,onFocus:F,onKeyDown:N,onBlur:W})))),t.createElement(pk,{$size:m,$variant:h,"aria-label":"フィルター入力パネルを開く","data-overflowing":C,type:"button",disabled:b,onClick:G},t.createElement(le,{name:x?"filter":"expand_diagonal_s_fill",color:"currentColor",size:J}))),t.createElement(Vk,{isOpen:M,menuIconSize:f,selectOptions:s,selectedIndex:r,title:e,values:n,onApply:Z,onClose:j}))},Ok=v.div`
|
|
4460
4460
|
position: fixed;
|
|
4461
4461
|
${({isOpen:e,height:t,offset:n,placement:r})=>`${r}: ${e?`${n}px`:""+(0!==t?`calc(${-t}px - 10px)`:"-100vh")}`};
|
|
4462
4462
|
width: 100%;
|
|
@@ -4465,22 +4465,22 @@ object-assign
|
|
|
4465
4465
|
border-bottom: 1px solid ${({theme:e})=>e.palette.neutral.softLight};
|
|
4466
4466
|
transition: all 0.3s;
|
|
4467
4467
|
z-index: 1;
|
|
4468
|
-
`,
|
|
4468
|
+
`,Sk=e.forwardRef((function({isOpen:t,placement:n="top",offset:r=0,children:i},o){const[a,l]=e.useState(null),s=Vc(o,l);return e.createElement(Ok,{ref:s,height:(null==a?void 0:a.clientHeight)||0,offset:r,isOpen:t,placement:n},i)})),Dk=v.div`
|
|
4469
4469
|
display: flex;
|
|
4470
4470
|
align-items: flex-start;
|
|
4471
|
-
`,Dk=v.div`
|
|
4472
|
-
padding: ${({theme:e})=>2*e.spacing}px;
|
|
4473
4471
|
`,Rk=v.div`
|
|
4472
|
+
padding: ${({theme:e})=>2*e.spacing}px;
|
|
4473
|
+
`,zk=v.div`
|
|
4474
4474
|
cursor: pointer;
|
|
4475
4475
|
padding: ${({theme:e})=>e.spacing}px;
|
|
4476
|
-
`,
|
|
4476
|
+
`,Nk=e.forwardRef((function({baseElement:t,positionPriority:n=["right-start"],offset:r=[0,10],isOpen:i,onClose:o,popoverProps:a,children:l},s){const c=ne();return e.createElement(Bh,Object.assign({isOpen:i,baseElement:t,positionPriority:n,offset:r,onClose:o},a),e.createElement(Dk,{ref:s},e.createElement(Rk,null,l),e.createElement(zk,{onClick:e=>{o&&o(e,"clickCloseIcon")}},e.createElement(le,{name:"close",color:c.palette.black}))))})),Tk=w`
|
|
4477
4477
|
0% {
|
|
4478
4478
|
transform: translate(-50%, 0%);
|
|
4479
4479
|
}
|
|
4480
4480
|
100% {
|
|
4481
4481
|
transform: translate(-50%, -48%);
|
|
4482
4482
|
}
|
|
4483
|
-
`,
|
|
4483
|
+
`,Zk=v(lm)`
|
|
4484
4484
|
position: absolute;
|
|
4485
4485
|
top: 50%;
|
|
4486
4486
|
left: 50%;
|
|
@@ -4490,20 +4490,20 @@ object-assign
|
|
|
4490
4490
|
transform: translate(-50%, -48%);
|
|
4491
4491
|
border-radius: 8px 8px 0 0;
|
|
4492
4492
|
background-color: ${({theme:e})=>e.palette.background.default};
|
|
4493
|
-
animation: ${
|
|
4493
|
+
animation: ${Tk} 0.4s;
|
|
4494
4494
|
overflow: hidden;
|
|
4495
|
-
`,
|
|
4495
|
+
`,Bk=v.div`
|
|
4496
4496
|
display: flex;
|
|
4497
4497
|
justify-content: space-between;
|
|
4498
4498
|
align-items: center;
|
|
4499
4499
|
padding: ${({theme:e})=>2*e.spacing}px
|
|
4500
4500
|
${({theme:e})=>3*e.spacing}px;
|
|
4501
4501
|
border-bottom: 1px solid ${({theme:e})=>e.palette.neutral.softLight};
|
|
4502
|
-
`,
|
|
4502
|
+
`,Pk=v.div`
|
|
4503
4503
|
display: flex;
|
|
4504
4504
|
align-items: center;
|
|
4505
4505
|
max-width: 70%;
|
|
4506
|
-
`,
|
|
4506
|
+
`,_k=v.div`
|
|
4507
4507
|
margin-bottom: ${({showFooter:e,theme:t})=>e?2*t.spacing*2+42:0}px;
|
|
4508
4508
|
${({overflowYScroll:e,showFooter:t,theme:n})=>e?Lh({maxHeight:"auto",height:`calc(100vh - ${2*n.spacing*2+42+(t?61:0)}px)`}):y`
|
|
4509
4509
|
overflow-y: visible;
|
|
@@ -4512,7 +4512,7 @@ object-assign
|
|
|
4512
4512
|
100vh - ${2*n.spacing*2+42+(t?61:0)}px
|
|
4513
4513
|
);
|
|
4514
4514
|
`}
|
|
4515
|
-
`,
|
|
4515
|
+
`,Gk=v.div`
|
|
4516
4516
|
position: fixed;
|
|
4517
4517
|
left: 0;
|
|
4518
4518
|
bottom: 0;
|
|
@@ -4525,9 +4525,9 @@ object-assign
|
|
|
4525
4525
|
background-color: ${({theme:e})=>e.palette.neutral.highlight};
|
|
4526
4526
|
border-radius: 0;
|
|
4527
4527
|
margin-bottom: 1.8vh;
|
|
4528
|
-
`,Gk=v.div`
|
|
4529
|
-
cursor: pointer;
|
|
4530
4528
|
`,jk=v.div`
|
|
4529
|
+
cursor: pointer;
|
|
4530
|
+
`,Fk=v.div`
|
|
4531
4531
|
position: fixed;
|
|
4532
4532
|
top: 0;
|
|
4533
4533
|
left: 0;
|
|
@@ -4537,38 +4537,38 @@ object-assign
|
|
|
4537
4537
|
display: flex;
|
|
4538
4538
|
justify-content: center;
|
|
4539
4539
|
align-items: center;
|
|
4540
|
-
`,
|
|
4541
|
-
&.${
|
|
4540
|
+
`,Yk=e.forwardRef((function(t,n){Ae("FullSizeConfirmModal","FullSizeConfirmModal は非推奨です。代わりに Drawer を使用してください。");const r=Cd({props:t,name:"FullSizeConfirmModal"}),{title:i,confirmText:o="Confirm",cancelText:a="Cancel",children:l,onClose:s,onSubmit:c,buttonColor:d="primary",isOpen:u=!0,disabled:p,loading:m,overflowYScroll:h=!0,disableHorizontalPadding:g=!1,subActions:f,modalProps:b,fadeProps:v}=r,x=ne(),y=!!c,w=e=>t=>{s&&s(t,e)};return e.createElement($h,Object.assign({isOpen:u,onClose:s},b),e.createElement(Lc,Object.assign({in:u,unmountOnExit:!0},v),e.createElement(Zk,{ref:n,role:"dialog","aria-modal":"true","aria-label":i},e.createElement("form",{onSubmit:c},e.createElement(Bk,null,e.createElement(Pk,null,e.createElement(ke,{weight:"bold",size:"xxxl"},i),f&&e.createElement(Ua,{pl:2},e.createElement(de,{display:"flex",alignItems:"center",gap:1},f.map(((t,n)=>e.createElement(e.Fragment,{key:n},t)))))),e.createElement(jk,{onClick:w("clickCloseIcon")},e.createElement(le,{name:"close",size:"lg",color:x.palette.black}))),e.createElement(_k,{overflowYScroll:h,showFooter:y},g?l:e.createElement(Ua,{px:3,pb:3},l)),y&&e.createElement(Gk,null,e.createElement(de,{display:"flex",alignItems:"center"},e.createElement(cl,{type:"button",color:"secondaryLight",inline:!0,onClick:w("clickCancelButton")},a),e.createElement(Ua,{pr:2}),e.createElement(cl,{type:"submit",color:d,disabled:p,inline:!0},o)))),m&&e.createElement(Fk,null,e.createElement(rl,null)))))})),Wk="grow-transition",Xk=v(uc)`
|
|
4541
|
+
&.${Wk}-enter, &.${Wk}-appear {
|
|
4542
4542
|
transform: scale(0);
|
|
4543
4543
|
}
|
|
4544
4544
|
|
|
4545
|
-
&.${
|
|
4545
|
+
&.${Wk}-enter-active, &.${Wk}-appear-active {
|
|
4546
4546
|
transform: none;
|
|
4547
4547
|
transition: transform ${({timeout:e})=>Mc(e,"enter")}ms;
|
|
4548
4548
|
}
|
|
4549
4549
|
|
|
4550
|
-
&.${
|
|
4550
|
+
&.${Wk}-exit {
|
|
4551
4551
|
transform: none;
|
|
4552
4552
|
}
|
|
4553
4553
|
|
|
4554
|
-
&.${
|
|
4554
|
+
&.${Wk}-exit-active {
|
|
4555
4555
|
transform: scale(0);
|
|
4556
4556
|
transition: transform ${({timeout:e})=>Mc(e,"exit")}ms;
|
|
4557
4557
|
}
|
|
4558
4558
|
|
|
4559
|
-
&.${
|
|
4559
|
+
&.${Wk}-exit-done {
|
|
4560
4560
|
transform: scale(0);
|
|
4561
4561
|
}
|
|
4562
|
-
`,
|
|
4562
|
+
`,Jk=t=>{var{timeout:n=300,children:r}=t,i=D(t,["timeout","children"]);const o=e.useRef(null);return e.createElement(Xk,Object.assign({nodeRef:o,appear:!0,mountOnEnter:!0,timeout:n,classNames:Wk},i),e.createElement("div",{ref:o},r))},Uk={xs:{iconSize:14,fontSize:12,gap:"2px"},small:{iconSize:16,fontSize:13,gap:"4px"},medium:{iconSize:18,fontSize:14,gap:"6px"},large:{iconSize:20,fontSize:16,gap:"6px"}},Qk=v.span`
|
|
4563
4563
|
color: ${({$color:e})=>e};
|
|
4564
4564
|
${W}
|
|
4565
|
-
`,
|
|
4565
|
+
`,qk=v.a`
|
|
4566
4566
|
display: inline-flex;
|
|
4567
4567
|
width: fit-content;
|
|
4568
4568
|
align-items: center;
|
|
4569
4569
|
vertical-align: middle;
|
|
4570
|
-
gap: ${({$size:e})=>
|
|
4571
|
-
font-size: ${({$size:e})=>`${
|
|
4570
|
+
gap: ${({$size:e})=>Uk[e].gap};
|
|
4571
|
+
font-size: ${({$size:e})=>`${Uk[e].fontSize}px`};
|
|
4572
4572
|
text-decoration: none;
|
|
4573
4573
|
border-radius: ${({theme:e})=>e.radius/2}px;
|
|
4574
4574
|
transition: background-color 0.3s ease;
|
|
@@ -4581,7 +4581,7 @@ object-assign
|
|
|
4581
4581
|
background-color: ${t.palette.primary.highlight};
|
|
4582
4582
|
}
|
|
4583
4583
|
`}
|
|
4584
|
-
`;function
|
|
4584
|
+
`;function Kk(e,n,r){return t.isValidElement(e)?t.cloneElement(e,{size:Uk[n].iconSize,color:r}):e}const eM=e=>{var{icon:n,size:r="medium",pos:i="prepend",prependIcon:o,appendIcon:a,color:l,iconColor:s,textColor:c,children:d}=e,u=D(e,["icon","size","pos","prependIcon","appendIcon","color","iconColor","textColor","children"]);const p=ne(),m=!!u.href,h=null!=c?c:m?p.palette.primary.base:null!=l?l:p.palette.black,g=null!=s?s:m?p.palette.primary.base:null!=l?l:p.palette.black;let f,b;return null!=o||null!=a?(f=o,b=a):"append"===i?(f=void 0,b=n):(f=n,b=void 0),t.createElement(qk,Object.assign({as:m?"a":"span",$size:r,$isLink:m},u),null!=f&&Kk(f,r,g),t.createElement(Qk,{$color:h},d),null!=b&&Kk(b,r,g))},tM=w`
|
|
4585
4585
|
0% {
|
|
4586
4586
|
right: 100%;
|
|
4587
4587
|
left: -35%;
|
|
@@ -4596,7 +4596,7 @@ object-assign
|
|
|
4596
4596
|
right: -90%;
|
|
4597
4597
|
left: 100%;
|
|
4598
4598
|
}
|
|
4599
|
-
`,
|
|
4599
|
+
`,nM=w`
|
|
4600
4600
|
0% {
|
|
4601
4601
|
right: 100%;
|
|
4602
4602
|
left: -200%;
|
|
@@ -4611,7 +4611,7 @@ object-assign
|
|
|
4611
4611
|
right: -8%;
|
|
4612
4612
|
left: 107%;
|
|
4613
4613
|
}
|
|
4614
|
-
`,
|
|
4614
|
+
`,rM=v.span.attrs({role:"progressbar","aria-label":"読み込み中","aria-busy":!0})`
|
|
4615
4615
|
position: relative;
|
|
4616
4616
|
display: block;
|
|
4617
4617
|
overflow: hidden;
|
|
@@ -4632,21 +4632,21 @@ object-assign
|
|
|
4632
4632
|
}
|
|
4633
4633
|
|
|
4634
4634
|
&::before {
|
|
4635
|
-
animation: ${
|
|
4635
|
+
animation: ${tM} 2.1s cubic-bezier(0.65, 0.815, 0.735, 0.395)
|
|
4636
4636
|
infinite;
|
|
4637
4637
|
}
|
|
4638
4638
|
|
|
4639
4639
|
&::after {
|
|
4640
|
-
animation: ${
|
|
4640
|
+
animation: ${nM} 2.1s cubic-bezier(0.165, 0.84, 0.44, 1) 1.15s
|
|
4641
4641
|
infinite;
|
|
4642
4642
|
}
|
|
4643
|
-
`,
|
|
4643
|
+
`,iM=v.div`
|
|
4644
4644
|
border: 1px solid
|
|
4645
4645
|
${({theme:e,isFocused:t})=>t?e.palette.primary.base:e.palette.divider};
|
|
4646
4646
|
border-radius: ${({theme:e})=>e.radius}px;
|
|
4647
4647
|
display: flex;
|
|
4648
4648
|
background-color: ${({theme:e})=>e.palette.background.default};
|
|
4649
|
-
`,
|
|
4649
|
+
`,oM=v.div`
|
|
4650
4650
|
display: flex;
|
|
4651
4651
|
align-items: center;
|
|
4652
4652
|
flex-wrap: wrap;
|
|
@@ -4658,48 +4658,48 @@ object-assign
|
|
|
4658
4658
|
flex-grow: 1;
|
|
4659
4659
|
margin-bottom: 8px;
|
|
4660
4660
|
}
|
|
4661
|
-
`,
|
|
4661
|
+
`,aM=v.div`
|
|
4662
4662
|
padding-left: 8px;
|
|
4663
4663
|
margin-bottom: 8px;
|
|
4664
|
-
`,
|
|
4664
|
+
`,lM=v.div`
|
|
4665
4665
|
display: flex;
|
|
4666
4666
|
justify-content: center;
|
|
4667
4667
|
align-items: center;
|
|
4668
4668
|
padding-left: 8px;
|
|
4669
4669
|
flex-grow: 0;
|
|
4670
|
-
`,
|
|
4670
|
+
`,sM=v.div`
|
|
4671
4671
|
padding-top: 8px;
|
|
4672
4672
|
padding-bottom: 8px;
|
|
4673
4673
|
flex-grow: 1;
|
|
4674
4674
|
min-height: 40px;
|
|
4675
4675
|
display: flex;
|
|
4676
4676
|
align-items: center;
|
|
4677
|
-
`,
|
|
4677
|
+
`,cM=v.div`
|
|
4678
4678
|
flex-grow: 0;
|
|
4679
4679
|
display: flex;
|
|
4680
4680
|
align-items: center;
|
|
4681
4681
|
padding-right: 19px;
|
|
4682
|
-
`,
|
|
4682
|
+
`,dM=v.div``,uM=v(lm)`
|
|
4683
4683
|
box-shadow: ${({theme:e})=>No(5,e.palette.action.shadowOpacity,e.palette.action.shadowBase)};
|
|
4684
4684
|
min-width: 300px;
|
|
4685
4685
|
width: ${({width:e})=>e};
|
|
4686
4686
|
border-radius: ${({theme:e})=>`${e.radius}px`};
|
|
4687
4687
|
background-color: ${({theme:e})=>e.palette.background.default};
|
|
4688
|
-
`,
|
|
4688
|
+
`,pM=v.div`
|
|
4689
4689
|
display: flex;
|
|
4690
4690
|
justify-content: space-between;
|
|
4691
4691
|
align-items: center;
|
|
4692
4692
|
padding: ${({theme:e})=>2*e.spacing}px
|
|
4693
4693
|
${({theme:e})=>3*e.spacing}px;
|
|
4694
4694
|
border-bottom: 1px solid ${({theme:e})=>e.palette.neutral.lighter};
|
|
4695
|
-
`,pM=v.div`
|
|
4696
|
-
cursor: pointer;
|
|
4697
4695
|
`,mM=v.div`
|
|
4696
|
+
cursor: pointer;
|
|
4697
|
+
`,hM=v.div`
|
|
4698
4698
|
padding: ${({theme:e})=>2*e.spacing}px
|
|
4699
4699
|
${({theme:e})=>3*e.spacing}px;
|
|
4700
|
-
`,
|
|
4700
|
+
`,gM=v.div`
|
|
4701
4701
|
text-align: right;
|
|
4702
|
-
`,
|
|
4702
|
+
`,fM=v.div``,bM=v.div`
|
|
4703
4703
|
position: relative;
|
|
4704
4704
|
display: flex;
|
|
4705
4705
|
align-items: center;
|
|
@@ -4710,37 +4710,37 @@ object-assign
|
|
|
4710
4710
|
${({hasRightIcon:e})=>e?"padding-right: 32px":""};
|
|
4711
4711
|
${({hasLeftIcon:e})=>e?"padding-left: 35px":""};
|
|
4712
4712
|
}
|
|
4713
|
-
`,
|
|
4713
|
+
`,vM=v.div`
|
|
4714
4714
|
position: absolute;
|
|
4715
4715
|
top: 50%;
|
|
4716
4716
|
transform: translateY(-50%);
|
|
4717
4717
|
cursor: pointer;
|
|
4718
|
-
`,
|
|
4718
|
+
`,xM=v(vM)`
|
|
4719
4719
|
left: 10px;
|
|
4720
|
-
`,
|
|
4720
|
+
`,yM=v(vM)`
|
|
4721
4721
|
right: 10px;
|
|
4722
|
-
`,
|
|
4722
|
+
`,wM=e.forwardRef((function(t,n){var{errorText:r,icon:i,type:o,inputRef:a}=t,l=D(t,["errorText","icon","type","inputRef"]);Ae("TextField","TextField は非推奨です。代わりに Input(+必要なら ErrorText)を使用してください。");const[s,c]=e.useState(!1),d=ne(),u=()=>{c(!s)};return e.createElement(fM,{ref:n},e.createElement(bM,{hasLeftIcon:null!=i,hasRightIcon:"password"===o},null!=i&&e.createElement(xM,{onClick:u},e.createElement(le,{name:i,size:"md",color:d.palette.neutral.base})),e.createElement(va,Object.assign({ref:a},l,{error:!!r,type:s?"text":o})),"password"===o&&e.createElement(yM,{onClick:u},e.createElement(le,{name:s?"eye":"eye_off",size:"md",color:d.palette.black}))),r&&e.createElement(Ua,{pt:1},e.createElement(nd,null,r)))})),CM=t=>{var n,r;const i=Cd({props:t,name:"FilterCard"}),{onClose:o,onApply:a,selectedFilterPack:l,applyButtonTitle:s="Apply",inputErrorText:c="Please input",formPlaceholder:d="search",width:u,currentReferredFilters:p,sectionTitle:m="Section",conditionTitle:h=""}=i,g=C(),f=(null!==(r=null===(n=null==l?void 0:l.filters)||void 0===n?void 0:n.length)&&void 0!==r?r:0)>1,[b,v]=e.useState(),[x,y]=e.useState(),[w,E]=e.useState(f||null==l?void 0:l.filters[0]),[I,k]=e.useState(""),M=null==l?void 0:l.filters.find((e=>e.filterName===(null==w?void 0:w.filterName))),$=null==l?void 0:l.filters.map((e=>({label:e.filterName,value:e.filterName}))),A=e=>{k(""),y(e.target.value)},L=e=>{e.target.value||k(c)},V=e=>{y(null==e?void 0:e.value)};return e.createElement(uM,{width:u},e.createElement(pM,null,e.createElement(ke,{weight:"bold",size:"xxl"},null==l?void 0:l.categoryName),e.createElement(Ua,{pr:2}),e.createElement(mM,{key:"close",onClick:o},e.createElement(le,{name:"close",size:"md",color:g.palette.black}))),e.createElement(hM,null,f&&e.createElement(e.Fragment,null,e.createElement(ke,{weight:"bold",size:"lg"},(null==l?void 0:l.sectionTitle)||m),e.createElement(Ua,{py:.5}),e.createElement(_x,{maxMenuHeight:250,options:(e=>{const t=p.map((e=>e.filterName));return null==e?void 0:e.filter((e=>!t.includes(e.label)))})($),autoFocus:!0,onChange:e=>{if(k(""),null===e)return v(void 0),y(void 0),void E(void 0);const t=null==l?void 0:l.filters.find((t=>t.filterName===e.value));v(null==t?void 0:t.filterName),E(t)}}),e.createElement(Ua,{py:1})),w&&e.createElement("div",null,e.createElement(ke,{weight:"bold",size:"lg"},(null==M?void 0:M.conditionTitle)||h),e.createElement(Ua,{py:.5}),M&&(t=>{switch(null==t?void 0:t.control.type){case"text":return e.createElement(wM,{placeholder:d,icon:"search",name:"condition",errorText:I,autoFocus:!0,onChange:A,onBlur:L});case"select":const n=null==t?void 0:t.control.options;return e.createElement(_x,{options:n.map((e=>({label:e,value:e}))),autoFocus:!0,onChange:V});case"boolean":return e.createElement("div",null,e.createElement(ay,{name:"condition",value:"true",autoFocus:!0,onChange:A,onBlur:L},"true"),e.createElement("br",null),e.createElement(ay,{name:"condition",value:"false",autoFocus:!0,onChange:A,onBlur:L},"false"))}})(M),e.createElement(Ua,{py:1})),e.createElement(Rh,{orientation:"horizontal",color:g.palette.neutral.softLight,my:2}),e.createElement(gM,null,e.createElement(cl,{size:"small",inline:!0,disabled:f&&!b||!x,onClick:()=>{const e={categoryName:null==l?void 0:l.categoryName,filterName:f?null==w?void 0:w.filterName:null==l?void 0:l.categoryName,filterType:null==w?void 0:w.control.type,filterCondition:x};a(e)}},s))))},EM=v(lm)`
|
|
4723
4723
|
box-shadow: 0px 0px 16px
|
|
4724
4724
|
${({theme:e})=>zo(e.palette.neutral.lighter,.4)};
|
|
4725
4725
|
min-width: 300px;
|
|
4726
4726
|
width: ${({width:e})=>e};
|
|
4727
4727
|
border-radius: ${({theme:e})=>`${e.radius}px`};
|
|
4728
4728
|
background-color: ${({theme:e})=>e.palette.background.default};
|
|
4729
|
-
`,
|
|
4729
|
+
`,IM=v.div`
|
|
4730
4730
|
display: flex;
|
|
4731
4731
|
justify-content: space-between;
|
|
4732
4732
|
align-items: center;
|
|
4733
4733
|
padding: ${({theme:e})=>2*e.spacing}px
|
|
4734
4734
|
${({theme:e})=>3*e.spacing}px;
|
|
4735
4735
|
border-bottom: 1px solid ${({theme:e})=>e.palette.neutral.lighter};
|
|
4736
|
-
`,IM=v.div`
|
|
4737
|
-
cursor: pointer;
|
|
4738
4736
|
`,kM=v.div`
|
|
4737
|
+
cursor: pointer;
|
|
4738
|
+
`,MM=v.div`
|
|
4739
4739
|
padding: ${({theme:e})=>2*e.spacing}px
|
|
4740
4740
|
${({theme:e})=>3*e.spacing}px;
|
|
4741
|
-
|
|
4741
|
+
`,$M=v.div`
|
|
4742
4742
|
text-align: right;
|
|
4743
|
-
|
|
4743
|
+
`,AM=t=>{var n,r;const i=Cd({props:t,name:"EditFilterCard"}),{onClose:o,onEdit:a,willEditFilter:l,selectedFilterPack:s,editButtonTitle:c="Edit",inputErrorText:d="Please input",formPlaceholder:u="search",sectionTitle:p="Section",conditionTitle:m="",width:h}=i,g=C(),[f,b]=e.useState(null==l?void 0:l.filterCondition),[v,x]=e.useState(""),y=null==s?void 0:s.filters.find((e=>e.filterName===(null==l?void 0:l.filterName))),w=e=>{x(""),b(e.target.value)},E=e=>{e.target.value||x(d)},I=e=>{b(null==e?void 0:e.value)};return e.createElement(EM,{width:h},e.createElement(IM,null,e.createElement(ke,{weight:"bold",size:"xxl"},null==l?void 0:l.categoryName),e.createElement(Ua,{pr:2}),e.createElement(kM,{key:"close",onClick:o},e.createElement(le,{name:"close",size:"md",color:g.palette.black}))),e.createElement(MM,null,(null!==(r=null===(n=null==s?void 0:s.filters)||void 0===n?void 0:n.length)&&void 0!==r?r:0)>1&&e.createElement(e.Fragment,null,e.createElement(ke,{weight:"bold",size:"lg"},(null==s?void 0:s.sectionTitle)||p),e.createElement(Ua,{py:.5}),e.createElement(wM,{readOnly:!0,value:null==l?void 0:l.filterName}),e.createElement(Ua,{py:1})),e.createElement(ke,{weight:"bold",size:"lg"},(null==y?void 0:y.conditionTitle)||m),e.createElement(Ua,{py:.5}),y&&(t=>{switch(null==t?void 0:t.control.type){case"text":return e.createElement(wM,{icon:"search",placeholder:u,name:"condition",value:f,errorText:v,onChange:w,onBlur:E});case"select":const n=null==t?void 0:t.control.options;return e.createElement(_x,{maxMenuHeight:250,options:n.map((e=>({label:e,value:e}))),defaultValue:{label:null==l?void 0:l.filterCondition,value:null==l?void 0:l.filterCondition},onChange:I});case"boolean":return e.createElement("div",null,e.createElement(ay,{name:"condition",value:"true",defaultChecked:"true"===(null==l?void 0:l.filterCondition),onChange:w},"true"),e.createElement("br",null),e.createElement(ay,{name:"condition",value:"false",defaultChecked:"false"===(null==l?void 0:l.filterCondition),onChange:w},"false"))}})(y),e.createElement(Ua,{py:1}),e.createElement(Rh,{orientation:"horizontal",color:g.palette.neutral.softLight,my:2}),e.createElement($M,null,e.createElement(cl,{size:"small",inline:!0,disabled:!f,onClick:()=>{const e={filterCondition:f,filterType:null==l?void 0:l.filterType,filterName:null==l?void 0:l.filterName,categoryName:null==l?void 0:l.categoryName};a(e)}},c))))},LM=0,VM=1,HM=2,OM=3,SM=v.div`
|
|
4744
4744
|
padding: 2px 8px;
|
|
4745
4745
|
width: auto;
|
|
4746
4746
|
height: auto;
|
|
@@ -4756,40 +4756,40 @@ object-assign
|
|
|
4756
4756
|
cursor: pointer;
|
|
4757
4757
|
background-color: ${({theme:e})=>e.palette.neutral.softLight};
|
|
4758
4758
|
}
|
|
4759
|
-
`,
|
|
4759
|
+
`,DM=v.div`
|
|
4760
4760
|
display: flex;
|
|
4761
4761
|
justify-content: center;
|
|
4762
4762
|
align-items: center;
|
|
4763
|
-
`,
|
|
4763
|
+
`,RM=v.div`
|
|
4764
4764
|
padding-left: 8px;
|
|
4765
|
-
`,
|
|
4765
|
+
`,zM=v.div``,NM=({filter:t,onRemove:n,onClick:r})=>{const i=ne();return e.createElement(SM,null,e.createElement(DM,{onClick:e=>{r(e,t)}},e.createElement(ke,{size:"sm",component:"span"},t.filterName,": "),e.createElement(ke,{size:"sm",component:"span",weight:"bold"},"boolean"==typeof(o=t.filterCondition)?o?"Yes":"No":o)),e.createElement(RM,null,e.createElement(zM,{onClick:()=>{n(t)}},e.createElement(le,{name:"close_circle",color:i.palette.black,type:"fill"}))));var o},TM=e.forwardRef((function(t,n){Ae("MultipleFilter","MultipleFilter は非推奨です。代わりに AdvancedFilter を使用してください。");const r=Cd({props:t,name:"MultipleFilter"}),{filterPacks:i,onChange:o,placeholder:a="Add a new filter",editButtonTitle:l,applyButtonTitle:s,inputErrorText:c,formPlaceholder:d,width:u}=r,[p,m]=e.useState(!1),[h,g]=e.useState(null),f=ne(),[b,v]=e.useState(null),[x,y]=e.useState(null),[w,C]=e.useState(null),E=((e,t,n)=>e?n?OM:null===t?VM:null!==t?HM:LM:LM)(p,h,w),[I,k]=e.useState([]),M=()=>{g(null),m(!1),C(null)},$=e=>{const t=I.filter((t=>t.filterName!==e.filterName));k(t),void 0!==o&&o(t)},A=(e,t)=>{const n=null==i?void 0:i.find((e=>e.categoryName===t.categoryName));n&&(1===n.filters.length&&(n.filters[0].filterName=n.categoryName),y(e.currentTarget),m(!0),g(n),C(t))};return e.createElement(e.Fragment,null,e.createElement(iM,{ref:n,isFocused:E!==LM},e.createElement(lM,null,e.createElement(le,{name:"search",size:"md",color:f.palette.neutral.base})),e.createElement(sM,null,e.createElement(oM,null,I.map((t=>e.createElement(aM,{key:t.filterName},e.createElement(NM,{filter:t,onRemove:$,onClick:A})))),e.createElement(va,{ref:v,readOnly:!0,type:"text",placeholder:a,onClick:()=>{m(!0)}})),E===VM&&e.createElement(Bh,{baseElement:b},e.createElement(Ph,{contents:null==i?void 0:i.filter((e=>e.filters.length!==I.filter((t=>t.categoryName===e.categoryName)).length)).map((e=>{return{onClick:(t=e,()=>{g(t)}),text:e.categoryName};var t})),baseElement:b,onClose:(e,t)=>{"backdropClick"===t&&m(!1)}}))),e.createElement(cM,null,0!==I.length&&e.createElement(dM,{onClick:()=>{k([]),void 0!==o&&o([])}},e.createElement(le,{name:"close_circle",color:f.palette.black,type:"fill"})))),E===HM&&e.createElement(Bh,{baseElement:b,positionPriority:["bottom-start"],onClose:M},e.createElement(CM,{applyButtonTitle:s,currentReferredFilters:I,selectedFilterPack:null==i?void 0:i.find((e=>e.categoryName===(null==h?void 0:h.categoryName))),inputErrorText:c,formPlaceholder:d,width:u,onApply:e=>{const t=I.concat([e]);k(t),void 0!==o&&o(t),g(null),m(!1)},onClose:M})),E===OM&&e.createElement(Bh,{baseElement:x,positionPriority:["bottom-start"],onClose:M},e.createElement(AM,{editButtonTitle:l,willEditFilter:w,selectedFilterPack:null==i?void 0:i.find((e=>e.categoryName===(null==w?void 0:w.categoryName))),inputErrorText:c,formPlaceholder:d,width:u,onEdit:e=>{const t=I.findIndex((t=>t.filterName===e.filterName));I[t].filterCondition!==e.filterCondition&&k((n=>{const r=[...n];return r[t]=e,null==o||o(r),r})),m(!1),g(null),C(null)},onClose:M})))})),ZM="64px",BM="256px",PM="72px",_M="72px",GM="56px",jM="56px",FM=.3,YM=v.div`
|
|
4766
4766
|
position: fixed;
|
|
4767
4767
|
display: flex;
|
|
4768
4768
|
flex-direction: column;
|
|
4769
4769
|
justify-content: ${({isMobile:e})=>e?"flex-start":"space-between"};
|
|
4770
4770
|
height: 100%;
|
|
4771
|
-
width: ${({isOpen:e,isFixed:t})=>e||t?ZM
|
|
4771
|
+
width: ${({isOpen:e,isFixed:t})=>e||t?BM:ZM};
|
|
4772
4772
|
background-color: ${({theme:e})=>e.palette.background.default};
|
|
4773
4773
|
border-right: ${({theme:e,isOpen:t,isFixed:n})=>t&&!n?"none":`1px solid ${e.palette.neutral.softLight}`};
|
|
4774
4774
|
box-shadow: ${({isOpen:e,isFixed:t,theme:n})=>e&&!t?`0px 0px ${2*n.spacing}px ${zo(n.palette.neutral.base,4*n.palette.action.shadowOpacity)}`:"none"};
|
|
4775
4775
|
box-sizing: content-box;
|
|
4776
4776
|
overflow-x: hidden;
|
|
4777
4777
|
z-index: ${({theme:e})=>e.depth.drawer};
|
|
4778
|
-
transition: width ${
|
|
4778
|
+
transition: width ${FM}s;
|
|
4779
4779
|
|
|
4780
4780
|
/* Mobile styles */
|
|
4781
4781
|
@media (max-width: ${F.MOBILE}px) {
|
|
4782
|
-
width: ${
|
|
4782
|
+
width: ${BM};
|
|
4783
4783
|
right: 0;
|
|
4784
4784
|
transform: translateX(
|
|
4785
4785
|
${({isMobileMenuOpen:e})=>e?"0":"100%"}
|
|
4786
4786
|
);
|
|
4787
|
-
transition: transform ${
|
|
4787
|
+
transition: transform ${FM}s;
|
|
4788
4788
|
border-right: none;
|
|
4789
4789
|
border-left: 1px solid ${({theme:e})=>e.palette.neutral.softLight};
|
|
4790
4790
|
box-shadow: ${({isMobileMenuOpen:e,theme:t})=>e?`-4px 0px ${2*t.spacing}px ${zo(t.palette.neutral.base,4*t.palette.action.shadowOpacity)}`:"none"};
|
|
4791
4791
|
}
|
|
4792
|
-
`,
|
|
4792
|
+
`,WM=v.div`
|
|
4793
4793
|
position: fixed;
|
|
4794
4794
|
top: 0;
|
|
4795
4795
|
left: 0;
|
|
@@ -4800,18 +4800,18 @@ object-assign
|
|
|
4800
4800
|
opacity: ${({isVisible:e})=>e?1:0};
|
|
4801
4801
|
visibility: ${({isVisible:e})=>e?"visible":"hidden"};
|
|
4802
4802
|
transition:
|
|
4803
|
-
opacity ${
|
|
4804
|
-
visibility ${
|
|
4803
|
+
opacity ${FM}s,
|
|
4804
|
+
visibility ${FM}s;
|
|
4805
4805
|
display: none;
|
|
4806
4806
|
|
|
4807
4807
|
@media (max-width: ${F.MOBILE}px) {
|
|
4808
4808
|
display: block;
|
|
4809
4809
|
}
|
|
4810
|
-
`;function
|
|
4810
|
+
`;function XM(){return c(JM)}const JM=e.createContext({isOpen:!1,isFixed:!1,isMobile:!1,isMobileMenuOpen:!1,notificationCount:0,slotNotificationCount:0}),UM=v.div`
|
|
4811
4811
|
display: flex;
|
|
4812
4812
|
width: 100vw;
|
|
4813
4813
|
height: 100%;
|
|
4814
|
-
`,
|
|
4814
|
+
`,QM=v.div`
|
|
4815
4815
|
position: fixed;
|
|
4816
4816
|
top: ${({theme:e})=>2*e.spacing}px;
|
|
4817
4817
|
right: ${({theme:e})=>2*e.spacing}px;
|
|
@@ -4821,7 +4821,7 @@ object-assign
|
|
|
4821
4821
|
@media (max-width: ${F.MOBILE}px) {
|
|
4822
4822
|
display: block;
|
|
4823
4823
|
}
|
|
4824
|
-
`,
|
|
4824
|
+
`,qM=v.div`
|
|
4825
4825
|
position: relative;
|
|
4826
4826
|
display: inline-flex;
|
|
4827
4827
|
align-items: center;
|
|
@@ -4829,13 +4829,13 @@ object-assign
|
|
|
4829
4829
|
flex-shrink: 0;
|
|
4830
4830
|
vertical-align: middle;
|
|
4831
4831
|
line-height: 0;
|
|
4832
|
-
`,
|
|
4832
|
+
`,KM=v.div`
|
|
4833
4833
|
display: flex;
|
|
4834
4834
|
width: 100%;
|
|
4835
4835
|
align-items: center;
|
|
4836
4836
|
justify-content: space-between;
|
|
4837
4837
|
gap: 4px;
|
|
4838
|
-
`,
|
|
4838
|
+
`,e$=v.span`
|
|
4839
4839
|
display: inline-flex;
|
|
4840
4840
|
align-items: center;
|
|
4841
4841
|
justify-content: center;
|
|
@@ -4847,7 +4847,7 @@ object-assign
|
|
|
4847
4847
|
transform: ${({invisible:e,position:t,$overlayOffsetPercent:n})=>e?"scale(0)":`scale(1) translate(${((e,t)=>{const n=`${t}%`;return`${["top-right","bottom-right"].includes(e)?n:`-${n}`}, ${["bottom-right","bottom-left"].includes(e)?n:`-${n}`}`})(t,n)})`};
|
|
4848
4848
|
transform-origin: ${({position:e})=>`${["top-right","bottom-right"].includes(e)?"100%":"0%"} ${["bottom-right","bottom-left"].includes(e)?"100%":"0%"}`};
|
|
4849
4849
|
transition: transform 0.3s;
|
|
4850
|
-
`,
|
|
4850
|
+
`,t$=v.span`
|
|
4851
4851
|
display: block;
|
|
4852
4852
|
border-radius: 50%;
|
|
4853
4853
|
background-color: ${({theme:e})=>e.palette.danger.base};
|
|
@@ -4855,12 +4855,12 @@ object-assign
|
|
|
4855
4855
|
height: ${({size:e})=>e};
|
|
4856
4856
|
transform: ${({invisible:e})=>e?"scale(0)":"scale(1)"};
|
|
4857
4857
|
transition: transform 0.3s;
|
|
4858
|
-
`,
|
|
4858
|
+
`,n$={small:"8px",medium:"12px",large:"16px"},r$=e.forwardRef((function({variant:t="normal",badgeContent:n="",position:r="top-right",overlayOffsetPercent:i=50,dotSize:o="medium",max:a=99,showZero:l=!1,invisible:s=!1,layout:c="overlay",color:d="danger",fontWeight:u="normal",fontSize:p,size:m="small",children:h},g){let f=s;(0===n&&!l||""===n&&"dot"!==t)&&(f=!0);let b="";return"dot"!==t&&(b="number"==typeof n&&n>a?`${a}+`:n),"inline"===c&&"normal"===t?e.createElement(KM,{ref:g},h,f?null:e.createElement(jd,{type:"pill",color:d,fontWeight:u,fontSize:p,size:m},b)):e.createElement(qM,{ref:g},h,e.createElement(e$,{position:r,invisible:f,$overlayOffsetPercent:i},"dot"===t?e.createElement(t$,{size:n$[o],invisible:f}):e.createElement(jd,{type:"pill",color:d,fontWeight:u,fontSize:p,size:m},b)))})),i$=t.forwardRef((function(e,n){const{isMobile:r,isMobileMenuOpen:i,handleMobileMenuToggle:o,notificationCount:a}=XM();if(!r||i)return null;const l=t.createElement(cl,{ref:n,color:"clear",size:"medium","aria-label":"メニューを開く",icon:t.createElement(le,{name:"menu",color:"currentColor"}),onClick:o});return a>0?t.createElement(r$,{variant:"dot",dotSize:"small",position:"top-right",overlayOffsetPercent:10},l):l})),o$=`(max-width: ${F.MOBILE}px)`,a$=t.forwardRef((function({defaultFixed:e=!1,onChangeOpen:n,onChangeFixed:r,notificationCount:i=0,slotNotificationCount:o=0,showMobileMenuButton:a=!0,children:l},s){const[c,d]=t.useState(e),[u,p]=t.useState(e),m=Lo(o$),[h,g]=t.useState(!1),[f,b]=t.useState(0),v=t.useCallback((()=>{b((e=>e+1))}),[]),x=t.useCallback((()=>{b((e=>Math.max(0,e-1)))}),[]),y=a&&0===f&&m&&!h;return t.createElement(JM.Provider,{value:{isOpen:c,isFixed:u,handleOpen:()=>{u||(d(!0),n&&n(!0))},handleClose:()=>{u||(d(!1),n&&n(!1))},handleFixed:()=>{d(!0),p(!0),r&&r(!0)},handleUnFixed:()=>{d(!1),p(!1),r&&r(!1)},isMobile:m,isMobileMenuOpen:h,handleMobileMenuToggle:()=>{g((e=>!e))},registerMobileMenuButton:v,unregisterMobileMenuButton:x,notificationCount:i,slotNotificationCount:o}},t.createElement(UM,{ref:s},l,y&&t.createElement(QM,null,t.createElement(i$,null))))})),l$=v.div`
|
|
4859
4859
|
flex-shrink: 0;
|
|
4860
|
-
flex-basis: ${
|
|
4860
|
+
flex-basis: ${PM};
|
|
4861
4861
|
display: flex;
|
|
4862
4862
|
align-items: center;
|
|
4863
|
-
`,
|
|
4863
|
+
`,s$=v.div`
|
|
4864
4864
|
flex-grow: 1;
|
|
4865
4865
|
overflow-x: hidden;
|
|
4866
4866
|
overflow-y: auto;
|
|
@@ -4868,9 +4868,9 @@ object-assign
|
|
|
4868
4868
|
& * {
|
|
4869
4869
|
text-decoration: none;
|
|
4870
4870
|
}
|
|
4871
|
-
`,
|
|
4871
|
+
`,c$=v.div`
|
|
4872
4872
|
flex-shrink: 0;
|
|
4873
|
-
flex-basis: ${
|
|
4873
|
+
flex-basis: ${_M};
|
|
4874
4874
|
display: flex;
|
|
4875
4875
|
align-items: center;
|
|
4876
4876
|
border-top: 1px solid ${({theme:e})=>e.palette.neutral.softLight};
|
|
@@ -4878,19 +4878,19 @@ object-assign
|
|
|
4878
4878
|
@media (max-width: ${F.MOBILE}px) {
|
|
4879
4879
|
display: none;
|
|
4880
4880
|
}
|
|
4881
|
-
`,
|
|
4882
|
-
padding-left: ${({isFixed:e})=>e?ZM
|
|
4881
|
+
`,d$=v.div`
|
|
4882
|
+
padding-left: ${({isFixed:e})=>e?BM:ZM};
|
|
4883
4883
|
width: 100%;
|
|
4884
4884
|
height: 100%;
|
|
4885
|
-
transition: padding-left ${
|
|
4885
|
+
transition: padding-left ${FM}s;
|
|
4886
4886
|
|
|
4887
4887
|
@media (max-width: ${F.MOBILE}px) {
|
|
4888
4888
|
padding-left: 0;
|
|
4889
4889
|
}
|
|
4890
|
-
`,
|
|
4890
|
+
`,u$=t.forwardRef((function({children:e},n){const{isFixed:r}=t.useContext(JM);return t.createElement(d$,{ref:n,isFixed:r},e)})),p$=v.span`
|
|
4891
4891
|
display: inline-flex;
|
|
4892
4892
|
line-height: 0;
|
|
4893
|
-
`,
|
|
4893
|
+
`,m$=t.forwardRef((function({labelFixtureTooltip:e=(e=>(e?"Unfix":"Fix")+" the side menu")},n){const r=ne(),{isOpen:i,isFixed:o,isMobile:a,handleFixed:l,handleUnFixed:s,slotNotificationCount:c}=t.useContext(JM),d=e(o),u=!a&&!i&&!o&&c>0,p=t.useCallback((()=>{o?null==s||s():null==l||l()}),[o,l,s]),m=t.createElement(cl,{ref:n,isQuiet:!0,color:"clear",size:"medium","aria-label":d,icon:t.createElement(le,{name:o?"sidebar_fold":"sidebar_unfold",color:"currentColor"}),onClick:p});return t.createElement(Sc,{key:o?"fixed":"unfixed",content:d,positionPriority:["right"],offset:[0,2.5*r.spacing],enterDelay:FM},t.createElement(p$,null,u?t.createElement(r$,{variant:"dot",dotSize:"small",position:"top-right",overlayOffsetPercent:10},m):m))})),h$=v.div`
|
|
4894
4894
|
cursor: pointer;
|
|
4895
4895
|
display: flex;
|
|
4896
4896
|
align-items: center;
|
|
@@ -4905,7 +4905,7 @@ object-assign
|
|
|
4905
4905
|
& > * {
|
|
4906
4906
|
flex-shrink: 0;
|
|
4907
4907
|
}
|
|
4908
|
-
`,
|
|
4908
|
+
`,g$=v.div`
|
|
4909
4909
|
flex-shrink: 1;
|
|
4910
4910
|
flex-grow: 1;
|
|
4911
4911
|
display: flex;
|
|
@@ -4913,14 +4913,14 @@ object-assign
|
|
|
4913
4913
|
margin-left: ${({theme:e})=>1.5*e.spacing}px;
|
|
4914
4914
|
min-width: 0;
|
|
4915
4915
|
overflow: hidden;
|
|
4916
|
-
transition: opacity ${
|
|
4916
|
+
transition: opacity ${FM}s;
|
|
4917
4917
|
|
|
4918
4918
|
${({isOpen:e})=>e?y`
|
|
4919
4919
|
opacity: 1;
|
|
4920
4920
|
`:y`
|
|
4921
4921
|
display: none;
|
|
4922
4922
|
`}
|
|
4923
|
-
`,
|
|
4923
|
+
`,f$=v(ke)`
|
|
4924
4924
|
white-space: nowrap;
|
|
4925
4925
|
overflow: hidden;
|
|
4926
4926
|
text-overflow: ellipsis;
|
|
@@ -4931,7 +4931,7 @@ object-assign
|
|
|
4931
4931
|
& > * + * {
|
|
4932
4932
|
margin-left: ${({theme:e})=>.5*e.spacing}px;
|
|
4933
4933
|
}
|
|
4934
|
-
`;const
|
|
4934
|
+
`;const b$=v.span`
|
|
4935
4935
|
display: flex;
|
|
4936
4936
|
align-items: center;
|
|
4937
4937
|
align-content: center;
|
|
@@ -4951,7 +4951,7 @@ object-assign
|
|
|
4951
4951
|
${({invisible:e})=>e&&y`
|
|
4952
4952
|
display: none;
|
|
4953
4953
|
`}
|
|
4954
|
-
`,
|
|
4954
|
+
`,v$=({notificationCount:t=0,invisible:n=!1,style:r})=>{const i=t>=100?"99+":t;return e.createElement(b$,{invisible:n,style:r},i)},x$=e.forwardRef((function(t,n){var{title:r,isActive:i=!1,iconName:o,notificationCount:a=0,badge:l}=t,s=D(t,["title","isActive","iconName","notificationCount","badge"]);const c=ne(),{isOpen:d,isMobile:u,isMobileMenuOpen:p}=e.useContext(JM),m=void 0!==l,h=a>0,g=u?p:d;return e.createElement(h$,Object.assign({ref:n,isActive:i,$isMenuExpanded:g,"aria-current":i?"page":void 0},s),h?e.createElement(r$,{badgeContent:a,position:"top-left",invisible:g},e.createElement(le,{name:o,size:"lg",type:i?"fill":"line",color:i?"active":c.palette.black})):e.createElement(le,{name:o,size:"lg",type:i?"fill":"line",color:i?"active":c.palette.black}),e.createElement(g$,{isOpen:u?p:d},e.createElement(f$,{component:"span",color:i?"primary":"initial",weight:"bold",size:"sm"},r)),m&&(u?p:d)&&e.createElement(jd,Object.assign({},l,{size:l.size||"small"})),h&&e.createElement(v$,{notificationCount:a,invisible:0===a||!(u?p:d),style:{marginLeft:m&&(u?p:d)?"4px":"0"}}))})),y$=v.div`
|
|
4955
4955
|
cursor: pointer;
|
|
4956
4956
|
display: flex;
|
|
4957
4957
|
align-items: center;
|
|
@@ -4966,7 +4966,7 @@ object-assign
|
|
|
4966
4966
|
& > * {
|
|
4967
4967
|
flex-shrink: 0;
|
|
4968
4968
|
}
|
|
4969
|
-
`,
|
|
4969
|
+
`,w$=v.div`
|
|
4970
4970
|
flex-shrink: 1;
|
|
4971
4971
|
flex-grow: 1;
|
|
4972
4972
|
display: flex;
|
|
@@ -4974,18 +4974,18 @@ object-assign
|
|
|
4974
4974
|
margin-left: ${({theme:e})=>1.5*e.spacing}px;
|
|
4975
4975
|
min-width: 0;
|
|
4976
4976
|
overflow: hidden;
|
|
4977
|
-
transition: opacity ${
|
|
4977
|
+
transition: opacity ${FM}s;
|
|
4978
4978
|
|
|
4979
4979
|
${({isOpen:e})=>e?y`
|
|
4980
4980
|
opacity: 1;
|
|
4981
4981
|
`:y`
|
|
4982
4982
|
display: none;
|
|
4983
4983
|
`}
|
|
4984
|
-
`,
|
|
4984
|
+
`,C$=v(ke)`
|
|
4985
4985
|
white-space: nowrap;
|
|
4986
4986
|
overflow: hidden;
|
|
4987
4987
|
text-overflow: ellipsis;
|
|
4988
|
-
`,
|
|
4988
|
+
`,E$=v.div`
|
|
4989
4989
|
flex-shrink: 0;
|
|
4990
4990
|
margin-right: ${({theme:e})=>e.spacing}px;
|
|
4991
4991
|
transform: rotate(${({isExpand:e})=>e?"180deg":"none"});
|
|
@@ -4996,12 +4996,12 @@ object-assign
|
|
|
4996
4996
|
`:y`
|
|
4997
4997
|
display: none;
|
|
4998
4998
|
`}
|
|
4999
|
-
`,
|
|
4999
|
+
`,I$=v.div`
|
|
5000
5000
|
overflow-y: hidden;
|
|
5001
5001
|
max-height: ${({isExpand:e,height:t})=>e?t:"0px"};
|
|
5002
5002
|
transition: max-height 0.3s
|
|
5003
|
-
${({delay:e})=>e?
|
|
5004
|
-
`,
|
|
5003
|
+
${({delay:e})=>e?FM:0}s;
|
|
5004
|
+
`,k$=e.forwardRef((function(t,n){var{title:r,isActive:i=!1,iconName:o,expansionList:a=[],defaultExpand:l=!1,notificationCount:s=0,onChangeExpand:c,onClick:d}=t,u=D(t,["title","isActive","iconName","expansionList","defaultExpand","notificationCount","onChangeExpand","onClick"]);const p=ne(),{isOpen:m,isMobile:h,isMobileMenuOpen:g}=e.useContext(JM),[f,b]=e.useState(l),[v,x]=e.useState(!1),[y,w]=e.useState("auto"),C=e.useRef(null),E=m||h&&g;return e.useEffect((()=>{x(E)}),[E]),e.useEffect((()=>{x(!1),c&&c(f)}),[f,c]),e.useEffect((()=>{if(!C.current)return;const{height:e}=C.current.getBoundingClientRect();0!==e&&w(`${e}px`)}),[]),e.createElement("div",{ref:n},e.createElement(y$,Object.assign({isActive:i,$isMenuExpanded:E,onClick:e=>{0!==a.length&&b(!f),d&&d(e)}},u),e.createElement(r$,{badgeContent:s,position:"top-left"},e.createElement(le,{name:o,size:"lg",type:i?"fill":"line",color:i?"active":p.palette.black})),e.createElement(w$,{isOpen:E},e.createElement(C$,{component:"span",color:i?"primary":"initial",weight:"bold",size:"sm"},r)),e.createElement(E$,{isExpand:f,isOpen:E},e.createElement(le,{name:"arrow_bottom",color:i?"active":p.palette.black,size:"md"}))),e.createElement(I$,{ref:C,isExpand:f&&E||"auto"===y,height:y,delay:v},a.map(((t,n)=>e.createElement(e.Fragment,{key:n},t)))))})),M$=v.div`
|
|
5005
5005
|
cursor: pointer;
|
|
5006
5006
|
display: flex;
|
|
5007
5007
|
align-items: center;
|
|
@@ -5014,7 +5014,7 @@ object-assign
|
|
|
5014
5014
|
& > * {
|
|
5015
5015
|
flex-shrink: 0;
|
|
5016
5016
|
}
|
|
5017
|
-
|
|
5017
|
+
`,$$=v(ke)`
|
|
5018
5018
|
flex-shrink: 1;
|
|
5019
5019
|
flex-grow: 1;
|
|
5020
5020
|
display: flex;
|
|
@@ -5023,7 +5023,7 @@ object-assign
|
|
|
5023
5023
|
white-space: nowrap;
|
|
5024
5024
|
overflow: hidden;
|
|
5025
5025
|
text-overflow: ellipsis;
|
|
5026
|
-
|
|
5026
|
+
`,A$=e.forwardRef((function(t,n){var{title:r,isActive:i=!1,notificationCount:o=0,badge:a}=t,l=D(t,["title","isActive","notificationCount","badge"]);const s=ne();return e.createElement(M$,Object.assign({ref:n},l),e.createElement($$,{component:"div",weight:i?"bold":"normal",color:i?"primary":s.palette.black,size:"sm"},r),a&&e.createElement(jd,Object.assign({},a,{size:a.size||"small"})),e.createElement(v$,{notificationCount:o,invisible:0===o,style:{marginLeft:a?"4px":"0"}}))})),L$=v.div`
|
|
5027
5027
|
flex-shrink: 0;
|
|
5028
5028
|
display: none;
|
|
5029
5029
|
flex-direction: column;
|
|
@@ -5043,13 +5043,13 @@ object-assign
|
|
|
5043
5043
|
display: none;
|
|
5044
5044
|
}
|
|
5045
5045
|
`}
|
|
5046
|
-
`,
|
|
5046
|
+
`,V$=v.div`
|
|
5047
5047
|
display: none;
|
|
5048
5048
|
flex-shrink: 0;
|
|
5049
5049
|
align-items: center;
|
|
5050
5050
|
justify-content: ${({$hasLeadingActions:e})=>e?"space-between":"flex-end"};
|
|
5051
5051
|
gap: ${({theme:e})=>2*e.spacing}px;
|
|
5052
|
-
min-height: ${
|
|
5052
|
+
min-height: ${jM};
|
|
5053
5053
|
padding: ${({theme:e})=>1.5*e.spacing}px;
|
|
5054
5054
|
box-sizing: border-box;
|
|
5055
5055
|
|
|
@@ -5062,17 +5062,17 @@ object-assign
|
|
|
5062
5062
|
display: none;
|
|
5063
5063
|
}
|
|
5064
5064
|
`}
|
|
5065
|
-
`,
|
|
5065
|
+
`,H$=v.div`
|
|
5066
5066
|
display: flex;
|
|
5067
5067
|
flex-shrink: 0;
|
|
5068
5068
|
align-items: center;
|
|
5069
5069
|
gap: ${({theme:e})=>e.spacing}px;
|
|
5070
5070
|
min-width: 0;
|
|
5071
|
-
`,
|
|
5071
|
+
`,O$=v.div`
|
|
5072
5072
|
display: flex;
|
|
5073
5073
|
flex-shrink: 0;
|
|
5074
5074
|
align-items: center;
|
|
5075
|
-
`,
|
|
5075
|
+
`,S$=v.div`
|
|
5076
5076
|
flex-shrink: 0;
|
|
5077
5077
|
display: flex;
|
|
5078
5078
|
align-items: center;
|
|
@@ -5081,21 +5081,21 @@ object-assign
|
|
|
5081
5081
|
padding: 0 ${({theme:e})=>2*e.spacing}px;
|
|
5082
5082
|
border-bottom: 1px solid ${({theme:e})=>e.palette.neutral.softLight};
|
|
5083
5083
|
box-sizing: border-box;
|
|
5084
|
-
min-height: ${
|
|
5084
|
+
min-height: ${GM};
|
|
5085
5085
|
|
|
5086
5086
|
@media (max-width: ${F.MOBILE}px) {
|
|
5087
5087
|
align-items: flex-start;
|
|
5088
5088
|
padding: 0;
|
|
5089
5089
|
border-bottom: none;
|
|
5090
5090
|
}
|
|
5091
|
-
`,
|
|
5091
|
+
`,D$=v.div`
|
|
5092
5092
|
flex: 1;
|
|
5093
5093
|
min-width: 0;
|
|
5094
5094
|
display: flex;
|
|
5095
5095
|
align-items: center;
|
|
5096
5096
|
gap: ${({theme:e})=>2*e.spacing}px;
|
|
5097
5097
|
overflow: visible;
|
|
5098
|
-
transition: opacity ${
|
|
5098
|
+
transition: opacity ${FM}s;
|
|
5099
5099
|
|
|
5100
5100
|
${({$showCustom:e})=>!e&&y`
|
|
5101
5101
|
display: none;
|
|
@@ -5106,7 +5106,7 @@ object-assign
|
|
|
5106
5106
|
align-self: stretch;
|
|
5107
5107
|
width: 100%;
|
|
5108
5108
|
}
|
|
5109
|
-
`,
|
|
5109
|
+
`,R$=v.div`
|
|
5110
5110
|
flex-shrink: 0;
|
|
5111
5111
|
display: flex;
|
|
5112
5112
|
align-items: center;
|
|
@@ -5115,7 +5115,7 @@ object-assign
|
|
|
5115
5115
|
@media (max-width: ${F.MOBILE}px) {
|
|
5116
5116
|
display: none;
|
|
5117
5117
|
}
|
|
5118
|
-
`,
|
|
5118
|
+
`,z$=v.div`
|
|
5119
5119
|
display: flex;
|
|
5120
5120
|
align-items: center;
|
|
5121
5121
|
gap: inherit;
|
|
@@ -5140,20 +5140,20 @@ object-assign
|
|
|
5140
5140
|
width: 100%;
|
|
5141
5141
|
}
|
|
5142
5142
|
`}
|
|
5143
|
-
`,
|
|
5143
|
+
`,N$=t.forwardRef((function({children:e,actions:n,mobileLeadingActions:r},i){const{isOpen:o,isFixed:a,isMobile:l,handleMobileMenuToggle:s}=XM(),c=l||o||a,d=t.Children.count(e)>0,u=t.createElement(cl,{color:"clear",size:"medium","aria-label":"メニューを閉じる",icon:t.createElement(le,{name:"close",color:"currentColor"}),onClick:s}),p=l?u:null!=n?n:t.createElement(m$,null),m=t.createElement(D$,{$showCustom:c,"data-testid":"navigation-rail-slot-custom"},e),h=null!=r;return l?t.createElement(L$,{ref:i,"data-testid":"navigation-rail-slot",$showCustom:c},t.createElement(V$,{$showCustom:c,$hasLeadingActions:h,"data-testid":"navigation-rail-slot-mobile-close"},h?t.createElement(H$,{"data-testid":"navigation-rail-slot-mobile-leading"},r):null,t.createElement(O$,null,u)),d?t.createElement(S$,{$showCustom:c},m):null):t.createElement(S$,{ref:i,"data-testid":"navigation-rail-slot",$showCustom:c},m,t.createElement(R$,{$showCustom:c},p))})),T$=t.forwardRef((function({children:e,visibility:n="all"},r){return t.createElement(z$,{ref:r,$visibility:n,$passthrough:"all"===n},e)})),Z$="undefined"!=typeof window?t.useLayoutEffect:t.useEffect,B$=t.forwardRef((function(e,n){const{registerMobileMenuButton:r,unregisterMobileMenuButton:i}=XM();return Z$((()=>(null==r||r(),()=>null==i?void 0:i())),[r,i]),t.createElement(i$,{ref:n})}));function P$(e){let n=!1;return t.Children.forEach(e,(e=>{!n&&t.isValidElement(e)&&(e.type!==N$?e.type===t.Fragment&&(n=P$(e.props.children)):n=!0)})),n}const _$=t.forwardRef((function({children:e},n){const{isOpen:r,isFixed:i,handleOpen:o,handleClose:a,isMobile:l,isMobileMenuOpen:s,handleMobileMenuToggle:c}=t.useContext(JM),d=P$(e),u=l&&!d?t.createElement(N$,null):null;return t.createElement(t.Fragment,null,t.createElement(WM,{isVisible:l&&s,"data-testid":"navigation-rail-overlay",onClick:c}),t.createElement(YM,{ref:n,isOpen:r,isFixed:i,isMobile:l,isMobileMenuOpen:s,onMouseEnter:()=>{l||null==o||o()},onMouseLeave:()=>{l||null==a||a()}},u,e))}));_$.Container=a$,_$.Header=l$,_$.Content=s$,_$.Footer=c$,_$.Menu=x$,_$.ExpansionMenu=k$,_$.ExpansionMenuItem=A$,_$.Fixture=m$,_$.MainContent=u$,_$.Slot=N$,_$.SlotContent=T$,_$.MobileMenuButton=B$;const G$=e.forwardRef((function(t,n){var{title:r,description:i,slotContent:o,slotExpansion:a="whenChecked",disabled:l,error:s,checked:c,inputRef:d}=t,u=D(t,["title","description","slotContent","slotExpansion","disabled","error","checked","inputRef"]);const p=!!c,{controlWrapRef:m,assignInputRef:h,handleHeaderClick:g}=mh(l,d),f=e.createElement(dh,null,e.createElement(ch,{ref:m},e.createElement(ay,Object.assign({},u,{checked:c,disabled:l,error:s,inputRef:h}),r)),hh(i)?e.createElement(uh,{$disabled:!!l},i):null);return e.createElement(ph,{ref:n,checked:p,disabled:l,header:f,slot:o,slotExpansion:a,onHeaderClick:g})})),j$=new Set(["height","maxHeight","minHeight"]),F$=v.div.withConfig({shouldForwardProp:e=>!j$.has(e)})`
|
|
5144
5144
|
${({height:e,maxHeight:t,minHeight:n})=>Lh({height:e,maxHeight:t,minHeight:n})}
|
|
5145
|
-
`,
|
|
5145
|
+
`,Y$=e.forwardRef((function(t,n){var{height:r="auto",maxHeight:i="none",minHeight:o="none",children:a}=t,l=D(t,["height","maxHeight","minHeight","children"]);return e.createElement(F$,Object.assign({height:r,maxHeight:i,minHeight:o,tabIndex:0},l,{ref:n}),a)})),W$="24px",X$=v.div`
|
|
5146
5146
|
flex-direction: row;
|
|
5147
5147
|
width: 100%;
|
|
5148
|
-
min-height: ${
|
|
5148
|
+
min-height: ${W$};
|
|
5149
5149
|
display: flex;
|
|
5150
5150
|
align-items: center;
|
|
5151
5151
|
position: relative;
|
|
5152
5152
|
cursor: ${({disabled:e})=>e?"not-allowed":"default"};
|
|
5153
|
-
`,
|
|
5153
|
+
`,J$=v.div`
|
|
5154
5154
|
position: relative;
|
|
5155
5155
|
flex: 1;
|
|
5156
|
-
min-height: ${
|
|
5156
|
+
min-height: ${W$};
|
|
5157
5157
|
display: flex;
|
|
5158
5158
|
align-items: center;
|
|
5159
5159
|
min-width: 100px;
|
|
@@ -5171,7 +5171,7 @@ object-assign
|
|
|
5171
5171
|
background-color: ${({theme:e})=>e.palette.neutral.lighter};
|
|
5172
5172
|
pointer-events: none;
|
|
5173
5173
|
}
|
|
5174
|
-
`,
|
|
5174
|
+
`,U$=v.div`
|
|
5175
5175
|
position: absolute;
|
|
5176
5176
|
top: 50%;
|
|
5177
5177
|
left: 0;
|
|
@@ -5185,7 +5185,7 @@ object-assign
|
|
|
5185
5185
|
width: ${e}%;
|
|
5186
5186
|
left: ${t}%;
|
|
5187
5187
|
`}
|
|
5188
|
-
`,
|
|
5188
|
+
`,Q$=v.div`
|
|
5189
5189
|
position: absolute;
|
|
5190
5190
|
width: 18px;
|
|
5191
5191
|
height: 18px;
|
|
@@ -5205,7 +5205,7 @@ object-assign
|
|
|
5205
5205
|
left: ${e}%;
|
|
5206
5206
|
transform: translate(-50%, -50%);
|
|
5207
5207
|
`}
|
|
5208
|
-
`,
|
|
5208
|
+
`,q$=v.div`
|
|
5209
5209
|
position: absolute;
|
|
5210
5210
|
top: 0;
|
|
5211
5211
|
left: 0;
|
|
@@ -5215,7 +5215,7 @@ object-assign
|
|
|
5215
5215
|
z-index: 1;
|
|
5216
5216
|
display: flex;
|
|
5217
5217
|
justify-content: space-between;
|
|
5218
|
-
`,
|
|
5218
|
+
`,K$=v.div`
|
|
5219
5219
|
position: absolute;
|
|
5220
5220
|
display: flex;
|
|
5221
5221
|
flex-direction: column;
|
|
@@ -5226,7 +5226,7 @@ object-assign
|
|
|
5226
5226
|
top: 50%;
|
|
5227
5227
|
transform: translateY(-50%);
|
|
5228
5228
|
`}
|
|
5229
|
-
`,
|
|
5229
|
+
`,eA=v.div`
|
|
5230
5230
|
border-radius: 50%;
|
|
5231
5231
|
position: absolute;
|
|
5232
5232
|
top: 50%;
|
|
@@ -5236,32 +5236,32 @@ object-assign
|
|
|
5236
5236
|
|
|
5237
5237
|
width: 8px;
|
|
5238
5238
|
height: 8px;
|
|
5239
|
-
`,
|
|
5240
|
-
&.${
|
|
5241
|
-
transform: ${({direction:e})=>
|
|
5239
|
+
`,tA=(e,t,n)=>Math.max(t,Math.min(n,e)),nA=(e,t,n,r)=>void 0===e?r?[t,n]:t:Array.isArray(e)?[tA(e[0],t,n),tA(e[1],t,n)]:tA(e,t,n),rA=(e,t,n)=>(e-t)/(n-t)*100,iA=(e,t,n,r,i)=>{const o=n+(e-t.left)/t.width*100/100*(r-n),a=Math.round(o/i)*i;return tA(a,n,r)},oA=(e,t)=>{if(1===t.length)return 0;const[n,r]=t,i=Math.abs(e-n),o=Math.abs(e-r);if(i!==o)return i<o?0:1;return e>=(n+r)/2?1:0},aA=(e,t,n,r,i,o,a)=>{const l="PageUp"===t||"PageDown"===t?10*i:i;let s;if(o&&Array.isArray(e)){const i=null!=a?a:0,o=e[i];switch(t){case"ArrowLeft":case"ArrowDown":case"PageDown":s=tA(o-l,n,r);break;case"ArrowRight":case"ArrowUp":case"PageUp":s=tA(o+l,n,r);break;case"Home":s=n;break;case"End":s=r;break;default:return e}const c=[...e];return c[i]=s,0===i?c[0]=Math.min(s,c[1]):c[1]=Math.max(s,c[0]),c}{const i=Array.isArray(e)?e[0]:e;switch(t){case"ArrowLeft":case"ArrowDown":case"PageDown":s=tA(i-l,n,r);break;case"ArrowRight":case"ArrowUp":case"PageUp":s=tA(i+l,n,r);break;case"Home":s=n;break;case"End":s=r;break;default:return e}return s}},lA=()=>{document.body.style.userSelect="none"},sA=()=>{document.body.style.userSelect=""},cA=e=>{e.preventDefault()};function dA({value:t,defaultValue:n,onChange:r,min:i,max:o,step:a,disabled:l=!1}){const s=e.useCallback((e=>{const r=Array.isArray(t)||Array.isArray(n);return nA(e,i,o,r)}),[i,o,t,n]),[c,d]=e.useState(s(n)),[u,p]=e.useState(!1),[m,h]=e.useState(null),[g,f]=e.useState(new Map),[b,v]=e.useState(new Map),x=e.useRef(null),y=e.useRef(null);e.useEffect((()=>{if(void 0===t&&void 0!==n){const e=s(n);d(e)}}),[t,n,s]);const w=void 0!==t?t:c,C=e.useCallback((e=>{r?r(e):d(e)}),[r]),E=e.useCallback((e=>{if(!x.current)return i;const t=x.current.getBoundingClientRect();return iA(e,t,i,o,a)}),[i,o,a]),I=e.useCallback((e=>{if(l)return;e.preventDefault(),p(!0),lA(),document.addEventListener("wheel",cA,{passive:!1}),document.addEventListener("touchmove",cA,{passive:!1});const t=E(e.clientX);if(Array.isArray(w)){const e=oA(t,w);h(e);const n=[...w];n[e]=t,C(n)}else h(0),C(t)}),[l,E,w,C]),k=e.useCallback((e=>{if(!u||l)return;const t=E(e.clientX);if(Array.isArray(w)&&null!==m){const e=[...w];e[m]=t,0===m?e[0]=Math.min(t,e[1]):e[1]=Math.max(t,e[0]),C(e)}else Array.isArray(w)||C(t)}),[u,l,E,w,m,C]),M=e.useCallback((()=>{p(!1),h(null),sA(),document.removeEventListener("wheel",cA),document.removeEventListener("touchmove",cA)}),[]),$=e.useCallback((e=>{if(l)return;e.preventDefault(),p(!0),lA(),document.addEventListener("wheel",cA,{passive:!1}),document.addEventListener("touchmove",cA,{passive:!1});const t=new Map,n=new Map;Array.from(e.changedTouches).forEach((e=>{const r=E(e.clientX);if(t.set(e.identifier,e),Array.isArray(w)){const t=oA(r,w);n.set(e.identifier,t)}else n.set(e.identifier,0)})),f(t),v(n)}),[l,E,w]),A=e.useCallback((e=>{u&&!l&&(e.preventDefault(),Array.from(e.changedTouches).forEach((e=>{const t=b.get(e.identifier);if(void 0===t)return;const n=E(e.clientX);if(Array.isArray(w)){const e=[...w];e[t]=n,0===t?e[0]=Math.min(n,e[1]):e[1]=Math.max(n,e[0]),C(e)}else C(n)})))}),[u,l,E,w,b,C]),L=e.useCallback((e=>{const t=new Map(g),n=new Map(b);Array.from(e.changedTouches).forEach((e=>{t.delete(e.identifier),n.delete(e.identifier)})),f(t),v(n),0===t.size&&(p(!1),sA(),document.removeEventListener("wheel",cA),document.removeEventListener("touchmove",cA))}),[g,b]);return{currentValue:w,isDragging:u,trackRef:x,thumbRef:y,handleChange:C,handleMouseDown:I,handleMouseMove:k,handleMouseUp:M,handleTouchStart:$,handleTouchMove:A,handleTouchEnd:L}}function uA({showScale:t,min:n,max:r,step:i,currentValue:o}){const a=e.useCallback((()=>{if(!t)return[];const e=[];for(let t=n;t<=r;t+=i)e.push(t);return e}),[t,n,r,i]),l=e.useCallback((e=>Array.isArray(o)?e>=o[0]&&e<=o[1]:e<=o),[o]),s=e.useCallback((()=>{if(!t)return null;const i=a();return e.createElement(q$,{},i.map((t=>e.createElement(K$,{key:t,percentage:(t-n)/(r-n)*100},e.createElement(eA,{isOnFill:l(t)})))))}),[t,a,n,r,l]);return{getScaleValues:a,isScaleOnFill:l,renderScale:s}}let pA=0;const mA={min:0,max:100,step:1,disabled:!1,showScale:!1},hA=e.forwardRef((function(t,n){var{value:r,defaultValue:i,onChange:o,min:a=mA.min,max:l=mA.max,step:s=mA.step,disabled:c=mA.disabled,showScale:d=mA.showScale,id:u,className:p,style:m,"aria-label":h,"aria-labelledby":g,"aria-describedby":f}=t,b=D(t,["value","defaultValue","onChange","min","max","step","disabled","showScale","id","className","style","aria-label","aria-labelledby","aria-describedby"]);const v=ne(),x=e.useId(),y=e.useMemo((()=>"slider-"+ ++pA),[]),w=u||x||y,{currentValue:C,isDragging:E,trackRef:I,thumbRef:k,handleChange:M,handleMouseDown:$,handleMouseMove:A,handleMouseUp:L,handleTouchStart:V,handleTouchMove:H,handleTouchEnd:O}=dA({value:r,defaultValue:i,onChange:o,min:a,max:l,step:s,disabled:c}),{renderScale:S}=uA({showScale:d,min:a,max:l,step:s,currentValue:C}),R=e.useCallback((e=>rA(e,a,l)),[a,l]),z=e.useCallback((e=>{if(c)return;const t=Array.isArray(C),n=aA(C,e.key,a,l,s,t,null);n!==C&&(e.preventDefault(),M(n))}),[c,C,a,l,s,M]),N=e.useCallback((e=>{const t=parseFloat(e.target.value);if(Array.isArray(C)){const e=[...C];e[0]=t,M(e)}else M(t)}),[C,M]),T=e.useCallback((e=>{if(!Array.isArray(C))return;const t=parseFloat(e.target.value),n=[...C];n[0]=Math.min(t,n[1]),M(n)}),[C,M]),Z=e.useCallback((e=>{if(!Array.isArray(C))return;const t=parseFloat(e.target.value),n=[...C];n[1]=Math.max(t,n[0]),M(n)}),[C,M]);return e.useEffect((()=>{if(E){document.addEventListener("mousemove",A),document.addEventListener("mouseup",L),document.addEventListener("touchmove",H),document.addEventListener("touchend",O);const e=e=>e.preventDefault();return document.addEventListener("contextmenu",e),()=>{document.removeEventListener("mousemove",A),document.removeEventListener("mouseup",L),document.removeEventListener("touchmove",H),document.removeEventListener("touchend",O),document.removeEventListener("contextmenu",e)}}}),[E,A,L,H,O]),e.createElement(X$,Object.assign({ref:n,theme:v,disabled:c,className:p,style:m},b),e.createElement(J$,{ref:I,id:w,tabIndex:c?-1:0,role:"slider","aria-valuemin":a,"aria-valuemax":l,"aria-valuenow":Array.isArray(C)?C[0]:C,"aria-valuetext":Array.isArray(C)?`${C[0]} to ${C[1]}`:void 0,"aria-disabled":c,"aria-label":h,"aria-labelledby":g,"aria-describedby":f,onMouseDown:$,onTouchStart:V,onKeyDown:z},Array.isArray(C)?e.createElement(e.Fragment,null,e.createElement(U$,{percentage:R(C[1])-R(C[0]),isDragging:E,startPercentage:R(C[0]),disabled:c}),e.createElement(Q$,{ref:k,percentage:R(C[0]),isDragging:E,disabled:c}),e.createElement(Q$,{percentage:R(C[1]),isDragging:E,disabled:c})):e.createElement(e.Fragment,null,e.createElement(U$,{percentage:R(C),isDragging:E,disabled:c}),e.createElement(Q$,{ref:k,percentage:R(C),isDragging:E,disabled:c})),S()),Array.isArray(C)?e.createElement(e.Fragment,null,e.createElement("input",{type:"range",min:a,max:l,step:s,value:C[0],style:{position:"absolute",opacity:0,pointerEvents:"none",width:"1px",height:"1px",margin:"-1px",padding:0,border:"none",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap"},"aria-label":"Slider minimum value","aria-labelledby":g,"aria-describedby":f,disabled:c,onChange:T}),e.createElement("input",{type:"range",min:a,max:l,step:s,value:C[1],style:{position:"absolute",opacity:0,pointerEvents:"none",width:"1px",height:"1px",margin:"-1px",padding:0,border:"none",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap"},"aria-label":"Slider maximum value","aria-labelledby":g,"aria-describedby":f,disabled:c,onChange:Z})):e.createElement("input",{type:"range",min:a,max:l,step:s,value:C,style:{position:"absolute",opacity:0,pointerEvents:"none",width:"1px",height:"1px",margin:"-1px",padding:0,border:"none",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap"},"aria-label":"Slider input","aria-labelledby":g,"aria-describedby":f,disabled:c,onChange:N}))})),gA=s(null),fA=()=>{const e=c(gA);if(!e)throw new Error("SliderField components must be used within a SliderField");return e},bA=({children:e})=>{const n=r(),i={fieldId:n,sliderId:`${n}-slider`,outputId:`${n}-output`};return t.createElement(gA.Provider,{value:i},e)};bA.Slider=e=>{const{sliderId:n,outputId:r}=fA(),i=e.id||n,o=e["aria-describedby"]||r;return t.createElement(hA,Object.assign({},e,{id:i,"aria-describedby":o}))},bA.Output=e=>{var{children:n,id:r}=e,i=D(e,["children","id"]);const{outputId:o}=fA();return t.createElement("div",Object.assign({},i,{id:r||o}),n)};const vA=e=>{switch(e){case"down":default:return"translateY(100vh)";case"up":return"translateY(-100vh)";case"right":return"translateX(100vw)";case"left":return"translateX(-100vw)"}},xA="slide-transition",yA=v(uc)`
|
|
5240
|
+
&.${xA}-enter, &.${xA}-appear {
|
|
5241
|
+
transform: ${({direction:e})=>vA(e)};
|
|
5242
5242
|
}
|
|
5243
|
-
&.${
|
|
5243
|
+
&.${xA}-enter-active, &.${xA}-appear-active {
|
|
5244
5244
|
transform: none;
|
|
5245
5245
|
transition: transform ${({timeout:e})=>Mc(e,"enter")}ms;
|
|
5246
5246
|
}
|
|
5247
|
-
&.${
|
|
5247
|
+
&.${xA}-exit {
|
|
5248
5248
|
transform: none;
|
|
5249
5249
|
}
|
|
5250
|
-
&.${
|
|
5251
|
-
transform: ${({direction:e})=>
|
|
5250
|
+
&.${xA}-exit-active {
|
|
5251
|
+
transform: ${({direction:e})=>vA(e)};
|
|
5252
5252
|
transition: transform ${({timeout:e})=>Mc(e,"exit")}ms;
|
|
5253
5253
|
}
|
|
5254
|
-
&.${
|
|
5255
|
-
transform: ${({direction:e})=>
|
|
5254
|
+
&.${xA}-exit-done {
|
|
5255
|
+
transform: ${({direction:e})=>vA(e)};
|
|
5256
5256
|
}
|
|
5257
|
-
`,
|
|
5257
|
+
`,wA=t=>{var{timeout:n=300,children:r,direction:i="down"}=t,o=D(t,["timeout","children","direction"]);const a=e.useRef(null);return e.createElement(yA,Object.assign({nodeRef:a,appear:!0,timeout:n,direction:i,classNames:xA},o),e.createElement("div",{ref:a},r))},CA=v.div`
|
|
5258
5258
|
position: fixed;
|
|
5259
5259
|
left: ${({horizontal:e,theme:t})=>"left"===e?3*t.spacing+"px":"auto"};
|
|
5260
5260
|
right: ${({horizontal:e,theme:t})=>"right"===e?3*t.spacing+"px":"auto"};
|
|
5261
5261
|
top: ${({vertical:e,theme:t})=>"top"===e?3*t.spacing+"px":"auto"};
|
|
5262
5262
|
bottom: ${({vertical:e,theme:t})=>"bottom"===e?3*t.spacing+"px":"auto"};
|
|
5263
5263
|
z-index: ${({theme:e})=>e.depth.snackbar};
|
|
5264
|
-
`,
|
|
5264
|
+
`,EA=v.div`
|
|
5265
5265
|
position: relative;
|
|
5266
5266
|
min-width: 320px;
|
|
5267
5267
|
max-width: 400px;
|
|
@@ -5273,121 +5273,121 @@ object-assign
|
|
|
5273
5273
|
box-shadow: ${({boxShadow:e})=>e};
|
|
5274
5274
|
border-radius: ${({theme:e})=>e.radius}px;
|
|
5275
5275
|
color: ${({textColor:e})=>e||"inherit"};
|
|
5276
|
-
`,
|
|
5276
|
+
`,IA=v.div`
|
|
5277
5277
|
position: absolute;
|
|
5278
5278
|
top: ${({theme:e})=>e.spacing}px;
|
|
5279
5279
|
right: ${({theme:e})=>e.spacing}px;
|
|
5280
5280
|
cursor: pointer;
|
|
5281
|
-
`,
|
|
5281
|
+
`,kA=({color:t,onClose:n,children:r})=>{const i=(e=>({default:{iconColor:e.palette.black,boxShadow:No(5,e.palette.action.shadowOpacity,e.palette.action.shadowBase),background:e.palette.background.default},dark:{iconColor:e.palette.white,boxShadow:No(5,e.palette.action.shadowOpacity,e.palette.action.shadowBase),background:e.palette.black,textColor:e.palette.text.white},warning:{iconColor:e.palette.warning.ultraDark,boxShadow:No(5,e.palette.action.shadowOpacity,e.palette.warning.highlight),background:e.palette.warning.highlight}}))(ne())[t];return e.createElement(EA,Object.assign({},i),r,e.createElement(IA,{onClick:n},e.createElement(le,{name:"close",color:i.iconColor})))},MA=e.forwardRef((function({color:t="default",anchorOrigin:{vertical:n,horizontal:r}={vertical:"bottom",horizontal:"right"},isOpen:i,onClose:o,children:a},l){return i?e.createElement(CA,{ref:l,vertical:n,horizontal:r,role:"warning"===t?"alert":"status"},e.createElement(kA,{color:t,onClose:o},a)):null})),$A=v.div`
|
|
5282
5282
|
display: block;
|
|
5283
|
-
|
|
5283
|
+
`,AA=e.forwardRef((function(t,n){var{children:r}=t,i=D(t,["children"]);return e.createElement(de,Object.assign({ref:n,display:"flex"},i),e.createElement(Ua,{pr:1}),e.createElement(zh,{orientation:"vertical"}),e.createElement(Ua,{pr:1}),e.createElement($A,null,r))})),LA={small:{height:"28px",fontSize:"12px",padding:"0 4px",borderRadius:"4px",itemHeight:"20px",itemPadding:"0 4px",itemRadius:"2px",iconSize:"sm-md",iconItemWidth:"24px",gap:"4px"},medium:{height:"32px",fontSize:"12px",padding:"0 4px",borderRadius:"4px",itemHeight:"24px",itemPadding:"0 6px",itemRadius:"4px",iconSize:"sm-md",iconItemWidth:"24px",gap:"6px"},large:{height:"40px",fontSize:"13px",padding:"0 6px",borderRadius:"6px",itemHeight:"28px",itemPadding:"0 8px",itemRadius:"4px",iconSize:"md",iconItemWidth:"28px",gap:"8px"}},VA=e=>({light:{containerBackground:e.palette.background.default,indicatorBackground:e.palette.black,textColor:e.palette.black,textColorActive:e.palette.background.default,textColorDisabled:e.palette.text.disabled,iconColor:e.palette.black,iconColorActive:e.palette.background.default,iconColorDisabled:e.palette.neutral.lighter,borderColor:e.palette.divider,hoverBackground:e.palette.neutral.softLight},dark:{containerBackground:e.palette.neutral.ultraLight,indicatorBackground:e.palette.black,textColor:e.palette.black,textColorActive:e.palette.background.default,textColorDisabled:e.palette.text.disabled,iconColor:e.palette.black,iconColorActive:e.palette.background.default,iconColorDisabled:e.palette.neutral.lighter,borderColor:e.palette.divider,hoverBackground:e.palette.neutral.softLight},primary:{containerBackground:e.palette.primary.ultraLight,indicatorBackground:e.palette.primary.base,textColor:e.palette.primary.base,textColorActive:e.palette.background.default,textColorDisabled:e.palette.text.disabled,iconColor:e.palette.primary.base,iconColorActive:e.palette.background.default,iconColorDisabled:e.palette.neutral.lighter,borderColor:e.palette.primary.base,hoverBackground:e.palette.primary.highlight}}),HA=v.div`
|
|
5284
5284
|
display: inline-flex;
|
|
5285
5285
|
align-items: center;
|
|
5286
|
-
height: ${({$size:e})=>
|
|
5287
|
-
padding: ${({$size:e})=>
|
|
5288
|
-
border-radius: ${({$size:e})=>
|
|
5289
|
-
background-color: ${({$variant:e,theme:t,$disabled:n})=>{if(n)return t.palette.neutral.softLight;return
|
|
5286
|
+
height: ${({$size:e})=>LA[e].height};
|
|
5287
|
+
padding: ${({$size:e})=>LA[e].padding};
|
|
5288
|
+
border-radius: ${({$size:e})=>LA[e].borderRadius};
|
|
5289
|
+
background-color: ${({$variant:e,theme:t,$disabled:n})=>{if(n)return t.palette.neutral.softLight;return VA(t)[e].containerBackground}};
|
|
5290
5290
|
border: 1px solid
|
|
5291
|
-
${({$variant:e,theme:t,$disabled:n})=>{if(n)return t.palette.text.disabled;return
|
|
5291
|
+
${({$variant:e,theme:t,$disabled:n})=>{if(n)return t.palette.text.disabled;return VA(t)[e].borderColor}};
|
|
5292
5292
|
width: ${({$fullWidth:e,$width:t})=>e?"100%":t?`${isNaN(+t)?t:t+"px"}`:"auto"};
|
|
5293
5293
|
cursor: ${({$disabled:e})=>e?"not-allowed":"default"};
|
|
5294
5294
|
transition: all 0.3s ease-in-out;
|
|
5295
|
-
`,
|
|
5295
|
+
`,OA=v.div`
|
|
5296
5296
|
position: relative;
|
|
5297
5297
|
width: 100%;
|
|
5298
|
-
`,
|
|
5298
|
+
`,SA=v.div`
|
|
5299
5299
|
position: relative;
|
|
5300
5300
|
width: 100%;
|
|
5301
5301
|
white-space: nowrap;
|
|
5302
5302
|
display: flex;
|
|
5303
5303
|
align-items: center;
|
|
5304
|
-
gap: ${({$size:e})=>
|
|
5304
|
+
gap: ${({$size:e})=>LA[e].gap};
|
|
5305
5305
|
${({$fullWidth:e})=>e&&"\n & > * {\n flex: 1;\n }\n "}
|
|
5306
|
-
`,
|
|
5306
|
+
`,DA=v.div`
|
|
5307
5307
|
display: inline-flex;
|
|
5308
5308
|
align-items: center;
|
|
5309
5309
|
justify-content: center;
|
|
5310
|
-
width: ${({$size:e})=>
|
|
5311
|
-
height: ${({$size:e})=>
|
|
5312
|
-
border-radius: ${({$size:e})=>
|
|
5310
|
+
width: ${({$size:e})=>LA[e].iconItemWidth};
|
|
5311
|
+
height: ${({$size:e})=>LA[e].itemHeight};
|
|
5312
|
+
border-radius: ${({$size:e})=>LA[e].itemRadius};
|
|
5313
5313
|
cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
|
|
5314
5314
|
transition: all 0.3s ease-in-out;
|
|
5315
5315
|
background-color: transparent;
|
|
5316
5316
|
|
|
5317
5317
|
@media (any-hover: hover) {
|
|
5318
5318
|
&:hover:not([data-disabled="true"]) {
|
|
5319
|
-
background-color: ${({$variant:e,theme:t,$active:n,$disabled:r})=>{if(r)return"transparent";if(n)return"transparent";return
|
|
5319
|
+
background-color: ${({$variant:e,theme:t,$active:n,$disabled:r})=>{if(r)return"transparent";if(n)return"transparent";return VA(t)[e].hoverBackground}};
|
|
5320
5320
|
}
|
|
5321
5321
|
}
|
|
5322
|
-
`,
|
|
5322
|
+
`,RA=v.div`
|
|
5323
5323
|
display: inline-flex;
|
|
5324
5324
|
align-items: center;
|
|
5325
5325
|
justify-content: center;
|
|
5326
|
-
height: ${({$size:e})=>
|
|
5327
|
-
padding: ${({$size:e})=>
|
|
5328
|
-
border-radius: ${({$size:e})=>
|
|
5326
|
+
height: ${({$size:e})=>LA[e].itemHeight};
|
|
5327
|
+
padding: ${({$size:e})=>LA[e].itemPadding};
|
|
5328
|
+
border-radius: ${({$size:e})=>LA[e].itemRadius};
|
|
5329
5329
|
cursor: ${({$disabled:e})=>e?"not-allowed":"pointer"};
|
|
5330
5330
|
transition: all 0.3s ease-in-out;
|
|
5331
5331
|
background-color: transparent;
|
|
5332
5332
|
|
|
5333
5333
|
@media (any-hover: hover) {
|
|
5334
5334
|
&:hover:not([data-disabled="true"]) {
|
|
5335
|
-
background-color: ${({$variant:e,theme:t,$active:n,$disabled:r})=>{if(r)return"transparent";if(n)return"transparent";return
|
|
5335
|
+
background-color: ${({$variant:e,theme:t,$active:n,$disabled:r})=>{if(r)return"transparent";if(n)return"transparent";return VA(t)[e].hoverBackground}};
|
|
5336
5336
|
}
|
|
5337
5337
|
}
|
|
5338
5338
|
|
|
5339
5339
|
span {
|
|
5340
|
-
color: ${({$variant:e,theme:t,$active:n,$disabled:r})=>{if(r&&n)return t.palette.background.default;if(r){return
|
|
5340
|
+
color: ${({$variant:e,theme:t,$active:n,$disabled:r})=>{if(r&&n)return t.palette.background.default;if(r){return VA(t)[e].textColorDisabled}if(n){return VA(t)[e].textColorActive}return VA(t)[e].textColor}};
|
|
5341
5341
|
transition: color 0.5s ease-in-out;
|
|
5342
5342
|
}
|
|
5343
|
-
`,
|
|
5343
|
+
`,zA=v.div`
|
|
5344
5344
|
position: absolute;
|
|
5345
5345
|
top: 0;
|
|
5346
5346
|
height: 100%;
|
|
5347
5347
|
transition: all 0.3s ease-in-out; //インジケーターの動きだしタイミングを少しだけ速くする
|
|
5348
|
-
background-color: ${({$variant:e,theme:t,$disabled:n})=>{if(n)return t.palette.text.disabled;return
|
|
5349
|
-
border-radius: ${({$size:e})=>
|
|
5350
|
-
`,
|
|
5348
|
+
background-color: ${({$variant:e,theme:t,$disabled:n})=>{if(n)return t.palette.text.disabled;return VA(t)[e].indicatorBackground}};
|
|
5349
|
+
border-radius: ${({$size:e})=>LA[e].itemRadius};
|
|
5350
|
+
`,NA="undefined"!=typeof window?t.useLayoutEffect:t.useEffect;function TA(e){const n=t.useRef(e);return NA((()=>{n.current=e})),t.useCallback(((...e)=>n.current(...e)),[])}const ZA=e.forwardRef((function({cases:t,value:n,onChange:r,size:i="medium",variant:o="light",disabled:a=!1,fullWidth:l=!1,width:s,showTooltip:c=!1,tooltipPosition:d=["top-start","bottom-start","auto"]},u){const p=ne(),m=t,h=new Map,g=e.useRef(null),f=e.useRef(null),[b,v]=e.useState({}),x=(e,t)=>()=>{!r||a||t||r(e)},y=e.useMemo((()=>"small"===i||"medium"===i?"sm-md":"md"),[i]),w=e.useCallback(((e,t)=>e&&t?p.palette.background.default:e?p.palette.text.disabled:t?p.palette.background.default:VA(p)[o].iconColor),[p,o]),C=e.useMemo((()=>"small"===i?"xs":"sm"),[i]),E=TA((()=>{const{tabsMeta:e,tabMeta:t}=(()=>{const e=g.current;let t,r;if(e){const n=e.getBoundingClientRect();t={clientWidth:e.clientWidth,scrollLeft:e.scrollLeft,scrollTop:e.scrollTop,scrollWidth:e.scrollWidth,top:n.top,bottom:n.bottom,left:n.left,right:n.right}}if(e&&null!=n&&f.current){const e=f.current.children;if(e.length>0){const t=e[h.get(n)];r=(null==t?void 0:t.getBoundingClientRect())||null}}return{tabsMeta:t,tabMeta:r}})();let r=0;if(t&&e){const n=e.scrollLeft;r=t.left-e.left+n}const i={left:r,width:t?t.width:0};if(void 0===b.left||void 0===b.width)v(i);else{const e=Math.abs(b.left-i.left),t=Math.abs((null==b?void 0:b.width)-i.width);(e>=1||t>=1)&&v(i)}}));return e.useEffect((()=>{E()}),[n,m.length,i,o,E]),e.useEffect((()=>{const e=()=>{E()};return window.addEventListener("resize",e),()=>{window.removeEventListener("resize",e)}}),[E]),e.createElement(HA,{ref:u,$size:i,$variant:o,$disabled:a,$fullWidth:l,$width:s,role:"tablist","aria-label":"Switch options"},e.createElement(OA,{ref:g},e.createElement(zA,{$size:i,$variant:o,$disabled:a,style:Object.assign({},b)}),e.createElement(SA,{ref:f,$size:i,$fullWidth:l},m.map(((t,r)=>{const l=void 0===t.value?r:t.value;h.set(l,r);const s=l===n,u=t.disabled||a,p=null!=t.icon?e.createElement(DA,{$size:i,$variant:o,$active:s,$disabled:u,"data-disabled":u,role:"tab","aria-selected":s,tabIndex:u?-1:0,onClick:x(l,u)},e.createElement(le,{name:t.icon,size:y,color:w(u,s)})):e.createElement(RA,{key:t.name,$size:i,$variant:o,$active:s,$disabled:u,"data-disabled":u,role:"tab","aria-selected":s,tabIndex:u?-1:0,onClick:x(l,u)},e.createElement(ke,{trimVertical:!0,component:"span",size:C,weight:"normal",color:"secondary"},t.name));return c?e.createElement(Sc,{key:t.name,content:t.name,positionPriority:d,offset:[0,15]},p):e.createElement(e.Fragment,{key:t.name},p)})))))})),BA=e.forwardRef((function(t,n){var{children:r}=t,i=D(t,["children"]);return e.createElement("tbody",Object.assign({ref:n},i),r)})),PA=v.td`
|
|
5351
5351
|
width: ${({width:e})=>e};
|
|
5352
5352
|
padding: ${({theme:e})=>2*e.spacing}px;
|
|
5353
|
-
`,
|
|
5353
|
+
`,_A=e.forwardRef((function(t,n){var{width:r="auto",children:i}=t,o=D(t,["width","children"]);return e.createElement(PA,Object.assign({ref:n,width:r},o),e.createElement(ke,{component:"div"},i))})),GA=e.forwardRef((function({children:t},n){return e.createElement("thead",{ref:n},t)})),jA={small:"8px",medium:"12px",large:"16px"},FA=e=>jA[e],YA=v.tr`
|
|
5354
5354
|
border: 1px solid ${({theme:e})=>e.palette.divider};
|
|
5355
5355
|
|
|
5356
5356
|
& > td,
|
|
5357
5357
|
th {
|
|
5358
|
-
padding-top: ${({$verticalSpacing:e})=>
|
|
5359
|
-
padding-bottom: ${({$verticalSpacing:e})=>
|
|
5358
|
+
padding-top: ${({$verticalSpacing:e})=>FA(e)};
|
|
5359
|
+
padding-bottom: ${({$verticalSpacing:e})=>FA(e)};
|
|
5360
5360
|
}
|
|
5361
|
-
`,
|
|
5361
|
+
`,WA=e.forwardRef((function(t,n){var{children:r,verticalSpacing:i="medium"}=t,o=D(t,["children","verticalSpacing"]);return e.createElement(YA,Object.assign({ref:n,$verticalSpacing:i},o),r)})),XA=v.th`
|
|
5362
5362
|
width: ${({width:e})=>e};
|
|
5363
5363
|
padding: ${({theme:e})=>2*e.spacing}px;
|
|
5364
5364
|
background-color: ${({theme:e})=>e.palette.neutral.highlight};
|
|
5365
5365
|
border: 1px solid ${({theme:e})=>e.palette.divider};
|
|
5366
|
-
`,
|
|
5366
|
+
`,JA=t.forwardRef((function(e,n){var{width:r="auto",children:i}=e,o=D(e,["width","children"]);return t.createElement(XA,Object.assign({ref:n,width:r},o),t.createElement(ke,{component:"div",weight:"bold",size:"md",lineHeight:"normal"},i))})),UA=v.table`
|
|
5367
5367
|
width: 100%;
|
|
5368
5368
|
border-collapse: collapse;
|
|
5369
5369
|
table-layout: auto;
|
|
5370
5370
|
background-color: ${({theme:e})=>e.palette.background.default};
|
|
5371
|
-
`,
|
|
5371
|
+
`,QA=e.forwardRef((function(t,n){var{children:r}=t,i=D(t,["children"]);return e.createElement(UA,Object.assign({ref:n},i),r)}));QA.Header=GA,QA.Body=BA,QA.Row=WA,QA.Cell=_A,QA.HeaderCell=JA;const qA=v.div`
|
|
5372
5372
|
position: relative;
|
|
5373
|
-
`,
|
|
5373
|
+
`,KA=v.div`
|
|
5374
5374
|
${({$orientation:e})=>"vertical"===e&&y`
|
|
5375
5375
|
display: flex;
|
|
5376
5376
|
flex-direction: column;
|
|
5377
5377
|
align-items: stretch;
|
|
5378
5378
|
`}
|
|
5379
|
-
`,
|
|
5379
|
+
`,eL=v.div`
|
|
5380
5380
|
display: flex;
|
|
5381
5381
|
flex-direction: column;
|
|
5382
|
-
`,
|
|
5382
|
+
`,tL=v.div`
|
|
5383
5383
|
overflow-x: auto;
|
|
5384
5384
|
-webkit-overflow-scrolling: touch;
|
|
5385
|
-
`,
|
|
5385
|
+
`,nL=v.div`
|
|
5386
5386
|
position: relative;
|
|
5387
5387
|
display: inline-flex;
|
|
5388
5388
|
flex-wrap: nowrap;
|
|
5389
5389
|
align-items: stretch;
|
|
5390
|
-
`,
|
|
5390
|
+
`,rL=v.button`
|
|
5391
5391
|
flex-shrink: 0;
|
|
5392
5392
|
line-height: 1.25;
|
|
5393
5393
|
overflow: hidden;
|
|
@@ -5430,7 +5430,7 @@ object-assign
|
|
|
5430
5430
|
}
|
|
5431
5431
|
`}
|
|
5432
5432
|
`}
|
|
5433
|
-
`,
|
|
5433
|
+
`,iL=v.div`
|
|
5434
5434
|
display: flex;
|
|
5435
5435
|
align-items: center;
|
|
5436
5436
|
min-height: ${Ld.small.pillHeight};
|
|
@@ -5438,11 +5438,11 @@ object-assign
|
|
|
5438
5438
|
${({$orientation:e})=>"vertical"===e&&y`
|
|
5439
5439
|
width: 100%;
|
|
5440
5440
|
`}
|
|
5441
|
-
`,
|
|
5441
|
+
`,oL=v(ke).attrs({trimVertical:!0})`
|
|
5442
5442
|
padding-right: 2px;
|
|
5443
5443
|
font-weight: normal;
|
|
5444
5444
|
color: ${({selected:e,theme:t})=>e?t.palette.primary.base:t.palette.text.primary};
|
|
5445
|
-
`,
|
|
5445
|
+
`,aL=v.div`
|
|
5446
5446
|
position: absolute;
|
|
5447
5447
|
top: 0;
|
|
5448
5448
|
height: 100%;
|
|
@@ -5451,20 +5451,20 @@ object-assign
|
|
|
5451
5451
|
left 0.3s ease-in-out,
|
|
5452
5452
|
width 0.3s ease-in-out;
|
|
5453
5453
|
border-bottom: ${({theme:e})=>`2px solid ${e.palette.primary.base}`};
|
|
5454
|
-
`,
|
|
5454
|
+
`,lL=v.div`
|
|
5455
5455
|
flex-shrink: 0;
|
|
5456
5456
|
height: 1px;
|
|
5457
5457
|
width: 100%;
|
|
5458
5458
|
background: ${({theme:e})=>e.palette.neutral.lighter};
|
|
5459
|
-
`,
|
|
5459
|
+
`,sL=e.forwardRef((function({text:t,count:n,countMax:r,value:i,selected:o,orientation:a,onChange:l,onClick:s},c){const d=o?"primary":"secondaryDark";return e.createElement(rL,{ref:c,value:i,tabIndex:o?0:-1,role:"tab","aria-selected":o,selected:o,$orientation:a,onClick:e=>{!o&&l&&l(i),s&&s(e)}},e.createElement(iL,{$orientation:a},e.createElement(r$,{showZero:!0,layout:"inline",badgeContent:n,max:null!=r?r:99,color:d,size:"small"},e.createElement(oL,{selected:o},t))))})),cL=({ref:t,data:n,value:r,orientation:i="horizontal",onChange:o,onClick:a})=>{const l="vertical"===i,s=new Map,c=e.useRef(null),[d,u]=e.useState({}),p=Vc(t),m=TA((()=>{var e,t;const n=(()=>{const e=c.current;if(!e||!r)return null;const t=s.get(r);return void 0===t?null:e.children[t]})(),i={left:null!==(e=null==n?void 0:n.offsetLeft)&&void 0!==e?e:0,width:null!==(t=null==n?void 0:n.offsetWidth)&&void 0!==t?t:0};if(void 0===d.left||void 0===d.width)u(i);else{const e=Math.abs(d.left-i.left),t=Math.abs(d.width-i.width);(e>=1||t>=1)&&u(i)}}));e.useEffect((()=>{l||m()})),e.useEffect((()=>{if(l)return;const e=()=>{m()};return window.addEventListener("resize",e),()=>window.removeEventListener("resize",e)}),[l,m]);const h=n.map(((t,n)=>{const l=t.value,c=l===r;return s.set(l,n),e.createElement(sL,{key:n.toString(),selected:c,orientation:i,value:l,count:t.count,countMax:t.countMax,text:t.text,onChange:o,onClick:a})}));return e.createElement(qA,{ref:p},l?e.createElement(KA,{ref:c,role:"tablist",$orientation:i,"aria-orientation":"vertical"},h):e.createElement(eL,null,e.createElement(tL,null,e.createElement(nL,{ref:c,role:"tablist","aria-orientation":"horizontal"},h,e.createElement(aL,{"aria-hidden":"true",style:Object.assign({},d)}))),e.createElement(lL,null)))},dL=v.div`
|
|
5460
5460
|
cursor: ${({disabled:e})=>e?"not-allowed":"pointer"};
|
|
5461
|
-
`,dL=(e=15)=>{const t=[];for(let n=0;n<24;n++)for(let r=0;r<60;r+=e){const e=_a().hour(n).minute(r).format("HH:mm");t.push(e)}return t},uL=(e,t,n,r)=>{let i;if(0===t)i=e.add(n,"hour").second(0).millisecond(0);else{if(2!==t)return null;i=e.add(n,"minute").second(0).millisecond(0)}const o=i.format(r);return{newTime:i,normalizedValue:o}};var pL=g((({time:e,error:n=!1,errorText:s,disabled:c=!1,onTimeChange:u,dropdownInterval:p=60,filterTimeOptions:m,size:h="medium",variant:g="light",width:f="120px",maxHeight:b=300,onFocus:v,onBlur:x})=>{var y,w,C,E;Ae("TimeField","TimeField は非推奨です。代わりに TimeField2 を使用してください。");const I=ne(),[k,$]=i(!1),A=o(null),L=r(),V="HH:mm",H=e||_a(),O=l((()=>{const e=dL(p);return m&&m.length>0?e.filter((e=>m.every((t=>t(e))))):e}),[p,m]),[S,D]=i(H.format(V)),[R,z]=i(iC(S)),[N,T]=i({start:0,end:R.length-1,current:0}),[Z,B]=i(null);a((()=>{const e=H.format(V);D(e),z(iC(e))}),[H,V]);const P=d((()=>{setTimeout((()=>{var e,t,n;const r=null!==(t=null===(e=A.current)||void 0===e?void 0:e.selectionStart)&&void 0!==t?t:0,i=R[R.length-1].end+1,o=r>=i?i:r,a=R.findIndex((e=>o>=e.start&&o<=e.end+1));T((e=>R[a].editable?e.current===a?e:Object.assign(Object.assign({},e),{current:a}):Object.assign(Object.assign({},e),{current:a+1}))),null===(n=A.current)||void 0===n||n.setSelectionRange(R[a].start,R[a].end+1)}))}),[R]),_=d((()=>{P(),null==v||v()}),[P,v]),G=d((()=>{T((e=>Object.assign(Object.assign({},e),{current:0}))),B(null),null==x||x()}),[x]),j=d(((e,t,n)=>{const r=uL(e,t,n,V);return r?r.newTime:null}),[V]),F=d((t=>{const n=pC(t.code),r=n?mC(t.code):null;if(!uC.includes(t.key)&&!n)return;if(t.key===sC.ArrowLeft||t.key===sC.ArrowRight){t.preventDefault();const e=((e,t,n)=>{if(t===sC.ArrowLeft){for(let t=e-1;t>=0;t--)if(n[t].editable)return t-e}else if(t===sC.ArrowRight)for(let t=e+1;t<n.length;t++)if(n[t].editable)return t-e;return 0})(N.current,t.key,R);T((t=>Object.assign(Object.assign({},t),{current:t.current+e}))),B(null)}if(t.key===sC.ArrowUp||t.key===sC.ArrowDown){t.preventDefault();const n=t.key===sC.ArrowUp?1:-1,r=e||_a(),i=j(r,N.current,n);if(i){const e=i.format(V);D(e),z(iC(e)),u&&u(i)}}const i=n?r:t.key;if((dC.includes(t.key)||n)&&i){t.preventDefault();const n=((e,t,n,r)=>{const i=t.map((e=>Object.assign({},e)));let o=!1,a=null;if(r!==n){i[n].value=e.padStart(t[n].value.length,"0");const r=parseInt(e);(0===n?r<=2:r<=5)?a=n:(a=null,o=!0)}else{const r=(t[n].value.slice(1)+e).slice(-t[n].value.length);i[n].value=r,a=null,o=!0}return{newSections:i,shouldMoveToNextSection:o,newLastEditedSection:a}})(i,R,N.current,Z),r=oC(n.newSections),o=e||_a(),a=r,l=_a(`${o.format("YYYY-MM-DD")} ${a}`),s=l.format(V);if(M((()=>{D(s),z(iC(s))})),l.isValid()&&u){const e=o.hour(l.hour()).minute(l.minute()).second(0).millisecond(0);u(e)}if(B(n.newLastEditedSection),n.shouldMoveToNextSection)for(let e=N.current+1;e<R.length;e++)if(R[e].editable){T((t=>Object.assign(Object.assign({},t),{current:e})));break}}if(t.key===sC.Backspace){t.preventDefault();const e=((e,t)=>{const n=e.map((e=>Object.assign({},e)));return n[t].value="0".padStart(e[t].value.length,"0"),n})(R,N.current);z(e),B(null);const n=oC(e);D(n)}}),[R,N,Z,V,u,e,j]),Y=d((()=>{P()}),[P]),W=d((t=>{const[n,r]=t.split(":").map(Number),i=(e||_a()).hour(n).minute(r).second(0).millisecond(0);u&&u(i),$(!1)}),[e,u]),X=d((t=>{t.preventDefault();const n=t.clipboardData.getData("text").trim(),[r,i]=n.split(":"),o=parseInt(r,10),a=parseInt(i,10);if(!(!isNaN(o)&&!isNaN(a)&&o>=0&&o<=23&&a>=0&&a<=59))return;const l=e||_a(),s=_a(`${l.format("YYYY-MM-DD")} ${n}`);if(s.isValid()){const e=l.hour(s.hour()).minute(s.minute()).second(0).millisecond(0),t=e.format(V);D(t),z(iC(t)),u&&u(e)}}),[e,V,u]);return a((()=>{var e;R[N.current]&&(null===(e=A.current)||void 0===e||e.setSelectionRange(R[N.current].start,R[N.current].end+1))}),[N,R]),a((()=>{if(k&&e){const t=e.format(V);requestAnimationFrame((()=>{const e=document.querySelector(`[data-timefield-item="${CSS.escape(L)}-${t}"]`);e&&"function"==typeof e.scrollIntoView&&e.scrollIntoView({block:"center"})}))}}),[k,e,L,V]),t.createElement(t.Fragment,null,t.createElement(va,{ref:A,readOnly:!0,multiline:!1,error:n||!!s,disabled:c,width:f,size:h,variant:g,value:S,append:t.createElement(cL,{disabled:c,"aria-label":"時刻を選択",role:"button",tabIndex:c?-1:0,onClick:e=>{e.stopPropagation(),e.preventDefault(),c||$(!k)}},t.createElement(le,{name:"arrow_down",color:c?I.palette.text.disabled:I.palette.black})),onFocus:_,onBlur:G,onKeyDown:F,onMouseDown:Y,onPaste:X}),t.createElement(Da,null,t.createElement(Sa,{open:k,trigger:{x:null!==(w=null===(y=A.current)||void 0===y?void 0:y.getBoundingClientRect().left)&&void 0!==w?w:0,y:(null!==(E=null===(C=A.current)||void 0===C?void 0:C.getBoundingClientRect().bottom)&&void 0!==E?E:0)+5},placement:"bottom-start",width:120,maxHeight:b,onOpenChange:$},O.length>0?O.map((n=>{const r=(null==e?void 0:e.format(V))===n;return t.createElement(Ro,{key:n,"data-timefield-item":`${L}-${n}`,checked:r,onChange:e=>{e&&W(n)}},n)})):t.createElement(Dt,{disabled:!0},"選択可能な時刻がありません"))),s&&t.createElement(t.Fragment,null,t.createElement(Ua,{py:1}),t.createElement(nd,null,s)))}));var mL=g((({time:e,name:n,error:s=!1,errorText:c,disabled:u=!1,onTimeChange:p,dropdownInterval:m=60,filterTimeOptions:h,size:g="medium",variant:f="light",width:b="120px",maxHeight:v=480,onFocus:x,onBlur:y})=>{var w,C,E,I;const k=ne(),[M,$]=i(!1),A=o(null),L=r(),V="HH:mm",H=ba(),O=e||_a(),S=l((()=>{const e=dL(m);return h&&h.length>0?e.filter((e=>h.every((t=>t(e))))):e}),[m,h]),{value:D,sections:R,focusedIndex:z,isFocused:N,getSegmentProps:T,groupProps:Z}=(({time:e,disabled:t=!1,onTimeChange:n})=>{const r="HH:mm",l=e||_a(),[s,c]=i(l.format(r)),u=o(s),[p,m]=i(iC(s)),[h,g]=i(null),f=o(null),b=o(0),[v,x]=i(!1),y=o([]),w=o(null),C=d((e=>{f.current=e,g(e)}),[]),E=d((e=>{C(e),b.current=0;const t=y.current[e];t&&t!==document.activeElement&&t.focus()}),[C]);a((()=>{const t=(e||_a()).format(r);c(t),u.current=t,m(iC(t))}),[e]);const I=d(((e,t)=>{for(let n=e+t;n>=0&&n<p.length;n+=t)if(p[n].editable)return n;return null}),[p]),k=d((t=>{const i=f.current;if(null===i)return;const o=p[i];if(!(null==o?void 0:o.editable))return;const a=b.current;let l=o.value;0===a&&(l="".padStart(o.value.length,"0"));const s=`${l.slice(1)}${t}`,d=[...p];d[i]=Object.assign(Object.assign({},d[i]),{value:s}),m(d);const h=a+1;b.current=h;const g=0===i,v=parseInt(t);let x=!1;x=0===a?!(g?v<=2:v<=5):h>=o.value.length;const y=oC(d),w=e||_a(),C=_a(`${w.format("YYYY-MM-DD")} ${y}`),k=C.format(r);if(c(k),u.current=k,m(iC(k)),x){b.current=0;const e=I(i,1);null!==e&&E(e)}if(C.isValid()&&n){const e=w.hour(C.hour()).minute(C.minute()).second(0).millisecond(0);n(e)}}),[p,e,n,I,E]),M=d((e=>t=>{y.current[e]=t}),[]),$=d((e=>()=>{x(!0),C(e),b.current=0}),[C]),A=d((e=>t=>{const n=t.relatedTarget;w.current&&n&&w.current.contains(n)||f.current===e&&(x(!1),C(null),b.current=0)}),[C]),L=d((t=>i=>{const o=p[t];if((null==o?void 0:o.editable)&&!(i.ctrlKey||i.metaKey||i.altKey))if(i.key!==sC.ArrowUp&&i.key!==sC.ArrowDown){if(i.key===sC.Backspace||i.key===sC.Delete){i.preventDefault(),i.stopPropagation();const e=i.key===sC.Backspace,n="0".repeat(o.value.length);if(o.value===n&&0===b.current){if(e){const e=I(t,-1);null!==e&&E(e)}return}const r=[...p];r[t]=Object.assign(Object.assign({},r[t]),{value:n}),m(r),b.current=0;const a=oC(r);return c(a),void(u.current=a)}if(pC(i.code)){i.preventDefault();const e=mC(i.code);e&&k(e)}}else{i.preventDefault();const o=i.key===sC.ArrowUp?1:-1,a=e||_a(),[l,s]=u.current.split(":").map(Number),d=a.hour(l).minute(s).second(0).millisecond(0),p=uL(d,t,o,r);p&&(c(p.normalizedValue),u.current=p.normalizedValue,m(iC(p.normalizedValue)),null==n||n(p.newTime))}}),[p,e,r,n,k,I,E]),V=d((e=>e=>{const t=e.nativeEvent;if(e.preventDefault(),"deleteContentBackward"!==t.inputType&&"deleteContentForward"!==t.inputType&&null!=t.data){const e=t.data;/^\d$/.test(e)&&k(e)}}),[k]),H=d((e=>{const n=p[e];if(t||!(null==n?void 0:n.editable))return{ref:M(e),"aria-hidden":!0};const r=["時","分"][p.slice(0,e+1).filter((e=>e.editable)).length-1];return{ref:M(e),role:"spinbutton",contentEditable:!0,suppressContentEditableWarning:!0,inputMode:"numeric",tabIndex:0,enterKeyHint:"next",spellCheck:!1,autoCorrect:"off",style:{caretColor:"transparent"},"aria-label":r,onFocus:$(e),onBlur:A(e),onKeyDown:L(e),onBeforeInput:V(e),onPointerDown(e){e.stopPropagation()},onMouseDown(e){e.stopPropagation()}}}),[p,t,M,$,A,L,V]),O=d((e=>{const t=f.current;if(null!==t)if(e.key!==sC.ArrowLeft&&e.key!==sC.ArrowRight){if(e.key===sC.Tab){const n=e.shiftKey?-1:1,r=I(t,n);null!==r&&(e.preventDefault(),E(r))}}else{e.preventDefault();const n=e.key===sC.ArrowLeft?-1:1,r=I(t,n);null!==r&&E(r)}}),[I,E]),S=d((t=>{t.preventDefault();const i=t.clipboardData.getData("text").trim(),[o,a]=i.split(":"),l=parseInt(o,10),s=parseInt(a,10);if(isNaN(l)||isNaN(s)||l<0||l>23||s<0||s>59)return;const d=(e||_a()).hour(l).minute(s).second(0).millisecond(0),p=d.format(r);c(p),u.current=p,m(iC(p)),null==n||n(d)}),[e,r,n]);return{value:s,sections:p,focusedIndex:h,isFocused:v,getSegmentProps:H,groupProps:{ref:w,onKeyDown:O,onPaste:S}}})({time:O,disabled:u,onTimeChange:p}),B=d((()=>{null==x||x()}),[x]),P=d((e=>{const t=e.relatedTarget;A.current&&t&&A.current.contains(t)||null==y||y()}),[y]),_=d((t=>{const[n,r]=t.split(":").map(Number),i=(e||_a()).hour(n).minute(r).second(0).millisecond(0);null==p||p(i),$(!1)}),[e,p]),G=d((e=>{e.stopPropagation(),e.preventDefault(),u||$(!M)}),[u,M]),j=d((e=>t=>{t&&_(e)}),[_]);return a((()=>{if(M&&e){const t=e.format(V);requestAnimationFrame((()=>{const e=document.querySelector(`[data-timefield-item="${CSS.escape(L)}-${t}"]`);e&&"function"==typeof e.scrollIntoView&&e.scrollIntoView({block:"center"})}))}}),[M,e,L,V]),t.createElement(t.Fragment,null,t.createElement(zC,{ref:A,$disabled:u,$error:s||!!c,$focused:N,$isIOS:H,$size:g,$variant:f,$width:b,onBlurCapture:P,onFocusCapture:B},t.createElement(NC,Object.assign({},Z),R.map(((e,n)=>t.createElement(TC,Object.assign({key:`${e.start}-${e.end}`,$editable:e.editable,$focused:N&&z===n},T(n)),e.value)))),t.createElement(ZC,null,t.createElement(cL,{disabled:u,"aria-label":"時刻を選択",role:"button",tabIndex:u?-1:0,onClick:G},t.createElement(le,{color:u?k.palette.text.disabled:k.palette.black,name:"arrow_down"})))),t.createElement("input",{type:"hidden",name:n,value:D,disabled:u}),t.createElement(Da,null,t.createElement(Sa,{maxHeight:v,open:M,placement:"bottom-start",trigger:{x:null!==(C=null===(w=A.current)||void 0===w?void 0:w.getBoundingClientRect().left)&&void 0!==C?C:0,y:(null!==(I=null===(E=A.current)||void 0===E?void 0:E.getBoundingClientRect().bottom)&&void 0!==I?I:0)+5},width:120,onOpenChange:$},S.length>0?S.map((n=>{const r=(null==e?void 0:e.format(V))===n;return t.createElement(Ro,{key:n,checked:r,"data-timefield-item":`${L}-${n}`,onChange:j(n)},n)})):t.createElement(Dt,{disabled:!0},"選択可能な時刻がありません"))),c&&t.createElement(t.Fragment,null,t.createElement(Ua,{py:1}),t.createElement(nd,null,c)))}));const hL="calc(100vw - 24px)",gL="800px",fL=v.div`
|
|
5461
|
+
`,uL=(e=15)=>{const t=[];for(let n=0;n<24;n++)for(let r=0;r<60;r+=e){const e=_a().hour(n).minute(r).format("HH:mm");t.push(e)}return t},pL=(e,t,n,r)=>{let i;if(0===t)i=e.add(n,"hour").second(0).millisecond(0);else{if(2!==t)return null;i=e.add(n,"minute").second(0).millisecond(0)}const o=i.format(r);return{newTime:i,normalizedValue:o}};var mL=g((({time:e,error:n=!1,errorText:s,disabled:c=!1,onTimeChange:u,dropdownInterval:p=60,filterTimeOptions:m,size:h="medium",variant:g="light",width:f="120px",maxHeight:b=300,onFocus:v,onBlur:x})=>{var y,w,C,E;Ae("TimeField","TimeField は非推奨です。代わりに TimeField2 を使用してください。");const I=ne(),[k,$]=i(!1),A=o(null),L=r(),V="HH:mm",H=e||_a(),O=l((()=>{const e=uL(p);return m&&m.length>0?e.filter((e=>m.every((t=>t(e))))):e}),[p,m]),[S,D]=i(H.format(V)),[R,z]=i(oC(S)),[N,T]=i({start:0,end:R.length-1,current:0}),[Z,B]=i(null);a((()=>{const e=H.format(V);D(e),z(oC(e))}),[H,V]);const P=d((()=>{setTimeout((()=>{var e,t,n;const r=null!==(t=null===(e=A.current)||void 0===e?void 0:e.selectionStart)&&void 0!==t?t:0,i=R[R.length-1].end+1,o=r>=i?i:r,a=R.findIndex((e=>o>=e.start&&o<=e.end+1));T((e=>R[a].editable?e.current===a?e:Object.assign(Object.assign({},e),{current:a}):Object.assign(Object.assign({},e),{current:a+1}))),null===(n=A.current)||void 0===n||n.setSelectionRange(R[a].start,R[a].end+1)}))}),[R]),_=d((()=>{P(),null==v||v()}),[P,v]),G=d((()=>{T((e=>Object.assign(Object.assign({},e),{current:0}))),B(null),null==x||x()}),[x]),j=d(((e,t,n)=>{const r=pL(e,t,n,V);return r?r.newTime:null}),[V]),F=d((t=>{const n=mC(t.code),r=n?hC(t.code):null;if(!pC.includes(t.key)&&!n)return;if(t.key===cC.ArrowLeft||t.key===cC.ArrowRight){t.preventDefault();const e=((e,t,n)=>{if(t===cC.ArrowLeft){for(let t=e-1;t>=0;t--)if(n[t].editable)return t-e}else if(t===cC.ArrowRight)for(let t=e+1;t<n.length;t++)if(n[t].editable)return t-e;return 0})(N.current,t.key,R);T((t=>Object.assign(Object.assign({},t),{current:t.current+e}))),B(null)}if(t.key===cC.ArrowUp||t.key===cC.ArrowDown){t.preventDefault();const n=t.key===cC.ArrowUp?1:-1,r=e||_a(),i=j(r,N.current,n);if(i){const e=i.format(V);D(e),z(oC(e)),u&&u(i)}}const i=n?r:t.key;if((uC.includes(t.key)||n)&&i){t.preventDefault();const n=((e,t,n,r)=>{const i=t.map((e=>Object.assign({},e)));let o=!1,a=null;if(r!==n){i[n].value=e.padStart(t[n].value.length,"0");const r=parseInt(e);(0===n?r<=2:r<=5)?a=n:(a=null,o=!0)}else{const r=(t[n].value.slice(1)+e).slice(-t[n].value.length);i[n].value=r,a=null,o=!0}return{newSections:i,shouldMoveToNextSection:o,newLastEditedSection:a}})(i,R,N.current,Z),r=aC(n.newSections),o=e||_a(),a=r,l=_a(`${o.format("YYYY-MM-DD")} ${a}`),s=l.format(V);if(M((()=>{D(s),z(oC(s))})),l.isValid()&&u){const e=o.hour(l.hour()).minute(l.minute()).second(0).millisecond(0);u(e)}if(B(n.newLastEditedSection),n.shouldMoveToNextSection)for(let e=N.current+1;e<R.length;e++)if(R[e].editable){T((t=>Object.assign(Object.assign({},t),{current:e})));break}}if(t.key===cC.Backspace){t.preventDefault();const e=((e,t)=>{const n=e.map((e=>Object.assign({},e)));return n[t].value="0".padStart(e[t].value.length,"0"),n})(R,N.current);z(e),B(null);const n=aC(e);D(n)}}),[R,N,Z,V,u,e,j]),Y=d((()=>{P()}),[P]),W=d((t=>{const[n,r]=t.split(":").map(Number),i=(e||_a()).hour(n).minute(r).second(0).millisecond(0);u&&u(i),$(!1)}),[e,u]),X=d((t=>{t.preventDefault();const n=t.clipboardData.getData("text").trim(),[r,i]=n.split(":"),o=parseInt(r,10),a=parseInt(i,10);if(!(!isNaN(o)&&!isNaN(a)&&o>=0&&o<=23&&a>=0&&a<=59))return;const l=e||_a(),s=_a(`${l.format("YYYY-MM-DD")} ${n}`);if(s.isValid()){const e=l.hour(s.hour()).minute(s.minute()).second(0).millisecond(0),t=e.format(V);D(t),z(oC(t)),u&&u(e)}}),[e,V,u]);return a((()=>{var e;R[N.current]&&(null===(e=A.current)||void 0===e||e.setSelectionRange(R[N.current].start,R[N.current].end+1))}),[N,R]),a((()=>{if(k&&e){const t=e.format(V);requestAnimationFrame((()=>{const e=document.querySelector(`[data-timefield-item="${CSS.escape(L)}-${t}"]`);e&&"function"==typeof e.scrollIntoView&&e.scrollIntoView({block:"center"})}))}}),[k,e,L,V]),t.createElement(t.Fragment,null,t.createElement(va,{ref:A,readOnly:!0,multiline:!1,error:n||!!s,disabled:c,width:f,size:h,variant:g,value:S,append:t.createElement(dL,{disabled:c,"aria-label":"時刻を選択",role:"button",tabIndex:c?-1:0,onClick:e=>{e.stopPropagation(),e.preventDefault(),c||$(!k)}},t.createElement(le,{name:"arrow_down",color:c?I.palette.text.disabled:I.palette.black})),onFocus:_,onBlur:G,onKeyDown:F,onMouseDown:Y,onPaste:X}),t.createElement(Da,null,t.createElement(Sa,{open:k,trigger:{x:null!==(w=null===(y=A.current)||void 0===y?void 0:y.getBoundingClientRect().left)&&void 0!==w?w:0,y:(null!==(E=null===(C=A.current)||void 0===C?void 0:C.getBoundingClientRect().bottom)&&void 0!==E?E:0)+5},placement:"bottom-start",width:120,maxHeight:b,onOpenChange:$},O.length>0?O.map((n=>{const r=(null==e?void 0:e.format(V))===n;return t.createElement(Ro,{key:n,"data-timefield-item":`${L}-${n}`,checked:r,onChange:e=>{e&&W(n)}},n)})):t.createElement(Dt,{disabled:!0},"選択可能な時刻がありません"))),s&&t.createElement(t.Fragment,null,t.createElement(Ua,{py:1}),t.createElement(nd,null,s)))}));var hL=g((({time:e,name:n,error:s=!1,errorText:c,disabled:u=!1,onTimeChange:p,dropdownInterval:m=60,filterTimeOptions:h,size:g="medium",variant:f="light",width:b="120px",maxHeight:v=480,onFocus:x,onBlur:y})=>{var w,C,E,I;const k=ne(),[M,$]=i(!1),A=o(null),L=r(),V="HH:mm",H=ba(),O=e||_a(),S=l((()=>{const e=uL(m);return h&&h.length>0?e.filter((e=>h.every((t=>t(e))))):e}),[m,h]),{value:D,sections:R,focusedIndex:z,isFocused:N,getSegmentProps:T,groupProps:Z}=(({time:e,disabled:t=!1,onTimeChange:n})=>{const r="HH:mm",l=e||_a(),[s,c]=i(l.format(r)),u=o(s),[p,m]=i(oC(s)),[h,g]=i(null),f=o(null),b=o(0),[v,x]=i(!1),y=o([]),w=o(null),C=d((e=>{f.current=e,g(e)}),[]),E=d((e=>{C(e),b.current=0;const t=y.current[e];t&&t!==document.activeElement&&t.focus()}),[C]);a((()=>{const t=(e||_a()).format(r);c(t),u.current=t,m(oC(t))}),[e]);const I=d(((e,t)=>{for(let n=e+t;n>=0&&n<p.length;n+=t)if(p[n].editable)return n;return null}),[p]),k=d((t=>{const i=f.current;if(null===i)return;const o=p[i];if(!(null==o?void 0:o.editable))return;const a=b.current;let l=o.value;0===a&&(l="".padStart(o.value.length,"0"));const s=`${l.slice(1)}${t}`,d=[...p];d[i]=Object.assign(Object.assign({},d[i]),{value:s}),m(d);const h=a+1;b.current=h;const g=0===i,v=parseInt(t);let x=!1;x=0===a?!(g?v<=2:v<=5):h>=o.value.length;const y=aC(d),w=e||_a(),C=_a(`${w.format("YYYY-MM-DD")} ${y}`),k=C.format(r);if(c(k),u.current=k,m(oC(k)),x){b.current=0;const e=I(i,1);null!==e&&E(e)}if(C.isValid()&&n){const e=w.hour(C.hour()).minute(C.minute()).second(0).millisecond(0);n(e)}}),[p,e,n,I,E]),M=d((e=>t=>{y.current[e]=t}),[]),$=d((e=>()=>{x(!0),C(e),b.current=0}),[C]),A=d((e=>t=>{const n=t.relatedTarget;w.current&&n&&w.current.contains(n)||f.current===e&&(x(!1),C(null),b.current=0)}),[C]),L=d((t=>i=>{const o=p[t];if((null==o?void 0:o.editable)&&!(i.ctrlKey||i.metaKey||i.altKey))if(i.key!==cC.ArrowUp&&i.key!==cC.ArrowDown){if(i.key===cC.Backspace||i.key===cC.Delete){i.preventDefault(),i.stopPropagation();const e=i.key===cC.Backspace,n="0".repeat(o.value.length);if(o.value===n&&0===b.current){if(e){const e=I(t,-1);null!==e&&E(e)}return}const r=[...p];r[t]=Object.assign(Object.assign({},r[t]),{value:n}),m(r),b.current=0;const a=aC(r);return c(a),void(u.current=a)}if(mC(i.code)){i.preventDefault();const e=hC(i.code);e&&k(e)}}else{i.preventDefault();const o=i.key===cC.ArrowUp?1:-1,a=e||_a(),[l,s]=u.current.split(":").map(Number),d=a.hour(l).minute(s).second(0).millisecond(0),p=pL(d,t,o,r);p&&(c(p.normalizedValue),u.current=p.normalizedValue,m(oC(p.normalizedValue)),null==n||n(p.newTime))}}),[p,e,r,n,k,I,E]),V=d((e=>e=>{const t=e.nativeEvent;if(e.preventDefault(),"deleteContentBackward"!==t.inputType&&"deleteContentForward"!==t.inputType&&null!=t.data){const e=t.data;/^\d$/.test(e)&&k(e)}}),[k]),H=d((e=>{const n=p[e];if(t||!(null==n?void 0:n.editable))return{ref:M(e),"aria-hidden":!0};const r=["時","分"][p.slice(0,e+1).filter((e=>e.editable)).length-1];return{ref:M(e),role:"spinbutton",contentEditable:!0,suppressContentEditableWarning:!0,inputMode:"numeric",tabIndex:0,enterKeyHint:"next",spellCheck:!1,autoCorrect:"off",style:{caretColor:"transparent"},"aria-label":r,onFocus:$(e),onBlur:A(e),onKeyDown:L(e),onBeforeInput:V(e),onPointerDown(e){e.stopPropagation()},onMouseDown(e){e.stopPropagation()}}}),[p,t,M,$,A,L,V]),O=d((e=>{const t=f.current;if(null!==t)if(e.key!==cC.ArrowLeft&&e.key!==cC.ArrowRight){if(e.key===cC.Tab){const n=e.shiftKey?-1:1,r=I(t,n);null!==r&&(e.preventDefault(),E(r))}}else{e.preventDefault();const n=e.key===cC.ArrowLeft?-1:1,r=I(t,n);null!==r&&E(r)}}),[I,E]),S=d((t=>{t.preventDefault();const i=t.clipboardData.getData("text").trim(),[o,a]=i.split(":"),l=parseInt(o,10),s=parseInt(a,10);if(isNaN(l)||isNaN(s)||l<0||l>23||s<0||s>59)return;const d=(e||_a()).hour(l).minute(s).second(0).millisecond(0),p=d.format(r);c(p),u.current=p,m(oC(p)),null==n||n(d)}),[e,r,n]);return{value:s,sections:p,focusedIndex:h,isFocused:v,getSegmentProps:H,groupProps:{ref:w,onKeyDown:O,onPaste:S}}})({time:O,disabled:u,onTimeChange:p}),B=d((()=>{null==x||x()}),[x]),P=d((e=>{const t=e.relatedTarget;A.current&&t&&A.current.contains(t)||null==y||y()}),[y]),_=d((t=>{const[n,r]=t.split(":").map(Number),i=(e||_a()).hour(n).minute(r).second(0).millisecond(0);null==p||p(i),$(!1)}),[e,p]),G=d((e=>{e.stopPropagation(),e.preventDefault(),u||$(!M)}),[u,M]),j=d((e=>t=>{t&&_(e)}),[_]);return a((()=>{if(M&&e){const t=e.format(V);requestAnimationFrame((()=>{const e=document.querySelector(`[data-timefield-item="${CSS.escape(L)}-${t}"]`);e&&"function"==typeof e.scrollIntoView&&e.scrollIntoView({block:"center"})}))}}),[M,e,L,V]),t.createElement(t.Fragment,null,t.createElement(NC,{ref:A,$disabled:u,$error:s||!!c,$focused:N,$isIOS:H,$size:g,$variant:f,$width:b,onBlurCapture:P,onFocusCapture:B},t.createElement(TC,Object.assign({},Z),R.map(((e,n)=>t.createElement(ZC,Object.assign({key:`${e.start}-${e.end}`,$editable:e.editable,$focused:N&&z===n},T(n)),e.value)))),t.createElement(BC,null,t.createElement(dL,{disabled:u,"aria-label":"時刻を選択",role:"button",tabIndex:u?-1:0,onClick:G},t.createElement(le,{color:u?k.palette.text.disabled:k.palette.black,name:"arrow_down"})))),t.createElement("input",{type:"hidden",name:n,value:D,disabled:u}),t.createElement(Da,null,t.createElement(Sa,{maxHeight:v,open:M,placement:"bottom-start",trigger:{x:null!==(C=null===(w=A.current)||void 0===w?void 0:w.getBoundingClientRect().left)&&void 0!==C?C:0,y:(null!==(I=null===(E=A.current)||void 0===E?void 0:E.getBoundingClientRect().bottom)&&void 0!==I?I:0)+5},width:120,onOpenChange:$},S.length>0?S.map((n=>{const r=(null==e?void 0:e.format(V))===n;return t.createElement(Ro,{key:n,checked:r,"data-timefield-item":`${L}-${n}`,onChange:j(n)},n)})):t.createElement(Dt,{disabled:!0},"選択可能な時刻がありません"))),c&&t.createElement(t.Fragment,null,t.createElement(Ua,{py:1}),t.createElement(nd,null,c)))}));const gL="calc(100vw - 24px)",fL="800px",bL=v.div`
|
|
5462
5462
|
box-sizing: border-box;
|
|
5463
5463
|
display: inline-flex;
|
|
5464
5464
|
flex-direction: column;
|
|
5465
5465
|
margin-inline: auto;
|
|
5466
5466
|
padding: ${({theme:e})=>2*e.spacing}px;
|
|
5467
|
-
`,
|
|
5467
|
+
`,vL=v.div`
|
|
5468
5468
|
position: relative;
|
|
5469
5469
|
display: flex;
|
|
5470
5470
|
align-items: center;
|
|
@@ -5472,7 +5472,7 @@ object-assign
|
|
|
5472
5472
|
overflow: hidden;
|
|
5473
5473
|
width: fit-content;
|
|
5474
5474
|
min-width: ${240}px;
|
|
5475
|
-
max-width: ${
|
|
5475
|
+
max-width: ${gL};
|
|
5476
5476
|
padding: ${({theme:e})=>2*e.spacing}px;
|
|
5477
5477
|
background: ${({background:e})=>e};
|
|
5478
5478
|
box-shadow: ${({boxShadow:e})=>e};
|
|
@@ -5485,9 +5485,9 @@ object-assign
|
|
|
5485
5485
|
|
|
5486
5486
|
@media (min-width: ${F.MOBILE}px) {
|
|
5487
5487
|
min-width: ${400}px;
|
|
5488
|
-
max-width: ${
|
|
5488
|
+
max-width: ${fL};
|
|
5489
5489
|
}
|
|
5490
|
-
`,
|
|
5490
|
+
`,xL=v.div`
|
|
5491
5491
|
position: relative;
|
|
5492
5492
|
z-index: 1;
|
|
5493
5493
|
display: flex;
|
|
@@ -5495,11 +5495,11 @@ object-assign
|
|
|
5495
5495
|
gap: ${({theme:e})=>2*e.spacing}px;
|
|
5496
5496
|
width: 100%;
|
|
5497
5497
|
min-width: 0;
|
|
5498
|
-
`,
|
|
5498
|
+
`,yL=v.span`
|
|
5499
5499
|
flex-shrink: 0;
|
|
5500
5500
|
display: flex;
|
|
5501
5501
|
align-items: center;
|
|
5502
|
-
`,
|
|
5502
|
+
`,wL=v.div`
|
|
5503
5503
|
flex: 1;
|
|
5504
5504
|
min-width: 0;
|
|
5505
5505
|
|
|
@@ -5508,19 +5508,19 @@ object-assign
|
|
|
5508
5508
|
word-break: break-word;
|
|
5509
5509
|
overflow-wrap: break-word;
|
|
5510
5510
|
}
|
|
5511
|
-
`,
|
|
5511
|
+
`,CL=v.div`
|
|
5512
5512
|
flex-shrink: 0;
|
|
5513
5513
|
align-self: center;
|
|
5514
5514
|
cursor: pointer;
|
|
5515
|
-
`,
|
|
5515
|
+
`,EL=w`
|
|
5516
5516
|
from {
|
|
5517
5517
|
width: 100%;
|
|
5518
5518
|
}
|
|
5519
5519
|
to {
|
|
5520
5520
|
width: 0%
|
|
5521
5521
|
}
|
|
5522
|
-
`,
|
|
5523
|
-
animation: ${
|
|
5522
|
+
`,IL=v.div`
|
|
5523
|
+
animation: ${EL}
|
|
5524
5524
|
${({autoDismissTimeout:e})=>e}ms linear;
|
|
5525
5525
|
animation-play-state: ${({isRunning:e})=>e?"running":"paused"};
|
|
5526
5526
|
background-color: ${({backgroundColor:e})=>e};
|
|
@@ -5531,7 +5531,7 @@ object-assign
|
|
|
5531
5531
|
width: 0;
|
|
5532
5532
|
height: 100%;
|
|
5533
5533
|
pointer-events: none;
|
|
5534
|
-
`,
|
|
5534
|
+
`,kL={right:"translate3d(120%, 0, 0)",left:"translate3d(-120%, 0, 0)",bottom:"translate3d(0, 120%, 0)",top:"translate3d(0, -120%, 0)"};function ML(e){const t=e.split("-"),n="center"===t[1]?t[0]:t[1];return kL[n]}const $L=({appearance:t,placement:n,transitionDuration:r,transitionState:i,onDismiss:o,children:a,autoDismiss:l,autoDismissTimeout:s,isRunning:c})=>{const d=(({palette:t})=>({info:{background:t.primary.highlight,boxShadow:No(5,t.action.shadowOpacity,t.primary.softLight),icon:e.createElement(le,{name:"information",type:"fill",size:"lg",color:t.primary.base}),countDownBackground:t.primary.base,titleColor:t.primary.ultraDark,contentColor:t.primary.base,closeColor:t.primary.base},success:{background:t.success.highlight,boxShadow:No(5,t.action.shadowOpacity,t.success.lighter),icon:e.createElement(le,{name:"checkbox_circle",type:"fill",size:"lg",color:t.success.base}),countDownBackground:t.success.base,titleColor:t.success.ultraDark,contentColor:t.success.base,closeColor:t.success.base},warning:{background:t.warning.highlight,boxShadow:No(5,t.action.shadowOpacity,t.warning.light),icon:e.createElement(le,{name:"alert",type:"fill",size:"lg",color:t.warning.base}),countDownBackground:t.warning.base,titleColor:t.warning.ultraDark,contentColor:t.warning.base,closeColor:t.warning.base},error:{background:t.danger.highlight,boxShadow:No(5,t.action.shadowOpacity,t.danger.lighter),icon:e.createElement(le,{name:"alert",type:"fill",size:"lg",color:t.danger.base}),countDownBackground:t.danger.base,titleColor:t.danger.ultraDark,contentColor:t.danger.base,closeColor:t.danger.base}}))(ne())[t];return e.createElement(bL,null,e.createElement(vL,Object.assign({background:d.background,boxShadow:d.boxShadow,transitionDuration:r,role:"error"===t||"warning"===t?"alert":"status"},(e=>({entering:{transform:`${ML(e)}`,opacity:0},entered:{transform:"translate3d(0,0,0)",opacity:1},exiting:{transform:"scale(0.66)",opacity:0},exited:{transform:"scale(0.66)",opacity:0}}))(n)[i]),e.createElement(xL,null,e.createElement(yL,null,d.icon),e.createElement(wL,null,e.createElement(ke,{color:d.titleColor,weight:"bold"},a)),e.createElement(CL,{onClick:()=>{o()}},e.createElement(le,{name:"close",color:d.closeColor}))),e.createElement(IL,{opacity:l?1:0,autoDismissTimeout:s,isRunning:c,backgroundColor:d.countDownBackground})))},AL=v.div`
|
|
5535
5535
|
border: 0;
|
|
5536
5536
|
clip: rect(1px, 1px, 1px, 1px);
|
|
5537
5537
|
height: 1;
|
|
@@ -5540,7 +5540,7 @@ object-assign
|
|
|
5540
5540
|
position: absolute;
|
|
5541
5541
|
white-space: nowrap;
|
|
5542
5542
|
width: 1;
|
|
5543
|
-
`,
|
|
5543
|
+
`,LL=v.div`
|
|
5544
5544
|
cursor: pointer;
|
|
5545
5545
|
flex-shrink: 0;
|
|
5546
5546
|
opacity: 0.5;
|
|
@@ -5549,14 +5549,14 @@ object-assign
|
|
|
5549
5549
|
&:hover {
|
|
5550
5550
|
opacity: 1;
|
|
5551
5551
|
}
|
|
5552
|
-
`,
|
|
5552
|
+
`,VL=v.div`
|
|
5553
5553
|
flex-grow: 1;
|
|
5554
5554
|
font-size: 14;
|
|
5555
5555
|
line-height: 1.4;
|
|
5556
5556
|
min-height: 40px;
|
|
5557
5557
|
padding: ${({gutter:e})=>`${e}px ${1.5*e}px`};
|
|
5558
|
-
`,
|
|
5559
|
-
animation: ${({autoDismissTimeout:e})=>`${
|
|
5558
|
+
`,HL=w`from { height: 100%; } to { height: 0% }`,OL=v.div`
|
|
5559
|
+
animation: ${({autoDismissTimeout:e})=>`${HL} ${e}ms linear`};
|
|
5560
5560
|
animation-play-state: ${({isRunning:e})=>e?"running":"paused"};
|
|
5561
5561
|
background-color: rgba(0, 0, 0, 0.1);
|
|
5562
5562
|
bottom: 0;
|
|
@@ -5565,7 +5565,7 @@ object-assign
|
|
|
5565
5565
|
opacity: ${({opacity:e})=>e};
|
|
5566
5566
|
position: absolute;
|
|
5567
5567
|
width: 100%;
|
|
5568
|
-
`,
|
|
5568
|
+
`,SL=v.div`
|
|
5569
5569
|
background-color: ${({backgroundColor:e})=>e};
|
|
5570
5570
|
border-top-left-radius: ${({borderRadius:e})=>e}px;
|
|
5571
5571
|
border-bottom-left-radius: ${({borderRadius:e})=>e}px;
|
|
@@ -5577,11 +5577,11 @@ object-assign
|
|
|
5577
5577
|
overflow: hidden;
|
|
5578
5578
|
text-align: center;
|
|
5579
5579
|
width: 30px;
|
|
5580
|
-
`,
|
|
5580
|
+
`,DL=v.div`
|
|
5581
5581
|
height: ${({height:e})=>e};
|
|
5582
5582
|
transition: height
|
|
5583
5583
|
${({transitionDuration:e})=>`height ${e-100}ms 100ms`};
|
|
5584
|
-
`,
|
|
5584
|
+
`,RL=v.div`
|
|
5585
5585
|
background-color: ${({backgroundColor:e})=>e};
|
|
5586
5586
|
border-radius: ${({borderRadius:e})=>e}px;
|
|
5587
5587
|
box-shadow: 0 3px 8px rgba(0, 0, 0, 0.175);
|
|
@@ -5592,7 +5592,7 @@ object-assign
|
|
|
5592
5592
|
transition: ${({transitionDuration:e})=>`transform ${e}ms cubic-bezier(0.2, 0, 0, 1), opacity ${e}ms`};
|
|
5593
5593
|
width: ${({width:e})=>e}px;
|
|
5594
5594
|
${({transitionState:e,placement:t})=>{switch(e){case"entered":return y({transform:"translate3d(0,0,0)"});case"exiting":case"exited":return y({transform:"scale(0.66)",opacity:0});case"entering":return y((e=>{const t=e.split("-");return{right:"translate3d(120%, 0, 0)",left:"translate3d(-120%, 0, 0)",bottom:"translate3d(0, 120%, 0)",top:"translate3d(0, -120%, 0)"}["center"===t[1]?t[0]:t[1]]})(t));default:return""}}}
|
|
5595
|
-
`;function
|
|
5595
|
+
`;function zL(e){return{"aria-hidden":!0,height:16,width:e,viewBox:`0 0 ${e} 16`,style:{display:"inline-block",verticalAlign:"text-top",fill:"currentColor"}}}const NL=e=>t.createElement("svg",Object.assign({},zL(14),e),t.createElement("path",{fillRule:"evenodd",d:"M7.71 8.23l3.75 3.75-1.48 1.48-3.75-3.75-3.75 3.75L1 11.98l3.75-3.75L1 4.48 2.48 3l3.75 3.75L9.98 3l1.48 1.48-3.75 3.75z"})),TL=()=>{};const ZL=e=>{var{tag:n="span"}=e,r=D(e,["tag"]);return t.createElement(AL,Object.assign({as:n},r))},BL={success:{icon:e=>t.createElement("svg",Object.assign({},zL(12),e),t.createElement("path",{fillRule:"evenodd",d:"M12 5.5l-8 8-4-4L1.5 8 4 10.5 10.5 4 12 5.5z"})),text:"#006644",fg:"#36B37E",bg:"#E3FCEF"},error:{icon:e=>t.createElement("svg",Object.assign({},zL(12),e),t.createElement("path",{fillRule:"evenodd",d:"M5.05.01c.81 2.17.41 3.38-.52 4.31C3.55 5.37 1.98 6.15.9 7.68c-1.45 2.05-1.7 6.53 3.53 7.7-2.2-1.16-2.67-4.52-.3-6.61-.61 2.03.53 3.33 1.94 2.86 1.39-.47 2.3.53 2.27 1.67-.02.78-.31 1.44-1.13 1.81 3.42-.59 4.78-3.42 4.78-5.56 0-2.84-2.53-3.22-1.25-5.61-1.52.13-2.03 1.13-1.89 2.75.09 1.08-1.02 1.8-1.86 1.33-.67-.41-.66-1.19-.06-1.78C8.18 5.01 8.68 2.15 5.05.02L5.03 0l.02.01z"})),text:"#BF2600",fg:"#FF5630",bg:"#FFEBE6"},warning:{icon:e=>t.createElement("svg",Object.assign({},zL(16),e),t.createElement("path",{fillRule:"evenodd",d:"M8.893 1.5c-.183-.31-.52-.5-.887-.5s-.703.19-.886.5L.138 13.499a.98.98 0 0 0 0 1.001c.193.31.53.501.886.501h13.964c.367 0 .704-.19.877-.5a1.03 1.03 0 0 0 .01-1.002L8.893 1.5zm.133 11.497H6.987v-2.003h2.039v2.003zm0-3.004H6.987V5.987h2.039v4.006z"})),text:"#FF8B00",fg:"#FFAB00",bg:"#FFFAE6"},info:{icon:e=>t.createElement("svg",Object.assign({},zL(14),e),t.createElement("path",{fillRule:"evenodd",d:"M6.3 5.71a.942.942 0 0 1-.28-.7c0-.28.09-.52.28-.7.19-.18.42-.28.7-.28.28 0 .52.09.7.28.18.19.28.42.28.7 0 .28-.09.52-.28.7a1 1 0 0 1-.7.3c-.28 0-.52-.11-.7-.3zM8 8.01c-.02-.25-.11-.48-.31-.69-.2-.19-.42-.3-.69-.31H6c-.27.02-.48.13-.69.31-.2.2-.3.44-.31.69h1v3c.02.27.11.5.31.69.2.2.42.31.69.31h1c.27 0 .48-.11.69-.31.2-.19.3-.42.31-.69H8V8v.01zM7 2.32C3.86 2.32 1.3 4.86 1.3 8c0 3.14 2.56 5.7 5.7 5.7s5.7-2.55 5.7-5.7c0-3.15-2.56-5.69-5.7-5.69v.01zM7 1c3.86 0 7 3.14 7 7s-3.14 7-7 7-7-3.12-7-7 3.14-7 7-7z"})),text:"#505F79",fg:"#2684FF",bg:"white"}},PL=e=>{var{children:n}=e,r=D(e,["children"]);return t.createElement(LL,Object.assign({role:"button",className:"react-toast-notifications__toast__dismiss-button",gutter:8},r),n)},_L=e=>t.createElement(VL,Object.assign({className:"react-toast-notifications__toast__content",gutter:8},e)),GL=e=>{var{autoDismissTimeout:n,opacity:r,isRunning:i}=e,o=D(e,["autoDismissTimeout","opacity","isRunning"]);return t.createElement(OL,Object.assign({className:"react-toast-notifications__toast__countdown",autoDismissTimeout:n,isRunning:i,opacity:r},o))},jL=({appearance:e,autoDismiss:n,autoDismissTimeout:r,isRunning:i})=>{const o=BL[e],a=o.icon;return t.createElement(SL,{className:"react-toast-notifications__toast__icon-wrapper",color:o.bg,backgroundColor:o.fg,borderRadius:4,gutter:8},t.createElement(GL,{opacity:n?1:0,autoDismissTimeout:r,isRunning:i}),t.createElement(a,{className:"react-toast-notifications__toast__icon",css:{position:"relative",zIndex:1}}))},FL=e=>{var{appearance:n,placement:r,transitionDuration:l,transitionState:s}=e,c=D(e,["appearance","placement","transitionDuration","transitionState"]);const[d,u]=i("auto"),p=o(null);return a((()=>{if(p.current){if("entered"===s){const e=p.current;u(e.offsetHeight+8)}"exiting"===s&&u(0)}}),[s]),t.createElement(DL,{ref:p,height:d,transitionDuration:l},t.createElement(RL,Object.assign({className:`react-toast-notifications__toast react-toast-notifications__toast--${n}`,backgroundColor:BL[n].bg,borderRadius:4,color:BL[n].text,gutter:8,placement:r,width:360,transitionState:s,transitionDuration:l},c)))},YL=v.div`
|
|
5596
5596
|
box-sizing: border-box;
|
|
5597
5597
|
max-height: 100%;
|
|
5598
5598
|
max-width: 100%;
|
|
@@ -5602,22 +5602,22 @@ object-assign
|
|
|
5602
5602
|
position: fixed;
|
|
5603
5603
|
z-index: 1000;
|
|
5604
5604
|
${({placement:e})=>{switch(e){case"top-left":return y({top:0,left:0});case"top-center":return y({top:0,left:"50%",transform:"translateX(-50%)"});case"top-right":return y({top:0,right:0});case"bottom-left":return y({bottom:0,left:0});case"bottom-center":return y({bottom:0,left:"50%",transform:"translateX(-50%)"});case"bottom-right":return y({bottom:0,right:0});default:return""}}}
|
|
5605
|
-
`,
|
|
5605
|
+
`,WL=e=>{var{hasToasts:n,placement:r}=e,i=D(e,["hasToasts","placement"]);return t.createElement(YL,Object.assign({className:"react-toast-notifications__container",hasToasts:n,placement:r},i))};class XL{constructor(e,t){this.callback=e,this.start=t,this.remaining=t,this.resume()}clear(){clearTimeout(this.timerId)}pause(){clearTimeout(this.timerId),this.remaining-=Date.now()-this.start}resume(){this.start=Date.now(),clearTimeout(this.timerId),this.timerId=setTimeout(this.callback,this.remaining)}}class JL extends f{constructor(){super(...arguments),this.state={isRunning:Boolean(this.props.autoDismiss)},this.startTimer=()=>{const{autoDismiss:e,autoDismissTimeout:t,onDismiss:n}=this.props;e&&(this.setState({isRunning:!0}),this.timeout=new XL(n,t))},this.clearTimer=()=>{this.timeout&&this.timeout.clear()},this.onMouseEnter=()=>{this.setState({isRunning:!1},(()=>{this.timeout&&this.timeout.pause()}))},this.onMouseLeave=()=>{this.setState({isRunning:!0},(()=>{this.timeout&&this.timeout.resume()}))}}componentDidMount(){this.startTimer()}componentDidUpdate(e){if(e.autoDismiss!==this.props.autoDismiss){(this.props.autoDismiss?this.startTimer:this.clearTimer)()}}componentWillUnmount(){this.clearTimer()}render(){const e=this.props,{autoDismiss:n,autoDismissTimeout:r,component:i}=e,o=D(e,["autoDismiss","autoDismissTimeout","component"]),{isRunning:a}=this.state,l=n?this.onMouseEnter:TL,s=n?this.onMouseLeave:TL;return t.createElement(i,Object.assign({autoDismiss:n,autoDismissTimeout:r,isRunning:a,onMouseEnter:l,onMouseLeave:s},o))}}JL.defaultProps={autoDismiss:!1};const UL={Toast:e=>{var{appearance:n="info",autoDismiss:r,autoDismissTimeout:i,children:o,isRunning:a,onDismiss:l=TL,placement:s,transitionDuration:c,transitionState:d,onMouseEnter:u,onMouseLeave:p}=e,m=D(e,["appearance","autoDismiss","autoDismissTimeout","children","isRunning","onDismiss","placement","transitionDuration","transitionState","onMouseEnter","onMouseLeave"]);return t.createElement(FL,Object.assign({appearance:n,placement:s,transitionState:d,transitionDuration:c,onMouseEnter:u,onMouseLeave:p},m),t.createElement(jL,{appearance:n,autoDismiss:r,autoDismissTimeout:i,isRunning:a}),t.createElement(_L,null,o),l?t.createElement(PL,{onClick:l},t.createElement(NL,{className:"react-toast-notifications__toast__dismiss-icon"}),t.createElement(ZL,{className:"react-toast-notifications__toast__dismiss-text"},"Close")):null)},ToastContainer:WL},QL=t.createContext({add:()=>"0",remove:TL,removeAll:TL,update:TL,toasts:[]}),{Consumer:qL,Provider:KL}=QL,eV=!("undefined"==typeof window||!window.document||!window.document.createElement);let tV=class extends f{constructor(){super(...arguments),this.toastNodeRefs=new Map,this.state={toasts:[]},this.getNodeRef=e=>(this.toastNodeRefs.has(e)||this.toastNodeRefs.set(e,t.createRef()),this.toastNodeRefs.get(e)),this.has=e=>!!this.state.toasts.length&&Boolean(this.state.toasts.filter((t=>t.id===e)).length),this.onDismiss=(e,t=TL)=>()=>{t(e),this.remove(e)},this.add=(e,t,n=TL)=>{const r=(null==t?void 0:t.id)?t.id:function(){let e=46656*Math.random()|0,t=46656*Math.random()|0;return e=("000"+e.toString(36)).slice(-3),t=("000"+t.toString(36)).slice(-3),e+t}();if(!this.has(r))return this.setState((n=>{const i=Object.assign({content:e,id:r},t);return{toasts:this.props.newestOnTop?[i,...n.toasts]:[...n.toasts,i]}}),(()=>n(r))),r},this.remove=(e,t=TL)=>{this.has(e)&&this.setState((t=>{const n=t.toasts.filter((t=>t.id!==e));return{toasts:n}}),(()=>{this.toastNodeRefs.delete(e),t(e)}))},this.removeAll=()=>{this.state.toasts.length&&this.state.toasts.forEach((e=>this.remove(e.id)))},this.update=(e,t,n=TL)=>{this.has(e)&&this.setState((n=>{const r=n.toasts,i=r.findIndex((t=>t.id===e)),o=Object.assign(Object.assign({},r[i]),t);return{toasts:[...r.slice(0,i),o,...r.slice(i+1)]}}),(()=>n(e)))}}render(){const{autoDismiss:e,autoDismissTimeout:n,children:r,components:i,placement:o,portalTargetSelector:a,transitionDuration:l}=this.props,{Toast:s,ToastContainer:c}=Object.assign(Object.assign({},UL),i),{add:d,remove:u,removeAll:p,update:m}=this,h=this.state.toasts,g=Boolean(h.length),f=eV?a?document.querySelector(a):document.body:null;return t.createElement(KL,{value:{add:d,remove:u,removeAll:p,update:m,toasts:h}},r,f?k(t.createElement(c,{placement:o,hasToasts:g},t.createElement(xc,{component:null},h.map((r=>{var{appearance:i,autoDismiss:a,content:c,id:d,onDismiss:u}=r,p=D(r,["appearance","autoDismiss","content","id","onDismiss"]);const m=this.getNodeRef(d);return t.createElement(lc,{key:d,appear:!0,mountOnEnter:!0,unmountOnExit:!0,nodeRef:m,timeout:l},(r=>t.createElement("div",{ref:m},t.createElement(JL,Object.assign({appearance:i,autoDismiss:void 0!==a?a:e,autoDismissTimeout:n,component:s,placement:o,transitionDuration:l,transitionState:r,onDismiss:this.onDismiss(d,u)},p),c))))})))),f):t.createElement(c,{placement:o,hasToasts:g}))}};tV.defaultProps={autoDismiss:!1,autoDismissTimeout:5e3,components:UL,newestOnTop:!1,placement:"top-right",transitionDuration:220};const nV=v(WL)`
|
|
5606
5606
|
z-index: ${({theme:e})=>e.depth.toast} !important;
|
|
5607
5607
|
|
|
5608
5608
|
${({placement:e})=>e.includes("center")&&y`
|
|
5609
5609
|
box-sizing: border-box;
|
|
5610
|
-
max-width: ${
|
|
5610
|
+
max-width: ${gL};
|
|
5611
5611
|
|
|
5612
5612
|
@media (min-width: ${F.MOBILE}px) {
|
|
5613
|
-
max-width: ${
|
|
5613
|
+
max-width: ${fL};
|
|
5614
5614
|
}
|
|
5615
5615
|
`}
|
|
5616
|
-
`,
|
|
5616
|
+
`,rV=t=>{var{children:n}=t,r=D(t,["children"]);const i={pt:r.placement.includes("top")?3:0,pb:r.placement.includes("bottom")?3:0};return e.createElement(nV,Object.assign({},r),e.createElement(Ua,Object.assign({},i),n))},iV={appearance:"info",autoDismiss:!1,autoDismissTimeout:0,isRunning:!0,onDismiss:()=>{},onMouseEnter:()=>{},onMouseLeave:()=>{},placement:"top-center",transitionDuration:0,transitionState:"entered",children:null},oV=e=>t.createElement($L,Object.assign({},iV,e));oV.Provider=t=>{var{children:n}=t,r=D(t,["children"]);return e.createElement(tV,Object.assign({},r,{components:Object.assign({Toast:$L,ToastContainer:rV},r.components)}),n)},oV.useToasts=()=>{const e=c(QL);if(!e)throw Error("The `useToasts` hook must be called from a descendent of the `ToastProvider`.");return{addToast:e.add,removeToast:e.remove,removeAllToasts:e.removeAll,updateToast:e.update,toastStack:e.toasts}};const aV=v.div`
|
|
5617
5617
|
position: relative;
|
|
5618
5618
|
width: 40px;
|
|
5619
5619
|
height: 22px;
|
|
5620
|
-
`,
|
|
5620
|
+
`,lV=v.span`
|
|
5621
5621
|
position: absolute;
|
|
5622
5622
|
top: 50%;
|
|
5623
5623
|
left: 3px;
|
|
@@ -5630,19 +5630,19 @@ object-assign
|
|
|
5630
5630
|
${({checked:e,disabled:t,theme:n})=>t&&e?zo(n.palette.primary.base,.6):t&&!e?zo(n.palette.divider,.6):e?n.palette.primary.dark:n.palette.divider};
|
|
5631
5631
|
box-shadow: ${({theme:e})=>No(3,e.palette.action.shadowOpacity,e.palette.action.shadowBase)};
|
|
5632
5632
|
transition: all 0.2s ease-in-out;
|
|
5633
|
-
`,
|
|
5633
|
+
`,sV=v.div`
|
|
5634
5634
|
position: absolute;
|
|
5635
5635
|
width: 100%;
|
|
5636
5636
|
word-break: break-all;
|
|
5637
5637
|
white-space: nowrap;
|
|
5638
5638
|
transition: all 0.2s ease-in-out;
|
|
5639
|
-
`,
|
|
5639
|
+
`,cV=v(sV)`
|
|
5640
5640
|
padding-left: 8px;
|
|
5641
5641
|
opacity: 0;
|
|
5642
|
-
`,
|
|
5642
|
+
`,dV=v(sV)`
|
|
5643
5643
|
padding-right: 8px;
|
|
5644
5644
|
opacity: 1;
|
|
5645
|
-
`,
|
|
5645
|
+
`,uV=v.label`
|
|
5646
5646
|
position: absolute;
|
|
5647
5647
|
top: 0;
|
|
5648
5648
|
left: 0;
|
|
@@ -5660,13 +5660,13 @@ object-assign
|
|
|
5660
5660
|
transition: all 0.2s ease-in-out;
|
|
5661
5661
|
|
|
5662
5662
|
${({checked:e})=>e&&y`
|
|
5663
|
-
& > ${
|
|
5663
|
+
& > ${lV} {
|
|
5664
5664
|
left: calc(100% - 14px - 5px);
|
|
5665
5665
|
}
|
|
5666
|
-
& > ${
|
|
5666
|
+
& > ${cV} {
|
|
5667
5667
|
opacity: 1;
|
|
5668
5668
|
}
|
|
5669
|
-
& > ${
|
|
5669
|
+
& > ${dV} {
|
|
5670
5670
|
opacity: 0;
|
|
5671
5671
|
}
|
|
5672
5672
|
`}
|
|
@@ -5676,11 +5676,11 @@ object-assign
|
|
|
5676
5676
|
border-color: ${({theme:e})=>e.palette.primary.base};
|
|
5677
5677
|
}
|
|
5678
5678
|
`}
|
|
5679
|
-
`,
|
|
5679
|
+
`,pV=v.input`
|
|
5680
5680
|
width: 0;
|
|
5681
5681
|
height: 0;
|
|
5682
5682
|
visibility: hidden;
|
|
5683
|
-
`,
|
|
5683
|
+
`,mV=e.forwardRef((function(t,n){const{checked:r=!1,disabled:i=!1,onChange:o,width:a="48px",checkedText:l="",unCheckedText:s="",inputRef:c,children:d}=t;return"production"!==process.env.NODE_ENV&&d&&console.warn("[ingred-ui] ToggleButton: childrenによるラベル指定は非推奨です。別の手段でラベルを指定してください。"),e.createElement(aV,{ref:n,width:a},e.createElement(uV,{checked:r,disabled:i,width:a},e.createElement(pV,{ref:c,checked:r,type:"checkbox",readOnly:null==o,disabled:i,onChange:o}),e.createElement(cV,null,e.createElement(ke,{component:"div",color:i?"disabled":"primary",align:"left",size:"xs",weight:"bold"},l)),e.createElement(dV,null,e.createElement(ke,{component:"div",color:i?"disabled":"secondary",align:"right",size:"xs",weight:"bold"},s)),e.createElement(lV,{checked:r,disabled:i})))})),hV=v.div``,gV=v.span`
|
|
5684
5684
|
background-color: ${({active:e,theme:t})=>e?t.palette.primary.base:t.palette.white};
|
|
5685
5685
|
border: 1px solid
|
|
5686
5686
|
${({theme:e,active:t})=>t?e.palette.primary.dark:e.palette.neutral.lighter};
|
|
@@ -5688,26 +5688,26 @@ object-assign
|
|
|
5688
5688
|
height: ${({theme:e})=>3*e.spacing}px;
|
|
5689
5689
|
width: ${({theme:e})=>3*e.spacing}px;
|
|
5690
5690
|
outline: none;
|
|
5691
|
-
`,
|
|
5691
|
+
`,fV=v.div`
|
|
5692
5692
|
display: grid;
|
|
5693
5693
|
grid-template-columns: 38px repeat(24, 1fr);
|
|
5694
5694
|
grid-gap: ${({theme:e})=>e.spacing/2}px;
|
|
5695
5695
|
align-items: center;
|
|
5696
5696
|
justify-items: center;
|
|
5697
5697
|
width: fit-content;
|
|
5698
|
-
`,
|
|
5698
|
+
`,bV=v.div`
|
|
5699
5699
|
height: 24px;
|
|
5700
5700
|
text-align: center;
|
|
5701
5701
|
background-color: ${({theme:e})=>e.palette.neutral.softLight};
|
|
5702
5702
|
border-radius: ${({theme:e})=>e.spacing/2}px;
|
|
5703
5703
|
border: 1px solid ${({theme:e})=>e.palette.neutral.lighter};
|
|
5704
|
-
`,
|
|
5704
|
+
`,vV=v(bV)`
|
|
5705
5705
|
width: 38px;
|
|
5706
|
-
`,
|
|
5706
|
+
`,xV=v(bV)`
|
|
5707
5707
|
width: 24px;
|
|
5708
|
-
`,
|
|
5708
|
+
`,yV=v(bV)`
|
|
5709
5709
|
border: none;
|
|
5710
|
-
`,
|
|
5710
|
+
`,wV=e=>{if(!e)return Array(7).fill(Array(24).fill("1"));const t=(e=>{if(!e)return Array(7).fill(Array(24).fill("1")).join("");let t="";for(const n of e)switch(n){case"0":t+="0000";break;case"1":t+="0001";break;case"2":t+="0010";break;case"3":t+="0011";break;case"4":t+="0100";break;case"5":t+="0101";break;case"6":t+="0110";break;case"7":t+="0111";break;case"8":t+="1000";break;case"9":t+="1001";break;case"a":t+="1010";break;case"b":t+="1011";break;case"c":t+="1100";break;case"d":t+="1101";break;case"e":t+="1110";break;case"f":t+="1111";break;default:return""}return t})(e),n=[];for(let e=0;e<7;e++){n[e]=[];for(let r=0;r<24;r++)n[e][r]=t.charAt(24*e+r)}return n},CV=Array.from(Array(24)).map(((e,t)=>t)),EV=({weekList:e,weekTime:n,WeekTimeItem:r,interactive:i=!1,isWithinHoverRange:o,onMouseOver:a,onMouseDown:s})=>{const c=l((()=>wV(n)),[n]),d=(e,t)=>()=>{null==a||a(e,t)},u=(e,t,n)=>()=>{null==s||s(e,t,n)};return t.createElement(fV,null,t.createElement(yV,null),CV.map((e=>t.createElement(xV,{key:e},e))),c.map(((n,a)=>t.createElement(b,{key:a},t.createElement(vV,null,e[a]),n.map(((n,l)=>t.createElement(r,Object.assign({key:`${a}-${l}`,active:"1"===n,hover:!!o&&o(a,l)},i?{"aria-label":`${e[a]} ${String(l).padStart(2,"0")}:00`,"aria-pressed":"1"===n}:{},{onMouseOver:d(a,l),onMouseDown:u(a,l,n)}))))))))},IV=t.forwardRef((function(e,n){const r=Cd({props:e,name:"WeekTime"}),{weekList:i,weekTime:o}=r;return t.createElement(hV,{ref:n},t.createElement(EV,{weekTime:o,weekList:i,WeekTimeItem:gV}))})),kV=v.div``,MV=v.button`
|
|
5711
5711
|
background-color: ${({active:e,hover:t,theme:n})=>t?n.palette.primary.highlight:e?n.palette.primary.base:n.palette.white};
|
|
5712
5712
|
border: 1px solid
|
|
5713
5713
|
${({theme:e,active:t,hover:n})=>n?e.palette.primary.softLight:t?e.palette.primary.dark:e.palette.neutral.lighter};
|
|
@@ -5716,5 +5716,5 @@ object-assign
|
|
|
5716
5716
|
height: ${({theme:e})=>3*e.spacing}px;
|
|
5717
5717
|
width: ${({theme:e})=>3*e.spacing}px;
|
|
5718
5718
|
outline: none;
|
|
5719
|
-
|
|
5719
|
+
`,$V=t.forwardRef((function(e,n){const r=Cd({props:e,name:"WeekTimeSelector"}),{weekList:o,weekTime:s,errorText:c,onChange:d}=r,u=l((()=>wV(s)),[s]),[p,m]=i({weekIndex:0,timeIndex:0}),[h,g]=i({weekIndex:0,timeIndex:0}),[f,b]=i("none"),[v,x]=i("1"),y=(e,t,n)=>{if("choosing"===f){const r=((e,t,n,r,i,o)=>{const a=[...o],l=Math.min(e,n),s=Math.max(e,n),c=Math.min(t,r),d=Math.max(t,r);for(let e=l;e<=s;e++){const t=a[e].map(((t,n)=>e>=l&&e<=s&&n>=c&&n<=d?i:t));a[e]=t}return a})(p.weekIndex,p.timeIndex,e,t,n,[...u]);b("none"),null==d||d((e=>{let t="";for(let n=0;n<7;n++)for(let r=0;r<24;r++)t+=e[n][r];return(e=>{let t="";for(let n=0;n<e.length;n+=4)switch(e.substr(n,4)){case"0000":t+="0";break;case"0001":t+="1";break;case"0010":t+="2";break;case"0011":t+="3";break;case"0100":t+="4";break;case"0101":t+="5";break;case"0110":t+="6";break;case"0111":t+="7";break;case"1000":t+="8";break;case"1001":t+="9";break;case"1010":t+="a";break;case"1011":t+="b";break;case"1100":t+="c";break;case"1101":t+="d";break;case"1110":t+="e";break;case"1111":t+="f";break;default:return""}return t})(t)})(r))}else"none"===f&&(m({weekIndex:e,timeIndex:t}),g({weekIndex:e,timeIndex:t}),b("choosing"))},w=()=>{"choosing"===f&&y(h.weekIndex,h.timeIndex,v)};return a((()=>(addEventListener("mouseup",w),()=>{removeEventListener("mouseup",w)}))),t.createElement(kV,{ref:n},t.createElement(EV,{weekTime:s,weekList:o,WeekTimeItem:MV,interactive:!0,isWithinHoverRange:(e,t)=>{if("choosing"===f){const n=Math.min(p.weekIndex,h.weekIndex),r=Math.max(p.weekIndex,h.weekIndex),i=Math.min(p.timeIndex,h.timeIndex),o=Math.max(p.timeIndex,h.timeIndex);return e>=n&&e<=r&&t>=i&&t<=o}return!1},onMouseOver:(e,t)=>{"none"!==f&&g({weekIndex:e,timeIndex:t})},onMouseDown:(e,t,n)=>{const r="1"===n?"0":"1";x(r),y(e,t,r)}}),c&&t.createElement(Ua,{pt:1},t.createElement(nd,null,c)))}));export{Ze as ADVANCED_FILTER_CONSTANTS,be as Accordion,Le as ActionButton,ou as AdvancedFilter,tu as AdvancedFilterConfigPanel,cn as AdvancedFilterTrigger,Bu as Backdrop,jd as Badge,Wu as Banner,eh as BarChart,F as BreakPoint,cl as Button,Qu as ButtonGroup,Fm as CHART_DEFAULT_HEIGHT,Tp as Calendar,am as CalendarRange,lm as Card,Kd as Checkbox,gh as CheckboxCard,fh as ClickAwayListener,Ah as ConfirmModal,Y as ContainerBreakPoint,Gh as ContextMenu,Sa as ContextMenu2,Za as ContextMenu2ButtonControlsItem,Dt as ContextMenu2ButtonItem,Ro as ContextMenu2CheckItem,Da as ContextMenu2Container,Ra as ContextMenu2HeadingItem,Na as ContextMenu2HelpTextItem,Ta as ContextMenu2SeparatorItem,sa as ContextMenu2SortableFixedItem,ea as ContextMenu2SortableGroup,ia as ContextMenu2SortableItem,_o as ContextMenu2SwitchItem,ya as ContextMenu2TextInputItem,Wo as ContextMenu2TriggerItem,Gx as CreatableSelect,pu as DATE_OPERATORS,Be as DEFAULT_PERSIST_OPTION_LABEL,Zy as DataTable,Jw as DataTable2,nC as DataTable2ActionButton,Kw as DataTable2Body,tC as DataTable2Cell,Qw as DataTable2Column,qw as DataTable2ColumnLabel,Uw as DataTable2Head,rC as DataTable2InlineEditor,iC as DataTable2InlineSelectEditor,eC as DataTable2Row,HC as DateField,_C as DateField2,Id as DatePicker,RC as DateRangeField,YC as DateRangeField2,XC as DateRangePicker,zh as Divider,rE as Drawer,uE as DropdownButton,LE as DualListBox,$I as DualListBox2,CI as DualListBox2Accordion,uI as DualListBox2Item,xI as DualListBox2Section,nd as ErrorText,Lc as Fade,VI as FileUploader,qI as FilterComboBox,ru as FilterPositionCalculator,sk as FilterSelectInput,Hk as FilterTagInput,Sk as FixedPanel,de as Flex,Nk as FloatingTip,Yk as FullSizeConfirmModal,Jk as Grow,le as Icon,eM as IconText,va as Input,Ay as ItemEmpty,rM as LoadingBar,wd as LocaleProvider,Ph as Menu,Th as MenuList,$h as Modal,TM as MultipleFilter,uu as NUMBER_OPERATORS,_$ as NavigationRail,JM as NavigationRailContext,r$ as NotificationBadge,hu as PRESET_OPERATORS,Ey as Pager,Bh as Popover,Mh as Portal,ay as RadioButton,G$ as RadioCard,_ as Radius,Dc as SELECT2_SIZES,mu as SELECTION_OPERATORS,Y$ as ScrollArea,_x as Select,Qc as Select2,qc as Select2Option,Kc as Select2OptionGroup,ed as Select2Separator,P as Shadow,wA as Slide,hA as Slider,bA as SliderField,MA as Snackbar,G as Space,Ua as Spacer,rl as Spinner,AA as SplitAnnotation,ZA as Switch,du as TEXT_OPERATORS,QA as Table,cL as Tabs,ze as Tag,wM as TextField,R as ThemeProvider,mL as TimeField,hL as TimeField2,oV as Toast,mV as ToggleButton,Sc as Tooltip,ke as Typography,IV as WeekTime,$V as WeekTimeSelector,ku as applyFilter,Mu as applyMultipleFilters,Iu as applyOperatorToValue,j as breakpointPrimitives,Mt as buildFilterSlots,xu as changeOperatorLabel,Hu as changeValueLabel,tA as clamp,z as colors,bu as combineOperators,Lu as combineValues,Nm as computeMaxStackedTotal,zm as computeYTicks,fu as createOperator,q as createTheme,Au as createValue,K as defaultTheme,xd as enUS,$u as evaluateFilterConditions,we as fontSize,th as formatDateAsMonthDay,st as generateTagText,ct as generateTagTitle,pt as getAvailableTypes,ee as getChartPalette,te as getChartSeriesColors,nA as getClampedValue,kt as getConfiguredFilters,mt as getFilterTypeLabel,Iy as getFilteredItems,Je as getInitialPersistValue,aA as getKeyboardValue,zu as getLabelsForValues,oA as getNearestThumbIndex,rA as getPercentage,Ue as getPersistOptionLabel,gu as getPresetOperators,yu as getPresetOperatorsWithLabels,Et as getPresetSlotId,ye as getResponsiveFontSizeCss,ht as getTagBoldText,iA as getValueFromPosition,Ru as getValueLabels,Du as getValueStrings,Jm as hasChartData,It as isConfiguredFilter,Ye as isCustomOperator,Xe as isPersistOptionEnabled,Fe as isRangeOperator,xe as isResponsiveObject,dt as isValidFilterConfig,ut as isValidFilterType,bd as jaJP,rh as mapTimeSeriesChartData,Nu as mergeValues,Eu as normalizeForSearch,vu as overrideOperatorLabels,Vu as overrideValueLabels,Z as palette,cA as preventScroll,lA as preventTextSelection,Ie as resolveFontWeight,sA as restoreTextSelection,wu as selectOperators,Cu as selectOperatorsByIndex,Ou as selectValues,Su as selectValuesByIndex,Tu as sortValues,vI as toGroupedItems,W as trimVertical,nu as useAdvancedFilterState,Ea as useContextMenu2Anchor,iu as useFilterMenuPosition,ky as useFilterState,XM as useNavigationRail,dA as useSlider,uA as useSliderScale,ne as useTheme,vd as zhCN};
|
|
5720
5720
|
//# sourceMappingURL=index.es.js.map
|