@efficiency-point/design-system 0.0.14 → 0.0.15
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/index.cjs +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.es.js +20 -2
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});let e=require("react/jsx-runtime"),t=require("react"),n=require("@tanstack/react-table"),r=require("react-dom"),i=require("zustand");var a={badge:`_badge_1pk53_1`,sm:`_sm_1pk53_3`,md:`_md_1pk53_5`,neutral:`_neutral_1pk53_7`,info:`_info_1pk53_9`,success:`_success_1pk53_11`,warning:`_warning_1pk53_13`,error:`_error_1pk53_15`,dot:`_dot_1pk53_17`,icon:`_icon_1pk53_19`,label:`_label_1pk53_21`},o=({children:t,variant:n=`neutral`,size:r=`md`,dot:i=!1,icon:o,className:s=``})=>(0,e.jsxs)(`span`,{className:`${a.badge} ${a[n]} ${a[r]} ${s}`,children:[i&&(0,e.jsx)(`span`,{className:a.dot,"aria-hidden":`true`}),o&&(0,e.jsx)(`span`,{className:a.icon,"aria-hidden":`true`,children:o}),(0,e.jsx)(`span`,{className:a.label,children:t})]}),s={loader:`_loader_1tjcf_1`,"ds-spin":`_ds-spin_1tjcf_1`,primary:`_primary_1tjcf_21`,secondary:`_secondary_1tjcf_23`,light:`_light_1tjcf_25`,danger:`_danger_1tjcf_27`},c=({variant:t=`primary`,label:n=`Загрузка`,className:r=``,decorative:i=!1})=>(0,e.jsx)(`span`,{className:`${s.loader} ${s[t]} ${r}`,role:i?void 0:`status`,"aria-label":i?void 0:n,"aria-hidden":i||void 0}),l={button:`_button_1jisp_1`,sm:`_sm_1jisp_31`,md:`_md_1jisp_33`,lg:`_lg_1jisp_35`,primary:`_primary_1jisp_37`,secondary:`_secondary_1jisp_39`,outline:`_outline_1jisp_41`,ghost:`_ghost_1jisp_45`,empty:`_empty_1jisp_57`,destructive:`_destructive_1jisp_67`,destructiveOutline:`_destructiveOutline_1jisp_69`},u=(0,t.forwardRef)(({children:t,variant:n=`primary`,size:r=`md`,isLoading:i=!1,loadingLabel:a=`Загрузка`,disabled:o,type:s=`button`,className:u=``,...d},f)=>(0,e.jsx)(`button`,{ref:f,className:`${l.button} ${l[n]} ${l[r]} ${u}`,disabled:o||i,"aria-busy":i||void 0,...d,type:s,children:i?(0,e.jsx)(c,{variant:`light`,label:a}):t}));u.displayName=`DSButton`;var d={label:`_label_1lsqq_1`,required:`_required_1lsqq_23`,error:`_error_1lsqq_25`,optional:`_optional_1lsqq_33`,hint:`_hint_1lsqq_35`,disabled:`_disabled_1lsqq_47`,message:`_message_1lsqq_55`,success:`_success_1lsqq_71`},f=({children:t,required:n=!1,optionalText:r,disabled:i=!1,className:a=``,...o})=>(0,e.jsxs)(`label`,{className:`${d.label} ${i?d.disabled:``} ${a}`,...o,children:[(0,e.jsx)(`span`,{children:t}),n&&(0,e.jsx)(`span`,{className:d.required,"aria-hidden":`true`,children:`*`}),r&&(0,e.jsx)(`span`,{className:d.optional,children:r})]}),p=({children:t,variant:n=`hint`,id:r,live:i=!1,className:a=``})=>(0,e.jsx)(`span`,{id:r,className:`${d.message} ${d[n]} ${a}`,role:i&&n===`error`?`alert`:void 0,"aria-live":i&&n!==`error`?`polite`:void 0,children:t}),m={wrapper:`_wrapper_1gq36_1`,label:`_label_1gq36_3`,input:`_input_1gq36_5`,control:`_control_1gq36_7`,disabled:`_disabled_1gq36_13`,controlError:`_controlError_1gq36_17`},h=({checked:n,onChange:r,label:i,hint:a,error:o,disabled:s=!1,readOnly:c=!1,className:l=``,name:u,id:d,indeterminate:f=!1,...h})=>{let g=(0,t.useId)(),_=d??`ds-checkbox-${u??g}`,v=(0,t.useRef)(null),y=a?`${_}-hint`:void 0,b=o?`${_}-error`:void 0;return(0,t.useEffect)(()=>{v.current&&(v.current.indeterminate=f&&!n)},[n,f]),(0,e.jsxs)(`div`,{className:`${m.wrapper} ${l}`,children:[(0,e.jsxs)(`label`,{className:`${m.label} ${s?m.disabled:``}`,htmlFor:_,children:[(0,e.jsx)(`input`,{ref:v,id:_,name:u,type:`checkbox`,checked:n,disabled:s,"aria-readonly":c||void 0,"aria-invalid":!!o,"aria-describedby":[y,b].filter(Boolean).join(` `)||void 0,className:m.input,onChange:e=>{c||r?.(e.target.checked,e)},...h}),(0,e.jsx)(`span`,{className:`${m.control} ${o?m.controlError:``}`,"aria-hidden":`true`,children:f&&!n?`−`:n?`✓`:``}),i&&(0,e.jsx)(`span`,{children:i})]}),a&&!o&&(0,e.jsx)(p,{id:y,children:a}),o&&(0,e.jsx)(p,{id:b,variant:`error`,children:o})]})},g={wrapper:`_wrapper_1528c_1`,trigger:`_trigger_1528c_17`,nav:`_nav_1528c_53`,day:`_day_1528c_55`,monthSelect:`_monthSelect_1528c_57`,yearInput:`_yearInput_1528c_59`,timeInput:`_timeInput_1528c_61`,value:`_value_1528c_85`,placeholder:`_placeholder_1528c_93`,error:`_error_1528c_101`,panel:`_panel_1528c_109`,calendarHeader:`_calendarHeader_1528c_135`,weekdays:`_weekdays_1528c_225`,days:`_days_1528c_227`,outside:`_outside_1528c_263`,selected:`_selected_1528c_271`,timeLabel:`_timeLabel_1528c_291`},_=[`Пн`,`Вт`,`Ср`,`Чт`,`Пт`,`Сб`,`Вс`],v=[`Январь`,`Февраль`,`Март`,`Апрель`,`Май`,`Июнь`,`Июль`,`Август`,`Сентябрь`,`Октябрь`,`Ноябрь`,`Декабрь`],y=e=>String(e).padStart(2,`0`),b=e=>new Date(e.getFullYear(),e.getMonth(),e.getDate()),x=(e,t)=>{if(!e)return``;let n=`${e.getFullYear()}-${y(e.getMonth()+1)}-${y(e.getDate())}`,r=`${y(e.getHours())}:${y(e.getMinutes())}`;return t===`date`?n:t===`time`?r:`${n}T${r}`},S=(e,t)=>{if(!e)return null;if(t===`time`){let t=/^(\d{2}):(\d{2})$/.exec(e);if(!t)return null;let n=Number(t[1]),r=Number(t[2]);if(n>23||r>59)return null;let i=new Date;return i.setHours(n,r,0,0),i}let n=new Date(t===`date`?`${e}T00:00`:e);return Number.isNaN(n.getTime())?null:n},C=(e,t)=>{if(!e)return``;let n=`${y(e.getDate())}.${y(e.getMonth()+1)}.${e.getFullYear()}`,r=`${y(e.getHours())}:${y(e.getMinutes())}`;return t===`date`?n:t===`time`?r:`${n} ${r}`},w=e=>{let t=new Date(e.getFullYear(),e.getMonth(),1),n=(t.getDay()+6)%7,r=new Date(t);return r.setDate(t.getDate()-n),Array.from({length:42},(e,t)=>{let n=new Date(r);return n.setDate(r.getDate()+t),n})},T=(e,t)=>!!(e&&e.getFullYear()===t.getFullYear()&&e.getMonth()===t.getMonth()&&e.getDate()===t.getDate()),E=(e,t,n)=>{let r=b(e).getTime();return!!(t&&r<b(t).getTime()||n&&r>b(n).getTime())},D=({value:n,onChange:r,mode:i=`date`,label:a,placeholder:o,hint:s,error:c,disabled:l=!1,readOnly:u=!1,required:d=!1,min:m,max:h,id:y,name:b,className:D=``})=>{let O=(0,t.useId)(),k=y??`ds-date-time-${b??O}`,A=s?`${k}-hint`:void 0,j=c?`${k}-error`:void 0,M=(0,t.useRef)(null),N=(0,t.useRef)(null),[P,F]=(0,t.useState)(!1),[I,L]=(0,t.useState)(n??new Date),[R,ee]=(0,t.useState)(x(n,`time`)),te=(0,t.useMemo)(()=>w(I),[I]),z=i!==`time`,ne=i!==`date`;(0,t.useEffect)(()=>{n&&L(n),ee(x(n,`time`))},[n]),(0,t.useEffect)(()=>{let e=e=>{M.current?.contains(e.target)||F(!1)},t=e=>{e.key===`Escape`&&(F(!1),N.current?.focus())};return document.addEventListener(`mousedown`,e),document.addEventListener(`keydown`,t),()=>{document.removeEventListener(`mousedown`,e),document.removeEventListener(`keydown`,t)}},[]);let re=e=>{if(E(e,m,h))return;let t=new Date(e);t.setHours(n?.getHours()??0,n?.getMinutes()??0,0,0),r?.(t),i===`date`&&F(!1)},ie=e=>{if(ee(e),!e){r?.(null);return}let t=S(e,`time`);if(!t)return;let a=new Date(i===`datetime`?n??I:new Date);a.setHours(t.getHours(),t.getMinutes(),0,0),!(m&&a<m||h&&a>h)&&r?.(a)},B=o??(i===`date`?`Выберите дату`:i===`time`?`Введите время`:`Выберите дату и время`),ae=[A,j].filter(Boolean).join(` `)||void 0;return(0,e.jsxs)(`div`,{ref:M,className:`${g.wrapper} ${D}`,children:[a&&(0,e.jsx)(f,{htmlFor:k,required:d,disabled:l,children:a}),(0,e.jsxs)(`button`,{ref:N,id:k,name:b,type:`button`,className:`${g.trigger} ${c?g.error:``}`,disabled:l,"aria-readonly":u||void 0,"aria-expanded":P,"aria-haspopup":`dialog`,"aria-describedby":ae,onClick:()=>{u||F(e=>!e)},children:[(0,e.jsx)(`span`,{className:n?g.value:g.placeholder,children:C(n,i)||B}),(0,e.jsx)(`span`,{"aria-hidden":`true`,children:`▾`})]}),P&&!u&&(0,e.jsxs)(`div`,{className:g.panel,role:`dialog`,"aria-label":a??B,children:[z&&(0,e.jsxs)(e.Fragment,{children:[(0,e.jsxs)(`div`,{className:g.calendarHeader,children:[(0,e.jsx)(`button`,{type:`button`,className:g.nav,"aria-label":`Предыдущий месяц`,onClick:()=>L(new Date(I.getFullYear(),I.getMonth()-1,1)),children:`‹`}),(0,e.jsx)(`select`,{className:g.monthSelect,"aria-label":`Месяц`,value:I.getMonth(),onChange:e=>L(new Date(I.getFullYear(),Number(e.target.value),1)),children:v.map((t,n)=>(0,e.jsx)(`option`,{value:n,children:t},t))}),(0,e.jsx)(`input`,{className:g.yearInput,type:`number`,"aria-label":`Год`,value:I.getFullYear(),onChange:e=>L(new Date(Number(e.target.value),I.getMonth(),1))}),(0,e.jsx)(`button`,{type:`button`,className:g.nav,"aria-label":`Следующий месяц`,onClick:()=>L(new Date(I.getFullYear(),I.getMonth()+1,1)),children:`›`})]}),(0,e.jsx)(`div`,{className:g.weekdays,children:_.map(t=>(0,e.jsx)(`span`,{children:t},t))}),(0,e.jsx)(`div`,{className:g.days,children:te.map(t=>{let r=T(n,t);return(0,e.jsx)(`button`,{type:`button`,className:`${g.day} ${t.getMonth()===I.getMonth()?``:g.outside} ${r?g.selected:``}`,disabled:E(t,m,h),"aria-pressed":r,onClick:()=>re(t),children:t.getDate()},t.toISOString())})})]}),ne&&(0,e.jsxs)(`label`,{className:g.timeLabel,children:[(0,e.jsx)(`span`,{children:`Время`}),(0,e.jsx)(`input`,{className:g.timeInput,type:`time`,value:R,onChange:e=>ie(e.target.value)})]})]}),s&&!c&&(0,e.jsx)(p,{id:A,children:s}),c&&(0,e.jsx)(p,{id:j,variant:`error`,children:c})]})},O={root:`_root_1q42e_1`,legend:`_legend_1q42e_3`,range:`_range_1q42e_5`},k=e=>!!(e.from&&e.to&&e.from.getTime()<=e.to.getTime()),A=({value:t,onChange:n,onDraftChange:r,mode:i=`date`,fromLabel:a=`От`,toLabel:o=`До`,hint:s,error:c,min:l,max:u,disabled:d=!1,readOnly:f=!1,required:m=!1,className:h=``})=>{let g=c??(t.from&&t.to&&t.from>t.to?`Дата «От» не может быть позже даты «До»`:void 0),_=e=>{r?.(e),k(e)&&n?.(e)};return(0,e.jsxs)(`fieldset`,{className:`${O.root} ${h}`,disabled:d,children:[(0,e.jsxs)(`div`,{className:O.range,children:[(0,e.jsx)(D,{value:t.from,mode:i===`datetime`?`datetime`:i,label:a,min:l,max:t.to??u,disabled:d,readOnly:f,required:m,error:g,onChange:e=>_({...t,from:e})}),(0,e.jsx)(D,{value:t.to,mode:i===`datetime`?`datetime`:i,label:o,min:t.from??l,max:u,disabled:d,readOnly:f,required:m,error:g,onChange:e=>_({...t,to:e})})]}),s&&!g&&(0,e.jsx)(p,{children:s})]})},j={group:`_group_1fs9e_1`,skeleton:`_skeleton_1fs9e_3`,text:`_text_1fs9e_5`,rectangular:`_rectangular_1fs9e_7`,circular:`_circular_1fs9e_9`,animated:`_animated_1fs9e_11`,"ds-skeleton":`_ds-skeleton_1fs9e_1`},M=({variant:t=`text`,width:n=`100%`,height:r,lines:i=1,animated:a=!0,className:o=``})=>(0,e.jsx)(`span`,{className:`${j.group} ${o}`,"aria-hidden":`true`,children:Array.from({length:Math.max(1,i)},(o,s)=>(0,e.jsx)(`span`,{className:`${j.skeleton} ${j[t]} ${a?j.animated:``}`,style:{width:s===i-1&&i>1?`70%`:n,height:r}},s))}),N={wrapper:`_wrapper_dkn63_1`,label:`_label_dkn63_17`,container:`_container_dkn63_29`,trigger:`_trigger_dkn63_37`,disabledText:`_disabledText_dkn63_39`,value:`_value_dkn63_109`,placeholder:`_placeholder_dkn63_111`,chevron:`_chevron_dkn63_137`,chevronOpen:`_chevronOpen_dkn63_163`,menu:`_menu_dkn63_171`,option:`_option_dkn63_207`,selected:`_selected_dkn63_245`,message:`_message_dkn63_265`,error:`_error_dkn63_267`,errorState:`_errorState_dkn63_293`},P=(e,t,n)=>{for(let r=0;r<e.length;r+=1){let i=(t+r*n+e.length)%e.length;if(!e[i]?.disabled)return i}return-1},F=({options:n,value:r,onChange:i,placeholder:a=`Выберите опцию`,disabled:o=!1,stringWhileDisabled:s=!1,label:c,error:l,hint:u,className:d=``,name:f,id:p,needMark:m=!0,maxMenuHeight:h})=>{let g=(0,t.useId)(),_=p??`ds-dropdown-${f??g}`,[v,y]=(0,t.useState)(!1),b=(0,t.useRef)(null),x=(0,t.useRef)(null),S=(0,t.useRef)([]),C=(0,t.useMemo)(()=>n.find(e=>e.value===r),[n,r]),w=u?`${_}-hint`:void 0,T=l?`${_}-error`:void 0,E=[w,T].filter(Boolean).join(` `)||void 0,D=o&&s;(0,t.useEffect)(()=>{let e=e=>{b.current?.contains(e.target)||y(!1)},t=e=>{e.key===`Escape`&&v&&(y(!1),x.current?.focus())};return document.addEventListener(`mousedown`,e),document.addEventListener(`keydown`,t),()=>{document.removeEventListener(`mousedown`,e),document.removeEventListener(`keydown`,t)}},[v]);let O=(e,t)=>{let r=P(n,e,t);S.current[r]?.focus(),S.current[r]?.scrollIntoView({block:`nearest`})},k=e=>{e.disabled||(i?.(e.value,e),y(!1),x.current?.focus())};return(0,e.jsxs)(`div`,{ref:b,className:[N.wrapper,l?N.errorState:``,d].filter(Boolean).join(` `),children:[c&&(0,e.jsx)(`label`,{htmlFor:D?void 0:_,className:N.label,children:c}),(0,e.jsx)(`div`,{className:N.container,children:D?(0,e.jsx)(`div`,{id:_,className:N.disabledText,"aria-describedby":E,children:C?.label??a}):(0,e.jsxs)(e.Fragment,{children:[(0,e.jsxs)(`button`,{ref:x,id:_,type:`button`,name:f,className:N.trigger,disabled:o,"aria-haspopup":`listbox`,"aria-expanded":v,"aria-controls":`${_}-listbox`,"aria-describedby":E,"aria-invalid":!!l,onClick:()=>y(e=>!e),onKeyDown:e=>{if(e.key===`ArrowDown`||e.key===`ArrowUp`){e.preventDefault(),y(!0);let t=e.key===`ArrowDown`?1:-1;requestAnimationFrame(()=>O(e.key===`ArrowDown`?0:n.length-1,t))}},children:[(0,e.jsx)(`span`,{className:C?N.value:N.placeholder,children:C?.label??a}),(0,e.jsx)(`span`,{className:`${N.chevron} ${v?N.chevronOpen:``}`,"aria-hidden":`true`,children:(0,e.jsx)(`svg`,{viewBox:`0 0 20 20`,fill:`none`,children:(0,e.jsx)(`path`,{d:`M5 7.5L10 12.5L15 7.5`,stroke:`currentColor`,strokeWidth:`1.8`,strokeLinecap:`round`,strokeLinejoin:`round`})})})]}),v&&(0,e.jsx)(`ul`,{id:`${_}-listbox`,className:N.menu,role:`listbox`,"aria-label":c,style:{maxHeight:h},children:n.map((t,i)=>{let a=t.value===r;return(0,e.jsx)(`li`,{role:`presentation`,children:(0,e.jsxs)(`button`,{ref:e=>{S.current[i]=e},type:`button`,role:`option`,"aria-selected":a,disabled:t.disabled,className:`${N.option} ${a?N.selected:``}`,onClick:()=>k(t),onKeyDown:e=>{if((e.key===`ArrowDown`||e.key===`ArrowUp`)&&(e.preventDefault(),O(i+(e.key===`ArrowDown`?1:-1),e.key===`ArrowDown`?1:-1)),e.key===`Tab`&&y(!1),e.key===`Home`||e.key===`End`){e.preventDefault();let t=e.key===`Home`?1:-1;O(e.key===`Home`?0:n.length-1,t)}},children:[(0,e.jsx)(`span`,{children:t.label}),a&&m&&(0,e.jsx)(`span`,{"aria-hidden":`true`,children:`✓`})]})},t.value)})})]})}),u&&!l&&(0,e.jsx)(`span`,{id:w,className:N.message,children:u}),l&&(0,e.jsx)(`span`,{id:T,className:N.error,children:l})]})},I=e=>`${e.id}:${e.direction}`,L=({options:t,value:n,onChange:r,label:i=`Сортировка`,placeholder:a=`Выберите сортировку`,disabled:o=!1,className:s})=>{let c=t.flatMap(e=>[{value:I({id:e.id,direction:`asc`}),label:e.ascLabel??`${e.label} · по возрастанию`,disabled:e.disabled},{value:I({id:e.id,direction:`desc`}),label:e.descLabel??`${e.label} · по убыванию`,disabled:e.disabled}]);return(0,e.jsx)(F,{options:c,value:n?I(n):``,label:i,placeholder:a,disabled:o,className:s,onChange:e=>{let t=e.lastIndexOf(`:`);r?.({id:e.slice(0,t),direction:e.slice(t+1)})}})},R={root:`_root_1h9ti_1`,tableWrap:`_tableWrap_1h9ti_3`,table:`_table_1h9ti_3`,sticky:`_sticky_1h9ti_15`,sortButton:`_sortButton_1h9ti_17`,state:`_state_1h9ti_21`,cards:`_cards_1h9ti_23`,mobileSort:`_mobileSort_1h9ti_23`,card:`_card_1h9ti_23`,spanTwo:`_spanTwo_1h9ti_37`,default:`_default_1h9ti_41`,tableOnMobile:`_tableOnMobile_1h9ti_41`,wide:`_wide_1h9ti_45`},ee=(0,n.tableFeatures)({rowSortingFeature:n.rowSortingFeature,sortedRowModel:(0,n.createSortedRowModel)()}),te=(e,t)=>{let n=new Set;for(let t of e){if(!t.id.trim())return`Идентификатор колонки не может быть пустым`;if(n.has(t.id))return`Идентификатор колонки «${t.id}» повторяется`;n.add(t.id)}for(let n=0;n<t.length;n+=1){let r=t[n];for(let t of e)if(typeof t.accessor==`string`&&!(t.accessor in r))return`В строке ${n+1} отсутствует колонка «${t.id}»`}return null},z=(e,t)=>typeof e==`function`?e(t):t[e],ne=e=>{if(e==null||e===``)return null;let t=Date.parse(String(e));return Number.isNaN(t)?null:t},re=(e,t,n)=>{let r=ne(e.getValue(n)),i=ne(t.getValue(n));return r===null&&i===null?0:r===null?-1:i===null?1:r-i},ie=(e,t,n)=>{let r=e.getValue(n),i=t.getValue(n);return r==null&&i==null?0:r==null?-1:i==null?1:Number(r)-Number(i)},B=(e,t,n)=>{let r=e.getValue(n),i=t.getValue(n);return r==null&&i==null?0:r==null?-1:i==null?1:Number(!!r)-Number(!!i)},ae=(e,t,n)=>{let r=String(e.getValue(n)??``),i=String(t.getValue(n)??``);return r.localeCompare(i,void 0,{numeric:!0,sensitivity:`base`})},oe=e=>{switch(e){case`date`:return re;case`number`:return ie;case`boolean`:return B;case`text`:case void 0:return ae;case`custom`:return}},se=e=>{let t=t=>z(e.accessor,t),n=e.sortFn??oe(e.dataType),r=e.enableSorting??(e.dataType!==`custom`&&n!==void 0),i={id:e.id,accessorFn:t,header:()=>e.header,cell:t=>{let n=t.getValue();return e.cell?.(t.row.original,n)??String(n??``)},enableSorting:r,sortDescFirst:e.sortDescFirst};return n!==void 0&&(i.sortFn=n),i},ce=({columns:r,data:i,tableOnMobile:a=!1,breakpoint:o=`default`,sorting:s,onSortingChange:c,renderMobileCard:l,getRowId:u,caption:d,ariaLabel:f,loading:p=!1,error:m,emptyState:h=`Нет данных`,stickyHeader:g=!1,maxHeight:_,className:v=``})=>{let[y,b]=(0,t.useState)([]),x=s??y,S=(0,t.useMemo)(()=>te(r,i),[r,i]),C=(0,t.useMemo)(()=>r.map(se),[r]),w=(0,n.useTable)({features:ee,columns:C,data:i,state:{sorting:x},onSortingChange:e=>{let t=typeof e==`function`?e(x):e;s===void 0&&b(t),c?.(t)},getRowId:u}),T=w.getRowModel().rows,E=r.filter(e=>e.enableSorting??e.dataType!==`custom`).map(e=>({id:e.id,label:typeof e.header==`string`?e.header:e.id})),D=[R.root,o===`wide`?R.wide:R.default,a?R.tableOnMobile:``,v].filter(Boolean).join(` `),O=S??m;return(0,e.jsxs)(`section`,{className:D,"aria-busy":p,children:[!a&&!p&&!O&&T.length>0&&E.length>0&&(0,e.jsx)(L,{className:R.mobileSort,options:E,value:x[0]?{id:x[0].id,direction:x[0].desc?`desc`:`asc`}:null,onChange:e=>w.setSorting([{id:e.id,desc:e.direction===`desc`}])}),(0,e.jsx)(`div`,{className:R.tableWrap,style:{maxHeight:_},children:(0,e.jsxs)(`table`,{className:R.table,"aria-label":f,children:[d&&(0,e.jsx)(`caption`,{children:d}),(0,e.jsx)(`thead`,{className:g?R.sticky:``,children:w.getHeaderGroups().map(t=>(0,e.jsx)(`tr`,{children:t.headers.map(t=>{let n=t.column.getIsSorted(),r=t.column.getCanSort(),i=t.column.getToggleSortingHandler();return(0,e.jsx)(`th`,{scope:`col`,"aria-sort":n===`asc`?`ascending`:n===`desc`?`descending`:`none`,children:(0,e.jsxs)(`button`,{type:`button`,className:R.sortButton,disabled:!r,onClick:i,children:[(0,e.jsx)(w.FlexRender,{header:t}),(0,e.jsx)(`span`,{"aria-hidden":`true`,children:n===`asc`?`↑`:n===`desc`?`↓`:`↕`})]})},t.id)})},t.id))}),(0,e.jsx)(`tbody`,{children:p?(0,e.jsx)(`tr`,{children:(0,e.jsx)(`td`,{colSpan:r.length,children:(0,e.jsx)(M,{lines:3})})}):O?(0,e.jsx)(`tr`,{children:(0,e.jsx)(`td`,{className:R.state,colSpan:r.length,children:O})}):T.length===0?(0,e.jsx)(`tr`,{children:(0,e.jsx)(`td`,{className:R.state,colSpan:r.length,children:h})}):T.map(t=>(0,e.jsx)(`tr`,{children:t.getAllCells().map(t=>(0,e.jsx)(`td`,{children:(0,e.jsx)(w.FlexRender,{cell:t})},t.id))},t.id))})]})}),!a&&(0,e.jsx)(`div`,{className:R.cards,role:`list`,"aria-label":f??d,children:p?(0,e.jsx)(M,{lines:4}):O?(0,e.jsx)(`div`,{className:R.state,children:O}):T.length===0?(0,e.jsx)(`div`,{className:R.state,children:h}):T.map(t=>{if(l)return(0,e.jsx)(`div`,{role:`listitem`,children:l({row:t.original,columns:r})},t.id);let n=r.filter(e=>!e.mobile?.hideOnMobile).sort((e,t)=>(e.mobile?.mobileOrder??0)-(t.mobile?.mobileOrder??0)),i=n.find(e=>e.mobile?.primary)??n.find(e=>e.mobile?.mobileVariant!==`actions`),a=e=>z(e.accessor,t.original),o=e=>e.mobile?.renderMobile?.(t.original,a(e))??e.cell?.(t.original,a(e))??String(a(e)??``);return(0,e.jsxs)(`article`,{role:`listitem`,className:R.card,children:[(0,e.jsx)(`h3`,{children:i?o(i):`Строка ${t.index+1}`}),(0,e.jsx)(`dl`,{children:n.filter(e=>e!==i&&e.mobile?.mobileVariant!==`actions`).map(t=>(0,e.jsxs)(`div`,{className:t.mobile?.mobileSpan===2?R.spanTwo:``,children:[(0,e.jsx)(`dt`,{children:t.mobile?.mobileLabel??t.header}),(0,e.jsx)(`dd`,{children:o(t)})]},t.id))}),n.filter(e=>e.mobile?.mobileVariant===`actions`).map(t=>(0,e.jsx)(`footer`,{children:o(t)},t.id))]},t.id)})})]})},le=({options:n,value:r,onChange:i,placeholder:a=`Выберите опции`,disabled:o=!1,label:s,error:c,hint:l,className:u=``,name:d,id:f,closeOnSelect:p=!1,maxMenuHeight:m})=>{let h=(0,t.useId)(),g=f??`ds-dropdown-multiple-${d??h}`,[_,v]=(0,t.useState)(!1),y=(0,t.useRef)(null),b=(0,t.useRef)(null),x=(0,t.useRef)([]),S=(0,t.useMemo)(()=>n.filter(e=>r.includes(e.value)),[n,r]),C=S.map(e=>e.label).join(`, `),w=l?`${g}-hint`:void 0,T=c?`${g}-error`:void 0;(0,t.useEffect)(()=>{let e=e=>{y.current?.contains(e.target)||v(!1)},t=e=>{e.key===`Escape`&&_&&(v(!1),b.current?.focus())};return document.addEventListener(`mousedown`,e),document.addEventListener(`keydown`,t),()=>{document.removeEventListener(`mousedown`,e),document.removeEventListener(`keydown`,t)}},[_]);let E=e=>{if(e.disabled)return;let t=r.includes(e.value)?r.filter(t=>t!==e.value):[...r,e.value];i?.(t,n.filter(e=>t.includes(e.value))),p&&(v(!1),b.current?.focus())},D=(e,t)=>{let r=P(n,e,t);x.current[r]?.focus(),x.current[r]?.scrollIntoView({block:`nearest`})};return(0,e.jsxs)(`div`,{ref:y,className:[N.wrapper,c?N.errorState:``,u].filter(Boolean).join(` `),children:[s&&(0,e.jsx)(`label`,{htmlFor:g,className:N.label,children:s}),(0,e.jsxs)(`div`,{className:N.container,children:[(0,e.jsxs)(`button`,{ref:b,id:g,type:`button`,name:d,className:N.trigger,disabled:o,"aria-haspopup":`listbox`,"aria-expanded":_,"aria-controls":`${g}-listbox`,"aria-describedby":[w,T].filter(Boolean).join(` `)||void 0,"aria-invalid":!!c,onClick:()=>v(e=>!e),onKeyDown:e=>{if(e.key===`ArrowDown`||e.key===`ArrowUp`){e.preventDefault(),v(!0);let t=e.key===`ArrowDown`?1:-1;requestAnimationFrame(()=>D(e.key===`ArrowDown`?0:n.length-1,t))}},children:[(0,e.jsx)(`span`,{className:S.length?N.value:N.placeholder,children:C||a}),(0,e.jsx)(`span`,{className:`${N.chevron} ${_?N.chevronOpen:``}`,"aria-hidden":`true`,children:`⌄`})]}),_&&(0,e.jsx)(`ul`,{id:`${g}-listbox`,className:N.menu,role:`listbox`,"aria-label":s,"aria-multiselectable":`true`,style:{maxHeight:m},children:n.map((t,i)=>{let a=r.includes(t.value);return(0,e.jsx)(`li`,{role:`presentation`,children:(0,e.jsxs)(`button`,{ref:e=>{x.current[i]=e},type:`button`,role:`option`,"aria-selected":a,disabled:t.disabled,className:`${N.option} ${a?N.selected:``}`,onClick:()=>E(t),onKeyDown:e=>{if(e.key===`ArrowDown`||e.key===`ArrowUp`){e.preventDefault();let t=e.key===`ArrowDown`?1:-1;D(i+t,t)}if(e.key===`Home`||e.key===`End`){e.preventDefault();let t=e.key===`Home`?1:-1;D(e.key===`Home`?0:n.length-1,t)}e.key===`Tab`&&v(!1)},children:[(0,e.jsx)(`span`,{children:t.label}),(0,e.jsx)(`span`,{"aria-hidden":`true`,children:a?`✓`:``})]})},t.value)})})]}),l&&!c&&(0,e.jsx)(`span`,{id:w,className:N.message,children:l}),c&&(0,e.jsx)(`span`,{id:T,className:N.error,children:c})]})},ue={approve:`M4 12l5 5L20 6`,reject:`M5 5l14 14M19 5L5 19`,edit:`M4 20h4L19 9l-4-4L4 16v4z`,cross:`M5 5l14 14M19 5L5 19`,chevron:`M6 9l6 6 6-6`,basket:`M4 7h16l-1 13H5L4 7zm3 0V4h10v3`,info:`M12 10v7m0-10v.01`,warning:`M12 4L3 20h18L12 4zm0 5v5m0 3v.01`},de=({name:t,title:n,width:r=24,height:i=24,...a})=>(0,e.jsxs)(`svg`,{viewBox:`0 0 24 24`,width:r,height:i,fill:`none`,stroke:`currentColor`,strokeWidth:`1.8`,strokeLinecap:`round`,strokeLinejoin:`round`,role:n?`img`:void 0,"aria-hidden":!n||void 0,focusable:`false`,...a,children:[n&&(0,e.jsx)(`title`,{children:n}),(0,e.jsx)(`path`,{d:ue[t]})]}),V={root:`_root_1y2s8_1`,header:`_header_1y2s8_21`,title:`_title_1y2s8_41`,dismiss:`_dismiss_1y2s8_55`,content:`_content_1y2s8_113`},fe=({title:n,children:r,dismissible:i=!1,onDismiss:a,dismissLabel:o=`Закрыть информационный блок`,headingAs:s=`h3`,className:c=``})=>{let l=`ds-info-block-${(0,t.useId)()}`;return(0,e.jsxs)(`section`,{className:`${V.root} ${c}`,"aria-labelledby":l,children:[(0,e.jsxs)(`header`,{className:V.header,children:[(0,e.jsx)(s,{id:l,className:V.title,children:n}),i&&(0,e.jsx)(`button`,{type:`button`,className:V.dismiss,onClick:a,"aria-label":o,children:(0,e.jsx)(`svg`,{viewBox:`0 0 20 20`,"aria-hidden":`true`,children:(0,e.jsx)(`path`,{d:`M5 5L15 15M15 5L5 15`,fill:`none`,stroke:`currentColor`,strokeWidth:`1.8`,strokeLinecap:`round`})})})]}),(0,e.jsx)(`div`,{className:V.content,children:r})]})},H={wrapper:`_wrapper_ip6vf_1`,control:`_control_ip6vf_3`,input:`_input_ip6vf_5`,disabledText:`_disabledText_ip6vf_5`,inputError:`_inputError_ip6vf_39`,trailingAction:`_trailingAction_ip6vf_41`},pe=({value:n,onChange:r,type:i=`text`,placeholder:a=``,disabled:o=!1,readOnly:s=!1,stringWhileDisabled:c=!1,label:l,error:u,hint:d,className:m=``,name:h,id:g,clearable:_=!0,required:v=!1,selectTextOnFocus:y=!1,isPassword:b=!1,passwordVisibleLabel:x=`Скрыть пароль`,passwordHiddenLabel:S=`Показать пароль`,onFocus:C,...w})=>{let T=(0,t.useId)(),E=g??`ds-input-${h??T}`,D=(0,t.useRef)(null),[O,k]=(0,t.useState)(!1),A=d?`${E}-hint`:void 0,j=u?`${E}-error`:void 0,M=String(n??``),N=[A,j].filter(Boolean).join(` `)||void 0,P=b?O?`text`:`password`:i;return(0,t.useEffect)(()=>{b||k(!1)},[b]),(0,e.jsxs)(`div`,{className:`${H.wrapper} ${m}`,children:[l&&(0,e.jsx)(f,{htmlFor:E,required:v,disabled:o,children:l}),o&&c?(0,e.jsx)(`div`,{id:E,className:H.disabledText,"aria-describedby":N,children:M||a}):(0,e.jsxs)(`div`,{className:H.control,children:[(0,e.jsx)(`input`,{ref:D,id:E,name:h,type:P,value:M,placeholder:a,disabled:o,readOnly:s,required:v,"aria-invalid":!!u,"aria-describedby":N,className:`${H.input} ${u?H.inputError:``}`,onChange:e=>{if(i===`number`&&!b){let t=e.target.value===``?``:Number(e.target.value);r?.(t,e);return}r?.(e.target.value,e)},onFocus:e=>{y&&e.currentTarget.value&&e.currentTarget.select(),C?.(e)},...w}),b&&(0,e.jsx)(`button`,{type:`button`,className:H.trailingAction,disabled:o,"aria-label":O?x:S,"aria-pressed":O,onClick:()=>k(e=>!e),children:O?(0,e.jsx)(`svg`,{viewBox:`0 0 24 24`,"aria-hidden":`true`,children:(0,e.jsx)(`path`,{d:`M3 3l18 18M10.6 10.7a2 2 0 0 0 2.7 2.7M9.9 4.2A10.7 10.7 0 0 1 12 4c5.5 0 9 5.3 9 5.3a14 14 0 0 1-2.3 2.8M6.6 6.6C4.3 8.1 3 10 3 10s3.5 5 9 5c1 0 2-.2 2.8-.5`})}):(0,e.jsxs)(`svg`,{viewBox:`0 0 24 24`,"aria-hidden":`true`,children:[(0,e.jsx)(`path`,{d:`M3 12s3.5-5 9-5 9 5 9 5-3.5 5-9 5-9-5-9-5Z`}),(0,e.jsx)(`circle`,{cx:`12`,cy:`12`,r:`2.5`})]})}),!b&&_&&M&&!o&&!s&&(0,e.jsx)(`button`,{type:`button`,className:H.trailingAction,"aria-label":`Очистить поле`,onClick:()=>{let e=D.current;e&&((Object.getOwnPropertyDescriptor(HTMLInputElement.prototype,`value`)?.set)?.call(e,``),e.dispatchEvent(new Event(`input`,{bubbles:!0})),e.focus())},children:`×`})]}),d&&!u&&(0,e.jsx)(p,{id:A,children:d}),u&&(0,e.jsx)(p,{id:j,variant:`error`,children:u})]})},U={wrapper:`_wrapper_vu1ob_1`,input:`_input_vu1ob_21`,switch:`_switch_vu1ob_35`,thumb:`_thumb_vu1ob_67`,label:`_label_vu1ob_111`,disabled:`_disabled_vu1ob_123`},me=({checked:n,onChange:r,label:i,disabled:a=!1,readOnly:o=!1,className:s=``,name:c,id:l,value:u})=>{let d=(0,t.useId)(),f=l??`ds-radio-button-${c??d}`;return(0,e.jsxs)(`label`,{htmlFor:f,className:`${U.wrapper} ${a?U.disabled:``} ${s}`,children:[(0,e.jsx)(`input`,{id:f,className:U.input,type:`checkbox`,role:`switch`,name:c,value:u,checked:n,disabled:a,"aria-readonly":o||void 0,onChange:e=>{o||r?.(e.target.checked,e)}}),(0,e.jsx)(`span`,{className:U.switch,"aria-hidden":`true`,children:(0,e.jsx)(`span`,{className:U.thumb})}),i&&(0,e.jsx)(`span`,{className:U.label,children:i})]})},W={root:`_root_kepgo_1`,grid:`_grid_kepgo_3`,actions:`_actions_kepgo_5`},he=({filters:t,values:n,onChange:r,onApply:i,onReset:a,applyMode:o=`instant`,loading:s=!1,disabled:c=!1,className:l=``})=>{let d=(e,t)=>{let a={...n,[e]:t};r?.(a,e),o===`instant`&&i?.(a)};return(0,e.jsxs)(`section`,{className:`${W.root} ${l}`,"aria-label":`Фильтры`,"aria-busy":s,children:[(0,e.jsx)(`div`,{className:W.grid,children:t.filter(e=>!e.hidden).map(t=>{let r=c||s||t.disabled,i=n[t.id];if(t.type===`input`){let n={label:t.label,hint:t.hint,placeholder:t.placeholder,disabled:r};return t.inputType===`number`?(0,e.jsx)(pe,{...n,type:`number`,value:i??``,onChange:e=>d(t.id,e)},t.id):(0,e.jsx)(pe,{...n,type:`text`,value:String(i??``),onChange:e=>d(t.id,e)},t.id)}if(t.type===`dropdown`)return(0,e.jsx)(F,{label:t.label,hint:t.hint,placeholder:t.placeholder,options:t.options,value:String(i??``),disabled:r,onChange:e=>d(t.id,e)},t.id);if(t.type===`multiple`)return(0,e.jsx)(le,{label:t.label,hint:t.hint,placeholder:t.placeholder,options:t.options,value:Array.isArray(i)?i:[],disabled:r,onChange:e=>d(t.id,e)},t.id);if(t.type===`checkbox`)return(0,e.jsx)(h,{label:t.label,hint:t.hint,checked:!!i,disabled:r,onChange:e=>d(t.id,e)},t.id);if(t.type===`radio`)return(0,e.jsx)(me,{label:t.label,checked:!!i,disabled:r,onChange:e=>d(t.id,e)},t.id);let a=i&&typeof i==`object`&&!Array.isArray(i)?i:{from:null,to:null};return(0,e.jsx)(A,{hint:t.hint,mode:t.mode,min:t.min,max:t.max,value:a,disabled:r,onDraftChange:e=>d(t.id,e)},t.id)})}),(a||o===`manual`)&&(0,e.jsxs)(`div`,{className:W.actions,children:[a&&(0,e.jsx)(u,{variant:`destructiveOutline`,disabled:c||s,onClick:a,children:`Сбросить`}),o===`manual`&&(0,e.jsx)(u,{isLoading:s,disabled:c,onClick:()=>i?.(n),children:`Применить`})]})]})},G={wrapper:`_wrapper_1ymdr_1`,dropzone:`_dropzone_1ymdr_3`,dragActive:`_dragActive_1ymdr_5`,disabled:`_disabled_1ymdr_7`,error:`_error_1ymdr_9`,nativeInput:`_nativeInput_1ymdr_11`,empty:`_empty_1ymdr_13`,uploadIcon:`_uploadIcon_1ymdr_15`,browseButton:`_browseButton_1ymdr_17`,files:`_files_1ymdr_19`,file:`_file_1ymdr_19`,fileName:`_fileName_1ymdr_23`,fileSize:`_fileSize_1ymdr_25`},K=e=>`${e.name}:${e.size}:${e.lastModified}`,ge=e=>e<1024?`${e} Б`:e<1048576?`${(e/1024).toFixed(1)} КБ`:`${(e/1024/1024).toFixed(1)} МБ`,_e=(e,t)=>!t||t.split(`,`).map(e=>e.trim().toLowerCase()).some(t=>t.startsWith(`.`)?e.name.toLowerCase().endsWith(t):t.endsWith(`/*`)?e.type.startsWith(t.slice(0,-1)):e.type.toLowerCase()===t),ve=({value:n,onChange:r,multiple:i=!1,accept:a,maxSize:o,maxFiles:s,label:c,hint:l,error:d,required:m=!1,disabled:h=!1,readOnly:g=!1,name:_,id:v,className:y=``,dropLabel:b=`Перетащите файлы в эту область`,browseLabel:x=`Выбрать файлы`,addMoreLabel:S=`Добавить ещё`,onReject:C})=>{let w=(0,t.useId)(),T=v??`ds-file-input-${_??w}`,E=(0,t.useRef)(null),D=(0,t.useRef)(0),[O,k]=(0,t.useState)(!1),A=l?`${T}-hint`:void 0,j=d?`${T}-error`:void 0,M=[A,j].filter(Boolean).join(` `)||void 0,N=!h&&!g,P=e=>{let t=[],c=new Set(n.map(K)),l=e.filter(e=>_e(e,a)?o!==void 0&&e.size>o?(t.push({file:e,reason:`maxSize`}),!1):!c.has(K(e))&&(c.add(K(e)),!0):(t.push({file:e,reason:`accept`}),!1)),u=i?s:1,d=i?[...n,...l]:l.slice(-1);u!==void 0&&d.length>u&&(d.slice(u).forEach(e=>t.push({file:e,reason:`maxFiles`})),d=d.slice(0,u)),t.length&&C?.(t),l.length&&r?.(d),E.current&&(E.current.value=``)};return(0,e.jsxs)(`div`,{className:`${G.wrapper} ${y}`,children:[c&&(0,e.jsx)(f,{htmlFor:T,required:m,disabled:h,children:c}),(0,e.jsxs)(`div`,{className:`${G.dropzone} ${O?G.dragActive:``} ${h?G.disabled:``} ${d?G.error:``}`,onDragEnter:e=>{e.preventDefault(),N&&++D.current===1&&k(!0)},onDragOver:e=>e.preventDefault(),onDragLeave:e=>{e.preventDefault(),--D.current<=0&&(D.current=0,k(!1))},onDrop:e=>{e.preventDefault(),D.current=0,k(!1),N&&P(Array.from(e.dataTransfer.files))},children:[(0,e.jsx)(`input`,{ref:E,id:T,name:_,className:G.nativeInput,type:`file`,multiple:i,accept:a,required:m&&n.length===0,disabled:!N,"aria-describedby":M,"aria-invalid":!!d,onChange:e=>P(Array.from(e.target.files??[]))}),n.length?(0,e.jsxs)(e.Fragment,{children:[(0,e.jsx)(`ul`,{className:G.files,"aria-live":`polite`,children:n.map((t,i)=>(0,e.jsxs)(`li`,{className:G.file,children:[(0,e.jsx)(`span`,{className:G.fileName,title:t.name,children:t.name}),(0,e.jsx)(`span`,{className:G.fileSize,children:ge(t.size)}),N&&(0,e.jsx)(u,{variant:`empty`,size:`sm`,"aria-label":`Удалить файл ${t.name}`,onClick:()=>r?.(n.filter((e,t)=>t!==i)),children:`×`})]},K(t)))}),N&&(i||n.length===0)&&(0,e.jsx)(u,{className:G.browseButton,size:`sm`,onClick:()=>E.current?.click(),children:S}),N&&!i&&(0,e.jsx)(u,{className:G.browseButton,size:`sm`,onClick:()=>E.current?.click(),children:x})]}):(0,e.jsxs)(`div`,{className:G.empty,children:[(0,e.jsx)(`span`,{className:G.uploadIcon,"aria-hidden":`true`,children:`↑`}),(0,e.jsx)(`strong`,{children:O?`Отпустите файлы здесь`:b}),!O&&N&&(0,e.jsxs)(e.Fragment,{children:[(0,e.jsx)(`span`,{children:`или`}),(0,e.jsx)(u,{className:G.browseButton,onClick:()=>E.current?.click(),children:x})]})]})]}),l&&!d&&(0,e.jsx)(p,{id:A,children:l}),d&&(0,e.jsx)(p,{id:j,variant:`error`,live:!0,children:d})]})},ye=0,q=(0,i.create)(e=>({modals:[],openModal:(t,n={},r={})=>{ye+=1;let i=`ds-modal-${ye}`;return e(e=>({modals:[...e.modals,{id:i,name:t,payload:n,closeOnEscape:r.closeOnEscape??!0,closeOnBackdrop:r.closeOnBackdrop??!0}]})),i},closeModal:t=>e(e=>({modals:e.modals.filter(e=>e.id!==t)})),closeTopModal:()=>e(e=>({modals:e.modals.slice(0,-1)})),closeAllModals:()=>e({modals:[]})})),be=()=>q.setState({modals:[]}),J={layer:`_layer_1nb2z_1`,backdrop:`_backdrop_1nb2z_3`,panel:`_panel_1nb2z_5`,header:`_header_1nb2z_9`,title:`_title_1nb2z_11`,description:`_description_1nb2z_13`,content:`_content_1nb2z_15`},xe=`button:not(:disabled), [href], input:not(:disabled), select:not(:disabled), textarea:not(:disabled), [tabindex]:not([tabindex="-1"])`,Y=({children:n,title:r,description:i,modalId:a,closeLabel:o=`Закрыть модальное окно`,className:s=``,role:c=`dialog`})=>{let l=(0,t.useId)(),d=(0,t.useId)(),f=(0,t.useRef)(null),p=q(e=>e.closeModal);return(0,t.useEffect)(()=>{let e=document.activeElement,t=f.current;return(t?.querySelector(xe)??t)?.focus(),()=>e?.focus()},[]),(0,e.jsxs)(`div`,{ref:f,className:`${J.panel} ${s}`,role:c,"aria-modal":`true`,"aria-labelledby":r?l:void 0,"aria-describedby":i?d:void 0,tabIndex:-1,onKeyDown:e=>{if(e.key!==`Tab`)return;let t=Array.from(f.current?.querySelectorAll(xe)??[]);if(!t.length){e.preventDefault();return}let n=t[0],r=t[t.length-1];e.shiftKey&&document.activeElement===n?(e.preventDefault(),r?.focus()):!e.shiftKey&&document.activeElement===r&&(e.preventDefault(),n?.focus())},children:[(r||o)&&(0,e.jsxs)(`header`,{className:J.header,children:[r&&(0,e.jsx)(`h2`,{id:l,className:J.title,children:r}),(0,e.jsx)(u,{variant:`empty`,size:`sm`,"aria-label":o,onClick:()=>p(a),children:(0,e.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`24`,height:`24`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,e.jsx)(`path`,{d:`M18 6 6 18`}),(0,e.jsx)(`path`,{d:`m6 6 12 12`})]})})]}),i&&(0,e.jsx)(`p`,{id:d,className:J.description,children:i}),(0,e.jsx)(`div`,{className:J.content,children:n})]})},Se=({registry:n})=>{let i=q(e=>e.modals),a=q(e=>e.closeModal),o=q(e=>e.closeAllModals);return(0,t.useEffect)(()=>{let e=e=>{if(e.key!==`Escape`)return;let t=q.getState().modals.at(-1);t?.closeOnEscape&&a(t.id)};return document.addEventListener(`keydown`,e),()=>document.removeEventListener(`keydown`,e)},[a]),!i.length||typeof document>`u`?null:(0,r.createPortal)((0,e.jsx)(`div`,{className:J.layer,"aria-label":`Модальные окна`,children:i.map((t,r)=>{let s=n[t.name];return s?(0,e.jsx)(`div`,{className:J.backdrop,"aria-hidden":r!==i.length-1||void 0,onMouseDown:e=>{e.target===e.currentTarget&&t.closeOnBackdrop&&a(t.id)},children:(0,e.jsx)(s,{...t.payload,modalId:t.id,close:()=>a(t.id),closeAll:o})},t.id):null})}),document.body)},Ce=({registry:n,children:r,lockBodyScroll:i=!0})=>{let a=q(e=>e.modals.length);return(0,t.useEffect)(()=>{if(!i||a===0)return;let e=document.body.style.overflow;return document.body.style.overflow=`hidden`,()=>{document.body.style.overflow=e}},[i,a]),(0,e.jsxs)(e.Fragment,{children:[r,(0,e.jsx)(Se,{registry:n})]})},we=e=>e,X={message:`_message_1vtru_1`,actions:`_actions_1vtru_3`},Te=new Map,Ee=0,De=({modalId:t,close:n,title:r=`Подтверждение`,message:i=`Продолжить действие?`,confirmLabel:a=`Подтвердить`,cancelLabel:o=`Отмена`,tone:s=`default`,requestId:c})=>{let l=e=>{Te.get(c)?.(e),Te.delete(c),n()};return(0,e.jsxs)(Y,{modalId:t,title:r,role:`alertdialog`,children:[(0,e.jsx)(`p`,{className:X.message,children:i}),(0,e.jsxs)(`div`,{className:X.actions,children:[(0,e.jsx)(u,{variant:`outline`,onClick:()=>l(!1),children:o}),(0,e.jsx)(u,{variant:s===`danger`?`destructive`:`primary`,onClick:()=>l(!0),children:a})]})]})},Oe=({modalId:t,close:n,title:r=`Ошибка`,message:i,closeLabel:a=`Закрыть`})=>(0,e.jsxs)(Y,{modalId:t,title:r,role:`alertdialog`,children:[(0,e.jsx)(`p`,{className:X.message,children:i}),(0,e.jsx)(`div`,{className:X.actions,children:(0,e.jsx)(u,{onClick:n,children:a})})]}),ke=we({ConfirmModal:De,ErrorModal:Oe}),Ae=()=>{let e=q(e=>e.openModal);return(t={})=>new Promise(n=>{Ee+=1;let r=`confirm-${Ee}`;Te.set(r,n),e(`ConfirmModal`,{...t,requestId:r},{closeOnEscape:!1})})},je=e=>e instanceof Error?e.message:typeof e==`string`?e:e&&typeof e==`object`&&`message`in e&&typeof e.message==`string`?e.message:`Произошла неизвестная ошибка`,Me=()=>{let e=q(e=>e.openModal);return{showError:(t,n)=>e(`ErrorModal`,{title:n,message:je(t)})}},Ne=(0,i.create)(()=>({})),Pe=(0,i.create)(()=>({})),Fe=()=>{let e=q(e=>e.modals),t=q(e=>e.openModal);return{openModal:(e,n={},r)=>t(e,n,r),closeModal:q(e=>e.closeModal),closeTopModal:q(e=>e.closeTopModal),closeAllModals:q(e=>e.closeAllModals),isOpen:t=>e.some(e=>e.name===t),count:e.length}},Ie={root:`_root_1x7h7_1`},Le=({label:t=`Загрузка страницы`,className:n=``})=>(0,e.jsxs)(`div`,{className:`${Ie.root} ${n}`,role:`status`,"aria-label":t,children:[(0,e.jsx)(c,{decorative:!0}),(0,e.jsx)(`span`,{children:t})]}),Z={viewport:`_viewport_15mi5_1`,"top-right":`_top-right_15mi5_3`,"top-left":`_top-left_15mi5_5`,"bottom-right":`_bottom-right_15mi5_7`,"bottom-left":`_bottom-left_15mi5_9`,toast:`_toast_15mi5_11`,body:`_body_15mi5_13`,icon:`_icon_15mi5_15`,info:`_info_15mi5_17`,success:`_success_15mi5_19`,warning:`_warning_15mi5_21`,error:`_error_15mi5_23`},Re=t=>{let n;return n=t===`info`?(0,e.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`24`,height:`24`,viewBox:`0 0 24 24`,fill:`none`,stroke:`#179cf0`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,e.jsx)(`circle`,{cx:`12`,cy:`12`,r:`10`}),(0,e.jsx)(`path`,{d:`M12 16v-4`}),(0,e.jsx)(`path`,{d:`M12 8h.01`})]}):t===`success`?(0,e.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`24`,height:`24`,viewBox:`0 0 24 24`,fill:`none`,stroke:`#179c66`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,e.jsx)(`circle`,{cx:`12`,cy:`12`,r:`10`}),(0,e.jsx)(`path`,{d:`m9 12 2 2 4-4`})]}):t===`warning`?(0,e.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`24`,height:`24`,viewBox:`0 0 24 24`,fill:`none`,stroke:`#f59e0b`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,e.jsx)(`path`,{d:`m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3`}),(0,e.jsx)(`path`,{d:`M12 9v4`}),(0,e.jsx)(`path`,{d:`M12 17h.01`})]}):t===`error`?(0,e.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`24`,height:`24`,viewBox:`0 0 24 24`,fill:`none`,stroke:`#dc2626`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,e.jsx)(`path`,{d:`m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3`}),(0,e.jsx)(`path`,{d:`M12 9v4`}),(0,e.jsx)(`path`,{d:`M12 17h.01`})]}):(0,e.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`24`,height:`24`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,e.jsx)(`circle`,{cx:`12`,cy:`12`,r:`10`}),(0,e.jsx)(`path`,{d:`m15 9-6 6`}),(0,e.jsx)(`path`,{d:`m9 9 6 6`})]}),n},ze=({toast:n,onClose:r})=>{let[i,a]=(0,t.useState)(!1),o=(0,t.useRef)(n.duration),s=(0,t.useRef)(Date.now());return(0,t.useEffect)(()=>{if(i||n.duration<=0)return;s.current=Date.now();let e=setTimeout(()=>r(n.id),o.current);return()=>{clearTimeout(e),o.current=Math.max(0,o.current-(Date.now()-s.current))}},[r,i,n.duration,n.id]),(0,e.jsxs)(`article`,{className:`${Z.toast} ${Z[n.variant]}`,role:n.variant===`error`?`alert`:`status`,"aria-live":n.variant===`error`?`assertive`:`polite`,onMouseEnter:()=>a(!0),onMouseLeave:()=>a(!1),onFocus:()=>a(!0),onBlur:()=>a(!1),children:[(0,e.jsx)(`div`,{children:Re(n.variant)}),(0,e.jsxs)(`div`,{className:Z.body,children:[n.title&&(0,e.jsx)(`strong`,{children:n.title}),(0,e.jsx)(`div`,{children:n.message}),n.action&&(0,e.jsx)(u,{variant:`empty`,size:`sm`,onClick:()=>{n.action?.onClick(),(n.action?.dismissOnClick??!0)&&r(n.id)},children:n.action.label})]}),n.closable&&(0,e.jsx)(u,{variant:`empty`,size:`sm`,"aria-label":`Закрыть уведомление`,onClick:()=>r(n.id),children:(0,e.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`24`,height:`24`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,e.jsx)(`path`,{d:`M18 6 6 18`}),(0,e.jsx)(`path`,{d:`m6 6 12 12`})]})})]})},Be=0,Q=(0,i.create)(e=>({toasts:[],showToast:t=>{Be+=1;let n=`ds-toast-${Be}`;return e(e=>({toasts:[...e.toasts,{variant:`info`,duration:5e3,closable:!0,...t,id:n}]})),n},removeToast:t=>e(e=>({toasts:e.toasts.filter(e=>e.id!==t)})),clearToasts:()=>e({toasts:[]})})),Ve=()=>Q.setState({toasts:[]}),He=({position:t=`top-right`})=>{let n=Q(e=>e.toasts),r=Q(e=>e.removeToast);return(0,e.jsx)(`div`,{className:`${Z.viewport} ${Z[t]}`,"aria-label":`Уведомления`,children:n.map(t=>(0,e.jsx)(ze,{toast:t,onClose:r},t.id))})},Ue=()=>{let e=Q(e=>e.showToast),n=Q(e=>e.removeToast),r=Q(e=>e.clearToasts),i=(0,t.useCallback)(t=>e({...t,variant:`info`}),[e]),a=(0,t.useCallback)(t=>e({...t,variant:`success`}),[e]),o=(0,t.useCallback)(t=>e({...t,variant:`warning`}),[e]),s=(0,t.useCallback)(t=>e({...t,variant:`error`}),[e]);return(0,t.useMemo)(()=>({showToast:e,infoToast:i,successToast:a,warningToast:o,errorToast:s,removeToast:n,clearToasts:r}),[r,s,i,n,e,a,o])},We={root:`_root_s9o0g_1`,tooltip:`_tooltip_s9o0g_3`,"ds-tooltip-in":`_ds-tooltip-in_s9o0g_1`,top:`_top_s9o0g_5`,bottom:`_bottom_s9o0g_7`,left:`_left_s9o0g_9`,right:`_right_s9o0g_11`},Ge=({content:n,children:r,placement:i=`top`,delay:a=450,disabled:o=!1,maxWidth:s=280,className:c=``})=>{let l=(0,t.useId)(),[u,d]=(0,t.useState)(!1),f=(0,t.useRef)(null),p=()=>{o||!n||(f.current=setTimeout(()=>d(!0),a))},m=()=>{f.current&&clearTimeout(f.current),d(!1)};if((0,t.useEffect)(()=>{let e=e=>{e.key===`Escape`&&m()};return document.addEventListener(`keydown`,e),()=>{document.removeEventListener(`keydown`,e),f.current&&clearTimeout(f.current)}},[]),!(0,t.isValidElement)(r))return r;let h=(0,t.cloneElement)(r,{"aria-describedby":u?l:void 0,onMouseEnter:p,onMouseLeave:m,onFocus:p,onBlur:m});return(0,e.jsxs)(`span`,{className:`${We.root} ${c}`,onPointerDown:u?m:p,children:[h,u&&(0,e.jsx)(`span`,{id:l,role:`tooltip`,className:`${We.tooltip} ${We[i]}`,style:{maxWidth:s},children:n})]})},$={root:`_root_1ue3g_1`,frame:`_frame_1ue3g_3`,video:`_video_1ue3g_5`,overlay:`_overlay_1ue3g_7`,error:`_error_1ue3g_7`,caption:`_caption_1ue3g_13`},Ke=({sources:n,tracks:r=[],title:i,aspectRatio:a=`16 / 9`,objectFit:o=`contain`,loading:s=!1,error:l,fallback:u,className:d=``,controls:f=!0,playsInline:p=!0,...m})=>{let[h,g]=(0,t.useState)(!1),_=l??(h?`Не удалось воспроизвести видео`:void 0);return(0,e.jsxs)(`figure`,{className:`${$.root} ${d}`,children:[(0,e.jsxs)(`div`,{className:$.frame,style:{aspectRatio:a},children:[!_&&n.length>0&&(0,e.jsxs)(`video`,{...m,"aria-label":i,controls:f,playsInline:p,className:$.video,style:{objectFit:o},onError:e=>{g(!0),m.onError?.(e)},children:[n.map(t=>(0,e.jsx)(`source`,{...t},`${t.src}-${t.type}`)),r.map(t=>(0,e.jsx)(`track`,{...t},`${t.src}-${t.srcLang}`))]}),s&&(0,e.jsx)(`div`,{className:$.overlay,children:(0,e.jsx)(c,{label:`Загрузка видео`})}),(_||n.length===0)&&(0,e.jsx)(`div`,{className:$.error,role:`alert`,children:u??_??`Источник видео не указан`})]}),(0,e.jsx)(`figcaption`,{className:$.caption,children:i})]})};exports.ConfirmModal=De,exports.DSBadge=o,exports.DSButton=u,exports.DSCheckbox=h,exports.DSDataTable=ce,exports.DSDateRange=A,exports.DSDateTimePicker=D,exports.DSDropDown=F,exports.DSDropDownMultiple=le,exports.DSFieldLabel=f,exports.DSFieldMessage=p,exports.DSFileInput=ve,exports.DSFilters=he,exports.DSIcon=de,exports.DSInfoBlock=fe,exports.DSInput=pe,exports.DSLoader=c,exports.DSModal=Se,exports.DSModalFrame=Y,exports.DSPageLoader=Le,exports.DSRadioButton=me,exports.DSSkeleton=M,exports.DSSort=L,exports.DSToast=ze,exports.DSToastProvider=He,exports.DSTooltip=Ge,exports.DSVideoPlayerFrame=Ke,exports.ErrorModal=Oe,exports.ModalSystemProvider=Ce,exports.builtInModalRegistry=ke,exports.defineModalRegistry=we,exports.formatDateTimeLocalValue=x,exports.getErrorMessage=je,exports.getNextEnabledOptionIndex=P,exports.isValidDateRange=k,exports.parseDateTimeLocalValue=S,exports.resetModalStore=be,exports.resetToastStore=Ve,exports.useConfirmModal=Ae,exports.useConfirmModalStore=Ne,exports.useErrorModal=Me,exports.useErrorModalStore=Pe,exports.useModals=Fe,exports.useModalsStore=q,exports.useToast=Ue,exports.useToastStore=Q,exports.validateDSDataTableData=te;
|
|
1
|
+
Object.defineProperty(exports,Symbol.toStringTag,{value:`Module`});let e=require("react/jsx-runtime"),t=require("react"),n=require("@tanstack/react-table"),r=require("react-dom"),i=require("zustand");var a={badge:`_badge_1pk53_1`,sm:`_sm_1pk53_3`,md:`_md_1pk53_5`,neutral:`_neutral_1pk53_7`,info:`_info_1pk53_9`,success:`_success_1pk53_11`,warning:`_warning_1pk53_13`,error:`_error_1pk53_15`,dot:`_dot_1pk53_17`,icon:`_icon_1pk53_19`,label:`_label_1pk53_21`},o=({children:t,variant:n=`neutral`,size:r=`md`,dot:i=!1,icon:o,className:s=``})=>(0,e.jsxs)(`span`,{className:`${a.badge} ${a[n]} ${a[r]} ${s}`,children:[i&&(0,e.jsx)(`span`,{className:a.dot,"aria-hidden":`true`}),o&&(0,e.jsx)(`span`,{className:a.icon,"aria-hidden":`true`,children:o}),(0,e.jsx)(`span`,{className:a.label,children:t})]}),s={loader:`_loader_1tjcf_1`,"ds-spin":`_ds-spin_1tjcf_1`,primary:`_primary_1tjcf_21`,secondary:`_secondary_1tjcf_23`,light:`_light_1tjcf_25`,danger:`_danger_1tjcf_27`},c=({variant:t=`primary`,label:n=`Загрузка`,className:r=``,decorative:i=!1})=>(0,e.jsx)(`span`,{className:`${s.loader} ${s[t]} ${r}`,role:i?void 0:`status`,"aria-label":i?void 0:n,"aria-hidden":i||void 0}),l={button:`_button_1jisp_1`,sm:`_sm_1jisp_31`,md:`_md_1jisp_33`,lg:`_lg_1jisp_35`,primary:`_primary_1jisp_37`,secondary:`_secondary_1jisp_39`,outline:`_outline_1jisp_41`,ghost:`_ghost_1jisp_45`,empty:`_empty_1jisp_57`,destructive:`_destructive_1jisp_67`,destructiveOutline:`_destructiveOutline_1jisp_69`},u=(0,t.forwardRef)(({children:t,variant:n=`primary`,size:r=`md`,isLoading:i=!1,loadingLabel:a=`Загрузка`,disabled:o,type:s=`button`,className:u=``,...d},f)=>(0,e.jsx)(`button`,{ref:f,className:`${l.button} ${l[n]} ${l[r]} ${u}`,disabled:o||i,"aria-busy":i||void 0,...d,type:s,children:i?(0,e.jsx)(c,{variant:`light`,label:a}):t}));u.displayName=`DSButton`;var d={label:`_label_1lsqq_1`,required:`_required_1lsqq_23`,error:`_error_1lsqq_25`,optional:`_optional_1lsqq_33`,hint:`_hint_1lsqq_35`,disabled:`_disabled_1lsqq_47`,message:`_message_1lsqq_55`,success:`_success_1lsqq_71`},f=({children:t,required:n=!1,optionalText:r,disabled:i=!1,className:a=``,...o})=>(0,e.jsxs)(`label`,{className:`${d.label} ${i?d.disabled:``} ${a}`,...o,children:[(0,e.jsx)(`span`,{children:t}),n&&(0,e.jsx)(`span`,{className:d.required,"aria-hidden":`true`,children:`*`}),r&&(0,e.jsx)(`span`,{className:d.optional,children:r})]}),p=({children:t,variant:n=`hint`,id:r,live:i=!1,className:a=``})=>(0,e.jsx)(`span`,{id:r,className:`${d.message} ${d[n]} ${a}`,role:i&&n===`error`?`alert`:void 0,"aria-live":i&&n!==`error`?`polite`:void 0,children:t}),m={wrapper:`_wrapper_1gq36_1`,label:`_label_1gq36_3`,input:`_input_1gq36_5`,control:`_control_1gq36_7`,disabled:`_disabled_1gq36_13`,controlError:`_controlError_1gq36_17`},h=({checked:n,onChange:r,label:i,hint:a,error:o,disabled:s=!1,readOnly:c=!1,className:l=``,name:u,id:d,indeterminate:f=!1,...h})=>{let g=(0,t.useId)(),_=d??`ds-checkbox-${u??g}`,v=(0,t.useRef)(null),y=a?`${_}-hint`:void 0,b=o?`${_}-error`:void 0;return(0,t.useEffect)(()=>{v.current&&(v.current.indeterminate=f&&!n)},[n,f]),(0,e.jsxs)(`div`,{className:`${m.wrapper} ${l}`,children:[(0,e.jsxs)(`label`,{className:`${m.label} ${s?m.disabled:``}`,htmlFor:_,children:[(0,e.jsx)(`input`,{ref:v,id:_,name:u,type:`checkbox`,checked:n,disabled:s,"aria-readonly":c||void 0,"aria-invalid":!!o,"aria-describedby":[y,b].filter(Boolean).join(` `)||void 0,className:m.input,onChange:e=>{c||r?.(e.target.checked,e)},...h}),(0,e.jsx)(`span`,{className:`${m.control} ${o?m.controlError:``}`,"aria-hidden":`true`,children:f&&!n?`−`:n?`✓`:``}),i&&(0,e.jsx)(`span`,{children:i})]}),a&&!o&&(0,e.jsx)(p,{id:y,children:a}),o&&(0,e.jsx)(p,{id:b,variant:`error`,children:o})]})},g={wrapper:`_wrapper_1528c_1`,trigger:`_trigger_1528c_17`,nav:`_nav_1528c_53`,day:`_day_1528c_55`,monthSelect:`_monthSelect_1528c_57`,yearInput:`_yearInput_1528c_59`,timeInput:`_timeInput_1528c_61`,value:`_value_1528c_85`,placeholder:`_placeholder_1528c_93`,error:`_error_1528c_101`,panel:`_panel_1528c_109`,calendarHeader:`_calendarHeader_1528c_135`,weekdays:`_weekdays_1528c_225`,days:`_days_1528c_227`,outside:`_outside_1528c_263`,selected:`_selected_1528c_271`,timeLabel:`_timeLabel_1528c_291`},_=[`Пн`,`Вт`,`Ср`,`Чт`,`Пт`,`Сб`,`Вс`],v=[`Январь`,`Февраль`,`Март`,`Апрель`,`Май`,`Июнь`,`Июль`,`Август`,`Сентябрь`,`Октябрь`,`Ноябрь`,`Декабрь`],y=e=>String(e).padStart(2,`0`),b=e=>new Date(e.getFullYear(),e.getMonth(),e.getDate()),x=(e,t)=>{if(!e)return``;let n=`${e.getFullYear()}-${y(e.getMonth()+1)}-${y(e.getDate())}`,r=`${y(e.getHours())}:${y(e.getMinutes())}`;return t===`date`?n:t===`time`?r:`${n}T${r}`},S=(e,t)=>{if(!e)return null;if(t===`time`){let t=/^(\d{2}):(\d{2})$/.exec(e);if(!t)return null;let n=Number(t[1]),r=Number(t[2]);if(n>23||r>59)return null;let i=new Date;return i.setHours(n,r,0,0),i}let n=new Date(t===`date`?`${e}T00:00`:e);return Number.isNaN(n.getTime())?null:n},C=(e,t)=>{if(!e)return``;let n=`${y(e.getDate())}.${y(e.getMonth()+1)}.${e.getFullYear()}`,r=`${y(e.getHours())}:${y(e.getMinutes())}`;return t===`date`?n:t===`time`?r:`${n} ${r}`},w=e=>{let t=new Date(e.getFullYear(),e.getMonth(),1),n=(t.getDay()+6)%7,r=new Date(t);return r.setDate(t.getDate()-n),Array.from({length:42},(e,t)=>{let n=new Date(r);return n.setDate(r.getDate()+t),n})},T=(e,t)=>!!(e&&e.getFullYear()===t.getFullYear()&&e.getMonth()===t.getMonth()&&e.getDate()===t.getDate()),E=(e,t,n)=>{let r=b(e).getTime();return!!(t&&r<b(t).getTime()||n&&r>b(n).getTime())},D=({value:n,onChange:r,mode:i=`date`,label:a,placeholder:o,hint:s,error:c,disabled:l=!1,readOnly:u=!1,required:d=!1,min:m,max:h,id:y,name:b,className:D=``})=>{let O=(0,t.useId)(),k=y??`ds-date-time-${b??O}`,A=s?`${k}-hint`:void 0,j=c?`${k}-error`:void 0,M=(0,t.useRef)(null),N=(0,t.useRef)(null),[P,F]=(0,t.useState)(!1),[I,L]=(0,t.useState)(n??new Date),[R,ee]=(0,t.useState)(x(n,`time`)),te=(0,t.useMemo)(()=>w(I),[I]),z=i!==`time`,ne=i!==`date`;(0,t.useEffect)(()=>{n&&L(n),ee(x(n,`time`))},[n]),(0,t.useEffect)(()=>{let e=e=>{M.current?.contains(e.target)||F(!1)},t=e=>{e.key===`Escape`&&(F(!1),N.current?.focus())};return document.addEventListener(`mousedown`,e),document.addEventListener(`keydown`,t),()=>{document.removeEventListener(`mousedown`,e),document.removeEventListener(`keydown`,t)}},[]);let re=e=>{if(E(e,m,h))return;let t=new Date(e);t.setHours(n?.getHours()??0,n?.getMinutes()??0,0,0),r?.(t),i===`date`&&F(!1)},ie=e=>{if(ee(e),!e){r?.(null);return}let t=S(e,`time`);if(!t)return;let a=new Date(i===`datetime`?n??I:new Date);a.setHours(t.getHours(),t.getMinutes(),0,0),!(m&&a<m||h&&a>h)&&r?.(a)},B=o??(i===`date`?`Выберите дату`:i===`time`?`Введите время`:`Выберите дату и время`),ae=[A,j].filter(Boolean).join(` `)||void 0;return(0,e.jsxs)(`div`,{ref:M,className:`${g.wrapper} ${D}`,children:[a&&(0,e.jsx)(f,{htmlFor:k,required:d,disabled:l,children:a}),(0,e.jsxs)(`button`,{ref:N,id:k,name:b,type:`button`,className:`${g.trigger} ${c?g.error:``}`,disabled:l,"aria-readonly":u||void 0,"aria-expanded":P,"aria-haspopup":`dialog`,"aria-describedby":ae,onClick:()=>{u||F(e=>!e)},children:[(0,e.jsx)(`span`,{className:n?g.value:g.placeholder,children:C(n,i)||B}),(0,e.jsx)(`span`,{"aria-hidden":`true`,children:`▾`})]}),P&&!u&&(0,e.jsxs)(`div`,{className:g.panel,role:`dialog`,"aria-label":a??B,children:[z&&(0,e.jsxs)(e.Fragment,{children:[(0,e.jsxs)(`div`,{className:g.calendarHeader,children:[(0,e.jsx)(`button`,{type:`button`,className:g.nav,"aria-label":`Предыдущий месяц`,onClick:()=>L(new Date(I.getFullYear(),I.getMonth()-1,1)),children:`‹`}),(0,e.jsx)(`select`,{className:g.monthSelect,"aria-label":`Месяц`,value:I.getMonth(),onChange:e=>L(new Date(I.getFullYear(),Number(e.target.value),1)),children:v.map((t,n)=>(0,e.jsx)(`option`,{value:n,children:t},t))}),(0,e.jsx)(`input`,{className:g.yearInput,type:`number`,"aria-label":`Год`,value:I.getFullYear(),onChange:e=>L(new Date(Number(e.target.value),I.getMonth(),1))}),(0,e.jsx)(`button`,{type:`button`,className:g.nav,"aria-label":`Следующий месяц`,onClick:()=>L(new Date(I.getFullYear(),I.getMonth()+1,1)),children:`›`})]}),(0,e.jsx)(`div`,{className:g.weekdays,children:_.map(t=>(0,e.jsx)(`span`,{children:t},t))}),(0,e.jsx)(`div`,{className:g.days,children:te.map(t=>{let r=T(n,t);return(0,e.jsx)(`button`,{type:`button`,className:`${g.day} ${t.getMonth()===I.getMonth()?``:g.outside} ${r?g.selected:``}`,disabled:E(t,m,h),"aria-pressed":r,onClick:()=>re(t),children:t.getDate()},t.toISOString())})})]}),ne&&(0,e.jsxs)(`label`,{className:g.timeLabel,children:[(0,e.jsx)(`span`,{children:`Время`}),(0,e.jsx)(`input`,{className:g.timeInput,type:`time`,value:R,onChange:e=>ie(e.target.value)})]})]}),s&&!c&&(0,e.jsx)(p,{id:A,children:s}),c&&(0,e.jsx)(p,{id:j,variant:`error`,children:c})]})},O={root:`_root_1q42e_1`,legend:`_legend_1q42e_3`,range:`_range_1q42e_5`},k=e=>!!(e.from&&e.to&&e.from.getTime()<=e.to.getTime()),A=({value:t,onChange:n,onDraftChange:r,mode:i=`date`,fromLabel:a=`От`,toLabel:o=`До`,hint:s,error:c,min:l,max:u,disabled:d=!1,readOnly:f=!1,required:m=!1,className:h=``})=>{let g=c??(t.from&&t.to&&t.from>t.to?`Дата «От» не может быть позже даты «До»`:void 0),_=e=>{r?.(e),k(e)&&n?.(e)};return(0,e.jsxs)(`fieldset`,{className:`${O.root} ${h}`,disabled:d,children:[(0,e.jsxs)(`div`,{className:O.range,children:[(0,e.jsx)(D,{value:t.from,mode:i===`datetime`?`datetime`:i,label:a,min:l,max:t.to??u,disabled:d,readOnly:f,required:m,error:g,onChange:e=>_({...t,from:e})}),(0,e.jsx)(D,{value:t.to,mode:i===`datetime`?`datetime`:i,label:o,min:t.from??l,max:u,disabled:d,readOnly:f,required:m,error:g,onChange:e=>_({...t,to:e})})]}),s&&!g&&(0,e.jsx)(p,{children:s})]})},j={group:`_group_1fs9e_1`,skeleton:`_skeleton_1fs9e_3`,text:`_text_1fs9e_5`,rectangular:`_rectangular_1fs9e_7`,circular:`_circular_1fs9e_9`,animated:`_animated_1fs9e_11`,"ds-skeleton":`_ds-skeleton_1fs9e_1`},M=({variant:t=`text`,width:n=`100%`,height:r,lines:i=1,animated:a=!0,className:o=``})=>(0,e.jsx)(`span`,{className:`${j.group} ${o}`,"aria-hidden":`true`,children:Array.from({length:Math.max(1,i)},(o,s)=>(0,e.jsx)(`span`,{className:`${j.skeleton} ${j[t]} ${a?j.animated:``}`,style:{width:s===i-1&&i>1?`70%`:n,height:r}},s))}),N={wrapper:`_wrapper_dkn63_1`,label:`_label_dkn63_17`,container:`_container_dkn63_29`,trigger:`_trigger_dkn63_37`,disabledText:`_disabledText_dkn63_39`,value:`_value_dkn63_109`,placeholder:`_placeholder_dkn63_111`,chevron:`_chevron_dkn63_137`,chevronOpen:`_chevronOpen_dkn63_163`,menu:`_menu_dkn63_171`,option:`_option_dkn63_207`,selected:`_selected_dkn63_245`,message:`_message_dkn63_265`,error:`_error_dkn63_267`,errorState:`_errorState_dkn63_293`},P=(e,t,n)=>{for(let r=0;r<e.length;r+=1){let i=(t+r*n+e.length)%e.length;if(!e[i]?.disabled)return i}return-1},F=({options:n,value:r,onChange:i,placeholder:a=`Выберите опцию`,disabled:o=!1,stringWhileDisabled:s=!1,label:c,error:l,hint:u,className:d=``,name:f,id:p,needMark:m=!0,maxMenuHeight:h})=>{let g=(0,t.useId)(),_=p??`ds-dropdown-${f??g}`,[v,y]=(0,t.useState)(!1),b=(0,t.useRef)(null),x=(0,t.useRef)(null),S=(0,t.useRef)([]),C=(0,t.useMemo)(()=>n.find(e=>e.value===r),[n,r]),w=u?`${_}-hint`:void 0,T=l?`${_}-error`:void 0,E=[w,T].filter(Boolean).join(` `)||void 0,D=o&&s;(0,t.useEffect)(()=>{let e=e=>{b.current?.contains(e.target)||y(!1)},t=e=>{e.key===`Escape`&&v&&(y(!1),x.current?.focus())};return document.addEventListener(`mousedown`,e),document.addEventListener(`keydown`,t),()=>{document.removeEventListener(`mousedown`,e),document.removeEventListener(`keydown`,t)}},[v]);let O=(e,t)=>{let r=P(n,e,t);S.current[r]?.focus(),S.current[r]?.scrollIntoView({block:`nearest`})},k=e=>{e.disabled||(i?.(e.value,e),y(!1),x.current?.focus())};return(0,e.jsxs)(`div`,{ref:b,className:[N.wrapper,l?N.errorState:``,d].filter(Boolean).join(` `),children:[c&&(0,e.jsx)(`label`,{htmlFor:D?void 0:_,className:N.label,children:c}),(0,e.jsx)(`div`,{className:N.container,children:D?(0,e.jsx)(`div`,{id:_,className:N.disabledText,"aria-describedby":E,children:C?.label??a}):(0,e.jsxs)(e.Fragment,{children:[(0,e.jsxs)(`button`,{ref:x,id:_,type:`button`,name:f,className:N.trigger,disabled:o,"aria-haspopup":`listbox`,"aria-expanded":v,"aria-controls":`${_}-listbox`,"aria-describedby":E,"aria-invalid":!!l,onClick:()=>y(e=>!e),onKeyDown:e=>{if(e.key===`ArrowDown`||e.key===`ArrowUp`){e.preventDefault(),y(!0);let t=e.key===`ArrowDown`?1:-1;requestAnimationFrame(()=>O(e.key===`ArrowDown`?0:n.length-1,t))}},children:[(0,e.jsx)(`span`,{className:C?N.value:N.placeholder,children:C?.label??a}),(0,e.jsx)(`span`,{className:`${N.chevron} ${v?N.chevronOpen:``}`,"aria-hidden":`true`,children:(0,e.jsx)(`svg`,{viewBox:`0 0 20 20`,fill:`none`,children:(0,e.jsx)(`path`,{d:`M5 7.5L10 12.5L15 7.5`,stroke:`currentColor`,strokeWidth:`1.8`,strokeLinecap:`round`,strokeLinejoin:`round`})})})]}),v&&(0,e.jsx)(`ul`,{id:`${_}-listbox`,className:N.menu,role:`listbox`,"aria-label":c,style:{maxHeight:h},children:n.map((t,i)=>{let a=t.value===r;return(0,e.jsx)(`li`,{role:`presentation`,children:(0,e.jsxs)(`button`,{ref:e=>{S.current[i]=e},type:`button`,role:`option`,"aria-selected":a,disabled:t.disabled,className:`${N.option} ${a?N.selected:``}`,onClick:()=>k(t),onKeyDown:e=>{if((e.key===`ArrowDown`||e.key===`ArrowUp`)&&(e.preventDefault(),O(i+(e.key===`ArrowDown`?1:-1),e.key===`ArrowDown`?1:-1)),e.key===`Tab`&&y(!1),e.key===`Home`||e.key===`End`){e.preventDefault();let t=e.key===`Home`?1:-1;O(e.key===`Home`?0:n.length-1,t)}},children:[(0,e.jsx)(`span`,{children:t.label}),a&&m&&(0,e.jsx)(`span`,{"aria-hidden":`true`,children:`✓`})]})},t.value)})})]})}),u&&!l&&(0,e.jsx)(`span`,{id:w,className:N.message,children:u}),l&&(0,e.jsx)(`span`,{id:T,className:N.error,children:l})]})},I=e=>`${e.id}:${e.direction}`,L=({options:t,value:n,onChange:r,label:i=`Сортировка`,placeholder:a=`Выберите сортировку`,disabled:o=!1,className:s})=>{let c=t.flatMap(e=>[{value:I({id:e.id,direction:`asc`}),label:e.ascLabel??`${e.label} · по возрастанию`,disabled:e.disabled},{value:I({id:e.id,direction:`desc`}),label:e.descLabel??`${e.label} · по убыванию`,disabled:e.disabled}]);return(0,e.jsx)(F,{options:c,value:n?I(n):``,label:i,placeholder:a,disabled:o,className:s,onChange:e=>{let t=e.lastIndexOf(`:`);r?.({id:e.slice(0,t),direction:e.slice(t+1)})}})},R={root:`_root_1h9ti_1`,tableWrap:`_tableWrap_1h9ti_3`,table:`_table_1h9ti_3`,sticky:`_sticky_1h9ti_15`,sortButton:`_sortButton_1h9ti_17`,state:`_state_1h9ti_21`,cards:`_cards_1h9ti_23`,mobileSort:`_mobileSort_1h9ti_23`,card:`_card_1h9ti_23`,spanTwo:`_spanTwo_1h9ti_37`,default:`_default_1h9ti_41`,tableOnMobile:`_tableOnMobile_1h9ti_41`,wide:`_wide_1h9ti_45`},ee=(0,n.tableFeatures)({rowSortingFeature:n.rowSortingFeature,sortedRowModel:(0,n.createSortedRowModel)()}),te=(e,t)=>{let n=new Set;for(let t of e){if(!t.id.trim())return`Идентификатор колонки не может быть пустым`;if(n.has(t.id))return`Идентификатор колонки «${t.id}» повторяется`;n.add(t.id)}for(let n=0;n<t.length;n+=1){let r=t[n];for(let t of e)if(typeof t.accessor==`string`&&!(t.accessor in r))return`В строке ${n+1} отсутствует колонка «${t.id}»`}return null},z=(e,t)=>typeof e==`function`?e(t):t[e],ne=e=>{if(e==null||e===``)return null;let t=Date.parse(String(e));return Number.isNaN(t)?null:t},re=(e,t,n)=>{let r=ne(e.getValue(n)),i=ne(t.getValue(n));return r===null&&i===null?0:r===null?-1:i===null?1:r-i},ie=(e,t,n)=>{let r=e.getValue(n),i=t.getValue(n);return r==null&&i==null?0:r==null?-1:i==null?1:Number(r)-Number(i)},B=(e,t,n)=>{let r=e.getValue(n),i=t.getValue(n);return r==null&&i==null?0:r==null?-1:i==null?1:Number(!!r)-Number(!!i)},ae=(e,t,n)=>{let r=String(e.getValue(n)??``),i=String(t.getValue(n)??``);return r.localeCompare(i,void 0,{numeric:!0,sensitivity:`base`})},oe=e=>{switch(e){case`date`:return re;case`number`:return ie;case`boolean`:return B;case`text`:case void 0:return ae;case`custom`:return}},se=e=>{let t=t=>z(e.accessor,t),n=e.sortFn??oe(e.dataType),r=e.enableSorting??(e.dataType!==`custom`&&n!==void 0),i={id:e.id,accessorFn:t,header:()=>e.header,cell:t=>{let n=t.getValue();return e.cell?.(t.row.original,n)??String(n??``)},enableSorting:r,sortDescFirst:e.sortDescFirst};return n!==void 0&&(i.sortFn=n),i},ce=({columns:r,data:i,tableOnMobile:a=!1,breakpoint:o=`default`,sorting:s,onSortingChange:c,renderMobileCard:l,getRowId:u,caption:d,ariaLabel:f,loading:p=!1,error:m,emptyState:h=`Нет данных`,stickyHeader:g=!1,maxHeight:_,className:v=``})=>{let[y,b]=(0,t.useState)([]),x=s??y,S=(0,t.useMemo)(()=>te(r,i),[r,i]),C=(0,t.useMemo)(()=>r.map(se),[r]),w=(0,n.useTable)({features:ee,columns:C,data:i,state:{sorting:x},onSortingChange:e=>{let t=typeof e==`function`?e(x):e;s===void 0&&b(t),c?.(t)},getRowId:u}),T=w.getRowModel().rows,E=r.filter(e=>e.enableSorting??e.dataType!==`custom`).map(e=>({id:e.id,label:typeof e.header==`string`?e.header:e.id})),D=[R.root,o===`wide`?R.wide:R.default,a?R.tableOnMobile:``,v].filter(Boolean).join(` `),O=S??m;return(0,e.jsxs)(`section`,{className:D,"aria-busy":p,children:[!a&&!p&&!O&&T.length>0&&E.length>0&&(0,e.jsx)(L,{className:R.mobileSort,options:E,value:x[0]?{id:x[0].id,direction:x[0].desc?`desc`:`asc`}:null,onChange:e=>w.setSorting([{id:e.id,desc:e.direction===`desc`}])}),(0,e.jsx)(`div`,{className:R.tableWrap,style:{maxHeight:_},children:(0,e.jsxs)(`table`,{className:R.table,"aria-label":f,children:[d&&(0,e.jsx)(`caption`,{children:d}),(0,e.jsx)(`thead`,{className:g?R.sticky:``,children:w.getHeaderGroups().map(t=>(0,e.jsx)(`tr`,{children:t.headers.map(t=>{let n=t.column.getIsSorted(),r=t.column.getCanSort(),i=t.column.getToggleSortingHandler();return(0,e.jsx)(`th`,{scope:`col`,"aria-sort":n===`asc`?`ascending`:n===`desc`?`descending`:`none`,children:(0,e.jsxs)(`button`,{type:`button`,className:R.sortButton,disabled:!r,onClick:i,children:[(0,e.jsx)(w.FlexRender,{header:t}),(0,e.jsx)(`span`,{"aria-hidden":`true`,children:n===`asc`?`↑`:n===`desc`?`↓`:`↕`})]})},t.id)})},t.id))}),(0,e.jsx)(`tbody`,{children:p?(0,e.jsx)(`tr`,{children:(0,e.jsx)(`td`,{colSpan:r.length,children:(0,e.jsx)(M,{lines:3})})}):O?(0,e.jsx)(`tr`,{children:(0,e.jsx)(`td`,{className:R.state,colSpan:r.length,children:O})}):T.length===0?(0,e.jsx)(`tr`,{children:(0,e.jsx)(`td`,{className:R.state,colSpan:r.length,children:h})}):T.map(t=>(0,e.jsx)(`tr`,{children:t.getAllCells().map(t=>(0,e.jsx)(`td`,{children:(0,e.jsx)(w.FlexRender,{cell:t})},t.id))},t.id))})]})}),!a&&(0,e.jsx)(`div`,{className:R.cards,role:`list`,"aria-label":f??d,children:p?(0,e.jsx)(M,{lines:4}):O?(0,e.jsx)(`div`,{className:R.state,children:O}):T.length===0?(0,e.jsx)(`div`,{className:R.state,children:h}):T.map(t=>{if(l)return(0,e.jsx)(`div`,{role:`listitem`,children:l({row:t.original,columns:r})},t.id);let n=r.filter(e=>!e.mobile?.hideOnMobile).sort((e,t)=>(e.mobile?.mobileOrder??0)-(t.mobile?.mobileOrder??0)),i=n.find(e=>e.mobile?.primary)??n.find(e=>e.mobile?.mobileVariant!==`actions`),a=e=>z(e.accessor,t.original),o=e=>e.mobile?.renderMobile?.(t.original,a(e))??e.cell?.(t.original,a(e))??String(a(e)??``);return(0,e.jsxs)(`article`,{role:`listitem`,className:R.card,children:[(0,e.jsx)(`h3`,{children:i?o(i):`Строка ${t.index+1}`}),(0,e.jsx)(`dl`,{children:n.filter(e=>e!==i&&e.mobile?.mobileVariant!==`actions`).map(t=>(0,e.jsxs)(`div`,{className:t.mobile?.mobileSpan===2?R.spanTwo:``,children:[(0,e.jsx)(`dt`,{children:t.mobile?.mobileLabel??t.header}),(0,e.jsx)(`dd`,{children:o(t)})]},t.id))}),n.filter(e=>e.mobile?.mobileVariant===`actions`).map(t=>(0,e.jsx)(`footer`,{children:o(t)},t.id))]},t.id)})})]})},le=({options:n,value:r,onChange:i,placeholder:a=`Выберите опции`,disabled:o=!1,label:s,error:c,hint:l,className:u=``,name:d,id:f,closeOnSelect:p=!1,maxMenuHeight:m})=>{let h=(0,t.useId)(),g=f??`ds-dropdown-multiple-${d??h}`,[_,v]=(0,t.useState)(!1),y=(0,t.useRef)(null),b=(0,t.useRef)(null),x=(0,t.useRef)([]),S=(0,t.useMemo)(()=>n.filter(e=>r.includes(e.value)),[n,r]),C=S.map(e=>e.label).join(`, `),w=l?`${g}-hint`:void 0,T=c?`${g}-error`:void 0;(0,t.useEffect)(()=>{let e=e=>{y.current?.contains(e.target)||v(!1)},t=e=>{e.key===`Escape`&&_&&(v(!1),b.current?.focus())};return document.addEventListener(`mousedown`,e),document.addEventListener(`keydown`,t),()=>{document.removeEventListener(`mousedown`,e),document.removeEventListener(`keydown`,t)}},[_]);let E=e=>{if(e.disabled)return;let t=r.includes(e.value)?r.filter(t=>t!==e.value):[...r,e.value];i?.(t,n.filter(e=>t.includes(e.value))),p&&(v(!1),b.current?.focus())},D=(e,t)=>{let r=P(n,e,t);x.current[r]?.focus(),x.current[r]?.scrollIntoView({block:`nearest`})};return(0,e.jsxs)(`div`,{ref:y,className:[N.wrapper,c?N.errorState:``,u].filter(Boolean).join(` `),children:[s&&(0,e.jsx)(`label`,{htmlFor:g,className:N.label,children:s}),(0,e.jsxs)(`div`,{className:N.container,children:[(0,e.jsxs)(`button`,{ref:b,id:g,type:`button`,name:d,className:N.trigger,disabled:o,"aria-haspopup":`listbox`,"aria-expanded":_,"aria-controls":`${g}-listbox`,"aria-describedby":[w,T].filter(Boolean).join(` `)||void 0,"aria-invalid":!!c,onClick:()=>v(e=>!e),onKeyDown:e=>{if(e.key===`ArrowDown`||e.key===`ArrowUp`){e.preventDefault(),v(!0);let t=e.key===`ArrowDown`?1:-1;requestAnimationFrame(()=>D(e.key===`ArrowDown`?0:n.length-1,t))}},children:[(0,e.jsx)(`span`,{className:S.length?N.value:N.placeholder,children:C||a}),(0,e.jsx)(`span`,{className:`${N.chevron} ${_?N.chevronOpen:``}`,"aria-hidden":`true`,children:`⌄`})]}),_&&(0,e.jsx)(`ul`,{id:`${g}-listbox`,className:N.menu,role:`listbox`,"aria-label":s,"aria-multiselectable":`true`,style:{maxHeight:m},children:n.map((t,i)=>{let a=r.includes(t.value);return(0,e.jsx)(`li`,{role:`presentation`,children:(0,e.jsxs)(`button`,{ref:e=>{x.current[i]=e},type:`button`,role:`option`,"aria-selected":a,disabled:t.disabled,className:`${N.option} ${a?N.selected:``}`,onClick:()=>E(t),onKeyDown:e=>{if(e.key===`ArrowDown`||e.key===`ArrowUp`){e.preventDefault();let t=e.key===`ArrowDown`?1:-1;D(i+t,t)}if(e.key===`Home`||e.key===`End`){e.preventDefault();let t=e.key===`Home`?1:-1;D(e.key===`Home`?0:n.length-1,t)}e.key===`Tab`&&v(!1)},children:[(0,e.jsx)(`span`,{children:t.label}),(0,e.jsx)(`span`,{"aria-hidden":`true`,children:a?`✓`:``})]})},t.value)})})]}),l&&!c&&(0,e.jsx)(`span`,{id:w,className:N.message,children:l}),c&&(0,e.jsx)(`span`,{id:T,className:N.error,children:c})]})},ue={approve:`M4 12l5 5L20 6`,reject:`M5 5l14 14M19 5L5 19`,edit:`M4 20h4L19 9l-4-4L4 16v4z`,cross:`M5 5l14 14M19 5L5 19`,chevron:`M6 9l6 6 6-6`,basket:`M4 7h16l-1 13H5L4 7zm3 0V4h10v3`,info:`M12 10v7m0-10v.01`,warning:`M12 4L3 20h18L12 4zm0 5v5m0 3v.01`},de=({name:t,title:n,width:r=24,height:i=24,...a})=>(0,e.jsxs)(`svg`,{viewBox:`0 0 24 24`,width:r,height:i,fill:`none`,stroke:`currentColor`,strokeWidth:`1.8`,strokeLinecap:`round`,strokeLinejoin:`round`,role:n?`img`:void 0,"aria-hidden":!n||void 0,focusable:`false`,...a,children:[n&&(0,e.jsx)(`title`,{children:n}),(0,e.jsx)(`path`,{d:ue[t]})]}),V={root:`_root_1y2s8_1`,header:`_header_1y2s8_21`,title:`_title_1y2s8_41`,dismiss:`_dismiss_1y2s8_55`,content:`_content_1y2s8_113`},fe=({title:n,children:r,dismissible:i=!1,onDismiss:a,dismissLabel:o=`Закрыть информационный блок`,headingAs:s=`h3`,className:c=``})=>{let l=`ds-info-block-${(0,t.useId)()}`;return(0,e.jsxs)(`section`,{className:`${V.root} ${c}`,"aria-labelledby":l,children:[(0,e.jsxs)(`header`,{className:V.header,children:[(0,e.jsx)(s,{id:l,className:V.title,children:n}),i&&(0,e.jsx)(`button`,{type:`button`,className:V.dismiss,onClick:a,"aria-label":o,children:(0,e.jsx)(`svg`,{viewBox:`0 0 20 20`,"aria-hidden":`true`,children:(0,e.jsx)(`path`,{d:`M5 5L15 15M15 5L5 15`,fill:`none`,stroke:`currentColor`,strokeWidth:`1.8`,strokeLinecap:`round`})})})]}),(0,e.jsx)(`div`,{className:V.content,children:r})]})},H={wrapper:`_wrapper_ip6vf_1`,control:`_control_ip6vf_3`,input:`_input_ip6vf_5`,disabledText:`_disabledText_ip6vf_5`,inputError:`_inputError_ip6vf_39`,trailingAction:`_trailingAction_ip6vf_41`},pe=({value:n,onChange:r,type:i=`text`,placeholder:a=``,disabled:o=!1,readOnly:s=!1,stringWhileDisabled:c=!1,label:l,error:u,hint:d,className:m=``,name:h,id:g,clearable:_=!0,required:v=!1,selectTextOnFocus:y=!1,isPassword:b=!1,passwordVisibleLabel:x=`Скрыть пароль`,passwordHiddenLabel:S=`Показать пароль`,onFocus:C,...w})=>{let T=(0,t.useId)(),E=g??`ds-input-${h??T}`,D=(0,t.useRef)(null),[O,k]=(0,t.useState)(!1),A=d?`${E}-hint`:void 0,j=u?`${E}-error`:void 0,M=String(n??``),N=[A,j].filter(Boolean).join(` `)||void 0,P=b?O?`text`:`password`:i;return(0,t.useEffect)(()=>{b||k(!1)},[b]),(0,e.jsxs)(`div`,{className:`${H.wrapper} ${m}`,children:[l&&(0,e.jsx)(f,{htmlFor:E,required:v,disabled:o,children:l}),o&&c?(0,e.jsx)(`div`,{id:E,className:H.disabledText,"aria-describedby":N,children:M||a}):(0,e.jsxs)(`div`,{className:H.control,children:[(0,e.jsx)(`input`,{ref:D,id:E,name:h,type:P,value:M,placeholder:a,disabled:o,readOnly:s,required:v,"aria-invalid":!!u,"aria-describedby":N,className:`${H.input} ${u?H.inputError:``}`,onChange:e=>{if(i===`number`&&!b){let t=e.target.value===``?``:Number(e.target.value);r?.(t,e);return}r?.(e.target.value,e)},onFocus:e=>{y&&e.currentTarget.value&&e.currentTarget.select(),C?.(e)},...w}),b&&(0,e.jsx)(`button`,{type:`button`,className:H.trailingAction,disabled:o,"aria-label":O?x:S,"aria-pressed":O,onClick:()=>k(e=>!e),children:O?(0,e.jsx)(`svg`,{viewBox:`0 0 24 24`,"aria-hidden":`true`,children:(0,e.jsx)(`path`,{d:`M3 3l18 18M10.6 10.7a2 2 0 0 0 2.7 2.7M9.9 4.2A10.7 10.7 0 0 1 12 4c5.5 0 9 5.3 9 5.3a14 14 0 0 1-2.3 2.8M6.6 6.6C4.3 8.1 3 10 3 10s3.5 5 9 5c1 0 2-.2 2.8-.5`})}):(0,e.jsxs)(`svg`,{viewBox:`0 0 24 24`,"aria-hidden":`true`,children:[(0,e.jsx)(`path`,{d:`M3 12s3.5-5 9-5 9 5 9 5-3.5 5-9 5-9-5-9-5Z`}),(0,e.jsx)(`circle`,{cx:`12`,cy:`12`,r:`2.5`})]})}),!b&&_&&M&&!o&&!s&&(0,e.jsx)(`button`,{type:`button`,className:H.trailingAction,"aria-label":`Очистить поле`,onClick:()=>{let e=D.current;e&&((Object.getOwnPropertyDescriptor(HTMLInputElement.prototype,`value`)?.set)?.call(e,``),e.dispatchEvent(new Event(`input`,{bubbles:!0})),e.focus())},children:`×`})]}),d&&!u&&(0,e.jsx)(p,{id:A,children:d}),u&&(0,e.jsx)(p,{id:j,variant:`error`,children:u})]})},U={wrapper:`_wrapper_vu1ob_1`,input:`_input_vu1ob_21`,switch:`_switch_vu1ob_35`,thumb:`_thumb_vu1ob_67`,label:`_label_vu1ob_111`,disabled:`_disabled_vu1ob_123`},me=({checked:n,onChange:r,label:i,disabled:a=!1,readOnly:o=!1,className:s=``,name:c,id:l,value:u})=>{let d=(0,t.useId)(),f=l??`ds-radio-button-${c??d}`;return(0,e.jsxs)(`label`,{htmlFor:f,className:`${U.wrapper} ${a?U.disabled:``} ${s}`,children:[(0,e.jsx)(`input`,{id:f,className:U.input,type:`checkbox`,role:`switch`,name:c,value:u,checked:n,disabled:a,"aria-readonly":o||void 0,onChange:e=>{o||r?.(e.target.checked,e)}}),(0,e.jsx)(`span`,{className:U.switch,"aria-hidden":`true`,children:(0,e.jsx)(`span`,{className:U.thumb})}),i&&(0,e.jsx)(`span`,{className:U.label,children:i})]})},W={root:`_root_kepgo_1`,grid:`_grid_kepgo_3`,actions:`_actions_kepgo_5`},he=({filters:t,values:n,onChange:r,onApply:i,onReset:a,applyMode:o=`instant`,loading:s=!1,disabled:c=!1,className:l=``})=>{let d=(e,t)=>{let a={...n,[e]:t};r?.(a,e),o===`instant`&&i?.(a)};return(0,e.jsxs)(`section`,{className:`${W.root} ${l}`,"aria-label":`Фильтры`,"aria-busy":s,children:[(0,e.jsx)(`div`,{className:W.grid,children:t.filter(e=>!e.hidden).map(t=>{let r=c||s||t.disabled,i=n[t.id];if(t.type===`input`){let n={label:t.label,hint:t.hint,placeholder:t.placeholder,disabled:r};return t.inputType===`number`?(0,e.jsx)(pe,{...n,type:`number`,value:i??``,onChange:e=>d(t.id,e)},t.id):(0,e.jsx)(pe,{...n,type:`text`,value:String(i??``),onChange:e=>d(t.id,e)},t.id)}if(t.type===`dropdown`)return(0,e.jsx)(F,{label:t.label,hint:t.hint,placeholder:t.placeholder,options:t.options,value:String(i??``),disabled:r,onChange:e=>d(t.id,e)},t.id);if(t.type===`multiple`)return(0,e.jsx)(le,{label:t.label,hint:t.hint,placeholder:t.placeholder,options:t.options,value:Array.isArray(i)?i:[],disabled:r,onChange:e=>d(t.id,e)},t.id);if(t.type===`checkbox`)return(0,e.jsx)(h,{label:t.label,hint:t.hint,checked:!!i,disabled:r,onChange:e=>d(t.id,e)},t.id);if(t.type===`radio`)return(0,e.jsx)(me,{label:t.label,checked:!!i,disabled:r,onChange:e=>d(t.id,e)},t.id);let a=i&&typeof i==`object`&&!Array.isArray(i)?i:{from:null,to:null};return(0,e.jsx)(A,{hint:t.hint,mode:t.mode,min:t.min,max:t.max,value:a,disabled:r,onDraftChange:e=>d(t.id,e)},t.id)})}),(a||o===`manual`)&&(0,e.jsxs)(`div`,{className:W.actions,children:[a&&(0,e.jsx)(u,{variant:`destructiveOutline`,disabled:c||s,onClick:a,children:`Сбросить`}),o===`manual`&&(0,e.jsx)(u,{isLoading:s,disabled:c,onClick:()=>i?.(n),children:`Применить`})]})]})},G={wrapper:`_wrapper_1ymdr_1`,dropzone:`_dropzone_1ymdr_3`,dragActive:`_dragActive_1ymdr_5`,disabled:`_disabled_1ymdr_7`,error:`_error_1ymdr_9`,nativeInput:`_nativeInput_1ymdr_11`,empty:`_empty_1ymdr_13`,uploadIcon:`_uploadIcon_1ymdr_15`,browseButton:`_browseButton_1ymdr_17`,files:`_files_1ymdr_19`,file:`_file_1ymdr_19`,fileName:`_fileName_1ymdr_23`,fileSize:`_fileSize_1ymdr_25`},K=e=>`${e.name}:${e.size}:${e.lastModified}`,ge=e=>e<1024?`${e} Б`:e<1048576?`${(e/1024).toFixed(1)} КБ`:`${(e/1024/1024).toFixed(1)} МБ`,_e=(e,t)=>!t||t.split(`,`).map(e=>e.trim().toLowerCase()).some(t=>t.startsWith(`.`)?e.name.toLowerCase().endsWith(t):t.endsWith(`/*`)?e.type.startsWith(t.slice(0,-1)):e.type.toLowerCase()===t),ve=({value:n,onChange:r,multiple:i=!1,accept:a,maxSize:o,maxFiles:s,label:c,hint:l,error:d,required:m=!1,disabled:h=!1,readOnly:g=!1,name:_,id:v,className:y=``,dropLabel:b=`Перетащите файлы в эту область`,browseLabel:x=`Выбрать файлы`,addMoreLabel:S=`Добавить ещё`,onReject:C})=>{let w=(0,t.useId)(),T=v??`ds-file-input-${_??w}`,E=(0,t.useRef)(null),D=(0,t.useRef)(0),[O,k]=(0,t.useState)(!1),A=l?`${T}-hint`:void 0,j=d?`${T}-error`:void 0,M=[A,j].filter(Boolean).join(` `)||void 0,N=!h&&!g,P=e=>{let t=[],c=new Set(n.map(K)),l=e.filter(e=>_e(e,a)?o!==void 0&&e.size>o?(t.push({file:e,reason:`maxSize`}),!1):!c.has(K(e))&&(c.add(K(e)),!0):(t.push({file:e,reason:`accept`}),!1)),u=i?s:1,d=i?[...n,...l]:l.slice(-1);u!==void 0&&d.length>u&&(d.slice(u).forEach(e=>t.push({file:e,reason:`maxFiles`})),d=d.slice(0,u)),t.length&&C?.(t),l.length&&r?.(d),E.current&&(E.current.value=``)};return(0,e.jsxs)(`div`,{className:`${G.wrapper} ${y}`,children:[c&&(0,e.jsx)(f,{htmlFor:T,required:m,disabled:h,children:c}),(0,e.jsxs)(`div`,{className:`${G.dropzone} ${O?G.dragActive:``} ${h?G.disabled:``} ${d?G.error:``}`,onDragEnter:e=>{e.preventDefault(),N&&++D.current===1&&k(!0)},onDragOver:e=>e.preventDefault(),onDragLeave:e=>{e.preventDefault(),--D.current<=0&&(D.current=0,k(!1))},onDrop:e=>{e.preventDefault(),D.current=0,k(!1),N&&P(Array.from(e.dataTransfer.files))},children:[(0,e.jsx)(`input`,{ref:E,id:T,name:_,className:G.nativeInput,type:`file`,multiple:i,accept:a,required:m&&n.length===0,disabled:!N,"aria-describedby":M,"aria-invalid":!!d,onChange:e=>P(Array.from(e.target.files??[]))}),n.length?(0,e.jsxs)(e.Fragment,{children:[(0,e.jsx)(`ul`,{className:G.files,"aria-live":`polite`,children:n.map((t,i)=>(0,e.jsxs)(`li`,{className:G.file,children:[(0,e.jsx)(`span`,{className:G.fileName,title:t.name,children:t.name}),(0,e.jsx)(`span`,{className:G.fileSize,children:ge(t.size)}),N&&(0,e.jsx)(u,{variant:`empty`,size:`sm`,"aria-label":`Удалить файл ${t.name}`,onClick:()=>r?.(n.filter((e,t)=>t!==i)),children:`×`})]},K(t)))}),N&&(i||n.length===0)&&(0,e.jsx)(u,{className:G.browseButton,size:`sm`,onClick:()=>E.current?.click(),children:S}),N&&!i&&(0,e.jsx)(u,{className:G.browseButton,size:`sm`,onClick:()=>E.current?.click(),children:x})]}):(0,e.jsxs)(`div`,{className:G.empty,children:[(0,e.jsx)(`span`,{className:G.uploadIcon,"aria-hidden":`true`,children:`↑`}),(0,e.jsx)(`strong`,{children:O?`Отпустите файлы здесь`:b}),!O&&N&&(0,e.jsxs)(e.Fragment,{children:[(0,e.jsx)(`span`,{children:`или`}),(0,e.jsx)(u,{className:G.browseButton,onClick:()=>E.current?.click(),children:x})]})]})]}),l&&!d&&(0,e.jsx)(p,{id:A,children:l}),d&&(0,e.jsx)(p,{id:j,variant:`error`,live:!0,children:d})]})},ye=0,q=(0,i.create)(e=>({modals:[],openModal:(t,n={},r={})=>{ye+=1;let i=`ds-modal-${ye}`;return e(e=>({modals:[...e.modals,{id:i,name:t,payload:n,closeOnEscape:r.closeOnEscape??!0,closeOnBackdrop:r.closeOnBackdrop??!0}]})),i},closeModal:t=>e(e=>({modals:e.modals.filter(e=>e.id!==t)})),closeTopModal:()=>e(e=>({modals:e.modals.slice(0,-1)})),closeAllModals:()=>e({modals:[]})})),be=()=>q.setState({modals:[]}),J={layer:`_layer_1nb2z_1`,backdrop:`_backdrop_1nb2z_3`,panel:`_panel_1nb2z_5`,header:`_header_1nb2z_9`,title:`_title_1nb2z_11`,description:`_description_1nb2z_13`,content:`_content_1nb2z_15`},xe=`button:not(:disabled), [href], input:not(:disabled), select:not(:disabled), textarea:not(:disabled), [tabindex]:not([tabindex="-1"])`,Se=({children:n,title:r,description:i,modalId:a,closeLabel:o=`Закрыть модальное окно`,className:s=``,role:c=`dialog`})=>{let l=(0,t.useId)(),d=(0,t.useId)(),f=(0,t.useRef)(null),p=q(e=>e.closeModal);return(0,t.useEffect)(()=>{let e=document.activeElement,t=f.current;return(t?.querySelector(xe)??t)?.focus(),()=>e?.focus()},[]),(0,e.jsxs)(`div`,{ref:f,className:`${J.panel} ${s}`,role:c,"aria-modal":`true`,"aria-labelledby":r?l:void 0,"aria-describedby":i?d:void 0,tabIndex:-1,onKeyDown:e=>{if(e.key!==`Tab`)return;let t=Array.from(f.current?.querySelectorAll(xe)??[]);if(!t.length){e.preventDefault();return}let n=t[0],r=t[t.length-1];e.shiftKey&&document.activeElement===n?(e.preventDefault(),r?.focus()):!e.shiftKey&&document.activeElement===r&&(e.preventDefault(),n?.focus())},children:[(r||o)&&(0,e.jsxs)(`header`,{className:J.header,children:[r&&(0,e.jsx)(`h2`,{id:l,className:J.title,children:r}),(0,e.jsx)(u,{variant:`empty`,size:`sm`,"aria-label":o,onClick:()=>p(a),children:(0,e.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`24`,height:`24`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,e.jsx)(`path`,{d:`M18 6 6 18`}),(0,e.jsx)(`path`,{d:`m6 6 12 12`})]})})]}),i&&(0,e.jsx)(`p`,{id:d,className:J.description,children:i}),(0,e.jsx)(`div`,{className:J.content,children:n})]})},Ce=({registry:n})=>{let i=q(e=>e.modals),a=q(e=>e.closeModal),o=q(e=>e.closeAllModals);return(0,t.useEffect)(()=>{let e=e=>{if(e.key!==`Escape`)return;let t=q.getState().modals.at(-1);t?.closeOnEscape&&a(t.id)};return document.addEventListener(`keydown`,e),()=>document.removeEventListener(`keydown`,e)},[a]),!i.length||typeof document>`u`?null:(0,r.createPortal)((0,e.jsx)(`div`,{className:J.layer,"aria-label":`Модальные окна`,children:i.map((t,r)=>{let s=n[t.name];return s?(0,e.jsx)(`div`,{className:J.backdrop,"aria-hidden":r!==i.length-1||void 0,onMouseDown:e=>{e.target===e.currentTarget&&t.closeOnBackdrop&&a(t.id)},children:(0,e.jsx)(s,{...t.payload,modalId:t.id,close:()=>a(t.id),closeAll:o})},t.id):null})}),document.body)},we=({registry:n,children:r,lockBodyScroll:i=!0})=>{let a=q(e=>e.modals.length);return(0,t.useEffect)(()=>{if(!i||a===0)return;let e=document.body.style.overflow;return document.body.style.overflow=`hidden`,()=>{document.body.style.overflow=e}},[i,a]),(0,e.jsxs)(e.Fragment,{children:[r,(0,e.jsx)(Ce,{registry:n})]})},Te=e=>e,Y={message:`_message_1vtru_1`,actions:`_actions_1vtru_3`},Ee=new Map,De=0,Oe=({modalId:t,close:n,title:r=`Подтверждение`,message:i=`Продолжить действие?`,confirmLabel:a=`Подтвердить`,cancelLabel:o=`Отмена`,tone:s=`default`,requestId:c})=>{let l=e=>{Ee.get(c)?.(e),Ee.delete(c),n()};return(0,e.jsxs)(Se,{modalId:t,title:r,role:`alertdialog`,children:[(0,e.jsx)(`p`,{className:Y.message,children:i}),(0,e.jsxs)(`div`,{className:Y.actions,children:[(0,e.jsx)(u,{variant:`outline`,onClick:()=>l(!1),children:o}),(0,e.jsx)(u,{variant:s===`danger`?`destructive`:`primary`,onClick:()=>l(!0),children:a})]})]})},ke=({modalId:t,close:n,title:r=`Ошибка`,message:i,closeLabel:a=`Закрыть`})=>(0,e.jsxs)(Se,{modalId:t,title:r,role:`alertdialog`,children:[(0,e.jsx)(`p`,{className:Y.message,children:i}),(0,e.jsx)(`div`,{className:Y.actions,children:(0,e.jsx)(u,{onClick:n,children:a})})]}),Ae=Te({ConfirmModal:Oe,ErrorModal:ke}),je=()=>{let e=q(e=>e.openModal);return(t={})=>new Promise(n=>{De+=1;let r=`confirm-${De}`;Ee.set(r,n),e(`ConfirmModal`,{...t,requestId:r},{closeOnEscape:!1})})},Me=e=>e instanceof Error?e.message:typeof e==`string`?e:e&&typeof e==`object`&&`message`in e&&typeof e.message==`string`?e.message:`Произошла неизвестная ошибка`,Ne=()=>{let e=q(e=>e.openModal);return{showError:(t,n)=>e(`ErrorModal`,{title:n,message:Me(t)})}},Pe=(0,i.create)(()=>({})),Fe=(0,i.create)(()=>({})),Ie=()=>{let e=q(e=>e.modals),t=q(e=>e.openModal);return{openModal:(e,n={},r)=>t(e,n,r),closeModal:q(e=>e.closeModal),closeTopModal:q(e=>e.closeTopModal),closeAllModals:q(e=>e.closeAllModals),isOpen:t=>e.some(e=>e.name===t),count:e.length}},Le={root:`_root_1x7h7_1`},Re=({label:t=`Загрузка страницы`,className:n=``})=>(0,e.jsxs)(`div`,{className:`${Le.root} ${n}`,role:`status`,"aria-label":t,children:[(0,e.jsx)(c,{decorative:!0}),(0,e.jsx)(`span`,{children:t})]}),X={viewport:`_viewport_15mi5_1`,"top-right":`_top-right_15mi5_3`,"top-left":`_top-left_15mi5_5`,"bottom-right":`_bottom-right_15mi5_7`,"bottom-left":`_bottom-left_15mi5_9`,toast:`_toast_15mi5_11`,body:`_body_15mi5_13`,icon:`_icon_15mi5_15`,info:`_info_15mi5_17`,success:`_success_15mi5_19`,warning:`_warning_15mi5_21`,error:`_error_15mi5_23`},ze=t=>{let n;return n=t===`info`?(0,e.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`24`,height:`24`,viewBox:`0 0 24 24`,fill:`none`,stroke:`#179cf0`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,e.jsx)(`circle`,{cx:`12`,cy:`12`,r:`10`}),(0,e.jsx)(`path`,{d:`M12 16v-4`}),(0,e.jsx)(`path`,{d:`M12 8h.01`})]}):t===`success`?(0,e.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`24`,height:`24`,viewBox:`0 0 24 24`,fill:`none`,stroke:`#179c66`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,e.jsx)(`circle`,{cx:`12`,cy:`12`,r:`10`}),(0,e.jsx)(`path`,{d:`m9 12 2 2 4-4`})]}):t===`warning`?(0,e.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`24`,height:`24`,viewBox:`0 0 24 24`,fill:`none`,stroke:`#f59e0b`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,e.jsx)(`path`,{d:`m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3`}),(0,e.jsx)(`path`,{d:`M12 9v4`}),(0,e.jsx)(`path`,{d:`M12 17h.01`})]}):t===`error`?(0,e.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`24`,height:`24`,viewBox:`0 0 24 24`,fill:`none`,stroke:`#dc2626`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,e.jsx)(`path`,{d:`m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3`}),(0,e.jsx)(`path`,{d:`M12 9v4`}),(0,e.jsx)(`path`,{d:`M12 17h.01`})]}):(0,e.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`24`,height:`24`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,e.jsx)(`circle`,{cx:`12`,cy:`12`,r:`10`}),(0,e.jsx)(`path`,{d:`m15 9-6 6`}),(0,e.jsx)(`path`,{d:`m9 9 6 6`})]}),n},Be=({toast:n,onClose:r})=>{let[i,a]=(0,t.useState)(!1),o=(0,t.useRef)(n.duration),s=(0,t.useRef)(Date.now());return(0,t.useEffect)(()=>{if(i||n.duration<=0)return;s.current=Date.now();let e=setTimeout(()=>r(n.id),o.current);return()=>{clearTimeout(e),o.current=Math.max(0,o.current-(Date.now()-s.current))}},[r,i,n.duration,n.id]),(0,e.jsxs)(`article`,{className:`${X.toast} ${X[n.variant]}`,role:n.variant===`error`?`alert`:`status`,"aria-live":n.variant===`error`?`assertive`:`polite`,onMouseEnter:()=>a(!0),onMouseLeave:()=>a(!1),onFocus:()=>a(!0),onBlur:()=>a(!1),children:[(0,e.jsx)(`div`,{children:ze(n.variant)}),(0,e.jsxs)(`div`,{className:X.body,children:[n.title&&(0,e.jsx)(`strong`,{children:n.title}),(0,e.jsx)(`div`,{children:n.message}),n.action&&(0,e.jsx)(u,{variant:`empty`,size:`sm`,onClick:()=>{n.action?.onClick(),(n.action?.dismissOnClick??!0)&&r(n.id)},children:n.action.label})]}),n.closable&&(0,e.jsx)(u,{variant:`empty`,size:`sm`,"aria-label":`Закрыть уведомление`,onClick:()=>r(n.id),children:(0,e.jsxs)(`svg`,{xmlns:`http://www.w3.org/2000/svg`,width:`24`,height:`24`,viewBox:`0 0 24 24`,fill:`none`,stroke:`currentColor`,strokeWidth:`2`,strokeLinecap:`round`,strokeLinejoin:`round`,children:[(0,e.jsx)(`path`,{d:`M18 6 6 18`}),(0,e.jsx)(`path`,{d:`m6 6 12 12`})]})})]})},Ve=0,Z=(0,i.create)(e=>({toasts:[],showToast:t=>{Ve+=1;let n=`ds-toast-${Ve}`;return e(e=>({toasts:[...e.toasts,{variant:`info`,duration:5e3,closable:!0,...t,id:n}]})),n},removeToast:t=>e(e=>({toasts:e.toasts.filter(e=>e.id!==t)})),clearToasts:()=>e({toasts:[]})})),He=()=>Z.setState({toasts:[]}),Ue=({position:t=`top-right`})=>{let n=Z(e=>e.toasts),r=Z(e=>e.removeToast);return(0,e.jsx)(`div`,{className:`${X.viewport} ${X[t]}`,"aria-label":`Уведомления`,children:n.map(t=>(0,e.jsx)(Be,{toast:t,onClose:r},t.id))})},We=()=>{let e=Z(e=>e.showToast),n=Z(e=>e.removeToast),r=Z(e=>e.clearToasts),i=(0,t.useCallback)(t=>e({...t,variant:`info`}),[e]),a=(0,t.useCallback)(t=>e({...t,variant:`success`}),[e]),o=(0,t.useCallback)(t=>e({...t,variant:`warning`}),[e]),s=(0,t.useCallback)(t=>e({...t,variant:`error`}),[e]);return(0,t.useMemo)(()=>({showToast:e,infoToast:i,successToast:a,warningToast:o,errorToast:s,removeToast:n,clearToasts:r}),[r,s,i,n,e,a,o])},Ge={root:`_root_s9o0g_1`,tooltip:`_tooltip_s9o0g_3`,"ds-tooltip-in":`_ds-tooltip-in_s9o0g_1`,top:`_top_s9o0g_5`,bottom:`_bottom_s9o0g_7`,left:`_left_s9o0g_9`,right:`_right_s9o0g_11`},Ke=({content:n,children:r,placement:i=`top`,delay:a=450,disabled:o=!1,maxWidth:s=280,className:c=``})=>{let l=(0,t.useId)(),[u,d]=(0,t.useState)(!1),f=(0,t.useRef)(null),p=()=>{o||!n||(f.current=setTimeout(()=>d(!0),a))},m=()=>{f.current&&clearTimeout(f.current),d(!1)};if((0,t.useEffect)(()=>{let e=e=>{e.key===`Escape`&&m()};return document.addEventListener(`keydown`,e),()=>{document.removeEventListener(`keydown`,e),f.current&&clearTimeout(f.current)}},[]),!(0,t.isValidElement)(r))return r;let h=(0,t.cloneElement)(r,{"aria-describedby":u?l:void 0,onMouseEnter:p,onMouseLeave:m,onFocus:p,onBlur:m});return(0,e.jsxs)(`span`,{className:`${Ge.root} ${c}`,onPointerDown:u?m:p,children:[h,u&&(0,e.jsx)(`span`,{id:l,role:`tooltip`,className:`${Ge.tooltip} ${Ge[i]}`,style:{maxWidth:s},children:n})]})},Q={root:`_root_1ue3g_1`,frame:`_frame_1ue3g_3`,video:`_video_1ue3g_5`,overlay:`_overlay_1ue3g_7`,error:`_error_1ue3g_7`,caption:`_caption_1ue3g_13`},qe=({sources:n,tracks:r=[],title:i,aspectRatio:a=`16 / 9`,objectFit:o=`contain`,loading:s=!1,error:l,fallback:u,className:d=``,controls:f=!0,playsInline:p=!0,...m})=>{let[h,g]=(0,t.useState)(!1),_=l??(h?`Не удалось воспроизвести видео`:void 0);return(0,e.jsxs)(`figure`,{className:`${Q.root} ${d}`,children:[(0,e.jsxs)(`div`,{className:Q.frame,style:{aspectRatio:a},children:[!_&&n.length>0&&(0,e.jsxs)(`video`,{...m,"aria-label":i,controls:f,playsInline:p,className:Q.video,style:{objectFit:o},onError:e=>{g(!0),m.onError?.(e)},children:[n.map(t=>(0,e.jsx)(`source`,{...t},`${t.src}-${t.type}`)),r.map(t=>(0,e.jsx)(`track`,{...t},`${t.src}-${t.srcLang}`))]}),s&&(0,e.jsx)(`div`,{className:Q.overlay,children:(0,e.jsx)(c,{label:`Загрузка видео`})}),(_||n.length===0)&&(0,e.jsx)(`div`,{className:Q.error,role:`alert`,children:u??_??`Источник видео не указан`})]}),(0,e.jsx)(`figcaption`,{className:Q.caption,children:i})]})},$={popup:`_popup_15ovj_1`,trigger:`_trigger_15ovj_15`,content:`_content_15ovj_23`,top:`_top_15ovj_107`,right:`_right_15ovj_141`,bottom:`_bottom_15ovj_175`,left:`_left_15ovj_209`},Je=({content:t,children:n,placement:r=`top`,disabled:i=!1})=>i?(0,e.jsx)(e.Fragment,{children:n}):(0,e.jsxs)(`span`,{className:`${$.popup} ${$[r]}`,children:[(0,e.jsx)(`span`,{className:$.trigger,children:n}),(0,e.jsx)(`span`,{className:$.content,role:`tooltip`,children:t})]});exports.ConfirmModal=Oe,exports.DSBadge=o,exports.DSButton=u,exports.DSCheckbox=h,exports.DSDataTable=ce,exports.DSDateRange=A,exports.DSDateTimePicker=D,exports.DSDropDown=F,exports.DSDropDownMultiple=le,exports.DSFieldLabel=f,exports.DSFieldMessage=p,exports.DSFileInput=ve,exports.DSFilters=he,exports.DSIcon=de,exports.DSInfoBlock=fe,exports.DSInput=pe,exports.DSLoader=c,exports.DSModal=Ce,exports.DSModalFrame=Se,exports.DSPageLoader=Re,exports.DSPopup=Je,exports.DSRadioButton=me,exports.DSSkeleton=M,exports.DSSort=L,exports.DSToast=Be,exports.DSToastProvider=Ue,exports.DSTooltip=Ke,exports.DSVideoPlayerFrame=qe,exports.ErrorModal=ke,exports.ModalSystemProvider=we,exports.builtInModalRegistry=Ae,exports.defineModalRegistry=Te,exports.formatDateTimeLocalValue=x,exports.getErrorMessage=Me,exports.getNextEnabledOptionIndex=P,exports.isValidDateRange=k,exports.parseDateTimeLocalValue=S,exports.resetModalStore=be,exports.resetToastStore=He,exports.useConfirmModal=je,exports.useConfirmModalStore=Pe,exports.useErrorModal=Ne,exports.useErrorModalStore=Fe,exports.useModals=Ie,exports.useModalsStore=q,exports.useToast=We,exports.useToastStore=Z,exports.validateDSDataTableData=te;
|
package/dist/index.d.ts
CHANGED
|
@@ -30,4 +30,5 @@ export * from './components/DSToast/useToast';
|
|
|
30
30
|
export * from './components/DSTooltip/DSTooltip';
|
|
31
31
|
export * from './components/DSVideoPlayerFrame/DSVideoPlayerFrame';
|
|
32
32
|
export * from './components/Field/DSField';
|
|
33
|
+
export * from './components/DSPopup/DSPopup';
|
|
33
34
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,qBAAqB,CAAC;AAE7B,cAAc,8BAA8B,CAAC;AAC7C,cAAc,gCAAgC,CAAC;AAC/C,cAAc,oCAAoC,CAAC;AACnD,cAAc,gDAAgD,CAAC;AAC/D,cAAc,sCAAsC,CAAC;AACrD,cAAc,sCAAsC,CAAC;AACrD,cAAc,oCAAoC,CAAC;AACnD,cAAc,oDAAoD,CAAC;AACnE,cAAc,4BAA4B,CAAC;AAC3C,cAAc,sCAAsC,CAAC;AACrD,cAAc,kCAAkC,CAAC;AACjD,cAAc,sCAAsC,CAAC;AACrD,cAAc,8BAA8B,CAAC;AAC7C,cAAc,gCAAgC,CAAC;AAC/C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,0CAA0C,CAAC;AACzD,cAAc,+BAA+B,CAAC;AAC9C,cAAc,kCAAkC,CAAC;AACjD,cAAc,kCAAkC,CAAC;AACjD,cAAc,gCAAgC,CAAC;AAC/C,cAAc,wCAAwC,CAAC;AACvD,cAAc,0CAA0C,CAAC;AACzD,cAAc,oCAAoC,CAAC;AACnD,cAAc,4BAA4B,CAAC;AAC3C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,sCAAsC,CAAC;AACrD,cAAc,kCAAkC,CAAC;AACjD,cAAc,kCAAkC,CAAC;AACjD,cAAc,+BAA+B,CAAC;AAC9C,cAAc,kCAAkC,CAAC;AACjD,cAAc,oDAAoD,CAAC;AACnE,cAAc,4BAA4B,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,qBAAqB,CAAC;AAE7B,cAAc,8BAA8B,CAAC;AAC7C,cAAc,gCAAgC,CAAC;AAC/C,cAAc,oCAAoC,CAAC;AACnD,cAAc,gDAAgD,CAAC;AAC/D,cAAc,sCAAsC,CAAC;AACrD,cAAc,sCAAsC,CAAC;AACrD,cAAc,oCAAoC,CAAC;AACnD,cAAc,oDAAoD,CAAC;AACnE,cAAc,4BAA4B,CAAC;AAC3C,cAAc,sCAAsC,CAAC;AACrD,cAAc,kCAAkC,CAAC;AACjD,cAAc,sCAAsC,CAAC;AACrD,cAAc,8BAA8B,CAAC;AAC7C,cAAc,gCAAgC,CAAC;AAC/C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,0CAA0C,CAAC;AACzD,cAAc,+BAA+B,CAAC;AAC9C,cAAc,kCAAkC,CAAC;AACjD,cAAc,kCAAkC,CAAC;AACjD,cAAc,gCAAgC,CAAC;AAC/C,cAAc,wCAAwC,CAAC;AACvD,cAAc,0CAA0C,CAAC;AACzD,cAAc,oCAAoC,CAAC;AACnD,cAAc,4BAA4B,CAAC;AAC3C,cAAc,8BAA8B,CAAC;AAC7C,cAAc,sCAAsC,CAAC;AACrD,cAAc,kCAAkC,CAAC;AACjD,cAAc,kCAAkC,CAAC;AACjD,cAAc,+BAA+B,CAAC;AAC9C,cAAc,kCAAkC,CAAC;AACjD,cAAc,oDAAoD,CAAC;AACnE,cAAc,4BAA4B,CAAC;AAC3C,cAAc,8BAA8B,CAAC"}
|
package/dist/index.es.js
CHANGED
|
@@ -1820,6 +1820,24 @@ var w = {
|
|
|
1820
1820
|
children: i
|
|
1821
1821
|
})]
|
|
1822
1822
|
});
|
|
1823
|
-
}
|
|
1823
|
+
}, ot = {
|
|
1824
|
+
popup: "_popup_15ovj_1",
|
|
1825
|
+
trigger: "_trigger_15ovj_15",
|
|
1826
|
+
content: "_content_15ovj_23",
|
|
1827
|
+
top: "_top_15ovj_107",
|
|
1828
|
+
right: "_right_15ovj_141",
|
|
1829
|
+
bottom: "_bottom_15ovj_175",
|
|
1830
|
+
left: "_left_15ovj_209"
|
|
1831
|
+
}, st = ({ content: r, children: i, placement: a = "top", disabled: o = !1 }) => o ? /* @__PURE__ */ t(e, { children: i }) : /* @__PURE__ */ n("span", {
|
|
1832
|
+
className: `${ot.popup} ${ot[a]}`,
|
|
1833
|
+
children: [/* @__PURE__ */ t("span", {
|
|
1834
|
+
className: ot.trigger,
|
|
1835
|
+
children: i
|
|
1836
|
+
}), /* @__PURE__ */ t("span", {
|
|
1837
|
+
className: ot.content,
|
|
1838
|
+
role: "tooltip",
|
|
1839
|
+
children: r
|
|
1840
|
+
})]
|
|
1841
|
+
});
|
|
1824
1842
|
//#endregion
|
|
1825
|
-
export { Be as ConfirmModal, y as DSBadge, C as DSButton, O as DSCheckbox, _e as DSDataTable, B as DSDateRange, ne as DSDateTimePicker, ie as DSDropDown, ve as DSDropDownMultiple, T as DSFieldLabel, E as DSFieldMessage, ke as DSFileInput, Te as DSFilters, be as DSIcon, xe as DSInfoBlock, Se as DSInput, x as DSLoader, Pe as DSModal, Ne as DSModalFrame, Xe as DSPageLoader, Ce as DSRadioButton, H as DSSkeleton, oe as DSSort, Qe as DSToast, tt as DSToastProvider, it as DSTooltip, at as DSVideoPlayerFrame, Ve as ErrorModal, Fe as ModalSystemProvider, He as builtInModalRegistry, Ie as defineModalRegistry, P as formatDateTimeLocalValue, We as getErrorMessage, re as getNextEnabledOptionIndex, z as isValidDateRange, F as parseDateTimeLocalValue, je as resetModalStore, et as resetToastStore, Ue as useConfirmModal, Ke as useConfirmModalStore, Ge as useErrorModal, qe as useErrorModalStore, Je as useModals, Y as useModalsStore, nt as useToast, Q as useToastStore, ce as validateDSDataTableData };
|
|
1843
|
+
export { Be as ConfirmModal, y as DSBadge, C as DSButton, O as DSCheckbox, _e as DSDataTable, B as DSDateRange, ne as DSDateTimePicker, ie as DSDropDown, ve as DSDropDownMultiple, T as DSFieldLabel, E as DSFieldMessage, ke as DSFileInput, Te as DSFilters, be as DSIcon, xe as DSInfoBlock, Se as DSInput, x as DSLoader, Pe as DSModal, Ne as DSModalFrame, Xe as DSPageLoader, st as DSPopup, Ce as DSRadioButton, H as DSSkeleton, oe as DSSort, Qe as DSToast, tt as DSToastProvider, it as DSTooltip, at as DSVideoPlayerFrame, Ve as ErrorModal, Fe as ModalSystemProvider, He as builtInModalRegistry, Ie as defineModalRegistry, P as formatDateTimeLocalValue, We as getErrorMessage, re as getNextEnabledOptionIndex, z as isValidDateRange, F as parseDateTimeLocalValue, je as resetModalStore, et as resetToastStore, Ue as useConfirmModal, Ke as useConfirmModalStore, Ge as useErrorModal, qe as useErrorModalStore, Je as useModals, Y as useModalsStore, nt as useToast, Q as useToastStore, ce as validateDSDataTableData };
|
package/dist/style.css
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
:root{--color-primary:#179cf0;--color-secondary:var(--color-text);--color-text-light:var(--color-surface);--color-text-dark:var(--color-primary);--color-text:#22252b;--color-inactive:#9ca3af;--color-success:#179c66;--color-warning:#f59e0b;--color-error:#dc2626;--color-background-disabled:#dbcff1;--color-surface:#fff;--color-border:#d9dee7;--color-text-secondary:#6b7280;--color-focus-ring:color-mix(in srgb, var(--color-primary) 18%, transparent);--color-neutral-surface:#f1f3f6;--color-neutral-text:#4b5563;--color-info-surface:#179cf01f;--color-info-text:#0878bd;--color-success-surface:#179c661f;--color-success-text:#11784f;--color-warning-surface:#fff4d6;--color-warning-text:#8a5800;--color-error-surface:#feecec;--color-error-text:#b91c1c;--color-skeleton-base:#e9edf3;--color-skeleton-highlight:#f5f7fa;--shadow-floating:0 8px 24px #0000002e;--z-dropdown:1000;--z-tooltip:1100;--z-modal:1200;--z-toast:1300;--ds-dropdown-menu-max-height:240px;--gap-s:8px;--gap-m:16px;--gap-l:20px;--text-size-s:14px;--text-size-m:16px;--text-size-l:32px;--border-radius:10px;--height-s:30px;--height-m:44px;--height-l:70px}._badge_1pk53_1{border-radius:999px;align-items:center;gap:6px;max-width:100%;font-size:12px;font-weight:600;line-height:1;display:inline-flex}._sm_1pk53_3{min-height:20px;padding:0 7px}._md_1pk53_5{min-height:24px;padding:0 9px}._neutral_1pk53_7{background:var(--color-neutral-surface);color:var(--color-neutral-text)}._info_1pk53_9{background:var(--color-info-surface);color:var(--color-info-text)}._success_1pk53_11{background:var(--color-success-surface);color:var(--color-success-text)}._warning_1pk53_13{background:var(--color-warning-surface);color:var(--color-warning-text)}._error_1pk53_15{background:var(--color-error-surface);color:var(--color-error-text)}._dot_1pk53_17{background:currentColor;border-radius:50%;width:6px;height:6px}._icon_1pk53_19{display:inline-flex}._label_1pk53_21{text-overflow:ellipsis;white-space:nowrap;min-width:0;overflow:hidden}._loader_1tjcf_1{border:2px solid;border-right-color:#0000;border-radius:50%;width:20px;height:20px;animation:.7s linear infinite _ds-spin_1tjcf_1;display:inline-block}._primary_1tjcf_21{color:var(--color-primary)}._secondary_1tjcf_23{color:var(--color-text)}._light_1tjcf_25{color:var(--color-surface)}._danger_1tjcf_27{color:var(--color-error)}@keyframes _ds-spin_1tjcf_1{to{transform:rotate(360deg)}}@media (prefers-reduced-motion:reduce){._loader_1tjcf_1{animation-duration:1.5s}}._button_1jisp_1{justify-content:center;align-items:center;gap:var(--gap-s);border-radius:var(--border-radius);font:inherit;cursor:pointer;border:1px solid #0000;font-weight:600;transition:background .15s,box-shadow .15s,color .15s;display:inline-flex}._button_1jisp_1:focus-visible{box-shadow:0 0 0 4px var(--color-focus-ring);outline:none}._button_1jisp_1:disabled{opacity:.55;cursor:not-allowed}._sm_1jisp_31{min-height:var(--height-s);padding:4px 10px;font-size:12px}._md_1jisp_33{min-height:var(--height-m);font-size:var(--text-size-s);padding:8px 16px}._lg_1jisp_35{min-height:52px;font-size:var(--text-size-m);padding:12px 20px}._primary_1jisp_37{background:var(--color-primary);color:var(--color-text-light,var(--color-surface))}._secondary_1jisp_39{background:var(--color-secondary,var(--color-text));color:var(--color-text-dark,var(--color-primary))}._outline_1jisp_41{border-color:var(--color-primary);color:var(--color-primary);background:0 0}._ghost_1jisp_45{border-color:color-mix(in srgb, var(--color-primary) 20%, transparent);background:color-mix(in srgb, var(--color-primary) 20%, transparent);color:var(--color-primary)}._empty_1jisp_57{color:var(--color-primary);background:0 0;border-color:#0000}._destructive_1jisp_67{background:var(--color-error);color:var(--color-surface)}._destructiveOutline_1jisp_69{border-color:var(--color-error);color:var(--color-error);background:0 0}._button_1jisp_1:hover:not(:disabled){filter:brightness(.96)}._ghost_1jisp_45:hover:not(:disabled){background:color-mix(in srgb, var(--color-primary) 25%, transparent);filter:none}._ghost_1jisp_45:active:not(:disabled){background:color-mix(in srgb, var(--color-primary) 30%, transparent);filter:none}._empty_1jisp_57:hover:not(:disabled){background:color-mix(in srgb, var(--color-primary) 10%, transparent);filter:none}._empty_1jisp_57:active:not(:disabled){background:color-mix(in srgb, var(--color-primary) 16%, transparent);filter:none}._label_1lsqq_1{width:fit-content;color:var(--color-text);font-size:var(--text-size-s);align-items:baseline;gap:4px;font-weight:600;line-height:1.4;display:inline-flex}._required_1lsqq_23,._error_1lsqq_25{color:var(--color-error)}._optional_1lsqq_33,._hint_1lsqq_35{color:var(--color-text-secondary);font-size:12px;font-weight:400}._disabled_1lsqq_47{color:var(--color-inactive)}._message_1lsqq_55{align-items:flex-start;gap:6px;font-size:12px;line-height:1.4;display:flex}._success_1lsqq_71{color:var(--color-success)}._wrapper_1gq36_1{gap:var(--gap-s);flex-direction:column;display:flex}._label_1gq36_3{width:fit-content;color:var(--color-text);font-size:var(--text-size-s);cursor:pointer;align-items:center;gap:10px;font-weight:600;display:inline-flex}._input_1gq36_5{opacity:0;width:1px;height:1px;position:absolute}._control_1gq36_7{border:1px solid var(--color-primary);background:var(--color-surface);width:20px;height:20px;color:var(--color-surface);border-radius:6px;flex:none;place-items:center;display:grid}._input_1gq36_5:checked+._control_1gq36_7,._input_1gq36_5:indeterminate+._control_1gq36_7{background:var(--color-primary)}._input_1gq36_5:focus-visible+._control_1gq36_7{box-shadow:0 0 0 4px var(--color-focus-ring)}._disabled_1gq36_13{color:var(--color-inactive);cursor:not-allowed}._disabled_1gq36_13 ._control_1gq36_7{opacity:.55}._controlError_1gq36_17{border-color:var(--color-error)}._wrapper_1528c_1{gap:var(--gap-s);flex-direction:column;width:100%;display:flex;position:relative}._trigger_1528c_17{width:100%;min-height:var(--height-m);border:1px solid var(--color-primary);border-radius:var(--border-radius);background:var(--color-surface);color:var(--color-text);font:inherit;text-align:left;cursor:pointer;justify-content:space-between;align-items:center;gap:12px;padding:10px 14px;display:flex}._trigger_1528c_17:focus-visible,._nav_1528c_53:focus-visible,._day_1528c_55:focus-visible,._monthSelect_1528c_57:focus-visible,._yearInput_1528c_59:focus-visible,._timeInput_1528c_61:focus-visible{box-shadow:0 0 0 4px var(--color-focus-ring);outline:none}._trigger_1528c_17:disabled{border-color:var(--color-background-disabled);color:var(--color-inactive);cursor:not-allowed;background:#e9e9e9}._value_1528c_85{color:var(--color-text)}._placeholder_1528c_93{color:var(--color-text-secondary)}._error_1528c_101{border-color:var(--color-error)}._panel_1528c_109{z-index:var(--z-dropdown);width:min(360px,100vw - 32px);padding:var(--gap-m);border:1px solid var(--color-border);border-radius:var(--border-radius);background:var(--color-surface);box-shadow:var(--shadow-floating);position:absolute;top:calc(100% + 6px);left:0}._calendarHeader_1528c_135{grid-template-columns:36px minmax(110px,1fr) 84px 36px;align-items:center;gap:6px;margin-bottom:12px;display:grid}._nav_1528c_53,._day_1528c_55{color:var(--color-text);font:inherit;cursor:pointer;background:0 0;border:0;border-radius:8px}._nav_1528c_53{min-height:36px;font-size:22px}._nav_1528c_53:hover,._day_1528c_55:hover:not(:disabled){background:color-mix(in srgb, var(--color-primary) 10%, transparent)}._monthSelect_1528c_57,._yearInput_1528c_59,._timeInput_1528c_61{border:1px solid var(--color-border);background:var(--color-surface);min-width:0;min-height:36px;color:var(--color-text);font:inherit;border-radius:8px}._monthSelect_1528c_57,._yearInput_1528c_59{padding:6px 8px}._weekdays_1528c_225,._days_1528c_227{grid-template-columns:repeat(7,1fr);gap:4px;display:grid}._weekdays_1528c_225{color:var(--color-text-secondary);text-align:center;margin-bottom:4px;font-size:12px}._day_1528c_55{aspect-ratio:1;min-width:32px}._outside_1528c_263{color:var(--color-inactive)}._selected_1528c_271{background:var(--color-primary);color:var(--color-text-light,var(--color-surface))}._day_1528c_55:disabled{opacity:.35;cursor:not-allowed}._timeLabel_1528c_291{gap:var(--gap-s);margin-top:var(--gap-m);color:var(--color-text);font-size:var(--text-size-s);font-weight:600;display:grid}._timeInput_1528c_61{padding:8px 12px}@media (width<400px){._panel_1528c_109{padding:12px;left:auto;right:0}._calendarHeader_1528c_135{grid-template-columns:32px minmax(96px,1fr) 76px 32px}}._root_1q42e_1{gap:var(--gap-s);border:0;flex-direction:column;width:100%;margin:0;padding:0;display:flex}._legend_1q42e_3{margin-bottom:var(--gap-s);color:var(--color-text);font-size:var(--text-size-s);font-weight:600}._range_1q42e_5{gap:var(--gap-m);grid-template-columns:repeat(2,minmax(0,1fr));display:grid}@media (width<640px){._range_1q42e_5{grid-template-columns:1fr}}._group_1fs9e_1{gap:var(--gap-s);flex-direction:column;width:100%;display:flex}._skeleton_1fs9e_3{background:var(--color-skeleton-base);display:block;overflow:hidden}._text_1fs9e_5{border-radius:4px;height:14px}._rectangular_1fs9e_7{border-radius:var(--border-radius);min-height:44px}._circular_1fs9e_9{border-radius:50%;width:40px;height:40px}._animated_1fs9e_11{background-image:linear-gradient(90deg, var(--color-skeleton-base), var(--color-skeleton-highlight), var(--color-skeleton-base));background-size:200% 100%;animation:1.4s linear infinite _ds-skeleton_1fs9e_1}@keyframes _ds-skeleton_1fs9e_1{to{background-position-x:-200%}}@media (prefers-reduced-motion:reduce){._animated_1fs9e_11{background-image:none;animation:none}}._wrapper_dkn63_1{gap:var(--gap-s);width:100%;color:var(--color-text);flex-direction:column;display:flex}._label_dkn63_17{font-size:var(--text-size-s);font-weight:600;line-height:1.4}._container_dkn63_29{position:relative}._trigger_dkn63_37,._disabledText_dkn63_39{width:100%;min-height:var(--height-m);border:1px solid var(--color-primary);border-radius:var(--border-radius);background:var(--color-surface);color:var(--color-text);font:inherit;padding:10px 14px}._trigger_dkn63_37{cursor:pointer;justify-content:space-between;align-items:center;gap:12px;display:flex}._trigger_dkn63_37:hover:not(:disabled){box-shadow:0 0 0 3px #179cf01f}._trigger_dkn63_37:focus-visible{box-shadow:0 0 0 4px var(--color-focus-ring);outline:none}._trigger_dkn63_37:disabled,._disabledText_dkn63_39{border-color:var(--color-background-disabled);cursor:not-allowed;background:#e9e9e9}._value_dkn63_109,._placeholder_dkn63_111{text-overflow:ellipsis;white-space:nowrap;min-width:0;font-size:var(--text-size-s);text-align:left;overflow:hidden}._placeholder_dkn63_111{color:var(--color-text-secondary)}._chevron_dkn63_137{color:#22252b;flex-shrink:0;width:20px;height:20px;transition:transform .2s}._chevron_dkn63_137 svg{width:100%;height:100%}._chevronOpen_dkn63_163{transform:rotate(180deg)}._menu_dkn63_171{z-index:20;width:100%;max-height:var(--ds-dropdown-menu-max-height);overscroll-behavior:contain;border:1px solid var(--color-border);border-radius:var(--border-radius);background:var(--color-surface);margin:0;padding:0;list-style:none;position:absolute;top:calc(100% + 6px);left:0;overflow-y:auto;box-shadow:0 8px 24px #0000002e}._option_dkn63_207{width:100%;min-height:40px;color:var(--color-text);font:inherit;text-align:left;cursor:pointer;background:0 0;border:0;border-radius:8px;justify-content:space-between;align-items:center;gap:12px;padding:10px 12px;display:flex}._option_dkn63_207:hover:not(:disabled),._option_dkn63_207:focus-visible,._selected_dkn63_245{background:#179cf01f;outline:none}._option_dkn63_207:disabled{opacity:.5;cursor:not-allowed}._message_dkn63_265,._error_dkn63_267{font-size:12px;line-height:1.4}._message_dkn63_265{color:var(--color-text-secondary)}._error_dkn63_267{color:var(--color-error)}._errorState_dkn63_293 ._trigger_dkn63_37{border-color:var(--color-error)}._root_1h9ti_1{gap:var(--gap-m);width:100%;color:var(--color-text);display:grid}._tableWrap_1h9ti_3{border:1px solid var(--color-border);border-radius:var(--border-radius);overflow:auto}._table_1h9ti_3{border-collapse:collapse;background:var(--color-surface);width:100%}._table_1h9ti_3 caption{padding:var(--gap-s);text-align:left;font-weight:600}._table_1h9ti_3 th,._table_1h9ti_3 td{min-height:var(--height-m);padding:12px var(--gap-m);border-bottom:1px solid var(--color-border);text-align:left}._table_1h9ti_3 tbody tr:last-child td{border-bottom:0}._table_1h9ti_3 tbody tr:hover{background:var(--color-info-surface)}._sticky_1h9ti_15{z-index:1;background:var(--color-surface);position:sticky;top:0}._sortButton_1h9ti_17{align-items:center;gap:var(--gap-s);width:100%;color:inherit;font:inherit;cursor:pointer;background:0 0;border:0;padding:0;font-weight:600;display:inline-flex}._sortButton_1h9ti_17:focus-visible{outline:2px solid var(--color-primary);outline-offset:3px}._state_1h9ti_21{padding:var(--gap-l);color:var(--color-text-secondary);text-align:center}._cards_1h9ti_23,._mobileSort_1h9ti_23{display:none}._card_1h9ti_23{padding:var(--gap-m);border:1px solid var(--color-border);border-radius:var(--border-radius);background:var(--color-surface);gap:12px;display:grid}._card_1h9ti_23 h3{font-size:var(--text-size-m);margin:0}._card_1h9ti_23 dl{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin:0;display:grid}._card_1h9ti_23 dt{color:var(--color-text-secondary);text-transform:uppercase;font-size:12px}._card_1h9ti_23 dd{overflow-wrap:anywhere;font-size:var(--text-size-s);margin:4px 0 0}._card_1h9ti_23 footer{border-top:1px solid var(--color-border);justify-content:flex-end;padding-top:12px;display:flex}._spanTwo_1h9ti_37{grid-column:span 2}@media (width<640px){._default_1h9ti_41:not(._tableOnMobile_1h9ti_41) ._tableWrap_1h9ti_3{display:none}._default_1h9ti_41:not(._tableOnMobile_1h9ti_41) ._cards_1h9ti_23{gap:12px;display:grid}._default_1h9ti_41:not(._tableOnMobile_1h9ti_41) ._mobileSort_1h9ti_23{display:block}}@media (width<1280px){._wide_1h9ti_45:not(._tableOnMobile_1h9ti_41) ._tableWrap_1h9ti_3{display:none}._wide_1h9ti_45:not(._tableOnMobile_1h9ti_41) ._cards_1h9ti_23{gap:12px;display:grid}._wide_1h9ti_45:not(._tableOnMobile_1h9ti_41) ._mobileSort_1h9ti_23{display:block}}._root_1y2s8_1{border:1px solid var(--color-border);border-radius:var(--border-radius);background:var(--color-surface);width:100%;color:var(--color-text);overflow-wrap:anywhere;overflow:hidden}._header_1y2s8_21{justify-content:space-between;align-items:center;gap:var(--gap-m);min-height:52px;padding:12px var(--gap-m);border-bottom:1px solid var(--color-border);display:flex}._title_1y2s8_41{font-size:var(--text-size-m);margin:0;font-weight:600;line-height:1.4}._dismiss_1y2s8_55{width:32px;height:32px;color:var(--color-text-secondary);cursor:pointer;background:0 0;border:0;border-radius:8px;flex:none;place-items:center;padding:0;display:grid}._dismiss_1y2s8_55:hover{color:var(--color-text);background:#22252b12}._dismiss_1y2s8_55:focus-visible{box-shadow:0 0 0 4px var(--color-focus-ring);outline:none}._dismiss_1y2s8_55 svg{width:20px;height:20px}._content_1y2s8_113{padding:var(--gap-m);font-size:var(--text-size-s);line-height:1.5}._wrapper_ip6vf_1{gap:var(--gap-s);flex-direction:column;width:100%;display:flex}._control_ip6vf_3{display:flex;position:relative}._input_ip6vf_5,._disabledText_ip6vf_5{width:100%;min-height:var(--height-m);max-height:var(--height-m);height:var(--height-m);border:1px solid var(--color-primary);border-radius:var(--border-radius);background:var(--color-surface);color:var(--color-text);padding:10px 14px}._input_ip6vf_5:focus-visible{border-color:var(--color-primary);box-shadow:0 0 0 4px var(--color-focus-ring);outline:none}._input_ip6vf_5:disabled,._disabledText_ip6vf_5{border:1px solid var(--color-border);color:var(--color-inactive);background:#e9e9e9}._inputError_ip6vf_39{border-color:var(--color-error)}._input_ip6vf_5:has(+._trailingAction_ip6vf_41){padding-right:52px}._trailingAction_ip6vf_41{width:44px;height:44px;color:var(--color-text-secondary);cursor:pointer;background:0 0;border:0;border-radius:8px;place-items:center;padding:0;font-size:20px;display:grid;position:absolute;top:50%;right:0;transform:translateY(-50%)}._trailingAction_ip6vf_41:hover:not(:disabled){color:var(--color-primary);background:color-mix(in srgb, var(--color-primary) 10%, transparent)}._trailingAction_ip6vf_41:disabled{cursor:not-allowed;opacity:.55}._trailingAction_ip6vf_41:focus-visible{box-shadow:0 0 0 4px var(--color-focus-ring);outline:none}._trailingAction_ip6vf_41 svg{fill:none;stroke:currentColor;stroke-width:1.8px;stroke-linecap:round;stroke-linejoin:round;width:20px;height:20px}._wrapper_vu1ob_1{width:fit-content;color:var(--color-text);cursor:pointer;-webkit-user-select:none;user-select:none;align-items:center;gap:10px;display:inline-flex}._input_vu1ob_21{opacity:0;width:1px;height:1px;position:absolute}._switch_vu1ob_35{border:1px solid var(--color-inactive);background:var(--color-inactive);border-radius:999px;flex:none;align-items:center;width:42px;height:24px;padding:2px;transition:background .2s,border-color .2s,box-shadow .2s;display:flex}._thumb_vu1ob_67{background:var(--color-surface);border-radius:50%;width:18px;height:18px;transition:transform .2s;box-shadow:0 1px 3px #00000040}._input_vu1ob_21:checked+._switch_vu1ob_35{border-color:var(--color-primary);background:var(--color-primary)}._input_vu1ob_21:checked+._switch_vu1ob_35 ._thumb_vu1ob_67{transform:translate(18px)}._input_vu1ob_21:focus-visible+._switch_vu1ob_35{box-shadow:0 0 0 4px var(--color-focus-ring)}._label_vu1ob_111{font-size:var(--text-size-s);font-weight:600;line-height:1.4}._disabled_vu1ob_123{color:var(--color-inactive);cursor:not-allowed}._disabled_vu1ob_123 ._switch_vu1ob_35{opacity:.55}._root_kepgo_1{gap:var(--gap-m);width:100%;display:grid}._grid_kepgo_3{gap:var(--gap-m);grid-template-columns:repeat(auto-fit,minmax(220px,1fr));align-items:center;display:grid}._actions_kepgo_5{justify-content:flex-end;gap:var(--gap-s);display:flex}@media (width<640px){._grid_kepgo_3{grid-template-columns:1fr}._actions_kepgo_5>*{flex:1}}._wrapper_1ymdr_1{gap:var(--gap-s);flex-direction:column;width:100%;display:flex}._dropzone_1ymdr_3{justify-content:center;align-items:center;gap:var(--gap-m);min-height:156px;padding:var(--gap-l);border:1px dashed var(--color-border);border-radius:var(--border-radius);background:var(--color-surface);color:var(--color-text-secondary);flex-direction:column;transition:border-color .15s,background .15s,box-shadow .15s;display:flex}._dragActive_1ymdr_5{border-color:var(--color-primary);background:var(--color-info-surface);box-shadow:0 0 0 4px var(--color-focus-ring);color:var(--color-primary)}._disabled_1ymdr_7{background:var(--color-neutral-surface);opacity:.6}._error_1ymdr_9{border-color:var(--color-error)}._nativeInput_1ymdr_11{clip-path:inset(50%);white-space:nowrap;width:1px;height:1px;position:absolute;overflow:hidden}._empty_1ymdr_13{align-items:center;gap:var(--gap-s);text-align:center;flex-direction:column;display:flex}._uploadIcon_1ymdr_15{background:var(--color-info-surface);width:40px;height:40px;color:var(--color-primary);border-radius:50%;place-items:center;font-size:24px;display:grid}._browseButton_1ymdr_17{color:var(--color-text)}._files_1ymdr_19{gap:var(--gap-s);flex-direction:column;width:100%;margin:0;padding:0;list-style:none;display:flex}._file_1ymdr_19{align-items:center;gap:var(--gap-s);padding:var(--gap-s);border-radius:var(--border-radius);background:var(--color-neutral-surface);color:var(--color-text);grid-template-columns:minmax(0,1fr) auto auto;display:grid}._fileName_1ymdr_23{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}._fileSize_1ymdr_25{color:var(--color-text-secondary);font-size:var(--text-size-s);white-space:nowrap}@media (width<640px){._dropzone_1ymdr_3{min-height:148px;padding:var(--gap-m)}}._layer_1nb2z_1{z-index:var(--z-modal);pointer-events:none;position:fixed;inset:0}._backdrop_1nb2z_3{padding:var(--gap-m);pointer-events:auto;background:#0000007a;place-items:center;display:grid;position:absolute;inset:0}._panel_1nb2z_5{border-radius:var(--border-radius);background:var(--color-surface);width:min(560px,100%);max-height:calc(100vh - 32px);color:var(--color-text);box-shadow:var(--shadow-floating);overflow-y:auto}._panel_1nb2z_5:focus{outline:none}._header_1nb2z_9{justify-content:space-between;align-items:center;gap:var(--gap-m);padding:var(--gap-m);border-bottom:1px solid var(--color-border);display:flex}._title_1nb2z_11{margin:0;font-size:20px;line-height:1.3}._description_1nb2z_13{padding:var(--gap-m) var(--gap-m) 0;color:var(--color-text-secondary);font-size:var(--text-size-s);margin:0}._content_1nb2z_15{padding:var(--gap-m)}._message_1vtru_1{color:var(--color-text);margin:0;line-height:1.5}._actions_1vtru_3{justify-content:flex-end;gap:var(--gap-s);margin-top:var(--gap-l);display:flex}@media (width<480px){._actions_1vtru_3{flex-direction:column-reverse}}._root_1x7h7_1{justify-content:center;align-items:center;gap:var(--gap-s);min-height:160px;color:var(--color-text-secondary);font-size:var(--text-size-s);display:flex}._viewport_15mi5_1{z-index:var(--z-toast);gap:var(--gap-s);pointer-events:none;flex-direction:column;width:min(380px,100vw - 32px);display:flex;position:fixed}._top-right_15mi5_3{top:16px;right:16px}._top-left_15mi5_5{top:16px;left:16px}._bottom-right_15mi5_7{bottom:16px;right:16px}._bottom-left_15mi5_9{bottom:16px;left:16px}._toast_15mi5_11{border:1px solid var(--color-border);border-radius:var(--border-radius);background:var(--color-surface);color:var(--color-text);box-shadow:var(--shadow-floating);pointer-events:auto;border-left-width:4px;align-items:flex-start;gap:10px;padding:12px;display:flex}._body_15mi5_13{min-width:0;font-size:var(--text-size-s);flex-direction:column;flex:1;gap:6px;line-height:1.4;display:flex}._icon_15mi5_15{flex:none;width:20px;height:20px}._info_15mi5_17{border-left-color:var(--color-primary)}._success_15mi5_19{border-left-color:var(--color-success)}._warning_15mi5_21{border-left-color:var(--color-warning)}._error_15mi5_23{border-left-color:var(--color-error)}._root_s9o0g_1{display:inline-flex;position:relative}._tooltip_s9o0g_3{z-index:var(--z-tooltip);background:var(--color-text);width:max-content;max-width:calc(100vw - 32px);color:var(--color-surface);pointer-events:none;border-radius:8px;padding:8px 10px;font-size:12px;line-height:1.4;animation:.12s ease-out _ds-tooltip-in_s9o0g_1;position:absolute;box-shadow:0 6px 18px #0000002e}._top_s9o0g_5{bottom:calc(100% + 8px);left:50%;transform:translate(-50%)}._bottom_s9o0g_7{top:calc(100% + 8px);left:50%;transform:translate(-50%)}._left_s9o0g_9{top:50%;right:calc(100% + 8px);transform:translateY(-50%)}._right_s9o0g_11{top:50%;left:calc(100% + 8px);transform:translateY(-50%)}@keyframes _ds-tooltip-in_s9o0g_1{0%{opacity:0}}@media (prefers-reduced-motion:reduce){._tooltip_s9o0g_3{animation:none}}._root_1ue3g_1{gap:var(--gap-s);width:100%;margin:0;display:grid}._frame_1ue3g_3{border-radius:var(--border-radius);background:#000;width:100%;position:relative;overflow:hidden}._video_1ue3g_5{width:100%;height:100%;display:block}._overlay_1ue3g_7,._error_1ue3g_7{padding:var(--gap-m);text-align:center;place-items:center;display:grid;position:absolute;inset:0}._overlay_1ue3g_7{color:#fff;background:#00000073}._error_1ue3g_7{background:var(--color-error-surface);color:var(--color-error-text)}._caption_1ue3g_13{color:var(--color-text);font-size:var(--text-size-s);font-weight:600}._frame_1ue3g_3:fullscreen{border-radius:0}
|
|
1
|
+
:root{--color-primary:#179cf0;--color-secondary:var(--color-text);--color-text-light:var(--color-surface);--color-text-dark:var(--color-primary);--color-text:#22252b;--color-inactive:#9ca3af;--color-success:#179c66;--color-warning:#f59e0b;--color-error:#dc2626;--color-background-disabled:#dbcff1;--color-surface:#fff;--color-border:#d9dee7;--color-text-secondary:#6b7280;--color-focus-ring:color-mix(in srgb, var(--color-primary) 18%, transparent);--color-neutral-surface:#f1f3f6;--color-neutral-text:#4b5563;--color-info-surface:#179cf01f;--color-info-text:#0878bd;--color-success-surface:#179c661f;--color-success-text:#11784f;--color-warning-surface:#fff4d6;--color-warning-text:#8a5800;--color-error-surface:#feecec;--color-error-text:#b91c1c;--color-skeleton-base:#e9edf3;--color-skeleton-highlight:#f5f7fa;--shadow-floating:0 8px 24px #0000002e;--z-dropdown:1000;--z-tooltip:1100;--z-modal:1200;--z-toast:1300;--ds-dropdown-menu-max-height:240px;--gap-s:8px;--gap-m:16px;--gap-l:20px;--text-size-s:14px;--text-size-m:16px;--text-size-l:32px;--border-radius:10px;--height-s:30px;--height-m:44px;--height-l:70px}._badge_1pk53_1{border-radius:999px;align-items:center;gap:6px;max-width:100%;font-size:12px;font-weight:600;line-height:1;display:inline-flex}._sm_1pk53_3{min-height:20px;padding:0 7px}._md_1pk53_5{min-height:24px;padding:0 9px}._neutral_1pk53_7{background:var(--color-neutral-surface);color:var(--color-neutral-text)}._info_1pk53_9{background:var(--color-info-surface);color:var(--color-info-text)}._success_1pk53_11{background:var(--color-success-surface);color:var(--color-success-text)}._warning_1pk53_13{background:var(--color-warning-surface);color:var(--color-warning-text)}._error_1pk53_15{background:var(--color-error-surface);color:var(--color-error-text)}._dot_1pk53_17{background:currentColor;border-radius:50%;width:6px;height:6px}._icon_1pk53_19{display:inline-flex}._label_1pk53_21{text-overflow:ellipsis;white-space:nowrap;min-width:0;overflow:hidden}._loader_1tjcf_1{border:2px solid;border-right-color:#0000;border-radius:50%;width:20px;height:20px;animation:.7s linear infinite _ds-spin_1tjcf_1;display:inline-block}._primary_1tjcf_21{color:var(--color-primary)}._secondary_1tjcf_23{color:var(--color-text)}._light_1tjcf_25{color:var(--color-surface)}._danger_1tjcf_27{color:var(--color-error)}@keyframes _ds-spin_1tjcf_1{to{transform:rotate(360deg)}}@media (prefers-reduced-motion:reduce){._loader_1tjcf_1{animation-duration:1.5s}}._button_1jisp_1{justify-content:center;align-items:center;gap:var(--gap-s);border-radius:var(--border-radius);font:inherit;cursor:pointer;border:1px solid #0000;font-weight:600;transition:background .15s,box-shadow .15s,color .15s;display:inline-flex}._button_1jisp_1:focus-visible{box-shadow:0 0 0 4px var(--color-focus-ring);outline:none}._button_1jisp_1:disabled{opacity:.55;cursor:not-allowed}._sm_1jisp_31{min-height:var(--height-s);padding:4px 10px;font-size:12px}._md_1jisp_33{min-height:var(--height-m);font-size:var(--text-size-s);padding:8px 16px}._lg_1jisp_35{min-height:52px;font-size:var(--text-size-m);padding:12px 20px}._primary_1jisp_37{background:var(--color-primary);color:var(--color-text-light,var(--color-surface))}._secondary_1jisp_39{background:var(--color-secondary,var(--color-text));color:var(--color-text-dark,var(--color-primary))}._outline_1jisp_41{border-color:var(--color-primary);color:var(--color-primary);background:0 0}._ghost_1jisp_45{border-color:color-mix(in srgb, var(--color-primary) 20%, transparent);background:color-mix(in srgb, var(--color-primary) 20%, transparent);color:var(--color-primary)}._empty_1jisp_57{color:var(--color-primary);background:0 0;border-color:#0000}._destructive_1jisp_67{background:var(--color-error);color:var(--color-surface)}._destructiveOutline_1jisp_69{border-color:var(--color-error);color:var(--color-error);background:0 0}._button_1jisp_1:hover:not(:disabled){filter:brightness(.96)}._ghost_1jisp_45:hover:not(:disabled){background:color-mix(in srgb, var(--color-primary) 25%, transparent);filter:none}._ghost_1jisp_45:active:not(:disabled){background:color-mix(in srgb, var(--color-primary) 30%, transparent);filter:none}._empty_1jisp_57:hover:not(:disabled){background:color-mix(in srgb, var(--color-primary) 10%, transparent);filter:none}._empty_1jisp_57:active:not(:disabled){background:color-mix(in srgb, var(--color-primary) 16%, transparent);filter:none}._label_1lsqq_1{width:fit-content;color:var(--color-text);font-size:var(--text-size-s);align-items:baseline;gap:4px;font-weight:600;line-height:1.4;display:inline-flex}._required_1lsqq_23,._error_1lsqq_25{color:var(--color-error)}._optional_1lsqq_33,._hint_1lsqq_35{color:var(--color-text-secondary);font-size:12px;font-weight:400}._disabled_1lsqq_47{color:var(--color-inactive)}._message_1lsqq_55{align-items:flex-start;gap:6px;font-size:12px;line-height:1.4;display:flex}._success_1lsqq_71{color:var(--color-success)}._wrapper_1gq36_1{gap:var(--gap-s);flex-direction:column;display:flex}._label_1gq36_3{width:fit-content;color:var(--color-text);font-size:var(--text-size-s);cursor:pointer;align-items:center;gap:10px;font-weight:600;display:inline-flex}._input_1gq36_5{opacity:0;width:1px;height:1px;position:absolute}._control_1gq36_7{border:1px solid var(--color-primary);background:var(--color-surface);width:20px;height:20px;color:var(--color-surface);border-radius:6px;flex:none;place-items:center;display:grid}._input_1gq36_5:checked+._control_1gq36_7,._input_1gq36_5:indeterminate+._control_1gq36_7{background:var(--color-primary)}._input_1gq36_5:focus-visible+._control_1gq36_7{box-shadow:0 0 0 4px var(--color-focus-ring)}._disabled_1gq36_13{color:var(--color-inactive);cursor:not-allowed}._disabled_1gq36_13 ._control_1gq36_7{opacity:.55}._controlError_1gq36_17{border-color:var(--color-error)}._wrapper_1528c_1{gap:var(--gap-s);flex-direction:column;width:100%;display:flex;position:relative}._trigger_1528c_17{width:100%;min-height:var(--height-m);border:1px solid var(--color-primary);border-radius:var(--border-radius);background:var(--color-surface);color:var(--color-text);font:inherit;text-align:left;cursor:pointer;justify-content:space-between;align-items:center;gap:12px;padding:10px 14px;display:flex}._trigger_1528c_17:focus-visible,._nav_1528c_53:focus-visible,._day_1528c_55:focus-visible,._monthSelect_1528c_57:focus-visible,._yearInput_1528c_59:focus-visible,._timeInput_1528c_61:focus-visible{box-shadow:0 0 0 4px var(--color-focus-ring);outline:none}._trigger_1528c_17:disabled{border-color:var(--color-background-disabled);color:var(--color-inactive);cursor:not-allowed;background:#e9e9e9}._value_1528c_85{color:var(--color-text)}._placeholder_1528c_93{color:var(--color-text-secondary)}._error_1528c_101{border-color:var(--color-error)}._panel_1528c_109{z-index:var(--z-dropdown);width:min(360px,100vw - 32px);padding:var(--gap-m);border:1px solid var(--color-border);border-radius:var(--border-radius);background:var(--color-surface);box-shadow:var(--shadow-floating);position:absolute;top:calc(100% + 6px);left:0}._calendarHeader_1528c_135{grid-template-columns:36px minmax(110px,1fr) 84px 36px;align-items:center;gap:6px;margin-bottom:12px;display:grid}._nav_1528c_53,._day_1528c_55{color:var(--color-text);font:inherit;cursor:pointer;background:0 0;border:0;border-radius:8px}._nav_1528c_53{min-height:36px;font-size:22px}._nav_1528c_53:hover,._day_1528c_55:hover:not(:disabled){background:color-mix(in srgb, var(--color-primary) 10%, transparent)}._monthSelect_1528c_57,._yearInput_1528c_59,._timeInput_1528c_61{border:1px solid var(--color-border);background:var(--color-surface);min-width:0;min-height:36px;color:var(--color-text);font:inherit;border-radius:8px}._monthSelect_1528c_57,._yearInput_1528c_59{padding:6px 8px}._weekdays_1528c_225,._days_1528c_227{grid-template-columns:repeat(7,1fr);gap:4px;display:grid}._weekdays_1528c_225{color:var(--color-text-secondary);text-align:center;margin-bottom:4px;font-size:12px}._day_1528c_55{aspect-ratio:1;min-width:32px}._outside_1528c_263{color:var(--color-inactive)}._selected_1528c_271{background:var(--color-primary);color:var(--color-text-light,var(--color-surface))}._day_1528c_55:disabled{opacity:.35;cursor:not-allowed}._timeLabel_1528c_291{gap:var(--gap-s);margin-top:var(--gap-m);color:var(--color-text);font-size:var(--text-size-s);font-weight:600;display:grid}._timeInput_1528c_61{padding:8px 12px}@media (width<400px){._panel_1528c_109{padding:12px;left:auto;right:0}._calendarHeader_1528c_135{grid-template-columns:32px minmax(96px,1fr) 76px 32px}}._root_1q42e_1{gap:var(--gap-s);border:0;flex-direction:column;width:100%;margin:0;padding:0;display:flex}._legend_1q42e_3{margin-bottom:var(--gap-s);color:var(--color-text);font-size:var(--text-size-s);font-weight:600}._range_1q42e_5{gap:var(--gap-m);grid-template-columns:repeat(2,minmax(0,1fr));display:grid}@media (width<640px){._range_1q42e_5{grid-template-columns:1fr}}._group_1fs9e_1{gap:var(--gap-s);flex-direction:column;width:100%;display:flex}._skeleton_1fs9e_3{background:var(--color-skeleton-base);display:block;overflow:hidden}._text_1fs9e_5{border-radius:4px;height:14px}._rectangular_1fs9e_7{border-radius:var(--border-radius);min-height:44px}._circular_1fs9e_9{border-radius:50%;width:40px;height:40px}._animated_1fs9e_11{background-image:linear-gradient(90deg, var(--color-skeleton-base), var(--color-skeleton-highlight), var(--color-skeleton-base));background-size:200% 100%;animation:1.4s linear infinite _ds-skeleton_1fs9e_1}@keyframes _ds-skeleton_1fs9e_1{to{background-position-x:-200%}}@media (prefers-reduced-motion:reduce){._animated_1fs9e_11{background-image:none;animation:none}}._wrapper_dkn63_1{gap:var(--gap-s);width:100%;color:var(--color-text);flex-direction:column;display:flex}._label_dkn63_17{font-size:var(--text-size-s);font-weight:600;line-height:1.4}._container_dkn63_29{position:relative}._trigger_dkn63_37,._disabledText_dkn63_39{width:100%;min-height:var(--height-m);border:1px solid var(--color-primary);border-radius:var(--border-radius);background:var(--color-surface);color:var(--color-text);font:inherit;padding:10px 14px}._trigger_dkn63_37{cursor:pointer;justify-content:space-between;align-items:center;gap:12px;display:flex}._trigger_dkn63_37:hover:not(:disabled){box-shadow:0 0 0 3px #179cf01f}._trigger_dkn63_37:focus-visible{box-shadow:0 0 0 4px var(--color-focus-ring);outline:none}._trigger_dkn63_37:disabled,._disabledText_dkn63_39{border-color:var(--color-background-disabled);cursor:not-allowed;background:#e9e9e9}._value_dkn63_109,._placeholder_dkn63_111{text-overflow:ellipsis;white-space:nowrap;min-width:0;font-size:var(--text-size-s);text-align:left;overflow:hidden}._placeholder_dkn63_111{color:var(--color-text-secondary)}._chevron_dkn63_137{color:#22252b;flex-shrink:0;width:20px;height:20px;transition:transform .2s}._chevron_dkn63_137 svg{width:100%;height:100%}._chevronOpen_dkn63_163{transform:rotate(180deg)}._menu_dkn63_171{z-index:20;width:100%;max-height:var(--ds-dropdown-menu-max-height);overscroll-behavior:contain;border:1px solid var(--color-border);border-radius:var(--border-radius);background:var(--color-surface);margin:0;padding:0;list-style:none;position:absolute;top:calc(100% + 6px);left:0;overflow-y:auto;box-shadow:0 8px 24px #0000002e}._option_dkn63_207{width:100%;min-height:40px;color:var(--color-text);font:inherit;text-align:left;cursor:pointer;background:0 0;border:0;border-radius:8px;justify-content:space-between;align-items:center;gap:12px;padding:10px 12px;display:flex}._option_dkn63_207:hover:not(:disabled),._option_dkn63_207:focus-visible,._selected_dkn63_245{background:#179cf01f;outline:none}._option_dkn63_207:disabled{opacity:.5;cursor:not-allowed}._message_dkn63_265,._error_dkn63_267{font-size:12px;line-height:1.4}._message_dkn63_265{color:var(--color-text-secondary)}._error_dkn63_267{color:var(--color-error)}._errorState_dkn63_293 ._trigger_dkn63_37{border-color:var(--color-error)}._root_1h9ti_1{gap:var(--gap-m);width:100%;color:var(--color-text);display:grid}._tableWrap_1h9ti_3{border:1px solid var(--color-border);border-radius:var(--border-radius);overflow:auto}._table_1h9ti_3{border-collapse:collapse;background:var(--color-surface);width:100%}._table_1h9ti_3 caption{padding:var(--gap-s);text-align:left;font-weight:600}._table_1h9ti_3 th,._table_1h9ti_3 td{min-height:var(--height-m);padding:12px var(--gap-m);border-bottom:1px solid var(--color-border);text-align:left}._table_1h9ti_3 tbody tr:last-child td{border-bottom:0}._table_1h9ti_3 tbody tr:hover{background:var(--color-info-surface)}._sticky_1h9ti_15{z-index:1;background:var(--color-surface);position:sticky;top:0}._sortButton_1h9ti_17{align-items:center;gap:var(--gap-s);width:100%;color:inherit;font:inherit;cursor:pointer;background:0 0;border:0;padding:0;font-weight:600;display:inline-flex}._sortButton_1h9ti_17:focus-visible{outline:2px solid var(--color-primary);outline-offset:3px}._state_1h9ti_21{padding:var(--gap-l);color:var(--color-text-secondary);text-align:center}._cards_1h9ti_23,._mobileSort_1h9ti_23{display:none}._card_1h9ti_23{padding:var(--gap-m);border:1px solid var(--color-border);border-radius:var(--border-radius);background:var(--color-surface);gap:12px;display:grid}._card_1h9ti_23 h3{font-size:var(--text-size-m);margin:0}._card_1h9ti_23 dl{grid-template-columns:repeat(2,minmax(0,1fr));gap:12px;margin:0;display:grid}._card_1h9ti_23 dt{color:var(--color-text-secondary);text-transform:uppercase;font-size:12px}._card_1h9ti_23 dd{overflow-wrap:anywhere;font-size:var(--text-size-s);margin:4px 0 0}._card_1h9ti_23 footer{border-top:1px solid var(--color-border);justify-content:flex-end;padding-top:12px;display:flex}._spanTwo_1h9ti_37{grid-column:span 2}@media (width<640px){._default_1h9ti_41:not(._tableOnMobile_1h9ti_41) ._tableWrap_1h9ti_3{display:none}._default_1h9ti_41:not(._tableOnMobile_1h9ti_41) ._cards_1h9ti_23{gap:12px;display:grid}._default_1h9ti_41:not(._tableOnMobile_1h9ti_41) ._mobileSort_1h9ti_23{display:block}}@media (width<1280px){._wide_1h9ti_45:not(._tableOnMobile_1h9ti_41) ._tableWrap_1h9ti_3{display:none}._wide_1h9ti_45:not(._tableOnMobile_1h9ti_41) ._cards_1h9ti_23{gap:12px;display:grid}._wide_1h9ti_45:not(._tableOnMobile_1h9ti_41) ._mobileSort_1h9ti_23{display:block}}._root_1y2s8_1{border:1px solid var(--color-border);border-radius:var(--border-radius);background:var(--color-surface);width:100%;color:var(--color-text);overflow-wrap:anywhere;overflow:hidden}._header_1y2s8_21{justify-content:space-between;align-items:center;gap:var(--gap-m);min-height:52px;padding:12px var(--gap-m);border-bottom:1px solid var(--color-border);display:flex}._title_1y2s8_41{font-size:var(--text-size-m);margin:0;font-weight:600;line-height:1.4}._dismiss_1y2s8_55{width:32px;height:32px;color:var(--color-text-secondary);cursor:pointer;background:0 0;border:0;border-radius:8px;flex:none;place-items:center;padding:0;display:grid}._dismiss_1y2s8_55:hover{color:var(--color-text);background:#22252b12}._dismiss_1y2s8_55:focus-visible{box-shadow:0 0 0 4px var(--color-focus-ring);outline:none}._dismiss_1y2s8_55 svg{width:20px;height:20px}._content_1y2s8_113{padding:var(--gap-m);font-size:var(--text-size-s);line-height:1.5}._wrapper_ip6vf_1{gap:var(--gap-s);flex-direction:column;width:100%;display:flex}._control_ip6vf_3{display:flex;position:relative}._input_ip6vf_5,._disabledText_ip6vf_5{width:100%;min-height:var(--height-m);max-height:var(--height-m);height:var(--height-m);border:1px solid var(--color-primary);border-radius:var(--border-radius);background:var(--color-surface);color:var(--color-text);padding:10px 14px}._input_ip6vf_5:focus-visible{border-color:var(--color-primary);box-shadow:0 0 0 4px var(--color-focus-ring);outline:none}._input_ip6vf_5:disabled,._disabledText_ip6vf_5{border:1px solid var(--color-border);color:var(--color-inactive);background:#e9e9e9}._inputError_ip6vf_39{border-color:var(--color-error)}._input_ip6vf_5:has(+._trailingAction_ip6vf_41){padding-right:52px}._trailingAction_ip6vf_41{width:44px;height:44px;color:var(--color-text-secondary);cursor:pointer;background:0 0;border:0;border-radius:8px;place-items:center;padding:0;font-size:20px;display:grid;position:absolute;top:50%;right:0;transform:translateY(-50%)}._trailingAction_ip6vf_41:hover:not(:disabled){color:var(--color-primary);background:color-mix(in srgb, var(--color-primary) 10%, transparent)}._trailingAction_ip6vf_41:disabled{cursor:not-allowed;opacity:.55}._trailingAction_ip6vf_41:focus-visible{box-shadow:0 0 0 4px var(--color-focus-ring);outline:none}._trailingAction_ip6vf_41 svg{fill:none;stroke:currentColor;stroke-width:1.8px;stroke-linecap:round;stroke-linejoin:round;width:20px;height:20px}._wrapper_vu1ob_1{width:fit-content;color:var(--color-text);cursor:pointer;-webkit-user-select:none;user-select:none;align-items:center;gap:10px;display:inline-flex}._input_vu1ob_21{opacity:0;width:1px;height:1px;position:absolute}._switch_vu1ob_35{border:1px solid var(--color-inactive);background:var(--color-inactive);border-radius:999px;flex:none;align-items:center;width:42px;height:24px;padding:2px;transition:background .2s,border-color .2s,box-shadow .2s;display:flex}._thumb_vu1ob_67{background:var(--color-surface);border-radius:50%;width:18px;height:18px;transition:transform .2s;box-shadow:0 1px 3px #00000040}._input_vu1ob_21:checked+._switch_vu1ob_35{border-color:var(--color-primary);background:var(--color-primary)}._input_vu1ob_21:checked+._switch_vu1ob_35 ._thumb_vu1ob_67{transform:translate(18px)}._input_vu1ob_21:focus-visible+._switch_vu1ob_35{box-shadow:0 0 0 4px var(--color-focus-ring)}._label_vu1ob_111{font-size:var(--text-size-s);font-weight:600;line-height:1.4}._disabled_vu1ob_123{color:var(--color-inactive);cursor:not-allowed}._disabled_vu1ob_123 ._switch_vu1ob_35{opacity:.55}._root_kepgo_1{gap:var(--gap-m);width:100%;display:grid}._grid_kepgo_3{gap:var(--gap-m);grid-template-columns:repeat(auto-fit,minmax(220px,1fr));align-items:center;display:grid}._actions_kepgo_5{justify-content:flex-end;gap:var(--gap-s);display:flex}@media (width<640px){._grid_kepgo_3{grid-template-columns:1fr}._actions_kepgo_5>*{flex:1}}._wrapper_1ymdr_1{gap:var(--gap-s);flex-direction:column;width:100%;display:flex}._dropzone_1ymdr_3{justify-content:center;align-items:center;gap:var(--gap-m);min-height:156px;padding:var(--gap-l);border:1px dashed var(--color-border);border-radius:var(--border-radius);background:var(--color-surface);color:var(--color-text-secondary);flex-direction:column;transition:border-color .15s,background .15s,box-shadow .15s;display:flex}._dragActive_1ymdr_5{border-color:var(--color-primary);background:var(--color-info-surface);box-shadow:0 0 0 4px var(--color-focus-ring);color:var(--color-primary)}._disabled_1ymdr_7{background:var(--color-neutral-surface);opacity:.6}._error_1ymdr_9{border-color:var(--color-error)}._nativeInput_1ymdr_11{clip-path:inset(50%);white-space:nowrap;width:1px;height:1px;position:absolute;overflow:hidden}._empty_1ymdr_13{align-items:center;gap:var(--gap-s);text-align:center;flex-direction:column;display:flex}._uploadIcon_1ymdr_15{background:var(--color-info-surface);width:40px;height:40px;color:var(--color-primary);border-radius:50%;place-items:center;font-size:24px;display:grid}._browseButton_1ymdr_17{color:var(--color-text)}._files_1ymdr_19{gap:var(--gap-s);flex-direction:column;width:100%;margin:0;padding:0;list-style:none;display:flex}._file_1ymdr_19{align-items:center;gap:var(--gap-s);padding:var(--gap-s);border-radius:var(--border-radius);background:var(--color-neutral-surface);color:var(--color-text);grid-template-columns:minmax(0,1fr) auto auto;display:grid}._fileName_1ymdr_23{text-overflow:ellipsis;white-space:nowrap;overflow:hidden}._fileSize_1ymdr_25{color:var(--color-text-secondary);font-size:var(--text-size-s);white-space:nowrap}@media (width<640px){._dropzone_1ymdr_3{min-height:148px;padding:var(--gap-m)}}._layer_1nb2z_1{z-index:var(--z-modal);pointer-events:none;position:fixed;inset:0}._backdrop_1nb2z_3{padding:var(--gap-m);pointer-events:auto;background:#0000007a;place-items:center;display:grid;position:absolute;inset:0}._panel_1nb2z_5{border-radius:var(--border-radius);background:var(--color-surface);width:min(560px,100%);max-height:calc(100vh - 32px);color:var(--color-text);box-shadow:var(--shadow-floating);overflow-y:auto}._panel_1nb2z_5:focus{outline:none}._header_1nb2z_9{justify-content:space-between;align-items:center;gap:var(--gap-m);padding:var(--gap-m);border-bottom:1px solid var(--color-border);display:flex}._title_1nb2z_11{margin:0;font-size:20px;line-height:1.3}._description_1nb2z_13{padding:var(--gap-m) var(--gap-m) 0;color:var(--color-text-secondary);font-size:var(--text-size-s);margin:0}._content_1nb2z_15{padding:var(--gap-m)}._message_1vtru_1{color:var(--color-text);margin:0;line-height:1.5}._actions_1vtru_3{justify-content:flex-end;gap:var(--gap-s);margin-top:var(--gap-l);display:flex}@media (width<480px){._actions_1vtru_3{flex-direction:column-reverse}}._root_1x7h7_1{justify-content:center;align-items:center;gap:var(--gap-s);min-height:160px;color:var(--color-text-secondary);font-size:var(--text-size-s);display:flex}._viewport_15mi5_1{z-index:var(--z-toast);gap:var(--gap-s);pointer-events:none;flex-direction:column;width:min(380px,100vw - 32px);display:flex;position:fixed}._top-right_15mi5_3{top:16px;right:16px}._top-left_15mi5_5{top:16px;left:16px}._bottom-right_15mi5_7{bottom:16px;right:16px}._bottom-left_15mi5_9{bottom:16px;left:16px}._toast_15mi5_11{border:1px solid var(--color-border);border-radius:var(--border-radius);background:var(--color-surface);color:var(--color-text);box-shadow:var(--shadow-floating);pointer-events:auto;border-left-width:4px;align-items:flex-start;gap:10px;padding:12px;display:flex}._body_15mi5_13{min-width:0;font-size:var(--text-size-s);flex-direction:column;flex:1;gap:6px;line-height:1.4;display:flex}._icon_15mi5_15{flex:none;width:20px;height:20px}._info_15mi5_17{border-left-color:var(--color-primary)}._success_15mi5_19{border-left-color:var(--color-success)}._warning_15mi5_21{border-left-color:var(--color-warning)}._error_15mi5_23{border-left-color:var(--color-error)}._root_s9o0g_1{display:inline-flex;position:relative}._tooltip_s9o0g_3{z-index:var(--z-tooltip);background:var(--color-text);width:max-content;max-width:calc(100vw - 32px);color:var(--color-surface);pointer-events:none;border-radius:8px;padding:8px 10px;font-size:12px;line-height:1.4;animation:.12s ease-out _ds-tooltip-in_s9o0g_1;position:absolute;box-shadow:0 6px 18px #0000002e}._top_s9o0g_5{bottom:calc(100% + 8px);left:50%;transform:translate(-50%)}._bottom_s9o0g_7{top:calc(100% + 8px);left:50%;transform:translate(-50%)}._left_s9o0g_9{top:50%;right:calc(100% + 8px);transform:translateY(-50%)}._right_s9o0g_11{top:50%;left:calc(100% + 8px);transform:translateY(-50%)}@keyframes _ds-tooltip-in_s9o0g_1{0%{opacity:0}}@media (prefers-reduced-motion:reduce){._tooltip_s9o0g_3{animation:none}}._root_1ue3g_1{gap:var(--gap-s);width:100%;margin:0;display:grid}._frame_1ue3g_3{border-radius:var(--border-radius);background:#000;width:100%;position:relative;overflow:hidden}._video_1ue3g_5{width:100%;height:100%;display:block}._overlay_1ue3g_7,._error_1ue3g_7{padding:var(--gap-m);text-align:center;place-items:center;display:grid;position:absolute;inset:0}._overlay_1ue3g_7{color:#fff;background:#00000073}._error_1ue3g_7{background:var(--color-error-surface);color:var(--color-error-text)}._caption_1ue3g_13{color:var(--color-text);font-size:var(--text-size-s);font-weight:600}._frame_1ue3g_3:fullscreen{border-radius:0}._popup_15ovj_1{width:fit-content;max-width:100%;display:inline-flex;position:relative}._trigger_15ovj_15{display:inline-flex}._content_15ovj_23{z-index:var(--z-tooltip,1000);border:1px solid var(--color-border);border-radius:var(--border-radius,6px);background:var(--color-text);width:max-content;max-width:min(280px,100vw - 32px);color:var(--color-surface);box-shadow:var(--shadow-floating);text-align:left;pointer-events:none;opacity:0;visibility:hidden;padding:7px 10px;font-weight:500;line-height:1.35;transition:opacity .16s,transform .16s,visibility .16s;position:absolute;transform:translateY(4px)}._content_15ovj_23:after{border-right:1px solid var(--color-border);border-bottom:1px solid var(--color-border);background:var(--color-text);content:"";width:7px;height:7px;position:absolute;transform:rotate(45deg)}._popup_15ovj_1:hover ._content_15ovj_23,._popup_15ovj_1:focus-within ._content_15ovj_23{opacity:1;visibility:visible;transform:translate(0)}._top_15ovj_107 ._content_15ovj_23{bottom:calc(100% + 8px);left:50%;transform:translate(-50%,4px)}._top_15ovj_107 ._content_15ovj_23:after{bottom:-4px;left:50%;transform:translate(-50%)rotate(45deg)}._popup_15ovj_1:hover._top_15ovj_107 ._content_15ovj_23,._popup_15ovj_1:focus-within._top_15ovj_107 ._content_15ovj_23{transform:translate(-50%)}._right_15ovj_141 ._content_15ovj_23{top:50%;left:calc(100% + 8px);transform:translate(4px,-50%)}._right_15ovj_141 ._content_15ovj_23:after{top:50%;left:-4px;transform:translateY(-50%)rotate(135deg)}._popup_15ovj_1:hover._right_15ovj_141 ._content_15ovj_23,._popup_15ovj_1:focus-within._right_15ovj_141 ._content_15ovj_23{transform:translateY(-50%)}._bottom_15ovj_175 ._content_15ovj_23{top:calc(100% + 8px);left:50%;transform:translate(-50%,-4px)}._bottom_15ovj_175 ._content_15ovj_23:after{top:-4px;left:50%;transform:translate(-50%)rotate(225deg)}._popup_15ovj_1:hover._bottom_15ovj_175 ._content_15ovj_23,._popup_15ovj_1:focus-within._bottom_15ovj_175 ._content_15ovj_23{transform:translate(-50%)}._left_15ovj_209 ._content_15ovj_23{top:50%;right:calc(100% + 8px);transform:translate(-4px,-50%)}._left_15ovj_209 ._content_15ovj_23:after{top:50%;right:-4px;transform:translateY(-50%)rotate(-45deg)}._popup_15ovj_1:hover._left_15ovj_209 ._content_15ovj_23,._popup_15ovj_1:focus-within._left_15ovj_209 ._content_15ovj_23{transform:translateY(-50%)}@media (prefers-reduced-motion:reduce){._content_15ovj_23{transition:none}}
|
|
2
2
|
/*$vite$:1*/
|