@telia-ace/widget-side-menu 1.1.110 → 1.1.111-rc.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.js +1 -1
- package/index.mjs +1 -1
- package/package.json +2 -2
- package/side-menu-CzWxcxZ4.js +551 -0
- package/{side-menu-4JEDSkCM.mjs → side-menu-kgmWEmR2.mjs} +1234 -1136
- package/side-menu-CQ_mHxDZ.js +0 -551
|
@@ -0,0 +1,551 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});var Yt=function(i,t){return Yt=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,n){e.__proto__=n}||function(e,n){for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(e[s]=n[s])},Yt(i,t)};function Z(i,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");Yt(i,t);function e(){this.constructor=i}i.prototype=t===null?Object.create(t):(e.prototype=t.prototype,new e)}function rn(i,t,e,n){function s(r){return r instanceof e?r:new e(function(o){o(r)})}return new(e||(e=Promise))(function(r,o){function a(u){try{c(n.next(u))}catch(h){o(h)}}function l(u){try{c(n.throw(u))}catch(h){o(h)}}function c(u){u.done?r(u.value):s(u.value).then(a,l)}c((n=n.apply(i,t||[])).next())})}function si(i,t){var e={label:0,sent:function(){if(r[0]&1)throw r[1];return r[1]},trys:[],ops:[]},n,s,r,o=Object.create((typeof Iterator=="function"?Iterator:Object).prototype);return o.next=a(0),o.throw=a(1),o.return=a(2),typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function a(c){return function(u){return l([c,u])}}function l(c){if(n)throw new TypeError("Generator is already executing.");for(;o&&(o=0,c[0]&&(e=0)),e;)try{if(n=1,s&&(r=c[0]&2?s.return:c[0]?s.throw||((r=s.return)&&r.call(s),0):s.next)&&!(r=r.call(s,c[1])).done)return r;switch(s=0,r&&(c=[c[0]&2,r.value]),c[0]){case 0:case 1:r=c;break;case 4:return e.label++,{value:c[1],done:!1};case 5:e.label++,s=c[1],c=[0];continue;case 7:c=e.ops.pop(),e.trys.pop();continue;default:if(r=e.trys,!(r=r.length>0&&r[r.length-1])&&(c[0]===6||c[0]===2)){e=0;continue}if(c[0]===3&&(!r||c[1]>r[0]&&c[1]<r[3])){e.label=c[1];break}if(c[0]===6&&e.label<r[1]){e.label=r[1],r=c;break}if(r&&e.label<r[2]){e.label=r[2],e.ops.push(c);break}r[2]&&e.ops.pop(),e.trys.pop();continue}c=t.call(i,e)}catch(u){c=[6,u],s=0}finally{n=r=0}if(c[0]&5)throw c[1];return{value:c[0]?c[1]:void 0,done:!0}}}function q(i){var t=typeof Symbol=="function"&&Symbol.iterator,e=t&&i[t],n=0;if(e)return e.call(i);if(i&&typeof i.length=="number")return{next:function(){return i&&n>=i.length&&(i=void 0),{value:i&&i[n++],done:!i}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")}function Wt(i,t){var e=typeof Symbol=="function"&&i[Symbol.iterator];if(!e)return i;var n=e.call(i),s,r=[],o;try{for(;(t===void 0||t-- >0)&&!(s=n.next()).done;)r.push(s.value)}catch(a){o={error:a}}finally{try{s&&!s.done&&(e=n.return)&&e.call(n)}finally{if(o)throw o.error}}return r}function qt(i,t,e){if(e||arguments.length===2)for(var n=0,s=t.length,r;n<s;n++)(r||!(n in t))&&(r||(r=Array.prototype.slice.call(t,0,n)),r[n]=t[n]);return i.concat(r||Array.prototype.slice.call(t))}function F(i){return this instanceof F?(this.v=i,this):new F(i)}function on(i,t,e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n=e.apply(i,t||[]),s,r=[];return s=Object.create((typeof AsyncIterator=="function"?AsyncIterator:Object).prototype),a("next"),a("throw"),a("return",o),s[Symbol.asyncIterator]=function(){return this},s;function o(f){return function($){return Promise.resolve($).then(f,h)}}function a(f,$){n[f]&&(s[f]=function(g){return new Promise(function(ht,Q){r.push([f,g,ht,Q])>1||l(f,g)})},$&&(s[f]=$(s[f])))}function l(f,$){try{c(n[f]($))}catch(g){d(r[0][3],g)}}function c(f){f.value instanceof F?Promise.resolve(f.value.v).then(u,h):d(r[0][2],f)}function u(f){l("next",f)}function h(f){l("throw",f)}function d(f,$){f($),r.shift(),r.length&&l(r[0][0],r[0][1])}}function an(i){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var t=i[Symbol.asyncIterator],e;return t?t.call(i):(i=typeof q=="function"?q(i):i[Symbol.iterator](),e={},n("next"),n("throw"),n("return"),e[Symbol.asyncIterator]=function(){return this},e);function n(r){e[r]=i[r]&&function(o){return new Promise(function(a,l){o=i[r](o),s(a,l,o.done,o.value)})}}function s(r,o,a,l){Promise.resolve(l).then(function(c){r({value:c,done:a})},o)}}function v(i){return typeof i=="function"}function ri(i){var t=function(n){Error.call(n),n.stack=new Error().stack},e=i(t);return e.prototype=Object.create(Error.prototype),e.prototype.constructor=e,e}var Ut=ri(function(i){return function(e){i(this),this.message=e?e.length+` errors occurred during unsubscription:
|
|
2
|
+
`+e.map(function(n,s){return s+1+") "+n.toString()}).join(`
|
|
3
|
+
`):"",this.name="UnsubscriptionError",this.errors=e}});function Gt(i,t){if(i){var e=i.indexOf(t);0<=e&&i.splice(e,1)}}var Et=function(){function i(t){this.initialTeardown=t,this.closed=!1,this._parentage=null,this._finalizers=null}return i.prototype.unsubscribe=function(){var t,e,n,s,r;if(!this.closed){this.closed=!0;var o=this._parentage;if(o)if(this._parentage=null,Array.isArray(o))try{for(var a=q(o),l=a.next();!l.done;l=a.next()){var c=l.value;c.remove(this)}}catch(g){t={error:g}}finally{try{l&&!l.done&&(e=a.return)&&e.call(a)}finally{if(t)throw t.error}}else o.remove(this);var u=this.initialTeardown;if(v(u))try{u()}catch(g){r=g instanceof Ut?g.errors:[g]}var h=this._finalizers;if(h){this._finalizers=null;try{for(var d=q(h),f=d.next();!f.done;f=d.next()){var $=f.value;try{be($)}catch(g){r=r??[],g instanceof Ut?r=qt(qt([],Wt(r)),Wt(g.errors)):r.push(g)}}}catch(g){n={error:g}}finally{try{f&&!f.done&&(s=d.return)&&s.call(d)}finally{if(n)throw n.error}}}if(r)throw new Ut(r)}},i.prototype.add=function(t){var e;if(t&&t!==this)if(this.closed)be(t);else{if(t instanceof i){if(t.closed||t._hasParent(this))return;t._addParent(this)}(this._finalizers=(e=this._finalizers)!==null&&e!==void 0?e:[]).push(t)}},i.prototype._hasParent=function(t){var e=this._parentage;return e===t||Array.isArray(e)&&e.includes(t)},i.prototype._addParent=function(t){var e=this._parentage;this._parentage=Array.isArray(e)?(e.push(t),e):e?[e,t]:t},i.prototype._removeParent=function(t){var e=this._parentage;e===t?this._parentage=null:Array.isArray(e)&&Gt(e,t)},i.prototype.remove=function(t){var e=this._finalizers;e&&Gt(e,t),t instanceof i&&t._removeParent(this)},i.EMPTY=function(){var t=new i;return t.closed=!0,t}(),i}(),oi=Et.EMPTY;function ai(i){return i instanceof Et||i&&"closed"in i&&v(i.remove)&&v(i.add)&&v(i.unsubscribe)}function be(i){v(i)?i():i.unsubscribe()}var li={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1},ci={setTimeout:function(i,t){for(var e=[],n=2;n<arguments.length;n++)e[n-2]=arguments[n];return setTimeout.apply(void 0,qt([i,t],Wt(e)))},clearTimeout:function(i){var t=ci.delegate;return((t==null?void 0:t.clearTimeout)||clearTimeout)(i)},delegate:void 0};function ui(i){ci.setTimeout(function(){throw i})}function _e(){}function pt(i){i()}var te=function(i){Z(t,i);function t(e){var n=i.call(this)||this;return n.isStopped=!1,e?(n.destination=e,ai(e)&&e.add(n)):n.destination=hn,n}return t.create=function(e,n,s){return new Kt(e,n,s)},t.prototype.next=function(e){this.isStopped||this._next(e)},t.prototype.error=function(e){this.isStopped||(this.isStopped=!0,this._error(e))},t.prototype.complete=function(){this.isStopped||(this.isStopped=!0,this._complete())},t.prototype.unsubscribe=function(){this.closed||(this.isStopped=!0,i.prototype.unsubscribe.call(this),this.destination=null)},t.prototype._next=function(e){this.destination.next(e)},t.prototype._error=function(e){try{this.destination.error(e)}finally{this.unsubscribe()}},t.prototype._complete=function(){try{this.destination.complete()}finally{this.unsubscribe()}},t}(Et),ln=Function.prototype.bind;function jt(i,t){return ln.call(i,t)}var cn=function(){function i(t){this.partialObserver=t}return i.prototype.next=function(t){var e=this.partialObserver;if(e.next)try{e.next(t)}catch(n){dt(n)}},i.prototype.error=function(t){var e=this.partialObserver;if(e.error)try{e.error(t)}catch(n){dt(n)}else dt(t)},i.prototype.complete=function(){var t=this.partialObserver;if(t.complete)try{t.complete()}catch(e){dt(e)}},i}(),Kt=function(i){Z(t,i);function t(e,n,s){var r=i.call(this)||this,o;if(v(e)||!e)o={next:e??void 0,error:n??void 0,complete:s??void 0};else{var a;r&&li.useDeprecatedNextContext?(a=Object.create(e),a.unsubscribe=function(){return r.unsubscribe()},o={next:e.next&&jt(e.next,a),error:e.error&&jt(e.error,a),complete:e.complete&&jt(e.complete,a)}):o=e}return r.destination=new cn(o),r}return t}(te);function dt(i){ui(i)}function un(i){throw i}var hn={closed:!0,next:_e,error:un,complete:_e},ee=function(){return typeof Symbol=="function"&&Symbol.observable||"@@observable"}();function hi(i){return i}function dn(i){return i.length===0?hi:i.length===1?i[0]:function(e){return i.reduce(function(n,s){return s(n)},e)}}var _=function(){function i(t){t&&(this._subscribe=t)}return i.prototype.lift=function(t){var e=new i;return e.source=this,e.operator=t,e},i.prototype.subscribe=function(t,e,n){var s=this,r=pn(t)?t:new Kt(t,e,n);return pt(function(){var o=s,a=o.operator,l=o.source;r.add(a?a.call(r,l):l?s._subscribe(r):s._trySubscribe(r))}),r},i.prototype._trySubscribe=function(t){try{return this._subscribe(t)}catch(e){t.error(e)}},i.prototype.forEach=function(t,e){var n=this;return e=we(e),new e(function(s,r){var o=new Kt({next:function(a){try{t(a)}catch(l){r(l),o.unsubscribe()}},error:r,complete:s});n.subscribe(o)})},i.prototype._subscribe=function(t){var e;return(e=this.source)===null||e===void 0?void 0:e.subscribe(t)},i.prototype[ee]=function(){return this},i.prototype.pipe=function(){for(var t=[],e=0;e<arguments.length;e++)t[e]=arguments[e];return dn(t)(this)},i.prototype.toPromise=function(t){var e=this;return t=we(t),new t(function(n,s){var r;e.subscribe(function(o){return r=o},function(o){return s(o)},function(){return n(r)})})},i.create=function(t){return new i(t)},i}();function we(i){var t;return(t=i??li.Promise)!==null&&t!==void 0?t:Promise}function fn(i){return i&&v(i.next)&&v(i.error)&&v(i.complete)}function pn(i){return i&&i instanceof te||fn(i)&&ai(i)}function gn(i){return v(i==null?void 0:i.lift)}function Ct(i){return function(t){if(gn(t))return t.lift(function(e){try{return i(e,this)}catch(n){this.error(n)}});throw new TypeError("Unable to lift unknown Observable type")}}function $t(i,t,e,n,s){return new $n(i,t,e,n,s)}var $n=function(i){Z(t,i);function t(e,n,s,r,o,a){var l=i.call(this,e)||this;return l.onFinalize=o,l.shouldUnsubscribe=a,l._next=n?function(c){try{n(c)}catch(u){e.error(u)}}:i.prototype._next,l._error=r?function(c){try{r(c)}catch(u){e.error(u)}finally{this.unsubscribe()}}:i.prototype._error,l._complete=s?function(){try{s()}catch(c){e.error(c)}finally{this.unsubscribe()}}:i.prototype._complete,l}return t.prototype.unsubscribe=function(){var e;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){var n=this.closed;i.prototype.unsubscribe.call(this),!n&&((e=this.onFinalize)===null||e===void 0||e.call(this))}},t}(te),vn=ri(function(i){return function(){i(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"}}),Ot=function(i){Z(t,i);function t(){var e=i.call(this)||this;return e.closed=!1,e.currentObservers=null,e.observers=[],e.isStopped=!1,e.hasError=!1,e.thrownError=null,e}return t.prototype.lift=function(e){var n=new xe(this,this);return n.operator=e,n},t.prototype._throwIfClosed=function(){if(this.closed)throw new vn},t.prototype.next=function(e){var n=this;pt(function(){var s,r;if(n._throwIfClosed(),!n.isStopped){n.currentObservers||(n.currentObservers=Array.from(n.observers));try{for(var o=q(n.currentObservers),a=o.next();!a.done;a=o.next()){var l=a.value;l.next(e)}}catch(c){s={error:c}}finally{try{a&&!a.done&&(r=o.return)&&r.call(o)}finally{if(s)throw s.error}}}})},t.prototype.error=function(e){var n=this;pt(function(){if(n._throwIfClosed(),!n.isStopped){n.hasError=n.isStopped=!0,n.thrownError=e;for(var s=n.observers;s.length;)s.shift().error(e)}})},t.prototype.complete=function(){var e=this;pt(function(){if(e._throwIfClosed(),!e.isStopped){e.isStopped=!0;for(var n=e.observers;n.length;)n.shift().complete()}})},t.prototype.unsubscribe=function(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null},Object.defineProperty(t.prototype,"observed",{get:function(){var e;return((e=this.observers)===null||e===void 0?void 0:e.length)>0},enumerable:!1,configurable:!0}),t.prototype._trySubscribe=function(e){return this._throwIfClosed(),i.prototype._trySubscribe.call(this,e)},t.prototype._subscribe=function(e){return this._throwIfClosed(),this._checkFinalizedStatuses(e),this._innerSubscribe(e)},t.prototype._innerSubscribe=function(e){var n=this,s=this,r=s.hasError,o=s.isStopped,a=s.observers;return r||o?oi:(this.currentObservers=null,a.push(e),new Et(function(){n.currentObservers=null,Gt(a,e)}))},t.prototype._checkFinalizedStatuses=function(e){var n=this,s=n.hasError,r=n.thrownError,o=n.isStopped;s?e.error(r):o&&e.complete()},t.prototype.asObservable=function(){var e=new _;return e.source=this,e},t.create=function(e,n){return new xe(e,n)},t}(_),xe=function(i){Z(t,i);function t(e,n){var s=i.call(this)||this;return s.destination=e,s.source=n,s}return t.prototype.next=function(e){var n,s;(s=(n=this.destination)===null||n===void 0?void 0:n.next)===null||s===void 0||s.call(n,e)},t.prototype.error=function(e){var n,s;(s=(n=this.destination)===null||n===void 0?void 0:n.error)===null||s===void 0||s.call(n,e)},t.prototype.complete=function(){var e,n;(n=(e=this.destination)===null||e===void 0?void 0:e.complete)===null||n===void 0||n.call(e)},t.prototype._subscribe=function(e){var n,s;return(s=(n=this.source)===null||n===void 0?void 0:n.subscribe(e))!==null&&s!==void 0?s:oi},t}(Ot),di=function(i){Z(t,i);function t(e){var n=i.call(this)||this;return n._value=e,n}return Object.defineProperty(t.prototype,"value",{get:function(){return this.getValue()},enumerable:!1,configurable:!0}),t.prototype._subscribe=function(e){var n=i.prototype._subscribe.call(this,e);return!n.closed&&e.next(this._value),n},t.prototype.getValue=function(){var e=this,n=e.hasError,s=e.thrownError,r=e._value;if(n)throw s;return this._throwIfClosed(),r},t.prototype.next=function(e){i.prototype.next.call(this,this._value=e)},t}(Ot),mn=new _(function(i){return i.complete()});function yn(i){return i&&v(i.schedule)}function fi(i){return i[i.length-1]}function bn(i){return yn(fi(i))?i.pop():void 0}function _n(i,t){return typeof fi(i)=="number"?i.pop():t}var pi=function(i){return i&&typeof i.length=="number"&&typeof i!="function"};function gi(i){return v(i==null?void 0:i.then)}function $i(i){return v(i[ee])}function vi(i){return Symbol.asyncIterator&&v(i==null?void 0:i[Symbol.asyncIterator])}function mi(i){return new TypeError("You provided "+(i!==null&&typeof i=="object"?"an invalid object":"'"+i+"'")+" where a stream was expected. You can provide an Observable, Promise, ReadableStream, Array, AsyncIterable, or Iterable.")}function wn(){return typeof Symbol!="function"||!Symbol.iterator?"@@iterator":Symbol.iterator}var yi=wn();function bi(i){return v(i==null?void 0:i[yi])}function _i(i){return on(this,arguments,function(){var e,n,s,r;return si(this,function(o){switch(o.label){case 0:e=i.getReader(),o.label=1;case 1:o.trys.push([1,,9,10]),o.label=2;case 2:return[4,F(e.read())];case 3:return n=o.sent(),s=n.value,r=n.done,r?[4,F(void 0)]:[3,5];case 4:return[2,o.sent()];case 5:return[4,F(s)];case 6:return[4,o.sent()];case 7:return o.sent(),[3,2];case 8:return[3,10];case 9:return e.releaseLock(),[7];case 10:return[2]}})})}function wi(i){return v(i==null?void 0:i.getReader)}function X(i){if(i instanceof _)return i;if(i!=null){if($i(i))return xn(i);if(pi(i))return Sn(i);if(gi(i))return An(i);if(vi(i))return xi(i);if(bi(i))return kn(i);if(wi(i))return En(i)}throw mi(i)}function xn(i){return new _(function(t){var e=i[ee]();if(v(e.subscribe))return e.subscribe(t);throw new TypeError("Provided object does not correctly implement Symbol.observable")})}function Sn(i){return new _(function(t){for(var e=0;e<i.length&&!t.closed;e++)t.next(i[e]);t.complete()})}function An(i){return new _(function(t){i.then(function(e){t.closed||(t.next(e),t.complete())},function(e){return t.error(e)}).then(null,ui)})}function kn(i){return new _(function(t){var e,n;try{for(var s=q(i),r=s.next();!r.done;r=s.next()){var o=r.value;if(t.next(o),t.closed)return}}catch(a){e={error:a}}finally{try{r&&!r.done&&(n=s.return)&&n.call(s)}finally{if(e)throw e.error}}t.complete()})}function xi(i){return new _(function(t){Cn(i,t).catch(function(e){return t.error(e)})})}function En(i){return xi(_i(i))}function Cn(i,t){var e,n,s,r;return rn(this,void 0,void 0,function(){var o,a;return si(this,function(l){switch(l.label){case 0:l.trys.push([0,5,6,11]),e=an(i),l.label=1;case 1:return[4,e.next()];case 2:if(n=l.sent(),!!n.done)return[3,4];if(o=n.value,t.next(o),t.closed)return[2];l.label=3;case 3:return[3,1];case 4:return[3,11];case 5:return a=l.sent(),s={error:a},[3,11];case 6:return l.trys.push([6,,9,10]),n&&!n.done&&(r=e.return)?[4,r.call(e)]:[3,8];case 7:l.sent(),l.label=8;case 8:return[3,10];case 9:if(s)throw s.error;return[7];case 10:return[7];case 11:return t.complete(),[2]}})})}function L(i,t,e,n,s){n===void 0&&(n=0),s===void 0&&(s=!1);var r=t.schedule(function(){e(),s?i.add(this.schedule(null,n)):this.unsubscribe()},n);if(i.add(r),!s)return r}function Si(i,t){return t===void 0&&(t=0),Ct(function(e,n){e.subscribe($t(n,function(s){return L(n,i,function(){return n.next(s)},t)},function(){return L(n,i,function(){return n.complete()},t)},function(s){return L(n,i,function(){return n.error(s)},t)}))})}function Ai(i,t){return t===void 0&&(t=0),Ct(function(e,n){n.add(i.schedule(function(){return e.subscribe(n)},t))})}function On(i,t){return X(i).pipe(Ai(t),Si(t))}function Tn(i,t){return X(i).pipe(Ai(t),Si(t))}function Pn(i,t){return new _(function(e){var n=0;return t.schedule(function(){n===i.length?e.complete():(e.next(i[n++]),e.closed||this.schedule())})})}function In(i,t){return new _(function(e){var n;return L(e,t,function(){n=i[yi](),L(e,t,function(){var s,r,o;try{s=n.next(),r=s.value,o=s.done}catch(a){e.error(a);return}o?e.complete():e.next(r)},0,!0)}),function(){return v(n==null?void 0:n.return)&&n.return()}})}function ki(i,t){if(!i)throw new Error("Iterable cannot be null");return new _(function(e){L(e,t,function(){var n=i[Symbol.asyncIterator]();L(e,t,function(){n.next().then(function(s){s.done?e.complete():e.next(s.value)})},0,!0)})})}function Ln(i,t){return ki(_i(i),t)}function Rn(i,t){if(i!=null){if($i(i))return On(i,t);if(pi(i))return Pn(i,t);if(gi(i))return Tn(i,t);if(vi(i))return ki(i,t);if(bi(i))return In(i,t);if(wi(i))return Ln(i,t)}throw mi(i)}function Un(i,t){return t?Rn(i,t):X(i)}function jn(i,t){return Ct(function(e,n){var s=0;e.subscribe($t(n,function(r){n.next(i.call(t,r,s++))}))})}function Mn(i,t,e,n,s,r,o,a){var l=[],c=0,u=0,h=!1,d=function(){h&&!l.length&&!c&&t.complete()},f=function(g){return c<n?$(g):l.push(g)},$=function(g){c++;var ht=!1;X(e(g,u++)).subscribe($t(t,function(Q){t.next(Q)},function(){ht=!0},void 0,function(){if(ht)try{c--;for(var Q=function(){var Rt=l.shift();o||$(Rt)};l.length&&c<n;)Q();d()}catch(Rt){t.error(Rt)}}))};return i.subscribe($t(t,f,function(){h=!0,d()})),function(){}}function Ei(i,t,e){return e===void 0&&(e=1/0),v(t)?Ei(function(n,s){return jn(function(r,o){return t(n,r,s,o)})(X(i(n,s)))},e):(typeof t=="number"&&(e=t),Ct(function(n,s){return Mn(n,s,i,e)}))}function Nn(i){return i===void 0&&(i=1/0),Ei(hi,i)}function Bn(){for(var i=[],t=0;t<arguments.length;t++)i[t]=arguments[t];var e=bn(i),n=_n(i,1/0),s=i;return s.length?s.length===1?X(s[0]):Nn(n)(Un(s,e)):mn}/**
|
|
4
|
+
* @license
|
|
5
|
+
* Copyright 2019 Google LLC
|
|
6
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
7
|
+
*/const gt=globalThis,ie=gt.ShadowRoot&&(gt.ShadyCSS===void 0||gt.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,ne=Symbol(),Se=new WeakMap;let Ci=class{constructor(t,e,n){if(this._$cssResult$=!0,n!==ne)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o;const e=this.t;if(ie&&t===void 0){const n=e!==void 0&&e.length===1;n&&(t=Se.get(e)),t===void 0&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),n&&Se.set(e,t))}return t}toString(){return this.cssText}};const Hn=i=>new Ci(typeof i=="string"?i:i+"",void 0,ne),M=(i,...t)=>{const e=i.length===1?i[0]:t.reduce((n,s,r)=>n+(o=>{if(o._$cssResult$===!0)return o.cssText;if(typeof o=="number")return o;throw Error("Value passed to 'css' function must be a 'css' function result: "+o+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(s)+i[r+1],i[0]);return new Ci(e,i,ne)},Dn=(i,t)=>{if(ie)i.adoptedStyleSheets=t.map(e=>e instanceof CSSStyleSheet?e:e.styleSheet);else for(const e of t){const n=document.createElement("style"),s=gt.litNonce;s!==void 0&&n.setAttribute("nonce",s),n.textContent=e.cssText,i.appendChild(n)}},Ae=ie?i=>i:i=>i instanceof CSSStyleSheet?(t=>{let e="";for(const n of t.cssRules)e+=n.cssText;return Hn(e)})(i):i;/**
|
|
8
|
+
* @license
|
|
9
|
+
* Copyright 2017 Google LLC
|
|
10
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
11
|
+
*/const{is:zn,defineProperty:Fn,getOwnPropertyDescriptor:Yn,getOwnPropertyNames:Wn,getOwnPropertySymbols:qn,getPrototypeOf:Gn}=Object,O=globalThis,ke=O.trustedTypes,Kn=ke?ke.emptyScript:"",Mt=O.reactiveElementPolyfillSupport,V=(i,t)=>i,vt={toAttribute(i,t){switch(t){case Boolean:i=i?Kn:null;break;case Object:case Array:i=i==null?i:JSON.stringify(i)}return i},fromAttribute(i,t){let e=i;switch(t){case Boolean:e=i!==null;break;case Number:e=i===null?null:Number(i);break;case Object:case Array:try{e=JSON.parse(i)}catch{e=null}}return e}},se=(i,t)=>!zn(i,t),Ee={attribute:!0,type:String,converter:vt,reflect:!1,hasChanged:se};Symbol.metadata??(Symbol.metadata=Symbol("metadata")),O.litPropertyMetadata??(O.litPropertyMetadata=new WeakMap);let B=class extends HTMLElement{static addInitializer(t){this._$Ei(),(this.l??(this.l=[])).push(t)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,e=Ee){if(e.state&&(e.attribute=!1),this._$Ei(),this.elementProperties.set(t,e),!e.noAccessor){const n=Symbol(),s=this.getPropertyDescriptor(t,n,e);s!==void 0&&Fn(this.prototype,t,s)}}static getPropertyDescriptor(t,e,n){const{get:s,set:r}=Yn(this.prototype,t)??{get(){return this[e]},set(o){this[e]=o}};return{get(){return s==null?void 0:s.call(this)},set(o){const a=s==null?void 0:s.call(this);r.call(this,o),this.requestUpdate(t,a,n)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)??Ee}static _$Ei(){if(this.hasOwnProperty(V("elementProperties")))return;const t=Gn(this);t.finalize(),t.l!==void 0&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(V("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(V("properties"))){const e=this.properties,n=[...Wn(e),...qn(e)];for(const s of n)this.createProperty(s,e[s])}const t=this[Symbol.metadata];if(t!==null){const e=litPropertyMetadata.get(t);if(e!==void 0)for(const[n,s]of e)this.elementProperties.set(n,s)}this._$Eh=new Map;for(const[e,n]of this.elementProperties){const s=this._$Eu(e,n);s!==void 0&&this._$Eh.set(s,e)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){const e=[];if(Array.isArray(t)){const n=new Set(t.flat(1/0).reverse());for(const s of n)e.unshift(Ae(s))}else t!==void 0&&e.push(Ae(t));return e}static _$Eu(t,e){const n=e.attribute;return n===!1?void 0:typeof n=="string"?n:typeof t=="string"?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){var t;this._$ES=new Promise(e=>this.enableUpdating=e),this._$AL=new Map,this._$E_(),this.requestUpdate(),(t=this.constructor.l)==null||t.forEach(e=>e(this))}addController(t){var e;(this._$EO??(this._$EO=new Set)).add(t),this.renderRoot!==void 0&&this.isConnected&&((e=t.hostConnected)==null||e.call(t))}removeController(t){var e;(e=this._$EO)==null||e.delete(t)}_$E_(){const t=new Map,e=this.constructor.elementProperties;for(const n of e.keys())this.hasOwnProperty(n)&&(t.set(n,this[n]),delete this[n]);t.size>0&&(this._$Ep=t)}createRenderRoot(){const t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return Dn(t,this.constructor.elementStyles),t}connectedCallback(){var t;this.renderRoot??(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),(t=this._$EO)==null||t.forEach(e=>{var n;return(n=e.hostConnected)==null?void 0:n.call(e)})}enableUpdating(t){}disconnectedCallback(){var t;(t=this._$EO)==null||t.forEach(e=>{var n;return(n=e.hostDisconnected)==null?void 0:n.call(e)})}attributeChangedCallback(t,e,n){this._$AK(t,n)}_$EC(t,e){var r;const n=this.constructor.elementProperties.get(t),s=this.constructor._$Eu(t,n);if(s!==void 0&&n.reflect===!0){const o=(((r=n.converter)==null?void 0:r.toAttribute)!==void 0?n.converter:vt).toAttribute(e,n.type);this._$Em=t,o==null?this.removeAttribute(s):this.setAttribute(s,o),this._$Em=null}}_$AK(t,e){var r;const n=this.constructor,s=n._$Eh.get(t);if(s!==void 0&&this._$Em!==s){const o=n.getPropertyOptions(s),a=typeof o.converter=="function"?{fromAttribute:o.converter}:((r=o.converter)==null?void 0:r.fromAttribute)!==void 0?o.converter:vt;this._$Em=s,this[s]=a.fromAttribute(e,o.type),this._$Em=null}}requestUpdate(t,e,n){if(t!==void 0){if(n??(n=this.constructor.getPropertyOptions(t)),!(n.hasChanged??se)(this[t],e))return;this.P(t,e,n)}this.isUpdatePending===!1&&(this._$ES=this._$ET())}P(t,e,n){this._$AL.has(t)||this._$AL.set(t,e),n.reflect===!0&&this._$Em!==t&&(this._$Ej??(this._$Ej=new Set)).add(t)}async _$ET(){this.isUpdatePending=!0;try{await this._$ES}catch(e){Promise.reject(e)}const t=this.scheduleUpdate();return t!=null&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var n;if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??(this.renderRoot=this.createRenderRoot()),this._$Ep){for(const[r,o]of this._$Ep)this[r]=o;this._$Ep=void 0}const s=this.constructor.elementProperties;if(s.size>0)for(const[r,o]of s)o.wrapped!==!0||this._$AL.has(r)||this[r]===void 0||this.P(r,this[r],o)}let t=!1;const e=this._$AL;try{t=this.shouldUpdate(e),t?(this.willUpdate(e),(n=this._$EO)==null||n.forEach(s=>{var r;return(r=s.hostUpdate)==null?void 0:r.call(s)}),this.update(e)):this._$EU()}catch(s){throw t=!1,this._$EU(),s}t&&this._$AE(e)}willUpdate(t){}_$AE(t){var e;(e=this._$EO)==null||e.forEach(n=>{var s;return(s=n.hostUpdated)==null?void 0:s.call(n)}),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$EU(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(t){return!0}update(t){this._$Ej&&(this._$Ej=this._$Ej.forEach(e=>this._$EC(e,this[e]))),this._$EU()}updated(t){}firstUpdated(t){}};B.elementStyles=[],B.shadowRootOptions={mode:"open"},B[V("elementProperties")]=new Map,B[V("finalized")]=new Map,Mt==null||Mt({ReactiveElement:B}),(O.reactiveElementVersions??(O.reactiveElementVersions=[])).push("2.0.4");/**
|
|
12
|
+
* @license
|
|
13
|
+
* Copyright 2017 Google LLC
|
|
14
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
15
|
+
*/const tt=globalThis,mt=tt.trustedTypes,Ce=mt?mt.createPolicy("lit-html",{createHTML:i=>i}):void 0,Oi="$lit$",C=`lit$${Math.random().toFixed(9).slice(2)}$`,Ti="?"+C,Zn=`<${Ti}>`,R=document,it=()=>R.createComment(""),nt=i=>i===null||typeof i!="object"&&typeof i!="function",re=Array.isArray,Xn=i=>re(i)||typeof(i==null?void 0:i[Symbol.iterator])=="function",Nt=`[
|
|
16
|
+
\f\r]`,J=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,Oe=/-->/g,Te=/>/g,T=RegExp(`>|${Nt}(?:([^\\s"'>=/]+)(${Nt}*=${Nt}*(?:[^
|
|
17
|
+
\f\r"'\`<>=]|("|')|))|$)`,"g"),Pe=/'/g,Ie=/"/g,Pi=/^(?:script|style|textarea|title)$/i,Qn=i=>(t,...e)=>({_$litType$:i,strings:t,values:e}),k=Qn(1),U=Symbol.for("lit-noChange"),p=Symbol.for("lit-nothing"),Le=new WeakMap,I=R.createTreeWalker(R,129);function Ii(i,t){if(!re(i)||!i.hasOwnProperty("raw"))throw Error("invalid template strings array");return Ce!==void 0?Ce.createHTML(t):t}const Jn=(i,t)=>{const e=i.length-1,n=[];let s,r=t===2?"<svg>":t===3?"<math>":"",o=J;for(let a=0;a<e;a++){const l=i[a];let c,u,h=-1,d=0;for(;d<l.length&&(o.lastIndex=d,u=o.exec(l),u!==null);)d=o.lastIndex,o===J?u[1]==="!--"?o=Oe:u[1]!==void 0?o=Te:u[2]!==void 0?(Pi.test(u[2])&&(s=RegExp("</"+u[2],"g")),o=T):u[3]!==void 0&&(o=T):o===T?u[0]===">"?(o=s??J,h=-1):u[1]===void 0?h=-2:(h=o.lastIndex-u[2].length,c=u[1],o=u[3]===void 0?T:u[3]==='"'?Ie:Pe):o===Ie||o===Pe?o=T:o===Oe||o===Te?o=J:(o=T,s=void 0);const f=o===T&&i[a+1].startsWith("/>")?" ":"";r+=o===J?l+Zn:h>=0?(n.push(c),l.slice(0,h)+Oi+l.slice(h)+C+f):l+C+(h===-2?a:f)}return[Ii(i,r+(i[e]||"<?>")+(t===2?"</svg>":t===3?"</math>":"")),n]};let Zt=class Li{constructor({strings:t,_$litType$:e},n){let s;this.parts=[];let r=0,o=0;const a=t.length-1,l=this.parts,[c,u]=Jn(t,e);if(this.el=Li.createElement(c,n),I.currentNode=this.el.content,e===2||e===3){const h=this.el.content.firstChild;h.replaceWith(...h.childNodes)}for(;(s=I.nextNode())!==null&&l.length<a;){if(s.nodeType===1){if(s.hasAttributes())for(const h of s.getAttributeNames())if(h.endsWith(Oi)){const d=u[o++],f=s.getAttribute(h).split(C),$=/([.?@])?(.*)/.exec(d);l.push({type:1,index:r,name:$[2],strings:f,ctor:$[1]==="."?ts:$[1]==="?"?es:$[1]==="@"?is:Tt}),s.removeAttribute(h)}else h.startsWith(C)&&(l.push({type:6,index:r}),s.removeAttribute(h));if(Pi.test(s.tagName)){const h=s.textContent.split(C),d=h.length-1;if(d>0){s.textContent=mt?mt.emptyScript:"";for(let f=0;f<d;f++)s.append(h[f],it()),I.nextNode(),l.push({type:2,index:++r});s.append(h[d],it())}}}else if(s.nodeType===8)if(s.data===Ti)l.push({type:2,index:r});else{let h=-1;for(;(h=s.data.indexOf(C,h+1))!==-1;)l.push({type:7,index:r}),h+=C.length-1}r++}}static createElement(t,e){const n=R.createElement("template");return n.innerHTML=t,n}};function G(i,t,e=i,n){var o,a;if(t===U)return t;let s=n!==void 0?(o=e._$Co)==null?void 0:o[n]:e._$Cl;const r=nt(t)?void 0:t._$litDirective$;return(s==null?void 0:s.constructor)!==r&&((a=s==null?void 0:s._$AO)==null||a.call(s,!1),r===void 0?s=void 0:(s=new r(i),s._$AT(i,e,n)),n!==void 0?(e._$Co??(e._$Co=[]))[n]=s:e._$Cl=s),s!==void 0&&(t=G(i,s._$AS(i,t.values),s,n)),t}class Vn{constructor(t,e){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:e},parts:n}=this._$AD,s=((t==null?void 0:t.creationScope)??R).importNode(e,!0);I.currentNode=s;let r=I.nextNode(),o=0,a=0,l=n[0];for(;l!==void 0;){if(o===l.index){let c;l.type===2?c=new lt(r,r.nextSibling,this,t):l.type===1?c=new l.ctor(r,l.name,l.strings,this,t):l.type===6&&(c=new ns(r,this,t)),this._$AV.push(c),l=n[++a]}o!==(l==null?void 0:l.index)&&(r=I.nextNode(),o++)}return I.currentNode=R,s}p(t){let e=0;for(const n of this._$AV)n!==void 0&&(n.strings!==void 0?(n._$AI(t,n,e),e+=n.strings.length-2):n._$AI(t[e])),e++}}class lt{get _$AU(){var t;return((t=this._$AM)==null?void 0:t._$AU)??this._$Cv}constructor(t,e,n,s){this.type=2,this._$AH=p,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=n,this.options=s,this._$Cv=(s==null?void 0:s.isConnected)??!0}get parentNode(){let t=this._$AA.parentNode;const e=this._$AM;return e!==void 0&&(t==null?void 0:t.nodeType)===11&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=G(this,t,e),nt(t)?t===p||t==null||t===""?(this._$AH!==p&&this._$AR(),this._$AH=p):t!==this._$AH&&t!==U&&this._(t):t._$litType$!==void 0?this.$(t):t.nodeType!==void 0?this.T(t):Xn(t)?this.k(t):this._(t)}O(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t))}_(t){this._$AH!==p&&nt(this._$AH)?this._$AA.nextSibling.data=t:this.T(R.createTextNode(t)),this._$AH=t}$(t){var r;const{values:e,_$litType$:n}=t,s=typeof n=="number"?this._$AC(t):(n.el===void 0&&(n.el=Zt.createElement(Ii(n.h,n.h[0]),this.options)),n);if(((r=this._$AH)==null?void 0:r._$AD)===s)this._$AH.p(e);else{const o=new Vn(s,this),a=o.u(this.options);o.p(e),this.T(a),this._$AH=o}}_$AC(t){let e=Le.get(t.strings);return e===void 0&&Le.set(t.strings,e=new Zt(t)),e}k(t){re(this._$AH)||(this._$AH=[],this._$AR());const e=this._$AH;let n,s=0;for(const r of t)s===e.length?e.push(n=new lt(this.O(it()),this.O(it()),this,this.options)):n=e[s],n._$AI(r),s++;s<e.length&&(this._$AR(n&&n._$AB.nextSibling,s),e.length=s)}_$AR(t=this._$AA.nextSibling,e){var n;for((n=this._$AP)==null?void 0:n.call(this,!1,!0,e);t&&t!==this._$AB;){const s=t.nextSibling;t.remove(),t=s}}setConnected(t){var e;this._$AM===void 0&&(this._$Cv=t,(e=this._$AP)==null||e.call(this,t))}}class Tt{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,n,s,r){this.type=1,this._$AH=p,this._$AN=void 0,this.element=t,this.name=e,this._$AM=s,this.options=r,n.length>2||n[0]!==""||n[1]!==""?(this._$AH=Array(n.length-1).fill(new String),this.strings=n):this._$AH=p}_$AI(t,e=this,n,s){const r=this.strings;let o=!1;if(r===void 0)t=G(this,t,e,0),o=!nt(t)||t!==this._$AH&&t!==U,o&&(this._$AH=t);else{const a=t;let l,c;for(t=r[0],l=0;l<r.length-1;l++)c=G(this,a[n+l],e,l),c===U&&(c=this._$AH[l]),o||(o=!nt(c)||c!==this._$AH[l]),c===p?t=p:t!==p&&(t+=(c??"")+r[l+1]),this._$AH[l]=c}o&&!s&&this.j(t)}j(t){t===p?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}}let ts=class extends Tt{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===p?void 0:t}};class es extends Tt{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==p)}}class is extends Tt{constructor(t,e,n,s,r){super(t,e,n,s,r),this.type=5}_$AI(t,e=this){if((t=G(this,t,e,0)??p)===U)return;const n=this._$AH,s=t===p&&n!==p||t.capture!==n.capture||t.once!==n.once||t.passive!==n.passive,r=t!==p&&(n===p||s);s&&this.element.removeEventListener(this.name,this,n),r&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var e;typeof this._$AH=="function"?this._$AH.call(((e=this.options)==null?void 0:e.host)??this.element,t):this._$AH.handleEvent(t)}}class ns{constructor(t,e,n){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=n}get _$AU(){return this._$AM._$AU}_$AI(t){G(this,t)}}const Bt=tt.litHtmlPolyfillSupport;Bt==null||Bt(Zt,lt),(tt.litHtmlVersions??(tt.litHtmlVersions=[])).push("3.2.1");const ss=(i,t,e)=>{const n=(e==null?void 0:e.renderBefore)??t;let s=n._$litPart$;if(s===void 0){const r=(e==null?void 0:e.renderBefore)??null;n._$litPart$=s=new lt(t.insertBefore(it(),r),r,void 0,e??{})}return s._$AI(i),s};/**
|
|
18
|
+
* @license
|
|
19
|
+
* Copyright 2017 Google LLC
|
|
20
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
21
|
+
*/let x=class extends B{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){var e;const t=super.createRenderRoot();return(e=this.renderOptions).renderBefore??(e.renderBefore=t.firstChild),t}update(t){const e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=ss(e,this.renderRoot,this.renderOptions)}connectedCallback(){var t;super.connectedCallback(),(t=this._$Do)==null||t.setConnected(!0)}disconnectedCallback(){var t;super.disconnectedCallback(),(t=this._$Do)==null||t.setConnected(!1)}render(){return U}};var ni;x._$litElement$=!0,x.finalized=!0,(ni=globalThis.litElementHydrateSupport)==null||ni.call(globalThis,{LitElement:x});const Ht=globalThis.litElementPolyfillSupport;Ht==null||Ht({LitElement:x});(globalThis.litElementVersions??(globalThis.litElementVersions=[])).push("4.1.1");/**
|
|
22
|
+
* @license
|
|
23
|
+
* Copyright 2017 Google LLC
|
|
24
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
25
|
+
*/const rs={attribute:!0,type:String,converter:vt,reflect:!1,hasChanged:se},os=(i=rs,t,e)=>{const{kind:n,metadata:s}=e;let r=globalThis.litPropertyMetadata.get(s);if(r===void 0&&globalThis.litPropertyMetadata.set(s,r=new Map),r.set(e.name,i),n==="accessor"){const{name:o}=e;return{set(a){const l=t.get.call(this);t.set.call(this,a),this.requestUpdate(o,l,i)},init(a){return a!==void 0&&this.P(o,void 0,i),a}}}if(n==="setter"){const{name:o}=e;return function(a){const l=this[o];t.call(this,a),this.requestUpdate(o,l,i)}}throw Error("Unsupported decorator location: "+n)};function b(i){return(t,e)=>typeof e=="object"?os(i,t,e):((n,s,r)=>{const o=s.hasOwnProperty(r);return s.constructor.createProperty(r,o?{...n,wrapped:!0}:n),o?Object.getOwnPropertyDescriptor(s,r):void 0})(i,t,e)}/**
|
|
26
|
+
* @license
|
|
27
|
+
* Copyright 2017 Google LLC
|
|
28
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
29
|
+
*/function N(i){return b({...i,state:!0,attribute:!1})}var as=Object.defineProperty,ls=(i,t,e,n)=>{for(var s=void 0,r=i.length-1,o;r>=0;r--)(o=i[r])&&(s=o(t,e,s)||s);return s&&as(t,e,s),s};const pe=class pe extends x{constructor(){super(...arguments),this.anchor="BottomRight"}appendChild(t){var e;return(e=this.shadowRoot)==null||e.appendChild(t),t}render(){return this.anchor==="BottomLeft"?this.renderRoot.host.classList.add("bottom-left"):this.anchor==="BottomRight"&&this.renderRoot.host.classList.add("bottom-right"),p}};pe.styles=[M`
|
|
30
|
+
:host {
|
|
31
|
+
position: fixed;
|
|
32
|
+
display: flex;
|
|
33
|
+
align-items: center;
|
|
34
|
+
gap: 1rem;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
:host(.bottom-right) {
|
|
38
|
+
bottom: 20px;
|
|
39
|
+
right: 20px;
|
|
40
|
+
}
|
|
41
|
+
:host(.bottom-left) {
|
|
42
|
+
bottom: 20px;
|
|
43
|
+
left: 20px;
|
|
44
|
+
}
|
|
45
|
+
`];let yt=pe;ls([b({attribute:!0})],yt.prototype,"anchor");/**
|
|
46
|
+
* @license
|
|
47
|
+
* Copyright 2017 Google LLC
|
|
48
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
49
|
+
*/const oe={ATTRIBUTE:1,CHILD:2,PROPERTY:3,BOOLEAN_ATTRIBUTE:4,EVENT:5,ELEMENT:6},ae=i=>(...t)=>({_$litDirective$:i,values:t});let Ri=class{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,e,n){this._$Ct=t,this._$AM=e,this._$Ci=n}_$AS(t,e){return this.update(t,e)}update(t,e){return this.render(...e)}};/**
|
|
50
|
+
* @license
|
|
51
|
+
* Copyright 2020 Google LLC
|
|
52
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
53
|
+
*/const cs=i=>i.strings===void 0;/**
|
|
54
|
+
* @license
|
|
55
|
+
* Copyright 2017 Google LLC
|
|
56
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
57
|
+
*/const et=(i,t)=>{var n;const e=i._$AN;if(e===void 0)return!1;for(const s of e)(n=s._$AO)==null||n.call(s,t,!1),et(s,t);return!0},bt=i=>{let t,e;do{if((t=i._$AM)===void 0)break;e=t._$AN,e.delete(i),i=t}while((e==null?void 0:e.size)===0)},Ui=i=>{for(let t;t=i._$AM;i=t){let e=t._$AN;if(e===void 0)t._$AN=e=new Set;else if(e.has(i))break;e.add(i),ds(t)}};function us(i){this._$AN!==void 0?(bt(this),this._$AM=i,Ui(this)):this._$AM=i}function hs(i,t=!1,e=0){const n=this._$AH,s=this._$AN;if(s!==void 0&&s.size!==0)if(t)if(Array.isArray(n))for(let r=e;r<n.length;r++)et(n[r],!1),bt(n[r]);else n!=null&&(et(n,!1),bt(n));else et(this,i)}const ds=i=>{i.type==oe.CHILD&&(i._$AP??(i._$AP=hs),i._$AQ??(i._$AQ=us))};class ji extends Ri{constructor(){super(...arguments),this._$AN=void 0}_$AT(t,e,n){super._$AT(t,e,n),Ui(this),this.isConnected=t._$AU}_$AO(t,e=!0){var n,s;t!==this.isConnected&&(this.isConnected=t,t?(n=this.reconnected)==null||n.call(this):(s=this.disconnected)==null||s.call(this)),e&&(et(this,t),bt(this))}setValue(t){if(cs(this._$Ct))this._$Ct._$AI(t,this);else{const e=[...this._$Ct._$AH];e[this._$Ci]=t,this._$Ct._$AI(e,this,0)}}disconnected(){}reconnected(){}}const fs=new WeakMap;let Re=0;const Dt=new Map,Ue=new WeakSet,je=()=>new Promise(i=>requestAnimationFrame(i)),Me=[{transform:"translateY(-100%) scale(0)",opacity:0}],ps=[{transform:"translateX(100%) scale(0)",opacity:0}],Ne=(i,t)=>{const e=i-t;return e===0?void 0:e},Be=(i,t)=>{const e=i/t;return e===1?void 0:e},zt={left:(i,t)=>{const e=Ne(i,t);return{value:e,transform:e==null||isNaN(e)?void 0:`translateX(${e}px)`}},top:(i,t)=>{const e=Ne(i,t);return{value:e,transform:e==null||isNaN(e)?void 0:`translateY(${e}px)`}},width:(i,t)=>{let e;t===0&&(t=1,e={width:"1px"});const n=Be(i,t);return{value:n,overrideFrom:e,transform:n==null||isNaN(n)?void 0:`scaleX(${n})`}},height:(i,t)=>{let e;t===0&&(t=1,e={height:"1px"});const n=Be(i,t);return{value:n,overrideFrom:e,transform:n==null||isNaN(n)?void 0:`scaleY(${n})`}}},gs={duration:333,easing:"ease-in-out"},$s=["left","top","width","height","opacity","color","background"],He=new WeakMap;class vs extends ji{constructor(t){if(super(t),this.t=!1,this.i=null,this.o=null,this.h=!0,this.shouldLog=!1,t.type===oe.CHILD)throw Error("The `animate` directive must be used in attribute position.");this.createFinished()}createFinished(){var t;(t=this.resolveFinished)==null||t.call(this),this.finished=new Promise(e=>{this.l=e})}async resolveFinished(){var t;(t=this.l)==null||t.call(this),this.l=void 0}render(t){return p}getController(){return fs.get(this.u)}isDisabled(){var t;return this.options.disabled||((t=this.getController())==null?void 0:t.disabled)}update(t,[e]){var s;const n=this.u===void 0;return n&&(this.u=(s=t.options)==null?void 0:s.host,this.u.addController(this),this.u.updateComplete.then(r=>this.t=!0),this.element=t.element,He.set(this.element,this)),this.optionsOrCallback=e,(n||typeof e!="function")&&this.p(e),this.render(e)}p(t){t=t??{};const e=this.getController();e!==void 0&&((t={...e.defaultOptions,...t}).keyframeOptions={...e.defaultOptions.keyframeOptions,...t.keyframeOptions}),t.properties??(t.properties=$s),this.options=t}m(){const t={},e=this.element.getBoundingClientRect(),n=getComputedStyle(this.element);return this.options.properties.forEach(s=>{const r=e[s]??(zt[s]?void 0:n[s]),o=Number(r);t[s]=isNaN(o)?r+"":o}),t}v(){let t,e=!0;return this.options.guard&&(t=this.options.guard(),e=((n,s)=>{if(Array.isArray(n)){if(Array.isArray(s)&&s.length===n.length&&n.every((r,o)=>r===s[o]))return!1}else if(s===n)return!1;return!0})(t,this._)),this.h=this.t&&!this.isDisabled()&&!this.isAnimating()&&e&&this.element.isConnected,this.h&&(this._=Array.isArray(t)?Array.from(t):t),this.h}hostUpdate(){typeof this.optionsOrCallback=="function"&&this.p(this.optionsOrCallback()),this.v()&&(this.A=this.m(),this.i=this.i??this.element.parentNode,this.o=this.element.nextSibling)}async hostUpdated(){if(!this.h||!this.element.isConnected||this.options.skipInitial&&!this.isHostRendered)return;let t;this.prepare(),await je;const e=this.O(),n=this.j(this.options.keyframeOptions,e),s=this.m();if(this.A!==void 0){const{from:r,to:o}=this.N(this.A,s,e);this.log("measured",[this.A,s,r,o]),t=this.calculateKeyframes(r,o)}else{const r=Dt.get(this.options.inId);if(r){Dt.delete(this.options.inId);const{from:o,to:a}=this.N(r,s,e);t=this.calculateKeyframes(o,a),t=this.options.in?[{...this.options.in[0],...t[0]},...this.options.in.slice(1),t[1]]:t,Re++,t.forEach(l=>l.zIndex=Re)}else this.options.in&&(t=[...this.options.in,{}])}this.animate(t,n)}resetStyles(){this.P!==void 0&&(this.element.setAttribute("style",this.P??""),this.P=void 0)}commitStyles(){var t,e;this.P=this.element.getAttribute("style"),(t=this.webAnimation)==null||t.commitStyles(),(e=this.webAnimation)==null||e.cancel()}reconnected(){}async disconnected(){var e;if(!this.h||(this.options.id!==void 0&&Dt.set(this.options.id,this.A),this.options.out===void 0))return;if(this.prepare(),await je(),(e=this.i)==null?void 0:e.isConnected){const n=this.o&&this.o.parentNode===this.i?this.o:null;if(this.i.insertBefore(this.element,n),this.options.stabilizeOut){const s=this.m();this.log("stabilizing out");const r=this.A.left-s.left,o=this.A.top-s.top;getComputedStyle(this.element).position!=="static"||r===0&&o===0||(this.element.style.position="relative"),r!==0&&(this.element.style.left=r+"px"),o!==0&&(this.element.style.top=o+"px")}}const t=this.j(this.options.keyframeOptions);await this.animate(this.options.out,t),this.element.remove()}prepare(){this.createFinished()}start(){var t,e;(e=(t=this.options).onStart)==null||e.call(t,this)}didFinish(t){var e,n;t&&((n=(e=this.options).onComplete)==null||n.call(e,this)),this.A=void 0,this.animatingProperties=void 0,this.frames=void 0,this.resolveFinished()}O(){const t=[];for(let e=this.element.parentNode;e;e=e==null?void 0:e.parentNode){const n=He.get(e);n&&!n.isDisabled()&&n&&t.push(n)}return t}get isHostRendered(){const t=Ue.has(this.u);return t||this.u.updateComplete.then(()=>{Ue.add(this.u)}),t}j(t,e=this.O()){const n={...gs};return e.forEach(s=>Object.assign(n,s.options.keyframeOptions)),Object.assign(n,t),n}N(t,e,n){t={...t},e={...e};const s=n.map(a=>a.animatingProperties).filter(a=>a!==void 0);let r=1,o=1;return s.length>0&&(s.forEach(a=>{a.width&&(r/=a.width),a.height&&(o/=a.height)}),t.left!==void 0&&e.left!==void 0&&(t.left=r*t.left,e.left=r*e.left),t.top!==void 0&&e.top!==void 0&&(t.top=o*t.top,e.top=o*e.top)),{from:t,to:e}}calculateKeyframes(t,e,n=!1){const s={},r={};let o=!1;const a={};for(const l in e){const c=t[l],u=e[l];if(l in zt){const h=zt[l];if(c===void 0||u===void 0)continue;const d=h(c,u);d.transform!==void 0&&(a[l]=d.value,o=!0,s.transform=`${s.transform??""} ${d.transform}`,d.overrideFrom!==void 0&&Object.assign(s,d.overrideFrom))}else c!==u&&c!==void 0&&u!==void 0&&(o=!0,s[l]=c,r[l]=u)}return s.transformOrigin=r.transformOrigin=n?"center center":"top left",this.animatingProperties=a,o?[s,r]:void 0}async animate(t,e=this.options.keyframeOptions){this.start(),this.frames=t;let n=!1;if(!this.isAnimating()&&!this.isDisabled()&&(this.options.onFrames&&(this.frames=t=this.options.onFrames(this),this.log("modified frames",t)),t!==void 0)){this.log("animate",[t,e]),n=!0,this.webAnimation=this.element.animate(t,e);const s=this.getController();s==null||s.add(this);try{await this.webAnimation.finished}catch{}s==null||s.remove(this)}return this.didFinish(n),n}isAnimating(){var t,e;return((t=this.webAnimation)==null?void 0:t.playState)==="running"||((e=this.webAnimation)==null?void 0:e.pending)}log(t,e){this.shouldLog&&!this.isDisabled()&&console.log(t,this.options.id,e)}}const Mi=ae(vs),ms={name:"question",svg:'<svg viewBox="0 0 64 64" xmlns="http://www.w3.org/2000/svg" fill="currentColor"><path fill-rule="evenodd" clip-rule="evenodd" d="M32 4C16.536 4 4 16.536 4 32C4 47.464 16.536 60 32 60C47.464 60 60 47.464 60 32C59.9827 16.5432 47.4568 4.01731 32 4ZM32 55.6923C18.9151 55.6923 8.30769 45.0849 8.30769 32C8.30769 18.9151 18.9151 8.30769 32 8.30769C45.0849 8.30769 55.6923 18.9151 55.6923 32C55.6775 45.0788 45.0788 55.6775 32 55.6923Z"/><path fill-rule="evenodd" clip-rule="evenodd" d="M31.9423 37.5723L36.311 32.9068L36.7354 32.4448C39.7555 29.1161 40.7645 27.0647 40.7645 24.5087C40.7645 23.1091 40.4251 21.7942 39.7041 20.6491C38.3044 18.3587 35.6323 16.9166 32.2816 16.9166C28.7565 16.9166 25.3125 18.7414 23.2581 21.6772L23.1201 21.8791C22.8232 22.3032 22.696 22.6849 22.696 22.9818C22.696 23.7029 23.926 25.9932 25.2833 25.9932C25.5378 25.9932 25.7922 25.9084 26.0467 25.7388C26.2588 25.5691 26.5981 25.2298 27.0647 24.7208C28.8885 22.6849 30.1185 21.9215 31.7726 21.9215C33.6813 21.9215 35.081 23.1939 35.081 24.8905C35.081 26.375 34.2751 27.7746 32.3664 29.8529L28.2523 34.2216C27.9554 34.6033 27.7857 34.9426 27.7857 35.282C27.7857 35.6213 27.9978 36.1726 28.4219 36.8937C29.0581 37.8692 29.7368 38.3782 30.4578 38.3782C30.9244 38.3782 31.3909 38.1237 31.9423 37.5723ZM30.882 47.4972C29.2278 47.4972 27.6585 44.7403 27.6585 43.6799C27.6585 42.1954 30.0761 40.6261 32.4089 40.6261C33.6389 40.6261 34.2751 41.1775 34.2751 42.3227C34.2751 44.0616 33.4692 45.843 32.4513 46.7761C31.9423 47.2427 31.4334 47.4972 30.882 47.4972Z"/></svg>'};/**
|
|
58
|
+
* @license
|
|
59
|
+
* Copyright 2018 Google LLC
|
|
60
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
61
|
+
*/const De=ae(class extends Ri{constructor(i){var t;if(super(i),i.type!==oe.ATTRIBUTE||i.name!=="class"||((t=i.strings)==null?void 0:t.length)>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(i){return" "+Object.keys(i).filter(t=>i[t]).join(" ")+" "}update(i,[t]){var n,s;if(this.st===void 0){this.st=new Set,i.strings!==void 0&&(this.nt=new Set(i.strings.join(" ").split(/\s/).filter(r=>r!=="")));for(const r in t)t[r]&&!((n=this.nt)!=null&&n.has(r))&&this.st.add(r);return this.render(t)}const e=i.element.classList;for(const r of this.st)r in t||(e.remove(r),this.st.delete(r));for(const r in t){const o=!!t[r];o===this.st.has(r)||(s=this.nt)!=null&&s.has(r)||(o?(e.add(r),this.st.add(r)):(e.remove(r),this.st.delete(r)))}return U}}),A=(i,t,e)=>{i&&e.style.setProperty(t,i)},Ni=(i,t)=>{var e,n,s,r,o,a,l,c,u;A((e=i.colors)==null?void 0:e.primaryBackground,"--primary-background",t),A((n=i.colors)==null?void 0:n.textOnPrimaryBackground,"--text-on-primary-background",t),A((s=i.colors)==null?void 0:s.secondaryBackground,"--secondary-background",t),A((r=i.colors)==null?void 0:r.textOnSecondaryBackground,"--text-on-secondary-background",t),A((o=i.colors)==null?void 0:o.interactiveDestructiveBackground,"--destructive-color",t),A((a=i.colors)==null?void 0:a.interactiveTextOnDestructiveBackground,"--text-on-destructive-color",t),A((l=i.colors)==null?void 0:l.interactivePrimaryBackground,"--interactive-primary-background",t),A((c=i.colors)==null?void 0:c.interactiveTextOnPrimaryBackground,"--interactive-text-on-primary-background",t),A((u=i.colors)==null?void 0:u.focusColor,"--focus-color",t)};/**
|
|
62
|
+
* @license
|
|
63
|
+
* Copyright 2020 Google LLC
|
|
64
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
65
|
+
*/const _t=()=>new ys;let ys=class{};const Ft=new WeakMap,le=ae(class extends ji{render(i){return p}update(i,[t]){var n;const e=t!==this.Y;return e&&this.Y!==void 0&&this.rt(void 0),(e||this.lt!==this.ct)&&(this.Y=t,this.ht=(n=i.options)==null?void 0:n.host,this.rt(this.ct=i.element)),p}rt(i){if(this.isConnected||(i=void 0),typeof this.Y=="function"){const t=this.ht??globalThis;let e=Ft.get(t);e===void 0&&(e=new WeakMap,Ft.set(t,e)),e.get(this.Y)!==void 0&&this.Y.call(this.ht,void 0),e.set(this.Y,i),i!==void 0&&this.Y.call(this.ht,i)}else this.Y.value=i}get lt(){var i,t;return typeof this.Y=="function"?(i=Ft.get(this.ht??globalThis))==null?void 0:i.get(this.Y):(t=this.Y)==null?void 0:t.value}disconnected(){this.lt===this.ct&&this.rt(void 0)}reconnected(){this.rt(this.ct)}});var bs=Object.defineProperty,ct=(i,t,e,n)=>{for(var s=void 0,r=i.length-1,o;r>=0;r--)(o=i[r])&&(s=o(t,e,s)||s);return s&&bs(t,e,s),s};const ge=class ge extends x{constructor(){super(...arguments),this.active=!1,this.triggerVisible=!0,this.loaded=!1,this.containerRef=_t(),this.widgetActive$=new di(!1),this.componentIsDestroyed$=new Ot}async connectedCallback(){super.connectedCallback(),this.icon=await this._renderSymbol(),this.loaded=!0,this._applyBranding()}disconnectedCallback(){super.disconnectedCallback(),this.componentIsDestroyed$.next(),this.componentIsDestroyed$.complete()}toggleActive(){var t;if(!((t=this.application)!=null&&t.root)){console.warn("Could not activate widget. No root element assigned to widget.");return}this.active=!this.active,this.active?(this.application.appendToDOM(),this.notify("widget-set-active",{widgetId:this.application.id,active:!0}),this.widgetActive$.next(!0),this.hideTrigger()):(this.application.hide(),this.notify("widget-set-active",{widgetId:this.application.id,active:!1}),this.widgetActive$.next(!1),this.showTrigger())}notify(t,e={}){window!=null&&window.parent&&window.parent.postMessage({type:t,data:e},"*")}_applyBranding(){var t;(t=this.application)!=null&&t.settings&&Ni(this.application.settings.branding,this)}async _renderSymbol(){var a,l,c;const t=(a=this.application)==null?void 0:a.branding(),e=(l=t==null?void 0:t.graphics)==null?void 0:l.trigger;if(e)return k` <img src=${e} class="trigger-icon" alt="" /> `;const n=(c=this.application)==null?void 0:c.triggerIcon;if(!n)return p;const s=async u=>ms,{type:r,content:o}=n;switch(r){case"Telia":{const u=await s();return u?k`<telia-icon
|
|
66
|
+
class="trigger-icon"
|
|
67
|
+
svg=${u.svg}
|
|
68
|
+
size="lg"
|
|
69
|
+
></telia-icon>`:p}default:return p}}hideTrigger(){this.triggerVisible=!1}showTrigger(){this.triggerVisible=!0}render(){var t,e,n,s;return k`<div
|
|
70
|
+
class=${De({"trigger-container":!0,hidden:!this.triggerVisible})}
|
|
71
|
+
${le(this.containerRef)}
|
|
72
|
+
>
|
|
73
|
+
${!this.active&&((s=(n=(e=(t=this.application)==null?void 0:t.settings)==null?void 0:e.branding)==null?void 0:n.other)!=null&&s.showButtonLabel)?k`
|
|
74
|
+
<button
|
|
75
|
+
label="${this.application.settings.branding.other.buttonLabelText??"Widget trigger"}"
|
|
76
|
+
class="trigger-label"
|
|
77
|
+
@click=${this.toggleActive}
|
|
78
|
+
${Mi({keyframeOptions:{},in:ps,stabilizeOut:!0,skipInitial:!1})}
|
|
79
|
+
>
|
|
80
|
+
${this.application.settings.branding.other.buttonLabelText}
|
|
81
|
+
</button>
|
|
82
|
+
`:p}
|
|
83
|
+
|
|
84
|
+
<button
|
|
85
|
+
label="Widget trigger"
|
|
86
|
+
class=${De({trigger:!0,active:this.active,rendered:this.loaded})}
|
|
87
|
+
@click=${this.toggleActive}
|
|
88
|
+
>
|
|
89
|
+
${this.icon}
|
|
90
|
+
<span class="trigger-close">
|
|
91
|
+
<svg
|
|
92
|
+
width="18"
|
|
93
|
+
height="9"
|
|
94
|
+
viewBox="0 0 18 9"
|
|
95
|
+
fill="none"
|
|
96
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
97
|
+
>
|
|
98
|
+
<path
|
|
99
|
+
d="M9 9C8.81794 9.00045 8.63759 8.96634 8.46939 8.89965C8.3012 8.83295 8.14851 8.735 8.02015 8.61145L0.194523 1.12367C0.068294 0.99862 -0.00155266 0.831133 2.61958e-05 0.657285C0.00160506 0.483436 0.0744832 0.317136 0.202964 0.194202C0.331445 0.0712675 0.505249 0.00153576 0.686941 2.50649e-05C0.868634 -0.00148563 1.04368 0.0653456 1.17437 0.186125L9 7.6739L16.8256 0.186125C16.9563 0.0653456 17.1314 -0.00148563 17.3131 2.50649e-05C17.4948 0.00153576 17.6686 0.0712675 17.797 0.194202C17.9255 0.317136 17.9984 0.483436 18 0.657285C18.0016 0.831133 17.9317 0.99862 17.8055 1.12367L9.97985 8.61145C9.85149 8.735 9.6988 8.83295 9.53061 8.89965C9.36241 8.96634 9.18206 9.00045 9 9Z"
|
|
100
|
+
fill="white"
|
|
101
|
+
/>
|
|
102
|
+
</svg>
|
|
103
|
+
</span>
|
|
104
|
+
<span class="trigger-loader">
|
|
105
|
+
<svg viewBox="25 25 50 50">
|
|
106
|
+
<circle
|
|
107
|
+
cx="50"
|
|
108
|
+
cy="50"
|
|
109
|
+
r="20"
|
|
110
|
+
fill="none"
|
|
111
|
+
stroke="#000"
|
|
112
|
+
stroke-width="2"
|
|
113
|
+
stroke-miterlimit="10"
|
|
114
|
+
/>
|
|
115
|
+
</svg>
|
|
116
|
+
</span>
|
|
117
|
+
</button>
|
|
118
|
+
</div>`}};ge.styles=[M`
|
|
119
|
+
:host {
|
|
120
|
+
--voca-rem-multiplier: 0.625;
|
|
121
|
+
--trigger-label-bg: #f5e0ff;
|
|
122
|
+
--trigger-label-text-color: rgba(0, 0, 0, 0.8);
|
|
123
|
+
display: block;
|
|
124
|
+
box-sizing: border-box;
|
|
125
|
+
font-family: TeliaSans, Helvetica, Arial, Lucida Grande, sans-serif;
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
:focus {
|
|
129
|
+
outline-color: var(--focus-color);
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
.trigger-container {
|
|
133
|
+
display: flex;
|
|
134
|
+
align-items: center;
|
|
135
|
+
gap: 1rem;
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
.trigger-container.hidden {
|
|
139
|
+
display: none;
|
|
140
|
+
}
|
|
141
|
+
|
|
142
|
+
.trigger {
|
|
143
|
+
transform: scale(0);
|
|
144
|
+
box-shadow: rgba(0, 0, 0, 0.16) 0px 5px 40px;
|
|
145
|
+
z-index: 5;
|
|
146
|
+
display: flex;
|
|
147
|
+
align-items: center;
|
|
148
|
+
justify-content: center;
|
|
149
|
+
border: none;
|
|
150
|
+
line-height: 55px;
|
|
151
|
+
height: 55px;
|
|
152
|
+
width: 55px;
|
|
153
|
+
border-radius: 55px;
|
|
154
|
+
cursor: pointer;
|
|
155
|
+
background-color: var(
|
|
156
|
+
--interactive-primary-background,
|
|
157
|
+
var(--primary-background)
|
|
158
|
+
);
|
|
159
|
+
font-family: Lato;
|
|
160
|
+
text-decoration: none;
|
|
161
|
+
border: 3px dashed transparent;
|
|
162
|
+
box-sizing: border-box;
|
|
163
|
+
transition: transform 200ms ease-out;
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
.trigger:active {
|
|
167
|
+
transform: scale(0.8) !important;
|
|
168
|
+
}
|
|
169
|
+
|
|
170
|
+
.trigger:hover:not(:active) {
|
|
171
|
+
transform: scale(1.1) !important;
|
|
172
|
+
}
|
|
173
|
+
|
|
174
|
+
.trigger.rendered {
|
|
175
|
+
transform: scale(1);
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
.trigger.active .trigger-icon {
|
|
179
|
+
opacity: 0;
|
|
180
|
+
transform: rotate(-180deg) scale(0);
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
.trigger.active .trigger-close {
|
|
184
|
+
opacity: 1;
|
|
185
|
+
transform: rotate(0deg) scale(1);
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
.trigger-icon {
|
|
189
|
+
display: inline-block;
|
|
190
|
+
line-height: inherit;
|
|
191
|
+
text-align: center;
|
|
192
|
+
opacity: 1;
|
|
193
|
+
transform: rotate(0deg) scale(1);
|
|
194
|
+
transition: opacity 200ms ease-out, transform 200ms ease-out;
|
|
195
|
+
color: var(
|
|
196
|
+
--interactive-text-on-primary-background,
|
|
197
|
+
var(--text-on-primary-background)
|
|
198
|
+
);
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
.trigger-close {
|
|
202
|
+
opacity: 0;
|
|
203
|
+
transition: transform 200ms ease-out;
|
|
204
|
+
transform: rotate(180deg) scale(0);
|
|
205
|
+
position: absolute;
|
|
206
|
+
top: 0;
|
|
207
|
+
bottom: 0;
|
|
208
|
+
left: 0;
|
|
209
|
+
right: 0;
|
|
210
|
+
display: flex;
|
|
211
|
+
justify-content: center;
|
|
212
|
+
align-items: center;
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
.trigger-close svg path {
|
|
216
|
+
fill: var(
|
|
217
|
+
--interactive-text-on-primary-background,
|
|
218
|
+
var(--text-on-primary-background)
|
|
219
|
+
);
|
|
220
|
+
}
|
|
221
|
+
|
|
222
|
+
img {
|
|
223
|
+
max-width: 100%;
|
|
224
|
+
}
|
|
225
|
+
|
|
226
|
+
.trigger-label {
|
|
227
|
+
box-shadow: 0px 1px 4px 0px rgba(0, 0, 0, 0.1);
|
|
228
|
+
background-color: var(--secondary-background);
|
|
229
|
+
color: var(--text-on-secondary-background);
|
|
230
|
+
white-space: nowrap;
|
|
231
|
+
padding: 0.7rem 1rem;
|
|
232
|
+
border-radius: 0.3rem;
|
|
233
|
+
font-weight: 500;
|
|
234
|
+
display: flex;
|
|
235
|
+
justify-content: center;
|
|
236
|
+
align-items: center;
|
|
237
|
+
cursor: pointer;
|
|
238
|
+
border: none;
|
|
239
|
+
font-size: 1rem;
|
|
240
|
+
font-family: inherit;
|
|
241
|
+
transition: all 300ms ease-in-out;
|
|
242
|
+
}
|
|
243
|
+
|
|
244
|
+
.trigger-label:hover {
|
|
245
|
+
opacity: 0.8;
|
|
246
|
+
}
|
|
247
|
+
`];let E=ge;ct([b({attribute:!1})],E.prototype,"application");ct([N()],E.prototype,"active");ct([N()],E.prototype,"triggerVisible");ct([N()],E.prototype,"loaded");ct([N()],E.prototype,"icon");var _s=Object.defineProperty,P=(i,t,e,n)=>{for(var s=void 0,r=i.length-1,o;r>=0;r--)(o=i[r])&&(s=o(t,e,s)||s);return s&&_s(t,e,s),s};const Bi=i=>{const e=class e extends i{constructor(){super(...arguments),this.properties={},this.context={},this.layout={},this.nodes=[]}writeProperties(s){this.properties=s}writeLayout(s){this.layout=s}writeContext(s){this.context=s}addChild(s){s.parent=this,this.nodes.push(s)}connectedCallback(){super.connectedCallback(),this.renderRoot.host.style.setProperty("--width",this.layout.size==="full"?"var(--columns, 1)":`min(${this.layout.size||"var(--columns)"}, var(--columns))`),this.application.mountComponent(this)}};e.styles=[M`
|
|
248
|
+
:host {
|
|
249
|
+
font-family: var(--font-family);
|
|
250
|
+
grid-column: span var(--width);
|
|
251
|
+
max-width: 100%;
|
|
252
|
+
overflow: hidden;
|
|
253
|
+
box-sizing: border-box;
|
|
254
|
+
display: block;
|
|
255
|
+
}
|
|
256
|
+
* {
|
|
257
|
+
box-sizing: border-box;
|
|
258
|
+
}
|
|
259
|
+
`];let t=e;return P([b()],t.prototype,"properties"),P([b()],t.prototype,"context"),P([b()],t.prototype,"layout"),P([b()],t.prototype,"name"),P([b()],t.prototype,"type"),P([b({attribute:!1})],t.prototype,"application"),P([b({attribute:!1})],t.prototype,"parent"),t},$e=class $e extends Bi(x){render(){return k`Non resolved component`}};$e.styles=[M`
|
|
260
|
+
:host {
|
|
261
|
+
display: block;
|
|
262
|
+
}
|
|
263
|
+
`];let Xt=$e;/**
|
|
264
|
+
* @license
|
|
265
|
+
* Copyright 2021 Google LLC
|
|
266
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
267
|
+
*/function*ws(i,t){if(i!==void 0){let e=0;for(const n of i)yield t(n,e++)}}var st=(i=>(i.Inline="inline",i.Trigger="trigger",i))(st||{});/**
|
|
268
|
+
* @license
|
|
269
|
+
* Copyright 2021 Google LLC
|
|
270
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
271
|
+
*/let xs=class extends Event{constructor(t,e,n){super("context-request",{bubbles:!0,composed:!0}),this.context=t,this.callback=e,this.subscribe=n??!1}};/**
|
|
272
|
+
* @license
|
|
273
|
+
* Copyright 2021 Google LLC
|
|
274
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
275
|
+
*//**
|
|
276
|
+
* @license
|
|
277
|
+
* Copyright 2021 Google LLC
|
|
278
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
279
|
+
*/class Ss{get value(){return this.o}set value(t){this.setValue(t)}setValue(t,e=!1){const n=e||!Object.is(t,this.o);this.o=t,n&&this.updateObservers()}constructor(t){this.subscriptions=new Map,this.updateObservers=()=>{for(const[e,{disposer:n}]of this.subscriptions)e(this.o,n)},t!==void 0&&(this.value=t)}addCallback(t,e,n){if(!n)return void t(this.value);this.subscriptions.has(t)||this.subscriptions.set(t,{disposer:()=>{this.subscriptions.delete(t)},consumerHost:e});const{disposer:s}=this.subscriptions.get(t);t(this.value,s)}clearCallbacks(){this.subscriptions.clear()}}/**
|
|
280
|
+
* @license
|
|
281
|
+
* Copyright 2021 Google LLC
|
|
282
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
283
|
+
*/let As=class extends Event{constructor(t){super("context-provider",{bubbles:!0,composed:!0}),this.context=t}};class ze extends Ss{constructor(t,e,n){var s,r;super(e.context!==void 0?e.initialValue:n),this.onContextRequest=o=>{const a=o.composedPath()[0];o.context===this.context&&a!==this.host&&(o.stopPropagation(),this.addCallback(o.callback,a,o.subscribe))},this.onProviderRequest=o=>{const a=o.composedPath()[0];if(o.context!==this.context||a===this.host)return;const l=new Set;for(const[c,{consumerHost:u}]of this.subscriptions)l.has(c)||(l.add(c),u.dispatchEvent(new xs(this.context,c,!0)));o.stopPropagation()},this.host=t,e.context!==void 0?this.context=e.context:this.context=e,this.attachListeners(),(r=(s=this.host).addController)==null||r.call(s,this)}attachListeners(){this.host.addEventListener("context-request",this.onContextRequest),this.host.addEventListener("context-provider",this.onProviderRequest)}hostConnected(){this.host.dispatchEvent(new As(this.context))}}/**
|
|
284
|
+
* @license
|
|
285
|
+
* Copyright 2017 Google LLC
|
|
286
|
+
* SPDX-License-Identifier: BSD-3-Clause
|
|
287
|
+
*/function ks({context:i}){return(t,e)=>{const n=new WeakMap;if(typeof e=="object")return e.addInitializer(function(){n.set(this,new ze(this,{context:i}))}),{get(){return t.get.call(this)},set(s){var r;return(r=n.get(this))==null||r.setValue(s),t.set.call(this,s)},init(s){var r;return(r=n.get(this))==null||r.setValue(s),s}};{t.constructor.addInitializer(o=>{n.set(o,new ze(o,{context:i}))});const s=Object.getOwnPropertyDescriptor(t,e);let r;if(s===void 0){const o=new WeakMap;r={get(){return o.get(this)},set(a){n.get(this).setValue(a),o.set(this,a)},configurable:!0,enumerable:!0}}else{const o=s.set;r={...s,set(a){n.get(this).setValue(a),o==null||o.call(this,a)}}}return void Object.defineProperty(t,e,r)}}}var Es=Object.defineProperty,Hi=(i,t,e,n)=>{for(var s=void 0,r=i.length-1,o;r>=0;r--)(o=i[r])&&(s=o(t,e,s)||s);return s&&Es(t,e,s),s};const Cs="application",ve=class ve extends x{constructor(){super(...arguments),this.nodes=[],this.wrapperRef=_t(),this.fullscreen=!1,this.isReady=new di(!1)}addChild(t){t.parent=this,this.nodes.push(t)}applyBranding(){if(!this.wrapperRef.value)return;const t=this.application.settings;t!=null&&t.branding&&Ni(t.branding,this.wrapperRef.value)}applyStyles(){if(!this.wrapperRef.value)return;const t=this.application.styles(),e=this.wrapperRef.value;Object.entries(t).forEach(([n,s])=>{e.style.setProperty(`--${n}`,s)})}firstUpdated(t){this.applyBranding(),this.applyStyles()}render(){var n,s;const t=this.application.settings.components.conversation;return((s=(n=t==null?void 0:t.properties)==null?void 0:n.chat)==null?void 0:s.isThirdPartyWidget)?this.renderRoot.host.classList.add("third-party"):this.application.renderStrategy===st.Trigger&&(this.renderRoot.host.classList.add("floating"),this.application.anchor==="BottomLeft"?this.renderRoot.host.classList.add("bottom-left"):this.application.anchor==="BottomRight"&&this.renderRoot.host.classList.add("bottom-right")),this.application.fullscreen&&this.renderRoot.host.classList.add("fullscreen"),window.self!==window.top&&this.renderRoot.host.classList.add("embedded"),k`<div class="widget-container" ${le(this.wrapperRef)}>
|
|
288
|
+
${ws(this.nodes,r=>r)}
|
|
289
|
+
</div>`}};ve.styles=M`
|
|
290
|
+
:host {
|
|
291
|
+
--font-family: TeliaSans, Helvetica, Arial, Lucida Grande, sans-serif;
|
|
292
|
+
--spacing-xs: 0.2rem;
|
|
293
|
+
--spacing-sm: 0.5rem;
|
|
294
|
+
--spacing-md: 1rem;
|
|
295
|
+
--spacing-lg: 1.2rem;
|
|
296
|
+
--spacing-xl: 1.8rem;
|
|
297
|
+
|
|
298
|
+
--inverted-spacing-lg: -1.2rem;
|
|
299
|
+
|
|
300
|
+
--text-color: #222222;
|
|
301
|
+
--link-color: #990ae3;
|
|
302
|
+
--gray-color: #f3f3f8;
|
|
303
|
+
--white-color: #fff;
|
|
304
|
+
--gray-dark-color: #a6a6a6;
|
|
305
|
+
--black-border-color: #00000054;
|
|
306
|
+
|
|
307
|
+
--box-shadow: rgba(149, 157, 165, 0.2) 0px 8px 24px;
|
|
308
|
+
--border-radius: var(--spacing-sm);
|
|
309
|
+
--border-radius-sm: var(--spacing-sm);
|
|
310
|
+
--border-radius-lg: var(--spacing-lg);
|
|
311
|
+
--border-radius-xl: var(--spacing-xl);
|
|
312
|
+
--gap: var(--spacing-sm);
|
|
313
|
+
|
|
314
|
+
--header-height: 69px;
|
|
315
|
+
}
|
|
316
|
+
|
|
317
|
+
:host {
|
|
318
|
+
--voca-rem-multiplier: 0.625;
|
|
319
|
+
box-sizing: border-box;
|
|
320
|
+
display: block;
|
|
321
|
+
}
|
|
322
|
+
|
|
323
|
+
:host(.inline) {
|
|
324
|
+
height: 100%;
|
|
325
|
+
position: fixed;
|
|
326
|
+
inset: 0 0 0 0;
|
|
327
|
+
}
|
|
328
|
+
|
|
329
|
+
:host(.floating) {
|
|
330
|
+
z-index: 6;
|
|
331
|
+
position: fixed;
|
|
332
|
+
}
|
|
333
|
+
|
|
334
|
+
:host(.fullscreen.floating) {
|
|
335
|
+
inset: 0 !important;
|
|
336
|
+
height: 100% !important;
|
|
337
|
+
width: auto !important;
|
|
338
|
+
max-height: none !important;
|
|
339
|
+
}
|
|
340
|
+
|
|
341
|
+
:host(.fullscreen.floating) .widget-container {
|
|
342
|
+
box-shadow: none !important;
|
|
343
|
+
border-radius: 0 !important;
|
|
344
|
+
}
|
|
345
|
+
|
|
346
|
+
@media screen and (max-width: 800px) {
|
|
347
|
+
:host(.floating) {
|
|
348
|
+
inset: 0;
|
|
349
|
+
height: 100%;
|
|
350
|
+
}
|
|
351
|
+
|
|
352
|
+
:host(.third-party) {
|
|
353
|
+
inset: 0;
|
|
354
|
+
height: 100vh;
|
|
355
|
+
}
|
|
356
|
+
}
|
|
357
|
+
|
|
358
|
+
@media screen and (min-width: 801px) {
|
|
359
|
+
:host(.floating) {
|
|
360
|
+
inset: auto 20px 20px auto;
|
|
361
|
+
max-height: calc(100vh - 120px);
|
|
362
|
+
width: 400px;
|
|
363
|
+
height: 775px;
|
|
364
|
+
}
|
|
365
|
+
|
|
366
|
+
:host(.third-party) {
|
|
367
|
+
max-width: 1000px;
|
|
368
|
+
height: 100vh;
|
|
369
|
+
position: relative;
|
|
370
|
+
left: 50%;
|
|
371
|
+
transform: translateX(-50%);
|
|
372
|
+
margin: -10px 0;
|
|
373
|
+
}
|
|
374
|
+
|
|
375
|
+
:host(.floating.bottom-right) {
|
|
376
|
+
inset: auto 20px 20px auto;
|
|
377
|
+
}
|
|
378
|
+
|
|
379
|
+
:host(.floating.bottom-left) {
|
|
380
|
+
inset: auto auto 20px 20px;
|
|
381
|
+
}
|
|
382
|
+
}
|
|
383
|
+
|
|
384
|
+
:host(.floating) .widget-container {
|
|
385
|
+
box-shadow: rgba(0, 0, 0, 0.16) 0px 5px 40px;
|
|
386
|
+
border-radius: 0.7rem;
|
|
387
|
+
|
|
388
|
+
@media screen and (max-width: 800px) {
|
|
389
|
+
border-radius: 0;
|
|
390
|
+
}
|
|
391
|
+
}
|
|
392
|
+
|
|
393
|
+
* {
|
|
394
|
+
box-sizing: border-box;
|
|
395
|
+
}
|
|
396
|
+
|
|
397
|
+
.widget-container {
|
|
398
|
+
height: 100%;
|
|
399
|
+
background-color: var(--primary-background);
|
|
400
|
+
padding: var(--spacing-sm);
|
|
401
|
+
border: var(--widget-border, none);
|
|
402
|
+
}
|
|
403
|
+
|
|
404
|
+
@keyframes slideDown {
|
|
405
|
+
from {
|
|
406
|
+
transform: translateY(0);
|
|
407
|
+
opacity: 1;
|
|
408
|
+
}
|
|
409
|
+
to {
|
|
410
|
+
transform: translateY(100%);
|
|
411
|
+
opacity: 0;
|
|
412
|
+
}
|
|
413
|
+
}
|
|
414
|
+
|
|
415
|
+
@keyframes slideUp {
|
|
416
|
+
from {
|
|
417
|
+
transform: translateY(100%);
|
|
418
|
+
opacity: 0;
|
|
419
|
+
}
|
|
420
|
+
to {
|
|
421
|
+
transform: translateY(0);
|
|
422
|
+
opacity: 1;
|
|
423
|
+
}
|
|
424
|
+
}
|
|
425
|
+
|
|
426
|
+
:host(.expanded) {
|
|
427
|
+
opacity: 1;
|
|
428
|
+
animation: slideUp 0.3s linear;
|
|
429
|
+
}
|
|
430
|
+
|
|
431
|
+
:host(.hidden) {
|
|
432
|
+
opacity: 0;
|
|
433
|
+
animation: slideDown 0.3s linear;
|
|
434
|
+
pointer-events: none;
|
|
435
|
+
}
|
|
436
|
+
|
|
437
|
+
:host(.hidden.embedded),
|
|
438
|
+
:host(.expanded.embedded) {
|
|
439
|
+
animation: none;
|
|
440
|
+
}
|
|
441
|
+
`;let rt=ve;Hi([b({attribute:!0})],rt.prototype,"fullscreen");Hi([b({attribute:!1}),ks({context:Cs})],rt.prototype,"application");const kt=class kt{constructor(t=kt.endpoint){this._endpoint=t}async getSite(t){const n=await(await fetch(t)).json();return n?{id:n.id,triggers:n.triggers||[],apps:(n.widgets||[]).map(s=>{let r=st.Trigger;s.renderStrategy.toLowerCase()==="inline"&&(r=st.Inline);const o=s.widgetId?s.widgetId:s.id,a=typeof s.autoActivate=="boolean"?s.autoActivate:!1,l=typeof s.anchor=="string"?s.anchor:"BottomRight",c=typeof s.triggerIcon=="string"?s.triggerIcon:"question";return{id:o,widgetId:o,renderStrategy:r,autoActivate:a,anchor:l,triggerIcon:{type:"Telia",content:c}}})}:null}async getWidget(t){const n=await(await fetch(`${this._endpoint}/widget/${t}`)).json();return n?{name:n.name,config:JSON.parse(n.configuration)}:null}};kt.endpoint="https://widgets.ace.teliacompany.net/api";let Fe=kt;var Os=Object.defineProperty,ce=(i,t,e,n)=>{for(var s=void 0,r=i.length-1,o;r>=0;r--)(o=i[r])&&(s=o(t,e,s)||s);return s&&Os(t,e,s),s};const me=class me extends x{constructor(){super(),this.status="deactivated",this.addEventListener("environment-created",this.onEnvironmentCreated)}async connectedCallback(){super.connectedCallback(),await this.getGlobalEnvironment()}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("environment-created",this.onEnvironmentCreated)}async onEnvironmentCreated(t){this.widget=t.detail.widget,await this.activate(),this.requestUpdate()}async activate(){this.widget&&(await this.widget.activate(),this.status="activated")}async getGlobalEnvironment(){const t=globalThis.widgets;t&&(this.widget=t.applications.find(e=>e.name===this.name),await this.activate())}render(){if(!this.widget||this.status!=="activated")return p;if(this.widget.renderStrategy===st.Trigger){const t=new E;return t.application=this.widget,t}return this.widget.render()}};me.styles=[M`
|
|
442
|
+
:host {
|
|
443
|
+
display: block;
|
|
444
|
+
}
|
|
445
|
+
`];let K=me;ce([b({attribute:!0})],K.prototype,"name");ce([N()],K.prototype,"widget");ce([N()],K.prototype,"status");customElements.get("ace-trigger-slot")||customElements.define("ace-trigger-slot",yt);customElements.get("ace-trigger")||customElements.define("ace-trigger",E);customElements.get("ace-unresolved-component")||customElements.define("ace-unresolved-component",Xt);customElements.get("ace-wrapper")||customElements.define("ace-wrapper",rt);customElements.get("ace-widget")||customElements.define("ace-widget",K);const Ts=()=>"10000000-1000-4000-8000-100000000000".replace(/[018]/g,i=>(+i^crypto.getRandomValues(new Uint8Array(1))[0]&15>>+i/4).toString(16)),Ps=()=>typeof crypto.randomUUID=="function"?crypto.randomUUID():Ts();class Is{constructor(t,e,n,s,r,o,a=!0){this.label=t,this.icon=e,this.onClick=n,this.closeOnClick=s,this.key=r,this.update=new Ot,this.id=Ps(),this._controller=o,this.enabled=a}updateLabel(t){this.label=t,this.update.next()}updateIcon(t){this.icon=t,this.update.next()}remove(){this._controller.removeOption(this)}subscribe(){return this.update.asObservable()}}class Ls{constructor(t){this._options=[],this._subscription=null,this._host=t,t.addController(this)}hostConnected(){}hostDisconnected(){this._subscription&&this._subscription.unsubscribe(),this._options=[]}addOption(t){const e=new Is(t.label,t.icon,t.onClick,t.closeOnClick,t.key,this);return this._options.push(e),this.handleUpdate(),e}removeOption(t){this._options=this._options.filter(e=>e.id!==t.id)}handleUpdate(){this._subscription&&this._subscription.unsubscribe();const t=this._options.map(e=>e.subscribe());this._subscription=Bn(t).subscribe(()=>{this._host.requestUpdate()})}set options(t){this._options=t,this._host.requestUpdate()}get options(){return this._options}hasOptions(){return this._options.length>0}}const H={allRenderFn:!1,cmpDidLoad:!0,cmpDidUnload:!1,cmpDidUpdate:!0,cmpDidRender:!0,cmpWillLoad:!0,cmpWillUpdate:!0,cmpWillRender:!0,connectedCallback:!0,disconnectedCallback:!0,element:!0,event:!0,hasRenderFn:!0,lifecycle:!0,hostListener:!0,hostListenerTargetWindow:!0,hostListenerTargetDocument:!0,hostListenerTargetBody:!0,hostListenerTargetParent:!1,hostListenerTarget:!0,member:!0,method:!0,mode:!0,observeAttribute:!0,prop:!0,propMutable:!0,reflect:!0,scoped:!0,shadowDom:!0,slot:!0,cssAnnotations:!0,state:!0,style:!0,svg:!0,updatable:!0,vdomAttribute:!0,vdomXlink:!0,vdomClass:!0,vdomFunctional:!0,vdomKey:!0,vdomListener:!0,vdomRef:!0,vdomPropOrAttr:!0,vdomRender:!0,vdomStyle:!0,vdomText:!0,watchCallback:!0,taskQueue:!0,hotModuleReplacement:!1,isDebug:!1,isDev:!1,isTesting:!1,hydrateServerSide:!1,hydrateClientSide:!1,lifecycleDOMEvents:!1,lazyLoad:!1,profile:!1,slotRelocation:!0,appendChildSlotFix:!1,cloneNodeFix:!1,hydratedAttribute:!1,hydratedClass:!0,safari10:!1,scriptDataOpts:!1,scopedSlotTextContentFix:!1,shadowDomShim:!1,slotChildNodesFix:!1,invisiblePrehydration:!0,propBoolean:!0,propNumber:!0,propString:!0,cssVarShim:!1,constructableCSS:!0,cmpShouldUpdate:!0,devTools:!1,dynamicImportShim:!1,shadowDelegatesFocus:!0,initializeNextTick:!1,asyncLoading:!1,asyncQueue:!1,transformTagName:!1,attachStyles:!0};let D,Di,Pt,zi=!1,wt=!1,ue=!1,y=!1,Ye=null,Qt=!1;const It=typeof window<"u"?window:{},S=It.document||{head:{}},Fi=It.HTMLElement||class{},m={$flags$:0,$resourcesUrl$:"",jmp:i=>i(),raf:i=>requestAnimationFrame(i),ael:(i,t,e,n)=>i.addEventListener(t,e,n),rel:(i,t,e,n)=>i.removeEventListener(t,e,n),ce:(i,t)=>new CustomEvent(i,t)},Rs=(()=>{let i=!1;try{S.addEventListener("e",null,Object.defineProperty({},"passive",{get(){i=!0}}))}catch{}return i})(),Us=i=>Promise.resolve(i),js=(()=>{try{return new CSSStyleSheet,typeof new CSSStyleSheet().replace=="function"}catch{}return!1})(),Yi=(i,t,e,n)=>{e&&e.map(([s,r,o])=>{const a=Ns(i,s),l=Ms(t,o),c=Bs(s);m.ael(a,r,l,c),(t.$rmListeners$=t.$rmListeners$||[]).push(()=>m.rel(a,r,l,c))})},Ms=(i,t)=>e=>{try{H.lazyLoad||i.$hostElement$[t](e)}catch(n){ut(n)}},Ns=(i,t)=>t&4?S:t&8?It:t&16?S.body:i,Bs=i=>Rs?{passive:(i&1)!==0,capture:(i&2)!==0}:(i&2)!==0,We="http://www.w3.org/1999/xlink",j=(i,t="")=>()=>{},qe=new WeakMap,Hs=(i,t,e)=>{let n=At.get(i);js&&e?(n=n||new CSSStyleSheet,n.replace(t)):n=t,At.set(i,n)},Ds=(i,t,e,n)=>{let s=Wi(t,e),r=At.get(s);if(i=i.nodeType===11?i:S,r)if(typeof r=="string"){i=i.head||i;let o=qe.get(i),a;o||qe.set(i,o=new Set),o.has(s)||(a=S.createElement("style"),a.innerHTML=r,i.insertBefore(a,i.querySelector("link")),o&&o.add(s))}else i.adoptedStyleSheets.includes(r)||(i.adoptedStyleSheets=[...i.adoptedStyleSheets,r]);return s},zs=i=>{const t=i.$cmpMeta$,e=i.$hostElement$,n=t.$flags$,s=j("attachStyles",t.$tagName$),r=Ds(e.shadowRoot?e.shadowRoot:e.getRootNode(),t,i.$modeName$);n&10&&(e["s-sc"]=r,e.classList.add(r+"-h"),n&2&&e.classList.add(r+"-s")),s()},Wi=(i,t)=>"sc-"+(t&&i.$flags$&32?i.$tagName$+"-"+t:i.$tagName$),Fs=i=>vr.map(t=>t(i)).find(t=>!!t),Ge={},Ys="http://www.w3.org/2000/svg",Ws="http://www.w3.org/1999/xhtml",qs=i=>i!=null,he=i=>(i=typeof i,i==="object"||i==="function"),Y=(i,t,...e)=>{let n=null,s=null,r=null,o=!1,a=!1,l=[];const c=h=>{for(let d=0;d<h.length;d++)n=h[d],Array.isArray(n)?c(n):n!=null&&typeof n!="boolean"&&((o=typeof i!="function"&&!he(n))&&(n=String(n)),o&&a?l[l.length-1].$text$+=n:l.push(o?xt(null,n):n),a=o)};if(c(e),t){t.key&&(s=t.key),t.name&&(r=t.name);{const h=t.className||t.class;h&&(t.class=typeof h!="object"?h:Object.keys(h).filter(d=>h[d]).join(" "))}}if(typeof i=="function")return i(t===null?{}:t,l,Ks);const u=xt(i,null);return u.$attrs$=t,l.length>0&&(u.$children$=l),u.$key$=s,u.$name$=r,u},xt=(i,t)=>{const e={$flags$:0,$tag$:i,$text$:t,$elm$:null,$children$:null};return e.$attrs$=null,e.$key$=null,e.$name$=null,e},de={},Gs=i=>i&&i.$tag$===de,Ks={forEach:(i,t)=>i.map(Ke).forEach(t),map:(i,t)=>i.map(Ke).map(t).map(Zs)},Ke=i=>({vattrs:i.$attrs$,vchildren:i.$children$,vkey:i.$key$,vname:i.$name$,vtag:i.$tag$,vtext:i.$text$}),Zs=i=>{if(typeof i.vtag=="function"){const e=Object.assign({},i.vattrs);return i.vkey&&(e.key=i.vkey),i.vname&&(e.name=i.vname),Y(i.vtag,e,...i.vchildren||[])}const t=xt(i.vtag,i.vtext);return t.$attrs$=i.vattrs,t.$children$=i.vchildren,t.$key$=i.vkey,t.$name$=i.vname,t},Ze=(i,t,e,n,s,r)=>{if(e!==n){let o=Ve(i,t),a=t.toLowerCase();if(t==="class"){const l=i.classList,c=Xe(e),u=Xe(n);l.remove(...c.filter(h=>h&&!u.includes(h))),l.add(...u.filter(h=>h&&!c.includes(h)))}else if(t==="style"){for(const l in e)(!n||n[l]==null)&&(l.includes("-")?i.style.removeProperty(l):i.style[l]="");for(const l in n)(!e||n[l]!==e[l])&&(l.includes("-")?i.style.setProperty(l,n[l]):i.style[l]=n[l])}else if(t!=="key")if(t==="ref")n&&n(i);else if(!i.__lookupSetter__(t)&&t[0]==="o"&&t[1]==="n")t[2]==="-"?t=t.slice(3):Ve(It,a)?t=a.slice(2):t=a[2]+t.slice(3),e&&m.rel(i,t,e,!1),n&&m.ael(i,t,n,!1);else{const l=he(n);if((o||l&&n!==null)&&!s)try{if(i.tagName.includes("-"))i[t]=n;else{let u=n??"";t==="list"?o=!1:(e==null||i[t]!=u)&&(i[t]=u)}}catch{}let c=!1;a!==(a=a.replace(/^xlink\:?/,""))&&(t=a,c=!0),n==null||n===!1?(n!==!1||i.getAttribute(t)==="")&&(c?i.removeAttributeNS(We,t):i.removeAttribute(t)):(!o||r&4||s)&&!l&&(n=n===!0?"":n,c?i.setAttributeNS(We,t,n):i.setAttribute(t,n))}}},Xs=/\s/,Xe=i=>i?i.split(Xs):[],qi=(i,t,e,n)=>{const s=t.$elm$.nodeType===11&&t.$elm$.host?t.$elm$.host:t.$elm$,r=i&&i.$attrs$||Ge,o=t.$attrs$||Ge;for(n in r)n in o||Ze(s,n,r[n],void 0,e,t.$flags$);for(n in o)Ze(s,n,r[n],o[n],e,t.$flags$)},St=(i,t,e,n)=>{let s=t.$children$[e],r=0,o,a,l;if(zi||(ue=!0,s.$tag$==="slot"&&(D&&n.classList.add(D+"-s"),s.$flags$|=s.$children$?2:1)),s.$text$!==null)o=s.$elm$=S.createTextNode(s.$text$);else if(s.$flags$&1)o=s.$elm$=S.createTextNode("");else{if(y||(y=s.$tag$==="svg"),o=s.$elm$=S.createElementNS(y?Ys:Ws,s.$flags$&2?"slot-fb":s.$tag$),y&&s.$tag$==="foreignObject"&&(y=!1),qi(null,s,y),qs(D)&&o["s-si"]!==D&&o.classList.add(o["s-si"]=D),s.$children$)for(r=0;r<s.$children$.length;++r)a=St(i,s,r,o),a&&o.appendChild(a);s.$tag$==="svg"?y=!1:o.tagName==="foreignObject"&&(y=!0)}return o["s-hn"]=Pt,s.$flags$&3&&(o["s-sr"]=!0,o["s-cr"]=Di,o["s-sn"]=s.$name$||"",l=i&&i.$children$&&i.$children$[e],l&&l.$tag$===s.$tag$&&i.$elm$&&ot(i.$elm$,!1)),o},ot=(i,t)=>{m.$flags$|=1;const e=i.childNodes;for(let n=e.length-1;n>=0;n--){const s=e[n];s["s-hn"]!==Pt&&s["s-ol"]&&(Zi(s).insertBefore(s,fe(s)),s["s-ol"].remove(),s["s-ol"]=void 0,ue=!0),t&&ot(s,t)}m.$flags$&=-2},Gi=(i,t,e,n,s,r)=>{let o=i["s-cr"]&&i["s-cr"].parentNode||i,a;for(o.shadowRoot&&o.tagName===Pt&&(o=o.shadowRoot);s<=r;++s)n[s]&&(a=St(null,e,s,i),a&&(n[s].$elm$=a,o.insertBefore(a,fe(t))))},Ki=(i,t,e,n,s)=>{for(;t<=e;++t)(n=i[t])&&(s=n.$elm$,Ji(n),wt=!0,s["s-ol"]?s["s-ol"].remove():ot(s,!0),s.remove())},Qs=(i,t,e,n)=>{let s=0,r=0,o=0,a=0,l=t.length-1,c=t[0],u=t[l],h=n.length-1,d=n[0],f=n[h],$,g;for(;s<=l&&r<=h;)if(c==null)c=t[++s];else if(u==null)u=t[--l];else if(d==null)d=n[++r];else if(f==null)f=n[--h];else if(ft(c,d))z(c,d),c=t[++s],d=n[++r];else if(ft(u,f))z(u,f),u=t[--l],f=n[--h];else if(ft(c,f))(c.$tag$==="slot"||f.$tag$==="slot")&&ot(c.$elm$.parentNode,!1),z(c,f),i.insertBefore(c.$elm$,u.$elm$.nextSibling),c=t[++s],f=n[--h];else if(ft(u,d))(c.$tag$==="slot"||f.$tag$==="slot")&&ot(u.$elm$.parentNode,!1),z(u,d),i.insertBefore(u.$elm$,c.$elm$),u=t[--l],d=n[++r];else{for(o=-1,a=s;a<=l;++a)if(t[a]&&t[a].$key$!==null&&t[a].$key$===d.$key$){o=a;break}o>=0?(g=t[o],g.$tag$!==d.$tag$?$=St(t&&t[r],e,o,i):(z(g,d),t[o]=void 0,$=g.$elm$),d=n[++r]):($=St(t&&t[r],e,r,i),d=n[++r]),$&&Zi(c.$elm$).insertBefore($,fe(c.$elm$))}s>l?Gi(i,n[h+1]==null?null:n[h+1].$elm$,e,n,r,h):r>h&&Ki(t,s,l)},ft=(i,t)=>i.$tag$===t.$tag$?i.$tag$==="slot"?i.$name$===t.$name$:i.$key$===t.$key$:!1,fe=i=>i&&i["s-ol"]||i,Zi=i=>(i["s-ol"]?i["s-ol"]:i).parentNode,z=(i,t)=>{const e=t.$elm$=i.$elm$,n=i.$children$,s=t.$children$,r=t.$tag$,o=t.$text$;let a;o===null?(y=r==="svg"?!0:r==="foreignObject"?!1:y,r==="slot"||qi(i,t,y),n!==null&&s!==null?Qs(e,n,t,s):s!==null?(i.$text$!==null&&(e.textContent=""),Gi(e,null,t,s,0,s.length-1)):n!==null&&Ki(n,0,n.length-1),y&&r==="svg"&&(y=!1)):(a=e["s-cr"])?a.parentNode.textContent=o:i.$text$!==o&&(e.data=o)},Xi=i=>{let t=i.childNodes,e,n,s,r,o,a;for(n=0,s=t.length;n<s;n++)if(e=t[n],e.nodeType===1){if(e["s-sr"]){for(o=e["s-sn"],e.hidden=!1,r=0;r<s;r++)if(a=t[r].nodeType,t[r]["s-hn"]!==e["s-hn"]||o!==""){if(a===1&&o===t[r].getAttribute("slot")){e.hidden=!0;break}}else if(a===1||a===3&&t[r].textContent.trim()!==""){e.hidden=!0;break}}Xi(e)}},w=[],Qi=i=>{let t,e,n,s,r,o,a=0,l=i.childNodes,c=l.length;for(;a<c;a++){if(t=l[a],t["s-sr"]&&(e=t["s-cr"])&&e.parentNode)for(n=e.parentNode.childNodes,s=t["s-sn"],o=n.length-1;o>=0;o--)e=n[o],!e["s-cn"]&&!e["s-nr"]&&e["s-hn"]!==t["s-hn"]&&(Qe(e,s)?(r=w.find(u=>u.$nodeToRelocate$===e),wt=!0,e["s-sn"]=e["s-sn"]||s,r?r.$slotRefNode$=t:w.push({$slotRefNode$:t,$nodeToRelocate$:e}),e["s-sr"]&&w.map(u=>{Qe(u.$nodeToRelocate$,e["s-sn"])&&(r=w.find(h=>h.$nodeToRelocate$===e),r&&!u.$slotRefNode$&&(u.$slotRefNode$=r.$slotRefNode$))})):w.some(u=>u.$nodeToRelocate$===e)||w.push({$nodeToRelocate$:e}));t.nodeType===1&&Qi(t)}},Qe=(i,t)=>i.nodeType===1?i.getAttribute("slot")===null&&t===""||i.getAttribute("slot")===t:i["s-sn"]===t?!0:t==="",Ji=i=>{i.$attrs$&&i.$attrs$.ref&&i.$attrs$.ref(null),i.$children$&&i.$children$.map(Ji)},Js=(i,t)=>{const e=i.$hostElement$,n=i.$cmpMeta$,s=i.$vnode$||xt(null,null),r=Gs(t)?t:Y(null,null,t);Pt=e.tagName,n.$attrsToReflect$&&(r.$attrs$=r.$attrs$||{},n.$attrsToReflect$.map(([o,a])=>r.$attrs$[a]=e[o])),r.$tag$=null,r.$flags$|=4,i.$vnode$=r,r.$elm$=s.$elm$=e.shadowRoot||e,D=e["s-sc"],Di=e["s-cr"],zi=(n.$flags$&1)!==0,wt=!1,z(s,r);{if(m.$flags$|=1,ue){Qi(r.$elm$);let o,a,l,c,u,h,d=0;for(;d<w.length;d++)o=w[d],a=o.$nodeToRelocate$,a["s-ol"]||(l=S.createTextNode(""),l["s-nr"]=a,a.parentNode.insertBefore(a["s-ol"]=l,a));for(d=0;d<w.length;d++)if(o=w[d],a=o.$nodeToRelocate$,o.$slotRefNode$){for(c=o.$slotRefNode$.parentNode,u=o.$slotRefNode$.nextSibling,l=a["s-ol"];l=l.previousSibling;)if(h=l["s-nr"],h&&h["s-sn"]===a["s-sn"]&&c===h.parentNode&&(h=h.nextSibling,!h||!h["s-nr"])){u=h;break}(!u&&c!==a.parentNode||a.nextSibling!==u)&&a!==u&&(!a["s-hn"]&&a["s-ol"]&&(a["s-hn"]=a["s-ol"].parentNode.nodeName),c.insertBefore(a,u))}else a.nodeType===1&&(a.hidden=!0)}wt&&Xi(r.$elm$),m.$flags$&=-2,w.length=0}},Vs=i=>i,tr=(i,t,e)=>{const n=Vs(i);return{emit:s=>er(n,t,{bubbles:!!(e&4),composed:!!(e&2),cancelable:!!(e&1),detail:s})}},er=(i,t,e)=>{const n=m.ce(t,e);return i.dispatchEvent(n),n},ir=(i,t)=>{},Vi=(i,t)=>(i.$flags$|=16,ir(i,i.$ancestorComponent$),br(()=>nr(i,t))),nr=(i,t)=>{const e=i.$hostElement$,n=j("scheduleUpdate",i.$cmpMeta$.$tagName$),s=e;let r;return t?r=W(s,"componentWillLoad"):r=W(s,"componentWillUpdate"),r=Je(r,()=>W(s,"componentWillRender")),n(),Je(r,()=>sr(i,s,t))},sr=async(i,t,e)=>{const n=i.$hostElement$,s=j("update",i.$cmpMeta$.$tagName$);n["s-rc"],e&&zs(i);const r=j("render",i.$cmpMeta$.$tagName$);rr(i,t,n),r(),s(),or(i)},rr=(i,t,e)=>{try{Ye=t,t=t.render&&t.render(),i.$flags$&=-17,i.$flags$|=2,(H.hasRenderFn||H.reflect)&&(H.vdomRender||H.reflect)&&(H.hydrateServerSide||Js(i,t))}catch(a){ut(a,i.$hostElement$)}return Ye=null,null},or=i=>{const t=i.$cmpMeta$.$tagName$,e=i.$hostElement$,n=j("postUpdate",t),s=e;i.$ancestorComponent$,W(s,"componentDidRender"),i.$flags$&64?(W(s,"componentDidUpdate"),n()):(i.$flags$|=64,W(s,"componentDidLoad"),n())},W=(i,t,e)=>{if(i&&i[t])try{return i[t](e)}catch(n){ut(n)}},Je=(i,t)=>i&&i.then?i.then(t):t(),ar=(i,t)=>i!=null&&!he(i)?t&4?i==="false"?!1:i===""||!!i:t&2?parseFloat(i):t&1?String(i):i:i,lr=(i,t)=>Lt(i).$instanceValues$.get(t),cr=(i,t,e,n)=>{const s=Lt(i),r=i,o=s.$instanceValues$.get(t),a=s.$flags$,l=r;e=ar(e,n.$members$[t][0]);const c=Number.isNaN(o)&&Number.isNaN(e);if(e!==o&&!c){s.$instanceValues$.set(t,e);{if(n.$watchers$&&a&128){const h=n.$watchers$[t];h&&h.map(d=>{try{l[d](e,o,t)}catch(f){ut(f,r)}})}if((a&18)===2){if(l.componentShouldUpdate&&l.componentShouldUpdate(e,o,t)===!1)return;Vi(s,!1)}}}},ur=(i,t,e)=>{if(t.$members$){i.watchers&&(t.$watchers$=i.watchers);const n=Object.entries(t.$members$),s=i.prototype;n.map(([r,[o]])=>{(o&31||o&32)&&Object.defineProperty(s,r,{get(){return lr(this,r)},set(a){cr(this,r,a,t)},configurable:!0,enumerable:!0})});{const r=new Map;s.attributeChangedCallback=function(o,a,l){m.jmp(()=>{const c=r.get(o);if(this.hasOwnProperty(c))l=this[c],delete this[c];else if(s.hasOwnProperty(c)&&typeof this[c]=="number"&&this[c]==l)return;this[c]=l===null&&typeof this[c]=="boolean"?!1:l})},i.observedAttributes=n.filter(([o,a])=>a[0]&15).map(([o,a])=>{const l=a[1]||o;return r.set(l,o),a[0]&512&&t.$attrsToReflect$.push([o,l]),l})}}return i},hr=async(i,t,e,n,s)=>{if(!(t.$flags$&32)&&(s=i.constructor,t.$flags$|=32,customElements.whenDefined(e.$tagName$).then(()=>t.$flags$|=128),s.style)){let o=s.style;typeof o!="string"&&(o=o[t.$modeName$=Fs(i)]);const a=Wi(e,t.$modeName$);if(!At.has(a)){const l=j("registerStyles",e.$tagName$);Hs(a,o,!!(e.$flags$&1)),l()}}t.$ancestorComponent$,Vi(t,!0)},dr=i=>{},fr=i=>{if(!(m.$flags$&1)){const t=Lt(i),e=t.$cmpMeta$,n=j("connectedCallback",e.$tagName$);t.$flags$&1?(Yi(i,t,e.$listeners$),dr(t.$lazyInstance$)):(t.$flags$|=1,e.$flags$&12&&pr(i),e.$members$&&Object.entries(e.$members$).map(([s,[r]])=>{if(r&31&&i.hasOwnProperty(s)){const o=i[s];delete i[s],i[s]=o}}),hr(i,t,e)),n()}},pr=i=>{const t=i["s-cr"]=S.createComment("");t["s-cn"]=!0,i.insertBefore(t,i.firstChild)},gr=i=>{if(!(m.$flags$&1)){const t=Lt(i);t.$rmListeners$&&(t.$rmListeners$.map(e=>e()),t.$rmListeners$=void 0)}},tn=(i,t)=>{const e={$flags$:t[0],$tagName$:t[1]};e.$members$=t[2],e.$listeners$=t[3],e.$watchers$=i.$watchers$,e.$attrsToReflect$=[];const n=i.prototype.connectedCallback,s=i.prototype.disconnectedCallback;return Object.assign(i.prototype,{__registerHost(){$r(this,e)},connectedCallback(){fr(this),n&&n.call(this)},disconnectedCallback(){gr(this),s&&s.call(this)},__attachShadow(){this.attachShadow({mode:"open",delegatesFocus:!!(e.$flags$&16)})}}),i.is=e.$tagName$,ur(i,e)},en=new WeakMap,Lt=i=>en.get(i),$r=(i,t)=>{const e={$flags$:0,$hostElement$:i,$cmpMeta$:t,$instanceValues$:new Map};return Yi(i,e,t.$listeners$),en.set(i,e)},Ve=(i,t)=>t in i,ut=(i,t)=>(0,console.error)(i,t),At=new Map,vr=[],ti=[],nn=[],mr=(i,t)=>e=>{i.push(e),Qt||(Qt=!0,t&&m.$flags$&4?yr(Jt):m.raf(Jt))},ei=i=>{for(let t=0;t<i.length;t++)try{i[t](performance.now())}catch(e){ut(e)}i.length=0},Jt=()=>{ei(ti),ei(nn),(Qt=ti.length>0)&&m.raf(Jt)},yr=i=>Us().then(i),br=mr(nn,!0),_r=(i={})=>{const{content:t="",title:e,attributes:n=[]}=i;let s="",r=[{name:"xmlns",value:"http://www.w3.org/2000/svg"},{name:"fill",value:"currentColor"},...n];return e&&(s=`<title>${e}</title>`),`<svg ${r.map(a=>`${a.name}="${a.value}"`).join(" ")}>${s}${t}</svg>`},wr=i=>i.replace(/<(\/?)svg([^>]*)>/g,"").trim();function xr(i){return`${i.getFullYear()}.${i.getMonth()+1}`}class Sr{constructor(t){this.voca_component=t,this.voca_added=xr(new Date)}}const Ar="telia-vst{display:none}",kr=tn(class extends Fi{constructor(){super(),this.__registerHost(),this.vocaInternalUStats=tr(this,"vocaInternalUStats",7)}connectedCallback(){this.vocaInternalUStats.emit(new Sr(this.dataTrackingId))}render(){return Y(de,null)}static get style(){return Ar}},[0,"telia-vst",{dataTrackingId:[1,"data-tracking-id"]}]);function sn(){if(typeof customElements>"u")return;["telia-vst"].forEach(t=>{switch(t){case"telia-vst":customElements.get(t)||customElements.define(t,kr);break}})}sn();function Vt(){return typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{vocadsIcons:void 0,vocadsIconsRegistered:!1}}function Er(){if(typeof Vt().vocadsIcons!==void 0)return Vt().vocadsIcons}function Cr(){return Vt().vocadsIconsRegistered}const Or=".telia-icon{display:inline-block}.telia-icon__container{display:block;height:inherit}.telia-icon svg{display:block}.telia-icon--sm{height:calc(1.6rem * var(--voca-rem-multiplier));min-width:calc(1.6rem * var(--voca-rem-multiplier));width:calc(1.6rem * var(--voca-rem-multiplier))}.telia-icon--md{height:calc(2.4rem * var(--voca-rem-multiplier));min-width:calc(2.4rem * var(--voca-rem-multiplier));width:calc(2.4rem * var(--voca-rem-multiplier))}.telia-icon--lg{height:calc(3.2rem * var(--voca-rem-multiplier));min-width:calc(3.2rem * var(--voca-rem-multiplier));width:calc(3.2rem * var(--voca-rem-multiplier))}",Tr=tn(class extends Fi{constructor(){super(),this.__registerHost(),this.size="md",this.allyTitle=null,this.dataTrackingId="telia-icon"}getSvgString(){if(this.svg)return this.svg;if(Cr()&&this.name){const i=Er();return i[this.name]?i[this.name].svg:""}return this.name&&console.warn(this.name,"Icons bundle is not registered and will not be rendered. Check if you have registered icons bundle or use svg property"),""}render(){let i=this.getSvgString(),t=[{name:"viewBox",value:"0 0 64 64"}];this.allyTitle?t=[...t,{name:"role",value:"img"}]:t=[...t,{name:"aria-hidden",value:"true"}];const e=_r({content:wr(i),attributes:t,title:this.allyTitle});return Y(de,{class:`telia-icon telia-icon--${this.size}`},Y("span",{"aria-label":this.allyTitle,class:"telia-icon__container",innerHTML:e}),Y("telia-vst",{dataTrackingId:this.dataTrackingId}))}static get style(){return Or}},[0,"telia-icon",{name:[1],svg:[1],size:[1],allyTitle:[1,"ally-title"],dataTestid:[1,"data-testid"]}]);function Pr(){if(typeof customElements>"u")return;["telia-icon","telia-vst"].forEach(t=>{switch(t){case"telia-icon":customElements.get(t)||customElements.define(t,Tr);break;case"telia-vst":customElements.get(t)||sn();break}})}Pr();var Ir=Object.defineProperty,Lr=(i,t,e,n)=>{for(var s=void 0,r=i.length-1,o;r>=0;r--)(o=i[r])&&(s=o(t,e,s)||s);return s&&Ir(t,e,s),s};const ii=Bi(x),ye=class ye extends ii{constructor(){super(...arguments),this.optionsIsVisible=!1,this.options=new Ls(this),this.optionsRef=_t(),this.optionsTriggerRef=_t(),this._onClickOutside=t=>{!this.optionsTriggerRef.value||!this.optionsRef.value||t.composedPath().includes(this.optionsTriggerRef.value)||t.composedPath().includes(this.optionsRef.value)||(this.optionsIsVisible=!1)}}addOption(t){return this.options.addOption(t)}removeOption(t){const e=this.options.removeOption(t);return this.requestUpdate(),e}_onToggleOptionsMenuClick(){this.optionsIsVisible=!this.optionsIsVisible}connectedCallback(){super.connectedCallback(),document.addEventListener("click",this._onClickOutside)}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("click",this._onClickOutside)}render(){return this.options.options.length?k` <div class="side-menu">
|
|
446
|
+
<div
|
|
447
|
+
class="options-menu"
|
|
448
|
+
${le(this.optionsRef)}
|
|
449
|
+
${Mi({keyframeOptions:{duration:120},in:Me,out:Me,stabilizeOut:!0,skipInitial:!1})}
|
|
450
|
+
>
|
|
451
|
+
${this.options.options.map(t=>k`<button
|
|
452
|
+
class="options-menu__item"
|
|
453
|
+
data-testid="${t.key}"
|
|
454
|
+
@click=${()=>{t.closeOnClick&&this._onToggleOptionsMenuClick(),t.onClick(),this.requestUpdate()}}
|
|
455
|
+
?disabled="${!t.enabled}"
|
|
456
|
+
>
|
|
457
|
+
${t.icon?k`<telia-icon
|
|
458
|
+
class="option-icon"
|
|
459
|
+
svg=${t.icon}
|
|
460
|
+
size="sm"
|
|
461
|
+
></telia-icon>`:p}
|
|
462
|
+
</button>`)}
|
|
463
|
+
</div>
|
|
464
|
+
</div>`:p}};ye.styles=[ii.styles||[],M`
|
|
465
|
+
:host {
|
|
466
|
+
--header-text-color: var(--text-on-primary-background);
|
|
467
|
+
overflow: revert;
|
|
468
|
+
}
|
|
469
|
+
|
|
470
|
+
:focus {
|
|
471
|
+
outline-color: var(--focus-color);
|
|
472
|
+
}
|
|
473
|
+
|
|
474
|
+
.side-menu {
|
|
475
|
+
padding-left: var(--spacing-sm);
|
|
476
|
+
|
|
477
|
+
background-color: transparent;
|
|
478
|
+
color: var(--header-text-color);
|
|
479
|
+
display: flex;
|
|
480
|
+
gap: var(--spacing-md);
|
|
481
|
+
flex-direction: row;
|
|
482
|
+
justify-content: space-between;
|
|
483
|
+
align-items: center;
|
|
484
|
+
border-radius: var(--spacing-sm) var(--spacing-sm) 0px 0px;
|
|
485
|
+
/* padding: 0 var(--spacing-xs); */
|
|
486
|
+
}
|
|
487
|
+
|
|
488
|
+
button {
|
|
489
|
+
background-color: transparent;
|
|
490
|
+
//TODO: Add border color
|
|
491
|
+
border: 1px solid var(--header-text-color);
|
|
492
|
+
font-family: inherit;
|
|
493
|
+
font-size: inherit;
|
|
494
|
+
cursor: pointer;
|
|
495
|
+
|
|
496
|
+
transition: all 300ms ease-in-out;
|
|
497
|
+
padding: var(--spacing-sm);
|
|
498
|
+
}
|
|
499
|
+
|
|
500
|
+
.side-menu__action-buttons {
|
|
501
|
+
display: flex;
|
|
502
|
+
flex-direction: column;
|
|
503
|
+
gap: var(--spacing-md);
|
|
504
|
+
}
|
|
505
|
+
|
|
506
|
+
.side-menu__action-button {
|
|
507
|
+
border-radius: var(--border-radius-xl);
|
|
508
|
+
color: var(--header-text-color);
|
|
509
|
+
display: flex;
|
|
510
|
+
align-items: center;
|
|
511
|
+
justify-content: center;
|
|
512
|
+
}
|
|
513
|
+
|
|
514
|
+
.side-menu__action-button:hover {
|
|
515
|
+
background-color: rgba(255, 255, 255, 0.1);
|
|
516
|
+
}
|
|
517
|
+
.side-menu__action-button:active {
|
|
518
|
+
transform: scale(0.8);
|
|
519
|
+
}
|
|
520
|
+
|
|
521
|
+
.options-menu {
|
|
522
|
+
background-color: white;
|
|
523
|
+
color: #222;
|
|
524
|
+
overflow: visible;
|
|
525
|
+
padding: var(--spacing-sm);
|
|
526
|
+
border-radius: var(--border-radius-xl);
|
|
527
|
+
z-index: 1;
|
|
528
|
+
}
|
|
529
|
+
|
|
530
|
+
.options-menu__item {
|
|
531
|
+
padding: var(--border-radius);
|
|
532
|
+
transition: all 300ms ease-in-out;
|
|
533
|
+
cursor: pointer;
|
|
534
|
+
border-radius: var(--border-radius-xl);
|
|
535
|
+
display: flex;
|
|
536
|
+
gap: var(--spacing-sm);
|
|
537
|
+
align-items: center;
|
|
538
|
+
}
|
|
539
|
+
|
|
540
|
+
.options-menu__item:hover {
|
|
541
|
+
background-color: var(--secondary-background);
|
|
542
|
+
color: var(--text-on-secondary-background);
|
|
543
|
+
box-shadow: rgba(0, 18, 46, 0.16) 0px 6px 32px 0px;
|
|
544
|
+
}
|
|
545
|
+
|
|
546
|
+
.options-menu__item:disabled,
|
|
547
|
+
.options-menu__item[disabled] {
|
|
548
|
+
cursor: default;
|
|
549
|
+
pointer-events: none;
|
|
550
|
+
}
|
|
551
|
+
`];let at=ye;Lr([N()],at.prototype,"optionsIsVisible");exports.SideMenu=at;exports.default=at;
|