| Server IP : 85.214.143.32 / Your IP : 216.73.216.142 Web Server : nginx/1.24.0 System : Linux datensicherung.webdress.site 6.8.0-139-generic #139-Ubuntu SMP PREEMPT_DYNAMIC Sat Aug 1 03:52:05 UTC 2026 x86_64 User : www-data ( 33) PHP Version : 7.4.33 Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals,pcntl_unshare, MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /var/www/nextcloud/dist/ |
Upload File : |
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=[window.OC.filePath('', '', 'dist/index-CmQ6RK7u.chunk.mjs'),window.OC.filePath('', '', 'dist/Web-Bpn1hT4U.chunk.mjs'),window.OC.filePath('', '', 'dist/public-C1mLBHT3.chunk.mjs'),window.OC.filePath('', '', 'dist/logger-D3RVzcfQ-B6R2fmjp.chunk.mjs'),window.OC.filePath('', '', 'dist/createElementId-DhjFt1I9-CzYhhUzc.chunk.mjs'),window.OC.filePath('', '', 'dist/translation-DoG5ZELJ-BmllVdG7.chunk.mjs'),window.OC.filePath('', '', 'dist/index-Cp0kcsps.chunk.mjs'),window.OC.filePath('', '', 'dist/common-createElementId-DhjFt1I9-C_oBIsvc.chunk.css'),window.OC.filePath('', '', 'dist/common-logger-D3RVzcfQ-Ks0gkIDB.chunk.css'),window.OC.filePath('', '', 'dist/colors-Cv9F-jWS-3J5iRBdf.chunk.mjs'),window.OC.filePath('', '', 'dist/NcModal-DiDvgcU8-DlAqoAw2.chunk.mjs'),window.OC.filePath('', '', 'dist/common-NcModal-DiDvgcU8-B-yi1OwC.chunk.css'),window.OC.filePath('', '', 'dist/common-index-bfXBK-tQ.chunk.css'),window.OC.filePath('', '', 'dist/index-SqBpzfCA.chunk.mjs'),window.OC.filePath('', '', 'dist/index-B-O3WGfL.chunk.mjs'),window.OC.filePath('', '', 'dist/TrashCanOutline-BTIe_2cO.chunk.mjs'),window.OC.filePath('', '', 'dist/common-TrashCanOutline-BYHcrfvW.chunk.css'),window.OC.filePath('', '', 'dist/common-index-BWhNCeJl.chunk.css'),window.OC.filePath('', '', 'dist/common-index-BnF98eos.chunk.css')])))=>i.map(i=>d[i]);
import{b as R,n as j,o as b,f as I,g,t as S,y as w,m as T,s as Y,v as V,r as k,i as Z,O as L,L as H,h as D,c as x,k as W,w as G,a as N,_ as P}from"./Web-Bpn1hT4U.chunk.mjs";import{r as F,o as J,_ as A,b as z,c as E,p as K}from"./createElementId-DhjFt1I9-CzYhhUzc.chunk.mjs";import{a as X}from"./PencilOutline-BzMMCVP9.chunk.mjs";import{N as Q}from"./NcPasswordField-BFyzHTOO-DLUAy5-a.chunk.mjs";import{_ as tt}from"./NcTextField.vue_vue_type_script_setup_true_lang-Bx2esFU2-LotydYy2.chunk.mjs";import{t as et}from"./index-Cp0kcsps.chunk.mjs";F(J);const it=["for"],st=["id","type","value","min","max"],nt=R({inheritAttrs:!1,__name:"NcDateTimePickerNative",props:Y({class:{default:void 0},id:{default:()=>E()},inputClass:{default:""},type:{default:"date"},label:{default:()=>z("Please choose a date")},min:{default:null},max:{default:null},hideLabel:{type:Boolean}},{modelValue:{default:null},modelModifiers:{}}),emits:["update:modelValue"],setup(a){const e=j(a,"modelValue"),t=a,r=V(()=>e.value?p(e.value):""),d=V(()=>t.max?p(t.max):void 0),o=V(()=>t.min?p(t.min):void 0);function c(s){const i=s.getFullYear().toString().padStart(4,"0"),h=(s.getMonth()+1).toString().padStart(2,"0"),u=s.getDate().toString().padStart(2,"0"),m=s.getHours().toString().padStart(2,"0"),f=s.getMinutes().toString().padStart(2,"0");return{yyyy:i,MM:h,dd:u,hh:m,mm:f}}function p(s){const{yyyy:i,MM:h,dd:u,hh:m,mm:f}=c(s);if(t.type==="datetime-local")return`${i}-${h}-${u}T${m}:${f}`;if(t.type==="date")return`${i}-${h}-${u}`;if(t.type==="month")return`${i}-${h}`;if(t.type==="time")return`${m}:${f}`;if(t.type==="week"){const l=new Date(Number.parseInt(i),0,1),v=Math.floor((s.getTime()-l.getTime())/(1440*60*1e3)),_=Math.ceil(v/7);return`${i}-W${_}`}return""}function n(s){const i=s.target;if(!i||isNaN(i.valueAsNumber))e.value=null;else if(t.type==="time"){const h=i.value,{yyyy:u,MM:m,dd:f}=c(e.value||new Date);e.value=new Date(`${u}-${m}-${f}T${h}`)}else if(t.type==="month"){const h=(new Date(i.value).getMonth()+1).toString().padStart(2,"0"),{yyyy:u,dd:m,hh:f,mm:l}=c(e.value||new Date);e.value=new Date(`${u}-${h}-${m}T${f}:${l}`)}else{const h=new Date(i.valueAsNumber).getTimezoneOffset()*1e3*60,u=i.valueAsNumber+h;e.value=new Date(u)}}return(s,i)=>(b(),I("div",{class:w(["native-datetime-picker",s.$props.class])},[g("label",{class:w(["native-datetime-picker__label",{"hidden-visually":a.hideLabel}]),for:a.id},S(a.label),11,it),g("input",T({id:a.id,class:["native-datetime-picker__input",a.inputClass],type:a.type,value:r.value,min:o.value,max:d.value},s.$attrs,{onInput:n}),null,16,st)],2))}}),at=A(nt,[["__scopeId","data-v-b97e1f7a"]]);F(K);const rt={name:"NcActionInput",components:{NcDateTimePickerNative:at,NcPasswordField:Q,NcTextField:tt,NcColorPicker:N(()=>P(()=>import("./index-CmQ6RK7u.chunk.mjs"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12]),import.meta.url)),NcDateTimePicker:N(()=>P(()=>import("./index-SqBpzfCA.chunk.mjs"),__vite__mapDeps([13,3,1,2,4,5,6,7,8,10,11,14,15,16,17,18]),import.meta.url)),NcSelect:N(()=>P(()=>import("./index-B-O3WGfL.chunk.mjs").then(a=>a.i),__vite__mapDeps([14,1,2,10,3,4,5,6,7,8,11,15,16,17]),import.meta.url))},mixins:[X],inheritAttrs:!1,props:{id:{type:String,default:()=>"action-"+E(),validator:a=>a.trim()!==""},inputId:{type:String,default:()=>"action-input-"+E(),validator:a=>a.trim()!==""},icon:{type:String,default:""},type:{type:String,default:"text",validator(a){return["date","datetime-local","month","multiselect","number","password","search","tel","text","time","url","week","color","email"].includes(a)}},idNativeDateTimePicker:{type:String,default:"date-time-picker_id"},isNativePicker:{type:Boolean,default:!1},label:{type:String,default:null},labelOutside:{type:Boolean,default:!0},modelValue:{type:[String,Date,Number,Array],default:""},disabled:{type:Boolean,default:!1},ariaLabel:{type:String,default:""},showTrailingButton:{type:Boolean,default:!0},trailingButtonLabel:{type:String,default:z("Submit")},class:{type:[String,Array,Object],default:""}},emits:["submit","update:modelValue"],computed:{isIconUrl(){try{return new URL(this.icon)}catch{return!1}},isMultiselectType(){return this.type==="multiselect"},nativeDatePickerType(){switch(this.type){case"date":case"month":case"time":case"week":case"datetime-local":return this.type}return!1},datePickerType(){if(!this.isNativePicker)switch(this.type){case"date":case"month":case"time":return this.type;case"datetime-local":return"datetime"}return!1},isFocusable(){return!this.disabled}},methods:{onLeave(){this.$refs.datetimepicker&&this.$refs.datetimepicker.$refs.datepicker&&this.$refs.datetimepicker.$refs.datepicker.closePopup()},onSubmit(a){if(a.preventDefault(),a.stopPropagation(),!this.disabled)this.$emit("submit",a);else return!1},onUpdateModelValue(a){this.$emit("update:modelValue",a)}}},ot={class:"action-input__icon-wrapper"},lt=["disabled"],ut={class:"action-input__container"},ct=["for"],ht={class:"action-input__input-container"},dt={key:4,class:"action-input__container"},pt=["for"],mt={class:"action-input__input-container"};function ft(a,e,t,r,d,o){const c=k("NcDateTimePicker"),p=k("NcDateTimePickerNative"),n=k("NcSelect"),s=k("NcPasswordField"),i=k("NcColorPicker"),h=k("NcTextField");return b(),I("li",{class:w(["action",[{"action--disabled":t.disabled},a.$props.class]])},[g("span",{class:w(["action-input",{"action-input-picker--disabled":t.disabled,"action-input--visible-label":t.labelOutside&&t.label}]),onMouseleave:e[3]||(e[3]=(...u)=>o.onLeave&&o.onLeave(...u))},[g("span",ot,[Z(a.$slots,"icon",{},()=>[g("span",{"aria-hidden":"true",class:w(["action-input__icon",[o.isIconUrl?"action-input__icon--url":t.icon]]),style:L({backgroundImage:o.isIconUrl?`url(${t.icon})`:null})},null,6)],!0)]),g("form",{ref:"form",class:"action-input__form",disabled:t.disabled,onSubmit:e[2]||(e[2]=H((...u)=>o.onSubmit&&o.onSubmit(...u),["prevent"]))},[g("div",ut,[t.label&&t.labelOutside&&!t.isNativePicker?(b(),I("label",{key:0,class:w(["action-input__text-label",{"action-input__text-label--hidden":!t.labelOutside}]),for:t.inputId},S(t.label),11,ct)):D("",!0),g("div",ht,[o.datePickerType?(b(),x(c,T({key:0,ref:"datetimepicker",modelValue:t.modelValue,style:{"z-index":"99999999999"},placeholder:a.text,disabled:t.disabled,type:o.datePickerType,inputClass:["mx-input",{focusable:o.isFocusable}],class:"action-input__datetimepicker",appendToBody:""},a.$attrs,{"onUpdate:modelValue":o.onUpdateModelValue}),null,16,["modelValue","placeholder","disabled","type","inputClass","onUpdate:modelValue"])):t.isNativePicker?(b(),x(p,T({key:1,id:t.idNativeDateTimePicker,modelValue:t.modelValue,label:t.label,type:o.nativeDatePickerType,inputClass:{focusable:o.isFocusable},class:"action-input__datetimepicker"},a.$attrs,{"onUpdate:modelValue":o.onUpdateModelValue}),null,16,["id","modelValue","label","type","inputClass","onUpdate:modelValue"])):o.isMultiselectType?(b(),x(n,T({key:2,modelValue:t.modelValue,placeholder:a.text,disabled:t.disabled,appendToBody:!1,inputClass:{focusable:o.isFocusable},class:"action-input__multi"},a.$attrs,{"onUpdate:modelValue":o.onUpdateModelValue}),null,16,["modelValue","placeholder","disabled","inputClass","onUpdate:modelValue"])):t.type==="password"?(b(),x(s,T({key:3,id:t.inputId,modelValue:t.modelValue,label:t.label,labelOutside:!t.label||t.labelOutside,placeholder:a.text,disabled:t.disabled,inputClass:{focusable:o.isFocusable},showTrailingButton:t.showTrailingButton&&!t.disabled},a.$attrs,{"onUpdate:modelValue":o.onUpdateModelValue}),null,16,["id","modelValue","label","labelOutside","placeholder","disabled","inputClass","showTrailingButton","onUpdate:modelValue"])):t.type==="color"?(b(),I("div",dt,[t.label&&t.type==="color"?(b(),I("label",{key:0,class:w(["action-input__text-label",{"action-input__text-label--hidden":!t.labelOutside}]),for:t.inputId},S(t.label),11,pt)):D("",!0),g("div",mt,[W(i,T({id:"inputId",modelValue:t.modelValue,class:"colorpicker__trigger"},a.$attrs,{"onUpdate:modelValue":o.onUpdateModelValue,onSubmit:e[0]||(e[0]=u=>a.$refs.form.requestSubmit())}),{default:G(()=>[g("button",{class:w(["colorpicker__preview",{focusable:o.isFocusable}]),style:L({"background-color":t.modelValue})},null,6)]),_:1},16,["modelValue","onUpdate:modelValue"])])])):(b(),x(h,T({key:5,id:t.inputId,modelValue:t.modelValue,label:t.label,labelOutside:!t.label||t.labelOutside,placeholder:a.text,disabled:t.disabled,inputClass:{focusable:o.isFocusable},type:t.type,trailingButtonIcon:"arrowRight",trailingButtonLabel:t.trailingButtonLabel,showTrailingButton:t.showTrailingButton&&!t.disabled},a.$attrs,{onTrailingButtonClick:e[1]||(e[1]=u=>a.$refs.form.requestSubmit()),"onUpdate:modelValue":o.onUpdateModelValue}),null,16,["id","modelValue","label","labelOutside","placeholder","disabled","inputClass","type","trailingButtonLabel","showTrailingButton","onUpdate:modelValue"]))])])],40,lt)],34)],2)}const Nt=A(rt,[["render",ft],["__scopeId","data-v-43230e98"]]);var O={exports:{}},M;function yt(){return M||(M=1,(function(a){var e=Object.prototype.hasOwnProperty,t="~";function r(){}Object.create&&(r.prototype=Object.create(null),new r().__proto__||(t=!1));function d(n,s,i){this.fn=n,this.context=s,this.once=i||!1}function o(n,s,i,h,u){if(typeof i!="function")throw new TypeError("The listener must be a function");var m=new d(i,h||n,u),f=t?t+s:s;return n._events[f]?n._events[f].fn?n._events[f]=[n._events[f],m]:n._events[f].push(m):(n._events[f]=m,n._eventsCount++),n}function c(n,s){--n._eventsCount===0?n._events=new r:delete n._events[s]}function p(){this._events=new r,this._eventsCount=0}p.prototype.eventNames=function(){var n=[],s,i;if(this._eventsCount===0)return n;for(i in s=this._events)e.call(s,i)&&n.push(t?i.slice(1):i);return Object.getOwnPropertySymbols?n.concat(Object.getOwnPropertySymbols(s)):n},p.prototype.listeners=function(n){var s=t?t+n:n,i=this._events[s];if(!i)return[];if(i.fn)return[i.fn];for(var h=0,u=i.length,m=new Array(u);h<u;h++)m[h]=i[h].fn;return m},p.prototype.listenerCount=function(n){var s=t?t+n:n,i=this._events[s];return i?i.fn?1:i.length:0},p.prototype.emit=function(n,s,i,h,u,m){var f=t?t+n:n;if(!this._events[f])return!1;var l=this._events[f],v=arguments.length,_,y;if(l.fn){switch(l.once&&this.removeListener(n,l.fn,void 0,!0),v){case 1:return l.fn.call(l.context),!0;case 2:return l.fn.call(l.context,s),!0;case 3:return l.fn.call(l.context,s,i),!0;case 4:return l.fn.call(l.context,s,i,h),!0;case 5:return l.fn.call(l.context,s,i,h,u),!0;case 6:return l.fn.call(l.context,s,i,h,u,m),!0}for(y=1,_=new Array(v-1);y<v;y++)_[y-1]=arguments[y];l.fn.apply(l.context,_)}else{var q=l.length,$;for(y=0;y<q;y++)switch(l[y].once&&this.removeListener(n,l[y].fn,void 0,!0),v){case 1:l[y].fn.call(l[y].context);break;case 2:l[y].fn.call(l[y].context,s);break;case 3:l[y].fn.call(l[y].context,s,i);break;case 4:l[y].fn.call(l[y].context,s,i,h);break;default:if(!_)for($=1,_=new Array(v-1);$<v;$++)_[$-1]=arguments[$];l[y].fn.apply(l[y].context,_)}}return!0},p.prototype.on=function(n,s,i){return o(this,n,s,i,!1)},p.prototype.once=function(n,s,i){return o(this,n,s,i,!0)},p.prototype.removeListener=function(n,s,i,h){var u=t?t+n:n;if(!this._events[u])return this;if(!s)return c(this,u),this;var m=this._events[u];if(m.fn)m.fn===s&&(!h||m.once)&&(!i||m.context===i)&&c(this,u);else{for(var f=0,l=[],v=m.length;f<v;f++)(m[f].fn!==s||h&&!m[f].once||i&&m[f].context!==i)&&l.push(m[f]);l.length?this._events[u]=l.length===1?l[0]:l:c(this,u)}return this},p.prototype.removeAllListeners=function(n){var s;return n?(s=t?t+n:n,this._events[s]&&c(this,s)):(this._events=new r,this._eventsCount=0),this},p.prototype.off=p.prototype.removeListener,p.prototype.addListener=p.prototype.on,p.prefixed=t,p.EventEmitter=p,a.exports=p})(O)),O.exports}var vt=yt();const bt=et(vt);class C extends Error{name="TimeoutError";constructor(e,t){super(e,t),Error.captureStackTrace?.(this,C)}}const U=a=>a.reason??new DOMException("This operation was aborted.","AbortError");function gt(a,e){const{milliseconds:t,fallback:r,message:d,customTimers:o={setTimeout,clearTimeout},signal:c}=e;let p,n;const s=new Promise((i,h)=>{if(typeof t!="number"||Math.sign(t)!==1)throw new TypeError(`Expected \`milliseconds\` to be a positive number, got \`${t}\``);if(c?.aborted){h(U(c));return}if(c&&(n=()=>{h(U(c))},c.addEventListener("abort",n,{once:!0})),a.then(i,h),t===Number.POSITIVE_INFINITY)return;const u=new C;p=o.setTimeout.call(void 0,()=>{if(r){try{i(r())}catch(m){h(m)}return}typeof a.cancel=="function"&&a.cancel(),d===!1?i():d instanceof Error?h(d):(u.message=d??`Promise timed out after ${t} milliseconds`,h(u))},t)}).finally(()=>{s.clear(),n&&c&&c.removeEventListener("abort",n)});return s.clear=()=>{o.clearTimeout.call(void 0,p),p=void 0},s}function _t(a,e,t){let r=0,d=a.length;for(;d>0;){const o=Math.trunc(d/2);let c=r+o;t(a[c],e)<=0?(r=++c,d-=o+1):d=o}return r}const wt=100;class B{#e=[];#t=0;enqueue(e,t){const{priority:r=0,id:d}=t??{},{size:o}=this,c={priority:r,id:d,run:e};if(o===0){this.#e.length=0,this.#t=0,this.#e.push(c);return}if(this.#e.at(-1).priority>=r){this.#e.push(c);return}this.#a();const p=_t(this.#e,c,(n,s)=>s.priority-n.priority);this.#e.splice(p,0,c)}setPriority(e,t){const r=this.#e.findIndex((o,c)=>c>=this.#t&&o.id===e);if(r===-1)throw new ReferenceError(`No promise function with the id "${e}" exists in the queue.`);const[d]=this.#e.splice(r,1);this.enqueue(d.run,{priority:t,id:e})}remove(e){const t=this.#e.findIndex((r,d)=>d<this.#t?!1:typeof e=="string"?r.id===e:r.run===e);t!==-1&&this.#e.splice(t,1)}dequeue(){if(this.#t===this.#e.length)return;const e=this.#e[this.#t];return this.#t++,this.#t===this.#e.length?(this.#e.length=0,this.#t=0):this.#t>wt&&this.#t>this.#e.length/2&&this.#a(),e?.run}filter(e){const t=[];for(let r=this.#t;r<this.#e.length;r++){const d=this.#e[r];d.priority===e.priority&&t.push(d.run)}return t}get size(){return this.#e.length-this.#t}#a(){this.#t!==0&&(this.#e.splice(0,this.#t),this.#t=0)}}class Pt extends bt{#e;#t;#a=0;#p;#f=!1;#g=!1;#u;#_=0;#l;#c;#o;#r=[];#n=0;#i;#I;#s=0;#y;#h;#C=1n;#v=new Map;#w=new Set;timeout;constructor(e){if(super(),e={carryoverIntervalCount:!1,intervalCap:Number.POSITIVE_INFINITY,interval:0,concurrency:Number.POSITIVE_INFINITY,autoStart:!0,queueClass:B,strict:!1,...e},!(typeof e.intervalCap=="number"&&e.intervalCap>=1))throw new TypeError(`Expected \`intervalCap\` to be a number from 1 and up, got \`${e.intervalCap?.toString()??""}\` (${typeof e.intervalCap})`);if(e.interval===void 0||!(Number.isFinite(e.interval)&&e.interval>=0))throw new TypeError(`Expected \`interval\` to be a finite number >= 0, got \`${e.interval?.toString()??""}\` (${typeof e.interval})`);if(e.strict&&e.interval===0)throw new TypeError("The `strict` option requires a non-zero `interval`");if(e.strict&&e.intervalCap===Number.POSITIVE_INFINITY)throw new TypeError("The `strict` option requires a finite `intervalCap`");if(this.#e=e.carryoverIntervalCount??e.carryoverConcurrencyCount??!1,this.#t=e.intervalCap===Number.POSITIVE_INFINITY||e.interval===0,this.#p=e.intervalCap,this.#u=e.interval,this.#o=e.strict,this.#i=new e.queueClass,this.#I=e.queueClass,this.concurrency=e.concurrency,e.timeout!==void 0&&!(Number.isFinite(e.timeout)&&e.timeout>0))throw new TypeError(`Expected \`timeout\` to be a positive finite number, got \`${e.timeout}\` (${typeof e.timeout})`);this.timeout=e.timeout,this.#h=e.autoStart===!1,this.#A()}#T(e){for(;this.#n<this.#r.length;){const t=this.#r[this.#n];if(t!==void 0&&e-t>=this.#u)this.#n++;else break}(this.#n>100&&this.#n>this.#r.length/2||this.#n===this.#r.length)&&(this.#r=this.#r.slice(this.#n),this.#n=0)}#L(e){this.#o?this.#r.push(e):this.#a++}#D(){this.#o?this.#r.length>this.#n&&this.#r.pop():this.#a>0&&this.#a--}#k(){return this.#r.length-this.#n}get#O(){return this.#t?!0:this.#o?this.#k()<this.#p:this.#a<this.#p}get#M(){return this.#s<this.#y}#U(){this.#s--,this.#s===0&&this.emit("pendingZero"),this.#b(),this.emit("next")}#B(){this.#c=void 0,this.#S(),this.#P()}#F(e){if(this.#o){if(this.#T(e),this.#k()>=this.#p){const t=this.#r[this.#n],r=this.#u-(e-t);return this.#V(r),!0}return!1}if(this.#l===void 0){const t=this.#_-e;if(t<0)this.#a=this.#e?this.#s:0;else return this.#V(t),!0}return!1}#V(e){this.#c===void 0&&(this.#c=setTimeout(()=>{this.#B()},e))}#$(){this.#l&&(clearInterval(this.#l),this.#l=void 0)}#N(){this.#c&&(clearTimeout(this.#c),this.#c=void 0)}#b(){if(this.#i.size===0){if(this.#$(),this.emit("empty"),this.#s===0){if(this.#N(),this.#o&&this.#n>0){const t=Date.now();this.#T(t)}this.emit("idle")}return!1}let e=!1;if(!this.#h){const t=Date.now(),r=!this.#F(t);if(this.#O&&this.#M){const d=this.#i.dequeue();this.#t||(this.#L(t),this.#m()),r&&this.#P(),this.emit("active"),d(),e=!0}}return e}#P(){this.#t||this.#l!==void 0||this.#o||(this.#l=setInterval(()=>{this.#S()},this.#u),this.#_=Date.now()+this.#u)}#S(){this.#o||(this.#l!==void 0&&(this.#a===0&&this.#s===0?this.#$():this.#_=Date.now()+this.#u),this.#a=this.#e?this.#s:0),this.#x(),this.#m()}#x(){for(;this.#b(););}get concurrency(){return this.#y}set concurrency(e){if(!(typeof e=="number"&&e>=1))throw new TypeError(`Expected \`concurrency\` to be a number from 1 and up, got \`${e}\` (${typeof e})`);this.#y=e,this.#x()}setPriority(e,t){if(typeof t!="number"||!Number.isFinite(t))throw new TypeError(`Expected \`priority\` to be a finite number, got \`${t}\` (${typeof t})`);this.#i.setPriority(e,t)}async add(e,t={}){if(t={timeout:this.timeout,...t,id:t.id??(this.#C++).toString()},t.timeout!==void 0&&!(Number.isFinite(t.timeout)&&t.timeout>0))throw new TypeError(`Expected \`timeout\` to be a positive finite number, got \`${t.timeout}\` (${typeof t.timeout})`);return new Promise((r,d)=>{const o=Symbol(`task-${t.id}`);let c=()=>{};const p=async()=>{c(),this.#s++,this.#v.set(o,{id:t.id,priority:t.priority??0,startTime:Date.now(),timeout:t.timeout});let s;try{try{t.signal?.throwIfAborted()}catch(u){throw this.#z(),this.#v.delete(o),u}let i=e({signal:t.signal});if(t.timeout!==void 0&&(i=gt(Promise.resolve(i),{milliseconds:t.timeout,message:`Task timed out after ${t.timeout}ms (queue has ${this.#s} running, ${this.#i.size} waiting)`})),t.signal){const{signal:u}=t;i=Promise.race([i,new Promise((m,f)=>{s=()=>{f(u.reason)},u.addEventListener("abort",s,{once:!0})})])}const h=await i;r(h),this.emit("completed",h)}catch(i){d(i),this.emit("error",i)}finally{s&&t.signal?.removeEventListener("abort",s),this.#v.delete(o),queueMicrotask(()=>{this.#U()})}};this.#i.enqueue(p,t);const n=()=>{if(this.#i instanceof B){this.#i.remove(p);return}this.#i.remove?.(t.id)};if(t.signal){const{signal:s}=t,i=()=>{c(),n(),d(s.reason),this.#b(),this.emit("next")};if(c=()=>{s.removeEventListener("abort",i),this.#w.delete(c)},s.aborted){i();return}s.addEventListener("abort",i,{once:!0}),this.#w.add(c)}this.emit("add"),this.#b()})}async addAll(e,t){return Promise.all(e.map(async r=>this.add(r,t)))}start(){return this.#h?(this.#h=!1,this.#x(),this):this}pause(){this.#h=!0}clear(){for(const e of this.#w)e();this.#i=new this.#I,this.#$(),this.#E(),this.emit("empty"),this.#s===0&&(this.#N(),this.emit("idle")),this.emit("next")}async onEmpty(){this.#i.size!==0&&await this.#d("empty")}async onSizeLessThan(e){this.#i.size<e||await this.#d(["next","active"],()=>this.#i.size<e)}async onIdle(){this.#s===0&&this.#i.size===0||await this.#d("idle")}async onPendingZero(){this.#s!==0&&await this.#d("pendingZero")}async onRateLimit(){this.isRateLimited||await this.#d("rateLimit")}async onRateLimitCleared(){this.isRateLimited&&await this.#d("rateLimitCleared")}onError(){return new Promise((e,t)=>{const r=d=>{this.off("error",r),t(d)};this.on("error",r)})}async#d(e,t){const r=Array.isArray(e)?e:[e];return new Promise(d=>{const o=()=>{if(!(t&&!t())){for(const c of r)this.off(c,o);d()}};for(const c of r)this.on(c,o)})}get size(){return this.#i.size}sizeBy(e){return this.#i.filter(e).length}get pending(){return this.#s}get isPaused(){return this.#h}#A(){this.#t||(this.on("add",()=>{this.#i.size>0&&this.#m()}),this.on("next",()=>{this.#m()}))}#m(){this.#t||this.#g||(this.#g=!0,queueMicrotask(()=>{this.#g=!1,this.#E()}))}#z(){this.#t||(this.#D(),this.#m())}#E(){const e=this.#f;if(this.#t||this.#i.size===0){e&&(this.#f=!1,this.emit("rateLimitCleared"));return}let t;if(this.#o){const d=Date.now();this.#T(d),t=this.#k()}else t=this.#a;const r=t>=this.#p;r!==e&&(this.#f=r,this.emit(r?"rateLimit":"rateLimitCleared"))}get isRateLimited(){return this.#f}get isSaturated(){return this.#s===this.#y&&this.#i.size>0||this.isRateLimited&&this.#i.size>0}get runningTasks(){return[...this.#v.values()].map(e=>({...e,timeoutRemaining:e.timeout?Math.max(0,e.startTime+e.timeout-Date.now()):void 0}))}}export{at as N,Pt as P,Nt as a};
//# sourceMappingURL=NcBreadcrumbs-B4eyDS9i-Di3uuiFW.chunk.mjs.map