UNPKG

@uploadcare/file-uploader

Version:

Building blocks for Uploadcare products integration

7 lines 282 kB
import {subscribeKeys,listenKeys,map}from'nanostores';import {html,LitElement,nothing}from'lit';import {createContext,ContextConsumer,ContextProvider}from'@lit/context';import {property,state}from'lit/decorators.js';import {Queue,uploadFile,CancelError,UploadcareError,uploadFileGroup,getUserAgent,UploadError,NetworkError}from'@uploadcare/upload-client';import {startKeyUX,focusGroupKeyUX,pressKeyUX,jumpKeyUX,hiddenKeyUX}from'keyux';import {TelemetryAPIService}from'@uploadcare/quality-insights';import {unsafeSVG}from'lit/directives/unsafe-svg.js';import {createRef,ref}from'lit/directives/ref.js';import {repeat}from'lit/directives/repeat.js';import {shrinkFile}from'@uploadcare/image-shrink';import {styleMap}from'lit/directives/style-map.js';import {when}from'lit/directives/when.js';import {classMap}from'lit/directives/class-map.js';import {ifDefined}from'lit/directives/if-defined.js';import {getPrefixedCdnBaseAsync,isPrefixedCdnBase}from'@uploadcare/cname-prefix/async';/** * @license * Package: @uploadcare/file-uploader@1.28.0 (MIT) * License: https://github.com/uploadcare/blob/main/LICENSE * Built: 2026-04-03T13:57:43.140Z */ var Ns=Object.defineProperty;var Bs=Object.getOwnPropertyDescriptor;var d=(r,o,e,t)=>{for(var i=t>1?void 0:t?Bs(o,e):o,s=r.length-1,n;s>=0;s--)(n=r[s])&&(i=(t?n(o,e,i):n(i))||i);return t&&i&&Ns(o,e,i),i};var M=class r{static{this._contexts=new Map;}constructor(o,e){this._ctxId=o,this._store=e;}get id(){return this._ctxId}pub(o,e){o in this._store.get()||console.warn(`PubSub#pub: Key "${String(o)}" not found`),this._store.setKey(o,e);}sub(o,e,t=true){return (t?subscribeKeys:listenKeys)(this._store,[o],s=>{e(s[o]);})}read(o){return o in this._store.get()||console.warn(`PubSub#read: Key "${String(o)}" not found`),this._store.get()[o]}add(o,e,t=false){(!(o in this._store.get())||t)&&this._store.setKey(o,e);}has(o){return o in this._store.get()}get store(){return this._store.get()}static registerCtx(o,e){if(r._contexts.has(e))throw new Error(`PubSub: Context with id "${e}" already exists`);let t=map(o);return r._contexts.set(e,t),new r(e,t)}static deleteCtx(o){r._contexts.delete(o);}static getCtx(o){let e=r._contexts.get(o);return e?new r(o,e):null}static hasCtx(o){return r._contexts.has(o)}};var js=/\\([0-9a-fA-F]{1,6} ?)/g;function Gs(r){return r.length<2?false:(r[0]==='"'||r[0]==="'")&&(r[r.length-1]==='"'||r[r.length-1]==="'")}function Ws(r){let o=r;return (o[0]==='"'||o[0]==="'")&&(o=o.slice(1)),(o[o.length-1]==='"'||o[o.length-1]==="'")&&(o=o.slice(0,-1)),o}function qs(r){let o="",e="";for(let t=0;t<r.length;t++){let i=r[t+1];r[t]==="\\"&&i==='"'?(o+='\\"',t++):r[t]==='"'&&e!=="\\"?o+='\\"':o+=r[t],e=r[t]??"";}return o}function Hr(r){let o=r;Gs(r)&&(o=Ws(o),o=o.replace(js,(e,t)=>String.fromCodePoint(parseInt(t.trim(),16))),o=o.replaceAll(`\\ `,"\\n"),o=qs(o),o='"'+o+'"');try{return JSON.parse(o)}catch{return}}function Ne(r){class o extends r{constructor(){super(...arguments);this._cssDataCache=null;this._computedStyle=null;}getCssData(i,s=false){let n=this._cssDataCache??Object.create(null);if(!Object.keys(n).includes(i)||!n[i]){this._computedStyle||(this._computedStyle=window.getComputedStyle(this));let a=this._computedStyle.getPropertyValue(i).trim();try{n[i]=Hr(a);}catch(l){s||console.warn(`CSS Data error: ${i}`,l),n[i]=null;}}return this._cssDataCache=n,n[i]}}return o}function At(r){class o extends r{constructor(){super(...arguments);this.willYield=true;this._slotsMap={};this._initialLightDomChildren=null;this._hasAdoptedChildren=false;}createRenderRoot(){return this}connectedCallback(){this._initialLightDomChildren||(this._initialLightDomChildren=Array.from(this.childNodes)),super.connectedCallback();}_adoptChildren(){if(this._hasAdoptedChildren)return;this._hasAdoptedChildren=true,this._slotsMap={};let i=Array.from(this.childNodes),s=i.length?i:this._initialLightDomChildren??[];for(let n of s){let a=this._getSlotNameForChild(n),l=this._slotsMap[a]??[];n instanceof Element&&(n.removeAttribute("slot"),n.removeAttribute("content-for")),l.push(n),this._slotsMap[a]=l;}this._initialLightDomChildren=null;}_getSlotNameForChild(i){return i instanceof Comment&&i.nextSibling instanceof Element?this._getSlotNameForChild(i.nextSibling):"contentFor"in i?i.contentFor||"":i instanceof Element&&i.hasAttribute("content-for")&&i.getAttribute("content-for")||""}_isTextNodeEmpty(i){return !i.textContent||!i.textContent.trim()}_isSlotEmpty(i){let s=this._slotsMap[i];return !s||s.every(n=>n instanceof Comment||n instanceof Text&&this._isTextNodeEmpty(n))}update(i){!this.hasUpdated&&this.willYield&&this._adoptChildren(),super.update(i);}yield(i,s){if(i===""&&!this._slotsMap[i]&&!this._hasAdoptedChildren&&this._initialLightDomChildren?.length){let a=[];for(let l of this._initialLightDomChildren)l instanceof Element&&(l.removeAttribute("slot"),l.removeAttribute("content-for")),a.push(l);this._slotsMap[i]=a,this._hasAdoptedChildren=true,this._initialLightDomChildren=null;}let n=this._slotsMap[i];return html` ${n} ${this._isSlotEmpty(i)?s:void 0} `}}return o}function Be(r){class o extends r{static reg(t){let i=this,s=window.customElements.get(t);if(s){s!==i&&console.warn([`Element with tag name "${t}" already registered.`,`You're trying to override it with another class "${this.name}".`,"This is most likely a mistake.","New element will not be registered."].join(` `));return}window.customElements.define(t,i);}}return o}function E(r,o){let e,t=((...i)=>{e&&clearTimeout(e),e=setTimeout(()=>r(...i),o);});return t.cancel=()=>{e&&clearTimeout(e);},t}var zr=createContext("ctx-name-context");function Mt(){return function(r){class o extends r{constructor(...i){super(...i);this._symbioteSharedPubSub=null;this._symbioteFirstUpdated=false;this._needsReconnectInit=false;this._ctxNameProvider=void 0;this._pendingSharedAdds=new Map;this._symbioteSubscriptions=new Set;this.init$={};this.ctxOwner=false;this._ctxNameAttrValue=void 0;this._pendingCtxInitOnConnect=false;this.ctxName=this._effectiveCtxName;this._isInitialized=false;this._ctxNameAttrValue=this.getAttribute("ctx-name")||void 0,this.ctxName=this._effectiveCtxName,this._ctxNameConsumer=new ContextConsumer(this,{context:zr,callback:s=>{if(!s){console.error("SymbioteMixin: Received invalid ctx-name from context");return}this._ctxNameFromContext=s,this._handleCtxNameSourceChange();},subscribe:true});}static set template(i){console.error("Caution: static 'template' property is deprecated and has no effect. See https://github.com/uploadcare/file-uploader/releases/tag/v1.25.0 for details.");}get _ctxNameAttr(){return this._ctxNameAttrValue}set _ctxNameAttr(i){let s=i??void 0;this._ctxNameAttrValue!==s&&(this._ctxNameAttrValue=s,this._handleCtxNameSourceChange());}shouldUpdate(i){return this._isInitialized?super.shouldUpdate(i):false}get _effectiveCtxName(){return this._ctxNameAttr||this._ctxNameFromContext||void 0}_handleCtxNameSourceChange(){if(this.ctxName=this._effectiveCtxName,!(!this.ctxName||this._symbioteFirstUpdated)){if(this.isConnected){this._performInitialization();return}this._pendingCtxInitOnConnect=true;}}willUpdate(i){super.willUpdate(i),this.ctxName=this._effectiveCtxName,this.ctxName&&(this._ctxNameProvider?this._ctxNameProvider.setValue(this.ctxName):this._ctxNameProvider=new ContextProvider(this,{context:zr,initialValue:this.ctxName}));}_applyPendingSharedAdds(){if(!(!this._symbioteSharedPubSub||this._pendingSharedAdds.size===0)){for(let[i,{value:s,rewrite:n}]of this._pendingSharedAdds)this._symbioteSharedPubSub.add(i,s,n);this._pendingSharedAdds.clear();}}_getSharedPubSub(){return !this._symbioteSharedPubSub&&this._effectiveCtxName&&this._initSharedContext(),this._symbioteSharedPubSub&&this._applyPendingSharedAdds(),this._symbioteSharedPubSub}_requireSharedPubSub(){let i=this._getSharedPubSub();if(!i)throw new Error("SymbioteMixin: Shared context is not initialized.");return i}_initSharedContext(){let i=this.init$,s=this._effectiveCtxName;if(!s){console.error("SymbioteMixin: ctx-name is required for components with shared properties (*)");return}if(!this._symbioteSharedPubSub){this._symbioteSharedPubSub=M.getCtx(s)??M.registerCtx(i,s);for(let[n,a]of Object.entries(this.init$))this._symbioteSharedPubSub.add(n,a,this.ctxOwner);this._applyPendingSharedAdds();}}get $(){return this._effectiveCtxName&&this._initSharedContext(),new Proxy({},{get:(i,s)=>{if(typeof s=="string")return this._symbioteSharedPubSub?.read(s)},set:(i,s,n)=>(typeof s!="string"||this._symbioteSharedPubSub?.pub(s,n),true)})}sub(i,s,n=true){let a=this._requireSharedPubSub().sub(i,s,n);if(!a||typeof a!="function")return ()=>{};let l=a.bind(a),c=false,u=()=>{c||(c=true,l(),this._symbioteSubscriptions.delete(u));};return this._symbioteSubscriptions.add(u),u}pub(i,s){this._requireSharedPubSub().pub(i,s);}set$(i){for(let[s,n]of Object.entries(i))this.pub(s,n);}get sharedCtx(){return this._requireSharedPubSub()}has(i){return this._symbioteSharedPubSub?.has(i)??false}add(i,s,n=false){let a=this._getSharedPubSub();if(!a){if(!n&&this._pendingSharedAdds.has(i))return;this._pendingSharedAdds.set(i,{value:s,rewrite:n});return}this._pendingSharedAdds.delete(i),a.add(i,s,n);}add$(i,s=false){for(let[n,a]of Object.entries(i))this.add(n,a,s);}connectedCallback(){super.connectedCallback(),this._symbioteFirstUpdated?this._isInitialized&&this._needsReconnectInit&&(this._needsReconnectInit=false,this.initCallback()):this.ctxName?(this._pendingCtxInitOnConnect=false,this._performInitialization()):this._pendingCtxInitOnConnect&&this._effectiveCtxName&&(this._pendingCtxInitOnConnect=false,this._performInitialization());}_performInitialization(){if(this._symbioteFirstUpdated)return;this._symbioteFirstUpdated=true,this._initSharedContext();let i=this.init$;if(Object.keys(i).length>0){let s=this._requireSharedPubSub();for(let[n,a]of Object.entries(i))s.read(n)===void 0&&s.pub(n,a),this.sub(n,E(async()=>{this.isConnected&&(await this.updateComplete,this.requestUpdate());},0),false);}this.initCallback(),this._isInitialized=true,this.requestUpdate();}firstUpdated(i){super.firstUpdated(i);}disconnectedCallback(){this._cleanupSymbioteSubscriptions(),super.disconnectedCallback(),this._symbioteFirstUpdated&&(this._needsReconnectInit=true);}_cleanupSymbioteSubscriptions(){if(this._symbioteSubscriptions.size!==0){for(let i of [...this._symbioteSubscriptions])i();this._symbioteSubscriptions.clear();}}initCallback(){}}return d([property({type:String,attribute:"ctx-name",noAccessor:true})],o.prototype,"_ctxNameAttr",1),d([state()],o.prototype,"_ctxNameFromContext",2),d([state()],o.prototype,"ctxName",2),d([state()],o.prototype,"_isInitialized",2),o}}var $i=class extends Be(Mt()(Ne(At(LitElement)))){};var Q=class r{static generateFastUid(){return `uid-${Date.now().toString(36)}-${Math.random().toString(36).slice(2,11)}`}static generateRandomUUID(){let o=globalThis.crypto;return o&&typeof o.randomUUID=="function"?o.randomUUID():r.generateFastUid()}};var tn=["UploaderBlock","ActivityBlock","Block","SolutionBlock"];function Fi(r){for(let o in r){if(tn.includes(o))continue;let e=[...o].reduce((t,i)=>(i.toUpperCase()===i&&(i=`-${i.toLowerCase()}`),t+=i,t),"");e.startsWith("-")&&(e=e.replace("-","")),e.startsWith("uc-")||(e=`uc-${e}`),r[o].reg&&r[o].reg(e);}}var Ni="UC";function rn(r,o=false){return new Promise((e,t)=>{if(typeof document!="object"){e(null);return}if(typeof window=="object"&&window[Ni]){e(window[Ni]);return}let i=document.createElement("script");i.async=true,i.src=r,i.onerror=()=>{t();},i.onload=()=>{let s=window[Ni];o&&Fi(s),e(s);},document.head.appendChild(i);})}var st={"locale-id":"en","social-source-lang":"en","upload-file":"Upload file","upload-files":"Upload files","choose-file":"Choose file","choose-files":"Choose files","drop-files-here":"Drop files here","drop-file-here":"Drop file here","select-file-source":"Select file source",selected:"Selected",upload:"Upload","add-more":"Add more",cancel:"Cancel","start-from-cancel":"Cancel",clear:"Clear","camera-shot":"Shot","upload-url":"Import","upload-url-placeholder":"Paste link here","edit-image":"Edit image","edit-detail":"Details",back:"Back",done:"Done",ok:"Ok","remove-from-list":"Remove",no:"No",yes:"Yes","confirm-your-action":"Confirm your action","are-you-sure":"Are you sure?","selected-count":"{{count}} of {{total}} selected","select-all":"Select all","deselect-all":"Deselect all","upload-error":"Upload error","validation-error":"Validation error","no-files":"No files selected",browse:"Browse","not-uploaded-yet":"Not uploaded yet...",file__one:"file",file__other:"files",error__one:"error",error__other:"errors","header-uploading":"Uploading {{count}} {{plural:file(count)}}","header-failed":"{{count}} {{plural:error(count)}}","header-succeed":"{{count}} {{plural:file(count)}} uploaded","header-total":"{{count}} {{plural:file(count)}} selected","src-type-local":"From device","src-type-from-url":"From link","src-type-camera":"Camera","src-type-mobile-video-camera":"Video","src-type-mobile-photo-camera":"Photo","src-type-draw":"Draw","src-type-facebook":"Facebook","src-type-dropbox":"Dropbox","src-type-gdrive":"Google Drive","src-type-ngdrive":"Google Drive","src-type-gphotos":"Google Photos","src-type-flickr":"Flickr","src-type-vk":"VK","src-type-evernote":"Evernote","src-type-box":"Box","src-type-onedrive":"OneDrive","src-type-huddle":"Huddle","src-type-other":"Other","caption-from-url":"Import from link","caption-camera":"Camera","caption-draw":"Draw","caption-edit-file":"Edit file","file-no-name":"No name...","toggle-fullscreen":"Toggle fullscreen","toggle-guides":"Toggle guides",rotate:"Rotate","flip-vertical":"Flip vertical","flip-horizontal":"Flip horizontal",apply:"Apply",brightness:"Brightness",contrast:"Contrast",saturation:"Saturation",exposure:"Exposure",gamma:"Gamma",vibrance:"Vibrance",warmth:"Warmth",enhance:"Enhance",original:"Original",resize:"Resize image",crop:"Crop","select-color":"Select color",text:"Text",draw:"Draw","cancel-edit":"Cancel edit","tab-view":"Preview","tab-details":"Details","file-name":"Name","file-size":"Size","cdn-url":"CDN URL","file-size-unknown":"Unknown","camera-permissions-denied":"Camera access denied","camera-permissions-prompt":"Please allow access to the camera","camera-permissions-request":"Request access","files-count-limit-error-title":"Files count limit overflow","files-count-limit-error-too-few":"You\u2019ve chosen {{total}} {{plural:file(total)}}. At least {{min}} {{plural:file(min)}} required.","files-count-limit-error-too-many":"You\u2019ve chosen too many files. {{max}} {{plural:file(max)}} is maximum.","files-max-size-limit-error":"File is too big. Max file size is {{maxFileSize}}.","has-validation-errors":"File validation error occurred. Please, check your files before upload.","images-only-accepted":"Only image files are accepted.","file-type-not-allowed":"Uploading of these file types is not allowed.","some-files-were-not-uploaded":"Some files were not uploaded.","file-item-edit-button":"Edit","file-item-remove-button":"Remove","a11y-editor-tab-filters":"Filters","a11y-editor-tab-tuning":"Tuning","a11y-editor-tab-crop":"Crop","a11y-activity-header-button-close":"Close",flip:"Flip",mirror:"Mirror","a11y-cloud-editor-apply-filter":"Apply {{name}} filter","a11y-cloud-editor-apply-crop":"Apply {{name}} operation","a11y-cloud-editor-apply-tuning":"Apply {{name}} tuning","a11y-cloud-editor-apply-aspect-ratio":"Apply operation {{name}} {{value}}",finished:"Finished",failed:"Failed",uploading:"Uploading",idle:"Idle","a11y-file-item-status":"File {{fileName}} in status {{status}}","waiting-for":"Waiting for {{source}}","queued-uploading":"Queued for upload","queued-validation":"Queued for validation",validation:"Validating","crop-to-shape":"Crop to {{value}}",custom:"Freeform","freeform-crop":"Freeform crop"};var Bi=new Map,Kr=new Map,jr=(r,o)=>{Bi.has(r)&&console.log(`Locale ${r} is already defined. Overwriting...`);let e={...st,...o};return Bi.set(r,e),e},on=(r,o)=>{Kr.set(r,o);},Gr=(r,o)=>{typeof o=="function"?on(r,o):jr(r,o);},Wr=async r=>{let o=Bi.get(r);if(!o){let e=Kr.get(r);if(!e)throw new Error(`Locale ${r} is not defined`);let t=await e();o=jr(r,t);}return o};Gr("en",st);var w=r=>`*cfg/${r}`;var q=r=>r?r.split(",").map(o=>o.trim()).filter(Boolean):[],ve=r=>r.join(",");var qr=r=>{if(typeof r!="string"||!r)return "";let o=r.trim();return o.startsWith("-/")?o=o.slice(2):o.startsWith("/")&&(o=o.slice(1)),o.endsWith("/")&&(o=o.slice(0,o.length-1)),o},Ot=(...r)=>r.filter(o=>typeof o=="string"&&!!o).map(o=>qr(o)).join("/-/"),z=(...r)=>{let o=Ot(...r);return o?`-/${o}/`:""};function Lt(r){let o=new URL(r),e=o.pathname+o.search+o.hash,t=e.lastIndexOf("http"),i=e.lastIndexOf("/"),s="";return t>=0?s=e.slice(t):i>=0&&(s=e.slice(i+1)),s}function Pt(r){let o=new URL(r),{pathname:e}=o,t=e.indexOf("/"),i=e.indexOf("/",t+1);return e.substring(t+1,i)}function Hi(r){let o=Zr(r),e=new URL(o),t=e.pathname.indexOf("/-/");return t===-1?"":e.pathname.substring(t).slice(1)}function zi(r){return Hi(r).split("/-/").filter(Boolean).map(e=>qr(e))}function Zr(r){let o=new URL(r),e=Lt(r),t=Xr(e)?Yr(e).pathname:e;return o.pathname=o.pathname.replace(t,""),o.search="",o.hash="",o.toString()}function Xr(r){return r.startsWith("http")}function Yr(r){let o=new URL(r);return {pathname:`${o.origin}${o.pathname??""}`,search:o.search??"",hash:o.hash??""}}var V=(r,o,e)=>{let t=new URL(Zr(r)),i=e??Lt(r),s=o??"";if(t.pathname.startsWith("//")&&(t.pathname=t.pathname.replace("//","/")),i&&Xr(i)){let n=Yr(i);t.pathname=`${t.pathname}${s}${n.pathname||""}`,t.search=n.search,t.hash=n.hash;}else t.pathname=`${t.pathname}${s}${i||""}`;return t.toString()},xe=(r,o)=>{let e=new URL(r);return e.pathname=`${o}/`,e.toString()};var D=(r,o=",")=>r.trim().split(o).map(e=>e.trim()).filter(e=>e.length>0);var nt=Object.freeze({brightness:0,exposure:0,gamma:100,contrast:0,saturation:0,vibrance:0,warmth:0,enhance:0,filter:0,rotate:0,mirror:false,flip:false,crop:void 0}),Jr=["enhance","brightness","exposure","gamma","contrast","saturation","vibrance","warmth","filter","mirror","flip","rotate","crop"];function sn(r,o){if(typeof o=="number"){let e=o;return nt[r]!==e?`${r}/${e}`:""}if(typeof o=="boolean"){let e=o;return nt[r]!==e?`${r}`:""}if(r==="filter"&&o){let{name:e,amount:t}=o;return nt.filter===t?"":`${r}/${e}/${t}`}if(r==="crop"&&o){let{dimensions:e,coords:t}=o;return `${r}/${e.join("x")}/${t.join(",")}`}return ""}function Se(r){return Ot(...Jr.filter(o=>typeof r[o]<"u"&&r[o]!==null).map(o=>{let e=r[o];return sn(o,e)}).filter(o=>!!o))}var Rt=Ot("format/auto","progressive/yes"),be=([r])=>typeof r<"u"?Number(r):void 0,Qr=()=>true,nn=([r,o])=>({name:r,amount:typeof o<"u"?Number(o):100}),an=([r,o])=>{if(!/\d+x\d+/.test(r)||!/\d+,\d+/.test(o))throw new Error("Crop by aspect ratio, percentage or alignment shortcuts is not supported.");return {dimensions:D(r,"x").map(Number),coords:D(o).map(Number)}},ln=Object.freeze({enhance:be,brightness:be,exposure:be,gamma:be,contrast:be,saturation:be,vibrance:be,warmth:be,filter:nn,mirror:Qr,flip:Qr,rotate:be,crop:r=>{let[o,e]=r,{dimensions:t,coords:i}=an([o,e]);return {dimensions:t,coords:i}}});function Ki(r){let o={};for(let e of r){let[t,...i]=e.split("/");if(!t||!Jr.includes(t))continue;let s=t,n=ln[s];try{let a=n(i);o[s]=a;}catch(a){console.warn([`Failed to parse URL operation "${e}". It will be ignored.`,a instanceof Error?`Error message: "${a.message}"`:a,"If you need this functionality, please feel free to open an issue at https://github.com/uploadcare/blocks/issues/new"].join(` `));}}return o}var k=Object.freeze({CROP:"crop",TUNING:"tuning",FILTERS:"filters"}),K=Object.freeze([k.CROP,k.TUNING,k.FILTERS]),eo=Object.freeze(["brightness","exposure","gamma","contrast","saturation","vibrance","warmth","enhance"]),to=Object.freeze(["adaris","briaril","calarel","carris","cynarel","cyren","elmet","elonni","enzana","erydark","fenralan","ferand","galen","gavin","gethriel","iorill","iothari","iselva","jadis","lavra","misiara","namala","nerion","nethari","pamaya","sarnar","sedis","sewen","sorahel","sorlen","tarian","thellassan","varriel","varven","vevera","virkas","yedis","yllara","zatvel","zevcen"]),io=Object.freeze(["rotate","mirror","flip"]),ye=nt,ne=Object.freeze({brightness:{zero:ye.brightness,range:[-100,100],keypointsNumber:2},exposure:{zero:ye.exposure,range:[-500,500],keypointsNumber:2},gamma:{zero:ye.gamma,range:[0,1e3],keypointsNumber:2},contrast:{zero:ye.contrast,range:[-100,500],keypointsNumber:2},saturation:{zero:ye.saturation,range:[-100,500],keypointsNumber:1},vibrance:{zero:ye.vibrance,range:[-100,500],keypointsNumber:1},warmth:{zero:ye.warmth,range:[-100,100],keypointsNumber:1},enhance:{zero:ye.enhance,range:[0,100],keypointsNumber:1},filter:{zero:ye.filter,range:[0,100],keypointsNumber:1}});var at="https://ucarecdn.com",cn="https://upload.uploadcare.com",dn="https://social.uploadcare.com",un="https://ucarecd.net",pn={pubkey:"",multiple:true,multipleMin:0,multipleMax:Number.MAX_SAFE_INTEGER,confirmUpload:false,imgOnly:false,accept:"",externalSourcesPreferredTypes:"",externalSourcesEmbedCss:"",store:"auto",cameraMirror:false,cameraCapture:"",sourceList:"local, url, camera, dropbox, gdrive",topLevelOrigin:"",cloudImageEditorTabs:ve(K),maxLocalFileSizeBytes:0,thumbSize:76,showEmptyList:false,useLocalImageEditor:false,useCloudImageEditor:true,removeCopyright:false,cropPreset:"",imageShrink:"",modalScrollLock:true,modalBackdropStrokes:false,sourceListWrap:true,remoteTabSessionKey:"",cdnCname:at,cdnCnamePrefixed:un,baseUrl:cn,socialBaseUrl:dn,secureSignature:"",secureExpire:"",secureDeliveryProxy:"",retryThrottledRequestMaxTimes:3,retryNetworkErrorMaxTimes:3,multipartMinFileSize:26214400,multipartChunkSize:5242880,maxConcurrentRequests:10,multipartMaxConcurrentRequests:4,multipartMaxAttempts:3,checkForUrlDuplicates:false,saveUrlForRecurrentUploads:false,groupOutput:false,userAgentIntegration:"",debug:false,metadata:null,localeName:"en",localeDefinitionOverride:null,secureUploadsExpireThreshold:600*1e3,secureUploadsSignatureResolver:null,secureDeliveryProxyUrlResolver:null,iconHrefResolver:null,fileValidators:[],collectionValidators:[],validationTimeout:15*1e3,validationConcurrency:100,cameraModes:"photo, video",defaultCameraMode:null,enableAudioRecording:true,enableVideoRecording:null,maxVideoRecordingDuration:null,mediaRecorderOptions:null,filesViewMode:"list",gridShowFileNames:false,cloudImageEditorAutoOpen:false,cloudImageEditorMaskHref:null,testMode:false,qualityInsights:true,pasteScope:"local"},B=Object.freeze(pn);var Ut=(r,o)=>(...e)=>{let t=r();if(!t.read(w("debug")))return;let i=e;if(typeof e?.[0]=="function"){let n=e[0];i=n();}let s=[t.id,o].filter(Boolean);console.log(`[${s.join("][")}]`,...i);};var F=class{constructor(o){this._subscriptions=new Set;this._cfgProxy=null;this._debugPrint=Ut(()=>this._sharedInstancesBag.ctx,this.constructor.name);this._sharedInstancesBag=o,this._ctx=o.ctx;}addSub(o){this._subscriptions.add(o);}get _cfg(){if(!this._cfgProxy){let o={};this._cfgProxy=new Proxy(o,{set:()=>{throw new Error("SharedInstance cfg proxy is read-only")},get:(e,t)=>{if(typeof t!="string")return;let i=w(t);return this._sharedInstancesBag.ctx.has(i)?this._sharedInstancesBag.ctx.read(i):B[t]}});}return this._cfgProxy}destroy(){for(let o of this._subscriptions)try{o();}catch{}this._subscriptions.clear();}},de=(r,o,e=true)=>{let t=r.has(o),i=t?r.read(o):null;if(t&&i||!e)return i;throw new Error(`Unexpected error: shared instance for key "${String(o)}" is not available`)},ro=r=>({get ctx(){return r()},get modalManager(){return de(r(),"*modalManager",false)},get telemetryManager(){return de(r(),"*telemetryManager")},get localeManager(){return de(r(),"*localeManager")},get a11y(){return de(r(),"*a11y")},get blocksRegistry(){return de(r(),"*blocksRegistry")},get eventEmitter(){return de(r(),"*eventEmitter")},get uploadCollection(){return de(r(),"*uploadCollection")},get secureUploadsManager(){return de(r(),"*secureUploadsManager",false)},get api(){return de(r(),"*publicApi")},get validationManager(){return de(r(),"*validationManager")}});var $=Object.freeze({ADD:"modal:add",DELETE:"modal:delete",OPEN:"modal:open",CLOSE:"modal:close",CLOSE_ALL:"modal:closeAll",DESTROY:"modal:destroy"}),Vt=class extends F{constructor(){super(...arguments);this._modals=new Map;this._activeModals=new Set;this._subscribers=new Map;}registerModal(e,t){this._modals.set(e,t),this._notify($.ADD,{id:e,modal:t});}deleteModal(e){let t=this._modals.get(e);return t?(this._modals.delete(e),this._activeModals.delete(e),this._notify($.DELETE,{id:e,modal:t}),true):false}open(e){let t=this._modals.get(e);return t?(this._activeModals.add(e),this._notify($.OPEN,{modal:t,id:e}),true):(this._debugPrint(`Modal with ID "${e}" not found`),false)}close(e){let t=this._modals.get(e);return !t||!this._activeModals.has(e)?(this._debugPrint(`Modal with ID "${e}" not found or not active`),false):(this._activeModals.delete(e),this._notify($.CLOSE,{id:e,modal:t}),true)}toggle(e){return this._modals.has(e)?this._activeModals.has(e)?this.close(e):this.open(e):(this._debugPrint(`Modal with ID "${e}" not found`),false)}get hasActiveModals(){return this._activeModals.size>0}back(){if(this._activeModals.size===0)return this._debugPrint("No active modals to go back from"),false;let e=Array.from(this._activeModals).pop();return e?this.close(e):false}closeAll(){let e=this._activeModals.size;return this._activeModals.clear(),this._notify($.CLOSE_ALL,{}),e}subscribe(e,t){return this._subscribers.has(e)||this._subscribers.set(e,new Set),this._subscribers.get(e)?.add(t),()=>this.unsubscribe(e,t)}unsubscribe(e,t){this._subscribers.has(e)&&this._subscribers.get(e)?.delete(t);}_notify(e,t){if(this._subscribers.has(e))for(let i of this._subscribers.get(e)??new Set)try{i(t);}catch(s){this._sharedInstancesBag.telemetryManager.sendEventError(s,"modal subscriber"),this._debugPrint("Error in modal subscriber:",s);}}destroy(){super.destroy(),this.closeAll(),this._modals.clear(),this._subscribers.clear(),this._notify($.DESTROY,{});}};var lt=r=>r.match(/[A-Z]{2,}(?=[A-Z][a-z]+[0-9]*|\b)|[A-Z]?[a-z]+[0-9]*|[A-Z]|[0-9]+/g)?.map(o=>o.toLowerCase()).join("-");var ji=()=>({}),Gi=r=>({...ji(),"*currentActivity":null,"*currentActivityParams":{},"*history":[],"*historyBack":null,"*closeModal":()=>{r.modalManager?.close(r.$["*currentActivity"]),r.pub("*currentActivity",null);}}),Wi=r=>({...Gi(r),"*commonProgress":0,"*uploadList":[],"*uploadQueue":new Queue(1),"*collectionErrors":[],"*collectionState":null,"*groupInfo":null,"*uploadTrigger":new Set}),oo=r=>({...Wi(r),"*solution":null});var J=Object.freeze({START_FROM:"start-from",CAMERA:"camera",DRAW:"draw",UPLOAD_LIST:"upload-list",URL:"url",CLOUD_IMG_EDIT:"cloud-image-edit",EXTERNAL:"external"});var Dt=class extends F{constructor(e){super(e);this.scopes=new Set;this.listener=this._listener.bind(this),window.addEventListener("paste",this.listener);}openUploadList(){this._sharedInstancesBag.api.setCurrentActivity(J.UPLOAD_LIST),this._sharedInstancesBag.api.setModalState(true);}async _listener(e){if(e.clipboardData){for(let t of this.scopes)if(t.isConnected)switch(this._cfg.pasteScope){case "global":await this.handlePaste(e);break;case "local":if(!t.contains(e.target))continue;await this.handlePaste(e);break;default:continue}}}async handlePaste(e){let t=Array.from(e.clipboardData.items),i=t.map(n=>n.getAsFile()).filter(n=>n!==null),s=t.filter(n=>n.kind==="string"&&n.type==="text/plain").map(n=>new Promise(a=>{n.getAsString(l=>{a(l);});}));i.length>0&&(i.forEach(n=>{this._sharedInstancesBag.api.addFileFromObject(n,{source:"clipboard"});}),this.openUploadList()),s.length>0&&((await Promise.all(s)).forEach(a=>{this._sharedInstancesBag.api.addFileFromUrl(a,{source:"clipboard"});}),this.openUploadList());}registerBlock(e){return this.scopes.add(e),()=>{this.scopes.delete(e);}}destroy(){super.destroy(),window.removeEventListener("paste",this.listener),this.scopes.clear();}};var qi=class{constructor(){this._listeners=new Map;this._scope=[];}addEventListener(o,e){let t=i=>{let s=i.target;s instanceof Node&&this._scope.some(n=>n===s||n.contains(s))&&e(i);};this._listeners.set(e,t),window.addEventListener(o,t);}removeEventListener(o,e){let t=this._listeners.get(e);t&&window.removeEventListener(o,t),this._listeners.delete(e);}get CustomEvent(){return window.CustomEvent}get document(){return window.document}get navigator(){return window.navigator}registerScope(o){this._scope.push(o);}destroy(){this._scope=[];for(let o of this._listeners.values())window.removeEventListener("keydown",o),window.removeEventListener("keyup",o);this._listeners.clear();}},$t=class{constructor(){this._scopedWindow=new qi,this._destroyKeyUX=startKeyUX(this._scopedWindow,[focusGroupKeyUX(),pressKeyUX("is-pressed"),jumpKeyUX(),hiddenKeyUX()]);}registerBlock(o){this._scopedWindow.registerScope(o);}destroy(){this._destroyKeyUX?.(),this._scopedWindow.destroy();}};var _e=r=>`*l10n/${r}`,yn="en",Ft=class extends F{constructor(e){super(e);this._localeName="";for(let[t,i]of Object.entries(st)){let s=this._ctx.has(_e(t))?!this._ctx.read(_e(t)):true;this._ctx.add(_e(t),i,s);}this.addSub(this._ctx.sub(w("localeName"),async t=>{if(!t)return;this._localeName=t;let i=await Wr(t);if(t!==yn&&this._localeName!==t)return;let s=this._cfg.localeDefinitionOverride?.[t];for(let[n,a]of Object.entries(i)){let l=s?.[n];this._ctx.add(_e(n),l??a,true);}})),this.addSub(this._ctx.sub(w("localeDefinitionOverride"),t=>{if(!t)return;let i=t[this._localeName];if(i)for(let[s,n]of Object.entries(i))this._ctx.add(_e(s),n,true);}));}};var _n=20,x=Object.freeze({INIT_SOLUTION:"init-solution",CHANGE_CONFIG:"change-config",ACTION_EVENT:"action-event",ERROR_EVENT:"error-event"}),_=Object.freeze({FILE_ADDED:"file-added",FILE_REMOVED:"file-removed",FILE_UPLOAD_START:"file-upload-start",FILE_UPLOAD_PROGRESS:"file-upload-progress",FILE_UPLOAD_SUCCESS:"file-upload-success",FILE_UPLOAD_FAILED:"file-upload-failed",FILE_URL_CHANGED:"file-url-changed",MODAL_OPEN:"modal-open",MODAL_CLOSE:"modal-close",DONE_CLICK:"done-click",UPLOAD_CLICK:"upload-click",ACTIVITY_CHANGE:"activity-change",COMMON_UPLOAD_START:"common-upload-start",COMMON_UPLOAD_PROGRESS:"common-upload-progress",COMMON_UPLOAD_SUCCESS:"common-upload-success",COMMON_UPLOAD_FAILED:"common-upload-failed",CHANGE:"change",GROUP_CREATED:"group-created"}),Nt=class extends F{constructor(){super(...arguments);this._timeoutStore=new Map;this._targets=new Set;}bindTarget(e){return this._targets.add(e),()=>{this._targets.delete(e);}}_dispatch(e,t){for(let i of this._targets)i.dispatchEvent(new CustomEvent(e,{detail:t}));this._debugPrint?.(()=>{let i=t&&typeof t=="object"?{...t}:t;return [`event "${e}"`,i]});}emit(e,t,i={}){let{debounce:s}=i;if(typeof s!="number"&&!s){this._dispatch(e,typeof t=="function"?t():t);return}this._timeoutStore.has(e)&&window.clearTimeout(this._timeoutStore.get(e));let n=typeof s=="number"?s:_n,a=window.setTimeout(()=>{try{let l=typeof t=="function"?t():t;this._dispatch(e,l),this._timeoutStore.delete(e);}catch(l){this._debugPrint?.(()=>`Error while getting payload for event "${e}"`,l);}},n);this._timeoutStore.set(e,a);}destroy(){for(let e of this._timeoutStore.values())window.clearTimeout(e);this._targets.clear();}};var so="1.28.0";var ue="blocks",pe=so;var Bt=class extends F{constructor(e){super(e);this._sessionId=Q.generateRandomUUID();this._config=structuredClone(B);this._initialized=false;this._lastPayload=null;this._isEnabled=false;this._telemetryInstance=new TelemetryAPIService,this._queue=new Queue(10),this.addSub(this._ctx.sub(w("qualityInsights"),t=>{this._isEnabled=!!t;}));for(let t of Object.keys(this._config))this.addSub(this._ctx.sub(w(t),i=>{this._isEnabled&&(this._initialized&&this._config[t]!==i&&this.sendEvent({eventType:x.CHANGE_CONFIG}),this._setConfig(t,i));}));}_init(e){e===x.INIT_SOLUTION&&!this._initialized&&(this._initialized=true);}_setConfig(e,t){this._config[e]!==t&&(this._config[e]=t);}_formattingPayload(e){let t=e.payload?{...e.payload}:{};t.activity&&(t.activity=void 0);let i={...e};return (e.eventType===x.INIT_SOLUTION||e.eventType===x.CHANGE_CONFIG)&&(i.config=this._config),{...i,appVersion:pe,appName:ue,sessionId:this._sessionId,component:this._solution,activity:this._activity,projectPubkey:this._config.pubkey,userAgent:navigator.userAgent,eventType:i.eventType??"",eventTimestamp:this._timestamp,payload:{location:this._location,...t}}}_excludedEvents(e){return !!(e&&[_.CHANGE,_.COMMON_UPLOAD_PROGRESS,_.FILE_ADDED,_.FILE_REMOVED,_.FILE_UPLOAD_START,_.FILE_UPLOAD_PROGRESS,_.FILE_UPLOAD_SUCCESS,_.FILE_UPLOAD_FAILED].includes(e))}sendEvent(e){if(!this._isEnabled)return;let t=this._formattingPayload({eventType:e.eventType,payload:e.payload,config:e.config});this._init(e.eventType),!(this._excludedEvents(e.eventType)||this._lastPayload&&this._checkObj(this._lastPayload,t))&&this._queue.add(async()=>{this._lastPayload=t,await this._telemetryInstance.sendEvent(t);});}sendEventError(e,t="unknown"){this.sendEvent({eventType:x.ERROR_EVENT,payload:{metadata:{event:"error",text:`Error in ${t}`,error:e.message}}});}sendEventCloudImageEditor(e,t,i={}){this.sendEvent({eventType:x.ACTION_EVENT,payload:{metadata:{tabId:t,node:e.currentTarget?.tagName,event:e.type,...i}}});}_checkObj(e,t){if(JSON.stringify(e)===JSON.stringify(t))return true;if(typeof e!="object"||typeof t!="object"||e==null||t==null)return false;let i=Object.keys(e),s=Object.keys(t);if(i.length!==s.length)return false;for(let n of i)if(!Object.hasOwn(t,n)||!this._checkObj(e[n],t[n]))return false;return true}get _timestamp(){return Date.now()}get _solution(){if(!this._ctx.has("*solution"))return null;let e=this._ctx.read("*solution");return e?e.toLowerCase():null}get _activity(){return this._ctx.has("*currentActivity")?this._ctx.read("*currentActivity"):null}get _location(){return location.origin}};var no=r=>{let o=new Intl.Locale(r),e="ltr",t=o.getTextInfo?.().direction;return t?e=t:o.textInfo?.direction&&(e=o.textInfo.direction),e};var En=r=>r;var ao="plural:";function He(r,o={},e={}){let{openToken:t="{{",closeToken:i="}}",transform:s=En}=e;for(let n in o){let a=o[n],l=a?.toString(),c=typeof l=="string"?s(l):String(l);r=r.replaceAll(t+n+i,c);}return r}function lo(r){let o=[],e=r.indexOf("{{");for(;e!==-1;){let t=r.indexOf("}}",e);if(t===-1)break;let i=r.substring(e+2,t);if(i.startsWith(ao)){let s=r.substring(e+2,t).replace(ao,""),n=s.substring(0,s.indexOf("(")),a=s.substring(s.indexOf("(")+1,s.indexOf(")"));o.push({variable:i,pluralKey:n,countVariable:a});}e=r.indexOf("{{",t);}return o}var co="--uploadcare-blocks-window-height",ct=class r{static{this.clientsRegistry=new Set;}static{this.flush=E(()=>{document.documentElement.style.setProperty(co,`${window.innerHeight}px`);},100);}static registerClient(o){r.clientsRegistry.size===0&&r.attachTracker(),r.clientsRegistry.add(o);}static unregisterClient(o){r.clientsRegistry.delete(o),r.clientsRegistry.size===0&&r.detachTracker();}static attachTracker(){window.addEventListener("resize",r.flush,{passive:true,capture:true}),r.flush();}static detachTracker(){window.removeEventListener("resize",r.flush,{capture:true}),document.documentElement.style.removeProperty(co);}};var Ht=(r,o)=>new Intl.PluralRules(r).select(o);var xn=r=>(o,e)=>{let t=r(),i=t("locale-id")||"en",s=Ht(i,e);return t(`${o}__${s}`)},zt=r=>{let o=xn(()=>e),e=(t,i={})=>{if(!t)return "";let n=r().read(_e(t))||t,a=lo(n);for(let c of a)i[c.variable]=o(c.pluralKey,Number(i[c.countVariable]));return He(n,i)};return e};var Sn=r=>r.tagName?.includes("-")??false,Kt=class{constructor(o){this._trackedElements=new Set;this._originalValues=new Map;this._enabled=false;this._host=o,this._host.addController(this);}hostDisconnected(){this._unsubscribe?.(),this._unsubscribe=void 0,this._trackedElements.clear(),this._originalValues.clear();}hostUpdated(){if(!this._unsubscribe&&this._host.has(w("testMode"))){let o=this._host.subConfigValue("testMode",e=>{this._enabled=!!e,this._applyTestMode();});this._unsubscribe=o;}this._collectElements(),this._applyTestMode();}_collectElements(){let o=this._host,e=o.renderRoot??o;if(!e)return;let t=this._host,i=t.tagName?.toLowerCase(),s=Array.from(e.querySelectorAll("[data-testid]")).filter(n=>!Sn(n));for(let n of s)if(!(i&&n.closest(i)!==t)&&!this._trackedElements.has(n)){let a=n.getAttribute("data-testid");if(!a)continue;this._trackedElements.add(n),this._originalValues.set(n,a);}for(let n of Array.from(this._trackedElements))(!n.isConnected||i&&n.closest(i)!==t)&&(this._trackedElements.delete(n),this._originalValues.delete(n));}_applyTestMode(){if(!this._trackedElements.size)return;let o=this._host.testId||"";for(let e of this._trackedElements){let t=this._originalValues.get(e);t&&(this._enabled?e.setAttribute("data-testid",`${o}--${t}`):e.removeAttribute("data-testid"));}}};var kn=Be(Mt()(Ne(At(LitElement)))),v=class extends kn{constructor(){super();this._sharedContextInstances=new Map;this.activityType=null;this.init$=ji();this.l10n=zt(()=>this.sharedCtx);this.debugPrint=Ut(()=>this.sharedCtx,this.constructor.name);this._sharedInstancesBag=ro(()=>this.sharedCtx);new Kt(this);}static{this.styleAttrs=[];}emit(e,t,i){let s=this.has("*eventEmitter")?this.$["*eventEmitter"]:void 0;if(!s)return;s.emit(e,t,i);let n=typeof t=="function"?t():t;this.telemetryManager.sendEvent({eventType:e,payload:n??void 0});}hasBlockInCtx(e){for(let t of this.blocksRegistry)if(e(t))return true;return false}connectedCallback(){this.constructor.styleAttrs.forEach(t=>{this.setAttribute(t,"");}),super.connectedCallback(),ct.registerClient(this);}initCallback(){this._addSharedContextInstance("*blocksRegistry",()=>new Set),this._addSharedContextInstance("*eventEmitter",e=>new Nt(e)),this._addSharedContextInstance("*localeManager",e=>new Ft(e)),this._addSharedContextInstance("*modalManager",e=>new Vt(e)),this._addSharedContextInstance("*a11y",()=>new $t),this._addSharedContextInstance("*clipboard",e=>new Dt(e)),this._addSharedContextInstance("*telemetryManager",e=>new Bt(e)),this.sub(_e("locale-id"),e=>{let t=no(e);this.style.direction=t==="ltr"?"":t,this.requestUpdate();}),this.subConfigValue("testMode",e=>{if(!e||!this.testId){this.removeAttribute("data-testid");return}this.setAttribute("data-testid",this.testId);}),this.blocksRegistry.add(this);}get testId(){return window.customElements.getName(this.constructor)}get modalManager(){return this._getSharedContextInstance("*modalManager",false)}get telemetryManager(){return this._getSharedContextInstance("*telemetryManager")}get localeManager(){return this._getSharedContextInstance("*localeManager")}get a11y(){return this._getSharedContextInstance("*a11y")}get clipboardLayer(){return this._getSharedContextInstance("*clipboard")}get blocksRegistry(){return this._getSharedContextInstance("*blocksRegistry")}get eventEmitter(){return this._getSharedContextInstance("*eventEmitter")}disconnectedCallback(){super.disconnectedCallback(),ct.unregisterClient(this);let e=this.blocksRegistry;e?.delete(this),e?.size===0&&setTimeout(()=>{this.isConnected||e?.size>0||this.destroyCtxCallback();},0);}destroyCtxCallback(){this._destroySharedContextInstances(),M.deleteCtx(this.ctxName);}_addSharedContextInstance(e,t){if(!this._sharedContextInstances.has(e)&&(!this.has(e)||!this.$[e])){let i=t(this._sharedInstancesBag);this.add(e,i,true),this._sharedContextInstances.set(e,i);return}}_destroySharedContextInstances(){for(let[e,t]of this._sharedContextInstances.entries())t?.destroy?.(),this.pub(e,null),this._sharedContextInstances.delete(e);}_getSharedContextInstance(e,t=true){if(this.has(e)&&this.$[e])return this.$[e];if(!t)return this.$[e];throw new Error(`Unexpected error: context manager for key "${String(e)}" is not available`)}async proxyUrl(e){if(this.cfg.secureDeliveryProxy&&this.cfg.secureDeliveryProxyUrlResolver&&console.warn("Both secureDeliveryProxy and secureDeliveryProxyUrlResolver are set. The secureDeliveryProxyUrlResolver will be used."),this.cfg.secureDeliveryProxyUrlResolver)try{return await this.cfg.secureDeliveryProxyUrlResolver(e,{uuid:Pt(e),cdnUrlModifiers:Hi(e),fileName:Lt(e)})}catch(t){return console.error("Failed to resolve secure delivery proxy URL. Falling back to the default URL.",t),this.telemetryManager.sendEventError(t,"secureDeliveryProxyUrlResolver. Failed to resolve secure delivery proxy URL. Falling back to the default URL."),e}return this.cfg.secureDeliveryProxy?He(this.cfg.secureDeliveryProxy,{previewUrl:e},{transform:t=>window.encodeURIComponent(t)}):e}get cfg(){if(!this._cfgProxy){let e={};this._cfgProxy=new Proxy(e,{set:(t,i,s)=>{if(typeof i!="string"||!(i in B))return false;let n=i,a=w(n);return this.has(a)||this.add(a,B[n]),this.$[a]=s,true},get:(t,i)=>{let s=w(i);return this.has(s)||this.add(s,B[i]),this.$[s]}});}return this._cfgProxy}subConfigValue(e,t){let i=w(e);return this.has(i)||this.add(i,B[e]),this.sub(i,t)}};var uo="<svg width='0' height='0' style='position:absolute'><symbol viewBox='0 0 24 24' id='uc-icon-about' xmlns='http://www.w3.org/2000/svg'><path fill='currentColor' fill-rule='evenodd' d='M11.152 14.12v.1h1.523v-.1c.007-.409.053-.752.138-1.028.086-.277.22-.517.405-.72.188-.202.434-.397.735-.586.32-.191.593-.412.82-.66.232-.249.41-.531.533-.847.125-.32.187-.678.187-1.076 0-.579-.137-1.085-.41-1.518a2.717 2.717 0 0 0-1.14-1.018c-.49-.245-1.062-.367-1.715-.367-.597 0-1.142.114-1.636.34-.49.228-.884.564-1.182 1.008-.299.44-.46.98-.485 1.619h1.62c.024-.377.118-.684.282-.922a1.48 1.48 0 0 1 .617-.532c.25-.114.51-.17.784-.17.301 0 .575.063.82.191.248.124.447.302.597.533.149.23.223.504.223.82 0 .263-.05.502-.149.72a1.91 1.91 0 0 1-.405.574 3.48 3.48 0 0 1-.575.453 4.22 4.22 0 0 0-.847.66c-.234.242-.415.558-.543.949-.125.39-.19.916-.197 1.577Zm.053 3.03c.21.206.46.31.75.31.196 0 .374-.049.534-.144a1.1 1.1 0 0 0 .383-.384c.1-.163.15-.343.15-.538a1 1 0 0 0-.32-.746 1.019 1.019 0 0 0-.746-.314c-.291 0-.542.105-.751.314-.21.206-.314.455-.314.746 0 .295.104.547.314.756ZM24 12c0 6.627-5.373 12-12 12S0 18.627 0 12 5.373 0 12 0s12 5.373 12 12Zm-1.5 0c0 5.799-4.701 10.5-10.5 10.5S1.5 17.799 1.5 12 6.201 1.5 12 1.5 22.5 6.201 22.5 12Z'/></symbol><symbol viewBox='0 0 24 24' id='uc-icon-add' xmlns='http://www.w3.org/2000/svg'><path fill='currentColor' fill-rule='evenodd' d='M12.75 21a.75.75 0 0 1-1.5 0v-8.25H3a.75.75 0 0 1 0-1.5h8.25V3a.75.75 0 0 1 1.5 0v8.25H21a.75.75 0 0 1 0 1.5h-8.25V21Z'/></symbol><symbol viewBox='0 0 24 24' id='uc-icon-arrow-down' xmlns='http://www.w3.org/2000/svg'><path fill='currentColor' fill-rule='evenodd' d='M11.5 23.03a.75.75 0 0 0 .999 0l9.29-8.276a.75.75 0 0 0-.998-1.12l-8.042 7.164V1.53a.75.75 0 0 0-1.5 0v19.267l-8.04-7.163a.75.75 0 0 0-.998 1.12z'/></symbol><symbol fill='none' viewBox='0 0 9 6' id='uc-icon-arrow-dropdown' xmlns='http://www.w3.org/2000/svg'><path stroke='currentColor' d='m1.5 1.667 3 2.666 3-2.666' opacity='.5'/></symbol><symbol viewBox='0 0 24 24' id='uc-icon-aspect-ratio' xmlns='http://www.w3.org/2000/svg'><path stroke='currentColor' d='M7.395 22.5H2.454v-5.25m14.824 5.25h4.94v-5.25m0-10.5V1.5h-4.94m-9.883 0H2.454v5.25'/></symbol><symbol viewBox='0 0 24 24' id='uc-icon-back' xmlns='http://www.w3.org/2000/svg'><path fill='currentColor' fill-rule='evenodd' d='M20.251 12a.75.75 0 0 1-.75.75H6.067l5.72 5.85a.75.75 0 1 1-1.072 1.05L4.136 12.92a1.292 1.292 0 0 1 0-1.842l6.579-6.728a.75.75 0 1 1 1.072 1.048l-5.72 5.851H19.5a.75.75 0 0 1 .75.75Z'/></symbol><symbol viewBox='0 0 24 24' id='uc-icon-badge-error' xmlns='http://www.w3.org/2000/svg'><path fill='currentColor' fill-rule='evenodd' d='M13.6 18.4a1.6 1.6 0 1 1-3.2 0 1.6 1.6 0 0 1 3.2 0zM12 4.5A1.5 1.5 0 0 1 13.5 6v7a1.5 1.5 0 0 1-3 0V6A1.5 1.5 0 0 1 12 4.5z'/></symbol><symbol viewBox='0 0 24 24' id='uc-icon-badge-success' xmlns='http://www.w3.org/2000/svg'><path fill='currentColor' fill-rule='evenodd' d='m10.5 18.204 7.6-8.183a1.5 1.5 0 0 0-2.2-2.042l-5.4 5.817-2.4-2.586a1.5 1.5 0 1 0-2.2 2.041l4.6 4.953Z'/></symbol><symbol viewBox='0 0 24 24' id='uc-icon-box' xmlns='http://www.w3.org/2000/svg'><path fill='currentColor' fill-rule='evenodd' d='M1.01 4.148a.75.75 0 0 1 .75.75v4.348a4.437 4.437 0 0 1 2.988-1.153c1.734 0 3.23.992 3.978 2.438a4.478 4.478 0 0 1 3.978-2.438c2.49 0 4.488 2.044 4.488 4.543 0 2.5-1.999 4.544-4.488 4.544a4.478 4.478 0 0 1-3.978-2.438 4.478 4.478 0 0 1-3.978 2.438C2.26 17.18.26 15.135.26 12.636V4.898a.75.75 0 0 1 .75-.75Zm.75 8.488c0 1.692 1.348 3.044 2.988 3.044s2.989-1.352 2.989-3.044c0-1.691-1.349-3.043-2.989-3.043S1.76 10.945 1.76 12.636Zm10.944-3.043c-1.64 0-2.988 1.352-2.988 3.043 0 1.692 1.348 3.044 2.988 3.044s2.988-1.352 2.988-3.044c0-1.69-1.348-3.043-2.988-3.043Zm4.328-1.23a.75.75 0 0 1 1.052.128l2.333 2.983 2.333-2.983a.75.75 0 0 1 1.181.924l-2.562 3.277 2.562 3.276a.75.75 0 1 1-1.181.924l-2.333-2.983-2.333 2.983a.75.75 0 1 1-1.181-.924l2.562-3.276-2.562-3.277a.75.75 0 0 1 .129-1.052Z'/></symbol><symbol viewBox='0 0 24 24' id='uc-icon-camera' xmlns='http://www.w3.org/2000/svg'><path fill='currentColor' fill-rule='evenodd' d='M7.65 2.55a.75.75 0 0 1 .6-.3h7.5a.75.75 0 0 1 .6.3l2.025 2.7H21a3 3 0 0 1 3 3v10.5a3 3 0 0 1-3 3H3a3 3 0 0 1-3-3V8.25a3 3 0 0 1 3-3h2.625zm.975 1.2L6.6 6.45a.75.75 0 0 1-.6.3H3a1.5 1.5 0 0 0-1.5 1.5v10.5a1.5 1.5 0 0 0 1.5 1.5h18a1.5 1.5 0 0 0 1.5-1.5V8.25a1.5 1.5 0 0 0-1.5-1.5h-3a.75.75 0 0 1-.6-.3l-2.025-2.7zm3.375 6a3.375 3.375 0 1 0 0 6.75 3.375 3.375 0 0 0 0-6.75zm-4.875 3.375a4.875 4.875 0 1 1 9.75 0 4.875 4.875 0 0 1-9.75 0z'/></symbol><symbol viewBox='0 0 20 20' id='uc-icon-camera-full' xmlns='http://www.w3.org/2000/svg'><path fill-rule='evenodd' clip-rule='evenodd' d='M2 4.667a2 2 0 0 0-2 2V16a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2V6.667a2 2 0 0 0-2-2h-2.667l-2-2.667H6.667l-2 2.667H2Zm8 10a3.667 3.667 0 1 0 0-7.334 3.667 3.667 0 0 0 0 7.334Z' fill='currentColor'/></symbol><symbol viewBox='0 0 24 24' id='uc-icon-close' xmlns='http://www.w3.org/2000/svg'><path fill='currentColor' fill-rule='evenodd' d='M4.604 4.604a.75.75 0 0 1 1.06 0L12 10.939l6.335-6.335a.75.75 0 1 1 1.061 1.06L13.061 12l6.335 6.335a.75.75 0 1 1-1.06 1.061L12 13.061l-6.335 6.335a.75.75 0 0 1-1.061-1.06L10.939 12 4.604 5.665a.75.75 0 0 1 0-1.061z'/></symbol><symbol viewBox='0 0 24 24' id='uc-icon-collapse' xmlns='http://www.w3.org/2000/svg'><path fill='currentColor' fill-rule='evenodd' d='M3.116 12a.75.75 0 0 1 .75-.75h16.268a.75.75 0 0 1 0 1.5H3.866a.75.75 0 0 1-.75-.75Z'/></symbol><symbol viewBox='0 0 24 24' id='uc-icon-default' xmlns='http://www.w3.org/2000/svg'><path fill='currentColor' fill-rule='evenodd' d='M11.501.392a.75.75 0 0 1 .998 0l6.704 5.972a.75.75 0 0 1-.998 1.12l-5.455-4.86v13.439a.75.75 0 0 1-1.5 0V2.625l-5.454 4.86a.75.75 0 1 1-.998-1.12zM.857 16.73a.75.75 0 0 1 .75.75v4.914h20.786v-4.914a.75.75 0 0 1 1.5 0v5.664a.75.75 0 0 1-.75.75H.857a.75.75 0 0 1-.75-.75v-5.664a.75.75 0 0 1 .75-.75z'/></symbol><symbol viewBox='0 0 24 24' id='uc-icon-dropbox' xmlns='http://www.w3.org/2000/svg'><path fill='currentColor' fill-rule='evenodd' d='M6.019 1.92a.75.75 0 0 1 .806 0L12 5.219l5.176-3.297a.75.75 0 0 1 .806 0l5.577 3.553a.75.75 0 0 1 0 1.265l-4.574 2.914 4.574 2.914a.75.75 0 0 1 0 1.265l-5.577 3.554a.75.75 0 0 1-.806 0L12 14.089l-5.175 3.297a.75.75 0 0 1-.806 0L.44 13.833a.75.75 0 0 1 0-1.266l4.575-2.914L.44 6.74a.75.75 0 0 1 0-1.265zm.403 8.616L2.24 13.2l4.182 2.664 4.181-2.664zm6.975 2.664 4.182 2.664L21.76 13.2l-4.181-2.664zm2.776-3.547L12 12.311 7.828 9.653 12 6.995zm1.406-.882 4.181-2.664-4.181-2.664-4.182 2.664zm-6.976-2.664L6.422 3.443 2.24 6.107 6.422 8.77zM5.791 18.544a.75.75 0 0 1 1.035-.23l5.175 3.297 5.175-3.297a.75.75 0 1 1 .806 1.265l-5.578 3.554a.75.75 0 0 1-.806 0L6.02 19.579a.75.75 0 0 1-.23-1.035z'/></symbol><symbol viewBox='0 0 24 24' id='uc-icon-edit-file' xmlns='http://www.w3.org/2000/svg'><path fill='currentColor' fill-rule='evenodd' d='M18.558 2.804a.78.78 0 0 0-.557.235l-.008.007-2.472 2.46 3.847 3.848 2.46-2.473.004-.003a.78.78 0 0 0 0-1.108l-.004-.003-2.712-2.728a.78.78 0 0 0-.558-.235Zm-.248 7.613-3.852-3.852-8.93 8.887-1.516 5.41 5.41-1.515 8.888-8.93Zm-.636-8.934a2.28 2.28 0 0 1 2.512.505l2.702 2.717.002.002a2.278 2.278 0 0 1 0 3.234l-.002.002-12.541 12.602a.75.75 0 0 1-.33.193l-6.884 1.928a.75.75 0 0 1-.925-.924l1.928-6.885a.75.75 0 0 1 .193-.33l12.603-12.54a2.28 2.28 0 0 1 .742-.504Z' clip-rule='evenodd'/></symbol><symbol viewBox='0 0 24 24' id='uc-icon-error' xmlns='http://www.w3.org/2000/svg'><path fill='currentColor' fill-rule='evenodd' d='M13 13h-2V7h2m0 10h-2v-2h2M12 2A10 10 0 0 0 2 12a10 10 0 0 0 10 10 10 10 0 0 0 10-10A10 10 0 0 0 12 2Z'/></symbol><symbol viewBox='0 0 24 24' id='uc-icon-evernote' xmlns='http://www.w3.org/2000/svg'><path fill='currentColor' fill-rule='evenodd' d='M9.804 2.27v-.048c.055-.263.313-.562.85-.562h.44c.142 0 .325.014.526.033.066.009.124.023.267.06l.13.032h.002c.319.079.515.275.644.482a1.461 1.461 0 0 1 .16.356l.004.012a.75.75 0 0 0 .603.577l1.191.207a1988.512 1988.512 0 0 0 2.332.402c.512.083 1.1.178 1.665.442.64.3 1.19.795 1.376 1.77.548 2.931.657 5.829.621 8a39.233 39.233 0 0 1-.125 2.602 17.518 17.518 0 0 1-.092.849.735.735 0 0 0-.024.112c-.378 2.705-1.269 3.796-2.04 4.27-.746.457-1.53.451-2.217.447h-.192c-.46 0-1.073-.23-1.581-.635-.518-.412-.763-.87-.763-1.217 0-.45.188-.688.355-.786.161-.095.436-.137.796.087a.75.75 0 1 0 .792-1.274c-.766-.476-1.64-.52-2.345-.108-.7.409-1.098 1.188-1.098 2.08 0 .996.634 1.84 1.329 2.392.704.56 1.638.96 2.515.96l.185.002c.667.009 1.874.025 3.007-.67 1.283-.786 2.314-2.358 2.733-5.276a4.213 4.213 0 0 0 .056-.335c.023-.184.051-.445.079-.772.055-.655.111-1.585.13-2.704.037-2.234-.074-5.239-.647-8.301v-.002c-.294-1.544-1.233-2.391-2.215-2.85-.777-.363-1.623-.496-2.129-.576a8.872 8.872 0 0 1-.25-.041l-.006-.001-1.99-.345-.761-.132a2.93 2.93 0 0 0-.182-.338A2.532 2.532 0 0 0 12.379.329l-.091-.023a3.967 3.967 0 0 0-.493-.103L11.769.2a7.846 7.846 0 0 0-.675-.04h-.44c-.733 0-1.368.284-1.795.742L2.416 7.431c-.468.428-.751 1.071-.751 1.81 0 .02 0 .041.003.062l.003.034c.017.21.038.468.096.796.107.715.275 1.47.391 1.9