react-luminus-components 1.1.10 → 1.1.12
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/.vite/manifest.json +62 -61
- package/dist/{DataKey-BSoaCf9L.mjs → DataKey-BaB2j476.js} +1 -1
- package/dist/DataKey-GNKO_90K.cjs +1 -0
- package/dist/{SimplePicker.module--OMl78Ir.mjs → SimplePicker.module-CbnMHmWA.js} +2 -2
- package/dist/{SimplePicker.module-De0azFIA.js → SimplePicker.module-qosp2o8I.cjs} +2 -2
- package/dist/{SimpleTooltip-CnmY5QiG.mjs → SimpleTooltip-BImeVF6b.js} +2 -2
- package/dist/SimpleTooltip-C_Ovh5Fg.cjs +1 -0
- package/dist/components/HookForm/FileInput/HookFormFileInput.d.ts +15 -0
- package/dist/components/HookForm/index.d.ts +1 -0
- package/dist/components/common/YearPicker/YearPicker.d.ts +9 -0
- package/dist/components/common/index.d.ts +1 -0
- package/dist/contexts.cjs.js +1 -1
- package/dist/contexts.es.js +4 -4
- package/dist/{hasClass-DXhjqDzJ.js → hasClass-BlrP77rO.cjs} +1 -1
- package/dist/{hasClass-D4r9EJyq.mjs → hasClass-CLvicWax.js} +1 -1
- package/dist/hooks/useZodSchemaTypes/useZodSchemaTypes.d.ts +10 -0
- package/dist/hooks.cjs.js +1 -1
- package/dist/hooks.es.js +357 -355
- package/dist/layout.cjs.js +1 -1
- package/dist/layout.es.js +2 -2
- package/dist/main.cjs.js +1 -1
- package/dist/main.d.ts +2 -2
- package/dist/main.es.js +801 -767
- package/dist/style.css +1 -1
- package/dist/textUtils-CDK5A52_.js +28 -0
- package/dist/textUtils-FVcup93t.cjs +1 -0
- package/dist/{useConfirm-CGg-p14L.mjs → useConfirm--ASfu4pl.js} +1 -1
- package/dist/useConfirm-CV919Kku.cjs +1 -0
- package/dist/utils/text/textUtils.d.ts +1 -0
- package/dist/utils.cjs.js +1 -1
- package/dist/utils.es.js +33 -32
- package/package.json +3 -1
- package/dist/DataKey-C5l4FOL1.js +0 -1
- package/dist/SimpleTooltip-D42eUFjD.js +0 -1
- package/dist/textUtils-9KFqOvA8.mjs +0 -27
- package/dist/textUtils-C0nqWp3S.js +0 -1
- package/dist/useConfirm-BG0v5BwQ.js +0 -1
- /package/dist/{constants-CT2hnPeO.js → constants-CT2hnPeO.cjs} +0 -0
- /package/dist/{constants-CzNy5yO3.mjs → constants-CzNy5yO3.js} +0 -0
- /package/dist/{useClickOutside-BjJyGTec.mjs → useClickOutside-BjJyGTec.js} +0 -0
- /package/dist/{useClickOutside-DsVG12Cs.js → useClickOutside-DsVG12Cs.cjs} +0 -0
package/dist/style.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
._loading_14qfh_1{position:fixed;display:flex;align-items:center;justify-content:center;height:100vh;width:100vw;gap:8px}._loading_14qfh_1 ._spinner-grow_14qfh_10{width:40px;height:40px}._loading_14qfh_1 ._spinner-grow_14qfh_10._second_14qfh_14{animation-delay:.1s}._loading_14qfh_1 ._spinner-grow_14qfh_10._third_14qfh_17{animation-delay:.2s}._h1_1unxw_1{font-size:22px;font-weight:400;margin:0;padding:0}._h3_1unxw_8{font-size:20px;font-weight:400;margin:0;padding:0}._h6_1unxw_15,._subtitle_1unxw_22{font-size:16px;font-weight:400;margin:0;padding:0}._body_1unxw_29{font-size:14px;font-weight:400;margin:0;padding:0}._body2_1unxw_36{font-size:13px;font-weight:400;margin:0;padding:0}._caption_1unxw_43{font-size:11px;font-weight:400;margin:0;padding:0}.
|
|
1
|
+
._loading_14qfh_1{position:fixed;display:flex;align-items:center;justify-content:center;height:100vh;width:100vw;gap:8px}._loading_14qfh_1 ._spinner-grow_14qfh_10{width:40px;height:40px}._loading_14qfh_1 ._spinner-grow_14qfh_10._second_14qfh_14{animation-delay:.1s}._loading_14qfh_1 ._spinner-grow_14qfh_10._third_14qfh_17{animation-delay:.2s}._h1_1unxw_1{font-size:22px;font-weight:400;margin:0;padding:0}._h3_1unxw_8{font-size:20px;font-weight:400;margin:0;padding:0}._h6_1unxw_15,._subtitle_1unxw_22{font-size:16px;font-weight:400;margin:0;padding:0}._body_1unxw_29{font-size:14px;font-weight:400;margin:0;padding:0}._body2_1unxw_36{font-size:13px;font-weight:400;margin:0;padding:0}._caption_1unxw_43{font-size:11px;font-weight:400;margin:0;padding:0}._toast_1s57i_1{color:#fff!important;display:flex!important;align-items:center!important;justify-content:center!important;border:none!important;font-size:14px!important;padding:4px 24px 4px 8px!important;gap:4px!important}._toast_1s57i_1.luminus-toast-prompt{color:#000!important}._button_jww69_1{display:flex;align-items:center;justify-content:center;border-width:2px}._button_jww69_1._filled_jww69_7,._button_jww69_1._filled_jww69_7 *{color:#fff}._button_jww69_1._sm_jww69_13{font-size:14px;padding:4px 8px;gap:6px}._button_jww69_1._md_jww69_18{font-size:16px;padding:6px 12px;gap:8px}._button_jww69_1._lg_jww69_23{font-size:18px;padding:10px 16px;gap:12px;min-width:120px}._button_jww69_1:hover,._button_jww69_1:hover *{color:#fff}._submit-container_w6qi9_1{position:fixed;bottom:0;left:0;right:0;display:flex;align-items:center;justify-content:center;gap:12px;padding:24px;background-color:#ffffffe6}._spacer_w6qi9_14{height:75px}._button_6qbjz_1{display:flex;align-items:center;justify-content:center;border:none;font-size:12px;padding:5px 10px;gap:6px}._widget_1sdw8_1{height:320px;display:flex;justify-content:center;align-items:center}._dashboard_1ikl9_1 ._widgets-grid_1ikl9_1{display:grid;grid-template-columns:repeat(2,1fr);column-gap:16px;row-gap:16px}._dashboard_1ikl9_1 ._widget-wrapper_1ikl9_7{position:relative;height:320px;width:100%}._dashboard_1ikl9_1 ._widget-wrapper_1ikl9_7._full-width_1ikl9_12{grid-column:span 2}._dashboard_1ikl9_1 ._widget-wrapper_1ikl9_7._widget-edit_1ikl9_15{border:2px dashed gray}._dashboard_1ikl9_1 ._widget-wrapper_1ikl9_7 ._remove-icon_1ikl9_18{z-index:2;position:absolute;right:-16px;top:-16px;background-color:#fff}._dashboard_1ikl9_1 ._widget-wrapper_1ikl9_7 ._full-width-icon_1ikl9_25{z-index:2;position:absolute;right:-16px;top:calc(50% - 15px);background-color:#fff}._dashboard_1ikl9_1 ._widget-wrapper_1ikl9_7 ._full-width-icon_1ikl9_25 svg{rotate:90deg}._dashboard_1ikl9_1 ._widget-wrapper_1ikl9_7 ._widget-edit-overlay_1ikl9_35{position:absolute;left:0;top:0;height:100%;width:100%;background-color:#80808080;opacity:.6}._badge_nhser_1._sm_nhser_1{padding:4px}._badge_nhser_1._md_nhser_4{padding:8px}._badge_nhser_1._lg_nhser_7{padding:10px}._collapse-icon_1ahhn_1{font-size:22px;rotate:90deg;transition:.2s ease}._collapse-icon_1ahhn_1._collapsed_1ahhn_6{rotate:-90deg}._floating-label_1vydx_1{margin-top:4px}._floating-label_1vydx_1 input{padding:0rem .75rem!important}._floating-label_1vydx_1>.form-control,._floating-label_1vydx_1>.form-control-plaintext,._floating-label_1vydx_1>.form-select{height:calc(3rem + 2px);min-height:calc(3rem + 2px);max-height:calc(3rem + 2px);line-height:1;font-size:14px}._floating-label_1vydx_1>.form-control,._floating-label_1vydx_1>.form-control-plaintext{padding:0rem .75rem}._floating-label_1vydx_1>.form-select{padding:0rem 2rem 0rem .75rem}._floating-label_1vydx_1>label{font-size:14px;padding:0rem .25rem;height:1.5rem;position:absolute;left:.5rem;top:calc(50% - .75rem);transition:all .2s ease}._floating-label_1vydx_1>.form-control:focus~label,._floating-label_1vydx_1>.form-control:not(:placeholder-shown)~label,._floating-label_1vydx_1>.form-select~label{transform:none;height:1.25rem;padding:0rem .25rem;font-size:12px;opacity:1;top:-9px;background-color:#fff}._floating-label_1vydx_1>.form-control:focus~label:after,._floating-label_1vydx_1>.form-control:not(:placeholder-shown)~label:after,._floating-label_1vydx_1>.form-select~label:after{content:none!important}._floating-label_1vydx_1 .form-control:disabled{background-color:#fff;font-style:italic}._feedback_12jrk_1{padding:0 4px;font-size:12px;display:block}._feedback_12jrk_1._for-floating_12jrk_6{position:absolute;background-color:#fff;top:calc(3rem - 8px);right:12px;width:auto;max-width:70%;margin:0}._feedback-spacer_12jrk_16{padding:0 12px;color:transparent;font-size:12px;width:auto;max-width:70%}._dropdown_gxnf9_1{overflow:hidden;position:absolute;display:none;width:100%;background-color:#fff;border-top-left-radius:0!important;border-top-right-radius:0!important}._dropdown_gxnf9_1._open_gxnf9_10{display:block}._dropdown_gxnf9_1 ._selected-button_gxnf9_13{width:100%;background-color:#d3d3d3;border:none;padding:.75rem;text-decoration:none}._dropdown_gxnf9_1 ._clear-button_gxnf9_20{width:100%;padding:.25rem .75rem;background-color:#fff;border:none}._dropdown_gxnf9_1 ._search-input-container_gxnf9_26{padding:.75rem}._dropdown_gxnf9_1 ._search-input-container_gxnf9_26 ._form-control_gxnf9_29{width:100%}._dropdown_gxnf9_1 ._loading-container_gxnf9_32{display:flex;align-items:center;justify-content:center;width:100%;padding:.75rem}._dropdown_gxnf9_1 ._items-container_gxnf9_39{max-height:20vh;overflow-y:auto}._dropdown_gxnf9_1 ._items-container_gxnf9_39 ._item_gxnf9_39{width:100%;padding:.75rem;background-color:#fff;border:none}._side-menu-item_9ejxx_1{width:100%;position:relative}._side-menu-item_9ejxx_1 ._nav-button_9ejxx_5{position:relative;width:100%;display:flex;align-items:center;justify-content:center;padding:8px 16px}._side-menu-item_9ejxx_1 ._nav-button_9ejxx_5._child_9ejxx_13{padding:4px 8px}._side-menu-item_9ejxx_1 ._nav-button_9ejxx_5._child_9ejxx_13 ._text_9ejxx_16{margin-left:0}._side-menu-item_9ejxx_1 ._nav-button_9ejxx_5 ._icon_9ejxx_19{display:flex;justify-content:center;align-items:center;font-size:24px}._side-menu-item_9ejxx_1 ._nav-button_9ejxx_5 ._collapse-icon_9ejxx_25{width:100%;display:flex;justify-content:end;align-items:center;font-size:20px}._side-menu-item_9ejxx_1 ._nav-button_9ejxx_5 ._collapse-icon_9ejxx_25 svg{transition:.2s ease}._side-menu-item_9ejxx_1 ._nav-button_9ejxx_5 ._collapse-icon_9ejxx_25._collapsed_9ejxx_35 svg{rotate:180deg}._side-menu-item_9ejxx_1 ._nav-button_9ejxx_5 ._text_9ejxx_16{font-size:16px;margin-left:24px}._side-menu-item_9ejxx_1._expanded_9ejxx_42 ._nav-button_9ejxx_5,._side-menu-item_9ejxx_1._expanded_9ejxx_42 ._nav-button_9ejxx_5 ._icon_9ejxx_19{justify-content:flex-start}._side-menu-item_9ejxx_1 ._children-container_9ejxx_48{position:absolute;display:none;max-height:0px;flex-direction:column;flex-wrap:wrap;gap:4px;padding:16px}._side-menu-item_9ejxx_1 ._children-container_9ejxx_48._visible_9ejxx_57{display:flex;left:100%;top:0;max-height:50vh}._side-menu_1hjei_1{position:fixed;top:0;left:0;height:100%;background-color:#fff;transition:.3s ease;scrollbar-width:none}._side-menu_1hjei_1::state(webkit-scrollbar){display:none}._side-menu_1hjei_1 ._sidebar-header_1hjei_13{display:flex;justify-content:center;align-items:center}._side-menu_1hjei_1 ._side-menu-content_1hjei_18{margin-top:64px;padding:0}._side-menu_1hjei_1._expand_1hjei_22 ._sidebar-header_1hjei_13{padding:0 12px;justify-content:start}._side-menu_1hjei_1 ._divider_1hjei_26{opacity:1}._top-bar_1t8hq_1{padding:0 12px;border-left:16px solid transparent;display:flex;align-items:center;grid-gap:24px;position:fixed;top:0;left:0;width:100%;transition:.3s ease}._top-bar_1t8hq_1 ._top-bar-brand_1t8hq_13{text-decoration:none;font-size:20px;margin-left:12px}._side-content-bar_17kwd_1{position:fixed;top:0;right:0;height:100%;background-color:#fff;overflow-x:hidden;scrollbar-width:none}._side-content-bar_17kwd_1::state(webkit-scrollbar){display:none}._full-screen-container_1c9bu_1{width:100%;display:flex;flex-direction:column}.luminus-input-remove-icon{position:absolute;top:0;right:16px;height:100%;display:flex;align-items:center;justify-content:center}.luminus-input-remove-icon.inset{right:40px}.luminus-input-remove-icon .icon-button{padding:0;margin:0;font-size:16px;height:20px;width:20px;display:flex;align-items:center}.form-control,.form-control-plaintext,.form-select{box-shadow:none!important}._avatar-icon_1axl6_1{height:36px;width:36px;display:flex;align-items:center;justify-content:center;border-radius:100%;color:#fff;font-size:16px}._item_qkqdk_1{display:flex;align-items:center;justify-content:flex-start;border:none;font-size:12px;padding:8px 14px;gap:8px}._item_qkqdk_1:after{content:none!important}._button_s0y6b_1{display:flex;align-items:center;justify-content:center;border:none;font-size:12px;padding:5px 10px;gap:6px}._button_s0y6b_1:after{content:none}._dropdown_1lk66_1{padding:0;border:none;min-width:auto}._tabs_13chm_1{gap:4px;border:none!important}._tabs_13chm_1 .nav-link{font-size:16px;padding:12px}._tabs_13chm_1 .nav-link.active{background-color:#fff!important}._tabs_13chm_1 .nav-link:not(.active){border:none!important}._tabs_13chm_1~.tab-content{background-color:#fff;padding:1rem}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
const n = (r) => r == null ? !0 : !(typeof r == "object" || typeof r == "function"), a = (r) => {
|
|
2
|
+
n(r) || Object.keys(r).forEach((t) => {
|
|
3
|
+
const s = r[t];
|
|
4
|
+
if (n(s))
|
|
5
|
+
return;
|
|
6
|
+
const e = Object.keys(s);
|
|
7
|
+
e.includes("id") && e.length === 1 && s.id === null ? r[t] = null : a(s);
|
|
8
|
+
});
|
|
9
|
+
}, i = (r) => {
|
|
10
|
+
var s;
|
|
11
|
+
const t = (s = r.response) == null ? void 0 : s.data;
|
|
12
|
+
return t && t.errorFields && t.errorFields.length > 0 ? t.errorFields.map((e) => ({
|
|
13
|
+
name: e.name.split(".").map((o) => `${o.charAt(0).toLowerCase()}${o.slice(1)}`).join("."),
|
|
14
|
+
errors: e.errors
|
|
15
|
+
})) : [];
|
|
16
|
+
}, l = (r, t) => {
|
|
17
|
+
i(t).forEach((e) => {
|
|
18
|
+
r.setError(e.name, { message: e.errors, type: "server" }, { shouldFocus: !0 }), n(r.getValues(e.name)) || r.setError(`${e.name}.id`, { message: e.errors, type: "server" }, { shouldFocus: !0 });
|
|
19
|
+
});
|
|
20
|
+
}, c = (r) => r.length < 300 ? r : r.substring(0, 300) + "...", d = (r) => r < 1024 ? `${r} bytes` : r >= 1024 && r < 1048576 ? `${(r / 1024).toFixed(1)} KB` : `${(r / 1048576).toFixed(1)} MB`;
|
|
21
|
+
export {
|
|
22
|
+
a,
|
|
23
|
+
i as e,
|
|
24
|
+
d as f,
|
|
25
|
+
l as h,
|
|
26
|
+
n as i,
|
|
27
|
+
c as t
|
|
28
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const o=r=>r==null?!0:!(typeof r=="object"||typeof r=="function"),i=r=>{o(r)||Object.keys(r).forEach(t=>{const s=r[t];if(o(s))return;const e=Object.keys(s);e.includes("id")&&e.length===1&&s.id===null?r[t]=null:i(s)})},u=r=>{var s;const t=(s=r.response)==null?void 0:s.data;return t&&t.errorFields&&t.errorFields.length>0?t.errorFields.map(e=>({name:e.name.split(".").map(n=>`${n.charAt(0).toLowerCase()}${n.slice(1)}`).join("."),errors:e.errors})):[]},a=(r,t)=>{u(t).forEach(e=>{r.setError(e.name,{message:e.errors,type:"server"},{shouldFocus:!0}),o(r.getValues(e.name))||r.setError(`${e.name}.id`,{message:e.errors,type:"server"},{shouldFocus:!0})})},l=r=>r.length<300?r:r.substring(0,300)+"...",c=r=>r<1024?`${r} bytes`:r>=1024&&r<1048576?`${(r/1024).toFixed(1)} KB`:`${(r/1048576).toFixed(1)} MB`;exports.extractErrorsFromResponse=u;exports.fixNameIdNulls=i;exports.formatFileSize=c;exports.hookFormSetServerErrors=a;exports.isPrimitive=o;exports.truncateText=l;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const m=require("./SimplePicker.module-qosp2o8I.cjs"),C=require("react");let n;const f=()=>{const{show:e,text:r,showConfirm:t,hideConfirm:s}=C.useContext(m.ConfirmContext),o=()=>{s()};return{confirm:async c=>(t(c),new Promise(i=>{n=i})),onConfirm:()=>{o(),n(!0)},onCancel:()=>{o(),n(!1)},show:e,text:r}};exports.useConfirm=f;
|
package/dist/utils.cjs.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("./textUtils-FVcup93t.cjs"),d=require("./constants-CT2hnPeO.cjs");function g(t,e){const r=(e==null?void 0:e.additionalDigits)??2,n=x(t);let i;if(n.date){const s=S(n.date,r);i=U(s.restDateString,s.year)}if(!i||isNaN(i.getTime()))return new Date(NaN);const a=i.getTime();let o=0,c;if(n.time&&(o=h(n.time),isNaN(o)))return new Date(NaN);if(n.timezone){if(c=w(n.timezone),isNaN(c))return new Date(NaN)}else{const s=new Date(a+o),u=new Date(0);return u.setFullYear(s.getUTCFullYear(),s.getUTCMonth(),s.getUTCDate()),u.setHours(s.getUTCHours(),s.getUTCMinutes(),s.getUTCSeconds(),s.getUTCMilliseconds()),u}return new Date(a+o+c)}const m={dateTimeDelimiter:/[T ]/,timeZoneDelimiter:/[Z ]/i,timezone:/([Z+-].*)$/},p=/^-?(?:(\d{3})|(\d{2})(?:-?(\d{2}))?|W(\d{2})(?:-?(\d{1}))?|)$/,T=/^(\d{2}(?:[.,]\d*)?)(?::?(\d{2}(?:[.,]\d*)?))?(?::?(\d{2}(?:[.,]\d*)?))?$/,I=/^([+-])(\d{2})(?::?(\d{2}))?$/;function x(t){const e={},r=t.split(m.dateTimeDelimiter);let n;if(r.length>2)return e;if(/:/.test(r[0])?n=r[0]:(e.date=r[0],n=r[1],m.timeZoneDelimiter.test(e.date)&&(e.date=t.split(m.timeZoneDelimiter)[0],n=t.substr(e.date.length,t.length))),n){const i=m.timezone.exec(n);i?(e.time=n.replace(i[1],""),e.timezone=i[1]):e.time=n}return e}function S(t,e){const r=new RegExp("^(?:(\\d{4}|[+-]\\d{"+(4+e)+"})|(\\d{2}|[+-]\\d{"+(2+e)+"})$)"),n=t.match(r);if(!n)return{year:NaN,restDateString:""};const i=n[1]?parseInt(n[1]):null,a=n[2]?parseInt(n[2]):null;return{year:a===null?i:a*100,restDateString:t.slice((n[1]||n[2]).length)}}function U(t,e){if(e===null)return new Date(NaN);const r=t.match(p);if(!r)return new Date(NaN);const n=!!r[4],i=f(r[1]),a=f(r[2])-1,o=f(r[3]),c=f(r[4]),s=f(r[5])-1;if(n)return O(e,c,s)?C(e,c,s):new Date(NaN);{const u=new Date(0);return!y(e,a,o)||!z(e,i)?new Date(NaN):(u.setUTCFullYear(e,a,Math.max(i,o)),u)}}function f(t){return t?parseInt(t):1}function h(t){const e=t.match(T);if(!e)return NaN;const r=D(e[1]),n=D(e[2]),i=D(e[3]);return Y(r,n,i)?r*d.millisecondsInHour+n*d.millisecondsInMinute+i*1e3:NaN}function D(t){return t&&parseFloat(t.replace(",","."))||0}function w(t){if(t==="Z")return 0;const e=t.match(I);if(!e)return 0;const r=e[1]==="+"?-1:1,n=parseInt(e[2]),i=e[3]&&parseInt(e[3])||0;return v(n,i)?r*(n*d.millisecondsInHour+i*d.millisecondsInMinute):NaN}function C(t,e,r){const n=new Date(0);n.setUTCFullYear(t,0,4);const i=n.getUTCDay()||7,a=(e-1)*7+r+1-i;return n.setUTCDate(n.getUTCDate()+a),n}const F=[31,null,31,30,31,30,31,31,30,31,30,31];function N(t){return t%400===0||t%4===0&&t%100!==0}function y(t,e,r){return e>=0&&e<=11&&r>=1&&r<=(F[e]||(N(t)?29:28))}function z(t,e){return e>=1&&e<=(N(t)?366:365)}function O(t,e,r){return e>=1&&e<=53&&r>=0&&r<=6}function Y(t,e,r){return t===24?e===0&&r===0:r>=0&&r<60&&e>=0&&e<60&&t>=0&&t<25}function v(t,e){return e>=0&&e<=59}const M=t=>{const e=g(t);return!isNaN(e.getTime())};exports.extractErrorsFromResponse=l.extractErrorsFromResponse;exports.fixNameIdNulls=l.fixNameIdNulls;exports.formatFileSize=l.formatFileSize;exports.hookFormSetServerErrors=l.hookFormSetServerErrors;exports.isPrimitive=l.isPrimitive;exports.truncateText=l.truncateText;exports.isISODate=M;
|
package/dist/utils.es.js
CHANGED
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { e as W,
|
|
2
|
-
import { b as
|
|
1
|
+
import { e as W, a as $, f as E, h as H, i as b, t as _ } from "./textUtils-CDK5A52_.js";
|
|
2
|
+
import { b as d, c as D } from "./constants-CzNy5yO3.js";
|
|
3
3
|
function p(t, e) {
|
|
4
4
|
const r = (e == null ? void 0 : e.additionalDigits) ?? 2, n = U(t);
|
|
5
5
|
let a;
|
|
6
6
|
if (n.date) {
|
|
7
|
-
const
|
|
8
|
-
a = x(
|
|
7
|
+
const i = w(n.date, r);
|
|
8
|
+
a = x(i.restDateString, i.year);
|
|
9
9
|
}
|
|
10
10
|
if (!a || isNaN(a.getTime()))
|
|
11
11
|
return /* @__PURE__ */ new Date(NaN);
|
|
12
|
-
const
|
|
12
|
+
const s = a.getTime();
|
|
13
13
|
let o = 0, c;
|
|
14
14
|
if (n.time && (o = I(n.time), isNaN(o)))
|
|
15
15
|
return /* @__PURE__ */ new Date(NaN);
|
|
@@ -17,19 +17,19 @@ function p(t, e) {
|
|
|
17
17
|
if (c = C(n.timezone), isNaN(c))
|
|
18
18
|
return /* @__PURE__ */ new Date(NaN);
|
|
19
19
|
} else {
|
|
20
|
-
const
|
|
20
|
+
const i = new Date(s + o), u = /* @__PURE__ */ new Date(0);
|
|
21
21
|
return u.setFullYear(
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
22
|
+
i.getUTCFullYear(),
|
|
23
|
+
i.getUTCMonth(),
|
|
24
|
+
i.getUTCDate()
|
|
25
25
|
), u.setHours(
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
26
|
+
i.getUTCHours(),
|
|
27
|
+
i.getUTCMinutes(),
|
|
28
|
+
i.getUTCSeconds(),
|
|
29
|
+
i.getUTCMilliseconds()
|
|
30
30
|
), u;
|
|
31
31
|
}
|
|
32
|
-
return new Date(
|
|
32
|
+
return new Date(s + o + c);
|
|
33
33
|
}
|
|
34
34
|
const f = {
|
|
35
35
|
dateTimeDelimiter: /[T ]/,
|
|
@@ -56,9 +56,9 @@ function w(t, e) {
|
|
|
56
56
|
), n = t.match(r);
|
|
57
57
|
if (!n)
|
|
58
58
|
return { year: NaN, restDateString: "" };
|
|
59
|
-
const a = n[1] ? parseInt(n[1]) : null,
|
|
59
|
+
const a = n[1] ? parseInt(n[1]) : null, s = n[2] ? parseInt(n[2]) : null;
|
|
60
60
|
return {
|
|
61
|
-
year:
|
|
61
|
+
year: s === null ? a : s * 100,
|
|
62
62
|
restDateString: t.slice((n[1] || n[2]).length)
|
|
63
63
|
};
|
|
64
64
|
}
|
|
@@ -68,12 +68,12 @@ function x(t, e) {
|
|
|
68
68
|
const r = t.match(g);
|
|
69
69
|
if (!r)
|
|
70
70
|
return /* @__PURE__ */ new Date(NaN);
|
|
71
|
-
const n = !!r[4], a = l(r[1]),
|
|
71
|
+
const n = !!r[4], a = l(r[1]), s = l(r[2]) - 1, o = l(r[3]), c = l(r[4]), i = l(r[5]) - 1;
|
|
72
72
|
if (n)
|
|
73
|
-
return F(e, c,
|
|
73
|
+
return F(e, c, i) ? S(e, c, i) : /* @__PURE__ */ new Date(NaN);
|
|
74
74
|
{
|
|
75
75
|
const u = /* @__PURE__ */ new Date(0);
|
|
76
|
-
return !
|
|
76
|
+
return !y(e, s, o) || !z(e, a) ? /* @__PURE__ */ new Date(NaN) : (u.setUTCFullYear(e, s, Math.max(a, o)), u);
|
|
77
77
|
}
|
|
78
78
|
}
|
|
79
79
|
function l(t) {
|
|
@@ -83,10 +83,10 @@ function I(t) {
|
|
|
83
83
|
const e = t.match(T);
|
|
84
84
|
if (!e)
|
|
85
85
|
return NaN;
|
|
86
|
-
const r =
|
|
87
|
-
return O(r, n, a) ? r *
|
|
86
|
+
const r = m(e[1]), n = m(e[2]), a = m(e[3]);
|
|
87
|
+
return O(r, n, a) ? r * d + n * D + a * 1e3 : NaN;
|
|
88
88
|
}
|
|
89
|
-
function
|
|
89
|
+
function m(t) {
|
|
90
90
|
return t && parseFloat(t.replace(",", ".")) || 0;
|
|
91
91
|
}
|
|
92
92
|
function C(t) {
|
|
@@ -96,20 +96,20 @@ function C(t) {
|
|
|
96
96
|
if (!e)
|
|
97
97
|
return 0;
|
|
98
98
|
const r = e[1] === "+" ? -1 : 1, n = parseInt(e[2]), a = e[3] && parseInt(e[3]) || 0;
|
|
99
|
-
return k(n, a) ? r * (n *
|
|
99
|
+
return k(n, a) ? r * (n * d + a * D) : NaN;
|
|
100
100
|
}
|
|
101
|
-
function
|
|
101
|
+
function S(t, e, r) {
|
|
102
102
|
const n = /* @__PURE__ */ new Date(0);
|
|
103
103
|
n.setUTCFullYear(t, 0, 4);
|
|
104
|
-
const a = n.getUTCDay() || 7,
|
|
105
|
-
return n.setUTCDate(n.getUTCDate() +
|
|
104
|
+
const a = n.getUTCDay() || 7, s = (e - 1) * 7 + r + 1 - a;
|
|
105
|
+
return n.setUTCDate(n.getUTCDate() + s), n;
|
|
106
106
|
}
|
|
107
|
-
const
|
|
107
|
+
const Y = [31, null, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31];
|
|
108
108
|
function N(t) {
|
|
109
109
|
return t % 400 === 0 || t % 4 === 0 && t % 100 !== 0;
|
|
110
110
|
}
|
|
111
|
-
function
|
|
112
|
-
return e >= 0 && e <= 11 && r >= 1 && r <= (
|
|
111
|
+
function y(t, e, r) {
|
|
112
|
+
return e >= 0 && e <= 11 && r >= 1 && r <= (Y[e] || (N(t) ? 29 : 28));
|
|
113
113
|
}
|
|
114
114
|
function z(t, e) {
|
|
115
115
|
return e >= 1 && e <= (N(t) ? 366 : 365);
|
|
@@ -130,8 +130,9 @@ const R = (t) => {
|
|
|
130
130
|
export {
|
|
131
131
|
W as extractErrorsFromResponse,
|
|
132
132
|
$ as fixNameIdNulls,
|
|
133
|
-
E as
|
|
133
|
+
E as formatFileSize,
|
|
134
|
+
H as hookFormSetServerErrors,
|
|
134
135
|
R as isISODate,
|
|
135
|
-
|
|
136
|
-
|
|
136
|
+
b as isPrimitive,
|
|
137
|
+
_ as truncateText
|
|
137
138
|
};
|
package/package.json
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-luminus-components",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.12",
|
|
4
4
|
"description": "Library of React Components reusable in Luminus projects (Fleetman, CAFM)",
|
|
5
|
+
"type": "module",
|
|
5
6
|
"repository": {
|
|
6
7
|
"type": "git",
|
|
7
8
|
"url": "git+https://github.com/BenefitCZ/react-luminus-components.git"
|
|
@@ -70,6 +71,7 @@
|
|
|
70
71
|
"@types/node": "^20.11.29",
|
|
71
72
|
"@types/react": "^18.2.56",
|
|
72
73
|
"@types/react-dom": "^18.2.19",
|
|
74
|
+
"@types/uuid": "^9.0.8",
|
|
73
75
|
"@typescript-eslint/eslint-plugin": "^7.3.1",
|
|
74
76
|
"@typescript-eslint/parser": "^7.3.1",
|
|
75
77
|
"@vitejs/plugin-react": "^4.2.1",
|
package/dist/DataKey-C5l4FOL1.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";const s=require("./SimplePicker.module-De0azFIA.js"),a=require("react"),u=()=>s.jsxRuntimeExports.jsxs("div",{className:s.classNames("luminus-loading",s.classes.loading),children:[s.jsxRuntimeExports.jsx("div",{className:s.classNames("spinner-grow",s.classes.spinnerGrow,"text-primary"),role:"status"}),s.jsxRuntimeExports.jsx("div",{className:s.classNames("spinner-grow",s.classes.spinnerGrow,"text-primary",s.classes.second),role:"status"}),s.jsxRuntimeExports.jsx("div",{className:s.classNames("spinner-grow",s.classes.spinnerGrow,"text-primary",s.classes.third),role:"status"})]}),n=({variant:e,className:t,children:r})=>{switch(e){case"h1":return s.jsxRuntimeExports.jsx("h1",{className:s.classNames("luminus-text-primary luminus-h1",s.classes$1.h1,t),children:r});case"h3":return s.jsxRuntimeExports.jsx("h3",{className:s.classNames("luminus-text luminus-h3",s.classes$1.h3,t),children:r});case"h6":return s.jsxRuntimeExports.jsx("h6",{className:s.classNames("luminus-text luminus-h6",s.classes$1.h6,t),children:r});case"subtitle":return s.jsxRuntimeExports.jsx("div",{className:s.classNames("luminus-text luminus-subtitle",s.classes$1.subtitle,t),children:r});case"body":return s.jsxRuntimeExports.jsx("div",{className:s.classNames("luminus-text luminus-body",s.classes$1.body,t),children:r});case"body2":return s.jsxRuntimeExports.jsx("div",{className:s.classNames("luminus-text luminus-body2",s.classes$1.body2,t),children:r});case"caption":return s.jsxRuntimeExports.jsx("div",{className:s.classNames("luminus-text-muted luminus-caption",s.classes$1.caption,t),children:r});default:return s.jsxRuntimeExports.jsx(s.jsxRuntimeExports.Fragment,{children:r})}},i=({variant:e,className:t,children:r})=>s.jsxRuntimeExports.jsx(n,{variant:e,className:t,children:r});function o(e){const t=a.useRef(null);return a.useEffect(()=>{t.current=e}),t.current}var c=Function.prototype.bind.call(Function.prototype.call,[].slice);function l(e,t){return c(e.querySelectorAll(t))}const m="data-rr-ui-",x="rrUi";function p(e){return`${m}${e}`}function j(e){return`${x}${e}`}exports.Loading=u;exports.Typography=i;exports.dataAttr=p;exports.dataProp=j;exports.qsa=l;exports.usePrevious=o;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";const M=require("./SimplePicker.module-De0azFIA.js"),b=require("./hasClass-DXhjqDzJ.js"),O=require("react"),Ut=require("react-dom");function Vt(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const r in e)if(r!=="default"){const n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}}return t.default=e,Object.freeze(t)}const z=Vt(O);function De(){return De=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},De.apply(this,arguments)}function Je(e){return"default"+e.charAt(0).toUpperCase()+e.substr(1)}function qt(e){var t=zt(e,"string");return typeof t=="symbol"?t:String(t)}function zt(e,t){if(typeof e!="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(typeof n!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function pt(e,t,r){var n=O.useRef(e!==void 0),o=O.useState(t),i=o[0],c=o[1],u=e!==void 0,a=n.current;return n.current=u,!u&&a&&i!==t&&c(t),[u?e:i,O.useCallback(function(f){for(var s=arguments.length,d=new Array(s>1?s-1:0),m=1;m<s;m++)d[m-1]=arguments[m];r&&r.apply(void 0,[f].concat(d)),c(f)},[r])]}function Xt(e,t){return Object.keys(t).reduce(function(r,n){var o,i=r,c=i[Je(n)],u=i[n],a=b._objectWithoutPropertiesLoose(i,[Je(n),n].map(qt)),f=t[n],s=pt(u,c,e[f]),d=s[0],m=s[1];return De({},a,(o={},o[n]=d,o[f]=m,o))},e)}const Te=2**31-1;function dt(e,t,r){const n=r-Date.now();e.current=n<=Te?setTimeout(t,n):setTimeout(()=>dt(e,t,r),Te)}function Yt(){const e=b.useMounted(),t=O.useRef();return b.useWillUnmount(()=>clearTimeout(t.current)),O.useMemo(()=>{const r=()=>clearTimeout(t.current);function n(o,i=0){e()&&(r(),i<=Te?t.current=setTimeout(o,i):dt(t,o,Date.now()+i))}return{set:n,clear:r,handleRef:t}},[])}var Qe=Object.prototype.hasOwnProperty;function Ze(e,t,r){for(r of e.keys())if(ue(r,t))return r}function ue(e,t){var r,n,o;if(e===t)return!0;if(e&&t&&(r=e.constructor)===t.constructor){if(r===Date)return e.getTime()===t.getTime();if(r===RegExp)return e.toString()===t.toString();if(r===Array){if((n=e.length)===t.length)for(;n--&&ue(e[n],t[n]););return n===-1}if(r===Set){if(e.size!==t.size)return!1;for(n of e)if(o=n,o&&typeof o=="object"&&(o=Ze(t,o),!o)||!t.has(o))return!1;return!0}if(r===Map){if(e.size!==t.size)return!1;for(n of e)if(o=n[0],o&&typeof o=="object"&&(o=Ze(t,o),!o)||!ue(n[1],t.get(o)))return!1;return!0}if(r===ArrayBuffer)e=new Uint8Array(e),t=new Uint8Array(t);else if(r===DataView){if((n=e.byteLength)===t.byteLength)for(;n--&&e.getInt8(n)===t.getInt8(n););return n===-1}if(ArrayBuffer.isView(e)){if((n=e.byteLength)===t.byteLength)for(;n--&&e[n]===t[n];);return n===-1}if(!r||typeof e=="object"){n=0;for(r in e)if(Qe.call(e,r)&&++n&&!Qe.call(t,r)||!(r in t)||!ue(e[r],t[r]))return!1;return Object.keys(t).length===n}}return e!==e&&t!==t}function Kt(e){const t=b.useMounted();return[e[0],O.useCallback(r=>{if(t())return e[1](r)},[t,e[1]])]}var B="top",W="bottom",H="right",k="left",$e="auto",de=[B,W,H,k],te="start",le="end",Gt="clippingParents",vt="viewport",se="popper",Jt="reference",et=de.reduce(function(e,t){return e.concat([t+"-"+te,t+"-"+le])},[]),mt=[].concat(de,[$e]).reduce(function(e,t){return e.concat([t,t+"-"+te,t+"-"+le])},[]),Qt="beforeRead",Zt="read",er="afterRead",tr="beforeMain",rr="main",nr="afterMain",or="beforeWrite",ir="write",ar="afterWrite",sr=[Qt,Zt,er,tr,rr,nr,or,ir,ar];function I(e){return e.split("-")[0]}function F(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function Z(e){var t=F(e).Element;return e instanceof t||e instanceof Element}function U(e){var t=F(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function Be(e){if(typeof ShadowRoot>"u")return!1;var t=F(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}var Q=Math.max,Ee=Math.min,re=Math.round;function Me(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function ht(){return!/^((?!chrome|android).)*safari/i.test(Me())}function ne(e,t,r){t===void 0&&(t=!1),r===void 0&&(r=!1);var n=e.getBoundingClientRect(),o=1,i=1;t&&U(e)&&(o=e.offsetWidth>0&&re(n.width)/e.offsetWidth||1,i=e.offsetHeight>0&&re(n.height)/e.offsetHeight||1);var c=Z(e)?F(e):window,u=c.visualViewport,a=!ht()&&r,f=(n.left+(a&&u?u.offsetLeft:0))/o,s=(n.top+(a&&u?u.offsetTop:0))/i,d=n.width/o,m=n.height/i;return{width:d,height:m,top:s,right:f+d,bottom:s+m,left:f,x:f,y:s}}function ke(e){var t=ne(e),r=e.offsetWidth,n=e.offsetHeight;return Math.abs(t.width-r)<=1&&(r=t.width),Math.abs(t.height-n)<=1&&(n=t.height),{x:e.offsetLeft,y:e.offsetTop,width:r,height:n}}function gt(e,t){var r=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(r&&Be(r)){var n=t;do{if(n&&e.isSameNode(n))return!0;n=n.parentNode||n.host}while(n)}return!1}function X(e){return e?(e.nodeName||"").toLowerCase():null}function V(e){return F(e).getComputedStyle(e)}function ur(e){return["table","td","th"].indexOf(X(e))>=0}function Y(e){return((Z(e)?e.ownerDocument:e.document)||window.document).documentElement}function Re(e){return X(e)==="html"?e:e.assignedSlot||e.parentNode||(Be(e)?e.host:null)||Y(e)}function tt(e){return!U(e)||V(e).position==="fixed"?null:e.offsetParent}function cr(e){var t=/firefox/i.test(Me()),r=/Trident/i.test(Me());if(r&&U(e)){var n=V(e);if(n.position==="fixed")return null}var o=Re(e);for(Be(o)&&(o=o.host);U(o)&&["html","body"].indexOf(X(o))<0;){var i=V(o);if(i.transform!=="none"||i.perspective!=="none"||i.contain==="paint"||["transform","perspective"].indexOf(i.willChange)!==-1||t&&i.willChange==="filter"||t&&i.filter&&i.filter!=="none")return o;o=o.parentNode}return null}function ve(e){for(var t=F(e),r=tt(e);r&&ur(r)&&V(r).position==="static";)r=tt(r);return r&&(X(r)==="html"||X(r)==="body"&&V(r).position==="static")?t:r||cr(e)||t}function Le(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function ce(e,t,r){return Q(e,Ee(t,r))}function fr(e,t,r){var n=ce(e,t,r);return n>r?r:n}function yt(){return{top:0,right:0,bottom:0,left:0}}function wt(e){return Object.assign({},yt(),e)}function bt(e,t){return t.reduce(function(r,n){return r[n]=e,r},{})}var lr=function(t,r){return t=typeof t=="function"?t(Object.assign({},r.rects,{placement:r.placement})):t,wt(typeof t!="number"?t:bt(t,de))};function pr(e){var t,r=e.state,n=e.name,o=e.options,i=r.elements.arrow,c=r.modifiersData.popperOffsets,u=I(r.placement),a=Le(u),f=[k,H].indexOf(u)>=0,s=f?"height":"width";if(!(!i||!c)){var d=lr(o.padding,r),m=ke(i),p=a==="y"?B:k,v=a==="y"?W:H,g=r.rects.reference[s]+r.rects.reference[a]-c[a]-r.rects.popper[s],l=c[a]-r.rects.reference[a],y=ve(i),h=y?a==="y"?y.clientHeight||0:y.clientWidth||0:0,E=g/2-l/2,w=d[p],R=h-m[s]-d[v],x=h/2-m[s]/2+E,j=ce(w,x,R),C=a;r.modifiersData[n]=(t={},t[C]=j,t.centerOffset=j-x,t)}}function dr(e){var t=e.state,r=e.options,n=r.element,o=n===void 0?"[data-popper-arrow]":n;o!=null&&(typeof o=="string"&&(o=t.elements.popper.querySelector(o),!o)||gt(t.elements.popper,o)&&(t.elements.arrow=o))}const vr={name:"arrow",enabled:!0,phase:"main",fn:pr,effect:dr,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function oe(e){return e.split("-")[1]}var mr={top:"auto",right:"auto",bottom:"auto",left:"auto"};function hr(e,t){var r=e.x,n=e.y,o=t.devicePixelRatio||1;return{x:re(r*o)/o||0,y:re(n*o)/o||0}}function rt(e){var t,r=e.popper,n=e.popperRect,o=e.placement,i=e.variation,c=e.offsets,u=e.position,a=e.gpuAcceleration,f=e.adaptive,s=e.roundOffsets,d=e.isFixed,m=c.x,p=m===void 0?0:m,v=c.y,g=v===void 0?0:v,l=typeof s=="function"?s({x:p,y:g}):{x:p,y:g};p=l.x,g=l.y;var y=c.hasOwnProperty("x"),h=c.hasOwnProperty("y"),E=k,w=B,R=window;if(f){var x=ve(r),j="clientHeight",C="clientWidth";if(x===F(r)&&(x=Y(r),V(x).position!=="static"&&u==="absolute"&&(j="scrollHeight",C="scrollWidth")),x=x,o===B||(o===k||o===H)&&i===le){w=W;var A=d&&x===R&&R.visualViewport?R.visualViewport.height:x[j];g-=A-n.height,g*=a?1:-1}if(o===k||(o===B||o===W)&&i===le){E=H;var P=d&&x===R&&R.visualViewport?R.visualViewport.width:x[C];p-=P-n.width,p*=a?1:-1}}var D=Object.assign({position:u},f&&mr),L=s===!0?hr({x:p,y:g},F(r)):{x:p,y:g};if(p=L.x,g=L.y,a){var T;return Object.assign({},D,(T={},T[w]=h?"0":"",T[E]=y?"0":"",T.transform=(R.devicePixelRatio||1)<=1?"translate("+p+"px, "+g+"px)":"translate3d("+p+"px, "+g+"px, 0)",T))}return Object.assign({},D,(t={},t[w]=h?g+"px":"",t[E]=y?p+"px":"",t.transform="",t))}function gr(e){var t=e.state,r=e.options,n=r.gpuAcceleration,o=n===void 0?!0:n,i=r.adaptive,c=i===void 0?!0:i,u=r.roundOffsets,a=u===void 0?!0:u,f={placement:I(t.placement),variation:oe(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:o,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,rt(Object.assign({},f,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:c,roundOffsets:a})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,rt(Object.assign({},f,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:a})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const yr={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:gr,data:{}};var be={passive:!0};function wr(e){var t=e.state,r=e.instance,n=e.options,o=n.scroll,i=o===void 0?!0:o,c=n.resize,u=c===void 0?!0:c,a=F(t.elements.popper),f=[].concat(t.scrollParents.reference,t.scrollParents.popper);return i&&f.forEach(function(s){s.addEventListener("scroll",r.update,be)}),u&&a.addEventListener("resize",r.update,be),function(){i&&f.forEach(function(s){s.removeEventListener("scroll",r.update,be)}),u&&a.removeEventListener("resize",r.update,be)}}const br={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:wr,data:{}};var xr={left:"right",right:"left",bottom:"top",top:"bottom"};function xe(e){return e.replace(/left|right|bottom|top/g,function(t){return xr[t]})}var Or={start:"end",end:"start"};function nt(e){return e.replace(/start|end/g,function(t){return Or[t]})}function Ne(e){var t=F(e),r=t.pageXOffset,n=t.pageYOffset;return{scrollLeft:r,scrollTop:n}}function Fe(e){return ne(Y(e)).left+Ne(e).scrollLeft}function Er(e,t){var r=F(e),n=Y(e),o=r.visualViewport,i=n.clientWidth,c=n.clientHeight,u=0,a=0;if(o){i=o.width,c=o.height;var f=ht();(f||!f&&t==="fixed")&&(u=o.offsetLeft,a=o.offsetTop)}return{width:i,height:c,x:u+Fe(e),y:a}}function Rr(e){var t,r=Y(e),n=Ne(e),o=(t=e.ownerDocument)==null?void 0:t.body,i=Q(r.scrollWidth,r.clientWidth,o?o.scrollWidth:0,o?o.clientWidth:0),c=Q(r.scrollHeight,r.clientHeight,o?o.scrollHeight:0,o?o.clientHeight:0),u=-n.scrollLeft+Fe(e),a=-n.scrollTop;return V(o||r).direction==="rtl"&&(u+=Q(r.clientWidth,o?o.clientWidth:0)-i),{width:i,height:c,x:u,y:a}}function We(e){var t=V(e),r=t.overflow,n=t.overflowX,o=t.overflowY;return/auto|scroll|overlay|hidden/.test(r+o+n)}function xt(e){return["html","body","#document"].indexOf(X(e))>=0?e.ownerDocument.body:U(e)&&We(e)?e:xt(Re(e))}function fe(e,t){var r;t===void 0&&(t=[]);var n=xt(e),o=n===((r=e.ownerDocument)==null?void 0:r.body),i=F(n),c=o?[i].concat(i.visualViewport||[],We(n)?n:[]):n,u=t.concat(c);return o?u:u.concat(fe(Re(c)))}function Se(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function jr(e,t){var r=ne(e,!1,t==="fixed");return r.top=r.top+e.clientTop,r.left=r.left+e.clientLeft,r.bottom=r.top+e.clientHeight,r.right=r.left+e.clientWidth,r.width=e.clientWidth,r.height=e.clientHeight,r.x=r.left,r.y=r.top,r}function ot(e,t,r){return t===vt?Se(Er(e,r)):Z(t)?jr(t,r):Se(Rr(Y(e)))}function Pr(e){var t=fe(Re(e)),r=["absolute","fixed"].indexOf(V(e).position)>=0,n=r&&U(e)?ve(e):e;return Z(n)?t.filter(function(o){return Z(o)&>(o,n)&&X(o)!=="body"}):[]}function Cr(e,t,r,n){var o=t==="clippingParents"?Pr(e):[].concat(t),i=[].concat(o,[r]),c=i[0],u=i.reduce(function(a,f){var s=ot(e,f,n);return a.top=Q(s.top,a.top),a.right=Ee(s.right,a.right),a.bottom=Ee(s.bottom,a.bottom),a.left=Q(s.left,a.left),a},ot(e,c,n));return u.width=u.right-u.left,u.height=u.bottom-u.top,u.x=u.left,u.y=u.top,u}function Ot(e){var t=e.reference,r=e.element,n=e.placement,o=n?I(n):null,i=n?oe(n):null,c=t.x+t.width/2-r.width/2,u=t.y+t.height/2-r.height/2,a;switch(o){case B:a={x:c,y:t.y-r.height};break;case W:a={x:c,y:t.y+t.height};break;case H:a={x:t.x+t.width,y:u};break;case k:a={x:t.x-r.width,y:u};break;default:a={x:t.x,y:t.y}}var f=o?Le(o):null;if(f!=null){var s=f==="y"?"height":"width";switch(i){case te:a[f]=a[f]-(t[s]/2-r[s]/2);break;case le:a[f]=a[f]+(t[s]/2-r[s]/2);break}}return a}function pe(e,t){t===void 0&&(t={});var r=t,n=r.placement,o=n===void 0?e.placement:n,i=r.strategy,c=i===void 0?e.strategy:i,u=r.boundary,a=u===void 0?Gt:u,f=r.rootBoundary,s=f===void 0?vt:f,d=r.elementContext,m=d===void 0?se:d,p=r.altBoundary,v=p===void 0?!1:p,g=r.padding,l=g===void 0?0:g,y=wt(typeof l!="number"?l:bt(l,de)),h=m===se?Jt:se,E=e.rects.popper,w=e.elements[v?h:m],R=Cr(Z(w)?w:w.contextElement||Y(e.elements.popper),a,s,c),x=ne(e.elements.reference),j=Ot({reference:x,element:E,strategy:"absolute",placement:o}),C=Se(Object.assign({},E,j)),A=m===se?C:x,P={top:R.top-A.top+y.top,bottom:A.bottom-R.bottom+y.bottom,left:R.left-A.left+y.left,right:A.right-R.right+y.right},D=e.modifiersData.offset;if(m===se&&D){var L=D[o];Object.keys(P).forEach(function(T){var $=[H,W].indexOf(T)>=0?1:-1,S=[B,W].indexOf(T)>=0?"y":"x";P[T]+=L[S]*$})}return P}function Ar(e,t){t===void 0&&(t={});var r=t,n=r.placement,o=r.boundary,i=r.rootBoundary,c=r.padding,u=r.flipVariations,a=r.allowedAutoPlacements,f=a===void 0?mt:a,s=oe(n),d=s?u?et:et.filter(function(v){return oe(v)===s}):de,m=d.filter(function(v){return f.indexOf(v)>=0});m.length===0&&(m=d);var p=m.reduce(function(v,g){return v[g]=pe(e,{placement:g,boundary:o,rootBoundary:i,padding:c})[I(g)],v},{});return Object.keys(p).sort(function(v,g){return p[v]-p[g]})}function Dr(e){if(I(e)===$e)return[];var t=xe(e);return[nt(e),t,nt(t)]}function Tr(e){var t=e.state,r=e.options,n=e.name;if(!t.modifiersData[n]._skip){for(var o=r.mainAxis,i=o===void 0?!0:o,c=r.altAxis,u=c===void 0?!0:c,a=r.fallbackPlacements,f=r.padding,s=r.boundary,d=r.rootBoundary,m=r.altBoundary,p=r.flipVariations,v=p===void 0?!0:p,g=r.allowedAutoPlacements,l=t.options.placement,y=I(l),h=y===l,E=a||(h||!v?[xe(l)]:Dr(l)),w=[l].concat(E).reduce(function(ee,q){return ee.concat(I(q)===$e?Ar(t,{placement:q,boundary:s,rootBoundary:d,padding:f,flipVariations:v,allowedAutoPlacements:g}):q)},[]),R=t.rects.reference,x=t.rects.popper,j=new Map,C=!0,A=w[0],P=0;P<w.length;P++){var D=w[P],L=I(D),T=oe(D)===te,$=[B,W].indexOf(L)>=0,S=$?"width":"height",N=pe(t,{placement:D,boundary:s,rootBoundary:d,altBoundary:m,padding:f}),_=$?T?H:k:T?W:B;R[S]>x[S]&&(_=xe(_));var me=xe(_),K=[];if(i&&K.push(N[L]<=0),u&&K.push(N[_]<=0,N[me]<=0),K.every(function(ee){return ee})){A=D,C=!1;break}j.set(D,K)}if(C)for(var he=v?3:1,je=function(q){var ae=w.find(function(ye){var G=j.get(ye);if(G)return G.slice(0,q).every(function(Pe){return Pe})});if(ae)return A=ae,"break"},ie=he;ie>0;ie--){var ge=je(ie);if(ge==="break")break}t.placement!==A&&(t.modifiersData[n]._skip=!0,t.placement=A,t.reset=!0)}}const Mr={name:"flip",enabled:!0,phase:"main",fn:Tr,requiresIfExists:["offset"],data:{_skip:!1}};function it(e,t,r){return r===void 0&&(r={x:0,y:0}),{top:e.top-t.height-r.y,right:e.right-t.width+r.x,bottom:e.bottom-t.height+r.y,left:e.left-t.width-r.x}}function at(e){return[B,H,W,k].some(function(t){return e[t]>=0})}function Sr(e){var t=e.state,r=e.name,n=t.rects.reference,o=t.rects.popper,i=t.modifiersData.preventOverflow,c=pe(t,{elementContext:"reference"}),u=pe(t,{altBoundary:!0}),a=it(c,n),f=it(u,o,i),s=at(a),d=at(f);t.modifiersData[r]={referenceClippingOffsets:a,popperEscapeOffsets:f,isReferenceHidden:s,hasPopperEscaped:d},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":s,"data-popper-escaped":d})}const $r={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:Sr};function Br(e,t,r){var n=I(e),o=[k,B].indexOf(n)>=0?-1:1,i=typeof r=="function"?r(Object.assign({},t,{placement:e})):r,c=i[0],u=i[1];return c=c||0,u=(u||0)*o,[k,H].indexOf(n)>=0?{x:u,y:c}:{x:c,y:u}}function kr(e){var t=e.state,r=e.options,n=e.name,o=r.offset,i=o===void 0?[0,0]:o,c=mt.reduce(function(s,d){return s[d]=Br(d,t.rects,i),s},{}),u=c[t.placement],a=u.x,f=u.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=a,t.modifiersData.popperOffsets.y+=f),t.modifiersData[n]=c}const Lr={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:kr};function Nr(e){var t=e.state,r=e.name;t.modifiersData[r]=Ot({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const Fr={name:"popperOffsets",enabled:!0,phase:"read",fn:Nr,data:{}};function Wr(e){return e==="x"?"y":"x"}function Hr(e){var t=e.state,r=e.options,n=e.name,o=r.mainAxis,i=o===void 0?!0:o,c=r.altAxis,u=c===void 0?!1:c,a=r.boundary,f=r.rootBoundary,s=r.altBoundary,d=r.padding,m=r.tether,p=m===void 0?!0:m,v=r.tetherOffset,g=v===void 0?0:v,l=pe(t,{boundary:a,rootBoundary:f,padding:d,altBoundary:s}),y=I(t.placement),h=oe(t.placement),E=!h,w=Le(y),R=Wr(w),x=t.modifiersData.popperOffsets,j=t.rects.reference,C=t.rects.popper,A=typeof g=="function"?g(Object.assign({},t.rects,{placement:t.placement})):g,P=typeof A=="number"?{mainAxis:A,altAxis:A}:Object.assign({mainAxis:0,altAxis:0},A),D=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,L={x:0,y:0};if(x){if(i){var T,$=w==="y"?B:k,S=w==="y"?W:H,N=w==="y"?"height":"width",_=x[w],me=_+l[$],K=_-l[S],he=p?-C[N]/2:0,je=h===te?j[N]:C[N],ie=h===te?-C[N]:-j[N],ge=t.elements.arrow,ee=p&&ge?ke(ge):{width:0,height:0},q=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:yt(),ae=q[$],ye=q[S],G=ce(0,j[N],ee[N]),Pe=E?j[N]/2-he-G-ae-P.mainAxis:je-G-ae-P.mainAxis,Nt=E?-j[N]/2+he+G+ye+P.mainAxis:ie+G+ye+P.mainAxis,Ce=t.elements.arrow&&ve(t.elements.arrow),Ft=Ce?w==="y"?Ce.clientTop||0:Ce.clientLeft||0:0,Ie=(T=D==null?void 0:D[w])!=null?T:0,Wt=_+Pe-Ie-Ft,Ht=_+Nt-Ie,Ue=ce(p?Ee(me,Wt):me,_,p?Q(K,Ht):K);x[w]=Ue,L[w]=Ue-_}if(u){var Ve,_t=w==="x"?B:k,It=w==="x"?W:H,J=x[R],we=R==="y"?"height":"width",qe=J+l[_t],ze=J-l[It],Ae=[B,k].indexOf(y)!==-1,Xe=(Ve=D==null?void 0:D[R])!=null?Ve:0,Ye=Ae?qe:J-j[we]-C[we]-Xe+P.altAxis,Ke=Ae?J+j[we]+C[we]-Xe-P.altAxis:ze,Ge=p&&Ae?fr(Ye,J,Ke):ce(p?Ye:qe,J,p?Ke:ze);x[R]=Ge,L[R]=Ge-J}t.modifiersData[n]=L}}const _r={name:"preventOverflow",enabled:!0,phase:"main",fn:Hr,requiresIfExists:["offset"]};function Ir(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function Ur(e){return e===F(e)||!U(e)?Ne(e):Ir(e)}function Vr(e){var t=e.getBoundingClientRect(),r=re(t.width)/e.offsetWidth||1,n=re(t.height)/e.offsetHeight||1;return r!==1||n!==1}function qr(e,t,r){r===void 0&&(r=!1);var n=U(t),o=U(t)&&Vr(t),i=Y(t),c=ne(e,o,r),u={scrollLeft:0,scrollTop:0},a={x:0,y:0};return(n||!n&&!r)&&((X(t)!=="body"||We(i))&&(u=Ur(t)),U(t)?(a=ne(t,!0),a.x+=t.clientLeft,a.y+=t.clientTop):i&&(a.x=Fe(i))),{x:c.left+u.scrollLeft-a.x,y:c.top+u.scrollTop-a.y,width:c.width,height:c.height}}function zr(e){var t=new Map,r=new Set,n=[];e.forEach(function(i){t.set(i.name,i)});function o(i){r.add(i.name);var c=[].concat(i.requires||[],i.requiresIfExists||[]);c.forEach(function(u){if(!r.has(u)){var a=t.get(u);a&&o(a)}}),n.push(i)}return e.forEach(function(i){r.has(i.name)||o(i)}),n}function Xr(e){var t=zr(e);return sr.reduce(function(r,n){return r.concat(t.filter(function(o){return o.phase===n}))},[])}function Yr(e){var t;return function(){return t||(t=new Promise(function(r){Promise.resolve().then(function(){t=void 0,r(e())})})),t}}function Kr(e){var t=e.reduce(function(r,n){var o=r[n.name];return r[n.name]=o?Object.assign({},o,n,{options:Object.assign({},o.options,n.options),data:Object.assign({},o.data,n.data)}):n,r},{});return Object.keys(t).map(function(r){return t[r]})}var st={placement:"bottom",modifiers:[],strategy:"absolute"};function ut(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return!t.some(function(n){return!(n&&typeof n.getBoundingClientRect=="function")})}function Gr(e){e===void 0&&(e={});var t=e,r=t.defaultModifiers,n=r===void 0?[]:r,o=t.defaultOptions,i=o===void 0?st:o;return function(u,a,f){f===void 0&&(f=i);var s={placement:"bottom",orderedModifiers:[],options:Object.assign({},st,i),modifiersData:{},elements:{reference:u,popper:a},attributes:{},styles:{}},d=[],m=!1,p={state:s,setOptions:function(y){var h=typeof y=="function"?y(s.options):y;g(),s.options=Object.assign({},i,s.options,h),s.scrollParents={reference:Z(u)?fe(u):u.contextElement?fe(u.contextElement):[],popper:fe(a)};var E=Xr(Kr([].concat(n,s.options.modifiers)));return s.orderedModifiers=E.filter(function(w){return w.enabled}),v(),p.update()},forceUpdate:function(){if(!m){var y=s.elements,h=y.reference,E=y.popper;if(ut(h,E)){s.rects={reference:qr(h,ve(E),s.options.strategy==="fixed"),popper:ke(E)},s.reset=!1,s.placement=s.options.placement,s.orderedModifiers.forEach(function(P){return s.modifiersData[P.name]=Object.assign({},P.data)});for(var w=0;w<s.orderedModifiers.length;w++){if(s.reset===!0){s.reset=!1,w=-1;continue}var R=s.orderedModifiers[w],x=R.fn,j=R.options,C=j===void 0?{}:j,A=R.name;typeof x=="function"&&(s=x({state:s,options:C,name:A,instance:p})||s)}}}},update:Yr(function(){return new Promise(function(l){p.forceUpdate(),l(s)})}),destroy:function(){g(),m=!0}};if(!ut(u,a))return p;p.setOptions(f).then(function(l){!m&&f.onFirstUpdate&&f.onFirstUpdate(l)});function v(){s.orderedModifiers.forEach(function(l){var y=l.name,h=l.options,E=h===void 0?{}:h,w=l.effect;if(typeof w=="function"){var R=w({state:s,name:y,instance:p,options:E}),x=function(){};d.push(R||x)}})}function g(){d.forEach(function(l){return l()}),d=[]}return p}}const Jr=Gr({defaultModifiers:[$r,Fr,yr,br,Lr,Mr,_r,vr]}),Qr=["enabled","placement","strategy","modifiers"];function Zr(e,t){if(e==null)return{};var r={},n=Object.keys(e),o,i;for(i=0;i<n.length;i++)o=n[i],!(t.indexOf(o)>=0)&&(r[o]=e[o]);return r}const en={name:"applyStyles",enabled:!1,phase:"afterWrite",fn:()=>{}},tn={name:"ariaDescribedBy",enabled:!0,phase:"afterWrite",effect:({state:e})=>()=>{const{reference:t,popper:r}=e.elements;if("removeAttribute"in t){const n=(t.getAttribute("aria-describedby")||"").split(",").filter(o=>o.trim()!==r.id);n.length?t.setAttribute("aria-describedby",n.join(",")):t.removeAttribute("aria-describedby")}},fn:({state:e})=>{var t;const{popper:r,reference:n}=e.elements,o=(t=r.getAttribute("role"))==null?void 0:t.toLowerCase();if(r.id&&o==="tooltip"&&"setAttribute"in n){const i=n.getAttribute("aria-describedby");if(i&&i.split(",").indexOf(r.id)!==-1)return;n.setAttribute("aria-describedby",i?`${i},${r.id}`:r.id)}}},rn=[];function Et(e,t,r={}){let{enabled:n=!0,placement:o="bottom",strategy:i="absolute",modifiers:c=rn}=r,u=Zr(r,Qr);const a=O.useRef(c),f=O.useRef(),s=O.useCallback(()=>{var l;(l=f.current)==null||l.update()},[]),d=O.useCallback(()=>{var l;(l=f.current)==null||l.forceUpdate()},[]),[m,p]=Kt(O.useState({placement:o,update:s,forceUpdate:d,attributes:{},styles:{popper:{},arrow:{}}})),v=O.useMemo(()=>({name:"updateStateModifier",enabled:!0,phase:"write",requires:["computeStyles"],fn:({state:l})=>{const y={},h={};Object.keys(l.elements).forEach(E=>{y[E]=l.styles[E],h[E]=l.attributes[E]}),p({state:l,styles:y,attributes:h,update:s,forceUpdate:d,placement:l.placement})}}),[s,d,p]),g=O.useMemo(()=>(ue(a.current,c)||(a.current=c),a.current),[c]);return O.useEffect(()=>{!f.current||!n||f.current.setOptions({placement:o,strategy:i,modifiers:[...g,v,en]})},[i,o,v,n,g]),O.useEffect(()=>{if(!(!n||e==null||t==null))return f.current=Jr(e,t,Object.assign({},u,{placement:o,strategy:i,modifiers:[...g,tn,v]})),()=>{f.current!=null&&(f.current.destroy(),f.current=void 0,p(l=>Object.assign({},l,{attributes:{},styles:{popper:{}}})))}},[n,e,t]),m}var nn=process.env.NODE_ENV!=="production",Rt=function(){};if(nn){var on=function(t,r){var n=arguments.length;r=new Array(n>1?n-1:0);for(var o=1;o<n;o++)r[o-1]=arguments[o];var i=0,c="Warning: "+t.replace(/%s/g,function(){return r[i++]});typeof console<"u"&&console.error(c);try{throw new Error(c)}catch{}};Rt=function(e,t,r){var n=arguments.length;r=new Array(n>2?n-2:0);for(var o=2;o<n;o++)r[o-2]=arguments[o];if(t===void 0)throw new Error("`warning(condition, format, ...args)` requires a warning message argument");e||on.apply(null,[t].concat(r))}}var an=Rt;const He=M.getDefaultExportFromCjs(an),ct=()=>{};function sn(e){return e.button===0}function un(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}const Oe=e=>e&&("current"in e?e.current:e),ft={click:"mousedown",mouseup:"mousedown",pointerup:"pointerdown"};function jt(e,t=ct,{disabled:r,clickTrigger:n="click"}={}){const o=O.useRef(!1),i=O.useRef(!1),c=O.useCallback(f=>{const s=Oe(e);He(!!s,"ClickOutside captured a close event but does not have a ref to compare it to. useClickOutside(), should be passed a ref that resolves to a DOM node"),o.current=!s||un(f)||!sn(f)||!!b.contains(s,f.target)||i.current,i.current=!1},[e]),u=b.useEventCallback(f=>{const s=Oe(e);s&&b.contains(s,f.target)&&(i.current=!0)}),a=b.useEventCallback(f=>{o.current||t(f)});O.useEffect(()=>{var f,s;if(r||e==null)return;const d=b.ownerDocument(Oe(e)),m=d.defaultView||window;let p=(f=m.event)!=null?f:(s=m.parent)==null?void 0:s.event,v=null;ft[n]&&(v=b.listen(d,ft[n],u,!0));const g=b.listen(d,n,c,!0),l=b.listen(d,n,h=>{if(h===p){p=void 0;return}a(h)});let y=[];return"ontouchstart"in d.documentElement&&(y=[].slice.call(d.body.children).map(h=>b.listen(h,"mousemove",ct))),()=>{v==null||v(),g(),l(),y.forEach(h=>h())}},[e,r,n,c,u,a])}function cn(e){const t={};return Array.isArray(e)?(e==null||e.forEach(r=>{t[r.name]=r}),t):e||t}function fn(e={}){return Array.isArray(e)?e:Object.keys(e).map(t=>(e[t].name=t,e[t]))}function Pt({enabled:e,enableEvents:t,placement:r,flip:n,offset:o,fixed:i,containerPadding:c,arrowElement:u,popperConfig:a={}}){var f,s,d,m,p;const v=cn(a.modifiers);return Object.assign({},a,{placement:r,enabled:e,strategy:i?"fixed":a.strategy,modifiers:fn(Object.assign({},v,{eventListeners:{enabled:t,options:(f=v.eventListeners)==null?void 0:f.options},preventOverflow:Object.assign({},v.preventOverflow,{options:c?Object.assign({padding:c},(s=v.preventOverflow)==null?void 0:s.options):(d=v.preventOverflow)==null?void 0:d.options}),offset:{options:Object.assign({offset:o},(m=v.offset)==null?void 0:m.options)},arrow:Object.assign({},v.arrow,{enabled:!!u,options:Object.assign({},(p=v.arrow)==null?void 0:p.options,{element:u})}),flip:Object.assign({enabled:!!n},v.flip)}))})}const ln=()=>{};function pn(e,t,{disabled:r,clickTrigger:n}={}){const o=t||ln;jt(e,o,{disabled:r,clickTrigger:n});const i=b.useEventCallback(c=>{b.isEscKey(c)&&o(c)});O.useEffect(()=>{if(r||e==null)return;const c=b.ownerDocument(Oe(e));let u=(c.defaultView||window).event;const a=b.listen(c,"keyup",f=>{if(f===u){u=void 0;return}i(f)});return()=>{a()}},[e,r,i])}const Ct=z.forwardRef((e,t)=>{const{flip:r,offset:n,placement:o,containerPadding:i,popperConfig:c={},transition:u,runTransition:a}=e,[f,s]=b.useCallbackRef(),[d,m]=b.useCallbackRef(),p=b.useMergedRefs(s,t),v=b.useWaitForDOMRef(e.container),g=b.useWaitForDOMRef(e.target),[l,y]=O.useState(!e.show),h=Et(g,f,Pt({placement:o,enableEvents:!!e.show,containerPadding:i||5,flip:r,offset:n,arrowElement:d,popperConfig:c}));e.show&&l&&y(!1);const E=(...D)=>{y(!0),e.onExited&&e.onExited(...D)},w=e.show||!l;if(pn(f,e.onHide,{disabled:!e.rootClose||e.rootCloseDisabled,clickTrigger:e.rootCloseEvent}),!w)return null;const{onExit:R,onExiting:x,onEnter:j,onEntering:C,onEntered:A}=e;let P=e.children(Object.assign({},h.attributes.popper,{style:h.styles.popper,ref:p}),{popper:h,placement:o,show:!!e.show,arrowProps:Object.assign({},h.attributes.arrow,{style:h.styles.arrow,ref:m})});return P=b.renderTransition(u,a,{in:!!e.show,appear:!0,mountOnEnter:!0,unmountOnExit:!0,children:P,onExit:R,onExiting:x,onExited:E,onEnter:j,onEntering:C,onEntered:A}),v?Ut.createPortal(P,v):null});Ct.displayName="Overlay";const dn=Ct,At=z.forwardRef(({className:e,bsPrefix:t,as:r="div",...n},o)=>(t=b.useBootstrapPrefix(t,"popover-header"),M.jsxRuntimeExports.jsx(r,{ref:o,className:M.classNames(e,t),...n})));At.displayName="PopoverHeader";const vn=At,Dt=z.forwardRef(({className:e,bsPrefix:t,as:r="div",...n},o)=>(t=b.useBootstrapPrefix(t,"popover-body"),M.jsxRuntimeExports.jsx(r,{ref:o,className:M.classNames(e,t),...n})));Dt.displayName="PopoverBody";const Tt=Dt;function Mt(e,t){let r=e;return e==="left"?r=t?"end":"start":e==="right"&&(r=t?"start":"end"),r}function St(e="absolute"){return{position:e,top:"0",left:"0",opacity:"0",pointerEvents:"none"}}const mn=z.forwardRef(({bsPrefix:e,placement:t="right",className:r,style:n,children:o,body:i,arrowProps:c,hasDoneInitialMeasure:u,popper:a,show:f,...s},d)=>{const m=b.useBootstrapPrefix(e,"popover"),p=b.useIsRTL(),[v]=(t==null?void 0:t.split("-"))||[],g=Mt(v,p);let l=n;return f&&!u&&(l={...n,...St(a==null?void 0:a.strategy)}),M.jsxRuntimeExports.jsxs("div",{ref:d,role:"tooltip",style:l,"x-placement":v,className:M.classNames(r,m,v&&`bs-popover-${g}`),...s,children:[M.jsxRuntimeExports.jsx("div",{className:"popover-arrow",...c}),i?M.jsxRuntimeExports.jsx(Tt,{children:o}):o]})}),$t=Object.assign(mn,{Header:vn,Body:Tt,POPPER_OFFSET:[0,8]}),Bt=z.forwardRef(({bsPrefix:e,placement:t="right",className:r,style:n,children:o,arrowProps:i,hasDoneInitialMeasure:c,popper:u,show:a,...f},s)=>{e=b.useBootstrapPrefix(e,"tooltip");const d=b.useIsRTL(),[m]=(t==null?void 0:t.split("-"))||[],p=Mt(m,d);let v=n;return a&&!c&&(v={...n,...St(u==null?void 0:u.strategy)}),M.jsxRuntimeExports.jsxs("div",{ref:s,style:v,role:"tooltip","x-placement":m,className:M.classNames(r,e,`bs-tooltip-${p}`),...f,children:[M.jsxRuntimeExports.jsx("div",{className:"tooltip-arrow",...i}),M.jsxRuntimeExports.jsx("div",{className:`${e}-inner`,children:o})]})});Bt.displayName="Tooltip";const _e=Object.assign(Bt,{TOOLTIP_OFFSET:[0,6]});function hn(e){const t=O.useRef(null),r=b.useBootstrapPrefix(void 0,"popover"),n=b.useBootstrapPrefix(void 0,"tooltip"),o=O.useMemo(()=>({name:"offset",options:{offset:()=>{if(e)return e;if(t.current){if(b.hasClass(t.current,r))return $t.POPPER_OFFSET;if(b.hasClass(t.current,n))return _e.TOOLTIP_OFFSET}return[0,0]}}}),[e,r,n]);return[t,[o]]}function gn(e,t){const{ref:r}=e,{ref:n}=t;e.ref=r.__wrapped||(r.__wrapped=o=>r(b.safeFindDOMNode(o))),t.ref=n.__wrapped||(n.__wrapped=o=>n(b.safeFindDOMNode(o)))}const kt=z.forwardRef(({children:e,transition:t=b.Fade,popperConfig:r={},rootClose:n=!1,placement:o="top",show:i=!1,...c},u)=>{const a=O.useRef({}),[f,s]=O.useState(null),[d,m]=hn(c.offset),p=b.useMergedRefs(u,d),v=t===!0?b.Fade:t||void 0,g=b.useEventCallback(l=>{s(l),r==null||r.onFirstUpdate==null||r.onFirstUpdate(l)});return b.useIsomorphicEffect(()=>{f&&c.target&&(a.current.scheduleUpdate==null||a.current.scheduleUpdate())},[f,c.target]),O.useEffect(()=>{i||s(null)},[i]),M.jsxRuntimeExports.jsx(dn,{...c,ref:p,popperConfig:{...r,modifiers:m.concat(r.modifiers||[]),onFirstUpdate:g},transition:v,rootClose:n,placement:o,show:i,children:(l,{arrowProps:y,popper:h,show:E})=>{var w,R;gn(l,y);const x=h==null?void 0:h.placement,j=Object.assign(a.current,{state:h==null?void 0:h.state,scheduleUpdate:h==null?void 0:h.update,placement:x,outOfBoundaries:(h==null||(w=h.state)==null||(R=w.modifiersData.hide)==null?void 0:R.isReferenceHidden)||!1,strategy:r.strategy}),C=!!f;return typeof e=="function"?e({...l,placement:x,show:E,...!t&&E&&{className:"show"},popper:j,arrowProps:y,hasDoneInitialMeasure:C}):z.cloneElement(e,{...l,placement:x,arrowProps:y,popper:j,hasDoneInitialMeasure:C,className:M.classNames(e.props.className,!t&&E&&"show"),style:{...e.props.style,...l.style}})}})});kt.displayName="Overlay";const yn=kt;function wn(e){return e&&typeof e=="object"?e:{show:e,hide:e}}function lt(e,t,r){const[n]=t,o=n.currentTarget,i=n.relatedTarget||n.nativeEvent[r];(!i||i!==o)&&!b.contains(o,i)&&e(...t)}b.PropTypes.oneOf(["click","hover","focus"]);const bn=({trigger:e=["hover","focus"],overlay:t,children:r,popperConfig:n={},show:o,defaultShow:i=!1,onToggle:c,delay:u,placement:a,flip:f=a&&a.indexOf("auto")!==-1,...s})=>{const d=O.useRef(null),m=b.useMergedRefs(d,r.ref),p=Yt(),v=O.useRef(""),[g,l]=pt(o,i,c),y=wn(u),{onFocus:h,onBlur:E,onClick:w}=typeof r!="function"?z.Children.only(r).props:{},R=S=>{m(b.safeFindDOMNode(S))},x=O.useCallback(()=>{if(p.clear(),v.current="show",!y.show){l(!0);return}p.set(()=>{v.current==="show"&&l(!0)},y.show)},[y.show,l,p]),j=O.useCallback(()=>{if(p.clear(),v.current="hide",!y.hide){l(!1);return}p.set(()=>{v.current==="hide"&&l(!1)},y.hide)},[y.hide,l,p]),C=O.useCallback((...S)=>{x(),h==null||h(...S)},[x,h]),A=O.useCallback((...S)=>{j(),E==null||E(...S)},[j,E]),P=O.useCallback((...S)=>{l(!g),w==null||w(...S)},[w,l,g]),D=O.useCallback((...S)=>{lt(x,S,"fromElement")},[x]),L=O.useCallback((...S)=>{lt(j,S,"toElement")},[j]),T=e==null?[]:[].concat(e),$={ref:R};return T.indexOf("click")!==-1&&($.onClick=P),T.indexOf("focus")!==-1&&($.onFocus=C,$.onBlur=A),T.indexOf("hover")!==-1&&(process.env.NODE_ENV!=="production"&&He(T.length>1,'[react-bootstrap] Specifying only the `"hover"` trigger limits the visibility of the overlay to just mouse users. Consider also including the `"focus"` trigger so that touch and keyboard only users can see the overlay as well.'),$.onMouseOver=D,$.onMouseOut=L),M.jsxRuntimeExports.jsxs(M.jsxRuntimeExports.Fragment,{children:[typeof r=="function"?r($):O.cloneElement(r,$),M.jsxRuntimeExports.jsx(yn,{...s,show:g,onHide:j,flip:f,placement:a,popperConfig:n,target:d.current,children:t})]})},Lt=bn,xn=({text:e,placement:t,children:r})=>M.jsxRuntimeExports.jsx(Lt,{placement:t,overlay:M.jsxRuntimeExports.jsx(_e,{className:"luminus-tooltip",children:e}),children:r});exports.OverlayTrigger=Lt;exports.Popover=$t;exports.SimpleTooltip=xn;exports.Tooltip=_e;exports.mergeOptionsWithPopperConfig=Pt;exports.useClickOutside=jt;exports.usePopper=Et;exports.useUncontrolled=Xt;exports.warning=He;
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
const n = (r) => r == null ? !0 : !(typeof r == "object" || typeof r == "function"), i = (r) => {
|
|
2
|
-
n(r) || Object.keys(r).forEach((s) => {
|
|
3
|
-
const t = r[s];
|
|
4
|
-
if (n(t))
|
|
5
|
-
return;
|
|
6
|
-
const e = Object.keys(t);
|
|
7
|
-
e.includes("id") && e.length === 1 && t.id === null ? r[s] = null : i(t);
|
|
8
|
-
});
|
|
9
|
-
}, a = (r) => {
|
|
10
|
-
var t;
|
|
11
|
-
const s = (t = r.response) == null ? void 0 : t.data;
|
|
12
|
-
return s && s.errorFields && s.errorFields.length > 0 ? s.errorFields.map((e) => ({
|
|
13
|
-
name: e.name.split(".").map((o) => `${o.charAt(0).toLowerCase()}${o.slice(1)}`).join("."),
|
|
14
|
-
errors: e.errors
|
|
15
|
-
})) : [];
|
|
16
|
-
}, l = (r, s) => {
|
|
17
|
-
a(s).forEach((e) => {
|
|
18
|
-
r.setError(e.name, { message: e.errors, type: "server" }, { shouldFocus: !0 }), n(r.getValues(e.name)) || r.setError(`${e.name}.id`, { message: e.errors, type: "server" }, { shouldFocus: !0 });
|
|
19
|
-
});
|
|
20
|
-
}, c = (r) => r.length < 300 ? r : r.substring(0, 300) + "...";
|
|
21
|
-
export {
|
|
22
|
-
a as e,
|
|
23
|
-
i as f,
|
|
24
|
-
l as h,
|
|
25
|
-
n as i,
|
|
26
|
-
c as t
|
|
27
|
-
};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";const o=r=>r==null?!0:!(typeof r=="object"||typeof r=="function"),i=r=>{o(r)||Object.keys(r).forEach(s=>{const t=r[s];if(o(t))return;const e=Object.keys(t);e.includes("id")&&e.length===1&&t.id===null?r[s]=null:i(t)})},u=r=>{var t;const s=(t=r.response)==null?void 0:t.data;return s&&s.errorFields&&s.errorFields.length>0?s.errorFields.map(e=>({name:e.name.split(".").map(n=>`${n.charAt(0).toLowerCase()}${n.slice(1)}`).join("."),errors:e.errors})):[]},a=(r,s)=>{u(s).forEach(e=>{r.setError(e.name,{message:e.errors,type:"server"},{shouldFocus:!0}),o(r.getValues(e.name))||r.setError(`${e.name}.id`,{message:e.errors,type:"server"},{shouldFocus:!0})})},c=r=>r.length<300?r:r.substring(0,300)+"...";exports.extractErrorsFromResponse=u;exports.fixNameIdNulls=i;exports.hookFormSetServerErrors=a;exports.isPrimitive=o;exports.truncateText=c;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";const m=require("./SimplePicker.module-De0azFIA.js"),C=require("react");let n;const f=()=>{const{show:e,text:r,showConfirm:t,hideConfirm:s}=C.useContext(m.ConfirmContext),o=()=>{s()};return{confirm:async c=>(t(c),new Promise(i=>{n=i})),onConfirm:()=>{o(),n(!0)},onCancel:()=>{o(),n(!1)},show:e,text:r}};exports.useConfirm=f;
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|