Files
WPS3Media/assets/js/pro/settings.min.js
Malin 3248cbb029 feat: add S3-compatible storage provider (MinIO, Ceph, R2, etc.)
Adds a new 'S3-Compatible Storage' provider that works with any
S3-API-compatible object storage service, including MinIO, Ceph,
Cloudflare R2, Backblaze B2, and others.

Changes:
- New provider class: classes/providers/storage/s3-compatible-provider.php
  - Provider key: s3compatible
  - Reads user-configured endpoint URL from settings
  - Uses path-style URL access (required by most S3-compatible services)
  - Supports credentials via AS3CF_S3COMPAT_ACCESS_KEY_ID /
    AS3CF_S3COMPAT_SECRET_ACCESS_KEY wp-config.php constants
  - Disables AWS-specific features (Block Public Access, Object Ownership)
- New provider SVG icons (s3compatible.svg, -link.svg, -round.svg)
- Registered provider in main plugin class with endpoint setting support
- Updated StorageProviderSubPage to show endpoint URL input for S3-compatible
- Built pro settings bundle with rollup (Svelte 4.2.19)
- Added package.json and updated rollup.config.mjs for pro-only builds
2026-03-03 12:30:18 +01:00

1 line
912 KiB
JavaScript
Raw Blame History

This file contains invisible Unicode characters
This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
(function(global,factory){typeof exports==="object"&&typeof module!=="undefined"?module.exports=factory():typeof define==="function"&&define.amd?define(factory):(global=typeof globalThis!=="undefined"?globalThis:global||self,global.AS3CFPro_Settings=factory())})(this,(function(){"use strict";function noop(){}const identity=x=>x;function assign(tar,src){for(const k in src)tar[k]=src[k];return tar}function is_promise(value){return!!value&&(typeof value==="object"||typeof value==="function")&&typeof value.then==="function"}function add_location(element,file,line,column,char){element.__svelte_meta={loc:{file:file,line:line,column:column,char:char}}}function run(fn){return fn()}function blank_object(){return Object.create(null)}function run_all(fns){fns.forEach(run)}function is_function(thing){return typeof thing==="function"}function safe_not_equal(a,b){return a!=a?b==b:a!==b||a&&typeof a==="object"||typeof a==="function"}let src_url_equal_anchor;function src_url_equal(element_src,url){if(element_src===url)return true;if(!src_url_equal_anchor){src_url_equal_anchor=document.createElement("a")}src_url_equal_anchor.href=url;return element_src===src_url_equal_anchor.href}function is_empty(obj){return Object.keys(obj).length===0}function validate_store(store,name){if(store!=null&&typeof store.subscribe!=="function"){throw new Error(`'${name}' is not a store with a 'subscribe' method`)}}function subscribe(store,...callbacks){if(store==null){for(const callback of callbacks){callback(undefined)}return noop}const unsub=store.subscribe(...callbacks);return unsub.unsubscribe?()=>unsub.unsubscribe():unsub}function get_store_value(store){let value;subscribe(store,(_=>value=_))();return value}function component_subscribe(component,store,callback){component.$$.on_destroy.push(subscribe(store,callback))}function create_slot(definition,ctx,$$scope,fn){if(definition){const slot_ctx=get_slot_context(definition,ctx,$$scope,fn);return definition[0](slot_ctx)}}function get_slot_context(definition,ctx,$$scope,fn){return definition[1]&&fn?assign($$scope.ctx.slice(),definition[1](fn(ctx))):$$scope.ctx}function get_slot_changes(definition,$$scope,dirty,fn){if(definition[2]&&fn){const lets=definition[2](fn(dirty));if($$scope.dirty===undefined){return lets}if(typeof lets==="object"){const merged=[];const len=Math.max($$scope.dirty.length,lets.length);for(let i=0;i<len;i+=1){merged[i]=$$scope.dirty[i]|lets[i]}return merged}return $$scope.dirty|lets}return $$scope.dirty}function update_slot_base(slot,slot_definition,ctx,$$scope,slot_changes,get_slot_context_fn){if(slot_changes){const slot_context=get_slot_context(slot_definition,ctx,$$scope,get_slot_context_fn);slot.p(slot_context,slot_changes)}}function get_all_dirty_from_scope($$scope){if($$scope.ctx.length>32){const dirty=[];const length=$$scope.ctx.length/32;for(let i=0;i<length;i++){dirty[i]=-1}return dirty}return-1}function exclude_internal_props(props){const result={};for(const k in props)if(k[0]!=="$")result[k]=props[k];return result}function set_store_value(store,ret,value){store.set(value);return ret}function action_destroyer(action_result){return action_result&&is_function(action_result.destroy)?action_result.destroy:noop}const is_client=typeof window!=="undefined";let now=is_client?()=>window.performance.now():()=>Date.now();let raf=is_client?cb=>requestAnimationFrame(cb):noop;const tasks=new Set;function run_tasks(now){tasks.forEach((task=>{if(!task.c(now)){tasks.delete(task);task.f()}}));if(tasks.size!==0)raf(run_tasks)}function loop(callback){let task;if(tasks.size===0)raf(run_tasks);return{promise:new Promise((fulfill=>{tasks.add(task={c:callback,f:fulfill})})),abort(){tasks.delete(task)}}}const globals=typeof window!=="undefined"?window:typeof globalThis!=="undefined"?globalThis:global;function append(target,node){target.appendChild(node)}function get_root_for_style(node){if(!node)return document;const root=node.getRootNode?node.getRootNode():node.ownerDocument;if(root&&root.host){return root}return node.ownerDocument}function append_empty_stylesheet(node){const style_element=element("style");style_element.textContent="/* empty */";append_stylesheet(get_root_for_style(node),style_element);return style_element.sheet}function append_stylesheet(node,style){append(node.head||node,style);return style.sheet}function insert(target,node,anchor){target.insertBefore(node,anchor||null)}function detach(node){if(node.parentNode){node.parentNode.removeChild(node)}}function destroy_each(iterations,detaching){for(let i=0;i<iterations.length;i+=1){if(iterations[i])iterations[i].d(detaching)}}function element(name){return document.createElement(name)}function svg_element(name){return document.createElementNS("http://www.w3.org/2000/svg",name)}function text(data){return document.createTextNode(data)}function space(){return text(" ")}function empty(){return text("")}function listen(node,event,handler,options){node.addEventListener(event,handler,options);return()=>node.removeEventListener(event,handler,options)}function prevent_default(fn){return function(event){event.preventDefault();return fn.call(this,event)}}function attr(node,attribute,value){if(value==null)node.removeAttribute(attribute);else if(node.getAttribute(attribute)!==value)node.setAttribute(attribute,value)}function init_binding_group(group){let _inputs;return{p(...inputs){_inputs=inputs;_inputs.forEach((input=>group.push(input)))},r(){_inputs.forEach((input=>group.splice(group.indexOf(input),1)))}}}function children(element){return Array.from(element.childNodes)}function set_input_value(input,value){input.value=value==null?"":value}function set_style(node,key,value,important){if(value==null){node.style.removeProperty(key)}else{node.style.setProperty(key,value,important?"important":"")}}function select_option(select,value,mounting){for(let i=0;i<select.options.length;i+=1){const option=select.options[i];if(option.__value===value){option.selected=true;return}}if(!mounting||value!==undefined){select.selectedIndex=-1}}function select_value(select){const selected_option=select.querySelector(":checked");return selected_option&&selected_option.__value}let crossorigin;function is_crossorigin(){if(crossorigin===undefined){crossorigin=false;try{if(typeof window!=="undefined"&&window.parent){void window.parent.document}}catch(error){crossorigin=true}}return crossorigin}function add_iframe_resize_listener(node,fn){const computed_style=getComputedStyle(node);if(computed_style.position==="static"){node.style.position="relative"}const iframe=element("iframe");iframe.setAttribute("style","display: block; position: absolute; top: 0; left: 0; width: 100%; height: 100%; "+"overflow: hidden; border: 0; opacity: 0; pointer-events: none; z-index: -1;");iframe.setAttribute("aria-hidden","true");iframe.tabIndex=-1;const crossorigin=is_crossorigin();let unsubscribe;if(crossorigin){iframe.src="data:text/html,<script>onresize=function(){parent.postMessage(0,'*')}<\/script>";unsubscribe=listen(window,"message",(event=>{if(event.source===iframe.contentWindow)fn()}))}else{iframe.src="about:blank";iframe.onload=()=>{unsubscribe=listen(iframe.contentWindow,"resize",fn);fn()}}append(node,iframe);return()=>{if(crossorigin){unsubscribe()}else if(unsubscribe&&iframe.contentWindow){unsubscribe()}detach(iframe)}}function toggle_class(element,name,toggle){element.classList.toggle(name,!!toggle)}function custom_event(type,detail,{bubbles:bubbles=false,cancelable:cancelable=false}={}){return new CustomEvent(type,{detail:detail,bubbles:bubbles,cancelable:cancelable})}class HtmlTag{is_svg=false;e=undefined;n=undefined;t=undefined;a=undefined;constructor(is_svg=false){this.is_svg=is_svg;this.e=this.n=null}c(html){this.h(html)}m(html,target,anchor=null){if(!this.e){if(this.is_svg)this.e=svg_element(target.nodeName);else this.e=element(target.nodeType===11?"TEMPLATE":target.nodeName);this.t=target.tagName!=="TEMPLATE"?target:target.content;this.c(html)}this.i(anchor)}h(html){this.e.innerHTML=html;this.n=Array.from(this.e.nodeName==="TEMPLATE"?this.e.content.childNodes:this.e.childNodes)}i(anchor){for(let i=0;i<this.n.length;i+=1){insert(this.t,this.n[i],anchor)}}p(html){this.d();this.h(html);this.i(this.a)}d(){this.n.forEach(detach)}}const managed_styles=new Map;let active$1=0;function hash(str){let hash=5381;let i=str.length;while(i--)hash=(hash<<5)-hash^str.charCodeAt(i);return hash>>>0}function create_style_information(doc,node){const info={stylesheet:append_empty_stylesheet(node),rules:{}};managed_styles.set(doc,info);return info}function create_rule(node,a,b,duration,delay,ease,fn,uid=0){const step=16.666/duration;let keyframes="{\n";for(let p=0;p<=1;p+=step){const t=a+(b-a)*ease(p);keyframes+=p*100+`%{${fn(t,1-t)}}\n`}const rule=keyframes+`100% {${fn(b,1-b)}}\n}`;const name=`__svelte_${hash(rule)}_${uid}`;const doc=get_root_for_style(node);const{stylesheet:stylesheet,rules:rules}=managed_styles.get(doc)||create_style_information(doc,node);if(!rules[name]){rules[name]=true;stylesheet.insertRule(`@keyframes ${name} ${rule}`,stylesheet.cssRules.length)}const animation=node.style.animation||"";node.style.animation=`${animation?`${animation}, `:""}${name} ${duration}ms linear ${delay}ms 1 both`;active$1+=1;return name}function delete_rule(node,name){const previous=(node.style.animation||"").split(", ");const next=previous.filter(name?anim=>anim.indexOf(name)<0:anim=>anim.indexOf("__svelte")===-1);const deleted=previous.length-next.length;if(deleted){node.style.animation=next.join(", ");active$1-=deleted;if(!active$1)clear_rules()}}function clear_rules(){raf((()=>{if(active$1)return;managed_styles.forEach((info=>{const{ownerNode:ownerNode}=info.stylesheet;if(ownerNode)detach(ownerNode)}));managed_styles.clear()}))}let current_component;function set_current_component(component){current_component=component}function get_current_component(){if(!current_component)throw new Error("Function called outside component initialization");return current_component}function onMount(fn){get_current_component().$$.on_mount.push(fn)}function afterUpdate(fn){get_current_component().$$.after_update.push(fn)}function onDestroy(fn){get_current_component().$$.on_destroy.push(fn)}function createEventDispatcher(){const component=get_current_component();return(type,detail,{cancelable:cancelable=false}={})=>{const callbacks=component.$$.callbacks[type];if(callbacks){const event=custom_event(type,detail,{cancelable:cancelable});callbacks.slice().forEach((fn=>{fn.call(component,event)}));return!event.defaultPrevented}return true}}function setContext(key,context){get_current_component().$$.context.set(key,context);return context}function getContext(key){return get_current_component().$$.context.get(key)}function hasContext(key){return get_current_component().$$.context.has(key)}function bubble(component,event){const callbacks=component.$$.callbacks[event.type];if(callbacks){callbacks.slice().forEach((fn=>fn.call(this,event)))}}const dirty_components=[];const binding_callbacks=[];let render_callbacks=[];const flush_callbacks=[];const resolved_promise=Promise.resolve();let update_scheduled=false;function schedule_update(){if(!update_scheduled){update_scheduled=true;resolved_promise.then(flush)}}function tick(){schedule_update();return resolved_promise}function add_render_callback(fn){render_callbacks.push(fn)}function add_flush_callback(fn){flush_callbacks.push(fn)}const seen_callbacks=new Set;let flushidx=0;function flush(){if(flushidx!==0){return}const saved_component=current_component;do{try{while(flushidx<dirty_components.length){const component=dirty_components[flushidx];flushidx++;set_current_component(component);update(component.$$)}}catch(e){dirty_components.length=0;flushidx=0;throw e}set_current_component(null);dirty_components.length=0;flushidx=0;while(binding_callbacks.length)binding_callbacks.pop()();for(let i=0;i<render_callbacks.length;i+=1){const callback=render_callbacks[i];if(!seen_callbacks.has(callback)){seen_callbacks.add(callback);callback()}}render_callbacks.length=0}while(dirty_components.length);while(flush_callbacks.length){flush_callbacks.pop()()}update_scheduled=false;seen_callbacks.clear();set_current_component(saved_component)}function update($$){if($$.fragment!==null){$$.update();run_all($$.before_update);const dirty=$$.dirty;$$.dirty=[-1];$$.fragment&&$$.fragment.p($$.ctx,dirty);$$.after_update.forEach(add_render_callback)}}function flush_render_callbacks(fns){const filtered=[];const targets=[];render_callbacks.forEach((c=>fns.indexOf(c)===-1?filtered.push(c):targets.push(c)));targets.forEach((c=>c()));render_callbacks=filtered}let promise;function wait(){if(!promise){promise=Promise.resolve();promise.then((()=>{promise=null}))}return promise}function dispatch(node,direction,kind){node.dispatchEvent(custom_event(`${direction?"intro":"outro"}${kind}`))}const outroing=new Set;let outros;function group_outros(){outros={r:0,c:[],p:outros}}function check_outros(){if(!outros.r){run_all(outros.c)}outros=outros.p}function transition_in(block,local){if(block&&block.i){outroing.delete(block);block.i(local)}}function transition_out(block,local,detach,callback){if(block&&block.o){if(outroing.has(block))return;outroing.add(block);outros.c.push((()=>{outroing.delete(block);if(callback){if(detach)block.d(1);callback()}}));block.o(local)}else if(callback){callback()}}const null_transition={duration:0};function create_bidirectional_transition(node,fn,params,intro){const options={direction:"both"};let config=fn(node,params,options);let t=intro?0:1;let running_program=null;let pending_program=null;let animation_name=null;let original_inert_value;function clear_animation(){if(animation_name)delete_rule(node,animation_name)}function init(program,duration){const d=program.b-t;duration*=Math.abs(d);return{a:t,b:program.b,d:d,duration:duration,start:program.start,end:program.start+duration,group:program.group}}function go(b){const{delay:delay=0,duration:duration=300,easing:easing=identity,tick:tick=noop,css:css}=config||null_transition;const program={start:now()+delay,b:b};if(!b){program.group=outros;outros.r+=1}if("inert"in node){if(b){if(original_inert_value!==undefined){node.inert=original_inert_value}}else{original_inert_value=node.inert;node.inert=true}}if(running_program||pending_program){pending_program=program}else{if(css){clear_animation();animation_name=create_rule(node,t,b,duration,delay,easing,css)}if(b)tick(0,1);running_program=init(program,duration);add_render_callback((()=>dispatch(node,b,"start")));loop((now=>{if(pending_program&&now>pending_program.start){running_program=init(pending_program,duration);pending_program=null;dispatch(node,running_program.b,"start");if(css){clear_animation();animation_name=create_rule(node,t,running_program.b,running_program.duration,0,easing,config.css)}}if(running_program){if(now>=running_program.end){tick(t=running_program.b,1-t);dispatch(node,running_program.b,"end");if(!pending_program){if(running_program.b){clear_animation()}else{if(! --running_program.group.r)run_all(running_program.group.c)}}running_program=null}else if(now>=running_program.start){const p=now-running_program.start;t=running_program.a+running_program.d*easing(p/running_program.duration);tick(t,1-t)}}return!!(running_program||pending_program)}))}}return{run(b){if(is_function(config)){wait().then((()=>{const opts={direction:b?"in":"out"};config=config(opts);go(b)}))}else{go(b)}},end(){clear_animation();running_program=pending_program=null}}}function handle_promise(promise,info){const token=info.token={};function update(type,index,key,value){if(info.token!==token)return;info.resolved=value;let child_ctx=info.ctx;if(key!==undefined){child_ctx=child_ctx.slice();child_ctx[key]=value}const block=type&&(info.current=type)(child_ctx);let needs_flush=false;if(info.block){if(info.blocks){info.blocks.forEach(((block,i)=>{if(i!==index&&block){group_outros();transition_out(block,1,1,(()=>{if(info.blocks[i]===block){info.blocks[i]=null}}));check_outros()}}))}else{info.block.d(1)}block.c();transition_in(block,1);block.m(info.mount(),info.anchor);needs_flush=true}info.block=block;if(info.blocks)info.blocks[index]=block;if(needs_flush){flush()}}if(is_promise(promise)){const current_component=get_current_component();promise.then((value=>{set_current_component(current_component);update(info.then,1,info.value,value);set_current_component(null)}),(error=>{set_current_component(current_component);update(info.catch,2,info.error,error);set_current_component(null);if(!info.hasCatch){throw error}}));if(info.current!==info.pending){update(info.pending,0);return true}}else{if(info.current!==info.then){update(info.then,1,info.value,promise);return true}info.resolved=promise}}function update_await_block_branch(info,ctx,dirty){const child_ctx=ctx.slice();const{resolved:resolved}=info;if(info.current===info.then){child_ctx[info.value]=resolved}if(info.current===info.catch){child_ctx[info.error]=resolved}info.block.p(child_ctx,dirty)}function ensure_array_like(array_like_or_iterator){return array_like_or_iterator?.length!==undefined?array_like_or_iterator:Array.from(array_like_or_iterator)}function destroy_block(block,lookup){block.d(1);lookup.delete(block.key)}function outro_and_destroy_block(block,lookup){transition_out(block,1,1,(()=>{lookup.delete(block.key)}))}function update_keyed_each(old_blocks,dirty,get_key,dynamic,ctx,list,lookup,node,destroy,create_each_block,next,get_context){let o=old_blocks.length;let n=list.length;let i=o;const old_indexes={};while(i--)old_indexes[old_blocks[i].key]=i;const new_blocks=[];const new_lookup=new Map;const deltas=new Map;const updates=[];i=n;while(i--){const child_ctx=get_context(ctx,list,i);const key=get_key(child_ctx);let block=lookup.get(key);if(!block){block=create_each_block(key,child_ctx);block.c()}else if(dynamic){updates.push((()=>block.p(child_ctx,dirty)))}new_lookup.set(key,new_blocks[i]=block);if(key in old_indexes)deltas.set(key,Math.abs(i-old_indexes[key]))}const will_move=new Set;const did_move=new Set;function insert(block){transition_in(block,1);block.m(node,next);lookup.set(block.key,block);next=block.first;n--}while(o&&n){const new_block=new_blocks[n-1];const old_block=old_blocks[o-1];const new_key=new_block.key;const old_key=old_block.key;if(new_block===old_block){next=new_block.first;o--;n--}else if(!new_lookup.has(old_key)){destroy(old_block,lookup);o--}else if(!lookup.has(new_key)||will_move.has(new_key)){insert(new_block)}else if(did_move.has(old_key)){o--}else if(deltas.get(new_key)>deltas.get(old_key)){did_move.add(new_key);insert(new_block)}else{will_move.add(old_key);o--}}while(o--){const old_block=old_blocks[o];if(!new_lookup.has(old_block.key))destroy(old_block,lookup)}while(n)insert(new_blocks[n-1]);run_all(updates);return new_blocks}function validate_each_keys(ctx,list,get_context,get_key){const keys=new Map;for(let i=0;i<list.length;i++){const key=get_key(get_context(ctx,list,i));if(keys.has(key)){let value="";try{value=`with value '${String(key)}' `}catch(e){}throw new Error(`Cannot have duplicate keys in a keyed each: Keys at index ${keys.get(key)} and ${i} ${value}are duplicates`)}keys.set(key,i)}}function get_spread_update(levels,updates){const update={};const to_null_out={};const accounted_for={$$scope:1};let i=levels.length;while(i--){const o=levels[i];const n=updates[i];if(n){for(const key in o){if(!(key in n))to_null_out[key]=1}for(const key in n){if(!accounted_for[key]){update[key]=n[key];accounted_for[key]=1}}levels[i]=n}else{for(const key in o){accounted_for[key]=1}}}for(const key in to_null_out){if(!(key in update))update[key]=undefined}return update}function get_spread_object(spread_props){return typeof spread_props==="object"&&spread_props!==null?spread_props:{}}function bind(component,name,callback){const index=component.$$.props[name];if(index!==undefined){component.$$.bound[index]=callback;callback(component.$$.ctx[index])}}function create_component(block){block&&block.c()}function mount_component(component,target,anchor){const{fragment:fragment,after_update:after_update}=component.$$;fragment&&fragment.m(target,anchor);add_render_callback((()=>{const new_on_destroy=component.$$.on_mount.map(run).filter(is_function);if(component.$$.on_destroy){component.$$.on_destroy.push(...new_on_destroy)}else{run_all(new_on_destroy)}component.$$.on_mount=[]}));after_update.forEach(add_render_callback)}function destroy_component(component,detaching){const $$=component.$$;if($$.fragment!==null){flush_render_callbacks($$.after_update);run_all($$.on_destroy);$$.fragment&&$$.fragment.d(detaching);$$.on_destroy=$$.fragment=null;$$.ctx=[]}}function make_dirty(component,i){if(component.$$.dirty[0]===-1){dirty_components.push(component);schedule_update();component.$$.dirty.fill(0)}component.$$.dirty[i/31|0]|=1<<i%31}function init(component,options,instance,create_fragment,not_equal,props,append_styles=null,dirty=[-1]){const parent_component=current_component;set_current_component(component);const $$=component.$$={fragment:null,ctx:[],props:props,update:noop,not_equal:not_equal,bound:blank_object(),on_mount:[],on_destroy:[],on_disconnect:[],before_update:[],after_update:[],context:new Map(options.context||(parent_component?parent_component.$$.context:[])),callbacks:blank_object(),dirty:dirty,skip_bound:false,root:options.target||parent_component.$$.root};append_styles&&append_styles($$.root);let ready=false;$$.ctx=instance?instance(component,options.props||{},((i,ret,...rest)=>{const value=rest.length?rest[0]:ret;if($$.ctx&&not_equal($$.ctx[i],$$.ctx[i]=value)){if(!$$.skip_bound&&$$.bound[i])$$.bound[i](value);if(ready)make_dirty(component,i)}return ret})):[];$$.update();ready=true;run_all($$.before_update);$$.fragment=create_fragment?create_fragment($$.ctx):false;if(options.target){if(options.hydrate){const nodes=children(options.target);$$.fragment&&$$.fragment.l(nodes);nodes.forEach(detach)}else{$$.fragment&&$$.fragment.c()}if(options.intro)transition_in(component.$$.fragment);mount_component(component,options.target,options.anchor);flush()}set_current_component(parent_component)}class SvelteComponent{$$=undefined;$$set=undefined;$destroy(){destroy_component(this,1);this.$destroy=noop}$on(type,callback){if(!is_function(callback)){return noop}const callbacks=this.$$.callbacks[type]||(this.$$.callbacks[type]=[]);callbacks.push(callback);return()=>{const index=callbacks.indexOf(callback);if(index!==-1)callbacks.splice(index,1)}}$set(props){if(this.$$set&&!is_empty(props)){this.$$.skip_bound=true;this.$$set(props);this.$$.skip_bound=false}}}const VERSION="4.2.19";const PUBLIC_VERSION="4";function dispatch_dev(type,detail){document.dispatchEvent(custom_event(type,{version:VERSION,...detail},{bubbles:true}))}function append_dev(target,node){dispatch_dev("SvelteDOMInsert",{target:target,node:node});append(target,node)}function insert_dev(target,node,anchor){dispatch_dev("SvelteDOMInsert",{target:target,node:node,anchor:anchor});insert(target,node,anchor)}function detach_dev(node){dispatch_dev("SvelteDOMRemove",{node:node});detach(node)}function listen_dev(node,event,handler,options,has_prevent_default,has_stop_propagation,has_stop_immediate_propagation){const modifiers=options===true?["capture"]:options?Array.from(Object.keys(options)):[];if(has_prevent_default)modifiers.push("preventDefault");if(has_stop_propagation)modifiers.push("stopPropagation");if(has_stop_immediate_propagation)modifiers.push("stopImmediatePropagation");dispatch_dev("SvelteDOMAddEventListener",{node:node,event:event,handler:handler,modifiers:modifiers});const dispose=listen(node,event,handler,options);return()=>{dispatch_dev("SvelteDOMRemoveEventListener",{node:node,event:event,handler:handler,modifiers:modifiers});dispose()}}function attr_dev(node,attribute,value){attr(node,attribute,value);if(value==null)dispatch_dev("SvelteDOMRemoveAttribute",{node:node,attribute:attribute});else dispatch_dev("SvelteDOMSetAttribute",{node:node,attribute:attribute,value:value})}function prop_dev(node,property,value){node[property]=value;dispatch_dev("SvelteDOMSetProperty",{node:node,property:property,value:value})}function set_data_dev(text,data){data=""+data;if(text.data===data)return;dispatch_dev("SvelteDOMSetData",{node:text,data:data});text.data=data}function ensure_array_like_dev(arg){if(typeof arg!=="string"&&!(arg&&typeof arg==="object"&&"length"in arg)&&!(typeof Symbol==="function"&&arg&&Symbol.iterator in arg)){throw new Error("{#each} only works with iterable values.")}return ensure_array_like(arg)}function validate_slots(name,slot,keys){for(const slot_key of Object.keys(slot)){if(!~keys.indexOf(slot_key)){console.warn(`<${name}> received an unexpected slot "${slot_key}".`)}}}function construct_svelte_component_dev(component,props){const error_message="this={...} of <svelte:component> should specify a Svelte component.";try{const instance=new component(props);if(!instance.$$||!instance.$set||!instance.$on||!instance.$destroy){throw new Error(error_message)}return instance}catch(err){const{message:message}=err;if(typeof message==="string"&&message.indexOf("is not a constructor")!==-1){throw new Error(error_message)}else{throw err}}}class SvelteComponentDev extends SvelteComponent{$$prop_def;$$events_def;$$slot_def;constructor(options){if(!options||!options.target&&!options.$$inline){throw new Error("'target' is a required option")}super()}$destroy(){super.$destroy();this.$destroy=()=>{console.warn("Component was already destroyed")}}$capture_state(){}$inject_state(){}}if(typeof window!=="undefined")(window.__svelte||(window.__svelte={v:new Set})).v.add(PUBLIC_VERSION);const subscriber_queue=[];function readable(value,start){return{subscribe:writable(value,start).subscribe}}function writable(value,start=noop){let stop;const subscribers=new Set;function set(new_value){if(safe_not_equal(value,new_value)){value=new_value;if(stop){const run_queue=!subscriber_queue.length;for(const subscriber of subscribers){subscriber[1]();subscriber_queue.push(subscriber,value)}if(run_queue){for(let i=0;i<subscriber_queue.length;i+=2){subscriber_queue[i][0](subscriber_queue[i+1])}subscriber_queue.length=0}}}}function update(fn){set(fn(value))}function subscribe(run,invalidate=noop){const subscriber=[run,invalidate];subscribers.add(subscriber);if(subscribers.size===1){stop=start(set,update)||noop}run(value);return()=>{subscribers.delete(subscriber);if(subscribers.size===0&&stop){stop();stop=null}}}return{set:set,update:update,subscribe:subscribe}}function derived(stores,fn,initial_value){const single=!Array.isArray(stores);const stores_array=single?[stores]:stores;if(!stores_array.every(Boolean)){throw new Error("derived() expects stores as input, got a falsy value")}const auto=fn.length<2;return readable(initial_value,((set,update)=>{let started=false;const values=[];let pending=0;let cleanup=noop;const sync=()=>{if(pending){return}cleanup();const result=fn(single?values[0]:values,set,update);if(auto){set(result)}else{cleanup=is_function(result)?result:noop}};const unsubscribers=stores_array.map(((store,i)=>subscribe(store,(value=>{values[i]=value;pending&=~(1<<i);if(started){sync()}}),(()=>{pending|=1<<i}))));started=true;sync();return function stop(){run_all(unsubscribers);cleanup();started=false}}))}function objectsDiffer([previous,current]){if(!previous||!current){return false}const prevKeys=Object.keys(previous);const currKeys=Object.keys(current);if(prevKeys.length!==currKeys.length){return true}if(prevKeys.filter((x=>!currKeys.includes(x))).concat(currKeys.filter((x=>!prevKeys.includes(x)))).length>0){return true}for(const key in previous){if(JSON.stringify(current[key])!==JSON.stringify(previous[key])){return true}}return false}const config=writable({});const settingsLocked=writable(false);const current_settings=derived(config,($config=>$config.settings));const defined_settings=derived(config,($config=>$config.defined_settings));const strings=derived(config,($config=>$config.strings));const nonce=derived(config,($config=>$config.nonce));const urls=derived(config,($config=>$config.urls));const docs=derived(config,($config=>$config.docs));const endpoints=derived(config,($config=>$config.endpoints));const diagnostics=derived(config,($config=>$config.diagnostics));const counts=derived(config,($config=>$config.counts));const summaryCounts=derived(config,($config=>$config.summary_counts));const offloadRemainingUpsell=derived(config,($config=>$config.offload_remaining_upsell));derived(config,($config=>$config.upgrades));const is_plugin_setup=derived(config,($config=>$config.is_plugin_setup));const is_plugin_setup_with_credentials=derived(config,($config=>$config.is_plugin_setup_with_credentials));const needs_access_keys=derived(config,($config=>$config.needs_access_keys));const bucket_writable=derived(config,($config=>$config.bucket_writable));const settings_validation=derived(config,($config=>$config.settings_validation));const settings_notifications=writable(new Map);const validationErrors=writable(new Map);const revalidatingSettings=writable(false);const needs_refresh=writable(false);const api={};function createSettings(){const{subscribe:subscribe,set:set,update:update}=writable([]);return{subscribe:subscribe,set:set,async save(){const json=await api.put("settings",get_store_value(this));if(json.hasOwnProperty("saved")&&true===json.saved){this.updateSettings(json);return json}return{saved:false}},reset(){set({...get_store_value(current_settings)})},async fetch(){const json=await api.get("settings",{});this.updateSettings(json)},updateSettings(json){if(json.hasOwnProperty("defined_settings")&&json.hasOwnProperty("settings")&&json.hasOwnProperty("storage_providers")&&json.hasOwnProperty("delivery_providers")&&json.hasOwnProperty("is_plugin_setup")&&json.hasOwnProperty("is_plugin_setup_with_credentials")&&json.hasOwnProperty("needs_access_keys")&&json.hasOwnProperty("bucket_writable")&&json.hasOwnProperty("urls")){config.update(($config=>({...$config,defined_settings:json.defined_settings,settings:json.settings,storage_providers:json.storage_providers,delivery_providers:json.delivery_providers,is_plugin_setup:json.is_plugin_setup,is_plugin_setup_with_credentials:json.is_plugin_setup_with_credentials,needs_access_keys:json.needs_access_keys,bucket_writable:json.bucket_writable,urls:json.urls})));update(($settings=>({...json.settings})))}}}}const settings=createSettings();const settings_changed=derived([settings,current_settings],objectsDiffer);const defaultStorageProvider=derived(config,($config=>$config.default_storage_provider));const storage_providers=derived([config,urls],(([$config,$urls])=>{for(const key in $config.storage_providers){$config.storage_providers[key].icon=$urls.assets+"img/icon/provider/storage/"+$config.storage_providers[key].provider_key_name+".svg";$config.storage_providers[key].link_icon=$urls.assets+"img/icon/provider/storage/"+$config.storage_providers[key].provider_key_name+"-link.svg";$config.storage_providers[key].round_icon=$urls.assets+"img/icon/provider/storage/"+$config.storage_providers[key].provider_key_name+"-round.svg"}return $config.storage_providers}));const storage_provider=derived([settings,storage_providers],(([$settings,$storage_providers])=>{if($settings.hasOwnProperty("provider")&&$storage_providers.hasOwnProperty($settings.provider)){return $storage_providers[$settings.provider]}else{return[]}}));derived(config,($config=>$config.default_delivery_provider));const delivery_providers=derived([config,urls,storage_provider],(([$config,$urls,$storage_provider])=>{for(const key in $config.delivery_providers){if("storage"===key){$config.delivery_providers[key].icon=$storage_provider.icon;$config.delivery_providers[key].round_icon=$storage_provider.round_icon;$config.delivery_providers[key].provider_service_quick_start_url=$storage_provider.provider_service_quick_start_url}else{$config.delivery_providers[key].icon=$urls.assets+"img/icon/provider/delivery/"+$config.delivery_providers[key].provider_key_name+".svg";$config.delivery_providers[key].round_icon=$urls.assets+"img/icon/provider/delivery/"+$config.delivery_providers[key].provider_key_name+"-round.svg"}}return $config.delivery_providers}));const delivery_provider=derived([settings,delivery_providers,urls],(([$settings,$delivery_providers,$urls])=>{if($settings.hasOwnProperty("delivery-provider")&&$delivery_providers.hasOwnProperty($settings["delivery-provider"])){return $delivery_providers[$settings["delivery-provider"]]}else{return[]}}));const region_name=derived([settings,storage_provider,strings],(([$settings,$storage_provider,$strings])=>{if($settings.region&&$storage_provider.regions&&$storage_provider.regions.hasOwnProperty($settings.region)){return $storage_provider.regions[$settings.region]}else if($settings.region&&$storage_provider.regions){return $strings.unknown}else if($storage_provider.default_region&&$storage_provider.regions&&$storage_provider.regions.hasOwnProperty($storage_provider.default_region)){return $storage_provider.regions[$storage_provider.default_region]}else{return $strings.unknown}}));const bapa=derived([settings,storage_provider],(([$settings,$storage_provider])=>$storage_provider.block_public_access_supported&&$settings.hasOwnProperty("block-public-access")&&$settings["block-public-access"]));const ooe=derived([settings,storage_provider],(([$settings,$storage_provider])=>$storage_provider.object_ownership_supported&&$settings.hasOwnProperty("object-ownership-enforced")&&$settings["object-ownership-enforced"]));function createNotifications(){const{subscribe:subscribe,set:set,update:update}=writable([]);return{set:set,subscribe:subscribe,add(notification){if(notification.hasOwnProperty("type")&&notification.type==="updated"){notification.type="success"}if(notification.hasOwnProperty("type")&&notification.type==="notice-warning"){notification.type="warning"}if(notification.hasOwnProperty("type")&&notification.type==="notice-info"){notification.type="info"}if(notification.hasOwnProperty("message")&&(!notification.hasOwnProperty("heading")||notification.heading.trim().length===0)){notification.heading=notification.message;notification.plainHeading=true;delete notification.message}if(!notification.hasOwnProperty("flash")){notification.flash=true}if(!notification.hasOwnProperty("id")){const idHeading=notification.hasOwnProperty("heading")?notification.heading.trim():"dynamic-heading";const idMessage=notification.hasOwnProperty("message")?notification.message.trim():"dynamic-message";notification.id=btoa(idHeading+idMessage)}const createdAt=notification.hasOwnProperty("created_at")?notification.created_at:0;notification.render_key=notification.id+"-"+createdAt;update(($notifications=>{let index=-1;if(notification.hasOwnProperty("id")){index=$notifications.findIndex((_notification=>_notification.id===notification.id))}if(index>=0){if($notifications[index].hasOwnProperty("dismissed")){if($notifications[index].dismissed<notification.created_at){$notifications.push(notification);$notifications.splice(index,1)}}else{$notifications.splice(index,1,notification)}}else{$notifications.push(notification)}return $notifications.sort(this.sortCompare)}))},sortCompare(a,b){if(a.created_at<b.created_at){return-1}if(a.created_at>b.created_at){return 1}return 0},async dismiss(id){update(($notifications=>{const index=$notifications.findIndex((notification=>notification.id===id));if(index>=0){if($notifications[index].hasOwnProperty("created_at")){$notifications[index].dismissed=$notifications[index].created_at}else{$notifications.splice(index,1)}}return $notifications}));await api.delete("notifications",{id:id,all_tabs:true})},delete(id){update(($notifications=>{const index=$notifications.findIndex((notification=>notification.id===id));if(index>=0){$notifications.splice(index,1)}return $notifications}))},cleanup(latest){update(($notifications=>{for(const[index,notification]of $notifications.entries()){if(notification.hasOwnProperty("dismissed")||notification.hasOwnProperty("created_at")){const latestIndex=latest.findIndex((_notification=>_notification.id===notification.id));if(latestIndex<0){$notifications.splice(index,1)}}}return $notifications}))}}}const notifications=createNotifications();let stateFetchInterval;let stateFetchIntervalStarted=false;let stateFetchIntervalPaused=false;const preStateUpdateCallbacks=writable([]);const postStateUpdateCallbacks=writable([]);function createState(){const{subscribe:subscribe,set:set,update:update}=writable([]);return{subscribe:subscribe,set:set,update:update,async fetch(){const json=await api.get("state",{});if(stateFetchIntervalStarted&&!stateFetchIntervalPaused){this.updateState(json)}},updateState(json){for(const callable of get_store_value(preStateUpdateCallbacks)){callable(json)}const dirty=get_store_value(settings_changed);const previous_settings={...get_store_value(current_settings)};config.update(($config=>({...$config,...json})));if(!dirty&&get_store_value(settings_changed)){settings.reset()}if(dirty&&objectsDiffer([previous_settings,get_store_value(current_settings)])){needs_refresh.update(($needs_refresh=>true));settings.reset()}for(const callable of get_store_value(postStateUpdateCallbacks)){callable(json)}},async startPeriodicFetch(){stateFetchIntervalStarted=true;stateFetchIntervalPaused=false;await this.fetch();stateFetchInterval=setInterval((async()=>{await this.fetch()}),5e3)},stopPeriodicFetch(){stateFetchIntervalStarted=false;stateFetchIntervalPaused=false;clearInterval(stateFetchInterval)},pausePeriodicFetch(){if(stateFetchIntervalStarted){stateFetchIntervalPaused=true;clearInterval(stateFetchInterval)}},async resumePeriodicFetch(){stateFetchIntervalPaused=false;if(stateFetchIntervalStarted){await this.startPeriodicFetch()}}}}const state=createState();api.headers=()=>({Accept:"application/json","Content-Type":"application/json","X-WP-Nonce":get_store_value(nonce)});api.url=endpoint=>get_store_value(urls).api+get_store_value(endpoints)[endpoint];api.get=async(endpoint,params)=>{let url=new URL(api.url(endpoint));const searchParams=new URLSearchParams(params);searchParams.forEach((function(value,name){url.searchParams.set(name,value)}));const response=await fetch(url.toString(),{method:"GET",headers:api.headers()});return response.json().then((json=>{json=api.check_response(json);return json}))};api.post=async(endpoint,body)=>{const response=await fetch(api.url(endpoint),{method:"POST",headers:api.headers(),body:JSON.stringify(body)});return response.json().then((json=>{json=api.check_response(json);return json}))};api.put=async(endpoint,body)=>{const response=await fetch(api.url(endpoint),{method:"PUT",headers:api.headers(),body:JSON.stringify(body)});return response.json().then((json=>{json=api.check_response(json);return json}))};api.delete=async(endpoint,body)=>{const response=await fetch(api.url(endpoint),{method:"DELETE",headers:api.headers(),body:JSON.stringify(body)});return response.json().then((json=>{json=api.check_response(json);return json}))};api.check_errors=json=>{if(json.code&&json.message){notifications.add({id:json.code,type:"error",dismissible:true,heading:get_store_value(strings).api_error_notice_heading,message:json.message});delete json.code;delete json.message}return json};api.check_notifications=json=>{const _notifications=json.hasOwnProperty("notifications")?json.notifications:[];if(_notifications){for(const notification of _notifications){notifications.add(notification)}}notifications.cleanup(_notifications);delete json.notifications;return json};api.check_response=json=>{json=api.check_notifications(json);json=api.check_errors(json);return json};const licence=derived(config,($config=>$config.hasOwnProperty("licences")?$config.licences.at(0):[]));const offloadRemainingWithCount=derived(config,($config=>$config.offload_remaining_with_count));const documentation=derived(config,($config=>$config.documentation));const toolsLocked=writable(false);const running=writable("");const toolIcons={"add-metadata":"offload","reverse-add-metadata":"analyzerepair","verify-add-metadata":"analyzerepair","copy-buckets":"move","download-and-remover":"remove",downloader:"download","elementor-analyze-and-repair":"analyzerepair","move-objects":"move","move-private-objects":"move","move-public-objects":"move","remove-local-files":"clean","update-acls":"analyzerepair",uploader:"offload","woocommerce-product-urls":"analyzerepair"};function createTools(){const{subscribe:subscribe,set:set,update:update}=writable({});return{subscribe:subscribe,set:set,async action(tool,action){state.pausePeriodicFetch();tool.status_description=tool.busy_description;tool.short_status_description=tool.busy_description;update((_tools=>{_tools[tool.id]=tool;return _tools}));let result={};const json=await api.put("tools",{id:tool.id,action:action});if(json.hasOwnProperty("ok")){result=json}await state.resumePeriodicFetch();return result},async start(tool){running.update((_running=>tool.id));tool.is_queued=true;return await this.action(tool,"start")},async cancel(tool){tool.is_cancelled=true;return await this.action(tool,"cancel")},async pauseResume(tool){tool.is_paused=!tool.is_paused;return await this.action(tool,"pause_resume")},updateTools(json){if(json.hasOwnProperty("tools")){update((_tools=>({...json.tools})));const runningTool=Object.values(json.tools).find((tool=>tool.is_processing||tool.is_queued||tool.is_paused||tool.is_cancelled));if(runningTool){running.update((_running=>runningTool.id))}else{running.update((_running=>""))}}},icon(tool,isRunning,animated){let icon="tool-generic";let type="default";if(isRunning){if(tool.is_paused){type="paused"}else if(animated){type="running-animated"}else{type="active"}}if(tool&&tool.hasOwnProperty("slug")&&toolIcons.hasOwnProperty(tool.slug)){icon="tool-"+toolIcons[tool.slug]}if(["active","default","paused","running-animated"].includes(type)){icon=icon+"-"+type+".svg"}else{icon=icon+"-default.svg"}return icon}}}const tools=createTools();const assetsNeedsRefresh=writable(false);const assetsSettingsLocked=writable(false);const currentAssetsSettings=derived(config,($config=>$config.assets_settings));const assetsDefinedSettings=derived(config,($config=>$config.assets_defined_settings));derived(config,($config=>$config.assets_domain_check));const enableAssets=derived([licence,config],(([$licence,$config])=>{if($licence.hasOwnProperty("is_set")&&$licence.is_set&&$licence.hasOwnProperty("is_valid")&&$licence.is_valid&&$config.hasOwnProperty("assets_settings")){return true}return false}));function createAssetsSettings(){const{subscribe:subscribe,set:set,update:update}=writable([]);return{subscribe:subscribe,set:set,async save(){const json=await api.put("assets-settings",get_store_value(this));if(json.hasOwnProperty("saved")&&true===json.saved){this.updateSettings(json);return json}return{}},reset(){set({...get_store_value(currentAssetsSettings)})},async fetch(){const json=await api.get("assets-settings",{});this.updateSettings(json)},updateSettings(json){if(json.hasOwnProperty("assets_defined_settings")&&json.hasOwnProperty("assets_settings")){const dirty=get_store_value(assetsSettingsChanged);const previousSettings={...get_store_value(currentAssetsSettings)};config.update((_config=>({..._config,assets_defined_settings:json.assets_defined_settings,assets_settings:json.assets_settings})));if(json.hasOwnProperty("saved")&&true===json.saved){return}if(!dirty&&get_store_value(assetsSettingsChanged)){assetsSettings.reset()}if(dirty&&objectsDiffer([previousSettings,get_store_value(currentAssetsSettings)])){assetsNeedsRefresh.update((_needsRefresh=>true));assetsSettings.reset()}}}}}const assetsSettings=createAssetsSettings();const assetsSettingsChanged=derived([assetsSettings,currentAssetsSettings],objectsDiffer);function wrap(args){if(!args){throw Error("Parameter args is required")}if(!args.component==!args.asyncComponent){throw Error("One and only one of component and asyncComponent is required")}if(args.component){args.asyncComponent=()=>Promise.resolve(args.component)}if(typeof args.asyncComponent!="function"){throw Error("Parameter asyncComponent must be a function")}if(args.conditions){if(!Array.isArray(args.conditions)){args.conditions=[args.conditions]}for(let i=0;i<args.conditions.length;i++){if(!args.conditions[i]||typeof args.conditions[i]!="function"){throw Error("Invalid parameter conditions["+i+"]")}}}if(args.loadingComponent){args.asyncComponent.loading=args.loadingComponent;args.asyncComponent.loadingParams=args.loadingParams||undefined}const obj={component:args.asyncComponent,userData:args.userData,conditions:args.conditions&&args.conditions.length?args.conditions:undefined,props:args.props&&Object.keys(args.props).length?args.props:{},_sveltesparouter:true};return obj}function createPages(){const{subscribe:subscribe,set:set,update:update}=writable([]);return{subscribe:subscribe,set:set,add(page){update(($pages=>[...$pages,page].sort(((a,b)=>a.position-b.position))))},withPrefix(prefix=null){return get_store_value(this).filter((page=>prefix&&page.route.startsWith(prefix)||!prefix))},routes(prefix=null){let defaultComponent=null;let defaultUserData=null;const routes=new Map;const conditions=[detail=>{if(detail.hasOwnProperty("userData")&&detail.userData.hasOwnProperty("page")&&detail.userData.page.hasOwnProperty("enabled")){return detail.userData.page.enabled()}return true}];for(const page of this.withPrefix(prefix)){const userData={page:page};let route=page.route;if(prefix&&route!==prefix+"/*"){route=route.replace(prefix,"")}routes.set(route,wrap({component:page.component,userData:userData,conditions:conditions}));if(!defaultComponent&&page.default){defaultComponent=page.component;defaultUserData=userData}}if(defaultComponent){routes.set("*",wrap({component:defaultComponent,userData:defaultUserData,conditions:conditions}))}return routes},handleRouteEvent(detail){if(detail.hasOwnProperty("event")){if(!detail.hasOwnProperty("data")){detail.data={}}let route=false;for(const page of get_store_value(this).values()){if(page.events&&page.events[detail.event]&&page.events[detail.event](detail.data)&&!route){route=page.route}}if(route){return route}}if(detail.hasOwnProperty("default")){return detail.default}return false}}}const pages=createPages();const routes=derived(pages,(()=>pages.routes()));function parse(str,loose){if(str instanceof RegExp)return{keys:false,pattern:str};var c,o,tmp,ext,keys=[],pattern="",arr=str.split("/");arr[0]||arr.shift();while(tmp=arr.shift()){c=tmp[0];if(c==="*"){keys.push("wild");pattern+="/(.*)"}else if(c===":"){o=tmp.indexOf("?",1);ext=tmp.indexOf(".",1);keys.push(tmp.substring(1,!!~o?o:!!~ext?ext:tmp.length));pattern+=!!~o&&!~ext?"(?:/([^/]+?))?":"/([^/]+?)";if(!!~ext)pattern+=(!!~o?"?":"")+"\\"+tmp.substring(ext)}else{pattern+="/"+tmp}}return{keys:keys,pattern:new RegExp("^"+pattern+(loose?"(?=$|/)":"/?$"),"i")}}const{Error:Error_1,Object:Object_1$8,console:console_1}=globals;function create_else_block$g(ctx){let switch_instance;let switch_instance_anchor;let current;const switch_instance_spread_levels=[ctx[2]];var switch_value=ctx[0];function switch_props(ctx,dirty){let switch_instance_props={};for(let i=0;i<switch_instance_spread_levels.length;i+=1){switch_instance_props=assign(switch_instance_props,switch_instance_spread_levels[i])}if(dirty!==undefined&&dirty&4){switch_instance_props=assign(switch_instance_props,get_spread_update(switch_instance_spread_levels,[get_spread_object(ctx[2])]))}return{props:switch_instance_props,$$inline:true}}if(switch_value){switch_instance=construct_svelte_component_dev(switch_value,switch_props(ctx));switch_instance.$on("routeEvent",ctx[7])}const block={c:function create(){if(switch_instance)create_component(switch_instance.$$.fragment);switch_instance_anchor=empty()},m:function mount(target,anchor){if(switch_instance)mount_component(switch_instance,target,anchor);insert_dev(target,switch_instance_anchor,anchor);current=true},p:function update(ctx,dirty){if(dirty&1&&switch_value!==(switch_value=ctx[0])){if(switch_instance){group_outros();const old_component=switch_instance;transition_out(old_component.$$.fragment,1,0,(()=>{destroy_component(old_component,1)}));check_outros()}if(switch_value){switch_instance=construct_svelte_component_dev(switch_value,switch_props(ctx,dirty));switch_instance.$on("routeEvent",ctx[7]);create_component(switch_instance.$$.fragment);transition_in(switch_instance.$$.fragment,1);mount_component(switch_instance,switch_instance_anchor.parentNode,switch_instance_anchor)}else{switch_instance=null}}else if(switch_value){const switch_instance_changes=dirty&4?get_spread_update(switch_instance_spread_levels,[get_spread_object(ctx[2])]):{};switch_instance.$set(switch_instance_changes)}},i:function intro(local){if(current)return;if(switch_instance)transition_in(switch_instance.$$.fragment,local);current=true},o:function outro(local){if(switch_instance)transition_out(switch_instance.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(switch_instance_anchor)}if(switch_instance)destroy_component(switch_instance,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block$g.name,type:"else",source:"(246:0) {:else}",ctx:ctx});return block}function create_if_block$D(ctx){let switch_instance;let switch_instance_anchor;let current;const switch_instance_spread_levels=[{params:ctx[1]},ctx[2]];var switch_value=ctx[0];function switch_props(ctx,dirty){let switch_instance_props={};for(let i=0;i<switch_instance_spread_levels.length;i+=1){switch_instance_props=assign(switch_instance_props,switch_instance_spread_levels[i])}if(dirty!==undefined&&dirty&6){switch_instance_props=assign(switch_instance_props,get_spread_update(switch_instance_spread_levels,[dirty&2&&{params:ctx[1]},dirty&4&&get_spread_object(ctx[2])]))}return{props:switch_instance_props,$$inline:true}}if(switch_value){switch_instance=construct_svelte_component_dev(switch_value,switch_props(ctx));switch_instance.$on("routeEvent",ctx[6])}const block={c:function create(){if(switch_instance)create_component(switch_instance.$$.fragment);switch_instance_anchor=empty()},m:function mount(target,anchor){if(switch_instance)mount_component(switch_instance,target,anchor);insert_dev(target,switch_instance_anchor,anchor);current=true},p:function update(ctx,dirty){if(dirty&1&&switch_value!==(switch_value=ctx[0])){if(switch_instance){group_outros();const old_component=switch_instance;transition_out(old_component.$$.fragment,1,0,(()=>{destroy_component(old_component,1)}));check_outros()}if(switch_value){switch_instance=construct_svelte_component_dev(switch_value,switch_props(ctx,dirty));switch_instance.$on("routeEvent",ctx[6]);create_component(switch_instance.$$.fragment);transition_in(switch_instance.$$.fragment,1);mount_component(switch_instance,switch_instance_anchor.parentNode,switch_instance_anchor)}else{switch_instance=null}}else if(switch_value){const switch_instance_changes=dirty&6?get_spread_update(switch_instance_spread_levels,[dirty&2&&{params:ctx[1]},dirty&4&&get_spread_object(ctx[2])]):{};switch_instance.$set(switch_instance_changes)}},i:function intro(local){if(current)return;if(switch_instance)transition_in(switch_instance.$$.fragment,local);current=true},o:function outro(local){if(switch_instance)transition_out(switch_instance.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(switch_instance_anchor)}if(switch_instance)destroy_component(switch_instance,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$D.name,type:"if",source:"(239:0) {#if componentParams}",ctx:ctx});return block}function create_fragment$1e(ctx){let current_block_type_index;let if_block;let if_block_anchor;let current;const if_block_creators=[create_if_block$D,create_else_block$g];const if_blocks=[];function select_block_type(ctx,dirty){if(ctx[1])return 0;return 1}current_block_type_index=select_block_type(ctx);if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);const block={c:function create(){if_block.c();if_block_anchor=empty()},l:function claim(nodes){throw new Error_1("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){if_blocks[current_block_type_index].m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,[dirty]){let previous_block_index=current_block_type_index;current_block_type_index=select_block_type(ctx);if(current_block_type_index===previous_block_index){if_blocks[current_block_type_index].p(ctx,dirty)}else{group_outros();transition_out(if_blocks[previous_block_index],1,1,(()=>{if_blocks[previous_block_index]=null}));check_outros();if_block=if_blocks[current_block_type_index];if(!if_block){if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);if_block.c()}else{if_block.p(ctx,dirty)}transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if_blocks[current_block_type_index].d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$1e.name,type:"component",source:"",ctx:ctx});return block}function getLocation(){const hashPosition=window.location.href.indexOf("#/");let location=hashPosition>-1?window.location.href.substr(hashPosition+1):"/";const qsPosition=location.indexOf("?");let querystring="";if(qsPosition>-1){querystring=location.substr(qsPosition+1);location=location.substr(0,qsPosition)}return{location:location,querystring:querystring}}const loc=readable(null,(function start(set){set(getLocation());const update=()=>{set(getLocation())};window.addEventListener("hashchange",update,false);return function stop(){window.removeEventListener("hashchange",update,false)}}));const location$1=derived(loc,(_loc=>_loc.location));const querystring=derived(loc,(_loc=>_loc.querystring));const params=writable(undefined);async function push(location){if(!location||location.length<1||location.charAt(0)!="/"&&location.indexOf("#/")!==0){throw Error("Invalid parameter location")}await tick();history.replaceState({...history.state,__svelte_spa_router_scrollX:window.scrollX,__svelte_spa_router_scrollY:window.scrollY},undefined);window.location.hash=(location.charAt(0)=="#"?"":"#")+location}async function pop(){await tick();window.history.back()}async function replace(location){if(!location||location.length<1||location.charAt(0)!="/"&&location.indexOf("#/")!==0){throw Error("Invalid parameter location")}await tick();const dest=(location.charAt(0)=="#"?"":"#")+location;try{const newState={...history.state};delete newState["__svelte_spa_router_scrollX"];delete newState["__svelte_spa_router_scrollY"];window.history.replaceState(newState,undefined,dest)}catch(e){console.warn("Caught exception while replacing the current page. If you're running this in the Svelte REPL, please note that the `replace` method might not work in this environment.")}window.dispatchEvent(new Event("hashchange"))}function link(node,opts){opts=linkOpts(opts);if(!node||!node.tagName||node.tagName.toLowerCase()!="a"){throw Error('Action "link" can only be used with <a> tags')}updateLink(node,opts);return{update(updated){updated=linkOpts(updated);updateLink(node,updated)}}}function restoreScroll(state){if(state){window.scrollTo(state.__svelte_spa_router_scrollX,state.__svelte_spa_router_scrollY)}else{window.scrollTo(0,0)}}function updateLink(node,opts){let href=opts.href||node.getAttribute("href");if(href&&href.charAt(0)=="/"){href="#"+href}else if(!href||href.length<2||href.slice(0,2)!="#/"){throw Error('Invalid value for "href" attribute: '+href)}node.setAttribute("href",href);node.addEventListener("click",(event=>{event.preventDefault();if(!opts.disabled){scrollstateHistoryHandler(event.currentTarget.getAttribute("href"))}}))}function linkOpts(val){if(val&&typeof val=="string"){return{href:val}}else{return val||{}}}function scrollstateHistoryHandler(href){history.replaceState({...history.state,__svelte_spa_router_scrollX:window.scrollX,__svelte_spa_router_scrollY:window.scrollY},undefined);window.location.hash=href}function instance$1e($$self,$$props,$$invalidate){let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("Router",slots,[]);let{routes:routes={}}=$$props;let{prefix:prefix=""}=$$props;let{restoreScrollState:restoreScrollState=false}=$$props;class RouteItem{constructor(path,component){if(!component||typeof component!="function"&&(typeof component!="object"||component._sveltesparouter!==true)){throw Error("Invalid component object")}if(!path||typeof path=="string"&&(path.length<1||path.charAt(0)!="/"&&path.charAt(0)!="*")||typeof path=="object"&&!(path instanceof RegExp)){throw Error('Invalid value for "path" argument - strings must start with / or *')}const{pattern:pattern,keys:keys}=parse(path);this.path=path;if(typeof component=="object"&&component._sveltesparouter===true){this.component=component.component;this.conditions=component.conditions||[];this.userData=component.userData;this.props=component.props||{}}else{this.component=()=>Promise.resolve(component);this.conditions=[];this.props={}}this._pattern=pattern;this._keys=keys}match(path){if(prefix){if(typeof prefix=="string"){if(path.startsWith(prefix)){path=path.substr(prefix.length)||"/"}else{return null}}else if(prefix instanceof RegExp){const match=path.match(prefix);if(match&&match[0]){path=path.substr(match[0].length)||"/"}else{return null}}}const matches=this._pattern.exec(path);if(matches===null){return null}if(this._keys===false){return matches}const out={};let i=0;while(i<this._keys.length){try{out[this._keys[i]]=decodeURIComponent(matches[i+1]||"")||null}catch(e){out[this._keys[i]]=null}i++}return out}async checkConditions(detail){for(let i=0;i<this.conditions.length;i++){if(!await this.conditions[i](detail)){return false}}return true}}const routesList=[];if(routes instanceof Map){routes.forEach(((route,path)=>{routesList.push(new RouteItem(path,route))}))}else{Object.keys(routes).forEach((path=>{routesList.push(new RouteItem(path,routes[path]))}))}let component=null;let componentParams=null;let props={};const dispatch=createEventDispatcher();async function dispatchNextTick(name,detail){await tick();dispatch(name,detail)}let previousScrollState=null;let popStateChanged=null;if(restoreScrollState){popStateChanged=event=>{if(event.state&&(event.state.__svelte_spa_router_scrollY||event.state.__svelte_spa_router_scrollX)){previousScrollState=event.state}else{previousScrollState=null}};window.addEventListener("popstate",popStateChanged);afterUpdate((()=>{restoreScroll(previousScrollState)}))}let lastLoc=null;let componentObj=null;const unsubscribeLoc=loc.subscribe((async newLoc=>{lastLoc=newLoc;let i=0;while(i<routesList.length){const match=routesList[i].match(newLoc.location);if(!match){i++;continue}const detail={route:routesList[i].path,location:newLoc.location,querystring:newLoc.querystring,userData:routesList[i].userData,params:match&&typeof match=="object"&&Object.keys(match).length?match:null};if(!await routesList[i].checkConditions(detail)){$$invalidate(0,component=null);componentObj=null;dispatchNextTick("conditionsFailed",detail);return}dispatchNextTick("routeLoading",Object.assign({},detail));const obj=routesList[i].component;if(componentObj!=obj){if(obj.loading){$$invalidate(0,component=obj.loading);componentObj=obj;$$invalidate(1,componentParams=obj.loadingParams);$$invalidate(2,props={});dispatchNextTick("routeLoaded",Object.assign({},detail,{component:component,name:component.name,params:componentParams}))}else{$$invalidate(0,component=null);componentObj=null}const loaded=await obj();if(newLoc!=lastLoc){return}$$invalidate(0,component=loaded&&loaded.default||loaded);componentObj=obj}if(match&&typeof match=="object"&&Object.keys(match).length){$$invalidate(1,componentParams=match)}else{$$invalidate(1,componentParams=null)}$$invalidate(2,props=routesList[i].props);dispatchNextTick("routeLoaded",Object.assign({},detail,{component:component,name:component.name,params:componentParams})).then((()=>{params.set(componentParams)}));return}$$invalidate(0,component=null);componentObj=null;params.set(undefined)}));onDestroy((()=>{unsubscribeLoc();popStateChanged&&window.removeEventListener("popstate",popStateChanged)}));const writable_props=["routes","prefix","restoreScrollState"];Object_1$8.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console_1.warn(`<Router> was created with unknown prop '${key}'`)}));function routeEvent_handler(event){bubble.call(this,$$self,event)}function routeEvent_handler_1(event){bubble.call(this,$$self,event)}$$self.$$set=$$props=>{if("routes"in $$props)$$invalidate(3,routes=$$props.routes);if("prefix"in $$props)$$invalidate(4,prefix=$$props.prefix);if("restoreScrollState"in $$props)$$invalidate(5,restoreScrollState=$$props.restoreScrollState)};$$self.$capture_state=()=>({readable:readable,writable:writable,derived:derived,tick:tick,getLocation:getLocation,loc:loc,location:location$1,querystring:querystring,params:params,push:push,pop:pop,replace:replace,link:link,restoreScroll:restoreScroll,updateLink:updateLink,linkOpts:linkOpts,scrollstateHistoryHandler:scrollstateHistoryHandler,onDestroy:onDestroy,createEventDispatcher:createEventDispatcher,afterUpdate:afterUpdate,parse:parse,routes:routes,prefix:prefix,restoreScrollState:restoreScrollState,RouteItem:RouteItem,routesList:routesList,component:component,componentParams:componentParams,props:props,dispatch:dispatch,dispatchNextTick:dispatchNextTick,previousScrollState:previousScrollState,popStateChanged:popStateChanged,lastLoc:lastLoc,componentObj:componentObj,unsubscribeLoc:unsubscribeLoc});$$self.$inject_state=$$props=>{if("routes"in $$props)$$invalidate(3,routes=$$props.routes);if("prefix"in $$props)$$invalidate(4,prefix=$$props.prefix);if("restoreScrollState"in $$props)$$invalidate(5,restoreScrollState=$$props.restoreScrollState);if("component"in $$props)$$invalidate(0,component=$$props.component);if("componentParams"in $$props)$$invalidate(1,componentParams=$$props.componentParams);if("props"in $$props)$$invalidate(2,props=$$props.props);if("previousScrollState"in $$props)previousScrollState=$$props.previousScrollState;if("popStateChanged"in $$props)popStateChanged=$$props.popStateChanged;if("lastLoc"in $$props)lastLoc=$$props.lastLoc;if("componentObj"in $$props)componentObj=$$props.componentObj};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty&32){history.scrollRestoration=restoreScrollState?"manual":"auto"}};return[component,componentParams,props,routes,prefix,restoreScrollState,routeEvent_handler,routeEvent_handler_1]}class Router extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$1e,create_fragment$1e,safe_not_equal,{routes:3,prefix:4,restoreScrollState:5});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"Router",options:options,id:create_fragment$1e.name})}get routes(){throw new Error_1("<Router>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set routes(value){throw new Error_1("<Router>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get prefix(){throw new Error_1("<Router>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set prefix(value){throw new Error_1("<Router>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get restoreScrollState(){throw new Error_1("<Router>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set restoreScrollState(value){throw new Error_1("<Router>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$12="ui/components/Page.svelte";function create_fragment$1d(ctx){let div;let div_class_value;let current;const default_slot_template=ctx[4].default;const default_slot=create_slot(default_slot_template,ctx,ctx[3],null);const block={c:function create(){div=element("div");if(default_slot)default_slot.c();attr_dev(div,"class",div_class_value="page-wrapper "+ctx[0]);toggle_class(div,"subpage",ctx[1]);add_location(div,file$12,30,0,796)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,div,anchor);if(default_slot){default_slot.m(div,null)}current=true},p:function update(ctx,[dirty]){if(default_slot){if(default_slot.p&&(!current||dirty&8)){update_slot_base(default_slot,default_slot_template,ctx,ctx[3],!current?get_all_dirty_from_scope(ctx[3]):get_slot_changes(default_slot_template,ctx[3],dirty,null),null)}}if(!current||dirty&1&&div_class_value!==(div_class_value="page-wrapper "+ctx[0])){attr_dev(div,"class",div_class_value)}if(!current||dirty&3){toggle_class(div,"subpage",ctx[1])}},i:function intro(local){if(current)return;transition_in(default_slot,local);current=true},o:function outro(local){transition_out(default_slot,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(div)}if(default_slot)default_slot.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$1d.name,type:"component",source:"",ctx:ctx});return block}function instance$1d($$self,$$props,$$invalidate){let $location;let $current_settings;validate_store(location$1,"location");component_subscribe($$self,location$1,($$value=>$$invalidate(5,$location=$$value)));validate_store(current_settings,"current_settings");component_subscribe($$self,current_settings,($$value=>$$invalidate(6,$current_settings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("Page",slots,["default"]);let{name:name=""}=$$props;let{subpage:subpage=false}=$$props;let{initialSettings:initialSettings=$current_settings}=$$props;const dispatch=createEventDispatcher();setContext("initialSettings",initialSettings);onMount((()=>{dispatch("routeEvent",{event:"page.initial.settings",data:{settings:initialSettings,location:$location}})}));const writable_props=["name","subpage","initialSettings"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<Page> was created with unknown prop '${key}'`)}));$$self.$$set=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name);if("subpage"in $$props)$$invalidate(1,subpage=$$props.subpage);if("initialSettings"in $$props)$$invalidate(2,initialSettings=$$props.initialSettings);if("$$scope"in $$props)$$invalidate(3,$$scope=$$props.$$scope)};$$self.$capture_state=()=>({onMount:onMount,createEventDispatcher:createEventDispatcher,setContext:setContext,location:location$1,current_settings:current_settings,name:name,subpage:subpage,initialSettings:initialSettings,dispatch:dispatch,$location:$location,$current_settings:$current_settings});$$self.$inject_state=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name);if("subpage"in $$props)$$invalidate(1,subpage=$$props.subpage);if("initialSettings"in $$props)$$invalidate(2,initialSettings=$$props.initialSettings)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[name,subpage,initialSettings,$$scope,slots]}class Page extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$1d,create_fragment$1d,safe_not_equal,{name:0,subpage:1,initialSettings:2});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"Page",options:options,id:create_fragment$1d.name})}get name(){throw new Error("<Page>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set name(value){throw new Error("<Page>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get subpage(){throw new Error("<Page>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set subpage(value){throw new Error("<Page>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get initialSettings(){throw new Error("<Page>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set initialSettings(value){throw new Error("<Page>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$11="ui/components/Button.svelte";function create_if_block$C(ctx){let img;let img_src_value;const block={c:function create(){img=element("img");attr_dev(img,"class","icon refresh");if(!src_url_equal(img.src,img_src_value=ctx[15](ctx[11])))attr_dev(img,"src",img_src_value);attr_dev(img,"alt",ctx[12]);toggle_class(img,"refreshing",ctx[11]);add_location(img,file$11,72,2,1802)},m:function mount(target,anchor){insert_dev(target,img,anchor)},p:function update(ctx,dirty){if(dirty&2048&&!src_url_equal(img.src,img_src_value=ctx[15](ctx[11]))){attr_dev(img,"src",img_src_value)}if(dirty&4096){attr_dev(img,"alt",ctx[12])}if(dirty&2048){toggle_class(img,"refreshing",ctx[11])}},d:function destroy(detaching){if(detaching){detach_dev(img)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$C.name,type:"if",source:"(72:1) {#if refresh}",ctx:ctx});return block}function create_fragment$1c(ctx){let button;let t;let button_disabled_value;let current;let mounted;let dispose;let if_block=ctx[7]&&create_if_block$C(ctx);const default_slot_template=ctx[17].default;const default_slot=create_slot(default_slot_template,ctx,ctx[16],null);const block={c:function create(){button=element("button");if(if_block)if_block.c();t=space();if(default_slot)default_slot.c();attr_dev(button,"class",ctx[13]);attr_dev(button,"title",ctx[12]);button.disabled=button_disabled_value=ctx[9]||ctx[11];toggle_class(button,"btn-xs",ctx[1]);toggle_class(button,"btn-sm",ctx[2]);toggle_class(button,"btn-md",ctx[4]);toggle_class(button,"btn-lg",ctx[3]);toggle_class(button,"btn-primary",ctx[5]);toggle_class(button,"btn-outline",ctx[8]);toggle_class(button,"btn-expandable",ctx[6]);toggle_class(button,"btn-disabled",ctx[9]);toggle_class(button,"btn-expanded",ctx[10]);toggle_class(button,"btn-refresh",ctx[7]);toggle_class(button,"btn-refreshing",ctx[11]);add_location(button,file$11,51,0,1322)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,button,anchor);if(if_block)if_block.m(button,null);append_dev(button,t);if(default_slot){default_slot.m(button,null)}ctx[20](button);current=true;if(!mounted){dispose=[listen_dev(button,"click",prevent_default(ctx[18]),false,true,false,false),listen_dev(button,"focusout",ctx[19],false,false,false,false),listen_dev(button,"keyup",ctx[14],false,false,false,false)];mounted=true}},p:function update(ctx,[dirty]){if(ctx[7]){if(if_block){if_block.p(ctx,dirty)}else{if_block=create_if_block$C(ctx);if_block.c();if_block.m(button,t)}}else if(if_block){if_block.d(1);if_block=null}if(default_slot){if(default_slot.p&&(!current||dirty&65536)){update_slot_base(default_slot,default_slot_template,ctx,ctx[16],!current?get_all_dirty_from_scope(ctx[16]):get_slot_changes(default_slot_template,ctx[16],dirty,null),null)}}if(!current||dirty&4096){attr_dev(button,"title",ctx[12])}if(!current||dirty&2560&&button_disabled_value!==(button_disabled_value=ctx[9]||ctx[11])){prop_dev(button,"disabled",button_disabled_value)}if(!current||dirty&2){toggle_class(button,"btn-xs",ctx[1])}if(!current||dirty&4){toggle_class(button,"btn-sm",ctx[2])}if(!current||dirty&16){toggle_class(button,"btn-md",ctx[4])}if(!current||dirty&8){toggle_class(button,"btn-lg",ctx[3])}if(!current||dirty&32){toggle_class(button,"btn-primary",ctx[5])}if(!current||dirty&256){toggle_class(button,"btn-outline",ctx[8])}if(!current||dirty&64){toggle_class(button,"btn-expandable",ctx[6])}if(!current||dirty&512){toggle_class(button,"btn-disabled",ctx[9])}if(!current||dirty&1024){toggle_class(button,"btn-expanded",ctx[10])}if(!current||dirty&128){toggle_class(button,"btn-refresh",ctx[7])}if(!current||dirty&2048){toggle_class(button,"btn-refreshing",ctx[11])}},i:function intro(local){if(current)return;transition_in(default_slot,local);current=true},o:function outro(local){transition_out(default_slot,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(button)}if(if_block)if_block.d();if(default_slot)default_slot.d(detaching);ctx[20](null);mounted=false;run_all(dispose)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$1c.name,type:"component",source:"",ctx:ctx});return block}function instance$1c($$self,$$props,$$invalidate){let $urls;validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(21,$urls=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("Button",slots,["default"]);const classes=$$props.class?$$props.class:"";const dispatch=createEventDispatcher();let{ref:ref={}}=$$props;let{extraSmall:extraSmall=false}=$$props;let{small:small=false}=$$props;let{large:large=false}=$$props;let{medium:medium=!extraSmall&&!small&&!large}=$$props;let{primary:primary=false}=$$props;let{expandable:expandable=false}=$$props;let{refresh:refresh=false}=$$props;let{outline:outline=!primary&&!expandable&&!refresh}=$$props;let{disabled:disabled=false}=$$props;let{expanded:expanded=false}=$$props;let{refreshing:refreshing=false}=$$props;let{title:title=""}=$$props;function handleKeyup(event){if(event.key==="Escape"){event.preventDefault();dispatch("cancel")}}function refreshIcon(refreshing){return $urls.assets+"img/icon/"+(refreshing?"refresh-disabled.svg":"refresh.svg")}function click_handler(event){bubble.call(this,$$self,event)}function focusout_handler(event){bubble.call(this,$$self,event)}function button_binding($$value){binding_callbacks[$$value?"unshift":"push"]((()=>{ref=$$value;$$invalidate(0,ref)}))}$$self.$$set=$$new_props=>{$$invalidate(23,$$props=assign(assign({},$$props),exclude_internal_props($$new_props)));if("ref"in $$new_props)$$invalidate(0,ref=$$new_props.ref);if("extraSmall"in $$new_props)$$invalidate(1,extraSmall=$$new_props.extraSmall);if("small"in $$new_props)$$invalidate(2,small=$$new_props.small);if("large"in $$new_props)$$invalidate(3,large=$$new_props.large);if("medium"in $$new_props)$$invalidate(4,medium=$$new_props.medium);if("primary"in $$new_props)$$invalidate(5,primary=$$new_props.primary);if("expandable"in $$new_props)$$invalidate(6,expandable=$$new_props.expandable);if("refresh"in $$new_props)$$invalidate(7,refresh=$$new_props.refresh);if("outline"in $$new_props)$$invalidate(8,outline=$$new_props.outline);if("disabled"in $$new_props)$$invalidate(9,disabled=$$new_props.disabled);if("expanded"in $$new_props)$$invalidate(10,expanded=$$new_props.expanded);if("refreshing"in $$new_props)$$invalidate(11,refreshing=$$new_props.refreshing);if("title"in $$new_props)$$invalidate(12,title=$$new_props.title);if("$$scope"in $$new_props)$$invalidate(16,$$scope=$$new_props.$$scope)};$$self.$capture_state=()=>({createEventDispatcher:createEventDispatcher,urls:urls,classes:classes,dispatch:dispatch,ref:ref,extraSmall:extraSmall,small:small,large:large,medium:medium,primary:primary,expandable:expandable,refresh:refresh,outline:outline,disabled:disabled,expanded:expanded,refreshing:refreshing,title:title,handleKeyup:handleKeyup,refreshIcon:refreshIcon,$urls:$urls});$$self.$inject_state=$$new_props=>{$$invalidate(23,$$props=assign(assign({},$$props),$$new_props));if("ref"in $$props)$$invalidate(0,ref=$$new_props.ref);if("extraSmall"in $$props)$$invalidate(1,extraSmall=$$new_props.extraSmall);if("small"in $$props)$$invalidate(2,small=$$new_props.small);if("large"in $$props)$$invalidate(3,large=$$new_props.large);if("medium"in $$props)$$invalidate(4,medium=$$new_props.medium);if("primary"in $$props)$$invalidate(5,primary=$$new_props.primary);if("expandable"in $$props)$$invalidate(6,expandable=$$new_props.expandable);if("refresh"in $$props)$$invalidate(7,refresh=$$new_props.refresh);if("outline"in $$props)$$invalidate(8,outline=$$new_props.outline);if("disabled"in $$props)$$invalidate(9,disabled=$$new_props.disabled);if("expanded"in $$props)$$invalidate(10,expanded=$$new_props.expanded);if("refreshing"in $$props)$$invalidate(11,refreshing=$$new_props.refreshing);if("title"in $$props)$$invalidate(12,title=$$new_props.title)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$props=exclude_internal_props($$props);return[ref,extraSmall,small,large,medium,primary,expandable,refresh,outline,disabled,expanded,refreshing,title,classes,handleKeyup,refreshIcon,$$scope,slots,click_handler,focusout_handler,button_binding]}class Button extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$1c,create_fragment$1c,safe_not_equal,{ref:0,extraSmall:1,small:2,large:3,medium:4,primary:5,expandable:6,refresh:7,outline:8,disabled:9,expanded:10,refreshing:11,title:12});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"Button",options:options,id:create_fragment$1c.name})}get ref(){throw new Error("<Button>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set ref(value){throw new Error("<Button>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get extraSmall(){throw new Error("<Button>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set extraSmall(value){throw new Error("<Button>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get small(){throw new Error("<Button>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set small(value){throw new Error("<Button>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get large(){throw new Error("<Button>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set large(value){throw new Error("<Button>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get medium(){throw new Error("<Button>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set medium(value){throw new Error("<Button>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get primary(){throw new Error("<Button>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set primary(value){throw new Error("<Button>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get expandable(){throw new Error("<Button>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set expandable(value){throw new Error("<Button>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get refresh(){throw new Error("<Button>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set refresh(value){throw new Error("<Button>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get outline(){throw new Error("<Button>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set outline(value){throw new Error("<Button>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get disabled(){throw new Error("<Button>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set disabled(value){throw new Error("<Button>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get expanded(){throw new Error("<Button>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set expanded(value){throw new Error("<Button>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get refreshing(){throw new Error("<Button>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set refreshing(value){throw new Error("<Button>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get title(){throw new Error("<Button>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set title(value){throw new Error("<Button>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$10="ui/components/Notification.svelte";const get_details_slot_changes=dirty=>({});const get_details_slot_context=ctx=>({});function create_if_block_8$5(ctx){let div;let img;let img_src_value;let img_alt_value;let div_resize_listener;const block={c:function create(){div=element("div");img=element("img");attr_dev(img,"class","icon type");if(!src_url_equal(img.src,img_src_value=ctx[18]))attr_dev(img,"src",img_src_value);attr_dev(img,"alt",img_alt_value=""+(ctx[0].type+" icon"));add_location(img,file$10,97,4,2657);attr_dev(div,"class","icon type");add_render_callback((()=>ctx[25].call(div)));add_location(div,file$10,96,3,2598)},m:function mount(target,anchor){insert_dev(target,div,anchor);append_dev(div,img);div_resize_listener=add_iframe_resize_listener(div,ctx[25].bind(div))},p:function update(ctx,dirty){if(dirty[0]&262144&&!src_url_equal(img.src,img_src_value=ctx[18])){attr_dev(img,"src",img_src_value)}if(dirty[0]&1&&img_alt_value!==(img_alt_value=""+(ctx[0].type+" icon"))){attr_dev(img,"alt",img_alt_value)}},d:function destroy(detaching){if(detaching){detach_dev(div)}div_resize_listener()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_8$5.name,type:"if",source:"(96:2) {#if iconURL}",ctx:ctx});return block}function create_if_block_2$b(ctx){let div;let t;let current_block_type_index;let if_block1;let current;let if_block0=ctx[8]&&create_if_block_6$5(ctx);const if_block_creators=[create_if_block_3$7,create_if_block_4$7,create_if_block_5$5];const if_blocks=[];function select_block_type_1(ctx,dirty){if(ctx[9]&&ctx[12])return 0;if(ctx[12])return 1;if(ctx[9])return 2;return-1}if(~(current_block_type_index=select_block_type_1(ctx))){if_block1=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx)}const block={c:function create(){div=element("div");if(if_block0)if_block0.c();t=space();if(if_block1)if_block1.c();attr_dev(div,"class","heading");add_location(div,file$10,102,4,2847)},m:function mount(target,anchor){insert_dev(target,div,anchor);if(if_block0)if_block0.m(div,null);append_dev(div,t);if(~current_block_type_index){if_blocks[current_block_type_index].m(div,null)}current=true},p:function update(ctx,dirty){if(ctx[8]){if(if_block0){if_block0.p(ctx,dirty)}else{if_block0=create_if_block_6$5(ctx);if_block0.c();if_block0.m(div,t)}}else if(if_block0){if_block0.d(1);if_block0=null}let previous_block_index=current_block_type_index;current_block_type_index=select_block_type_1(ctx);if(current_block_type_index===previous_block_index){if(~current_block_type_index){if_blocks[current_block_type_index].p(ctx,dirty)}}else{if(if_block1){group_outros();transition_out(if_blocks[previous_block_index],1,1,(()=>{if_blocks[previous_block_index]=null}));check_outros()}if(~current_block_type_index){if_block1=if_blocks[current_block_type_index];if(!if_block1){if_block1=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);if_block1.c()}else{if_block1.p(ctx,dirty)}transition_in(if_block1,1);if_block1.m(div,null)}else{if_block1=null}}},i:function intro(local){if(current)return;transition_in(if_block1);current=true},o:function outro(local){transition_out(if_block1);current=false},d:function destroy(detaching){if(detaching){detach_dev(div)}if(if_block0)if_block0.d();if(~current_block_type_index){if_blocks[current_block_type_index].d()}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_2$b.name,type:"if",source:"(102:3) {#if heading || dismissible || expandable}",ctx:ctx});return block}function create_if_block_6$5(ctx){let if_block_anchor;function select_block_type(ctx,dirty){if(ctx[10])return create_if_block_7$5;return create_else_block$f}let current_block_type=select_block_type(ctx);let if_block=current_block_type(ctx);const block={c:function create(){if_block.c();if_block_anchor=empty()},m:function mount(target,anchor){if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor)},p:function update(ctx,dirty){if(current_block_type===(current_block_type=select_block_type(ctx))&&if_block){if_block.p(ctx,dirty)}else{if_block.d(1);if_block=current_block_type(ctx);if(if_block){if_block.c();if_block.m(if_block_anchor.parentNode,if_block_anchor)}}},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_6$5.name,type:"if",source:"(104:5) {#if heading}",ctx:ctx});return block}function create_else_block$f(ctx){let h3;const block={c:function create(){h3=element("h3");add_location(h3,file$10,107,7,2964)},m:function mount(target,anchor){insert_dev(target,h3,anchor);h3.innerHTML=ctx[8]},p:function update(ctx,dirty){if(dirty[0]&256)h3.innerHTML=ctx[8]},d:function destroy(detaching){if(detaching){detach_dev(h3)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block$f.name,type:"else",source:"(107:6) {:else}",ctx:ctx});return block}function create_if_block_7$5(ctx){let p;const block={c:function create(){p=element("p");add_location(p,file$10,105,7,2920)},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=ctx[8]},p:function update(ctx,dirty){if(dirty[0]&256)p.innerHTML=ctx[8]},d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_7$5.name,type:"if",source:"(105:6) {#if plainHeading}",ctx:ctx});return block}function create_if_block_5$5(ctx){let button;let button_title_value;let mounted;let dispose;const block={c:function create(){button=element("button");attr_dev(button,"class","icon close");attr_dev(button,"title",button_title_value=ctx[19]["dismiss_notice"]);add_location(button,file$10,116,6,3529)},m:function mount(target,anchor){insert_dev(target,button,anchor);if(!mounted){dispose=listen_dev(button,"click",prevent_default(ctx[28]),false,true,false,false);mounted=true}},p:function update(ctx,dirty){if(dirty[0]&524288&&button_title_value!==(button_title_value=ctx[19]["dismiss_notice"])){attr_dev(button,"title",button_title_value)}},i:noop,o:noop,d:function destroy(detaching){if(detaching){detach_dev(button)}mounted=false;dispose()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_5$5.name,type:"if",source:"(116:27) ",ctx:ctx});return block}function create_if_block_4$7(ctx){let button;let current;button=new Button({props:{expandable:true,expanded:ctx[1],title:ctx[1]?ctx[19].hide_details:ctx[19].show_details},$$inline:true});button.$on("click",ctx[27]);const block={c:function create(){create_component(button.$$.fragment)},m:function mount(target,anchor){mount_component(button,target,anchor);current=true},p:function update(ctx,dirty){const button_changes={};if(dirty[0]&2)button_changes.expanded=ctx[1];if(dirty[0]&524290)button_changes.title=ctx[1]?ctx[19].hide_details:ctx[19].show_details;button.$set(button_changes)},i:function intro(local){if(current)return;transition_in(button.$$.fragment,local);current=true},o:function outro(local){transition_out(button.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(button,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_4$7.name,type:"if",source:"(114:26) ",ctx:ctx});return block}function create_if_block_3$7(ctx){let button0;let t0_value=ctx[19].dismiss_all+"";let t0;let t1;let button1;let current;let mounted;let dispose;button1=new Button({props:{expandable:true,expanded:ctx[1],title:ctx[1]?ctx[19].hide_details:ctx[19].show_details},$$inline:true});button1.$on("click",ctx[26]);const block={c:function create(){button0=element("button");t0=text(t0_value);t1=space();create_component(button1.$$.fragment);attr_dev(button0,"class","dismiss");add_location(button0,file$10,111,6,3055)},m:function mount(target,anchor){insert_dev(target,button0,anchor);append_dev(button0,t0);insert_dev(target,t1,anchor);mount_component(button1,target,anchor);current=true;if(!mounted){dispose=listen_dev(button0,"click",prevent_default((function(){if(is_function(notifications.dismiss(ctx[2])))notifications.dismiss(ctx[2]).apply(this,arguments)})),false,true,false,false);mounted=true}},p:function update(new_ctx,dirty){ctx=new_ctx;if((!current||dirty[0]&524288)&&t0_value!==(t0_value=ctx[19].dismiss_all+""))set_data_dev(t0,t0_value);const button1_changes={};if(dirty[0]&2)button1_changes.expanded=ctx[1];if(dirty[0]&524290)button1_changes.title=ctx[1]?ctx[19].hide_details:ctx[19].show_details;button1.$set(button1_changes)},i:function intro(local){if(current)return;transition_in(button1.$$.fragment,local);current=true},o:function outro(local){transition_out(button1.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(button0);detach_dev(t1)}destroy_component(button1,detaching);mounted=false;dispose()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_3$7.name,type:"if",source:"(111:5) {#if dismissible && expandable}",ctx:ctx});return block}function create_if_block_1$k(ctx){let p;const block={c:function create(){p=element("p");add_location(p,file$10,122,4,3727)},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=ctx[11]},p:function update(ctx,dirty){if(dirty[0]&2048)p.innerHTML=ctx[11]},d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_1$k.name,type:"if",source:"(122:3) {#if extra}",ctx:ctx});return block}function create_if_block$B(ctx){let p;const block={c:function create(){p=element("p");attr_dev(p,"class","links");add_location(p,file$10,125,4,3780)},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=ctx[16]},p:function update(ctx,dirty){if(dirty[0]&65536)p.innerHTML=ctx[16]},d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$B.name,type:"if",source:"(125:3) {#if linksHTML}",ctx:ctx});return block}function create_fragment$1b(ctx){let div2;let div1;let t0;let div0;let t1;let t2;let t3;let div0_resize_listener;let t4;let current;let if_block0=ctx[18]&&create_if_block_8$5(ctx);let if_block1=(ctx[8]||ctx[9]||ctx[12])&&create_if_block_2$b(ctx);const default_slot_template=ctx[24].default;const default_slot=create_slot(default_slot_template,ctx,ctx[23],null);let if_block2=ctx[11]&&create_if_block_1$k(ctx);let if_block3=ctx[16]&&create_if_block$B(ctx);const details_slot_template=ctx[24].details;const details_slot=create_slot(details_slot_template,ctx,ctx[23],get_details_slot_context);const block={c:function create(){div2=element("div");div1=element("div");if(if_block0)if_block0.c();t0=space();div0=element("div");if(if_block1)if_block1.c();t1=space();if(default_slot)default_slot.c();t2=space();if(if_block2)if_block2.c();t3=space();if(if_block3)if_block3.c();t4=space();if(details_slot)details_slot.c();attr_dev(div0,"class","body");add_render_callback((()=>ctx[29].call(div0)));add_location(div0,file$10,100,2,2747);attr_dev(div1,"class","content");add_location(div1,file$10,94,1,2557);attr_dev(div2,"class","notification "+ctx[20]);toggle_class(div2,"inline",ctx[3]);toggle_class(div2,"wordpress",ctx[4]);toggle_class(div2,"success",ctx[5]);toggle_class(div2,"warning",ctx[6]);toggle_class(div2,"error",ctx[7]);toggle_class(div2,"info",ctx[15]);toggle_class(div2,"multiline",ctx[17]);toggle_class(div2,"expandable",ctx[12]);toggle_class(div2,"expanded",ctx[1]);add_location(div2,file$10,82,0,2380)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,div2,anchor);append_dev(div2,div1);if(if_block0)if_block0.m(div1,null);append_dev(div1,t0);append_dev(div1,div0);if(if_block1)if_block1.m(div0,null);append_dev(div0,t1);if(default_slot){default_slot.m(div0,null)}append_dev(div0,t2);if(if_block2)if_block2.m(div0,null);append_dev(div0,t3);if(if_block3)if_block3.m(div0,null);div0_resize_listener=add_iframe_resize_listener(div0,ctx[29].bind(div0));append_dev(div2,t4);if(details_slot){details_slot.m(div2,null)}current=true},p:function update(ctx,dirty){if(ctx[18]){if(if_block0){if_block0.p(ctx,dirty)}else{if_block0=create_if_block_8$5(ctx);if_block0.c();if_block0.m(div1,t0)}}else if(if_block0){if_block0.d(1);if_block0=null}if(ctx[8]||ctx[9]||ctx[12]){if(if_block1){if_block1.p(ctx,dirty);if(dirty[0]&4864){transition_in(if_block1,1)}}else{if_block1=create_if_block_2$b(ctx);if_block1.c();transition_in(if_block1,1);if_block1.m(div0,t1)}}else if(if_block1){group_outros();transition_out(if_block1,1,1,(()=>{if_block1=null}));check_outros()}if(default_slot){if(default_slot.p&&(!current||dirty[0]&8388608)){update_slot_base(default_slot,default_slot_template,ctx,ctx[23],!current?get_all_dirty_from_scope(ctx[23]):get_slot_changes(default_slot_template,ctx[23],dirty,null),null)}}if(ctx[11]){if(if_block2){if_block2.p(ctx,dirty)}else{if_block2=create_if_block_1$k(ctx);if_block2.c();if_block2.m(div0,t3)}}else if(if_block2){if_block2.d(1);if_block2=null}if(ctx[16]){if(if_block3){if_block3.p(ctx,dirty)}else{if_block3=create_if_block$B(ctx);if_block3.c();if_block3.m(div0,null)}}else if(if_block3){if_block3.d(1);if_block3=null}if(details_slot){if(details_slot.p&&(!current||dirty[0]&8388608)){update_slot_base(details_slot,details_slot_template,ctx,ctx[23],!current?get_all_dirty_from_scope(ctx[23]):get_slot_changes(details_slot_template,ctx[23],dirty,get_details_slot_changes),get_details_slot_context)}}if(!current||dirty[0]&8){toggle_class(div2,"inline",ctx[3])}if(!current||dirty[0]&16){toggle_class(div2,"wordpress",ctx[4])}if(!current||dirty[0]&32){toggle_class(div2,"success",ctx[5])}if(!current||dirty[0]&64){toggle_class(div2,"warning",ctx[6])}if(!current||dirty[0]&128){toggle_class(div2,"error",ctx[7])}if(!current||dirty[0]&32768){toggle_class(div2,"info",ctx[15])}if(!current||dirty[0]&131072){toggle_class(div2,"multiline",ctx[17])}if(!current||dirty[0]&4096){toggle_class(div2,"expandable",ctx[12])}if(!current||dirty[0]&2){toggle_class(div2,"expanded",ctx[1])}},i:function intro(local){if(current)return;transition_in(if_block1);transition_in(default_slot,local);transition_in(details_slot,local);current=true},o:function outro(local){transition_out(if_block1);transition_out(default_slot,local);transition_out(details_slot,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(div2)}if(if_block0)if_block0.d();if(if_block1)if_block1.d();if(default_slot)default_slot.d(detaching);if(if_block2)if_block2.d();if(if_block3)if_block3.d();div0_resize_listener();if(details_slot)details_slot.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$1b.name,type:"component",source:"",ctx:ctx});return block}function getLinksHTML(links){if(links.length){return links.join(" ")}return""}function instance$1b($$self,$$props,$$invalidate){let iconURL;let multiline;let linksHTML;let $urls;let $strings;validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(30,$urls=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(19,$strings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("Notification",slots,["default","details"]);const classes=$$props.class?$$props.class:"";let{notification:notification={}}=$$props;let{unique_id:unique_id=(notification.id?notification.id:"")}=$$props;let{inline:inline=(notification.inline?notification.inline:false)}=$$props;let{wordpress:wordpress=(notification.wordpress?notification.wordpress:false)}=$$props;let{success:success=notification.type==="success"}=$$props;let{warning:warning=notification.type==="warning"}=$$props;let{error:error=notification.type==="error"}=$$props;let info=false;if(success){notification.type="success"}else if(warning){notification.type="warning"}else if(error){notification.type="error"}else{info=true;notification.type="info"}let{heading:heading=(notification.hasOwnProperty("heading")&&notification.heading.trim().length?notification.heading.trim():"")}=$$props;let{dismissible:dismissible=(notification.dismissible?notification.dismissible:false)}=$$props;let{icon:icon=(notification.icon?notification.icon:false)}=$$props;let{plainHeading:plainHeading=(notification.plainHeading?notification.plainHeading:false)}=$$props;let{extra:extra=(notification.extra?notification.extra:"")}=$$props;let{links:links=(notification.links?notification.links:[])}=$$props;let{expandable:expandable=false}=$$props;let{expanded:expanded=false}=$$props;function getIconURL(icon,notificationType){if(icon){return $urls.assets+"img/icon/"+icon}return $urls.assets+"img/icon/notification-"+notificationType+".svg"}let iconHeight=0;let bodyHeight=0;function div_elementresize_handler(){iconHeight=this.clientHeight;$$invalidate(13,iconHeight)}const click_handler=()=>$$invalidate(1,expanded=!expanded);const click_handler_1=()=>$$invalidate(1,expanded=!expanded);const click_handler_2=()=>notifications.dismiss(unique_id);function div0_elementresize_handler(){bodyHeight=this.clientHeight;$$invalidate(14,bodyHeight)}$$self.$$set=$$new_props=>{$$invalidate(32,$$props=assign(assign({},$$props),exclude_internal_props($$new_props)));if("notification"in $$new_props)$$invalidate(0,notification=$$new_props.notification);if("unique_id"in $$new_props)$$invalidate(2,unique_id=$$new_props.unique_id);if("inline"in $$new_props)$$invalidate(3,inline=$$new_props.inline);if("wordpress"in $$new_props)$$invalidate(4,wordpress=$$new_props.wordpress);if("success"in $$new_props)$$invalidate(5,success=$$new_props.success);if("warning"in $$new_props)$$invalidate(6,warning=$$new_props.warning);if("error"in $$new_props)$$invalidate(7,error=$$new_props.error);if("heading"in $$new_props)$$invalidate(8,heading=$$new_props.heading);if("dismissible"in $$new_props)$$invalidate(9,dismissible=$$new_props.dismissible);if("icon"in $$new_props)$$invalidate(21,icon=$$new_props.icon);if("plainHeading"in $$new_props)$$invalidate(10,plainHeading=$$new_props.plainHeading);if("extra"in $$new_props)$$invalidate(11,extra=$$new_props.extra);if("links"in $$new_props)$$invalidate(22,links=$$new_props.links);if("expandable"in $$new_props)$$invalidate(12,expandable=$$new_props.expandable);if("expanded"in $$new_props)$$invalidate(1,expanded=$$new_props.expanded);if("$$scope"in $$new_props)$$invalidate(23,$$scope=$$new_props.$$scope)};$$self.$capture_state=()=>({notifications:notifications,strings:strings,urls:urls,Button:Button,classes:classes,notification:notification,unique_id:unique_id,inline:inline,wordpress:wordpress,success:success,warning:warning,error:error,info:info,heading:heading,dismissible:dismissible,icon:icon,plainHeading:plainHeading,extra:extra,links:links,expandable:expandable,expanded:expanded,getIconURL:getIconURL,iconHeight:iconHeight,bodyHeight:bodyHeight,getLinksHTML:getLinksHTML,linksHTML:linksHTML,multiline:multiline,iconURL:iconURL,$urls:$urls,$strings:$strings});$$self.$inject_state=$$new_props=>{$$invalidate(32,$$props=assign(assign({},$$props),$$new_props));if("notification"in $$props)$$invalidate(0,notification=$$new_props.notification);if("unique_id"in $$props)$$invalidate(2,unique_id=$$new_props.unique_id);if("inline"in $$props)$$invalidate(3,inline=$$new_props.inline);if("wordpress"in $$props)$$invalidate(4,wordpress=$$new_props.wordpress);if("success"in $$props)$$invalidate(5,success=$$new_props.success);if("warning"in $$props)$$invalidate(6,warning=$$new_props.warning);if("error"in $$props)$$invalidate(7,error=$$new_props.error);if("info"in $$props)$$invalidate(15,info=$$new_props.info);if("heading"in $$props)$$invalidate(8,heading=$$new_props.heading);if("dismissible"in $$props)$$invalidate(9,dismissible=$$new_props.dismissible);if("icon"in $$props)$$invalidate(21,icon=$$new_props.icon);if("plainHeading"in $$props)$$invalidate(10,plainHeading=$$new_props.plainHeading);if("extra"in $$props)$$invalidate(11,extra=$$new_props.extra);if("links"in $$props)$$invalidate(22,links=$$new_props.links);if("expandable"in $$props)$$invalidate(12,expandable=$$new_props.expandable);if("expanded"in $$props)$$invalidate(1,expanded=$$new_props.expanded);if("iconHeight"in $$props)$$invalidate(13,iconHeight=$$new_props.iconHeight);if("bodyHeight"in $$props)$$invalidate(14,bodyHeight=$$new_props.bodyHeight);if("linksHTML"in $$props)$$invalidate(16,linksHTML=$$new_props.linksHTML);if("multiline"in $$props)$$invalidate(17,multiline=$$new_props.multiline);if("iconURL"in $$props)$$invalidate(18,iconURL=$$new_props.iconURL)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty[0]&2097153){$$invalidate(18,iconURL=getIconURL(icon,notification.type))}if($$self.$$.dirty[0]&24576){$$invalidate(17,multiline=iconHeight&&bodyHeight&&bodyHeight>iconHeight)}if($$self.$$.dirty[0]&4194304){$$invalidate(16,linksHTML=getLinksHTML(links))}};$$props=exclude_internal_props($$props);return[notification,expanded,unique_id,inline,wordpress,success,warning,error,heading,dismissible,plainHeading,extra,expandable,iconHeight,bodyHeight,info,linksHTML,multiline,iconURL,$strings,classes,icon,links,$$scope,slots,div_elementresize_handler,click_handler,click_handler_1,click_handler_2,div0_elementresize_handler]}class Notification extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$1b,create_fragment$1b,safe_not_equal,{notification:0,unique_id:2,inline:3,wordpress:4,success:5,warning:6,error:7,heading:8,dismissible:9,icon:21,plainHeading:10,extra:11,links:22,expandable:12,expanded:1},null,[-1,-1]);dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"Notification",options:options,id:create_fragment$1b.name})}get notification(){throw new Error("<Notification>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set notification(value){throw new Error("<Notification>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get unique_id(){throw new Error("<Notification>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set unique_id(value){throw new Error("<Notification>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get inline(){throw new Error("<Notification>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set inline(value){throw new Error("<Notification>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get wordpress(){throw new Error("<Notification>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set wordpress(value){throw new Error("<Notification>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get success(){throw new Error("<Notification>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set success(value){throw new Error("<Notification>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get warning(){throw new Error("<Notification>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set warning(value){throw new Error("<Notification>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get error(){throw new Error("<Notification>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set error(value){throw new Error("<Notification>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get heading(){throw new Error("<Notification>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set heading(value){throw new Error("<Notification>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get dismissible(){throw new Error("<Notification>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set dismissible(value){throw new Error("<Notification>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get icon(){throw new Error("<Notification>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set icon(value){throw new Error("<Notification>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get plainHeading(){throw new Error("<Notification>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set plainHeading(value){throw new Error("<Notification>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get extra(){throw new Error("<Notification>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set extra(value){throw new Error("<Notification>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get links(){throw new Error("<Notification>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set links(value){throw new Error("<Notification>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get expandable(){throw new Error("<Notification>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set expandable(value){throw new Error("<Notification>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get expanded(){throw new Error("<Notification>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set expanded(value){throw new Error("<Notification>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const{Object:Object_1$7}=globals;const file$$="ui/components/Notifications.svelte";function get_each_context$e(ctx,list,i){const child_ctx=ctx.slice();child_ctx[6]=list[i];return child_ctx}function create_if_block$A(ctx){let div;let each_blocks=[];let each_1_lookup=new Map;let current;let each_value=ensure_array_like_dev(ctx[1]);const get_key=ctx=>ctx[6].render_key;validate_each_keys(ctx,each_value,get_each_context$e,get_key);for(let i=0;i<each_value.length;i+=1){let child_ctx=get_each_context$e(ctx,each_value,i);let key=get_key(child_ctx);each_1_lookup.set(key,each_blocks[i]=create_each_block$e(key,child_ctx))}const block={c:function create(){div=element("div");for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].c()}attr_dev(div,"id","notifications");attr_dev(div,"class","notifications wrapper");add_location(div,file$$,22,1,793)},m:function mount(target,anchor){insert_dev(target,div,anchor);for(let i=0;i<each_blocks.length;i+=1){if(each_blocks[i]){each_blocks[i].m(div,null)}}current=true},p:function update(ctx,dirty){if(dirty&7){each_value=ensure_array_like_dev(ctx[1]);group_outros();validate_each_keys(ctx,each_value,get_each_context$e,get_key);each_blocks=update_keyed_each(each_blocks,dirty,get_key,1,ctx,each_value,each_1_lookup,div,outro_and_destroy_block,create_each_block$e,null,get_each_context$e);check_outros()}},i:function intro(local){if(current)return;for(let i=0;i<each_value.length;i+=1){transition_in(each_blocks[i])}current=true},o:function outro(local){for(let i=0;i<each_blocks.length;i+=1){transition_out(each_blocks[i])}current=false},d:function destroy(detaching){if(detaching){detach_dev(div)}for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].d()}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$A.name,type:"if",source:"(22:0) {#if $notifications.length && Object.values( $notifications ).filter( notification => renderNotification( notification ) ).length}",ctx:ctx});return block}function create_if_block_1$j(ctx){let switch_instance;let switch_instance_anchor;let current;var switch_value=ctx[0];function switch_props(ctx,dirty){return{props:{notification:ctx[6],$$slots:{default:[create_default_slot$H]},$$scope:{ctx:ctx}},$$inline:true}}if(switch_value){switch_instance=construct_svelte_component_dev(switch_value,switch_props(ctx))}const block={c:function create(){if(switch_instance)create_component(switch_instance.$$.fragment);switch_instance_anchor=empty()},m:function mount(target,anchor){if(switch_instance)mount_component(switch_instance,target,anchor);insert_dev(target,switch_instance_anchor,anchor);current=true},p:function update(ctx,dirty){if(dirty&1&&switch_value!==(switch_value=ctx[0])){if(switch_instance){group_outros();const old_component=switch_instance;transition_out(old_component.$$.fragment,1,0,(()=>{destroy_component(old_component,1)}));check_outros()}if(switch_value){switch_instance=construct_svelte_component_dev(switch_value,switch_props(ctx));create_component(switch_instance.$$.fragment);transition_in(switch_instance.$$.fragment,1);mount_component(switch_instance,switch_instance_anchor.parentNode,switch_instance_anchor)}else{switch_instance=null}}else if(switch_value){const switch_instance_changes={};if(dirty&2)switch_instance_changes.notification=ctx[6];if(dirty&514){switch_instance_changes.$$scope={dirty:dirty,ctx:ctx}}switch_instance.$set(switch_instance_changes)}},i:function intro(local){if(current)return;if(switch_instance)transition_in(switch_instance.$$.fragment,local);current=true},o:function outro(local){if(switch_instance)transition_out(switch_instance.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(switch_instance_anchor)}if(switch_instance)destroy_component(switch_instance,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_1$j.name,type:"if",source:"(25:3) {#if renderNotification( notification )}",ctx:ctx});return block}function create_if_block_2$a(ctx){let p;let raw_value=ctx[6].message+"";const block={c:function create(){p=element("p");add_location(p,file$$,27,6,1065)},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=raw_value},p:function update(ctx,dirty){if(dirty&2&&raw_value!==(raw_value=ctx[6].message+""))p.innerHTML=raw_value},d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_2$a.name,type:"if",source:"(27:5) {#if notification.message}",ctx:ctx});return block}function create_default_slot$H(ctx){let t;let if_block=ctx[6].message&&create_if_block_2$a(ctx);const block={c:function create(){if(if_block)if_block.c();t=space()},m:function mount(target,anchor){if(if_block)if_block.m(target,anchor);insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(ctx[6].message){if(if_block){if_block.p(ctx,dirty)}else{if_block=create_if_block_2$a(ctx);if_block.c();if_block.m(t.parentNode,t)}}else if(if_block){if_block.d(1);if_block=null}},d:function destroy(detaching){if(detaching){detach_dev(t)}if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$H.name,type:"slot",source:"(26:4) <svelte:component this={component} notification={notification}>",ctx:ctx});return block}function create_each_block$e(key_1,ctx){let first;let show_if=ctx[2](ctx[6]);let if_block_anchor;let current;let if_block=show_if&&create_if_block_1$j(ctx);const block={key:key_1,first:null,c:function create(){first=empty();if(if_block)if_block.c();if_block_anchor=empty();this.first=first},m:function mount(target,anchor){insert_dev(target,first,anchor);if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(new_ctx,dirty){ctx=new_ctx;if(dirty&2)show_if=ctx[2](ctx[6]);if(show_if){if(if_block){if_block.p(ctx,dirty);if(dirty&2){transition_in(if_block,1)}}else{if_block=create_if_block_1$j(ctx);if_block.c();transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(first);detach_dev(if_block_anchor)}if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_each_block$e.name,type:"each",source:"(24:2) {#each $notifications as notification (notification.render_key)}",ctx:ctx});return block}function create_fragment$1a(ctx){let show_if=ctx[1].length&&Object.values(ctx[1]).filter(ctx[5]).length;let if_block_anchor;let current;let if_block=show_if&&create_if_block$A(ctx);const block={c:function create(){if(if_block)if_block.c();if_block_anchor=empty()},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,[dirty]){if(dirty&2)show_if=ctx[1].length&&Object.values(ctx[1]).filter(ctx[5]).length;if(show_if){if(if_block){if_block.p(ctx,dirty);if(dirty&2){transition_in(if_block,1)}}else{if_block=create_if_block$A(ctx);if_block.c();transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$1a.name,type:"component",source:"",ctx:ctx});return block}function instance$1a($$self,$$props,$$invalidate){let $notifications;validate_store(notifications,"notifications");component_subscribe($$self,notifications,($$value=>$$invalidate(1,$notifications=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("Notifications",slots,[]);let{component:component=Notification}=$$props;let{tab:tab=""}=$$props;let{tabParent:tabParent=""}=$$props;function renderNotification(notification){let not_dismissed=!notification.dismissed;let valid_parent_tab=notification.only_show_on_tab===tab&&notification.hide_on_parent!==true;let valid_sub_tab=notification.only_show_on_tab===tabParent;let show_on_all_tabs=!notification.only_show_on_tab;return not_dismissed&&(valid_parent_tab||valid_sub_tab||show_on_all_tabs)}const writable_props=["component","tab","tabParent"];Object_1$7.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<Notifications> was created with unknown prop '${key}'`)}));const func=notification=>renderNotification(notification);$$self.$$set=$$props=>{if("component"in $$props)$$invalidate(0,component=$$props.component);if("tab"in $$props)$$invalidate(3,tab=$$props.tab);if("tabParent"in $$props)$$invalidate(4,tabParent=$$props.tabParent)};$$self.$capture_state=()=>({notifications:notifications,Notification:Notification,component:component,tab:tab,tabParent:tabParent,renderNotification:renderNotification,$notifications:$notifications});$$self.$inject_state=$$props=>{if("component"in $$props)$$invalidate(0,component=$$props.component);if("tab"in $$props)$$invalidate(3,tab=$$props.tab);if("tabParent"in $$props)$$invalidate(4,tabParent=$$props.tabParent)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[component,$notifications,renderNotification,tab,tabParent,func]}class Notifications extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$1a,create_fragment$1a,safe_not_equal,{component:0,tab:3,tabParent:4});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"Notifications",options:options,id:create_fragment$1a.name})}get component(){throw new Error("<Notifications>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set component(value){throw new Error("<Notifications>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get tab(){throw new Error("<Notifications>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set tab(value){throw new Error("<Notifications>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get tabParent(){throw new Error("<Notifications>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set tabParent(value){throw new Error("<Notifications>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$_="ui/components/SubNavItem.svelte";function create_if_block$z(ctx){let div;let img;let img_src_value;let img_alt_value;let div_class_value;const block={c:function create(){div=element("div");img=element("img");attr_dev(img,"class","notice-icon svelte-jtkdoa");if(!src_url_equal(img.src,img_src_value=ctx[4]))attr_dev(img,"src",img_src_value);attr_dev(img,"alt",img_alt_value=ctx[0].noticeIcon);add_location(img,file$_,27,4,799);attr_dev(div,"class",div_class_value="notice-icon-wrapper notice-icon-"+ctx[0].noticeIcon+" svelte-jtkdoa");add_location(div,file$_,26,3,731)},m:function mount(target,anchor){insert_dev(target,div,anchor);append_dev(div,img)},p:function update(ctx,dirty){if(dirty&16&&!src_url_equal(img.src,img_src_value=ctx[4])){attr_dev(img,"src",img_src_value)}if(dirty&1&&img_alt_value!==(img_alt_value=ctx[0].noticeIcon)){attr_dev(img,"alt",img_alt_value)}if(dirty&1&&div_class_value!==(div_class_value="notice-icon-wrapper notice-icon-"+ctx[0].noticeIcon+" svelte-jtkdoa")){attr_dev(div,"class",div_class_value)}},d:function destroy(detaching){if(detaching){detach_dev(div)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$z.name,type:"if",source:"(26:2) {#if showIcon}",ctx:ctx});return block}function create_fragment$19(ctx){let li;let a;let t0_value=ctx[0].title()+"";let t0;let t1;let a_href_value;let a_title_value;let mounted;let dispose;let if_block=ctx[1]&&create_if_block$z(ctx);const block={c:function create(){li=element("li");a=element("a");t0=text(t0_value);t1=space();if(if_block)if_block.c();attr_dev(a,"href",a_href_value=ctx[0].route);attr_dev(a,"title",a_title_value=ctx[0].title());add_location(a,file$_,15,1,489);attr_dev(li,"class","subnav-item");toggle_class(li,"active",ctx[5]===ctx[0].route);toggle_class(li,"focus",ctx[2]);toggle_class(li,"hover",ctx[3]);toggle_class(li,"has-icon",ctx[1]);add_location(li,file$_,14,0,373)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,li,anchor);append_dev(li,a);append_dev(a,t0);append_dev(a,t1);if(if_block)if_block.m(a,null);if(!mounted){dispose=[action_destroyer(link.call(null,a)),listen_dev(a,"focusin",ctx[7],false,false,false,false),listen_dev(a,"focusout",ctx[8],false,false,false,false),listen_dev(a,"mouseenter",ctx[9],false,false,false,false),listen_dev(a,"mouseleave",ctx[10],false,false,false,false)];mounted=true}},p:function update(ctx,[dirty]){if(dirty&1&&t0_value!==(t0_value=ctx[0].title()+""))set_data_dev(t0,t0_value);if(ctx[1]){if(if_block){if_block.p(ctx,dirty)}else{if_block=create_if_block$z(ctx);if_block.c();if_block.m(a,null)}}else if(if_block){if_block.d(1);if_block=null}if(dirty&1&&a_href_value!==(a_href_value=ctx[0].route)){attr_dev(a,"href",a_href_value)}if(dirty&1&&a_title_value!==(a_title_value=ctx[0].title())){attr_dev(a,"title",a_title_value)}if(dirty&33){toggle_class(li,"active",ctx[5]===ctx[0].route)}if(dirty&4){toggle_class(li,"focus",ctx[2])}if(dirty&8){toggle_class(li,"hover",ctx[3])}if(dirty&2){toggle_class(li,"has-icon",ctx[1])}},i:noop,o:noop,d:function destroy(detaching){if(detaching){detach_dev(li)}if(if_block)if_block.d();mounted=false;run_all(dispose)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$19.name,type:"component",source:"",ctx:ctx});return block}function instance$19($$self,$$props,$$invalidate){let showIcon;let iconUrl;let $urls;let $location;validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(6,$urls=$$value)));validate_store(location$1,"location");component_subscribe($$self,location$1,($$value=>$$invalidate(5,$location=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("SubNavItem",slots,[]);let{page:page}=$$props;let focus=false;let hover=false;$$self.$$.on_mount.push((function(){if(page===undefined&&!("page"in $$props||$$self.$$.bound[$$self.$$.props["page"]])){console.warn("<SubNavItem> was created without expected prop 'page'")}}));const writable_props=["page"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<SubNavItem> was created with unknown prop '${key}'`)}));const focusin_handler=()=>$$invalidate(2,focus=true);const focusout_handler=()=>$$invalidate(2,focus=false);const mouseenter_handler=()=>$$invalidate(3,hover=true);const mouseleave_handler=()=>$$invalidate(3,hover=false);$$self.$$set=$$props=>{if("page"in $$props)$$invalidate(0,page=$$props.page)};$$self.$capture_state=()=>({link:link,location:location$1,urls:urls,page:page,focus:focus,hover:hover,showIcon:showIcon,iconUrl:iconUrl,$urls:$urls,$location:$location});$$self.$inject_state=$$props=>{if("page"in $$props)$$invalidate(0,page=$$props.page);if("focus"in $$props)$$invalidate(2,focus=$$props.focus);if("hover"in $$props)$$invalidate(3,hover=$$props.hover);if("showIcon"in $$props)$$invalidate(1,showIcon=$$props.showIcon);if("iconUrl"in $$props)$$invalidate(4,iconUrl=$$props.iconUrl)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty&1){$$invalidate(1,showIcon=typeof page.noticeIcon==="string"&&["warning","error"].includes(page.noticeIcon))}if($$self.$$.dirty&67){$$invalidate(4,iconUrl=showIcon?$urls.assets+"img/icon/tab-notifier-"+page.noticeIcon+".svg":"")}};return[page,showIcon,focus,hover,iconUrl,$location,$urls,focusin_handler,focusout_handler,mouseenter_handler,mouseleave_handler]}class SubNavItem extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$19,create_fragment$19,safe_not_equal,{page:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"SubNavItem",options:options,id:create_fragment$19.name})}get page(){throw new Error("<SubNavItem>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set page(value){throw new Error("<SubNavItem>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$Z="ui/components/SubNav.svelte";function get_each_context$d(ctx,list,i){const child_ctx=ctx.slice();child_ctx[6]=list[i];child_ctx[8]=i;return child_ctx}function create_if_block$y(ctx){let ul;let ul_class_value;let current;let each_value=ensure_array_like_dev(ctx[3]);let each_blocks=[];for(let i=0;i<each_value.length;i+=1){each_blocks[i]=create_each_block$d(get_each_context$d(ctx,each_value,i))}const out=i=>transition_out(each_blocks[i],1,1,(()=>{each_blocks[i]=null}));const block={c:function create(){ul=element("ul");for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].c()}attr_dev(ul,"class",ul_class_value="subnav "+ctx[0]);toggle_class(ul,"subpage",ctx[1]);toggle_class(ul,"progress",ctx[2]);add_location(ul,file$Z,13,1,361)},m:function mount(target,anchor){insert_dev(target,ul,anchor);for(let i=0;i<each_blocks.length;i+=1){if(each_blocks[i]){each_blocks[i].m(ul,null)}}current=true},p:function update(ctx,dirty){if(dirty&28){each_value=ensure_array_like_dev(ctx[3]);let i;for(i=0;i<each_value.length;i+=1){const child_ctx=get_each_context$d(ctx,each_value,i);if(each_blocks[i]){each_blocks[i].p(child_ctx,dirty);transition_in(each_blocks[i],1)}else{each_blocks[i]=create_each_block$d(child_ctx);each_blocks[i].c();transition_in(each_blocks[i],1);each_blocks[i].m(ul,null)}}group_outros();for(i=each_value.length;i<each_blocks.length;i+=1){out(i)}check_outros()}if(!current||dirty&1&&ul_class_value!==(ul_class_value="subnav "+ctx[0])){attr_dev(ul,"class",ul_class_value)}if(!current||dirty&3){toggle_class(ul,"subpage",ctx[1])}if(!current||dirty&5){toggle_class(ul,"progress",ctx[2])}},i:function intro(local){if(current)return;for(let i=0;i<each_value.length;i+=1){transition_in(each_blocks[i])}current=true},o:function outro(local){each_blocks=each_blocks.filter(Boolean);for(let i=0;i<each_blocks.length;i+=1){transition_out(each_blocks[i])}current=false},d:function destroy(detaching){if(detaching){detach_dev(ul)}destroy_each(each_blocks,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$y.name,type:"if",source:"(13:0) {#if displayItems}",ctx:ctx});return block}function create_if_block_1$i(ctx){let li;let img;let img_src_value;let t;const block={c:function create(){li=element("li");img=element("img");t=space();if(!src_url_equal(img.src,img_src_value=ctx[4].assets+"img/icon/subnav-arrow.svg"))attr_dev(img,"src",img_src_value);attr_dev(img,"alt","");add_location(img,file$Z,19,5,634);attr_dev(li,"class","step-arrow");add_location(li,file$Z,18,4,605)},m:function mount(target,anchor){insert_dev(target,li,anchor);append_dev(li,img);append_dev(li,t)},p:function update(ctx,dirty){if(dirty&16&&!src_url_equal(img.src,img_src_value=ctx[4].assets+"img/icon/subnav-arrow.svg")){attr_dev(img,"src",img_src_value)}},d:function destroy(detaching){if(detaching){detach_dev(li)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_1$i.name,type:"if",source:"(18:3) {#if progress && index < (displayItems.length - 1)}",ctx:ctx});return block}function create_each_block$d(ctx){let subnavitem;let t;let if_block_anchor;let current;subnavitem=new SubNavItem({props:{page:ctx[6]},$$inline:true});let if_block=ctx[2]&&ctx[8]<ctx[3].length-1&&create_if_block_1$i(ctx);const block={c:function create(){create_component(subnavitem.$$.fragment);t=space();if(if_block)if_block.c();if_block_anchor=empty()},m:function mount(target,anchor){mount_component(subnavitem,target,anchor);insert_dev(target,t,anchor);if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,dirty){const subnavitem_changes={};if(dirty&8)subnavitem_changes.page=ctx[6];subnavitem.$set(subnavitem_changes);if(ctx[2]&&ctx[8]<ctx[3].length-1){if(if_block){if_block.p(ctx,dirty)}else{if_block=create_if_block_1$i(ctx);if_block.c();if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){if_block.d(1);if_block=null}},i:function intro(local){if(current)return;transition_in(subnavitem.$$.fragment,local);current=true},o:function outro(local){transition_out(subnavitem.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t);detach_dev(if_block_anchor)}destroy_component(subnavitem,detaching);if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_each_block$d.name,type:"each",source:"(15:2) {#each displayItems as page, index}",ctx:ctx});return block}function create_fragment$18(ctx){let if_block_anchor;let current;let if_block=ctx[3]&&create_if_block$y(ctx);const block={c:function create(){if(if_block)if_block.c();if_block_anchor=empty()},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,[dirty]){if(ctx[3]){if(if_block){if_block.p(ctx,dirty);if(dirty&8){transition_in(if_block,1)}}else{if_block=create_if_block$y(ctx);if_block.c();transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$18.name,type:"component",source:"",ctx:ctx});return block}function instance$18($$self,$$props,$$invalidate){let displayItems;let $urls;validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(4,$urls=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("SubNav",slots,[]);let{name:name="media"}=$$props;let{items:items=[]}=$$props;let{subpage:subpage=false}=$$props;let{progress:progress=false}=$$props;const writable_props=["name","items","subpage","progress"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<SubNav> was created with unknown prop '${key}'`)}));$$self.$$set=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name);if("items"in $$props)$$invalidate(5,items=$$props.items);if("subpage"in $$props)$$invalidate(1,subpage=$$props.subpage);if("progress"in $$props)$$invalidate(2,progress=$$props.progress)};$$self.$capture_state=()=>({urls:urls,SubNavItem:SubNavItem,name:name,items:items,subpage:subpage,progress:progress,displayItems:displayItems,$urls:$urls});$$self.$inject_state=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name);if("items"in $$props)$$invalidate(5,items=$$props.items);if("subpage"in $$props)$$invalidate(1,subpage=$$props.subpage);if("progress"in $$props)$$invalidate(2,progress=$$props.progress);if("displayItems"in $$props)$$invalidate(3,displayItems=$$props.displayItems)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty&32){$$invalidate(3,displayItems=items.filter((page=>page.title&&(!page.hasOwnProperty("enabled")||page.enabled()===true))))}};return[name,subpage,progress,displayItems,$urls,items]}class SubNav extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$18,create_fragment$18,safe_not_equal,{name:0,items:5,subpage:1,progress:2});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"SubNav",options:options,id:create_fragment$18.name})}get name(){throw new Error("<SubNav>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set name(value){throw new Error("<SubNav>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get items(){throw new Error("<SubNav>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set items(value){throw new Error("<SubNav>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get subpage(){throw new Error("<SubNav>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set subpage(value){throw new Error("<SubNav>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get progress(){throw new Error("<SubNav>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set progress(value){throw new Error("<SubNav>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$Y="ui/components/SubPages.svelte";function create_if_block$x(ctx){let div;let router;let t;let div_class_value;let current;router=new Router({props:{routes:ctx[2],prefix:ctx[1]},$$inline:true});router.$on("routeEvent",ctx[5]);const default_slot_template=ctx[4].default;const default_slot=create_slot(default_slot_template,ctx,ctx[3],null);const block={c:function create(){div=element("div");create_component(router.$$.fragment);t=space();if(default_slot)default_slot.c();attr_dev(div,"class",div_class_value=""+(ctx[0]+"-page wrapper"));add_location(div,file$Y,9,1,152)},m:function mount(target,anchor){insert_dev(target,div,anchor);mount_component(router,div,null);append_dev(div,t);if(default_slot){default_slot.m(div,null)}current=true},p:function update(ctx,dirty){const router_changes={};if(dirty&4)router_changes.routes=ctx[2];if(dirty&2)router_changes.prefix=ctx[1];router.$set(router_changes);if(default_slot){if(default_slot.p&&(!current||dirty&8)){update_slot_base(default_slot,default_slot_template,ctx,ctx[3],!current?get_all_dirty_from_scope(ctx[3]):get_slot_changes(default_slot_template,ctx[3],dirty,null),null)}}if(!current||dirty&1&&div_class_value!==(div_class_value=""+(ctx[0]+"-page wrapper"))){attr_dev(div,"class",div_class_value)}},i:function intro(local){if(current)return;transition_in(router.$$.fragment,local);transition_in(default_slot,local);current=true},o:function outro(local){transition_out(router.$$.fragment,local);transition_out(default_slot,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(div)}destroy_component(router);if(default_slot)default_slot.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$x.name,type:"if",source:"(9:0) {#if routes}",ctx:ctx});return block}function create_fragment$17(ctx){let if_block_anchor;let current;let if_block=ctx[2]&&create_if_block$x(ctx);const block={c:function create(){if(if_block)if_block.c();if_block_anchor=empty()},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,[dirty]){if(ctx[2]){if(if_block){if_block.p(ctx,dirty);if(dirty&4){transition_in(if_block,1)}}else{if_block=create_if_block$x(ctx);if_block.c();transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$17.name,type:"component",source:"",ctx:ctx});return block}function instance$17($$self,$$props,$$invalidate){let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("SubPages",slots,["default"]);let{name:name="sub"}=$$props;let{prefix:prefix=""}=$$props;let{routes:routes={}}=$$props;const writable_props=["name","prefix","routes"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<SubPages> was created with unknown prop '${key}'`)}));function routeEvent_handler(event){bubble.call(this,$$self,event)}$$self.$$set=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name);if("prefix"in $$props)$$invalidate(1,prefix=$$props.prefix);if("routes"in $$props)$$invalidate(2,routes=$$props.routes);if("$$scope"in $$props)$$invalidate(3,$$scope=$$props.$$scope)};$$self.$capture_state=()=>({Router:Router,name:name,prefix:prefix,routes:routes});$$self.$inject_state=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name);if("prefix"in $$props)$$invalidate(1,prefix=$$props.prefix);if("routes"in $$props)$$invalidate(2,routes=$$props.routes)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[name,prefix,routes,$$scope,slots,routeEvent_handler]}class SubPages extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$17,create_fragment$17,safe_not_equal,{name:0,prefix:1,routes:2});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"SubPages",options:options,id:create_fragment$17.name})}get name(){throw new Error("<SubPages>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set name(value){throw new Error("<SubPages>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get prefix(){throw new Error("<SubPages>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set prefix(value){throw new Error("<SubPages>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get routes(){throw new Error("<SubPages>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set routes(value){throw new Error("<SubPages>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const nodes=[];let location;function checkActive(el){const matchesLocation=el.pattern.test(location);toggleClasses(el,el.className,matchesLocation);toggleClasses(el,el.inactiveClassName,!matchesLocation)}function toggleClasses(el,className,shouldAdd){(className||"").split(" ").forEach((cls=>{if(!cls){return}el.node.classList.remove(cls);if(shouldAdd){el.node.classList.add(cls)}}))}loc.subscribe((value=>{location=value.location+(value.querystring?"?"+value.querystring:"");nodes.map(checkActive)}));function active(node,opts){if(opts&&(typeof opts=="string"||typeof opts=="object"&&opts instanceof RegExp)){opts={path:opts}}else{opts=opts||{}}if(!opts.path&&node.hasAttribute("href")){opts.path=node.getAttribute("href");if(opts.path&&opts.path.length>1&&opts.path.charAt(0)=="#"){opts.path=opts.path.substring(1)}}if(!opts.className){opts.className="active"}if(!opts.path||typeof opts.path=="string"&&(opts.path.length<1||opts.path.charAt(0)!="/"&&opts.path.charAt(0)!="*")){throw Error('Invalid value for "path" argument')}const{pattern:pattern}=typeof opts.path=="string"?parse(opts.path):{pattern:opts.path};const el={node:node,className:opts.className,inactiveClassName:opts.inactiveClassName,pattern:pattern};nodes.push(el);checkActive(el);return{destroy(){nodes.splice(nodes.indexOf(el),1)}}}const file$X="ui/components/SubPage.svelte";function create_fragment$16(ctx){let div;let active_action;let current;let mounted;let dispose;const default_slot_template=ctx[3].default;const default_slot=create_slot(default_slot_template,ctx,ctx[2],null);const block={c:function create(){div=element("div");if(default_slot)default_slot.c();attr_dev(div,"class",ctx[0]);add_location(div,file$X,7,0,117)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,div,anchor);if(default_slot){default_slot.m(div,null)}current=true;if(!mounted){dispose=action_destroyer(active_action=active.call(null,div,ctx[1]));mounted=true}},p:function update(ctx,[dirty]){if(default_slot){if(default_slot.p&&(!current||dirty&4)){update_slot_base(default_slot,default_slot_template,ctx,ctx[2],!current?get_all_dirty_from_scope(ctx[2]):get_slot_changes(default_slot_template,ctx[2],dirty,null),null)}}if(!current||dirty&1){attr_dev(div,"class",ctx[0])}if(active_action&&is_function(active_action.update)&&dirty&2)active_action.update.call(null,ctx[1])},i:function intro(local){if(current)return;transition_in(default_slot,local);current=true},o:function outro(local){transition_out(default_slot,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(div)}if(default_slot)default_slot.d(detaching);mounted=false;dispose()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$16.name,type:"component",source:"",ctx:ctx});return block}function instance$16($$self,$$props,$$invalidate){let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("SubPage",slots,["default"]);let{name:name=""}=$$props;let{route:route="/"}=$$props;const writable_props=["name","route"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<SubPage> was created with unknown prop '${key}'`)}));$$self.$$set=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name);if("route"in $$props)$$invalidate(1,route=$$props.route);if("$$scope"in $$props)$$invalidate(2,$$scope=$$props.$$scope)};$$self.$capture_state=()=>({active:active,name:name,route:route});$$self.$inject_state=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name);if("route"in $$props)$$invalidate(1,route=$$props.route)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[name,route,$$scope,slots]}class SubPage extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$16,create_fragment$16,safe_not_equal,{name:0,route:1});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"SubPage",options:options,id:create_fragment$16.name})}get name(){throw new Error("<SubPage>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set name(value){throw new Error("<SubPage>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get route(){throw new Error("<SubPage>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set route(value){throw new Error("<SubPage>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}function cubicOut(t){const f=t-1;return f*f*f+1}function fade(node,{delay:delay=0,duration:duration=400,easing:easing=identity}={}){const o=+getComputedStyle(node).opacity;return{delay:delay,duration:duration,easing:easing,css:t=>`opacity: ${t*o}`}}function slide(node,{delay:delay=0,duration:duration=400,easing:easing=cubicOut,axis:axis="y"}={}){const style=getComputedStyle(node);const opacity=+style.opacity;const primary_property=axis==="y"?"height":"width";const primary_property_value=parseFloat(style[primary_property]);const secondary_properties=axis==="y"?["top","bottom"]:["left","right"];const capitalized_secondary_properties=secondary_properties.map((e=>`${e[0].toUpperCase()}${e.slice(1)}`));const padding_start_value=parseFloat(style[`padding${capitalized_secondary_properties[0]}`]);const padding_end_value=parseFloat(style[`padding${capitalized_secondary_properties[1]}`]);const margin_start_value=parseFloat(style[`margin${capitalized_secondary_properties[0]}`]);const margin_end_value=parseFloat(style[`margin${capitalized_secondary_properties[1]}`]);const border_width_start_value=parseFloat(style[`border${capitalized_secondary_properties[0]}Width`]);const border_width_end_value=parseFloat(style[`border${capitalized_secondary_properties[1]}Width`]);return{delay:delay,duration:duration,easing:easing,css:t=>"overflow: hidden;"+`opacity: ${Math.min(t*20,1)*opacity};`+`${primary_property}: ${t*primary_property_value}px;`+`padding-${secondary_properties[0]}: ${t*padding_start_value}px;`+`padding-${secondary_properties[1]}: ${t*padding_end_value}px;`+`margin-${secondary_properties[0]}: ${t*margin_start_value}px;`+`margin-${secondary_properties[1]}: ${t*margin_end_value}px;`+`border-${secondary_properties[0]}-width: ${t*border_width_start_value}px;`+`border-${secondary_properties[1]}-width: ${t*border_width_end_value}px;`}}function scale(node,{delay:delay=0,duration:duration=400,easing:easing=cubicOut,start:start=0,opacity:opacity=0}={}){const style=getComputedStyle(node);const target_opacity=+style.opacity;const transform=style.transform==="none"?"":style.transform;const sd=1-start;const od=target_opacity*(1-opacity);return{delay:delay,duration:duration,easing:easing,css:(_t,u)=>`\n\t\t\ttransform: ${transform} scale(${1-sd*u});\n\t\t\topacity: ${target_opacity-od*u}\n\t\t`}}const file$W="ui/components/PanelContainer.svelte";function create_fragment$15(ctx){let div;let current;const default_slot_template=ctx[2].default;const default_slot=create_slot(default_slot_template,ctx,ctx[1],null);const block={c:function create(){div=element("div");if(default_slot)default_slot.c();attr_dev(div,"class","panel-container "+ctx[0]);add_location(div,file$W,4,0,73)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,div,anchor);if(default_slot){default_slot.m(div,null)}current=true},p:function update(ctx,[dirty]){if(default_slot){if(default_slot.p&&(!current||dirty&2)){update_slot_base(default_slot,default_slot_template,ctx,ctx[1],!current?get_all_dirty_from_scope(ctx[1]):get_slot_changes(default_slot_template,ctx[1],dirty,null),null)}}},i:function intro(local){if(current)return;transition_in(default_slot,local);current=true},o:function outro(local){transition_out(default_slot,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(div)}if(default_slot)default_slot.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$15.name,type:"component",source:"",ctx:ctx});return block}function instance$15($$self,$$props,$$invalidate){let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("PanelContainer",slots,["default"]);const classes=$$props.class?$$props.class:"";$$self.$$set=$$new_props=>{$$invalidate(3,$$props=assign(assign({},$$props),exclude_internal_props($$new_props)));if("$$scope"in $$new_props)$$invalidate(1,$$scope=$$new_props.$$scope)};$$self.$capture_state=()=>({classes:classes});$$self.$inject_state=$$new_props=>{$$invalidate(3,$$props=assign(assign({},$$props),$$new_props))};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$props=exclude_internal_props($$props);return[classes,$$scope,slots]}class PanelContainer extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$15,create_fragment$15,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"PanelContainer",options:options,id:create_fragment$15.name})}}const file$V="ui/components/PanelRow.svelte";function create_if_block$w(ctx){let div;const block={c:function create(){div=element("div");attr_dev(div,"class","gradient svelte-41r5oq");add_location(div,file$V,10,2,238)},m:function mount(target,anchor){insert_dev(target,div,anchor)},d:function destroy(detaching){if(detaching){detach_dev(div)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$w.name,type:"if",source:"(10:1) {#if gradient}",ctx:ctx});return block}function create_fragment$14(ctx){let div;let t;let current;let if_block=ctx[2]&&create_if_block$w(ctx);const default_slot_template=ctx[5].default;const default_slot=create_slot(default_slot_template,ctx,ctx[4],null);const block={c:function create(){div=element("div");if(if_block)if_block.c();t=space();if(default_slot)default_slot.c();attr_dev(div,"class","panel-row "+ctx[3]+" svelte-41r5oq");toggle_class(div,"header",ctx[0]);toggle_class(div,"footer",ctx[1]);add_location(div,file$V,8,0,160)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,div,anchor);if(if_block)if_block.m(div,null);append_dev(div,t);if(default_slot){default_slot.m(div,null)}current=true},p:function update(ctx,[dirty]){if(ctx[2]){if(if_block);else{if_block=create_if_block$w(ctx);if_block.c();if_block.m(div,t)}}else if(if_block){if_block.d(1);if_block=null}if(default_slot){if(default_slot.p&&(!current||dirty&16)){update_slot_base(default_slot,default_slot_template,ctx,ctx[4],!current?get_all_dirty_from_scope(ctx[4]):get_slot_changes(default_slot_template,ctx[4],dirty,null),null)}}if(!current||dirty&1){toggle_class(div,"header",ctx[0])}if(!current||dirty&2){toggle_class(div,"footer",ctx[1])}},i:function intro(local){if(current)return;transition_in(default_slot,local);current=true},o:function outro(local){transition_out(default_slot,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(div)}if(if_block)if_block.d();if(default_slot)default_slot.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$14.name,type:"component",source:"",ctx:ctx});return block}function instance$14($$self,$$props,$$invalidate){let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("PanelRow",slots,["default"]);const classes=$$props.class?$$props.class:"";let{header:header=false}=$$props;let{footer:footer=false}=$$props;let{gradient:gradient=false}=$$props;$$self.$$set=$$new_props=>{$$invalidate(6,$$props=assign(assign({},$$props),exclude_internal_props($$new_props)));if("header"in $$new_props)$$invalidate(0,header=$$new_props.header);if("footer"in $$new_props)$$invalidate(1,footer=$$new_props.footer);if("gradient"in $$new_props)$$invalidate(2,gradient=$$new_props.gradient);if("$$scope"in $$new_props)$$invalidate(4,$$scope=$$new_props.$$scope)};$$self.$capture_state=()=>({classes:classes,header:header,footer:footer,gradient:gradient});$$self.$inject_state=$$new_props=>{$$invalidate(6,$$props=assign(assign({},$$props),$$new_props));if("header"in $$props)$$invalidate(0,header=$$new_props.header);if("footer"in $$props)$$invalidate(1,footer=$$new_props.footer);if("gradient"in $$props)$$invalidate(2,gradient=$$new_props.gradient)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$props=exclude_internal_props($$props);return[header,footer,gradient,classes,$$scope,slots]}class PanelRow extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$14,create_fragment$14,safe_not_equal,{header:0,footer:1,gradient:2});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"PanelRow",options:options,id:create_fragment$14.name})}get header(){throw new Error("<PanelRow>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set header(value){throw new Error("<PanelRow>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get footer(){throw new Error("<PanelRow>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set footer(value){throw new Error("<PanelRow>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get gradient(){throw new Error("<PanelRow>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set gradient(value){throw new Error("<PanelRow>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$U="ui/components/DefinedInWPConfig.svelte";function create_if_block$v(ctx){let p;let t_value=ctx[1].defined_in_wp_config+"";let t;const block={c:function create(){p=element("p");t=text(t_value);attr_dev(p,"class","wp-config");add_location(p,file$U,7,1,104)},m:function mount(target,anchor){insert_dev(target,p,anchor);append_dev(p,t)},p:function update(ctx,dirty){if(dirty&2&&t_value!==(t_value=ctx[1].defined_in_wp_config+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$v.name,type:"if",source:"(7:0) {#if defined}",ctx:ctx});return block}function create_fragment$13(ctx){let if_block_anchor;let if_block=ctx[0]&&create_if_block$v(ctx);const block={c:function create(){if(if_block)if_block.c();if_block_anchor=empty()},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor)},p:function update(ctx,[dirty]){if(ctx[0]){if(if_block){if_block.p(ctx,dirty)}else{if_block=create_if_block$v(ctx);if_block.c();if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){if_block.d(1);if_block=null}},i:noop,o:noop,d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$13.name,type:"component",source:"",ctx:ctx});return block}function instance$13($$self,$$props,$$invalidate){let $strings;validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(1,$strings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("DefinedInWPConfig",slots,[]);let{defined:defined=false}=$$props;const writable_props=["defined"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<DefinedInWPConfig> was created with unknown prop '${key}'`)}));$$self.$$set=$$props=>{if("defined"in $$props)$$invalidate(0,defined=$$props.defined)};$$self.$capture_state=()=>({strings:strings,defined:defined,$strings:$strings});$$self.$inject_state=$$props=>{if("defined"in $$props)$$invalidate(0,defined=$$props.defined)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[defined,$strings]}class DefinedInWPConfig extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$13,create_fragment$13,safe_not_equal,{defined:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"DefinedInWPConfig",options:options,id:create_fragment$13.name})}get defined(){throw new Error("<DefinedInWPConfig>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set defined(value){throw new Error("<DefinedInWPConfig>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$T="ui/components/ToggleSwitch.svelte";function create_fragment$12(ctx){let div;let input;let t;let label;let current;let mounted;let dispose;const default_slot_template=ctx[4].default;const default_slot=create_slot(default_slot_template,ctx,ctx[3],null);const block={c:function create(){div=element("div");input=element("input");t=space();label=element("label");if(default_slot)default_slot.c();attr_dev(input,"type","checkbox");attr_dev(input,"id",ctx[1]);input.disabled=ctx[2];add_location(input,file$T,7,1,155);attr_dev(label,"class","toggle-label");attr_dev(label,"for",ctx[1]);add_location(label,file$T,13,1,235);attr_dev(div,"class","toggle-switch");toggle_class(div,"locked",ctx[2]);add_location(div,file$T,6,0,102)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,div,anchor);append_dev(div,input);input.checked=ctx[0];append_dev(div,t);append_dev(div,label);if(default_slot){default_slot.m(label,null)}current=true;if(!mounted){dispose=listen_dev(input,"change",ctx[5]);mounted=true}},p:function update(ctx,[dirty]){if(!current||dirty&2){attr_dev(input,"id",ctx[1])}if(!current||dirty&4){prop_dev(input,"disabled",ctx[2])}if(dirty&1){input.checked=ctx[0]}if(default_slot){if(default_slot.p&&(!current||dirty&8)){update_slot_base(default_slot,default_slot_template,ctx,ctx[3],!current?get_all_dirty_from_scope(ctx[3]):get_slot_changes(default_slot_template,ctx[3],dirty,null),null)}}if(!current||dirty&2){attr_dev(label,"for",ctx[1])}if(!current||dirty&4){toggle_class(div,"locked",ctx[2])}},i:function intro(local){if(current)return;transition_in(default_slot,local);current=true},o:function outro(local){transition_out(default_slot,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(div)}if(default_slot)default_slot.d(detaching);mounted=false;dispose()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$12.name,type:"component",source:"",ctx:ctx});return block}function instance$12($$self,$$props,$$invalidate){let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("ToggleSwitch",slots,["default"]);let{name:name=""}=$$props;let{checked:checked=false}=$$props;let{disabled:disabled=false}=$$props;const writable_props=["name","checked","disabled"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<ToggleSwitch> was created with unknown prop '${key}'`)}));function input_change_handler(){checked=this.checked;$$invalidate(0,checked)}$$self.$$set=$$props=>{if("name"in $$props)$$invalidate(1,name=$$props.name);if("checked"in $$props)$$invalidate(0,checked=$$props.checked);if("disabled"in $$props)$$invalidate(2,disabled=$$props.disabled);if("$$scope"in $$props)$$invalidate(3,$$scope=$$props.$$scope)};$$self.$capture_state=()=>({name:name,checked:checked,disabled:disabled});$$self.$inject_state=$$props=>{if("name"in $$props)$$invalidate(1,name=$$props.name);if("checked"in $$props)$$invalidate(0,checked=$$props.checked);if("disabled"in $$props)$$invalidate(2,disabled=$$props.disabled)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[checked,name,disabled,$$scope,slots,input_change_handler]}class ToggleSwitch extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$12,create_fragment$12,safe_not_equal,{name:1,checked:0,disabled:2});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"ToggleSwitch",options:options,id:create_fragment$12.name})}get name(){throw new Error("<ToggleSwitch>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set name(value){throw new Error("<ToggleSwitch>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get checked(){throw new Error("<ToggleSwitch>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set checked(value){throw new Error("<ToggleSwitch>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get disabled(){throw new Error("<ToggleSwitch>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set disabled(value){throw new Error("<ToggleSwitch>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$S="ui/components/HelpButton.svelte";function create_if_block$u(ctx){let a;let img;let img_src_value;const block={c:function create(){a=element("a");img=element("img");attr_dev(img,"class","icon help");if(!src_url_equal(img.src,img_src_value=ctx[2].assets+"img/icon/help.svg"))attr_dev(img,"src",img_src_value);attr_dev(img,"alt",ctx[3]);add_location(img,file$S,14,2,603);attr_dev(a,"href",ctx[1]);attr_dev(a,"title",ctx[4]);attr_dev(a,"class","help");attr_dev(a,"target","_blank");attr_dev(a,"data-setting-key",ctx[0]);add_location(a,file$S,13,1,526)},m:function mount(target,anchor){insert_dev(target,a,anchor);append_dev(a,img)},p:function update(ctx,dirty){if(dirty&4&&!src_url_equal(img.src,img_src_value=ctx[2].assets+"img/icon/help.svg")){attr_dev(img,"src",img_src_value)}if(dirty&2){attr_dev(a,"href",ctx[1])}if(dirty&1){attr_dev(a,"data-setting-key",ctx[0])}},d:function destroy(detaching){if(detaching){detach_dev(a)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$u.name,type:"if",source:"(13:0) {#if url}",ctx:ctx});return block}function create_fragment$11(ctx){let if_block_anchor;let if_block=ctx[1]&&create_if_block$u(ctx);const block={c:function create(){if(if_block)if_block.c();if_block_anchor=empty()},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor)},p:function update(ctx,[dirty]){if(ctx[1]){if(if_block){if_block.p(ctx,dirty)}else{if_block=create_if_block$u(ctx);if_block.c();if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){if_block.d(1);if_block=null}},i:noop,o:noop,d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$11.name,type:"component",source:"",ctx:ctx});return block}function instance$11($$self,$$props,$$invalidate){let $strings;let $docs;let $urls;validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(6,$strings=$$value)));validate_store(docs,"docs");component_subscribe($$self,docs,($$value=>$$invalidate(7,$docs=$$value)));validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(2,$urls=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("HelpButton",slots,[]);let{key:key=""}=$$props;let{url:url=(key&&$docs.hasOwnProperty(key)&&$docs[key].hasOwnProperty("url")?$docs[key].url:"")}=$$props;let{desc:desc=""}=$$props;let alt=desc.length?desc:key&&$docs.hasOwnProperty(key)&&$docs[key].hasOwnProperty("desc")?$docs[key].desc:$strings.help_desc;let title=alt;const writable_props=["key","url","desc"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<HelpButton> was created with unknown prop '${key}'`)}));$$self.$$set=$$props=>{if("key"in $$props)$$invalidate(0,key=$$props.key);if("url"in $$props)$$invalidate(1,url=$$props.url);if("desc"in $$props)$$invalidate(5,desc=$$props.desc)};$$self.$capture_state=()=>({strings:strings,urls:urls,docs:docs,key:key,url:url,desc:desc,alt:alt,title:title,$strings:$strings,$docs:$docs,$urls:$urls});$$self.$inject_state=$$props=>{if("key"in $$props)$$invalidate(0,key=$$props.key);if("url"in $$props)$$invalidate(1,url=$$props.url);if("desc"in $$props)$$invalidate(5,desc=$$props.desc);if("alt"in $$props)$$invalidate(3,alt=$$props.alt);if("title"in $$props)$$invalidate(4,title=$$props.title)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[key,url,$urls,alt,title,desc]}class HelpButton extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$11,create_fragment$11,safe_not_equal,{key:0,url:1,desc:5});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"HelpButton",options:options,id:create_fragment$11.name})}get key(){throw new Error("<HelpButton>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set key(value){throw new Error("<HelpButton>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get url(){throw new Error("<HelpButton>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set url(value){throw new Error("<HelpButton>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get desc(){throw new Error("<HelpButton>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set desc(value){throw new Error("<HelpButton>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$R="ui/components/Panel.svelte";function create_if_block_6$4(ctx){let div;let h2;let t0;let t1;let current_block_type_index;let if_block;let t2;let definedinwpconfig;let current;const if_block_creators=[create_if_block_7$4,create_if_block_8$4];const if_blocks=[];function select_block_type(ctx,dirty){if(ctx[13])return 0;if(ctx[12])return 1;return-1}if(~(current_block_type_index=select_block_type(ctx))){if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx)}definedinwpconfig=new DefinedInWPConfig({props:{defined:ctx[4]},$$inline:true});const block={c:function create(){div=element("div");h2=element("h2");t0=text(ctx[3]);t1=space();if(if_block)if_block.c();t2=space();create_component(definedinwpconfig.$$.fragment);add_location(h2,file$R,87,3,2464);attr_dev(div,"class","heading");add_location(div,file$R,86,2,2439)},m:function mount(target,anchor){insert_dev(target,div,anchor);append_dev(div,h2);append_dev(h2,t0);append_dev(div,t1);if(~current_block_type_index){if_blocks[current_block_type_index].m(div,null)}append_dev(div,t2);mount_component(definedinwpconfig,div,null);current=true},p:function update(ctx,dirty){if(!current||dirty[0]&8)set_data_dev(t0,ctx[3]);let previous_block_index=current_block_type_index;current_block_type_index=select_block_type(ctx);if(current_block_type_index===previous_block_index){if(~current_block_type_index){if_blocks[current_block_type_index].p(ctx,dirty)}}else{if(if_block){group_outros();transition_out(if_blocks[previous_block_index],1,1,(()=>{if_blocks[previous_block_index]=null}));check_outros()}if(~current_block_type_index){if_block=if_blocks[current_block_type_index];if(!if_block){if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);if_block.c()}else{if_block.p(ctx,dirty)}transition_in(if_block,1);if_block.m(div,t2)}else{if_block=null}}const definedinwpconfig_changes={};if(dirty[0]&16)definedinwpconfig_changes.defined=ctx[4];definedinwpconfig.$set(definedinwpconfig_changes)},i:function intro(local){if(current)return;transition_in(if_block);transition_in(definedinwpconfig.$$.fragment,local);current=true},o:function outro(local){transition_out(if_block);transition_out(definedinwpconfig.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(div)}if(~current_block_type_index){if_blocks[current_block_type_index].d()}destroy_component(definedinwpconfig)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_6$4.name,type:"if",source:"(86:1) {#if !multi && heading}",ctx:ctx});return block}function create_if_block_8$4(ctx){let helpbutton;let current;helpbutton=new HelpButton({props:{key:ctx[12],desc:ctx[14]},$$inline:true});const block={c:function create(){create_component(helpbutton.$$.fragment)},m:function mount(target,anchor){mount_component(helpbutton,target,anchor);current=true},p:function update(ctx,dirty){const helpbutton_changes={};if(dirty[0]&4096)helpbutton_changes.key=ctx[12];if(dirty[0]&16384)helpbutton_changes.desc=ctx[14];helpbutton.$set(helpbutton_changes)},i:function intro(local){if(current)return;transition_in(helpbutton.$$.fragment,local);current=true},o:function outro(local){transition_out(helpbutton.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(helpbutton,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_8$4.name,type:"if",source:"(91:21) ",ctx:ctx});return block}function create_if_block_7$4(ctx){let helpbutton;let current;helpbutton=new HelpButton({props:{url:ctx[13],desc:ctx[14]},$$inline:true});const block={c:function create(){create_component(helpbutton.$$.fragment)},m:function mount(target,anchor){mount_component(helpbutton,target,anchor);current=true},p:function update(ctx,dirty){const helpbutton_changes={};if(dirty[0]&8192)helpbutton_changes.url=ctx[13];if(dirty[0]&16384)helpbutton_changes.desc=ctx[14];helpbutton.$set(helpbutton_changes)},i:function intro(local){if(current)return;transition_in(helpbutton.$$.fragment,local);current=true},o:function outro(local){transition_out(helpbutton.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(helpbutton,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_7$4.name,type:"if",source:"(89:3) {#if helpURL}",ctx:ctx});return block}function create_if_block$t(ctx){let panelrow;let current;panelrow=new PanelRow({props:{header:true,$$slots:{default:[create_default_slot_1$r]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty[0]&327578|dirty[1]&8){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$t.name,type:"if",source:"(98:2) {#if multi && heading}",ctx:ctx});return block}function create_else_block$e(ctx){let h3;let t;const block={c:function create(){h3=element("h3");t=text(ctx[3]);add_location(h3,file$R,108,5,3174)},m:function mount(target,anchor){insert_dev(target,h3,anchor);append_dev(h3,t)},p:function update(ctx,dirty){if(dirty[0]&8)set_data_dev(t,ctx[3])},i:noop,o:noop,d:function destroy(detaching){if(detaching){detach_dev(h3)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block$e.name,type:"else",source:"(108:4) {:else}",ctx:ctx});return block}function create_if_block_5$4(ctx){let toggleswitch;let updating_checked;let t0;let h3;let t1;let current;let mounted;let dispose;function toggleswitch_checked_binding(value){ctx[31](value)}let toggleswitch_props={name:ctx[7],disabled:ctx[18],$$slots:{default:[create_default_slot_3$8]},$$scope:{ctx:ctx}};if(ctx[1]!==void 0){toggleswitch_props.checked=ctx[1]}toggleswitch=new ToggleSwitch({props:toggleswitch_props,$$inline:true});binding_callbacks.push((()=>bind(toggleswitch,"checked",toggleswitch_checked_binding)));const block={c:function create(){create_component(toggleswitch.$$.fragment);t0=space();h3=element("h3");t1=text(ctx[3]);attr_dev(h3,"class","toggler svelte-k1tgof");toggle_class(h3,"toggleDisabled",ctx[18]);add_location(h3,file$R,106,5,3070)},m:function mount(target,anchor){mount_component(toggleswitch,target,anchor);insert_dev(target,t0,anchor);insert_dev(target,h3,anchor);append_dev(h3,t1);current=true;if(!mounted){dispose=listen_dev(h3,"click",ctx[21],false,false,false,false);mounted=true}},p:function update(ctx,dirty){const toggleswitch_changes={};if(dirty[0]&128)toggleswitch_changes.name=ctx[7];if(dirty[0]&262144)toggleswitch_changes.disabled=ctx[18];if(dirty[0]&8|dirty[1]&8){toggleswitch_changes.$$scope={dirty:dirty,ctx:ctx}}if(!updating_checked&&dirty[0]&2){updating_checked=true;toggleswitch_changes.checked=ctx[1];add_flush_callback((()=>updating_checked=false))}toggleswitch.$set(toggleswitch_changes);if(!current||dirty[0]&8)set_data_dev(t1,ctx[3]);if(!current||dirty[0]&262144){toggle_class(h3,"toggleDisabled",ctx[18])}},i:function intro(local){if(current)return;transition_in(toggleswitch.$$.fragment,local);current=true},o:function outro(local){transition_out(toggleswitch.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(h3)}destroy_component(toggleswitch,detaching);mounted=false;dispose()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_5$4.name,type:"if",source:"(100:4) {#if toggleName}",ctx:ctx});return block}function create_default_slot_3$8(ctx){let t;const block={c:function create(){t=text(ctx[3])},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty[0]&8)set_data_dev(t,ctx[3])},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_3$8.name,type:"slot",source:"(101:5) <ToggleSwitch name={toggleName} bind:checked={toggle} disabled={toggleDisabled}>",ctx:ctx});return block}function create_if_block_4$6(ctx){let button;let current;button=new Button({props:{refresh:true,refreshing:ctx[11],title:ctx[10],$$slots:{default:[create_default_slot_2$j]},$$scope:{ctx:ctx}},$$inline:true});button.$on("click",ctx[32]);const block={c:function create(){create_component(button.$$.fragment)},m:function mount(target,anchor){mount_component(button,target,anchor);current=true},p:function update(ctx,dirty){const button_changes={};if(dirty[0]&2048)button_changes.refreshing=ctx[11];if(dirty[0]&1024)button_changes.title=ctx[10];if(dirty[0]&512|dirty[1]&8){button_changes.$$scope={dirty:dirty,ctx:ctx}}button.$set(button_changes)},i:function intro(local){if(current)return;transition_in(button.$$.fragment,local);current=true},o:function outro(local){transition_out(button.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(button,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_4$6.name,type:"if",source:"(112:4) {#if refresh}",ctx:ctx});return block}function create_default_slot_2$j(ctx){let html_tag;let html_anchor;const block={c:function create(){html_tag=new HtmlTag(false);html_anchor=empty();html_tag.a=html_anchor},m:function mount(target,anchor){html_tag.m(ctx[9],target,anchor);insert_dev(target,html_anchor,anchor)},p:function update(ctx,dirty){if(dirty[0]&512)html_tag.p(ctx[9])},d:function destroy(detaching){if(detaching){detach_dev(html_anchor);html_tag.d()}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_2$j.name,type:"slot",source:'(113:5) <Button refresh {refreshing} title={refreshDesc} on:click={() => dispatch(\\"refresh\\")}>',ctx:ctx});return block}function create_if_block_3$6(ctx){let div;let a;let img;let img_src_value;let img_alt_value;let t0;let t1_value=ctx[15].provider_service_name+"";let t1;let mounted;let dispose;const block={c:function create(){div=element("div");a=element("a");img=element("img");t0=space();t1=text(t1_value);if(!src_url_equal(img.src,img_src_value=ctx[15].link_icon))attr_dev(img,"src",img_src_value);attr_dev(img,"alt",img_alt_value=ctx[15].icon_desc);add_location(img,file$R,117,7,3504);attr_dev(a,"href","/storage/provider");attr_dev(a,"class","link");add_location(a,file$R,116,6,3446);attr_dev(div,"class","provider");add_location(div,file$R,115,5,3417)},m:function mount(target,anchor){insert_dev(target,div,anchor);append_dev(div,a);append_dev(a,img);append_dev(a,t0);append_dev(a,t1);if(!mounted){dispose=action_destroyer(link.call(null,a));mounted=true}},p:function update(ctx,dirty){if(dirty[0]&32768&&!src_url_equal(img.src,img_src_value=ctx[15].link_icon)){attr_dev(img,"src",img_src_value)}if(dirty[0]&32768&&img_alt_value!==(img_alt_value=ctx[15].icon_desc)){attr_dev(img,"alt",img_alt_value)}if(dirty[0]&32768&&t1_value!==(t1_value=ctx[15].provider_service_name+""))set_data_dev(t1,t1_value)},d:function destroy(detaching){if(detaching){detach_dev(div)}mounted=false;dispose()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_3$6.name,type:"if",source:"(115:4) {#if storageProvider}",ctx:ctx});return block}function create_if_block_2$9(ctx){let helpbutton;let current;helpbutton=new HelpButton({props:{key:ctx[12],desc:ctx[14]},$$inline:true});const block={c:function create(){create_component(helpbutton.$$.fragment)},m:function mount(target,anchor){mount_component(helpbutton,target,anchor);current=true},p:function update(ctx,dirty){const helpbutton_changes={};if(dirty[0]&4096)helpbutton_changes.key=ctx[12];if(dirty[0]&16384)helpbutton_changes.desc=ctx[14];helpbutton.$set(helpbutton_changes)},i:function intro(local){if(current)return;transition_in(helpbutton.$$.fragment,local);current=true},o:function outro(local){transition_out(helpbutton.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(helpbutton,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_2$9.name,type:"if",source:"(125:22) ",ctx:ctx});return block}function create_if_block_1$h(ctx){let helpbutton;let current;helpbutton=new HelpButton({props:{url:ctx[13],desc:ctx[14]},$$inline:true});const block={c:function create(){create_component(helpbutton.$$.fragment)},m:function mount(target,anchor){mount_component(helpbutton,target,anchor);current=true},p:function update(ctx,dirty){const helpbutton_changes={};if(dirty[0]&8192)helpbutton_changes.url=ctx[13];if(dirty[0]&16384)helpbutton_changes.desc=ctx[14];helpbutton.$set(helpbutton_changes)},i:function intro(local){if(current)return;transition_in(helpbutton.$$.fragment,local);current=true},o:function outro(local){transition_out(helpbutton.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(helpbutton,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_1$h.name,type:"if",source:"(123:4) {#if helpURL}",ctx:ctx});return block}function create_default_slot_1$r(ctx){let current_block_type_index;let if_block0;let t0;let definedinwpconfig;let t1;let t2;let t3;let current_block_type_index_1;let if_block3;let if_block3_anchor;let current;const if_block_creators=[create_if_block_5$4,create_else_block$e];const if_blocks=[];function select_block_type_1(ctx,dirty){if(ctx[7])return 0;return 1}current_block_type_index=select_block_type_1(ctx);if_block0=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);definedinwpconfig=new DefinedInWPConfig({props:{defined:ctx[4]},$$inline:true});let if_block1=ctx[8]&&create_if_block_4$6(ctx);let if_block2=ctx[15]&&create_if_block_3$6(ctx);const if_block_creators_1=[create_if_block_1$h,create_if_block_2$9];const if_blocks_1=[];function select_block_type_2(ctx,dirty){if(ctx[13])return 0;if(ctx[12])return 1;return-1}if(~(current_block_type_index_1=select_block_type_2(ctx))){if_block3=if_blocks_1[current_block_type_index_1]=if_block_creators_1[current_block_type_index_1](ctx)}const block={c:function create(){if_block0.c();t0=space();create_component(definedinwpconfig.$$.fragment);t1=space();if(if_block1)if_block1.c();t2=space();if(if_block2)if_block2.c();t3=space();if(if_block3)if_block3.c();if_block3_anchor=empty()},m:function mount(target,anchor){if_blocks[current_block_type_index].m(target,anchor);insert_dev(target,t0,anchor);mount_component(definedinwpconfig,target,anchor);insert_dev(target,t1,anchor);if(if_block1)if_block1.m(target,anchor);insert_dev(target,t2,anchor);if(if_block2)if_block2.m(target,anchor);insert_dev(target,t3,anchor);if(~current_block_type_index_1){if_blocks_1[current_block_type_index_1].m(target,anchor)}insert_dev(target,if_block3_anchor,anchor);current=true},p:function update(ctx,dirty){let previous_block_index=current_block_type_index;current_block_type_index=select_block_type_1(ctx);if(current_block_type_index===previous_block_index){if_blocks[current_block_type_index].p(ctx,dirty)}else{group_outros();transition_out(if_blocks[previous_block_index],1,1,(()=>{if_blocks[previous_block_index]=null}));check_outros();if_block0=if_blocks[current_block_type_index];if(!if_block0){if_block0=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);if_block0.c()}else{if_block0.p(ctx,dirty)}transition_in(if_block0,1);if_block0.m(t0.parentNode,t0)}const definedinwpconfig_changes={};if(dirty[0]&16)definedinwpconfig_changes.defined=ctx[4];definedinwpconfig.$set(definedinwpconfig_changes);if(ctx[8]){if(if_block1){if_block1.p(ctx,dirty);if(dirty[0]&256){transition_in(if_block1,1)}}else{if_block1=create_if_block_4$6(ctx);if_block1.c();transition_in(if_block1,1);if_block1.m(t2.parentNode,t2)}}else if(if_block1){group_outros();transition_out(if_block1,1,1,(()=>{if_block1=null}));check_outros()}if(ctx[15]){if(if_block2){if_block2.p(ctx,dirty)}else{if_block2=create_if_block_3$6(ctx);if_block2.c();if_block2.m(t3.parentNode,t3)}}else if(if_block2){if_block2.d(1);if_block2=null}let previous_block_index_1=current_block_type_index_1;current_block_type_index_1=select_block_type_2(ctx);if(current_block_type_index_1===previous_block_index_1){if(~current_block_type_index_1){if_blocks_1[current_block_type_index_1].p(ctx,dirty)}}else{if(if_block3){group_outros();transition_out(if_blocks_1[previous_block_index_1],1,1,(()=>{if_blocks_1[previous_block_index_1]=null}));check_outros()}if(~current_block_type_index_1){if_block3=if_blocks_1[current_block_type_index_1];if(!if_block3){if_block3=if_blocks_1[current_block_type_index_1]=if_block_creators_1[current_block_type_index_1](ctx);if_block3.c()}else{if_block3.p(ctx,dirty)}transition_in(if_block3,1);if_block3.m(if_block3_anchor.parentNode,if_block3_anchor)}else{if_block3=null}}},i:function intro(local){if(current)return;transition_in(if_block0);transition_in(definedinwpconfig.$$.fragment,local);transition_in(if_block1);transition_in(if_block3);current=true},o:function outro(local){transition_out(if_block0);transition_out(definedinwpconfig.$$.fragment,local);transition_out(if_block1);transition_out(if_block3);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(t1);detach_dev(t2);detach_dev(t3);detach_dev(if_block3_anchor)}if_blocks[current_block_type_index].d(detaching);destroy_component(definedinwpconfig,detaching);if(if_block1)if_block1.d(detaching);if(if_block2)if_block2.d(detaching);if(~current_block_type_index_1){if_blocks_1[current_block_type_index_1].d(detaching)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$r.name,type:"slot",source:"(99:3) <PanelRow header>",ctx:ctx});return block}function create_default_slot$G(ctx){let t;let current;let if_block=ctx[5]&&ctx[3]&&create_if_block$t(ctx);const default_slot_template=ctx[25].default;const default_slot=create_slot(default_slot_template,ctx,ctx[34],null);const block={c:function create(){if(if_block)if_block.c();t=space();if(default_slot)default_slot.c()},m:function mount(target,anchor){if(if_block)if_block.m(target,anchor);insert_dev(target,t,anchor);if(default_slot){default_slot.m(target,anchor)}current=true},p:function update(ctx,dirty){if(ctx[5]&&ctx[3]){if(if_block){if_block.p(ctx,dirty);if(dirty[0]&40){transition_in(if_block,1)}}else{if_block=create_if_block$t(ctx);if_block.c();transition_in(if_block,1);if_block.m(t.parentNode,t)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}if(default_slot){if(default_slot.p&&(!current||dirty[1]&8)){update_slot_base(default_slot,default_slot_template,ctx,ctx[34],!current?get_all_dirty_from_scope(ctx[34]):get_slot_changes(default_slot_template,ctx[34],dirty,null),null)}}},i:function intro(local){if(current)return;transition_in(if_block);transition_in(default_slot,local);current=true},o:function outro(local){transition_out(if_block);transition_out(default_slot,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t)}if(if_block)if_block.d(detaching);if(default_slot)default_slot.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$G.name,type:"slot",source:"(97:1) <PanelContainer class={classes}>",ctx:ctx});return block}function create_fragment$10(ctx){let div;let t;let panelcontainer;let div_class_value;let div_transition;let current;let mounted;let dispose;let if_block=!ctx[5]&&ctx[3]&&create_if_block_6$4(ctx);panelcontainer=new PanelContainer({props:{class:ctx[19],$$slots:{default:[create_default_slot$G]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){div=element("div");if(if_block)if_block.c();t=space();create_component(panelcontainer.$$.fragment);attr_dev(div,"class",div_class_value="panel "+ctx[2]+" svelte-k1tgof");toggle_class(div,"multi",ctx[5]);toggle_class(div,"flyout",ctx[6]);toggle_class(div,"locked",ctx[16]);add_location(div,file$R,71,0,2186)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,div,anchor);if(if_block)if_block.m(div,null);append_dev(div,t);mount_component(panelcontainer,div,null);ctx[33](div);current=true;if(!mounted){dispose=[listen_dev(div,"focusout",ctx[26],false,false,false,false),listen_dev(div,"mouseenter",ctx[27],false,false,false,false),listen_dev(div,"mouseleave",ctx[28],false,false,false,false),listen_dev(div,"mousedown",ctx[29],false,false,false,false),listen_dev(div,"click",ctx[30],false,false,false,false),listen_dev(div,"keyup",ctx[22],false,false,false,false)];mounted=true}},p:function update(new_ctx,dirty){ctx=new_ctx;if(!ctx[5]&&ctx[3]){if(if_block){if_block.p(ctx,dirty);if(dirty[0]&40){transition_in(if_block,1)}}else{if_block=create_if_block_6$4(ctx);if_block.c();transition_in(if_block,1);if_block.m(div,t)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}const panelcontainer_changes={};if(dirty[0]&327610|dirty[1]&8){panelcontainer_changes.$$scope={dirty:dirty,ctx:ctx}}panelcontainer.$set(panelcontainer_changes);if(!current||dirty[0]&4&&div_class_value!==(div_class_value="panel "+ctx[2]+" svelte-k1tgof")){attr_dev(div,"class",div_class_value)}if(!current||dirty[0]&36){toggle_class(div,"multi",ctx[5])}if(!current||dirty[0]&68){toggle_class(div,"flyout",ctx[6])}if(!current||dirty[0]&65540){toggle_class(div,"locked",ctx[16])}},i:function intro(local){if(current)return;transition_in(if_block);transition_in(panelcontainer.$$.fragment,local);if(local){add_render_callback((()=>{if(!current)return;if(!div_transition)div_transition=create_bidirectional_transition(div,fade,{duration:ctx[6]?200:0},true);div_transition.run(1)}))}current=true},o:function outro(local){transition_out(if_block);transition_out(panelcontainer.$$.fragment,local);if(local){if(!div_transition)div_transition=create_bidirectional_transition(div,fade,{duration:ctx[6]?200:0},false);div_transition.run(0)}current=false},d:function destroy(detaching){if(detaching){detach_dev(div)}if(if_block)if_block.d();destroy_component(panelcontainer);ctx[33](null);if(detaching&&div_transition)div_transition.end();mounted=false;run_all(dispose)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$10.name,type:"component",source:"",ctx:ctx});return block}function instance$10($$self,$$props,$$invalidate){let locked;let toggleDisabled;let $defined_settings;let $settingsLocked,$$unsubscribe_settingsLocked=noop,$$subscribe_settingsLocked=()=>($$unsubscribe_settingsLocked(),$$unsubscribe_settingsLocked=subscribe(settingsLocked,($$value=>$$invalidate(24,$settingsLocked=$$value))),settingsLocked);let $strings;validate_store(defined_settings,"defined_settings");component_subscribe($$self,defined_settings,($$value=>$$invalidate(23,$defined_settings=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(35,$strings=$$value)));$$self.$$.on_destroy.push((()=>$$unsubscribe_settingsLocked()));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("Panel",slots,["default"]);const classes=$$props.class?$$props.class:"";const dispatch=createEventDispatcher();let{ref:ref={}}=$$props;let{name:name=""}=$$props;let{heading:heading=""}=$$props;let{defined:defined=false}=$$props;let{multi:multi=false}=$$props;let{flyout:flyout=false}=$$props;let{toggleName:toggleName=""}=$$props;let{toggle:toggle=false}=$$props;let{refresh:refresh=false}=$$props;let{refreshText:refreshText=$strings.refresh_title}=$$props;let{refreshDesc:refreshDesc=refreshText}=$$props;let{refreshing:refreshing=false}=$$props;let{helpKey:helpKey=""}=$$props;let{helpURL:helpURL=""}=$$props;let{helpDesc:helpDesc=$strings.help_desc}=$$props;let{storageProvider:storageProvider=null}=$$props;let settingsLocked=writable(false);validate_store(settingsLocked,"settingsLocked");$$subscribe_settingsLocked();if(hasContext("settingsLocked")){$$subscribe_settingsLocked(settingsLocked=getContext("settingsLocked"))}function headingClickHandler(){if(toggleName&&!toggleDisabled){$$invalidate(1,toggle=!toggle)}}function handleKeyup(event){if(event.key==="Escape"){event.preventDefault();dispatch("cancel")}}function focusout_handler(event){bubble.call(this,$$self,event)}function mouseenter_handler(event){bubble.call(this,$$self,event)}function mouseleave_handler(event){bubble.call(this,$$self,event)}function mousedown_handler(event){bubble.call(this,$$self,event)}function click_handler(event){bubble.call(this,$$self,event)}function toggleswitch_checked_binding(value){toggle=value;$$invalidate(1,toggle)}const click_handler_1=()=>dispatch("refresh");function div_binding($$value){binding_callbacks[$$value?"unshift":"push"]((()=>{ref=$$value;$$invalidate(0,ref)}))}$$self.$$set=$$new_props=>{$$invalidate(36,$$props=assign(assign({},$$props),exclude_internal_props($$new_props)));if("ref"in $$new_props)$$invalidate(0,ref=$$new_props.ref);if("name"in $$new_props)$$invalidate(2,name=$$new_props.name);if("heading"in $$new_props)$$invalidate(3,heading=$$new_props.heading);if("defined"in $$new_props)$$invalidate(4,defined=$$new_props.defined);if("multi"in $$new_props)$$invalidate(5,multi=$$new_props.multi);if("flyout"in $$new_props)$$invalidate(6,flyout=$$new_props.flyout);if("toggleName"in $$new_props)$$invalidate(7,toggleName=$$new_props.toggleName);if("toggle"in $$new_props)$$invalidate(1,toggle=$$new_props.toggle);if("refresh"in $$new_props)$$invalidate(8,refresh=$$new_props.refresh);if("refreshText"in $$new_props)$$invalidate(9,refreshText=$$new_props.refreshText);if("refreshDesc"in $$new_props)$$invalidate(10,refreshDesc=$$new_props.refreshDesc);if("refreshing"in $$new_props)$$invalidate(11,refreshing=$$new_props.refreshing);if("helpKey"in $$new_props)$$invalidate(12,helpKey=$$new_props.helpKey);if("helpURL"in $$new_props)$$invalidate(13,helpURL=$$new_props.helpURL);if("helpDesc"in $$new_props)$$invalidate(14,helpDesc=$$new_props.helpDesc);if("storageProvider"in $$new_props)$$invalidate(15,storageProvider=$$new_props.storageProvider);if("$$scope"in $$new_props)$$invalidate(34,$$scope=$$new_props.$$scope)};$$self.$capture_state=()=>({createEventDispatcher:createEventDispatcher,getContext:getContext,hasContext:hasContext,writable:writable,fade:fade,link:link,defined_settings:defined_settings,strings:strings,PanelContainer:PanelContainer,PanelRow:PanelRow,DefinedInWPConfig:DefinedInWPConfig,ToggleSwitch:ToggleSwitch,HelpButton:HelpButton,Button:Button,classes:classes,dispatch:dispatch,ref:ref,name:name,heading:heading,defined:defined,multi:multi,flyout:flyout,toggleName:toggleName,toggle:toggle,refresh:refresh,refreshText:refreshText,refreshDesc:refreshDesc,refreshing:refreshing,helpKey:helpKey,helpURL:helpURL,helpDesc:helpDesc,storageProvider:storageProvider,settingsLocked:settingsLocked,headingClickHandler:headingClickHandler,handleKeyup:handleKeyup,toggleDisabled:toggleDisabled,locked:locked,$defined_settings:$defined_settings,$settingsLocked:$settingsLocked,$strings:$strings});$$self.$inject_state=$$new_props=>{$$invalidate(36,$$props=assign(assign({},$$props),$$new_props));if("ref"in $$props)$$invalidate(0,ref=$$new_props.ref);if("name"in $$props)$$invalidate(2,name=$$new_props.name);if("heading"in $$props)$$invalidate(3,heading=$$new_props.heading);if("defined"in $$props)$$invalidate(4,defined=$$new_props.defined);if("multi"in $$props)$$invalidate(5,multi=$$new_props.multi);if("flyout"in $$props)$$invalidate(6,flyout=$$new_props.flyout);if("toggleName"in $$props)$$invalidate(7,toggleName=$$new_props.toggleName);if("toggle"in $$props)$$invalidate(1,toggle=$$new_props.toggle);if("refresh"in $$props)$$invalidate(8,refresh=$$new_props.refresh);if("refreshText"in $$props)$$invalidate(9,refreshText=$$new_props.refreshText);if("refreshDesc"in $$props)$$invalidate(10,refreshDesc=$$new_props.refreshDesc);if("refreshing"in $$props)$$invalidate(11,refreshing=$$new_props.refreshing);if("helpKey"in $$props)$$invalidate(12,helpKey=$$new_props.helpKey);if("helpURL"in $$props)$$invalidate(13,helpURL=$$new_props.helpURL);if("helpDesc"in $$props)$$invalidate(14,helpDesc=$$new_props.helpDesc);if("storageProvider"in $$props)$$invalidate(15,storageProvider=$$new_props.storageProvider);if("settingsLocked"in $$props)$$subscribe_settingsLocked($$invalidate(17,settingsLocked=$$new_props.settingsLocked));if("toggleDisabled"in $$props)$$invalidate(18,toggleDisabled=$$new_props.toggleDisabled);if("locked"in $$props)$$invalidate(16,locked=$$new_props.locked)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty[0]&16777216){$$invalidate(16,locked=$settingsLocked)}if($$self.$$.dirty[0]&8454272){$$invalidate(18,toggleDisabled=$defined_settings.includes(toggleName)||locked)}};$$props=exclude_internal_props($$props);return[ref,toggle,name,heading,defined,multi,flyout,toggleName,refresh,refreshText,refreshDesc,refreshing,helpKey,helpURL,helpDesc,storageProvider,locked,settingsLocked,toggleDisabled,classes,dispatch,headingClickHandler,handleKeyup,$defined_settings,$settingsLocked,slots,focusout_handler,mouseenter_handler,mouseleave_handler,mousedown_handler,click_handler,toggleswitch_checked_binding,click_handler_1,div_binding,$$scope]}class Panel extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$10,create_fragment$10,safe_not_equal,{ref:0,name:2,heading:3,defined:4,multi:5,flyout:6,toggleName:7,toggle:1,refresh:8,refreshText:9,refreshDesc:10,refreshing:11,helpKey:12,helpURL:13,helpDesc:14,storageProvider:15},null,[-1,-1]);dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"Panel",options:options,id:create_fragment$10.name})}get ref(){throw new Error("<Panel>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set ref(value){throw new Error("<Panel>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get name(){throw new Error("<Panel>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set name(value){throw new Error("<Panel>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get heading(){throw new Error("<Panel>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set heading(value){throw new Error("<Panel>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get defined(){throw new Error("<Panel>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set defined(value){throw new Error("<Panel>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get multi(){throw new Error("<Panel>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set multi(value){throw new Error("<Panel>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get flyout(){throw new Error("<Panel>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set flyout(value){throw new Error("<Panel>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get toggleName(){throw new Error("<Panel>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set toggleName(value){throw new Error("<Panel>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get toggle(){throw new Error("<Panel>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set toggle(value){throw new Error("<Panel>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get refresh(){throw new Error("<Panel>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set refresh(value){throw new Error("<Panel>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get refreshText(){throw new Error("<Panel>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set refreshText(value){throw new Error("<Panel>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get refreshDesc(){throw new Error("<Panel>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set refreshDesc(value){throw new Error("<Panel>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get refreshing(){throw new Error("<Panel>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set refreshing(value){throw new Error("<Panel>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get helpKey(){throw new Error("<Panel>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set helpKey(value){throw new Error("<Panel>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get helpURL(){throw new Error("<Panel>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set helpURL(value){throw new Error("<Panel>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get helpDesc(){throw new Error("<Panel>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set helpDesc(value){throw new Error("<Panel>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get storageProvider(){throw new Error("<Panel>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set storageProvider(value){throw new Error("<Panel>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$Q="ui/components/StorageSettingsHeadingRow.svelte";function create_default_slot_1$q(ctx){let t_value=ctx[3].edit+"";let t;const block={c:function create(){t=text(t_value)},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty&8&&t_value!==(t_value=ctx[3].edit+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$q.name,type:"slot",source:"(32:1) <Button outline on:click={() => push('/storage/provider')} title={$strings.edit_storage_provider} disabled={$settingsLocked}>",ctx:ctx});return block}function create_default_slot$F(ctx){let img;let img_src_value;let img_alt_value;let t0;let div;let h3;let t1_value=ctx[1].provider_service_name+"";let t1;let t2;let p;let a;let t3_value=ctx[4].bucket+"";let t3;let a_href_value;let a_title_value;let t4;let span;let t5;let span_title_value;let t6;let button;let current;button=new Button({props:{outline:true,title:ctx[3].edit_storage_provider,disabled:ctx[6],$$slots:{default:[create_default_slot_1$q]},$$scope:{ctx:ctx}},$$inline:true});button.$on("click",ctx[7]);const block={c:function create(){img=element("img");t0=space();div=element("div");h3=element("h3");t1=text(t1_value);t2=space();p=element("p");a=element("a");t3=text(t3_value);t4=space();span=element("span");t5=text(ctx[5]);t6=space();create_component(button.$$.fragment);if(!src_url_equal(img.src,img_src_value=ctx[1].icon))attr_dev(img,"src",img_src_value);attr_dev(img,"alt",img_alt_value=ctx[1].provider_service_name);attr_dev(img,"class","svelte-cn9mf");add_location(img,file$Q,23,1,589);attr_dev(h3,"class","svelte-cn9mf");add_location(h3,file$Q,25,2,707);attr_dev(a,"href",a_href_value=ctx[2].storage_provider_console_url);attr_dev(a,"class","console svelte-cn9mf");attr_dev(a,"target","_blank");attr_dev(a,"title",a_title_value=ctx[3].view_provider_console);add_location(a,file$Q,27,3,791);attr_dev(span,"class","region svelte-cn9mf");attr_dev(span,"title",span_title_value=ctx[4].region);add_location(span,file$Q,28,3,933);attr_dev(p,"class","console-details svelte-cn9mf");add_location(p,file$Q,26,2,760);attr_dev(div,"class","provider-details svelte-cn9mf");add_location(div,file$Q,24,1,674)},m:function mount(target,anchor){insert_dev(target,img,anchor);insert_dev(target,t0,anchor);insert_dev(target,div,anchor);append_dev(div,h3);append_dev(h3,t1);append_dev(div,t2);append_dev(div,p);append_dev(p,a);append_dev(a,t3);append_dev(p,t4);append_dev(p,span);append_dev(span,t5);insert_dev(target,t6,anchor);mount_component(button,target,anchor);current=true},p:function update(ctx,dirty){if(!current||dirty&2&&!src_url_equal(img.src,img_src_value=ctx[1].icon)){attr_dev(img,"src",img_src_value)}if(!current||dirty&2&&img_alt_value!==(img_alt_value=ctx[1].provider_service_name)){attr_dev(img,"alt",img_alt_value)}if((!current||dirty&2)&&t1_value!==(t1_value=ctx[1].provider_service_name+""))set_data_dev(t1,t1_value);if((!current||dirty&16)&&t3_value!==(t3_value=ctx[4].bucket+""))set_data_dev(t3,t3_value);if(!current||dirty&4&&a_href_value!==(a_href_value=ctx[2].storage_provider_console_url)){attr_dev(a,"href",a_href_value)}if(!current||dirty&8&&a_title_value!==(a_title_value=ctx[3].view_provider_console)){attr_dev(a,"title",a_title_value)}if(!current||dirty&32)set_data_dev(t5,ctx[5]);if(!current||dirty&16&&span_title_value!==(span_title_value=ctx[4].region)){attr_dev(span,"title",span_title_value)}const button_changes={};if(dirty&8)button_changes.title=ctx[3].edit_storage_provider;if(dirty&64)button_changes.disabled=ctx[6];if(dirty&264){button_changes.$$scope={dirty:dirty,ctx:ctx}}button.$set(button_changes)},i:function intro(local){if(current)return;transition_in(button.$$.fragment,local);current=true},o:function outro(local){transition_out(button.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(img);detach_dev(t0);detach_dev(div);detach_dev(t6)}destroy_component(button,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$F.name,type:"slot",source:'(23:0) <PanelRow header gradient class=\\"storage {$storage_provider.provider_key_name}\\">',ctx:ctx});return block}function create_fragment$$(ctx){let panelrow;let current;panelrow=new PanelRow({props:{header:true,gradient:true,class:"storage "+ctx[1].provider_key_name,$$slots:{default:[create_default_slot$F]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,[dirty]){const panelrow_changes={};if(dirty&2)panelrow_changes.class="storage "+ctx[1].provider_key_name;if(dirty&382){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$$.name,type:"component",source:"",ctx:ctx});return block}function instance$$($$self,$$props,$$invalidate){let $storage_provider;let $urls;let $strings;let $settings;let $region_name;let $settingsLocked,$$unsubscribe_settingsLocked=noop,$$subscribe_settingsLocked=()=>($$unsubscribe_settingsLocked(),$$unsubscribe_settingsLocked=subscribe(settingsLocked,($$value=>$$invalidate(6,$settingsLocked=$$value))),settingsLocked);validate_store(storage_provider,"storage_provider");component_subscribe($$self,storage_provider,($$value=>$$invalidate(1,$storage_provider=$$value)));validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(2,$urls=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(3,$strings=$$value)));validate_store(settings,"settings");component_subscribe($$self,settings,($$value=>$$invalidate(4,$settings=$$value)));validate_store(region_name,"region_name");component_subscribe($$self,region_name,($$value=>$$invalidate(5,$region_name=$$value)));$$self.$$.on_destroy.push((()=>$$unsubscribe_settingsLocked()));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("StorageSettingsHeadingRow",slots,[]);let settingsLocked=writable(false);validate_store(settingsLocked,"settingsLocked");$$subscribe_settingsLocked();if(hasContext("settingsLocked")){$$subscribe_settingsLocked(settingsLocked=getContext("settingsLocked"))}const writable_props=[];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<StorageSettingsHeadingRow> was created with unknown prop '${key}'`)}));const click_handler=()=>push("/storage/provider");$$self.$capture_state=()=>({getContext:getContext,hasContext:hasContext,writable:writable,push:push,region_name:region_name,settings:settings,storage_provider:storage_provider,strings:strings,urls:urls,PanelRow:PanelRow,Button:Button,settingsLocked:settingsLocked,$storage_provider:$storage_provider,$urls:$urls,$strings:$strings,$settings:$settings,$region_name:$region_name,$settingsLocked:$settingsLocked});$$self.$inject_state=$$props=>{if("settingsLocked"in $$props)$$subscribe_settingsLocked($$invalidate(0,settingsLocked=$$props.settingsLocked))};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[settingsLocked,$storage_provider,$urls,$strings,$settings,$region_name,$settingsLocked,click_handler]}class StorageSettingsHeadingRow extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$$,create_fragment$$,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"StorageSettingsHeadingRow",options:options,id:create_fragment$$.name})}}function delayMin(start,minTime){let elapsed=Date.now()-start;return new Promise((resolve=>setTimeout(resolve,minTime-elapsed)))}const file$P="ui/components/CheckAgain.svelte";function create_else_block$d(ctx){let button;let current;button=new Button({props:{refresh:true,refreshing:ctx[1],title:ctx[3].check_again_desc,$$slots:{default:[create_default_slot_1$p]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(button.$$.fragment)},m:function mount(target,anchor){mount_component(button,target,anchor);current=true},p:function update(ctx,dirty){const button_changes={};if(dirty&2)button_changes.refreshing=ctx[1];if(dirty&8)button_changes.title=ctx[3].check_again_desc;if(dirty&136){button_changes.$$scope={dirty:dirty,ctx:ctx}}button.$set(button_changes)},i:function intro(local){if(current)return;transition_in(button.$$.fragment,local);current=true},o:function outro(local){transition_out(button.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(button,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block$d.name,type:"else",source:"(41:1) {:else}",ctx:ctx});return block}function create_if_block$s(ctx){let button;let current;button=new Button({props:{refresh:true,refreshing:ctx[1],title:ctx[3].check_again_desc,$$slots:{default:[create_default_slot$E]},$$scope:{ctx:ctx}},$$inline:true});button.$on("click",ctx[5]);const block={c:function create(){create_component(button.$$.fragment)},m:function mount(target,anchor){mount_component(button,target,anchor);current=true},p:function update(ctx,dirty){const button_changes={};if(dirty&2)button_changes.refreshing=ctx[1];if(dirty&8)button_changes.title=ctx[3].check_again_desc;if(dirty&136){button_changes.$$scope={dirty:dirty,ctx:ctx}}button.$set(button_changes)},i:function intro(local){if(current)return;transition_in(button.$$.fragment,local);current=true},o:function outro(local){transition_out(button.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(button,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$s.name,type:"if",source:"(37:1) {#if !refreshing}",ctx:ctx});return block}function create_default_slot_1$p(ctx){let t_value=ctx[3].check_again_active+"";let t;const block={c:function create(){t=text(t_value)},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty&8&&t_value!==(t_value=ctx[3].check_again_active+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$p.name,type:"slot",source:"(42:2) <Button refresh {refreshing} title={$strings.check_again_desc}>",ctx:ctx});return block}function create_default_slot$E(ctx){let t_value=ctx[3].check_again_title+"";let t;const block={c:function create(){t=text(t_value)},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty&8&&t_value!==(t_value=ctx[3].check_again_title+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$E.name,type:"slot",source:"(38:2) <Button refresh {refreshing} title={$strings.check_again_desc} on:click={revalidate}>",ctx:ctx});return block}function create_fragment$_(ctx){let div;let current_block_type_index;let if_block;let t0;let span;let t1_value=ctx[2][ctx[0]].last_update+"";let t1;let current;const if_block_creators=[create_if_block$s,create_else_block$d];const if_blocks=[];function select_block_type(ctx,dirty){if(!ctx[1])return 0;return 1}current_block_type_index=select_block_type(ctx);if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);const block={c:function create(){div=element("div");if_block.c();t0=space();span=element("span");t1=text(t1_value);attr_dev(span,"class","last-update svelte-1oue4lo");attr_dev(span,"title",ctx[4]);add_location(span,file$P,45,1,1006);attr_dev(div,"class","check-again svelte-1oue4lo");add_location(div,file$P,35,0,701)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,div,anchor);if_blocks[current_block_type_index].m(div,null);append_dev(div,t0);append_dev(div,span);append_dev(span,t1);current=true},p:function update(ctx,[dirty]){let previous_block_index=current_block_type_index;current_block_type_index=select_block_type(ctx);if(current_block_type_index===previous_block_index){if_blocks[current_block_type_index].p(ctx,dirty)}else{group_outros();transition_out(if_blocks[previous_block_index],1,1,(()=>{if_blocks[previous_block_index]=null}));check_outros();if_block=if_blocks[current_block_type_index];if(!if_block){if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);if_block.c()}else{if_block.p(ctx,dirty)}transition_in(if_block,1);if_block.m(div,t0)}if((!current||dirty&5)&&t1_value!==(t1_value=ctx[2][ctx[0]].last_update+""))set_data_dev(t1,t1_value)},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(div)}if_blocks[current_block_type_index].d()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$_.name,type:"component",source:"",ctx:ctx});return block}function instance$_($$self,$$props,$$invalidate){let refreshing;let $settings_validation;let $revalidatingSettings;let $strings;validate_store(settings_validation,"settings_validation");component_subscribe($$self,settings_validation,($$value=>$$invalidate(2,$settings_validation=$$value)));validate_store(revalidatingSettings,"revalidatingSettings");component_subscribe($$self,revalidatingSettings,($$value=>$$invalidate(6,$revalidatingSettings=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(3,$strings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("CheckAgain",slots,[]);let{section:section=""}=$$props;let datetime=new Date($settings_validation[section].timestamp*1e3).toString();async function revalidate(){let start=Date.now();let params={revalidateSettings:true,section:section};$$invalidate(1,refreshing=true);let json=await api.get("state",params);await delayMin(start,1e3);state.updateState(json);$$invalidate(1,refreshing=false)}const writable_props=["section"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<CheckAgain> was created with unknown prop '${key}'`)}));$$self.$$set=$$props=>{if("section"in $$props)$$invalidate(0,section=$$props.section)};$$self.$capture_state=()=>({Button:Button,api:api,revalidatingSettings:revalidatingSettings,settings_validation:settings_validation,state:state,strings:strings,delayMin:delayMin,section:section,datetime:datetime,revalidate:revalidate,refreshing:refreshing,$settings_validation:$settings_validation,$revalidatingSettings:$revalidatingSettings,$strings:$strings});$$self.$inject_state=$$props=>{if("section"in $$props)$$invalidate(0,section=$$props.section);if("datetime"in $$props)$$invalidate(4,datetime=$$props.datetime);if("refreshing"in $$props)$$invalidate(1,refreshing=$$props.refreshing)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty&64){$$invalidate(1,refreshing=$revalidatingSettings)}};return[section,refreshing,$settings_validation,$strings,datetime,revalidate,$revalidatingSettings]}class CheckAgain extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$_,create_fragment$_,safe_not_equal,{section:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"CheckAgain",options:options,id:create_fragment$_.name})}get section(){throw new Error("<CheckAgain>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set section(value){throw new Error("<CheckAgain>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$O="ui/components/SettingsValidationStatusRow.svelte";function create_fragment$Z(ctx){let div3;let div2;let div0;let img;let img_src_value;let img_alt_value;let t0;let div1;let t1;let checkagain;let div3_class_value;let current;checkagain=new CheckAgain({props:{section:ctx[0]},$$inline:true});const block={c:function create(){div3=element("div");div2=element("div");div0=element("div");img=element("img");t0=space();div1=element("div");t1=space();create_component(checkagain.$$.fragment);attr_dev(img,"class","icon type");if(!src_url_equal(img.src,img_src_value=ctx[1]))attr_dev(img,"src",img_src_value);attr_dev(img,"alt",img_alt_value=""+(ctx[3]+" icon"));add_location(img,file$O,28,3,821);attr_dev(div0,"class","icon type in-panel");add_location(div0,file$O,27,2,785);attr_dev(div1,"class","body");add_location(div1,file$O,31,2,890);attr_dev(div2,"class","content in-panel");add_location(div2,file$O,26,1,752);attr_dev(div3,"class",div3_class_value="notification in-panel multiline "+ctx[0]);toggle_class(div3,"success",ctx[7]);toggle_class(div3,"warning",ctx[6]);toggle_class(div3,"error",ctx[5]);toggle_class(div3,"info",ctx[4]);add_location(div3,file$O,19,0,638)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,div3,anchor);append_dev(div3,div2);append_dev(div2,div0);append_dev(div0,img);append_dev(div2,t0);append_dev(div2,div1);div1.innerHTML=ctx[2];append_dev(div2,t1);mount_component(checkagain,div2,null);current=true},p:function update(ctx,[dirty]){if(!current||dirty&2&&!src_url_equal(img.src,img_src_value=ctx[1])){attr_dev(img,"src",img_src_value)}if(!current||dirty&8&&img_alt_value!==(img_alt_value=""+(ctx[3]+" icon"))){attr_dev(img,"alt",img_alt_value)}if(!current||dirty&4)div1.innerHTML=ctx[2];const checkagain_changes={};if(dirty&1)checkagain_changes.section=ctx[0];checkagain.$set(checkagain_changes);if(!current||dirty&1&&div3_class_value!==(div3_class_value="notification in-panel multiline "+ctx[0])){attr_dev(div3,"class",div3_class_value)}if(!current||dirty&129){toggle_class(div3,"success",ctx[7])}if(!current||dirty&65){toggle_class(div3,"warning",ctx[6])}if(!current||dirty&33){toggle_class(div3,"error",ctx[5])}if(!current||dirty&17){toggle_class(div3,"info",ctx[4])}},i:function intro(local){if(current)return;transition_in(checkagain.$$.fragment,local);current=true},o:function outro(local){transition_out(checkagain.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(div3)}destroy_component(checkagain)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$Z.name,type:"component",source:"",ctx:ctx});return block}function instance$Z($$self,$$props,$$invalidate){let success;let warning;let error;let info;let type;let message;let iconURL;let $settings_validation;let $urls;validate_store(settings_validation,"settings_validation");component_subscribe($$self,settings_validation,($$value=>$$invalidate(8,$settings_validation=$$value)));validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(9,$urls=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("SettingsValidationStatusRow",slots,[]);let{section:section=""}=$$props;const writable_props=["section"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<SettingsValidationStatusRow> was created with unknown prop '${key}'`)}));$$self.$$set=$$props=>{if("section"in $$props)$$invalidate(0,section=$$props.section)};$$self.$capture_state=()=>({settings_validation:settings_validation,urls:urls,CheckAgain:CheckAgain,section:section,iconURL:iconURL,message:message,type:type,info:info,error:error,warning:warning,success:success,$settings_validation:$settings_validation,$urls:$urls});$$self.$inject_state=$$props=>{if("section"in $$props)$$invalidate(0,section=$$props.section);if("iconURL"in $$props)$$invalidate(1,iconURL=$$props.iconURL);if("message"in $$props)$$invalidate(2,message=$$props.message);if("type"in $$props)$$invalidate(3,type=$$props.type);if("info"in $$props)$$invalidate(4,info=$$props.info);if("error"in $$props)$$invalidate(5,error=$$props.error);if("warning"in $$props)$$invalidate(6,warning=$$props.warning);if("success"in $$props)$$invalidate(7,success=$$props.success)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty&257){$$invalidate(7,success=$settings_validation[section].type==="success")}if($$self.$$.dirty&257){$$invalidate(6,warning=$settings_validation[section].type==="warning")}if($$self.$$.dirty&257){$$invalidate(5,error=$settings_validation[section].type==="error")}if($$self.$$.dirty&257){$$invalidate(4,info=$settings_validation[section].type==="info")}if($$self.$$.dirty&257){$$invalidate(3,type=$settings_validation[section].type)}if($$self.$$.dirty&257){$$invalidate(2,message="<p>"+$settings_validation[section].message+"</p>")}if($$self.$$.dirty&769){$$invalidate(1,iconURL=$urls.assets+"img/icon/notification-"+$settings_validation[section].type+".svg")}};return[section,iconURL,message,type,info,error,warning,success,$settings_validation,$urls]}class SettingsValidationStatusRow extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$Z,create_fragment$Z,safe_not_equal,{section:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"SettingsValidationStatusRow",options:options,id:create_fragment$Z.name})}get section(){throw new Error("<SettingsValidationStatusRow>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set section(value){throw new Error("<SettingsValidationStatusRow>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$N="ui/components/SettingNotifications.svelte";function get_each_context$c(ctx,list,i){const child_ctx=ctx.slice();child_ctx[2]=list[i];return child_ctx}function create_if_block$r(ctx){let each_blocks=[];let each_1_lookup=new Map;let each_1_anchor;let current;let each_value=ensure_array_like_dev([...ctx[1].get(ctx[0]).values()].sort(compareNotificationTypes));const get_key=ctx=>ctx[2];validate_each_keys(ctx,each_value,get_each_context$c,get_key);for(let i=0;i<each_value.length;i+=1){let child_ctx=get_each_context$c(ctx,each_value,i);let key=get_key(child_ctx);each_1_lookup.set(key,each_blocks[i]=create_each_block$c(key,child_ctx))}const block={c:function create(){for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].c()}each_1_anchor=empty()},m:function mount(target,anchor){for(let i=0;i<each_blocks.length;i+=1){if(each_blocks[i]){each_blocks[i].m(target,anchor)}}insert_dev(target,each_1_anchor,anchor);current=true},p:function update(ctx,dirty){if(dirty&3){each_value=ensure_array_like_dev([...ctx[1].get(ctx[0]).values()].sort(compareNotificationTypes));group_outros();validate_each_keys(ctx,each_value,get_each_context$c,get_key);each_blocks=update_keyed_each(each_blocks,dirty,get_key,1,ctx,each_value,each_1_lookup,each_1_anchor.parentNode,outro_and_destroy_block,create_each_block$c,each_1_anchor,get_each_context$c);check_outros()}},i:function intro(local){if(current)return;for(let i=0;i<each_value.length;i+=1){transition_in(each_blocks[i])}current=true},o:function outro(local){for(let i=0;i<each_blocks.length;i+=1){transition_out(each_blocks[i])}current=false},d:function destroy(detaching){if(detaching){detach_dev(each_1_anchor)}for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].d(detaching)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$r.name,type:"if",source:"(48:0) {#if $settings_notifications.has( settingKey )}",ctx:ctx});return block}function create_default_slot$D(ctx){let p;let raw_value=ctx[2].message+"";let t;const block={c:function create(){p=element("p");t=space();add_location(p,file$N,50,3,1314)},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=raw_value;insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty&3&&raw_value!==(raw_value=ctx[2].message+""))p.innerHTML=raw_value},d:function destroy(detaching){if(detaching){detach_dev(p);detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$D.name,type:"slot",source:"(50:2) <Notification {notification}>",ctx:ctx});return block}function create_each_block$c(key_1,ctx){let first;let notification_1;let current;notification_1=new Notification({props:{notification:ctx[2],$$slots:{default:[create_default_slot$D]},$$scope:{ctx:ctx}},$$inline:true});const block={key:key_1,first:null,c:function create(){first=empty();create_component(notification_1.$$.fragment);this.first=first},m:function mount(target,anchor){insert_dev(target,first,anchor);mount_component(notification_1,target,anchor);current=true},p:function update(new_ctx,dirty){ctx=new_ctx;const notification_1_changes={};if(dirty&3)notification_1_changes.notification=ctx[2];if(dirty&35){notification_1_changes.$$scope={dirty:dirty,ctx:ctx}}notification_1.$set(notification_1_changes)},i:function intro(local){if(current)return;transition_in(notification_1.$$.fragment,local);current=true},o:function outro(local){transition_out(notification_1.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(first)}destroy_component(notification_1,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_each_block$c.name,type:"each",source:"(49:1) {#each [...$settings_notifications.get( settingKey ).values()].sort( compareNotificationTypes ) as notification (notification)}",ctx:ctx});return block}function create_fragment$Y(ctx){let show_if=ctx[1].has(ctx[0]);let if_block_anchor;let current;let if_block=show_if&&create_if_block$r(ctx);const block={c:function create(){if(if_block)if_block.c();if_block_anchor=empty()},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,[dirty]){if(dirty&3)show_if=ctx[1].has(ctx[0]);if(show_if){if(if_block){if_block.p(ctx,dirty);if(dirty&3){transition_in(if_block,1)}}else{if_block=create_if_block$r(ctx);if_block.c();transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$Y.name,type:"component",source:"",ctx:ctx});return block}function compareNotificationTypes(a,b){if(a.type==="error"&&b.type!=="error"){return-1}if(b.type==="error"&&a.type!=="error"){return 1}if(a.type==="warning"&&b.type!=="warning"){return-1}if(b.type==="warning"&&a.type!=="warning"){return 1}if(a.type<b.type){return-1}if(b.type<a.type){return 1}return 0}function instance$Y($$self,$$props,$$invalidate){let $settings_notifications;validate_store(settings_notifications,"settings_notifications");component_subscribe($$self,settings_notifications,($$value=>$$invalidate(1,$settings_notifications=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("SettingNotifications",slots,[]);let{settingKey:settingKey}=$$props;$$self.$$.on_mount.push((function(){if(settingKey===undefined&&!("settingKey"in $$props||$$self.$$.bound[$$self.$$.props["settingKey"]])){console.warn("<SettingNotifications> was created without expected prop 'settingKey'")}}));const writable_props=["settingKey"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<SettingNotifications> was created with unknown prop '${key}'`)}));$$self.$$set=$$props=>{if("settingKey"in $$props)$$invalidate(0,settingKey=$$props.settingKey)};$$self.$capture_state=()=>({settings_notifications:settings_notifications,Notification:Notification,settingKey:settingKey,compareNotificationTypes:compareNotificationTypes,$settings_notifications:$settings_notifications});$$self.$inject_state=$$props=>{if("settingKey"in $$props)$$invalidate(0,settingKey=$$props.settingKey)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[settingKey,$settings_notifications]}class SettingNotifications extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$Y,create_fragment$Y,safe_not_equal,{settingKey:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"SettingNotifications",options:options,id:create_fragment$Y.name})}get settingKey(){throw new Error("<SettingNotifications>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set settingKey(value){throw new Error("<SettingNotifications>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$M="ui/components/SettingsPanelOption.svelte";function create_else_block$c(ctx){let h4;let t;const block={c:function create(){h4=element("h4");t=text(ctx[2]);attr_dev(h4,"id",ctx[17]);add_location(h4,file$M,105,3,2906)},m:function mount(target,anchor){insert_dev(target,h4,anchor);append_dev(h4,t)},p:function update(ctx,dirty){if(dirty&4)set_data_dev(t,ctx[2]);if(dirty&131072){attr_dev(h4,"id",ctx[17])}},i:noop,o:noop,d:function destroy(detaching){if(detaching){detach_dev(h4)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block$c.name,type:"else",source:"(105:2) {:else}",ctx:ctx});return block}function create_if_block_4$5(ctx){let toggleswitch;let updating_checked;let t0;let h4;let t1;let current;let mounted;let dispose;function toggleswitch_checked_binding(value){ctx[25](value)}let toggleswitch_props={name:ctx[7],disabled:ctx[14],$$slots:{default:[create_default_slot_3$7]},$$scope:{ctx:ctx}};if(ctx[0]!==void 0){toggleswitch_props.checked=ctx[0]}toggleswitch=new ToggleSwitch({props:toggleswitch_props,$$inline:true});binding_callbacks.push((()=>bind(toggleswitch,"checked",toggleswitch_checked_binding)));const block={c:function create(){create_component(toggleswitch.$$.fragment);t0=space();h4=element("h4");t1=text(ctx[2]);attr_dev(h4,"id",ctx[17]);attr_dev(h4,"class","toggler svelte-k1tgof");toggle_class(h4,"toggleDisabled",ctx[14]);add_location(h4,file$M,103,3,2789)},m:function mount(target,anchor){mount_component(toggleswitch,target,anchor);insert_dev(target,t0,anchor);insert_dev(target,h4,anchor);append_dev(h4,t1);current=true;if(!mounted){dispose=listen_dev(h4,"click",ctx[19],false,false,false,false);mounted=true}},p:function update(ctx,dirty){const toggleswitch_changes={};if(dirty&128)toggleswitch_changes.name=ctx[7];if(dirty&16384)toggleswitch_changes.disabled=ctx[14];if(dirty&134217732){toggleswitch_changes.$$scope={dirty:dirty,ctx:ctx}}if(!updating_checked&&dirty&1){updating_checked=true;toggleswitch_changes.checked=ctx[0];add_flush_callback((()=>updating_checked=false))}toggleswitch.$set(toggleswitch_changes);if(!current||dirty&4)set_data_dev(t1,ctx[2]);if(!current||dirty&131072){attr_dev(h4,"id",ctx[17])}if(!current||dirty&16384){toggle_class(h4,"toggleDisabled",ctx[14])}},i:function intro(local){if(current)return;transition_in(toggleswitch.$$.fragment,local);current=true},o:function outro(local){transition_out(toggleswitch.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(h4)}destroy_component(toggleswitch,detaching);mounted=false;dispose()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_4$5.name,type:"if",source:"(97:2) {#if toggleName}",ctx:ctx});return block}function create_default_slot_3$7(ctx){let t;const block={c:function create(){t=text(ctx[2])},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty&4)set_data_dev(t,ctx[2])},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_3$7.name,type:"slot",source:"(98:3) <ToggleSwitch name={toggleName} bind:checked={toggle} disabled={toggleDisabled}>",ctx:ctx});return block}function create_default_slot_2$i(ctx){let current_block_type_index;let if_block;let t;let definedinwpconfig;let current;const if_block_creators=[create_if_block_4$5,create_else_block$c];const if_blocks=[];function select_block_type(ctx,dirty){if(ctx[7])return 0;return 1}current_block_type_index=select_block_type(ctx);if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);definedinwpconfig=new DefinedInWPConfig({props:{defined:ctx[11].includes(ctx[7])||ctx[10]&&ctx[11].includes(ctx[8])},$$inline:true});const block={c:function create(){if_block.c();t=space();create_component(definedinwpconfig.$$.fragment)},m:function mount(target,anchor){if_blocks[current_block_type_index].m(target,anchor);insert_dev(target,t,anchor);mount_component(definedinwpconfig,target,anchor);current=true},p:function update(ctx,dirty){let previous_block_index=current_block_type_index;current_block_type_index=select_block_type(ctx);if(current_block_type_index===previous_block_index){if_blocks[current_block_type_index].p(ctx,dirty)}else{group_outros();transition_out(if_blocks[previous_block_index],1,1,(()=>{if_blocks[previous_block_index]=null}));check_outros();if_block=if_blocks[current_block_type_index];if(!if_block){if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);if_block.c()}else{if_block.p(ctx,dirty)}transition_in(if_block,1);if_block.m(t.parentNode,t)}const definedinwpconfig_changes={};if(dirty&3456)definedinwpconfig_changes.defined=ctx[11].includes(ctx[7])||ctx[10]&&ctx[11].includes(ctx[8]);definedinwpconfig.$set(definedinwpconfig_changes)},i:function intro(local){if(current)return;transition_in(if_block);transition_in(definedinwpconfig.$$.fragment,local);current=true},o:function outro(local){transition_out(if_block);transition_out(definedinwpconfig.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t)}if_blocks[current_block_type_index].d(detaching);destroy_component(definedinwpconfig,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_2$i.name,type:"slot",source:'(96:1) <PanelRow class=\\"option\\">',ctx:ctx});return block}function create_default_slot_1$o(ctx){let p;const block={c:function create(){p=element("p");add_location(p,file$M,110,2,3115)},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=ctx[3]},p:function update(ctx,dirty){if(dirty&8)p.innerHTML=ctx[3]},d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$o.name,type:"slot",source:'(110:1) <PanelRow class=\\"desc\\">',ctx:ctx});return block}function create_if_block_2$8(ctx){let panelrow;let t;let if_block_anchor;let current;panelrow=new PanelRow({props:{class:"input",$$slots:{default:[create_default_slot$C]},$$scope:{ctx:ctx}},$$inline:true});let if_block=ctx[15]&&ctx[13]&&create_if_block_3$5(ctx);const block={c:function create(){create_component(panelrow.$$.fragment);t=space();if(if_block)if_block.c();if_block_anchor=empty()},m:function mount(target,anchor){mount_component(panelrow,target,anchor);insert_dev(target,t,anchor);if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty&134414614){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes);if(ctx[15]&&ctx[13]){if(if_block){if_block.p(ctx,dirty);if(dirty&40960){transition_in(if_block,1)}}else{if_block=create_if_block_3$5(ctx);if_block.c();transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);transition_in(if_block);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(t);detach_dev(if_block_anchor)}destroy_component(panelrow,detaching);if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_2$8.name,type:"if",source:"(113:1) {#if input}",ctx:ctx});return block}function create_default_slot$C(ctx){let input_1;let t0;let label;let t1;let mounted;let dispose;const block={c:function create(){input_1=element("input");t0=space();label=element("label");t1=text(ctx[2]);attr_dev(input_1,"type","text");attr_dev(input_1,"id",ctx[8]);attr_dev(input_1,"name",ctx[8]);attr_dev(input_1,"minlength","1");attr_dev(input_1,"size","10");attr_dev(input_1,"placeholder",ctx[4]);input_1.disabled=ctx[16];attr_dev(input_1,"aria-labelledby",ctx[17]);toggle_class(input_1,"disabled",ctx[16]);add_location(input_1,file$M,114,3,3198);attr_dev(label,"for",ctx[8]);add_location(label,file$M,127,3,3462)},m:function mount(target,anchor){insert_dev(target,input_1,anchor);set_input_value(input_1,ctx[1]);insert_dev(target,t0,anchor);insert_dev(target,label,anchor);append_dev(label,t1);if(!mounted){dispose=[listen_dev(input_1,"input",ctx[26]),listen_dev(input_1,"input",ctx[18],false,false,false,false)];mounted=true}},p:function update(ctx,dirty){if(dirty&256){attr_dev(input_1,"id",ctx[8])}if(dirty&256){attr_dev(input_1,"name",ctx[8])}if(dirty&16){attr_dev(input_1,"placeholder",ctx[4])}if(dirty&65536){prop_dev(input_1,"disabled",ctx[16])}if(dirty&131072){attr_dev(input_1,"aria-labelledby",ctx[17])}if(dirty&2&&input_1.value!==ctx[1]){set_input_value(input_1,ctx[1])}if(dirty&65536){toggle_class(input_1,"disabled",ctx[16])}if(dirty&4)set_data_dev(t1,ctx[2]);if(dirty&256){attr_dev(label,"for",ctx[8])}},d:function destroy(detaching){if(detaching){detach_dev(input_1);detach_dev(t0);detach_dev(label)}mounted=false;run_all(dispose)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$C.name,type:"slot",source:'(114:2) <PanelRow class=\\"input\\">',ctx:ctx});return block}function create_if_block_3$5(ctx){let p;let t;let p_transition;let current;const block={c:function create(){p=element("p");t=text(ctx[15]);attr_dev(p,"class","input-error");add_location(p,file$M,132,3,3565)},m:function mount(target,anchor){insert_dev(target,p,anchor);append_dev(p,t);current=true},p:function update(ctx,dirty){if(!current||dirty&32768)set_data_dev(t,ctx[15])},i:function intro(local){if(current)return;if(local){add_render_callback((()=>{if(!current)return;if(!p_transition)p_transition=create_bidirectional_transition(p,slide,{},true);p_transition.run(1)}))}current=true},o:function outro(local){if(local){if(!p_transition)p_transition=create_bidirectional_transition(p,slide,{},false);p_transition.run(0)}current=false},d:function destroy(detaching){if(detaching){detach_dev(p)}if(detaching&&p_transition)p_transition.end()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_3$5.name,type:"if",source:"(132:2) {#if validationError && textDirty}",ctx:ctx});return block}function create_if_block_1$g(ctx){let settingnotifications;let current;settingnotifications=new SettingNotifications({props:{settingKey:ctx[7]},$$inline:true});const block={c:function create(){create_component(settingnotifications.$$.fragment)},m:function mount(target,anchor){mount_component(settingnotifications,target,anchor);current=true},p:function update(ctx,dirty){const settingnotifications_changes={};if(dirty&128)settingnotifications_changes.settingKey=ctx[7];settingnotifications.$set(settingnotifications_changes)},i:function intro(local){if(current)return;transition_in(settingnotifications.$$.fragment,local);current=true},o:function outro(local){transition_out(settingnotifications.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(settingnotifications,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_1$g.name,type:"if",source:"(137:1) {#if toggleName}",ctx:ctx});return block}function create_if_block$q(ctx){let settingnotifications;let current;settingnotifications=new SettingNotifications({props:{settingKey:ctx[8]},$$inline:true});const block={c:function create(){create_component(settingnotifications.$$.fragment)},m:function mount(target,anchor){mount_component(settingnotifications,target,anchor);current=true},p:function update(ctx,dirty){const settingnotifications_changes={};if(dirty&256)settingnotifications_changes.settingKey=ctx[8];settingnotifications.$set(settingnotifications_changes)},i:function intro(local){if(current)return;transition_in(settingnotifications.$$.fragment,local);current=true},o:function outro(local){transition_out(settingnotifications.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(settingnotifications,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$q.name,type:"if",source:"(141:1) {#if textName}",ctx:ctx});return block}function create_fragment$X(ctx){let div;let panelrow0;let t0;let panelrow1;let t1;let t2;let t3;let t4;let current;panelrow0=new PanelRow({props:{class:"option",$$slots:{default:[create_default_slot_2$i]},$$scope:{ctx:ctx}},$$inline:true});panelrow1=new PanelRow({props:{class:"desc",$$slots:{default:[create_default_slot_1$o]},$$scope:{ctx:ctx}},$$inline:true});let if_block0=ctx[10]&&create_if_block_2$8(ctx);let if_block1=ctx[7]&&create_if_block_1$g(ctx);let if_block2=ctx[8]&&create_if_block$q(ctx);const default_slot_template=ctx[24].default;const default_slot=create_slot(default_slot_template,ctx,ctx[27],null);const block={c:function create(){div=element("div");create_component(panelrow0.$$.fragment);t0=space();create_component(panelrow1.$$.fragment);t1=space();if(if_block0)if_block0.c();t2=space();if(if_block1)if_block1.c();t3=space();if(if_block2)if_block2.c();t4=space();if(default_slot)default_slot.c();attr_dev(div,"class","setting");toggle_class(div,"nested",ctx[5]);toggle_class(div,"first",ctx[6]);add_location(div,file$M,94,0,2418)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,div,anchor);mount_component(panelrow0,div,null);append_dev(div,t0);mount_component(panelrow1,div,null);append_dev(div,t1);if(if_block0)if_block0.m(div,null);append_dev(div,t2);if(if_block1)if_block1.m(div,null);append_dev(div,t3);if(if_block2)if_block2.m(div,null);append_dev(div,t4);if(default_slot){default_slot.m(div,null)}current=true},p:function update(ctx,[dirty]){const panelrow0_changes={};if(dirty&134368645){panelrow0_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow0.$set(panelrow0_changes);const panelrow1_changes={};if(dirty&134217736){panelrow1_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow1.$set(panelrow1_changes);if(ctx[10]){if(if_block0){if_block0.p(ctx,dirty);if(dirty&1024){transition_in(if_block0,1)}}else{if_block0=create_if_block_2$8(ctx);if_block0.c();transition_in(if_block0,1);if_block0.m(div,t2)}}else if(if_block0){group_outros();transition_out(if_block0,1,1,(()=>{if_block0=null}));check_outros()}if(ctx[7]){if(if_block1){if_block1.p(ctx,dirty);if(dirty&128){transition_in(if_block1,1)}}else{if_block1=create_if_block_1$g(ctx);if_block1.c();transition_in(if_block1,1);if_block1.m(div,t3)}}else if(if_block1){group_outros();transition_out(if_block1,1,1,(()=>{if_block1=null}));check_outros()}if(ctx[8]){if(if_block2){if_block2.p(ctx,dirty);if(dirty&256){transition_in(if_block2,1)}}else{if_block2=create_if_block$q(ctx);if_block2.c();transition_in(if_block2,1);if_block2.m(div,t4)}}else if(if_block2){group_outros();transition_out(if_block2,1,1,(()=>{if_block2=null}));check_outros()}if(default_slot){if(default_slot.p&&(!current||dirty&134217728)){update_slot_base(default_slot,default_slot_template,ctx,ctx[27],!current?get_all_dirty_from_scope(ctx[27]):get_slot_changes(default_slot_template,ctx[27],dirty,null),null)}}if(!current||dirty&32){toggle_class(div,"nested",ctx[5])}if(!current||dirty&64){toggle_class(div,"first",ctx[6])}},i:function intro(local){if(current)return;transition_in(panelrow0.$$.fragment,local);transition_in(panelrow1.$$.fragment,local);transition_in(if_block0);transition_in(if_block1);transition_in(if_block2);transition_in(default_slot,local);current=true},o:function outro(local){transition_out(panelrow0.$$.fragment,local);transition_out(panelrow1.$$.fragment,local);transition_out(if_block0);transition_out(if_block1);transition_out(if_block2);transition_out(default_slot,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(div)}destroy_component(panelrow0);destroy_component(panelrow1);if(if_block0)if_block0.d();if(if_block1)if_block1.d();if(if_block2)if_block2.d();if(default_slot)default_slot.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$X.name,type:"component",source:"",ctx:ctx});return block}function instance$X($$self,$$props,$$invalidate){let locked;let toggleDisabled;let textDisabled;let input;let headingName;let validationError;let $definedSettings,$$unsubscribe_definedSettings=noop,$$subscribe_definedSettings=()=>($$unsubscribe_definedSettings(),$$unsubscribe_definedSettings=subscribe(definedSettings,($$value=>$$invalidate(11,$definedSettings=$$value))),definedSettings);let $settingsLocked,$$unsubscribe_settingsLocked=noop,$$subscribe_settingsLocked=()=>($$unsubscribe_settingsLocked(),$$unsubscribe_settingsLocked=subscribe(settingsLocked,($$value=>$$invalidate(23,$settingsLocked=$$value))),settingsLocked);$$self.$$.on_destroy.push((()=>$$unsubscribe_definedSettings()));$$self.$$.on_destroy.push((()=>$$unsubscribe_settingsLocked()));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("SettingsPanelOption",slots,["default"]);let{heading:heading=""}=$$props;let{description:description=""}=$$props;let{placeholder:placeholder=""}=$$props;let{nested:nested=false}=$$props;let{first:first=false}=$$props;let{toggleName:toggleName=""}=$$props;let{toggle:toggle=false}=$$props;let{textName:textName=""}=$$props;let{text:text=""}=$$props;let{alwaysShowText:alwaysShowText=false}=$$props;let{definedSettings:definedSettings=defined_settings}=$$props;validate_store(definedSettings,"definedSettings");$$subscribe_definedSettings();let{validator:validator=textValue=>""}=$$props;let settingsLocked=writable(false);validate_store(settingsLocked,"settingsLocked");$$subscribe_settingsLocked();let textDirty=false;if(hasContext("settingsLocked")){$$subscribe_settingsLocked(settingsLocked=getContext("settingsLocked"))}function validateText(text,toggle){let message="";if(validator!==undefined&&toggle&&!textDisabled){message=validator(text)}validationErrors.update((_validationErrors=>{if(_validationErrors.has(textName)&&message===""){_validationErrors.delete(textName)}else if(message!==""){_validationErrors.set(textName,message)}return _validationErrors}));return message}function onTextInput(){$$invalidate(13,textDirty=true)}function headingClickHandler(){if(toggleName&&!toggleDisabled){$$invalidate(0,toggle=!toggle)}}const writable_props=["heading","description","placeholder","nested","first","toggleName","toggle","textName","text","alwaysShowText","definedSettings","validator"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<SettingsPanelOption> was created with unknown prop '${key}'`)}));function toggleswitch_checked_binding(value){toggle=value;$$invalidate(0,toggle)}function input_1_input_handler(){text=this.value;$$invalidate(1,text)}$$self.$$set=$$props=>{if("heading"in $$props)$$invalidate(2,heading=$$props.heading);if("description"in $$props)$$invalidate(3,description=$$props.description);if("placeholder"in $$props)$$invalidate(4,placeholder=$$props.placeholder);if("nested"in $$props)$$invalidate(5,nested=$$props.nested);if("first"in $$props)$$invalidate(6,first=$$props.first);if("toggleName"in $$props)$$invalidate(7,toggleName=$$props.toggleName);if("toggle"in $$props)$$invalidate(0,toggle=$$props.toggle);if("textName"in $$props)$$invalidate(8,textName=$$props.textName);if("text"in $$props)$$invalidate(1,text=$$props.text);if("alwaysShowText"in $$props)$$invalidate(20,alwaysShowText=$$props.alwaysShowText);if("definedSettings"in $$props)$$subscribe_definedSettings($$invalidate(9,definedSettings=$$props.definedSettings));if("validator"in $$props)$$invalidate(21,validator=$$props.validator);if("$$scope"in $$props)$$invalidate(27,$$scope=$$props.$$scope)};$$self.$capture_state=()=>({getContext:getContext,hasContext:hasContext,writable:writable,slide:slide,defined_settings:defined_settings,validationErrors:validationErrors,PanelRow:PanelRow,ToggleSwitch:ToggleSwitch,DefinedInWPConfig:DefinedInWPConfig,SettingNotifications:SettingNotifications,heading:heading,description:description,placeholder:placeholder,nested:nested,first:first,toggleName:toggleName,toggle:toggle,textName:textName,text:text,alwaysShowText:alwaysShowText,definedSettings:definedSettings,validator:validator,settingsLocked:settingsLocked,textDirty:textDirty,validateText:validateText,onTextInput:onTextInput,headingClickHandler:headingClickHandler,toggleDisabled:toggleDisabled,validationError:validationError,textDisabled:textDisabled,input:input,headingName:headingName,locked:locked,$definedSettings:$definedSettings,$settingsLocked:$settingsLocked});$$self.$inject_state=$$props=>{if("heading"in $$props)$$invalidate(2,heading=$$props.heading);if("description"in $$props)$$invalidate(3,description=$$props.description);if("placeholder"in $$props)$$invalidate(4,placeholder=$$props.placeholder);if("nested"in $$props)$$invalidate(5,nested=$$props.nested);if("first"in $$props)$$invalidate(6,first=$$props.first);if("toggleName"in $$props)$$invalidate(7,toggleName=$$props.toggleName);if("toggle"in $$props)$$invalidate(0,toggle=$$props.toggle);if("textName"in $$props)$$invalidate(8,textName=$$props.textName);if("text"in $$props)$$invalidate(1,text=$$props.text);if("alwaysShowText"in $$props)$$invalidate(20,alwaysShowText=$$props.alwaysShowText);if("definedSettings"in $$props)$$subscribe_definedSettings($$invalidate(9,definedSettings=$$props.definedSettings));if("validator"in $$props)$$invalidate(21,validator=$$props.validator);if("settingsLocked"in $$props)$$subscribe_settingsLocked($$invalidate(12,settingsLocked=$$props.settingsLocked));if("textDirty"in $$props)$$invalidate(13,textDirty=$$props.textDirty);if("toggleDisabled"in $$props)$$invalidate(14,toggleDisabled=$$props.toggleDisabled);if("validationError"in $$props)$$invalidate(15,validationError=$$props.validationError);if("textDisabled"in $$props)$$invalidate(16,textDisabled=$$props.textDisabled);if("input"in $$props)$$invalidate(10,input=$$props.input);if("headingName"in $$props)$$invalidate(17,headingName=$$props.headingName);if("locked"in $$props)$$invalidate(22,locked=$$props.locked)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty&8388608){$$invalidate(22,locked=$settingsLocked)}if($$self.$$.dirty&4196480){$$invalidate(14,toggleDisabled=$definedSettings.includes(toggleName)||locked)}if($$self.$$.dirty&4196608){$$invalidate(16,textDisabled=$definedSettings.includes(textName)||locked)}if($$self.$$.dirty&1048961){$$invalidate(10,input=(toggleName&&toggle||!toggleName||alwaysShowText)&&textName)}if($$self.$$.dirty&1408){$$invalidate(17,headingName=input?textName+"-heading":toggleName)}if($$self.$$.dirty&3){$$invalidate(15,validationError=validateText(text,toggle))}};return[toggle,text,heading,description,placeholder,nested,first,toggleName,textName,definedSettings,input,$definedSettings,settingsLocked,textDirty,toggleDisabled,validationError,textDisabled,headingName,onTextInput,headingClickHandler,alwaysShowText,validator,locked,$settingsLocked,slots,toggleswitch_checked_binding,input_1_input_handler,$$scope]}class SettingsPanelOption extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$X,create_fragment$X,safe_not_equal,{heading:2,description:3,placeholder:4,nested:5,first:6,toggleName:7,toggle:0,textName:8,text:1,alwaysShowText:20,definedSettings:9,validator:21});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"SettingsPanelOption",options:options,id:create_fragment$X.name})}get heading(){throw new Error("<SettingsPanelOption>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set heading(value){throw new Error("<SettingsPanelOption>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get description(){throw new Error("<SettingsPanelOption>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set description(value){throw new Error("<SettingsPanelOption>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get placeholder(){throw new Error("<SettingsPanelOption>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set placeholder(value){throw new Error("<SettingsPanelOption>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get nested(){throw new Error("<SettingsPanelOption>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set nested(value){throw new Error("<SettingsPanelOption>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get first(){throw new Error("<SettingsPanelOption>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set first(value){throw new Error("<SettingsPanelOption>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get toggleName(){throw new Error("<SettingsPanelOption>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set toggleName(value){throw new Error("<SettingsPanelOption>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get toggle(){throw new Error("<SettingsPanelOption>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set toggle(value){throw new Error("<SettingsPanelOption>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get textName(){throw new Error("<SettingsPanelOption>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set textName(value){throw new Error("<SettingsPanelOption>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get text(){throw new Error("<SettingsPanelOption>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set text(value){throw new Error("<SettingsPanelOption>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get alwaysShowText(){throw new Error("<SettingsPanelOption>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set alwaysShowText(value){throw new Error("<SettingsPanelOption>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get definedSettings(){throw new Error("<SettingsPanelOption>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set definedSettings(value){throw new Error("<SettingsPanelOption>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get validator(){throw new Error("<SettingsPanelOption>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set validator(value){throw new Error("<SettingsPanelOption>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}function create_default_slot$B(ctx){let storagesettingsheadingrow;let t0;let settingsvalidationstatusrow;let t1;let settingspaneloption0;let updating_toggle;let t2;let settingspaneloption1;let updating_toggle_1;let t3;let settingspaneloption2;let updating_toggle_2;let updating_text;let t4;let settingspaneloption3;let updating_toggle_3;let t5;let settingspaneloption4;let updating_toggle_4;let current;storagesettingsheadingrow=new StorageSettingsHeadingRow({$$inline:true});settingsvalidationstatusrow=new SettingsValidationStatusRow({props:{section:"storage"},$$inline:true});function settingspaneloption0_toggle_binding(value){ctx[2](value)}let settingspaneloption0_props={heading:ctx[0].copy_files_to_bucket,description:ctx[0].copy_files_to_bucket_desc,toggleName:"copy-to-s3"};if(ctx[1]["copy-to-s3"]!==void 0){settingspaneloption0_props.toggle=ctx[1]["copy-to-s3"]}settingspaneloption0=new SettingsPanelOption({props:settingspaneloption0_props,$$inline:true});binding_callbacks.push((()=>bind(settingspaneloption0,"toggle",settingspaneloption0_toggle_binding)));function settingspaneloption1_toggle_binding(value){ctx[3](value)}let settingspaneloption1_props={heading:ctx[0].remove_local_file,description:ctx[0].remove_local_file_desc,toggleName:"remove-local-file"};if(ctx[1]["remove-local-file"]!==void 0){settingspaneloption1_props.toggle=ctx[1]["remove-local-file"]}settingspaneloption1=new SettingsPanelOption({props:settingspaneloption1_props,$$inline:true});binding_callbacks.push((()=>bind(settingspaneloption1,"toggle",settingspaneloption1_toggle_binding)));function settingspaneloption2_toggle_binding(value){ctx[4](value)}function settingspaneloption2_text_binding(value){ctx[5](value)}let settingspaneloption2_props={heading:ctx[0].path,description:ctx[0].path_desc,toggleName:"enable-object-prefix",textName:"object-prefix"};if(ctx[1]["enable-object-prefix"]!==void 0){settingspaneloption2_props.toggle=ctx[1]["enable-object-prefix"]}if(ctx[1]["object-prefix"]!==void 0){settingspaneloption2_props.text=ctx[1]["object-prefix"]}settingspaneloption2=new SettingsPanelOption({props:settingspaneloption2_props,$$inline:true});binding_callbacks.push((()=>bind(settingspaneloption2,"toggle",settingspaneloption2_toggle_binding)));binding_callbacks.push((()=>bind(settingspaneloption2,"text",settingspaneloption2_text_binding)));function settingspaneloption3_toggle_binding(value){ctx[6](value)}let settingspaneloption3_props={heading:ctx[0].year_month,description:ctx[0].year_month_desc,toggleName:"use-yearmonth-folders"};if(ctx[1]["use-yearmonth-folders"]!==void 0){settingspaneloption3_props.toggle=ctx[1]["use-yearmonth-folders"]}settingspaneloption3=new SettingsPanelOption({props:settingspaneloption3_props,$$inline:true});binding_callbacks.push((()=>bind(settingspaneloption3,"toggle",settingspaneloption3_toggle_binding)));function settingspaneloption4_toggle_binding(value){ctx[7](value)}let settingspaneloption4_props={heading:ctx[0].object_versioning,description:ctx[0].object_versioning_desc,toggleName:"object-versioning"};if(ctx[1]["object-versioning"]!==void 0){settingspaneloption4_props.toggle=ctx[1]["object-versioning"]}settingspaneloption4=new SettingsPanelOption({props:settingspaneloption4_props,$$inline:true});binding_callbacks.push((()=>bind(settingspaneloption4,"toggle",settingspaneloption4_toggle_binding)));const block={c:function create(){create_component(storagesettingsheadingrow.$$.fragment);t0=space();create_component(settingsvalidationstatusrow.$$.fragment);t1=space();create_component(settingspaneloption0.$$.fragment);t2=space();create_component(settingspaneloption1.$$.fragment);t3=space();create_component(settingspaneloption2.$$.fragment);t4=space();create_component(settingspaneloption3.$$.fragment);t5=space();create_component(settingspaneloption4.$$.fragment)},m:function mount(target,anchor){mount_component(storagesettingsheadingrow,target,anchor);insert_dev(target,t0,anchor);mount_component(settingsvalidationstatusrow,target,anchor);insert_dev(target,t1,anchor);mount_component(settingspaneloption0,target,anchor);insert_dev(target,t2,anchor);mount_component(settingspaneloption1,target,anchor);insert_dev(target,t3,anchor);mount_component(settingspaneloption2,target,anchor);insert_dev(target,t4,anchor);mount_component(settingspaneloption3,target,anchor);insert_dev(target,t5,anchor);mount_component(settingspaneloption4,target,anchor);current=true},p:function update(ctx,dirty){const settingspaneloption0_changes={};if(dirty&1)settingspaneloption0_changes.heading=ctx[0].copy_files_to_bucket;if(dirty&1)settingspaneloption0_changes.description=ctx[0].copy_files_to_bucket_desc;if(!updating_toggle&&dirty&2){updating_toggle=true;settingspaneloption0_changes.toggle=ctx[1]["copy-to-s3"];add_flush_callback((()=>updating_toggle=false))}settingspaneloption0.$set(settingspaneloption0_changes);const settingspaneloption1_changes={};if(dirty&1)settingspaneloption1_changes.heading=ctx[0].remove_local_file;if(dirty&1)settingspaneloption1_changes.description=ctx[0].remove_local_file_desc;if(!updating_toggle_1&&dirty&2){updating_toggle_1=true;settingspaneloption1_changes.toggle=ctx[1]["remove-local-file"];add_flush_callback((()=>updating_toggle_1=false))}settingspaneloption1.$set(settingspaneloption1_changes);const settingspaneloption2_changes={};if(dirty&1)settingspaneloption2_changes.heading=ctx[0].path;if(dirty&1)settingspaneloption2_changes.description=ctx[0].path_desc;if(!updating_toggle_2&&dirty&2){updating_toggle_2=true;settingspaneloption2_changes.toggle=ctx[1]["enable-object-prefix"];add_flush_callback((()=>updating_toggle_2=false))}if(!updating_text&&dirty&2){updating_text=true;settingspaneloption2_changes.text=ctx[1]["object-prefix"];add_flush_callback((()=>updating_text=false))}settingspaneloption2.$set(settingspaneloption2_changes);const settingspaneloption3_changes={};if(dirty&1)settingspaneloption3_changes.heading=ctx[0].year_month;if(dirty&1)settingspaneloption3_changes.description=ctx[0].year_month_desc;if(!updating_toggle_3&&dirty&2){updating_toggle_3=true;settingspaneloption3_changes.toggle=ctx[1]["use-yearmonth-folders"];add_flush_callback((()=>updating_toggle_3=false))}settingspaneloption3.$set(settingspaneloption3_changes);const settingspaneloption4_changes={};if(dirty&1)settingspaneloption4_changes.heading=ctx[0].object_versioning;if(dirty&1)settingspaneloption4_changes.description=ctx[0].object_versioning_desc;if(!updating_toggle_4&&dirty&2){updating_toggle_4=true;settingspaneloption4_changes.toggle=ctx[1]["object-versioning"];add_flush_callback((()=>updating_toggle_4=false))}settingspaneloption4.$set(settingspaneloption4_changes)},i:function intro(local){if(current)return;transition_in(storagesettingsheadingrow.$$.fragment,local);transition_in(settingsvalidationstatusrow.$$.fragment,local);transition_in(settingspaneloption0.$$.fragment,local);transition_in(settingspaneloption1.$$.fragment,local);transition_in(settingspaneloption2.$$.fragment,local);transition_in(settingspaneloption3.$$.fragment,local);transition_in(settingspaneloption4.$$.fragment,local);current=true},o:function outro(local){transition_out(storagesettingsheadingrow.$$.fragment,local);transition_out(settingsvalidationstatusrow.$$.fragment,local);transition_out(settingspaneloption0.$$.fragment,local);transition_out(settingspaneloption1.$$.fragment,local);transition_out(settingspaneloption2.$$.fragment,local);transition_out(settingspaneloption3.$$.fragment,local);transition_out(settingspaneloption4.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(t1);detach_dev(t2);detach_dev(t3);detach_dev(t4);detach_dev(t5)}destroy_component(storagesettingsheadingrow,detaching);destroy_component(settingsvalidationstatusrow,detaching);destroy_component(settingspaneloption0,detaching);destroy_component(settingspaneloption1,detaching);destroy_component(settingspaneloption2,detaching);destroy_component(settingspaneloption3,detaching);destroy_component(settingspaneloption4,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$B.name,type:"slot",source:'(10:0) <Panel name=\\"settings\\" heading={$strings.storage_settings_title} helpKey=\\"storage-provider\\">',ctx:ctx});return block}function create_fragment$W(ctx){let panel;let current;panel=new Panel({props:{name:"settings",heading:ctx[0].storage_settings_title,helpKey:"storage-provider",$$slots:{default:[create_default_slot$B]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panel.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(panel,target,anchor);current=true},p:function update(ctx,[dirty]){const panel_changes={};if(dirty&1)panel_changes.heading=ctx[0].storage_settings_title;if(dirty&259){panel_changes.$$scope={dirty:dirty,ctx:ctx}}panel.$set(panel_changes)},i:function intro(local){if(current)return;transition_in(panel.$$.fragment,local);current=true},o:function outro(local){transition_out(panel.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panel,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$W.name,type:"component",source:"",ctx:ctx});return block}function instance$W($$self,$$props,$$invalidate){let $strings;let $settings;validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(0,$strings=$$value)));validate_store(settings,"settings");component_subscribe($$self,settings,($$value=>$$invalidate(1,$settings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("StorageSettingsPanel",slots,[]);const writable_props=[];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<StorageSettingsPanel> was created with unknown prop '${key}'`)}));function settingspaneloption0_toggle_binding(value){if($$self.$$.not_equal($settings["copy-to-s3"],value)){$settings["copy-to-s3"]=value;settings.set($settings)}}function settingspaneloption1_toggle_binding(value){if($$self.$$.not_equal($settings["remove-local-file"],value)){$settings["remove-local-file"]=value;settings.set($settings)}}function settingspaneloption2_toggle_binding(value){if($$self.$$.not_equal($settings["enable-object-prefix"],value)){$settings["enable-object-prefix"]=value;settings.set($settings)}}function settingspaneloption2_text_binding(value){if($$self.$$.not_equal($settings["object-prefix"],value)){$settings["object-prefix"]=value;settings.set($settings)}}function settingspaneloption3_toggle_binding(value){if($$self.$$.not_equal($settings["use-yearmonth-folders"],value)){$settings["use-yearmonth-folders"]=value;settings.set($settings)}}function settingspaneloption4_toggle_binding(value){if($$self.$$.not_equal($settings["object-versioning"],value)){$settings["object-versioning"]=value;settings.set($settings)}}$$self.$capture_state=()=>({settings:settings,strings:strings,Panel:Panel,StorageSettingsHeadingRow:StorageSettingsHeadingRow,SettingsValidationStatusRow:SettingsValidationStatusRow,SettingsPanelOption:SettingsPanelOption,$strings:$strings,$settings:$settings});return[$strings,$settings,settingspaneloption0_toggle_binding,settingspaneloption1_toggle_binding,settingspaneloption2_toggle_binding,settingspaneloption2_text_binding,settingspaneloption3_toggle_binding,settingspaneloption4_toggle_binding]}class StorageSettingsPanel extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$W,create_fragment$W,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"StorageSettingsPanel",options:options,id:create_fragment$W.name})}}function create_default_slot$A(ctx){let storagesettingspanel;let current;storagesettingspanel=new StorageSettingsPanel({$$inline:true});const block={c:function create(){create_component(storagesettingspanel.$$.fragment)},m:function mount(target,anchor){mount_component(storagesettingspanel,target,anchor);current=true},i:function intro(local){if(current)return;transition_in(storagesettingspanel.$$.fragment,local);current=true},o:function outro(local){transition_out(storagesettingspanel.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(storagesettingspanel,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$A.name,type:"slot",source:'(6:0) <SubPage name=\\"storage-settings\\">',ctx:ctx});return block}function create_fragment$V(ctx){let subpage;let current;subpage=new SubPage({props:{name:"storage-settings",$$slots:{default:[create_default_slot$A]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(subpage.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(subpage,target,anchor);current=true},p:function update(ctx,[dirty]){const subpage_changes={};if(dirty&1){subpage_changes.$$scope={dirty:dirty,ctx:ctx}}subpage.$set(subpage_changes)},i:function intro(local){if(current)return;transition_in(subpage.$$.fragment,local);current=true},o:function outro(local){transition_out(subpage.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(subpage,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$V.name,type:"component",source:"",ctx:ctx});return block}function instance$V($$self,$$props,$$invalidate){let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("StorageSettingsSubPage",slots,[]);const writable_props=[];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<StorageSettingsSubPage> was created with unknown prop '${key}'`)}));$$self.$capture_state=()=>({SubPage:SubPage,StorageSettingsPanel:StorageSettingsPanel});return[]}class StorageSettingsSubPage extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$V,create_fragment$V,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"StorageSettingsSubPage",options:options,id:create_fragment$V.name})}}const file$L="ui/components/DeliverySettingsHeadingRow.svelte";function create_default_slot_1$n(ctx){let t_value=ctx[5].edit+"";let t;const block={c:function create(){t=text(t_value)},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty&32&&t_value!==(t_value=ctx[5].edit+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$n.name,type:"slot",source:"(34:1) <Button outline on:click={() => push('/delivery/provider')} title={$strings.edit_delivery_provider} disabled={$settingsLocked}>",ctx:ctx});return block}function create_default_slot$z(ctx){let img;let img_src_value;let img_alt_value;let t0;let div;let h3;let t1_value=ctx[1].provider_service_name+"";let t1;let t2;let p;let a;let t3_value=ctx[1].console_title+"";let t3;let a_href_value;let a_title_value;let t4;let button;let current;button=new Button({props:{outline:true,title:ctx[5].edit_delivery_provider,disabled:ctx[6],$$slots:{default:[create_default_slot_1$n]},$$scope:{ctx:ctx}},$$inline:true});button.$on("click",ctx[9]);const block={c:function create(){img=element("img");t0=space();div=element("div");h3=element("h3");t1=text(t1_value);t2=space();p=element("p");a=element("a");t3=text(t3_value);t4=space();create_component(button.$$.fragment);if(!src_url_equal(img.src,img_src_value=ctx[1].icon))attr_dev(img,"src",img_src_value);attr_dev(img,"alt",img_alt_value=ctx[1].provider_service_name);attr_dev(img,"class","svelte-sglpwv");add_location(img,file$L,26,1,803);attr_dev(h3,"class","svelte-sglpwv");add_location(h3,file$L,28,2,923);attr_dev(a,"href",a_href_value=ctx[4].delivery_provider_console_url);attr_dev(a,"class","console svelte-sglpwv");attr_dev(a,"target","_blank");attr_dev(a,"title",a_title_value=ctx[5].view_provider_console);add_location(a,file$L,30,3,1008);attr_dev(p,"class","console-details svelte-sglpwv");add_location(p,file$L,29,2,977);attr_dev(div,"class","provider-details svelte-sglpwv");add_location(div,file$L,27,1,890)},m:function mount(target,anchor){insert_dev(target,img,anchor);insert_dev(target,t0,anchor);insert_dev(target,div,anchor);append_dev(div,h3);append_dev(h3,t1);append_dev(div,t2);append_dev(div,p);append_dev(p,a);append_dev(a,t3);insert_dev(target,t4,anchor);mount_component(button,target,anchor);current=true},p:function update(ctx,dirty){if(!current||dirty&2&&!src_url_equal(img.src,img_src_value=ctx[1].icon)){attr_dev(img,"src",img_src_value)}if(!current||dirty&2&&img_alt_value!==(img_alt_value=ctx[1].provider_service_name)){attr_dev(img,"alt",img_alt_value)}if((!current||dirty&2)&&t1_value!==(t1_value=ctx[1].provider_service_name+""))set_data_dev(t1,t1_value);if((!current||dirty&2)&&t3_value!==(t3_value=ctx[1].console_title+""))set_data_dev(t3,t3_value);if(!current||dirty&16&&a_href_value!==(a_href_value=ctx[4].delivery_provider_console_url)){attr_dev(a,"href",a_href_value)}if(!current||dirty&32&&a_title_value!==(a_title_value=ctx[5].view_provider_console)){attr_dev(a,"title",a_title_value)}const button_changes={};if(dirty&32)button_changes.title=ctx[5].edit_delivery_provider;if(dirty&64)button_changes.disabled=ctx[6];if(dirty&1056){button_changes.$$scope={dirty:dirty,ctx:ctx}}button.$set(button_changes)},i:function intro(local){if(current)return;transition_in(button.$$.fragment,local);current=true},o:function outro(local){transition_out(button.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(img);detach_dev(t0);detach_dev(div);detach_dev(t4)}destroy_component(button,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$z.name,type:"slot",source:'(26:0) <PanelRow header gradient class=\\"delivery {providerType} {providerKey}\\">',ctx:ctx});return block}function create_fragment$U(ctx){let panelrow;let current;panelrow=new PanelRow({props:{header:true,gradient:true,class:"delivery "+ctx[0]+" "+ctx[3],$$slots:{default:[create_default_slot$z]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,[dirty]){const panelrow_changes={};if(dirty&9)panelrow_changes.class="delivery "+ctx[0]+" "+ctx[3];if(dirty&1138){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$U.name,type:"component",source:"",ctx:ctx});return block}function instance$U($$self,$$props,$$invalidate){let providerType;let providerKey;let $delivery_provider;let $storage_provider;let $settings;let $urls;let $strings;let $settingsLocked,$$unsubscribe_settingsLocked=noop,$$subscribe_settingsLocked=()=>($$unsubscribe_settingsLocked(),$$unsubscribe_settingsLocked=subscribe(settingsLocked,($$value=>$$invalidate(6,$settingsLocked=$$value))),settingsLocked);validate_store(delivery_provider,"delivery_provider");component_subscribe($$self,delivery_provider,($$value=>$$invalidate(1,$delivery_provider=$$value)));validate_store(storage_provider,"storage_provider");component_subscribe($$self,storage_provider,($$value=>$$invalidate(7,$storage_provider=$$value)));validate_store(settings,"settings");component_subscribe($$self,settings,($$value=>$$invalidate(8,$settings=$$value)));validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(4,$urls=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(5,$strings=$$value)));$$self.$$.on_destroy.push((()=>$$unsubscribe_settingsLocked()));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("DeliverySettingsHeadingRow",slots,[]);let settingsLocked=writable(false);validate_store(settingsLocked,"settingsLocked");$$subscribe_settingsLocked();if(hasContext("settingsLocked")){$$subscribe_settingsLocked(settingsLocked=getContext("settingsLocked"))}const writable_props=[];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<DeliverySettingsHeadingRow> was created with unknown prop '${key}'`)}));const click_handler=()=>push("/delivery/provider");$$self.$capture_state=()=>({hasContext:hasContext,getContext:getContext,writable:writable,push:push,delivery_provider:delivery_provider,settings:settings,storage_provider:storage_provider,strings:strings,urls:urls,PanelRow:PanelRow,Button:Button,settingsLocked:settingsLocked,providerType:providerType,providerKey:providerKey,$delivery_provider:$delivery_provider,$storage_provider:$storage_provider,$settings:$settings,$urls:$urls,$strings:$strings,$settingsLocked:$settingsLocked});$$self.$inject_state=$$props=>{if("settingsLocked"in $$props)$$subscribe_settingsLocked($$invalidate(2,settingsLocked=$$props.settingsLocked));if("providerType"in $$props)$$invalidate(0,providerType=$$props.providerType);if("providerKey"in $$props)$$invalidate(3,providerKey=$$props.providerKey)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty&256){$$invalidate(0,providerType=$settings["delivery-provider"]==="storage"?"storage":"delivery")}if($$self.$$.dirty&131){$$invalidate(3,providerKey=providerType==="storage"?$storage_provider.provider_key_name:$delivery_provider.provider_key_name)}};return[providerType,$delivery_provider,settingsLocked,providerKey,$urls,$strings,$settingsLocked,$storage_provider,$settings,click_handler]}class DeliverySettingsHeadingRow extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$U,create_fragment$U,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"DeliverySettingsHeadingRow",options:options,id:create_fragment$U.name})}}function create_if_block$p(ctx){let settingspaneloption;let updating_toggle;let updating_text;let t;let if_block_anchor;let current;function settingspaneloption_toggle_binding(value){ctx[5](value)}function settingspaneloption_text_binding(value){ctx[6](value)}let settingspaneloption_props={heading:ctx[0].delivery_domain,description:ctx[1].delivery_domain_desc,toggleName:"enable-delivery-domain",textName:"delivery-domain",validator:ctx[3]};if(ctx[2]["enable-delivery-domain"]!==void 0){settingspaneloption_props.toggle=ctx[2]["enable-delivery-domain"]}if(ctx[2]["delivery-domain"]!==void 0){settingspaneloption_props.text=ctx[2]["delivery-domain"]}settingspaneloption=new SettingsPanelOption({props:settingspaneloption_props,$$inline:true});binding_callbacks.push((()=>bind(settingspaneloption,"toggle",settingspaneloption_toggle_binding)));binding_callbacks.push((()=>bind(settingspaneloption,"text",settingspaneloption_text_binding)));let if_block=ctx[1].use_signed_urls_key_file_allowed&&ctx[2]["enable-delivery-domain"]&&create_if_block_1$f(ctx);const block={c:function create(){create_component(settingspaneloption.$$.fragment);t=space();if(if_block)if_block.c();if_block_anchor=empty()},m:function mount(target,anchor){mount_component(settingspaneloption,target,anchor);insert_dev(target,t,anchor);if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,dirty){const settingspaneloption_changes={};if(dirty&1)settingspaneloption_changes.heading=ctx[0].delivery_domain;if(dirty&2)settingspaneloption_changes.description=ctx[1].delivery_domain_desc;if(!updating_toggle&&dirty&4){updating_toggle=true;settingspaneloption_changes.toggle=ctx[2]["enable-delivery-domain"];add_flush_callback((()=>updating_toggle=false))}if(!updating_text&&dirty&4){updating_text=true;settingspaneloption_changes.text=ctx[2]["delivery-domain"];add_flush_callback((()=>updating_text=false))}settingspaneloption.$set(settingspaneloption_changes);if(ctx[1].use_signed_urls_key_file_allowed&&ctx[2]["enable-delivery-domain"]){if(if_block){if_block.p(ctx,dirty);if(dirty&6){transition_in(if_block,1)}}else{if_block=create_if_block_1$f(ctx);if_block.c();transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(settingspaneloption.$$.fragment,local);transition_in(if_block);current=true},o:function outro(local){transition_out(settingspaneloption.$$.fragment,local);transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(t);detach_dev(if_block_anchor)}destroy_component(settingspaneloption,detaching);if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$p.name,type:"if",source:"(43:1) {#if $delivery_provider.delivery_domain_allowed}",ctx:ctx});return block}function create_if_block_1$f(ctx){let settingspaneloption;let updating_toggle;let current;function settingspaneloption_toggle_binding_1(value){ctx[10](value)}let settingspaneloption_props={heading:ctx[1].signed_urls_option_name,description:ctx[1].signed_urls_option_description,toggleName:"enable-signed-urls",$$slots:{default:[create_default_slot_1$m]},$$scope:{ctx:ctx}};if(ctx[2]["enable-signed-urls"]!==void 0){settingspaneloption_props.toggle=ctx[2]["enable-signed-urls"]}settingspaneloption=new SettingsPanelOption({props:settingspaneloption_props,$$inline:true});binding_callbacks.push((()=>bind(settingspaneloption,"toggle",settingspaneloption_toggle_binding_1)));const block={c:function create(){create_component(settingspaneloption.$$.fragment)},m:function mount(target,anchor){mount_component(settingspaneloption,target,anchor);current=true},p:function update(ctx,dirty){const settingspaneloption_changes={};if(dirty&2)settingspaneloption_changes.heading=ctx[1].signed_urls_option_name;if(dirty&2)settingspaneloption_changes.description=ctx[1].signed_urls_option_description;if(dirty&4102){settingspaneloption_changes.$$scope={dirty:dirty,ctx:ctx}}if(!updating_toggle&&dirty&4){updating_toggle=true;settingspaneloption_changes.toggle=ctx[2]["enable-signed-urls"];add_flush_callback((()=>updating_toggle=false))}settingspaneloption.$set(settingspaneloption_changes)},i:function intro(local){if(current)return;transition_in(settingspaneloption.$$.fragment,local);current=true},o:function outro(local){transition_out(settingspaneloption.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(settingspaneloption,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_1$f.name,type:"if",source:'(53:2) {#if $delivery_provider.use_signed_urls_key_file_allowed && $settings[ \\"enable-delivery-domain\\" ]}',ctx:ctx});return block}function create_if_block_2$7(ctx){let settingspaneloption0;let updating_text;let t0;let settingspaneloption1;let updating_text_1;let t1;let settingspaneloption2;let updating_text_2;let current;function settingspaneloption0_text_binding(value){ctx[7](value)}let settingspaneloption0_props={heading:ctx[1].signed_urls_key_id_name,description:ctx[1].signed_urls_key_id_description,textName:"signed-urls-key-id",nested:true,first:true};if(ctx[2]["signed-urls-key-id"]!==void 0){settingspaneloption0_props.text=ctx[2]["signed-urls-key-id"]}settingspaneloption0=new SettingsPanelOption({props:settingspaneloption0_props,$$inline:true});binding_callbacks.push((()=>bind(settingspaneloption0,"text",settingspaneloption0_text_binding)));function settingspaneloption1_text_binding(value){ctx[8](value)}let settingspaneloption1_props={heading:ctx[1].signed_urls_key_file_path_name,description:ctx[1].signed_urls_key_file_path_description,textName:"signed-urls-key-file-path",placeholder:ctx[1].signed_urls_key_file_path_placeholder,nested:true};if(ctx[2]["signed-urls-key-file-path"]!==void 0){settingspaneloption1_props.text=ctx[2]["signed-urls-key-file-path"]}settingspaneloption1=new SettingsPanelOption({props:settingspaneloption1_props,$$inline:true});binding_callbacks.push((()=>bind(settingspaneloption1,"text",settingspaneloption1_text_binding)));function settingspaneloption2_text_binding(value){ctx[9](value)}let settingspaneloption2_props={heading:ctx[1].signed_urls_object_prefix_name,description:ctx[1].signed_urls_object_prefix_description,textName:"signed-urls-object-prefix",placeholder:"private/",nested:true};if(ctx[2]["signed-urls-object-prefix"]!==void 0){settingspaneloption2_props.text=ctx[2]["signed-urls-object-prefix"]}settingspaneloption2=new SettingsPanelOption({props:settingspaneloption2_props,$$inline:true});binding_callbacks.push((()=>bind(settingspaneloption2,"text",settingspaneloption2_text_binding)));const block={c:function create(){create_component(settingspaneloption0.$$.fragment);t0=space();create_component(settingspaneloption1.$$.fragment);t1=space();create_component(settingspaneloption2.$$.fragment)},m:function mount(target,anchor){mount_component(settingspaneloption0,target,anchor);insert_dev(target,t0,anchor);mount_component(settingspaneloption1,target,anchor);insert_dev(target,t1,anchor);mount_component(settingspaneloption2,target,anchor);current=true},p:function update(ctx,dirty){const settingspaneloption0_changes={};if(dirty&2)settingspaneloption0_changes.heading=ctx[1].signed_urls_key_id_name;if(dirty&2)settingspaneloption0_changes.description=ctx[1].signed_urls_key_id_description;if(!updating_text&&dirty&4){updating_text=true;settingspaneloption0_changes.text=ctx[2]["signed-urls-key-id"];add_flush_callback((()=>updating_text=false))}settingspaneloption0.$set(settingspaneloption0_changes);const settingspaneloption1_changes={};if(dirty&2)settingspaneloption1_changes.heading=ctx[1].signed_urls_key_file_path_name;if(dirty&2)settingspaneloption1_changes.description=ctx[1].signed_urls_key_file_path_description;if(dirty&2)settingspaneloption1_changes.placeholder=ctx[1].signed_urls_key_file_path_placeholder;if(!updating_text_1&&dirty&4){updating_text_1=true;settingspaneloption1_changes.text=ctx[2]["signed-urls-key-file-path"];add_flush_callback((()=>updating_text_1=false))}settingspaneloption1.$set(settingspaneloption1_changes);const settingspaneloption2_changes={};if(dirty&2)settingspaneloption2_changes.heading=ctx[1].signed_urls_object_prefix_name;if(dirty&2)settingspaneloption2_changes.description=ctx[1].signed_urls_object_prefix_description;if(!updating_text_2&&dirty&4){updating_text_2=true;settingspaneloption2_changes.text=ctx[2]["signed-urls-object-prefix"];add_flush_callback((()=>updating_text_2=false))}settingspaneloption2.$set(settingspaneloption2_changes)},i:function intro(local){if(current)return;transition_in(settingspaneloption0.$$.fragment,local);transition_in(settingspaneloption1.$$.fragment,local);transition_in(settingspaneloption2.$$.fragment,local);current=true},o:function outro(local){transition_out(settingspaneloption0.$$.fragment,local);transition_out(settingspaneloption1.$$.fragment,local);transition_out(settingspaneloption2.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(t1)}destroy_component(settingspaneloption0,detaching);destroy_component(settingspaneloption1,detaching);destroy_component(settingspaneloption2,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_2$7.name,type:"if",source:'(61:4) {#if $settings[ \\"enable-signed-urls\\" ]}',ctx:ctx});return block}function create_default_slot_1$m(ctx){let if_block_anchor;let current;let if_block=ctx[2]["enable-signed-urls"]&&create_if_block_2$7(ctx);const block={c:function create(){if(if_block)if_block.c();if_block_anchor=empty()},m:function mount(target,anchor){if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,dirty){if(ctx[2]["enable-signed-urls"]){if(if_block){if_block.p(ctx,dirty);if(dirty&4){transition_in(if_block,1)}}else{if_block=create_if_block_2$7(ctx);if_block.c();transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$m.name,type:"slot",source:'(54:3) <SettingsPanelOption heading={$delivery_provider.signed_urls_option_name} description={$delivery_provider.signed_urls_option_description} toggleName=\\"enable-signed-urls\\" bind:toggle={$settings[\\"enable-signed-urls\\"]} >',ctx:ctx});return block}function create_default_slot$y(ctx){let deliverysettingsheadingrow;let t0;let settingsvalidationstatusrow;let t1;let settingspaneloption0;let updating_toggle;let t2;let t3;let settingspaneloption1;let updating_toggle_1;let current;deliverysettingsheadingrow=new DeliverySettingsHeadingRow({$$inline:true});settingsvalidationstatusrow=new SettingsValidationStatusRow({props:{section:"delivery"},$$inline:true});function settingspaneloption0_toggle_binding(value){ctx[4](value)}let settingspaneloption0_props={heading:ctx[0].rewrite_media_urls,description:ctx[1].rewrite_media_urls_desc,toggleName:"serve-from-s3"};if(ctx[2]["serve-from-s3"]!==void 0){settingspaneloption0_props.toggle=ctx[2]["serve-from-s3"]}settingspaneloption0=new SettingsPanelOption({props:settingspaneloption0_props,$$inline:true});binding_callbacks.push((()=>bind(settingspaneloption0,"toggle",settingspaneloption0_toggle_binding)));let if_block=ctx[1].delivery_domain_allowed&&create_if_block$p(ctx);function settingspaneloption1_toggle_binding(value){ctx[11](value)}let settingspaneloption1_props={heading:ctx[0].force_https,description:ctx[0].force_https_desc,toggleName:"force-https"};if(ctx[2]["force-https"]!==void 0){settingspaneloption1_props.toggle=ctx[2]["force-https"]}settingspaneloption1=new SettingsPanelOption({props:settingspaneloption1_props,$$inline:true});binding_callbacks.push((()=>bind(settingspaneloption1,"toggle",settingspaneloption1_toggle_binding)));const block={c:function create(){create_component(deliverysettingsheadingrow.$$.fragment);t0=space();create_component(settingsvalidationstatusrow.$$.fragment);t1=space();create_component(settingspaneloption0.$$.fragment);t2=space();if(if_block)if_block.c();t3=space();create_component(settingspaneloption1.$$.fragment)},m:function mount(target,anchor){mount_component(deliverysettingsheadingrow,target,anchor);insert_dev(target,t0,anchor);mount_component(settingsvalidationstatusrow,target,anchor);insert_dev(target,t1,anchor);mount_component(settingspaneloption0,target,anchor);insert_dev(target,t2,anchor);if(if_block)if_block.m(target,anchor);insert_dev(target,t3,anchor);mount_component(settingspaneloption1,target,anchor);current=true},p:function update(ctx,dirty){const settingspaneloption0_changes={};if(dirty&1)settingspaneloption0_changes.heading=ctx[0].rewrite_media_urls;if(dirty&2)settingspaneloption0_changes.description=ctx[1].rewrite_media_urls_desc;if(!updating_toggle&&dirty&4){updating_toggle=true;settingspaneloption0_changes.toggle=ctx[2]["serve-from-s3"];add_flush_callback((()=>updating_toggle=false))}settingspaneloption0.$set(settingspaneloption0_changes);if(ctx[1].delivery_domain_allowed){if(if_block){if_block.p(ctx,dirty);if(dirty&2){transition_in(if_block,1)}}else{if_block=create_if_block$p(ctx);if_block.c();transition_in(if_block,1);if_block.m(t3.parentNode,t3)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}const settingspaneloption1_changes={};if(dirty&1)settingspaneloption1_changes.heading=ctx[0].force_https;if(dirty&1)settingspaneloption1_changes.description=ctx[0].force_https_desc;if(!updating_toggle_1&&dirty&4){updating_toggle_1=true;settingspaneloption1_changes.toggle=ctx[2]["force-https"];add_flush_callback((()=>updating_toggle_1=false))}settingspaneloption1.$set(settingspaneloption1_changes)},i:function intro(local){if(current)return;transition_in(deliverysettingsheadingrow.$$.fragment,local);transition_in(settingsvalidationstatusrow.$$.fragment,local);transition_in(settingspaneloption0.$$.fragment,local);transition_in(if_block);transition_in(settingspaneloption1.$$.fragment,local);current=true},o:function outro(local){transition_out(deliverysettingsheadingrow.$$.fragment,local);transition_out(settingsvalidationstatusrow.$$.fragment,local);transition_out(settingspaneloption0.$$.fragment,local);transition_out(if_block);transition_out(settingspaneloption1.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(t1);detach_dev(t2);detach_dev(t3)}destroy_component(deliverysettingsheadingrow,detaching);destroy_component(settingsvalidationstatusrow,detaching);destroy_component(settingspaneloption0,detaching);if(if_block)if_block.d(detaching);destroy_component(settingspaneloption1,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$y.name,type:"slot",source:'(33:0) <Panel name=\\"settings\\" heading={$strings.delivery_settings_title} helpKey=\\"delivery-provider\\">',ctx:ctx});return block}function create_fragment$T(ctx){let panel;let current;panel=new Panel({props:{name:"settings",heading:ctx[0].delivery_settings_title,helpKey:"delivery-provider",$$slots:{default:[create_default_slot$y]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panel.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(panel,target,anchor);current=true},p:function update(ctx,[dirty]){const panel_changes={};if(dirty&1)panel_changes.heading=ctx[0].delivery_settings_title;if(dirty&4103){panel_changes.$$scope={dirty:dirty,ctx:ctx}}panel.$set(panel_changes)},i:function intro(local){if(current)return;transition_in(panel.$$.fragment,local);current=true},o:function outro(local){transition_out(panel.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panel,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$T.name,type:"component",source:"",ctx:ctx});return block}function instance$T($$self,$$props,$$invalidate){let $strings;let $delivery_provider;let $settings;validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(0,$strings=$$value)));validate_store(delivery_provider,"delivery_provider");component_subscribe($$self,delivery_provider,($$value=>$$invalidate(1,$delivery_provider=$$value)));validate_store(settings,"settings");component_subscribe($$self,settings,($$value=>$$invalidate(2,$settings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("DeliverySettingsPanel",slots,[]);function domainValidator(domain){const domainPattern=/[^a-z0-9.-]/;let message="";if(domain.trim().length===0){message=$strings.domain_blank}else if(true===domainPattern.test(domain)){message=$strings.domain_invalid_content}else if(domain.length<3){message=$strings.domain_too_short}return message}const writable_props=[];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<DeliverySettingsPanel> was created with unknown prop '${key}'`)}));function settingspaneloption0_toggle_binding(value){if($$self.$$.not_equal($settings["serve-from-s3"],value)){$settings["serve-from-s3"]=value;settings.set($settings)}}function settingspaneloption_toggle_binding(value){if($$self.$$.not_equal($settings["enable-delivery-domain"],value)){$settings["enable-delivery-domain"]=value;settings.set($settings)}}function settingspaneloption_text_binding(value){if($$self.$$.not_equal($settings["delivery-domain"],value)){$settings["delivery-domain"]=value;settings.set($settings)}}function settingspaneloption0_text_binding(value){if($$self.$$.not_equal($settings["signed-urls-key-id"],value)){$settings["signed-urls-key-id"]=value;settings.set($settings)}}function settingspaneloption1_text_binding(value){if($$self.$$.not_equal($settings["signed-urls-key-file-path"],value)){$settings["signed-urls-key-file-path"]=value;settings.set($settings)}}function settingspaneloption2_text_binding(value){if($$self.$$.not_equal($settings["signed-urls-object-prefix"],value)){$settings["signed-urls-object-prefix"]=value;settings.set($settings)}}function settingspaneloption_toggle_binding_1(value){if($$self.$$.not_equal($settings["enable-signed-urls"],value)){$settings["enable-signed-urls"]=value;settings.set($settings)}}function settingspaneloption1_toggle_binding(value){if($$self.$$.not_equal($settings["force-https"],value)){$settings["force-https"]=value;settings.set($settings)}}$$self.$capture_state=()=>({delivery_provider:delivery_provider,settings:settings,strings:strings,Panel:Panel,DeliverySettingsHeadingRow:DeliverySettingsHeadingRow,SettingsValidationStatusRow:SettingsValidationStatusRow,SettingsPanelOption:SettingsPanelOption,domainValidator:domainValidator,$strings:$strings,$delivery_provider:$delivery_provider,$settings:$settings});return[$strings,$delivery_provider,$settings,domainValidator,settingspaneloption0_toggle_binding,settingspaneloption_toggle_binding,settingspaneloption_text_binding,settingspaneloption0_text_binding,settingspaneloption1_text_binding,settingspaneloption2_text_binding,settingspaneloption_toggle_binding_1,settingspaneloption1_toggle_binding]}class DeliverySettingsPanel extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$T,create_fragment$T,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"DeliverySettingsPanel",options:options,id:create_fragment$T.name})}}function create_default_slot$x(ctx){let deliverysettingspanel;let current;deliverysettingspanel=new DeliverySettingsPanel({$$inline:true});const block={c:function create(){create_component(deliverysettingspanel.$$.fragment)},m:function mount(target,anchor){mount_component(deliverysettingspanel,target,anchor);current=true},i:function intro(local){if(current)return;transition_in(deliverysettingspanel.$$.fragment,local);current=true},o:function outro(local){transition_out(deliverysettingspanel.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(deliverysettingspanel,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$x.name,type:"slot",source:'(6:0) <SubPage name=\\"delivery-settings\\" route=\\"/media/delivery\\">',ctx:ctx});return block}function create_fragment$S(ctx){let subpage;let current;subpage=new SubPage({props:{name:"delivery-settings",route:"/media/delivery",$$slots:{default:[create_default_slot$x]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(subpage.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(subpage,target,anchor);current=true},p:function update(ctx,[dirty]){const subpage_changes={};if(dirty&1){subpage_changes.$$scope={dirty:dirty,ctx:ctx}}subpage.$set(subpage_changes)},i:function intro(local){if(current)return;transition_in(subpage.$$.fragment,local);current=true},o:function outro(local){transition_out(subpage.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(subpage,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$S.name,type:"component",source:"",ctx:ctx});return block}function instance$S($$self,$$props,$$invalidate){let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("DeliverySettingsSubPage",slots,[]);const writable_props=[];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<DeliverySettingsSubPage> was created with unknown prop '${key}'`)}));$$self.$capture_state=()=>({SubPage:SubPage,DeliverySettingsPanel:DeliverySettingsPanel});return[]}class DeliverySettingsSubPage extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$S,create_fragment$S,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"DeliverySettingsSubPage",options:options,id:create_fragment$S.name})}}function create_fragment$R(ctx){let storagesettingssubpage;let t;let deliverysettingssubpage;let current;storagesettingssubpage=new StorageSettingsSubPage({$$inline:true});deliverysettingssubpage=new DeliverySettingsSubPage({$$inline:true});const block={c:function create(){create_component(storagesettingssubpage.$$.fragment);t=space();create_component(deliverysettingssubpage.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(storagesettingssubpage,target,anchor);insert_dev(target,t,anchor);mount_component(deliverysettingssubpage,target,anchor);current=true},p:noop,i:function intro(local){if(current)return;transition_in(storagesettingssubpage.$$.fragment,local);transition_in(deliverysettingssubpage.$$.fragment,local);current=true},o:function outro(local){transition_out(storagesettingssubpage.$$.fragment,local);transition_out(deliverysettingssubpage.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t)}destroy_component(storagesettingssubpage,detaching);destroy_component(deliverysettingssubpage,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$R.name,type:"component",source:"",ctx:ctx});return block}function instance$R($$self,$$props,$$invalidate){let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("MediaSettings",slots,[]);let{params:params={}}=$$props;const _params=params;const writable_props=["params"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<MediaSettings> was created with unknown prop '${key}'`)}));$$self.$$set=$$props=>{if("params"in $$props)$$invalidate(0,params=$$props.params)};$$self.$capture_state=()=>({StorageSettingsSubPage:StorageSettingsSubPage,DeliverySettingsSubPage:DeliverySettingsSubPage,params:params,_params:_params});$$self.$inject_state=$$props=>{if("params"in $$props)$$invalidate(0,params=$$props.params)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[params]}class MediaSettings extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$R,create_fragment$R,safe_not_equal,{params:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"MediaSettings",options:options,id:create_fragment$R.name})}get params(){throw new Error("<MediaSettings>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set params(value){throw new Error("<MediaSettings>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$K="ui/components/UrlPreview.svelte";function get_each_context$b(ctx,list,i){const child_ctx=ctx.slice();child_ctx[7]=list[i];return child_ctx}function create_if_block$o(ctx){let panel;let current;panel=new Panel({props:{name:"url-preview",heading:ctx[1].url_preview_title,$$slots:{default:[create_default_slot$w]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panel.$$.fragment)},m:function mount(target,anchor){mount_component(panel,target,anchor);current=true},p:function update(ctx,dirty){const panel_changes={};if(dirty&2)panel_changes.heading=ctx[1].url_preview_title;if(dirty&1027){panel_changes.$$scope={dirty:dirty,ctx:ctx}}panel.$set(panel_changes)},i:function intro(local){if(current)return;transition_in(panel.$$.fragment,local);current=true},o:function outro(local){transition_out(panel.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panel,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$o.name,type:"if",source:"(43:0) {#if parts.length > 0}",ctx:ctx});return block}function create_default_slot_2$h(ctx){let p;let t_value=ctx[1].url_preview_desc+"";let t;const block={c:function create(){p=element("p");t=text(t_value);add_location(p,file$K,45,3,1186)},m:function mount(target,anchor){insert_dev(target,p,anchor);append_dev(p,t)},p:function update(ctx,dirty){if(dirty&2&&t_value!==(t_value=ctx[1].url_preview_desc+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_2$h.name,type:"slot",source:'(45:2) <PanelRow class=\\"desc\\">',ctx:ctx});return block}function create_each_block$b(key_1,ctx){let div;let dt;let t0_value=ctx[7].title+"";let t0;let t1;let dd;let t2_value=ctx[7].example+"";let t2;let t3;let div_data_key_value;let div_transition;let current;const block={key:key_1,first:null,c:function create(){div=element("div");dt=element("dt");t0=text(t0_value);t1=space();dd=element("dd");t2=text(t2_value);t3=space();add_location(dt,file$K,51,6,1371);add_location(dd,file$K,52,6,1399);attr_dev(div,"data-key",div_data_key_value=ctx[7].key);add_location(div,file$K,50,5,1322);this.first=div},m:function mount(target,anchor){insert_dev(target,div,anchor);append_dev(div,dt);append_dev(dt,t0);append_dev(div,t1);append_dev(div,dd);append_dev(dd,t2);append_dev(div,t3);current=true},p:function update(new_ctx,dirty){ctx=new_ctx;if((!current||dirty&1)&&t0_value!==(t0_value=ctx[7].title+""))set_data_dev(t0,t0_value);if((!current||dirty&1)&&t2_value!==(t2_value=ctx[7].example+""))set_data_dev(t2,t2_value);if(!current||dirty&1&&div_data_key_value!==(div_data_key_value=ctx[7].key)){attr_dev(div,"data-key",div_data_key_value)}},i:function intro(local){if(current)return;if(local){add_render_callback((()=>{if(!current)return;if(!div_transition)div_transition=create_bidirectional_transition(div,scale,{},true);div_transition.run(1)}))}current=true},o:function outro(local){if(local){if(!div_transition)div_transition=create_bidirectional_transition(div,scale,{},false);div_transition.run(0)}current=false},d:function destroy(detaching){if(detaching){detach_dev(div)}if(detaching&&div_transition)div_transition.end()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_each_block$b.name,type:"each",source:"(50:4) {#each parts as part (part.title)}",ctx:ctx});return block}function create_default_slot_1$l(ctx){let dl;let each_blocks=[];let each_1_lookup=new Map;let current;let each_value=ensure_array_like_dev(ctx[0]);const get_key=ctx=>ctx[7].title;validate_each_keys(ctx,each_value,get_each_context$b,get_key);for(let i=0;i<each_value.length;i+=1){let child_ctx=get_each_context$b(ctx,each_value,i);let key=get_key(child_ctx);each_1_lookup.set(key,each_blocks[i]=create_each_block$b(key,child_ctx))}const block={c:function create(){dl=element("dl");for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].c()}add_location(dl,file$K,48,3,1273)},m:function mount(target,anchor){insert_dev(target,dl,anchor);for(let i=0;i<each_blocks.length;i+=1){if(each_blocks[i]){each_blocks[i].m(dl,null)}}current=true},p:function update(ctx,dirty){if(dirty&1){each_value=ensure_array_like_dev(ctx[0]);group_outros();validate_each_keys(ctx,each_value,get_each_context$b,get_key);each_blocks=update_keyed_each(each_blocks,dirty,get_key,1,ctx,each_value,each_1_lookup,dl,outro_and_destroy_block,create_each_block$b,null,get_each_context$b);check_outros()}},i:function intro(local){if(current)return;for(let i=0;i<each_value.length;i+=1){transition_in(each_blocks[i])}current=true},o:function outro(local){for(let i=0;i<each_blocks.length;i+=1){transition_out(each_blocks[i])}current=false},d:function destroy(detaching){if(detaching){detach_dev(dl)}for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].d()}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$l.name,type:"slot",source:'(48:2) <PanelRow class=\\"body flex-row\\">',ctx:ctx});return block}function create_default_slot$w(ctx){let panelrow0;let t;let panelrow1;let current;panelrow0=new PanelRow({props:{class:"desc",$$slots:{default:[create_default_slot_2$h]},$$scope:{ctx:ctx}},$$inline:true});panelrow1=new PanelRow({props:{class:"body flex-row",$$slots:{default:[create_default_slot_1$l]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow0.$$.fragment);t=space();create_component(panelrow1.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow0,target,anchor);insert_dev(target,t,anchor);mount_component(panelrow1,target,anchor);current=true},p:function update(ctx,dirty){const panelrow0_changes={};if(dirty&1026){panelrow0_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow0.$set(panelrow0_changes);const panelrow1_changes={};if(dirty&1025){panelrow1_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow1.$set(panelrow1_changes)},i:function intro(local){if(current)return;transition_in(panelrow0.$$.fragment,local);transition_in(panelrow1.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow0.$$.fragment,local);transition_out(panelrow1.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t)}destroy_component(panelrow0,detaching);destroy_component(panelrow1,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$w.name,type:"slot",source:'(44:1) <Panel name=\\"url-preview\\" heading={$strings.url_preview_title}>',ctx:ctx});return block}function create_fragment$Q(ctx){let if_block_anchor;let current;let if_block=ctx[0].length>0&&create_if_block$o(ctx);const block={c:function create(){if(if_block)if_block.c();if_block_anchor=empty()},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,[dirty]){if(ctx[0].length>0){if(if_block){if_block.p(ctx,dirty);if(dirty&1){transition_in(if_block,1)}}else{if_block=create_if_block$o(ctx);if_block.c();transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$Q.name,type:"component",source:"",ctx:ctx});return block}function instance$Q($$self,$$props,$$invalidate){let isTemporaryUrl;let $settings;let $settings_changed;let $urls;let $strings;validate_store(settings,"settings");component_subscribe($$self,settings,($$value=>$$invalidate(2,$settings=$$value)));validate_store(settings_changed,"settings_changed");component_subscribe($$self,settings_changed,($$value=>$$invalidate(3,$settings_changed=$$value)));validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(4,$urls=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(1,$strings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("UrlPreview",slots,[]);let parts=$urls.url_parts;async function temporaryUrl(urls,settingsChanged,settings){if(settingsChanged){const response=await api.post("url-preview",{settings:settings});if(response.hasOwnProperty("url_parts")){$$invalidate(0,parts=response.url_parts);return true}}$$invalidate(0,parts=urls.url_parts);return false}const writable_props=[];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<UrlPreview> was created with unknown prop '${key}'`)}));$$self.$capture_state=()=>({scale:scale,api:api,settings:settings,settings_changed:settings_changed,strings:strings,urls:urls,Panel:Panel,PanelRow:PanelRow,parts:parts,temporaryUrl:temporaryUrl,isTemporaryUrl:isTemporaryUrl,$settings:$settings,$settings_changed:$settings_changed,$urls:$urls,$strings:$strings});$$self.$inject_state=$$props=>{if("parts"in $$props)$$invalidate(0,parts=$$props.parts);if("isTemporaryUrl"in $$props)isTemporaryUrl=$$props.isTemporaryUrl};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty&28){isTemporaryUrl=temporaryUrl($urls,$settings_changed,$settings)}};return[parts,$strings,$settings,$settings_changed,$urls]}class UrlPreview extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$Q,create_fragment$Q,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"UrlPreview",options:options,id:create_fragment$Q.name})}}function scrollNotificationsIntoView(){const element=document.getElementById("notifications");if(element){element.scrollIntoView({behavior:"smooth",block:"start"})}}const file$J="ui/components/Footer.svelte";function create_if_block$n(ctx){let div1;let div0;let button0;let t;let button1;let div1_transition;let current;button0=new Button({props:{outline:true,$$slots:{default:[create_default_slot_1$k]},$$scope:{ctx:ctx}},$$inline:true});button0.$on("click",ctx[4]);button1=new Button({props:{primary:true,disabled:ctx[1],$$slots:{default:[create_default_slot$v]},$$scope:{ctx:ctx}},$$inline:true});button1.$on("click",ctx[5]);const block={c:function create(){div1=element("div");div0=element("div");create_component(button0.$$.fragment);t=space();create_component(button1.$$.fragment);attr_dev(div0,"class","buttons");add_location(div0,file$J,69,2,1762);attr_dev(div1,"class","fixed-cta-block");add_location(div1,file$J,68,1,1713)},m:function mount(target,anchor){insert_dev(target,div1,anchor);append_dev(div1,div0);mount_component(button0,div0,null);append_dev(div0,t);mount_component(button1,div0,null);current=true},p:function update(ctx,dirty){const button0_changes={};if(dirty&2056){button0_changes.$$scope={dirty:dirty,ctx:ctx}}button0.$set(button0_changes);const button1_changes={};if(dirty&2)button1_changes.disabled=ctx[1];if(dirty&2056){button1_changes.$$scope={dirty:dirty,ctx:ctx}}button1.$set(button1_changes)},i:function intro(local){if(current)return;transition_in(button0.$$.fragment,local);transition_in(button1.$$.fragment,local);if(local){add_render_callback((()=>{if(!current)return;if(!div1_transition)div1_transition=create_bidirectional_transition(div1,slide,{},true);div1_transition.run(1)}))}current=true},o:function outro(local){transition_out(button0.$$.fragment,local);transition_out(button1.$$.fragment,local);if(local){if(!div1_transition)div1_transition=create_bidirectional_transition(div1,slide,{},false);div1_transition.run(0)}current=false},d:function destroy(detaching){if(detaching){detach_dev(div1)}destroy_component(button0);destroy_component(button1);if(detaching&&div1_transition)div1_transition.end()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$n.name,type:"if",source:"(68:0) {#if $settingsChangedStore}",ctx:ctx});return block}function create_default_slot_1$k(ctx){let t_value=ctx[3].cancel_button+"";let t;const block={c:function create(){t=text(t_value)},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty&8&&t_value!==(t_value=ctx[3].cancel_button+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$k.name,type:"slot",source:"(71:3) <Button outline on:click={handleCancel}>",ctx:ctx});return block}function create_default_slot$v(ctx){let t_value=ctx[3].save_changes+"";let t;const block={c:function create(){t=text(t_value)},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty&8&&t_value!==(t_value=ctx[3].save_changes+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$v.name,type:"slot",source:"(72:3) <Button primary on:click={handleSave} {disabled}>",ctx:ctx});return block}function create_fragment$P(ctx){let if_block_anchor;let current;let if_block=ctx[2]&&create_if_block$n(ctx);const block={c:function create(){if(if_block)if_block.c();if_block_anchor=empty()},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,[dirty]){if(ctx[2]){if(if_block){if_block.p(ctx,dirty);if(dirty&4){transition_in(if_block,1)}}else{if_block=create_if_block$n(ctx);if_block.c();transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$P.name,type:"component",source:"",ctx:ctx});return block}function instance$P($$self,$$props,$$invalidate){let disabled;let $revalidatingSettings;let $validationErrors;let $settingsChangedStore,$$unsubscribe_settingsChangedStore=noop,$$subscribe_settingsChangedStore=()=>($$unsubscribe_settingsChangedStore(),$$unsubscribe_settingsChangedStore=subscribe(settingsChangedStore,($$value=>$$invalidate(2,$settingsChangedStore=$$value))),settingsChangedStore);let $strings;validate_store(revalidatingSettings,"revalidatingSettings");component_subscribe($$self,revalidatingSettings,($$value=>$$invalidate(9,$revalidatingSettings=$$value)));validate_store(validationErrors,"validationErrors");component_subscribe($$self,validationErrors,($$value=>$$invalidate(8,$validationErrors=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(3,$strings=$$value)));$$self.$$.on_destroy.push((()=>$$unsubscribe_settingsChangedStore()));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("Footer",slots,[]);const dispatch=createEventDispatcher();let{settingsStore:settingsStore=settings}=$$props;let{settingsChangedStore:settingsChangedStore=settings_changed}=$$props;validate_store(settingsChangedStore,"settingsChangedStore");$$subscribe_settingsChangedStore();let saving=false;validationErrors.set(new Map);function handleCancel(){settingsStore.reset()}async function handleSave(){$$invalidate(7,saving=true);state.pausePeriodicFetch();const result=await settingsStore.save();set_store_value(revalidatingSettings,$revalidatingSettings=true,$revalidatingSettings);const statePromise=state.resumePeriodicFetch();if(result.hasOwnProperty("saved")&&result.hasOwnProperty("changed_settings")){dispatch("routeEvent",{event:"settings.save",data:result})}scrollNotificationsIntoView();$$invalidate(7,saving=false);await statePromise;set_store_value(revalidatingSettings,$revalidatingSettings=false,$revalidatingSettings)}onDestroy((()=>handleCancel()));const writable_props=["settingsStore","settingsChangedStore"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<Footer> was created with unknown prop '${key}'`)}));$$self.$$set=$$props=>{if("settingsStore"in $$props)$$invalidate(6,settingsStore=$$props.settingsStore);if("settingsChangedStore"in $$props)$$subscribe_settingsChangedStore($$invalidate(0,settingsChangedStore=$$props.settingsChangedStore))};$$self.$capture_state=()=>({createEventDispatcher:createEventDispatcher,onDestroy:onDestroy,slide:slide,revalidatingSettings:revalidatingSettings,settings_changed:settings_changed,settings:settings,strings:strings,state:state,validationErrors:validationErrors,scrollNotificationsIntoView:scrollNotificationsIntoView,Button:Button,dispatch:dispatch,settingsStore:settingsStore,settingsChangedStore:settingsChangedStore,saving:saving,handleCancel:handleCancel,handleSave:handleSave,disabled:disabled,$revalidatingSettings:$revalidatingSettings,$validationErrors:$validationErrors,$settingsChangedStore:$settingsChangedStore,$strings:$strings});$$self.$inject_state=$$props=>{if("settingsStore"in $$props)$$invalidate(6,settingsStore=$$props.settingsStore);if("settingsChangedStore"in $$props)$$subscribe_settingsChangedStore($$invalidate(0,settingsChangedStore=$$props.settingsChangedStore));if("saving"in $$props)$$invalidate(7,saving=$$props.saving);if("disabled"in $$props)$$invalidate(1,disabled=$$props.disabled)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty&384){$$invalidate(1,disabled=saving||$validationErrors.size>0)}};return[settingsChangedStore,disabled,$settingsChangedStore,$strings,handleCancel,handleSave,settingsStore,saving,$validationErrors]}class Footer extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$P,create_fragment$P,safe_not_equal,{settingsStore:6,settingsChangedStore:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"Footer",options:options,id:create_fragment$P.name})}get settingsStore(){throw new Error("<Footer>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set settingsStore(value){throw new Error("<Footer>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get settingsChangedStore(){throw new Error("<Footer>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set settingsChangedStore(value){throw new Error("<Footer>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}function create_if_block_1$e(ctx){let notifications;let t0;let subnav;let t1;let subpages;let t2;let urlpreview;let current;notifications=new Notifications({props:{tab:ctx[0]},$$inline:true});subnav=new SubNav({props:{name:ctx[0],items:ctx[3],subpage:true},$$inline:true});subpages=new SubPages({props:{name:ctx[0],routes:ctx[4]},$$inline:true});urlpreview=new UrlPreview({$$inline:true});const block={c:function create(){create_component(notifications.$$.fragment);t0=space();create_component(subnav.$$.fragment);t1=space();create_component(subpages.$$.fragment);t2=space();create_component(urlpreview.$$.fragment)},m:function mount(target,anchor){mount_component(notifications,target,anchor);insert_dev(target,t0,anchor);mount_component(subnav,target,anchor);insert_dev(target,t1,anchor);mount_component(subpages,target,anchor);insert_dev(target,t2,anchor);mount_component(urlpreview,target,anchor);current=true},p:function update(ctx,dirty){const notifications_changes={};if(dirty&1)notifications_changes.tab=ctx[0];notifications.$set(notifications_changes);const subnav_changes={};if(dirty&1)subnav_changes.name=ctx[0];if(dirty&8)subnav_changes.items=ctx[3];subnav.$set(subnav_changes);const subpages_changes={};if(dirty&1)subpages_changes.name=ctx[0];subpages.$set(subpages_changes)},i:function intro(local){if(current)return;transition_in(notifications.$$.fragment,local);transition_in(subnav.$$.fragment,local);transition_in(subpages.$$.fragment,local);transition_in(urlpreview.$$.fragment,local);current=true},o:function outro(local){transition_out(notifications.$$.fragment,local);transition_out(subnav.$$.fragment,local);transition_out(subpages.$$.fragment,local);transition_out(urlpreview.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(t1);detach_dev(t2)}destroy_component(notifications,detaching);destroy_component(subnav,detaching);destroy_component(subpages,detaching);destroy_component(urlpreview,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_1$e.name,type:"if",source:"(59:1) {#if render}",ctx:ctx});return block}function create_default_slot$u(ctx){let if_block_anchor;let current;let if_block=ctx[2]&&create_if_block_1$e(ctx);const block={c:function create(){if(if_block)if_block.c();if_block_anchor=empty()},m:function mount(target,anchor){if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,dirty){if(ctx[2]){if(if_block){if_block.p(ctx,dirty);if(dirty&4){transition_in(if_block,1)}}else{if_block=create_if_block_1$e(ctx);if_block.c();transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$u.name,type:"slot",source:"(58:0) <Page {name} on:routeEvent>",ctx:ctx});return block}function create_if_block$m(ctx){let switch_instance;let switch_instance_anchor;let current;var switch_value=ctx[1];function switch_props(ctx,dirty){return{$$inline:true}}if(switch_value){switch_instance=construct_svelte_component_dev(switch_value,switch_props())}const block={c:function create(){if(switch_instance)create_component(switch_instance.$$.fragment);switch_instance_anchor=empty()},m:function mount(target,anchor){if(switch_instance)mount_component(switch_instance,target,anchor);insert_dev(target,switch_instance_anchor,anchor);current=true},p:function update(ctx,dirty){if(dirty&2&&switch_value!==(switch_value=ctx[1])){if(switch_instance){group_outros();const old_component=switch_instance;transition_out(old_component.$$.fragment,1,0,(()=>{destroy_component(old_component,1)}));check_outros()}if(switch_value){switch_instance=construct_svelte_component_dev(switch_value,switch_props());create_component(switch_instance.$$.fragment);transition_in(switch_instance.$$.fragment,1);mount_component(switch_instance,switch_instance_anchor.parentNode,switch_instance_anchor)}else{switch_instance=null}}},i:function intro(local){if(current)return;if(switch_instance)transition_in(switch_instance.$$.fragment,local);current=true},o:function outro(local){if(switch_instance)transition_out(switch_instance.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(switch_instance_anchor)}if(switch_instance)destroy_component(switch_instance,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$m.name,type:"if",source:"(67:0) {#if sidebar && render}",ctx:ctx});return block}function create_fragment$O(ctx){let page;let t0;let t1;let footer;let current;page=new Page({props:{name:ctx[0],$$slots:{default:[create_default_slot$u]},$$scope:{ctx:ctx}},$$inline:true});page.$on("routeEvent",ctx[8]);let if_block=ctx[1]&&ctx[2]&&create_if_block$m(ctx);footer=new Footer({$$inline:true});footer.$on("routeEvent",ctx[9]);const block={c:function create(){create_component(page.$$.fragment);t0=space();if(if_block)if_block.c();t1=space();create_component(footer.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(page,target,anchor);insert_dev(target,t0,anchor);if(if_block)if_block.m(target,anchor);insert_dev(target,t1,anchor);mount_component(footer,target,anchor);current=true},p:function update(ctx,[dirty]){const page_changes={};if(dirty&1)page_changes.name=ctx[0];if(dirty&4109){page_changes.$$scope={dirty:dirty,ctx:ctx}}page.$set(page_changes);if(ctx[1]&&ctx[2]){if(if_block){if_block.p(ctx,dirty);if(dirty&6){transition_in(if_block,1)}}else{if_block=create_if_block$m(ctx);if_block.c();transition_in(if_block,1);if_block.m(t1.parentNode,t1)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(page.$$.fragment,local);transition_in(if_block);transition_in(footer.$$.fragment,local);current=true},o:function outro(local){transition_out(page.$$.fragment,local);transition_out(if_block);transition_out(footer.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(t1)}destroy_component(page,detaching);if(if_block)if_block.d(detaching);destroy_component(footer,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$O.name,type:"component",source:"",ctx:ctx});return block}function instance$O($$self,$$props,$$invalidate){let items;let $is_plugin_setup;let $settings_validation;let $strings;validate_store(is_plugin_setup,"is_plugin_setup");component_subscribe($$self,is_plugin_setup,($$value=>$$invalidate(10,$is_plugin_setup=$$value)));validate_store(settings_validation,"settings_validation");component_subscribe($$self,settings_validation,($$value=>$$invalidate(6,$settings_validation=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(7,$strings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("MediaPage",slots,[]);let{name:name="media"}=$$props;let{params:params={}}=$$props;const _params=params;let sidebar=null;let render=false;if(hasContext("sidebar")){sidebar=getContext("sidebar")}setContext("settingsLocked",settingsLocked);const routes={"*":MediaSettings};onMount((()=>{if($is_plugin_setup){$$invalidate(2,render=true)}}));const writable_props=["name","params"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<MediaPage> was created with unknown prop '${key}'`)}));function routeEvent_handler(event){bubble.call(this,$$self,event)}function routeEvent_handler_1(event){bubble.call(this,$$self,event)}$$self.$$set=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name);if("params"in $$props)$$invalidate(5,params=$$props.params)};$$self.$capture_state=()=>({getContext:getContext,hasContext:hasContext,onMount:onMount,setContext:setContext,is_plugin_setup:is_plugin_setup,settingsLocked:settingsLocked,strings:strings,settings_validation:settings_validation,Page:Page,Notifications:Notifications,SubNav:SubNav,SubPages:SubPages,MediaSettings:MediaSettings,UrlPreview:UrlPreview,Footer:Footer,name:name,params:params,_params:_params,sidebar:sidebar,render:render,routes:routes,items:items,$is_plugin_setup:$is_plugin_setup,$settings_validation:$settings_validation,$strings:$strings});$$self.$inject_state=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name);if("params"in $$props)$$invalidate(5,params=$$props.params);if("sidebar"in $$props)$$invalidate(1,sidebar=$$props.sidebar);if("render"in $$props)$$invalidate(2,render=$$props.render);if("items"in $$props)$$invalidate(3,items=$$props.items)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty&192){$$invalidate(3,items=[{route:"/",title:()=>$strings.storage_settings_title,noticeIcon:$settings_validation["storage"].type},{route:"/media/delivery",title:()=>$strings.delivery_settings_title,noticeIcon:$settings_validation["delivery"].type}])}};return[name,sidebar,render,items,routes,params,$settings_validation,$strings,routeEvent_handler,routeEvent_handler_1]}class MediaPage extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$O,create_fragment$O,safe_not_equal,{name:0,params:5});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"MediaPage",options:options,id:create_fragment$O.name})}get name(){throw new Error("<MediaPage>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set name(value){throw new Error("<MediaPage>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get params(){throw new Error("<MediaPage>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set params(value){throw new Error("<MediaPage>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}function create_default_slot$t(ctx){let notifications;let t0;let subnav;let t1;let subpages;let current;notifications=new Notifications({props:{tab:"media",tabParent:"media"},$$inline:true});subnav=new SubNav({props:{name:ctx[0],items:ctx[1],progress:true},$$inline:true});subpages=new SubPages({props:{name:ctx[0],prefix:prefix,routes:ctx[2]},$$inline:true});subpages.$on("routeEvent",ctx[4]);const block={c:function create(){create_component(notifications.$$.fragment);t0=space();create_component(subnav.$$.fragment);t1=space();create_component(subpages.$$.fragment)},m:function mount(target,anchor){mount_component(notifications,target,anchor);insert_dev(target,t0,anchor);mount_component(subnav,target,anchor);insert_dev(target,t1,anchor);mount_component(subpages,target,anchor);current=true},p:function update(ctx,dirty){const subnav_changes={};if(dirty&1)subnav_changes.name=ctx[0];if(dirty&2)subnav_changes.items=ctx[1];subnav.$set(subnav_changes);const subpages_changes={};if(dirty&1)subpages_changes.name=ctx[0];if(dirty&4)subpages_changes.routes=ctx[2];subpages.$set(subpages_changes)},i:function intro(local){if(current)return;transition_in(notifications.$$.fragment,local);transition_in(subnav.$$.fragment,local);transition_in(subpages.$$.fragment,local);current=true},o:function outro(local){transition_out(notifications.$$.fragment,local);transition_out(subnav.$$.fragment,local);transition_out(subpages.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(t1)}destroy_component(notifications,detaching);destroy_component(subnav,detaching);destroy_component(subpages,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$t.name,type:"slot",source:"(46:0) <Page {name} subpage on:routeEvent>",ctx:ctx});return block}function create_fragment$N(ctx){let page;let current;page=new Page({props:{name:ctx[0],subpage:true,$$slots:{default:[create_default_slot$t]},$$scope:{ctx:ctx}},$$inline:true});page.$on("routeEvent",ctx[5]);const block={c:function create(){create_component(page.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(page,target,anchor);current=true},p:function update(ctx,[dirty]){const page_changes={};if(dirty&1)page_changes.name=ctx[0];if(dirty&1031){page_changes.$$scope={dirty:dirty,ctx:ctx}}page.$set(page_changes)},i:function intro(local){if(current)return;transition_in(page.$$.fragment,local);current=true},o:function outro(local){transition_out(page.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(page,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$N.name,type:"component",source:"",ctx:ctx});return block}const prefix="/storage";function instance$N($$self,$$props,$$invalidate){let $location;let $needs_access_keys;let $current_settings;validate_store(location$1,"location");component_subscribe($$self,location$1,($$value=>$$invalidate(6,$location=$$value)));validate_store(needs_access_keys,"needs_access_keys");component_subscribe($$self,needs_access_keys,($$value=>$$invalidate(7,$needs_access_keys=$$value)));validate_store(current_settings,"current_settings");component_subscribe($$self,current_settings,($$value=>$$invalidate(8,$current_settings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("StoragePage",slots,[]);let{name:name="storage"}=$$props;let{params:params={}}=$$props;const _params=params;if($current_settings.bucket){setContext("initialSetup",false)}else{setContext("initialSetup",true)}setContext("settingsLocked",settingsLocked);let items=pages.withPrefix(prefix);let routes=pages.routes(prefix);afterUpdate((()=>{$$invalidate(1,items=pages.withPrefix(prefix));$$invalidate(2,routes=pages.routes(prefix));if($needs_access_keys&&$location.startsWith("/storage/")&&$location!=="/storage/provider"){push("/storage/provider")}}));const writable_props=["name","params"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<StoragePage> was created with unknown prop '${key}'`)}));function routeEvent_handler_1(event){bubble.call(this,$$self,event)}function routeEvent_handler(event){bubble.call(this,$$self,event)}$$self.$$set=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name);if("params"in $$props)$$invalidate(3,params=$$props.params)};$$self.$capture_state=()=>({afterUpdate:afterUpdate,setContext:setContext,location:location$1,push:push,current_settings:current_settings,settingsLocked:settingsLocked,needs_access_keys:needs_access_keys,Page:Page,Notifications:Notifications,SubNav:SubNav,SubPages:SubPages,pages:pages,name:name,params:params,_params:_params,prefix:prefix,items:items,routes:routes,$location:$location,$needs_access_keys:$needs_access_keys,$current_settings:$current_settings});$$self.$inject_state=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name);if("params"in $$props)$$invalidate(3,params=$$props.params);if("items"in $$props)$$invalidate(1,items=$$props.items);if("routes"in $$props)$$invalidate(2,routes=$$props.routes)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[name,items,routes,params,routeEvent_handler_1,routeEvent_handler]}class StoragePage extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$N,create_fragment$N,safe_not_equal,{name:0,params:3});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"StoragePage",options:options,id:create_fragment$N.name})}get name(){throw new Error("<StoragePage>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set name(value){throw new Error("<StoragePage>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get params(){throw new Error("<StoragePage>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set params(value){throw new Error("<StoragePage>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}function needsRefresh(saving,previousSettings,currentSettings,previousDefines,currentDefines){if(saving){return false}if(objectsDiffer([previousSettings,currentSettings])){return true}return objectsDiffer([previousDefines,currentDefines])}const file$I="ui/components/TabButton.svelte";function create_if_block_2$6(ctx){let img;let img_src_value;const block={c:function create(){img=element("img");if(!src_url_equal(img.src,img_src_value=ctx[2]))attr_dev(img,"src",img_src_value);attr_dev(img,"type","image/svg+xml");attr_dev(img,"alt",ctx[3]);add_location(img,file$I,20,2,363)},m:function mount(target,anchor){insert_dev(target,img,anchor)},p:function update(ctx,dirty){if(dirty&4&&!src_url_equal(img.src,img_src_value=ctx[2])){attr_dev(img,"src",img_src_value)}if(dirty&8){attr_dev(img,"alt",ctx[3])}},d:function destroy(detaching){if(detaching){detach_dev(img)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_2$6.name,type:"if",source:"(20:1) {#if icon}",ctx:ctx});return block}function create_if_block_1$d(ctx){let p;let t;const block={c:function create(){p=element("p");t=text(ctx[4]);add_location(p,file$I,27,2,449)},m:function mount(target,anchor){insert_dev(target,p,anchor);append_dev(p,t)},p:function update(ctx,dirty){if(dirty&16)set_data_dev(t,ctx[4])},d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_1$d.name,type:"if",source:"(27:1) {#if text}",ctx:ctx});return block}function create_if_block$l(ctx){let img;let img_src_value;let img_alt_value;const block={c:function create(){img=element("img");attr_dev(img,"class","checkmark");if(!src_url_equal(img.src,img_src_value=ctx[6].assets+"img/icon/licence-checked.svg"))attr_dev(img,"src",img_src_value);attr_dev(img,"type","image/svg+xml");attr_dev(img,"alt",img_alt_value=ctx[7].selected_desc);add_location(img,file$I,30,2,486)},m:function mount(target,anchor){insert_dev(target,img,anchor)},p:function update(ctx,dirty){if(dirty&64&&!src_url_equal(img.src,img_src_value=ctx[6].assets+"img/icon/licence-checked.svg")){attr_dev(img,"src",img_src_value)}if(dirty&128&&img_alt_value!==(img_alt_value=ctx[7].selected_desc)){attr_dev(img,"alt",img_alt_value)}},d:function destroy(detaching){if(detaching){detach_dev(img)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$l.name,type:"if",source:"(30:1) {#if active}",ctx:ctx});return block}function create_fragment$M(ctx){let a;let t0;let t1;let mounted;let dispose;let if_block0=ctx[2]&&create_if_block_2$6(ctx);let if_block1=ctx[4]&&create_if_block_1$d(ctx);let if_block2=ctx[0]&&create_if_block$l(ctx);const block={c:function create(){a=element("a");if(if_block0)if_block0.c();t0=space();if(if_block1)if_block1.c();t1=space();if(if_block2)if_block2.c();attr_dev(a,"href",ctx[5]);attr_dev(a,"class","button-tab");attr_dev(a,"disabled",ctx[1]);toggle_class(a,"active",ctx[0]);toggle_class(a,"btn-disabled",ctx[1]);add_location(a,file$I,11,0,230)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,a,anchor);if(if_block0)if_block0.m(a,null);append_dev(a,t0);if(if_block1)if_block1.m(a,null);append_dev(a,t1);if(if_block2)if_block2.m(a,null);if(!mounted){dispose=listen_dev(a,"click",prevent_default(ctx[8]),false,true,false,false);mounted=true}},p:function update(ctx,[dirty]){if(ctx[2]){if(if_block0){if_block0.p(ctx,dirty)}else{if_block0=create_if_block_2$6(ctx);if_block0.c();if_block0.m(a,t0)}}else if(if_block0){if_block0.d(1);if_block0=null}if(ctx[4]){if(if_block1){if_block1.p(ctx,dirty)}else{if_block1=create_if_block_1$d(ctx);if_block1.c();if_block1.m(a,t1)}}else if(if_block1){if_block1.d(1);if_block1=null}if(ctx[0]){if(if_block2){if_block2.p(ctx,dirty)}else{if_block2=create_if_block$l(ctx);if_block2.c();if_block2.m(a,null)}}else if(if_block2){if_block2.d(1);if_block2=null}if(dirty&32){attr_dev(a,"href",ctx[5])}if(dirty&2){attr_dev(a,"disabled",ctx[1])}if(dirty&1){toggle_class(a,"active",ctx[0])}if(dirty&2){toggle_class(a,"btn-disabled",ctx[1])}},i:noop,o:noop,d:function destroy(detaching){if(detaching){detach_dev(a)}if(if_block0)if_block0.d();if(if_block1)if_block1.d();if(if_block2)if_block2.d();mounted=false;dispose()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$M.name,type:"component",source:"",ctx:ctx});return block}function instance$M($$self,$$props,$$invalidate){let $urls;let $strings;validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(6,$urls=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(7,$strings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("TabButton",slots,[]);let{active:active=false}=$$props;let{disabled:disabled=false}=$$props;let{icon:icon=""}=$$props;let{iconDesc:iconDesc=""}=$$props;let{text:text=""}=$$props;let{url:url=$urls.settings}=$$props;const writable_props=["active","disabled","icon","iconDesc","text","url"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<TabButton> was created with unknown prop '${key}'`)}));function click_handler(event){bubble.call(this,$$self,event)}$$self.$$set=$$props=>{if("active"in $$props)$$invalidate(0,active=$$props.active);if("disabled"in $$props)$$invalidate(1,disabled=$$props.disabled);if("icon"in $$props)$$invalidate(2,icon=$$props.icon);if("iconDesc"in $$props)$$invalidate(3,iconDesc=$$props.iconDesc);if("text"in $$props)$$invalidate(4,text=$$props.text);if("url"in $$props)$$invalidate(5,url=$$props.url)};$$self.$capture_state=()=>({strings:strings,urls:urls,active:active,disabled:disabled,icon:icon,iconDesc:iconDesc,text:text,url:url,$urls:$urls,$strings:$strings});$$self.$inject_state=$$props=>{if("active"in $$props)$$invalidate(0,active=$$props.active);if("disabled"in $$props)$$invalidate(1,disabled=$$props.disabled);if("icon"in $$props)$$invalidate(2,icon=$$props.icon);if("iconDesc"in $$props)$$invalidate(3,iconDesc=$$props.iconDesc);if("text"in $$props)$$invalidate(4,text=$$props.text);if("url"in $$props)$$invalidate(5,url=$$props.url)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[active,disabled,icon,iconDesc,text,url,$urls,$strings,click_handler]}class TabButton extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$M,create_fragment$M,safe_not_equal,{active:0,disabled:1,icon:2,iconDesc:3,text:4,url:5});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"TabButton",options:options,id:create_fragment$M.name})}get active(){throw new Error("<TabButton>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set active(value){throw new Error("<TabButton>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get disabled(){throw new Error("<TabButton>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set disabled(value){throw new Error("<TabButton>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get icon(){throw new Error("<TabButton>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set icon(value){throw new Error("<TabButton>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get iconDesc(){throw new Error("<TabButton>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set iconDesc(value){throw new Error("<TabButton>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get text(){throw new Error("<TabButton>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set text(value){throw new Error("<TabButton>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get url(){throw new Error("<TabButton>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set url(value){throw new Error("<TabButton>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$H="ui/components/RadioButton.svelte";function create_if_block$k(ctx){let p;const block={c:function create(){p=element("p");attr_dev(p,"class","radio-desc");add_location(p,file$H,16,1,371)},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=ctx[5]},p:function update(ctx,dirty){if(dirty&32)p.innerHTML=ctx[5]},d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$k.name,type:"if",source:"(16:0) {#if selected === value && desc}",ctx:ctx});return block}function create_fragment$L(ctx){let div;let label;let input;let value_has_changed=false;let t0;let t1;let if_block_anchor;let current;let binding_group;let mounted;let dispose;const default_slot_template=ctx[7].default;const default_slot=create_slot(default_slot_template,ctx,ctx[6],null);let if_block=ctx[0]===ctx[4]&&ctx[5]&&create_if_block$k(ctx);binding_group=init_binding_group(ctx[9][0]);const block={c:function create(){div=element("div");label=element("label");input=element("input");t0=space();if(default_slot)default_slot.c();t1=space();if(if_block)if_block.c();if_block_anchor=empty();attr_dev(input,"type","radio");attr_dev(input,"name",ctx[3]);input.__value=ctx[4];set_input_value(input,input.__value);input.disabled=ctx[2];add_location(input,file$H,11,2,241);add_location(label,file$H,10,1,231);attr_dev(div,"class","radio-btn");toggle_class(div,"list",ctx[1]);toggle_class(div,"disabled",ctx[2]);add_location(div,file$H,9,0,180);binding_group.p(input)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,div,anchor);append_dev(div,label);append_dev(label,input);input.checked=input.__value===ctx[0];append_dev(label,t0);if(default_slot){default_slot.m(label,null)}insert_dev(target,t1,anchor);if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true;if(!mounted){dispose=listen_dev(input,"change",ctx[8]);mounted=true}},p:function update(ctx,[dirty]){if(!current||dirty&8){attr_dev(input,"name",ctx[3])}if(!current||dirty&16){prop_dev(input,"__value",ctx[4]);set_input_value(input,input.__value);value_has_changed=true}if(!current||dirty&4){prop_dev(input,"disabled",ctx[2])}if(value_has_changed||dirty&1){input.checked=input.__value===ctx[0]}if(default_slot){if(default_slot.p&&(!current||dirty&64)){update_slot_base(default_slot,default_slot_template,ctx,ctx[6],!current?get_all_dirty_from_scope(ctx[6]):get_slot_changes(default_slot_template,ctx[6],dirty,null),null)}}if(!current||dirty&2){toggle_class(div,"list",ctx[1])}if(!current||dirty&4){toggle_class(div,"disabled",ctx[2])}if(ctx[0]===ctx[4]&&ctx[5]){if(if_block){if_block.p(ctx,dirty)}else{if_block=create_if_block$k(ctx);if_block.c();if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){if_block.d(1);if_block=null}},i:function intro(local){if(current)return;transition_in(default_slot,local);current=true},o:function outro(local){transition_out(default_slot,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(div);detach_dev(t1);detach_dev(if_block_anchor)}if(default_slot)default_slot.d(detaching);if(if_block)if_block.d(detaching);binding_group.r();mounted=false;dispose()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$L.name,type:"component",source:"",ctx:ctx});return block}function instance$L($$self,$$props,$$invalidate){let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("RadioButton",slots,["default"]);let{list:list=false}=$$props;let{disabled:disabled=false}=$$props;let{name:name="options"}=$$props;let{value:value=""}=$$props;let{selected:selected=""}=$$props;let{desc:desc=""}=$$props;const writable_props=["list","disabled","name","value","selected","desc"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<RadioButton> was created with unknown prop '${key}'`)}));const $$binding_groups=[[]];function input_change_handler(){selected=this.__value;$$invalidate(0,selected)}$$self.$$set=$$props=>{if("list"in $$props)$$invalidate(1,list=$$props.list);if("disabled"in $$props)$$invalidate(2,disabled=$$props.disabled);if("name"in $$props)$$invalidate(3,name=$$props.name);if("value"in $$props)$$invalidate(4,value=$$props.value);if("selected"in $$props)$$invalidate(0,selected=$$props.selected);if("desc"in $$props)$$invalidate(5,desc=$$props.desc);if("$$scope"in $$props)$$invalidate(6,$$scope=$$props.$$scope)};$$self.$capture_state=()=>({list:list,disabled:disabled,name:name,value:value,selected:selected,desc:desc});$$self.$inject_state=$$props=>{if("list"in $$props)$$invalidate(1,list=$$props.list);if("disabled"in $$props)$$invalidate(2,disabled=$$props.disabled);if("name"in $$props)$$invalidate(3,name=$$props.name);if("value"in $$props)$$invalidate(4,value=$$props.value);if("selected"in $$props)$$invalidate(0,selected=$$props.selected);if("desc"in $$props)$$invalidate(5,desc=$$props.desc)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[selected,list,disabled,name,value,desc,$$scope,slots,input_change_handler,$$binding_groups]}class RadioButton extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$L,create_fragment$L,safe_not_equal,{list:1,disabled:2,name:3,value:4,selected:0,desc:5});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"RadioButton",options:options,id:create_fragment$L.name})}get list(){throw new Error("<RadioButton>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set list(value){throw new Error("<RadioButton>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get disabled(){throw new Error("<RadioButton>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set disabled(value){throw new Error("<RadioButton>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get name(){throw new Error("<RadioButton>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set name(value){throw new Error("<RadioButton>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get value(){throw new Error("<RadioButton>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set value(value){throw new Error("<RadioButton>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get selected(){throw new Error("<RadioButton>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set selected(value){throw new Error("<RadioButton>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get desc(){throw new Error("<RadioButton>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set desc(value){throw new Error("<RadioButton>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$G="ui/components/AccessKeysDefine.svelte";function create_fragment$K(ctx){let p;let raw_value=ctx[0].define_access_keys_desc+"";let t0;let pre;let t1_value=ctx[0].define_access_keys_example+"";let t1;const block={c:function create(){p=element("p");t0=space();pre=element("pre");t1=text(t1_value);add_location(p,file$G,4,0,42);add_location(pre,file$G,6,0,91)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=raw_value;insert_dev(target,t0,anchor);insert_dev(target,pre,anchor);append_dev(pre,t1)},p:function update(ctx,[dirty]){if(dirty&1&&raw_value!==(raw_value=ctx[0].define_access_keys_desc+""))p.innerHTML=raw_value;if(dirty&1&&t1_value!==(t1_value=ctx[0].define_access_keys_example+""))set_data_dev(t1,t1_value)},i:noop,o:noop,d:function destroy(detaching){if(detaching){detach_dev(p);detach_dev(t0);detach_dev(pre)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$K.name,type:"component",source:"",ctx:ctx});return block}function instance$K($$self,$$props,$$invalidate){let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("AccessKeysDefine",slots,[]);let{provider:provider}=$$props;$$self.$$.on_mount.push((function(){if(provider===undefined&&!("provider"in $$props||$$self.$$.bound[$$self.$$.props["provider"]])){console.warn("<AccessKeysDefine> was created without expected prop 'provider'")}}));const writable_props=["provider"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<AccessKeysDefine> was created with unknown prop '${key}'`)}));$$self.$$set=$$props=>{if("provider"in $$props)$$invalidate(0,provider=$$props.provider)};$$self.$capture_state=()=>({provider:provider});$$self.$inject_state=$$props=>{if("provider"in $$props)$$invalidate(0,provider=$$props.provider)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[provider]}class AccessKeysDefine extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$K,create_fragment$K,safe_not_equal,{provider:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"AccessKeysDefine",options:options,id:create_fragment$K.name})}get provider(){throw new Error("<AccessKeysDefine>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set provider(value){throw new Error("<AccessKeysDefine>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$F="ui/components/BackNextButtonsRow.svelte";function create_if_block_1$c(ctx){let button;let current;button=new Button({props:{large:true,disabled:ctx[1],title:ctx[2],$$slots:{default:[create_default_slot_2$g]},$$scope:{ctx:ctx}},$$inline:true});button.$on("click",ctx[12]);const block={c:function create(){create_component(button.$$.fragment)},m:function mount(target,anchor){mount_component(button,target,anchor);current=true},p:function update(ctx,dirty){const button_changes={};if(dirty&2)button_changes.disabled=ctx[1];if(dirty&4)button_changes.title=ctx[2];if(dirty&65537){button_changes.$$scope={dirty:dirty,ctx:ctx}}button.$set(button_changes)},i:function intro(local){if(current)return;transition_in(button.$$.fragment,local);current=true},o:function outro(local){transition_out(button.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(button,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_1$c.name,type:"if",source:"(27:1) {#if backVisible}",ctx:ctx});return block}function create_default_slot_2$g(ctx){let t;const block={c:function create(){t=text(ctx[0])},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty&1)set_data_dev(t,ctx[0])},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_2$g.name,type:"slot",source:"(28:2) <Button large on:click=\\\"{() => dispatch('back')}\\\" disabled={backDisabled} title={backTitle} >",ctx:ctx});return block}function create_if_block$j(ctx){let button;let current;button=new Button({props:{large:true,outline:true,disabled:ctx[5],title:ctx[6],$$slots:{default:[create_default_slot_1$j]},$$scope:{ctx:ctx}},$$inline:true});button.$on("click",ctx[13]);const block={c:function create(){create_component(button.$$.fragment)},m:function mount(target,anchor){mount_component(button,target,anchor);current=true},p:function update(ctx,dirty){const button_changes={};if(dirty&32)button_changes.disabled=ctx[5];if(dirty&64)button_changes.title=ctx[6];if(dirty&65552){button_changes.$$scope={dirty:dirty,ctx:ctx}}button.$set(button_changes)},i:function intro(local){if(current)return;transition_in(button.$$.fragment,local);current=true},o:function outro(local){transition_out(button.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(button,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$j.name,type:"if",source:"(37:1) {#if skipVisible}",ctx:ctx});return block}function create_default_slot_1$j(ctx){let t;const block={c:function create(){t=text(ctx[4])},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty&16)set_data_dev(t,ctx[4])},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$j.name,type:"slot",source:"(38:2) <Button large outline on:click=\\\"{() => dispatch('skip')}\\\" disabled={skipDisabled} title={skipTitle} >",ctx:ctx});return block}function create_default_slot$s(ctx){let t;const block={c:function create(){t=text(ctx[8])},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty&256)set_data_dev(t,ctx[8])},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$s.name,type:"slot",source:"(48:1) <Button large primary on:click=\\\"{() => dispatch('next')}\\\" disabled={nextDisabled} title={nextTitle} >",ctx:ctx});return block}function create_fragment$J(ctx){let div;let t0;let t1;let button;let current;let if_block0=ctx[3]&&create_if_block_1$c(ctx);let if_block1=ctx[7]&&create_if_block$j(ctx);button=new Button({props:{large:true,primary:true,disabled:ctx[9],title:ctx[10],$$slots:{default:[create_default_slot$s]},$$scope:{ctx:ctx}},$$inline:true});button.$on("click",ctx[14]);const block={c:function create(){div=element("div");if(if_block0)if_block0.c();t0=space();if(if_block1)if_block1.c();t1=space();create_component(button.$$.fragment);attr_dev(div,"class","btn-row");add_location(div,file$F,25,0,702)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,div,anchor);if(if_block0)if_block0.m(div,null);append_dev(div,t0);if(if_block1)if_block1.m(div,null);append_dev(div,t1);mount_component(button,div,null);current=true},p:function update(ctx,[dirty]){if(ctx[3]){if(if_block0){if_block0.p(ctx,dirty);if(dirty&8){transition_in(if_block0,1)}}else{if_block0=create_if_block_1$c(ctx);if_block0.c();transition_in(if_block0,1);if_block0.m(div,t0)}}else if(if_block0){group_outros();transition_out(if_block0,1,1,(()=>{if_block0=null}));check_outros()}if(ctx[7]){if(if_block1){if_block1.p(ctx,dirty);if(dirty&128){transition_in(if_block1,1)}}else{if_block1=create_if_block$j(ctx);if_block1.c();transition_in(if_block1,1);if_block1.m(div,t1)}}else if(if_block1){group_outros();transition_out(if_block1,1,1,(()=>{if_block1=null}));check_outros()}const button_changes={};if(dirty&512)button_changes.disabled=ctx[9];if(dirty&1024)button_changes.title=ctx[10];if(dirty&65792){button_changes.$$scope={dirty:dirty,ctx:ctx}}button.$set(button_changes)},i:function intro(local){if(current)return;transition_in(if_block0);transition_in(if_block1);transition_in(button.$$.fragment,local);current=true},o:function outro(local){transition_out(if_block0);transition_out(if_block1);transition_out(button.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(div)}if(if_block0)if_block0.d();if(if_block1)if_block1.d();destroy_component(button)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$J.name,type:"component",source:"",ctx:ctx});return block}function instance$J($$self,$$props,$$invalidate){let $strings;validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(15,$strings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("BackNextButtonsRow",slots,[]);const dispatch=createEventDispatcher();let{backText:backText=$strings.back}=$$props;let{backDisabled:backDisabled=false}=$$props;let{backTitle:backTitle=""}=$$props;let{backVisible:backVisible=false}=$$props;let{skipText:skipText=$strings.skip}=$$props;let{skipDisabled:skipDisabled=false}=$$props;let{skipTitle:skipTitle=""}=$$props;let{skipVisible:skipVisible=false}=$$props;let{nextText:nextText=$strings.next}=$$props;let{nextDisabled:nextDisabled=false}=$$props;let{nextTitle:nextTitle=""}=$$props;const writable_props=["backText","backDisabled","backTitle","backVisible","skipText","skipDisabled","skipTitle","skipVisible","nextText","nextDisabled","nextTitle"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<BackNextButtonsRow> was created with unknown prop '${key}'`)}));const click_handler=()=>dispatch("back");const click_handler_1=()=>dispatch("skip");const click_handler_2=()=>dispatch("next");$$self.$$set=$$props=>{if("backText"in $$props)$$invalidate(0,backText=$$props.backText);if("backDisabled"in $$props)$$invalidate(1,backDisabled=$$props.backDisabled);if("backTitle"in $$props)$$invalidate(2,backTitle=$$props.backTitle);if("backVisible"in $$props)$$invalidate(3,backVisible=$$props.backVisible);if("skipText"in $$props)$$invalidate(4,skipText=$$props.skipText);if("skipDisabled"in $$props)$$invalidate(5,skipDisabled=$$props.skipDisabled);if("skipTitle"in $$props)$$invalidate(6,skipTitle=$$props.skipTitle);if("skipVisible"in $$props)$$invalidate(7,skipVisible=$$props.skipVisible);if("nextText"in $$props)$$invalidate(8,nextText=$$props.nextText);if("nextDisabled"in $$props)$$invalidate(9,nextDisabled=$$props.nextDisabled);if("nextTitle"in $$props)$$invalidate(10,nextTitle=$$props.nextTitle)};$$self.$capture_state=()=>({createEventDispatcher:createEventDispatcher,strings:strings,Button:Button,dispatch:dispatch,backText:backText,backDisabled:backDisabled,backTitle:backTitle,backVisible:backVisible,skipText:skipText,skipDisabled:skipDisabled,skipTitle:skipTitle,skipVisible:skipVisible,nextText:nextText,nextDisabled:nextDisabled,nextTitle:nextTitle,$strings:$strings});$$self.$inject_state=$$props=>{if("backText"in $$props)$$invalidate(0,backText=$$props.backText);if("backDisabled"in $$props)$$invalidate(1,backDisabled=$$props.backDisabled);if("backTitle"in $$props)$$invalidate(2,backTitle=$$props.backTitle);if("backVisible"in $$props)$$invalidate(3,backVisible=$$props.backVisible);if("skipText"in $$props)$$invalidate(4,skipText=$$props.skipText);if("skipDisabled"in $$props)$$invalidate(5,skipDisabled=$$props.skipDisabled);if("skipTitle"in $$props)$$invalidate(6,skipTitle=$$props.skipTitle);if("skipVisible"in $$props)$$invalidate(7,skipVisible=$$props.skipVisible);if("nextText"in $$props)$$invalidate(8,nextText=$$props.nextText);if("nextDisabled"in $$props)$$invalidate(9,nextDisabled=$$props.nextDisabled);if("nextTitle"in $$props)$$invalidate(10,nextTitle=$$props.nextTitle)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[backText,backDisabled,backTitle,backVisible,skipText,skipDisabled,skipTitle,skipVisible,nextText,nextDisabled,nextTitle,dispatch,click_handler,click_handler_1,click_handler_2]}class BackNextButtonsRow extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$J,create_fragment$J,safe_not_equal,{backText:0,backDisabled:1,backTitle:2,backVisible:3,skipText:4,skipDisabled:5,skipTitle:6,skipVisible:7,nextText:8,nextDisabled:9,nextTitle:10});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"BackNextButtonsRow",options:options,id:create_fragment$J.name})}get backText(){throw new Error("<BackNextButtonsRow>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set backText(value){throw new Error("<BackNextButtonsRow>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get backDisabled(){throw new Error("<BackNextButtonsRow>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set backDisabled(value){throw new Error("<BackNextButtonsRow>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get backTitle(){throw new Error("<BackNextButtonsRow>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set backTitle(value){throw new Error("<BackNextButtonsRow>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get backVisible(){throw new Error("<BackNextButtonsRow>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set backVisible(value){throw new Error("<BackNextButtonsRow>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get skipText(){throw new Error("<BackNextButtonsRow>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set skipText(value){throw new Error("<BackNextButtonsRow>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get skipDisabled(){throw new Error("<BackNextButtonsRow>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set skipDisabled(value){throw new Error("<BackNextButtonsRow>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get skipTitle(){throw new Error("<BackNextButtonsRow>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set skipTitle(value){throw new Error("<BackNextButtonsRow>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get skipVisible(){throw new Error("<BackNextButtonsRow>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set skipVisible(value){throw new Error("<BackNextButtonsRow>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get nextText(){throw new Error("<BackNextButtonsRow>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set nextText(value){throw new Error("<BackNextButtonsRow>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get nextDisabled(){throw new Error("<BackNextButtonsRow>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set nextDisabled(value){throw new Error("<BackNextButtonsRow>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get nextTitle(){throw new Error("<BackNextButtonsRow>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set nextTitle(value){throw new Error("<BackNextButtonsRow>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$E="ui/components/KeyFileDefine.svelte";function create_fragment$I(ctx){let p;let raw_value=ctx[0].define_key_file_desc+"";let t0;let pre;let t1_value=ctx[0].define_key_file_example+"";let t1;const block={c:function create(){p=element("p");t0=space();pre=element("pre");t1=text(t1_value);add_location(p,file$E,4,0,42);add_location(pre,file$E,6,0,88)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=raw_value;insert_dev(target,t0,anchor);insert_dev(target,pre,anchor);append_dev(pre,t1)},p:function update(ctx,[dirty]){if(dirty&1&&raw_value!==(raw_value=ctx[0].define_key_file_desc+""))p.innerHTML=raw_value;if(dirty&1&&t1_value!==(t1_value=ctx[0].define_key_file_example+""))set_data_dev(t1,t1_value)},i:noop,o:noop,d:function destroy(detaching){if(detaching){detach_dev(p);detach_dev(t0);detach_dev(pre)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$I.name,type:"component",source:"",ctx:ctx});return block}function instance$I($$self,$$props,$$invalidate){let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("KeyFileDefine",slots,[]);let{provider:provider}=$$props;$$self.$$.on_mount.push((function(){if(provider===undefined&&!("provider"in $$props||$$self.$$.bound[$$self.$$.props["provider"]])){console.warn("<KeyFileDefine> was created without expected prop 'provider'")}}));const writable_props=["provider"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<KeyFileDefine> was created with unknown prop '${key}'`)}));$$self.$$set=$$props=>{if("provider"in $$props)$$invalidate(0,provider=$$props.provider)};$$self.$capture_state=()=>({provider:provider});$$self.$inject_state=$$props=>{if("provider"in $$props)$$invalidate(0,provider=$$props.provider)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[provider]}class KeyFileDefine extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$I,create_fragment$I,safe_not_equal,{provider:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"KeyFileDefine",options:options,id:create_fragment$I.name})}get provider(){throw new Error("<KeyFileDefine>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set provider(value){throw new Error("<KeyFileDefine>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$D="ui/components/UseServerRolesDefine.svelte";function create_fragment$H(ctx){let p;let raw_value=ctx[0].use_server_roles_desc+"";let t0;let pre;let t1_value=ctx[0].use_server_roles_example+"";let t1;const block={c:function create(){p=element("p");t0=space();pre=element("pre");t1=text(t1_value);add_location(p,file$D,4,0,42);add_location(pre,file$D,6,0,89)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=raw_value;insert_dev(target,t0,anchor);insert_dev(target,pre,anchor);append_dev(pre,t1)},p:function update(ctx,[dirty]){if(dirty&1&&raw_value!==(raw_value=ctx[0].use_server_roles_desc+""))p.innerHTML=raw_value;if(dirty&1&&t1_value!==(t1_value=ctx[0].use_server_roles_example+""))set_data_dev(t1,t1_value)},i:noop,o:noop,d:function destroy(detaching){if(detaching){detach_dev(p);detach_dev(t0);detach_dev(pre)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$H.name,type:"component",source:"",ctx:ctx});return block}function instance$H($$self,$$props,$$invalidate){let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("UseServerRolesDefine",slots,[]);let{provider:provider}=$$props;$$self.$$.on_mount.push((function(){if(provider===undefined&&!("provider"in $$props||$$self.$$.bound[$$self.$$.props["provider"]])){console.warn("<UseServerRolesDefine> was created without expected prop 'provider'")}}));const writable_props=["provider"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<UseServerRolesDefine> was created with unknown prop '${key}'`)}));$$self.$$set=$$props=>{if("provider"in $$props)$$invalidate(0,provider=$$props.provider)};$$self.$capture_state=()=>({provider:provider});$$self.$inject_state=$$props=>{if("provider"in $$props)$$invalidate(0,provider=$$props.provider)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[provider]}class UseServerRolesDefine extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$H,create_fragment$H,safe_not_equal,{provider:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"UseServerRolesDefine",options:options,id:create_fragment$H.name})}get provider(){throw new Error("<UseServerRolesDefine>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set provider(value){throw new Error("<UseServerRolesDefine>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$C="ui/components/AccessKeysEntry.svelte";function create_fragment$G(ctx){let p;let raw_value=ctx[2].enter_access_keys_desc+"";let t0;let label0;let t1;let t2;let input0;let t3;let label1;let t4;let t5;let input1;let mounted;let dispose;const block={c:function create(){p=element("p");t0=space();label0=element("label");t1=text(ctx[5]);t2=space();input0=element("input");t3=space();label1=element("label");t4=text(ctx[7]);t5=space();input1=element("input");add_location(p,file$C,15,0,370);attr_dev(label0,"class","input-label");attr_dev(label0,"for",ctx[4]);add_location(label0,file$C,17,0,418);attr_dev(input0,"type","text");attr_dev(input0,"id",ctx[4]);attr_dev(input0,"name",ctx[4]);attr_dev(input0,"minlength","20");attr_dev(input0,"size","20");input0.disabled=ctx[3];toggle_class(input0,"disabled",ctx[3]);add_location(input0,file$C,18,0,494);attr_dev(label1,"class","input-label");attr_dev(label1,"for",ctx[6]);add_location(label1,file$C,29,0,644);attr_dev(input1,"type","text");attr_dev(input1,"id",ctx[6]);attr_dev(input1,"name",ctx[6]);attr_dev(input1,"autocomplete","off");attr_dev(input1,"minlength","40");attr_dev(input1,"size","40");input1.disabled=ctx[3];toggle_class(input1,"disabled",ctx[3]);add_location(input1,file$C,30,0,728)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=raw_value;insert_dev(target,t0,anchor);insert_dev(target,label0,anchor);append_dev(label0,t1);insert_dev(target,t2,anchor);insert_dev(target,input0,anchor);set_input_value(input0,ctx[0]);insert_dev(target,t3,anchor);insert_dev(target,label1,anchor);append_dev(label1,t4);insert_dev(target,t5,anchor);insert_dev(target,input1,anchor);set_input_value(input1,ctx[1]);if(!mounted){dispose=[listen_dev(input0,"input",ctx[8]),listen_dev(input1,"input",ctx[9])];mounted=true}},p:function update(ctx,[dirty]){if(dirty&4&&raw_value!==(raw_value=ctx[2].enter_access_keys_desc+""))p.innerHTML=raw_value;if(dirty&8){prop_dev(input0,"disabled",ctx[3])}if(dirty&1&&input0.value!==ctx[0]){set_input_value(input0,ctx[0])}if(dirty&8){toggle_class(input0,"disabled",ctx[3])}if(dirty&8){prop_dev(input1,"disabled",ctx[3])}if(dirty&2&&input1.value!==ctx[1]){set_input_value(input1,ctx[1])}if(dirty&8){toggle_class(input1,"disabled",ctx[3])}},i:noop,o:noop,d:function destroy(detaching){if(detaching){detach_dev(p);detach_dev(t0);detach_dev(label0);detach_dev(t2);detach_dev(input0);detach_dev(t3);detach_dev(label1);detach_dev(t5);detach_dev(input1)}mounted=false;run_all(dispose)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$G.name,type:"component",source:"",ctx:ctx});return block}function instance$G($$self,$$props,$$invalidate){let $strings;validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(10,$strings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("AccessKeysEntry",slots,[]);let{provider:provider}=$$props;let{accessKeyId:accessKeyId=""}=$$props;let{secretAccessKey:secretAccessKey=""}=$$props;let{disabled:disabled=false}=$$props;let accessKeyIdName="access-key-id";let accessKeyIdLabel=$strings.access_key_id;let secretAccessKeyName="secret-access-key";let secretAccessKeyLabel=$strings.secret_access_key;$$self.$$.on_mount.push((function(){if(provider===undefined&&!("provider"in $$props||$$self.$$.bound[$$self.$$.props["provider"]])){console.warn("<AccessKeysEntry> was created without expected prop 'provider'")}}));const writable_props=["provider","accessKeyId","secretAccessKey","disabled"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<AccessKeysEntry> was created with unknown prop '${key}'`)}));function input0_input_handler(){accessKeyId=this.value;$$invalidate(0,accessKeyId)}function input1_input_handler(){secretAccessKey=this.value;$$invalidate(1,secretAccessKey)}$$self.$$set=$$props=>{if("provider"in $$props)$$invalidate(2,provider=$$props.provider);if("accessKeyId"in $$props)$$invalidate(0,accessKeyId=$$props.accessKeyId);if("secretAccessKey"in $$props)$$invalidate(1,secretAccessKey=$$props.secretAccessKey);if("disabled"in $$props)$$invalidate(3,disabled=$$props.disabled)};$$self.$capture_state=()=>({strings:strings,provider:provider,accessKeyId:accessKeyId,secretAccessKey:secretAccessKey,disabled:disabled,accessKeyIdName:accessKeyIdName,accessKeyIdLabel:accessKeyIdLabel,secretAccessKeyName:secretAccessKeyName,secretAccessKeyLabel:secretAccessKeyLabel,$strings:$strings});$$self.$inject_state=$$props=>{if("provider"in $$props)$$invalidate(2,provider=$$props.provider);if("accessKeyId"in $$props)$$invalidate(0,accessKeyId=$$props.accessKeyId);if("secretAccessKey"in $$props)$$invalidate(1,secretAccessKey=$$props.secretAccessKey);if("disabled"in $$props)$$invalidate(3,disabled=$$props.disabled);if("accessKeyIdName"in $$props)$$invalidate(4,accessKeyIdName=$$props.accessKeyIdName);if("accessKeyIdLabel"in $$props)$$invalidate(5,accessKeyIdLabel=$$props.accessKeyIdLabel);if("secretAccessKeyName"in $$props)$$invalidate(6,secretAccessKeyName=$$props.secretAccessKeyName);if("secretAccessKeyLabel"in $$props)$$invalidate(7,secretAccessKeyLabel=$$props.secretAccessKeyLabel)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[accessKeyId,secretAccessKey,provider,disabled,accessKeyIdName,accessKeyIdLabel,secretAccessKeyName,secretAccessKeyLabel,input0_input_handler,input1_input_handler]}class AccessKeysEntry extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$G,create_fragment$G,safe_not_equal,{provider:2,accessKeyId:0,secretAccessKey:1,disabled:3});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"AccessKeysEntry",options:options,id:create_fragment$G.name})}get provider(){throw new Error("<AccessKeysEntry>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set provider(value){throw new Error("<AccessKeysEntry>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get accessKeyId(){throw new Error("<AccessKeysEntry>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set accessKeyId(value){throw new Error("<AccessKeysEntry>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get secretAccessKey(){throw new Error("<AccessKeysEntry>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set secretAccessKey(value){throw new Error("<AccessKeysEntry>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get disabled(){throw new Error("<AccessKeysEntry>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set disabled(value){throw new Error("<AccessKeysEntry>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$B="ui/components/KeyFileEntry.svelte";function create_fragment$F(ctx){let p;let raw_value=ctx[1].enter_key_file_desc+"";let t0;let label_1;let t1;let t2;let textarea;let mounted;let dispose;const block={c:function create(){p=element("p");t0=space();label_1=element("label");t1=text(ctx[4]);t2=space();textarea=element("textarea");add_location(p,file$B,11,0,193);attr_dev(label_1,"class","input-label");attr_dev(label_1,"for",ctx[3]);add_location(label_1,file$B,13,0,238);attr_dev(textarea,"id",ctx[3]);attr_dev(textarea,"name",ctx[3]);textarea.disabled=ctx[2];attr_dev(textarea,"rows","10");toggle_class(textarea,"disabled",ctx[2]);add_location(textarea,file$B,14,0,292)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=raw_value;insert_dev(target,t0,anchor);insert_dev(target,label_1,anchor);append_dev(label_1,t1);insert_dev(target,t2,anchor);insert_dev(target,textarea,anchor);set_input_value(textarea,ctx[0]);if(!mounted){dispose=listen_dev(textarea,"input",ctx[5]);mounted=true}},p:function update(ctx,[dirty]){if(dirty&2&&raw_value!==(raw_value=ctx[1].enter_key_file_desc+""))p.innerHTML=raw_value;if(dirty&4){prop_dev(textarea,"disabled",ctx[2])}if(dirty&1){set_input_value(textarea,ctx[0])}if(dirty&4){toggle_class(textarea,"disabled",ctx[2])}},i:noop,o:noop,d:function destroy(detaching){if(detaching){detach_dev(p);detach_dev(t0);detach_dev(label_1);detach_dev(t2);detach_dev(textarea)}mounted=false;dispose()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$F.name,type:"component",source:"",ctx:ctx});return block}function instance$F($$self,$$props,$$invalidate){let $strings;validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(6,$strings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("KeyFileEntry",slots,[]);let{provider:provider}=$$props;let{value:value=""}=$$props;let{disabled:disabled=false}=$$props;let name="key-file";let label=$strings.key_file;$$self.$$.on_mount.push((function(){if(provider===undefined&&!("provider"in $$props||$$self.$$.bound[$$self.$$.props["provider"]])){console.warn("<KeyFileEntry> was created without expected prop 'provider'")}}));const writable_props=["provider","value","disabled"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<KeyFileEntry> was created with unknown prop '${key}'`)}));function textarea_input_handler(){value=this.value;$$invalidate(0,value)}$$self.$$set=$$props=>{if("provider"in $$props)$$invalidate(1,provider=$$props.provider);if("value"in $$props)$$invalidate(0,value=$$props.value);if("disabled"in $$props)$$invalidate(2,disabled=$$props.disabled)};$$self.$capture_state=()=>({strings:strings,provider:provider,value:value,disabled:disabled,name:name,label:label,$strings:$strings});$$self.$inject_state=$$props=>{if("provider"in $$props)$$invalidate(1,provider=$$props.provider);if("value"in $$props)$$invalidate(0,value=$$props.value);if("disabled"in $$props)$$invalidate(2,disabled=$$props.disabled);if("name"in $$props)$$invalidate(3,name=$$props.name);if("label"in $$props)$$invalidate(4,label=$$props.label)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[value,provider,disabled,name,label,textarea_input_handler]}class KeyFileEntry extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$F,create_fragment$F,safe_not_equal,{provider:1,value:0,disabled:2});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"KeyFileEntry",options:options,id:create_fragment$F.name})}get provider(){throw new Error("<KeyFileEntry>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set provider(value){throw new Error("<KeyFileEntry>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get value(){throw new Error("<KeyFileEntry>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set value(value){throw new Error("<KeyFileEntry>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get disabled(){throw new Error("<KeyFileEntry>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set disabled(value){throw new Error("<KeyFileEntry>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const{Object:Object_1$6}=globals;const file$A="ui/components/StorageProviderSubPage.svelte";function get_each_context$a(ctx,list,i){const child_ctx=ctx.slice();child_ctx[42]=list[i];return child_ctx}function create_if_block_11$1(ctx){let notification;let current;notification=new Notification({props:{inline:true,warning:true,heading:ctx[0].media_already_offloaded_warning.heading,$$slots:{default:[create_default_slot_13]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(notification.$$.fragment)},m:function mount(target,anchor){mount_component(notification,target,anchor);current=true},p:function update(ctx,dirty){const notification_changes={};if(dirty[0]&1)notification_changes.heading=ctx[0].media_already_offloaded_warning.heading;if(dirty[0]&1|dirty[1]&16384){notification_changes.$$scope={dirty:dirty,ctx:ctx}}notification.$set(notification_changes)},i:function intro(local){if(current)return;transition_in(notification.$$.fragment,local);current=true},o:function outro(local){transition_out(notification.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(notification,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_11$1.name,type:"if",source:"(212:1) {#if changedWithOffloaded}",ctx:ctx});return block}function create_default_slot_13(ctx){let p;let raw_value=ctx[0].media_already_offloaded_warning.message+"";const block={c:function create(){p=element("p");add_location(p,file$A,213,3,6396)},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=raw_value},p:function update(ctx,dirty){if(dirty[0]&1&&raw_value!==(raw_value=ctx[0].media_already_offloaded_warning.message+""))p.innerHTML=raw_value},d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_13.name,type:"slot",source:"(213:2) <Notification inline warning heading={storageProvider.media_already_offloaded_warning.heading}>",ctx:ctx});return block}function create_each_block$a(ctx){let tabbutton;let current;function click_handler(){return ctx[24](ctx[42])}tabbutton=new TabButton({props:{active:ctx[42].provider_key_name===ctx[0].provider_key_name,disabled:ctx[13],icon:ctx[42].icon,iconDesc:ctx[42].icon_desc,text:ctx[42].provider_service_name},$$inline:true});tabbutton.$on("click",click_handler);const block={c:function create(){create_component(tabbutton.$$.fragment)},m:function mount(target,anchor){mount_component(tabbutton,target,anchor);current=true},p:function update(new_ctx,dirty){ctx=new_ctx;const tabbutton_changes={};if(dirty[0]&32769)tabbutton_changes.active=ctx[42].provider_key_name===ctx[0].provider_key_name;if(dirty[0]&8192)tabbutton_changes.disabled=ctx[13];if(dirty[0]&32768)tabbutton_changes.icon=ctx[42].icon;if(dirty[0]&32768)tabbutton_changes.iconDesc=ctx[42].icon_desc;if(dirty[0]&32768)tabbutton_changes.text=ctx[42].provider_service_name;tabbutton.$set(tabbutton_changes)},i:function intro(local){if(current)return;transition_in(tabbutton.$$.fragment,local);current=true},o:function outro(local){transition_out(tabbutton.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(tabbutton,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_each_block$a.name,type:"each",source:"(220:3) {#each Object.values( $storage_providers ) as provider}",ctx:ctx});return block}function create_default_slot_12(ctx){let p;let raw_value=ctx[0].get_access_keys_help+"";const block={c:function create(){p=element("p");add_location(p,file$A,231,4,7010)},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=raw_value},p:function update(ctx,dirty){if(dirty[0]&1&&raw_value!==(raw_value=ctx[0].get_access_keys_help+""))p.innerHTML=raw_value},d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_12.name,type:"slot",source:'(231:3) <Notification class=\\"notice-qsg\\">',ctx:ctx});return block}function create_default_slot_11(ctx){let t;let notification;let current;let each_value=ensure_array_like_dev(Object.values(ctx[15]));let each_blocks=[];for(let i=0;i<each_value.length;i+=1){each_blocks[i]=create_each_block$a(get_each_context$a(ctx,each_value,i))}const out=i=>transition_out(each_blocks[i],1,1,(()=>{each_blocks[i]=null}));notification=new Notification({props:{class:"notice-qsg",$$slots:{default:[create_default_slot_12]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].c()}t=space();create_component(notification.$$.fragment)},m:function mount(target,anchor){for(let i=0;i<each_blocks.length;i+=1){if(each_blocks[i]){each_blocks[i].m(target,anchor)}}insert_dev(target,t,anchor);mount_component(notification,target,anchor);current=true},p:function update(ctx,dirty){if(dirty[0]&106497){each_value=ensure_array_like_dev(Object.values(ctx[15]));let i;for(i=0;i<each_value.length;i+=1){const child_ctx=get_each_context$a(ctx,each_value,i);if(each_blocks[i]){each_blocks[i].p(child_ctx,dirty);transition_in(each_blocks[i],1)}else{each_blocks[i]=create_each_block$a(child_ctx);each_blocks[i].c();transition_in(each_blocks[i],1);each_blocks[i].m(t.parentNode,t)}}group_outros();for(i=each_value.length;i<each_blocks.length;i+=1){out(i)}check_outros()}const notification_changes={};if(dirty[0]&1|dirty[1]&16384){notification_changes.$$scope={dirty:dirty,ctx:ctx}}notification.$set(notification_changes)},i:function intro(local){if(current)return;for(let i=0;i<each_value.length;i+=1){transition_in(each_blocks[i])}transition_in(notification.$$.fragment,local);current=true},o:function outro(local){each_blocks=each_blocks.filter(Boolean);for(let i=0;i<each_blocks.length;i+=1){transition_out(each_blocks[i])}transition_out(notification.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t)}destroy_each(each_blocks,detaching);destroy_component(notification,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_11.name,type:"slot",source:'(219:2) <PanelRow class=\\"body flex-row tab-buttons\\">',ctx:ctx});return block}function create_default_slot_10(ctx){let panelrow;let current;panelrow=new PanelRow({props:{class:"body flex-row tab-buttons",$$slots:{default:[create_default_slot_11]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty[0]&40961|dirty[1]&16384){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_10.name,type:"slot",source:"(218:1) <Panel heading={$strings.select_storage_provider_title} defined={defined} multi>",ctx:ctx});return block}function create_if_block_10$1(ctx){let radiobutton;let updating_selected;let current;function radiobutton_selected_binding_1(value){ctx[26](value)}let radiobutton_props={disabled:ctx[11],value:"define",desc:ctx[0].defined_auth_desc,$$slots:{default:[create_default_slot_9]},$$scope:{ctx:ctx}};if(ctx[1]!==void 0){radiobutton_props.selected=ctx[1]}radiobutton=new RadioButton({props:radiobutton_props,$$inline:true});binding_callbacks.push((()=>bind(radiobutton,"selected",radiobutton_selected_binding_1)));const block={c:function create(){create_component(radiobutton.$$.fragment)},m:function mount(target,anchor){mount_component(radiobutton,target,anchor);current=true},p:function update(ctx,dirty){const radiobutton_changes={};if(dirty[0]&2048)radiobutton_changes.disabled=ctx[11];if(dirty[0]&1)radiobutton_changes.desc=ctx[0].defined_auth_desc;if(dirty[0]&16384|dirty[1]&16384){radiobutton_changes.$$scope={dirty:dirty,ctx:ctx}}if(!updating_selected&&dirty[0]&2){updating_selected=true;radiobutton_changes.selected=ctx[1];add_flush_callback((()=>updating_selected=false))}radiobutton.$set(radiobutton_changes)},i:function intro(local){if(current)return;transition_in(radiobutton.$$.fragment,local);current=true},o:function outro(local){transition_out(radiobutton.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(radiobutton,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_10$1.name,type:"if",source:"(244:50) ",ctx:ctx});return block}function create_if_block_9$3(ctx){let radiobutton;let updating_selected;let current;function radiobutton_selected_binding(value){ctx[25](value)}let radiobutton_props={disabled:ctx[11],value:"define",desc:ctx[0].defined_auth_desc,$$slots:{default:[create_default_slot_8$3]},$$scope:{ctx:ctx}};if(ctx[1]!==void 0){radiobutton_props.selected=ctx[1]}radiobutton=new RadioButton({props:radiobutton_props,$$inline:true});binding_callbacks.push((()=>bind(radiobutton,"selected",radiobutton_selected_binding)));const block={c:function create(){create_component(radiobutton.$$.fragment)},m:function mount(target,anchor){mount_component(radiobutton,target,anchor);current=true},p:function update(ctx,dirty){const radiobutton_changes={};if(dirty[0]&2048)radiobutton_changes.disabled=ctx[11];if(dirty[0]&1)radiobutton_changes.desc=ctx[0].defined_auth_desc;if(dirty[0]&16384|dirty[1]&16384){radiobutton_changes.$$scope={dirty:dirty,ctx:ctx}}if(!updating_selected&&dirty[0]&2){updating_selected=true;radiobutton_changes.selected=ctx[1];add_flush_callback((()=>updating_selected=false))}radiobutton.$set(radiobutton_changes)},i:function intro(local){if(current)return;transition_in(radiobutton.$$.fragment,local);current=true},o:function outro(local){transition_out(radiobutton.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(radiobutton,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_9$3.name,type:"if",source:"(240:3) {#if storageProvider.use_access_keys_allowed}",ctx:ctx});return block}function create_default_slot_9(ctx){let t_value=ctx[14].define_key_file_path+"";let t;const block={c:function create(){t=text(t_value)},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty[0]&16384&&t_value!==(t_value=ctx[14].define_key_file_path+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_9.name,type:"slot",source:'(245:4) <RadioButton bind:selected={authMethod} disabled={authDisabled} value=\\"define\\" desc={storageProvider.defined_auth_desc}>',ctx:ctx});return block}function create_default_slot_8$3(ctx){let t_value=ctx[14].define_access_keys+"";let t;const block={c:function create(){t=text(t_value)},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty[0]&16384&&t_value!==(t_value=ctx[14].define_access_keys+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_8$3.name,type:"slot",source:'(241:4) <RadioButton bind:selected={authMethod} disabled={authDisabled} value=\\"define\\" desc={storageProvider.defined_auth_desc}>',ctx:ctx});return block}function create_if_block_8$3(ctx){let radiobutton;let updating_selected;let current;function radiobutton_selected_binding_2(value){ctx[27](value)}let radiobutton_props={disabled:ctx[11],value:"server-role",desc:ctx[0].defined_auth_desc,$$slots:{default:[create_default_slot_7$3]},$$scope:{ctx:ctx}};if(ctx[1]!==void 0){radiobutton_props.selected=ctx[1]}radiobutton=new RadioButton({props:radiobutton_props,$$inline:true});binding_callbacks.push((()=>bind(radiobutton,"selected",radiobutton_selected_binding_2)));const block={c:function create(){create_component(radiobutton.$$.fragment)},m:function mount(target,anchor){mount_component(radiobutton,target,anchor);current=true},p:function update(ctx,dirty){const radiobutton_changes={};if(dirty[0]&2048)radiobutton_changes.disabled=ctx[11];if(dirty[0]&1)radiobutton_changes.desc=ctx[0].defined_auth_desc;if(dirty[0]&1|dirty[1]&16384){radiobutton_changes.$$scope={dirty:dirty,ctx:ctx}}if(!updating_selected&&dirty[0]&2){updating_selected=true;radiobutton_changes.selected=ctx[1];add_flush_callback((()=>updating_selected=false))}radiobutton.$set(radiobutton_changes)},i:function intro(local){if(current)return;transition_in(radiobutton.$$.fragment,local);current=true},o:function outro(local){transition_out(radiobutton.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(radiobutton,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_8$3.name,type:"if",source:"(251:3) {#if storageProvider.use_server_roles_allowed}",ctx:ctx});return block}function create_default_slot_7$3(ctx){let t_value=ctx[0].use_server_roles_title+"";let t;const block={c:function create(){t=text(t_value)},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty[0]&1&&t_value!==(t_value=ctx[0].use_server_roles_title+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_7$3.name,type:"slot",source:'(252:4) <RadioButton bind:selected={authMethod} disabled={authDisabled} value=\\"server-role\\" desc={storageProvider.defined_auth_desc}>',ctx:ctx});return block}function create_if_block_7$3(ctx){let radiobutton;let updating_selected;let current;function radiobutton_selected_binding_4(value){ctx[29](value)}let radiobutton_props={disabled:ctx[11],value:"database",$$slots:{default:[create_default_slot_6$3]},$$scope:{ctx:ctx}};if(ctx[1]!==void 0){radiobutton_props.selected=ctx[1]}radiobutton=new RadioButton({props:radiobutton_props,$$inline:true});binding_callbacks.push((()=>bind(radiobutton,"selected",radiobutton_selected_binding_4)));const block={c:function create(){create_component(radiobutton.$$.fragment)},m:function mount(target,anchor){mount_component(radiobutton,target,anchor);current=true},p:function update(ctx,dirty){const radiobutton_changes={};if(dirty[0]&2048)radiobutton_changes.disabled=ctx[11];if(dirty[0]&16384|dirty[1]&16384){radiobutton_changes.$$scope={dirty:dirty,ctx:ctx}}if(!updating_selected&&dirty[0]&2){updating_selected=true;radiobutton_changes.selected=ctx[1];add_flush_callback((()=>updating_selected=false))}radiobutton.$set(radiobutton_changes)},i:function intro(local){if(current)return;transition_in(radiobutton.$$.fragment,local);current=true},o:function outro(local){transition_out(radiobutton.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(radiobutton,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_7$3.name,type:"if",source:"(262:50) ",ctx:ctx});return block}function create_if_block_6$3(ctx){let radiobutton;let updating_selected;let current;function radiobutton_selected_binding_3(value){ctx[28](value)}let radiobutton_props={disabled:ctx[11],value:"database",$$slots:{default:[create_default_slot_5$3]},$$scope:{ctx:ctx}};if(ctx[1]!==void 0){radiobutton_props.selected=ctx[1]}radiobutton=new RadioButton({props:radiobutton_props,$$inline:true});binding_callbacks.push((()=>bind(radiobutton,"selected",radiobutton_selected_binding_3)));const block={c:function create(){create_component(radiobutton.$$.fragment)},m:function mount(target,anchor){mount_component(radiobutton,target,anchor);current=true},p:function update(ctx,dirty){const radiobutton_changes={};if(dirty[0]&2048)radiobutton_changes.disabled=ctx[11];if(dirty[0]&16384|dirty[1]&16384){radiobutton_changes.$$scope={dirty:dirty,ctx:ctx}}if(!updating_selected&&dirty[0]&2){updating_selected=true;radiobutton_changes.selected=ctx[1];add_flush_callback((()=>updating_selected=false))}radiobutton.$set(radiobutton_changes)},i:function intro(local){if(current)return;transition_in(radiobutton.$$.fragment,local);current=true},o:function outro(local){transition_out(radiobutton.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(radiobutton,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_6$3.name,type:"if",source:"(258:3) {#if storageProvider.use_access_keys_allowed}",ctx:ctx});return block}function create_default_slot_6$3(ctx){let t_value=ctx[14].store_key_file_in_db+"";let t;const block={c:function create(){t=text(t_value)},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty[0]&16384&&t_value!==(t_value=ctx[14].store_key_file_in_db+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_6$3.name,type:"slot",source:'(263:4) <RadioButton bind:selected={authMethod} disabled={authDisabled} value=\\"database\\">',ctx:ctx});return block}function create_default_slot_5$3(ctx){let t_value=ctx[14].store_access_keys_in_db+"";let t;const block={c:function create(){t=text(t_value)},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty[0]&16384&&t_value!==(t_value=ctx[14].store_access_keys_in_db+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_5$3.name,type:"slot",source:'(259:4) <RadioButton bind:selected={authMethod} disabled={authDisabled} value=\\"database\\">',ctx:ctx});return block}function create_default_slot_4$5(ctx){let current_block_type_index;let if_block0;let t0;let t1;let current_block_type_index_1;let if_block2;let if_block2_anchor;let current;const if_block_creators=[create_if_block_9$3,create_if_block_10$1];const if_blocks=[];function select_block_type(ctx,dirty){if(ctx[0].use_access_keys_allowed)return 0;if(ctx[0].use_key_file_allowed)return 1;return-1}if(~(current_block_type_index=select_block_type(ctx))){if_block0=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx)}let if_block1=ctx[0].use_server_roles_allowed&&create_if_block_8$3(ctx);const if_block_creators_1=[create_if_block_6$3,create_if_block_7$3];const if_blocks_1=[];function select_block_type_1(ctx,dirty){if(ctx[0].use_access_keys_allowed)return 0;if(ctx[0].use_key_file_allowed)return 1;return-1}if(~(current_block_type_index_1=select_block_type_1(ctx))){if_block2=if_blocks_1[current_block_type_index_1]=if_block_creators_1[current_block_type_index_1](ctx)}const block={c:function create(){if(if_block0)if_block0.c();t0=space();if(if_block1)if_block1.c();t1=space();if(if_block2)if_block2.c();if_block2_anchor=empty()},m:function mount(target,anchor){if(~current_block_type_index){if_blocks[current_block_type_index].m(target,anchor)}insert_dev(target,t0,anchor);if(if_block1)if_block1.m(target,anchor);insert_dev(target,t1,anchor);if(~current_block_type_index_1){if_blocks_1[current_block_type_index_1].m(target,anchor)}insert_dev(target,if_block2_anchor,anchor);current=true},p:function update(ctx,dirty){let previous_block_index=current_block_type_index;current_block_type_index=select_block_type(ctx);if(current_block_type_index===previous_block_index){if(~current_block_type_index){if_blocks[current_block_type_index].p(ctx,dirty)}}else{if(if_block0){group_outros();transition_out(if_blocks[previous_block_index],1,1,(()=>{if_blocks[previous_block_index]=null}));check_outros()}if(~current_block_type_index){if_block0=if_blocks[current_block_type_index];if(!if_block0){if_block0=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);if_block0.c()}else{if_block0.p(ctx,dirty)}transition_in(if_block0,1);if_block0.m(t0.parentNode,t0)}else{if_block0=null}}if(ctx[0].use_server_roles_allowed){if(if_block1){if_block1.p(ctx,dirty);if(dirty[0]&1){transition_in(if_block1,1)}}else{if_block1=create_if_block_8$3(ctx);if_block1.c();transition_in(if_block1,1);if_block1.m(t1.parentNode,t1)}}else if(if_block1){group_outros();transition_out(if_block1,1,1,(()=>{if_block1=null}));check_outros()}let previous_block_index_1=current_block_type_index_1;current_block_type_index_1=select_block_type_1(ctx);if(current_block_type_index_1===previous_block_index_1){if(~current_block_type_index_1){if_blocks_1[current_block_type_index_1].p(ctx,dirty)}}else{if(if_block2){group_outros();transition_out(if_blocks_1[previous_block_index_1],1,1,(()=>{if_blocks_1[previous_block_index_1]=null}));check_outros()}if(~current_block_type_index_1){if_block2=if_blocks_1[current_block_type_index_1];if(!if_block2){if_block2=if_blocks_1[current_block_type_index_1]=if_block_creators_1[current_block_type_index_1](ctx);if_block2.c()}else{if_block2.p(ctx,dirty)}transition_in(if_block2,1);if_block2.m(if_block2_anchor.parentNode,if_block2_anchor)}else{if_block2=null}}},i:function intro(local){if(current)return;transition_in(if_block0);transition_in(if_block1);transition_in(if_block2);current=true},o:function outro(local){transition_out(if_block0);transition_out(if_block1);transition_out(if_block2);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(t1);detach_dev(if_block2_anchor)}if(~current_block_type_index){if_blocks[current_block_type_index].d(detaching)}if(if_block1)if_block1.d(detaching);if(~current_block_type_index_1){if_blocks_1[current_block_type_index_1].d(detaching)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_4$5.name,type:"slot",source:'(238:2) <PanelRow class=\\"body flex-column\\">',ctx:ctx});return block}function create_default_slot_3$6(ctx){let panelrow;let current;panelrow=new PanelRow({props:{class:"body flex-column",$$slots:{default:[create_default_slot_4$5]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty[0]&18435|dirty[1]&16384){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_3$6.name,type:"slot",source:"(237:1) <Panel heading={$strings.select_auth_method_title} defined={authDefined} multi>",ctx:ctx});return block}function create_if_block$i(ctx){let panel;let current;panel=new Panel({props:{heading:ctx[10],multi:true,$$slots:{default:[create_default_slot_1$i]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panel.$$.fragment)},m:function mount(target,anchor){mount_component(panel,target,anchor);current=true},p:function update(ctx,dirty){const panel_changes={};if(dirty[0]&1024)panel_changes.heading=ctx[10];if(dirty[0]&2947|dirty[1]&16384){panel_changes.$$scope={dirty:dirty,ctx:ctx}}panel.$set(panel_changes)},i:function intro(local){if(current)return;transition_in(panel.$$.fragment,local);current=true},o:function outro(local){transition_out(panel.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panel,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$i.name,type:"if",source:"(270:1) {#if !authDefined}",ctx:ctx});return block}function create_if_block_5$3(ctx){let keyfileentry;let updating_value;let current;function keyfileentry_value_binding(value){ctx[32](value)}let keyfileentry_props={provider:ctx[0]};if(ctx[9]!==void 0){keyfileentry_props.value=ctx[9]}keyfileentry=new KeyFileEntry({props:keyfileentry_props,$$inline:true});binding_callbacks.push((()=>bind(keyfileentry,"value",keyfileentry_value_binding)));const block={c:function create(){create_component(keyfileentry.$$.fragment)},m:function mount(target,anchor){mount_component(keyfileentry,target,anchor);current=true},p:function update(ctx,dirty){const keyfileentry_changes={};if(dirty[0]&1)keyfileentry_changes.provider=ctx[0];if(!updating_value&&dirty[0]&512){updating_value=true;keyfileentry_changes.value=ctx[9];add_flush_callback((()=>updating_value=false))}keyfileentry.$set(keyfileentry_changes)},i:function intro(local){if(current)return;transition_in(keyfileentry.$$.fragment,local);current=true},o:function outro(local){transition_out(keyfileentry.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(keyfileentry,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_5$3.name,type:"if",source:"(286:80) ",ctx:ctx});return block}function create_if_block_4$4(ctx){let accesskeysentry;let updating_accessKeyId;let updating_secretAccessKey;let current;function accesskeysentry_accessKeyId_binding(value){ctx[30](value)}function accesskeysentry_secretAccessKey_binding(value){ctx[31](value)}let accesskeysentry_props={provider:ctx[0],disabled:ctx[11]};if(ctx[7]!==void 0){accesskeysentry_props.accessKeyId=ctx[7]}if(ctx[8]!==void 0){accesskeysentry_props.secretAccessKey=ctx[8]}accesskeysentry=new AccessKeysEntry({props:accesskeysentry_props,$$inline:true});binding_callbacks.push((()=>bind(accesskeysentry,"accessKeyId",accesskeysentry_accessKeyId_binding)));binding_callbacks.push((()=>bind(accesskeysentry,"secretAccessKey",accesskeysentry_secretAccessKey_binding)));const block={c:function create(){create_component(accesskeysentry.$$.fragment)},m:function mount(target,anchor){mount_component(accesskeysentry,target,anchor);current=true},p:function update(ctx,dirty){const accesskeysentry_changes={};if(dirty[0]&1)accesskeysentry_changes.provider=ctx[0];if(dirty[0]&2048)accesskeysentry_changes.disabled=ctx[11];if(!updating_accessKeyId&&dirty[0]&128){updating_accessKeyId=true;accesskeysentry_changes.accessKeyId=ctx[7];add_flush_callback((()=>updating_accessKeyId=false))}if(!updating_secretAccessKey&&dirty[0]&256){updating_secretAccessKey=true;accesskeysentry_changes.secretAccessKey=ctx[8];add_flush_callback((()=>updating_secretAccessKey=false))}accesskeysentry.$set(accesskeysentry_changes)},i:function intro(local){if(current)return;transition_in(accesskeysentry.$$.fragment,local);current=true},o:function outro(local){transition_out(accesskeysentry.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(accesskeysentry,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_4$4.name,type:"if",source:"(279:83) ",ctx:ctx});return block}function create_if_block_3$4(ctx){let useserverrolesdefine;let current;useserverrolesdefine=new UseServerRolesDefine({props:{provider:ctx[0]},$$inline:true});const block={c:function create(){create_component(useserverrolesdefine.$$.fragment)},m:function mount(target,anchor){mount_component(useserverrolesdefine,target,anchor);current=true},p:function update(ctx,dirty){const useserverrolesdefine_changes={};if(dirty[0]&1)useserverrolesdefine_changes.provider=ctx[0];useserverrolesdefine.$set(useserverrolesdefine_changes)},i:function intro(local){if(current)return;transition_in(useserverrolesdefine.$$.fragment,local);current=true},o:function outro(local){transition_out(useserverrolesdefine.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(useserverrolesdefine,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_3$4.name,type:"if",source:"(277:87) ",ctx:ctx});return block}function create_if_block_2$5(ctx){let keyfiledefine;let current;keyfiledefine=new KeyFileDefine({props:{provider:ctx[0]},$$inline:true});const block={c:function create(){create_component(keyfiledefine.$$.fragment)},m:function mount(target,anchor){mount_component(keyfiledefine,target,anchor);current=true},p:function update(ctx,dirty){const keyfiledefine_changes={};if(dirty[0]&1)keyfiledefine_changes.provider=ctx[0];keyfiledefine.$set(keyfiledefine_changes)},i:function intro(local){if(current)return;transition_in(keyfiledefine.$$.fragment,local);current=true},o:function outro(local){transition_out(keyfiledefine.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(keyfiledefine,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_2$5.name,type:"if",source:"(275:78) ",ctx:ctx});return block}function create_if_block_1$b(ctx){let accesskeysdefine;let current;accesskeysdefine=new AccessKeysDefine({props:{provider:ctx[0]},$$inline:true});const block={c:function create(){create_component(accesskeysdefine.$$.fragment)},m:function mount(target,anchor){mount_component(accesskeysdefine,target,anchor);current=true},p:function update(ctx,dirty){const accesskeysdefine_changes={};if(dirty[0]&1)accesskeysdefine_changes.provider=ctx[0];accesskeysdefine.$set(accesskeysdefine_changes)},i:function intro(local){if(current)return;transition_in(accesskeysdefine.$$.fragment,local);current=true},o:function outro(local){transition_out(accesskeysdefine.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(accesskeysdefine,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_1$b.name,type:"if",source:'(273:4) {#if authMethod === \\"define\\" && storageProvider.use_access_keys_allowed}',ctx:ctx});return block}function create_default_slot_2$f(ctx){let current_block_type_index;let if_block;let if_block_anchor;let current;const if_block_creators=[create_if_block_1$b,create_if_block_2$5,create_if_block_3$4,create_if_block_4$4,create_if_block_5$3];const if_blocks=[];function select_block_type_2(ctx,dirty){if(ctx[1]==="define"&&ctx[0].use_access_keys_allowed)return 0;if(ctx[1]==="define"&&ctx[0].use_key_file_allowed)return 1;if(ctx[1]==="server-role"&&ctx[0].use_server_roles_allowed)return 2;if(ctx[1]==="database"&&ctx[0].use_access_keys_allowed)return 3;if(ctx[1]==="database"&&ctx[0].use_key_file_allowed)return 4;return-1}if(~(current_block_type_index=select_block_type_2(ctx))){if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx)}const block={c:function create(){if(if_block)if_block.c();if_block_anchor=empty()},m:function mount(target,anchor){if(~current_block_type_index){if_blocks[current_block_type_index].m(target,anchor)}insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,dirty){let previous_block_index=current_block_type_index;current_block_type_index=select_block_type_2(ctx);if(current_block_type_index===previous_block_index){if(~current_block_type_index){if_blocks[current_block_type_index].p(ctx,dirty)}}else{if(if_block){group_outros();transition_out(if_blocks[previous_block_index],1,1,(()=>{if_blocks[previous_block_index]=null}));check_outros()}if(~current_block_type_index){if_block=if_blocks[current_block_type_index];if(!if_block){if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);if_block.c()}else{if_block.p(ctx,dirty)}transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}else{if_block=null}}},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if(~current_block_type_index){if_blocks[current_block_type_index].d(detaching)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_2$f.name,type:"slot",source:'(272:3) <PanelRow class=\\"body flex-column access-keys\\">',ctx:ctx});return block}function create_default_slot_1$i(ctx){let panelrow;let current;panelrow=new PanelRow({props:{class:"body flex-column access-keys",$$slots:{default:[create_default_slot_2$f]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty[0]&2947|dirty[1]&16384){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$i.name,type:"slot",source:"(271:2) <Panel heading={saveCredentialsTitle} multi>",ctx:ctx});return block}function create_default_slot$r(ctx){let t0;let panel0;let t1;let panel1;let t2;let t3;let backnextbuttonsrow;let current;let if_block0=ctx[12]&&create_if_block_11$1(ctx);panel0=new Panel({props:{heading:ctx[14].select_storage_provider_title,defined:ctx[3],multi:true,$$slots:{default:[create_default_slot_10]},$$scope:{ctx:ctx}},$$inline:true});panel1=new Panel({props:{heading:ctx[14].select_auth_method_title,defined:ctx[2],multi:true,$$slots:{default:[create_default_slot_3$6]},$$scope:{ctx:ctx}},$$inline:true});let if_block1=!ctx[2]&&create_if_block$i(ctx);backnextbuttonsrow=new BackNextButtonsRow({props:{nextDisabled:ctx[5]||ctx[4],nextText:ctx[14].save_and_continue},$$inline:true});backnextbuttonsrow.$on("next",ctx[17]);const block={c:function create(){if(if_block0)if_block0.c();t0=space();create_component(panel0.$$.fragment);t1=space();create_component(panel1.$$.fragment);t2=space();if(if_block1)if_block1.c();t3=space();create_component(backnextbuttonsrow.$$.fragment)},m:function mount(target,anchor){if(if_block0)if_block0.m(target,anchor);insert_dev(target,t0,anchor);mount_component(panel0,target,anchor);insert_dev(target,t1,anchor);mount_component(panel1,target,anchor);insert_dev(target,t2,anchor);if(if_block1)if_block1.m(target,anchor);insert_dev(target,t3,anchor);mount_component(backnextbuttonsrow,target,anchor);current=true},p:function update(ctx,dirty){if(ctx[12]){if(if_block0){if_block0.p(ctx,dirty);if(dirty[0]&4096){transition_in(if_block0,1)}}else{if_block0=create_if_block_11$1(ctx);if_block0.c();transition_in(if_block0,1);if_block0.m(t0.parentNode,t0)}}else if(if_block0){group_outros();transition_out(if_block0,1,1,(()=>{if_block0=null}));check_outros()}const panel0_changes={};if(dirty[0]&16384)panel0_changes.heading=ctx[14].select_storage_provider_title;if(dirty[0]&8)panel0_changes.defined=ctx[3];if(dirty[0]&40961|dirty[1]&16384){panel0_changes.$$scope={dirty:dirty,ctx:ctx}}panel0.$set(panel0_changes);const panel1_changes={};if(dirty[0]&16384)panel1_changes.heading=ctx[14].select_auth_method_title;if(dirty[0]&4)panel1_changes.defined=ctx[2];if(dirty[0]&18435|dirty[1]&16384){panel1_changes.$$scope={dirty:dirty,ctx:ctx}}panel1.$set(panel1_changes);if(!ctx[2]){if(if_block1){if_block1.p(ctx,dirty);if(dirty[0]&4){transition_in(if_block1,1)}}else{if_block1=create_if_block$i(ctx);if_block1.c();transition_in(if_block1,1);if_block1.m(t3.parentNode,t3)}}else if(if_block1){group_outros();transition_out(if_block1,1,1,(()=>{if_block1=null}));check_outros()}const backnextbuttonsrow_changes={};if(dirty[0]&48)backnextbuttonsrow_changes.nextDisabled=ctx[5]||ctx[4];if(dirty[0]&16384)backnextbuttonsrow_changes.nextText=ctx[14].save_and_continue;backnextbuttonsrow.$set(backnextbuttonsrow_changes)},i:function intro(local){if(current)return;transition_in(if_block0);transition_in(panel0.$$.fragment,local);transition_in(panel1.$$.fragment,local);transition_in(if_block1);transition_in(backnextbuttonsrow.$$.fragment,local);current=true},o:function outro(local){transition_out(if_block0);transition_out(panel0.$$.fragment,local);transition_out(panel1.$$.fragment,local);transition_out(if_block1);transition_out(backnextbuttonsrow.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(t1);detach_dev(t2);detach_dev(t3)}if(if_block0)if_block0.d(detaching);destroy_component(panel0,detaching);destroy_component(panel1,detaching);if(if_block1)if_block1.d(detaching);destroy_component(backnextbuttonsrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$r.name,type:"slot",source:'(211:0) <SubPage name=\\"storage-provider-settings\\" route=\\"/storage/provider\\">',ctx:ctx});return block}function create_fragment$E(ctx){let subpage;let current;subpage=new SubPage({props:{name:"storage-provider-settings",route:"/storage/provider",$$slots:{default:[create_default_slot$r]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(subpage.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(subpage,target,anchor);current=true},p:function update(ctx,dirty){const subpage_changes={};if(dirty[0]&65471|dirty[1]&16384){subpage_changes.$$scope={dirty:dirty,ctx:ctx}}subpage.$set(subpage_changes)},i:function intro(local){if(current)return;transition_in(subpage.$$.fragment,local);current=true},o:function outro(local){transition_out(subpage.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(subpage,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$E.name,type:"component",source:"",ctx:ctx});return block}function instance$E($$self,$$props,$$invalidate){let defined;let disabled;let changedWithOffloaded;let authDefined;let authDisabled;let saveCredentialsTitle;let $revalidatingSettings;let $settings;let $strings;let $settingsLocked,$$unsubscribe_settingsLocked=noop,$$subscribe_settingsLocked=()=>($$unsubscribe_settingsLocked(),$$unsubscribe_settingsLocked=subscribe(settingsLocked,($$value=>$$invalidate(4,$settingsLocked=$$value))),settingsLocked);let $needs_refresh;let $counts;let $defined_settings;let $storage_provider;let $current_settings;let $storage_providers;validate_store(revalidatingSettings,"revalidatingSettings");component_subscribe($$self,revalidatingSettings,($$value=>$$invalidate(33,$revalidatingSettings=$$value)));validate_store(settings,"settings");component_subscribe($$self,settings,($$value=>$$invalidate(34,$settings=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(14,$strings=$$value)));validate_store(needs_refresh,"needs_refresh");component_subscribe($$self,needs_refresh,($$value=>$$invalidate(5,$needs_refresh=$$value)));validate_store(counts,"counts");component_subscribe($$self,counts,($$value=>$$invalidate(21,$counts=$$value)));validate_store(defined_settings,"defined_settings");component_subscribe($$self,defined_settings,($$value=>$$invalidate(22,$defined_settings=$$value)));validate_store(storage_provider,"storage_provider");component_subscribe($$self,storage_provider,($$value=>$$invalidate(35,$storage_provider=$$value)));validate_store(current_settings,"current_settings");component_subscribe($$self,current_settings,($$value=>$$invalidate(23,$current_settings=$$value)));validate_store(storage_providers,"storage_providers");component_subscribe($$self,storage_providers,($$value=>$$invalidate(15,$storage_providers=$$value)));$$self.$$.on_destroy.push((()=>$$unsubscribe_settingsLocked()));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("StorageProviderSubPage",slots,[]);let{params:params={}}=$$props;const _params=params;const dispatch=createEventDispatcher();let settingsLocked=writable(false);validate_store(settingsLocked,"settingsLocked");$$subscribe_settingsLocked();if(hasContext("settingsLocked")){$$subscribe_settingsLocked(settingsLocked=getContext("settingsLocked"))}let initialSettings=$current_settings;if(hasContext("initialSettings")){initialSettings=getContext("initialSettings")}let saving=false;const previousSettings={...$current_settings};const previousDefines={...$defined_settings};let storageProvider={...$storage_provider};function handleChooseProvider(provider){if(disabled){return}$$invalidate(0,storageProvider=provider);$$invalidate(1,authMethod=getAuthMethod(storageProvider,authMethod))}let accessKeyId=$settings["access-key-id"];let secretAccessKey=$settings["secret-access-key"];let keyFile=$settings["key-file"]?JSON.stringify($settings["key-file"]):"";function getAuthMethod(provider,current=""){if(provider.use_access_keys_allowed&&provider.used_access_keys_constants.length){return"define"}if(provider.use_key_file_allowed&&provider.used_key_file_path_constants.length){return"define"}if(provider.use_server_roles_allowed&&provider.used_server_roles_constants.length){return"server-role"}if(current==="server-role"&&!provider.use_server_roles_allowed){return"define"}if(current.length===0){if(provider.use_access_keys_allowed&&(accessKeyId||secretAccessKey)){return"database"}if(provider.use_key_file_allowed&&keyFile){return"database"}if(provider.use_server_roles_allowed&&$settings["use-server-roles"]){return"server-role"}return"define"}return current}let authMethod=getAuthMethod(storageProvider);function getCredentialsTitle(method){return $strings.auth_method_title[method]}async function handleNext(){$$invalidate(20,saving=true);state.pausePeriodicFetch();set_store_value(settings,$settings.provider=storageProvider.provider_key_name,$settings);set_store_value(settings,$settings["access-key-id"]=accessKeyId,$settings);set_store_value(settings,$settings["secret-access-key"]=secretAccessKey,$settings);set_store_value(settings,$settings["use-server-roles"]=authMethod==="server-role",$settings);set_store_value(settings,$settings["key-file"]=keyFile,$settings);const result=await settings.save();if(!result.hasOwnProperty("saved")||!result.saved){settings.reset();$$invalidate(20,saving=false);await state.resumePeriodicFetch();scrollNotificationsIntoView();return}set_store_value(revalidatingSettings,$revalidatingSettings=true,$revalidatingSettings);const statePromise=state.resumePeriodicFetch();dispatch("routeEvent",{event:"settings.save",data:result});await statePromise;set_store_value(revalidatingSettings,$revalidatingSettings=false,$revalidatingSettings)}const writable_props=["params"];Object_1$6.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<StorageProviderSubPage> was created with unknown prop '${key}'`)}));const click_handler=provider=>handleChooseProvider(provider);function radiobutton_selected_binding(value){authMethod=value;$$invalidate(1,authMethod)}function radiobutton_selected_binding_1(value){authMethod=value;$$invalidate(1,authMethod)}function radiobutton_selected_binding_2(value){authMethod=value;$$invalidate(1,authMethod)}function radiobutton_selected_binding_3(value){authMethod=value;$$invalidate(1,authMethod)}function radiobutton_selected_binding_4(value){authMethod=value;$$invalidate(1,authMethod)}function accesskeysentry_accessKeyId_binding(value){accessKeyId=value;$$invalidate(7,accessKeyId)}function accesskeysentry_secretAccessKey_binding(value){secretAccessKey=value;$$invalidate(8,secretAccessKey)}function keyfileentry_value_binding(value){keyFile=value;$$invalidate(9,keyFile)}$$self.$$set=$$props=>{if("params"in $$props)$$invalidate(18,params=$$props.params)};$$self.$capture_state=()=>({createEventDispatcher:createEventDispatcher,getContext:getContext,hasContext:hasContext,writable:writable,settings:settings,defined_settings:defined_settings,strings:strings,storage_providers:storage_providers,storage_provider:storage_provider,counts:counts,current_settings:current_settings,needs_refresh:needs_refresh,revalidatingSettings:revalidatingSettings,state:state,scrollNotificationsIntoView:scrollNotificationsIntoView,needsRefresh:needsRefresh,SubPage:SubPage,Panel:Panel,PanelRow:PanelRow,TabButton:TabButton,RadioButton:RadioButton,AccessKeysDefine:AccessKeysDefine,BackNextButtonsRow:BackNextButtonsRow,KeyFileDefine:KeyFileDefine,UseServerRolesDefine:UseServerRolesDefine,AccessKeysEntry:AccessKeysEntry,KeyFileEntry:KeyFileEntry,Notification:Notification,params:params,_params:_params,dispatch:dispatch,settingsLocked:settingsLocked,initialSettings:initialSettings,saving:saving,previousSettings:previousSettings,previousDefines:previousDefines,storageProvider:storageProvider,handleChooseProvider:handleChooseProvider,accessKeyId:accessKeyId,secretAccessKey:secretAccessKey,keyFile:keyFile,getAuthMethod:getAuthMethod,authMethod:authMethod,getCredentialsTitle:getCredentialsTitle,handleNext:handleNext,saveCredentialsTitle:saveCredentialsTitle,authDefined:authDefined,authDisabled:authDisabled,changedWithOffloaded:changedWithOffloaded,disabled:disabled,defined:defined,$revalidatingSettings:$revalidatingSettings,$settings:$settings,$strings:$strings,$settingsLocked:$settingsLocked,$needs_refresh:$needs_refresh,$counts:$counts,$defined_settings:$defined_settings,$storage_provider:$storage_provider,$current_settings:$current_settings,$storage_providers:$storage_providers});$$self.$inject_state=$$props=>{if("params"in $$props)$$invalidate(18,params=$$props.params);if("settingsLocked"in $$props)$$subscribe_settingsLocked($$invalidate(6,settingsLocked=$$props.settingsLocked));if("initialSettings"in $$props)$$invalidate(19,initialSettings=$$props.initialSettings);if("saving"in $$props)$$invalidate(20,saving=$$props.saving);if("storageProvider"in $$props)$$invalidate(0,storageProvider=$$props.storageProvider);if("accessKeyId"in $$props)$$invalidate(7,accessKeyId=$$props.accessKeyId);if("secretAccessKey"in $$props)$$invalidate(8,secretAccessKey=$$props.secretAccessKey);if("keyFile"in $$props)$$invalidate(9,keyFile=$$props.keyFile);if("authMethod"in $$props)$$invalidate(1,authMethod=$$props.authMethod);if("saveCredentialsTitle"in $$props)$$invalidate(10,saveCredentialsTitle=$$props.saveCredentialsTitle);if("authDefined"in $$props)$$invalidate(2,authDefined=$$props.authDefined);if("authDisabled"in $$props)$$invalidate(11,authDisabled=$$props.authDisabled);if("changedWithOffloaded"in $$props)$$invalidate(12,changedWithOffloaded=$$props.changedWithOffloaded);if("disabled"in $$props)$$invalidate(13,disabled=$$props.disabled);if("defined"in $$props)$$invalidate(3,defined=$$props.defined)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty[0]&13631520){{set_store_value(needs_refresh,$needs_refresh=$needs_refresh||needsRefresh(saving,previousSettings,$current_settings,previousDefines,$defined_settings),$needs_refresh)}}if($$self.$$.dirty[0]&4194304){$$invalidate(3,defined=$defined_settings.includes("provider"))}if($$self.$$.dirty[0]&56){$$invalidate(13,disabled=defined||$needs_refresh||$settingsLocked)}if($$self.$$.dirty[0]&2621441){$$invalidate(12,changedWithOffloaded=initialSettings.provider!==storageProvider.provider_key_name&&$counts.offloaded>0)}if($$self.$$.dirty[0]&1){$$invalidate(2,authDefined="database"!==getAuthMethod(storageProvider,"database"))}if($$self.$$.dirty[0]&52){$$invalidate(11,authDisabled=authDefined||$needs_refresh||$settingsLocked)}if($$self.$$.dirty[0]&2){$$invalidate(10,saveCredentialsTitle=getCredentialsTitle(authMethod))}};return[storageProvider,authMethod,authDefined,defined,$settingsLocked,$needs_refresh,settingsLocked,accessKeyId,secretAccessKey,keyFile,saveCredentialsTitle,authDisabled,changedWithOffloaded,disabled,$strings,$storage_providers,handleChooseProvider,handleNext,params,initialSettings,saving,$counts,$defined_settings,$current_settings,click_handler,radiobutton_selected_binding,radiobutton_selected_binding_1,radiobutton_selected_binding_2,radiobutton_selected_binding_3,radiobutton_selected_binding_4,accesskeysentry_accessKeyId_binding,accesskeysentry_secretAccessKey_binding,keyfileentry_value_binding]}class StorageProviderSubPage extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$E,create_fragment$E,safe_not_equal,{params:18},null,[-1,-1]);dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"StorageProviderSubPage",options:options,id:create_fragment$E.name})}get params(){throw new Error("<StorageProviderSubPage>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set params(value){throw new Error("<StorageProviderSubPage>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}function scrollIntoView(node,active){if(active){node.scrollIntoView({behavior:"smooth",block:"center",inline:"nearest"})}}const file$z="ui/components/Loading.svelte";function create_fragment$D(ctx){let p;let t_value=ctx[0].loading+"";let t;const block={c:function create(){p=element("p");t=text(t_value);add_location(p,file$z,4,0,59)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,p,anchor);append_dev(p,t)},p:function update(ctx,[dirty]){if(dirty&1&&t_value!==(t_value=ctx[0].loading+""))set_data_dev(t,t_value)},i:noop,o:noop,d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$D.name,type:"component",source:"",ctx:ctx});return block}function instance$D($$self,$$props,$$invalidate){let $strings;validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(0,$strings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("Loading",slots,[]);const writable_props=[];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<Loading> was created with unknown prop '${key}'`)}));$$self.$capture_state=()=>({strings:strings,$strings:$strings});return[$strings]}class Loading extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$D,create_fragment$D,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"Loading",options:options,id:create_fragment$D.name})}}const{Object:Object_1$5}=globals;const file$y="ui/components/BucketSettingsSubPage.svelte";function get_each_context$9(ctx,list,i){const child_ctx=ctx.slice();child_ctx[40]=list[i][0];child_ctx[41]=list[i][1];child_ctx[43]=i;return child_ctx}function get_each_context_1$1(ctx,list,i){const child_ctx=ctx.slice();child_ctx[45]=list[i];return child_ctx}function get_each_context_2(ctx,list,i){const child_ctx=ctx.slice();child_ctx[40]=list[i][0];child_ctx[41]=list[i][1];child_ctx[43]=i;return child_ctx}function get_each_context_3(ctx,list,i){const child_ctx=ctx.slice();child_ctx[40]=list[i][0];child_ctx[41]=list[i][1];child_ctx[43]=i;return child_ctx}function create_default_slot_8$2(ctx){let tabbutton0;let t;let tabbutton1;let current;tabbutton0=new TabButton({props:{active:ctx[0]==="existing",disabled:ctx[11],text:ctx[14].use_existing_bucket},$$inline:true});tabbutton0.$on("click",ctx[16]);tabbutton1=new TabButton({props:{active:ctx[0]==="new",disabled:ctx[11],text:ctx[14].create_new_bucket},$$inline:true});tabbutton1.$on("click",ctx[17]);const block={c:function create(){create_component(tabbutton0.$$.fragment);t=space();create_component(tabbutton1.$$.fragment)},m:function mount(target,anchor){mount_component(tabbutton0,target,anchor);insert_dev(target,t,anchor);mount_component(tabbutton1,target,anchor);current=true},p:function update(ctx,dirty){const tabbutton0_changes={};if(dirty[0]&1)tabbutton0_changes.active=ctx[0]==="existing";if(dirty[0]&2048)tabbutton0_changes.disabled=ctx[11];if(dirty[0]&16384)tabbutton0_changes.text=ctx[14].use_existing_bucket;tabbutton0.$set(tabbutton0_changes);const tabbutton1_changes={};if(dirty[0]&1)tabbutton1_changes.active=ctx[0]==="new";if(dirty[0]&2048)tabbutton1_changes.disabled=ctx[11];if(dirty[0]&16384)tabbutton1_changes.text=ctx[14].create_new_bucket;tabbutton1.$set(tabbutton1_changes)},i:function intro(local){if(current)return;transition_in(tabbutton0.$$.fragment,local);transition_in(tabbutton1.$$.fragment,local);current=true},o:function outro(local){transition_out(tabbutton0.$$.fragment,local);transition_out(tabbutton1.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t)}destroy_component(tabbutton0,detaching);destroy_component(tabbutton1,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_8$2.name,type:"slot",source:'(266:2) <PanelRow class=\\"body flex-row tab-buttons\\">',ctx:ctx});return block}function create_default_slot_7$2(ctx){let panelrow;let current;panelrow=new PanelRow({props:{class:"body flex-row tab-buttons",$$slots:{default:[create_default_slot_8$2]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty[0]&18433|dirty[1]&524288){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_7$2.name,type:"slot",source:"(265:1) <Panel heading={$strings.bucket_source_title} multi {defined}>",ctx:ctx});return block}function create_if_block_2$4(ctx){let panel;let current;panel=new Panel({props:{heading:ctx[14].existing_bucket_title,storageProvider:ctx[13],multi:true,defined:ctx[4],$$slots:{default:[create_default_slot_3$5]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panel.$$.fragment)},m:function mount(target,anchor){mount_component(panel,target,anchor);current=true},p:function update(ctx,dirty){const panel_changes={};if(dirty[0]&16384)panel_changes.heading=ctx[14].existing_bucket_title;if(dirty[0]&8192)panel_changes.storageProvider=ctx[13];if(dirty[0]&16)panel_changes.defined=ctx[4];if(dirty[0]&64782|dirty[1]&524288){panel_changes.$$scope={dirty:dirty,ctx:ctx}}panel.$set(panel_changes)},i:function intro(local){if(current)return;transition_in(panel.$$.fragment,local);current=true},o:function outro(local){transition_out(panel.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panel,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_2$4.name,type:"if",source:'(282:1) {#if bucketSource === \\"existing\\"}',ctx:ctx});return block}function create_default_slot_6$2(ctx){let t_value=ctx[14].enter_bucket+"";let t;const block={c:function create(){t=text(t_value)},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty[0]&16384&&t_value!==(t_value=ctx[14].enter_bucket+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_6$2.name,type:"slot",source:'(286:5) <RadioButton bind:selected={enterOrSelectExisting} value=\\"enter\\" list {disabled}>',ctx:ctx});return block}function create_default_slot_5$2(ctx){let t_value=ctx[14].select_bucket+"";let t;const block={c:function create(){t=text(t_value)},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty[0]&16384&&t_value!==(t_value=ctx[14].select_bucket+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_5$2.name,type:"slot",source:'(287:5) <RadioButton bind:selected={enterOrSelectExisting} value=\\"select\\" list {disabled}>',ctx:ctx});return block}function create_if_block_8$2(ctx){let div1;let div0;let label;let t0_value=ctx[14].bucket_name+"";let t0;let t1;let input;let input_placeholder_value;let t2;let current;let mounted;let dispose;let if_block=ctx[13].region_required&&create_if_block_9$2(ctx);const block={c:function create(){div1=element("div");div0=element("div");label=element("label");t0=text(t0_value);t1=space();input=element("input");t2=space();if(if_block)if_block.c();attr_dev(label,"class","input-label");attr_dev(label,"for","bucket-name");add_location(label,file$y,292,7,8073);attr_dev(input,"type","text");attr_dev(input,"id","bucket-name");attr_dev(input,"class","bucket-name");attr_dev(input,"name","bucket");attr_dev(input,"minlength","3");attr_dev(input,"placeholder",input_placeholder_value=ctx[14].enter_bucket_name_placeholder);input.disabled=ctx[11];toggle_class(input,"disabled",ctx[11]);add_location(input,file$y,293,7,8156);attr_dev(div0,"class","new-bucket-details flex-column");add_location(div0,file$y,291,6,8021);attr_dev(div1,"class","flex-row align-center row");add_location(div1,file$y,290,5,7975)},m:function mount(target,anchor){insert_dev(target,div1,anchor);append_dev(div1,div0);append_dev(div0,label);append_dev(label,t0);append_dev(div0,t1);append_dev(div0,input);set_input_value(input,ctx[2]);append_dev(div1,t2);if(if_block)if_block.m(div1,null);current=true;if(!mounted){dispose=listen_dev(input,"input",ctx[25]);mounted=true}},p:function update(ctx,dirty){if((!current||dirty[0]&16384)&&t0_value!==(t0_value=ctx[14].bucket_name+""))set_data_dev(t0,t0_value);if(!current||dirty[0]&16384&&input_placeholder_value!==(input_placeholder_value=ctx[14].enter_bucket_name_placeholder)){attr_dev(input,"placeholder",input_placeholder_value)}if(!current||dirty[0]&2048){prop_dev(input,"disabled",ctx[11])}if(dirty[0]&4&&input.value!==ctx[2]){set_input_value(input,ctx[2])}if(!current||dirty[0]&2048){toggle_class(input,"disabled",ctx[11])}if(ctx[13].region_required){if(if_block){if_block.p(ctx,dirty);if(dirty[0]&8192){transition_in(if_block,1)}}else{if_block=create_if_block_9$2(ctx);if_block.c();transition_in(if_block,1);if_block.m(div1,null)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(div1)}if(if_block)if_block.d();mounted=false;dispose()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_8$2.name,type:"if",source:'(290:4) {#if enterOrSelectExisting === \\"enter\\"}',ctx:ctx});return block}function create_if_block_9$2(ctx){let div;let label;let t0_value=ctx[14].region+"";let t0;let t1;let definedinwpconfig;let t2;let select;let current;let mounted;let dispose;definedinwpconfig=new DefinedInWPConfig({props:{defined:ctx[3]},$$inline:true});let each_value_3=ensure_array_like_dev(Object.entries(ctx[13].regions));let each_blocks=[];for(let i=0;i<each_value_3.length;i+=1){each_blocks[i]=create_each_block_3(get_each_context_3(ctx,each_value_3,i))}const block={c:function create(){div=element("div");label=element("label");t0=text(t0_value);t1=text(" ");create_component(definedinwpconfig.$$.fragment);t2=space();select=element("select");for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].c()}attr_dev(label,"class","input-label");attr_dev(label,"for","region");add_location(label,file$y,307,8,8530);attr_dev(select,"name","region");attr_dev(select,"id","region");select.disabled=ctx[12];if(ctx[8]===void 0)add_render_callback((()=>ctx[26].call(select)));toggle_class(select,"disabled",ctx[12]);add_location(select,file$y,310,8,8676);attr_dev(div,"class","region flex-column");add_location(div,file$y,306,7,8489)},m:function mount(target,anchor){insert_dev(target,div,anchor);append_dev(div,label);append_dev(label,t0);append_dev(label,t1);mount_component(definedinwpconfig,label,null);append_dev(div,t2);append_dev(div,select);for(let i=0;i<each_blocks.length;i+=1){if(each_blocks[i]){each_blocks[i].m(select,null)}}select_option(select,ctx[8],true);current=true;if(!mounted){dispose=listen_dev(select,"change",ctx[26]);mounted=true}},p:function update(ctx,dirty){if((!current||dirty[0]&16384)&&t0_value!==(t0_value=ctx[14].region+""))set_data_dev(t0,t0_value);const definedinwpconfig_changes={};if(dirty[0]&8)definedinwpconfig_changes.defined=ctx[3];definedinwpconfig.$set(definedinwpconfig_changes);if(dirty[0]&8448){each_value_3=ensure_array_like_dev(Object.entries(ctx[13].regions));let i;for(i=0;i<each_value_3.length;i+=1){const child_ctx=get_each_context_3(ctx,each_value_3,i);if(each_blocks[i]){each_blocks[i].p(child_ctx,dirty)}else{each_blocks[i]=create_each_block_3(child_ctx);each_blocks[i].c();each_blocks[i].m(select,null)}}for(;i<each_blocks.length;i+=1){each_blocks[i].d(1)}each_blocks.length=each_value_3.length}if(!current||dirty[0]&4096){prop_dev(select,"disabled",ctx[12])}if(dirty[0]&8448){select_option(select,ctx[8])}if(!current||dirty[0]&4096){toggle_class(select,"disabled",ctx[12])}},i:function intro(local){if(current)return;transition_in(definedinwpconfig.$$.fragment,local);current=true},o:function outro(local){transition_out(definedinwpconfig.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(div)}destroy_component(definedinwpconfig);destroy_each(each_blocks,detaching);mounted=false;dispose()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_9$2.name,type:"if",source:"(306:6) {#if $storage_provider.region_required}",ctx:ctx});return block}function create_each_block_3(ctx){let option;let t0_value=ctx[41]+"";let t0;let t1;let option_value_value;let option_selected_value;const block={c:function create(){option=element("option");t0=text(t0_value);t1=space();option.__value=option_value_value=ctx[40];set_input_value(option,option.__value);option.selected=option_selected_value=ctx[40]===ctx[8];add_location(option,file$y,312,10,8903)},m:function mount(target,anchor){insert_dev(target,option,anchor);append_dev(option,t0);append_dev(option,t1)},p:function update(ctx,dirty){if(dirty[0]&8192&&t0_value!==(t0_value=ctx[41]+""))set_data_dev(t0,t0_value);if(dirty[0]&8192&&option_value_value!==(option_value_value=ctx[40])){prop_dev(option,"__value",option_value_value);set_input_value(option,option.__value)}if(dirty[0]&8448&&option_selected_value!==(option_selected_value=ctx[40]===ctx[8])){prop_dev(option,"selected",option_selected_value)}},d:function destroy(detaching){if(detaching){detach_dev(option)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_each_block_3.name,type:"each",source:"(312:9) {#each Object.entries( $storage_provider.regions ) as [regionKey, regionName], index}",ctx:ctx});return block}function create_if_block_4$3(ctx){let t;let await_block_anchor;let promise;let current;let if_block=ctx[13].region_required&&create_if_block_7$2(ctx);let info={ctx:ctx,current:null,token:null,hasCatch:false,pending:create_pending_block,then:create_then_block,catch:create_catch_block,value:44,blocks:[,,,]};handle_promise(promise=ctx[18](ctx[8]),info);const block={c:function create(){if(if_block)if_block.c();t=space();await_block_anchor=empty();info.block.c()},m:function mount(target,anchor){if(if_block)if_block.m(target,anchor);insert_dev(target,t,anchor);insert_dev(target,await_block_anchor,anchor);info.block.m(target,info.anchor=anchor);info.mount=()=>await_block_anchor.parentNode;info.anchor=await_block_anchor;current=true},p:function update(new_ctx,dirty){ctx=new_ctx;if(ctx[13].region_required){if(if_block){if_block.p(ctx,dirty);if(dirty[0]&8192){transition_in(if_block,1)}}else{if_block=create_if_block_7$2(ctx);if_block.c();transition_in(if_block,1);if_block.m(t.parentNode,t)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}info.ctx=ctx;if(dirty[0]&256&&promise!==(promise=ctx[18](ctx[8]))&&handle_promise(promise,info));else{update_await_block_branch(info,ctx,dirty)}},i:function intro(local){if(current)return;transition_in(if_block);transition_in(info.block);current=true},o:function outro(local){transition_out(if_block);for(let i=0;i<3;i+=1){const block=info.blocks[i];transition_out(block)}current=false},d:function destroy(detaching){if(detaching){detach_dev(t);detach_dev(await_block_anchor)}if(if_block)if_block.d(detaching);info.block.d(detaching);info.token=null;info=null}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_4$3.name,type:"if",source:'(326:4) {#if enterOrSelectExisting === \\"select\\"}',ctx:ctx});return block}function create_if_block_7$2(ctx){let label;let t0_value=ctx[14].region+"";let t0;let t1;let definedinwpconfig;let t2;let select;let current;let mounted;let dispose;definedinwpconfig=new DefinedInWPConfig({props:{defined:ctx[3]},$$inline:true});let each_value_2=ensure_array_like_dev(Object.entries(ctx[13].regions));let each_blocks=[];for(let i=0;i<each_value_2.length;i+=1){each_blocks[i]=create_each_block_2(get_each_context_2(ctx,each_value_2,i))}const block={c:function create(){label=element("label");t0=text(t0_value);t1=text(" ");create_component(definedinwpconfig.$$.fragment);t2=space();select=element("select");for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].c()}attr_dev(label,"class","input-label");attr_dev(label,"for","list-region");add_location(label,file$y,327,6,9222);attr_dev(select,"name","region");attr_dev(select,"id","list-region");select.disabled=ctx[12];if(ctx[8]===void 0)add_render_callback((()=>ctx[27].call(select)));toggle_class(select,"disabled",ctx[12]);add_location(select,file$y,330,6,9367)},m:function mount(target,anchor){insert_dev(target,label,anchor);append_dev(label,t0);append_dev(label,t1);mount_component(definedinwpconfig,label,null);insert_dev(target,t2,anchor);insert_dev(target,select,anchor);for(let i=0;i<each_blocks.length;i+=1){if(each_blocks[i]){each_blocks[i].m(select,null)}}select_option(select,ctx[8],true);current=true;if(!mounted){dispose=listen_dev(select,"change",ctx[27]);mounted=true}},p:function update(ctx,dirty){if((!current||dirty[0]&16384)&&t0_value!==(t0_value=ctx[14].region+""))set_data_dev(t0,t0_value);const definedinwpconfig_changes={};if(dirty[0]&8)definedinwpconfig_changes.defined=ctx[3];definedinwpconfig.$set(definedinwpconfig_changes);if(dirty[0]&8448){each_value_2=ensure_array_like_dev(Object.entries(ctx[13].regions));let i;for(i=0;i<each_value_2.length;i+=1){const child_ctx=get_each_context_2(ctx,each_value_2,i);if(each_blocks[i]){each_blocks[i].p(child_ctx,dirty)}else{each_blocks[i]=create_each_block_2(child_ctx);each_blocks[i].c();each_blocks[i].m(select,null)}}for(;i<each_blocks.length;i+=1){each_blocks[i].d(1)}each_blocks.length=each_value_2.length}if(!current||dirty[0]&4096){prop_dev(select,"disabled",ctx[12])}if(dirty[0]&8448){select_option(select,ctx[8])}if(!current||dirty[0]&4096){toggle_class(select,"disabled",ctx[12])}},i:function intro(local){if(current)return;transition_in(definedinwpconfig.$$.fragment,local);current=true},o:function outro(local){transition_out(definedinwpconfig.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(label);detach_dev(t2);detach_dev(select)}destroy_component(definedinwpconfig);destroy_each(each_blocks,detaching);mounted=false;dispose()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_7$2.name,type:"if",source:"(327:5) {#if $storage_provider.region_required}",ctx:ctx});return block}function create_each_block_2(ctx){let option;let t0_value=ctx[41]+"";let t0;let t1;let option_value_value;let option_selected_value;const block={c:function create(){option=element("option");t0=text(t0_value);t1=space();option.__value=option_value_value=ctx[40];set_input_value(option,option.__value);option.selected=option_selected_value=ctx[40]===ctx[8];add_location(option,file$y,332,8,9595)},m:function mount(target,anchor){insert_dev(target,option,anchor);append_dev(option,t0);append_dev(option,t1)},p:function update(ctx,dirty){if(dirty[0]&8192&&t0_value!==(t0_value=ctx[41]+""))set_data_dev(t0,t0_value);if(dirty[0]&8192&&option_value_value!==(option_value_value=ctx[40])){prop_dev(option,"__value",option_value_value);set_input_value(option,option.__value)}if(dirty[0]&8448&&option_selected_value!==(option_selected_value=ctx[40]===ctx[8])){prop_dev(option,"selected",option_selected_value)}},d:function destroy(detaching){if(detaching){detach_dev(option)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_each_block_2.name,type:"each",source:"(332:7) {#each Object.entries( $storage_provider.regions ) as [regionKey, regionName], index}",ctx:ctx});return block}function create_catch_block(ctx){const block={c:noop,m:noop,p:noop,i:noop,o:noop,d:noop};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_catch_block.name,type:"catch",source:"(1:0) <script> import { createEventDispatcher, getContext, hasContext, onMount }",ctx:ctx});return block}function create_then_block(ctx){let ul;function select_block_type(ctx,dirty){if(ctx[44].length)return create_if_block_5$2;return create_else_block$b}let current_block_type=select_block_type(ctx);let if_block=current_block_type(ctx);const block={c:function create(){ul=element("ul");if_block.c();attr_dev(ul,"class","bucket-list");add_location(ul,file$y,344,6,9848)},m:function mount(target,anchor){insert_dev(target,ul,anchor);if_block.m(ul,null)},p:function update(ctx,dirty){if(current_block_type===(current_block_type=select_block_type(ctx))&&if_block){if_block.p(ctx,dirty)}else{if_block.d(1);if_block=current_block_type(ctx);if(if_block){if_block.c();if_block.m(ul,null)}}},i:noop,o:noop,d:function destroy(detaching){if(detaching){detach_dev(ul)}if_block.d()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_then_block.name,type:"then",source:"(344:5) {:then buckets}",ctx:ctx});return block}function create_else_block$b(ctx){let li;let p;let t_value=ctx[14].nothing_found+"";let t;const block={c:function create(){li=element("li");p=element("p");t=text(t_value);add_location(p,file$y,366,9,10789);attr_dev(li,"class","row nothing-found");add_location(li,file$y,365,8,10749)},m:function mount(target,anchor){insert_dev(target,li,anchor);append_dev(li,p);append_dev(p,t)},p:function update(ctx,dirty){if(dirty[0]&16384&&t_value!==(t_value=ctx[14].nothing_found+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(li)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block$b.name,type:"else",source:"(365:7) {:else}",ctx:ctx});return block}function create_if_block_5$2(ctx){let each_1_anchor;let each_value_1=ensure_array_like_dev(ctx[44]);let each_blocks=[];for(let i=0;i<each_value_1.length;i+=1){each_blocks[i]=create_each_block_1$1(get_each_context_1$1(ctx,each_value_1,i))}const block={c:function create(){for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].c()}each_1_anchor=empty()},m:function mount(target,anchor){for(let i=0;i<each_blocks.length;i+=1){if(each_blocks[i]){each_blocks[i].m(target,anchor)}}insert_dev(target,each_1_anchor,anchor)},p:function update(ctx,dirty){if(dirty[0]&311556){each_value_1=ensure_array_like_dev(ctx[44]);let i;for(i=0;i<each_value_1.length;i+=1){const child_ctx=get_each_context_1$1(ctx,each_value_1,i);if(each_blocks[i]){each_blocks[i].p(child_ctx,dirty)}else{each_blocks[i]=create_each_block_1$1(child_ctx);each_blocks[i].c();each_blocks[i].m(each_1_anchor.parentNode,each_1_anchor)}}for(;i<each_blocks.length;i+=1){each_blocks[i].d(1)}each_blocks.length=each_value_1.length}},d:function destroy(detaching){if(detaching){detach_dev(each_1_anchor)}destroy_each(each_blocks,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_5$2.name,type:"if",source:"(346:7) {#if buckets.length}",ctx:ctx});return block}function create_if_block_6$2(ctx){let img;let img_src_value;let img_alt_value;const block={c:function create(){img=element("img");attr_dev(img,"class","icon status");if(!src_url_equal(img.src,img_src_value=ctx[15].assets+"img/icon/licence-checked.svg"))attr_dev(img,"src",img_src_value);attr_dev(img,"type","image/svg+xml");attr_dev(img,"alt",img_alt_value=ctx[14].selected_desc);add_location(img,file$y,360,11,10549)},m:function mount(target,anchor){insert_dev(target,img,anchor)},p:function update(ctx,dirty){if(dirty[0]&32768&&!src_url_equal(img.src,img_src_value=ctx[15].assets+"img/icon/licence-checked.svg")){attr_dev(img,"src",img_src_value)}if(dirty[0]&16384&&img_alt_value!==(img_alt_value=ctx[14].selected_desc)){attr_dev(img,"alt",img_alt_value)}},d:function destroy(detaching){if(detaching){detach_dev(img)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_6$2.name,type:"if",source:"(360:10) {#if newBucket === bucket.Name}",ctx:ctx});return block}function create_each_block_1$1(ctx){let li;let img;let img_src_value;let img_alt_value;let t0;let p;let t1_value=ctx[45].Name+"";let t1;let t2;let t3;let li_data_bucket_name_value;let scrollIntoView_action;let mounted;let dispose;let if_block=ctx[2]===ctx[45].Name&&create_if_block_6$2(ctx);function click_handler(){return ctx[28](ctx[45])}const block={c:function create(){li=element("li");img=element("img");t0=space();p=element("p");t1=text(t1_value);t2=space();if(if_block)if_block.c();t3=space();attr_dev(img,"class","icon bucket");if(!src_url_equal(img.src,img_src_value=ctx[15].assets+"img/icon/bucket.svg"))attr_dev(img,"src",img_src_value);attr_dev(img,"alt",img_alt_value=ctx[14].bucket_icon);add_location(img,file$y,357,10,10367);add_location(p,file$y,358,10,10475);attr_dev(li,"class","row");attr_dev(li,"data-bucket-name",li_data_bucket_name_value=ctx[45].Name);toggle_class(li,"active",ctx[2]===ctx[45].Name);add_location(li,file$y,350,9,10120)},m:function mount(target,anchor){insert_dev(target,li,anchor);append_dev(li,img);append_dev(li,t0);append_dev(li,p);append_dev(p,t1);append_dev(li,t2);if(if_block)if_block.m(li,null);append_dev(li,t3);if(!mounted){dispose=[listen_dev(li,"click",click_handler,false,false,false,false),action_destroyer(scrollIntoView_action=scrollIntoView.call(null,li,ctx[2]===ctx[45].Name))];mounted=true}},p:function update(new_ctx,dirty){ctx=new_ctx;if(dirty[0]&32768&&!src_url_equal(img.src,img_src_value=ctx[15].assets+"img/icon/bucket.svg")){attr_dev(img,"src",img_src_value)}if(dirty[0]&16384&&img_alt_value!==(img_alt_value=ctx[14].bucket_icon)){attr_dev(img,"alt",img_alt_value)}if(dirty[0]&256&&t1_value!==(t1_value=ctx[45].Name+""))set_data_dev(t1,t1_value);if(ctx[2]===ctx[45].Name){if(if_block){if_block.p(ctx,dirty)}else{if_block=create_if_block_6$2(ctx);if_block.c();if_block.m(li,t3)}}else if(if_block){if_block.d(1);if_block=null}if(dirty[0]&8448&&li_data_bucket_name_value!==(li_data_bucket_name_value=ctx[45].Name)){attr_dev(li,"data-bucket-name",li_data_bucket_name_value)}if(scrollIntoView_action&&is_function(scrollIntoView_action.update)&&dirty[0]&260)scrollIntoView_action.update.call(null,ctx[2]===ctx[45].Name);if(dirty[0]&262404){toggle_class(li,"active",ctx[2]===ctx[45].Name)}},d:function destroy(detaching){if(detaching){detach_dev(li)}if(if_block)if_block.d();mounted=false;run_all(dispose)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_each_block_1$1.name,type:"each",source:"(347:8) {#each buckets as bucket}",ctx:ctx});return block}function create_pending_block(ctx){let loading;let current;loading=new Loading({$$inline:true});const block={c:function create(){create_component(loading.$$.fragment)},m:function mount(target,anchor){mount_component(loading,target,anchor);current=true},p:noop,i:function intro(local){if(current)return;transition_in(loading.$$.fragment,local);current=true},o:function outro(local){transition_out(loading.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(loading,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_pending_block.name,type:"pending",source:"(342:37) <Loading/> {:then buckets}",ctx:ctx});return block}function create_if_block_3$3(ctx){let p;let t;let p_transition;let current;const block={c:function create(){p=element("p");t=text(ctx[10]);attr_dev(p,"class","input-error");add_location(p,file$y,373,5,10924)},m:function mount(target,anchor){insert_dev(target,p,anchor);append_dev(p,t);current=true},p:function update(ctx,dirty){if(!current||dirty[0]&1024)set_data_dev(t,ctx[10])},i:function intro(local){if(current)return;if(local){add_render_callback((()=>{if(!current)return;if(!p_transition)p_transition=create_bidirectional_transition(p,slide,{},true);p_transition.run(1)}))}current=true},o:function outro(local){if(local){if(!p_transition)p_transition=create_bidirectional_transition(p,slide,{},false);p_transition.run(0)}current=false},d:function destroy(detaching){if(detaching){detach_dev(p)}if(detaching&&p_transition)p_transition.end()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_3$3.name,type:"if",source:"(373:4) {#if invalidBucketNameMessage}",ctx:ctx});return block}function create_default_slot_4$4(ctx){let div;let radiobutton0;let updating_selected;let t0;let radiobutton1;let updating_selected_1;let t1;let t2;let t3;let if_block2_anchor;let current;function radiobutton0_selected_binding(value){ctx[23](value)}let radiobutton0_props={value:"enter",list:true,disabled:ctx[11],$$slots:{default:[create_default_slot_6$2]},$$scope:{ctx:ctx}};if(ctx[1]!==void 0){radiobutton0_props.selected=ctx[1]}radiobutton0=new RadioButton({props:radiobutton0_props,$$inline:true});binding_callbacks.push((()=>bind(radiobutton0,"selected",radiobutton0_selected_binding)));function radiobutton1_selected_binding(value){ctx[24](value)}let radiobutton1_props={value:"select",list:true,disabled:ctx[11],$$slots:{default:[create_default_slot_5$2]},$$scope:{ctx:ctx}};if(ctx[1]!==void 0){radiobutton1_props.selected=ctx[1]}radiobutton1=new RadioButton({props:radiobutton1_props,$$inline:true});binding_callbacks.push((()=>bind(radiobutton1,"selected",radiobutton1_selected_binding)));let if_block0=ctx[1]==="enter"&&create_if_block_8$2(ctx);let if_block1=ctx[1]==="select"&&create_if_block_4$3(ctx);let if_block2=ctx[10]&&create_if_block_3$3(ctx);const block={c:function create(){div=element("div");create_component(radiobutton0.$$.fragment);t0=space();create_component(radiobutton1.$$.fragment);t1=space();if(if_block0)if_block0.c();t2=space();if(if_block1)if_block1.c();t3=space();if(if_block2)if_block2.c();if_block2_anchor=empty();attr_dev(div,"class","flex-row align-center row radio-btns");add_location(div,file$y,284,4,7613)},m:function mount(target,anchor){insert_dev(target,div,anchor);mount_component(radiobutton0,div,null);append_dev(div,t0);mount_component(radiobutton1,div,null);insert_dev(target,t1,anchor);if(if_block0)if_block0.m(target,anchor);insert_dev(target,t2,anchor);if(if_block1)if_block1.m(target,anchor);insert_dev(target,t3,anchor);if(if_block2)if_block2.m(target,anchor);insert_dev(target,if_block2_anchor,anchor);current=true},p:function update(ctx,dirty){const radiobutton0_changes={};if(dirty[0]&2048)radiobutton0_changes.disabled=ctx[11];if(dirty[0]&16384|dirty[1]&524288){radiobutton0_changes.$$scope={dirty:dirty,ctx:ctx}}if(!updating_selected&&dirty[0]&2){updating_selected=true;radiobutton0_changes.selected=ctx[1];add_flush_callback((()=>updating_selected=false))}radiobutton0.$set(radiobutton0_changes);const radiobutton1_changes={};if(dirty[0]&2048)radiobutton1_changes.disabled=ctx[11];if(dirty[0]&16384|dirty[1]&524288){radiobutton1_changes.$$scope={dirty:dirty,ctx:ctx}}if(!updating_selected_1&&dirty[0]&2){updating_selected_1=true;radiobutton1_changes.selected=ctx[1];add_flush_callback((()=>updating_selected_1=false))}radiobutton1.$set(radiobutton1_changes);if(ctx[1]==="enter"){if(if_block0){if_block0.p(ctx,dirty);if(dirty[0]&2){transition_in(if_block0,1)}}else{if_block0=create_if_block_8$2(ctx);if_block0.c();transition_in(if_block0,1);if_block0.m(t2.parentNode,t2)}}else if(if_block0){group_outros();transition_out(if_block0,1,1,(()=>{if_block0=null}));check_outros()}if(ctx[1]==="select"){if(if_block1){if_block1.p(ctx,dirty);if(dirty[0]&2){transition_in(if_block1,1)}}else{if_block1=create_if_block_4$3(ctx);if_block1.c();transition_in(if_block1,1);if_block1.m(t3.parentNode,t3)}}else if(if_block1){group_outros();transition_out(if_block1,1,1,(()=>{if_block1=null}));check_outros()}if(ctx[10]){if(if_block2){if_block2.p(ctx,dirty);if(dirty[0]&1024){transition_in(if_block2,1)}}else{if_block2=create_if_block_3$3(ctx);if_block2.c();transition_in(if_block2,1);if_block2.m(if_block2_anchor.parentNode,if_block2_anchor)}}else if(if_block2){group_outros();transition_out(if_block2,1,1,(()=>{if_block2=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(radiobutton0.$$.fragment,local);transition_in(radiobutton1.$$.fragment,local);transition_in(if_block0);transition_in(if_block1);transition_in(if_block2);current=true},o:function outro(local){transition_out(radiobutton0.$$.fragment,local);transition_out(radiobutton1.$$.fragment,local);transition_out(if_block0);transition_out(if_block1);transition_out(if_block2);current=false},d:function destroy(detaching){if(detaching){detach_dev(div);detach_dev(t1);detach_dev(t2);detach_dev(t3);detach_dev(if_block2_anchor)}destroy_component(radiobutton0);destroy_component(radiobutton1);if(if_block0)if_block0.d(detaching);if(if_block1)if_block1.d(detaching);if(if_block2)if_block2.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_4$4.name,type:"slot",source:'(284:3) <PanelRow class=\\"body flex-column\\">',ctx:ctx});return block}function create_default_slot_3$5(ctx){let panelrow;let current;panelrow=new PanelRow({props:{class:"body flex-column",$$slots:{default:[create_default_slot_4$4]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty[0]&64782|dirty[1]&524288){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_3$5.name,type:"slot",source:"(283:2) <Panel heading={$strings.existing_bucket_title} storageProvider={$storage_provider} multi {defined}>",ctx:ctx});return block}function create_if_block$h(ctx){let panel;let current;panel=new Panel({props:{heading:ctx[14].new_bucket_title,storageProvider:ctx[13],multi:true,defined:ctx[4],$$slots:{default:[create_default_slot_1$h]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panel.$$.fragment)},m:function mount(target,anchor){mount_component(panel,target,anchor);current=true},p:function update(ctx,dirty){const panel_changes={};if(dirty[0]&16384)panel_changes.heading=ctx[14].new_bucket_title;if(dirty[0]&8192)panel_changes.storageProvider=ctx[13];if(dirty[0]&16)panel_changes.defined=ctx[4];if(dirty[0]&32012|dirty[1]&524288){panel_changes.$$scope={dirty:dirty,ctx:ctx}}panel.$set(panel_changes)},i:function intro(local){if(current)return;transition_in(panel.$$.fragment,local);current=true},o:function outro(local){transition_out(panel.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panel,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$h.name,type:"if",source:'(380:1) {#if bucketSource === \\"new\\"}',ctx:ctx});return block}function create_each_block$9(ctx){let option;let t0_value=ctx[41]+"";let t0;let t1;let option_value_value;let option_selected_value;const block={c:function create(){option=element("option");t0=text(t0_value);t1=space();option.__value=option_value_value=ctx[40];set_input_value(option,option.__value);option.selected=option_selected_value=ctx[40]===ctx[8];add_location(option,file$y,403,8,12080)},m:function mount(target,anchor){insert_dev(target,option,anchor);append_dev(option,t0);append_dev(option,t1)},p:function update(ctx,dirty){if(dirty[0]&8192&&t0_value!==(t0_value=ctx[41]+""))set_data_dev(t0,t0_value);if(dirty[0]&8192&&option_value_value!==(option_value_value=ctx[40])){prop_dev(option,"__value",option_value_value);set_input_value(option,option.__value)}if(dirty[0]&8448&&option_selected_value!==(option_selected_value=ctx[40]===ctx[8])){prop_dev(option,"selected",option_selected_value)}},d:function destroy(detaching){if(detaching){detach_dev(option)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_each_block$9.name,type:"each",source:"(403:7) {#each Object.entries( $storage_provider.regions ) as [regionKey, regionName], index}",ctx:ctx});return block}function create_if_block_1$a(ctx){let p;let t;let p_transition;let current;const block={c:function create(){p=element("p");t=text(ctx[10]);attr_dev(p,"class","input-error");add_location(p,file$y,414,5,12303)},m:function mount(target,anchor){insert_dev(target,p,anchor);append_dev(p,t);current=true},p:function update(ctx,dirty){if(!current||dirty[0]&1024)set_data_dev(t,ctx[10])},i:function intro(local){if(current)return;if(local){add_render_callback((()=>{if(!current)return;if(!p_transition)p_transition=create_bidirectional_transition(p,slide,{},true);p_transition.run(1)}))}current=true},o:function outro(local){if(local){if(!p_transition)p_transition=create_bidirectional_transition(p,slide,{},false);p_transition.run(0)}current=false},d:function destroy(detaching){if(detaching){detach_dev(p)}if(detaching&&p_transition)p_transition.end()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_1$a.name,type:"if",source:"(414:4) {#if invalidBucketNameMessage}",ctx:ctx});return block}function create_default_slot_2$e(ctx){let div2;let div0;let label0;let t0_value=ctx[14].bucket_name+"";let t0;let t1;let input;let input_placeholder_value;let t2;let div1;let label1;let t3_value=ctx[14].region+"";let t3;let t4;let definedinwpconfig;let t5;let select;let t6;let if_block_anchor;let current;let mounted;let dispose;definedinwpconfig=new DefinedInWPConfig({props:{defined:ctx[3]},$$inline:true});let each_value=ensure_array_like_dev(Object.entries(ctx[13].regions));let each_blocks=[];for(let i=0;i<each_value.length;i+=1){each_blocks[i]=create_each_block$9(get_each_context$9(ctx,each_value,i))}let if_block=ctx[10]&&create_if_block_1$a(ctx);const block={c:function create(){div2=element("div");div0=element("div");label0=element("label");t0=text(t0_value);t1=space();input=element("input");t2=space();div1=element("div");label1=element("label");t3=text(t3_value);t4=text(" ");create_component(definedinwpconfig.$$.fragment);t5=space();select=element("select");for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].c()}t6=space();if(if_block)if_block.c();if_block_anchor=empty();attr_dev(label0,"class","input-label");attr_dev(label0,"for","new-bucket-name");add_location(label0,file$y,384,6,11306);attr_dev(input,"type","text");attr_dev(input,"id","new-bucket-name");attr_dev(input,"class","bucket-name");attr_dev(input,"name","bucket");attr_dev(input,"minlength","3");attr_dev(input,"placeholder",input_placeholder_value=ctx[14].enter_bucket_name_placeholder);input.disabled=ctx[11];toggle_class(input,"disabled",ctx[11]);add_location(input,file$y,385,6,11392);attr_dev(div0,"class","new-bucket-details flex-column");add_location(div0,file$y,383,5,11255);attr_dev(label1,"class","input-label");attr_dev(label1,"for","new-region");add_location(label1,file$y,398,6,11709);attr_dev(select,"name","region");attr_dev(select,"id","new-region");select.disabled=ctx[12];if(ctx[8]===void 0)add_render_callback((()=>ctx[30].call(select)));toggle_class(select,"disabled",ctx[12]);add_location(select,file$y,401,6,11853);attr_dev(div1,"class","region flex-column");add_location(div1,file$y,397,5,11670);attr_dev(div2,"class","flex-row align-center row");add_location(div2,file$y,382,4,11210)},m:function mount(target,anchor){insert_dev(target,div2,anchor);append_dev(div2,div0);append_dev(div0,label0);append_dev(label0,t0);append_dev(div0,t1);append_dev(div0,input);set_input_value(input,ctx[2]);append_dev(div2,t2);append_dev(div2,div1);append_dev(div1,label1);append_dev(label1,t3);append_dev(label1,t4);mount_component(definedinwpconfig,label1,null);append_dev(div1,t5);append_dev(div1,select);for(let i=0;i<each_blocks.length;i+=1){if(each_blocks[i]){each_blocks[i].m(select,null)}}select_option(select,ctx[8],true);insert_dev(target,t6,anchor);if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true;if(!mounted){dispose=[listen_dev(input,"input",ctx[29]),listen_dev(select,"change",ctx[30])];mounted=true}},p:function update(ctx,dirty){if((!current||dirty[0]&16384)&&t0_value!==(t0_value=ctx[14].bucket_name+""))set_data_dev(t0,t0_value);if(!current||dirty[0]&16384&&input_placeholder_value!==(input_placeholder_value=ctx[14].enter_bucket_name_placeholder)){attr_dev(input,"placeholder",input_placeholder_value)}if(!current||dirty[0]&2048){prop_dev(input,"disabled",ctx[11])}if(dirty[0]&4&&input.value!==ctx[2]){set_input_value(input,ctx[2])}if(!current||dirty[0]&2048){toggle_class(input,"disabled",ctx[11])}if((!current||dirty[0]&16384)&&t3_value!==(t3_value=ctx[14].region+""))set_data_dev(t3,t3_value);const definedinwpconfig_changes={};if(dirty[0]&8)definedinwpconfig_changes.defined=ctx[3];definedinwpconfig.$set(definedinwpconfig_changes);if(dirty[0]&8448){each_value=ensure_array_like_dev(Object.entries(ctx[13].regions));let i;for(i=0;i<each_value.length;i+=1){const child_ctx=get_each_context$9(ctx,each_value,i);if(each_blocks[i]){each_blocks[i].p(child_ctx,dirty)}else{each_blocks[i]=create_each_block$9(child_ctx);each_blocks[i].c();each_blocks[i].m(select,null)}}for(;i<each_blocks.length;i+=1){each_blocks[i].d(1)}each_blocks.length=each_value.length}if(!current||dirty[0]&4096){prop_dev(select,"disabled",ctx[12])}if(dirty[0]&8448){select_option(select,ctx[8])}if(!current||dirty[0]&4096){toggle_class(select,"disabled",ctx[12])}if(ctx[10]){if(if_block){if_block.p(ctx,dirty);if(dirty[0]&1024){transition_in(if_block,1)}}else{if_block=create_if_block_1$a(ctx);if_block.c();transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(definedinwpconfig.$$.fragment,local);transition_in(if_block);current=true},o:function outro(local){transition_out(definedinwpconfig.$$.fragment,local);transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(div2);detach_dev(t6);detach_dev(if_block_anchor)}destroy_component(definedinwpconfig);destroy_each(each_blocks,detaching);if(if_block)if_block.d(detaching);mounted=false;run_all(dispose)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_2$e.name,type:"slot",source:'(382:3) <PanelRow class=\\"body flex-column\\">',ctx:ctx});return block}function create_default_slot_1$h(ctx){let panelrow;let current;panelrow=new PanelRow({props:{class:"body flex-column",$$slots:{default:[create_default_slot_2$e]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty[0]&32012|dirty[1]&524288){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$h.name,type:"slot",source:"(381:2) <Panel heading={$strings.new_bucket_title} storageProvider={$storage_provider} multi {defined}>",ctx:ctx});return block}function create_default_slot$q(ctx){let panel;let t0;let t1;let t2;let backnextbuttonsrow;let current;panel=new Panel({props:{heading:ctx[14].bucket_source_title,multi:true,defined:ctx[4],$$slots:{default:[create_default_slot_7$2]},$$scope:{ctx:ctx}},$$inline:true});let if_block0=ctx[0]==="existing"&&create_if_block_2$4(ctx);let if_block1=ctx[0]==="new"&&create_if_block$h(ctx);backnextbuttonsrow=new BackNextButtonsRow({props:{nextText:ctx[9],nextDisabled:ctx[10]||ctx[6]||ctx[5],nextTitle:ctx[10]},$$inline:true});backnextbuttonsrow.$on("next",ctx[19]);const block={c:function create(){create_component(panel.$$.fragment);t0=space();if(if_block0)if_block0.c();t1=space();if(if_block1)if_block1.c();t2=space();create_component(backnextbuttonsrow.$$.fragment)},m:function mount(target,anchor){mount_component(panel,target,anchor);insert_dev(target,t0,anchor);if(if_block0)if_block0.m(target,anchor);insert_dev(target,t1,anchor);if(if_block1)if_block1.m(target,anchor);insert_dev(target,t2,anchor);mount_component(backnextbuttonsrow,target,anchor);current=true},p:function update(ctx,dirty){const panel_changes={};if(dirty[0]&16384)panel_changes.heading=ctx[14].bucket_source_title;if(dirty[0]&16)panel_changes.defined=ctx[4];if(dirty[0]&18433|dirty[1]&524288){panel_changes.$$scope={dirty:dirty,ctx:ctx}}panel.$set(panel_changes);if(ctx[0]==="existing"){if(if_block0){if_block0.p(ctx,dirty);if(dirty[0]&1){transition_in(if_block0,1)}}else{if_block0=create_if_block_2$4(ctx);if_block0.c();transition_in(if_block0,1);if_block0.m(t1.parentNode,t1)}}else if(if_block0){group_outros();transition_out(if_block0,1,1,(()=>{if_block0=null}));check_outros()}if(ctx[0]==="new"){if(if_block1){if_block1.p(ctx,dirty);if(dirty[0]&1){transition_in(if_block1,1)}}else{if_block1=create_if_block$h(ctx);if_block1.c();transition_in(if_block1,1);if_block1.m(t2.parentNode,t2)}}else if(if_block1){group_outros();transition_out(if_block1,1,1,(()=>{if_block1=null}));check_outros()}const backnextbuttonsrow_changes={};if(dirty[0]&512)backnextbuttonsrow_changes.nextText=ctx[9];if(dirty[0]&1120)backnextbuttonsrow_changes.nextDisabled=ctx[10]||ctx[6]||ctx[5];if(dirty[0]&1024)backnextbuttonsrow_changes.nextTitle=ctx[10];backnextbuttonsrow.$set(backnextbuttonsrow_changes)},i:function intro(local){if(current)return;transition_in(panel.$$.fragment,local);transition_in(if_block0);transition_in(if_block1);transition_in(backnextbuttonsrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panel.$$.fragment,local);transition_out(if_block0);transition_out(if_block1);transition_out(backnextbuttonsrow.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(t1);detach_dev(t2)}destroy_component(panel,detaching);if(if_block0)if_block0.d(detaching);if(if_block1)if_block1.d(detaching);destroy_component(backnextbuttonsrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$q.name,type:"slot",source:'(264:0) <SubPage name=\\"bucket-settings\\" route=\\"/storage/bucket\\">',ctx:ctx});return block}function create_fragment$C(ctx){let subpage;let current;subpage=new SubPage({props:{name:"bucket-settings",route:"/storage/bucket",$$slots:{default:[create_default_slot$q]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(subpage.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(subpage,target,anchor);current=true},p:function update(ctx,dirty){const subpage_changes={};if(dirty[0]&65407|dirty[1]&524288){subpage_changes.$$scope={dirty:dirty,ctx:ctx}}subpage.$set(subpage_changes)},i:function intro(local){if(current)return;transition_in(subpage.$$.fragment,local);current=true},o:function outro(local){transition_out(subpage.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(subpage,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$C.name,type:"component",source:"",ctx:ctx});return block}function instance$C($$self,$$props,$$invalidate){let defined;let disabled;let newRegionDefined;let newRegionDisabled;let invalidBucketNameMessage;let nextText;let $storage_provider;let $revalidatingSettings;let $settings;let $strings;let $settingsLocked,$$unsubscribe_settingsLocked=noop,$$subscribe_settingsLocked=()=>($$unsubscribe_settingsLocked(),$$unsubscribe_settingsLocked=subscribe(settingsLocked,($$value=>$$invalidate(5,$settingsLocked=$$value))),settingsLocked);let $needs_refresh;let $defined_settings;let $current_settings;let $urls;validate_store(storage_provider,"storage_provider");component_subscribe($$self,storage_provider,($$value=>$$invalidate(13,$storage_provider=$$value)));validate_store(revalidatingSettings,"revalidatingSettings");component_subscribe($$self,revalidatingSettings,($$value=>$$invalidate(32,$revalidatingSettings=$$value)));validate_store(settings,"settings");component_subscribe($$self,settings,($$value=>$$invalidate(33,$settings=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(14,$strings=$$value)));validate_store(needs_refresh,"needs_refresh");component_subscribe($$self,needs_refresh,($$value=>$$invalidate(6,$needs_refresh=$$value)));validate_store(defined_settings,"defined_settings");component_subscribe($$self,defined_settings,($$value=>$$invalidate(21,$defined_settings=$$value)));validate_store(current_settings,"current_settings");component_subscribe($$self,current_settings,($$value=>$$invalidate(22,$current_settings=$$value)));validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(15,$urls=$$value)));$$self.$$.on_destroy.push((()=>$$unsubscribe_settingsLocked()));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("BucketSettingsSubPage",slots,[]);const dispatch=createEventDispatcher();let settingsLocked=writable(false);validate_store(settingsLocked,"settingsLocked");$$subscribe_settingsLocked();if(hasContext("settingsLocked")){$$subscribe_settingsLocked(settingsLocked=getContext("settingsLocked"))}let initialSettings=$current_settings;if(hasContext("initialSettings")){initialSettings=getContext("initialSettings")}let saving=false;const previousSettings={...$current_settings};const previousDefines={...$defined_settings};let bucketSource="existing";let enterOrSelectExisting="enter";let newBucket=$settings.bucket;let newRegion=$settings.region;function handleExisting(){if(disabled){return}$$invalidate(0,bucketSource="existing")}function handleNew(){if(disabled){return}$$invalidate(0,bucketSource="new")}async function getBuckets(region){let params={};if($storage_provider.region_required){params={region:region}}let data=await api.get("buckets",params);if(data.hasOwnProperty("buckets")){if(data.buckets.filter((bucket=>bucket.Name===newBucket)).length===0){$$invalidate(2,newBucket="")}return data.buckets}$$invalidate(2,newBucket="");return[]}async function createBucket(){let data=await api.post("buckets",{bucket:newBucket,region:newRegion});if(data.hasOwnProperty("saved")){return data.saved}return false}function getInvalidBucketNameMessage(bucket,source,existingType){if(newRegionDefined&&(newRegion.length===0||!$storage_provider.regions.hasOwnProperty(newRegion))){return $strings.defined_region_invalid}const bucketNamePattern=source==="new"?/[^a-z0-9.\-]/:/[^a-zA-Z0-9.\-_]/;let message="";if(bucket.trim().length<1){if(source==="existing"&&existingType==="select"){message=$strings.no_bucket_selected}else{message=$strings.create_bucket_name_missing}}else if(true===bucketNamePattern.test(bucket)){message=source==="new"?$strings.create_bucket_invalid_chars:$strings.select_bucket_invalid_chars}else if(bucket.length<3){message=$strings.create_bucket_name_short}else if(bucket.length>63){message=$strings.create_bucket_name_long}return message}function getNextText(source,existingType){if(source==="existing"&&existingType==="enter"){return $strings.save_enter_bucket}if(source==="existing"&&existingType==="select"){return $strings.save_select_bucket}if(source==="new"){return $strings.save_new_bucket}return $strings.next}async function handleNext(){if(bucketSource==="new"&&false===await createBucket()){scrollNotificationsIntoView();return}$$invalidate(20,saving=true);state.pausePeriodicFetch();set_store_value(settings,$settings.bucket=newBucket,$settings);set_store_value(settings,$settings.region=newRegion,$settings);const result=await settings.save();if(result.hasOwnProperty("saved")&&!result.saved){settings.reset();$$invalidate(20,saving=false);await state.resumePeriodicFetch();scrollNotificationsIntoView();return}set_store_value(revalidatingSettings,$revalidatingSettings=true,$revalidatingSettings);const statePromise=state.resumePeriodicFetch();result.bucketSource=bucketSource;result.initialSettings=initialSettings;dispatch("routeEvent",{event:"settings.save",data:result,default:"/"});await statePromise;set_store_value(revalidatingSettings,$revalidatingSettings=false,$revalidatingSettings)}onMount((()=>{if(!newRegionDefined&&(newRegion.length===0||!$storage_provider.regions.hasOwnProperty(newRegion))){$$invalidate(8,newRegion=Object.keys($storage_provider.regions)[0])}}));const writable_props=[];Object_1$5.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<BucketSettingsSubPage> was created with unknown prop '${key}'`)}));function radiobutton0_selected_binding(value){enterOrSelectExisting=value;$$invalidate(1,enterOrSelectExisting)}function radiobutton1_selected_binding(value){enterOrSelectExisting=value;$$invalidate(1,enterOrSelectExisting)}function input_input_handler(){newBucket=this.value;$$invalidate(2,newBucket)}function select_change_handler(){newRegion=select_value(this);$$invalidate(8,newRegion)}function select_change_handler_1(){newRegion=select_value(this);$$invalidate(8,newRegion)}const click_handler=bucket=>$$invalidate(2,newBucket=bucket.Name);function input_input_handler_1(){newBucket=this.value;$$invalidate(2,newBucket)}function select_change_handler_2(){newRegion=select_value(this);$$invalidate(8,newRegion)}$$self.$capture_state=()=>({createEventDispatcher:createEventDispatcher,getContext:getContext,hasContext:hasContext,onMount:onMount,writable:writable,slide:slide,api:api,settings:settings,defined_settings:defined_settings,strings:strings,storage_provider:storage_provider,urls:urls,current_settings:current_settings,needs_refresh:needs_refresh,revalidatingSettings:revalidatingSettings,state:state,scrollIntoView:scrollIntoView,scrollNotificationsIntoView:scrollNotificationsIntoView,needsRefresh:needsRefresh,SubPage:SubPage,Panel:Panel,PanelRow:PanelRow,TabButton:TabButton,BackNextButtonsRow:BackNextButtonsRow,RadioButton:RadioButton,Loading:Loading,DefinedInWPConfig:DefinedInWPConfig,dispatch:dispatch,settingsLocked:settingsLocked,initialSettings:initialSettings,saving:saving,previousSettings:previousSettings,previousDefines:previousDefines,bucketSource:bucketSource,enterOrSelectExisting:enterOrSelectExisting,newBucket:newBucket,newRegion:newRegion,handleExisting:handleExisting,handleNew:handleNew,getBuckets:getBuckets,createBucket:createBucket,getInvalidBucketNameMessage:getInvalidBucketNameMessage,getNextText:getNextText,handleNext:handleNext,newRegionDefined:newRegionDefined,nextText:nextText,invalidBucketNameMessage:invalidBucketNameMessage,disabled:disabled,newRegionDisabled:newRegionDisabled,defined:defined,$storage_provider:$storage_provider,$revalidatingSettings:$revalidatingSettings,$settings:$settings,$strings:$strings,$settingsLocked:$settingsLocked,$needs_refresh:$needs_refresh,$defined_settings:$defined_settings,$current_settings:$current_settings,$urls:$urls});$$self.$inject_state=$$props=>{if("settingsLocked"in $$props)$$subscribe_settingsLocked($$invalidate(7,settingsLocked=$$props.settingsLocked));if("initialSettings"in $$props)initialSettings=$$props.initialSettings;if("saving"in $$props)$$invalidate(20,saving=$$props.saving);if("bucketSource"in $$props)$$invalidate(0,bucketSource=$$props.bucketSource);if("enterOrSelectExisting"in $$props)$$invalidate(1,enterOrSelectExisting=$$props.enterOrSelectExisting);if("newBucket"in $$props)$$invalidate(2,newBucket=$$props.newBucket);if("newRegion"in $$props)$$invalidate(8,newRegion=$$props.newRegion);if("newRegionDefined"in $$props)$$invalidate(3,newRegionDefined=$$props.newRegionDefined);if("nextText"in $$props)$$invalidate(9,nextText=$$props.nextText);if("invalidBucketNameMessage"in $$props)$$invalidate(10,invalidBucketNameMessage=$$props.invalidBucketNameMessage);if("disabled"in $$props)$$invalidate(11,disabled=$$props.disabled);if("newRegionDisabled"in $$props)$$invalidate(12,newRegionDisabled=$$props.newRegionDisabled);if("defined"in $$props)$$invalidate(4,defined=$$props.defined)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty[0]&7340096){{set_store_value(needs_refresh,$needs_refresh=$needs_refresh||needsRefresh(saving,previousSettings,$current_settings,previousDefines,$defined_settings),$needs_refresh)}}if($$self.$$.dirty[0]&2097152){$$invalidate(4,defined=$defined_settings.includes("bucket"))}if($$self.$$.dirty[0]&112){$$invalidate(11,disabled=defined||$needs_refresh||$settingsLocked)}if($$self.$$.dirty[0]&2097152){$$invalidate(3,newRegionDefined=$defined_settings.includes("region"))}if($$self.$$.dirty[0]&104){$$invalidate(12,newRegionDisabled=newRegionDefined||$needs_refresh||$settingsLocked)}if($$self.$$.dirty[0]&7){$$invalidate(10,invalidBucketNameMessage=getInvalidBucketNameMessage(newBucket,bucketSource,enterOrSelectExisting))}if($$self.$$.dirty[0]&3){$$invalidate(9,nextText=getNextText(bucketSource,enterOrSelectExisting))}};return[bucketSource,enterOrSelectExisting,newBucket,newRegionDefined,defined,$settingsLocked,$needs_refresh,settingsLocked,newRegion,nextText,invalidBucketNameMessage,disabled,newRegionDisabled,$storage_provider,$strings,$urls,handleExisting,handleNew,getBuckets,handleNext,saving,$defined_settings,$current_settings,radiobutton0_selected_binding,radiobutton1_selected_binding,input_input_handler,select_change_handler,select_change_handler_1,click_handler,input_input_handler_1,select_change_handler_2]}class BucketSettingsSubPage extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$C,create_fragment$C,safe_not_equal,{},null,[-1,-1]);dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"BucketSettingsSubPage",options:options,id:create_fragment$C.name})}}const file$x="ui/components/Checkbox.svelte";function create_fragment$B(ctx){let div;let label;let input;let t;let current;let mounted;let dispose;const default_slot_template=ctx[4].default;const default_slot=create_slot(default_slot_template,ctx,ctx[3],null);const block={c:function create(){div=element("div");label=element("label");input=element("input");t=space();if(default_slot)default_slot.c();attr_dev(input,"type","checkbox");attr_dev(input,"id",ctx[1]);input.disabled=ctx[2];add_location(input,file$x,8,2,207);attr_dev(label,"class","toggle-label");attr_dev(label,"for",ctx[1]);add_location(label,file$x,7,1,165);attr_dev(div,"class","checkbox");toggle_class(div,"locked",ctx[2]);toggle_class(div,"disabled",ctx[2]);add_location(div,file$x,6,0,102)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,div,anchor);append_dev(div,label);append_dev(label,input);input.checked=ctx[0];append_dev(label,t);if(default_slot){default_slot.m(label,null)}current=true;if(!mounted){dispose=listen_dev(input,"change",ctx[5]);mounted=true}},p:function update(ctx,[dirty]){if(!current||dirty&2){attr_dev(input,"id",ctx[1])}if(!current||dirty&4){prop_dev(input,"disabled",ctx[2])}if(dirty&1){input.checked=ctx[0]}if(default_slot){if(default_slot.p&&(!current||dirty&8)){update_slot_base(default_slot,default_slot_template,ctx,ctx[3],!current?get_all_dirty_from_scope(ctx[3]):get_slot_changes(default_slot_template,ctx[3],dirty,null),null)}}if(!current||dirty&2){attr_dev(label,"for",ctx[1])}if(!current||dirty&4){toggle_class(div,"locked",ctx[2])}if(!current||dirty&4){toggle_class(div,"disabled",ctx[2])}},i:function intro(local){if(current)return;transition_in(default_slot,local);current=true},o:function outro(local){transition_out(default_slot,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(div)}if(default_slot)default_slot.d(detaching);mounted=false;dispose()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$B.name,type:"component",source:"",ctx:ctx});return block}function instance$B($$self,$$props,$$invalidate){let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("Checkbox",slots,["default"]);let{name:name=""}=$$props;let{checked:checked=false}=$$props;let{disabled:disabled=false}=$$props;const writable_props=["name","checked","disabled"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<Checkbox> was created with unknown prop '${key}'`)}));function input_change_handler(){checked=this.checked;$$invalidate(0,checked)}$$self.$$set=$$props=>{if("name"in $$props)$$invalidate(1,name=$$props.name);if("checked"in $$props)$$invalidate(0,checked=$$props.checked);if("disabled"in $$props)$$invalidate(2,disabled=$$props.disabled);if("$$scope"in $$props)$$invalidate(3,$$scope=$$props.$$scope)};$$self.$capture_state=()=>({name:name,checked:checked,disabled:disabled});$$self.$inject_state=$$props=>{if("name"in $$props)$$invalidate(1,name=$$props.name);if("checked"in $$props)$$invalidate(0,checked=$$props.checked);if("disabled"in $$props)$$invalidate(2,disabled=$$props.disabled)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[checked,name,disabled,$$scope,slots,input_change_handler]}class Checkbox extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$B,create_fragment$B,safe_not_equal,{name:1,checked:0,disabled:2});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"Checkbox",options:options,id:create_fragment$B.name})}get name(){throw new Error("<Checkbox>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set name(value){throw new Error("<Checkbox>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get checked(){throw new Error("<Checkbox>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set checked(value){throw new Error("<Checkbox>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get disabled(){throw new Error("<Checkbox>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set disabled(value){throw new Error("<Checkbox>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$w="ui/components/SecuritySubPage.svelte";function create_else_block_1$5(ctx){let p0;let raw0_value=ctx[12].block_public_access_disabled_sub+"";let t0;let p1;let html_tag;let raw1_value=ctx[7].block_public_access_disabled_unsupported_desc+"";let t1;let html_tag_1;let raw2_value=ctx[13].block_public_access_disabled_unsupported_desc+"";const block={c:function create(){p0=element("p");t0=space();p1=element("p");html_tag=new HtmlTag(false);t1=space();html_tag_1=new HtmlTag(false);add_location(p0,file$w,232,4,7335);html_tag.a=t1;html_tag_1.a=null;add_location(p1,file$w,233,4,7396)},m:function mount(target,anchor){insert_dev(target,p0,anchor);p0.innerHTML=raw0_value;insert_dev(target,t0,anchor);insert_dev(target,p1,anchor);html_tag.m(raw1_value,p1);append_dev(p1,t1);html_tag_1.m(raw2_value,p1)},p:function update(ctx,dirty){if(dirty&4096&&raw0_value!==(raw0_value=ctx[12].block_public_access_disabled_sub+""))p0.innerHTML=raw0_value;if(dirty&128&&raw1_value!==(raw1_value=ctx[7].block_public_access_disabled_unsupported_desc+""))html_tag.p(raw1_value);if(dirty&8192&&raw2_value!==(raw2_value=ctx[13].block_public_access_disabled_unsupported_desc+""))html_tag_1.p(raw2_value)},d:function destroy(detaching){if(detaching){detach_dev(p0);detach_dev(t0);detach_dev(p1)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block_1$5.name,type:"else",source:"(232:3) {:else}",ctx:ctx});return block}function create_if_block_9$1(ctx){let p0;let raw0_value=ctx[12].block_public_access_disabled_sub+"";let t0;let p1;let html_tag;let raw1_value=ctx[7].block_public_access_disabled_supported_desc+"";let t1;let html_tag_1;let raw2_value=ctx[13].block_public_access_disabled_supported_desc+"";const block={c:function create(){p0=element("p");t0=space();p1=element("p");html_tag=new HtmlTag(false);t1=space();html_tag_1=new HtmlTag(false);add_location(p0,file$w,229,4,7111);html_tag.a=t1;html_tag_1.a=null;add_location(p1,file$w,230,4,7172)},m:function mount(target,anchor){insert_dev(target,p0,anchor);p0.innerHTML=raw0_value;insert_dev(target,t0,anchor);insert_dev(target,p1,anchor);html_tag.m(raw1_value,p1);append_dev(p1,t1);html_tag_1.m(raw2_value,p1)},p:function update(ctx,dirty){if(dirty&4096&&raw0_value!==(raw0_value=ctx[12].block_public_access_disabled_sub+""))p0.innerHTML=raw0_value;if(dirty&128&&raw1_value!==(raw1_value=ctx[7].block_public_access_disabled_supported_desc+""))html_tag.p(raw1_value);if(dirty&8192&&raw2_value!==(raw2_value=ctx[13].block_public_access_disabled_supported_desc+""))html_tag_1.p(raw2_value)},d:function destroy(detaching){if(detaching){detach_dev(p0);detach_dev(t0);detach_dev(p1)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_9$1.name,type:"if",source:"(229:109) ",ctx:ctx});return block}function create_if_block_8$1(ctx){let p0;let raw0_value=ctx[12].block_public_access_enabled_sub+"";let t0;let p1;let html_tag;let raw1_value=ctx[7].block_public_access_enabled_unsupported_desc+"";let t1;let html_tag_1;let raw2_value=ctx[13].block_public_access_enabled_unsupported_desc+"";const block={c:function create(){p0=element("p");t0=space();p1=element("p");html_tag=new HtmlTag(false);t1=space();html_tag_1=new HtmlTag(false);add_location(p0,file$w,226,4,6787);html_tag.a=t1;html_tag_1.a=null;add_location(p1,file$w,227,4,6847)},m:function mount(target,anchor){insert_dev(target,p0,anchor);p0.innerHTML=raw0_value;insert_dev(target,t0,anchor);insert_dev(target,p1,anchor);html_tag.m(raw1_value,p1);append_dev(p1,t1);html_tag_1.m(raw2_value,p1)},p:function update(ctx,dirty){if(dirty&4096&&raw0_value!==(raw0_value=ctx[12].block_public_access_enabled_sub+""))p0.innerHTML=raw0_value;if(dirty&128&&raw1_value!==(raw1_value=ctx[7].block_public_access_enabled_unsupported_desc+""))html_tag.p(raw1_value);if(dirty&8192&&raw2_value!==(raw2_value=ctx[13].block_public_access_enabled_unsupported_desc+""))html_tag_1.p(raw2_value)},d:function destroy(detaching){if(detaching){detach_dev(p0);detach_dev(t0);detach_dev(p1)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_8$1.name,type:"if",source:"(226:109) ",ctx:ctx});return block}function create_if_block_7$1(ctx){let p0;let raw0_value=ctx[12].block_public_access_enabled_sub+"";let t0;let p1;let html_tag;let raw1_value=ctx[7].block_public_access_enabled_supported_desc+"";let t1;let html_tag_1;let raw2_value=ctx[13].block_public_access_enabled_supported_desc+"";const block={c:function create(){p0=element("p");t0=space();p1=element("p");html_tag=new HtmlTag(false);t1=space();html_tag_1=new HtmlTag(false);add_location(p0,file$w,223,4,6467);html_tag.a=t1;html_tag_1.a=null;add_location(p1,file$w,224,4,6527)},m:function mount(target,anchor){insert_dev(target,p0,anchor);p0.innerHTML=raw0_value;insert_dev(target,t0,anchor);insert_dev(target,p1,anchor);html_tag.m(raw1_value,p1);append_dev(p1,t1);html_tag_1.m(raw2_value,p1)},p:function update(ctx,dirty){if(dirty&4096&&raw0_value!==(raw0_value=ctx[12].block_public_access_enabled_sub+""))p0.innerHTML=raw0_value;if(dirty&128&&raw1_value!==(raw1_value=ctx[7].block_public_access_enabled_supported_desc+""))html_tag.p(raw1_value);if(dirty&8192&&raw2_value!==(raw2_value=ctx[13].block_public_access_enabled_supported_desc+""))html_tag_1.p(raw2_value)},d:function destroy(detaching){if(detaching){detach_dev(p0);detach_dev(t0);detach_dev(p1)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_7$1.name,type:"if",source:"(223:108) ",ctx:ctx});return block}function create_if_block_6$1(ctx){let p0;let raw0_value=ctx[12].block_public_access_enabled_setup_sub+"";let t0;let p1;let html_tag;let raw1_value=ctx[7].block_public_access_enabled_unsupported_setup_desc+"";let t1;let html_tag_1;let raw2_value=ctx[13].block_public_access_enabled_unsupported_setup_desc+"";const block={c:function create(){p0=element("p");t0=space();p1=element("p");html_tag=new HtmlTag(false);t1=space();html_tag_1=new HtmlTag(false);add_location(p0,file$w,220,4,6126);html_tag.a=t1;html_tag_1.a=null;add_location(p1,file$w,221,4,6192)},m:function mount(target,anchor){insert_dev(target,p0,anchor);p0.innerHTML=raw0_value;insert_dev(target,t0,anchor);insert_dev(target,p1,anchor);html_tag.m(raw1_value,p1);append_dev(p1,t1);html_tag_1.m(raw2_value,p1)},p:function update(ctx,dirty){if(dirty&4096&&raw0_value!==(raw0_value=ctx[12].block_public_access_enabled_setup_sub+""))p0.innerHTML=raw0_value;if(dirty&128&&raw1_value!==(raw1_value=ctx[7].block_public_access_enabled_unsupported_setup_desc+""))html_tag.p(raw1_value);if(dirty&8192&&raw2_value!==(raw2_value=ctx[13].block_public_access_enabled_unsupported_setup_desc+""))html_tag_1.p(raw2_value)},d:function destroy(detaching){if(detaching){detach_dev(p0);detach_dev(t0);detach_dev(p1)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_6$1.name,type:"if",source:'(220:3) {#if initialSetup && $current_settings[ \\"block-public-access\\" ] && !$delivery_provider.block_public_access_supported}',ctx:ctx});return block}function create_default_slot_8$1(ctx){let if_block_anchor;function select_block_type(ctx,dirty){if(ctx[9]&&ctx[4]["block-public-access"]&&!ctx[7].block_public_access_supported)return create_if_block_6$1;if(ctx[4]["block-public-access"]&&ctx[7].block_public_access_supported)return create_if_block_7$1;if(ctx[4]["block-public-access"]&&!ctx[7].block_public_access_supported)return create_if_block_8$1;if(!ctx[4]["block-public-access"]&&ctx[7].block_public_access_supported)return create_if_block_9$1;return create_else_block_1$5}let current_block_type=select_block_type(ctx);let if_block=current_block_type(ctx);const block={c:function create(){if_block.c();if_block_anchor=empty()},m:function mount(target,anchor){if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor)},p:function update(ctx,dirty){if(current_block_type===(current_block_type=select_block_type(ctx))&&if_block){if_block.p(ctx,dirty)}else{if_block.d(1);if_block=current_block_type(ctx);if(if_block){if_block.c();if_block.m(if_block_anchor.parentNode,if_block_anchor)}}},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_8$1.name,type:"slot",source:'(219:2) <PanelRow class=\\"body flex-column\\">',ctx:ctx});return block}function create_if_block_5$1(ctx){let div;let panelrow;let div_transition;let current;panelrow=new PanelRow({props:{class:"body flex-column toggle-reveal",footer:true,$$slots:{default:[create_default_slot_6$1]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){div=element("div");create_component(panelrow.$$.fragment);add_location(div,file$w,237,3,7699)},m:function mount(target,anchor){insert_dev(target,div,anchor);mount_component(panelrow,div,null);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty&268435682){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);if(local){add_render_callback((()=>{if(!current)return;if(!div_transition)div_transition=create_bidirectional_transition(div,slide,{},true);div_transition.run(1)}))}current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);if(local){if(!div_transition)div_transition=create_bidirectional_transition(div,slide,{},false);div_transition.run(0)}current=false},d:function destroy(detaching){if(detaching){detach_dev(div)}destroy_component(panelrow);if(detaching&&div_transition)div_transition.end()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_5$1.name,type:"if",source:'(237:2) {#if !$current_settings[ \\"block-public-access\\" ] && blockPublicAccess && $delivery_provider.block_public_access_supported}',ctx:ctx});return block}function create_default_slot_7$1(ctx){let html_tag;let raw_value=ctx[7].block_public_access_confirm_setup_prompt+"";let html_anchor;const block={c:function create(){html_tag=new HtmlTag(false);html_anchor=empty();html_tag.a=html_anchor},m:function mount(target,anchor){html_tag.m(raw_value,target,anchor);insert_dev(target,html_anchor,anchor)},p:function update(ctx,dirty){if(dirty&128&&raw_value!==(raw_value=ctx[7].block_public_access_confirm_setup_prompt+""))html_tag.p(raw_value)},d:function destroy(detaching){if(detaching){detach_dev(html_anchor);html_tag.d()}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_7$1.name,type:"slot",source:'(240:5) <Checkbox name=\\"confirm-setup-bapa-oai\\" bind:checked={bapaSetupConfirmed} disabled={$needs_refresh || $settingsLocked}>',ctx:ctx});return block}function create_default_slot_6$1(ctx){let checkbox;let updating_checked;let current;function checkbox_checked_binding(value){ctx[17](value)}let checkbox_props={name:"confirm-setup-bapa-oai",disabled:ctx[6]||ctx[5],$$slots:{default:[create_default_slot_7$1]},$$scope:{ctx:ctx}};if(ctx[1]!==void 0){checkbox_props.checked=ctx[1]}checkbox=new Checkbox({props:checkbox_props,$$inline:true});binding_callbacks.push((()=>bind(checkbox,"checked",checkbox_checked_binding)));const block={c:function create(){create_component(checkbox.$$.fragment)},m:function mount(target,anchor){mount_component(checkbox,target,anchor);current=true},p:function update(ctx,dirty){const checkbox_changes={};if(dirty&96)checkbox_changes.disabled=ctx[6]||ctx[5];if(dirty&268435584){checkbox_changes.$$scope={dirty:dirty,ctx:ctx}}if(!updating_checked&&dirty&2){updating_checked=true;checkbox_changes.checked=ctx[1];add_flush_callback((()=>updating_checked=false))}checkbox.$set(checkbox_changes)},i:function intro(local){if(current)return;transition_in(checkbox.$$.fragment,local);current=true},o:function outro(local){transition_out(checkbox.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(checkbox,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_6$1.name,type:"slot",source:'(239:4) <PanelRow class=\\"body flex-column toggle-reveal\\" footer>',ctx:ctx});return block}function create_default_slot_5$1(ctx){let panelrow;let t;let if_block_anchor;let current;panelrow=new PanelRow({props:{class:"body flex-column",$$slots:{default:[create_default_slot_8$1]},$$scope:{ctx:ctx}},$$inline:true});let if_block=!ctx[4]["block-public-access"]&&ctx[0]&&ctx[7].block_public_access_supported&&create_if_block_5$1(ctx);const block={c:function create(){create_component(panelrow.$$.fragment);t=space();if(if_block)if_block.c();if_block_anchor=empty()},m:function mount(target,anchor){mount_component(panelrow,target,anchor);insert_dev(target,t,anchor);if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty&268448400){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes);if(!ctx[4]["block-public-access"]&&ctx[0]&&ctx[7].block_public_access_supported){if(if_block){if_block.p(ctx,dirty);if(dirty&145){transition_in(if_block,1)}}else{if_block=create_if_block_5$1(ctx);if_block.c();transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);transition_in(if_block);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(t);detach_dev(if_block_anchor)}destroy_component(panelrow,detaching);if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_5$1.name,type:"slot",source:'(211:1) <Panel class=\\"toggle-header\\" heading={$strings.block_public_access_title} toggleName=\\"block-public-access\\" bind:toggle={blockPublicAccess} helpKey=\\"block-public-access\\" multi >',ctx:ctx});return block}function create_else_block$a(ctx){let p0;let raw0_value=ctx[12].object_ownership_not_enforced_sub+"";let t0;let p1;let html_tag;let raw1_value=ctx[7].object_ownership_not_enforced_unsupported_desc+"";let t1;let html_tag_1;let raw2_value=ctx[13].object_ownership_not_enforced_unsupported_desc+"";const block={c:function create(){p0=element("p");t0=space();p1=element("p");html_tag=new HtmlTag(false);t1=space();html_tag_1=new HtmlTag(false);add_location(p0,file$w,267,4,9606);html_tag.a=t1;html_tag_1.a=null;add_location(p1,file$w,268,4,9668)},m:function mount(target,anchor){insert_dev(target,p0,anchor);p0.innerHTML=raw0_value;insert_dev(target,t0,anchor);insert_dev(target,p1,anchor);html_tag.m(raw1_value,p1);append_dev(p1,t1);html_tag_1.m(raw2_value,p1)},p:function update(ctx,dirty){if(dirty&4096&&raw0_value!==(raw0_value=ctx[12].object_ownership_not_enforced_sub+""))p0.innerHTML=raw0_value;if(dirty&128&&raw1_value!==(raw1_value=ctx[7].object_ownership_not_enforced_unsupported_desc+""))html_tag.p(raw1_value);if(dirty&8192&&raw2_value!==(raw2_value=ctx[13].object_ownership_not_enforced_unsupported_desc+""))html_tag_1.p(raw2_value)},d:function destroy(detaching){if(detaching){detach_dev(p0);detach_dev(t0);detach_dev(p1)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block$a.name,type:"else",source:"(267:3) {:else}",ctx:ctx});return block}function create_if_block_4$2(ctx){let p0;let raw0_value=ctx[12].object_ownership_not_enforced_sub+"";let t0;let p1;let html_tag;let raw1_value=ctx[7].object_ownership_not_enforced_supported_desc+"";let t1;let html_tag_1;let raw2_value=ctx[13].object_ownership_not_enforced_supported_desc+"";const block={c:function create(){p0=element("p");t0=space();p1=element("p");html_tag=new HtmlTag(false);t1=space();html_tag_1=new HtmlTag(false);add_location(p0,file$w,264,4,9379);html_tag.a=t1;html_tag_1.a=null;add_location(p1,file$w,265,4,9441)},m:function mount(target,anchor){insert_dev(target,p0,anchor);p0.innerHTML=raw0_value;insert_dev(target,t0,anchor);insert_dev(target,p1,anchor);html_tag.m(raw1_value,p1);append_dev(p1,t1);html_tag_1.m(raw2_value,p1)},p:function update(ctx,dirty){if(dirty&4096&&raw0_value!==(raw0_value=ctx[12].object_ownership_not_enforced_sub+""))p0.innerHTML=raw0_value;if(dirty&128&&raw1_value!==(raw1_value=ctx[7].object_ownership_not_enforced_supported_desc+""))html_tag.p(raw1_value);if(dirty&8192&&raw2_value!==(raw2_value=ctx[13].object_ownership_not_enforced_supported_desc+""))html_tag_1.p(raw2_value)},d:function destroy(detaching){if(detaching){detach_dev(p0);detach_dev(t0);detach_dev(p1)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_4$2.name,type:"if",source:"(264:112) ",ctx:ctx});return block}function create_if_block_3$2(ctx){let p0;let raw0_value=ctx[12].object_ownership_enforced_sub+"";let t0;let p1;let html_tag;let raw1_value=ctx[7].object_ownership_enforced_unsupported_desc+"";let t1;let html_tag_1;let raw2_value=ctx[13].object_ownership_enforced_unsupported_desc+"";const block={c:function create(){p0=element("p");t0=space();p1=element("p");html_tag=new HtmlTag(false);t1=space();html_tag_1=new HtmlTag(false);add_location(p0,file$w,261,4,9058);html_tag.a=t1;html_tag_1.a=null;add_location(p1,file$w,262,4,9116)},m:function mount(target,anchor){insert_dev(target,p0,anchor);p0.innerHTML=raw0_value;insert_dev(target,t0,anchor);insert_dev(target,p1,anchor);html_tag.m(raw1_value,p1);append_dev(p1,t1);html_tag_1.m(raw2_value,p1)},p:function update(ctx,dirty){if(dirty&4096&&raw0_value!==(raw0_value=ctx[12].object_ownership_enforced_sub+""))p0.innerHTML=raw0_value;if(dirty&128&&raw1_value!==(raw1_value=ctx[7].object_ownership_enforced_unsupported_desc+""))html_tag.p(raw1_value);if(dirty&8192&&raw2_value!==(raw2_value=ctx[13].object_ownership_enforced_unsupported_desc+""))html_tag_1.p(raw2_value)},d:function destroy(detaching){if(detaching){detach_dev(p0);detach_dev(t0);detach_dev(p1)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_3$2.name,type:"if",source:"(261:112) ",ctx:ctx});return block}function create_if_block_2$3(ctx){let p0;let raw0_value=ctx[12].object_ownership_enforced_sub+"";let t0;let p1;let html_tag;let raw1_value=ctx[7].object_ownership_enforced_supported_desc+"";let t1;let html_tag_1;let raw2_value=ctx[13].object_ownership_enforced_supported_desc+"";const block={c:function create(){p0=element("p");t0=space();p1=element("p");html_tag=new HtmlTag(false);t1=space();html_tag_1=new HtmlTag(false);add_location(p0,file$w,258,4,8741);html_tag.a=t1;html_tag_1.a=null;add_location(p1,file$w,259,4,8799)},m:function mount(target,anchor){insert_dev(target,p0,anchor);p0.innerHTML=raw0_value;insert_dev(target,t0,anchor);insert_dev(target,p1,anchor);html_tag.m(raw1_value,p1);append_dev(p1,t1);html_tag_1.m(raw2_value,p1)},p:function update(ctx,dirty){if(dirty&4096&&raw0_value!==(raw0_value=ctx[12].object_ownership_enforced_sub+""))p0.innerHTML=raw0_value;if(dirty&128&&raw1_value!==(raw1_value=ctx[7].object_ownership_enforced_supported_desc+""))html_tag.p(raw1_value);if(dirty&8192&&raw2_value!==(raw2_value=ctx[13].object_ownership_enforced_supported_desc+""))html_tag_1.p(raw2_value)},d:function destroy(detaching){if(detaching){detach_dev(p0);detach_dev(t0);detach_dev(p1)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_2$3.name,type:"if",source:"(258:111) ",ctx:ctx});return block}function create_if_block_1$9(ctx){let p0;let raw0_value=ctx[12].object_ownership_enforced_setup_sub+"";let t0;let p1;let html_tag;let raw1_value=ctx[7].object_ownership_enforced_unsupported_setup_desc+"";let t1;let html_tag_1;let raw2_value=ctx[13].object_ownership_enforced_unsupported_setup_desc+"";const block={c:function create(){p0=element("p");t0=space();p1=element("p");html_tag=new HtmlTag(false);t1=space();html_tag_1=new HtmlTag(false);add_location(p0,file$w,255,4,8403);html_tag.a=t1;html_tag_1.a=null;add_location(p1,file$w,256,4,8467)},m:function mount(target,anchor){insert_dev(target,p0,anchor);p0.innerHTML=raw0_value;insert_dev(target,t0,anchor);insert_dev(target,p1,anchor);html_tag.m(raw1_value,p1);append_dev(p1,t1);html_tag_1.m(raw2_value,p1)},p:function update(ctx,dirty){if(dirty&4096&&raw0_value!==(raw0_value=ctx[12].object_ownership_enforced_setup_sub+""))p0.innerHTML=raw0_value;if(dirty&128&&raw1_value!==(raw1_value=ctx[7].object_ownership_enforced_unsupported_setup_desc+""))html_tag.p(raw1_value);if(dirty&8192&&raw2_value!==(raw2_value=ctx[13].object_ownership_enforced_unsupported_setup_desc+""))html_tag_1.p(raw2_value)},d:function destroy(detaching){if(detaching){detach_dev(p0);detach_dev(t0);detach_dev(p1)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_1$9.name,type:"if",source:'(255:3) {#if initialSetup && $current_settings[ \\"object-ownership-enforced\\" ] && !$delivery_provider.object_ownership_supported}',ctx:ctx});return block}function create_default_slot_4$3(ctx){let if_block_anchor;function select_block_type_1(ctx,dirty){if(ctx[9]&&ctx[4]["object-ownership-enforced"]&&!ctx[7].object_ownership_supported)return create_if_block_1$9;if(ctx[4]["object-ownership-enforced"]&&ctx[7].object_ownership_supported)return create_if_block_2$3;if(ctx[4]["object-ownership-enforced"]&&!ctx[7].object_ownership_supported)return create_if_block_3$2;if(!ctx[4]["object-ownership-enforced"]&&ctx[7].object_ownership_supported)return create_if_block_4$2;return create_else_block$a}let current_block_type=select_block_type_1(ctx);let if_block=current_block_type(ctx);const block={c:function create(){if_block.c();if_block_anchor=empty()},m:function mount(target,anchor){if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor)},p:function update(ctx,dirty){if(current_block_type===(current_block_type=select_block_type_1(ctx))&&if_block){if_block.p(ctx,dirty)}else{if_block.d(1);if_block=current_block_type(ctx);if(if_block){if_block.c();if_block.m(if_block_anchor.parentNode,if_block_anchor)}}},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_4$3.name,type:"slot",source:'(254:2) <PanelRow class=\\"body flex-column\\">',ctx:ctx});return block}function create_if_block$g(ctx){let div;let panelrow;let div_transition;let current;panelrow=new PanelRow({props:{class:"body flex-column toggle-reveal",$$slots:{default:[create_default_slot_2$d]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){div=element("div");create_component(panelrow.$$.fragment);add_location(div,file$w,272,3,9982)},m:function mount(target,anchor){insert_dev(target,div,anchor);mount_component(panelrow,div,null);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty&268435688){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);if(local){add_render_callback((()=>{if(!current)return;if(!div_transition)div_transition=create_bidirectional_transition(div,slide,{},true);div_transition.run(1)}))}current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);if(local){if(!div_transition)div_transition=create_bidirectional_transition(div,slide,{},false);div_transition.run(0)}current=false},d:function destroy(detaching){if(detaching){detach_dev(div)}destroy_component(panelrow);if(detaching&&div_transition)div_transition.end()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$g.name,type:"if",source:'(272:2) {#if !$current_settings[ \\"object-ownership-enforced\\" ] && objectOwnershipEnforced && $delivery_provider.object_ownership_supported}',ctx:ctx});return block}function create_default_slot_3$4(ctx){let html_tag;let raw_value=ctx[7].object_ownership_confirm_setup_prompt+"";let html_anchor;const block={c:function create(){html_tag=new HtmlTag(false);html_anchor=empty();html_tag.a=html_anchor},m:function mount(target,anchor){html_tag.m(raw_value,target,anchor);insert_dev(target,html_anchor,anchor)},p:function update(ctx,dirty){if(dirty&128&&raw_value!==(raw_value=ctx[7].object_ownership_confirm_setup_prompt+""))html_tag.p(raw_value)},d:function destroy(detaching){if(detaching){detach_dev(html_anchor);html_tag.d()}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_3$4.name,type:"slot",source:'(275:5) <Checkbox name=\\"confirm-setup-ooe-oai\\" bind:checked={ooeSetupConfirmed} disabled={$needs_refresh || $settingsLocked}>',ctx:ctx});return block}function create_default_slot_2$d(ctx){let checkbox;let updating_checked;let current;function checkbox_checked_binding_1(value){ctx[19](value)}let checkbox_props={name:"confirm-setup-ooe-oai",disabled:ctx[6]||ctx[5],$$slots:{default:[create_default_slot_3$4]},$$scope:{ctx:ctx}};if(ctx[3]!==void 0){checkbox_props.checked=ctx[3]}checkbox=new Checkbox({props:checkbox_props,$$inline:true});binding_callbacks.push((()=>bind(checkbox,"checked",checkbox_checked_binding_1)));const block={c:function create(){create_component(checkbox.$$.fragment)},m:function mount(target,anchor){mount_component(checkbox,target,anchor);current=true},p:function update(ctx,dirty){const checkbox_changes={};if(dirty&96)checkbox_changes.disabled=ctx[6]||ctx[5];if(dirty&268435584){checkbox_changes.$$scope={dirty:dirty,ctx:ctx}}if(!updating_checked&&dirty&8){updating_checked=true;checkbox_changes.checked=ctx[3];add_flush_callback((()=>updating_checked=false))}checkbox.$set(checkbox_changes)},i:function intro(local){if(current)return;transition_in(checkbox.$$.fragment,local);current=true},o:function outro(local){transition_out(checkbox.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(checkbox,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_2$d.name,type:"slot",source:'(274:4) <PanelRow class=\\"body flex-column toggle-reveal\\">',ctx:ctx});return block}function create_default_slot_1$g(ctx){let panelrow;let t;let if_block_anchor;let current;panelrow=new PanelRow({props:{class:"body flex-column",$$slots:{default:[create_default_slot_4$3]},$$scope:{ctx:ctx}},$$inline:true});let if_block=!ctx[4]["object-ownership-enforced"]&&ctx[2]&&ctx[7].object_ownership_supported&&create_if_block$g(ctx);const block={c:function create(){create_component(panelrow.$$.fragment);t=space();if(if_block)if_block.c();if_block_anchor=empty()},m:function mount(target,anchor){mount_component(panelrow,target,anchor);insert_dev(target,t,anchor);if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty&268448400){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes);if(!ctx[4]["object-ownership-enforced"]&&ctx[2]&&ctx[7].object_ownership_supported){if(if_block){if_block.p(ctx,dirty);if(dirty&148){transition_in(if_block,1)}}else{if_block=create_if_block$g(ctx);if_block.c();transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);transition_in(if_block);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(t);detach_dev(if_block_anchor)}destroy_component(panelrow,detaching);if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$g.name,type:"slot",source:'(246:1) <Panel class=\\"toggle-header\\" heading={$strings.object_ownership_title} toggleName=\\"object-ownership-enforced\\" bind:toggle={objectOwnershipEnforced} helpKey=\\"object-ownership-enforced\\" multi >',ctx:ctx});return block}function create_default_slot$p(ctx){let panel0;let updating_toggle;let t0;let panel1;let updating_toggle_1;let t1;let backnextbuttonsrow;let current;function panel0_toggle_binding(value){ctx[18](value)}let panel0_props={class:"toggle-header",heading:ctx[12].block_public_access_title,toggleName:"block-public-access",helpKey:"block-public-access",multi:true,$$slots:{default:[create_default_slot_5$1]},$$scope:{ctx:ctx}};if(ctx[0]!==void 0){panel0_props.toggle=ctx[0]}panel0=new Panel({props:panel0_props,$$inline:true});binding_callbacks.push((()=>bind(panel0,"toggle",panel0_toggle_binding)));function panel1_toggle_binding(value){ctx[20](value)}let panel1_props={class:"toggle-header",heading:ctx[12].object_ownership_title,toggleName:"object-ownership-enforced",helpKey:"object-ownership-enforced",multi:true,$$slots:{default:[create_default_slot_1$g]},$$scope:{ctx:ctx}};if(ctx[2]!==void 0){panel1_props.toggle=ctx[2]}panel1=new Panel({props:panel1_props,$$inline:true});binding_callbacks.push((()=>bind(panel1,"toggle",panel1_toggle_binding)));backnextbuttonsrow=new BackNextButtonsRow({props:{nextText:ctx[11],nextDisabled:ctx[10]},$$inline:true});backnextbuttonsrow.$on("next",ctx[14]);const block={c:function create(){create_component(panel0.$$.fragment);t0=space();create_component(panel1.$$.fragment);t1=space();create_component(backnextbuttonsrow.$$.fragment)},m:function mount(target,anchor){mount_component(panel0,target,anchor);insert_dev(target,t0,anchor);mount_component(panel1,target,anchor);insert_dev(target,t1,anchor);mount_component(backnextbuttonsrow,target,anchor);current=true},p:function update(ctx,dirty){const panel0_changes={};if(dirty&4096)panel0_changes.heading=ctx[12].block_public_access_title;if(dirty&268448499){panel0_changes.$$scope={dirty:dirty,ctx:ctx}}if(!updating_toggle&&dirty&1){updating_toggle=true;panel0_changes.toggle=ctx[0];add_flush_callback((()=>updating_toggle=false))}panel0.$set(panel0_changes);const panel1_changes={};if(dirty&4096)panel1_changes.heading=ctx[12].object_ownership_title;if(dirty&268448508){panel1_changes.$$scope={dirty:dirty,ctx:ctx}}if(!updating_toggle_1&&dirty&4){updating_toggle_1=true;panel1_changes.toggle=ctx[2];add_flush_callback((()=>updating_toggle_1=false))}panel1.$set(panel1_changes);const backnextbuttonsrow_changes={};if(dirty&2048)backnextbuttonsrow_changes.nextText=ctx[11];if(dirty&1024)backnextbuttonsrow_changes.nextDisabled=ctx[10];backnextbuttonsrow.$set(backnextbuttonsrow_changes)},i:function intro(local){if(current)return;transition_in(panel0.$$.fragment,local);transition_in(panel1.$$.fragment,local);transition_in(backnextbuttonsrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panel0.$$.fragment,local);transition_out(panel1.$$.fragment,local);transition_out(backnextbuttonsrow.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(t1)}destroy_component(panel0,detaching);destroy_component(panel1,detaching);destroy_component(backnextbuttonsrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$p.name,type:"slot",source:'(210:0) <SubPage name=\\"bapa-settings\\" route=\\"/storage/security\\">',ctx:ctx});return block}function create_fragment$A(ctx){let subpage;let current;subpage=new SubPage({props:{name:"bapa-settings",route:"/storage/security",$$slots:{default:[create_default_slot$p]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(subpage.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(subpage,target,anchor);current=true},p:function update(ctx,[dirty]){const subpage_changes={};if(dirty&268451583){subpage_changes.$$scope={dirty:dirty,ctx:ctx}}subpage.$set(subpage_changes)},i:function intro(local){if(current)return;transition_in(subpage.$$.fragment,local);current=true},o:function outro(local){transition_out(subpage.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(subpage,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$A.name,type:"component",source:"",ctx:ctx});return block}function getNextDisabled(currentValue,newValue,supported,setupConfirmed,needsRefresh,settingsLocked){return needsRefresh||settingsLocked||!currentValue&&newValue&&supported&&!setupConfirmed}function instance$A($$self,$$props,$$invalidate){let nextText;let nextDisabled;let $revalidatingSettings;let $settings;let $current_settings;let $settingsLocked,$$unsubscribe_settingsLocked=noop,$$subscribe_settingsLocked=()=>($$unsubscribe_settingsLocked(),$$unsubscribe_settingsLocked=subscribe(settingsLocked,($$value=>$$invalidate(5,$settingsLocked=$$value))),settingsLocked);let $needs_refresh;let $delivery_provider;let $strings;let $defined_settings;let $storage_provider;validate_store(revalidatingSettings,"revalidatingSettings");component_subscribe($$self,revalidatingSettings,($$value=>$$invalidate(21,$revalidatingSettings=$$value)));validate_store(settings,"settings");component_subscribe($$self,settings,($$value=>$$invalidate(22,$settings=$$value)));validate_store(current_settings,"current_settings");component_subscribe($$self,current_settings,($$value=>$$invalidate(4,$current_settings=$$value)));validate_store(needs_refresh,"needs_refresh");component_subscribe($$self,needs_refresh,($$value=>$$invalidate(6,$needs_refresh=$$value)));validate_store(delivery_provider,"delivery_provider");component_subscribe($$self,delivery_provider,($$value=>$$invalidate(7,$delivery_provider=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(12,$strings=$$value)));validate_store(defined_settings,"defined_settings");component_subscribe($$self,defined_settings,($$value=>$$invalidate(16,$defined_settings=$$value)));validate_store(storage_provider,"storage_provider");component_subscribe($$self,storage_provider,($$value=>$$invalidate(13,$storage_provider=$$value)));$$self.$$.on_destroy.push((()=>$$unsubscribe_settingsLocked()));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("SecuritySubPage",slots,[]);const dispatch=createEventDispatcher();let settingsLocked=writable(false);validate_store(settingsLocked,"settingsLocked");$$subscribe_settingsLocked();if(hasContext("settingsLocked")){$$subscribe_settingsLocked(settingsLocked=getContext("settingsLocked"))}let saving=false;const previousSettings={...$current_settings};const previousDefines={...$defined_settings};let blockPublicAccess=$settings["block-public-access"];let bapaSetupConfirmed=false;let objectOwnershipEnforced=$settings["object-ownership-enforced"];let ooeSetupConfirmed=false;let initialSetup=false;if(hasContext("initialSetup")){initialSetup=getContext("initialSetup")}if(!initialSetup&&hasContext("initialSettings")&&getContext("initialSettings").provider!==$current_settings.provider){initialSetup=true}async function updateBucketProperties(){let data=await api.put("buckets",{bucket:$settings.bucket,blockPublicAccess:blockPublicAccess,objectOwnershipEnforced:objectOwnershipEnforced});if(data.hasOwnProperty("saved")){return data.saved}return false}function getNextText(bapaCurrent,bapaNew,ooeCurrent,ooeNew,needsRefresh,settingsLocked){if(needsRefresh||settingsLocked){return $strings.settings_locked}if(bapaCurrent!==bapaNew||ooeCurrent!==ooeNew){return $strings.update_bucket_security}return $strings.keep_bucket_security}async function handleNext(){if(blockPublicAccess===$current_settings["block-public-access"]&&objectOwnershipEnforced===$current_settings["object-ownership-enforced"]){dispatch("routeEvent",{event:"next",default:"/"});return}$$invalidate(15,saving=true);state.pausePeriodicFetch();const result=await updateBucketProperties();await settings.fetch();if(false===result){$$invalidate(15,saving=false);await state.resumePeriodicFetch();scrollNotificationsIntoView();return}set_store_value(revalidatingSettings,$revalidatingSettings=true,$revalidatingSettings);const statePromise=state.resumePeriodicFetch();dispatch("routeEvent",{event:"bucket-security",data:{blockPublicAccess:$settings["block-public-access"],objectOwnershipEnforced:$settings["object-ownership-enforced"]},default:"/"});await statePromise;set_store_value(revalidatingSettings,$revalidatingSettings=false,$revalidatingSettings)}const writable_props=[];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<SecuritySubPage> was created with unknown prop '${key}'`)}));function checkbox_checked_binding(value){bapaSetupConfirmed=value;$$invalidate(1,bapaSetupConfirmed)}function panel0_toggle_binding(value){blockPublicAccess=value;$$invalidate(0,blockPublicAccess)}function checkbox_checked_binding_1(value){ooeSetupConfirmed=value;$$invalidate(3,ooeSetupConfirmed)}function panel1_toggle_binding(value){objectOwnershipEnforced=value;$$invalidate(2,objectOwnershipEnforced)}$$self.$capture_state=()=>({createEventDispatcher:createEventDispatcher,getContext:getContext,hasContext:hasContext,writable:writable,slide:slide,api:api,settings:settings,strings:strings,current_settings:current_settings,storage_provider:storage_provider,delivery_provider:delivery_provider,needs_refresh:needs_refresh,revalidatingSettings:revalidatingSettings,state:state,defined_settings:defined_settings,scrollNotificationsIntoView:scrollNotificationsIntoView,needsRefresh:needsRefresh,SubPage:SubPage,Panel:Panel,PanelRow:PanelRow,BackNextButtonsRow:BackNextButtonsRow,Checkbox:Checkbox,dispatch:dispatch,settingsLocked:settingsLocked,saving:saving,previousSettings:previousSettings,previousDefines:previousDefines,blockPublicAccess:blockPublicAccess,bapaSetupConfirmed:bapaSetupConfirmed,objectOwnershipEnforced:objectOwnershipEnforced,ooeSetupConfirmed:ooeSetupConfirmed,initialSetup:initialSetup,updateBucketProperties:updateBucketProperties,getNextText:getNextText,getNextDisabled:getNextDisabled,handleNext:handleNext,nextDisabled:nextDisabled,nextText:nextText,$revalidatingSettings:$revalidatingSettings,$settings:$settings,$current_settings:$current_settings,$settingsLocked:$settingsLocked,$needs_refresh:$needs_refresh,$delivery_provider:$delivery_provider,$strings:$strings,$defined_settings:$defined_settings,$storage_provider:$storage_provider});$$self.$inject_state=$$props=>{if("settingsLocked"in $$props)$$subscribe_settingsLocked($$invalidate(8,settingsLocked=$$props.settingsLocked));if("saving"in $$props)$$invalidate(15,saving=$$props.saving);if("blockPublicAccess"in $$props)$$invalidate(0,blockPublicAccess=$$props.blockPublicAccess);if("bapaSetupConfirmed"in $$props)$$invalidate(1,bapaSetupConfirmed=$$props.bapaSetupConfirmed);if("objectOwnershipEnforced"in $$props)$$invalidate(2,objectOwnershipEnforced=$$props.objectOwnershipEnforced);if("ooeSetupConfirmed"in $$props)$$invalidate(3,ooeSetupConfirmed=$$props.ooeSetupConfirmed);if("initialSetup"in $$props)$$invalidate(9,initialSetup=$$props.initialSetup);if("nextDisabled"in $$props)$$invalidate(10,nextDisabled=$$props.nextDisabled);if("nextText"in $$props)$$invalidate(11,nextText=$$props.nextText)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty&98384){{set_store_value(needs_refresh,$needs_refresh=$needs_refresh||needsRefresh(saving,previousSettings,$current_settings,previousDefines,$defined_settings),$needs_refresh)}}if($$self.$$.dirty&117){$$invalidate(11,nextText=getNextText($current_settings["block-public-access"],blockPublicAccess,$current_settings["object-ownership-enforced"],objectOwnershipEnforced,$needs_refresh,$settingsLocked))}if($$self.$$.dirty&255){$$invalidate(10,nextDisabled=getNextDisabled($current_settings["block-public-access"],blockPublicAccess,$delivery_provider.block_public_access_supported,bapaSetupConfirmed,$needs_refresh,$settingsLocked)||getNextDisabled($current_settings["object-ownership-enforced"],objectOwnershipEnforced,$delivery_provider.object_ownership_supported,ooeSetupConfirmed,$needs_refresh,$settingsLocked))}};return[blockPublicAccess,bapaSetupConfirmed,objectOwnershipEnforced,ooeSetupConfirmed,$current_settings,$settingsLocked,$needs_refresh,$delivery_provider,settingsLocked,initialSetup,nextDisabled,nextText,$strings,$storage_provider,handleNext,saving,$defined_settings,checkbox_checked_binding,panel0_toggle_binding,checkbox_checked_binding_1,panel1_toggle_binding]}class SecuritySubPage extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$A,create_fragment$A,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"SecuritySubPage",options:options,id:create_fragment$A.name})}}const{Object:Object_1$4}=globals;const file$v="ui/components/DeliveryPage.svelte";function get_each_context$8(ctx,list,i){const child_ctx=ctx.slice();child_ctx[31]=list[i];return child_ctx}function create_each_block$8(ctx){let div;let tabbutton;let t0;let p0;let raw0_value=ctx[31].edge_server_support_desc+"";let t1;let p1;let raw1_value=ctx[31].signed_urls_support_desc+"";let t2;let helpbutton;let t3;let current;function click_handler(){return ctx[18](ctx[31])}tabbutton=new TabButton({props:{active:ctx[31].provider_key_name===ctx[1].provider_key_name,disabled:ctx[5],icon:ctx[31].icon,text:ctx[31].default_provider_service_name},$$inline:true});tabbutton.$on("click",click_handler);helpbutton=new HelpButton({props:{url:ctx[31].provider_service_quick_start_url,desc:ctx[8].view_quick_start_guide},$$inline:true});const block={c:function create(){div=element("div");create_component(tabbutton.$$.fragment);t0=space();p0=element("p");t1=space();p1=element("p");t2=space();create_component(helpbutton.$$.fragment);t3=space();attr_dev(p0,"class","speed");add_location(p0,file$v,166,6,5333);attr_dev(p1,"class","private-media");add_location(p1,file$v,167,6,5402);attr_dev(div,"class","row");add_location(div,file$v,158,5,5045)},m:function mount(target,anchor){insert_dev(target,div,anchor);mount_component(tabbutton,div,null);append_dev(div,t0);append_dev(div,p0);p0.innerHTML=raw0_value;append_dev(div,t1);append_dev(div,p1);p1.innerHTML=raw1_value;append_dev(div,t2);mount_component(helpbutton,div,null);append_dev(div,t3);current=true},p:function update(new_ctx,dirty){ctx=new_ctx;const tabbutton_changes={};if(dirty[0]&2)tabbutton_changes.active=ctx[31].provider_key_name===ctx[1].provider_key_name;if(dirty[0]&32)tabbutton_changes.disabled=ctx[5];tabbutton.$set(tabbutton_changes);const helpbutton_changes={};if(dirty[0]&256)helpbutton_changes.desc=ctx[8].view_quick_start_guide;helpbutton.$set(helpbutton_changes)},i:function intro(local){if(current)return;transition_in(tabbutton.$$.fragment,local);transition_in(helpbutton.$$.fragment,local);current=true},o:function outro(local){transition_out(tabbutton.$$.fragment,local);transition_out(helpbutton.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(div)}destroy_component(tabbutton);destroy_component(helpbutton)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_each_block$8.name,type:"each",source:"(158:4) {#each supportedDeliveryProviders() as provider}",ctx:ctx});return block}function create_default_slot_4$2(ctx){let each_1_anchor;let current;let each_value=ensure_array_like_dev(ctx[9]());let each_blocks=[];for(let i=0;i<each_value.length;i+=1){each_blocks[i]=create_each_block$8(get_each_context$8(ctx,each_value,i))}const out=i=>transition_out(each_blocks[i],1,1,(()=>{each_blocks[i]=null}));const block={c:function create(){for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].c()}each_1_anchor=empty()},m:function mount(target,anchor){for(let i=0;i<each_blocks.length;i+=1){if(each_blocks[i]){each_blocks[i].m(target,anchor)}}insert_dev(target,each_1_anchor,anchor);current=true},p:function update(ctx,dirty){if(dirty[0]&1826){each_value=ensure_array_like_dev(ctx[9]());let i;for(i=0;i<each_value.length;i+=1){const child_ctx=get_each_context$8(ctx,each_value,i);if(each_blocks[i]){each_blocks[i].p(child_ctx,dirty);transition_in(each_blocks[i],1)}else{each_blocks[i]=create_each_block$8(child_ctx);each_blocks[i].c();transition_in(each_blocks[i],1);each_blocks[i].m(each_1_anchor.parentNode,each_1_anchor)}}group_outros();for(i=each_value.length;i<each_blocks.length;i+=1){out(i)}check_outros()}},i:function intro(local){if(current)return;for(let i=0;i<each_value.length;i+=1){transition_in(each_blocks[i])}current=true},o:function outro(local){each_blocks=each_blocks.filter(Boolean);for(let i=0;i<each_blocks.length;i+=1){transition_out(each_blocks[i])}current=false},d:function destroy(detaching){if(detaching){detach_dev(each_1_anchor)}destroy_each(each_blocks,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_4$2.name,type:"slot",source:'(157:3) <PanelRow class=\\"body flex-column delivery-provider-buttons\\">',ctx:ctx});return block}function create_default_slot_3$3(ctx){let panelrow;let current;panelrow=new PanelRow({props:{class:"body flex-column delivery-provider-buttons",$$slots:{default:[create_default_slot_4$2]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty[0]&290|dirty[1]&8){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_3$3.name,type:"slot",source:"(156:2) <Panel heading={$strings.select_delivery_provider_title} defined={defined} multi>",ctx:ctx});return block}function create_if_block$f(ctx){let panel;let current;panel=new Panel({props:{heading:ctx[8].enter_other_cdn_name_title,defined:ctx[3],multi:true,$$slots:{default:[create_default_slot_1$f]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panel.$$.fragment)},m:function mount(target,anchor){mount_component(panel,target,anchor);current=true},p:function update(ctx,dirty){const panel_changes={};if(dirty[0]&256)panel_changes.heading=ctx[8].enter_other_cdn_name_title;if(dirty[0]&8)panel_changes.defined=ctx[3];if(dirty[0]&388|dirty[1]&8){panel_changes.$$scope={dirty:dirty,ctx:ctx}}panel.$set(panel_changes)},i:function intro(local){if(current)return;transition_in(panel.$$.fragment,local);current=true},o:function outro(local){transition_out(panel.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panel,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$f.name,type:"if",source:"(175:2) {#if deliveryProvider.provider_service_name_override_allowed}",ctx:ctx});return block}function create_default_slot_2$c(ctx){let input;let input_placeholder_value;let mounted;let dispose;const block={c:function create(){input=element("input");attr_dev(input,"type","text");attr_dev(input,"class","cdn-name");attr_dev(input,"id","cdn-name");attr_dev(input,"name","cdn-name");attr_dev(input,"minlength","4");attr_dev(input,"placeholder",input_placeholder_value=ctx[8].enter_other_cdn_name_placeholder);input.disabled=ctx[7];add_location(input,file$v,177,5,5832)},m:function mount(target,anchor){insert_dev(target,input,anchor);set_input_value(input,ctx[2]);if(!mounted){dispose=listen_dev(input,"input",ctx[19]);mounted=true}},p:function update(ctx,dirty){if(dirty[0]&256&&input_placeholder_value!==(input_placeholder_value=ctx[8].enter_other_cdn_name_placeholder)){attr_dev(input,"placeholder",input_placeholder_value)}if(dirty[0]&128){prop_dev(input,"disabled",ctx[7])}if(dirty[0]&4&&input.value!==ctx[2]){set_input_value(input,ctx[2])}},d:function destroy(detaching){if(detaching){detach_dev(input)}mounted=false;dispose()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_2$c.name,type:"slot",source:'(177:4) <PanelRow class=\\"body flex-column\\">',ctx:ctx});return block}function create_default_slot_1$f(ctx){let panelrow;let current;panelrow=new PanelRow({props:{class:"body flex-column",$$slots:{default:[create_default_slot_2$c]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty[0]&388|dirty[1]&8){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$f.name,type:"slot",source:"(176:3) <Panel heading={$strings.enter_other_cdn_name_title} defined={serviceNameDefined} multi>",ctx:ctx});return block}function create_default_slot$o(ctx){let notifications;let t0;let h2;let t1_value=ctx[8].delivery_title+"";let t1;let t2;let div;let panel;let t3;let t4;let backnextbuttonsrow;let current;notifications=new Notifications({props:{tab:ctx[0],tabParent:"media"},$$inline:true});panel=new Panel({props:{heading:ctx[8].select_delivery_provider_title,defined:ctx[4],multi:true,$$slots:{default:[create_default_slot_3$3]},$$scope:{ctx:ctx}},$$inline:true});let if_block=ctx[1].provider_service_name_override_allowed&&create_if_block$f(ctx);backnextbuttonsrow=new BackNextButtonsRow({props:{nextText:ctx[8].save_delivery_provider,nextDisabled:ctx[6],nextTitle:ctx[6]},$$inline:true});backnextbuttonsrow.$on("next",ctx[11]);const block={c:function create(){create_component(notifications.$$.fragment);t0=space();h2=element("h2");t1=text(t1_value);t2=space();div=element("div");create_component(panel.$$.fragment);t3=space();if(if_block)if_block.c();t4=space();create_component(backnextbuttonsrow.$$.fragment);attr_dev(h2,"class","page-title");add_location(h2,file$v,152,1,4728);attr_dev(div,"class","delivery-provider-settings-page wrapper");add_location(div,file$v,154,1,4784)},m:function mount(target,anchor){mount_component(notifications,target,anchor);insert_dev(target,t0,anchor);insert_dev(target,h2,anchor);append_dev(h2,t1);insert_dev(target,t2,anchor);insert_dev(target,div,anchor);mount_component(panel,div,null);append_dev(div,t3);if(if_block)if_block.m(div,null);append_dev(div,t4);mount_component(backnextbuttonsrow,div,null);current=true},p:function update(ctx,dirty){const notifications_changes={};if(dirty[0]&1)notifications_changes.tab=ctx[0];notifications.$set(notifications_changes);if((!current||dirty[0]&256)&&t1_value!==(t1_value=ctx[8].delivery_title+""))set_data_dev(t1,t1_value);const panel_changes={};if(dirty[0]&256)panel_changes.heading=ctx[8].select_delivery_provider_title;if(dirty[0]&16)panel_changes.defined=ctx[4];if(dirty[0]&290|dirty[1]&8){panel_changes.$$scope={dirty:dirty,ctx:ctx}}panel.$set(panel_changes);if(ctx[1].provider_service_name_override_allowed){if(if_block){if_block.p(ctx,dirty);if(dirty[0]&2){transition_in(if_block,1)}}else{if_block=create_if_block$f(ctx);if_block.c();transition_in(if_block,1);if_block.m(div,t4)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}const backnextbuttonsrow_changes={};if(dirty[0]&256)backnextbuttonsrow_changes.nextText=ctx[8].save_delivery_provider;if(dirty[0]&64)backnextbuttonsrow_changes.nextDisabled=ctx[6];if(dirty[0]&64)backnextbuttonsrow_changes.nextTitle=ctx[6];backnextbuttonsrow.$set(backnextbuttonsrow_changes)},i:function intro(local){if(current)return;transition_in(notifications.$$.fragment,local);transition_in(panel.$$.fragment,local);transition_in(if_block);transition_in(backnextbuttonsrow.$$.fragment,local);current=true},o:function outro(local){transition_out(notifications.$$.fragment,local);transition_out(panel.$$.fragment,local);transition_out(if_block);transition_out(backnextbuttonsrow.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(h2);detach_dev(t2);detach_dev(div)}destroy_component(notifications,detaching);destroy_component(panel);if(if_block)if_block.d();destroy_component(backnextbuttonsrow)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$o.name,type:"slot",source:"(151:0) <Page {name} subpage on:routeEvent>",ctx:ctx});return block}function create_fragment$z(ctx){let page;let current;page=new Page({props:{name:ctx[0],subpage:true,$$slots:{default:[create_default_slot$o]},$$scope:{ctx:ctx}},$$inline:true});page.$on("routeEvent",ctx[20]);const block={c:function create(){create_component(page.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(page,target,anchor);current=true},p:function update(ctx,dirty){const page_changes={};if(dirty[0]&1)page_changes.name=ctx[0];if(dirty[0]&511|dirty[1]&8){page_changes.$$scope={dirty:dirty,ctx:ctx}}page.$set(page_changes)},i:function intro(local){if(current)return;transition_in(page.$$.fragment,local);current=true},o:function outro(local){transition_out(page.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(page,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$z.name,type:"component",source:"",ctx:ctx});return block}function instance$z($$self,$$props,$$invalidate){let defined;let disabled;let serviceNameDefined;let serviceNameDisabled;let nextDisabledMessage;let $revalidatingSettings;let $settings;let $needs_refresh;let $settingsLocked;let $strings;let $delivery_provider;let $storage_provider;let $delivery_providers;let $defined_settings;let $current_settings;validate_store(revalidatingSettings,"revalidatingSettings");component_subscribe($$self,revalidatingSettings,($$value=>$$invalidate(21,$revalidatingSettings=$$value)));validate_store(settings,"settings");component_subscribe($$self,settings,($$value=>$$invalidate(22,$settings=$$value)));validate_store(needs_refresh,"needs_refresh");component_subscribe($$self,needs_refresh,($$value=>$$invalidate(14,$needs_refresh=$$value)));validate_store(settingsLocked,"settingsLocked");component_subscribe($$self,settingsLocked,($$value=>$$invalidate(15,$settingsLocked=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(8,$strings=$$value)));validate_store(delivery_provider,"delivery_provider");component_subscribe($$self,delivery_provider,($$value=>$$invalidate(23,$delivery_provider=$$value)));validate_store(storage_provider,"storage_provider");component_subscribe($$self,storage_provider,($$value=>$$invalidate(24,$storage_provider=$$value)));validate_store(delivery_providers,"delivery_providers");component_subscribe($$self,delivery_providers,($$value=>$$invalidate(25,$delivery_providers=$$value)));validate_store(defined_settings,"defined_settings");component_subscribe($$self,defined_settings,($$value=>$$invalidate(16,$defined_settings=$$value)));validate_store(current_settings,"current_settings");component_subscribe($$self,current_settings,($$value=>$$invalidate(17,$current_settings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("DeliveryPage",slots,[]);const dispatch=createEventDispatcher();let{name:name="delivery-provider"}=$$props;let{params:params={}}=$$props;const _params=params;setContext("settingsLocked",settingsLocked);let saving=false;const previousSettings={...$current_settings};const previousDefines={...$defined_settings};let deliveryProvider={...$delivery_provider};let serviceName=$settings["delivery-provider-service-name"];function supportedDeliveryProviders(){return Object.values($delivery_providers).filter((provider=>provider.supported_storage_providers.length===0||provider.supported_storage_providers.includes($storage_provider.provider_key_name)))}function getNextDisabledMessage(provider,providerName,settingsLocked,needsRefresh){let message="";if(settingsLocked||needsRefresh){message=$strings.settings_locked}else if(provider.provider_service_name_override_allowed&&providerName.trim().length<1){message=$strings.no_delivery_provider_name}else if(provider.provider_service_name_override_allowed&&providerName.trim().length<4){message=$strings.delivery_provider_name_short}else if(deliveryProvider.provider_key_name===$delivery_provider.provider_key_name&&providerName===$settings["delivery-provider-service-name"]){message=$strings.nothing_to_save}return message}function handleChooseProvider(provider){if(disabled){return}$$invalidate(1,deliveryProvider=provider)}async function handleNext(){$$invalidate(13,saving=true);state.pausePeriodicFetch();set_store_value(settings,$settings["delivery-provider"]=deliveryProvider.provider_key_name,$settings);set_store_value(settings,$settings["delivery-provider-service-name"]=serviceName,$settings);const result=await settings.save();if(result.hasOwnProperty("saved")&&!result.saved){settings.reset();$$invalidate(13,saving=false);await state.resumePeriodicFetch();scrollNotificationsIntoView();return}set_store_value(revalidatingSettings,$revalidatingSettings=true,$revalidatingSettings);const statePromise=state.resumePeriodicFetch();dispatch("routeEvent",{event:"settings.save",data:result,default:"/media/delivery"});await statePromise;set_store_value(revalidatingSettings,$revalidatingSettings=false,$revalidatingSettings)}const writable_props=["name","params"];Object_1$4.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<DeliveryPage> was created with unknown prop '${key}'`)}));const click_handler=provider=>handleChooseProvider(provider);function input_input_handler(){serviceName=this.value;$$invalidate(2,serviceName)}function routeEvent_handler(event){bubble.call(this,$$self,event)}$$self.$$set=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name);if("params"in $$props)$$invalidate(12,params=$$props.params)};$$self.$capture_state=()=>({createEventDispatcher:createEventDispatcher,setContext:setContext,strings:strings,settings:settings,storage_provider:storage_provider,delivery_providers:delivery_providers,delivery_provider:delivery_provider,defined_settings:defined_settings,settingsLocked:settingsLocked,current_settings:current_settings,needs_refresh:needs_refresh,revalidatingSettings:revalidatingSettings,state:state,scrollNotificationsIntoView:scrollNotificationsIntoView,needsRefresh:needsRefresh,Page:Page,Notifications:Notifications,Panel:Panel,PanelRow:PanelRow,TabButton:TabButton,BackNextButtonsRow:BackNextButtonsRow,HelpButton:HelpButton,dispatch:dispatch,name:name,params:params,_params:_params,saving:saving,previousSettings:previousSettings,previousDefines:previousDefines,deliveryProvider:deliveryProvider,serviceName:serviceName,supportedDeliveryProviders:supportedDeliveryProviders,getNextDisabledMessage:getNextDisabledMessage,handleChooseProvider:handleChooseProvider,handleNext:handleNext,disabled:disabled,nextDisabledMessage:nextDisabledMessage,serviceNameDefined:serviceNameDefined,serviceNameDisabled:serviceNameDisabled,defined:defined,$revalidatingSettings:$revalidatingSettings,$settings:$settings,$needs_refresh:$needs_refresh,$settingsLocked:$settingsLocked,$strings:$strings,$delivery_provider:$delivery_provider,$storage_provider:$storage_provider,$delivery_providers:$delivery_providers,$defined_settings:$defined_settings,$current_settings:$current_settings});$$self.$inject_state=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name);if("params"in $$props)$$invalidate(12,params=$$props.params);if("saving"in $$props)$$invalidate(13,saving=$$props.saving);if("deliveryProvider"in $$props)$$invalidate(1,deliveryProvider=$$props.deliveryProvider);if("serviceName"in $$props)$$invalidate(2,serviceName=$$props.serviceName);if("disabled"in $$props)$$invalidate(5,disabled=$$props.disabled);if("nextDisabledMessage"in $$props)$$invalidate(6,nextDisabledMessage=$$props.nextDisabledMessage);if("serviceNameDefined"in $$props)$$invalidate(3,serviceNameDefined=$$props.serviceNameDefined);if("serviceNameDisabled"in $$props)$$invalidate(7,serviceNameDisabled=$$props.serviceNameDisabled);if("defined"in $$props)$$invalidate(4,defined=$$props.defined)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty[0]&221184){{set_store_value(needs_refresh,$needs_refresh=$needs_refresh||needsRefresh(saving,previousSettings,$current_settings,previousDefines,$defined_settings),$needs_refresh)}}if($$self.$$.dirty[0]&65536){$$invalidate(4,defined=$defined_settings.includes("delivery-provider"))}if($$self.$$.dirty[0]&32784){$$invalidate(5,disabled=defined||$settingsLocked)}if($$self.$$.dirty[0]&65536){$$invalidate(3,serviceNameDefined=$defined_settings.includes("delivery-provider-service-name"))}if($$self.$$.dirty[0]&32776){$$invalidate(7,serviceNameDisabled=serviceNameDefined||$settingsLocked)}if($$self.$$.dirty[0]&49158){$$invalidate(6,nextDisabledMessage=getNextDisabledMessage(deliveryProvider,serviceName,$settingsLocked,$needs_refresh))}};return[name,deliveryProvider,serviceName,serviceNameDefined,defined,disabled,nextDisabledMessage,serviceNameDisabled,$strings,supportedDeliveryProviders,handleChooseProvider,handleNext,params,saving,$needs_refresh,$settingsLocked,$defined_settings,$current_settings,click_handler,input_input_handler,routeEvent_handler]}class DeliveryPage extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$z,create_fragment$z,safe_not_equal,{name:0,params:12},null,[-1,-1]);dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"DeliveryPage",options:options,id:create_fragment$z.name})}get name(){throw new Error("<DeliveryPage>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set name(value){throw new Error("<DeliveryPage>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get params(){throw new Error("<DeliveryPage>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set params(value){throw new Error("<DeliveryPage>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const defaultPages=[{position:0,name:"media-library",title:()=>get_store_value(strings).media_tab_title,nav:true,route:"/",routeMatcher:/^\/(media\/.*)*$/,component:MediaPage,default:true},{position:200,name:"storage",route:"/storage/*",component:StoragePage},{position:210,name:"storage-provider",title:()=>get_store_value(strings).storage_provider_tab_title,subNav:true,route:"/storage/provider",component:StorageProviderSubPage,default:true,events:{"page.initial.settings":data=>{if(data.hasOwnProperty("location")&&get_store_value(needs_access_keys)&&!get_store_value(is_plugin_setup)){for(const prefix of["/storage","/media","/delivery"]){if(data.location.startsWith(prefix)){return true}}return data.location==="/"}return false}}},{position:220,name:"bucket",title:()=>get_store_value(strings).bucket_tab_title,subNav:true,route:"/storage/bucket",component:BucketSettingsSubPage,enabled:()=>!get_store_value(needs_access_keys),events:{"page.initial.settings":data=>{if(data.hasOwnProperty("location")&&!get_store_value(needs_access_keys)&&!get_store_value(is_plugin_setup)){for(const prefix of["/storage","/media","/delivery"]){if(data.location.startsWith(prefix)){return true}}return data.location==="/"}return false},"settings.save":data=>get_store_value(location$1)==="/storage/provider"&&!get_store_value(needs_access_keys)}},{position:230,name:"security",title:()=>get_store_value(strings).security_tab_title,subNav:true,route:"/storage/security",component:SecuritySubPage,enabled:()=>get_store_value(is_plugin_setup_with_credentials)&&!get_store_value(storage_provider).requires_acls,events:{"settings.save":data=>{if(get_store_value(location$1)==="/storage/bucket"&&get_store_value(is_plugin_setup_with_credentials)&&!get_store_value(storage_provider).requires_acls&&(!data.hasOwnProperty("bucketSource")||data.bucketSource!=="new"||!data.hasOwnProperty("initialSettings")||!data.initialSettings.hasOwnProperty("bucket")||data.initialSettings.bucket.length>0||!data.hasOwnProperty("settings")||!data.settings.hasOwnProperty("use-bucket-acls")||!data.settings["use-bucket-acls"]&&get_store_value(delivery_provider).requires_acls)){return true}return false}}},{position:300,name:"delivery",route:"/delivery/*",component:DeliveryPage}];const file$u="ui/pro/AssetsSettingsHeaderRow.svelte";function create_default_slot$n(ctx){let img;let img_src_value;let t0;let div;let h3;let t1_value=ctx[1].assets_panel_header+"";let t1;let t2;let p;let t3_value=ctx[1].assets_panel_header_details+"";let t3;const block={c:function create(){img=element("img");t0=space();div=element("div");h3=element("h3");t1=text(t1_value);t2=space();p=element("p");t3=text(t3_value);if(!src_url_equal(img.src,img_src_value=ctx[0].assets+"img/icon/assets.svg"))attr_dev(img,"src",img_src_value);attr_dev(img,"alt","foo");attr_dev(img,"class","svelte-1m7cok0");add_location(img,file$u,7,1,155);attr_dev(h3,"class","svelte-1m7cok0");add_location(h3,file$u,9,2,249);attr_dev(p,"class","console-details svelte-1m7cok0");add_location(p,file$u,10,2,291);attr_dev(div,"class","assets-details svelte-1m7cok0");add_location(div,file$u,8,1,218)},m:function mount(target,anchor){insert_dev(target,img,anchor);insert_dev(target,t0,anchor);insert_dev(target,div,anchor);append_dev(div,h3);append_dev(h3,t1);append_dev(div,t2);append_dev(div,p);append_dev(p,t3)},p:function update(ctx,dirty){if(dirty&1&&!src_url_equal(img.src,img_src_value=ctx[0].assets+"img/icon/assets.svg")){attr_dev(img,"src",img_src_value)}if(dirty&2&&t1_value!==(t1_value=ctx[1].assets_panel_header+""))set_data_dev(t1,t1_value);if(dirty&2&&t3_value!==(t3_value=ctx[1].assets_panel_header_details+""))set_data_dev(t3,t3_value)},d:function destroy(detaching){if(detaching){detach_dev(img);detach_dev(t0);detach_dev(div)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$n.name,type:"slot",source:'(7:0) <PanelRow header class=\\"assets\\">',ctx:ctx});return block}function create_fragment$y(ctx){let panelrow;let current;panelrow=new PanelRow({props:{header:true,class:"assets",$$slots:{default:[create_default_slot$n]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,[dirty]){const panelrow_changes={};if(dirty&7){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$y.name,type:"component",source:"",ctx:ctx});return block}function instance$y($$self,$$props,$$invalidate){let $urls;let $strings;validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(0,$urls=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(1,$strings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("AssetsSettingsHeaderRow",slots,[]);const writable_props=[];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<AssetsSettingsHeaderRow> was created with unknown prop '${key}'`)}));$$self.$capture_state=()=>({strings:strings,urls:urls,PanelRow:PanelRow,$urls:$urls,$strings:$strings});return[$urls,$strings]}class AssetsSettingsHeaderRow extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$y,create_fragment$y,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"AssetsSettingsHeaderRow",options:options,id:create_fragment$y.name})}}function create_default_slot$m(ctx){let assetssettingsheaderrow;let t0;let settingsvalidationstatusrow;let t1;let settingspaneloption0;let updating_toggle;let updating_text;let t2;let settingspaneloption1;let updating_toggle_1;let current;assetssettingsheaderrow=new AssetsSettingsHeaderRow({$$inline:true});settingsvalidationstatusrow=new SettingsValidationStatusRow({props:{section:"assets"},$$inline:true});function settingspaneloption0_toggle_binding(value){ctx[3](value)}function settingspaneloption0_text_binding(value){ctx[4](value)}let settingspaneloption0_props={heading:ctx[0].assets_rewrite_urls,description:ctx[0].assets_rewrite_urls_desc,placeholder:"assets.example.com",toggleName:"rewrite-urls",textName:"domain",definedSettings:assetsDefinedSettings,validator:ctx[2]};if(ctx[1]["rewrite-urls"]!==void 0){settingspaneloption0_props.toggle=ctx[1]["rewrite-urls"]}if(ctx[1]["domain"]!==void 0){settingspaneloption0_props.text=ctx[1]["domain"]}settingspaneloption0=new SettingsPanelOption({props:settingspaneloption0_props,$$inline:true});binding_callbacks.push((()=>bind(settingspaneloption0,"toggle",settingspaneloption0_toggle_binding)));binding_callbacks.push((()=>bind(settingspaneloption0,"text",settingspaneloption0_text_binding)));function settingspaneloption1_toggle_binding(value){ctx[5](value)}let settingspaneloption1_props={heading:ctx[0].assets_force_https,description:ctx[0].assets_force_https_desc,toggleName:"force-https",definedSettings:assetsDefinedSettings};if(ctx[1]["force-https"]!==void 0){settingspaneloption1_props.toggle=ctx[1]["force-https"]}settingspaneloption1=new SettingsPanelOption({props:settingspaneloption1_props,$$inline:true});binding_callbacks.push((()=>bind(settingspaneloption1,"toggle",settingspaneloption1_toggle_binding)));const block={c:function create(){create_component(assetssettingsheaderrow.$$.fragment);t0=space();create_component(settingsvalidationstatusrow.$$.fragment);t1=space();create_component(settingspaneloption0.$$.fragment);t2=space();create_component(settingspaneloption1.$$.fragment)},m:function mount(target,anchor){mount_component(assetssettingsheaderrow,target,anchor);insert_dev(target,t0,anchor);mount_component(settingsvalidationstatusrow,target,anchor);insert_dev(target,t1,anchor);mount_component(settingspaneloption0,target,anchor);insert_dev(target,t2,anchor);mount_component(settingspaneloption1,target,anchor);current=true},p:function update(ctx,dirty){const settingspaneloption0_changes={};if(dirty&1)settingspaneloption0_changes.heading=ctx[0].assets_rewrite_urls;if(dirty&1)settingspaneloption0_changes.description=ctx[0].assets_rewrite_urls_desc;if(!updating_toggle&&dirty&2){updating_toggle=true;settingspaneloption0_changes.toggle=ctx[1]["rewrite-urls"];add_flush_callback((()=>updating_toggle=false))}if(!updating_text&&dirty&2){updating_text=true;settingspaneloption0_changes.text=ctx[1]["domain"];add_flush_callback((()=>updating_text=false))}settingspaneloption0.$set(settingspaneloption0_changes);const settingspaneloption1_changes={};if(dirty&1)settingspaneloption1_changes.heading=ctx[0].assets_force_https;if(dirty&1)settingspaneloption1_changes.description=ctx[0].assets_force_https_desc;if(!updating_toggle_1&&dirty&2){updating_toggle_1=true;settingspaneloption1_changes.toggle=ctx[1]["force-https"];add_flush_callback((()=>updating_toggle_1=false))}settingspaneloption1.$set(settingspaneloption1_changes)},i:function intro(local){if(current)return;transition_in(assetssettingsheaderrow.$$.fragment,local);transition_in(settingsvalidationstatusrow.$$.fragment,local);transition_in(settingspaneloption0.$$.fragment,local);transition_in(settingspaneloption1.$$.fragment,local);current=true},o:function outro(local){transition_out(assetssettingsheaderrow.$$.fragment,local);transition_out(settingsvalidationstatusrow.$$.fragment,local);transition_out(settingspaneloption0.$$.fragment,local);transition_out(settingspaneloption1.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(t1);detach_dev(t2)}destroy_component(assetssettingsheaderrow,detaching);destroy_component(settingsvalidationstatusrow,detaching);destroy_component(settingspaneloption0,detaching);destroy_component(settingspaneloption1,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$m.name,type:"slot",source:'(36:0) <Panel name=\\"settings\\" class=\\"assets-panel\\" heading={$strings.assets_title} helpKey=\\"assets-pull\\">',ctx:ctx});return block}function create_fragment$x(ctx){let panel;let current;panel=new Panel({props:{name:"settings",class:"assets-panel",heading:ctx[0].assets_title,helpKey:"assets-pull",$$slots:{default:[create_default_slot$m]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panel.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(panel,target,anchor);current=true},p:function update(ctx,[dirty]){const panel_changes={};if(dirty&1)panel_changes.heading=ctx[0].assets_title;if(dirty&131){panel_changes.$$scope={dirty:dirty,ctx:ctx}}panel.$set(panel_changes)},i:function intro(local){if(current)return;transition_in(panel.$$.fragment,local);current=true},o:function outro(local){transition_out(panel.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panel,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$x.name,type:"component",source:"",ctx:ctx});return block}function instance$x($$self,$$props,$$invalidate){let $strings;let $urls;let $assetsSettings;validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(0,$strings=$$value)));validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(6,$urls=$$value)));validate_store(assetsSettings,"assetsSettings");component_subscribe($$self,assetsSettings,($$value=>$$invalidate(1,$assetsSettings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("AssetsSettings",slots,[]);function validator(domain){const domainPattern=/[^a-z0-9.-]/;let message="";if(domain.trim().length===0){message=$strings.domain_blank}else if(true===domainPattern.test(domain)){message=$strings.domain_invalid_content}else if(domain.length<3){message=$strings.domain_too_short}else if(domain===$urls.home_domain){message=$strings.assets_domain_same_as_site}return message}const writable_props=[];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<AssetsSettings> was created with unknown prop '${key}'`)}));function settingspaneloption0_toggle_binding(value){if($$self.$$.not_equal($assetsSettings["rewrite-urls"],value)){$assetsSettings["rewrite-urls"]=value;assetsSettings.set($assetsSettings)}}function settingspaneloption0_text_binding(value){if($$self.$$.not_equal($assetsSettings["domain"],value)){$assetsSettings["domain"]=value;assetsSettings.set($assetsSettings)}}function settingspaneloption1_toggle_binding(value){if($$self.$$.not_equal($assetsSettings["force-https"],value)){$assetsSettings["force-https"]=value;assetsSettings.set($assetsSettings)}}$$self.$capture_state=()=>({strings:strings,urls:urls,assetsSettings:assetsSettings,assetsDefinedSettings:assetsDefinedSettings,AssetsSettingsHeaderRow:AssetsSettingsHeaderRow,Panel:Panel,SettingsPanelOption:SettingsPanelOption,SettingsValidationStatusRow:SettingsValidationStatusRow,validator:validator,$strings:$strings,$urls:$urls,$assetsSettings:$assetsSettings});return[$strings,$assetsSettings,validator,settingspaneloption0_toggle_binding,settingspaneloption0_text_binding,settingspaneloption1_toggle_binding]}class AssetsSettings extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$x,create_fragment$x,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"AssetsSettings",options:options,id:create_fragment$x.name})}}const file$t="ui/components/Upsell.svelte";const get_call_to_action_note_slot_changes=dirty=>({});const get_call_to_action_note_slot_context=ctx=>({});const get_call_to_action_slot_changes=dirty=>({});const get_call_to_action_slot_context=ctx=>({});function get_each_context$7(ctx,list,i){const child_ctx=ctx.slice();child_ctx[3]=list[i];return child_ctx}const get_description_slot_changes=dirty=>({});const get_description_slot_context=ctx=>({});const get_heading_slot_changes=dirty=>({});const get_heading_slot_context=ctx=>({});function create_each_block$7(ctx){let li;let img;let img_src_value;let img_alt_value;let t0;let span;let t1_value=ctx[3].text+"";let t1;let t2;const block={c:function create(){li=element("li");img=element("img");t0=space();span=element("span");t1=text(t1_value);t2=space();if(!src_url_equal(img.src,img_src_value=ctx[3].icon))attr_dev(img,"src",img_src_value);attr_dev(img,"alt",img_alt_value=ctx[3].alt);attr_dev(img,"class","svelte-5j10or");add_location(img,file$t,20,5,398);add_location(span,file$t,21,5,450);attr_dev(li,"class","svelte-5j10or");add_location(li,file$t,19,4,388)},m:function mount(target,anchor){insert_dev(target,li,anchor);append_dev(li,img);append_dev(li,t0);append_dev(li,span);append_dev(span,t1);append_dev(li,t2)},p:function update(ctx,dirty){if(dirty&1&&!src_url_equal(img.src,img_src_value=ctx[3].icon)){attr_dev(img,"src",img_src_value)}if(dirty&1&&img_alt_value!==(img_alt_value=ctx[3].alt)){attr_dev(img,"alt",img_alt_value)}if(dirty&1&&t1_value!==(t1_value=ctx[3].text+""))set_data_dev(t1,t1_value)},d:function destroy(detaching){if(detaching){detach_dev(li)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_each_block$7.name,type:"each",source:"(19:3) {#each benefits as benefit}",ctx:ctx});return block}function create_default_slot$l(ctx){let div0;let t0;let div6;let div1;let t1;let div2;let t2;let div3;let t3;let div5;let t4;let div4;let current;const heading_slot_template=ctx[1].heading;const heading_slot=create_slot(heading_slot_template,ctx,ctx[2],get_heading_slot_context);const description_slot_template=ctx[1].description;const description_slot=create_slot(description_slot_template,ctx,ctx[2],get_description_slot_context);let each_value=ensure_array_like_dev(ctx[0]);let each_blocks=[];for(let i=0;i<each_value.length;i+=1){each_blocks[i]=create_each_block$7(get_each_context$7(ctx,each_value,i))}const call_to_action_slot_template=ctx[1]["call-to-action"];const call_to_action_slot=create_slot(call_to_action_slot_template,ctx,ctx[2],get_call_to_action_slot_context);const call_to_action_note_slot_template=ctx[1]["call-to-action-note"];const call_to_action_note_slot=create_slot(call_to_action_note_slot_template,ctx,ctx[2],get_call_to_action_note_slot_context);const block={c:function create(){div0=element("div");t0=space();div6=element("div");div1=element("div");if(heading_slot)heading_slot.c();t1=space();div2=element("div");if(description_slot)description_slot.c();t2=space();div3=element("div");for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].c()}t3=space();div5=element("div");if(call_to_action_slot)call_to_action_slot.c();t4=space();div4=element("div");if(call_to_action_note_slot)call_to_action_note_slot.c();attr_dev(div0,"class","branding");add_location(div0,file$t,7,1,136);attr_dev(div1,"class","heading svelte-5j10or");add_location(div1,file$t,9,2,190);attr_dev(div2,"class","description svelte-5j10or");add_location(div2,file$t,13,2,256);attr_dev(div3,"class","benefits svelte-5j10or");add_location(div3,file$t,17,2,330);attr_dev(div4,"class","note svelte-5j10or");add_location(div4,file$t,28,3,582);attr_dev(div5,"class","call-to-action svelte-5j10or");add_location(div5,file$t,26,2,511);attr_dev(div6,"class","content svelte-5j10or");add_location(div6,file$t,8,1,166)},m:function mount(target,anchor){insert_dev(target,div0,anchor);insert_dev(target,t0,anchor);insert_dev(target,div6,anchor);append_dev(div6,div1);if(heading_slot){heading_slot.m(div1,null)}append_dev(div6,t1);append_dev(div6,div2);if(description_slot){description_slot.m(div2,null)}append_dev(div6,t2);append_dev(div6,div3);for(let i=0;i<each_blocks.length;i+=1){if(each_blocks[i]){each_blocks[i].m(div3,null)}}append_dev(div6,t3);append_dev(div6,div5);if(call_to_action_slot){call_to_action_slot.m(div5,null)}append_dev(div5,t4);append_dev(div5,div4);if(call_to_action_note_slot){call_to_action_note_slot.m(div4,null)}current=true},p:function update(ctx,dirty){if(heading_slot){if(heading_slot.p&&(!current||dirty&4)){update_slot_base(heading_slot,heading_slot_template,ctx,ctx[2],!current?get_all_dirty_from_scope(ctx[2]):get_slot_changes(heading_slot_template,ctx[2],dirty,get_heading_slot_changes),get_heading_slot_context)}}if(description_slot){if(description_slot.p&&(!current||dirty&4)){update_slot_base(description_slot,description_slot_template,ctx,ctx[2],!current?get_all_dirty_from_scope(ctx[2]):get_slot_changes(description_slot_template,ctx[2],dirty,get_description_slot_changes),get_description_slot_context)}}if(dirty&1){each_value=ensure_array_like_dev(ctx[0]);let i;for(i=0;i<each_value.length;i+=1){const child_ctx=get_each_context$7(ctx,each_value,i);if(each_blocks[i]){each_blocks[i].p(child_ctx,dirty)}else{each_blocks[i]=create_each_block$7(child_ctx);each_blocks[i].c();each_blocks[i].m(div3,null)}}for(;i<each_blocks.length;i+=1){each_blocks[i].d(1)}each_blocks.length=each_value.length}if(call_to_action_slot){if(call_to_action_slot.p&&(!current||dirty&4)){update_slot_base(call_to_action_slot,call_to_action_slot_template,ctx,ctx[2],!current?get_all_dirty_from_scope(ctx[2]):get_slot_changes(call_to_action_slot_template,ctx[2],dirty,get_call_to_action_slot_changes),get_call_to_action_slot_context)}}if(call_to_action_note_slot){if(call_to_action_note_slot.p&&(!current||dirty&4)){update_slot_base(call_to_action_note_slot,call_to_action_note_slot_template,ctx,ctx[2],!current?get_all_dirty_from_scope(ctx[2]):get_slot_changes(call_to_action_note_slot_template,ctx[2],dirty,get_call_to_action_note_slot_changes),get_call_to_action_note_slot_context)}}},i:function intro(local){if(current)return;transition_in(heading_slot,local);transition_in(description_slot,local);transition_in(call_to_action_slot,local);transition_in(call_to_action_note_slot,local);current=true},o:function outro(local){transition_out(heading_slot,local);transition_out(description_slot,local);transition_out(call_to_action_slot,local);transition_out(call_to_action_note_slot,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(div0);detach_dev(t0);detach_dev(div6)}if(heading_slot)heading_slot.d(detaching);if(description_slot)description_slot.d(detaching);destroy_each(each_blocks,detaching);if(call_to_action_slot)call_to_action_slot.d(detaching);if(call_to_action_note_slot)call_to_action_note_slot.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$l.name,type:"slot",source:'(7:0) <Panel name=\\"upsell\\" class=\\"upsell-panel\\">',ctx:ctx});return block}function create_fragment$w(ctx){let panel;let current;panel=new Panel({props:{name:"upsell",class:"upsell-panel",$$slots:{default:[create_default_slot$l]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panel.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(panel,target,anchor);current=true},p:function update(ctx,[dirty]){const panel_changes={};if(dirty&5){panel_changes.$$scope={dirty:dirty,ctx:ctx}}panel.$set(panel_changes)},i:function intro(local){if(current)return;transition_in(panel.$$.fragment,local);current=true},o:function outro(local){transition_out(panel.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panel,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$w.name,type:"component",source:"",ctx:ctx});return block}function instance$w($$self,$$props,$$invalidate){let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("Upsell",slots,["heading","description","call-to-action","call-to-action-note"]);let{benefits:benefits}=$$props;$$self.$$.on_mount.push((function(){if(benefits===undefined&&!("benefits"in $$props||$$self.$$.bound[$$self.$$.props["benefits"]])){console.warn("<Upsell> was created without expected prop 'benefits'")}}));const writable_props=["benefits"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<Upsell> was created with unknown prop '${key}'`)}));$$self.$$set=$$props=>{if("benefits"in $$props)$$invalidate(0,benefits=$$props.benefits);if("$$scope"in $$props)$$invalidate(2,$$scope=$$props.$$scope)};$$self.$capture_state=()=>({Panel:Panel,benefits:benefits});$$self.$inject_state=$$props=>{if("benefits"in $$props)$$invalidate(0,benefits=$$props.benefits)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[benefits,slots,$$scope]}class Upsell extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$w,create_fragment$w,safe_not_equal,{benefits:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"Upsell",options:options,id:create_fragment$w.name})}get benefits(){throw new Error("<Upsell>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set benefits(value){throw new Error("<Upsell>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$s="ui/pro/AssetsUpgrade.svelte";function create_heading_slot$1(ctx){let div;let t_value=ctx[0].assets_upsell_heading+"";let t;const block={c:function create(){div=element("div");t=text(t_value);attr_dev(div,"slot","heading");add_location(div,file$s,24,1,535)},m:function mount(target,anchor){insert_dev(target,div,anchor);append_dev(div,t)},p:function update(ctx,dirty){if(dirty&1&&t_value!==(t_value=ctx[0].assets_upsell_heading+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(div)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_heading_slot$1.name,type:"slot",source:"(25:1) ",ctx:ctx});return block}function create_description_slot$1(ctx){let div;let raw_value=ctx[0].assets_upsell_description+"";const block={c:function create(){div=element("div");attr_dev(div,"slot","description");add_location(div,file$s,26,1,596)},m:function mount(target,anchor){insert_dev(target,div,anchor);div.innerHTML=raw_value},p:function update(ctx,dirty){if(dirty&1&&raw_value!==(raw_value=ctx[0].assets_upsell_description+""))div.innerHTML=raw_value},d:function destroy(detaching){if(detaching){detach_dev(div)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_description_slot$1.name,type:"slot",source:"(27:1) ",ctx:ctx});return block}function create_call_to_action_slot(ctx){let a;let img;let img_src_value;let t0;let t1_value=ctx[0].assets_upsell_cta+"";let t1;let a_href_value;const block={c:function create(){a=element("a");img=element("img");t0=space();t1=text(t1_value);if(!src_url_equal(img.src,img_src_value=ctx[1].assets+"img/icon/stars.svg"))attr_dev(img,"src",img_src_value);attr_dev(img,"alt","stars icon");set_style(img,"margin-right","5px");add_location(img,file$s,29,2,769);attr_dev(a,"slot","call-to-action");attr_dev(a,"href",a_href_value=ctx[1].upsell_discount_assets);attr_dev(a,"class","button btn-lg btn-primary");add_location(a,file$s,28,1,671)},m:function mount(target,anchor){insert_dev(target,a,anchor);append_dev(a,img);append_dev(a,t0);append_dev(a,t1)},p:function update(ctx,dirty){if(dirty&2&&!src_url_equal(img.src,img_src_value=ctx[1].assets+"img/icon/stars.svg")){attr_dev(img,"src",img_src_value)}if(dirty&1&&t1_value!==(t1_value=ctx[0].assets_upsell_cta+""))set_data_dev(t1,t1_value);if(dirty&2&&a_href_value!==(a_href_value=ctx[1].upsell_discount_assets)){attr_dev(a,"href",a_href_value)}},d:function destroy(detaching){if(detaching){detach_dev(a)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_call_to_action_slot.name,type:"slot",source:"(29:1) ",ctx:ctx});return block}function create_call_to_action_note_slot(ctx){let div;let raw_value=ctx[0].assets_upsell_cta_note+"";const block={c:function create(){div=element("div");attr_dev(div,"slot","call-to-action-note");add_location(div,file$s,33,1,900)},m:function mount(target,anchor){insert_dev(target,div,anchor);div.innerHTML=raw_value},p:function update(ctx,dirty){if(dirty&1&&raw_value!==(raw_value=ctx[0].assets_upsell_cta_note+""))div.innerHTML=raw_value},d:function destroy(detaching){if(detaching){detach_dev(div)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_call_to_action_note_slot.name,type:"slot",source:"(34:1) ",ctx:ctx});return block}function create_fragment$v(ctx){let upsell;let current;upsell=new Upsell({props:{benefits:ctx[2],$$slots:{"call-to-action-note":[create_call_to_action_note_slot],"call-to-action":[create_call_to_action_slot],description:[create_description_slot$1],heading:[create_heading_slot$1]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(upsell.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(upsell,target,anchor);current=true},p:function update(ctx,[dirty]){const upsell_changes={};if(dirty&11){upsell_changes.$$scope={dirty:dirty,ctx:ctx}}upsell.$set(upsell_changes)},i:function intro(local){if(current)return;transition_in(upsell.$$.fragment,local);current=true},o:function outro(local){transition_out(upsell.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(upsell,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$v.name,type:"component",source:"",ctx:ctx});return block}function instance$v($$self,$$props,$$invalidate){let $strings;let $urls;validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(0,$strings=$$value)));validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(1,$urls=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("AssetsUpgrade",slots,[]);let benefits=[{icon:$urls.assets+"img/icon/fonts.svg",alt:"js icon",text:$strings.assets_uppsell_benefits.js},{icon:$urls.assets+"img/icon/css.svg",alt:"css icon",text:$strings.assets_uppsell_benefits.css},{icon:$urls.assets+"img/icon/fonts.svg",alt:"fonts icon",text:$strings.assets_uppsell_benefits.fonts}];const writable_props=[];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<AssetsUpgrade> was created with unknown prop '${key}'`)}));$$self.$capture_state=()=>({strings:strings,urls:urls,Upsell:Upsell,benefits:benefits,$strings:$strings,$urls:$urls});$$self.$inject_state=$$props=>{if("benefits"in $$props)$$invalidate(2,benefits=$$props.benefits)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[$strings,$urls,benefits]}class AssetsUpgrade extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$v,create_fragment$v,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"AssetsUpgrade",options:options,id:create_fragment$v.name})}}const file$r="ui/pro/AssetsPage.svelte";function create_else_block$9(ctx){let assetsupgrade;let current;assetsupgrade=new AssetsUpgrade({$$inline:true});const block={c:function create(){create_component(assetsupgrade.$$.fragment)},m:function mount(target,anchor){mount_component(assetsupgrade,target,anchor);current=true},i:function intro(local){if(current)return;transition_in(assetsupgrade.$$.fragment,local);current=true},o:function outro(local){transition_out(assetsupgrade.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(assetsupgrade,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block$9.name,type:"else",source:"(27:2) {:else}",ctx:ctx});return block}function create_if_block$e(ctx){let assetssettings;let current;assetssettings=new AssetsSettings({$$inline:true});const block={c:function create(){create_component(assetssettings.$$.fragment)},m:function mount(target,anchor){mount_component(assetssettings,target,anchor);current=true},i:function intro(local){if(current)return;transition_in(assetssettings.$$.fragment,local);current=true},o:function outro(local){transition_out(assetssettings.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(assetssettings,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$e.name,type:"if",source:"(25:2) {#if $enableAssets}",ctx:ctx});return block}function create_default_slot$k(ctx){let notifications;let t;let div;let current_block_type_index;let if_block;let current;notifications=new Notifications({props:{tab:ctx[0]},$$inline:true});const if_block_creators=[create_if_block$e,create_else_block$9];const if_blocks=[];function select_block_type(ctx,dirty){if(ctx[1])return 0;return 1}current_block_type_index=select_block_type(ctx);if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);const block={c:function create(){create_component(notifications.$$.fragment);t=space();div=element("div");if_block.c();attr_dev(div,"class","assets-page wrapper");add_location(div,file$r,23,1,716)},m:function mount(target,anchor){mount_component(notifications,target,anchor);insert_dev(target,t,anchor);insert_dev(target,div,anchor);if_blocks[current_block_type_index].m(div,null);current=true},p:function update(ctx,dirty){const notifications_changes={};if(dirty&1)notifications_changes.tab=ctx[0];notifications.$set(notifications_changes);let previous_block_index=current_block_type_index;current_block_type_index=select_block_type(ctx);if(current_block_type_index!==previous_block_index){group_outros();transition_out(if_blocks[previous_block_index],1,1,(()=>{if_blocks[previous_block_index]=null}));check_outros();if_block=if_blocks[current_block_type_index];if(!if_block){if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);if_block.c()}transition_in(if_block,1);if_block.m(div,null)}},i:function intro(local){if(current)return;transition_in(notifications.$$.fragment,local);transition_in(if_block);current=true},o:function outro(local){transition_out(notifications.$$.fragment,local);transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(t);detach_dev(div)}destroy_component(notifications,detaching);if_blocks[current_block_type_index].d()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$k.name,type:"slot",source:"(22:0) <Page {name} on:routeEvent initialSettings={currentAssetsSettings}>",ctx:ctx});return block}function create_fragment$u(ctx){let page;let t;let footer;let current;page=new Page({props:{name:ctx[0],initialSettings:currentAssetsSettings,$$slots:{default:[create_default_slot$k]},$$scope:{ctx:ctx}},$$inline:true});page.$on("routeEvent",ctx[2]);footer=new Footer({props:{settingsStore:assetsSettings,settingsChangedStore:assetsSettingsChanged},$$inline:true});footer.$on("routeEvent",ctx[3]);const block={c:function create(){create_component(page.$$.fragment);t=space();create_component(footer.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(page,target,anchor);insert_dev(target,t,anchor);mount_component(footer,target,anchor);current=true},p:function update(ctx,[dirty]){const page_changes={};if(dirty&1)page_changes.name=ctx[0];if(dirty&19){page_changes.$$scope={dirty:dirty,ctx:ctx}}page.$set(page_changes)},i:function intro(local){if(current)return;transition_in(page.$$.fragment,local);transition_in(footer.$$.fragment,local);current=true},o:function outro(local){transition_out(page.$$.fragment,local);transition_out(footer.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t)}destroy_component(page,detaching);destroy_component(footer,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$u.name,type:"component",source:"",ctx:ctx});return block}function instance$u($$self,$$props,$$invalidate){let $enableAssets;validate_store(enableAssets,"enableAssets");component_subscribe($$self,enableAssets,($$value=>$$invalidate(1,$enableAssets=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("AssetsPage",slots,[]);let{name:name="assets"}=$$props;setContext("settingsLocked",assetsSettingsLocked);const writable_props=["name"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<AssetsPage> was created with unknown prop '${key}'`)}));function routeEvent_handler(event){bubble.call(this,$$self,event)}function routeEvent_handler_1(event){bubble.call(this,$$self,event)}$$self.$$set=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name)};$$self.$capture_state=()=>({assetsSettings:assetsSettings,assetsSettingsChanged:assetsSettingsChanged,assetsSettingsLocked:assetsSettingsLocked,currentAssetsSettings:currentAssetsSettings,enableAssets:enableAssets,Page:Page,Notifications:Notifications,AssetsSettings:AssetsSettings,AssetsUpgrade:AssetsUpgrade,Footer:Footer,setContext:setContext,name:name,$enableAssets:$enableAssets});$$self.$inject_state=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[name,$enableAssets,routeEvent_handler,routeEvent_handler_1]}class AssetsPage extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$u,create_fragment$u,safe_not_equal,{name:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"AssetsPage",options:options,id:create_fragment$u.name})}get name(){throw new Error("<AssetsPage>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set name(value){throw new Error("<AssetsPage>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$q="ui/pro/ToolNotification.svelte";function get_each_context$6(ctx,list,i){const child_ctx=ctx.slice();child_ctx[9]=list[i];child_ctx[11]=i;return child_ctx}function get_each_context_1(ctx,list,i){const child_ctx=ctx.slice();child_ctx[12]=list[i];child_ctx[11]=i;return child_ctx}function create_else_block$8(ctx){let notification_1;let current;notification_1=new Notification({props:{notification:ctx[0],$$slots:{default:[create_default_slot$j]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(notification_1.$$.fragment)},m:function mount(target,anchor){mount_component(notification_1,target,anchor);current=true},p:function update(ctx,dirty){const notification_1_changes={};if(dirty&1)notification_1_changes.notification=ctx[0];if(dirty&128){notification_1_changes.$$scope={dirty:dirty,ctx:ctx}}notification_1.$set(notification_1_changes)},i:function intro(local){if(current)return;transition_in(notification_1.$$.fragment,local);current=true},o:function outro(local){transition_out(notification_1.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(notification_1,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block$8.name,type:"else",source:"(72:0) {:else}",ctx:ctx});return block}function create_if_block$d(ctx){let notification_1;let updating_expanded;let current;function notification_1_expanded_binding(value){ctx[6](value)}let notification_1_props={notification:ctx[0],expandable:true,$$slots:{details:[create_details_slot]},$$scope:{ctx:ctx}};if(ctx[1]!==void 0){notification_1_props.expanded=ctx[1]}notification_1=new Notification({props:notification_1_props,$$inline:true});binding_callbacks.push((()=>bind(notification_1,"expanded",notification_1_expanded_binding)));const block={c:function create(){create_component(notification_1.$$.fragment)},m:function mount(target,anchor){mount_component(notification_1,target,anchor);current=true},p:function update(ctx,dirty){const notification_1_changes={};if(dirty&1)notification_1_changes.notification=ctx[0];if(dirty&135){notification_1_changes.$$scope={dirty:dirty,ctx:ctx}}if(!updating_expanded&&dirty&2){updating_expanded=true;notification_1_changes.expanded=ctx[1];add_flush_callback((()=>updating_expanded=false))}notification_1.$set(notification_1_changes)},i:function intro(local){if(current)return;transition_in(notification_1.$$.fragment,local);current=true},o:function outro(local){transition_out(notification_1.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(notification_1,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$d.name,type:"if",source:'(47:0) {#if notification.hasOwnProperty( \\"class\\" ) && notification.class === \\"tool-error\\" && notification.hasOwnProperty( \\"errors\\" )}',ctx:ctx});return block}function create_default_slot$j(ctx){let current;const default_slot_template=ctx[4].default;const default_slot=create_slot(default_slot_template,ctx,ctx[7],null);const block={c:function create(){if(default_slot)default_slot.c()},m:function mount(target,anchor){if(default_slot){default_slot.m(target,anchor)}current=true},p:function update(ctx,dirty){if(default_slot){if(default_slot.p&&(!current||dirty&128)){update_slot_base(default_slot,default_slot_template,ctx,ctx[7],!current?get_all_dirty_from_scope(ctx[7]):get_slot_changes(default_slot_template,ctx[7],dirty,null),null)}}},i:function intro(local){if(current)return;transition_in(default_slot,local);current=true},o:function outro(local){transition_out(default_slot,local);current=false},d:function destroy(detaching){if(default_slot)default_slot.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$j.name,type:"slot",source:"(73:1) <Notification notification={notification}>",ctx:ctx});return block}function create_if_block_1$8(ctx){let div;let div_transition;let current;let each_value=ensure_array_like_dev(ctx[0].errors.details);let each_blocks=[];for(let i=0;i<each_value.length;i+=1){each_blocks[i]=create_each_block$6(get_each_context$6(ctx,each_value,i))}const out=i=>transition_out(each_blocks[i],1,1,(()=>{each_blocks[i]=null}));const block={c:function create(){div=element("div");for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].c()}attr_dev(div,"class","details");add_location(div,file$q,50,4,1221)},m:function mount(target,anchor){insert_dev(target,div,anchor);for(let i=0;i<each_blocks.length;i+=1){if(each_blocks[i]){each_blocks[i].m(div,null)}}current=true},p:function update(ctx,dirty){if(dirty&13){each_value=ensure_array_like_dev(ctx[0].errors.details);let i;for(i=0;i<each_value.length;i+=1){const child_ctx=get_each_context$6(ctx,each_value,i);if(each_blocks[i]){each_blocks[i].p(child_ctx,dirty);transition_in(each_blocks[i],1)}else{each_blocks[i]=create_each_block$6(child_ctx);each_blocks[i].c();transition_in(each_blocks[i],1);each_blocks[i].m(div,null)}}group_outros();for(i=each_value.length;i<each_blocks.length;i+=1){out(i)}check_outros()}},i:function intro(local){if(current)return;for(let i=0;i<each_value.length;i+=1){transition_in(each_blocks[i])}if(local){add_render_callback((()=>{if(!current)return;if(!div_transition)div_transition=create_bidirectional_transition(div,slide,{},true);div_transition.run(1)}))}current=true},o:function outro(local){each_blocks=each_blocks.filter(Boolean);for(let i=0;i<each_blocks.length;i+=1){transition_out(each_blocks[i])}if(local){if(!div_transition)div_transition=create_bidirectional_transition(div,slide,{},false);div_transition.run(0)}current=false},d:function destroy(detaching){if(detaching){detach_dev(div)}destroy_each(each_blocks,detaching);if(detaching&&div_transition)div_transition.end()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_1$8.name,type:"if",source:"(50:3) {#if expanded}",ctx:ctx});return block}function create_each_block_1(ctx){let li;let raw_value=ctx[12]+"";const block={c:function create(){li=element("li");add_location(li,file$q,62,9,1779)},m:function mount(target,anchor){insert_dev(target,li,anchor);li.innerHTML=raw_value},p:function update(ctx,dirty){if(dirty&1&&raw_value!==(raw_value=ctx[12]+""))li.innerHTML=raw_value},d:function destroy(detaching){if(detaching){detach_dev(li)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_each_block_1.name,type:"each",source:"(62:8) {#each item.messages as message, index}",ctx:ctx});return block}function create_each_block$6(ctx){let div2;let div1;let div0;let t0_value=ctx[11]+1+". "+ctx[9].source_type_name+"";let t0;let t1;let a;let t2;let t3_value=ctx[9].source_id+"";let t3;let a_href_value;let t4;let button;let t5_value=ctx[2].dismiss+"";let t5;let t6;let ul;let t7;let div2_transition;let current;let mounted;let dispose;function click_handler(){return ctx[5](ctx[9])}let each_value_1=ensure_array_like_dev(ctx[9].messages);let each_blocks=[];for(let i=0;i<each_value_1.length;i+=1){each_blocks[i]=create_each_block_1(get_each_context_1(ctx,each_value_1,i))}const block={c:function create(){div2=element("div");div1=element("div");div0=element("div");t0=text(t0_value);t1=space();a=element("a");t2=text("#");t3=text(t3_value);t4=space();button=element("button");t5=text(t5_value);t6=space();ul=element("ul");for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].c()}t7=space();attr_dev(a,"href",a_href_value=ctx[9].edit_url.url);add_location(a,file$q,56,9,1477);attr_dev(div0,"class","title");add_location(div0,file$q,54,8,1394);attr_dev(button,"class","dismiss");add_location(button,file$q,58,8,1550);attr_dev(div1,"class","summary");add_location(div1,file$q,53,7,1364);attr_dev(ul,"class","detail");add_location(ul,file$q,60,7,1702);attr_dev(div2,"class","item");add_location(div2,file$q,52,6,1322)},m:function mount(target,anchor){insert_dev(target,div2,anchor);append_dev(div2,div1);append_dev(div1,div0);append_dev(div0,t0);append_dev(div0,t1);append_dev(div0,a);append_dev(a,t2);append_dev(a,t3);append_dev(div1,t4);append_dev(div1,button);append_dev(button,t5);append_dev(div2,t6);append_dev(div2,ul);for(let i=0;i<each_blocks.length;i+=1){if(each_blocks[i]){each_blocks[i].m(ul,null)}}append_dev(div2,t7);current=true;if(!mounted){dispose=listen_dev(button,"click",prevent_default(click_handler),false,true,false,false);mounted=true}},p:function update(new_ctx,dirty){ctx=new_ctx;if((!current||dirty&1)&&t0_value!==(t0_value=ctx[11]+1+". "+ctx[9].source_type_name+""))set_data_dev(t0,t0_value);if((!current||dirty&1)&&t3_value!==(t3_value=ctx[9].source_id+""))set_data_dev(t3,t3_value);if(!current||dirty&1&&a_href_value!==(a_href_value=ctx[9].edit_url.url)){attr_dev(a,"href",a_href_value)}if((!current||dirty&4)&&t5_value!==(t5_value=ctx[2].dismiss+""))set_data_dev(t5,t5_value);if(dirty&1){each_value_1=ensure_array_like_dev(ctx[9].messages);let i;for(i=0;i<each_value_1.length;i+=1){const child_ctx=get_each_context_1(ctx,each_value_1,i);if(each_blocks[i]){each_blocks[i].p(child_ctx,dirty)}else{each_blocks[i]=create_each_block_1(child_ctx);each_blocks[i].c();each_blocks[i].m(ul,null)}}for(;i<each_blocks.length;i+=1){each_blocks[i].d(1)}each_blocks.length=each_value_1.length}},i:function intro(local){if(current)return;if(local){add_render_callback((()=>{if(!current)return;if(!div2_transition)div2_transition=create_bidirectional_transition(div2,fade,{},true);div2_transition.run(1)}))}current=true},o:function outro(local){if(local){if(!div2_transition)div2_transition=create_bidirectional_transition(div2,fade,{},false);div2_transition.run(0)}current=false},d:function destroy(detaching){if(detaching){detach_dev(div2)}destroy_each(each_blocks,detaching);if(detaching&&div2_transition)div2_transition.end();mounted=false;dispose()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_each_block$6.name,type:"each",source:"(52:5) {#each notification.errors.details as item, index}",ctx:ctx});return block}function create_details_slot(ctx){let if_block_anchor;let current;let if_block=ctx[1]&&create_if_block_1$8(ctx);const block={c:function create(){if(if_block)if_block.c();if_block_anchor=empty()},m:function mount(target,anchor){if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,dirty){if(ctx[1]){if(if_block){if_block.p(ctx,dirty);if(dirty&2){transition_in(if_block,1)}}else{if_block=create_if_block_1$8(ctx);if_block.c();transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_details_slot.name,type:"slot",source:'(49:2) <svelte:fragment slot=\\"details\\">',ctx:ctx});return block}function create_fragment$t(ctx){let show_if;let current_block_type_index;let if_block;let if_block_anchor;let current;const if_block_creators=[create_if_block$d,create_else_block$8];const if_blocks=[];function select_block_type(ctx,dirty){if(dirty&1)show_if=null;if(show_if==null)show_if=!!(ctx[0].hasOwnProperty("class")&&ctx[0].class==="tool-error"&&ctx[0].hasOwnProperty("errors"));if(show_if)return 0;return 1}current_block_type_index=select_block_type(ctx,-1);if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);const block={c:function create(){if_block.c();if_block_anchor=empty()},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){if_blocks[current_block_type_index].m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,[dirty]){let previous_block_index=current_block_type_index;current_block_type_index=select_block_type(ctx,dirty);if(current_block_type_index===previous_block_index){if_blocks[current_block_type_index].p(ctx,dirty)}else{group_outros();transition_out(if_blocks[previous_block_index],1,1,(()=>{if_blocks[previous_block_index]=null}));check_outros();if_block=if_blocks[current_block_type_index];if(!if_block){if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);if_block.c()}else{if_block.p(ctx,dirty)}transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if_blocks[current_block_type_index].d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$t.name,type:"component",source:"",ctx:ctx});return block}function instance$t($$self,$$props,$$invalidate){let $strings;validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(2,$strings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("ToolNotification",slots,["default"]);let{notification:notification}=$$props;let expanded=true;async function dismissAll(tool_key,item){await api.delete("tools",{id:tool_key,blog_id:item.blog_id,source_type:item.source_type,source_id:item.source_id})}async function dismissError(tool_key,item,index){await api.delete("tools",{id:tool_key,blog_id:item.blog_id,source_type:item.source_type,source_id:item.source_id,errors:index})}$$self.$$.on_mount.push((function(){if(notification===undefined&&!("notification"in $$props||$$self.$$.bound[$$self.$$.props["notification"]])){console.warn("<ToolNotification> was created without expected prop 'notification'")}}));const writable_props=["notification"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<ToolNotification> was created with unknown prop '${key}'`)}));const click_handler=item=>dismissAll(notification.errors.tool_key,item);function notification_1_expanded_binding(value){expanded=value;$$invalidate(1,expanded)}$$self.$$set=$$props=>{if("notification"in $$props)$$invalidate(0,notification=$$props.notification);if("$$scope"in $$props)$$invalidate(7,$$scope=$$props.$$scope)};$$self.$capture_state=()=>({fade:fade,slide:slide,api:api,strings:strings,Notification:Notification,notification:notification,expanded:expanded,dismissAll:dismissAll,dismissError:dismissError,$strings:$strings});$$self.$inject_state=$$props=>{if("notification"in $$props)$$invalidate(0,notification=$$props.notification);if("expanded"in $$props)$$invalidate(1,expanded=$$props.expanded)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[notification,expanded,$strings,dismissAll,slots,click_handler,notification_1_expanded_binding,$$scope]}class ToolNotification extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$t,create_fragment$t,safe_not_equal,{notification:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"ToolNotification",options:options,id:create_fragment$t.name})}get notification(){throw new Error("<ToolNotification>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set notification(value){throw new Error("<ToolNotification>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}function is_date(obj){return Object.prototype.toString.call(obj)==="[object Date]"}function get_interpolator(a,b){if(a===b||a!==a)return()=>a;const type=typeof a;if(type!==typeof b||Array.isArray(a)!==Array.isArray(b)){throw new Error("Cannot interpolate values of different type")}if(Array.isArray(a)){const arr=b.map(((bi,i)=>get_interpolator(a[i],bi)));return t=>arr.map((fn=>fn(t)))}if(type==="object"){if(!a||!b)throw new Error("Object cannot be null");if(is_date(a)&&is_date(b)){a=a.getTime();b=b.getTime();const delta=b-a;return t=>new Date(a+t*delta)}const keys=Object.keys(b);const interpolators={};keys.forEach((key=>{interpolators[key]=get_interpolator(a[key],b[key])}));return t=>{const result={};keys.forEach((key=>{result[key]=interpolators[key](t)}));return result}}if(type==="number"){const delta=b-a;return t=>a+t*delta}throw new Error(`Cannot interpolate ${type} values`)}function tweened(value,defaults={}){const store=writable(value);let task;let target_value=value;function set(new_value,opts){if(value==null){store.set(value=new_value);return Promise.resolve()}target_value=new_value;let previous_task=task;let started=false;let{delay:delay=0,duration:duration=400,easing:easing=identity,interpolate:interpolate=get_interpolator}=assign(assign({},defaults),opts);if(duration===0){if(previous_task){previous_task.abort();previous_task=null}store.set(value=target_value);return Promise.resolve()}const start=now()+delay;let fn;task=loop((now=>{if(now<start)return true;if(!started){fn=interpolate(value,new_value);if(typeof duration==="function")duration=duration(value,new_value);started=true}if(previous_task){previous_task.abort();previous_task=null}const elapsed=now-start;if(elapsed>duration){store.set(value=new_value);return false}store.set(value=fn(easing(elapsed/duration)));return true}));return task.promise}return{set:set,update:(fn,opts)=>set(fn(target_value,value),opts),subscribe:store.subscribe}}const file$p="ui/components/ProgressBar.svelte";function create_fragment$s(ctx){let div;let span;let mounted;let dispose;const block={c:function create(){div=element("div");span=element("span");attr_dev(span,"class","indicator animate");set_style(span,"width",ctx[5]+"%");toggle_class(span,"complete",ctx[4]);toggle_class(span,"running",ctx[1]);add_location(span,file$p,50,1,993);attr_dev(div,"class","progress-bar");attr_dev(div,"title",ctx[3]);toggle_class(div,"stripe",ctx[1]&&!ctx[2]);toggle_class(div,"animate",ctx[0]);add_location(div,file$p,41,0,837)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,div,anchor);append_dev(div,span);if(!mounted){dispose=[listen_dev(div,"click",prevent_default(ctx[8]),false,true,false,false),listen_dev(div,"mouseenter",ctx[9],false,false,false,false),listen_dev(div,"mouseleave",ctx[10],false,false,false,false)];mounted=true}},p:function update(ctx,[dirty]){if(dirty&32){set_style(span,"width",ctx[5]+"%")}if(dirty&16){toggle_class(span,"complete",ctx[4])}if(dirty&2){toggle_class(span,"running",ctx[1])}if(dirty&8){attr_dev(div,"title",ctx[3])}if(dirty&6){toggle_class(div,"stripe",ctx[1]&&!ctx[2])}if(dirty&1){toggle_class(div,"animate",ctx[0])}},i:noop,o:noop,d:function destroy(detaching){if(detaching){detach_dev(div)}mounted=false;run_all(dispose)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$s.name,type:"component",source:"",ctx:ctx});return block}function getProgress(percent){if(percent<1){return 0}if(percent>=100){return 100}return percent}function instance$s($$self,$$props,$$invalidate){let complete;let $progressTweened;let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("ProgressBar",slots,[]);let{percentComplete:percentComplete=0}=$$props;let{starting:starting=false}=$$props;let{running:running=false}=$$props;let{paused:paused=false}=$$props;let{title:title=""}=$$props;let progressTweened=tweened(0,{duration:400,easing:cubicOut});validate_store(progressTweened,"progressTweened");component_subscribe($$self,progressTweened,(value=>$$invalidate(5,$progressTweened=value)));const writable_props=["percentComplete","starting","running","paused","title"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<ProgressBar> was created with unknown prop '${key}'`)}));function click_handler(event){bubble.call(this,$$self,event)}function mouseenter_handler(event){bubble.call(this,$$self,event)}function mouseleave_handler(event){bubble.call(this,$$self,event)}$$self.$$set=$$props=>{if("percentComplete"in $$props)$$invalidate(7,percentComplete=$$props.percentComplete);if("starting"in $$props)$$invalidate(0,starting=$$props.starting);if("running"in $$props)$$invalidate(1,running=$$props.running);if("paused"in $$props)$$invalidate(2,paused=$$props.paused);if("title"in $$props)$$invalidate(3,title=$$props.title)};$$self.$capture_state=()=>({cubicOut:cubicOut,tweened:tweened,percentComplete:percentComplete,starting:starting,running:running,paused:paused,title:title,progressTweened:progressTweened,getProgress:getProgress,complete:complete,$progressTweened:$progressTweened});$$self.$inject_state=$$props=>{if("percentComplete"in $$props)$$invalidate(7,percentComplete=$$props.percentComplete);if("starting"in $$props)$$invalidate(0,starting=$$props.starting);if("running"in $$props)$$invalidate(1,running=$$props.running);if("paused"in $$props)$$invalidate(2,paused=$$props.paused);if("title"in $$props)$$invalidate(3,title=$$props.title);if("progressTweened"in $$props)$$invalidate(6,progressTweened=$$props.progressTweened);if("complete"in $$props)$$invalidate(4,complete=$$props.complete)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty&128){progressTweened.set(getProgress(percentComplete))}if($$self.$$.dirty&128){$$invalidate(4,complete=percentComplete>=100)}};return[starting,running,paused,title,complete,$progressTweened,progressTweened,percentComplete,click_handler,mouseenter_handler,mouseleave_handler]}class ProgressBar extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$s,create_fragment$s,safe_not_equal,{percentComplete:7,starting:0,running:1,paused:2,title:3});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"ProgressBar",options:options,id:create_fragment$s.name})}get percentComplete(){throw new Error("<ProgressBar>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set percentComplete(value){throw new Error("<ProgressBar>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get starting(){throw new Error("<ProgressBar>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set starting(value){throw new Error("<ProgressBar>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get running(){throw new Error("<ProgressBar>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set running(value){throw new Error("<ProgressBar>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get paused(){throw new Error("<ProgressBar>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set paused(value){throw new Error("<ProgressBar>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get title(){throw new Error("<ProgressBar>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set title(value){throw new Error("<ProgressBar>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}function create_if_block$c(ctx){let button0;let t;let button1;let current;button0=new Button({props:{outline:true,small:ctx[2],disabled:ctx[1],class:"pause",$$slots:{default:[create_default_slot_1$e]},$$scope:{ctx:ctx}},$$inline:true});button0.$on("click",ctx[4]);button1=new Button({props:{outline:true,small:ctx[2],disabled:ctx[1],$$slots:{default:[create_default_slot$i]},$$scope:{ctx:ctx}},$$inline:true});button1.$on("click",ctx[5]);const block={c:function create(){create_component(button0.$$.fragment);t=space();create_component(button1.$$.fragment)},m:function mount(target,anchor){mount_component(button0,target,anchor);insert_dev(target,t,anchor);mount_component(button1,target,anchor);current=true},p:function update(ctx,dirty){const button0_changes={};if(dirty&4)button0_changes.small=ctx[2];if(dirty&2)button0_changes.disabled=ctx[1];if(dirty&73){button0_changes.$$scope={dirty:dirty,ctx:ctx}}button0.$set(button0_changes);const button1_changes={};if(dirty&4)button1_changes.small=ctx[2];if(dirty&2)button1_changes.disabled=ctx[1];if(dirty&72){button1_changes.$$scope={dirty:dirty,ctx:ctx}}button1.$set(button1_changes)},i:function intro(local){if(current)return;transition_in(button0.$$.fragment,local);transition_in(button1.$$.fragment,local);current=true},o:function outro(local){transition_out(button0.$$.fragment,local);transition_out(button1.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t)}destroy_component(button0,detaching);destroy_component(button1,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$c.name,type:"if",source:"(25:0) {#if tool}",ctx:ctx});return block}function create_else_block$7(ctx){let t_value=ctx[3].pause_button+"";let t;const block={c:function create(){t=text(t_value)},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty&8&&t_value!==(t_value=ctx[3].pause_button+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block$7.name,type:"else",source:"(29:2) {:else}",ctx:ctx});return block}function create_if_block_1$7(ctx){let t_value=ctx[3].resume_button+"";let t;const block={c:function create(){t=text(t_value)},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty&8&&t_value!==(t_value=ctx[3].resume_button+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_1$7.name,type:"if",source:"(27:2) {#if tool.is_paused}",ctx:ctx});return block}function create_default_slot_1$e(ctx){let if_block_anchor;function select_block_type(ctx,dirty){if(ctx[0].is_paused)return create_if_block_1$7;return create_else_block$7}let current_block_type=select_block_type(ctx);let if_block=current_block_type(ctx);const block={c:function create(){if_block.c();if_block_anchor=empty()},m:function mount(target,anchor){if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor)},p:function update(ctx,dirty){if(current_block_type===(current_block_type=select_block_type(ctx))&&if_block){if_block.p(ctx,dirty)}else{if_block.d(1);if_block=current_block_type(ctx);if(if_block){if_block.c();if_block.m(if_block_anchor.parentNode,if_block_anchor)}}},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$e.name,type:"slot",source:'(26:1) <Button outline {small} {disabled} class=\\"pause\\" on:click={handlePauseResume}>',ctx:ctx});return block}function create_default_slot$i(ctx){let t_value=ctx[3].cancel_button+"";let t;const block={c:function create(){t=text(t_value)},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty&8&&t_value!==(t_value=ctx[3].cancel_button+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$i.name,type:"slot",source:"(33:1) <Button outline {small} {disabled} on:click={handleCancel}>",ctx:ctx});return block}function create_fragment$r(ctx){let if_block_anchor;let current;let if_block=ctx[0]&&create_if_block$c(ctx);const block={c:function create(){if(if_block)if_block.c();if_block_anchor=empty()},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,[dirty]){if(ctx[0]){if(if_block){if_block.p(ctx,dirty);if(dirty&1){transition_in(if_block,1)}}else{if_block=create_if_block$c(ctx);if_block.c();transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$r.name,type:"component",source:"",ctx:ctx});return block}function instance$r($$self,$$props,$$invalidate){let $strings;validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(3,$strings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("ToolRunningButtons",slots,[]);let{tool:tool={}}=$$props;let{disabled:disabled=false}=$$props;let{small:small=false}=$$props;function handlePauseResume(){tools.pauseResume(tool)}function handleCancel(){tools.cancel(tool)}const writable_props=["tool","disabled","small"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<ToolRunningButtons> was created with unknown prop '${key}'`)}));$$self.$$set=$$props=>{if("tool"in $$props)$$invalidate(0,tool=$$props.tool);if("disabled"in $$props)$$invalidate(1,disabled=$$props.disabled);if("small"in $$props)$$invalidate(2,small=$$props.small)};$$self.$capture_state=()=>({tools:tools,strings:strings,Button:Button,tool:tool,disabled:disabled,small:small,handlePauseResume:handlePauseResume,handleCancel:handleCancel,$strings:$strings});$$self.$inject_state=$$props=>{if("tool"in $$props)$$invalidate(0,tool=$$props.tool);if("disabled"in $$props)$$invalidate(1,disabled=$$props.disabled);if("small"in $$props)$$invalidate(2,small=$$props.small)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[tool,disabled,small,$strings,handlePauseResume,handleCancel]}class ToolRunningButtons extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$r,create_fragment$r,safe_not_equal,{tool:0,disabled:1,small:2});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"ToolRunningButtons",options:options,id:create_fragment$r.name})}get tool(){throw new Error("<ToolRunningButtons>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set tool(value){throw new Error("<ToolRunningButtons>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get disabled(){throw new Error("<ToolRunningButtons>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set disabled(value){throw new Error("<ToolRunningButtons>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get small(){throw new Error("<ToolRunningButtons>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set small(value){throw new Error("<ToolRunningButtons>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}function getLocale(){return navigator.languages&&navigator.languages.length?navigator.languages[0]:navigator.language}function numToString(num){return Intl.NumberFormat(getLocale()).format(num)}function numToShortString(num){return Intl.NumberFormat(getLocale(),{notation:"compact"}).format(num)}const file$o="ui/pro/ToolPanel.svelte";function get_each_context$5(ctx,list,i){const child_ctx=ctx.slice();child_ctx[26]=list[i][0];child_ctx[27]=list[i][1];return child_ctx}const get_status_right_slot_changes=dirty=>({isRunning:dirty&2});const get_status_right_slot_context=ctx=>({isRunning:ctx[1]});function create_else_block_3(ctx){let h3;let raw_value=ctx[0].title+"";const block={c:function create(){h3=element("h3");add_location(h3,file$o,115,3,3202)},m:function mount(target,anchor){insert_dev(target,h3,anchor);h3.innerHTML=raw_value},p:function update(ctx,dirty){if(dirty&1&&raw_value!==(raw_value=ctx[0].title+""))h3.innerHTML=raw_value},d:function destroy(detaching){if(detaching){detach_dev(h3)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block_3.name,type:"else",source:"(115:2) {:else}",ctx:ctx});return block}function create_if_block_9(ctx){let if_block_anchor;function select_block_type_1(ctx,dirty){if(ctx[4])return create_if_block_10;if(ctx[3])return create_if_block_11;return create_else_block_2}let current_block_type=select_block_type_1(ctx);let if_block=current_block_type(ctx);const block={c:function create(){if_block.c();if_block_anchor=empty()},m:function mount(target,anchor){if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor)},p:function update(ctx,dirty){if(current_block_type===(current_block_type=select_block_type_1(ctx))&&if_block){if_block.p(ctx,dirty)}else{if_block.d(1);if_block=current_block_type(ctx);if(if_block){if_block.c();if_block.m(if_block_anchor.parentNode,if_block_anchor)}}},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_9.name,type:"if",source:"(107:2) {#if showTotal}",ctx:ctx});return block}function create_else_block_2(ctx){let h3;let raw_value=ctx[0].title_complete+"";const block={c:function create(){h3=element("h3");add_location(h3,file$o,112,4,3143)},m:function mount(target,anchor){insert_dev(target,h3,anchor);h3.innerHTML=raw_value},p:function update(ctx,dirty){if(dirty&1&&raw_value!==(raw_value=ctx[0].title_complete+""))h3.innerHTML=raw_value},d:function destroy(detaching){if(detaching){detach_dev(h3)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block_2.name,type:"else",source:"(112:3) {:else}",ctx:ctx});return block}function create_if_block_11(ctx){let h3;let raw_value=ctx[0].title_partial_complete+"";const block={c:function create(){h3=element("h3");add_location(h3,file$o,110,4,3083)},m:function mount(target,anchor){insert_dev(target,h3,anchor);h3.innerHTML=raw_value},p:function update(ctx,dirty){if(dirty&1&&raw_value!==(raw_value=ctx[0].title_partial_complete+""))h3.innerHTML=raw_value},d:function destroy(detaching){if(detaching){detach_dev(h3)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_11.name,type:"if",source:"(110:29) ",ctx:ctx});return block}function create_if_block_10(ctx){let h3;let raw_value=ctx[0].title+"";const block={c:function create(){h3=element("h3");add_location(h3,file$o,108,4,3021)},m:function mount(target,anchor){insert_dev(target,h3,anchor);h3.innerHTML=raw_value},p:function update(ctx,dirty){if(dirty&1&&raw_value!==(raw_value=ctx[0].title+""))h3.innerHTML=raw_value},d:function destroy(detaching){if(detaching){detach_dev(h3)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_10.name,type:"if",source:"(108:3) {#if initial}",ctx:ctx});return block}function create_else_block_1$4(ctx){let button;let current;button=new Button({props:{primary:true,disabled:ctx[9],title:ctx[9]?ctx[13].disabled_tool_button:"",$$slots:{default:[create_default_slot_8]},$$scope:{ctx:ctx}},$$inline:true});button.$on("click",ctx[16]);const block={c:function create(){create_component(button.$$.fragment)},m:function mount(target,anchor){mount_component(button,target,anchor);current=true},p:function update(ctx,dirty){const button_changes={};if(dirty&512)button_changes.disabled=ctx[9];if(dirty&8704)button_changes.title=ctx[9]?ctx[13].disabled_tool_button:"";if(dirty&4194305){button_changes.$$scope={dirty:dirty,ctx:ctx}}button.$set(button_changes)},i:function intro(local){if(current)return;transition_in(button.$$.fragment,local);current=true},o:function outro(local){transition_out(button.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(button,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block_1$4.name,type:"else",source:"(130:4) {:else}",ctx:ctx});return block}function create_if_block_8(ctx){let button;let current;button=new Button({props:{primary:true,disabled:ctx[9],title:ctx[9]?ctx[13].disabled_tool_button:"",$$slots:{default:[create_default_slot_7]},$$scope:{ctx:ctx}},$$inline:true});button.$on("click",ctx[16]);const block={c:function create(){create_component(button.$$.fragment)},m:function mount(target,anchor){mount_component(button,target,anchor);current=true},p:function update(ctx,dirty){const button_changes={};if(dirty&512)button_changes.disabled=ctx[9];if(dirty&8704)button_changes.title=ctx[9]?ctx[13].disabled_tool_button:"";if(dirty&4194305){button_changes.$$scope={dirty:dirty,ctx:ctx}}button.$set(button_changes)},i:function intro(local){if(current)return;transition_in(button.$$.fragment,local);current=true},o:function outro(local){transition_out(button.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(button,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_8.name,type:"if",source:"(128:30) ",ctx:ctx});return block}function create_if_block_7(ctx){let button;let current;button=new Button({props:{primary:true,disabled:ctx[9],title:ctx[9]?ctx[13].disabled_tool_button:"",$$slots:{default:[create_default_slot_6]},$$scope:{ctx:ctx}},$$inline:true});button.$on("click",ctx[16]);const block={c:function create(){create_component(button.$$.fragment)},m:function mount(target,anchor){mount_component(button,target,anchor);current=true},p:function update(ctx,dirty){const button_changes={};if(dirty&512)button_changes.disabled=ctx[9];if(dirty&8704)button_changes.title=ctx[9]?ctx[13].disabled_tool_button:"";if(dirty&4194305){button_changes.$$scope={dirty:dirty,ctx:ctx}}button.$set(button_changes)},i:function intro(local){if(current)return;transition_in(button.$$.fragment,local);current=true},o:function outro(local){transition_out(button.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(button,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_7.name,type:"if",source:"(126:22) ",ctx:ctx});return block}function create_if_block_6(ctx){let button;let current;button=new Button({props:{primary:true,disabled:true,title:ctx[13].disabled_tool_bucket_access,$$slots:{default:[create_default_slot_5]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(button.$$.fragment)},m:function mount(target,anchor){mount_component(button,target,anchor);current=true},p:function update(ctx,dirty){const button_changes={};if(dirty&8192)button_changes.title=ctx[13].disabled_tool_bucket_access;if(dirty&4194313){button_changes.$$scope={dirty:dirty,ctx:ctx}}button.$set(button_changes)},i:function intro(local){if(current)return;transition_in(button.$$.fragment,local);current=true},o:function outro(local){transition_out(button.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(button,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_6.name,type:"if",source:"(124:37) ",ctx:ctx});return block}function create_if_block_5(ctx){const block={c:noop,m:noop,p:noop,i:noop,o:noop,d:noop};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_5.name,type:"if",source:"(122:4) {#if complete}",ctx:ctx});return block}function create_if_block_4$1(ctx){let toolrunningbuttons;let current;toolrunningbuttons=new ToolRunningButtons({props:{tool:ctx[0],disabled:ctx[9]},$$inline:true});const block={c:function create(){create_component(toolrunningbuttons.$$.fragment)},m:function mount(target,anchor){mount_component(toolrunningbuttons,target,anchor);current=true},p:function update(ctx,dirty){const toolrunningbuttons_changes={};if(dirty&1)toolrunningbuttons_changes.tool=ctx[0];if(dirty&512)toolrunningbuttons_changes.disabled=ctx[9];toolrunningbuttons.$set(toolrunningbuttons_changes)},i:function intro(local){if(current)return;transition_in(toolrunningbuttons.$$.fragment,local);current=true},o:function outro(local){transition_out(toolrunningbuttons.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(toolrunningbuttons,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_4$1.name,type:"if",source:"(119:3) {#if isRunning}",ctx:ctx});return block}function create_default_slot_8(ctx){let html_tag;let raw_value=ctx[0].button+"";let html_anchor;const block={c:function create(){html_tag=new HtmlTag(false);html_anchor=empty();html_tag.a=html_anchor},m:function mount(target,anchor){html_tag.m(raw_value,target,anchor);insert_dev(target,html_anchor,anchor)},p:function update(ctx,dirty){if(dirty&1&&raw_value!==(raw_value=ctx[0].button+""))html_tag.p(raw_value)},d:function destroy(detaching){if(detaching){detach_dev(html_anchor);html_tag.d()}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_8.name,type:"slot",source:'(131:5) <Button primary {disabled} title={disabled ? $strings.disabled_tool_button : \\"\\"} on:click={handleStart}>',ctx:ctx});return block}function create_default_slot_7(ctx){let html_tag;let raw_value=ctx[0].button_partial_complete+"";let html_anchor;const block={c:function create(){html_tag=new HtmlTag(false);html_anchor=empty();html_tag.a=html_anchor},m:function mount(target,anchor){html_tag.m(raw_value,target,anchor);insert_dev(target,html_anchor,anchor)},p:function update(ctx,dirty){if(dirty&1&&raw_value!==(raw_value=ctx[0].button_partial_complete+""))html_tag.p(raw_value)},d:function destroy(detaching){if(detaching){detach_dev(html_anchor);html_tag.d()}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_7.name,type:"slot",source:'(129:5) <Button primary {disabled} title={disabled ? $strings.disabled_tool_button : \\"\\"} on:click={handleStart}>',ctx:ctx});return block}function create_default_slot_6(ctx){let html_tag;let raw_value=ctx[0].button+"";let html_anchor;const block={c:function create(){html_tag=new HtmlTag(false);html_anchor=empty();html_tag.a=html_anchor},m:function mount(target,anchor){html_tag.m(raw_value,target,anchor);insert_dev(target,html_anchor,anchor)},p:function update(ctx,dirty){if(dirty&1&&raw_value!==(raw_value=ctx[0].button+""))html_tag.p(raw_value)},d:function destroy(detaching){if(detaching){detach_dev(html_anchor);html_tag.d()}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_6.name,type:"slot",source:'(127:5) <Button primary {disabled} title={disabled ? $strings.disabled_tool_button : \\"\\"} on:click={handleStart}>',ctx:ctx});return block}function create_default_slot_5(ctx){let html_tag;let raw_value=(ctx[3]?ctx[0].button_partial_complete:ctx[0].button)+"";let html_anchor;const block={c:function create(){html_tag=new HtmlTag(false);html_anchor=empty();html_tag.a=html_anchor},m:function mount(target,anchor){html_tag.m(raw_value,target,anchor);insert_dev(target,html_anchor,anchor)},p:function update(ctx,dirty){if(dirty&9&&raw_value!==(raw_value=(ctx[3]?ctx[0].button_partial_complete:ctx[0].button)+""))html_tag.p(raw_value)},d:function destroy(detaching){if(detaching){detach_dev(html_anchor);html_tag.d()}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_5.name,type:"slot",source:"(125:5) <Button primary disabled={true} title={$strings.disabled_tool_bucket_access}>",ctx:ctx});return block}function create_default_slot_4$1(ctx){let img;let img_src_value;let img_alt_value;let t0;let t1;let div;let current_block_type_index;let if_block1;let current;function select_block_type(ctx,dirty){if(ctx[2])return create_if_block_9;return create_else_block_3}let current_block_type=select_block_type(ctx);let if_block0=current_block_type(ctx);const if_block_creators=[create_if_block_4$1,create_if_block_5,create_if_block_6,create_if_block_7,create_if_block_8,create_else_block_1$4];const if_blocks=[];function select_block_type_2(ctx,dirty){if(ctx[1])return 0;if(ctx[11])return 1;if(ctx[8])return 2;if(ctx[4])return 3;if(ctx[3])return 4;return 5}current_block_type_index=select_block_type_2(ctx);if_block1=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);const block={c:function create(){img=element("img");t0=space();if_block0.c();t1=space();div=element("div");if_block1.c();if(!src_url_equal(img.src,img_src_value=ctx[6]))attr_dev(img,"src",img_src_value);attr_dev(img,"type","image/svg+xml");attr_dev(img,"alt",img_alt_value=ctx[0].title);add_location(img,file$o,105,2,2927);attr_dev(div,"class","buttons-right");add_location(div,file$o,117,2,3240)},m:function mount(target,anchor){insert_dev(target,img,anchor);insert_dev(target,t0,anchor);if_block0.m(target,anchor);insert_dev(target,t1,anchor);insert_dev(target,div,anchor);if_blocks[current_block_type_index].m(div,null);current=true},p:function update(ctx,dirty){if(!current||dirty&64&&!src_url_equal(img.src,img_src_value=ctx[6])){attr_dev(img,"src",img_src_value)}if(!current||dirty&1&&img_alt_value!==(img_alt_value=ctx[0].title)){attr_dev(img,"alt",img_alt_value)}if(current_block_type===(current_block_type=select_block_type(ctx))&&if_block0){if_block0.p(ctx,dirty)}else{if_block0.d(1);if_block0=current_block_type(ctx);if(if_block0){if_block0.c();if_block0.m(t1.parentNode,t1)}}let previous_block_index=current_block_type_index;current_block_type_index=select_block_type_2(ctx);if(current_block_type_index===previous_block_index){if_blocks[current_block_type_index].p(ctx,dirty)}else{group_outros();transition_out(if_blocks[previous_block_index],1,1,(()=>{if_blocks[previous_block_index]=null}));check_outros();if_block1=if_blocks[current_block_type_index];if(!if_block1){if_block1=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);if_block1.c()}else{if_block1.p(ctx,dirty)}transition_in(if_block1,1);if_block1.m(div,null)}},i:function intro(local){if(current)return;transition_in(if_block1);current=true},o:function outro(local){transition_out(if_block1);current=false},d:function destroy(detaching){if(detaching){detach_dev(img);detach_dev(t0);detach_dev(t1);detach_dev(div)}if_block0.d(detaching);if_blocks[current_block_type_index].d()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_4$1.name,type:"slot",source:"(105:1) <PanelRow header>",ctx:ctx});return block}function create_if_block_2$2(ctx){let panelrow;let current;panelrow=new PanelRow({props:{class:"body flex-row show-progress",$$slots:{default:[create_default_slot_3$2]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty&4195463){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_2$2.name,type:"if",source:"(136:1) {#if complete || partialComplete || isRunning}",ctx:ctx});return block}function create_else_block$6(ctx){let h4;let raw_value=ctx[0].progress_description+"";const block={c:function create(){h4=element("h4");add_location(h4,file$o,144,5,4543)},m:function mount(target,anchor){insert_dev(target,h4,anchor);h4.innerHTML=raw_value},p:function update(ctx,dirty){if(dirty&1&&raw_value!==(raw_value=ctx[0].progress_description+""))h4.innerHTML=raw_value},d:function destroy(detaching){if(detaching){detach_dev(h4)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block$6.name,type:"else",source:"(144:4) {:else }",ctx:ctx});return block}function create_if_block_3$1(ctx){let h4;let strong;let t0_value=ctx[14](ctx[0],ctx[1],ctx[2])+"";let t0;let t1;let t2;let t3_value=numToString(ctx[0].queue.processed)+"";let t3;let t4;let t5_value=numToString(ctx[0].queue.total)+"";let t5;let t6;let html_tag;let raw_value=(ctx[0].status_description?" "+ctx[0].status_description:" "+ctx[0].busy_description)+"";const block={c:function create(){h4=element("h4");strong=element("strong");t0=text(t0_value);t1=text("%");t2=text(" (");t3=text(t3_value);t4=text("/");t5=text(t5_value);t6=text(")\n\t\t\t\t\t\t");html_tag=new HtmlTag(false);add_location(strong,file$o,140,6,4271);html_tag.a=null;add_location(h4,file$o,139,5,4260)},m:function mount(target,anchor){insert_dev(target,h4,anchor);append_dev(h4,strong);append_dev(strong,t0);append_dev(strong,t1);append_dev(h4,t2);append_dev(h4,t3);append_dev(h4,t4);append_dev(h4,t5);append_dev(h4,t6);html_tag.m(raw_value,h4)},p:function update(ctx,dirty){if(dirty&7&&t0_value!==(t0_value=ctx[14](ctx[0],ctx[1],ctx[2])+""))set_data_dev(t0,t0_value);if(dirty&1&&t3_value!==(t3_value=numToString(ctx[0].queue.processed)+""))set_data_dev(t3,t3_value);if(dirty&1&&t5_value!==(t5_value=numToString(ctx[0].queue.total)+""))set_data_dev(t5,t5_value);if(dirty&1&&raw_value!==(raw_value=(ctx[0].status_description?" "+ctx[0].status_description:" "+ctx[0].busy_description)+""))html_tag.p(raw_value)},d:function destroy(detaching){if(detaching){detach_dev(h4)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_3$1.name,type:"if",source:"(139:4) {#if isRunning}",ctx:ctx});return block}function create_default_slot_3$2(ctx){let div;let t0;let t1;let progressbar;let current;function select_block_type_3(ctx,dirty){if(ctx[1])return create_if_block_3$1;return create_else_block$6}let current_block_type=select_block_type_3(ctx);let if_block=current_block_type(ctx);const status_right_slot_template=ctx[20]["status-right"];const status_right_slot=create_slot(status_right_slot_template,ctx,ctx[22],get_status_right_slot_context);progressbar=new ProgressBar({props:{percentComplete:ctx[7],starting:ctx[10],running:ctx[1],paused:ctx[0].is_paused,title:!ctx[1]&&ctx[2]?"("+numToString(ctx[0].total_processed)+"/"+numToString(ctx[0].total_items)+")":""},$$inline:true});const block={c:function create(){div=element("div");if_block.c();t0=space();if(status_right_slot)status_right_slot.c();t1=space();create_component(progressbar.$$.fragment);attr_dev(div,"class","status");add_location(div,file$o,137,3,4214)},m:function mount(target,anchor){insert_dev(target,div,anchor);if_block.m(div,null);append_dev(div,t0);if(status_right_slot){status_right_slot.m(div,null)}insert_dev(target,t1,anchor);mount_component(progressbar,target,anchor);current=true},p:function update(ctx,dirty){if(current_block_type===(current_block_type=select_block_type_3(ctx))&&if_block){if_block.p(ctx,dirty)}else{if_block.d(1);if_block=current_block_type(ctx);if(if_block){if_block.c();if_block.m(div,t0)}}if(status_right_slot){if(status_right_slot.p&&(!current||dirty&4194306)){update_slot_base(status_right_slot,status_right_slot_template,ctx,ctx[22],!current?get_all_dirty_from_scope(ctx[22]):get_slot_changes(status_right_slot_template,ctx[22],dirty,get_status_right_slot_changes),get_status_right_slot_context)}}const progressbar_changes={};if(dirty&128)progressbar_changes.percentComplete=ctx[7];if(dirty&1024)progressbar_changes.starting=ctx[10];if(dirty&2)progressbar_changes.running=ctx[1];if(dirty&1)progressbar_changes.paused=ctx[0].is_paused;if(dirty&7)progressbar_changes.title=!ctx[1]&&ctx[2]?"("+numToString(ctx[0].total_processed)+"/"+numToString(ctx[0].total_items)+")":"";progressbar.$set(progressbar_changes)},i:function intro(local){if(current)return;transition_in(status_right_slot,local);transition_in(progressbar.$$.fragment,local);current=true},o:function outro(local){transition_out(status_right_slot,local);transition_out(progressbar.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(div);detach_dev(t1)}if_block.d();if(status_right_slot)status_right_slot.d(detaching);destroy_component(progressbar,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_3$2.name,type:"slot",source:'(137:2) <PanelRow class=\\"body flex-row show-progress\\">',ctx:ctx});return block}function create_if_block$b(ctx){let panelrow;let t;let if_block_anchor;let current;panelrow=new PanelRow({props:{class:"body flex-row",$$slots:{default:[create_default_slot_2$b]},$$scope:{ctx:ctx}},$$inline:true});let if_block=!ctx[9]&&ctx[5].size>0&&create_if_block_1$6(ctx);const block={c:function create(){create_component(panelrow.$$.fragment);t=space();if(if_block)if_block.c();if_block_anchor=empty()},m:function mount(target,anchor){mount_component(panelrow,target,anchor);insert_dev(target,t,anchor);if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty&4194305){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes);if(!ctx[9]&&ctx[5].size>0){if(if_block){if_block.p(ctx,dirty);if(dirty&544){transition_in(if_block,1)}}else{if_block=create_if_block_1$6(ctx);if_block.c();transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);transition_in(if_block);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(t);detach_dev(if_block_anchor)}destroy_component(panelrow,detaching);if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$b.name,type:"if",source:"(158:1) {#if !complete && !partialComplete && !isRunning}",ctx:ctx});return block}function create_default_slot_2$b(ctx){let p;let raw_value=ctx[0].more_info+"";const block={c:function create(){p=element("p");attr_dev(p,"class","desc");add_location(p,file$o,159,3,4999)},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=raw_value},p:function update(ctx,dirty){if(dirty&1&&raw_value!==(raw_value=ctx[0].more_info+""))p.innerHTML=raw_value},d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_2$b.name,type:"slot",source:'(159:2) <PanelRow class=\\"body flex-row\\">',ctx:ctx});return block}function create_if_block_1$6(ctx){let panelrow;let current;panelrow=new PanelRow({props:{class:"body flex-column",footer:true,$$slots:{default:[create_default_slot_1$d]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty&4198432){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_1$6.name,type:"if",source:"(162:2) {#if !disabled && relatedTools.size > 0 }",ctx:ctx});return block}function create_each_block$5(ctx){let p;let a;let t0_value=ctx[27].title+"";let t0;let a_href_value;let a_title_value;let t1;let mounted;let dispose;function click_handler(){return ctx[21](ctx[27])}const block={c:function create(){p=element("p");a=element("a");t0=text(t0_value);t1=space();attr_dev(a,"href",a_href_value=ctx[12].settings);attr_dev(a,"title",a_title_value=ctx[27].more_info);add_location(a,file$o,165,6,5214);add_location(p,file$o,164,5,5204)},m:function mount(target,anchor){insert_dev(target,p,anchor);append_dev(p,a);append_dev(a,t0);append_dev(p,t1);if(!mounted){dispose=listen_dev(a,"click",prevent_default(click_handler),false,true,false,false);mounted=true}},p:function update(new_ctx,dirty){ctx=new_ctx;if(dirty&32&&t0_value!==(t0_value=ctx[27].title+""))set_data_dev(t0,t0_value);if(dirty&4096&&a_href_value!==(a_href_value=ctx[12].settings)){attr_dev(a,"href",a_href_value)}if(dirty&32&&a_title_value!==(a_title_value=ctx[27].more_info)){attr_dev(a,"title",a_title_value)}},d:function destroy(detaching){if(detaching){detach_dev(p)}mounted=false;dispose()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_each_block$5.name,type:"each",source:"(164:4) {#each [...relatedTools] as [key, relatedTool] }",ctx:ctx});return block}function create_default_slot_1$d(ctx){let each_1_anchor;let each_value=ensure_array_like_dev([...ctx[5]]);let each_blocks=[];for(let i=0;i<each_value.length;i+=1){each_blocks[i]=create_each_block$5(get_each_context$5(ctx,each_value,i))}const block={c:function create(){for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].c()}each_1_anchor=empty()},m:function mount(target,anchor){for(let i=0;i<each_blocks.length;i+=1){if(each_blocks[i]){each_blocks[i].m(target,anchor)}}insert_dev(target,each_1_anchor,anchor)},p:function update(ctx,dirty){if(dirty&36896){each_value=ensure_array_like_dev([...ctx[5]]);let i;for(i=0;i<each_value.length;i+=1){const child_ctx=get_each_context$5(ctx,each_value,i);if(each_blocks[i]){each_blocks[i].p(child_ctx,dirty)}else{each_blocks[i]=create_each_block$5(child_ctx);each_blocks[i].c();each_blocks[i].m(each_1_anchor.parentNode,each_1_anchor)}}for(;i<each_blocks.length;i+=1){each_blocks[i].d(1)}each_blocks.length=each_value.length}},d:function destroy(detaching){if(detaching){detach_dev(each_1_anchor)}destroy_each(each_blocks,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$d.name,type:"slot",source:'(163:3) <PanelRow class=\\"body flex-column\\" footer>',ctx:ctx});return block}function create_default_slot$h(ctx){let panelrow;let t0;let t1;let if_block1_anchor;let current;panelrow=new PanelRow({props:{header:true,$$slots:{default:[create_default_slot_4$1]},$$scope:{ctx:ctx}},$$inline:true});let if_block0=(ctx[11]||ctx[3]||ctx[1])&&create_if_block_2$2(ctx);let if_block1=!ctx[11]&&!ctx[3]&&!ctx[1]&&create_if_block$b(ctx);const block={c:function create(){create_component(panelrow.$$.fragment);t0=space();if(if_block0)if_block0.c();t1=space();if(if_block1)if_block1.c();if_block1_anchor=empty()},m:function mount(target,anchor){mount_component(panelrow,target,anchor);insert_dev(target,t0,anchor);if(if_block0)if_block0.m(target,anchor);insert_dev(target,t1,anchor);if(if_block1)if_block1.m(target,anchor);insert_dev(target,if_block1_anchor,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty&4205407){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes);if(ctx[11]||ctx[3]||ctx[1]){if(if_block0){if_block0.p(ctx,dirty);if(dirty&2058){transition_in(if_block0,1)}}else{if_block0=create_if_block_2$2(ctx);if_block0.c();transition_in(if_block0,1);if_block0.m(t1.parentNode,t1)}}else if(if_block0){group_outros();transition_out(if_block0,1,1,(()=>{if_block0=null}));check_outros()}if(!ctx[11]&&!ctx[3]&&!ctx[1]){if(if_block1){if_block1.p(ctx,dirty);if(dirty&2058){transition_in(if_block1,1)}}else{if_block1=create_if_block$b(ctx);if_block1.c();transition_in(if_block1,1);if_block1.m(if_block1_anchor.parentNode,if_block1_anchor)}}else if(if_block1){group_outros();transition_out(if_block1,1,1,(()=>{if_block1=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);transition_in(if_block0);transition_in(if_block1);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);transition_out(if_block0);transition_out(if_block1);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(t1);detach_dev(if_block1_anchor)}destroy_component(panelrow,detaching);if(if_block0)if_block0.d(detaching);if(if_block1)if_block1.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$h.name,type:"slot",source:'(104:0) <Panel multi class=\\"tools-panel\\">',ctx:ctx});return block}function create_fragment$q(ctx){let panel;let current;panel=new Panel({props:{multi:true,class:"tools-panel",$$slots:{default:[create_default_slot$h]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panel.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(panel,target,anchor);current=true},p:function update(ctx,[dirty]){const panel_changes={};if(dirty&4210687){panel_changes.$$scope={dirty:dirty,ctx:ctx}}panel.$set(panel_changes)},i:function intro(local){if(current)return;transition_in(panel.$$.fragment,local);current=true},o:function outro(local){transition_out(panel.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panel,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$q.name,type:"component",source:"",ctx:ctx});return block}function instance$q($$self,$$props,$$invalidate){let showTotal;let initial;let partialComplete;let complete;let isRunning;let starting;let disabled;let disabled_bucket_access;let percentComplete;let icon;let relatedTools;let $tools;let $urls;let $bucket_writable;let $toolsLocked;let $running;let $strings;validate_store(tools,"tools");component_subscribe($$self,tools,($$value=>$$invalidate(23,$tools=$$value)));validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(12,$urls=$$value)));validate_store(bucket_writable,"bucket_writable");component_subscribe($$self,bucket_writable,($$value=>$$invalidate(17,$bucket_writable=$$value)));validate_store(toolsLocked,"toolsLocked");component_subscribe($$self,toolsLocked,($$value=>$$invalidate(18,$toolsLocked=$$value)));validate_store(running,"running");component_subscribe($$self,running,($$value=>$$invalidate(19,$running=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(13,$strings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("ToolPanel",slots,["status-right"]);let{tool:tool={}}=$$props;function getPercentComplete(tool,isRunning,showTotal){if(isRunning){return tool.progress}else if(showTotal){return tool.total_progress}return 0}function getIcon(tool,isRunning){const icon=tools.icon(tool,isRunning,false);return $urls.assets+"img/icon/"+icon}function getRelatedTools(tool){let related=new Map;if(tool.hasOwnProperty("related_tools")&&tool.related_tools.length>0){tool.related_tools.forEach((key=>{if($tools.hasOwnProperty(key)){related.set(key,$tools[key])}}))}return related}function handleStartTool(tool){tools.start(tool)}function handleStart(){handleStartTool(tool)}const writable_props=["tool"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<ToolPanel> was created with unknown prop '${key}'`)}));const click_handler=relatedTool=>handleStartTool(relatedTool);$$self.$$set=$$props=>{if("tool"in $$props)$$invalidate(0,tool=$$props.tool);if("$$scope"in $$props)$$invalidate(22,$$scope=$$props.$$scope)};$$self.$capture_state=()=>({bucket_writable:bucket_writable,strings:strings,urls:urls,running:running,tools:tools,toolsLocked:toolsLocked,Panel:Panel,PanelRow:PanelRow,Button:Button,ProgressBar:ProgressBar,ToolRunningButtons:ToolRunningButtons,numToString:numToString,tool:tool,getPercentComplete:getPercentComplete,getIcon:getIcon,getRelatedTools:getRelatedTools,handleStartTool:handleStartTool,handleStart:handleStart,relatedTools:relatedTools,isRunning:isRunning,icon:icon,showTotal:showTotal,percentComplete:percentComplete,disabled_bucket_access:disabled_bucket_access,disabled:disabled,starting:starting,partialComplete:partialComplete,initial:initial,complete:complete,$tools:$tools,$urls:$urls,$bucket_writable:$bucket_writable,$toolsLocked:$toolsLocked,$running:$running,$strings:$strings});$$self.$inject_state=$$props=>{if("tool"in $$props)$$invalidate(0,tool=$$props.tool);if("relatedTools"in $$props)$$invalidate(5,relatedTools=$$props.relatedTools);if("isRunning"in $$props)$$invalidate(1,isRunning=$$props.isRunning);if("icon"in $$props)$$invalidate(6,icon=$$props.icon);if("showTotal"in $$props)$$invalidate(2,showTotal=$$props.showTotal);if("percentComplete"in $$props)$$invalidate(7,percentComplete=$$props.percentComplete);if("disabled_bucket_access"in $$props)$$invalidate(8,disabled_bucket_access=$$props.disabled_bucket_access);if("disabled"in $$props)$$invalidate(9,disabled=$$props.disabled);if("starting"in $$props)$$invalidate(10,starting=$$props.starting);if("partialComplete"in $$props)$$invalidate(3,partialComplete=$$props.partialComplete);if("initial"in $$props)$$invalidate(4,initial=$$props.initial);if("complete"in $$props)$$invalidate(11,complete=$$props.complete)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty&1){$$invalidate(2,showTotal=!!tool.hasOwnProperty("total_progress"))}if($$self.$$.dirty&5){$$invalidate(4,initial=!!(showTotal&&tool.total_progress<1))}if($$self.$$.dirty&5){$$invalidate(3,partialComplete=!!(showTotal&&tool.total_progress>0&&tool.total_progress<100))}if($$self.$$.dirty&28){$$invalidate(11,complete=!!(showTotal&&!initial&&!partialComplete))}if($$self.$$.dirty&524289){$$invalidate(1,isRunning=!!($running&&$running===tool.id))}if($$self.$$.dirty&3){$$invalidate(10,starting=!!(isRunning&&tool.progress<1&&!tool.is_paused))}if($$self.$$.dirty&786433){$$invalidate(9,disabled=$running&&$running!==tool.id||tool.is_processing&&tool.is_paused||tool.is_cancelled||$toolsLocked)}if($$self.$$.dirty&131073){$$invalidate(8,disabled_bucket_access=tool.requires_bucket_access&&!$bucket_writable)}if($$self.$$.dirty&7){$$invalidate(7,percentComplete=getPercentComplete(tool,isRunning,showTotal))}if($$self.$$.dirty&3){$$invalidate(6,icon=getIcon(tool,isRunning))}if($$self.$$.dirty&1){$$invalidate(5,relatedTools=getRelatedTools(tool))}};return[tool,isRunning,showTotal,partialComplete,initial,relatedTools,icon,percentComplete,disabled_bucket_access,disabled,starting,complete,$urls,$strings,getPercentComplete,handleStartTool,handleStart,$bucket_writable,$toolsLocked,$running,slots,click_handler,$$scope]}class ToolPanel extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$q,create_fragment$q,safe_not_equal,{tool:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"ToolPanel",options:options,id:create_fragment$q.name})}get tool(){throw new Error("<ToolPanel>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set tool(value){throw new Error("<ToolPanel>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$n="ui/pro/NoTools.svelte";function create_heading_slot(ctx){let div;let t_value=ctx[0].no_tools_header+"";let t;const block={c:function create(){div=element("div");t=text(t_value);attr_dev(div,"slot","heading");add_location(div,file$n,29,1,753)},m:function mount(target,anchor){insert_dev(target,div,anchor);append_dev(div,t)},p:function update(ctx,dirty){if(dirty&1&&t_value!==(t_value=ctx[0].no_tools_header+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(div)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_heading_slot.name,type:"slot",source:"(30:1) ",ctx:ctx});return block}function create_description_slot(ctx){let div;let raw_value=ctx[0].no_tools_description+"";const block={c:function create(){div=element("div");attr_dev(div,"slot","description");add_location(div,file$n,31,1,808)},m:function mount(target,anchor){insert_dev(target,div,anchor);div.innerHTML=raw_value},p:function update(ctx,dirty){if(dirty&1&&raw_value!==(raw_value=ctx[0].no_tools_description+""))div.innerHTML=raw_value},d:function destroy(detaching){if(detaching){detach_dev(div)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_description_slot.name,type:"slot",source:"(32:1) ",ctx:ctx});return block}function create_fragment$p(ctx){let upsell;let current;upsell=new Upsell({props:{benefits:ctx[1],$$slots:{description:[create_description_slot],heading:[create_heading_slot]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(upsell.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(upsell,target,anchor);current=true},p:function update(ctx,[dirty]){const upsell_changes={};if(dirty&9){upsell_changes.$$scope={dirty:dirty,ctx:ctx}}upsell.$set(upsell_changes)},i:function intro(local){if(current)return;transition_in(upsell.$$.fragment,local);current=true},o:function outro(local){transition_out(upsell.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(upsell,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$p.name,type:"component",source:"",ctx:ctx});return block}function instance$p($$self,$$props,$$invalidate){let $strings;let $urls;validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(0,$strings=$$value)));validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(2,$urls=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("NoTools",slots,[]);let benefits=[{icon:$urls.assets+"img/icon/offload-remaining.svg",alt:"offload icon",text:$strings.tools_uppsell_benefits.offload},{icon:$urls.assets+"img/icon/download.svg",alt:"download icon",text:$strings.tools_uppsell_benefits.download},{icon:$urls.assets+"img/icon/remove-from-bucket.svg",alt:"remove from bucket icon",text:$strings.tools_uppsell_benefits.remove_bucket},{icon:$urls.assets+"img/icon/remove-from-server.svg",alt:"remove from server icon",text:$strings.tools_uppsell_benefits.remove_server}];const writable_props=[];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<NoTools> was created with unknown prop '${key}'`)}));$$self.$capture_state=()=>({strings:strings,urls:urls,Upsell:Upsell,benefits:benefits,$strings:$strings,$urls:$urls});$$self.$inject_state=$$props=>{if("benefits"in $$props)$$invalidate(1,benefits=$$props.benefits)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[$strings,benefits]}class NoTools extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$p,create_fragment$p,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"NoTools",options:options,id:create_fragment$p.name})}}const{Object:Object_1$3}=globals;const file$m="ui/pro/ToolsPage.svelte";function get_each_context$4(ctx,list,i){const child_ctx=ctx.slice();child_ctx[4]=list[i];return child_ctx}function create_else_block$5(ctx){let notools;let current;notools=new NoTools({$$inline:true});const block={c:function create(){create_component(notools.$$.fragment)},m:function mount(target,anchor){mount_component(notools,target,anchor);current=true},i:function intro(local){if(current)return;transition_in(notools.$$.fragment,local);current=true},o:function outro(local){transition_out(notools.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(notools,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block$5.name,type:"else",source:"(25:2) {:else}",ctx:ctx});return block}function create_each_block$4(key_1,ctx){let first;let toolpanel;let current;toolpanel=new ToolPanel({props:{tool:ctx[4]},$$inline:true});const block={key:key_1,first:null,c:function create(){first=empty();create_component(toolpanel.$$.fragment);this.first=first},m:function mount(target,anchor){insert_dev(target,first,anchor);mount_component(toolpanel,target,anchor);current=true},p:function update(new_ctx,dirty){ctx=new_ctx;const toolpanel_changes={};if(dirty&4)toolpanel_changes.tool=ctx[4];toolpanel.$set(toolpanel_changes)},i:function intro(local){if(current)return;transition_in(toolpanel.$$.fragment,local);current=true},o:function outro(local){transition_out(toolpanel.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(first)}destroy_component(toolpanel,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_each_block$4.name,type:"each",source:"(23:2) {#each Object.values( $tools ).filter( ( tool ) => tool.render ) as tool (tool.id)}",ctx:ctx});return block}function create_default_slot$g(ctx){let notifications;let t0;let h2;let t1_value=ctx[1].tools_title+"";let t1;let t2;let div;let each_blocks=[];let each_1_lookup=new Map;let current;notifications=new Notifications({props:{tab:ctx[0],component:ToolNotification},$$inline:true});let each_value=ensure_array_like_dev(Object.values(ctx[2]).filter(func));const get_key=ctx=>ctx[4].id;validate_each_keys(ctx,each_value,get_each_context$4,get_key);for(let i=0;i<each_value.length;i+=1){let child_ctx=get_each_context$4(ctx,each_value,i);let key=get_key(child_ctx);each_1_lookup.set(key,each_blocks[i]=create_each_block$4(key,child_ctx))}let each_1_else=null;if(!each_value.length){each_1_else=create_else_block$5(ctx)}const block={c:function create(){create_component(notifications.$$.fragment);t0=space();h2=element("h2");t1=text(t1_value);t2=space();div=element("div");for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].c()}if(each_1_else){each_1_else.c()}attr_dev(h2,"class","page-title");add_location(h2,file$m,19,1,727);attr_dev(div,"class","tools-page wrapper");add_location(div,file$m,21,1,780)},m:function mount(target,anchor){mount_component(notifications,target,anchor);insert_dev(target,t0,anchor);insert_dev(target,h2,anchor);append_dev(h2,t1);insert_dev(target,t2,anchor);insert_dev(target,div,anchor);for(let i=0;i<each_blocks.length;i+=1){if(each_blocks[i]){each_blocks[i].m(div,null)}}if(each_1_else){each_1_else.m(div,null)}current=true},p:function update(ctx,dirty){const notifications_changes={};if(dirty&1)notifications_changes.tab=ctx[0];notifications.$set(notifications_changes);if((!current||dirty&2)&&t1_value!==(t1_value=ctx[1].tools_title+""))set_data_dev(t1,t1_value);if(dirty&4){each_value=ensure_array_like_dev(Object.values(ctx[2]).filter(func));group_outros();validate_each_keys(ctx,each_value,get_each_context$4,get_key);each_blocks=update_keyed_each(each_blocks,dirty,get_key,1,ctx,each_value,each_1_lookup,div,outro_and_destroy_block,create_each_block$4,null,get_each_context$4);check_outros();if(each_value.length){if(each_1_else){group_outros();transition_out(each_1_else,1,1,(()=>{each_1_else=null}));check_outros()}}else if(!each_1_else){each_1_else=create_else_block$5(ctx);each_1_else.c();transition_in(each_1_else,1);each_1_else.m(div,null)}}},i:function intro(local){if(current)return;transition_in(notifications.$$.fragment,local);for(let i=0;i<each_value.length;i+=1){transition_in(each_blocks[i])}current=true},o:function outro(local){transition_out(notifications.$$.fragment,local);for(let i=0;i<each_blocks.length;i+=1){transition_out(each_blocks[i])}current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(h2);detach_dev(t2);detach_dev(div)}destroy_component(notifications,detaching);for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].d()}if(each_1_else)each_1_else.d()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$g.name,type:"slot",source:"(18:0) <Page {name} on:routeEvent>",ctx:ctx});return block}function create_fragment$o(ctx){let page;let current;page=new Page({props:{name:ctx[0],$$slots:{default:[create_default_slot$g]},$$scope:{ctx:ctx}},$$inline:true});page.$on("routeEvent",ctx[3]);const block={c:function create(){create_component(page.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(page,target,anchor);current=true},p:function update(ctx,[dirty]){const page_changes={};if(dirty&1)page_changes.name=ctx[0];if(dirty&135){page_changes.$$scope={dirty:dirty,ctx:ctx}}page.$set(page_changes)},i:function intro(local){if(current)return;transition_in(page.$$.fragment,local);current=true},o:function outro(local){transition_out(page.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(page,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$o.name,type:"component",source:"",ctx:ctx});return block}const func=tool=>tool.render;function instance$o($$self,$$props,$$invalidate){let $strings;let $tools;validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(1,$strings=$$value)));validate_store(tools,"tools");component_subscribe($$self,tools,($$value=>$$invalidate(2,$tools=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("ToolsPage",slots,[]);let{name:name="tools"}=$$props;setContext("settingsLocked",toolsLocked);const writable_props=["name"];Object_1$3.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<ToolsPage> was created with unknown prop '${key}'`)}));function routeEvent_handler(event){bubble.call(this,$$self,event)}$$self.$$set=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name)};$$self.$capture_state=()=>({setContext:setContext,strings:strings,tools:tools,toolsLocked:toolsLocked,Page:Page,Notifications:Notifications,ToolNotification:ToolNotification,ToolPanel:ToolPanel,NoTools:NoTools,name:name,$strings:$strings,$tools:$tools});$$self.$inject_state=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[name,$strings,$tools,routeEvent_handler]}class ToolsPage extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$o,create_fragment$o,safe_not_equal,{name:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"ToolsPage",options:options,id:create_fragment$o.name})}get name(){throw new Error("<ToolsPage>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set name(value){throw new Error("<ToolsPage>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}function autofocus(node){node.focus()}const file$l="ui/pro/LicencePage.svelte";function create_else_block_1$3(ctx){let label;let t0_value=ctx[2].enter_licence_key+"";let t0;let t1;let input;let input_placeholder_value;let t2;let button;let current;let mounted;let dispose;button=new Button({props:{large:true,primary:true,disabled:ctx[1].length===0,$$slots:{default:[create_default_slot_2$a]},$$scope:{ctx:ctx}},$$inline:true});button.$on("click",ctx[4]);const block={c:function create(){label=element("label");t0=text(t0_value);t1=space();input=element("input");t2=space();create_component(button.$$.fragment);attr_dev(label,"for","enter-licence-key");attr_dev(label,"class","screen-reader-text");add_location(label,file$l,86,3,2225);attr_dev(input,"id","enter-licence-key");attr_dev(input,"type","text");attr_dev(input,"class","licence-field");attr_dev(input,"name","licence");attr_dev(input,"minlength","4");attr_dev(input,"placeholder",input_placeholder_value=ctx[2].enter_licence_key);add_location(input,file$l,87,3,2323)},m:function mount(target,anchor){insert_dev(target,label,anchor);append_dev(label,t0);insert_dev(target,t1,anchor);insert_dev(target,input,anchor);set_input_value(input,ctx[1]);insert_dev(target,t2,anchor);mount_component(button,target,anchor);current=true;if(!mounted){dispose=[listen_dev(input,"input",ctx[6]),action_destroyer(autofocus.call(null,input))];mounted=true}},p:function update(ctx,dirty){if((!current||dirty&4)&&t0_value!==(t0_value=ctx[2].enter_licence_key+""))set_data_dev(t0,t0_value);if(!current||dirty&4&&input_placeholder_value!==(input_placeholder_value=ctx[2].enter_licence_key)){attr_dev(input,"placeholder",input_placeholder_value)}if(dirty&2&&input.value!==ctx[1]){set_input_value(input,ctx[1])}const button_changes={};if(dirty&2)button_changes.disabled=ctx[1].length===0;if(dirty&1028){button_changes.$$scope={dirty:dirty,ctx:ctx}}button.$set(button_changes)},i:function intro(local){if(current)return;transition_in(button.$$.fragment,local);current=true},o:function outro(local){transition_out(button.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(label);detach_dev(t1);detach_dev(input);detach_dev(t2)}destroy_component(button,detaching);mounted=false;run_all(dispose)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block_1$3.name,type:"else",source:"(86:2) {:else}",ctx:ctx});return block}function create_if_block$a(ctx){let label;let t0_value=ctx[2].licence_title+"";let t0;let t1;let input;let input_value_value;let t2;let current_block_type_index;let if_block;let if_block_anchor;let current;const if_block_creators=[create_if_block_1$5,create_else_block$4];const if_blocks=[];function select_block_type_1(ctx,dirty){if(ctx[3].is_defined)return 0;return 1}current_block_type_index=select_block_type_1(ctx);if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);const block={c:function create(){label=element("label");t0=text(t0_value);t1=space();input=element("input");t2=space();if_block.c();if_block_anchor=empty();attr_dev(label,"for","licence-key");attr_dev(label,"class","screen-reader-text");add_location(label,file$l,71,3,1798);attr_dev(input,"id","licence-key");attr_dev(input,"type","text");attr_dev(input,"class","licence-field disabled");attr_dev(input,"name","licence");input.value=input_value_value=ctx[3].masked_licence;input.disabled=true;add_location(input,file$l,72,3,1886)},m:function mount(target,anchor){insert_dev(target,label,anchor);append_dev(label,t0);insert_dev(target,t1,anchor);insert_dev(target,input,anchor);insert_dev(target,t2,anchor);if_blocks[current_block_type_index].m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,dirty){if((!current||dirty&4)&&t0_value!==(t0_value=ctx[2].licence_title+""))set_data_dev(t0,t0_value);if(!current||dirty&8&&input_value_value!==(input_value_value=ctx[3].masked_licence)&&input.value!==input_value_value){prop_dev(input,"value",input_value_value)}let previous_block_index=current_block_type_index;current_block_type_index=select_block_type_1(ctx);if(current_block_type_index===previous_block_index){if_blocks[current_block_type_index].p(ctx,dirty)}else{group_outros();transition_out(if_blocks[previous_block_index],1,1,(()=>{if_blocks[previous_block_index]=null}));check_outros();if_block=if_blocks[current_block_type_index];if(!if_block){if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);if_block.c()}else{if_block.p(ctx,dirty)}transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(label);detach_dev(t1);detach_dev(input);detach_dev(t2);detach_dev(if_block_anchor)}if_blocks[current_block_type_index].d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$a.name,type:"if",source:"(71:2) {#if $licence.is_set}",ctx:ctx});return block}function create_default_slot_2$a(ctx){let t_value=ctx[2].activate_licence+"";let t;const block={c:function create(){t=text(t_value)},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty&4&&t_value!==(t_value=ctx[2].activate_licence+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_2$a.name,type:"slot",source:"(98:3) <Button large primary on:click={handleActivateLicence} disabled={value.length === 0}>",ctx:ctx});return block}function create_else_block$4(ctx){let button;let current;button=new Button({props:{large:true,outline:true,$$slots:{default:[create_default_slot_1$c]},$$scope:{ctx:ctx}},$$inline:true});button.$on("click",ctx[5]);const block={c:function create(){create_component(button.$$.fragment)},m:function mount(target,anchor){mount_component(button,target,anchor);current=true},p:function update(ctx,dirty){const button_changes={};if(dirty&1028){button_changes.$$scope={dirty:dirty,ctx:ctx}}button.$set(button_changes)},i:function intro(local){if(current)return;transition_in(button.$$.fragment,local);current=true},o:function outro(local){transition_out(button.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(button,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block$4.name,type:"else",source:"(83:3) {:else}",ctx:ctx});return block}function create_if_block_1$5(ctx){let definedinwpconfig;let current;definedinwpconfig=new DefinedInWPConfig({props:{defined:true},$$inline:true});const block={c:function create(){create_component(definedinwpconfig.$$.fragment)},m:function mount(target,anchor){mount_component(definedinwpconfig,target,anchor);current=true},p:noop,i:function intro(local){if(current)return;transition_in(definedinwpconfig.$$.fragment,local);current=true},o:function outro(local){transition_out(definedinwpconfig.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(definedinwpconfig,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_1$5.name,type:"if",source:"(81:3) {#if $licence.is_defined}",ctx:ctx});return block}function create_default_slot_1$c(ctx){let t_value=ctx[2].remove_licence+"";let t;const block={c:function create(){t=text(t_value)},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty&4&&t_value!==(t_value=ctx[2].remove_licence+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$c.name,type:"slot",source:"(84:4) <Button large outline on:click={handleRemoveLicence}>",ctx:ctx});return block}function create_default_slot$f(ctx){let notifications;let t0;let h2;let t1_value=ctx[2].licence_title+"";let t1;let t2;let div;let current_block_type_index;let if_block;let current;notifications=new Notifications({props:{tab:ctx[0]},$$inline:true});const if_block_creators=[create_if_block$a,create_else_block_1$3];const if_blocks=[];function select_block_type(ctx,dirty){if(ctx[3].is_set)return 0;return 1}current_block_type_index=select_block_type(ctx);if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);const block={c:function create(){create_component(notifications.$$.fragment);t0=space();h2=element("h2");t1=text(t1_value);t2=space();div=element("div");if_block.c();attr_dev(h2,"class","page-title");add_location(h2,file$l,67,1,1626);attr_dev(div,"class","licence-page wrapper");toggle_class(div,"defined",ctx[3].is_set&&ctx[3].is_defined);add_location(div,file$l,69,1,1681)},m:function mount(target,anchor){mount_component(notifications,target,anchor);insert_dev(target,t0,anchor);insert_dev(target,h2,anchor);append_dev(h2,t1);insert_dev(target,t2,anchor);insert_dev(target,div,anchor);if_blocks[current_block_type_index].m(div,null);current=true},p:function update(ctx,dirty){const notifications_changes={};if(dirty&1)notifications_changes.tab=ctx[0];notifications.$set(notifications_changes);if((!current||dirty&4)&&t1_value!==(t1_value=ctx[2].licence_title+""))set_data_dev(t1,t1_value);let previous_block_index=current_block_type_index;current_block_type_index=select_block_type(ctx);if(current_block_type_index===previous_block_index){if_blocks[current_block_type_index].p(ctx,dirty)}else{group_outros();transition_out(if_blocks[previous_block_index],1,1,(()=>{if_blocks[previous_block_index]=null}));check_outros();if_block=if_blocks[current_block_type_index];if(!if_block){if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);if_block.c()}else{if_block.p(ctx,dirty)}transition_in(if_block,1);if_block.m(div,null)}if(!current||dirty&8){toggle_class(div,"defined",ctx[3].is_set&&ctx[3].is_defined)}},i:function intro(local){if(current)return;transition_in(notifications.$$.fragment,local);transition_in(if_block);current=true},o:function outro(local){transition_out(notifications.$$.fragment,local);transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(h2);detach_dev(t2);detach_dev(div)}destroy_component(notifications,detaching);if_blocks[current_block_type_index].d()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$f.name,type:"slot",source:"(66:0) <Page {name} on:routeEvent>",ctx:ctx});return block}function create_fragment$n(ctx){let page;let current;page=new Page({props:{name:ctx[0],$$slots:{default:[create_default_slot$f]},$$scope:{ctx:ctx}},$$inline:true});page.$on("routeEvent",ctx[7]);const block={c:function create(){create_component(page.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(page,target,anchor);current=true},p:function update(ctx,[dirty]){const page_changes={};if(dirty&1)page_changes.name=ctx[0];if(dirty&1039){page_changes.$$scope={dirty:dirty,ctx:ctx}}page.$set(page_changes)},i:function intro(local){if(current)return;transition_in(page.$$.fragment,local);current=true},o:function outro(local){transition_out(page.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(page,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$n.name,type:"component",source:"",ctx:ctx});return block}function instance$n($$self,$$props,$$invalidate){let $strings;let $licence;validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(2,$strings=$$value)));validate_store(licence,"licence");component_subscribe($$self,licence,($$value=>$$invalidate(3,$licence=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("LicencePage",slots,[]);const dispatch=createEventDispatcher();let{name:name="licence"}=$$props;let value="";async function handleActivateLicence(event){const result=await api.post("licences",{licence:value});await updateLicenceInfo(result)}async function handleRemoveLicence(event){$$invalidate(1,value="");const result=await api.delete("licences");await updateLicenceInfo(result)}async function updateLicenceInfo(response){if(response.hasOwnProperty("licences")){config.update((currentConfig=>({...currentConfig,licences:response.licences})))}await settings.fetch()}const writable_props=["name"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<LicencePage> was created with unknown prop '${key}'`)}));function input_input_handler(){value=this.value;$$invalidate(1,value)}function routeEvent_handler(event){bubble.call(this,$$self,event)}$$self.$$set=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name)};$$self.$capture_state=()=>({createEventDispatcher:createEventDispatcher,api:api,config:config,settings:settings,strings:strings,autofocus:autofocus,licence:licence,Page:Page,Notifications:Notifications,Button:Button,DefinedInWPConfig:DefinedInWPConfig,dispatch:dispatch,name:name,value:value,handleActivateLicence:handleActivateLicence,handleRemoveLicence:handleRemoveLicence,updateLicenceInfo:updateLicenceInfo,$strings:$strings,$licence:$licence});$$self.$inject_state=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name);if("value"in $$props)$$invalidate(1,value=$$props.value)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[name,value,$strings,$licence,handleActivateLicence,handleRemoveLicence,input_input_handler,routeEvent_handler]}class LicencePage extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$n,create_fragment$n,safe_not_equal,{name:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"LicencePage",options:options,id:create_fragment$n.name})}get name(){throw new Error("<LicencePage>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set name(value){throw new Error("<LicencePage>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$k="ui/components/SupportPage.svelte";const get_footer_slot_changes$1=dirty=>({});const get_footer_slot_context$1=ctx=>({});const get_content_slot_changes=dirty=>({});const get_content_slot_context=ctx=>({});const get_header_slot_changes=dirty=>({});const get_header_slot_context=ctx=>({});function create_if_block$9(ctx){let h2;let t;const block={c:function create(){h2=element("h2");t=text(ctx[1]);attr_dev(h2,"class","page-title");add_location(h2,file$k,21,2,541)},m:function mount(target,anchor){insert_dev(target,h2,anchor);append_dev(h2,t)},p:function update(ctx,dirty){if(dirty&2)set_data_dev(t,ctx[1])},d:function destroy(detaching){if(detaching){detach_dev(h2)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$9.name,type:"if",source:"(21:1) {#if title}",ctx:ctx});return block}function fallback_block$3(ctx){let div;let p0;let raw0_value=ctx[2].no_support+"";let t0;let p1;let raw1_value=ctx[2].community_support+"";let t1;let p2;let raw2_value=ctx[2].upgrade_for_support+"";let t2;let p3;let raw3_value=ctx[2].report_a_bug+"";const block={c:function create(){div=element("div");p0=element("p");t0=space();p1=element("p");t1=space();p2=element("p");t2=space();p3=element("p");add_location(p0,file$k,31,6,764);add_location(p1,file$k,32,6,805);add_location(p2,file$k,33,6,853);add_location(p3,file$k,34,6,903);attr_dev(div,"class","lite-support");add_location(div,file$k,30,5,731)},m:function mount(target,anchor){insert_dev(target,div,anchor);append_dev(div,p0);p0.innerHTML=raw0_value;append_dev(div,t0);append_dev(div,p1);p1.innerHTML=raw1_value;append_dev(div,t1);append_dev(div,p2);p2.innerHTML=raw2_value;append_dev(div,t2);append_dev(div,p3);p3.innerHTML=raw3_value},p:function update(ctx,dirty){if(dirty&4&&raw0_value!==(raw0_value=ctx[2].no_support+""))p0.innerHTML=raw0_value;if(dirty&4&&raw1_value!==(raw1_value=ctx[2].community_support+""))p1.innerHTML=raw1_value;if(dirty&4&&raw2_value!==(raw2_value=ctx[2].upgrade_for_support+""))p2.innerHTML=raw2_value;if(dirty&4&&raw3_value!==(raw3_value=ctx[2].report_a_bug+""))p3.innerHTML=raw3_value},d:function destroy(detaching){if(detaching){detach_dev(div)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:fallback_block$3.name,type:"fallback",source:"(30:25) ",ctx:ctx});return block}function create_default_slot$e(ctx){let notifications;let t0;let t1;let div3;let t2;let div2;let div1;let t3;let div0;let hr;let t4;let h2;let t5_value=ctx[2].diagnostic_info_title+"";let t5;let t6;let pre;let t7;let t8;let a;let t9_value=ctx[2].download_diagnostics+"";let t9;let a_href_value;let t10;let current;notifications=new Notifications({props:{tab:ctx[0]},$$inline:true});let if_block=ctx[1]&&create_if_block$9(ctx);const header_slot_template=ctx[5].header;const header_slot=create_slot(header_slot_template,ctx,ctx[7],get_header_slot_context);const content_slot_template=ctx[5].content;const content_slot=create_slot(content_slot_template,ctx,ctx[7],get_content_slot_context);const content_slot_or_fallback=content_slot||fallback_block$3(ctx);const footer_slot_template=ctx[5].footer;const footer_slot=create_slot(footer_slot_template,ctx,ctx[7],get_footer_slot_context$1);const block={c:function create(){create_component(notifications.$$.fragment);t0=space();if(if_block)if_block.c();t1=space();div3=element("div");if(header_slot)header_slot.c();t2=space();div2=element("div");div1=element("div");if(content_slot_or_fallback)content_slot_or_fallback.c();t3=space();div0=element("div");hr=element("hr");t4=space();h2=element("h2");t5=text(t5_value);t6=space();pre=element("pre");t7=text(ctx[3]);t8=space();a=element("a");t9=text(t9_value);t10=space();if(footer_slot)footer_slot.c();add_location(hr,file$k,39,5,1004);attr_dev(h2,"class","page-title");add_location(h2,file$k,40,5,1014);add_location(pre,file$k,41,5,1080);attr_dev(a,"href",a_href_value=ctx[4].download_diagnostics);attr_dev(a,"class","button btn-md btn-outline");add_location(a,file$k,42,5,1111);attr_dev(div0,"class","diagnostic-info");add_location(div0,file$k,38,4,969);attr_dev(div1,"class","support-form");add_location(div1,file$k,28,3,673);attr_dev(div2,"class","columns");add_location(div2,file$k,27,2,648);attr_dev(div3,"class","support-page wrapper");add_location(div3,file$k,23,1,585)},m:function mount(target,anchor){mount_component(notifications,target,anchor);insert_dev(target,t0,anchor);if(if_block)if_block.m(target,anchor);insert_dev(target,t1,anchor);insert_dev(target,div3,anchor);if(header_slot){header_slot.m(div3,null)}append_dev(div3,t2);append_dev(div3,div2);append_dev(div2,div1);if(content_slot_or_fallback){content_slot_or_fallback.m(div1,null)}append_dev(div1,t3);append_dev(div1,div0);append_dev(div0,hr);append_dev(div0,t4);append_dev(div0,h2);append_dev(h2,t5);append_dev(div0,t6);append_dev(div0,pre);append_dev(pre,t7);append_dev(div0,t8);append_dev(div0,a);append_dev(a,t9);append_dev(div2,t10);if(footer_slot){footer_slot.m(div2,null)}current=true},p:function update(ctx,dirty){const notifications_changes={};if(dirty&1)notifications_changes.tab=ctx[0];notifications.$set(notifications_changes);if(ctx[1]){if(if_block){if_block.p(ctx,dirty)}else{if_block=create_if_block$9(ctx);if_block.c();if_block.m(t1.parentNode,t1)}}else if(if_block){if_block.d(1);if_block=null}if(header_slot){if(header_slot.p&&(!current||dirty&128)){update_slot_base(header_slot,header_slot_template,ctx,ctx[7],!current?get_all_dirty_from_scope(ctx[7]):get_slot_changes(header_slot_template,ctx[7],dirty,get_header_slot_changes),get_header_slot_context)}}if(content_slot){if(content_slot.p&&(!current||dirty&128)){update_slot_base(content_slot,content_slot_template,ctx,ctx[7],!current?get_all_dirty_from_scope(ctx[7]):get_slot_changes(content_slot_template,ctx[7],dirty,get_content_slot_changes),get_content_slot_context)}}else{if(content_slot_or_fallback&&content_slot_or_fallback.p&&(!current||dirty&4)){content_slot_or_fallback.p(ctx,!current?-1:dirty)}}if((!current||dirty&4)&&t5_value!==(t5_value=ctx[2].diagnostic_info_title+""))set_data_dev(t5,t5_value);if(!current||dirty&8)set_data_dev(t7,ctx[3]);if((!current||dirty&4)&&t9_value!==(t9_value=ctx[2].download_diagnostics+""))set_data_dev(t9,t9_value);if(!current||dirty&16&&a_href_value!==(a_href_value=ctx[4].download_diagnostics)){attr_dev(a,"href",a_href_value)}if(footer_slot){if(footer_slot.p&&(!current||dirty&128)){update_slot_base(footer_slot,footer_slot_template,ctx,ctx[7],!current?get_all_dirty_from_scope(ctx[7]):get_slot_changes(footer_slot_template,ctx[7],dirty,get_footer_slot_changes$1),get_footer_slot_context$1)}}},i:function intro(local){if(current)return;transition_in(notifications.$$.fragment,local);transition_in(header_slot,local);transition_in(content_slot_or_fallback,local);transition_in(footer_slot,local);current=true},o:function outro(local){transition_out(notifications.$$.fragment,local);transition_out(header_slot,local);transition_out(content_slot_or_fallback,local);transition_out(footer_slot,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(t1);detach_dev(div3)}destroy_component(notifications,detaching);if(if_block)if_block.d(detaching);if(header_slot)header_slot.d(detaching);if(content_slot_or_fallback)content_slot_or_fallback.d(detaching);if(footer_slot)footer_slot.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$e.name,type:"slot",source:"(19:0) <Page {name} on:routeEvent>",ctx:ctx});return block}function create_fragment$m(ctx){let page;let current;page=new Page({props:{name:ctx[0],$$slots:{default:[create_default_slot$e]},$$scope:{ctx:ctx}},$$inline:true});page.$on("routeEvent",ctx[6]);const block={c:function create(){create_component(page.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(page,target,anchor);current=true},p:function update(ctx,[dirty]){const page_changes={};if(dirty&1)page_changes.name=ctx[0];if(dirty&159){page_changes.$$scope={dirty:dirty,ctx:ctx}}page.$set(page_changes)},i:function intro(local){if(current)return;transition_in(page.$$.fragment,local);current=true},o:function outro(local){transition_out(page.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(page,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$m.name,type:"component",source:"",ctx:ctx});return block}function instance$m($$self,$$props,$$invalidate){let $config;let $strings;let $diagnostics;let $urls;validate_store(config,"config");component_subscribe($$self,config,($$value=>$$invalidate(8,$config=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(2,$strings=$$value)));validate_store(diagnostics,"diagnostics");component_subscribe($$self,diagnostics,($$value=>$$invalidate(3,$diagnostics=$$value)));validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(4,$urls=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("SupportPage",slots,["header","content","footer"]);let{name:name="support"}=$$props;let{title:title=$strings.support_tab_title}=$$props;onMount((async()=>{const json=await api.get("diagnostics",{});if(json.hasOwnProperty("diagnostics")){set_store_value(config,$config.diagnostics=json.diagnostics,$config)}}));const writable_props=["name","title"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<SupportPage> was created with unknown prop '${key}'`)}));function routeEvent_handler(event){bubble.call(this,$$self,event)}$$self.$$set=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name);if("title"in $$props)$$invalidate(1,title=$$props.title);if("$$scope"in $$props)$$invalidate(7,$$scope=$$props.$$scope)};$$self.$capture_state=()=>({onMount:onMount,api:api,config:config,diagnostics:diagnostics,strings:strings,urls:urls,Page:Page,Notifications:Notifications,name:name,title:title,$config:$config,$strings:$strings,$diagnostics:$diagnostics,$urls:$urls});$$self.$inject_state=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name);if("title"in $$props)$$invalidate(1,title=$$props.title)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[name,title,$strings,$diagnostics,$urls,slots,routeEvent_handler,$$scope]}class SupportPage extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$m,create_fragment$m,safe_not_equal,{name:0,title:1});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"SupportPage",options:options,id:create_fragment$m.name})}get name(){throw new Error("<SupportPage>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set name(value){throw new Error("<SupportPage>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get title(){throw new Error("<SupportPage>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set title(value){throw new Error("<SupportPage>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$j="ui/pro/DocumentationSidebar.svelte";function get_each_context$3(ctx,list,i){const child_ctx=ctx.slice();child_ctx[2]=list[i];return child_ctx}function create_if_block$8(ctx){let div;let h3;let t0_value=ctx[1].documentation_title+"";let t0;let t1;let each_value=ensure_array_like_dev(ctx[0]);let each_blocks=[];for(let i=0;i<each_value.length;i+=1){each_blocks[i]=create_each_block$3(get_each_context$3(ctx,each_value,i))}const block={c:function create(){div=element("div");h3=element("h3");t0=text(t0_value);t1=space();for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].c()}add_location(h3,file$j,7,2,159);attr_dev(div,"class","documentation");add_location(div,file$j,6,1,129)},m:function mount(target,anchor){insert_dev(target,div,anchor);append_dev(div,h3);append_dev(h3,t0);append_dev(div,t1);for(let i=0;i<each_blocks.length;i+=1){if(each_blocks[i]){each_blocks[i].m(div,null)}}},p:function update(ctx,dirty){if(dirty&2&&t0_value!==(t0_value=ctx[1].documentation_title+""))set_data_dev(t0,t0_value);if(dirty&1){each_value=ensure_array_like_dev(ctx[0]);let i;for(i=0;i<each_value.length;i+=1){const child_ctx=get_each_context$3(ctx,each_value,i);if(each_blocks[i]){each_blocks[i].p(child_ctx,dirty)}else{each_blocks[i]=create_each_block$3(child_ctx);each_blocks[i].c();each_blocks[i].m(div,null)}}for(;i<each_blocks.length;i+=1){each_blocks[i].d(1)}each_blocks.length=each_value.length}},d:function destroy(detaching){if(detaching){detach_dev(div)}destroy_each(each_blocks,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$8.name,type:"if",source:"(6:0) {#if $documentation.length}",ctx:ctx});return block}function create_each_block$3(ctx){let a;let t_value=ctx[2].title+"";let t;let a_href_value;const block={c:function create(){a=element("a");t=text(t_value);attr_dev(a,"href",a_href_value=ctx[2].url);attr_dev(a,"class","link");attr_dev(a,"target","_blank");add_location(a,file$j,9,3,235)},m:function mount(target,anchor){insert_dev(target,a,anchor);append_dev(a,t)},p:function update(ctx,dirty){if(dirty&1&&t_value!==(t_value=ctx[2].title+""))set_data_dev(t,t_value);if(dirty&1&&a_href_value!==(a_href_value=ctx[2].url)){attr_dev(a,"href",a_href_value)}},d:function destroy(detaching){if(detaching){detach_dev(a)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_each_block$3.name,type:"each",source:"(9:2) {#each $documentation as item}",ctx:ctx});return block}function create_fragment$l(ctx){let if_block_anchor;let if_block=ctx[0].length&&create_if_block$8(ctx);const block={c:function create(){if(if_block)if_block.c();if_block_anchor=empty()},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor)},p:function update(ctx,[dirty]){if(ctx[0].length){if(if_block){if_block.p(ctx,dirty)}else{if_block=create_if_block$8(ctx);if_block.c();if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){if_block.d(1);if_block=null}},i:noop,o:noop,d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$l.name,type:"component",source:"",ctx:ctx});return block}function instance$l($$self,$$props,$$invalidate){let $documentation;let $strings;validate_store(documentation,"documentation");component_subscribe($$self,documentation,($$value=>$$invalidate(0,$documentation=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(1,$strings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("DocumentationSidebar",slots,[]);const writable_props=[];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<DocumentationSidebar> was created with unknown prop '${key}'`)}));$$self.$capture_state=()=>({strings:strings,documentation:documentation,$documentation:$documentation,$strings:$strings});return[$documentation,$strings]}class DocumentationSidebar extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$l,create_fragment$l,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"DocumentationSidebar",options:options,id:create_fragment$l.name})}}const{Object:Object_1$2}=globals;const file$i="ui/pro/SupportForm.svelte";function get_each_context$2(ctx,list,i){const child_ctx=ctx.slice();child_ctx[13]=list[i];return child_ctx}function create_each_block$2(ctx){let option;let t_value=ctx[13]+"";let t;let option_value_value;const block={c:function create(){option=element("option");t=text(t_value);option.__value=option_value_value=ctx[13];set_input_value(option,option.__value);add_location(option,file$i,122,2,2692)},m:function mount(target,anchor){insert_dev(target,option,anchor);append_dev(option,t)},p:function update(ctx,dirty){if(dirty&64&&t_value!==(t_value=ctx[13]+""))set_data_dev(t,t_value);if(dirty&64&&option_value_value!==(option_value_value=ctx[13])){prop_dev(option,"__value",option_value_value);set_input_value(option,option.__value)}},d:function destroy(detaching){if(detaching){detach_dev(option)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_each_block$2.name,type:"each",source:"(122:1) {#each $licence.support_email_addresses as supportEmail}",ctx:ctx});return block}function create_default_slot$d(ctx){let t_value=ctx[5].send_email+"";let t;const block={c:function create(){t=text(t_value)},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty&32&&t_value!==(t_value=ctx[5].send_email+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$d.name,type:"slot",source:"(136:1) <Button primary on:click={submitSupportRequest} disabled={disabledReason} title={disabledReason}>",ctx:ctx});return block}function create_fragment$k(ctx){let label0;let t1;let select;let option;let t2_value=ctx[5].select_email+"";let t2;let t3;let p0;let raw0_value=ctx[5].email_note+"";let t4;let input0;let input0_placeholder_value;let t5;let textarea;let textarea_placeholder_value;let t6;let div1;let div0;let label1;let input1;let t7_value=ctx[5].attach_diagnostics+"";let t7;let t8;let button;let t9;let p1;let t10_value=ctx[5].having_trouble+"";let t10;let t11;let p2;let raw1_value=ctx[5].email_instead+"";let current;let mounted;let dispose;let each_value=ensure_array_like_dev(ctx[6].support_email_addresses);let each_blocks=[];for(let i=0;i<each_value.length;i+=1){each_blocks[i]=create_each_block$2(get_each_context$2(ctx,each_value,i))}button=new Button({props:{primary:true,disabled:ctx[4],title:ctx[4],$$slots:{default:[create_default_slot$d]},$$scope:{ctx:ctx}},$$inline:true});button.$on("click",ctx[7]);const block={c:function create(){label0=element("label");label0.textContent="From";t1=space();select=element("select");for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].c()}option=element("option");t2=text(t2_value);t3=space();p0=element("p");t4=space();input0=element("input");t5=space();textarea=element("textarea");t6=space();div1=element("div");div0=element("div");label1=element("label");input1=element("input");t7=text(t7_value);t8=space();create_component(button.$$.fragment);t9=space();p1=element("p");t10=text(t10_value);t11=space();p2=element("p");attr_dev(label0,"for","email");attr_dev(label0,"class","input-label");add_location(label0,file$i,119,0,2528);option.__value="";set_input_value(option,option.__value);add_location(option,file$i,124,1,2755);attr_dev(select,"name","email");attr_dev(select,"id","email");if(ctx[0]===void 0)add_render_callback((()=>ctx[8].call(select)));add_location(select,file$i,120,0,2580);attr_dev(p0,"class","note");add_location(p0,file$i,126,0,2815);attr_dev(input0,"type","text");attr_dev(input0,"id","subject");attr_dev(input0,"name","subject");attr_dev(input0,"minlength","4");attr_dev(input0,"placeholder",input0_placeholder_value=ctx[5].email_subject_placeholder);add_location(input0,file$i,127,0,2863);attr_dev(textarea,"id","message");attr_dev(textarea,"name","message");attr_dev(textarea,"rows","8");attr_dev(textarea,"placeholder",textarea_placeholder_value=ctx[5].email_message_placeholder);add_location(textarea,file$i,128,0,2995);attr_dev(input1,"type","checkbox");attr_dev(input1,"id","include-diagnostics");attr_dev(input1,"name","include-diagnostics");add_location(input1,file$i,132,3,3209);attr_dev(label1,"for","include-diagnostics");add_location(label1,file$i,131,2,3172);attr_dev(div0,"class","checkbox");add_location(div0,file$i,130,1,3147);attr_dev(div1,"class","actions");add_location(div1,file$i,129,0,3124);attr_dev(p1,"class","note first");add_location(p1,file$i,137,0,3503);attr_dev(p2,"class","note");add_location(p2,file$i,138,0,3555)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,label0,anchor);insert_dev(target,t1,anchor);insert_dev(target,select,anchor);for(let i=0;i<each_blocks.length;i+=1){if(each_blocks[i]){each_blocks[i].m(select,null)}}append_dev(select,option);append_dev(option,t2);select_option(select,ctx[0],true);insert_dev(target,t3,anchor);insert_dev(target,p0,anchor);p0.innerHTML=raw0_value;insert_dev(target,t4,anchor);insert_dev(target,input0,anchor);set_input_value(input0,ctx[1]);insert_dev(target,t5,anchor);insert_dev(target,textarea,anchor);set_input_value(textarea,ctx[2]);insert_dev(target,t6,anchor);insert_dev(target,div1,anchor);append_dev(div1,div0);append_dev(div0,label1);append_dev(label1,input1);input1.checked=ctx[3];append_dev(label1,t7);append_dev(div1,t8);mount_component(button,div1,null);insert_dev(target,t9,anchor);insert_dev(target,p1,anchor);append_dev(p1,t10);insert_dev(target,t11,anchor);insert_dev(target,p2,anchor);p2.innerHTML=raw1_value;current=true;if(!mounted){dispose=[listen_dev(select,"change",ctx[8]),listen_dev(input0,"input",ctx[9]),listen_dev(textarea,"input",ctx[10]),listen_dev(input1,"change",ctx[11])];mounted=true}},p:function update(ctx,[dirty]){if(dirty&64){each_value=ensure_array_like_dev(ctx[6].support_email_addresses);let i;for(i=0;i<each_value.length;i+=1){const child_ctx=get_each_context$2(ctx,each_value,i);if(each_blocks[i]){each_blocks[i].p(child_ctx,dirty)}else{each_blocks[i]=create_each_block$2(child_ctx);each_blocks[i].c();each_blocks[i].m(select,option)}}for(;i<each_blocks.length;i+=1){each_blocks[i].d(1)}each_blocks.length=each_value.length}if((!current||dirty&32)&&t2_value!==(t2_value=ctx[5].select_email+""))set_data_dev(t2,t2_value);if(dirty&65){select_option(select,ctx[0])}if((!current||dirty&32)&&raw0_value!==(raw0_value=ctx[5].email_note+""))p0.innerHTML=raw0_value;if(!current||dirty&32&&input0_placeholder_value!==(input0_placeholder_value=ctx[5].email_subject_placeholder)){attr_dev(input0,"placeholder",input0_placeholder_value)}if(dirty&2&&input0.value!==ctx[1]){set_input_value(input0,ctx[1])}if(!current||dirty&32&&textarea_placeholder_value!==(textarea_placeholder_value=ctx[5].email_message_placeholder)){attr_dev(textarea,"placeholder",textarea_placeholder_value)}if(dirty&4){set_input_value(textarea,ctx[2])}if(dirty&8){input1.checked=ctx[3]}if((!current||dirty&32)&&t7_value!==(t7_value=ctx[5].attach_diagnostics+""))set_data_dev(t7,t7_value);const button_changes={};if(dirty&16)button_changes.disabled=ctx[4];if(dirty&16)button_changes.title=ctx[4];if(dirty&65568){button_changes.$$scope={dirty:dirty,ctx:ctx}}button.$set(button_changes);if((!current||dirty&32)&&t10_value!==(t10_value=ctx[5].having_trouble+""))set_data_dev(t10,t10_value);if((!current||dirty&32)&&raw1_value!==(raw1_value=ctx[5].email_instead+""))p2.innerHTML=raw1_value},i:function intro(local){if(current)return;transition_in(button.$$.fragment,local);current=true},o:function outro(local){transition_out(button.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(label0);detach_dev(t1);detach_dev(select);detach_dev(t3);detach_dev(p0);detach_dev(t4);detach_dev(input0);detach_dev(t5);detach_dev(textarea);detach_dev(t6);detach_dev(div1);detach_dev(t9);detach_dev(p1);detach_dev(t11);detach_dev(p2)}destroy_each(each_blocks,detaching);destroy_component(button);mounted=false;run_all(dispose)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$k.name,type:"component",source:"",ctx:ctx});return block}function getDisabledReason(email,subject,message){let reason="";if(!email||!subject||!message){reason="Email, Subject and Message required."}return reason}function instance$k($$self,$$props,$$invalidate){let disabledReason;let $strings;let $licence;let $diagnostics;validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(5,$strings=$$value)));validate_store(licence,"licence");component_subscribe($$self,licence,($$value=>$$invalidate(6,$licence=$$value)));validate_store(diagnostics,"diagnostics");component_subscribe($$self,diagnostics,($$value=>$$invalidate(12,$diagnostics=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("SupportForm",slots,[]);let email="";let subject="";let message="";let includeDiagnostics=true;async function submitSupportRequest(event){const formData=new FormData;formData.append("email",email);formData.append("subject",subject);formData.append("message",message);if(includeDiagnostics){formData.append("local-diagnostic","1");formData.append("local-diagnostic-content",$diagnostics)}let response;try{response=await fetch($licence.support_url,{method:"POST",body:formData})}catch(error){const notice=$strings.send_email_post_error+error.message;notifications.add({id:"support-send-email-response",type:"error",dismissible:true,only_show_on_tab:"support",message:notice});return}const json=await response.json();if(json.hasOwnProperty("errors")){for(const[key,value]of Object.entries(json.errors)){const notice=$strings.send_email_api_error+value;notifications.add({id:"support-send-email-response",type:"error",dismissible:true,only_show_on_tab:"support",message:notice})}return}if(json.hasOwnProperty("success")&&json.success===1){notifications.add({id:"support-send-email-response",type:"success",dismissible:true,only_show_on_tab:"support",message:$strings.send_email_success});$$invalidate(0,email="");$$invalidate(1,subject="");$$invalidate(2,message="");$$invalidate(3,includeDiagnostics=true);return}notifications.add({id:"support-send-email-response",type:"error",dismissible:true,only_show_on_tab:"support",message:$strings.send_email_unexpected_error})}const writable_props=[];Object_1$2.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<SupportForm> was created with unknown prop '${key}'`)}));function select_change_handler(){email=select_value(this);$$invalidate(0,email)}function input0_input_handler(){subject=this.value;$$invalidate(1,subject)}function textarea_input_handler(){message=this.value;$$invalidate(2,message)}function input1_change_handler(){includeDiagnostics=this.checked;$$invalidate(3,includeDiagnostics)}$$self.$capture_state=()=>({diagnostics:diagnostics,notifications:notifications,strings:strings,licence:licence,Button:Button,email:email,subject:subject,message:message,includeDiagnostics:includeDiagnostics,getDisabledReason:getDisabledReason,submitSupportRequest:submitSupportRequest,disabledReason:disabledReason,$strings:$strings,$licence:$licence,$diagnostics:$diagnostics});$$self.$inject_state=$$props=>{if("email"in $$props)$$invalidate(0,email=$$props.email);if("subject"in $$props)$$invalidate(1,subject=$$props.subject);if("message"in $$props)$$invalidate(2,message=$$props.message);if("includeDiagnostics"in $$props)$$invalidate(3,includeDiagnostics=$$props.includeDiagnostics);if("disabledReason"in $$props)$$invalidate(4,disabledReason=$$props.disabledReason)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty&7){$$invalidate(4,disabledReason=getDisabledReason(email,subject,message))}};return[email,subject,message,includeDiagnostics,disabledReason,$strings,$licence,submitSupportRequest,select_change_handler,input0_input_handler,textarea_input_handler,input1_change_handler]}class SupportForm extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$k,create_fragment$k,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"SupportForm",options:options,id:create_fragment$k.name})}}const{Object:Object_1$1}=globals;const file$h="ui/pro/SupportPage.svelte";function create_else_block_1$2(ctx){let supportpage;let current;supportpage=new SupportPage({props:{name:ctx[0],title:ctx[3].email_support_title,$$slots:{footer:[create_footer_slot_2],content:[create_content_slot_2]},$$scope:{ctx:ctx}},$$inline:true});supportpage.$on("routeEvent",ctx[6]);const block={c:function create(){create_component(supportpage.$$.fragment)},m:function mount(target,anchor){mount_component(supportpage,target,anchor);current=true},p:function update(ctx,dirty){const supportpage_changes={};if(dirty&1)supportpage_changes.name=ctx[0];if(dirty&8)supportpage_changes.title=ctx[3].email_support_title;if(dirty&136){supportpage_changes.$$scope={dirty:dirty,ctx:ctx}}supportpage.$set(supportpage_changes)},i:function intro(local){if(current)return;transition_in(supportpage.$$.fragment,local);current=true},o:function outro(local){transition_out(supportpage.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(supportpage,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block_1$2.name,type:"else",source:"(58:0) {:else}",ctx:ctx});return block}function create_if_block$7(ctx){let current_block_type_index;let if_block;let if_block_anchor;let current;const if_block_creators=[create_if_block_1$4,create_else_block$3];const if_blocks=[];function select_block_type_1(ctx,dirty){if(ctx[1].is_valid&&ctx[2].length===0)return 0;return 1}current_block_type_index=select_block_type_1(ctx);if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);const block={c:function create(){if_block.c();if_block_anchor=empty()},m:function mount(target,anchor){if_blocks[current_block_type_index].m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,dirty){let previous_block_index=current_block_type_index;current_block_type_index=select_block_type_1(ctx);if(current_block_type_index===previous_block_index){if_blocks[current_block_type_index].p(ctx,dirty)}else{group_outros();transition_out(if_blocks[previous_block_index],1,1,(()=>{if_blocks[previous_block_index]=null}));check_outros();if_block=if_blocks[current_block_type_index];if(!if_block){if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);if_block.c()}else{if_block.p(ctx,dirty)}transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if_blocks[current_block_type_index].d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$7.name,type:"if",source:"(31:0) {#if $licence.is_set}",ctx:ctx});return block}function create_default_slot_1$b(ctx){let p0;let t0_value=ctx[3].licence_not_entered+"";let t0;let t1;let a;let t2_value=ctx[3].please_enter_licence+"";let t2;let t3;let p1;let t4_value=ctx[3].once_licence_entered+"";let t4;let mounted;let dispose;const block={c:function create(){p0=element("p");t0=text(t0_value);t1=space();a=element("a");t2=text(t2_value);t3=space();p1=element("p");t4=text(t4_value);attr_dev(a,"href","/license");add_location(a,file$h,63,5,1866);add_location(p0,file$h,61,4,1821);add_location(p1,file$h,67,4,1956)},m:function mount(target,anchor){insert_dev(target,p0,anchor);append_dev(p0,t0);append_dev(p0,t1);append_dev(p0,a);append_dev(a,t2);insert_dev(target,t3,anchor);insert_dev(target,p1,anchor);append_dev(p1,t4);if(!mounted){dispose=action_destroyer(link.call(null,a));mounted=true}},p:function update(ctx,dirty){if(dirty&8&&t0_value!==(t0_value=ctx[3].licence_not_entered+""))set_data_dev(t0,t0_value);if(dirty&8&&t2_value!==(t2_value=ctx[3].please_enter_licence+""))set_data_dev(t2,t2_value);if(dirty&8&&t4_value!==(t4_value=ctx[3].once_licence_entered+""))set_data_dev(t4,t4_value)},d:function destroy(detaching){if(detaching){detach_dev(p0);detach_dev(t3);detach_dev(p1)}mounted=false;dispose()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$b.name,type:"slot",source:"(61:3) <Notification warning inline>",ctx:ctx});return block}function create_content_slot_2(ctx){let notification;let current;notification=new Notification({props:{warning:true,inline:true,$$slots:{default:[create_default_slot_1$b]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(notification.$$.fragment)},m:function mount(target,anchor){mount_component(notification,target,anchor);current=true},p:function update(ctx,dirty){const notification_changes={};if(dirty&136){notification_changes.$$scope={dirty:dirty,ctx:ctx}}notification.$set(notification_changes)},i:function intro(local){if(current)return;transition_in(notification.$$.fragment,local);current=true},o:function outro(local){transition_out(notification.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(notification,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_content_slot_2.name,type:"slot",source:'(60:2) <svelte:fragment slot=\\"content\\">',ctx:ctx});return block}function create_footer_slot_2(ctx){let documentationsidebar;let current;documentationsidebar=new DocumentationSidebar({$$inline:true});const block={c:function create(){create_component(documentationsidebar.$$.fragment)},m:function mount(target,anchor){mount_component(documentationsidebar,target,anchor);current=true},i:function intro(local){if(current)return;transition_in(documentationsidebar.$$.fragment,local);current=true},o:function outro(local){transition_out(documentationsidebar.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(documentationsidebar,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_footer_slot_2.name,type:"slot",source:'(72:2) <svelte:fragment slot=\\"footer\\">',ctx:ctx});return block}function create_else_block$3(ctx){let supportpage;let current;supportpage=new SupportPage({props:{name:ctx[0],title:ctx[3].email_support_title,$$slots:{footer:[create_footer_slot_1],content:[create_content_slot_1]},$$scope:{ctx:ctx}},$$inline:true});supportpage.$on("routeEvent",ctx[5]);const block={c:function create(){create_component(supportpage.$$.fragment)},m:function mount(target,anchor){mount_component(supportpage,target,anchor);current=true},p:function update(ctx,dirty){const supportpage_changes={};if(dirty&1)supportpage_changes.name=ctx[0];if(dirty&8)supportpage_changes.title=ctx[3].email_support_title;if(dirty&132){supportpage_changes.$$scope={dirty:dirty,ctx:ctx}}supportpage.$set(supportpage_changes)},i:function intro(local){if(current)return;transition_in(supportpage.$$.fragment,local);current=true},o:function outro(local){transition_out(supportpage.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(supportpage,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block$3.name,type:"else",source:"(43:1) {:else}",ctx:ctx});return block}function create_if_block_1$4(ctx){let supportpage;let current;supportpage=new SupportPage({props:{name:ctx[0],title:ctx[3].email_support_title,$$slots:{footer:[create_footer_slot$1],content:[create_content_slot],header:[create_header_slot]},$$scope:{ctx:ctx}},$$inline:true});supportpage.$on("routeEvent",ctx[4]);const block={c:function create(){create_component(supportpage.$$.fragment)},m:function mount(target,anchor){mount_component(supportpage,target,anchor);current=true},p:function update(ctx,dirty){const supportpage_changes={};if(dirty&1)supportpage_changes.name=ctx[0];if(dirty&8)supportpage_changes.title=ctx[3].email_support_title;if(dirty&130){supportpage_changes.$$scope={dirty:dirty,ctx:ctx}}supportpage.$set(supportpage_changes)},i:function intro(local){if(current)return;transition_in(supportpage.$$.fragment,local);current=true},o:function outro(local){transition_out(supportpage.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(supportpage,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_1$4.name,type:"if",source:"(32:1) {#if $licence.is_valid && licenceError.length === 0}",ctx:ctx});return block}function create_default_slot$c(ctx){let p;const block={c:function create(){p=element("p");add_location(p,file$h,46,5,1475)},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=ctx[2]},p:function update(ctx,dirty){if(dirty&4)p.innerHTML=ctx[2]},d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$c.name,type:"slot",source:"(46:4) <Notification warning inline>",ctx:ctx});return block}function create_content_slot_1(ctx){let notification;let current;notification=new Notification({props:{warning:true,inline:true,$$slots:{default:[create_default_slot$c]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(notification.$$.fragment)},m:function mount(target,anchor){mount_component(notification,target,anchor);current=true},p:function update(ctx,dirty){const notification_changes={};if(dirty&132){notification_changes.$$scope={dirty:dirty,ctx:ctx}}notification.$set(notification_changes)},i:function intro(local){if(current)return;transition_in(notification.$$.fragment,local);current=true},o:function outro(local){transition_out(notification.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(notification,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_content_slot_1.name,type:"slot",source:'(45:3) <svelte:fragment slot=\\"content\\">',ctx:ctx});return block}function create_footer_slot_1(ctx){let documentationsidebar;let current;documentationsidebar=new DocumentationSidebar({$$inline:true});const block={c:function create(){create_component(documentationsidebar.$$.fragment)},m:function mount(target,anchor){mount_component(documentationsidebar,target,anchor);current=true},i:function intro(local){if(current)return;transition_in(documentationsidebar.$$.fragment,local);current=true},o:function outro(local){transition_out(documentationsidebar.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(documentationsidebar,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_footer_slot_1.name,type:"slot",source:'(53:3) <svelte:fragment slot=\\"footer\\">',ctx:ctx});return block}function create_header_slot(ctx){let p;let raw_value=ctx[1].your_active_licence+"";const block={c:function create(){p=element("p");attr_dev(p,"class","licence-type");attr_dev(p,"slot","header");add_location(p,file$h,33,3,1058)},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=raw_value},p:function update(ctx,dirty){if(dirty&2&&raw_value!==(raw_value=ctx[1].your_active_licence+""))p.innerHTML=raw_value},d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_header_slot.name,type:"slot",source:"(34:3) ",ctx:ctx});return block}function create_content_slot(ctx){let supportform;let current;supportform=new SupportForm({$$inline:true});const block={c:function create(){create_component(supportform.$$.fragment)},m:function mount(target,anchor){mount_component(supportform,target,anchor);current=true},i:function intro(local){if(current)return;transition_in(supportform.$$.fragment,local);current=true},o:function outro(local){transition_out(supportform.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(supportform,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_content_slot.name,type:"slot",source:'(35:3) <svelte:fragment slot=\\"content\\">',ctx:ctx});return block}function create_footer_slot$1(ctx){let documentationsidebar;let current;documentationsidebar=new DocumentationSidebar({$$inline:true});const block={c:function create(){create_component(documentationsidebar.$$.fragment)},m:function mount(target,anchor){mount_component(documentationsidebar,target,anchor);current=true},i:function intro(local){if(current)return;transition_in(documentationsidebar.$$.fragment,local);current=true},o:function outro(local){transition_out(documentationsidebar.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(documentationsidebar,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_footer_slot$1.name,type:"slot",source:'(39:3) <svelte:fragment slot=\\"footer\\">',ctx:ctx});return block}function create_fragment$j(ctx){let current_block_type_index;let if_block;let if_block_anchor;let current;const if_block_creators=[create_if_block$7,create_else_block_1$2];const if_blocks=[];function select_block_type(ctx,dirty){if(ctx[1].is_set)return 0;return 1}current_block_type_index=select_block_type(ctx);if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);const block={c:function create(){if_block.c();if_block_anchor=empty()},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){if_blocks[current_block_type_index].m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,[dirty]){let previous_block_index=current_block_type_index;current_block_type_index=select_block_type(ctx);if(current_block_type_index===previous_block_index){if_blocks[current_block_type_index].p(ctx,dirty)}else{group_outros();transition_out(if_blocks[previous_block_index],1,1,(()=>{if_blocks[previous_block_index]=null}));check_outros();if_block=if_blocks[current_block_type_index];if(!if_block){if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);if_block.c()}else{if_block.p(ctx,dirty)}transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if_blocks[current_block_type_index].d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$j.name,type:"component",source:"",ctx:ctx});return block}function getLicenceError(licence){if(licence.hasOwnProperty("errors")&&Object.values(licence.errors).length>0){return Object.values(licence.errors)[0]}return""}function instance$j($$self,$$props,$$invalidate){let licenceError;let $licence;let $strings;validate_store(licence,"licence");component_subscribe($$self,licence,($$value=>$$invalidate(1,$licence=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(3,$strings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("SupportPage",slots,[]);let{name:name="support"}=$$props;const writable_props=["name"];Object_1$1.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<SupportPage> was created with unknown prop '${key}'`)}));function routeEvent_handler(event){bubble.call(this,$$self,event)}function routeEvent_handler_1(event){bubble.call(this,$$self,event)}function routeEvent_handler_2(event){bubble.call(this,$$self,event)}$$self.$$set=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name)};$$self.$capture_state=()=>({link:link,strings:strings,licence:licence,SupportPage:SupportPage,DocumentationSidebar:DocumentationSidebar,SupportForm:SupportForm,Notification:Notification,name:name,getLicenceError:getLicenceError,licenceError:licenceError,$licence:$licence,$strings:$strings});$$self.$inject_state=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name);if("licenceError"in $$props)$$invalidate(2,licenceError=$$props.licenceError)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty&2){$$invalidate(2,licenceError=getLicenceError($licence))}};return[name,$licence,licenceError,$strings,routeEvent_handler,routeEvent_handler_1,routeEvent_handler_2]}class SupportPage_1 extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$j,create_fragment$j,safe_not_equal,{name:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"SupportPage_1",options:options,id:create_fragment$j.name})}get name(){throw new Error("<SupportPage>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set name(value){throw new Error("<SupportPage>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$g="ui/pro/UpdateObjectACLsPromptSubPage.svelte";function create_default_slot_2$9(ctx){let p;let raw_value=ctx[3].prompt+"";const block={c:function create(){p=element("p");add_location(p,file$g,49,3,1294)},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=raw_value},p:noop,d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_2$9.name,type:"slot",source:'(49:2) <PanelRow class=\\"body flex-column\\">',ctx:ctx});return block}function create_default_slot_1$a(ctx){let panelrow;let current;panelrow=new PanelRow({props:{class:"body flex-column",$$slots:{default:[create_default_slot_2$9]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty&256){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$a.name,type:"slot",source:"(43:1) <Panel heading={tool.title} helpURL={tool.doc_url} helpDesc={tool.doc_desc} multi >",ctx:ctx});return block}function create_default_slot$b(ctx){let panel;let t;let backnextbuttonsrow;let current;panel=new Panel({props:{heading:ctx[3].title,helpURL:ctx[3].doc_url,helpDesc:ctx[3].doc_desc,multi:true,$$slots:{default:[create_default_slot_1$a]},$$scope:{ctx:ctx}},$$inline:true});backnextbuttonsrow=new BackNextButtonsRow({props:{skipText:ctx[1].no,nextText:ctx[1].yes,skipVisible:true,nextDisabled:ctx[2]},$$inline:true});backnextbuttonsrow.$on("skip",ctx[4]);backnextbuttonsrow.$on("next",ctx[5]);const block={c:function create(){create_component(panel.$$.fragment);t=space();create_component(backnextbuttonsrow.$$.fragment)},m:function mount(target,anchor){mount_component(panel,target,anchor);insert_dev(target,t,anchor);mount_component(backnextbuttonsrow,target,anchor);current=true},p:function update(ctx,dirty){const panel_changes={};if(dirty&256){panel_changes.$$scope={dirty:dirty,ctx:ctx}}panel.$set(panel_changes);const backnextbuttonsrow_changes={};if(dirty&2)backnextbuttonsrow_changes.skipText=ctx[1].no;if(dirty&2)backnextbuttonsrow_changes.nextText=ctx[1].yes;if(dirty&4)backnextbuttonsrow_changes.nextDisabled=ctx[2];backnextbuttonsrow.$set(backnextbuttonsrow_changes)},i:function intro(local){if(current)return;transition_in(panel.$$.fragment,local);transition_in(backnextbuttonsrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panel.$$.fragment,local);transition_out(backnextbuttonsrow.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t)}destroy_component(panel,detaching);destroy_component(backnextbuttonsrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$b.name,type:"slot",source:'(42:0) <SubPage name=\\"update-acls\\" route=\\"/storage/update-acls\\">',ctx:ctx});return block}function create_fragment$i(ctx){let subpage;let current;subpage=new SubPage({props:{name:"update-acls",route:"/storage/update-acls",$$slots:{default:[create_default_slot$b]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(subpage.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(subpage,target,anchor);current=true},p:function update(ctx,[dirty]){const subpage_changes={};if(dirty&262){subpage_changes.$$scope={dirty:dirty,ctx:ctx}}subpage.$set(subpage_changes)},i:function intro(local){if(current)return;transition_in(subpage.$$.fragment,local);current=true},o:function outro(local){transition_out(subpage.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(subpage,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$i.name,type:"component",source:"",ctx:ctx});return block}function instance$i($$self,$$props,$$invalidate){let $tools;let $strings;let $settingsLocked,$$unsubscribe_settingsLocked=noop,$$subscribe_settingsLocked=()=>($$unsubscribe_settingsLocked(),$$unsubscribe_settingsLocked=subscribe(settingsLocked,($$value=>$$invalidate(2,$settingsLocked=$$value))),settingsLocked);validate_store(tools,"tools");component_subscribe($$self,tools,($$value=>$$invalidate(6,$tools=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(1,$strings=$$value)));$$self.$$.on_destroy.push((()=>$$unsubscribe_settingsLocked()));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("UpdateObjectACLsPromptSubPage",slots,[]);const tool=$tools.update_acls;const dispatch=createEventDispatcher();let settingsLocked=writable(false);validate_store(settingsLocked,"settingsLocked");$$subscribe_settingsLocked();if(hasContext("settingsLocked")){$$subscribe_settingsLocked(settingsLocked=getContext("settingsLocked"))}async function handleSkip(){dispatch("routeEvent",{event:"next",default:"/"})}async function handleNext(){await tools.start(tool);dispatch("routeEvent",{event:"next",default:"/"})}const writable_props=[];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<UpdateObjectACLsPromptSubPage> was created with unknown prop '${key}'`)}));$$self.$capture_state=()=>({createEventDispatcher:createEventDispatcher,getContext:getContext,hasContext:hasContext,writable:writable,pop:pop,strings:strings,tools:tools,SubPage:SubPage,Panel:Panel,PanelRow:PanelRow,BackNextButtonsRow:BackNextButtonsRow,tool:tool,dispatch:dispatch,settingsLocked:settingsLocked,handleSkip:handleSkip,handleNext:handleNext,$tools:$tools,$strings:$strings,$settingsLocked:$settingsLocked});$$self.$inject_state=$$props=>{if("settingsLocked"in $$props)$$subscribe_settingsLocked($$invalidate(0,settingsLocked=$$props.settingsLocked))};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[settingsLocked,$strings,$settingsLocked,tool,handleSkip,handleNext]}class UpdateObjectACLsPromptSubPage extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$i,create_fragment$i,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"UpdateObjectACLsPromptSubPage",options:options,id:create_fragment$i.name})}}const file$f="ui/pro/CopyBucketsPromptSubPage.svelte";function create_default_slot_2$8(ctx){let p;let raw_value=ctx[3].prompt+"";const block={c:function create(){p=element("p");add_location(p,file$f,49,3,1297)},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=raw_value},p:noop,d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_2$8.name,type:"slot",source:'(49:2) <PanelRow class=\\"body flex-column\\">',ctx:ctx});return block}function create_default_slot_1$9(ctx){let panelrow;let current;panelrow=new PanelRow({props:{class:"body flex-column",$$slots:{default:[create_default_slot_2$8]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty&256){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$9.name,type:"slot",source:"(43:1) <Panel heading={tool.title} helpURL={tool.doc_url} helpDesc={tool.doc_desc} multi >",ctx:ctx});return block}function create_default_slot$a(ctx){let panel;let t;let backnextbuttonsrow;let current;panel=new Panel({props:{heading:ctx[3].title,helpURL:ctx[3].doc_url,helpDesc:ctx[3].doc_desc,multi:true,$$slots:{default:[create_default_slot_1$9]},$$scope:{ctx:ctx}},$$inline:true});backnextbuttonsrow=new BackNextButtonsRow({props:{skipText:ctx[1].no,nextText:ctx[1].yes,skipVisible:true,nextDisabled:ctx[2]},$$inline:true});backnextbuttonsrow.$on("skip",ctx[4]);backnextbuttonsrow.$on("next",ctx[5]);const block={c:function create(){create_component(panel.$$.fragment);t=space();create_component(backnextbuttonsrow.$$.fragment)},m:function mount(target,anchor){mount_component(panel,target,anchor);insert_dev(target,t,anchor);mount_component(backnextbuttonsrow,target,anchor);current=true},p:function update(ctx,dirty){const panel_changes={};if(dirty&256){panel_changes.$$scope={dirty:dirty,ctx:ctx}}panel.$set(panel_changes);const backnextbuttonsrow_changes={};if(dirty&2)backnextbuttonsrow_changes.skipText=ctx[1].no;if(dirty&2)backnextbuttonsrow_changes.nextText=ctx[1].yes;if(dirty&4)backnextbuttonsrow_changes.nextDisabled=ctx[2];backnextbuttonsrow.$set(backnextbuttonsrow_changes)},i:function intro(local){if(current)return;transition_in(panel.$$.fragment,local);transition_in(backnextbuttonsrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panel.$$.fragment,local);transition_out(backnextbuttonsrow.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t)}destroy_component(panel,detaching);destroy_component(backnextbuttonsrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$a.name,type:"slot",source:'(42:0) <SubPage name=\\"copy-buckets\\" route=\\"/storage/copy-buckets\\">',ctx:ctx});return block}function create_fragment$h(ctx){let subpage;let current;subpage=new SubPage({props:{name:"copy-buckets",route:"/storage/copy-buckets",$$slots:{default:[create_default_slot$a]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(subpage.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(subpage,target,anchor);current=true},p:function update(ctx,[dirty]){const subpage_changes={};if(dirty&262){subpage_changes.$$scope={dirty:dirty,ctx:ctx}}subpage.$set(subpage_changes)},i:function intro(local){if(current)return;transition_in(subpage.$$.fragment,local);current=true},o:function outro(local){transition_out(subpage.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(subpage,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$h.name,type:"component",source:"",ctx:ctx});return block}function instance$h($$self,$$props,$$invalidate){let $tools;let $strings;let $settingsLocked,$$unsubscribe_settingsLocked=noop,$$subscribe_settingsLocked=()=>($$unsubscribe_settingsLocked(),$$unsubscribe_settingsLocked=subscribe(settingsLocked,($$value=>$$invalidate(2,$settingsLocked=$$value))),settingsLocked);validate_store(tools,"tools");component_subscribe($$self,tools,($$value=>$$invalidate(6,$tools=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(1,$strings=$$value)));$$self.$$.on_destroy.push((()=>$$unsubscribe_settingsLocked()));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("CopyBucketsPromptSubPage",slots,[]);const tool=$tools.copy_buckets;const dispatch=createEventDispatcher();let settingsLocked=writable(false);validate_store(settingsLocked,"settingsLocked");$$subscribe_settingsLocked();if(hasContext("settingsLocked")){$$subscribe_settingsLocked(settingsLocked=getContext("settingsLocked"))}async function handleSkip(){dispatch("routeEvent",{event:"next",default:"/"})}async function handleNext(){await tools.start(tool);dispatch("routeEvent",{event:"next",default:"/"})}const writable_props=[];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<CopyBucketsPromptSubPage> was created with unknown prop '${key}'`)}));$$self.$capture_state=()=>({createEventDispatcher:createEventDispatcher,getContext:getContext,hasContext:hasContext,writable:writable,pop:pop,strings:strings,tools:tools,SubPage:SubPage,Panel:Panel,PanelRow:PanelRow,BackNextButtonsRow:BackNextButtonsRow,tool:tool,dispatch:dispatch,settingsLocked:settingsLocked,handleSkip:handleSkip,handleNext:handleNext,$tools:$tools,$strings:$strings,$settingsLocked:$settingsLocked});$$self.$inject_state=$$props=>{if("settingsLocked"in $$props)$$subscribe_settingsLocked($$invalidate(0,settingsLocked=$$props.settingsLocked))};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[settingsLocked,$strings,$settingsLocked,tool,handleSkip,handleNext]}class CopyBucketsPromptSubPage extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$h,create_fragment$h,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"CopyBucketsPromptSubPage",options:options,id:create_fragment$h.name})}}const file$e="ui/pro/MoveObjectsPromptPage.svelte";function create_default_slot_4(ctx){let p;let raw_value=ctx[5].prompt+"";const block={c:function create(){p=element("p");add_location(p,file$e,66,3,1934)},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=raw_value},p:noop,d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_4.name,type:"slot",source:'(66:2) <PanelRow class=\\"body flex-column\\">',ctx:ctx});return block}function create_default_slot_3$1(ctx){let panelrow;let current;panelrow=new PanelRow({props:{class:"body flex-column",$$slots:{default:[create_default_slot_4]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty&32768){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_3$1.name,type:"slot",source:'(57:1) <Panel class=\\"toggle-header\\" heading={movePublicObjectsTool.name} toggleName=\\"move-public-objects\\" bind:toggle={movePublicObjects} helpURL={movePublicObjectsTool.doc_url} helpDesc={movePublicObjectsTool.doc_desc} multi >',ctx:ctx});return block}function create_default_slot_2$7(ctx){let p;let raw_value=ctx[6].prompt+"";const block={c:function create(){p=element("p");add_location(p,file$e,80,3,2286)},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=raw_value},p:noop,d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_2$7.name,type:"slot",source:'(80:2) <PanelRow class=\\"body flex-column\\">',ctx:ctx});return block}function create_default_slot_1$8(ctx){let panelrow;let current;panelrow=new PanelRow({props:{class:"body flex-column",$$slots:{default:[create_default_slot_2$7]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty&32768){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$8.name,type:"slot",source:'(71:1) <Panel class=\\"toggle-header\\" heading={movePrivateObjectsTool.name} toggleName=\\"move-private-objects\\" bind:toggle={movePrivateObjects} helpURL={movePrivateObjectsTool.doc_url} helpDesc={movePrivateObjectsTool.doc_desc} multi >',ctx:ctx});return block}function create_default_slot$9(ctx){let notifications;let t0;let panel0;let updating_toggle;let t1;let panel1;let updating_toggle_1;let t2;let backnextbuttonsrow;let current;notifications=new Notifications({props:{tab:"media",component:ToolNotification},$$inline:true});function panel0_toggle_binding(value){ctx[10](value)}let panel0_props={class:"toggle-header",heading:ctx[5].name,toggleName:"move-public-objects",helpURL:ctx[5].doc_url,helpDesc:ctx[5].doc_desc,multi:true,$$slots:{default:[create_default_slot_3$1]},$$scope:{ctx:ctx}};if(ctx[1]!==void 0){panel0_props.toggle=ctx[1]}panel0=new Panel({props:panel0_props,$$inline:true});binding_callbacks.push((()=>bind(panel0,"toggle",panel0_toggle_binding)));function panel1_toggle_binding(value){ctx[11](value)}let panel1_props={class:"toggle-header",heading:ctx[6].name,toggleName:"move-private-objects",helpURL:ctx[6].doc_url,helpDesc:ctx[6].doc_desc,multi:true,$$slots:{default:[create_default_slot_1$8]},$$scope:{ctx:ctx}};if(ctx[2]!==void 0){panel1_props.toggle=ctx[2]}panel1=new Panel({props:panel1_props,$$inline:true});binding_callbacks.push((()=>bind(panel1,"toggle",panel1_toggle_binding)));backnextbuttonsrow=new BackNextButtonsRow({props:{nextText:ctx[4].button,skipVisible:true,nextDisabled:ctx[3]},$$inline:true});backnextbuttonsrow.$on("skip",ctx[7]);backnextbuttonsrow.$on("next",ctx[8]);const block={c:function create(){create_component(notifications.$$.fragment);t0=space();create_component(panel0.$$.fragment);t1=space();create_component(panel1.$$.fragment);t2=space();create_component(backnextbuttonsrow.$$.fragment)},m:function mount(target,anchor){mount_component(notifications,target,anchor);insert_dev(target,t0,anchor);mount_component(panel0,target,anchor);insert_dev(target,t1,anchor);mount_component(panel1,target,anchor);insert_dev(target,t2,anchor);mount_component(backnextbuttonsrow,target,anchor);current=true},p:function update(ctx,dirty){const panel0_changes={};if(dirty&32768){panel0_changes.$$scope={dirty:dirty,ctx:ctx}}if(!updating_toggle&&dirty&2){updating_toggle=true;panel0_changes.toggle=ctx[1];add_flush_callback((()=>updating_toggle=false))}panel0.$set(panel0_changes);const panel1_changes={};if(dirty&32768){panel1_changes.$$scope={dirty:dirty,ctx:ctx}}if(!updating_toggle_1&&dirty&4){updating_toggle_1=true;panel1_changes.toggle=ctx[2];add_flush_callback((()=>updating_toggle_1=false))}panel1.$set(panel1_changes);const backnextbuttonsrow_changes={};if(dirty&8)backnextbuttonsrow_changes.nextDisabled=ctx[3];backnextbuttonsrow.$set(backnextbuttonsrow_changes)},i:function intro(local){if(current)return;transition_in(notifications.$$.fragment,local);transition_in(panel0.$$.fragment,local);transition_in(panel1.$$.fragment,local);transition_in(backnextbuttonsrow.$$.fragment,local);current=true},o:function outro(local){transition_out(notifications.$$.fragment,local);transition_out(panel0.$$.fragment,local);transition_out(panel1.$$.fragment,local);transition_out(backnextbuttonsrow.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(t1);detach_dev(t2)}destroy_component(notifications,detaching);destroy_component(panel0,detaching);destroy_component(panel1,detaching);destroy_component(backnextbuttonsrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$9.name,type:"slot",source:"(54:0) <Page {name} subpage on:routeEvent>",ctx:ctx});return block}function create_fragment$g(ctx){let page;let current;page=new Page({props:{name:ctx[0],subpage:true,$$slots:{default:[create_default_slot$9]},$$scope:{ctx:ctx}},$$inline:true});page.$on("routeEvent",ctx[12]);const block={c:function create(){create_component(page.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(page,target,anchor);current=true},p:function update(ctx,[dirty]){const page_changes={};if(dirty&1)page_changes.name=ctx[0];if(dirty&32782){page_changes.$$scope={dirty:dirty,ctx:ctx}}page.$set(page_changes)},i:function intro(local){if(current)return;transition_in(page.$$.fragment,local);current=true},o:function outro(local){transition_out(page.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(page,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$g.name,type:"component",source:"",ctx:ctx});return block}function instance$g($$self,$$props,$$invalidate){let nextDisabled;let $settingsLocked;let $tools;validate_store(settingsLocked,"settingsLocked");component_subscribe($$self,settingsLocked,($$value=>$$invalidate(9,$settingsLocked=$$value)));validate_store(tools,"tools");component_subscribe($$self,tools,($$value=>$$invalidate(13,$tools=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("MoveObjectsPromptPage",slots,[]);let{name:name="move-objects"}=$$props;setContext("settingsLocked",settingsLocked);const dispatch=createEventDispatcher();const moveObjectsTool=$tools.move_objects;const movePublicObjectsTool=$tools.move_public_objects;const movePrivateObjectsTool=$tools.move_private_objects;let movePublicObjects=false;let movePrivateObjects=true;async function handleSkip(){dispatch("routeEvent",{event:"next",default:"/"})}async function handleNext(){let tool=moveObjectsTool;if(!movePublicObjects||!movePrivateObjects){tool=movePublicObjects?movePublicObjectsTool:movePrivateObjectsTool}await tools.start(tool);dispatch("routeEvent",{event:"next",default:"/"})}const writable_props=["name"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<MoveObjectsPromptPage> was created with unknown prop '${key}'`)}));function panel0_toggle_binding(value){movePublicObjects=value;$$invalidate(1,movePublicObjects)}function panel1_toggle_binding(value){movePrivateObjects=value;$$invalidate(2,movePrivateObjects)}function routeEvent_handler(event){bubble.call(this,$$self,event)}$$self.$$set=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name)};$$self.$capture_state=()=>({createEventDispatcher:createEventDispatcher,setContext:setContext,settingsLocked:settingsLocked,tools:tools,Page:Page,Notifications:Notifications,ToolNotification:ToolNotification,BackNextButtonsRow:BackNextButtonsRow,Panel:Panel,PanelRow:PanelRow,name:name,dispatch:dispatch,moveObjectsTool:moveObjectsTool,movePublicObjectsTool:movePublicObjectsTool,movePrivateObjectsTool:movePrivateObjectsTool,movePublicObjects:movePublicObjects,movePrivateObjects:movePrivateObjects,handleSkip:handleSkip,handleNext:handleNext,nextDisabled:nextDisabled,$settingsLocked:$settingsLocked,$tools:$tools});$$self.$inject_state=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name);if("movePublicObjects"in $$props)$$invalidate(1,movePublicObjects=$$props.movePublicObjects);if("movePrivateObjects"in $$props)$$invalidate(2,movePrivateObjects=$$props.movePrivateObjects);if("nextDisabled"in $$props)$$invalidate(3,nextDisabled=$$props.nextDisabled)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty&518){$$invalidate(3,nextDisabled=$settingsLocked||!movePublicObjects&&!movePrivateObjects)}};return[name,movePublicObjects,movePrivateObjects,nextDisabled,moveObjectsTool,movePublicObjectsTool,movePrivateObjectsTool,handleSkip,handleNext,$settingsLocked,panel0_toggle_binding,panel1_toggle_binding,routeEvent_handler]}class MoveObjectsPromptPage extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$g,create_fragment$g,safe_not_equal,{name:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"MoveObjectsPromptPage",options:options,id:create_fragment$g.name})}get name(){throw new Error("<MoveObjectsPromptPage>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set name(value){throw new Error("<MoveObjectsPromptPage>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$d="ui/pro/MovePublicObjectsPromptPage.svelte";function create_default_slot_2$6(ctx){let p;let raw_value=ctx[2].prompt+"";const block={c:function create(){p=element("p");add_location(p,file$d,50,3,1357)},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=raw_value},p:noop,d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_2$6.name,type:"slot",source:'(50:2) <PanelRow class=\\"body flex-column\\">',ctx:ctx});return block}function create_default_slot_1$7(ctx){let panelrow;let current;panelrow=new PanelRow({props:{class:"body flex-column",$$slots:{default:[create_default_slot_2$6]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty&256){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$7.name,type:"slot",source:"(44:1) <Panel heading={tool.name} helpURL={tool.doc_url} helpDesc={tool.doc_desc} multi >",ctx:ctx});return block}function create_default_slot$8(ctx){let notifications;let t0;let panel;let t1;let backnextbuttonsrow;let current;notifications=new Notifications({props:{tab:"media",component:ToolNotification},$$inline:true});panel=new Panel({props:{heading:ctx[2].name,helpURL:ctx[2].doc_url,helpDesc:ctx[2].doc_desc,multi:true,$$slots:{default:[create_default_slot_1$7]},$$scope:{ctx:ctx}},$$inline:true});backnextbuttonsrow=new BackNextButtonsRow({props:{nextText:ctx[2].button,skipVisible:true,nextDisabled:ctx[1]},$$inline:true});backnextbuttonsrow.$on("skip",ctx[3]);backnextbuttonsrow.$on("next",ctx[4]);const block={c:function create(){create_component(notifications.$$.fragment);t0=space();create_component(panel.$$.fragment);t1=space();create_component(backnextbuttonsrow.$$.fragment)},m:function mount(target,anchor){mount_component(notifications,target,anchor);insert_dev(target,t0,anchor);mount_component(panel,target,anchor);insert_dev(target,t1,anchor);mount_component(backnextbuttonsrow,target,anchor);current=true},p:function update(ctx,dirty){const panel_changes={};if(dirty&256){panel_changes.$$scope={dirty:dirty,ctx:ctx}}panel.$set(panel_changes);const backnextbuttonsrow_changes={};if(dirty&2)backnextbuttonsrow_changes.nextDisabled=ctx[1];backnextbuttonsrow.$set(backnextbuttonsrow_changes)},i:function intro(local){if(current)return;transition_in(notifications.$$.fragment,local);transition_in(panel.$$.fragment,local);transition_in(backnextbuttonsrow.$$.fragment,local);current=true},o:function outro(local){transition_out(notifications.$$.fragment,local);transition_out(panel.$$.fragment,local);transition_out(backnextbuttonsrow.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(t1)}destroy_component(notifications,detaching);destroy_component(panel,detaching);destroy_component(backnextbuttonsrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$8.name,type:"slot",source:"(41:0) <Page {name} subpage on:routeEvent>",ctx:ctx});return block}function create_fragment$f(ctx){let page;let current;page=new Page({props:{name:ctx[0],subpage:true,$$slots:{default:[create_default_slot$8]},$$scope:{ctx:ctx}},$$inline:true});page.$on("routeEvent",ctx[5]);const block={c:function create(){create_component(page.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(page,target,anchor);current=true},p:function update(ctx,[dirty]){const page_changes={};if(dirty&1)page_changes.name=ctx[0];if(dirty&258){page_changes.$$scope={dirty:dirty,ctx:ctx}}page.$set(page_changes)},i:function intro(local){if(current)return;transition_in(page.$$.fragment,local);current=true},o:function outro(local){transition_out(page.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(page,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$f.name,type:"component",source:"",ctx:ctx});return block}function instance$f($$self,$$props,$$invalidate){let $tools;let $settingsLocked;validate_store(tools,"tools");component_subscribe($$self,tools,($$value=>$$invalidate(6,$tools=$$value)));validate_store(settingsLocked,"settingsLocked");component_subscribe($$self,settingsLocked,($$value=>$$invalidate(1,$settingsLocked=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("MovePublicObjectsPromptPage",slots,[]);let{name:name="move-public-objects"}=$$props;setContext("settingsLocked",settingsLocked);const dispatch=createEventDispatcher();const tool=$tools.move_public_objects;async function handleSkip(){dispatch("routeEvent",{event:"next",default:"/"})}async function handleNext(){await tools.start(tool);dispatch("routeEvent",{event:"next",default:"/"})}const writable_props=["name"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<MovePublicObjectsPromptPage> was created with unknown prop '${key}'`)}));function routeEvent_handler(event){bubble.call(this,$$self,event)}$$self.$$set=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name)};$$self.$capture_state=()=>({createEventDispatcher:createEventDispatcher,setContext:setContext,settingsLocked:settingsLocked,tools:tools,Page:Page,Notifications:Notifications,ToolNotification:ToolNotification,BackNextButtonsRow:BackNextButtonsRow,Panel:Panel,PanelRow:PanelRow,name:name,dispatch:dispatch,tool:tool,handleSkip:handleSkip,handleNext:handleNext,$tools:$tools,$settingsLocked:$settingsLocked});$$self.$inject_state=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[name,$settingsLocked,tool,handleSkip,handleNext,routeEvent_handler]}class MovePublicObjectsPromptPage extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$f,create_fragment$f,safe_not_equal,{name:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"MovePublicObjectsPromptPage",options:options,id:create_fragment$f.name})}get name(){throw new Error("<MovePublicObjectsPromptPage>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set name(value){throw new Error("<MovePublicObjectsPromptPage>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$c="ui/pro/MovePrivateObjectsPromptPage.svelte";function create_default_slot_2$5(ctx){let p;let raw_value=ctx[2].prompt+"";const block={c:function create(){p=element("p");add_location(p,file$c,50,3,1359)},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=raw_value},p:noop,d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_2$5.name,type:"slot",source:'(50:2) <PanelRow class=\\"body flex-column\\">',ctx:ctx});return block}function create_default_slot_1$6(ctx){let panelrow;let current;panelrow=new PanelRow({props:{class:"body flex-column",$$slots:{default:[create_default_slot_2$5]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty&256){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$6.name,type:"slot",source:"(44:1) <Panel heading={tool.name} helpURL={tool.doc_url} helpDesc={tool.doc_desc} multi >",ctx:ctx});return block}function create_default_slot$7(ctx){let notifications;let t0;let panel;let t1;let backnextbuttonsrow;let current;notifications=new Notifications({props:{tab:"media",component:ToolNotification},$$inline:true});panel=new Panel({props:{heading:ctx[2].name,helpURL:ctx[2].doc_url,helpDesc:ctx[2].doc_desc,multi:true,$$slots:{default:[create_default_slot_1$6]},$$scope:{ctx:ctx}},$$inline:true});backnextbuttonsrow=new BackNextButtonsRow({props:{nextText:ctx[2].button,skipVisible:true,nextDisabled:ctx[1]},$$inline:true});backnextbuttonsrow.$on("skip",ctx[3]);backnextbuttonsrow.$on("next",ctx[4]);const block={c:function create(){create_component(notifications.$$.fragment);t0=space();create_component(panel.$$.fragment);t1=space();create_component(backnextbuttonsrow.$$.fragment)},m:function mount(target,anchor){mount_component(notifications,target,anchor);insert_dev(target,t0,anchor);mount_component(panel,target,anchor);insert_dev(target,t1,anchor);mount_component(backnextbuttonsrow,target,anchor);current=true},p:function update(ctx,dirty){const panel_changes={};if(dirty&256){panel_changes.$$scope={dirty:dirty,ctx:ctx}}panel.$set(panel_changes);const backnextbuttonsrow_changes={};if(dirty&2)backnextbuttonsrow_changes.nextDisabled=ctx[1];backnextbuttonsrow.$set(backnextbuttonsrow_changes)},i:function intro(local){if(current)return;transition_in(notifications.$$.fragment,local);transition_in(panel.$$.fragment,local);transition_in(backnextbuttonsrow.$$.fragment,local);current=true},o:function outro(local){transition_out(notifications.$$.fragment,local);transition_out(panel.$$.fragment,local);transition_out(backnextbuttonsrow.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(t1)}destroy_component(notifications,detaching);destroy_component(panel,detaching);destroy_component(backnextbuttonsrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$7.name,type:"slot",source:"(41:0) <Page {name} subpage on:routeEvent>",ctx:ctx});return block}function create_fragment$e(ctx){let page;let current;page=new Page({props:{name:ctx[0],subpage:true,$$slots:{default:[create_default_slot$7]},$$scope:{ctx:ctx}},$$inline:true});page.$on("routeEvent",ctx[5]);const block={c:function create(){create_component(page.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(page,target,anchor);current=true},p:function update(ctx,[dirty]){const page_changes={};if(dirty&1)page_changes.name=ctx[0];if(dirty&258){page_changes.$$scope={dirty:dirty,ctx:ctx}}page.$set(page_changes)},i:function intro(local){if(current)return;transition_in(page.$$.fragment,local);current=true},o:function outro(local){transition_out(page.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(page,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$e.name,type:"component",source:"",ctx:ctx});return block}function instance$e($$self,$$props,$$invalidate){let $tools;let $settingsLocked;validate_store(tools,"tools");component_subscribe($$self,tools,($$value=>$$invalidate(6,$tools=$$value)));validate_store(settingsLocked,"settingsLocked");component_subscribe($$self,settingsLocked,($$value=>$$invalidate(1,$settingsLocked=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("MovePrivateObjectsPromptPage",slots,[]);let{name:name="move-private-objects"}=$$props;setContext("settingsLocked",settingsLocked);const dispatch=createEventDispatcher();const tool=$tools.move_private_objects;async function handleSkip(){dispatch("routeEvent",{event:"next",default:"/"})}async function handleNext(){await tools.start(tool);dispatch("routeEvent",{event:"next",default:"/"})}const writable_props=["name"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<MovePrivateObjectsPromptPage> was created with unknown prop '${key}'`)}));function routeEvent_handler(event){bubble.call(this,$$self,event)}$$self.$$set=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name)};$$self.$capture_state=()=>({createEventDispatcher:createEventDispatcher,setContext:setContext,settingsLocked:settingsLocked,tools:tools,Page:Page,Notifications:Notifications,ToolNotification:ToolNotification,BackNextButtonsRow:BackNextButtonsRow,Panel:Panel,PanelRow:PanelRow,name:name,dispatch:dispatch,tool:tool,handleSkip:handleSkip,handleNext:handleNext,$tools:$tools,$settingsLocked:$settingsLocked});$$self.$inject_state=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[name,$settingsLocked,tool,handleSkip,handleNext,routeEvent_handler]}class MovePrivateObjectsPromptPage extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$e,create_fragment$e,safe_not_equal,{name:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"MovePrivateObjectsPromptPage",options:options,id:create_fragment$e.name})}get name(){throw new Error("<MovePrivateObjectsPromptPage>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set name(value){throw new Error("<MovePrivateObjectsPromptPage>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$b="ui/pro/RemoveLocalFilesPromptPage.svelte";function create_default_slot_2$4(ctx){let p;let raw_value=ctx[2].prompt+"";const block={c:function create(){p=element("p");add_location(p,file$b,50,3,1355)},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=raw_value},p:noop,d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_2$4.name,type:"slot",source:'(50:2) <PanelRow class=\\"body flex-column\\">',ctx:ctx});return block}function create_default_slot_1$5(ctx){let panelrow;let current;panelrow=new PanelRow({props:{class:"body flex-column",$$slots:{default:[create_default_slot_2$4]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty&256){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$5.name,type:"slot",source:"(44:1) <Panel heading={tool.name} helpURL={tool.doc_url} helpDesc={tool.doc_desc} multi >",ctx:ctx});return block}function create_default_slot$6(ctx){let notifications;let t0;let panel;let t1;let backnextbuttonsrow;let current;notifications=new Notifications({props:{tab:"media",component:ToolNotification},$$inline:true});panel=new Panel({props:{heading:ctx[2].name,helpURL:ctx[2].doc_url,helpDesc:ctx[2].doc_desc,multi:true,$$slots:{default:[create_default_slot_1$5]},$$scope:{ctx:ctx}},$$inline:true});backnextbuttonsrow=new BackNextButtonsRow({props:{nextText:ctx[2].button,skipVisible:true,nextDisabled:ctx[1]},$$inline:true});backnextbuttonsrow.$on("skip",ctx[3]);backnextbuttonsrow.$on("next",ctx[4]);const block={c:function create(){create_component(notifications.$$.fragment);t0=space();create_component(panel.$$.fragment);t1=space();create_component(backnextbuttonsrow.$$.fragment)},m:function mount(target,anchor){mount_component(notifications,target,anchor);insert_dev(target,t0,anchor);mount_component(panel,target,anchor);insert_dev(target,t1,anchor);mount_component(backnextbuttonsrow,target,anchor);current=true},p:function update(ctx,dirty){const panel_changes={};if(dirty&256){panel_changes.$$scope={dirty:dirty,ctx:ctx}}panel.$set(panel_changes);const backnextbuttonsrow_changes={};if(dirty&2)backnextbuttonsrow_changes.nextDisabled=ctx[1];backnextbuttonsrow.$set(backnextbuttonsrow_changes)},i:function intro(local){if(current)return;transition_in(notifications.$$.fragment,local);transition_in(panel.$$.fragment,local);transition_in(backnextbuttonsrow.$$.fragment,local);current=true},o:function outro(local){transition_out(notifications.$$.fragment,local);transition_out(panel.$$.fragment,local);transition_out(backnextbuttonsrow.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(t1)}destroy_component(notifications,detaching);destroy_component(panel,detaching);destroy_component(backnextbuttonsrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$6.name,type:"slot",source:"(41:0) <Page {name} subpage on:routeEvent>",ctx:ctx});return block}function create_fragment$d(ctx){let page;let current;page=new Page({props:{name:ctx[0],subpage:true,$$slots:{default:[create_default_slot$6]},$$scope:{ctx:ctx}},$$inline:true});page.$on("routeEvent",ctx[5]);const block={c:function create(){create_component(page.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(page,target,anchor);current=true},p:function update(ctx,[dirty]){const page_changes={};if(dirty&1)page_changes.name=ctx[0];if(dirty&258){page_changes.$$scope={dirty:dirty,ctx:ctx}}page.$set(page_changes)},i:function intro(local){if(current)return;transition_in(page.$$.fragment,local);current=true},o:function outro(local){transition_out(page.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(page,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$d.name,type:"component",source:"",ctx:ctx});return block}function instance$d($$self,$$props,$$invalidate){let $tools;let $settingsLocked;validate_store(tools,"tools");component_subscribe($$self,tools,($$value=>$$invalidate(6,$tools=$$value)));validate_store(settingsLocked,"settingsLocked");component_subscribe($$self,settingsLocked,($$value=>$$invalidate(1,$settingsLocked=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("RemoveLocalFilesPromptPage",slots,[]);let{name:name="remove-local-files"}=$$props;setContext("settingsLocked",settingsLocked);const dispatch=createEventDispatcher();const tool=$tools.remove_local_files;async function handleSkip(){dispatch("routeEvent",{event:"next",default:"/"})}async function handleNext(){await tools.start(tool);dispatch("routeEvent",{event:"next",default:"/"})}const writable_props=["name"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<RemoveLocalFilesPromptPage> was created with unknown prop '${key}'`)}));function routeEvent_handler(event){bubble.call(this,$$self,event)}$$self.$$set=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name)};$$self.$capture_state=()=>({createEventDispatcher:createEventDispatcher,setContext:setContext,settingsLocked:settingsLocked,tools:tools,Page:Page,Notifications:Notifications,ToolNotification:ToolNotification,BackNextButtonsRow:BackNextButtonsRow,Panel:Panel,PanelRow:PanelRow,name:name,dispatch:dispatch,tool:tool,handleSkip:handleSkip,handleNext:handleNext,$tools:$tools,$settingsLocked:$settingsLocked});$$self.$inject_state=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[name,$settingsLocked,tool,handleSkip,handleNext,routeEvent_handler]}class RemoveLocalFilesPromptPage extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$d,create_fragment$d,safe_not_equal,{name:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"RemoveLocalFilesPromptPage",options:options,id:create_fragment$d.name})}get name(){throw new Error("<RemoveLocalFilesPromptPage>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set name(value){throw new Error("<RemoveLocalFilesPromptPage>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$a="ui/pro/UploaderPromptPage.svelte";function create_default_slot_2$3(ctx){let p;let raw_value=ctx[2].prompt+"";const block={c:function create(){p=element("p");add_location(p,file$a,50,3,1335)},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=raw_value},p:noop,d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_2$3.name,type:"slot",source:'(50:2) <PanelRow class=\\"body flex-column\\">',ctx:ctx});return block}function create_default_slot_1$4(ctx){let panelrow;let current;panelrow=new PanelRow({props:{class:"body flex-column",$$slots:{default:[create_default_slot_2$3]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty&256){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$4.name,type:"slot",source:"(44:1) <Panel heading={tool.name} helpURL={tool.doc_url} helpDesc={tool.doc_desc} multi >",ctx:ctx});return block}function create_default_slot$5(ctx){let notifications;let t0;let panel;let t1;let backnextbuttonsrow;let current;notifications=new Notifications({props:{tab:"media",component:ToolNotification},$$inline:true});panel=new Panel({props:{heading:ctx[2].name,helpURL:ctx[2].doc_url,helpDesc:ctx[2].doc_desc,multi:true,$$slots:{default:[create_default_slot_1$4]},$$scope:{ctx:ctx}},$$inline:true});backnextbuttonsrow=new BackNextButtonsRow({props:{nextText:ctx[2].button,skipVisible:true,nextDisabled:ctx[1]},$$inline:true});backnextbuttonsrow.$on("skip",ctx[3]);backnextbuttonsrow.$on("next",ctx[4]);const block={c:function create(){create_component(notifications.$$.fragment);t0=space();create_component(panel.$$.fragment);t1=space();create_component(backnextbuttonsrow.$$.fragment)},m:function mount(target,anchor){mount_component(notifications,target,anchor);insert_dev(target,t0,anchor);mount_component(panel,target,anchor);insert_dev(target,t1,anchor);mount_component(backnextbuttonsrow,target,anchor);current=true},p:function update(ctx,dirty){const panel_changes={};if(dirty&256){panel_changes.$$scope={dirty:dirty,ctx:ctx}}panel.$set(panel_changes);const backnextbuttonsrow_changes={};if(dirty&2)backnextbuttonsrow_changes.nextDisabled=ctx[1];backnextbuttonsrow.$set(backnextbuttonsrow_changes)},i:function intro(local){if(current)return;transition_in(notifications.$$.fragment,local);transition_in(panel.$$.fragment,local);transition_in(backnextbuttonsrow.$$.fragment,local);current=true},o:function outro(local){transition_out(notifications.$$.fragment,local);transition_out(panel.$$.fragment,local);transition_out(backnextbuttonsrow.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(t1)}destroy_component(notifications,detaching);destroy_component(panel,detaching);destroy_component(backnextbuttonsrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$5.name,type:"slot",source:"(41:0) <Page {name} subpage on:routeEvent>",ctx:ctx});return block}function create_fragment$c(ctx){let page;let current;page=new Page({props:{name:ctx[0],subpage:true,$$slots:{default:[create_default_slot$5]},$$scope:{ctx:ctx}},$$inline:true});page.$on("routeEvent",ctx[5]);const block={c:function create(){create_component(page.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(page,target,anchor);current=true},p:function update(ctx,[dirty]){const page_changes={};if(dirty&1)page_changes.name=ctx[0];if(dirty&258){page_changes.$$scope={dirty:dirty,ctx:ctx}}page.$set(page_changes)},i:function intro(local){if(current)return;transition_in(page.$$.fragment,local);current=true},o:function outro(local){transition_out(page.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(page,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$c.name,type:"component",source:"",ctx:ctx});return block}function instance$c($$self,$$props,$$invalidate){let $tools;let $settingsLocked;validate_store(tools,"tools");component_subscribe($$self,tools,($$value=>$$invalidate(6,$tools=$$value)));validate_store(settingsLocked,"settingsLocked");component_subscribe($$self,settingsLocked,($$value=>$$invalidate(1,$settingsLocked=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("UploaderPromptPage",slots,[]);let{name:name="uploader"}=$$props;setContext("settingsLocked",settingsLocked);const dispatch=createEventDispatcher();const tool=$tools.uploader;async function handleSkip(){dispatch("routeEvent",{event:"next",default:"/"})}async function handleNext(){await tools.start(tool);dispatch("routeEvent",{event:"next",default:"/"})}const writable_props=["name"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<UploaderPromptPage> was created with unknown prop '${key}'`)}));function routeEvent_handler(event){bubble.call(this,$$self,event)}$$self.$$set=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name)};$$self.$capture_state=()=>({createEventDispatcher:createEventDispatcher,setContext:setContext,settingsLocked:settingsLocked,tools:tools,Page:Page,Notifications:Notifications,ToolNotification:ToolNotification,BackNextButtonsRow:BackNextButtonsRow,Panel:Panel,PanelRow:PanelRow,name:name,dispatch:dispatch,tool:tool,handleSkip:handleSkip,handleNext:handleNext,$tools:$tools,$settingsLocked:$settingsLocked});$$self.$inject_state=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[name,$settingsLocked,tool,handleSkip,handleNext,routeEvent_handler]}class UploaderPromptPage extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$c,create_fragment$c,safe_not_equal,{name:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"UploaderPromptPage",options:options,id:create_fragment$c.name})}get name(){throw new Error("<UploaderPromptPage>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set name(value){throw new Error("<UploaderPromptPage>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$9="ui/pro/DownloaderPromptPage.svelte";function create_default_slot_2$2(ctx){let p;let raw_value=ctx[2].prompt+"";const block={c:function create(){p=element("p");add_location(p,file$9,50,3,1339)},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=raw_value},p:noop,d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_2$2.name,type:"slot",source:'(50:2) <PanelRow class=\\"body flex-column\\">',ctx:ctx});return block}function create_default_slot_1$3(ctx){let panelrow;let current;panelrow=new PanelRow({props:{class:"body flex-column",$$slots:{default:[create_default_slot_2$2]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty&256){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$3.name,type:"slot",source:"(44:1) <Panel heading={tool.name} helpURL={tool.doc_url} helpDesc={tool.doc_desc} multi >",ctx:ctx});return block}function create_default_slot$4(ctx){let notifications;let t0;let panel;let t1;let backnextbuttonsrow;let current;notifications=new Notifications({props:{tab:"media",component:ToolNotification},$$inline:true});panel=new Panel({props:{heading:ctx[2].name,helpURL:ctx[2].doc_url,helpDesc:ctx[2].doc_desc,multi:true,$$slots:{default:[create_default_slot_1$3]},$$scope:{ctx:ctx}},$$inline:true});backnextbuttonsrow=new BackNextButtonsRow({props:{nextText:ctx[2].button,skipVisible:true,nextDisabled:ctx[1]},$$inline:true});backnextbuttonsrow.$on("skip",ctx[3]);backnextbuttonsrow.$on("next",ctx[4]);const block={c:function create(){create_component(notifications.$$.fragment);t0=space();create_component(panel.$$.fragment);t1=space();create_component(backnextbuttonsrow.$$.fragment)},m:function mount(target,anchor){mount_component(notifications,target,anchor);insert_dev(target,t0,anchor);mount_component(panel,target,anchor);insert_dev(target,t1,anchor);mount_component(backnextbuttonsrow,target,anchor);current=true},p:function update(ctx,dirty){const panel_changes={};if(dirty&256){panel_changes.$$scope={dirty:dirty,ctx:ctx}}panel.$set(panel_changes);const backnextbuttonsrow_changes={};if(dirty&2)backnextbuttonsrow_changes.nextDisabled=ctx[1];backnextbuttonsrow.$set(backnextbuttonsrow_changes)},i:function intro(local){if(current)return;transition_in(notifications.$$.fragment,local);transition_in(panel.$$.fragment,local);transition_in(backnextbuttonsrow.$$.fragment,local);current=true},o:function outro(local){transition_out(notifications.$$.fragment,local);transition_out(panel.$$.fragment,local);transition_out(backnextbuttonsrow.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(t1)}destroy_component(notifications,detaching);destroy_component(panel,detaching);destroy_component(backnextbuttonsrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$4.name,type:"slot",source:"(41:0) <Page {name} subpage on:routeEvent>",ctx:ctx});return block}function create_fragment$b(ctx){let page;let current;page=new Page({props:{name:ctx[0],subpage:true,$$slots:{default:[create_default_slot$4]},$$scope:{ctx:ctx}},$$inline:true});page.$on("routeEvent",ctx[5]);const block={c:function create(){create_component(page.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(page,target,anchor);current=true},p:function update(ctx,[dirty]){const page_changes={};if(dirty&1)page_changes.name=ctx[0];if(dirty&258){page_changes.$$scope={dirty:dirty,ctx:ctx}}page.$set(page_changes)},i:function intro(local){if(current)return;transition_in(page.$$.fragment,local);current=true},o:function outro(local){transition_out(page.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(page,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$b.name,type:"component",source:"",ctx:ctx});return block}function instance$b($$self,$$props,$$invalidate){let $tools;let $settingsLocked;validate_store(tools,"tools");component_subscribe($$self,tools,($$value=>$$invalidate(6,$tools=$$value)));validate_store(settingsLocked,"settingsLocked");component_subscribe($$self,settingsLocked,($$value=>$$invalidate(1,$settingsLocked=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("DownloaderPromptPage",slots,[]);let{name:name="downloader"}=$$props;setContext("settingsLocked",settingsLocked);const dispatch=createEventDispatcher();const tool=$tools.downloader;async function handleSkip(){dispatch("routeEvent",{event:"next",default:"/"})}async function handleNext(){await tools.start(tool);dispatch("routeEvent",{event:"next",default:"/"})}const writable_props=["name"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<DownloaderPromptPage> was created with unknown prop '${key}'`)}));function routeEvent_handler(event){bubble.call(this,$$self,event)}$$self.$$set=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name)};$$self.$capture_state=()=>({createEventDispatcher:createEventDispatcher,setContext:setContext,settingsLocked:settingsLocked,tools:tools,Page:Page,Notifications:Notifications,ToolNotification:ToolNotification,BackNextButtonsRow:BackNextButtonsRow,Panel:Panel,PanelRow:PanelRow,name:name,dispatch:dispatch,tool:tool,handleSkip:handleSkip,handleNext:handleNext,$tools:$tools,$settingsLocked:$settingsLocked});$$self.$inject_state=$$props=>{if("name"in $$props)$$invalidate(0,name=$$props.name)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[name,$settingsLocked,tool,handleSkip,handleNext,routeEvent_handler]}class DownloaderPromptPage extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$b,create_fragment$b,safe_not_equal,{name:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"DownloaderPromptPage",options:options,id:create_fragment$b.name})}get name(){throw new Error("<DownloaderPromptPage>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set name(value){throw new Error("<DownloaderPromptPage>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}function addPages(enabledTools){pages.add({position:10,name:"assets",title:()=>get_store_value(strings).assets_tab_title,nav:true,route:"/assets",component:AssetsPage});pages.add({position:20,name:"tools",title:()=>get_store_value(strings).tools_tab_title,nav:true,route:"/tools",component:ToolsPage});pages.add({position:90,name:"licence",title:()=>get_store_value(strings).licence_tab_title,nav:true,route:"/license",component:LicencePage});pages.add({position:100,name:"support",title:()=>get_store_value(strings).support_tab_title,nav:true,route:"/support",component:SupportPage_1});if(enabledTools.hasOwnProperty("update_acls")){const updateACLs={position:240,name:"update-acls",title:()=>enabledTools.update_acls.name,subNav:true,route:"/storage/update-acls",component:UpdateObjectACLsPromptSubPage,enabled:()=>{if(!get_store_value(counts).hasOwnProperty("offloaded")||get_store_value(counts).offloaded<1||!get_store_value(current_settings).hasOwnProperty("bucket")){return false}if(get_store_value(storage_provider).requires_acls){return false}if(get_store_value(bapa)||get_store_value(ooe)){return false}if(get_store_value(storage_provider).block_public_access_supported&&get_store_value(current_settings).hasOwnProperty("block-public-access")&&updateACLs.blockPublicAccess!==get_store_value(current_settings)["block-public-access"]){return true}if(get_store_value(storage_provider).object_ownership_supported&&get_store_value(current_settings).hasOwnProperty("object-ownership-enforced")&&updateACLs.objectOwnershipEnforced!==get_store_value(current_settings)["object-ownership-enforced"]){return true}return false},isNextRoute:data=>{if(!get_store_value(licence).hasOwnProperty("is_valid")||!get_store_value(licence).is_valid||!updateACLs.enabled()){return false}return get_store_value(location$1)==="/storage/security"},blockPublicAccess:get_store_value(current_settings).hasOwnProperty("bucket")&&get_store_value(current_settings).hasOwnProperty("block-public-access")?get_store_value(current_settings)["block-public-access"]:false,objectOwnershipEnforced:get_store_value(current_settings).hasOwnProperty("bucket")&&get_store_value(current_settings).hasOwnProperty("object-ownership-enforced")?get_store_value(current_settings)["object-ownership-enforced"]:false,setInitialProperties:data=>{if(data.hasOwnProperty("settings")&&data.settings.hasOwnProperty("bucket")){if(data.settings.hasOwnProperty("block-public-access")){updateACLs.blockPublicAccess=data.settings["block-public-access"]}else{updateACLs.blockPublicAccess=false}if(data.settings.hasOwnProperty("object-ownership-enforced")){updateACLs.objectOwnershipEnforced=data.settings["object-ownership-enforced"]}else{updateACLs.objectOwnershipEnforced=false}}return false},events:{next:data=>updateACLs.isNextRoute(data),"bucket-security":data=>updateACLs.isNextRoute(data),"settings.save":data=>updateACLs.setInitialProperties(data),"page.initial.settings":data=>updateACLs.setInitialProperties(data)}};pages.add(updateACLs)}if(enabledTools.hasOwnProperty("copy_buckets")){const copyBuckets={position:250,name:"copy-buckets",title:()=>enabledTools.copy_buckets.name,subNav:true,route:"/storage/copy-buckets",component:CopyBucketsPromptSubPage,enabled:()=>get_store_value(counts).offloaded>0&&get_store_value(current_settings).hasOwnProperty("bucket")&&copyBuckets.bucket!==get_store_value(current_settings).bucket,isNextRoute:data=>{if(!get_store_value(licence).hasOwnProperty("is_valid")||!get_store_value(licence).is_valid||!copyBuckets.enabled()){return false}return get_store_value(location$1)==="/storage/bucket"||get_store_value(location$1)==="/storage/security"||get_store_value(location$1)==="/storage/update-acls"},bucket:get_store_value(current_settings).hasOwnProperty("bucket")?get_store_value(current_settings).bucket:"",setInitialBucket:data=>{if(data.hasOwnProperty("settings")&&data.settings.hasOwnProperty("bucket")){copyBuckets.bucket=data.settings.bucket}return false},events:{next:data=>copyBuckets.isNextRoute(data),"settings.save":data=>copyBuckets.isNextRoute(data),"bucket-security":data=>copyBuckets.isNextRoute(data),"page.initial.settings":data=>copyBuckets.setInitialBucket(data)}};pages.add(copyBuckets)}if(enabledTools.hasOwnProperty("move_objects")&&enabledTools.hasOwnProperty("move_public_objects")&&enabledTools.hasOwnProperty("move_private_objects")){const moveObjects={position:400,name:"move-objects",title:()=>enabledTools.move_objects.name,route:"/prompt/move-objects",component:MoveObjectsPromptPage,publicPathChanged:data=>{if(data.hasOwnProperty("changed_settings")){if(data.changed_settings.includes("use-yearmonth-folders")&&get_store_value(current_settings).hasOwnProperty("use-yearmonth-folders")&&!get_store_value(current_settings)["use-yearmonth-folders"]){return false}if(data.changed_settings.includes("object-versioning")&&get_store_value(current_settings).hasOwnProperty("object-versioning")&&!get_store_value(current_settings)["object-versioning"]){return false}if(data.changed_settings.includes("enable-object-prefix")&&get_store_value(current_settings).hasOwnProperty("enable-object-prefix")){return true}if(data.changed_settings.includes("object-prefix")&&get_store_value(current_settings).hasOwnProperty("enable-object-prefix")&&get_store_value(current_settings)["enable-object-prefix"]){return true}if(data.changed_settings.includes("use-yearmonth-folders")&&get_store_value(current_settings).hasOwnProperty("use-yearmonth-folders")&&get_store_value(current_settings)["use-yearmonth-folders"]){return true}if(data.changed_settings.includes("object-versioning")&&get_store_value(current_settings).hasOwnProperty("object-versioning")&&get_store_value(current_settings)["object-versioning"]){return true}}return false},privatePathChanged:data=>{if(data.hasOwnProperty("changed_settings")){if(data.changed_settings.includes("enable-signed-urls")&&get_store_value(current_settings).hasOwnProperty("enable-signed-urls")){return true}if(data.changed_settings.includes("signed-urls-object-prefix")&&get_store_value(current_settings).hasOwnProperty("enable-signed-urls")&&get_store_value(current_settings)["enable-signed-urls"]){return true}}return false},isNextRoute:data=>{if(!get_store_value(licence).hasOwnProperty("is_valid")||!get_store_value(licence).is_valid||!get_store_value(current_settings).hasOwnProperty("bucket")||!get_store_value(counts).hasOwnProperty("offloaded")||get_store_value(counts).offloaded<1){return false}return moveObjects.publicPathChanged(data)&&moveObjects.privatePathChanged(data)},events:{"settings.save":data=>moveObjects.isNextRoute(data)}};pages.add(moveObjects);const movePublicObjects={position:410,name:"move-public-objects",title:()=>enabledTools.move_public_objects.name,route:"/prompt/move-public-objects",component:MovePublicObjectsPromptPage,isNextRoute:data=>{if(!get_store_value(licence).hasOwnProperty("is_valid")||!get_store_value(licence).is_valid||!get_store_value(current_settings).hasOwnProperty("bucket")||!get_store_value(counts).hasOwnProperty("offloaded")||get_store_value(counts).offloaded<1){return false}return moveObjects.publicPathChanged(data)},events:{"settings.save":data=>movePublicObjects.isNextRoute(data)}};pages.add(movePublicObjects);const movePrivateObjects={position:420,name:"move-private-objects",title:()=>enabledTools.move_private_objects.name,route:"/prompt/move-private-objects",component:MovePrivateObjectsPromptPage,isNextRoute:data=>{if(!get_store_value(licence).hasOwnProperty("is_valid")||!get_store_value(licence).is_valid||!get_store_value(current_settings).hasOwnProperty("bucket")||!get_store_value(counts).hasOwnProperty("offloaded")||get_store_value(counts).offloaded<1){return false}return moveObjects.privatePathChanged(data)},events:{"settings.save":data=>movePrivateObjects.isNextRoute(data)}};pages.add(movePrivateObjects)}if(enabledTools.hasOwnProperty("remove_local_files")){const removeLocalFiles={position:430,name:"remove-local-files",title:()=>enabledTools.remove_local_files.name,route:"/prompt/remove-local-files",component:RemoveLocalFilesPromptPage,onPreviousPage:()=>{const previousPages=pages.withPrefix("/prompt/").filter((page=>page.position<removeLocalFiles.position));for(const previousPage of previousPages){if(get_store_value(location$1)===previousPage.route){return true}}return false},removeLocalFile:get_store_value(current_settings).hasOwnProperty("remove-local-file")?get_store_value(current_settings)["remove-local-file"]:false,setInitialRemoveLocalFile:data=>{if(get_store_value(location$1)!==removeLocalFiles.route&&!removeLocalFiles.onPreviousPage()&&data.hasOwnProperty("settings")&&data.settings.hasOwnProperty("remove-local-file")){removeLocalFiles.removeLocalFile=data.settings["remove-local-file"]}return false},isNextRoute:data=>{if(!get_store_value(licence).hasOwnProperty("is_valid")||!get_store_value(licence).is_valid||!get_store_value(current_settings).hasOwnProperty("bucket")||!get_store_value(counts).hasOwnProperty("offloaded")||get_store_value(counts).offloaded<1){return false}if(data.hasOwnProperty("changed_settings")){if(data.changed_settings.includes("remove-local-file")&&get_store_value(current_settings).hasOwnProperty("remove-local-file")&&removeLocalFiles.removeLocalFile!==get_store_value(current_settings)["remove-local-file"]&&get_store_value(current_settings)["remove-local-file"]){return true}}if(removeLocalFiles.onPreviousPage()&&get_store_value(current_settings).hasOwnProperty("remove-local-file")&&removeLocalFiles.removeLocalFile!==get_store_value(current_settings)["remove-local-file"]&&get_store_value(current_settings)["remove-local-file"]){return true}if(get_store_value(current_settings).hasOwnProperty("remove-local-file")){removeLocalFiles.removeLocalFile=get_store_value(current_settings)["remove-local-file"]}return false},events:{next:data=>removeLocalFiles.isNextRoute(data),"settings.save":data=>removeLocalFiles.isNextRoute(data),"page.initial.settings":data=>removeLocalFiles.setInitialRemoveLocalFile(data)}};pages.add(removeLocalFiles)}if(enabledTools.hasOwnProperty("uploader")){const uploader={position:440,name:"uploader",title:()=>enabledTools.uploader.name,route:"/prompt/uploader",component:UploaderPromptPage,onPreviousPage:()=>{const previousPages=pages.withPrefix("/prompt/").filter((page=>page.position<uploader.position));for(const previousPage of previousPages){if(get_store_value(location$1)===previousPage.route){return true}}return false},copyToProvider:get_store_value(current_settings).hasOwnProperty("copy-to-s3")?get_store_value(current_settings)["copy-to-s3"]:false,setInitialCopyToProvider:data=>{if(get_store_value(location$1)!==uploader.route&&!uploader.onPreviousPage()&&data.hasOwnProperty("settings")&&data.settings.hasOwnProperty("copy-to-s3")){uploader.copyToProvider=data.settings["copy-to-s3"]}return false},isNextRoute:data=>{if(!get_store_value(licence).hasOwnProperty("is_valid")||!get_store_value(licence).is_valid||!get_store_value(current_settings).hasOwnProperty("bucket")||!get_store_value(counts).hasOwnProperty("not_offloaded")||get_store_value(counts).not_offloaded<1){return false}if(data.hasOwnProperty("changed_settings")){if(data.changed_settings.includes("copy-to-s3")&&get_store_value(current_settings).hasOwnProperty("copy-to-s3")&&uploader.copyToProvider!==get_store_value(current_settings)["copy-to-s3"]&&get_store_value(current_settings)["copy-to-s3"]){return true}}if(uploader.onPreviousPage()&&get_store_value(current_settings).hasOwnProperty("copy-to-s3")&&uploader.copyToProvider!==get_store_value(current_settings)["copy-to-s3"]&&get_store_value(current_settings)["copy-to-s3"]){return true}if(get_store_value(current_settings).hasOwnProperty("copy-to-s3")){uploader.copyToProvider=get_store_value(current_settings)["copy-to-s3"]}return false},events:{next:data=>uploader.isNextRoute(data),"settings.save":data=>uploader.isNextRoute(data),"page.initial.settings":data=>uploader.setInitialCopyToProvider(data)}};pages.add(uploader)}if(enabledTools.hasOwnProperty("downloader")){const downloader={position:450,name:"downloader",title:()=>enabledTools.downloader.name,route:"/prompt/downloader",component:DownloaderPromptPage,onPreviousPage:()=>{const previousPages=pages.withPrefix("/prompt/").filter((page=>page.position<downloader.position));for(const previousPage of previousPages){if(get_store_value(location$1)===previousPage.route){return true}}return false},removeLocalFile:get_store_value(current_settings).hasOwnProperty("remove-local-file")?get_store_value(current_settings)["remove-local-file"]:false,setInitialRemoveLocalFile:data=>{if(get_store_value(location$1)!==downloader.route&&!downloader.onPreviousPage()&&data.hasOwnProperty("settings")&&data.settings.hasOwnProperty("remove-local-file")){downloader.removeLocalFile=data.settings["remove-local-file"]}return false},isNextRoute:data=>{if(!get_store_value(licence).hasOwnProperty("is_valid")||!get_store_value(licence).is_valid||!get_store_value(current_settings).hasOwnProperty("bucket")||!get_store_value(counts).hasOwnProperty("offloaded")||get_store_value(counts).offloaded<1){return false}if(data.hasOwnProperty("changed_settings")){if(data.changed_settings.includes("remove-local-file")&&get_store_value(current_settings).hasOwnProperty("remove-local-file")&&downloader.removeLocalFile!==get_store_value(current_settings)["remove-local-file"]&&!get_store_value(current_settings)["remove-local-file"]){return true}}if(downloader.onPreviousPage()&&get_store_value(current_settings).hasOwnProperty("remove-local-file")&&downloader.removeLocalFile!==get_store_value(current_settings)["remove-local-file"]&&!get_store_value(current_settings)["remove-local-file"]){return true}if(get_store_value(current_settings).hasOwnProperty("remove-local-file")){downloader.removeLocalFile=get_store_value(current_settings)["remove-local-file"]}return false},events:{next:data=>downloader.isNextRoute(data),"settings.save":data=>downloader.isNextRoute(data),"page.initial.settings":data=>downloader.setInitialRemoveLocalFile(data)}};pages.add(downloader)}}const settingsNotifications={process:(notifications,settings,current_settings,strings)=>{if(settings.hasOwnProperty("remove-local-file")&&settings["remove-local-file"]){let entries=notifications.has("remove-local-file")?notifications.get("remove-local-file"):new Map;if(settings.hasOwnProperty("serve-from-s3")&&!settings["serve-from-s3"]){if(!entries.has("lost-files-notice")){entries.set("lost-files-notice",{inline:true,type:"error",heading:strings.lost_files_notice_heading,message:strings.lost_files_notice_message})}}else{entries.delete("lost-files-notice")}if(!entries.has("remove-local-file-notice")&&current_settings.hasOwnProperty("remove-local-file")&&!current_settings["remove-local-file"]){entries.set("remove-local-file-notice",{inline:true,type:"warning",message:strings.remove_local_file_message})}notifications.set("remove-local-file",entries)}else{notifications.delete("remove-local-file")}return notifications}};const toolSettingsNotifications={process:(notifications,settings,current_settings,strings,counts,licence)=>{let entries=notifications.has("use-yearmonth-folders")?notifications.get("use-yearmonth-folders"):new Map;if(current_settings.hasOwnProperty("use-yearmonth-folders")&&current_settings["use-yearmonth-folders"]&&settings.hasOwnProperty("use-yearmonth-folders")&&!settings["use-yearmonth-folders"]&&counts.hasOwnProperty("offloaded")&&counts.offloaded>0&&licence.hasOwnProperty("is_valid")&&licence.is_valid){if(!entries.has("no-move-objects-year-month-notice")){entries.set("no-move-objects-year-month-notice",{inline:true,type:"warning",message:strings.no_move_objects_year_month_notice})}}else if(entries.has("no-move-objects-year-month-notice")){entries.delete("no-move-objects-year-month-notice")}notifications.set("use-yearmonth-folders",entries);entries=notifications.has("object-versioning")?notifications.get("object-versioning"):new Map;if(current_settings.hasOwnProperty("object-versioning")&&current_settings["object-versioning"]&&settings.hasOwnProperty("object-versioning")&&!settings["object-versioning"]&&counts.hasOwnProperty("offloaded")&&counts.offloaded>0&&licence.hasOwnProperty("is_valid")&&licence.is_valid){if(!entries.has("no-move-objects-object-versioning-notice")){entries.set("no-move-objects-object-versioning-notice",{inline:true,type:"warning",message:strings.no_move_objects_object_versioning_notice})}}else if(entries.has("no-move-objects-object-versioning-notice")){entries.delete("no-move-objects-object-versioning-notice")}notifications.set("object-versioning",entries);return notifications}};const file$8="ui/components/Header.svelte";function create_fragment$a(ctx){let div2;let div1;let img;let img_src_value;let img_alt_value;let t0;let h1;let t1_value=ctx[1].title+"";let t1;let t2;let div0;let current;const default_slot_template=ctx[4].default;const default_slot=create_slot(default_slot_template,ctx,ctx[3],null);const block={c:function create(){div2=element("div");div1=element("div");img=element("img");t0=space();h1=element("h1");t1=text(t1_value);t2=space();div0=element("div");if(default_slot)default_slot.c();attr_dev(img,"class","medallion");if(!src_url_equal(img.src,img_src_value=ctx[0]))attr_dev(img,"src",img_src_value);attr_dev(img,"alt",img_alt_value=""+(ctx[1].title+" logo"));add_location(img,file$8,8,2,185);add_location(h1,file$8,9,2,259);attr_dev(div0,"class","licence");add_location(div0,file$8,10,2,286);attr_dev(div1,"class","header-wrapper");add_location(div1,file$8,7,1,154);attr_dev(div2,"class","header");add_location(div2,file$8,6,0,132)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,div2,anchor);append_dev(div2,div1);append_dev(div1,img);append_dev(div1,t0);append_dev(div1,h1);append_dev(h1,t1);append_dev(div1,t2);append_dev(div1,div0);if(default_slot){default_slot.m(div0,null)}current=true},p:function update(ctx,[dirty]){if(!current||dirty&1&&!src_url_equal(img.src,img_src_value=ctx[0])){attr_dev(img,"src",img_src_value)}if(!current||dirty&2&&img_alt_value!==(img_alt_value=""+(ctx[1].title+" logo"))){attr_dev(img,"alt",img_alt_value)}if((!current||dirty&2)&&t1_value!==(t1_value=ctx[1].title+""))set_data_dev(t1,t1_value);if(default_slot){if(default_slot.p&&(!current||dirty&8)){update_slot_base(default_slot,default_slot_template,ctx,ctx[3],!current?get_all_dirty_from_scope(ctx[3]):get_slot_changes(default_slot_template,ctx[3],dirty,null),null)}}},i:function intro(local){if(current)return;transition_in(default_slot,local);current=true},o:function outro(local){transition_out(default_slot,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(div2)}if(default_slot)default_slot.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$a.name,type:"component",source:"",ctx:ctx});return block}function instance$a($$self,$$props,$$invalidate){let header_img_url;let $urls;let $config;validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(2,$urls=$$value)));validate_store(config,"config");component_subscribe($$self,config,($$value=>$$invalidate(1,$config=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("Header",slots,["default"]);const writable_props=[];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<Header> was created with unknown prop '${key}'`)}));$$self.$$set=$$props=>{if("$$scope"in $$props)$$invalidate(3,$$scope=$$props.$$scope)};$$self.$capture_state=()=>({config:config,urls:urls,header_img_url:header_img_url,$urls:$urls,$config:$config});$$self.$inject_state=$$props=>{if("header_img_url"in $$props)$$invalidate(0,header_img_url=$$props.header_img_url)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty&4){$$invalidate(0,header_img_url=$urls.assets+"img/brand/ome-medallion.svg")}};return[header_img_url,$config,$urls,$$scope,slots]}class Header extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$a,create_fragment$a,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"Header",options:options,id:create_fragment$a.name})}}function create_if_block_1$3(ctx){let switch_instance;let switch_instance_anchor;let current;var switch_value=ctx[0];function switch_props(ctx,dirty){return{$$inline:true}}if(switch_value){switch_instance=construct_svelte_component_dev(switch_value,switch_props())}const block={c:function create(){if(switch_instance)create_component(switch_instance.$$.fragment);switch_instance_anchor=empty()},m:function mount(target,anchor){if(switch_instance)mount_component(switch_instance,target,anchor);insert_dev(target,switch_instance_anchor,anchor);current=true},p:function update(ctx,dirty){if(dirty&1&&switch_value!==(switch_value=ctx[0])){if(switch_instance){group_outros();const old_component=switch_instance;transition_out(old_component.$$.fragment,1,0,(()=>{destroy_component(old_component,1)}));check_outros()}if(switch_value){switch_instance=construct_svelte_component_dev(switch_value,switch_props());create_component(switch_instance.$$.fragment);transition_in(switch_instance.$$.fragment,1);mount_component(switch_instance,switch_instance_anchor.parentNode,switch_instance_anchor)}else{switch_instance=null}}},i:function intro(local){if(current)return;if(switch_instance)transition_in(switch_instance.$$.fragment,local);current=true},o:function outro(local){if(switch_instance)transition_out(switch_instance.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(switch_instance_anchor)}if(switch_instance)destroy_component(switch_instance,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_1$3.name,type:"if",source:"(29:0) {#if header}",ctx:ctx});return block}function create_if_block$6(ctx){let switch_instance;let switch_instance_anchor;let current;var switch_value=ctx[1];function switch_props(ctx,dirty){return{$$inline:true}}if(switch_value){switch_instance=construct_svelte_component_dev(switch_value,switch_props())}const block={c:function create(){if(switch_instance)create_component(switch_instance.$$.fragment);switch_instance_anchor=empty()},m:function mount(target,anchor){if(switch_instance)mount_component(switch_instance,target,anchor);insert_dev(target,switch_instance_anchor,anchor);current=true},p:function update(ctx,dirty){if(dirty&2&&switch_value!==(switch_value=ctx[1])){if(switch_instance){group_outros();const old_component=switch_instance;transition_out(old_component.$$.fragment,1,0,(()=>{destroy_component(old_component,1)}));check_outros()}if(switch_value){switch_instance=construct_svelte_component_dev(switch_value,switch_props());create_component(switch_instance.$$.fragment);transition_in(switch_instance.$$.fragment,1);mount_component(switch_instance,switch_instance_anchor.parentNode,switch_instance_anchor)}else{switch_instance=null}}},i:function intro(local){if(current)return;if(switch_instance)transition_in(switch_instance.$$.fragment,local);current=true},o:function outro(local){if(switch_instance)transition_out(switch_instance.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(switch_instance_anchor)}if(switch_instance)destroy_component(switch_instance,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$6.name,type:"if",source:"(35:0) {#if footer}",ctx:ctx});return block}function create_fragment$9(ctx){let t0;let t1;let if_block1_anchor;let current;let if_block0=ctx[0]&&create_if_block_1$3(ctx);const default_slot_template=ctx[3].default;const default_slot=create_slot(default_slot_template,ctx,ctx[2],null);let if_block1=ctx[1]&&create_if_block$6(ctx);const block={c:function create(){if(if_block0)if_block0.c();t0=space();if(default_slot)default_slot.c();t1=space();if(if_block1)if_block1.c();if_block1_anchor=empty()},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){if(if_block0)if_block0.m(target,anchor);insert_dev(target,t0,anchor);if(default_slot){default_slot.m(target,anchor)}insert_dev(target,t1,anchor);if(if_block1)if_block1.m(target,anchor);insert_dev(target,if_block1_anchor,anchor);current=true},p:function update(ctx,[dirty]){if(ctx[0]){if(if_block0){if_block0.p(ctx,dirty);if(dirty&1){transition_in(if_block0,1)}}else{if_block0=create_if_block_1$3(ctx);if_block0.c();transition_in(if_block0,1);if_block0.m(t0.parentNode,t0)}}else if(if_block0){group_outros();transition_out(if_block0,1,1,(()=>{if_block0=null}));check_outros()}if(default_slot){if(default_slot.p&&(!current||dirty&4)){update_slot_base(default_slot,default_slot_template,ctx,ctx[2],!current?get_all_dirty_from_scope(ctx[2]):get_slot_changes(default_slot_template,ctx[2],dirty,null),null)}}if(ctx[1]){if(if_block1){if_block1.p(ctx,dirty);if(dirty&2){transition_in(if_block1,1)}}else{if_block1=create_if_block$6(ctx);if_block1.c();transition_in(if_block1,1);if_block1.m(if_block1_anchor.parentNode,if_block1_anchor)}}else if(if_block1){group_outros();transition_out(if_block1,1,1,(()=>{if_block1=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(if_block0);transition_in(default_slot,local);transition_in(if_block1);current=true},o:function outro(local){transition_out(if_block0);transition_out(default_slot,local);transition_out(if_block1);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(t1);detach_dev(if_block1_anchor)}if(if_block0)if_block0.d(detaching);if(default_slot)default_slot.d(detaching);if(if_block1)if_block1.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$9.name,type:"component",source:"",ctx:ctx});return block}function instance$9($$self,$$props,$$invalidate){let $config;validate_store(config,"config");component_subscribe($$self,config,($$value=>$$invalidate(4,$config=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("Settings",slots,["default"]);let{header:header=Header}=$$props;let{footer:footer=null}=$$props;settings.set({...$config.settings});if($config.notifications.length){for(const notification of $config.notifications){notifications.add(notification)}}onMount((()=>{state.startPeriodicFetch();return()=>state.stopPeriodicFetch()}));const writable_props=["header","footer"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<Settings> was created with unknown prop '${key}'`)}));$$self.$$set=$$props=>{if("header"in $$props)$$invalidate(0,header=$$props.header);if("footer"in $$props)$$invalidate(1,footer=$$props.footer);if("$$scope"in $$props)$$invalidate(2,$$scope=$$props.$$scope)};$$self.$capture_state=()=>({onMount:onMount,config:config,notifications:notifications,settings:settings,state:state,Header:Header,header:header,footer:footer,$config:$config});$$self.$inject_state=$$props=>{if("header"in $$props)$$invalidate(0,header=$$props.header);if("footer"in $$props)$$invalidate(1,footer=$$props.footer)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[header,footer,$$scope,slots]}class Settings extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$9,create_fragment$9,safe_not_equal,{header:0,footer:1});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"Settings",options:options,id:create_fragment$9.name})}get header(){throw new Error("<Settings>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set header(value){throw new Error("<Settings>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get footer(){throw new Error("<Settings>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set footer(value){throw new Error("<Settings>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$7="ui/pro/Header.svelte";function create_else_block_1$1(ctx){let button;let current;button=new Button({props:{large:true,primary:true,$$slots:{default:[create_default_slot_1$2]},$$scope:{ctx:ctx}},$$inline:true});button.$on("click",ctx[3]);const block={c:function create(){create_component(button.$$.fragment)},m:function mount(target,anchor){mount_component(button,target,anchor);current=true},p:function update(ctx,dirty){const button_changes={};if(dirty&20){button_changes.$$scope={dirty:dirty,ctx:ctx}}button.$set(button_changes)},i:function intro(local){if(current)return;transition_in(button.$$.fragment,local);current=true},o:function outro(local){transition_out(button.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(button,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block_1$1.name,type:"else",source:"(23:1) {:else}",ctx:ctx});return block}function create_if_block$5(ctx){let if_block_anchor;function select_block_type_1(ctx,dirty){if(ctx[0].is_valid)return create_if_block_1$2;return create_else_block$2}let current_block_type=select_block_type_1(ctx);let if_block=current_block_type(ctx);const block={c:function create(){if_block.c();if_block_anchor=empty()},m:function mount(target,anchor){if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor)},p:function update(ctx,dirty){if(current_block_type===(current_block_type=select_block_type_1(ctx))&&if_block){if_block.p(ctx,dirty)}else{if_block.d(1);if_block=current_block_type(ctx);if(if_block){if_block.c();if_block.m(if_block_anchor.parentNode,if_block_anchor)}}},i:noop,o:noop,d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$5.name,type:"if",source:"(10:1) {#if $licence.is_set}",ctx:ctx});return block}function create_default_slot_1$2(ctx){let t_value=ctx[2].activate_licence+"";let t;const block={c:function create(){t=text(t_value)},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty&4&&t_value!==(t_value=ctx[2].activate_licence+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$2.name,type:"slot",source:'(24:2) <Button large primary on:click={() => push(\\"/license\\")}>',ctx:ctx});return block}function create_else_block$2(ctx){let div;let img;let img_src_value;let img_alt_value;let t0;let a;let t1_value=ctx[0].status_description+"";let t1;let a_href_value;const block={c:function create(){div=element("div");img=element("img");t0=space();a=element("a");t1=text(t1_value);if(!src_url_equal(img.src,img_src_value=ctx[1].assets+"img/icon/error.svg"))attr_dev(img,"src",img_src_value);attr_dev(img,"alt",img_alt_value=ctx[2].licence_error);add_location(img,file$7,18,4,609);attr_dev(a,"href",a_href_value=ctx[1].licenses);attr_dev(a,"class","licence");attr_dev(a,"target","_blank");add_location(a,file$7,19,4,691);attr_dev(div,"class","licence-type");add_location(div,file$7,17,3,578)},m:function mount(target,anchor){insert_dev(target,div,anchor);append_dev(div,img);append_dev(div,t0);append_dev(div,a);append_dev(a,t1)},p:function update(ctx,dirty){if(dirty&2&&!src_url_equal(img.src,img_src_value=ctx[1].assets+"img/icon/error.svg")){attr_dev(img,"src",img_src_value)}if(dirty&4&&img_alt_value!==(img_alt_value=ctx[2].licence_error)){attr_dev(img,"alt",img_alt_value)}if(dirty&1&&t1_value!==(t1_value=ctx[0].status_description+""))set_data_dev(t1,t1_value);if(dirty&2&&a_href_value!==(a_href_value=ctx[1].licenses)){attr_dev(a,"href",a_href_value)}},d:function destroy(detaching){if(detaching){detach_dev(div)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block$2.name,type:"else",source:"(17:2) {:else}",ctx:ctx});return block}function create_if_block_1$2(ctx){let div;let img;let img_src_value;let img_alt_value;let t0;let a;let t1_value=ctx[0].plan_plus_licence+"";let t1;let a_href_value;let t2;let p;let raw_value=ctx[0].customer+"";const block={c:function create(){div=element("div");img=element("img");t0=space();a=element("a");t1=text(t1_value);t2=space();p=element("p");if(!src_url_equal(img.src,img_src_value=ctx[1].assets+"img/icon/licence-checked.svg"))attr_dev(img,"src",img_src_value);attr_dev(img,"alt",img_alt_value=ctx[2].licence_checked);add_location(img,file$7,12,4,335);attr_dev(a,"href",a_href_value=ctx[1].licenses);attr_dev(a,"class","licence");attr_dev(a,"target","_blank");add_location(a,file$7,13,4,429);attr_dev(div,"class","licence-type");add_location(div,file$7,11,3,304);add_location(p,file$7,15,3,532)},m:function mount(target,anchor){insert_dev(target,div,anchor);append_dev(div,img);append_dev(div,t0);append_dev(div,a);append_dev(a,t1);insert_dev(target,t2,anchor);insert_dev(target,p,anchor);p.innerHTML=raw_value},p:function update(ctx,dirty){if(dirty&2&&!src_url_equal(img.src,img_src_value=ctx[1].assets+"img/icon/licence-checked.svg")){attr_dev(img,"src",img_src_value)}if(dirty&4&&img_alt_value!==(img_alt_value=ctx[2].licence_checked)){attr_dev(img,"alt",img_alt_value)}if(dirty&1&&t1_value!==(t1_value=ctx[0].plan_plus_licence+""))set_data_dev(t1,t1_value);if(dirty&2&&a_href_value!==(a_href_value=ctx[1].licenses)){attr_dev(a,"href",a_href_value)}if(dirty&1&&raw_value!==(raw_value=ctx[0].customer+""))p.innerHTML=raw_value},d:function destroy(detaching){if(detaching){detach_dev(div);detach_dev(t2);detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_1$2.name,type:"if",source:"(11:2) {#if $licence.is_valid}",ctx:ctx});return block}function create_default_slot$3(ctx){let current_block_type_index;let if_block;let if_block_anchor;let current;const if_block_creators=[create_if_block$5,create_else_block_1$1];const if_blocks=[];function select_block_type(ctx,dirty){if(ctx[0].is_set)return 0;return 1}current_block_type_index=select_block_type(ctx);if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);const block={c:function create(){if_block.c();if_block_anchor=empty()},m:function mount(target,anchor){if_blocks[current_block_type_index].m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,dirty){let previous_block_index=current_block_type_index;current_block_type_index=select_block_type(ctx);if(current_block_type_index===previous_block_index){if_blocks[current_block_type_index].p(ctx,dirty)}else{group_outros();transition_out(if_blocks[previous_block_index],1,1,(()=>{if_blocks[previous_block_index]=null}));check_outros();if_block=if_blocks[current_block_type_index];if(!if_block){if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);if_block.c()}else{if_block.p(ctx,dirty)}transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if_blocks[current_block_type_index].d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$3.name,type:"slot",source:"(9:0) <Header>",ctx:ctx});return block}function create_fragment$8(ctx){let header;let current;header=new Header({props:{$$slots:{default:[create_default_slot$3]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(header.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(header,target,anchor);current=true},p:function update(ctx,[dirty]){const header_changes={};if(dirty&23){header_changes.$$scope={dirty:dirty,ctx:ctx}}header.$set(header_changes)},i:function intro(local){if(current)return;transition_in(header.$$.fragment,local);current=true},o:function outro(local){transition_out(header.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(header,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$8.name,type:"component",source:"",ctx:ctx});return block}function instance$8($$self,$$props,$$invalidate){let $licence;let $urls;let $strings;validate_store(licence,"licence");component_subscribe($$self,licence,($$value=>$$invalidate(0,$licence=$$value)));validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(1,$urls=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(2,$strings=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("Header",slots,[]);const writable_props=[];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<Header> was created with unknown prop '${key}'`)}));const click_handler=()=>push("/license");$$self.$capture_state=()=>({push:push,strings:strings,urls:urls,licence:licence,Header:Header,Button:Button,$licence:$licence,$urls:$urls,$strings:$strings});return[$licence,$urls,$strings,click_handler]}class Header_1 extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$8,create_fragment$8,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"Header_1",options:options,id:create_fragment$8.name})}}const file$6="ui/components/NavItem.svelte";function create_fragment$7(ctx){let li;let a;let t_value=ctx[0].title()+"";let t;let a_href_value;let a_title_value;let active_action;let mounted;let dispose;const block={c:function create(){li=element("li");a=element("a");t=text(t_value);attr_dev(a,"href",a_href_value=ctx[0].route);attr_dev(a,"title",a_title_value=ctx[0].title());add_location(a,file$6,11,1,276);attr_dev(li,"class","nav-item");toggle_class(li,"focus",ctx[1]);toggle_class(li,"hover",ctx[2]);add_location(li,file$6,10,0,168)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,li,anchor);append_dev(li,a);append_dev(a,t);if(!mounted){dispose=[action_destroyer(link.call(null,a)),listen_dev(a,"focusin",ctx[3],false,false,false,false),listen_dev(a,"focusout",ctx[4],false,false,false,false),listen_dev(a,"mouseenter",ctx[5],false,false,false,false),listen_dev(a,"mouseleave",ctx[6],false,false,false,false),action_destroyer(active_action=active.call(null,li,ctx[0].routeMatcher?ctx[0].routeMatcher:ctx[0].route))];mounted=true}},p:function update(ctx,[dirty]){if(dirty&1&&t_value!==(t_value=ctx[0].title()+""))set_data_dev(t,t_value);if(dirty&1&&a_href_value!==(a_href_value=ctx[0].route)){attr_dev(a,"href",a_href_value)}if(dirty&1&&a_title_value!==(a_title_value=ctx[0].title())){attr_dev(a,"title",a_title_value)}if(active_action&&is_function(active_action.update)&&dirty&1)active_action.update.call(null,ctx[0].routeMatcher?ctx[0].routeMatcher:ctx[0].route);if(dirty&2){toggle_class(li,"focus",ctx[1])}if(dirty&4){toggle_class(li,"hover",ctx[2])}},i:noop,o:noop,d:function destroy(detaching){if(detaching){detach_dev(li)}mounted=false;run_all(dispose)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$7.name,type:"component",source:"",ctx:ctx});return block}function instance$7($$self,$$props,$$invalidate){let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("NavItem",slots,[]);let{tab:tab}=$$props;let focus=false;let hover=false;$$self.$$.on_mount.push((function(){if(tab===undefined&&!("tab"in $$props||$$self.$$.bound[$$self.$$.props["tab"]])){console.warn("<NavItem> was created without expected prop 'tab'")}}));const writable_props=["tab"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<NavItem> was created with unknown prop '${key}'`)}));const focusin_handler=()=>$$invalidate(1,focus=true);const focusout_handler=()=>$$invalidate(1,focus=false);const mouseenter_handler=()=>$$invalidate(2,hover=true);const mouseleave_handler=()=>$$invalidate(2,hover=false);$$self.$$set=$$props=>{if("tab"in $$props)$$invalidate(0,tab=$$props.tab)};$$self.$capture_state=()=>({link:link,active:active,tab:tab,focus:focus,hover:hover});$$self.$inject_state=$$props=>{if("tab"in $$props)$$invalidate(0,tab=$$props.tab);if("focus"in $$props)$$invalidate(1,focus=$$props.focus);if("hover"in $$props)$$invalidate(2,hover=$$props.hover)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[tab,focus,hover,focusin_handler,focusout_handler,mouseenter_handler,mouseleave_handler]}class NavItem extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$7,create_fragment$7,safe_not_equal,{tab:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"NavItem",options:options,id:create_fragment$7.name})}get tab(){throw new Error("<NavItem>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set tab(value){throw new Error("<NavItem>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$5="ui/components/OffloadStatusFlyout.svelte";const get_footer_slot_changes=dirty=>({});const get_footer_slot_context=ctx=>({});function get_each_context$1(ctx,list,i){const child_ctx=ctx.slice();child_ctx[21]=list[i];return child_ctx}function create_if_block$4(ctx){let panel;let updating_ref;let current;function panel_ref_binding(value){ctx[19](value)}let panel_props={multi:true,flyout:true,refresh:true,refreshing:ctx[3],heading:ctx[4].offload_status_title,refreshDesc:ctx[4].refresh_media_counts_desc,$$slots:{default:[create_default_slot$2]},$$scope:{ctx:ctx}};if(ctx[2]!==void 0){panel_props.ref=ctx[2]}panel=new Panel({props:panel_props,$$inline:true});binding_callbacks.push((()=>bind(panel,"ref",panel_ref_binding)));panel.$on("focusout",ctx[12]);panel.$on("mouseenter",ctx[9]);panel.$on("mouseleave",ctx[10]);panel.$on("mousedown",ctx[9]);panel.$on("click",ctx[11]);panel.$on("cancel",ctx[13]);panel.$on("refresh",ctx[14]);const block={c:function create(){create_component(panel.$$.fragment)},m:function mount(target,anchor){mount_component(panel,target,anchor);current=true},p:function update(ctx,dirty){const panel_changes={};if(dirty&8)panel_changes.refreshing=ctx[3];if(dirty&16)panel_changes.heading=ctx[4].offload_status_title;if(dirty&16)panel_changes.refreshDesc=ctx[4].refresh_media_counts_desc;if(dirty&1049072){panel_changes.$$scope={dirty:dirty,ctx:ctx}}if(!updating_ref&&dirty&4){updating_ref=true;panel_changes.ref=ctx[2];add_flush_callback((()=>updating_ref=false))}panel.$set(panel_changes)},i:function intro(local){if(current)return;transition_in(panel.$$.fragment,local);current=true},o:function outro(local){transition_out(panel.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panel,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$4.name,type:"if",source:"(118:0) {#if expanded}",ctx:ctx});return block}function create_else_block_1(ctx){let td;let t_value=numToString(ctx[21].offloaded)+"";let t;const block={c:function create(){td=element("td");t=text(t_value);attr_dev(td,"class","numeric");add_location(td,file$5,153,7,3402)},m:function mount(target,anchor){insert_dev(target,td,anchor);append_dev(td,t)},p:function update(ctx,dirty){if(dirty&32&&t_value!==(t_value=numToString(ctx[21].offloaded)+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(td)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block_1.name,type:"else",source:"(153:6) {:else}",ctx:ctx});return block}function create_if_block_4(ctx){let td;let a;let t_value=numToString(ctx[21].offloaded)+"";let t;let a_href_value;const block={c:function create(){td=element("td");a=element("a");t=text(t_value);attr_dev(a,"href",a_href_value=ctx[21].offloaded_url);add_location(a,file$5,150,8,3295);attr_dev(td,"class","numeric");add_location(td,file$5,149,7,3266)},m:function mount(target,anchor){insert_dev(target,td,anchor);append_dev(td,a);append_dev(a,t)},p:function update(ctx,dirty){if(dirty&32&&t_value!==(t_value=numToString(ctx[21].offloaded)+""))set_data_dev(t,t_value);if(dirty&32&&a_href_value!==(a_href_value=ctx[21].offloaded_url)){attr_dev(a,"href",a_href_value)}},d:function destroy(detaching){if(detaching){detach_dev(td)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_4.name,type:"if",source:"(149:6) {#if summary.offloaded_url}",ctx:ctx});return block}function create_else_block$1(ctx){let td;let t_value=numToString(ctx[21].not_offloaded)+"";let t;const block={c:function create(){td=element("td");t=text(t_value);attr_dev(td,"class","numeric");add_location(td,file$5,160,7,3663)},m:function mount(target,anchor){insert_dev(target,td,anchor);append_dev(td,t)},p:function update(ctx,dirty){if(dirty&32&&t_value!==(t_value=numToString(ctx[21].not_offloaded)+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(td)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block$1.name,type:"else",source:"(160:6) {:else}",ctx:ctx});return block}function create_if_block_3(ctx){let td;let a;let t_value=numToString(ctx[21].not_offloaded)+"";let t;let a_href_value;const block={c:function create(){td=element("td");a=element("a");t=text(t_value);attr_dev(a,"href",a_href_value=ctx[21].not_offloaded_url);add_location(a,file$5,157,8,3548);attr_dev(td,"class","numeric");add_location(td,file$5,156,7,3519)},m:function mount(target,anchor){insert_dev(target,td,anchor);append_dev(td,a);append_dev(a,t)},p:function update(ctx,dirty){if(dirty&32&&t_value!==(t_value=numToString(ctx[21].not_offloaded)+""))set_data_dev(t,t_value);if(dirty&32&&a_href_value!==(a_href_value=ctx[21].not_offloaded_url)){attr_dev(a,"href",a_href_value)}},d:function destroy(detaching){if(detaching){detach_dev(td)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_3.name,type:"if",source:"(156:6) {#if summary.not_offloaded_url}",ctx:ctx});return block}function create_each_block$1(key_1,ctx){let tr;let td;let t0_value=ctx[21].name+"";let t0;let t1;let t2;let t3;function select_block_type(ctx,dirty){if(ctx[21].offloaded_url)return create_if_block_4;return create_else_block_1}let current_block_type=select_block_type(ctx);let if_block0=current_block_type(ctx);function select_block_type_1(ctx,dirty){if(ctx[21].not_offloaded_url)return create_if_block_3;return create_else_block$1}let current_block_type_1=select_block_type_1(ctx);let if_block1=current_block_type_1(ctx);const block={key:key_1,first:null,c:function create(){tr=element("tr");td=element("td");t0=text(t0_value);t1=space();if_block0.c();t2=space();if_block1.c();t3=space();add_location(td,file$5,147,6,3201);add_location(tr,file$5,146,5,3190);this.first=tr},m:function mount(target,anchor){insert_dev(target,tr,anchor);append_dev(tr,td);append_dev(td,t0);append_dev(tr,t1);if_block0.m(tr,null);append_dev(tr,t2);if_block1.m(tr,null);append_dev(tr,t3)},p:function update(new_ctx,dirty){ctx=new_ctx;if(dirty&32&&t0_value!==(t0_value=ctx[21].name+""))set_data_dev(t0,t0_value);if(current_block_type===(current_block_type=select_block_type(ctx))&&if_block0){if_block0.p(ctx,dirty)}else{if_block0.d(1);if_block0=current_block_type(ctx);if(if_block0){if_block0.c();if_block0.m(tr,t2)}}if(current_block_type_1===(current_block_type_1=select_block_type_1(ctx))&&if_block1){if_block1.p(ctx,dirty)}else{if_block1.d(1);if_block1=current_block_type_1(ctx);if(if_block1){if_block1.c();if_block1.m(tr,t3)}}},d:function destroy(detaching){if(detaching){detach_dev(tr)}if_block0.d();if_block1.d()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_each_block$1.name,type:"each",source:"(146:4) {#each $summaryCounts as summary (summary.type)}",ctx:ctx});return block}function create_if_block_2$1(ctx){let tfoot;let tr;let td0;let t0_value=ctx[4].summary_total_row_title+"";let t0;let t1;let td1;let t2_value=numToString(ctx[6].offloaded)+"";let t2;let t3;let td2;let t4_value=numToString(ctx[6].not_offloaded)+"";let t4;const block={c:function create(){tfoot=element("tfoot");tr=element("tr");td0=element("td");t0=text(t0_value);t1=space();td1=element("td");t2=text(t2_value);t3=space();td2=element("td");t4=text(t4_value);add_location(td0,file$5,169,6,3841);attr_dev(td1,"class","numeric");add_location(td1,file$5,170,6,3891);attr_dev(td2,"class","numeric");add_location(td2,file$5,171,6,3957);add_location(tr,file$5,168,5,3830);add_location(tfoot,file$5,167,5,3817)},m:function mount(target,anchor){insert_dev(target,tfoot,anchor);append_dev(tfoot,tr);append_dev(tr,td0);append_dev(td0,t0);append_dev(tr,t1);append_dev(tr,td1);append_dev(td1,t2);append_dev(tr,t3);append_dev(tr,td2);append_dev(td2,t4)},p:function update(ctx,dirty){if(dirty&16&&t0_value!==(t0_value=ctx[4].summary_total_row_title+""))set_data_dev(t0,t0_value);if(dirty&64&&t2_value!==(t2_value=numToString(ctx[6].offloaded)+""))set_data_dev(t2,t2_value);if(dirty&64&&t4_value!==(t4_value=numToString(ctx[6].not_offloaded)+""))set_data_dev(t4,t4_value)},d:function destroy(detaching){if(detaching){detach_dev(tfoot)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_2$1.name,type:"if",source:"(167:4) {#if $summaryCounts.length > 1}",ctx:ctx});return block}function create_default_slot_2$1(ctx){let table;let thead;let tr;let th0;let t0_value=ctx[4].summary_type_title+"";let t0;let t1;let th1;let t2_value=ctx[4].summary_offloaded_title+"";let t2;let t3;let th2;let t4_value=ctx[4].summary_not_offloaded_title+"";let t4;let t5;let tbody;let each_blocks=[];let each_1_lookup=new Map;let t6;let each_value=ensure_array_like_dev(ctx[5]);const get_key=ctx=>ctx[21].type;validate_each_keys(ctx,each_value,get_each_context$1,get_key);for(let i=0;i<each_value.length;i+=1){let child_ctx=get_each_context$1(ctx,each_value,i);let key=get_key(child_ctx);each_1_lookup.set(key,each_blocks[i]=create_each_block$1(key,child_ctx))}let if_block=ctx[5].length>1&&create_if_block_2$1(ctx);const block={c:function create(){table=element("table");thead=element("thead");tr=element("tr");th0=element("th");t0=text(t0_value);t1=space();th1=element("th");t2=text(t2_value);t3=space();th2=element("th");t4=text(t4_value);t5=space();tbody=element("tbody");for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].c()}t6=space();if(if_block)if_block.c();add_location(th0,file$5,138,5,2923);attr_dev(th1,"class","numeric");add_location(th1,file$5,139,5,2967);attr_dev(th2,"class","numeric");add_location(th2,file$5,140,5,3032);add_location(tr,file$5,137,4,2913);add_location(thead,file$5,136,4,2901);add_location(tbody,file$5,144,4,3124);add_location(table,file$5,135,3,2889)},m:function mount(target,anchor){insert_dev(target,table,anchor);append_dev(table,thead);append_dev(thead,tr);append_dev(tr,th0);append_dev(th0,t0);append_dev(tr,t1);append_dev(tr,th1);append_dev(th1,t2);append_dev(tr,t3);append_dev(tr,th2);append_dev(th2,t4);append_dev(table,t5);append_dev(table,tbody);for(let i=0;i<each_blocks.length;i+=1){if(each_blocks[i]){each_blocks[i].m(tbody,null)}}append_dev(table,t6);if(if_block)if_block.m(table,null)},p:function update(ctx,dirty){if(dirty&16&&t0_value!==(t0_value=ctx[4].summary_type_title+""))set_data_dev(t0,t0_value);if(dirty&16&&t2_value!==(t2_value=ctx[4].summary_offloaded_title+""))set_data_dev(t2,t2_value);if(dirty&16&&t4_value!==(t4_value=ctx[4].summary_not_offloaded_title+""))set_data_dev(t4,t4_value);if(dirty&32){each_value=ensure_array_like_dev(ctx[5]);validate_each_keys(ctx,each_value,get_each_context$1,get_key);each_blocks=update_keyed_each(each_blocks,dirty,get_key,1,ctx,each_value,each_1_lookup,tbody,destroy_block,create_each_block$1,null,get_each_context$1)}if(ctx[5].length>1){if(if_block){if_block.p(ctx,dirty)}else{if_block=create_if_block_2$1(ctx);if_block.c();if_block.m(table,null)}}else if(if_block){if_block.d(1);if_block=null}},d:function destroy(detaching){if(detaching){detach_dev(table)}for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].d()}if(if_block)if_block.d()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_2$1.name,type:"slot",source:'(135:2) <PanelRow class=\\"summary\\">',ctx:ctx});return block}function create_if_block_1$1(ctx){let p;const block={c:function create(){p=element("p");add_location(p,file$5,181,5,4181)},m:function mount(target,anchor){insert_dev(target,p,anchor);p.innerHTML=ctx[7]},p:function update(ctx,dirty){if(dirty&128)p.innerHTML=ctx[7]},d:function destroy(detaching){if(detaching){detach_dev(p)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_1$1.name,type:"if",source:"(181:4) {#if $offloadRemainingUpsell}",ctx:ctx});return block}function create_default_slot_1$1(ctx){let t0;let a;let img;let img_src_value;let t1;let t2_value=ctx[4].offload_remaining_upsell_cta+"";let t2;let a_href_value;let if_block=ctx[7]&&create_if_block_1$1(ctx);const block={c:function create(){if(if_block)if_block.c();t0=space();a=element("a");img=element("img");t1=space();t2=text(t2_value);if(!src_url_equal(img.src,img_src_value=ctx[8].assets+"img/icon/stars.svg"))attr_dev(img,"src",img_src_value);attr_dev(img,"alt","stars icon");set_style(img,"margin-right","5px");add_location(img,file$5,184,5,4330);attr_dev(a,"href",a_href_value=ctx[8].upsell_discount);attr_dev(a,"class","button btn-sm btn-primary licence");attr_dev(a,"target","_blank");add_location(a,file$5,183,4,4234)},m:function mount(target,anchor){if(if_block)if_block.m(target,anchor);insert_dev(target,t0,anchor);insert_dev(target,a,anchor);append_dev(a,img);append_dev(a,t1);append_dev(a,t2)},p:function update(ctx,dirty){if(ctx[7]){if(if_block){if_block.p(ctx,dirty)}else{if_block=create_if_block_1$1(ctx);if_block.c();if_block.m(t0.parentNode,t0)}}else if(if_block){if_block.d(1);if_block=null}if(dirty&256&&!src_url_equal(img.src,img_src_value=ctx[8].assets+"img/icon/stars.svg")){attr_dev(img,"src",img_src_value)}if(dirty&16&&t2_value!==(t2_value=ctx[4].offload_remaining_upsell_cta+""))set_data_dev(t2,t2_value);if(dirty&256&&a_href_value!==(a_href_value=ctx[8].upsell_discount)){attr_dev(a,"href",a_href_value)}},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(a)}if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1$1.name,type:"slot",source:'(180:3) <PanelRow footer class=\\"upsell\\">',ctx:ctx});return block}function fallback_block$2(ctx){let panelrow;let current;panelrow=new PanelRow({props:{footer:true,class:"upsell",$$slots:{default:[create_default_slot_1$1]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow,target,anchor);current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty&1048976){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes)},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(panelrow,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:fallback_block$2.name,type:"fallback",source:"(179:22) ",ctx:ctx});return block}function create_default_slot$2(ctx){let panelrow;let t;let current;panelrow=new PanelRow({props:{class:"summary",$$slots:{default:[create_default_slot_2$1]},$$scope:{ctx:ctx}},$$inline:true});const footer_slot_template=ctx[16].footer;const footer_slot=create_slot(footer_slot_template,ctx,ctx[20],get_footer_slot_context);const footer_slot_or_fallback=footer_slot||fallback_block$2(ctx);const block={c:function create(){create_component(panelrow.$$.fragment);t=space();if(footer_slot_or_fallback)footer_slot_or_fallback.c()},m:function mount(target,anchor){mount_component(panelrow,target,anchor);insert_dev(target,t,anchor);if(footer_slot_or_fallback){footer_slot_or_fallback.m(target,anchor)}current=true},p:function update(ctx,dirty){const panelrow_changes={};if(dirty&1048688){panelrow_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow.$set(panelrow_changes);if(footer_slot){if(footer_slot.p&&(!current||dirty&1048576)){update_slot_base(footer_slot,footer_slot_template,ctx,ctx[20],!current?get_all_dirty_from_scope(ctx[20]):get_slot_changes(footer_slot_template,ctx[20],dirty,get_footer_slot_changes),get_footer_slot_context)}}else{if(footer_slot_or_fallback&&footer_slot_or_fallback.p&&(!current||dirty&400)){footer_slot_or_fallback.p(ctx,!current?-1:dirty)}}},i:function intro(local){if(current)return;transition_in(panelrow.$$.fragment,local);transition_in(footer_slot_or_fallback,local);current=true},o:function outro(local){transition_out(panelrow.$$.fragment,local);transition_out(footer_slot_or_fallback,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t)}destroy_component(panelrow,detaching);if(footer_slot_or_fallback)footer_slot_or_fallback.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$2.name,type:"slot",source:"(119:1) <Panel multi flyout refresh {refreshing} heading={$strings.offload_status_title} refreshDesc={$strings.refresh_media_counts_desc} bind:ref={panelRef} on:focusout={handleFocusOut} on:mouseenter={handleMouseEnter} on:mouseleave={handleMouseLeave} on:mousedown={handleMouseEnter} on:click={handlePanelClick} on:cancel={handleCancel} on:refresh={handleRefresh} >",ctx:ctx});return block}function create_fragment$6(ctx){let button;let updating_ref;let t;let if_block_anchor;let current;function button_ref_binding(value){ctx[17](value)}let button_props={expandable:true,expanded:ctx[0],title:ctx[0]?ctx[4].hide_details:ctx[4].show_details};if(ctx[1]!==void 0){button_props.ref=ctx[1]}button=new Button({props:button_props,$$inline:true});binding_callbacks.push((()=>bind(button,"ref",button_ref_binding)));button.$on("click",ctx[18]);button.$on("focusout",ctx[12]);button.$on("cancel",ctx[13]);let if_block=ctx[0]&&create_if_block$4(ctx);const block={c:function create(){create_component(button.$$.fragment);t=space();if(if_block)if_block.c();if_block_anchor=empty()},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(button,target,anchor);insert_dev(target,t,anchor);if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,[dirty]){const button_changes={};if(dirty&1)button_changes.expanded=ctx[0];if(dirty&17)button_changes.title=ctx[0]?ctx[4].hide_details:ctx[4].show_details;if(!updating_ref&&dirty&2){updating_ref=true;button_changes.ref=ctx[1];add_flush_callback((()=>updating_ref=false))}button.$set(button_changes);if(ctx[0]){if(if_block){if_block.p(ctx,dirty);if(dirty&1){transition_in(if_block,1)}}else{if_block=create_if_block$4(ctx);if_block.c();transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(button.$$.fragment,local);transition_in(if_block);current=true},o:function outro(local){transition_out(button.$$.fragment,local);transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(t);detach_dev(if_block_anchor)}destroy_component(button,detaching);if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$6.name,type:"component",source:"",ctx:ctx});return block}function instance$6($$self,$$props,$$invalidate){let $strings;let $summaryCounts;let $counts;let $offloadRemainingUpsell;let $urls;validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(4,$strings=$$value)));validate_store(summaryCounts,"summaryCounts");component_subscribe($$self,summaryCounts,($$value=>$$invalidate(5,$summaryCounts=$$value)));validate_store(counts,"counts");component_subscribe($$self,counts,($$value=>$$invalidate(6,$counts=$$value)));validate_store(offloadRemainingUpsell,"offloadRemainingUpsell");component_subscribe($$self,offloadRemainingUpsell,($$value=>$$invalidate(7,$offloadRemainingUpsell=$$value)));validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(8,$urls=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("OffloadStatusFlyout",slots,["footer"]);let{expanded:expanded=false}=$$props;let{buttonRef:buttonRef={}}=$$props;let{panelRef:panelRef={}}=$$props;let{hasFocus:hasFocus=false}=$$props;let{refreshing:refreshing=false}=$$props;function handleMouseEnter(){$$invalidate(15,hasFocus=true)}function handleMouseLeave(){$$invalidate(15,hasFocus=false)}function handlePanelClick(){$$invalidate(15,hasFocus=true);const firstFocusable=panelRef.querySelector("a:not([tabindex='-1']),button:not([tabindex='-1'])");if(firstFocusable){firstFocusable.focus()}}function handleFocusOut(event){if(!expanded){return false}if(event.relatedTarget===null&&!hasFocus){$$invalidate(0,expanded=false)}if(event.relatedTarget!==null&&event.relatedTarget!==buttonRef&&!panelRef.contains(event.relatedTarget)){$$invalidate(0,expanded=false)}}function handleCancel(){buttonRef.focus();$$invalidate(0,expanded=false)}async function handleRefresh(){let start=Date.now();$$invalidate(3,refreshing=true);let params={refreshMediaCounts:true};let json=await api.get("state",params);await delayMin(start,1e3);state.updateState(json);$$invalidate(3,refreshing=false);buttonRef.focus()}const writable_props=["expanded","buttonRef","panelRef","hasFocus","refreshing"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<OffloadStatusFlyout> was created with unknown prop '${key}'`)}));function button_ref_binding(value){buttonRef=value;$$invalidate(1,buttonRef)}const click_handler=()=>$$invalidate(0,expanded=!expanded);function panel_ref_binding(value){panelRef=value;$$invalidate(2,panelRef)}$$self.$$set=$$props=>{if("expanded"in $$props)$$invalidate(0,expanded=$$props.expanded);if("buttonRef"in $$props)$$invalidate(1,buttonRef=$$props.buttonRef);if("panelRef"in $$props)$$invalidate(2,panelRef=$$props.panelRef);if("hasFocus"in $$props)$$invalidate(15,hasFocus=$$props.hasFocus);if("refreshing"in $$props)$$invalidate(3,refreshing=$$props.refreshing);if("$$scope"in $$props)$$invalidate(20,$$scope=$$props.$$scope)};$$self.$capture_state=()=>({counts:counts,offloadRemainingUpsell:offloadRemainingUpsell,summaryCounts:summaryCounts,strings:strings,urls:urls,api:api,state:state,numToString:numToString,delayMin:delayMin,Button:Button,Panel:Panel,PanelRow:PanelRow,expanded:expanded,buttonRef:buttonRef,panelRef:panelRef,hasFocus:hasFocus,refreshing:refreshing,handleMouseEnter:handleMouseEnter,handleMouseLeave:handleMouseLeave,handlePanelClick:handlePanelClick,handleFocusOut:handleFocusOut,handleCancel:handleCancel,handleRefresh:handleRefresh,$strings:$strings,$summaryCounts:$summaryCounts,$counts:$counts,$offloadRemainingUpsell:$offloadRemainingUpsell,$urls:$urls});$$self.$inject_state=$$props=>{if("expanded"in $$props)$$invalidate(0,expanded=$$props.expanded);if("buttonRef"in $$props)$$invalidate(1,buttonRef=$$props.buttonRef);if("panelRef"in $$props)$$invalidate(2,panelRef=$$props.panelRef);if("hasFocus"in $$props)$$invalidate(15,hasFocus=$$props.hasFocus);if("refreshing"in $$props)$$invalidate(3,refreshing=$$props.refreshing)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}return[expanded,buttonRef,panelRef,refreshing,$strings,$summaryCounts,$counts,$offloadRemainingUpsell,$urls,handleMouseEnter,handleMouseLeave,handlePanelClick,handleFocusOut,handleCancel,handleRefresh,hasFocus,slots,button_ref_binding,click_handler,panel_ref_binding,$$scope]}class OffloadStatusFlyout extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$6,create_fragment$6,safe_not_equal,{expanded:0,buttonRef:1,panelRef:2,hasFocus:15,refreshing:3});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"OffloadStatusFlyout",options:options,id:create_fragment$6.name})}get expanded(){throw new Error("<OffloadStatusFlyout>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set expanded(value){throw new Error("<OffloadStatusFlyout>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get buttonRef(){throw new Error("<OffloadStatusFlyout>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set buttonRef(value){throw new Error("<OffloadStatusFlyout>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get panelRef(){throw new Error("<OffloadStatusFlyout>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set panelRef(value){throw new Error("<OffloadStatusFlyout>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get hasFocus(){throw new Error("<OffloadStatusFlyout>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set hasFocus(value){throw new Error("<OffloadStatusFlyout>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get refreshing(){throw new Error("<OffloadStatusFlyout>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set refreshing(value){throw new Error("<OffloadStatusFlyout>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$4="ui/components/OffloadStatus.svelte";const get_flyout_slot_changes=dirty=>({});const get_flyout_slot_context=ctx=>({});function create_if_block$3(ctx){let img;let img_src_value;const block={c:function create(){img=element("img");attr_dev(img,"class","icon type");if(!src_url_equal(img.src,img_src_value=ctx[7].assets+"img/icon/licence-checked.svg"))attr_dev(img,"src",img_src_value);attr_dev(img,"alt",ctx[5]);attr_dev(img,"title",ctx[5]);add_location(img,file$4,91,3,2209)},m:function mount(target,anchor){insert_dev(target,img,anchor)},p:function update(ctx,dirty){if(dirty&128&&!src_url_equal(img.src,img_src_value=ctx[7].assets+"img/icon/licence-checked.svg")){attr_dev(img,"src",img_src_value)}if(dirty&32){attr_dev(img,"alt",ctx[5])}if(dirty&32){attr_dev(img,"title",ctx[5])}},d:function destroy(detaching){if(detaching){detach_dev(img)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$3.name,type:"if",source:"(91:2) {#if complete}",ctx:ctx});return block}function fallback_block$1(ctx){let offloadstatusflyout;let updating_expanded;let updating_hasFocus;let updating_buttonRef;let current;function offloadstatusflyout_expanded_binding(value){ctx[14](value)}function offloadstatusflyout_hasFocus_binding(value){ctx[15](value)}function offloadstatusflyout_buttonRef_binding(value){ctx[16](value)}let offloadstatusflyout_props={};if(ctx[0]!==void 0){offloadstatusflyout_props.expanded=ctx[0]}if(ctx[2]!==void 0){offloadstatusflyout_props.hasFocus=ctx[2]}if(ctx[1]!==void 0){offloadstatusflyout_props.buttonRef=ctx[1]}offloadstatusflyout=new OffloadStatusFlyout({props:offloadstatusflyout_props,$$inline:true});binding_callbacks.push((()=>bind(offloadstatusflyout,"expanded",offloadstatusflyout_expanded_binding)));binding_callbacks.push((()=>bind(offloadstatusflyout,"hasFocus",offloadstatusflyout_hasFocus_binding)));binding_callbacks.push((()=>bind(offloadstatusflyout,"buttonRef",offloadstatusflyout_buttonRef_binding)));const block={c:function create(){create_component(offloadstatusflyout.$$.fragment)},m:function mount(target,anchor){mount_component(offloadstatusflyout,target,anchor);current=true},p:function update(ctx,dirty){const offloadstatusflyout_changes={};if(!updating_expanded&&dirty&1){updating_expanded=true;offloadstatusflyout_changes.expanded=ctx[0];add_flush_callback((()=>updating_expanded=false))}if(!updating_hasFocus&&dirty&4){updating_hasFocus=true;offloadstatusflyout_changes.hasFocus=ctx[2];add_flush_callback((()=>updating_hasFocus=false))}if(!updating_buttonRef&&dirty&2){updating_buttonRef=true;offloadstatusflyout_changes.buttonRef=ctx[1];add_flush_callback((()=>updating_buttonRef=false))}offloadstatusflyout.$set(offloadstatusflyout_changes)},i:function intro(local){if(current)return;transition_in(offloadstatusflyout.$$.fragment,local);current=true},o:function outro(local){transition_out(offloadstatusflyout.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(offloadstatusflyout,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:fallback_block$1.name,type:"fallback",source:"(111:21) ",ctx:ctx});return block}function create_fragment$5(ctx){let div1;let div0;let t0;let p;let strong;let t1;let t2;let t3;let span;let raw_value=ctx[4].offloaded+"";let t4;let progressbar;let t5;let current;let mounted;let dispose;let if_block=ctx[6]&&create_if_block$3(ctx);progressbar=new ProgressBar({props:{percentComplete:ctx[3],title:ctx[5]},$$inline:true});const flyout_slot_template=ctx[13].flyout;const flyout_slot=create_slot(flyout_slot_template,ctx,ctx[12],get_flyout_slot_context);const flyout_slot_or_fallback=flyout_slot||fallback_block$1(ctx);const block={c:function create(){div1=element("div");div0=element("div");if(if_block)if_block.c();t0=space();p=element("p");strong=element("strong");t1=text(ctx[3]);t2=text("%");t3=space();span=element("span");t4=space();create_component(progressbar.$$.fragment);t5=space();if(flyout_slot_or_fallback)flyout_slot_or_fallback.c();add_location(strong,file$4,102,3,2382);add_location(span,file$4,103,3,2421);attr_dev(p,"class","status-text");attr_dev(p,"title",ctx[5]);add_location(p,file$4,98,2,2338);attr_dev(div0,"class","nav-status");attr_dev(div0,"title",ctx[5]);add_location(div0,file$4,83,1,2040);attr_dev(div1,"class","nav-status-wrapper svelte-1i784er");toggle_class(div1,"complete",ctx[6]);add_location(div1,file$4,80,0,1907)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,div1,anchor);append_dev(div1,div0);if(if_block)if_block.m(div0,null);append_dev(div0,t0);append_dev(div0,p);append_dev(p,strong);append_dev(strong,t1);append_dev(strong,t2);append_dev(p,t3);append_dev(p,span);span.innerHTML=raw_value;append_dev(div0,t4);mount_component(progressbar,div0,null);append_dev(div1,t5);if(flyout_slot_or_fallback){flyout_slot_or_fallback.m(div1,null)}current=true;if(!mounted){dispose=[listen_dev(div0,"click",prevent_default(ctx[8]),false,true,false,false),listen_dev(div0,"mouseenter",ctx[9],false,false,false,false),listen_dev(div0,"mouseleave",ctx[10],false,false,false,false)];mounted=true}},p:function update(ctx,[dirty]){if(ctx[6]){if(if_block){if_block.p(ctx,dirty)}else{if_block=create_if_block$3(ctx);if_block.c();if_block.m(div0,t0)}}else if(if_block){if_block.d(1);if_block=null}if(!current||dirty&8)set_data_dev(t1,ctx[3]);if((!current||dirty&16)&&raw_value!==(raw_value=ctx[4].offloaded+""))span.innerHTML=raw_value;if(!current||dirty&32){attr_dev(p,"title",ctx[5])}const progressbar_changes={};if(dirty&8)progressbar_changes.percentComplete=ctx[3];if(dirty&32)progressbar_changes.title=ctx[5];progressbar.$set(progressbar_changes);if(!current||dirty&32){attr_dev(div0,"title",ctx[5])}if(flyout_slot){if(flyout_slot.p&&(!current||dirty&4096)){update_slot_base(flyout_slot,flyout_slot_template,ctx,ctx[12],!current?get_all_dirty_from_scope(ctx[12]):get_slot_changes(flyout_slot_template,ctx[12],dirty,get_flyout_slot_changes),get_flyout_slot_context)}}else{if(flyout_slot_or_fallback&&flyout_slot_or_fallback.p&&(!current||dirty&7)){flyout_slot_or_fallback.p(ctx,!current?-1:dirty)}}if(!current||dirty&64){toggle_class(div1,"complete",ctx[6])}},i:function intro(local){if(current)return;transition_in(progressbar.$$.fragment,local);transition_in(flyout_slot_or_fallback,local);current=true},o:function outro(local){transition_out(progressbar.$$.fragment,local);transition_out(flyout_slot_or_fallback,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(div1)}if(if_block)if_block.d();destroy_component(progressbar);if(flyout_slot_or_fallback)flyout_slot_or_fallback.d(detaching);mounted=false;run_all(dispose)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$5.name,type:"component",source:"",ctx:ctx});return block}function getPercentComplete(total,offloaded){if(total<1||offloaded<1){return 0}const percent=Math.floor(Math.abs(offloaded/total*100));if(percent>100){return 100}return percent}function instance$5($$self,$$props,$$invalidate){let percentComplete;let complete;let title;let $strings;let $counts;let $urls;validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(4,$strings=$$value)));validate_store(counts,"counts");component_subscribe($$self,counts,($$value=>$$invalidate(11,$counts=$$value)));validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(7,$urls=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("OffloadStatus",slots,["flyout"]);let{expanded:expanded=false}=$$props;let{flyoutButton:flyoutButton={}}=$$props;let{hasFocus:hasFocus=false}=$$props;function getTitle(percent,total,offloaded,description){return percent+"% ("+numToString(offloaded)+"/"+numToString(total)+") "+description}function handleClick(){$$invalidate(0,expanded=!expanded);flyoutButton.focus();return true}function handleMouseEnter(){$$invalidate(2,hasFocus=true)}function handleMouseLeave(){$$invalidate(2,hasFocus=false)}const writable_props=["expanded","flyoutButton","hasFocus"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<OffloadStatus> was created with unknown prop '${key}'`)}));function offloadstatusflyout_expanded_binding(value){expanded=value;$$invalidate(0,expanded)}function offloadstatusflyout_hasFocus_binding(value){hasFocus=value;$$invalidate(2,hasFocus)}function offloadstatusflyout_buttonRef_binding(value){flyoutButton=value;$$invalidate(1,flyoutButton)}$$self.$$set=$$props=>{if("expanded"in $$props)$$invalidate(0,expanded=$$props.expanded);if("flyoutButton"in $$props)$$invalidate(1,flyoutButton=$$props.flyoutButton);if("hasFocus"in $$props)$$invalidate(2,hasFocus=$$props.hasFocus);if("$$scope"in $$props)$$invalidate(12,$$scope=$$props.$$scope)};$$self.$capture_state=()=>({counts:counts,strings:strings,urls:urls,numToString:numToString,ProgressBar:ProgressBar,OffloadStatusFlyout:OffloadStatusFlyout,expanded:expanded,flyoutButton:flyoutButton,hasFocus:hasFocus,getPercentComplete:getPercentComplete,getTitle:getTitle,handleClick:handleClick,handleMouseEnter:handleMouseEnter,handleMouseLeave:handleMouseLeave,percentComplete:percentComplete,title:title,complete:complete,$strings:$strings,$counts:$counts,$urls:$urls});$$self.$inject_state=$$props=>{if("expanded"in $$props)$$invalidate(0,expanded=$$props.expanded);if("flyoutButton"in $$props)$$invalidate(1,flyoutButton=$$props.flyoutButton);if("hasFocus"in $$props)$$invalidate(2,hasFocus=$$props.hasFocus);if("percentComplete"in $$props)$$invalidate(3,percentComplete=$$props.percentComplete);if("title"in $$props)$$invalidate(5,title=$$props.title);if("complete"in $$props)$$invalidate(6,complete=$$props.complete)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty&2048){$$invalidate(3,percentComplete=getPercentComplete($counts.total,$counts.offloaded))}if($$self.$$.dirty&8){$$invalidate(6,complete=percentComplete>=100)}if($$self.$$.dirty&2072){$$invalidate(5,title=getTitle(percentComplete,$counts.total,$counts.offloaded,$strings.offloaded))}};return[expanded,flyoutButton,hasFocus,percentComplete,$strings,title,complete,$urls,handleClick,handleMouseEnter,handleMouseLeave,$counts,$$scope,slots,offloadstatusflyout_expanded_binding,offloadstatusflyout_hasFocus_binding,offloadstatusflyout_buttonRef_binding]}class OffloadStatus extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$5,create_fragment$5,safe_not_equal,{expanded:0,flyoutButton:1,hasFocus:2});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"OffloadStatus",options:options,id:create_fragment$5.name})}get expanded(){throw new Error("<OffloadStatus>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set expanded(value){throw new Error("<OffloadStatus>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get flyoutButton(){throw new Error("<OffloadStatus>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set flyoutButton(value){throw new Error("<OffloadStatus>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}get hasFocus(){throw new Error("<OffloadStatus>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set hasFocus(value){throw new Error("<OffloadStatus>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}const file$3="ui/components/Nav.svelte";function get_each_context(ctx,list,i){const child_ctx=ctx.slice();child_ctx[3]=list[i];return child_ctx}function create_if_block$2(ctx){let navitem;let current;navitem=new NavItem({props:{tab:ctx[3]},$$inline:true});const block={c:function create(){create_component(navitem.$$.fragment)},m:function mount(target,anchor){mount_component(navitem,target,anchor);current=true},p:function update(ctx,dirty){const navitem_changes={};if(dirty&1)navitem_changes.tab=ctx[3];navitem.$set(navitem_changes)},i:function intro(local){if(current)return;transition_in(navitem.$$.fragment,local);current=true},o:function outro(local){transition_out(navitem.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(navitem,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$2.name,type:"if",source:"(11:4) {#if tab.nav && tab.title}",ctx:ctx});return block}function create_each_block(key_1,ctx){let first;let if_block_anchor;let current;let if_block=ctx[3].nav&&ctx[3].title&&create_if_block$2(ctx);const block={key:key_1,first:null,c:function create(){first=empty();if(if_block)if_block.c();if_block_anchor=empty();this.first=first},m:function mount(target,anchor){insert_dev(target,first,anchor);if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(new_ctx,dirty){ctx=new_ctx;if(ctx[3].nav&&ctx[3].title){if(if_block){if_block.p(ctx,dirty);if(dirty&1){transition_in(if_block,1)}}else{if_block=create_if_block$2(ctx);if_block.c();transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(first);detach_dev(if_block_anchor)}if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_each_block.name,type:"each",source:"(10:3) {#each $pages as tab (tab.position)}",ctx:ctx});return block}function fallback_block(ctx){let offloadstatus;let current;offloadstatus=new OffloadStatus({$$inline:true});const block={c:function create(){create_component(offloadstatus.$$.fragment)},m:function mount(target,anchor){mount_component(offloadstatus,target,anchor);current=true},i:function intro(local){if(current)return;transition_in(offloadstatus.$$.fragment,local);current=true},o:function outro(local){transition_out(offloadstatus.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(offloadstatus,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:fallback_block.name,type:"fallback",source:"(16:8) ",ctx:ctx});return block}function create_fragment$4(ctx){let div1;let div0;let ul;let each_blocks=[];let each_1_lookup=new Map;let t;let current;let each_value=ensure_array_like_dev(ctx[0]);const get_key=ctx=>ctx[3].position;validate_each_keys(ctx,each_value,get_each_context,get_key);for(let i=0;i<each_value.length;i+=1){let child_ctx=get_each_context(ctx,each_value,i);let key=get_key(child_ctx);each_1_lookup.set(key,each_blocks[i]=create_each_block(key,child_ctx))}const default_slot_template=ctx[2].default;const default_slot=create_slot(default_slot_template,ctx,ctx[1],null);const default_slot_or_fallback=default_slot||fallback_block(ctx);const block={c:function create(){div1=element("div");div0=element("div");ul=element("ul");for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].c()}t=space();if(default_slot_or_fallback)default_slot_or_fallback.c();attr_dev(ul,"class","nav");add_location(ul,file$3,8,2,192);attr_dev(div0,"class","items");add_location(div0,file$3,7,1,170);attr_dev(div1,"class","nav");add_location(div1,file$3,6,0,151)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){insert_dev(target,div1,anchor);append_dev(div1,div0);append_dev(div0,ul);for(let i=0;i<each_blocks.length;i+=1){if(each_blocks[i]){each_blocks[i].m(ul,null)}}append_dev(div0,t);if(default_slot_or_fallback){default_slot_or_fallback.m(div0,null)}current=true},p:function update(ctx,[dirty]){if(dirty&1){each_value=ensure_array_like_dev(ctx[0]);group_outros();validate_each_keys(ctx,each_value,get_each_context,get_key);each_blocks=update_keyed_each(each_blocks,dirty,get_key,1,ctx,each_value,each_1_lookup,ul,outro_and_destroy_block,create_each_block,null,get_each_context);check_outros()}if(default_slot){if(default_slot.p&&(!current||dirty&2)){update_slot_base(default_slot,default_slot_template,ctx,ctx[1],!current?get_all_dirty_from_scope(ctx[1]):get_slot_changes(default_slot_template,ctx[1],dirty,null),null)}}},i:function intro(local){if(current)return;for(let i=0;i<each_value.length;i+=1){transition_in(each_blocks[i])}transition_in(default_slot_or_fallback,local);current=true},o:function outro(local){for(let i=0;i<each_blocks.length;i+=1){transition_out(each_blocks[i])}transition_out(default_slot_or_fallback,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(div1)}for(let i=0;i<each_blocks.length;i+=1){each_blocks[i].d()}if(default_slot_or_fallback)default_slot_or_fallback.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$4.name,type:"component",source:"",ctx:ctx});return block}function instance$4($$self,$$props,$$invalidate){let $pages;validate_store(pages,"pages");component_subscribe($$self,pages,($$value=>$$invalidate(0,$pages=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("Nav",slots,["default"]);const writable_props=[];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<Nav> was created with unknown prop '${key}'`)}));$$self.$$set=$$props=>{if("$$scope"in $$props)$$invalidate(1,$$scope=$$props.$$scope)};$$self.$capture_state=()=>({pages:pages,NavItem:NavItem,OffloadStatus:OffloadStatus,$pages:$pages});return[$pages,$$scope,slots]}class Nav extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$4,create_fragment$4,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"Nav",options:options,id:create_fragment$4.name})}}const{Object:Object_1}=globals;const file$2="ui/pro/ToolRunningStatus.svelte";function create_if_block$1(ctx){let div2;let div1;let p;let strong;let t0_value=ctx[1].progress+"";let t0;let t1;let t2;let span;let t3;let progressbar;let t4;let div0;let img;let img_src_value;let img_alt_value;let t5;let toolrunningbuttons;let current;let mounted;let dispose;progressbar=new ProgressBar({props:{percentComplete:ctx[2],starting:ctx[5],running:ctx[0],paused:ctx[1].is_paused,title:ctx[3]},$$inline:true});toolrunningbuttons=new ToolRunningButtons({props:{tool:ctx[1],disabled:ctx[6],small:true},$$inline:true});const block={c:function create(){div2=element("div");div1=element("div");p=element("p");strong=element("strong");t0=text(t0_value);t1=text("%");t2=space();span=element("span");t3=space();create_component(progressbar.$$.fragment);t4=space();div0=element("div");img=element("img");t5=space();create_component(toolrunningbuttons.$$.fragment);add_location(strong,file$2,77,4,2381);add_location(span,file$2,78,4,2419);attr_dev(p,"class","status-text");attr_dev(p,"title",ctx[3]);add_location(p,file$2,76,3,2345);if(!src_url_equal(img.src,img_src_value=ctx[8].assets+"img/icon/"+ctx[7]))attr_dev(img,"src",img_src_value);attr_dev(img,"alt",img_alt_value=ctx[1].status_description);add_location(img,file$2,88,4,2626);attr_dev(div0,"class","animation-running");attr_dev(div0,"title",ctx[3]);add_location(div0,file$2,87,3,2582);attr_dev(div1,"class","nav-status");attr_dev(div1,"title",ctx[3]);add_location(div1,file$2,75,2,2277);attr_dev(div2,"class","nav-status-wrapper tool-running");add_location(div2,file$2,71,1,2082)},m:function mount(target,anchor){insert_dev(target,div2,anchor);append_dev(div2,div1);append_dev(div1,p);append_dev(p,strong);append_dev(strong,t0);append_dev(strong,t1);append_dev(p,t2);append_dev(p,span);span.innerHTML=ctx[4];append_dev(div1,t3);mount_component(progressbar,div1,null);append_dev(div1,t4);append_dev(div1,div0);append_dev(div0,img);append_dev(div2,t5);mount_component(toolrunningbuttons,div2,null);current=true;if(!mounted){dispose=listen_dev(div1,"click",ctx[12],false,false,false,false);mounted=true}},p:function update(ctx,dirty){if((!current||dirty&2)&&t0_value!==(t0_value=ctx[1].progress+""))set_data_dev(t0,t0_value);if(!current||dirty&16)span.innerHTML=ctx[4];if(!current||dirty&8){attr_dev(p,"title",ctx[3])}const progressbar_changes={};if(dirty&4)progressbar_changes.percentComplete=ctx[2];if(dirty&32)progressbar_changes.starting=ctx[5];if(dirty&1)progressbar_changes.running=ctx[0];if(dirty&2)progressbar_changes.paused=ctx[1].is_paused;if(dirty&8)progressbar_changes.title=ctx[3];progressbar.$set(progressbar_changes);if(!current||dirty&384&&!src_url_equal(img.src,img_src_value=ctx[8].assets+"img/icon/"+ctx[7])){attr_dev(img,"src",img_src_value)}if(!current||dirty&2&&img_alt_value!==(img_alt_value=ctx[1].status_description)){attr_dev(img,"alt",img_alt_value)}if(!current||dirty&8){attr_dev(div0,"title",ctx[3])}if(!current||dirty&8){attr_dev(div1,"title",ctx[3])}const toolrunningbuttons_changes={};if(dirty&2)toolrunningbuttons_changes.tool=ctx[1];if(dirty&64)toolrunningbuttons_changes.disabled=ctx[6];toolrunningbuttons.$set(toolrunningbuttons_changes)},i:function intro(local){if(current)return;transition_in(progressbar.$$.fragment,local);transition_in(toolrunningbuttons.$$.fragment,local);current=true},o:function outro(local){transition_out(progressbar.$$.fragment,local);transition_out(toolrunningbuttons.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(div2)}destroy_component(progressbar);destroy_component(toolrunningbuttons);mounted=false;dispose()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block$1.name,type:"if",source:"(71:0) {#if tool}",ctx:ctx});return block}function create_fragment$3(ctx){let if_block_anchor;let current;let if_block=ctx[1]&&create_if_block$1(ctx);const block={c:function create(){if(if_block)if_block.c();if_block_anchor=empty()},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,[dirty]){if(ctx[1]){if(if_block){if_block.p(ctx,dirty);if(dirty&2){transition_in(if_block,1)}}else{if_block=create_if_block$1(ctx);if_block.c();transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}}else if(if_block){group_outros();transition_out(if_block,1,1,(()=>{if_block=null}));check_outros()}},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if(if_block)if_block.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$3.name,type:"component",source:"",ctx:ctx});return block}function instance$3($$self,$$props,$$invalidate){let isRunning;let tool;let icon;let disabled;let starting;let status;let title;let percentComplete;let $toolsLocked;let $running;let $tools;let $urls;validate_store(toolsLocked,"toolsLocked");component_subscribe($$self,toolsLocked,($$value=>$$invalidate(9,$toolsLocked=$$value)));validate_store(running,"running");component_subscribe($$self,running,($$value=>$$invalidate(10,$running=$$value)));validate_store(tools,"tools");component_subscribe($$self,tools,($$value=>$$invalidate(11,$tools=$$value)));validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(8,$urls=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("ToolRunningStatus",slots,[]);function runningTool(tools,running){return Object.values(tools).find((tool=>tool.id===running))}function toolStatus(tool,isRunning){if(!isRunning){return""}if(tool.short_status_description){return tool.short_status_description}return tool.busy_description}function getPercentComplete(tool,isRunning){if(isRunning){return tool.progress}return 0}const writable_props=[];Object_1.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<ToolRunningStatus> was created with unknown prop '${key}'`)}));const click_handler=()=>push("/tools");$$self.$capture_state=()=>({push:push,urls:urls,running:running,tools:tools,toolsLocked:toolsLocked,numToShortString:numToShortString,numToString:numToString,ProgressBar:ProgressBar,ToolRunningButtons:ToolRunningButtons,runningTool:runningTool,toolStatus:toolStatus,getPercentComplete:getPercentComplete,isRunning:isRunning,tool:tool,percentComplete:percentComplete,title:title,status:status,starting:starting,disabled:disabled,icon:icon,$toolsLocked:$toolsLocked,$running:$running,$tools:$tools,$urls:$urls});$$self.$inject_state=$$props=>{if("isRunning"in $$props)$$invalidate(0,isRunning=$$props.isRunning);if("tool"in $$props)$$invalidate(1,tool=$$props.tool);if("percentComplete"in $$props)$$invalidate(2,percentComplete=$$props.percentComplete);if("title"in $$props)$$invalidate(3,title=$$props.title);if("status"in $$props)$$invalidate(4,status=$$props.status);if("starting"in $$props)$$invalidate(5,starting=$$props.starting);if("disabled"in $$props)$$invalidate(6,disabled=$$props.disabled);if("icon"in $$props)$$invalidate(7,icon=$$props.icon)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty&1024){$$invalidate(0,isRunning=!!$running)}if($$self.$$.dirty&3072){$$invalidate(1,tool=runningTool($tools,$running))}if($$self.$$.dirty&3){$$invalidate(7,icon=tools.icon(tool,isRunning,true))}if($$self.$$.dirty&1539){$$invalidate(6,disabled=isRunning&&($running&&$running!==tool.id||tool.is_processing&&tool.is_paused||tool.is_cancelled||$toolsLocked))}if($$self.$$.dirty&3){$$invalidate(5,starting=!!(isRunning&&tool.progress<1&&!tool.is_paused))}if($$self.$$.dirty&3){$$invalidate(4,status=isRunning?"("+numToShortString(tool.queue.processed)+"/"+numToShortString(tool.queue.total)+") "+toolStatus(tool,isRunning):"")}if($$self.$$.dirty&3){$$invalidate(3,title=isRunning?tool.name+": "+tool.progress+"% ("+numToString(tool.queue.processed)+"/"+numToString(tool.queue.total)+")":"")}if($$self.$$.dirty&3){$$invalidate(2,percentComplete=getPercentComplete(tool,isRunning))}};return[isRunning,tool,percentComplete,title,status,starting,disabled,icon,$urls,$toolsLocked,$running,$tools,click_handler]}class ToolRunningStatus extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$3,create_fragment$3,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"ToolRunningStatus",options:options,id:create_fragment$3.name})}}const file$1="ui/pro/Nav.svelte";function create_else_block(ctx){let offloadstatus;let updating_flyoutButton;let updating_expanded;let updating_hasFocus;let current;function offloadstatus_flyoutButton_binding(value){ctx[14](value)}function offloadstatus_expanded_binding(value){ctx[15](value)}function offloadstatus_hasFocus_binding(value){ctx[16](value)}let offloadstatus_props={$$slots:{flyout:[create_flyout_slot]},$$scope:{ctx:ctx}};if(ctx[1]!==void 0){offloadstatus_props.flyoutButton=ctx[1]}if(ctx[2]!==void 0){offloadstatus_props.expanded=ctx[2]}if(ctx[3]!==void 0){offloadstatus_props.hasFocus=ctx[3]}offloadstatus=new OffloadStatus({props:offloadstatus_props,$$inline:true});binding_callbacks.push((()=>bind(offloadstatus,"flyoutButton",offloadstatus_flyoutButton_binding)));binding_callbacks.push((()=>bind(offloadstatus,"expanded",offloadstatus_expanded_binding)));binding_callbacks.push((()=>bind(offloadstatus,"hasFocus",offloadstatus_hasFocus_binding)));const block={c:function create(){create_component(offloadstatus.$$.fragment)},m:function mount(target,anchor){mount_component(offloadstatus,target,anchor);current=true},p:function update(ctx,dirty){const offloadstatus_changes={};if(dirty&1049023){offloadstatus_changes.$$scope={dirty:dirty,ctx:ctx}}if(!updating_flyoutButton&&dirty&2){updating_flyoutButton=true;offloadstatus_changes.flyoutButton=ctx[1];add_flush_callback((()=>updating_flyoutButton=false))}if(!updating_expanded&&dirty&4){updating_expanded=true;offloadstatus_changes.expanded=ctx[2];add_flush_callback((()=>updating_expanded=false))}if(!updating_hasFocus&&dirty&8){updating_hasFocus=true;offloadstatus_changes.hasFocus=ctx[3];add_flush_callback((()=>updating_hasFocus=false))}offloadstatus.$set(offloadstatus_changes)},i:function intro(local){if(current)return;transition_in(offloadstatus.$$.fragment,local);current=true},o:function outro(local){transition_out(offloadstatus.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(offloadstatus,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_else_block.name,type:"else",source:"(73:1) {:else}",ctx:ctx});return block}function create_if_block(ctx){let toolrunningstatus;let current;toolrunningstatus=new ToolRunningStatus({$$inline:true});const block={c:function create(){create_component(toolrunningstatus.$$.fragment)},m:function mount(target,anchor){mount_component(toolrunningstatus,target,anchor);current=true},p:noop,i:function intro(local){if(current)return;transition_in(toolrunningstatus.$$.fragment,local);current=true},o:function outro(local){transition_out(toolrunningstatus.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(toolrunningstatus,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block.name,type:"if",source:"(71:1) {#if !!$running}",ctx:ctx});return block}function create_default_slot_3(ctx){let t;const block={c:function create(){t=text(ctx[7])},m:function mount(target,anchor){insert_dev(target,t,anchor)},p:function update(ctx,dirty){if(dirty&128)set_data_dev(t,ctx[7])},d:function destroy(detaching){if(detaching){detach_dev(t)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_3.name,type:"slot",source:"(79:7) <Button primary disabled={offloadRemainingDisabledMessage} title={offloadRemainingDisabledMessage} on:click={startOffload} >",ctx:ctx});return block}function create_default_slot_2(ctx){let button;let current;button=new Button({props:{primary:true,disabled:ctx[4],title:ctx[4],$$slots:{default:[create_default_slot_3]},$$scope:{ctx:ctx}},$$inline:true});button.$on("click",ctx[9]);const block={c:function create(){create_component(button.$$.fragment)},m:function mount(target,anchor){mount_component(button,target,anchor);current=true},p:function update(ctx,dirty){const button_changes={};if(dirty&16)button_changes.disabled=ctx[4];if(dirty&16)button_changes.title=ctx[4];if(dirty&1048704){button_changes.$$scope={dirty:dirty,ctx:ctx}}button.$set(button_changes)},i:function intro(local){if(current)return;transition_in(button.$$.fragment,local);current=true},o:function outro(local){transition_out(button.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(button,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_2.name,type:"slot",source:'(78:6) <PanelRow footer class=\\"offload-remaining\\">',ctx:ctx});return block}function create_if_block_2(ctx){let a;let t_value=ctx[5].upgrade_plan_cta+"";let t;let a_href_value;const block={c:function create(){a=element("a");t=text(t_value);attr_dev(a,"href",a_href_value=ctx[8].licenses);attr_dev(a,"target","_blank");attr_dev(a,"class","upgrade");add_location(a,file$1,98,8,2784)},m:function mount(target,anchor){insert_dev(target,a,anchor);append_dev(a,t)},p:function update(ctx,dirty){if(dirty&32&&t_value!==(t_value=ctx[5].upgrade_plan_cta+""))set_data_dev(t,t_value);if(dirty&256&&a_href_value!==(a_href_value=ctx[8].licenses)){attr_dev(a,"href",a_href_value)}},d:function destroy(detaching){if(detaching){detach_dev(a)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_2.name,type:"if",source:"(98:49) ",ctx:ctx});return block}function create_if_block_1(ctx){let a;let t_value=ctx[5].activate_licence+"";let t;let mounted;let dispose;const block={c:function create(){a=element("a");t=text(t_value);attr_dev(a,"href","/license");add_location(a,file$1,94,8,2647)},m:function mount(target,anchor){insert_dev(target,a,anchor);append_dev(a,t);if(!mounted){dispose=action_destroyer(link.call(null,a));mounted=true}},p:function update(ctx,dirty){if(dirty&32&&t_value!==(t_value=ctx[5].activate_licence+""))set_data_dev(t,t_value)},d:function destroy(detaching){if(detaching){detach_dev(a)}mounted=false;dispose()}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_if_block_1.name,type:"if",source:"(94:7) {#if !$licence.is_set}",ctx:ctx});return block}function create_default_slot_1(ctx){let div;let p0;let t0_value=ctx[5].plan_usage_title+"";let t0;let t1;let p1;let t2_value=ctx[0].plan_usage+"";let t2;let t3;let if_block_anchor;function select_block_type_1(ctx,dirty){if(!ctx[0].is_set)return create_if_block_1;if(ctx[0].limit_info.limit!==0)return create_if_block_2}let current_block_type=select_block_type_1(ctx);let if_block=current_block_type&&current_block_type(ctx);const block={c:function create(){div=element("div");p0=element("p");t0=text(t0_value);t1=space();p1=element("p");t2=text(t2_value);t3=space();if(if_block)if_block.c();if_block_anchor=empty();attr_dev(p0,"class","title");add_location(p0,file$1,90,8,2509);add_location(p1,file$1,91,8,2566);attr_dev(div,"class","details");add_location(div,file$1,89,7,2479)},m:function mount(target,anchor){insert_dev(target,div,anchor);append_dev(div,p0);append_dev(p0,t0);append_dev(div,t1);append_dev(div,p1);append_dev(p1,t2);insert_dev(target,t3,anchor);if(if_block)if_block.m(target,anchor);insert_dev(target,if_block_anchor,anchor)},p:function update(ctx,dirty){if(dirty&32&&t0_value!==(t0_value=ctx[5].plan_usage_title+""))set_data_dev(t0,t0_value);if(dirty&1&&t2_value!==(t2_value=ctx[0].plan_usage+""))set_data_dev(t2,t2_value);if(current_block_type===(current_block_type=select_block_type_1(ctx))&&if_block){if_block.p(ctx,dirty)}else{if(if_block)if_block.d(1);if_block=current_block_type&&current_block_type(ctx);if(if_block){if_block.c();if_block.m(if_block_anchor.parentNode,if_block_anchor)}}},d:function destroy(detaching){if(detaching){detach_dev(div);detach_dev(t3);detach_dev(if_block_anchor)}if(if_block){if_block.d(detaching)}}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot_1.name,type:"slot",source:'(89:6) <PanelRow footer class=\\"licence\\">',ctx:ctx});return block}function create_footer_slot(ctx){let panelrow0;let t;let panelrow1;let current;panelrow0=new PanelRow({props:{footer:true,class:"offload-remaining",$$slots:{default:[create_default_slot_2]},$$scope:{ctx:ctx}},$$inline:true});panelrow1=new PanelRow({props:{footer:true,class:"licence",$$slots:{default:[create_default_slot_1]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(panelrow0.$$.fragment);t=space();create_component(panelrow1.$$.fragment)},m:function mount(target,anchor){mount_component(panelrow0,target,anchor);insert_dev(target,t,anchor);mount_component(panelrow1,target,anchor);current=true},p:function update(ctx,dirty){const panelrow0_changes={};if(dirty&1048720){panelrow0_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow0.$set(panelrow0_changes);const panelrow1_changes={};if(dirty&1048865){panelrow1_changes.$$scope={dirty:dirty,ctx:ctx}}panelrow1.$set(panelrow1_changes)},i:function intro(local){if(current)return;transition_in(panelrow0.$$.fragment,local);transition_in(panelrow1.$$.fragment,local);current=true},o:function outro(local){transition_out(panelrow0.$$.fragment,local);transition_out(panelrow1.$$.fragment,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t)}destroy_component(panelrow0,detaching);destroy_component(panelrow1,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_footer_slot.name,type:"slot",source:'(77:5) <svelte:fragment slot=\\"footer\\">',ctx:ctx});return block}function create_flyout_slot(ctx){let offloadstatusflyout;let updating_expanded;let updating_hasFocus;let updating_buttonRef;let current;function offloadstatusflyout_expanded_binding(value){ctx[11](value)}function offloadstatusflyout_hasFocus_binding(value){ctx[12](value)}function offloadstatusflyout_buttonRef_binding(value){ctx[13](value)}let offloadstatusflyout_props={$$slots:{footer:[create_footer_slot]},$$scope:{ctx:ctx}};if(ctx[2]!==void 0){offloadstatusflyout_props.expanded=ctx[2]}if(ctx[3]!==void 0){offloadstatusflyout_props.hasFocus=ctx[3]}if(ctx[1]!==void 0){offloadstatusflyout_props.buttonRef=ctx[1]}offloadstatusflyout=new OffloadStatusFlyout({props:offloadstatusflyout_props,$$inline:true});binding_callbacks.push((()=>bind(offloadstatusflyout,"expanded",offloadstatusflyout_expanded_binding)));binding_callbacks.push((()=>bind(offloadstatusflyout,"hasFocus",offloadstatusflyout_hasFocus_binding)));binding_callbacks.push((()=>bind(offloadstatusflyout,"buttonRef",offloadstatusflyout_buttonRef_binding)));const block={c:function create(){create_component(offloadstatusflyout.$$.fragment)},m:function mount(target,anchor){mount_component(offloadstatusflyout,target,anchor);current=true},p:function update(ctx,dirty){const offloadstatusflyout_changes={};if(dirty&1049009){offloadstatusflyout_changes.$$scope={dirty:dirty,ctx:ctx}}if(!updating_expanded&&dirty&4){updating_expanded=true;offloadstatusflyout_changes.expanded=ctx[2];add_flush_callback((()=>updating_expanded=false))}if(!updating_hasFocus&&dirty&8){updating_hasFocus=true;offloadstatusflyout_changes.hasFocus=ctx[3];add_flush_callback((()=>updating_hasFocus=false))}if(!updating_buttonRef&&dirty&2){updating_buttonRef=true;offloadstatusflyout_changes.buttonRef=ctx[1];add_flush_callback((()=>updating_buttonRef=false))}offloadstatusflyout.$set(offloadstatusflyout_changes)},i:function intro(local){if(current)return;transition_in(offloadstatusflyout.$$.fragment,local);current=true},o:function outro(local){transition_out(offloadstatusflyout.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(offloadstatusflyout,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_flyout_slot.name,type:"slot",source:'(75:3) <svelte:fragment slot=\\"flyout\\">',ctx:ctx});return block}function create_default_slot$1(ctx){let current_block_type_index;let if_block;let if_block_anchor;let current;const if_block_creators=[create_if_block,create_else_block];const if_blocks=[];function select_block_type(ctx,dirty){if(!!ctx[6])return 0;return 1}current_block_type_index=select_block_type(ctx);if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);const block={c:function create(){if_block.c();if_block_anchor=empty()},m:function mount(target,anchor){if_blocks[current_block_type_index].m(target,anchor);insert_dev(target,if_block_anchor,anchor);current=true},p:function update(ctx,dirty){let previous_block_index=current_block_type_index;current_block_type_index=select_block_type(ctx);if(current_block_type_index===previous_block_index){if_blocks[current_block_type_index].p(ctx,dirty)}else{group_outros();transition_out(if_blocks[previous_block_index],1,1,(()=>{if_blocks[previous_block_index]=null}));check_outros();if_block=if_blocks[current_block_type_index];if(!if_block){if_block=if_blocks[current_block_type_index]=if_block_creators[current_block_type_index](ctx);if_block.c()}else{if_block.p(ctx,dirty)}transition_in(if_block,1);if_block.m(if_block_anchor.parentNode,if_block_anchor)}},i:function intro(local){if(current)return;transition_in(if_block);current=true},o:function outro(local){transition_out(if_block);current=false},d:function destroy(detaching){if(detaching){detach_dev(if_block_anchor)}if_blocks[current_block_type_index].d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot$1.name,type:"slot",source:"(70:0) <Nav>",ctx:ctx});return block}function create_fragment$2(ctx){let nav;let current;nav=new Nav({props:{$$slots:{default:[create_default_slot$1]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(nav.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(nav,target,anchor);current=true},p:function update(ctx,[dirty]){const nav_changes={};if(dirty&1049087){nav_changes.$$scope={dirty:dirty,ctx:ctx}}nav.$set(nav_changes)},i:function intro(local){if(current)return;transition_in(nav.$$.fragment,local);current=true},o:function outro(local){transition_out(nav.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(nav,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$2.name,type:"component",source:"",ctx:ctx});return block}function instance$2($$self,$$props,$$invalidate){let offloadRemainingDisabledMessage;let $tools;let $counts;let $licence;let $strings;let $bucket_writable;let $running;let $offloadRemainingWithCount;let $urls;validate_store(tools,"tools");component_subscribe($$self,tools,($$value=>$$invalidate(17,$tools=$$value)));validate_store(counts,"counts");component_subscribe($$self,counts,($$value=>$$invalidate(10,$counts=$$value)));validate_store(licence,"licence");component_subscribe($$self,licence,($$value=>$$invalidate(0,$licence=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(5,$strings=$$value)));validate_store(bucket_writable,"bucket_writable");component_subscribe($$self,bucket_writable,($$value=>$$invalidate(18,$bucket_writable=$$value)));validate_store(running,"running");component_subscribe($$self,running,($$value=>$$invalidate(6,$running=$$value)));validate_store(offloadRemainingWithCount,"offloadRemainingWithCount");component_subscribe($$self,offloadRemainingWithCount,($$value=>$$invalidate(7,$offloadRemainingWithCount=$$value)));validate_store(urls,"urls");component_subscribe($$self,urls,($$value=>$$invalidate(8,$urls=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("Nav",slots,[]);let flyoutButton;let expanded=false;let hasFocus=false;function getOffloadRemainingDisabledMessage(licence,counts){if(!licence.is_set){return $strings.no_licence}if(counts.total<1){return $strings.no_media}if(counts.not_offloaded<1){return $strings.all_media_offloaded}if(licence.limit_info.counts_toward_limit&&licence.limit_info.total>0&&licence.limit_info.limit>0&&licence.limit_info.total>=licence.limit_info.limit){if(licence.limit_info.total>licence.limit_info.limit){return $strings.licence_limit_exceeded}return $strings.licence_limit_reached}if(!$bucket_writable){return $strings.disabled_tool_bucket_access}return""}function startOffload(){$$invalidate(2,expanded=false);tools.start($tools.uploader)}const writable_props=[];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<Nav> was created with unknown prop '${key}'`)}));function offloadstatusflyout_expanded_binding(value){expanded=value;$$invalidate(2,expanded)}function offloadstatusflyout_hasFocus_binding(value){hasFocus=value;$$invalidate(3,hasFocus)}function offloadstatusflyout_buttonRef_binding(value){flyoutButton=value;$$invalidate(1,flyoutButton)}function offloadstatus_flyoutButton_binding(value){flyoutButton=value;$$invalidate(1,flyoutButton)}function offloadstatus_expanded_binding(value){expanded=value;$$invalidate(2,expanded)}function offloadstatus_hasFocus_binding(value){hasFocus=value;$$invalidate(3,hasFocus)}$$self.$capture_state=()=>({link:link,bucket_writable:bucket_writable,counts:counts,strings:strings,urls:urls,licence:licence,offloadRemainingWithCount:offloadRemainingWithCount,running:running,tools:tools,Nav:Nav,OffloadStatus:OffloadStatus,ToolRunningStatus:ToolRunningStatus,OffloadStatusFlyout:OffloadStatusFlyout,PanelRow:PanelRow,Button:Button,flyoutButton:flyoutButton,expanded:expanded,hasFocus:hasFocus,getOffloadRemainingDisabledMessage:getOffloadRemainingDisabledMessage,startOffload:startOffload,offloadRemainingDisabledMessage:offloadRemainingDisabledMessage,$tools:$tools,$counts:$counts,$licence:$licence,$strings:$strings,$bucket_writable:$bucket_writable,$running:$running,$offloadRemainingWithCount:$offloadRemainingWithCount,$urls:$urls});$$self.$inject_state=$$props=>{if("flyoutButton"in $$props)$$invalidate(1,flyoutButton=$$props.flyoutButton);if("expanded"in $$props)$$invalidate(2,expanded=$$props.expanded);if("hasFocus"in $$props)$$invalidate(3,hasFocus=$$props.hasFocus);if("offloadRemainingDisabledMessage"in $$props)$$invalidate(4,offloadRemainingDisabledMessage=$$props.offloadRemainingDisabledMessage)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty&1025){$$invalidate(4,offloadRemainingDisabledMessage=getOffloadRemainingDisabledMessage($licence,$counts))}};return[$licence,flyoutButton,expanded,hasFocus,offloadRemainingDisabledMessage,$strings,$running,$offloadRemainingWithCount,$urls,startOffload,$counts,offloadstatusflyout_expanded_binding,offloadstatusflyout_hasFocus_binding,offloadstatusflyout_buttonRef_binding,offloadstatus_flyoutButton_binding,offloadstatus_expanded_binding,offloadstatus_hasFocus_binding]}class Nav_1 extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$2,create_fragment$2,safe_not_equal,{});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"Nav_1",options:options,id:create_fragment$2.name})}}const file="ui/components/Pages.svelte";function create_fragment$1(ctx){let switch_instance;let t0;let div;let router;let t1;let current;var switch_value=ctx[0];function switch_props(ctx,dirty){return{$$inline:true}}if(switch_value){switch_instance=construct_svelte_component_dev(switch_value,switch_props())}router=new Router({props:{routes:ctx[1]},$$inline:true});router.$on("routeEvent",ctx[3]);const default_slot_template=ctx[5].default;const default_slot=create_slot(default_slot_template,ctx,ctx[4],null);const block={c:function create(){if(switch_instance)create_component(switch_instance.$$.fragment);t0=space();div=element("div");create_component(router.$$.fragment);t1=space();if(default_slot)default_slot.c();attr_dev(div,"class","wpome-wrapper "+ctx[2]);add_location(div,file,32,0,754)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){if(switch_instance)mount_component(switch_instance,target,anchor);insert_dev(target,t0,anchor);insert_dev(target,div,anchor);mount_component(router,div,null);append_dev(div,t1);if(default_slot){default_slot.m(div,null)}current=true},p:function update(ctx,[dirty]){if(dirty&1&&switch_value!==(switch_value=ctx[0])){if(switch_instance){group_outros();const old_component=switch_instance;transition_out(old_component.$$.fragment,1,0,(()=>{destroy_component(old_component,1)}));check_outros()}if(switch_value){switch_instance=construct_svelte_component_dev(switch_value,switch_props());create_component(switch_instance.$$.fragment);transition_in(switch_instance.$$.fragment,1);mount_component(switch_instance,t0.parentNode,t0)}else{switch_instance=null}}const router_changes={};if(dirty&2)router_changes.routes=ctx[1];router.$set(router_changes);if(default_slot){if(default_slot.p&&(!current||dirty&16)){update_slot_base(default_slot,default_slot_template,ctx,ctx[4],!current?get_all_dirty_from_scope(ctx[4]):get_slot_changes(default_slot_template,ctx[4],dirty,null),null)}}},i:function intro(local){if(current)return;if(switch_instance)transition_in(switch_instance.$$.fragment,local);transition_in(router.$$.fragment,local);transition_in(default_slot,local);current=true},o:function outro(local){if(switch_instance)transition_out(switch_instance.$$.fragment,local);transition_out(router.$$.fragment,local);transition_out(default_slot,local);current=false},d:function destroy(detaching){if(detaching){detach_dev(t0);detach_dev(div)}if(switch_instance)destroy_component(switch_instance,detaching);destroy_component(router);if(default_slot)default_slot.d(detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment$1.name,type:"component",source:"",ctx:ctx});return block}function instance$1($$self,$$props,$$invalidate){let $routes;validate_store(routes,"routes");component_subscribe($$self,routes,($$value=>$$invalidate(1,$routes=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("Pages",slots,["default"]);let{nav:nav=Nav}=$$props;const classes=$$props.class?$$props.class:"";function handleRouteEvent(event){const route=pages.handleRouteEvent(event.detail);if(route){push(route)}}$$self.$$set=$$new_props=>{$$invalidate(6,$$props=assign(assign({},$$props),exclude_internal_props($$new_props)));if("nav"in $$new_props)$$invalidate(0,nav=$$new_props.nav);if("$$scope"in $$new_props)$$invalidate(4,$$scope=$$new_props.$$scope)};$$self.$capture_state=()=>({Router:Router,push:push,pages:pages,routes:routes,Nav:Nav,nav:nav,classes:classes,handleRouteEvent:handleRouteEvent,$routes:$routes});$$self.$inject_state=$$new_props=>{$$invalidate(6,$$props=assign(assign({},$$props),$$new_props));if("nav"in $$props)$$invalidate(0,nav=$$new_props.nav)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$props=exclude_internal_props($$props);return[nav,$routes,classes,handleRouteEvent,$$scope,slots]}class Pages extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance$1,create_fragment$1,safe_not_equal,{nav:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"Pages",options:options,id:create_fragment$1.name})}get nav(){throw new Error("<Pages>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set nav(value){throw new Error("<Pages>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}function create_default_slot(ctx){let pages_1;let current;pages_1=new Pages({props:{nav:Nav_1},$$inline:true});const block={c:function create(){create_component(pages_1.$$.fragment)},m:function mount(target,anchor){mount_component(pages_1,target,anchor);current=true},p:noop,i:function intro(local){if(current)return;transition_in(pages_1.$$.fragment,local);current=true},o:function outro(local){transition_out(pages_1.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(pages_1,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_default_slot.name,type:"slot",source:"(199:0) <Settings header={Header}>",ctx:ctx});return block}function create_fragment(ctx){let settings_1;let current;settings_1=new Settings({props:{header:Header_1,$$slots:{default:[create_default_slot]},$$scope:{ctx:ctx}},$$inline:true});const block={c:function create(){create_component(settings_1.$$.fragment)},l:function claim(nodes){throw new Error("options.hydrate only works if the component was compiled with the `hydratable: true` option")},m:function mount(target,anchor){mount_component(settings_1,target,anchor);current=true},p:function update(ctx,[dirty]){const settings_1_changes={};if(dirty&524288){settings_1_changes.$$scope={dirty:dirty,ctx:ctx}}settings_1.$set(settings_1_changes)},i:function intro(local){if(current)return;transition_in(settings_1.$$.fragment,local);current=true},o:function outro(local){transition_out(settings_1.$$.fragment,local);current=false},d:function destroy(detaching){destroy_component(settings_1,detaching)}};dispatch_dev("SvelteRegisterBlock",{block:block,id:create_fragment.name,type:"component",source:"",ctx:ctx});return block}function instance($$self,$$props,$$invalidate){let $licence;let $counts;let $strings;let $current_settings;let $settings;let $config;let $needs_access_keys;let $running;let $defaultStorageProvider;let $assetsSettingsLocked;let $toolsLocked;let $settingsLocked;let $assetsNeedsRefresh;let $settings_changed;let $tools;let $needs_refresh;let $assetsSettingsChanged;validate_store(licence,"licence");component_subscribe($$self,licence,($$value=>$$invalidate(1,$licence=$$value)));validate_store(counts,"counts");component_subscribe($$self,counts,($$value=>$$invalidate(2,$counts=$$value)));validate_store(strings,"strings");component_subscribe($$self,strings,($$value=>$$invalidate(3,$strings=$$value)));validate_store(current_settings,"current_settings");component_subscribe($$self,current_settings,($$value=>$$invalidate(4,$current_settings=$$value)));validate_store(settings,"settings");component_subscribe($$self,settings,($$value=>$$invalidate(5,$settings=$$value)));validate_store(config,"config");component_subscribe($$self,config,($$value=>$$invalidate(6,$config=$$value)));validate_store(needs_access_keys,"needs_access_keys");component_subscribe($$self,needs_access_keys,($$value=>$$invalidate(7,$needs_access_keys=$$value)));validate_store(running,"running");component_subscribe($$self,running,($$value=>$$invalidate(8,$running=$$value)));validate_store(defaultStorageProvider,"defaultStorageProvider");component_subscribe($$self,defaultStorageProvider,($$value=>$$invalidate(9,$defaultStorageProvider=$$value)));validate_store(assetsSettingsLocked,"assetsSettingsLocked");component_subscribe($$self,assetsSettingsLocked,($$value=>$$invalidate(10,$assetsSettingsLocked=$$value)));validate_store(toolsLocked,"toolsLocked");component_subscribe($$self,toolsLocked,($$value=>$$invalidate(11,$toolsLocked=$$value)));validate_store(settingsLocked,"settingsLocked");component_subscribe($$self,settingsLocked,($$value=>$$invalidate(12,$settingsLocked=$$value)));validate_store(assetsNeedsRefresh,"assetsNeedsRefresh");component_subscribe($$self,assetsNeedsRefresh,($$value=>$$invalidate(13,$assetsNeedsRefresh=$$value)));validate_store(settings_changed,"settings_changed");component_subscribe($$self,settings_changed,($$value=>$$invalidate(14,$settings_changed=$$value)));validate_store(tools,"tools");component_subscribe($$self,tools,($$value=>$$invalidate(15,$tools=$$value)));validate_store(needs_refresh,"needs_refresh");component_subscribe($$self,needs_refresh,($$value=>$$invalidate(16,$needs_refresh=$$value)));validate_store(assetsSettingsChanged,"assetsSettingsChanged");component_subscribe($$self,assetsSettingsChanged,($$value=>$$invalidate(17,$assetsSettingsChanged=$$value)));let{$$slots:slots={},$$scope:$$scope}=$$props;validate_slots("Settings",slots,[]);let{init:init={}}=$$props;config.set(init);pages.set(defaultPages);tools.updateTools({tools:{...$config.tools}});assetsSettings.set({...$config.assets_settings});addPages($tools);async function handleStateUpdate(config){let _settingsLocked=false;let _toolsLocked=false;let _assetsSettingsLocked=false;if(config.upgrades.is_upgrading){_settingsLocked=true;_toolsLocked=true;_assetsSettingsLocked=true;const notification={id:"as3cf-all-settings-locked",type:"warning",dismissible:false,heading:config.upgrades.locked_notifications[config.upgrades.running_upgrade],icon:"notification-locked.svg",plainHeading:true};notifications.add(notification);if($settings_changed){settings.reset()}if($assetsSettingsChanged){assetsSettings.reset()}}else{notifications.delete("as3cf-all-settings-locked")}if($needs_refresh){_settingsLocked=true;_toolsLocked=true;const notification={id:"as3cf-media-settings-locked",type:"warning",dismissible:false,only_show_on_tab:"media",heading:$strings.needs_refresh,icon:"notification-locked.svg",plainHeading:true};notifications.add(notification)}else if($running){_settingsLocked=true;const tool=$tools[$running];const notification={id:"as3cf-media-settings-locked",type:"warning",dismissible:false,only_show_on_tab:"media",heading:tool.locked_notification,icon:"notification-locked.svg",plainHeading:true};notifications.add(notification);if($settings_changed){settings.reset()}}else{notifications.delete("as3cf-media-settings-locked")}if($assetsNeedsRefresh){_assetsSettingsLocked=true;const notification={id:"as3cf-assets-settings-locked",type:"warning",dismissible:false,only_show_on_tab:"assets",heading:$strings.needs_refresh,icon:"notification-locked.svg",plainHeading:true};notifications.add(notification)}else{notifications.delete("as3cf-assets-settings-locked")}set_store_value(settingsLocked,$settingsLocked=_settingsLocked,$settingsLocked);set_store_value(toolsLocked,$toolsLocked=_toolsLocked,$toolsLocked);set_store_value(assetsSettingsLocked,$assetsSettingsLocked=_assetsSettingsLocked,$assetsSettingsLocked);if($needs_access_keys&&($settings.provider!==$defaultStorageProvider||$settings.bucket.length!==0)){const notification={id:"as3cf-needs-access-keys",type:"error",dismissible:false,only_show_on_tab:"media",hide_on_parent:true,heading:$strings.needs_access_keys,plainHeading:true};notifications.add(notification)}else{notifications.delete("as3cf-needs-access-keys")}}onMount((()=>{handleStateUpdate($config);preStateUpdateCallbacks.update((_callables=>[..._callables,assetsSettings.updateSettings]));postStateUpdateCallbacks.update((_callables=>[..._callables,tools.updateTools,handleStateUpdate]))}));const writable_props=["init"];Object.keys($$props).forEach((key=>{if(!~writable_props.indexOf(key)&&key.slice(0,2)!=="$$"&&key!=="slot")console.warn(`<Settings> was created with unknown prop '${key}'`)}));$$self.$$set=$$props=>{if("init"in $$props)$$invalidate(0,init=$$props.init)};$$self.$capture_state=()=>({onMount:onMount,strings:strings,config:config,defaultStorageProvider:defaultStorageProvider,settingsLocked:settingsLocked,notifications:notifications,current_settings:current_settings,needs_access_keys:needs_access_keys,needs_refresh:needs_refresh,counts:counts,settings_notifications:settings_notifications,settings:settings,settings_changed:settings_changed,preStateUpdateCallbacks:preStateUpdateCallbacks,postStateUpdateCallbacks:postStateUpdateCallbacks,licence:licence,running:running,tools:tools,toolsLocked:toolsLocked,assetsNeedsRefresh:assetsNeedsRefresh,assetsSettingsLocked:assetsSettingsLocked,assetsSettings:assetsSettings,assetsSettingsChanged:assetsSettingsChanged,pages:pages,defaultPages:defaultPages,addPages:addPages,settingsNotifications:settingsNotifications,toolSettingsNotifications:toolSettingsNotifications,Settings:Settings,Header:Header_1,Nav:Nav_1,Pages:Pages,init:init,handleStateUpdate:handleStateUpdate,$licence:$licence,$counts:$counts,$strings:$strings,$current_settings:$current_settings,$settings:$settings,$config:$config,$needs_access_keys:$needs_access_keys,$running:$running,$defaultStorageProvider:$defaultStorageProvider,$assetsSettingsLocked:$assetsSettingsLocked,$toolsLocked:$toolsLocked,$settingsLocked:$settingsLocked,$assetsNeedsRefresh:$assetsNeedsRefresh,$settings_changed:$settings_changed,$tools:$tools,$needs_refresh:$needs_refresh,$assetsSettingsChanged:$assetsSettingsChanged});$$self.$inject_state=$$props=>{if("init"in $$props)$$invalidate(0,init=$$props.init)};if($$props&&"$$inject"in $$props){$$self.$inject_state($$props.$$inject)}$$self.$$.update=()=>{if($$self.$$.dirty&320){if($running){handleStateUpdate($config)}}if($$self.$$.dirty&192){if($needs_access_keys){handleStateUpdate($config)}}if($$self.$$.dirty&56){settings_notifications.update((notices=>settingsNotifications.process(notices,$settings,$current_settings,$strings)))}if($$self.$$.dirty&62){settings_notifications.update((notices=>toolSettingsNotifications.process(notices,$settings,$current_settings,$strings,$counts,$licence)))}};return[init,$licence,$counts,$strings,$current_settings,$settings,$config,$needs_access_keys,$running]}class Settings_1 extends SvelteComponentDev{constructor(options){super(options);init(this,options,instance,create_fragment,safe_not_equal,{init:0});dispatch_dev("SvelteRegisterComponent",{component:this,tagName:"Settings_1",options:options,id:create_fragment.name})}get init(){throw new Error("<Settings>: Props cannot be read directly from the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}set init(value){throw new Error("<Settings>: Props cannot be set directly on the component instance unless compiling with 'accessors: true' or '<svelte:options accessors/>'")}}return Settings_1}));