unis_crm/frontend/node_modules/framer-motion/dist/size-rollup-dom-animation-a...

2 lines
30 KiB
JavaScript
Raw Normal View History

2026-03-19 06:27:20 +00:00
const t=(t,e,s)=>s>e?e:s<t?t:s;function e(t,e){return e?`${t}. For more information and steps for solving, visit https://motion.dev/troubleshooting/${e}`:t}let s=()=>{},n=()=>{};"undefined"!=typeof process&&"production"!==process.env?.NODE_ENV&&(s=(t,s,n)=>{t||"undefined"==typeof console||console.warn(e(s,n))},n=(t,s,n)=>{if(!t)throw new Error(e(s,n))});const i={},r=t=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(t),a=t=>/^0[^.\s]+$/u.test(t);function o(t){let e;return()=>(void 0===e&&(e=t()),e)}const h=t=>t;class l{constructor(){this.subscriptions=[]}add(t){var e,s;return e=this.subscriptions,s=t,-1===e.indexOf(s)&&e.push(s),()=>function(t,e){const s=t.indexOf(e);s>-1&&t.splice(s,1)}(this.subscriptions,t)}notify(t,e,s){const n=this.subscriptions.length;if(n)if(1===n)this.subscriptions[0](t,e,s);else for(let i=0;i<n;i++){const n=this.subscriptions[i];n&&n(t,e,s)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const u=t=>1e3*t,c=t=>t/1e3;function d(t,e){return e?t*(1e3/e):0}const p=t=>Array.isArray(t)&&"number"==typeof t[0],f=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function m(t,e){let s=!1,n=!0;const r={delta:0,timestamp:0,isProcessing:!1},a=()=>s=!0,o=f.reduce((t,e)=>(t[e]=function(t){let e=new Set,s=new Set,n=!1,i=!1;const r=new WeakSet;let a={delta:0,timestamp:0,isProcessing:!1};function o(e){r.has(e)&&(h.schedule(e),t()),e(a)}const h={schedule:(t,i=!1,a=!1)=>{const o=a&&n?e:s;return i&&r.add(t),o.add(t),t},cancel:t=>{s.delete(t),r.delete(t)},process:t=>{if(a=t,n)return void(i=!0);n=!0;const r=e;e=s,s=r,e.forEach(o),e.clear(),n=!1,i&&(i=!1,h.process(t))}};return h}(a),t),{}),{setup:h,read:l,resolveKeyframes:u,preUpdate:c,update:d,preRender:p,render:m,postRender:g}=o,v=()=>{const a=i.useManualTiming,o=a?r.timestamp:performance.now();s=!1,a||(r.delta=n?1e3/60:Math.max(Math.min(o-r.timestamp,40),1)),r.timestamp=o,r.isProcessing=!0,h.process(r),l.process(r),u.process(r),c.process(r),d.process(r),p.process(r),m.process(r),g.process(r),r.isProcessing=!1,s&&e&&(n=!1,t(v))};return{schedule:f.reduce((e,i)=>{const a=o[i];return e[i]=(e,i=!1,o=!1)=>(s||(s=!0,n=!0,r.isProcessing||t(v)),a.schedule(e,i,o)),e},{}),cancel:t=>{for(let e=0;e<f.length;e++)o[f[e]].cancel(t)},state:r,steps:o}}const{schedule:g,cancel:v,state:y}=m("undefined"!=typeof requestAnimationFrame?requestAnimationFrame:h,!0);let b;function w(){b=void 0}const V={now:()=>(void 0===b&&V.set(y.isProcessing||i.useManualTiming?y.timestamp:performance.now()),b),set:t=>{b=t,queueMicrotask(w)}},S=t=>e=>"string"==typeof e&&e.startsWith(t),M=S("--"),T=S("var(--"),A=t=>!!T(t)&&x.test(t.split("/*")[0].trim()),x=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function C(t){return"string"==typeof t&&t.split("/*")[0].includes("var(--")}const k={test:t=>"number"==typeof t,parse:parseFloat,transform:t=>t},F={...k,transform:e=>t(0,1,e)},E={...k,default:1},B=t=>Math.round(1e5*t)/1e5,P=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;const R=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,I=(t,e)=>s=>Boolean("string"==typeof s&&R.test(s)&&s.startsWith(t)||e&&!function(t){return null==t}(s)&&Object.prototype.hasOwnProperty.call(s,e)),N=(t,e,s)=>n=>{if("string"!=typeof n)return n;const[i,r,a,o]=n.match(P);return{[t]:parseFloat(i),[e]:parseFloat(r),[s]:parseFloat(a),alpha:void 0!==o?parseFloat(o):1}},O={...k,transform:e=>Math.round((e=>t(0,255,e))(e))},$={test:I("rgb","red"),parse:N("red","green","blue"),transform:({red:t,green:e,blue:s,alpha:n=1})=>"rgba("+O.transform(t)+", "+O.transform(e)+", "+O.transform(s)+", "+B(F.transform(n))+")"};const L={test:I("#"),parse:function(t){let e="",s="",n="",i="";return t.length>5?(e=t.substring(1,3),s=t.substring(3,5),n=t.substring(5,7),i=t.substring(7,9)):(e=t.substring(1,2),s=t.substring(2,3),n=t.substring(3,4),i=t.substring(4,5),e+=e,s+=s,n+=n,i+=i),{red:parseInt(e,16),green:parseInt(s,16),blue:parseInt(n,16),alpha:i?parseInt(i,16)/255:1}},transform:$.transform},Y=t=>({test:e=>"string"==