"use strict";(globalThis.webpackChunkPlesk=globalThis.webpackChunkPlesk||[]).push([["app/backup/upload-files"],{3097(e,n,t){t.r(n),t.d(n,{default:()=>r});var i=t(95);const a=i.Locale.getSection("components.forms.backup.upload");class o extends i.AddRemoveDynamicSubForm{_initConfiguration(e){super._initConfiguration({addButtonTitle:a.lmsg("addFileLink"),removeButtonTitle:a.lmsg("removeLink"),...e})}_bindDynamicContent(e,n){super._bindDynamicContent(e,n),e.querySelectorAll("input").forEach(n=>{const t=e.querySelector(`label[for="${n.id}"]`),a={type:"file",id:n.id,name:n.name};t&&(a["aria-label"]=t.textContent.trim()),(0,i.render)(n,(0,i.createElement)("input",a),"replace")})}_prepareDynamicContent(e){const n=Math.floor(1e6*Math.random()),t=new RegExp(`(name=.*?)\\[(${this._id})\\]\\[dynamicSubFormTemplate\\]\\[file\\]`,"g"),i=new RegExp(`(id=.*?\\-${this._id}-)dynamicSubFormTemplate(-)`,"g"),a=new RegExp(`(for=.*?\\-${this._id}-)dynamicSubFormTemplate(-)`,"g");return e.innerHTML=e.innerHTML.replace(t,`$1__$2__c${n}[]`).replace(i,`$1c${n}$2`).replace(a,`$1c${n}$2`),e}}const r=e=>new o(e);t.dn(r)}}]);
//# sourceMappingURL=upload-files.js.map?63090e7570c1d6d889d1