Socket
Socket
Sign inDemoInstall

@maggioli-design-system/mds-dropdown

Package Overview
Dependencies
11
Maintainers
2
Versions
34
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 5.1.1 to 5.2.0

dist/collection/components/mds-dropdown/meta/dictionary.js

2

dist/cjs/loader.cjs.js

@@ -9,3 +9,3 @@ 'use strict';

if (typeof window === 'undefined') return undefined;
return index.bootstrapLazy([["mds-dropdown.cjs",[[1,"mds-dropdown",{"arrow":[4],"arrowPadding":[2,"arrow-padding"],"autoPlacement":[4,"auto-placement"],"backdrop":[4],"flip":[4],"target":[1],"offset":[2],"placement":[1],"shift":[4],"shiftPadding":[2,"shift-padding"],"smooth":[4],"strategy":[1],"visible":[1540],"zIndex":[2,"z-index"]},null,{"arrow":["arrowChanged"],"arrowPadding":["arrowPaddingChanged"],"autoPlacement":["autoPlacementChanged"],"backdrop":["backdropChanged"],"flip":["flipChanged"],"offset":["offsetChanged"],"placement":["placementChanged"],"shift":["shiftChanged"],"shiftPadding":["shiftPaddingChanged"],"strategy":["strategyChanged"],"visible":["visibleChanged"],"zIndex":["zIndexChanged"]}]]]], options);
return index.bootstrapLazy([["mds-dropdown.cjs",[[1,"mds-dropdown",{"arrow":[4],"arrowPadding":[2,"arrow-padding"],"autoPlacement":[4,"auto-placement"],"backdrop":[4],"flip":[4],"interaction":[513],"target":[1],"offset":[2],"placement":[1],"shift":[4],"shiftPadding":[2,"shift-padding"],"smooth":[4],"strategy":[1],"visible":[1540],"zIndex":[2,"z-index"]},null,{"arrow":["arrowChanged"],"arrowPadding":["arrowPaddingChanged"],"autoPlacement":["autoPlacementChanged"],"backdrop":["backdropChanged"],"flip":["flipChanged"],"offset":["offsetChanged"],"placement":["placementChanged"],"shift":["shiftChanged"],"shiftPadding":["shiftPaddingChanged"],"strategy":["strategyChanged"],"visible":["visibleChanged"],"zIndex":["zIndexChanged"]}]]]], options);
};

@@ -12,0 +12,0 @@

@@ -20,5 +20,5 @@ 'use strict';

patchBrowser().then(options => {
return index.bootstrapLazy([["mds-dropdown.cjs",[[1,"mds-dropdown",{"arrow":[4],"arrowPadding":[2,"arrow-padding"],"autoPlacement":[4,"auto-placement"],"backdrop":[4],"flip":[4],"target":[1],"offset":[2],"placement":[1],"shift":[4],"shiftPadding":[2,"shift-padding"],"smooth":[4],"strategy":[1],"visible":[1540],"zIndex":[2,"z-index"]},null,{"arrow":["arrowChanged"],"arrowPadding":["arrowPaddingChanged"],"autoPlacement":["autoPlacementChanged"],"backdrop":["backdropChanged"],"flip":["flipChanged"],"offset":["offsetChanged"],"placement":["placementChanged"],"shift":["shiftChanged"],"shiftPadding":["shiftPaddingChanged"],"strategy":["strategyChanged"],"visible":["visibleChanged"],"zIndex":["zIndexChanged"]}]]]], options);
return index.bootstrapLazy([["mds-dropdown.cjs",[[1,"mds-dropdown",{"arrow":[4],"arrowPadding":[2,"arrow-padding"],"autoPlacement":[4,"auto-placement"],"backdrop":[4],"flip":[4],"interaction":[513],"target":[1],"offset":[2],"placement":[1],"shift":[4],"shiftPadding":[2,"shift-padding"],"smooth":[4],"strategy":[1],"visible":[1540],"zIndex":[2,"z-index"]},null,{"arrow":["arrowChanged"],"arrowPadding":["arrowPaddingChanged"],"autoPlacement":["autoPlacementChanged"],"backdrop":["backdropChanged"],"flip":["flipChanged"],"offset":["offsetChanged"],"placement":["placementChanged"],"shift":["shiftChanged"],"shiftPadding":["shiftPaddingChanged"],"strategy":["strategyChanged"],"visible":["visibleChanged"],"zIndex":["zIndexChanged"]}]]]], options);
});
exports.setNonce = index.setNonce;

@@ -37,2 +37,17 @@ import { hashValue, setAttributeIfEmpty } from "../../common/aria";

};
this.callerOnMouseOver = () => {
this.mouseoverTimer = setTimeout(() => {
clearTimeout(this.mouseoverTimer);
this.handleVisibility(true);
}, cssDurationToMilliseconds(this.cssMouseOverDelayDuration));
};
this.closeDropdownMouseLeave = () => {
this.handleVisibility(false);
this.host.removeEventListener('mouseleave', this.closeDropdownMouseLeave.bind(this));
this.host.addEventListener('mouseover', this.handleCloseDropdownMouseLeave.bind(this));
};
this.handleCloseDropdownMouseLeave = () => {
this.host.removeEventListener('mouseover', this.handleCloseDropdownMouseLeave.bind(this));
this.host.addEventListener('mouseleave', this.closeDropdownMouseLeave.bind(this));
};
this.arrowInset = (middleware, arrowPosition) => {

@@ -154,2 +169,3 @@ const { arrow } = middleware;

this.cssBackdropZIndex = elementStyles.getPropertyValue('--mds-dropdown-backdrop-z-index');
this.cssMouseOverDelayDuration = elementStyles.getPropertyValue('--mds-dropdown-mouseover-delay');
};

@@ -161,2 +177,3 @@ this.arrow = true;

this.flip = false;
this.interaction = 'click';
this.target = undefined;

@@ -276,3 +293,9 @@ this.offset = 24;

this.setAriaAttributes();
this.caller.addEventListener('click', this.callerOnClick.bind(this));
if (this.interaction === 'click') {
this.caller.addEventListener('click', this.callerOnClick.bind(this));
}
if (this.interaction === 'mouseover') {
this.caller.addEventListener('mouseover', this.callerOnMouseOver.bind(this));
this.host.addEventListener('mouseover', this.handleCloseDropdownMouseLeave.bind(this));
}
this.km.addElement(this.host);

@@ -398,2 +421,26 @@ this.km.attachEscapeBehavior(() => this.handleVisibility(false));

},
"interaction": {
"type": "string",
"mutable": false,
"complexType": {
"original": "DropdownInteractionType",
"resolved": "\"click\" | \"mouseover\" | undefined",
"references": {
"DropdownInteractionType": {
"location": "import",
"path": "./meta/types",
"id": "src/components/mds-dropdown/meta/types.ts::DropdownInteractionType"
}
}
},
"required": false,
"optional": true,
"docs": {
"tags": [],
"text": "Specifies if the component is triggered from the caller on mouseover or click event"
},
"attribute": "interaction",
"reflect": true,
"defaultValue": "'click'"
},
"target": {

@@ -400,0 +447,0 @@ "type": "string",

@@ -14,2 +14,3 @@ var __rest = (this && this.__rest) || function (s, e) {

import { floatingUIPlacementDictionary, floatingUIStrategyDictionary, } from "../../../dictionary/floating-ui";
import { dropdownInteractionDictionary } from "../meta/dictionary";
import { h } from "@stencil/core";

@@ -39,2 +40,8 @@ export default {

},
interaction: {
type: { name: 'string' },
description: 'Specifies if the component is triggered from the caller on mouseover or click event',
options: dropdownInteractionDictionary,
control: { type: 'select' },
},
offset: {

@@ -129,2 +136,10 @@ type: { name: 'number' },

};
export const Interaction = Template.bind({});
Interaction.args = {
class: 'max-w-[350px] w-full',
backdrop: true,
interaction: 'mouseover',
layout: 'flex justify-center',
visible: false,
};
export const Offset = Template.bind({});

@@ -131,0 +146,0 @@ Offset.args = {

{
"timestamp": "2024-02-19T12:05:50",
"timestamp": "2024-02-26T21:04:59",
"compiler": {

@@ -133,2 +133,38 @@ "name": "@stencil/core",

{
"name": "interaction",
"type": "\"click\" | \"mouseover\" | undefined",
"complexType": {
"original": "DropdownInteractionType",
"resolved": "\"click\" | \"mouseover\" | undefined",
"references": {
"DropdownInteractionType": {
"location": "import",
"path": "./meta/types",
"id": "src/components/mds-dropdown/meta/types.ts::DropdownInteractionType"
}
}
},
"mutable": false,
"attr": "interaction",
"reflectToAttr": true,
"docs": "Specifies if the component is triggered from the caller on mouseover or click event",
"docsTags": [],
"default": "'click'",
"values": [
{
"value": "click",
"type": "string"
},
{
"value": "mouseover",
"type": "string"
},
{
"type": "undefined"
}
],
"optional": true,
"required": false
},
{
"name": "offset",

@@ -493,2 +529,7 @@ "type": "number",

{
"name": "--mds-dropdown-mouseover-delay",
"annotation": "prop",
"docs": "Sets the delay duration of the component when the caller trigger mouseover event, it's used by the javascript code."
},
{
"name": "--mds-dropdown-transform-from",

@@ -522,2 +563,7 @@ "annotation": "prop",

"typeLibrary": {
"src/components/mds-dropdown/meta/types.ts::DropdownInteractionType": {
"declaration": "export type DropdownInteractionType =\n | 'click'\n | 'mouseover'",
"docstring": "",
"path": "src/components/mds-dropdown/meta/types.ts"
},
"src/type/floating-ui.ts::FloatingUIPlacement": {

@@ -524,0 +570,0 @@ "declaration": "export type FloatingUIPlacement =\n | 'bottom'\n | 'bottom-end'\n | 'bottom-start'\n | 'left'\n | 'left-end'\n | 'left-start'\n | 'right'\n | 'right-end'\n | 'right-start'\n | 'top'\n | 'top-end'\n | 'top-start'",

@@ -1,1 +0,1 @@

import{b as bootstrapLazy}from"./index-37f9ae9f.js";export{s as setNonce}from"./index-37f9ae9f.js";var defineCustomElements=function(e,a){if(typeof window==="undefined")return undefined;return bootstrapLazy([["mds-dropdown",[[1,"mds-dropdown",{arrow:[4],arrowPadding:[2,"arrow-padding"],autoPlacement:[4,"auto-placement"],backdrop:[4],flip:[4],target:[1],offset:[2],placement:[1],shift:[4],shiftPadding:[2,"shift-padding"],smooth:[4],strategy:[1],visible:[1540],zIndex:[2,"z-index"]},null,{arrow:["arrowChanged"],arrowPadding:["arrowPaddingChanged"],autoPlacement:["autoPlacementChanged"],backdrop:["backdropChanged"],flip:["flipChanged"],offset:["offsetChanged"],placement:["placementChanged"],shift:["shiftChanged"],shiftPadding:["shiftPaddingChanged"],strategy:["strategyChanged"],visible:["visibleChanged"],zIndex:["zIndexChanged"]}]]]],a)};export{defineCustomElements};
import{b as bootstrapLazy}from"./index-37f9ae9f.js";export{s as setNonce}from"./index-37f9ae9f.js";var defineCustomElements=function(e,a){if(typeof window==="undefined")return undefined;return bootstrapLazy([["mds-dropdown",[[1,"mds-dropdown",{arrow:[4],arrowPadding:[2,"arrow-padding"],autoPlacement:[4,"auto-placement"],backdrop:[4],flip:[4],interaction:[513],target:[1],offset:[2],placement:[1],shift:[4],shiftPadding:[2,"shift-padding"],smooth:[4],strategy:[1],visible:[1540],zIndex:[2,"z-index"]},null,{arrow:["arrowChanged"],arrowPadding:["arrowPaddingChanged"],autoPlacement:["autoPlacementChanged"],backdrop:["backdropChanged"],flip:["flipChanged"],offset:["offsetChanged"],placement:["placementChanged"],shift:["shiftChanged"],shiftPadding:["shiftPaddingChanged"],strategy:["strategyChanged"],visible:["visibleChanged"],zIndex:["zIndexChanged"]}]]]],a)};export{defineCustomElements};

@@ -1,1 +0,1 @@

var __assign=this&&this.__assign||function(){__assign=Object.assign||function(t){for(var e,r=1,n=arguments.length;r<n;r++){e=arguments[r];for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i))t[i]=e[i]}return t};return __assign.apply(this,arguments)};var __awaiter=this&&this.__awaiter||function(t,e,r,n){function i(t){return t instanceof r?t:new r((function(e){e(t)}))}return new(r||(r=Promise))((function(r,o){function a(t){try{l(n.next(t))}catch(t){o(t)}}function s(t){try{l(n["throw"](t))}catch(t){o(t)}}function l(t){t.done?r(t.value):i(t.value).then(a,s)}l((n=n.apply(t,e||[])).next())}))};var __generator=this&&this.__generator||function(t,e){var r={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},n,i,o,a;return a={next:s(0),throw:s(1),return:s(2)},typeof Symbol==="function"&&(a[Symbol.iterator]=function(){return this}),a;function s(t){return function(e){return l([t,e])}}function l(s){if(n)throw new TypeError("Generator is already executing.");while(a&&(a=0,s[0]&&(r=0)),r)try{if(n=1,i&&(o=s[0]&2?i["return"]:s[0]?i["throw"]||((o=i["return"])&&o.call(i),0):i.next)&&!(o=o.call(i,s[1])).done)return o;if(i=0,o)s=[s[0]&2,o.value];switch(s[0]){case 0:case 1:o=s;break;case 4:r.label++;return{value:s[1],done:false};case 5:r.label++;i=s[1];s=[0];continue;case 7:s=r.ops.pop();r.trys.pop();continue;default:if(!(o=r.trys,o=o.length>0&&o[o.length-1])&&(s[0]===6||s[0]===2)){r=0;continue}if(s[0]===3&&(!o||s[1]>o[0]&&s[1]<o[3])){r.label=s[1];break}if(s[0]===6&&r.label<o[1]){r.label=o[1];o=s;break}if(o&&r.label<o[2]){r.label=o[2];r.ops.push(s);break}if(o[2])r.ops.pop();r.trys.pop();continue}s=e.call(t,r)}catch(t){s=[6,t];i=0}finally{n=o=0}if(s[0]&5)throw s[1];return{value:s[0]?s[1]:void 0,done:true}}};var __rest=this&&this.__rest||function(t,e){var r={};for(var n in t)if(Object.prototype.hasOwnProperty.call(t,n)&&e.indexOf(n)<0)r[n]=t[n];if(t!=null&&typeof Object.getOwnPropertySymbols==="function")for(var i=0,n=Object.getOwnPropertySymbols(t);i<n.length;i++){if(e.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(t,n[i]))r[n[i]]=t[n[i]]}return r};var __spreadArray=this&&this.__spreadArray||function(t,e,r){if(r||arguments.length===2)for(var n=0,i=e.length,o;n<i;n++){if(o||!(n in e)){if(!o)o=Array.prototype.slice.call(e,0,n);o[n]=e[n]}}return t.concat(o||Array.prototype.slice.call(e))};import{r as registerInstance,c as createEvent,h,H as Host,g as getElement}from"./index-37f9ae9f.js";var hash=function(t){var e,r;for(e=0,r=0;e<t.length;e++){r=Math.imul(31,r)+t.charCodeAt(e)|0}return r.toString()};var setAttributeIfEmpty=function(t,e,r){var n;if(t.hasAttribute(e)){return(n=t.getAttribute(e))!==null&&n!==void 0?n:""}t.setAttribute(e,r);return r};var hashValue=function(t){return"".concat(t,"-").concat(hash(t))};var KeyboardManager=function(){function t(){var t=this;this.elements=new Map;this.handleClickBehaviorDispatchEvent=function(t){if(t.code==="Enter"||t.code==="NumpadEnter"){t.target.click()}};this.handleEscapeBehaviorDispatchEvent=function(e){if(e.code==="Escape"&&t.escapeCallback){t.escapeCallback()}};this.addElement=function(e,r){if(r===void 0){r="element"}if(!e){throw Error("Passed an ".concat(e," element parameter to KeyboardManager.addElement"))}t.elements.set(r,e)};this.removeElement=function(e){if(e===void 0){e="element"}t.detachClickBehavior(e);t.elements.delete(e)};this.attachClickBehavior=function(e){if(e===void 0){e="element"}var r;(r=t.elements.get(e))===null||r===void 0?void 0:r.addEventListener("keydown",t.handleClickBehaviorDispatchEvent)};this.detachClickBehavior=function(e){if(e===void 0){e="element"}var r;(r=t.elements.get(e))===null||r===void 0?void 0:r.removeEventListener("keydown",t.handleClickBehaviorDispatchEvent)};this.attachEscapeBehavior=function(e){t.escapeCallback=e;if(window!==undefined){window.addEventListener("keydown",t.handleEscapeBehaviorDispatchEvent.bind(t))}};this.detachEscapeBehavior=function(){t.escapeCallback=function(){return};if(window!==undefined){window.removeEventListener("keydown",t.handleEscapeBehaviorDispatchEvent.bind(t))}}}return t}();var cssDurationToMilliseconds=function(t,e){if(e===void 0){e=1e3}if(t.includes("ms")){return Number(t.replace("ms",""))}if(t.includes("s")){return Number(t.replace("s",""))*1e3}return e};var sides=["top","right","bottom","left"];var alignments=["start","end"];var placements=sides.reduce((function(t,e){return t.concat(e,e+"-"+alignments[0],e+"-"+alignments[1])}),[]);var min=Math.min;var max=Math.max;var round=Math.round;var floor=Math.floor;var createCoords=function(t){return{x:t,y:t}};var oppositeSideMap={left:"right",right:"left",bottom:"top",top:"bottom"};var oppositeAlignmentMap={start:"end",end:"start"};function clamp(t,e,r){return max(t,min(e,r))}function evaluate(t,e){return typeof t==="function"?t(e):t}function getSide(t){return t.split("-")[0]}function getAlignment(t){return t.split("-")[1]}function getOppositeAxis(t){return t==="x"?"y":"x"}function getAxisLength(t){return t==="y"?"height":"width"}function getSideAxis(t){return["top","bottom"].includes(getSide(t))?"y":"x"}function getAlignmentAxis(t){return getOppositeAxis(getSideAxis(t))}function getAlignmentSides(t,e,r){if(r===void 0){r=false}var n=getAlignment(t);var i=getAlignmentAxis(t);var o=getAxisLength(i);var a=i==="x"?n===(r?"end":"start")?"right":"left":n==="start"?"bottom":"top";if(e.reference[o]>e.floating[o]){a=getOppositePlacement(a)}return[a,getOppositePlacement(a)]}function getExpandedPlacements(t){var e=getOppositePlacement(t);return[getOppositeAlignmentPlacement(t),e,getOppositeAlignmentPlacement(e)]}function getOppositeAlignmentPlacement(t){return t.replace(/start|end/g,(function(t){return oppositeAlignmentMap[t]}))}function getSideList(t,e,r){var n=["left","right"];var i=["right","left"];var o=["top","bottom"];var a=["bottom","top"];switch(t){case"top":case"bottom":if(r)return e?i:n;return e?n:i;case"left":case"right":return e?o:a;default:return[]}}function getOppositeAxisPlacements(t,e,r,n){var i=getAlignment(t);var o=getSideList(getSide(t),r==="start",n);if(i){o=o.map((function(t){return t+"-"+i}));if(e){o=o.concat(o.map(getOppositeAlignmentPlacement))}}return o}function getOppositePlacement(t){return t.replace(/left|right|bottom|top/g,(function(t){return oppositeSideMap[t]}))}function expandPaddingObject(t){return __assign({top:0,right:0,bottom:0,left:0},t)}function getPaddingObject(t){return typeof t!=="number"?expandPaddingObject(t):{top:t,right:t,bottom:t,left:t}}function rectToClientRect(t){return __assign(__assign({},t),{top:t.y,left:t.x,right:t.x+t.width,bottom:t.y+t.height})}function computeCoordsFromPlacement(t,e,r){var n=t.reference,i=t.floating;var o=getSideAxis(e);var a=getAlignmentAxis(e);var s=getAxisLength(a);var l=getSide(e);var c=o==="y";var u=n.x+n.width/2-i.width/2;var f=n.y+n.height/2-i.height/2;var d=n[s]/2-i[s]/2;var g;switch(l){case"top":g={x:u,y:n.y-i.height};break;case"bottom":g={x:u,y:n.y+n.height};break;case"right":g={x:n.x+n.width,y:f};break;case"left":g={x:n.x-i.width,y:f};break;default:g={x:n.x,y:n.y}}switch(getAlignment(e)){case"start":g[a]-=d*(r&&c?-1:1);break;case"end":g[a]+=d*(r&&c?-1:1);break}return g}var computePosition$1=function(t,e,r){return __awaiter(void 0,void 0,void 0,(function(){var n,i,o,a,s,l,c,u,f,d,g,v,m,p,b,h,w,y,x,k,_,A,C,O,E,P;var S,R;return __generator(this,(function(T){switch(T.label){case 0:n=r.placement,i=n===void 0?"bottom":n,o=r.strategy,a=o===void 0?"absolute":o,s=r.middleware,l=s===void 0?[]:s,c=r.platform;u=l.filter(Boolean);return[4,c.isRTL==null?void 0:c.isRTL(e)];case 1:f=T.sent();return[4,c.getElementRects({reference:t,floating:e,strategy:a})];case 2:d=T.sent();g=computeCoordsFromPlacement(d,i,f),v=g.x,m=g.y;p=i;b={};h=0;w=0;T.label=3;case 3:if(!(w<u.length))return[3,11];y=u[w],x=y.name,k=y.fn;return[4,k({x:v,y:m,initialPlacement:i,placement:p,strategy:a,middlewareData:b,rects:d,platform:c,elements:{reference:t,floating:e}})];case 4:_=T.sent(),A=_.x,C=_.y,O=_.data,E=_.reset;v=A!=null?A:v;m=C!=null?C:m;b=__assign(__assign({},b),(S={},S[x]=__assign(__assign({},b[x]),O),S));if(!(E&&h<=50))return[3,10];h++;if(!(typeof E==="object"))return[3,9];if(E.placement){p=E.placement}if(!E.rects)return[3,8];if(!(E.rects===true))return[3,6];return[4,c.getElementRects({reference:t,floating:e,strategy:a})];case 5:P=T.sent();return[3,7];case 6:P=E.rects;T.label=7;case 7:d=P;T.label=8;case 8:R=computeCoordsFromPlacement(d,p,f),v=R.x,m=R.y;T.label=9;case 9:w=-1;T.label=10;case 10:w++;return[3,3];case 11:return[2,{x:v,y:m,placement:p,strategy:a,middlewareData:b}]}}))}))};function detectOverflow(t,e){return __awaiter(this,void 0,void 0,(function(){var r,n,i,o,a,s,l,c,u,f,d,g,v,m,p,b,h,w,y,x,k,_,A,C,O,E,P,S,R,T,N,M,L,D;var j;return __generator(this,(function(z){switch(z.label){case 0:if(e===void 0){e={}}n=t.x,i=t.y,o=t.platform,a=t.rects,s=t.elements,l=t.strategy;c=evaluate(e,t),u=c.boundary,f=u===void 0?"clippingAncestors":u,d=c.rootBoundary,g=d===void 0?"viewport":d,v=c.elementContext,m=v===void 0?"floating":v,p=c.altBoundary,b=p===void 0?false:p,h=c.padding,w=h===void 0?0:h;y=getPaddingObject(w);x=m==="floating"?"reference":"floating";k=s[b?x:m];A=rectToClientRect;O=(C=o).getClippingRect;j={};return[4,o.isElement==null?void 0:o.isElement(k)];case 1:if(!((r=z.sent())!=null?r:true))return[3,2];E=k;return[3,5];case 2:P=k.contextElement;if(P)return[3,4];return[4,o.getDocumentElement==null?void 0:o.getDocumentElement(s.floating)];case 3:P=z.sent();z.label=4;case 4:E=P;z.label=5;case 5:return[4,O.apply(C,[(j.element=E,j.boundary=f,j.rootBoundary=g,j.strategy=l,j)])];case 6:_=A.apply(void 0,[z.sent()]);S=m==="floating"?__assign(__assign({},a.floating),{x:n,y:i}):a.reference;return[4,o.getOffsetParent==null?void 0:o.getOffsetParent(s.floating)];case 7:R=z.sent();return[4,o.isElement==null?void 0:o.isElement(R)];case 8:if(!z.sent())return[3,10];return[4,o.getScale==null?void 0:o.getScale(R)];case 9:N=z.sent()||{x:1,y:1};return[3,11];case 10:N={x:1,y:1};z.label=11;case 11:T=N;L=rectToClientRect;if(!o.convertOffsetParentRelativeRectToViewportRelativeRect)return[3,13];return[4,o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:S,offsetParent:R,strategy:l})];case 12:D=z.sent();return[3,14];case 13:D=S;z.label=14;case 14:M=L.apply(void 0,[D]);return[2,{top:(_.top-M.top+y.top)/T.y,bottom:(M.bottom-_.bottom+y.bottom)/T.y,left:(_.left-M.left+y.left)/T.x,right:(M.right-_.right+y.right)/T.x}]}}))}))}var arrow$1=function(t){return{name:"arrow",options:t,fn:function(e){return __awaiter(this,void 0,void 0,(function(){var r,n,i,o,a,s,l,c,u,f,d,g,v,m,p,b,h,w,y,x,k,_,A,C,O,E,P,S,R,T,N,M,L,D,j;var z,W;return __generator(this,(function(B){switch(B.label){case 0:r=e.x,n=e.y,i=e.placement,o=e.rects,a=e.platform,s=e.elements,l=e.middlewareData;c=evaluate(t,e)||{},u=c.element,f=c.padding,d=f===void 0?0:f;if(u==null){return[2,{}]}g=getPaddingObject(d);v={x:r,y:n};m=getAlignmentAxis(i);p=getAxisLength(m);return[4,a.getDimensions(u)];case 1:b=B.sent();h=m==="y";w=h?"top":"left";y=h?"bottom":"right";x=h?"clientHeight":"clientWidth";k=o.reference[p]+o.reference[m]-v[m]-o.floating[p];_=v[m]-o.reference[m];return[4,a.getOffsetParent==null?void 0:a.getOffsetParent(u)];case 2:A=B.sent();C=A?A[x]:0;O=!C;if(O)return[3,4];return[4,a.isElement==null?void 0:a.isElement(A)];case 3:O=!B.sent();B.label=4;case 4:if(O){C=s.floating[x]||o.floating[p]}E=k/2-_/2;P=C/2-b[p]/2-1;S=min(g[w],P);R=min(g[y],P);T=S;N=C-b[p]-R;M=C/2-b[p]/2+E;L=clamp(T,M,N);D=!l.arrow&&getAlignment(i)!=null&&M!==L&&o.reference[p]/2-(M<T?S:R)-b[p]/2<0;j=D?M<T?M-T:M-N:0;return[2,(z={},z[m]=v[m]+j,z.data=__assign((W={},W[m]=L,W.centerOffset=M-L-j,W),D&&{alignmentOffset:j}),z.reset=D,z)]}}))}))}}};function getPlacementList(t,e,r){var n=t?__spreadArray(__spreadArray([],r.filter((function(e){return getAlignment(e)===t})),true),r.filter((function(e){return getAlignment(e)!==t})),true):r.filter((function(t){return getSide(t)===t}));return n.filter((function(r){if(t){return getAlignment(r)===t||(e?getOppositeAlignmentPlacement(r)!==r:false)}return true}))}var autoPlacement$1=function(t){if(t===void 0){t={}}return{name:"autoPlacement",options:t,fn:function(e){return __awaiter(this,void 0,void 0,(function(){var r,n,i,o,a,s,l,c,u,f,d,g,v,m,p,b,h,w,y,x,k,_,A,C,O,E,P,S,R,T;return __generator(this,(function(N){switch(N.label){case 0:o=e.rects,a=e.middlewareData,s=e.placement,l=e.platform,c=e.elements;u=evaluate(t,e),f=u.crossAxis,d=f===void 0?false:f,g=u.alignment,v=u.allowedPlacements,m=v===void 0?placements:v,p=u.autoAlignment,b=p===void 0?true:p,h=__rest(u,["crossAxis","alignment","allowedPlacements","autoAlignment"]);w=g!==undefined||m===placements?getPlacementList(g||null,b,m):m;return[4,detectOverflow(e,h)];case 1:y=N.sent();x=((r=a.autoPlacement)==null?void 0:r.index)||0;k=w[x];if(k==null){return[2,{}]}A=getAlignmentSides;C=[k,o];return[4,l.isRTL==null?void 0:l.isRTL(c.floating)];case 2:_=A.apply(void 0,C.concat([N.sent()]));if(s!==k){return[2,{reset:{placement:w[0]}}]}O=[y[getSide(k)],y[_[0]],y[_[1]]];E=__spreadArray(__spreadArray([],((n=a.autoPlacement)==null?void 0:n.overflows)||[],true),[{placement:k,overflows:O}],false);P=w[x+1];if(P){return[2,{data:{index:x+1,overflows:E},reset:{placement:P}}]}S=E.map((function(t){var e=getAlignment(t.placement);return[t.placement,e&&d?t.overflows.slice(0,2).reduce((function(t,e){return t+e}),0):t.overflows[0],t.overflows]})).sort((function(t,e){return t[1]-e[1]}));R=S.filter((function(t){return t[2].slice(0,getAlignment(t[0])?2:3).every((function(t){return t<=0}))}));T=((i=R[0])==null?void 0:i[0])||S[0][0];if(T!==s){return[2,{data:{index:x+1,overflows:E},reset:{placement:T}}]}return[2,{}]}}))}))}}};var flip$1=function(t){if(t===void 0){t={}}return{name:"flip",options:t,fn:function(e){return __awaiter(this,void 0,void 0,(function(){var r,n,i,o,a,s,l,c,u,f,d,g,v,m,p,b,h,w,y,x,k,_,A,C,O,E,P,S,R,T,N,M,L,D,j,z,W;return __generator(this,(function(B){switch(B.label){case 0:i=e.placement,o=e.middlewareData,a=e.rects,s=e.initialPlacement,l=e.platform,c=e.elements;u=evaluate(t,e),f=u.mainAxis,d=f===void 0?true:f,g=u.crossAxis,v=g===void 0?true:g,m=u.fallbackPlacements,p=u.fallbackStrategy,b=p===void 0?"bestFit":p,h=u.fallbackAxisSideDirection,w=h===void 0?"none":h,y=u.flipAlignment,x=y===void 0?true:y,k=__rest(u,["mainAxis","crossAxis","fallbackPlacements","fallbackStrategy","fallbackAxisSideDirection","flipAlignment"]);if((r=o.arrow)!=null&&r.alignmentOffset){return[2,{}]}_=getSide(i);A=getSide(s)===s;return[4,l.isRTL==null?void 0:l.isRTL(c.floating)];case 1:C=B.sent();O=m||(A||!x?[getOppositePlacement(s)]:getExpandedPlacements(s));if(!m&&w!=="none"){O.push.apply(O,getOppositeAxisPlacements(s,x,w,C))}E=__spreadArray([s],O,true);return[4,detectOverflow(e,k)];case 2:P=B.sent();S=[];R=((n=o.flip)==null?void 0:n.overflows)||[];if(d){S.push(P[_])}if(v){T=getAlignmentSides(i,a,C);S.push(P[T[0]],P[T[1]])}R=__spreadArray(__spreadArray([],R,true),[{placement:i,overflows:S}],false);if(!S.every((function(t){return t<=0}))){L=(((N=o.flip)==null?void 0:N.index)||0)+1;D=E[L];if(D){return[2,{data:{index:L,overflows:R},reset:{placement:D}}]}j=(M=R.filter((function(t){return t.overflows[0]<=0})).sort((function(t,e){return t.overflows[1]-e.overflows[1]}))[0])==null?void 0:M.placement;if(!j){switch(b){case"bestFit":{W=(z=R.map((function(t){return[t.placement,t.overflows.filter((function(t){return t>0})).reduce((function(t,e){return t+e}),0)]})).sort((function(t,e){return t[1]-e[1]}))[0])==null?void 0:z[0];if(W){j=W}break}case"initialPlacement":j=s;break}}if(i!==j){return[2,{reset:{placement:j}}]}}return[2,{}]}}))}))}}};function convertValueToCoords(t,e){return __awaiter(this,void 0,void 0,(function(){var r,n,i,o,a,s,l,c,u,f,d,g,v,m;return __generator(this,(function(p){switch(p.label){case 0:r=t.placement,n=t.platform,i=t.elements;return[4,n.isRTL==null?void 0:n.isRTL(i.floating)];case 1:o=p.sent();a=getSide(r);s=getAlignment(r);l=getSideAxis(r)==="y";c=["left","top"].includes(a)?-1:1;u=o&&l?-1:1;f=evaluate(e,t);d=typeof f==="number"?{mainAxis:f,crossAxis:0,alignmentAxis:null}:__assign({mainAxis:0,crossAxis:0,alignmentAxis:null},f),g=d.mainAxis,v=d.crossAxis,m=d.alignmentAxis;if(s&&typeof m==="number"){v=s==="end"?m*-1:m}return[2,l?{x:v*u,y:g*c}:{x:g*c,y:v*u}]}}))}))}var offset=function(t){if(t===void 0){t=0}return{name:"offset",options:t,fn:function(e){return __awaiter(this,void 0,void 0,(function(){var r,n,i,o,a,s,l;return __generator(this,(function(c){switch(c.label){case 0:i=e.x,o=e.y,a=e.placement,s=e.middlewareData;return[4,convertValueToCoords(e,t)];case 1:l=c.sent();if(a===((r=s.offset)==null?void 0:r.placement)&&(n=s.arrow)!=null&&n.alignmentOffset){return[2,{}]}return[2,{x:i+l.x,y:o+l.y,data:__assign(__assign({},l),{placement:a})}]}}))}))}}};var shift$1=function(t){if(t===void 0){t={}}return{name:"shift",options:t,fn:function(e){return __awaiter(this,void 0,void 0,(function(){var r,n,i,o,a,s,l,c,u,f,d,g,v,m,p,b,h,w,y,x,k,w,y,_,A,C;var O;return __generator(this,(function(E){switch(E.label){case 0:r=e.x,n=e.y,i=e.placement;o=evaluate(t,e),a=o.mainAxis,s=a===void 0?true:a,l=o.crossAxis,c=l===void 0?false:l,u=o.limiter,f=u===void 0?{fn:function(t){var e=t.x,r=t.y;return{x:e,y:r}}}:u,d=__rest(o,["mainAxis","crossAxis","limiter"]);g={x:r,y:n};return[4,detectOverflow(e,d)];case 1:v=E.sent();m=getSideAxis(getSide(i));p=getOppositeAxis(m);b=g[p];h=g[m];if(s){w=p==="y"?"top":"left";y=p==="y"?"bottom":"right";x=b+v[w];k=b-v[y];b=clamp(x,b,k)}if(c){w=m==="y"?"top":"left";y=m==="y"?"bottom":"right";_=h+v[w];A=h-v[y];h=clamp(_,h,A)}C=f.fn(__assign(__assign({},e),(O={},O[p]=b,O[m]=h,O)));return[2,__assign(__assign({},C),{data:{x:C.x-r,y:C.y-n}})]}}))}))}}};function getNodeName(t){if(isNode(t)){return(t.nodeName||"").toLowerCase()}return"#document"}function getWindow(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function getDocumentElement(t){var e;return(e=(isNode(t)?t.ownerDocument:t.document)||window.document)==null?void 0:e.documentElement}function isNode(t){return t instanceof Node||t instanceof getWindow(t).Node}function isElement(t){return t instanceof Element||t instanceof getWindow(t).Element}function isHTMLElement(t){return t instanceof HTMLElement||t instanceof getWindow(t).HTMLElement}function isShadowRoot(t){if(typeof ShadowRoot==="undefined"){return false}return t instanceof ShadowRoot||t instanceof getWindow(t).ShadowRoot}function isOverflowElement(t){var e=getComputedStyle(t),r=e.overflow,n=e.overflowX,i=e.overflowY,o=e.display;return/auto|scroll|overlay|hidden|clip/.test(r+i+n)&&!["inline","contents"].includes(o)}function isTableElement(t){return["table","td","th"].includes(getNodeName(t))}function isContainingBlock(t){var e=isWebKit();var r=getComputedStyle(t);return r.transform!=="none"||r.perspective!=="none"||(r.containerType?r.containerType!=="normal":false)||!e&&(r.backdropFilter?r.backdropFilter!=="none":false)||!e&&(r.filter?r.filter!=="none":false)||["transform","perspective","filter"].some((function(t){return(r.willChange||"").includes(t)}))||["paint","layout","strict","content"].some((function(t){return(r.contain||"").includes(t)}))}function getContainingBlock(t){var e=getParentNode(t);while(isHTMLElement(e)&&!isLastTraversableNode(e)){if(isContainingBlock(e)){return e}else{e=getParentNode(e)}}return null}function isWebKit(){if(typeof CSS==="undefined"||!CSS.supports)return false;return CSS.supports("-webkit-backdrop-filter","none")}function isLastTraversableNode(t){return["html","body","#document"].includes(getNodeName(t))}function getComputedStyle(t){return getWindow(t).getComputedStyle(t)}function getNodeScroll(t){if(isElement(t)){return{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}}return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function getParentNode(t){if(getNodeName(t)==="html"){return t}var e=t.assignedSlot||t.parentNode||isShadowRoot(t)&&t.host||getDocumentElement(t);return isShadowRoot(e)?e.host:e}function getNearestOverflowAncestor(t){var e=getParentNode(t);if(isLastTraversableNode(e)){return t.ownerDocument?t.ownerDocument.body:t.body}if(isHTMLElement(e)&&isOverflowElement(e)){return e}return getNearestOverflowAncestor(e)}function getOverflowAncestors(t,e,r){var n;if(e===void 0){e=[]}if(r===void 0){r=true}var i=getNearestOverflowAncestor(t);var o=i===((n=t.ownerDocument)==null?void 0:n.body);var a=getWindow(i);if(o){return e.concat(a,a.visualViewport||[],isOverflowElement(i)?i:[],a.frameElement&&r?getOverflowAncestors(a.frameElement):[])}return e.concat(i,getOverflowAncestors(i,[],r))}function getCssDimensions(t){var e=getComputedStyle(t);var r=parseFloat(e.width)||0;var n=parseFloat(e.height)||0;var i=isHTMLElement(t);var o=i?t.offsetWidth:r;var a=i?t.offsetHeight:n;var s=round(r)!==o||round(n)!==a;if(s){r=o;n=a}return{width:r,height:n,$:s}}function unwrapElement(t){return!isElement(t)?t.contextElement:t}function getScale(t){var e=unwrapElement(t);if(!isHTMLElement(e)){return createCoords(1)}var r=e.getBoundingClientRect();var n=getCssDimensions(e),i=n.width,o=n.height,a=n.$;var s=(a?round(r.width):r.width)/i;var l=(a?round(r.height):r.height)/o;if(!s||!Number.isFinite(s)){s=1}if(!l||!Number.isFinite(l)){l=1}return{x:s,y:l}}var noOffsets=createCoords(0);function getVisualOffsets(t){var e=getWindow(t);if(!isWebKit()||!e.visualViewport){return noOffsets}return{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function shouldAddVisualOffsets(t,e,r){if(e===void 0){e=false}if(!r||e&&r!==getWindow(t)){return false}return e}function getBoundingClientRect(t,e,r,n){if(e===void 0){e=false}if(r===void 0){r=false}var i=t.getBoundingClientRect();var o=unwrapElement(t);var a=createCoords(1);if(e){if(n){if(isElement(n)){a=getScale(n)}}else{a=getScale(t)}}var s=shouldAddVisualOffsets(o,r,n)?getVisualOffsets(o):createCoords(0);var l=(i.left+s.x)/a.x;var c=(i.top+s.y)/a.y;var u=i.width/a.x;var f=i.height/a.y;if(o){var d=getWindow(o);var g=n&&isElement(n)?getWindow(n):n;var v=d.frameElement;while(v&&n&&g!==d){var m=getScale(v);var p=v.getBoundingClientRect();var b=getComputedStyle(v);var h=p.left+(v.clientLeft+parseFloat(b.paddingLeft))*m.x;var w=p.top+(v.clientTop+parseFloat(b.paddingTop))*m.y;l*=m.x;c*=m.y;u*=m.x;f*=m.y;l+=h;c+=w;v=getWindow(v).frameElement}}return rectToClientRect({width:u,height:f,x:l,y:c})}function convertOffsetParentRelativeRectToViewportRelativeRect(t){var e=t.rect,r=t.offsetParent,n=t.strategy;var i=isHTMLElement(r);var o=getDocumentElement(r);if(r===o){return e}var a={scrollLeft:0,scrollTop:0};var s=createCoords(1);var l=createCoords(0);if(i||!i&&n!=="fixed"){if(getNodeName(r)!=="body"||isOverflowElement(o)){a=getNodeScroll(r)}if(isHTMLElement(r)){var c=getBoundingClientRect(r);s=getScale(r);l.x=c.x+r.clientLeft;l.y=c.y+r.clientTop}}return{width:e.width*s.x,height:e.height*s.y,x:e.x*s.x-a.scrollLeft*s.x+l.x,y:e.y*s.y-a.scrollTop*s.y+l.y}}function getClientRects(t){return Array.from(t.getClientRects())}function getWindowScrollBarX(t){return getBoundingClientRect(getDocumentElement(t)).left+getNodeScroll(t).scrollLeft}function getDocumentRect(t){var e=getDocumentElement(t);var r=getNodeScroll(t);var n=t.ownerDocument.body;var i=max(e.scrollWidth,e.clientWidth,n.scrollWidth,n.clientWidth);var o=max(e.scrollHeight,e.clientHeight,n.scrollHeight,n.clientHeight);var a=-r.scrollLeft+getWindowScrollBarX(t);var s=-r.scrollTop;if(getComputedStyle(n).direction==="rtl"){a+=max(e.clientWidth,n.clientWidth)-i}return{width:i,height:o,x:a,y:s}}function getViewportRect(t,e){var r=getWindow(t);var n=getDocumentElement(t);var i=r.visualViewport;var o=n.clientWidth;var a=n.clientHeight;var s=0;var l=0;if(i){o=i.width;a=i.height;var c=isWebKit();if(!c||c&&e==="fixed"){s=i.offsetLeft;l=i.offsetTop}}return{width:o,height:a,x:s,y:l}}function getInnerBoundingClientRect(t,e){var r=getBoundingClientRect(t,true,e==="fixed");var n=r.top+t.clientTop;var i=r.left+t.clientLeft;var o=isHTMLElement(t)?getScale(t):createCoords(1);var a=t.clientWidth*o.x;var s=t.clientHeight*o.y;var l=i*o.x;var c=n*o.y;return{width:a,height:s,x:l,y:c}}function getClientRectFromClippingAncestor(t,e,r){var n;if(e==="viewport"){n=getViewportRect(t,r)}else if(e==="document"){n=getDocumentRect(getDocumentElement(t))}else if(isElement(e)){n=getInnerBoundingClientRect(e,r)}else{var i=getVisualOffsets(t);n=__assign(__assign({},e),{x:e.x-i.x,y:e.y-i.y})}return rectToClientRect(n)}function hasFixedPositionAncestor(t,e){var r=getParentNode(t);if(r===e||!isElement(r)||isLastTraversableNode(r)){return false}return getComputedStyle(r).position==="fixed"||hasFixedPositionAncestor(r,e)}function getClippingElementAncestors(t,e){var r=e.get(t);if(r){return r}var n=getOverflowAncestors(t,[],false).filter((function(t){return isElement(t)&&getNodeName(t)!=="body"}));var i=null;var o=getComputedStyle(t).position==="fixed";var a=o?getParentNode(t):t;while(isElement(a)&&!isLastTraversableNode(a)){var s=getComputedStyle(a);var l=isContainingBlock(a);if(!l&&s.position==="fixed"){i=null}var c=o?!l&&!i:!l&&s.position==="static"&&!!i&&["absolute","fixed"].includes(i.position)||isOverflowElement(a)&&!l&&hasFixedPositionAncestor(t,a);if(c){n=n.filter((function(t){return t!==a}))}else{i=s}a=getParentNode(a)}e.set(t,n);return n}function getClippingRect(t){var e=t.element,r=t.boundary,n=t.rootBoundary,i=t.strategy;var o=r==="clippingAncestors"?getClippingElementAncestors(e,this._c):[].concat(r);var a=__spreadArray(__spreadArray([],o,true),[n],false);var s=a[0];var l=a.reduce((function(t,r){var n=getClientRectFromClippingAncestor(e,r,i);t.top=max(n.top,t.top);t.right=min(n.right,t.right);t.bottom=min(n.bottom,t.bottom);t.left=max(n.left,t.left);return t}),getClientRectFromClippingAncestor(e,s,i));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function getDimensions(t){var e=getCssDimensions(t),r=e.width,n=e.height;return{width:r,height:n}}function getRectRelativeToOffsetParent(t,e,r){var n=isHTMLElement(e);var i=getDocumentElement(e);var o=r==="fixed";var a=getBoundingClientRect(t,true,o,e);var s={scrollLeft:0,scrollTop:0};var l=createCoords(0);if(n||!n&&!o){if(getNodeName(e)!=="body"||isOverflowElement(i)){s=getNodeScroll(e)}if(n){var c=getBoundingClientRect(e,true,o,e);l.x=c.x+e.clientLeft;l.y=c.y+e.clientTop}else if(i){l.x=getWindowScrollBarX(i)}}return{x:a.left+s.scrollLeft-l.x,y:a.top+s.scrollTop-l.y,width:a.width,height:a.height}}function getTrueOffsetParent(t,e){if(!isHTMLElement(t)||getComputedStyle(t).position==="fixed"){return null}if(e){return e(t)}return t.offsetParent}function getOffsetParent(t,e){var r=getWindow(t);if(!isHTMLElement(t)){return r}var n=getTrueOffsetParent(t,e);while(n&&isTableElement(n)&&getComputedStyle(n).position==="static"){n=getTrueOffsetParent(n,e)}if(n&&(getNodeName(n)==="html"||getNodeName(n)==="body"&&getComputedStyle(n).position==="static"&&!isContainingBlock(n))){return r}return n||getContainingBlock(t)||r}var getElementRects=function(t){return __awaiter(this,void 0,void 0,(function(){var e,r,n,i,o,a,s,l;var c;return __generator(this,(function(u){switch(u.label){case 0:e=t.reference,r=t.floating,n=t.strategy;i=this.getOffsetParent||getOffsetParent;o=this.getDimensions;c={};a=getRectRelativeToOffsetParent;s=[e];return[4,i(r)];case 1:c.reference=a.apply(void 0,s.concat([u.sent(),n]));l=[{x:0,y:0}];return[4,o(r)];case 2:return[2,(c.floating=__assign.apply(void 0,l.concat([u.sent()])),c)]}}))}))};function isRTL(t){return getComputedStyle(t).direction==="rtl"}var platform={convertOffsetParentRelativeRectToViewportRelativeRect:convertOffsetParentRelativeRectToViewportRelativeRect,getDocumentElement:getDocumentElement,getClippingRect:getClippingRect,getOffsetParent:getOffsetParent,getElementRects:getElementRects,getClientRects:getClientRects,getDimensions:getDimensions,getScale:getScale,isElement:isElement,isRTL:isRTL};function observeMove(t,e){var r=null;var n;var i=getDocumentElement(t);function o(){clearTimeout(n);r&&r.disconnect();r=null}function a(s,l){if(s===void 0){s=false}if(l===void 0){l=1}o();var c=t.getBoundingClientRect(),u=c.left,f=c.top,d=c.width,g=c.height;if(!s){e()}if(!d||!g){return}var v=floor(f);var m=floor(i.clientWidth-(u+d));var p=floor(i.clientHeight-(f+g));var b=floor(u);var h=-v+"px "+-m+"px "+-p+"px "+-b+"px";var w={rootMargin:h,threshold:max(0,min(1,l))||1};var y=true;function x(t){var e=t[0].intersectionRatio;if(e!==l){if(!y){return a()}if(!e){n=setTimeout((function(){a(false,1e-7)}),100)}else{a(false,e)}}y=false}try{r=new IntersectionObserver(x,__assign(__assign({},w),{root:i.ownerDocument}))}catch(t){r=new IntersectionObserver(x,w)}r.observe(t)}a(true);return o}function autoUpdate(t,e,r,n){if(n===void 0){n={}}var i=n.ancestorScroll,o=i===void 0?true:i,a=n.ancestorResize,s=a===void 0?true:a,l=n.elementResize,c=l===void 0?typeof ResizeObserver==="function":l,u=n.layoutShift,f=u===void 0?typeof IntersectionObserver==="function":u,d=n.animationFrame,g=d===void 0?false:d;var v=unwrapElement(t);var m=o||s?__spreadArray(__spreadArray([],v?getOverflowAncestors(v):[],true),getOverflowAncestors(e),true):[];m.forEach((function(t){o&&t.addEventListener("scroll",r,{passive:true});s&&t.addEventListener("resize",r)}));var p=v&&f?observeMove(v,r):null;var b=-1;var h=null;if(c){h=new ResizeObserver((function(t){var n=t[0];if(n&&n.target===v&&h){h.unobserve(e);cancelAnimationFrame(b);b=requestAnimationFrame((function(){h&&h.observe(e)}))}r()}));if(v&&!g){h.observe(v)}h.observe(e)}var w;var y=g?getBoundingClientRect(t):null;if(g){x()}function x(){var e=getBoundingClientRect(t);if(y&&(e.x!==y.x||e.y!==y.y||e.width!==y.width||e.height!==y.height)){r()}y=e;w=requestAnimationFrame(x)}r();return function(){m.forEach((function(t){o&&t.removeEventListener("scroll",r);s&&t.removeEventListener("resize",r)}));p&&p();h&&h.disconnect();h=null;if(g){cancelAnimationFrame(w)}}}var autoPlacement=autoPlacement$1;var shift=shift$1;var flip=flip$1;var arrow=arrow$1;var computePosition=function(t,e,r){var n=new Map;var i=__assign({platform:platform},r);var o=__assign(__assign({},i.platform),{_c:n});return computePosition$1(t,e,__assign(__assign({},i),{platform:o}))};var arrowSvg='<svg width="30" height="16" viewBox="0 0 30 16" xmlns="http://www.w3.org/2000/svg">\n <path d="M10.2 2.4C12.6 -0.800001 17.4 -0.800001 19.8 2.4L30 16H0L10.2 2.4Z"/>\n</svg>\n';var mdsDropdownCss='.visible{visibility:visible}.static{position:static}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.mt-\\[25vh\\]{margin-top:25vh}.flex{display:-ms-flexbox;display:flex}.hidden{display:none}.h-\\[100vh\\]{height:100vh}.h-\\[150vh\\]{height:150vh}.h-\\[2px\\]{height:2px}.w-2000{width:5rem}.w-full{width:100%}.max-w-\\[350px\\]{max-width:350px}.transform{-webkit-transform:translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));transform:translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.items-center{-ms-flex-align:center;align-items:center}.justify-start{-ms-flex-pack:start;justify-content:flex-start}.justify-end{-ms-flex-pack:end;justify-content:flex-end}.justify-center{-ms-flex-pack:center;justify-content:center}.border{border-width:1px}.bg-brand-maggioli-06{--tw-bg-opacity:1;background-color:rgb(var(--brand-maggioli-06) / var(--tw-bg-opacity))}.bg-label-amaranth-10{--tw-bg-opacity:1;background-color:rgb(var(--label-amaranth-10) / var(--tw-bg-opacity))}.bg-label-aqua-10{--tw-bg-opacity:1;background-color:rgb(var(--label-aqua-10) / var(--tw-bg-opacity))}.bg-label-blue-10{--tw-bg-opacity:1;background-color:rgb(var(--label-blue-10) / var(--tw-bg-opacity))}.bg-label-green-10{--tw-bg-opacity:1;background-color:rgb(var(--label-green-10) / var(--tw-bg-opacity))}.bg-label-lime-10{--tw-bg-opacity:1;background-color:rgb(var(--label-lime-10) / var(--tw-bg-opacity))}.bg-label-orange-10{--tw-bg-opacity:1;background-color:rgb(var(--label-orange-10) / var(--tw-bg-opacity))}.bg-label-orchid-10{--tw-bg-opacity:1;background-color:rgb(var(--label-orchid-10) / var(--tw-bg-opacity))}.bg-label-violet-10{--tw-bg-opacity:1;background-color:rgb(var(--label-violet-10) / var(--tw-bg-opacity))}.bg-label-yellow-10{--tw-bg-opacity:1;background-color:rgb(var(--label-yellow-10) / var(--tw-bg-opacity))}.bg-tone-neutral-08{--tw-bg-opacity:1;background-color:rgb(var(--tone-neutral-08) / var(--tw-bg-opacity))}.bg-tone-neutral-10{--tw-bg-opacity:1;background-color:rgb(var(--tone-neutral-10) / var(--tw-bg-opacity))}.fill-label-amaranth-04{fill:rgb(var(--label-amaranth-04))}.fill-label-aqua-04{fill:rgb(var(--label-aqua-04))}.fill-label-blue-04{fill:rgb(var(--label-blue-04))}.fill-label-green-04{fill:rgb(var(--label-green-04))}.fill-label-lime-04{fill:rgb(var(--label-lime-04))}.fill-label-orange-04{fill:rgb(var(--label-orange-04))}.fill-label-orchid-04{fill:rgb(var(--label-orchid-04))}.fill-label-violet-04{fill:rgb(var(--label-violet-04))}.fill-label-yellow-04{fill:rgb(var(--label-yellow-04))}.fill-tone-neutral-04{fill:rgb(var(--tone-neutral-04))}.px-0{padding-left:0rem;padding-right:0rem}.text-label-amaranth-04{--tw-text-opacity:1;color:rgb(var(--label-amaranth-04) / var(--tw-text-opacity))}.text-label-aqua-04{--tw-text-opacity:1;color:rgb(var(--label-aqua-04) / var(--tw-text-opacity))}.text-label-blue-04{--tw-text-opacity:1;color:rgb(var(--label-blue-04) / var(--tw-text-opacity))}.text-label-green-04{--tw-text-opacity:1;color:rgb(var(--label-green-04) / var(--tw-text-opacity))}.text-label-lime-04{--tw-text-opacity:1;color:rgb(var(--label-lime-04) / var(--tw-text-opacity))}.text-label-orange-04{--tw-text-opacity:1;color:rgb(var(--label-orange-04) / var(--tw-text-opacity))}.text-label-orchid-04{--tw-text-opacity:1;color:rgb(var(--label-orchid-04) / var(--tw-text-opacity))}.text-label-violet-04{--tw-text-opacity:1;color:rgb(var(--label-violet-04) / var(--tw-text-opacity))}.text-label-yellow-04{--tw-text-opacity:1;color:rgb(var(--label-yellow-04) / var(--tw-text-opacity))}.text-tone-neutral-02{--tw-text-opacity:1;color:rgb(var(--tone-neutral-02) / var(--tw-text-opacity))}.text-tone-neutral-04{--tw-text-opacity:1;color:rgb(var(--tone-neutral-04) / var(--tw-text-opacity))}.shadow{--tw-shadow:0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);-webkit-box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}.transition{transition-property:color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, -webkit-backdrop-filter;-webkit-transition-property:color, background-color, border-color, fill, stroke, opacity, -webkit-text-decoration-color, -webkit-box-shadow, -webkit-transform, -webkit-filter, -webkit-backdrop-filter;transition-property:color, background-color, border-color, fill, stroke, opacity, -webkit-text-decoration-color, -webkit-box-shadow, -webkit-transform, -webkit-filter, -webkit-backdrop-filter;transition-property:color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter;transition-property:color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter, -webkit-text-decoration-color, -webkit-box-shadow, -webkit-transform, -webkit-filter, -webkit-backdrop-filter;transition-property:color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter, -webkit-backdrop-filter;-webkit-transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);-webkit-transition-duration:150ms;transition-duration:150ms}.ease-out{-webkit-transition-timing-function:cubic-bezier(0, 0, 0.2, 1);transition-timing-function:cubic-bezier(0, 0, 0.2, 1)}:host{--mds-dropdown-arrow-background:var(--mds-dropdown-background);--mds-dropdown-backdrop-duration:200ms;--mds-dropdown-backdrop-z-index:var(--magma-backdrop-z-index, 3000);--mds-dropdown-background:rgb(var(--tone-neutral));--mds-dropdown-drop-shadow:drop-shadow(0 10px 8px rgb(0 0 0 / 0.04)) drop-shadow(0 4px 3px rgb(0 0 0 / 0.1)) drop-shadow(0 0 1px rgb(0 0 0 / 0.1));--mds-dropdown-duration:0.5s;--mds-dropdown-ease:cubic-bezier(0.19, 1, 0.22, 1);--mds-dropdown-transform-from:scale(0.9) translateY(-3%);--mds-dropdown-transform-to:scale(1) translate(0, 0);--mds-dropdown-z-index:var(--magma-dropdown-z-index, 4000);gap:1rem;border-radius:0.5rem;padding:1.5rem;opacity:0;background-color:var(--mds-dropdown-background);-webkit-box-sizing:border-box;box-sizing:border-box;display:grid;-webkit-filter:var(--mds-dropdown-drop-shadow);filter:var(--mds-dropdown-drop-shadow);pointer-events:none;position:fixed;-webkit-transform:var(--mds-dropdown-transform-from);transform:var(--mds-dropdown-transform-from);-webkit-transition-duration:var(--mds-dropdown-duration);transition-duration:var(--mds-dropdown-duration);-webkit-transition-property:opacity, -webkit-transform, -webkit-transform-origin;transition-property:opacity, -webkit-transform, -webkit-transform-origin;transition-property:opacity, transform, transform-origin;transition-property:opacity, transform, transform-origin, -webkit-transform, -webkit-transform-origin;-webkit-transition-timing-function:var(--mds-dropdown-ease);transition-timing-function:var(--mds-dropdown-ease);z-index:var(--mds-dropdown-z-index)}:host([visible]:not([visible="false"])){opacity:1;pointer-events:auto;-webkit-transform:var(--mds-dropdown-transform-to);transform:var(--mds-dropdown-transform-to)}:host([smooth]:not([smooth="false"])){-webkit-transition-property:bottom, left, opacity, right, top, -webkit-transform, -webkit-transform-origin;transition-property:bottom, left, opacity, right, top, -webkit-transform, -webkit-transform-origin;transition-property:bottom, left, opacity, right, top, transform, transform-origin;transition-property:bottom, left, opacity, right, top, transform, transform-origin, -webkit-transform, -webkit-transform-origin}.arrow{top:-1rem;display:-ms-flexbox;display:flex;fill:var(--mds-dropdown-arrow-background);pointer-events:none;position:fixed;-webkit-transition-duration:var(--mds-dropdown-duration);transition-duration:var(--mds-dropdown-duration);-webkit-transition-property:bottom, left, right, top, -webkit-transform, -webkit-transform-origin;transition-property:bottom, left, right, top, -webkit-transform, -webkit-transform-origin;transition-property:bottom, left, right, top, transform, transform-origin;transition-property:bottom, left, right, top, transform, transform-origin, -webkit-transform, -webkit-transform-origin}:host([arrow]:not([arrow="false"])[visible]:not([visible="false"])) .arrow{-webkit-transition-timing-function:cubic-bezier(0.165, 0.84, 0.44, 1);transition-timing-function:cubic-bezier(0.165, 0.84, 0.44, 1)}:host([arrow]:not([arrow="false"],[visible],[visible="true"])) .arrow{-webkit-transition-timing-function:cubic-bezier(0.19, 1, 0.22, 1);transition-timing-function:cubic-bezier(0.19, 1, 0.22, 1)}::slotted(*){z-index:10;position:relative}';var MdsDropdown=function(){function t(t){var e=this;registerInstance(this,t);this.visibleEvent=createEvent(this,"mdsDropdownVisible",7);this.hiddenEvent=createEvent(this,"mdsDropdownHide",7);this.changedEvent=createEvent(this,"mdsDropdownChange",7);this.backdropBackgroundVisible="rgba(var(--magma-backdrop-color, 0 0 0) / var(--magma-backdrop-opacity, 0.1))";this.backdropBackgroundHidden="rgba(var(--magma-backdrop-color, 0 0 0) / 0)";this.backdropId="mds-dropdown-backdrop";this.km=new KeyboardManager;this.handleCloseDropdown=function(t){if(!e.visible){return}if(!e.host.contains(t.target)&&t.target!==e.caller){e.handleVisibility(false)}};this.handleVisibility=function(t){e.visible=t;e.changedEvent.emit({caller:e.caller,visible:e.visible});if(e.visible){e.visibleEvent.emit({caller:e.caller,visible:true});return}e.hiddenEvent.emit({caller:e.caller,visible:false});e.updatePosition()};this.callerOnClick=function(){e.handleVisibility(!e.visible)};this.arrowInset=function(t,e){var r=t.arrow;var n={bottom:"",left:"",right:"",top:""};if(r===undefined){return{}}switch(e){case"bottom":n.left=r.x!==null?"".concat(r.x,"px"):"";n.top="100%";break;case"left":n.right="100%";n.top=r.y!==null?"".concat(r.y,"px"):"";break;case"right":n.left="100%";n.top=r.y!==null?"".concat(r.y,"px"):"";break;case"top":n.left=r.x!==null?"".concat(r.x,"px"):"";n.top="";break}return n};this.arrowTransform=function(t){var r=e.arrow&&e.visible?"scale(1)":"scale(0)";switch(t){case"bottom":r="rotate(180deg) ".concat(r," translate(0, -100%)");break;case"left":r="rotate(-90deg) ".concat(r," translate(50%, -50%)");break;case"right":r="rotate(90deg) ".concat(r," translate(-50%, -50%)");break;case"top":r="rotate(0deg) ".concat(r," translate(0, 0)");break}return{transform:r}};this.arrowTransformOrigin=function(t){switch(t){case"bottom":return{transformOrigin:"center top"};case"left":return{transformOrigin:"right center"};case"right":return{transformOrigin:"left center"};case"top":return{transformOrigin:"center bottom"};default:return{transformOrigin:"center top"}}};this.updatePosition=function(){if(!e.caller)return;var t=new Array;var r={};if(e.shiftPadding){r.padding=e.shiftPadding}if(e.autoPlacement){t.push(autoPlacement())}if(e.offset){t.push(offset(e.offset))}if(!e.autoPlacement&&e.flip){t.push(flip(r))}if(e.shift){t.push(shift(r))}if(e.arrow){t.push(arrow({element:e.arrowEl,padding:e.arrowPadding}))}computePosition(e.caller,e.host,{middleware:t,placement:e.placement,strategy:e.strategy}).then((function(t){var r=t.x,n=t.y,i=t.placement,o=t.middlewareData;Object.assign(e.host.style,{left:"".concat(r,"px"),top:"".concat(n,"px")});var a={};var s={top:"bottom",right:"left",bottom:"top",left:"right"}[i.split("-")[0]];if(s){Object.assign(a,e.arrowTransform(s));Object.assign(a,e.arrowInset(o,s));Object.assign(a,e.arrowTransformOrigin(s));Object.assign(e.arrowEl.style,a)}}))};this.updateCSSCustomProps=function(){var t=window.getComputedStyle(e.host);e.cssBackdropDuration=t.getPropertyValue("--mds-dropdown-backdrop-duration");e.cssBackdropZIndex=t.getPropertyValue("--mds-dropdown-backdrop-z-index")};this.arrow=true;this.arrowPadding=24;this.autoPlacement=false;this.backdrop=false;this.flip=false;this.target=undefined;this.offset=24;this.placement="bottom";this.shift=true;this.shiftPadding=24;this.smooth=true;this.strategy="fixed";this.visible=false;this.zIndex=undefined}t.prototype.attachBackdrop=function(){var t=this;if(!this.backdropEl){this.backdropEl=document.createElement("div");this.backdropEl.style.backgroundColor=this.backdropBackgroundHidden;this.backdropEl.className=this.backdropId;this.backdropEl.style.inset="0";this.backdropEl.style.pointerEvents="none";this.backdropEl.style.position="fixed";this.backdropEl.style.transition="background-color ".concat(this.cssBackdropDuration," ease-out");this.backdropEl.style.zIndex=this.cssBackdropZIndex}document.body.appendChild(this.backdropEl);clearTimeout(this.backdropTimer);this.backdropTimer=setTimeout((function(){t.backdropEl.style.backgroundColor=t.backdropBackgroundVisible}),1)};t.prototype.detachBackdrop=function(){var t=this;if(!this.backdropEl){return}this.backdropEl.style.backgroundColor="transparent";clearTimeout(this.backdropTimer);this.backdropTimer=setTimeout((function(){t.backdropEl.remove()}),cssDurationToMilliseconds(this.cssBackdropDuration))};t.prototype.arrowChanged=function(){this.updatePosition()};t.prototype.arrowPaddingChanged=function(){this.updatePosition()};t.prototype.autoPlacementChanged=function(){this.updatePosition()};t.prototype.backdropChanged=function(t){if(!this.visible){return}if(t){this.attachBackdrop();return}this.detachBackdrop()};t.prototype.flipChanged=function(){this.updatePosition()};t.prototype.offsetChanged=function(){this.updatePosition()};t.prototype.placementChanged=function(){this.updatePosition()};t.prototype.shiftChanged=function(){this.updatePosition()};t.prototype.shiftPaddingChanged=function(){this.updatePosition()};t.prototype.strategyChanged=function(){this.updatePosition()};t.prototype.visibleChanged=function(t){this.updatePosition();if(!this.backdrop){return}if(t){this.attachBackdrop();return}this.detachBackdrop()};t.prototype.zIndexChanged=function(t){if(t){this.host.style.setProperty("z-index",t.toString())}};t.prototype.componentWillLoad=function(){Array.from(document.getElementsByClassName(this.backdropId)).forEach((function(t){t.remove()}));this.zIndexChanged(this.zIndex)};t.prototype.setAriaAttributes=function(){var t=setAttributeIfEmpty(this.host,"id",hashValue(this.target));setAttributeIfEmpty(this.caller,"aria-haspopup","true");setAttributeIfEmpty(this.caller,"aria-controls",t);setAttributeIfEmpty(this.host,"role","menu");setAttributeIfEmpty(this.host,"aria-labelledby",this.target)};t.prototype.componentDidLoad=function(){var t=this;var e;this.updateCSSCustomProps();document.addEventListener("click",this.handleCloseDropdown);this.arrowEl=(e=this.host.shadowRoot)===null||e===void 0?void 0:e.querySelector(".arrow");var r=document.querySelector(this.target);if(!r){return}this.caller=r;this.setAriaAttributes();this.caller.addEventListener("click",this.callerOnClick.bind(this));this.km.addElement(this.host);this.km.attachEscapeBehavior((function(){return t.handleVisibility(false)}));this.backdropChanged(this.backdrop);this.updatePosition();if(!this.cleanupAutoUpdate){this.cleanupAutoUpdate=autoUpdate(this.caller,this.host,this.updatePosition)}};t.prototype.disconnectedCallback=function(){this.detachBackdrop();this.km.detachEscapeBehavior();this.cleanupAutoUpdate=function(){return}};t.prototype.render=function(){return h(Host,null,h("div",{class:"arrow",innerHTML:arrowSvg}),h("slot",null))};Object.defineProperty(t.prototype,"host",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(t,"watchers",{get:function(){return{arrow:["arrowChanged"],arrowPadding:["arrowPaddingChanged"],autoPlacement:["autoPlacementChanged"],backdrop:["backdropChanged"],flip:["flipChanged"],offset:["offsetChanged"],placement:["placementChanged"],shift:["shiftChanged"],shiftPadding:["shiftPaddingChanged"],strategy:["strategyChanged"],visible:["visibleChanged"],zIndex:["zIndexChanged"]}},enumerable:false,configurable:true});return t}();MdsDropdown.style=mdsDropdownCss;export{MdsDropdown as mds_dropdown};
var __assign=this&&this.__assign||function(){__assign=Object.assign||function(t){for(var e,r=1,n=arguments.length;r<n;r++){e=arguments[r];for(var i in e)if(Object.prototype.hasOwnProperty.call(e,i))t[i]=e[i]}return t};return __assign.apply(this,arguments)};var __awaiter=this&&this.__awaiter||function(t,e,r,n){function i(t){return t instanceof r?t:new r((function(e){e(t)}))}return new(r||(r=Promise))((function(r,o){function a(t){try{l(n.next(t))}catch(t){o(t)}}function s(t){try{l(n["throw"](t))}catch(t){o(t)}}function l(t){t.done?r(t.value):i(t.value).then(a,s)}l((n=n.apply(t,e||[])).next())}))};var __generator=this&&this.__generator||function(t,e){var r={label:0,sent:function(){if(o[0]&1)throw o[1];return o[1]},trys:[],ops:[]},n,i,o,a;return a={next:s(0),throw:s(1),return:s(2)},typeof Symbol==="function"&&(a[Symbol.iterator]=function(){return this}),a;function s(t){return function(e){return l([t,e])}}function l(s){if(n)throw new TypeError("Generator is already executing.");while(a&&(a=0,s[0]&&(r=0)),r)try{if(n=1,i&&(o=s[0]&2?i["return"]:s[0]?i["throw"]||((o=i["return"])&&o.call(i),0):i.next)&&!(o=o.call(i,s[1])).done)return o;if(i=0,o)s=[s[0]&2,o.value];switch(s[0]){case 0:case 1:o=s;break;case 4:r.label++;return{value:s[1],done:false};case 5:r.label++;i=s[1];s=[0];continue;case 7:s=r.ops.pop();r.trys.pop();continue;default:if(!(o=r.trys,o=o.length>0&&o[o.length-1])&&(s[0]===6||s[0]===2)){r=0;continue}if(s[0]===3&&(!o||s[1]>o[0]&&s[1]<o[3])){r.label=s[1];break}if(s[0]===6&&r.label<o[1]){r.label=o[1];o=s;break}if(o&&r.label<o[2]){r.label=o[2];r.ops.push(s);break}if(o[2])r.ops.pop();r.trys.pop();continue}s=e.call(t,r)}catch(t){s=[6,t];i=0}finally{n=o=0}if(s[0]&5)throw s[1];return{value:s[0]?s[1]:void 0,done:true}}};var __rest=this&&this.__rest||function(t,e){var r={};for(var n in t)if(Object.prototype.hasOwnProperty.call(t,n)&&e.indexOf(n)<0)r[n]=t[n];if(t!=null&&typeof Object.getOwnPropertySymbols==="function")for(var i=0,n=Object.getOwnPropertySymbols(t);i<n.length;i++){if(e.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(t,n[i]))r[n[i]]=t[n[i]]}return r};var __spreadArray=this&&this.__spreadArray||function(t,e,r){if(r||arguments.length===2)for(var n=0,i=e.length,o;n<i;n++){if(o||!(n in e)){if(!o)o=Array.prototype.slice.call(e,0,n);o[n]=e[n]}}return t.concat(o||Array.prototype.slice.call(e))};import{r as registerInstance,c as createEvent,h,H as Host,g as getElement}from"./index-37f9ae9f.js";var hash=function(t){var e,r;for(e=0,r=0;e<t.length;e++){r=Math.imul(31,r)+t.charCodeAt(e)|0}return r.toString()};var setAttributeIfEmpty=function(t,e,r){var n;if(t.hasAttribute(e)){return(n=t.getAttribute(e))!==null&&n!==void 0?n:""}t.setAttribute(e,r);return r};var hashValue=function(t){return"".concat(t,"-").concat(hash(t))};var KeyboardManager=function(){function t(){var t=this;this.elements=new Map;this.handleClickBehaviorDispatchEvent=function(t){if(t.code==="Enter"||t.code==="NumpadEnter"){t.target.click()}};this.handleEscapeBehaviorDispatchEvent=function(e){if(e.code==="Escape"&&t.escapeCallback){t.escapeCallback()}};this.addElement=function(e,r){if(r===void 0){r="element"}if(!e){throw Error("Passed an ".concat(e," element parameter to KeyboardManager.addElement"))}t.elements.set(r,e)};this.removeElement=function(e){if(e===void 0){e="element"}t.detachClickBehavior(e);t.elements.delete(e)};this.attachClickBehavior=function(e){if(e===void 0){e="element"}var r;(r=t.elements.get(e))===null||r===void 0?void 0:r.addEventListener("keydown",t.handleClickBehaviorDispatchEvent)};this.detachClickBehavior=function(e){if(e===void 0){e="element"}var r;(r=t.elements.get(e))===null||r===void 0?void 0:r.removeEventListener("keydown",t.handleClickBehaviorDispatchEvent)};this.attachEscapeBehavior=function(e){t.escapeCallback=e;if(window!==undefined){window.addEventListener("keydown",t.handleEscapeBehaviorDispatchEvent.bind(t))}};this.detachEscapeBehavior=function(){t.escapeCallback=function(){return};if(window!==undefined){window.removeEventListener("keydown",t.handleEscapeBehaviorDispatchEvent.bind(t))}}}return t}();var cssDurationToMilliseconds=function(t,e){if(e===void 0){e=1e3}if(t.includes("ms")){return Number(t.replace("ms",""))}if(t.includes("s")){return Number(t.replace("s",""))*1e3}return e};var sides=["top","right","bottom","left"];var alignments=["start","end"];var placements=sides.reduce((function(t,e){return t.concat(e,e+"-"+alignments[0],e+"-"+alignments[1])}),[]);var min=Math.min;var max=Math.max;var round=Math.round;var floor=Math.floor;var createCoords=function(t){return{x:t,y:t}};var oppositeSideMap={left:"right",right:"left",bottom:"top",top:"bottom"};var oppositeAlignmentMap={start:"end",end:"start"};function clamp(t,e,r){return max(t,min(e,r))}function evaluate(t,e){return typeof t==="function"?t(e):t}function getSide(t){return t.split("-")[0]}function getAlignment(t){return t.split("-")[1]}function getOppositeAxis(t){return t==="x"?"y":"x"}function getAxisLength(t){return t==="y"?"height":"width"}function getSideAxis(t){return["top","bottom"].includes(getSide(t))?"y":"x"}function getAlignmentAxis(t){return getOppositeAxis(getSideAxis(t))}function getAlignmentSides(t,e,r){if(r===void 0){r=false}var n=getAlignment(t);var i=getAlignmentAxis(t);var o=getAxisLength(i);var a=i==="x"?n===(r?"end":"start")?"right":"left":n==="start"?"bottom":"top";if(e.reference[o]>e.floating[o]){a=getOppositePlacement(a)}return[a,getOppositePlacement(a)]}function getExpandedPlacements(t){var e=getOppositePlacement(t);return[getOppositeAlignmentPlacement(t),e,getOppositeAlignmentPlacement(e)]}function getOppositeAlignmentPlacement(t){return t.replace(/start|end/g,(function(t){return oppositeAlignmentMap[t]}))}function getSideList(t,e,r){var n=["left","right"];var i=["right","left"];var o=["top","bottom"];var a=["bottom","top"];switch(t){case"top":case"bottom":if(r)return e?i:n;return e?n:i;case"left":case"right":return e?o:a;default:return[]}}function getOppositeAxisPlacements(t,e,r,n){var i=getAlignment(t);var o=getSideList(getSide(t),r==="start",n);if(i){o=o.map((function(t){return t+"-"+i}));if(e){o=o.concat(o.map(getOppositeAlignmentPlacement))}}return o}function getOppositePlacement(t){return t.replace(/left|right|bottom|top/g,(function(t){return oppositeSideMap[t]}))}function expandPaddingObject(t){return __assign({top:0,right:0,bottom:0,left:0},t)}function getPaddingObject(t){return typeof t!=="number"?expandPaddingObject(t):{top:t,right:t,bottom:t,left:t}}function rectToClientRect(t){return __assign(__assign({},t),{top:t.y,left:t.x,right:t.x+t.width,bottom:t.y+t.height})}function computeCoordsFromPlacement(t,e,r){var n=t.reference,i=t.floating;var o=getSideAxis(e);var a=getAlignmentAxis(e);var s=getAxisLength(a);var l=getSide(e);var c=o==="y";var u=n.x+n.width/2-i.width/2;var f=n.y+n.height/2-i.height/2;var d=n[s]/2-i[s]/2;var g;switch(l){case"top":g={x:u,y:n.y-i.height};break;case"bottom":g={x:u,y:n.y+n.height};break;case"right":g={x:n.x+n.width,y:f};break;case"left":g={x:n.x-i.width,y:f};break;default:g={x:n.x,y:n.y}}switch(getAlignment(e)){case"start":g[a]-=d*(r&&c?-1:1);break;case"end":g[a]+=d*(r&&c?-1:1);break}return g}var computePosition$1=function(t,e,r){return __awaiter(void 0,void 0,void 0,(function(){var n,i,o,a,s,l,c,u,f,d,g,v,m,p,b,h,w,y,x,k,_,A,C,O,E,P;var S,R;return __generator(this,(function(T){switch(T.label){case 0:n=r.placement,i=n===void 0?"bottom":n,o=r.strategy,a=o===void 0?"absolute":o,s=r.middleware,l=s===void 0?[]:s,c=r.platform;u=l.filter(Boolean);return[4,c.isRTL==null?void 0:c.isRTL(e)];case 1:f=T.sent();return[4,c.getElementRects({reference:t,floating:e,strategy:a})];case 2:d=T.sent();g=computeCoordsFromPlacement(d,i,f),v=g.x,m=g.y;p=i;b={};h=0;w=0;T.label=3;case 3:if(!(w<u.length))return[3,11];y=u[w],x=y.name,k=y.fn;return[4,k({x:v,y:m,initialPlacement:i,placement:p,strategy:a,middlewareData:b,rects:d,platform:c,elements:{reference:t,floating:e}})];case 4:_=T.sent(),A=_.x,C=_.y,O=_.data,E=_.reset;v=A!=null?A:v;m=C!=null?C:m;b=__assign(__assign({},b),(S={},S[x]=__assign(__assign({},b[x]),O),S));if(!(E&&h<=50))return[3,10];h++;if(!(typeof E==="object"))return[3,9];if(E.placement){p=E.placement}if(!E.rects)return[3,8];if(!(E.rects===true))return[3,6];return[4,c.getElementRects({reference:t,floating:e,strategy:a})];case 5:P=T.sent();return[3,7];case 6:P=E.rects;T.label=7;case 7:d=P;T.label=8;case 8:R=computeCoordsFromPlacement(d,p,f),v=R.x,m=R.y;T.label=9;case 9:w=-1;T.label=10;case 10:w++;return[3,3];case 11:return[2,{x:v,y:m,placement:p,strategy:a,middlewareData:b}]}}))}))};function detectOverflow(t,e){return __awaiter(this,void 0,void 0,(function(){var r,n,i,o,a,s,l,c,u,f,d,g,v,m,p,b,h,w,y,x,k,_,A,C,O,E,P,S,R,T,N,M,L,D;var j;return __generator(this,(function(z){switch(z.label){case 0:if(e===void 0){e={}}n=t.x,i=t.y,o=t.platform,a=t.rects,s=t.elements,l=t.strategy;c=evaluate(e,t),u=c.boundary,f=u===void 0?"clippingAncestors":u,d=c.rootBoundary,g=d===void 0?"viewport":d,v=c.elementContext,m=v===void 0?"floating":v,p=c.altBoundary,b=p===void 0?false:p,h=c.padding,w=h===void 0?0:h;y=getPaddingObject(w);x=m==="floating"?"reference":"floating";k=s[b?x:m];A=rectToClientRect;O=(C=o).getClippingRect;j={};return[4,o.isElement==null?void 0:o.isElement(k)];case 1:if(!((r=z.sent())!=null?r:true))return[3,2];E=k;return[3,5];case 2:P=k.contextElement;if(P)return[3,4];return[4,o.getDocumentElement==null?void 0:o.getDocumentElement(s.floating)];case 3:P=z.sent();z.label=4;case 4:E=P;z.label=5;case 5:return[4,O.apply(C,[(j.element=E,j.boundary=f,j.rootBoundary=g,j.strategy=l,j)])];case 6:_=A.apply(void 0,[z.sent()]);S=m==="floating"?__assign(__assign({},a.floating),{x:n,y:i}):a.reference;return[4,o.getOffsetParent==null?void 0:o.getOffsetParent(s.floating)];case 7:R=z.sent();return[4,o.isElement==null?void 0:o.isElement(R)];case 8:if(!z.sent())return[3,10];return[4,o.getScale==null?void 0:o.getScale(R)];case 9:N=z.sent()||{x:1,y:1};return[3,11];case 10:N={x:1,y:1};z.label=11;case 11:T=N;L=rectToClientRect;if(!o.convertOffsetParentRelativeRectToViewportRelativeRect)return[3,13];return[4,o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:S,offsetParent:R,strategy:l})];case 12:D=z.sent();return[3,14];case 13:D=S;z.label=14;case 14:M=L.apply(void 0,[D]);return[2,{top:(_.top-M.top+y.top)/T.y,bottom:(M.bottom-_.bottom+y.bottom)/T.y,left:(_.left-M.left+y.left)/T.x,right:(M.right-_.right+y.right)/T.x}]}}))}))}var arrow$1=function(t){return{name:"arrow",options:t,fn:function(e){return __awaiter(this,void 0,void 0,(function(){var r,n,i,o,a,s,l,c,u,f,d,g,v,m,p,b,h,w,y,x,k,_,A,C,O,E,P,S,R,T,N,M,L,D,j;var z,W;return __generator(this,(function(B){switch(B.label){case 0:r=e.x,n=e.y,i=e.placement,o=e.rects,a=e.platform,s=e.elements,l=e.middlewareData;c=evaluate(t,e)||{},u=c.element,f=c.padding,d=f===void 0?0:f;if(u==null){return[2,{}]}g=getPaddingObject(d);v={x:r,y:n};m=getAlignmentAxis(i);p=getAxisLength(m);return[4,a.getDimensions(u)];case 1:b=B.sent();h=m==="y";w=h?"top":"left";y=h?"bottom":"right";x=h?"clientHeight":"clientWidth";k=o.reference[p]+o.reference[m]-v[m]-o.floating[p];_=v[m]-o.reference[m];return[4,a.getOffsetParent==null?void 0:a.getOffsetParent(u)];case 2:A=B.sent();C=A?A[x]:0;O=!C;if(O)return[3,4];return[4,a.isElement==null?void 0:a.isElement(A)];case 3:O=!B.sent();B.label=4;case 4:if(O){C=s.floating[x]||o.floating[p]}E=k/2-_/2;P=C/2-b[p]/2-1;S=min(g[w],P);R=min(g[y],P);T=S;N=C-b[p]-R;M=C/2-b[p]/2+E;L=clamp(T,M,N);D=!l.arrow&&getAlignment(i)!=null&&M!==L&&o.reference[p]/2-(M<T?S:R)-b[p]/2<0;j=D?M<T?M-T:M-N:0;return[2,(z={},z[m]=v[m]+j,z.data=__assign((W={},W[m]=L,W.centerOffset=M-L-j,W),D&&{alignmentOffset:j}),z.reset=D,z)]}}))}))}}};function getPlacementList(t,e,r){var n=t?__spreadArray(__spreadArray([],r.filter((function(e){return getAlignment(e)===t})),true),r.filter((function(e){return getAlignment(e)!==t})),true):r.filter((function(t){return getSide(t)===t}));return n.filter((function(r){if(t){return getAlignment(r)===t||(e?getOppositeAlignmentPlacement(r)!==r:false)}return true}))}var autoPlacement$1=function(t){if(t===void 0){t={}}return{name:"autoPlacement",options:t,fn:function(e){return __awaiter(this,void 0,void 0,(function(){var r,n,i,o,a,s,l,c,u,f,d,g,v,m,p,b,h,w,y,x,k,_,A,C,O,E,P,S,R,T;return __generator(this,(function(N){switch(N.label){case 0:o=e.rects,a=e.middlewareData,s=e.placement,l=e.platform,c=e.elements;u=evaluate(t,e),f=u.crossAxis,d=f===void 0?false:f,g=u.alignment,v=u.allowedPlacements,m=v===void 0?placements:v,p=u.autoAlignment,b=p===void 0?true:p,h=__rest(u,["crossAxis","alignment","allowedPlacements","autoAlignment"]);w=g!==undefined||m===placements?getPlacementList(g||null,b,m):m;return[4,detectOverflow(e,h)];case 1:y=N.sent();x=((r=a.autoPlacement)==null?void 0:r.index)||0;k=w[x];if(k==null){return[2,{}]}A=getAlignmentSides;C=[k,o];return[4,l.isRTL==null?void 0:l.isRTL(c.floating)];case 2:_=A.apply(void 0,C.concat([N.sent()]));if(s!==k){return[2,{reset:{placement:w[0]}}]}O=[y[getSide(k)],y[_[0]],y[_[1]]];E=__spreadArray(__spreadArray([],((n=a.autoPlacement)==null?void 0:n.overflows)||[],true),[{placement:k,overflows:O}],false);P=w[x+1];if(P){return[2,{data:{index:x+1,overflows:E},reset:{placement:P}}]}S=E.map((function(t){var e=getAlignment(t.placement);return[t.placement,e&&d?t.overflows.slice(0,2).reduce((function(t,e){return t+e}),0):t.overflows[0],t.overflows]})).sort((function(t,e){return t[1]-e[1]}));R=S.filter((function(t){return t[2].slice(0,getAlignment(t[0])?2:3).every((function(t){return t<=0}))}));T=((i=R[0])==null?void 0:i[0])||S[0][0];if(T!==s){return[2,{data:{index:x+1,overflows:E},reset:{placement:T}}]}return[2,{}]}}))}))}}};var flip$1=function(t){if(t===void 0){t={}}return{name:"flip",options:t,fn:function(e){return __awaiter(this,void 0,void 0,(function(){var r,n,i,o,a,s,l,c,u,f,d,g,v,m,p,b,h,w,y,x,k,_,A,C,O,E,P,S,R,T,N,M,L,D,j,z,W;return __generator(this,(function(B){switch(B.label){case 0:i=e.placement,o=e.middlewareData,a=e.rects,s=e.initialPlacement,l=e.platform,c=e.elements;u=evaluate(t,e),f=u.mainAxis,d=f===void 0?true:f,g=u.crossAxis,v=g===void 0?true:g,m=u.fallbackPlacements,p=u.fallbackStrategy,b=p===void 0?"bestFit":p,h=u.fallbackAxisSideDirection,w=h===void 0?"none":h,y=u.flipAlignment,x=y===void 0?true:y,k=__rest(u,["mainAxis","crossAxis","fallbackPlacements","fallbackStrategy","fallbackAxisSideDirection","flipAlignment"]);if((r=o.arrow)!=null&&r.alignmentOffset){return[2,{}]}_=getSide(i);A=getSide(s)===s;return[4,l.isRTL==null?void 0:l.isRTL(c.floating)];case 1:C=B.sent();O=m||(A||!x?[getOppositePlacement(s)]:getExpandedPlacements(s));if(!m&&w!=="none"){O.push.apply(O,getOppositeAxisPlacements(s,x,w,C))}E=__spreadArray([s],O,true);return[4,detectOverflow(e,k)];case 2:P=B.sent();S=[];R=((n=o.flip)==null?void 0:n.overflows)||[];if(d){S.push(P[_])}if(v){T=getAlignmentSides(i,a,C);S.push(P[T[0]],P[T[1]])}R=__spreadArray(__spreadArray([],R,true),[{placement:i,overflows:S}],false);if(!S.every((function(t){return t<=0}))){L=(((N=o.flip)==null?void 0:N.index)||0)+1;D=E[L];if(D){return[2,{data:{index:L,overflows:R},reset:{placement:D}}]}j=(M=R.filter((function(t){return t.overflows[0]<=0})).sort((function(t,e){return t.overflows[1]-e.overflows[1]}))[0])==null?void 0:M.placement;if(!j){switch(b){case"bestFit":{W=(z=R.map((function(t){return[t.placement,t.overflows.filter((function(t){return t>0})).reduce((function(t,e){return t+e}),0)]})).sort((function(t,e){return t[1]-e[1]}))[0])==null?void 0:z[0];if(W){j=W}break}case"initialPlacement":j=s;break}}if(i!==j){return[2,{reset:{placement:j}}]}}return[2,{}]}}))}))}}};function convertValueToCoords(t,e){return __awaiter(this,void 0,void 0,(function(){var r,n,i,o,a,s,l,c,u,f,d,g,v,m;return __generator(this,(function(p){switch(p.label){case 0:r=t.placement,n=t.platform,i=t.elements;return[4,n.isRTL==null?void 0:n.isRTL(i.floating)];case 1:o=p.sent();a=getSide(r);s=getAlignment(r);l=getSideAxis(r)==="y";c=["left","top"].includes(a)?-1:1;u=o&&l?-1:1;f=evaluate(e,t);d=typeof f==="number"?{mainAxis:f,crossAxis:0,alignmentAxis:null}:__assign({mainAxis:0,crossAxis:0,alignmentAxis:null},f),g=d.mainAxis,v=d.crossAxis,m=d.alignmentAxis;if(s&&typeof m==="number"){v=s==="end"?m*-1:m}return[2,l?{x:v*u,y:g*c}:{x:g*c,y:v*u}]}}))}))}var offset=function(t){if(t===void 0){t=0}return{name:"offset",options:t,fn:function(e){return __awaiter(this,void 0,void 0,(function(){var r,n,i,o,a,s,l;return __generator(this,(function(c){switch(c.label){case 0:i=e.x,o=e.y,a=e.placement,s=e.middlewareData;return[4,convertValueToCoords(e,t)];case 1:l=c.sent();if(a===((r=s.offset)==null?void 0:r.placement)&&(n=s.arrow)!=null&&n.alignmentOffset){return[2,{}]}return[2,{x:i+l.x,y:o+l.y,data:__assign(__assign({},l),{placement:a})}]}}))}))}}};var shift$1=function(t){if(t===void 0){t={}}return{name:"shift",options:t,fn:function(e){return __awaiter(this,void 0,void 0,(function(){var r,n,i,o,a,s,l,c,u,f,d,g,v,m,p,b,h,w,y,x,k,w,y,_,A,C;var O;return __generator(this,(function(E){switch(E.label){case 0:r=e.x,n=e.y,i=e.placement;o=evaluate(t,e),a=o.mainAxis,s=a===void 0?true:a,l=o.crossAxis,c=l===void 0?false:l,u=o.limiter,f=u===void 0?{fn:function(t){var e=t.x,r=t.y;return{x:e,y:r}}}:u,d=__rest(o,["mainAxis","crossAxis","limiter"]);g={x:r,y:n};return[4,detectOverflow(e,d)];case 1:v=E.sent();m=getSideAxis(getSide(i));p=getOppositeAxis(m);b=g[p];h=g[m];if(s){w=p==="y"?"top":"left";y=p==="y"?"bottom":"right";x=b+v[w];k=b-v[y];b=clamp(x,b,k)}if(c){w=m==="y"?"top":"left";y=m==="y"?"bottom":"right";_=h+v[w];A=h-v[y];h=clamp(_,h,A)}C=f.fn(__assign(__assign({},e),(O={},O[p]=b,O[m]=h,O)));return[2,__assign(__assign({},C),{data:{x:C.x-r,y:C.y-n}})]}}))}))}}};function getNodeName(t){if(isNode(t)){return(t.nodeName||"").toLowerCase()}return"#document"}function getWindow(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function getDocumentElement(t){var e;return(e=(isNode(t)?t.ownerDocument:t.document)||window.document)==null?void 0:e.documentElement}function isNode(t){return t instanceof Node||t instanceof getWindow(t).Node}function isElement(t){return t instanceof Element||t instanceof getWindow(t).Element}function isHTMLElement(t){return t instanceof HTMLElement||t instanceof getWindow(t).HTMLElement}function isShadowRoot(t){if(typeof ShadowRoot==="undefined"){return false}return t instanceof ShadowRoot||t instanceof getWindow(t).ShadowRoot}function isOverflowElement(t){var e=getComputedStyle(t),r=e.overflow,n=e.overflowX,i=e.overflowY,o=e.display;return/auto|scroll|overlay|hidden|clip/.test(r+i+n)&&!["inline","contents"].includes(o)}function isTableElement(t){return["table","td","th"].includes(getNodeName(t))}function isContainingBlock(t){var e=isWebKit();var r=getComputedStyle(t);return r.transform!=="none"||r.perspective!=="none"||(r.containerType?r.containerType!=="normal":false)||!e&&(r.backdropFilter?r.backdropFilter!=="none":false)||!e&&(r.filter?r.filter!=="none":false)||["transform","perspective","filter"].some((function(t){return(r.willChange||"").includes(t)}))||["paint","layout","strict","content"].some((function(t){return(r.contain||"").includes(t)}))}function getContainingBlock(t){var e=getParentNode(t);while(isHTMLElement(e)&&!isLastTraversableNode(e)){if(isContainingBlock(e)){return e}else{e=getParentNode(e)}}return null}function isWebKit(){if(typeof CSS==="undefined"||!CSS.supports)return false;return CSS.supports("-webkit-backdrop-filter","none")}function isLastTraversableNode(t){return["html","body","#document"].includes(getNodeName(t))}function getComputedStyle(t){return getWindow(t).getComputedStyle(t)}function getNodeScroll(t){if(isElement(t)){return{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}}return{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function getParentNode(t){if(getNodeName(t)==="html"){return t}var e=t.assignedSlot||t.parentNode||isShadowRoot(t)&&t.host||getDocumentElement(t);return isShadowRoot(e)?e.host:e}function getNearestOverflowAncestor(t){var e=getParentNode(t);if(isLastTraversableNode(e)){return t.ownerDocument?t.ownerDocument.body:t.body}if(isHTMLElement(e)&&isOverflowElement(e)){return e}return getNearestOverflowAncestor(e)}function getOverflowAncestors(t,e,r){var n;if(e===void 0){e=[]}if(r===void 0){r=true}var i=getNearestOverflowAncestor(t);var o=i===((n=t.ownerDocument)==null?void 0:n.body);var a=getWindow(i);if(o){return e.concat(a,a.visualViewport||[],isOverflowElement(i)?i:[],a.frameElement&&r?getOverflowAncestors(a.frameElement):[])}return e.concat(i,getOverflowAncestors(i,[],r))}function getCssDimensions(t){var e=getComputedStyle(t);var r=parseFloat(e.width)||0;var n=parseFloat(e.height)||0;var i=isHTMLElement(t);var o=i?t.offsetWidth:r;var a=i?t.offsetHeight:n;var s=round(r)!==o||round(n)!==a;if(s){r=o;n=a}return{width:r,height:n,$:s}}function unwrapElement(t){return!isElement(t)?t.contextElement:t}function getScale(t){var e=unwrapElement(t);if(!isHTMLElement(e)){return createCoords(1)}var r=e.getBoundingClientRect();var n=getCssDimensions(e),i=n.width,o=n.height,a=n.$;var s=(a?round(r.width):r.width)/i;var l=(a?round(r.height):r.height)/o;if(!s||!Number.isFinite(s)){s=1}if(!l||!Number.isFinite(l)){l=1}return{x:s,y:l}}var noOffsets=createCoords(0);function getVisualOffsets(t){var e=getWindow(t);if(!isWebKit()||!e.visualViewport){return noOffsets}return{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function shouldAddVisualOffsets(t,e,r){if(e===void 0){e=false}if(!r||e&&r!==getWindow(t)){return false}return e}function getBoundingClientRect(t,e,r,n){if(e===void 0){e=false}if(r===void 0){r=false}var i=t.getBoundingClientRect();var o=unwrapElement(t);var a=createCoords(1);if(e){if(n){if(isElement(n)){a=getScale(n)}}else{a=getScale(t)}}var s=shouldAddVisualOffsets(o,r,n)?getVisualOffsets(o):createCoords(0);var l=(i.left+s.x)/a.x;var c=(i.top+s.y)/a.y;var u=i.width/a.x;var f=i.height/a.y;if(o){var d=getWindow(o);var g=n&&isElement(n)?getWindow(n):n;var v=d.frameElement;while(v&&n&&g!==d){var m=getScale(v);var p=v.getBoundingClientRect();var b=getComputedStyle(v);var h=p.left+(v.clientLeft+parseFloat(b.paddingLeft))*m.x;var w=p.top+(v.clientTop+parseFloat(b.paddingTop))*m.y;l*=m.x;c*=m.y;u*=m.x;f*=m.y;l+=h;c+=w;v=getWindow(v).frameElement}}return rectToClientRect({width:u,height:f,x:l,y:c})}function convertOffsetParentRelativeRectToViewportRelativeRect(t){var e=t.rect,r=t.offsetParent,n=t.strategy;var i=isHTMLElement(r);var o=getDocumentElement(r);if(r===o){return e}var a={scrollLeft:0,scrollTop:0};var s=createCoords(1);var l=createCoords(0);if(i||!i&&n!=="fixed"){if(getNodeName(r)!=="body"||isOverflowElement(o)){a=getNodeScroll(r)}if(isHTMLElement(r)){var c=getBoundingClientRect(r);s=getScale(r);l.x=c.x+r.clientLeft;l.y=c.y+r.clientTop}}return{width:e.width*s.x,height:e.height*s.y,x:e.x*s.x-a.scrollLeft*s.x+l.x,y:e.y*s.y-a.scrollTop*s.y+l.y}}function getClientRects(t){return Array.from(t.getClientRects())}function getWindowScrollBarX(t){return getBoundingClientRect(getDocumentElement(t)).left+getNodeScroll(t).scrollLeft}function getDocumentRect(t){var e=getDocumentElement(t);var r=getNodeScroll(t);var n=t.ownerDocument.body;var i=max(e.scrollWidth,e.clientWidth,n.scrollWidth,n.clientWidth);var o=max(e.scrollHeight,e.clientHeight,n.scrollHeight,n.clientHeight);var a=-r.scrollLeft+getWindowScrollBarX(t);var s=-r.scrollTop;if(getComputedStyle(n).direction==="rtl"){a+=max(e.clientWidth,n.clientWidth)-i}return{width:i,height:o,x:a,y:s}}function getViewportRect(t,e){var r=getWindow(t);var n=getDocumentElement(t);var i=r.visualViewport;var o=n.clientWidth;var a=n.clientHeight;var s=0;var l=0;if(i){o=i.width;a=i.height;var c=isWebKit();if(!c||c&&e==="fixed"){s=i.offsetLeft;l=i.offsetTop}}return{width:o,height:a,x:s,y:l}}function getInnerBoundingClientRect(t,e){var r=getBoundingClientRect(t,true,e==="fixed");var n=r.top+t.clientTop;var i=r.left+t.clientLeft;var o=isHTMLElement(t)?getScale(t):createCoords(1);var a=t.clientWidth*o.x;var s=t.clientHeight*o.y;var l=i*o.x;var c=n*o.y;return{width:a,height:s,x:l,y:c}}function getClientRectFromClippingAncestor(t,e,r){var n;if(e==="viewport"){n=getViewportRect(t,r)}else if(e==="document"){n=getDocumentRect(getDocumentElement(t))}else if(isElement(e)){n=getInnerBoundingClientRect(e,r)}else{var i=getVisualOffsets(t);n=__assign(__assign({},e),{x:e.x-i.x,y:e.y-i.y})}return rectToClientRect(n)}function hasFixedPositionAncestor(t,e){var r=getParentNode(t);if(r===e||!isElement(r)||isLastTraversableNode(r)){return false}return getComputedStyle(r).position==="fixed"||hasFixedPositionAncestor(r,e)}function getClippingElementAncestors(t,e){var r=e.get(t);if(r){return r}var n=getOverflowAncestors(t,[],false).filter((function(t){return isElement(t)&&getNodeName(t)!=="body"}));var i=null;var o=getComputedStyle(t).position==="fixed";var a=o?getParentNode(t):t;while(isElement(a)&&!isLastTraversableNode(a)){var s=getComputedStyle(a);var l=isContainingBlock(a);if(!l&&s.position==="fixed"){i=null}var c=o?!l&&!i:!l&&s.position==="static"&&!!i&&["absolute","fixed"].includes(i.position)||isOverflowElement(a)&&!l&&hasFixedPositionAncestor(t,a);if(c){n=n.filter((function(t){return t!==a}))}else{i=s}a=getParentNode(a)}e.set(t,n);return n}function getClippingRect(t){var e=t.element,r=t.boundary,n=t.rootBoundary,i=t.strategy;var o=r==="clippingAncestors"?getClippingElementAncestors(e,this._c):[].concat(r);var a=__spreadArray(__spreadArray([],o,true),[n],false);var s=a[0];var l=a.reduce((function(t,r){var n=getClientRectFromClippingAncestor(e,r,i);t.top=max(n.top,t.top);t.right=min(n.right,t.right);t.bottom=min(n.bottom,t.bottom);t.left=max(n.left,t.left);return t}),getClientRectFromClippingAncestor(e,s,i));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function getDimensions(t){var e=getCssDimensions(t),r=e.width,n=e.height;return{width:r,height:n}}function getRectRelativeToOffsetParent(t,e,r){var n=isHTMLElement(e);var i=getDocumentElement(e);var o=r==="fixed";var a=getBoundingClientRect(t,true,o,e);var s={scrollLeft:0,scrollTop:0};var l=createCoords(0);if(n||!n&&!o){if(getNodeName(e)!=="body"||isOverflowElement(i)){s=getNodeScroll(e)}if(n){var c=getBoundingClientRect(e,true,o,e);l.x=c.x+e.clientLeft;l.y=c.y+e.clientTop}else if(i){l.x=getWindowScrollBarX(i)}}return{x:a.left+s.scrollLeft-l.x,y:a.top+s.scrollTop-l.y,width:a.width,height:a.height}}function getTrueOffsetParent(t,e){if(!isHTMLElement(t)||getComputedStyle(t).position==="fixed"){return null}if(e){return e(t)}return t.offsetParent}function getOffsetParent(t,e){var r=getWindow(t);if(!isHTMLElement(t)){return r}var n=getTrueOffsetParent(t,e);while(n&&isTableElement(n)&&getComputedStyle(n).position==="static"){n=getTrueOffsetParent(n,e)}if(n&&(getNodeName(n)==="html"||getNodeName(n)==="body"&&getComputedStyle(n).position==="static"&&!isContainingBlock(n))){return r}return n||getContainingBlock(t)||r}var getElementRects=function(t){return __awaiter(this,void 0,void 0,(function(){var e,r,n,i,o,a,s,l;var c;return __generator(this,(function(u){switch(u.label){case 0:e=t.reference,r=t.floating,n=t.strategy;i=this.getOffsetParent||getOffsetParent;o=this.getDimensions;c={};a=getRectRelativeToOffsetParent;s=[e];return[4,i(r)];case 1:c.reference=a.apply(void 0,s.concat([u.sent(),n]));l=[{x:0,y:0}];return[4,o(r)];case 2:return[2,(c.floating=__assign.apply(void 0,l.concat([u.sent()])),c)]}}))}))};function isRTL(t){return getComputedStyle(t).direction==="rtl"}var platform={convertOffsetParentRelativeRectToViewportRelativeRect:convertOffsetParentRelativeRectToViewportRelativeRect,getDocumentElement:getDocumentElement,getClippingRect:getClippingRect,getOffsetParent:getOffsetParent,getElementRects:getElementRects,getClientRects:getClientRects,getDimensions:getDimensions,getScale:getScale,isElement:isElement,isRTL:isRTL};function observeMove(t,e){var r=null;var n;var i=getDocumentElement(t);function o(){clearTimeout(n);r&&r.disconnect();r=null}function a(s,l){if(s===void 0){s=false}if(l===void 0){l=1}o();var c=t.getBoundingClientRect(),u=c.left,f=c.top,d=c.width,g=c.height;if(!s){e()}if(!d||!g){return}var v=floor(f);var m=floor(i.clientWidth-(u+d));var p=floor(i.clientHeight-(f+g));var b=floor(u);var h=-v+"px "+-m+"px "+-p+"px "+-b+"px";var w={rootMargin:h,threshold:max(0,min(1,l))||1};var y=true;function x(t){var e=t[0].intersectionRatio;if(e!==l){if(!y){return a()}if(!e){n=setTimeout((function(){a(false,1e-7)}),100)}else{a(false,e)}}y=false}try{r=new IntersectionObserver(x,__assign(__assign({},w),{root:i.ownerDocument}))}catch(t){r=new IntersectionObserver(x,w)}r.observe(t)}a(true);return o}function autoUpdate(t,e,r,n){if(n===void 0){n={}}var i=n.ancestorScroll,o=i===void 0?true:i,a=n.ancestorResize,s=a===void 0?true:a,l=n.elementResize,c=l===void 0?typeof ResizeObserver==="function":l,u=n.layoutShift,f=u===void 0?typeof IntersectionObserver==="function":u,d=n.animationFrame,g=d===void 0?false:d;var v=unwrapElement(t);var m=o||s?__spreadArray(__spreadArray([],v?getOverflowAncestors(v):[],true),getOverflowAncestors(e),true):[];m.forEach((function(t){o&&t.addEventListener("scroll",r,{passive:true});s&&t.addEventListener("resize",r)}));var p=v&&f?observeMove(v,r):null;var b=-1;var h=null;if(c){h=new ResizeObserver((function(t){var n=t[0];if(n&&n.target===v&&h){h.unobserve(e);cancelAnimationFrame(b);b=requestAnimationFrame((function(){h&&h.observe(e)}))}r()}));if(v&&!g){h.observe(v)}h.observe(e)}var w;var y=g?getBoundingClientRect(t):null;if(g){x()}function x(){var e=getBoundingClientRect(t);if(y&&(e.x!==y.x||e.y!==y.y||e.width!==y.width||e.height!==y.height)){r()}y=e;w=requestAnimationFrame(x)}r();return function(){m.forEach((function(t){o&&t.removeEventListener("scroll",r);s&&t.removeEventListener("resize",r)}));p&&p();h&&h.disconnect();h=null;if(g){cancelAnimationFrame(w)}}}var autoPlacement=autoPlacement$1;var shift=shift$1;var flip=flip$1;var arrow=arrow$1;var computePosition=function(t,e,r){var n=new Map;var i=__assign({platform:platform},r);var o=__assign(__assign({},i.platform),{_c:n});return computePosition$1(t,e,__assign(__assign({},i),{platform:o}))};var arrowSvg='<svg width="30" height="16" viewBox="0 0 30 16" xmlns="http://www.w3.org/2000/svg">\n <path d="M10.2 2.4C12.6 -0.800001 17.4 -0.800001 19.8 2.4L30 16H0L10.2 2.4Z"/>\n</svg>\n';var mdsDropdownCss='.visible{visibility:visible}.static{position:static}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.mt-\\[25vh\\]{margin-top:25vh}.flex{display:-ms-flexbox;display:flex}.hidden{display:none}.h-\\[100vh\\]{height:100vh}.h-\\[150vh\\]{height:150vh}.h-\\[2px\\]{height:2px}.w-2000{width:5rem}.w-full{width:100%}.max-w-\\[350px\\]{max-width:350px}.transform{-webkit-transform:translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y));transform:translate(var(--tw-translate-x), var(--tw-translate-y)) rotate(var(--tw-rotate)) skewX(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.items-center{-ms-flex-align:center;align-items:center}.justify-start{-ms-flex-pack:start;justify-content:flex-start}.justify-end{-ms-flex-pack:end;justify-content:flex-end}.justify-center{-ms-flex-pack:center;justify-content:center}.border{border-width:1px}.bg-brand-maggioli-06{--tw-bg-opacity:1;background-color:rgb(var(--brand-maggioli-06) / var(--tw-bg-opacity))}.bg-label-amaranth-10{--tw-bg-opacity:1;background-color:rgb(var(--label-amaranth-10) / var(--tw-bg-opacity))}.bg-label-aqua-10{--tw-bg-opacity:1;background-color:rgb(var(--label-aqua-10) / var(--tw-bg-opacity))}.bg-label-blue-10{--tw-bg-opacity:1;background-color:rgb(var(--label-blue-10) / var(--tw-bg-opacity))}.bg-label-green-10{--tw-bg-opacity:1;background-color:rgb(var(--label-green-10) / var(--tw-bg-opacity))}.bg-label-lime-10{--tw-bg-opacity:1;background-color:rgb(var(--label-lime-10) / var(--tw-bg-opacity))}.bg-label-orange-10{--tw-bg-opacity:1;background-color:rgb(var(--label-orange-10) / var(--tw-bg-opacity))}.bg-label-orchid-10{--tw-bg-opacity:1;background-color:rgb(var(--label-orchid-10) / var(--tw-bg-opacity))}.bg-label-violet-10{--tw-bg-opacity:1;background-color:rgb(var(--label-violet-10) / var(--tw-bg-opacity))}.bg-label-yellow-10{--tw-bg-opacity:1;background-color:rgb(var(--label-yellow-10) / var(--tw-bg-opacity))}.bg-tone-neutral-08{--tw-bg-opacity:1;background-color:rgb(var(--tone-neutral-08) / var(--tw-bg-opacity))}.bg-tone-neutral-10{--tw-bg-opacity:1;background-color:rgb(var(--tone-neutral-10) / var(--tw-bg-opacity))}.fill-label-amaranth-04{fill:rgb(var(--label-amaranth-04))}.fill-label-aqua-04{fill:rgb(var(--label-aqua-04))}.fill-label-blue-04{fill:rgb(var(--label-blue-04))}.fill-label-green-04{fill:rgb(var(--label-green-04))}.fill-label-lime-04{fill:rgb(var(--label-lime-04))}.fill-label-orange-04{fill:rgb(var(--label-orange-04))}.fill-label-orchid-04{fill:rgb(var(--label-orchid-04))}.fill-label-violet-04{fill:rgb(var(--label-violet-04))}.fill-label-yellow-04{fill:rgb(var(--label-yellow-04))}.fill-tone-neutral-04{fill:rgb(var(--tone-neutral-04))}.px-0{padding-left:0rem;padding-right:0rem}.text-label-amaranth-04{--tw-text-opacity:1;color:rgb(var(--label-amaranth-04) / var(--tw-text-opacity))}.text-label-aqua-04{--tw-text-opacity:1;color:rgb(var(--label-aqua-04) / var(--tw-text-opacity))}.text-label-blue-04{--tw-text-opacity:1;color:rgb(var(--label-blue-04) / var(--tw-text-opacity))}.text-label-green-04{--tw-text-opacity:1;color:rgb(var(--label-green-04) / var(--tw-text-opacity))}.text-label-lime-04{--tw-text-opacity:1;color:rgb(var(--label-lime-04) / var(--tw-text-opacity))}.text-label-orange-04{--tw-text-opacity:1;color:rgb(var(--label-orange-04) / var(--tw-text-opacity))}.text-label-orchid-04{--tw-text-opacity:1;color:rgb(var(--label-orchid-04) / var(--tw-text-opacity))}.text-label-violet-04{--tw-text-opacity:1;color:rgb(var(--label-violet-04) / var(--tw-text-opacity))}.text-label-yellow-04{--tw-text-opacity:1;color:rgb(var(--label-yellow-04) / var(--tw-text-opacity))}.text-tone-neutral-02{--tw-text-opacity:1;color:rgb(var(--tone-neutral-02) / var(--tw-text-opacity))}.text-tone-neutral-04{--tw-text-opacity:1;color:rgb(var(--tone-neutral-04) / var(--tw-text-opacity))}.shadow{--tw-shadow:0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);--tw-shadow-colored:0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);-webkit-box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000), var(--tw-ring-shadow, 0 0 #0000), var(--tw-shadow)}.transition{transition-property:color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, -webkit-backdrop-filter;-webkit-transition-property:color, background-color, border-color, fill, stroke, opacity, -webkit-text-decoration-color, -webkit-box-shadow, -webkit-transform, -webkit-filter, -webkit-backdrop-filter;transition-property:color, background-color, border-color, fill, stroke, opacity, -webkit-text-decoration-color, -webkit-box-shadow, -webkit-transform, -webkit-filter, -webkit-backdrop-filter;transition-property:color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter;transition-property:color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter, -webkit-text-decoration-color, -webkit-box-shadow, -webkit-transform, -webkit-filter, -webkit-backdrop-filter;transition-property:color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter, -webkit-backdrop-filter;-webkit-transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);transition-timing-function:cubic-bezier(0.4, 0, 0.2, 1);-webkit-transition-duration:150ms;transition-duration:150ms}.ease-out{-webkit-transition-timing-function:cubic-bezier(0, 0, 0.2, 1);transition-timing-function:cubic-bezier(0, 0, 0.2, 1)}:host{--mds-dropdown-arrow-background:var(--mds-dropdown-background);--mds-dropdown-backdrop-duration:200ms;--mds-dropdown-backdrop-z-index:var(--magma-backdrop-z-index, 3000);--mds-dropdown-background:rgb(var(--tone-neutral));--mds-dropdown-mouseover-delay:0.5s;--mds-dropdown-drop-shadow:drop-shadow(0 10px 8px rgb(0 0 0 / 0.04)) drop-shadow(0 4px 3px rgb(0 0 0 / 0.1)) drop-shadow(0 0 1px rgb(0 0 0 / 0.1));--mds-dropdown-duration:0.5s;--mds-dropdown-ease:cubic-bezier(0.19, 1, 0.22, 1);--mds-dropdown-transform-from:scale(0.9) translateY(-3%);--mds-dropdown-transform-to:scale(1) translate(0, 0);--mds-dropdown-z-index:var(--magma-dropdown-z-index, 4000);gap:1rem;border-radius:0.5rem;padding:1.5rem;opacity:0;background-color:var(--mds-dropdown-background);-webkit-box-sizing:border-box;box-sizing:border-box;display:grid;-webkit-filter:var(--mds-dropdown-drop-shadow);filter:var(--mds-dropdown-drop-shadow);pointer-events:none;position:fixed;-webkit-transform:var(--mds-dropdown-transform-from);transform:var(--mds-dropdown-transform-from);-webkit-transition-duration:var(--mds-dropdown-duration);transition-duration:var(--mds-dropdown-duration);-webkit-transition-property:opacity, -webkit-transform, -webkit-transform-origin;transition-property:opacity, -webkit-transform, -webkit-transform-origin;transition-property:opacity, transform, transform-origin;transition-property:opacity, transform, transform-origin, -webkit-transform, -webkit-transform-origin;-webkit-transition-timing-function:var(--mds-dropdown-ease);transition-timing-function:var(--mds-dropdown-ease);z-index:var(--mds-dropdown-z-index)}:host([visible]:not([visible="false"])){opacity:1;pointer-events:auto;-webkit-transform:var(--mds-dropdown-transform-to);transform:var(--mds-dropdown-transform-to)}:host([smooth]:not([smooth="false"])){-webkit-transition-property:bottom, left, opacity, right, top, -webkit-transform, -webkit-transform-origin;transition-property:bottom, left, opacity, right, top, -webkit-transform, -webkit-transform-origin;transition-property:bottom, left, opacity, right, top, transform, transform-origin;transition-property:bottom, left, opacity, right, top, transform, transform-origin, -webkit-transform, -webkit-transform-origin}.arrow{top:-1rem;display:-ms-flexbox;display:flex;fill:var(--mds-dropdown-arrow-background);pointer-events:none;position:fixed;-webkit-transition-duration:var(--mds-dropdown-duration);transition-duration:var(--mds-dropdown-duration);-webkit-transition-property:bottom, left, right, top, -webkit-transform, -webkit-transform-origin;transition-property:bottom, left, right, top, -webkit-transform, -webkit-transform-origin;transition-property:bottom, left, right, top, transform, transform-origin;transition-property:bottom, left, right, top, transform, transform-origin, -webkit-transform, -webkit-transform-origin}:host([arrow]:not([arrow="false"])[visible]:not([visible="false"])) .arrow{-webkit-transition-timing-function:cubic-bezier(0.165, 0.84, 0.44, 1);transition-timing-function:cubic-bezier(0.165, 0.84, 0.44, 1)}:host([arrow]:not([arrow="false"],[visible],[visible="true"])) .arrow{-webkit-transition-timing-function:cubic-bezier(0.19, 1, 0.22, 1);transition-timing-function:cubic-bezier(0.19, 1, 0.22, 1)}::slotted(*){z-index:10;position:relative}';var MdsDropdown=function(){function t(t){var e=this;registerInstance(this,t);this.visibleEvent=createEvent(this,"mdsDropdownVisible",7);this.hiddenEvent=createEvent(this,"mdsDropdownHide",7);this.changedEvent=createEvent(this,"mdsDropdownChange",7);this.backdropBackgroundVisible="rgba(var(--magma-backdrop-color, 0 0 0) / var(--magma-backdrop-opacity, 0.1))";this.backdropBackgroundHidden="rgba(var(--magma-backdrop-color, 0 0 0) / 0)";this.backdropId="mds-dropdown-backdrop";this.km=new KeyboardManager;this.handleCloseDropdown=function(t){if(!e.visible){return}if(!e.host.contains(t.target)&&t.target!==e.caller){e.handleVisibility(false)}};this.handleVisibility=function(t){e.visible=t;e.changedEvent.emit({caller:e.caller,visible:e.visible});if(e.visible){e.visibleEvent.emit({caller:e.caller,visible:true});return}e.hiddenEvent.emit({caller:e.caller,visible:false});e.updatePosition()};this.callerOnClick=function(){e.handleVisibility(!e.visible)};this.callerOnMouseOver=function(){e.mouseoverTimer=setTimeout((function(){clearTimeout(e.mouseoverTimer);e.handleVisibility(true)}),cssDurationToMilliseconds(e.cssMouseOverDelayDuration))};this.closeDropdownMouseLeave=function(){e.handleVisibility(false);e.host.removeEventListener("mouseleave",e.closeDropdownMouseLeave.bind(e));e.host.addEventListener("mouseover",e.handleCloseDropdownMouseLeave.bind(e))};this.handleCloseDropdownMouseLeave=function(){e.host.removeEventListener("mouseover",e.handleCloseDropdownMouseLeave.bind(e));e.host.addEventListener("mouseleave",e.closeDropdownMouseLeave.bind(e))};this.arrowInset=function(t,e){var r=t.arrow;var n={bottom:"",left:"",right:"",top:""};if(r===undefined){return{}}switch(e){case"bottom":n.left=r.x!==null?"".concat(r.x,"px"):"";n.top="100%";break;case"left":n.right="100%";n.top=r.y!==null?"".concat(r.y,"px"):"";break;case"right":n.left="100%";n.top=r.y!==null?"".concat(r.y,"px"):"";break;case"top":n.left=r.x!==null?"".concat(r.x,"px"):"";n.top="";break}return n};this.arrowTransform=function(t){var r=e.arrow&&e.visible?"scale(1)":"scale(0)";switch(t){case"bottom":r="rotate(180deg) ".concat(r," translate(0, -100%)");break;case"left":r="rotate(-90deg) ".concat(r," translate(50%, -50%)");break;case"right":r="rotate(90deg) ".concat(r," translate(-50%, -50%)");break;case"top":r="rotate(0deg) ".concat(r," translate(0, 0)");break}return{transform:r}};this.arrowTransformOrigin=function(t){switch(t){case"bottom":return{transformOrigin:"center top"};case"left":return{transformOrigin:"right center"};case"right":return{transformOrigin:"left center"};case"top":return{transformOrigin:"center bottom"};default:return{transformOrigin:"center top"}}};this.updatePosition=function(){if(!e.caller)return;var t=new Array;var r={};if(e.shiftPadding){r.padding=e.shiftPadding}if(e.autoPlacement){t.push(autoPlacement())}if(e.offset){t.push(offset(e.offset))}if(!e.autoPlacement&&e.flip){t.push(flip(r))}if(e.shift){t.push(shift(r))}if(e.arrow){t.push(arrow({element:e.arrowEl,padding:e.arrowPadding}))}computePosition(e.caller,e.host,{middleware:t,placement:e.placement,strategy:e.strategy}).then((function(t){var r=t.x,n=t.y,i=t.placement,o=t.middlewareData;Object.assign(e.host.style,{left:"".concat(r,"px"),top:"".concat(n,"px")});var a={};var s={top:"bottom",right:"left",bottom:"top",left:"right"}[i.split("-")[0]];if(s){Object.assign(a,e.arrowTransform(s));Object.assign(a,e.arrowInset(o,s));Object.assign(a,e.arrowTransformOrigin(s));Object.assign(e.arrowEl.style,a)}}))};this.updateCSSCustomProps=function(){var t=window.getComputedStyle(e.host);e.cssBackdropDuration=t.getPropertyValue("--mds-dropdown-backdrop-duration");e.cssBackdropZIndex=t.getPropertyValue("--mds-dropdown-backdrop-z-index");e.cssMouseOverDelayDuration=t.getPropertyValue("--mds-dropdown-mouseover-delay")};this.arrow=true;this.arrowPadding=24;this.autoPlacement=false;this.backdrop=false;this.flip=false;this.interaction="click";this.target=undefined;this.offset=24;this.placement="bottom";this.shift=true;this.shiftPadding=24;this.smooth=true;this.strategy="fixed";this.visible=false;this.zIndex=undefined}t.prototype.attachBackdrop=function(){var t=this;if(!this.backdropEl){this.backdropEl=document.createElement("div");this.backdropEl.style.backgroundColor=this.backdropBackgroundHidden;this.backdropEl.className=this.backdropId;this.backdropEl.style.inset="0";this.backdropEl.style.pointerEvents="none";this.backdropEl.style.position="fixed";this.backdropEl.style.transition="background-color ".concat(this.cssBackdropDuration," ease-out");this.backdropEl.style.zIndex=this.cssBackdropZIndex}document.body.appendChild(this.backdropEl);clearTimeout(this.backdropTimer);this.backdropTimer=setTimeout((function(){t.backdropEl.style.backgroundColor=t.backdropBackgroundVisible}),1)};t.prototype.detachBackdrop=function(){var t=this;if(!this.backdropEl){return}this.backdropEl.style.backgroundColor="transparent";clearTimeout(this.backdropTimer);this.backdropTimer=setTimeout((function(){t.backdropEl.remove()}),cssDurationToMilliseconds(this.cssBackdropDuration))};t.prototype.arrowChanged=function(){this.updatePosition()};t.prototype.arrowPaddingChanged=function(){this.updatePosition()};t.prototype.autoPlacementChanged=function(){this.updatePosition()};t.prototype.backdropChanged=function(t){if(!this.visible){return}if(t){this.attachBackdrop();return}this.detachBackdrop()};t.prototype.flipChanged=function(){this.updatePosition()};t.prototype.offsetChanged=function(){this.updatePosition()};t.prototype.placementChanged=function(){this.updatePosition()};t.prototype.shiftChanged=function(){this.updatePosition()};t.prototype.shiftPaddingChanged=function(){this.updatePosition()};t.prototype.strategyChanged=function(){this.updatePosition()};t.prototype.visibleChanged=function(t){this.updatePosition();if(!this.backdrop){return}if(t){this.attachBackdrop();return}this.detachBackdrop()};t.prototype.zIndexChanged=function(t){if(t){this.host.style.setProperty("z-index",t.toString())}};t.prototype.componentWillLoad=function(){Array.from(document.getElementsByClassName(this.backdropId)).forEach((function(t){t.remove()}));this.zIndexChanged(this.zIndex)};t.prototype.setAriaAttributes=function(){var t=setAttributeIfEmpty(this.host,"id",hashValue(this.target));setAttributeIfEmpty(this.caller,"aria-haspopup","true");setAttributeIfEmpty(this.caller,"aria-controls",t);setAttributeIfEmpty(this.host,"role","menu");setAttributeIfEmpty(this.host,"aria-labelledby",this.target)};t.prototype.componentDidLoad=function(){var t=this;var e;this.updateCSSCustomProps();document.addEventListener("click",this.handleCloseDropdown);this.arrowEl=(e=this.host.shadowRoot)===null||e===void 0?void 0:e.querySelector(".arrow");var r=document.querySelector(this.target);if(!r){return}this.caller=r;this.setAriaAttributes();if(this.interaction==="click"){this.caller.addEventListener("click",this.callerOnClick.bind(this))}if(this.interaction==="mouseover"){this.caller.addEventListener("mouseover",this.callerOnMouseOver.bind(this));this.host.addEventListener("mouseover",this.handleCloseDropdownMouseLeave.bind(this))}this.km.addElement(this.host);this.km.attachEscapeBehavior((function(){return t.handleVisibility(false)}));this.backdropChanged(this.backdrop);this.updatePosition();if(!this.cleanupAutoUpdate){this.cleanupAutoUpdate=autoUpdate(this.caller,this.host,this.updatePosition)}};t.prototype.disconnectedCallback=function(){this.detachBackdrop();this.km.detachEscapeBehavior();this.cleanupAutoUpdate=function(){return}};t.prototype.render=function(){return h(Host,null,h("div",{class:"arrow",innerHTML:arrowSvg}),h("slot",null))};Object.defineProperty(t.prototype,"host",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(t,"watchers",{get:function(){return{arrow:["arrowChanged"],arrowPadding:["arrowPaddingChanged"],autoPlacement:["autoPlacementChanged"],backdrop:["backdropChanged"],flip:["flipChanged"],offset:["offsetChanged"],placement:["placementChanged"],shift:["shiftChanged"],shiftPadding:["shiftPaddingChanged"],strategy:["strategyChanged"],visible:["visibleChanged"],zIndex:["zIndexChanged"]}},enumerable:false,configurable:true});return t}();MdsDropdown.style=mdsDropdownCss;export{MdsDropdown as mds_dropdown};

@@ -1,1 +0,1 @@

import{p as promiseResolve,b as bootstrapLazy}from"./index-37f9ae9f.js";export{s as setNonce}from"./index-37f9ae9f.js";var patchBrowser=function(){var a=import.meta.url;var e={};if(a!==""){e.resourcesUrl=new URL(".",a).href}return promiseResolve(e)};patchBrowser().then((function(a){return bootstrapLazy([["mds-dropdown",[[1,"mds-dropdown",{arrow:[4],arrowPadding:[2,"arrow-padding"],autoPlacement:[4,"auto-placement"],backdrop:[4],flip:[4],target:[1],offset:[2],placement:[1],shift:[4],shiftPadding:[2,"shift-padding"],smooth:[4],strategy:[1],visible:[1540],zIndex:[2,"z-index"]},null,{arrow:["arrowChanged"],arrowPadding:["arrowPaddingChanged"],autoPlacement:["autoPlacementChanged"],backdrop:["backdropChanged"],flip:["flipChanged"],offset:["offsetChanged"],placement:["placementChanged"],shift:["shiftChanged"],shiftPadding:["shiftPaddingChanged"],strategy:["strategyChanged"],visible:["visibleChanged"],zIndex:["zIndexChanged"]}]]]],a)}));
import{p as promiseResolve,b as bootstrapLazy}from"./index-37f9ae9f.js";export{s as setNonce}from"./index-37f9ae9f.js";var patchBrowser=function(){var a=import.meta.url;var e={};if(a!==""){e.resourcesUrl=new URL(".",a).href}return promiseResolve(e)};patchBrowser().then((function(a){return bootstrapLazy([["mds-dropdown",[[1,"mds-dropdown",{arrow:[4],arrowPadding:[2,"arrow-padding"],autoPlacement:[4,"auto-placement"],backdrop:[4],flip:[4],interaction:[513],target:[1],offset:[2],placement:[1],shift:[4],shiftPadding:[2,"shift-padding"],smooth:[4],strategy:[1],visible:[1540],zIndex:[2,"z-index"]},null,{arrow:["arrowChanged"],arrowPadding:["arrowPaddingChanged"],autoPlacement:["autoPlacementChanged"],backdrop:["backdropChanged"],flip:["flipChanged"],offset:["offsetChanged"],placement:["placementChanged"],shift:["shiftChanged"],shiftPadding:["shiftPaddingChanged"],strategy:["strategyChanged"],visible:["visibleChanged"],zIndex:["zIndexChanged"]}]]]],a)}));

@@ -6,5 +6,5 @@ import { b as bootstrapLazy } from './index-37f9ae9f.js';

if (typeof window === 'undefined') return undefined;
return bootstrapLazy([["mds-dropdown",[[1,"mds-dropdown",{"arrow":[4],"arrowPadding":[2,"arrow-padding"],"autoPlacement":[4,"auto-placement"],"backdrop":[4],"flip":[4],"target":[1],"offset":[2],"placement":[1],"shift":[4],"shiftPadding":[2,"shift-padding"],"smooth":[4],"strategy":[1],"visible":[1540],"zIndex":[2,"z-index"]},null,{"arrow":["arrowChanged"],"arrowPadding":["arrowPaddingChanged"],"autoPlacement":["autoPlacementChanged"],"backdrop":["backdropChanged"],"flip":["flipChanged"],"offset":["offsetChanged"],"placement":["placementChanged"],"shift":["shiftChanged"],"shiftPadding":["shiftPaddingChanged"],"strategy":["strategyChanged"],"visible":["visibleChanged"],"zIndex":["zIndexChanged"]}]]]], options);
return bootstrapLazy([["mds-dropdown",[[1,"mds-dropdown",{"arrow":[4],"arrowPadding":[2,"arrow-padding"],"autoPlacement":[4,"auto-placement"],"backdrop":[4],"flip":[4],"interaction":[513],"target":[1],"offset":[2],"placement":[1],"shift":[4],"shiftPadding":[2,"shift-padding"],"smooth":[4],"strategy":[1],"visible":[1540],"zIndex":[2,"z-index"]},null,{"arrow":["arrowChanged"],"arrowPadding":["arrowPaddingChanged"],"autoPlacement":["autoPlacementChanged"],"backdrop":["backdropChanged"],"flip":["flipChanged"],"offset":["offsetChanged"],"placement":["placementChanged"],"shift":["shiftChanged"],"shiftPadding":["shiftPaddingChanged"],"strategy":["strategyChanged"],"visible":["visibleChanged"],"zIndex":["zIndexChanged"]}]]]], options);
};
export { defineCustomElements };

@@ -17,3 +17,3 @@ import { p as promiseResolve, b as bootstrapLazy } from './index-37f9ae9f.js';

patchBrowser().then(options => {
return bootstrapLazy([["mds-dropdown",[[1,"mds-dropdown",{"arrow":[4],"arrowPadding":[2,"arrow-padding"],"autoPlacement":[4,"auto-placement"],"backdrop":[4],"flip":[4],"target":[1],"offset":[2],"placement":[1],"shift":[4],"shiftPadding":[2,"shift-padding"],"smooth":[4],"strategy":[1],"visible":[1540],"zIndex":[2,"z-index"]},null,{"arrow":["arrowChanged"],"arrowPadding":["arrowPaddingChanged"],"autoPlacement":["autoPlacementChanged"],"backdrop":["backdropChanged"],"flip":["flipChanged"],"offset":["offsetChanged"],"placement":["placementChanged"],"shift":["shiftChanged"],"shiftPadding":["shiftPaddingChanged"],"strategy":["strategyChanged"],"visible":["visibleChanged"],"zIndex":["zIndexChanged"]}]]]], options);
return bootstrapLazy([["mds-dropdown",[[1,"mds-dropdown",{"arrow":[4],"arrowPadding":[2,"arrow-padding"],"autoPlacement":[4,"auto-placement"],"backdrop":[4],"flip":[4],"interaction":[513],"target":[1],"offset":[2],"placement":[1],"shift":[4],"shiftPadding":[2,"shift-padding"],"smooth":[4],"strategy":[1],"visible":[1540],"zIndex":[2,"z-index"]},null,{"arrow":["arrowChanged"],"arrowPadding":["arrowPaddingChanged"],"autoPlacement":["autoPlacementChanged"],"backdrop":["backdropChanged"],"flip":["flipChanged"],"offset":["offsetChanged"],"placement":["placementChanged"],"shift":["shiftChanged"],"shiftPadding":["shiftPaddingChanged"],"strategy":["strategyChanged"],"visible":["visibleChanged"],"zIndex":["zIndexChanged"]}]]]], options);
});

@@ -1,1 +0,1 @@

import{p as a,b as e}from"./p-3706264e.js";export{s as setNonce}from"./p-3706264e.js";(()=>{const e=import.meta.url,d={};return""!==e&&(d.resourcesUrl=new URL(".",e).href),a(d)})().then((a=>e([["p-e5ef22ad",[[1,"mds-dropdown",{arrow:[4],arrowPadding:[2,"arrow-padding"],autoPlacement:[4,"auto-placement"],backdrop:[4],flip:[4],target:[1],offset:[2],placement:[1],shift:[4],shiftPadding:[2,"shift-padding"],smooth:[4],strategy:[1],visible:[1540],zIndex:[2,"z-index"]},null,{arrow:["arrowChanged"],arrowPadding:["arrowPaddingChanged"],autoPlacement:["autoPlacementChanged"],backdrop:["backdropChanged"],flip:["flipChanged"],offset:["offsetChanged"],placement:["placementChanged"],shift:["shiftChanged"],shiftPadding:["shiftPaddingChanged"],strategy:["strategyChanged"],visible:["visibleChanged"],zIndex:["zIndexChanged"]}]]]],a)));
import{p as a,b as e}from"./p-3706264e.js";export{s as setNonce}from"./p-3706264e.js";(()=>{const e=import.meta.url,d={};return""!==e&&(d.resourcesUrl=new URL(".",e).href),a(d)})().then((a=>e([["p-2d109ebb",[[1,"mds-dropdown",{arrow:[4],arrowPadding:[2,"arrow-padding"],autoPlacement:[4,"auto-placement"],backdrop:[4],flip:[4],interaction:[513],target:[1],offset:[2],placement:[1],shift:[4],shiftPadding:[2,"shift-padding"],smooth:[4],strategy:[1],visible:[1540],zIndex:[2,"z-index"]},null,{arrow:["arrowChanged"],arrowPadding:["arrowPaddingChanged"],autoPlacement:["autoPlacementChanged"],backdrop:["backdropChanged"],flip:["flipChanged"],offset:["offsetChanged"],placement:["placementChanged"],shift:["shiftChanged"],shiftPadding:["shiftPaddingChanged"],strategy:["strategyChanged"],visible:["visibleChanged"],zIndex:["zIndexChanged"]}]]]],a)));

@@ -1,1 +0,1 @@

System.register(["./p-b094388b.system.js"],(function(e,a){"use strict";var n,t;return{setters:[function(a){n=a.p;t=a.b;e("setNonce",a.s)}],execute:function(){var e=function(){var e=a.meta.url;var t={};if(e!==""){t.resourcesUrl=new URL(".",e).href}return n(t)};e().then((function(e){return t([["p-7bce0755.system",[[1,"mds-dropdown",{arrow:[4],arrowPadding:[2,"arrow-padding"],autoPlacement:[4,"auto-placement"],backdrop:[4],flip:[4],target:[1],offset:[2],placement:[1],shift:[4],shiftPadding:[2,"shift-padding"],smooth:[4],strategy:[1],visible:[1540],zIndex:[2,"z-index"]},null,{arrow:["arrowChanged"],arrowPadding:["arrowPaddingChanged"],autoPlacement:["autoPlacementChanged"],backdrop:["backdropChanged"],flip:["flipChanged"],offset:["offsetChanged"],placement:["placementChanged"],shift:["shiftChanged"],shiftPadding:["shiftPaddingChanged"],strategy:["strategyChanged"],visible:["visibleChanged"],zIndex:["zIndexChanged"]}]]]],e)}))}}}));
System.register(["./p-b094388b.system.js"],(function(e,a){"use strict";var n,t;return{setters:[function(a){n=a.p;t=a.b;e("setNonce",a.s)}],execute:function(){var e=function(){var e=a.meta.url;var t={};if(e!==""){t.resourcesUrl=new URL(".",e).href}return n(t)};e().then((function(e){return t([["p-4d77d3c5.system",[[1,"mds-dropdown",{arrow:[4],arrowPadding:[2,"arrow-padding"],autoPlacement:[4,"auto-placement"],backdrop:[4],flip:[4],interaction:[513],target:[1],offset:[2],placement:[1],shift:[4],shiftPadding:[2,"shift-padding"],smooth:[4],strategy:[1],visible:[1540],zIndex:[2,"z-index"]},null,{arrow:["arrowChanged"],arrowPadding:["arrowPaddingChanged"],autoPlacement:["autoPlacementChanged"],backdrop:["backdropChanged"],flip:["flipChanged"],offset:["offsetChanged"],placement:["placementChanged"],shift:["shiftChanged"],shiftPadding:["shiftPaddingChanged"],strategy:["strategyChanged"],visible:["visibleChanged"],zIndex:["zIndexChanged"]}]]]],e)}))}}}));
{
"timestamp": "2024-02-19T12:05:50",
"timestamp": "2024-02-26T21:04:59",
"compiler": {

@@ -12,7 +12,7 @@ "name": "node",

"entries": 1,
"bundles": 81,
"bundles": 83,
"outputs": [
{
"name": "dist-collection",
"files": 40,
"files": 42,
"generatedFiles": [

@@ -32,3 +32,5 @@ "./dist/collection/common/aria.js",

"./dist/collection/components/mds-dropdown/mds-dropdown.js",
"./dist/collection/components/mds-dropdown/meta/dictionary.js",
"./dist/collection/components/mds-dropdown/meta/event-detail.js",
"./dist/collection/components/mds-dropdown/meta/types.js",
"./dist/collection/components/mds-dropdown/test/mds-dropdown.stories.js",

@@ -96,17 +98,17 @@ "./dist/collection/dictionary/autocomplete.js",

"./dist/mds-dropdown/mds-dropdown.js",
"./dist/mds-dropdown/p-2d109ebb.entry.js",
"./dist/mds-dropdown/p-3706264e.js",
"./dist/mds-dropdown/p-4d77d3c5.system.entry.js",
"./dist/mds-dropdown/p-50ea2036.system.js",
"./dist/mds-dropdown/p-7bce0755.system.entry.js",
"./dist/mds-dropdown/p-b094388b.system.js",
"./dist/mds-dropdown/p-c29a7ce6.system.js",
"./dist/mds-dropdown/p-e5ef22ad.entry.js",
"./www/build/index.esm.js",
"./www/build/mds-dropdown.esm.js",
"./www/build/mds-dropdown.js",
"./www/build/p-2d109ebb.entry.js",
"./www/build/p-3706264e.js",
"./www/build/p-4d77d3c5.system.entry.js",
"./www/build/p-50ea2036.system.js",
"./www/build/p-7bce0755.system.entry.js",
"./www/build/p-b094388b.system.js",
"./www/build/p-c29a7ce6.system.js",
"./www/build/p-e5ef22ad.entry.js"
"./www/build/p-c29a7ce6.system.js"
]

@@ -144,8 +146,8 @@ },

],
"bundleId": "p-e5ef22ad",
"fileName": "p-e5ef22ad.entry.js",
"bundleId": "p-2d109ebb",
"fileName": "p-2d109ebb.entry.js",
"imports": [
"p-3706264e.js"
],
"originalByteSize": 74858
"originalByteSize": 76183
}

@@ -164,3 +166,3 @@ ],

],
"originalByteSize": 74862
"originalByteSize": 76187
}

@@ -179,3 +181,3 @@ ],

],
"originalByteSize": 74862
"originalByteSize": 76187
}

@@ -189,8 +191,8 @@ ],

],
"bundleId": "p-7bce0755.system",
"fileName": "p-7bce0755.system.entry.js",
"bundleId": "p-4d77d3c5.system",
"fileName": "p-4d77d3c5.system.entry.js",
"imports": [
"p-b094388b.system.js"
],
"originalByteSize": 97542
"originalByteSize": 99143
}

@@ -209,3 +211,3 @@ ],

],
"originalByteSize": 74927
"originalByteSize": 76252
}

@@ -414,2 +416,28 @@ ]

{
"name": "interaction",
"type": "string",
"attribute": "interaction",
"reflect": true,
"mutable": false,
"required": false,
"optional": true,
"defaultValue": "'click'",
"complexType": {
"original": "DropdownInteractionType",
"resolved": "\"click\" | \"mouseover\" | undefined",
"references": {
"DropdownInteractionType": {
"location": "import",
"path": "./meta/types",
"id": "src/components/mds-dropdown/meta/types.ts::DropdownInteractionType"
}
}
},
"docs": {
"tags": [],
"text": "Specifies if the component is triggered from the caller on mouseover or click event"
},
"internal": false
},
{
"name": "target",

@@ -724,2 +752,28 @@ "type": "string",

{
"name": "interaction",
"type": "string",
"attribute": "interaction",
"reflect": true,
"mutable": false,
"required": false,
"optional": true,
"defaultValue": "'click'",
"complexType": {
"original": "DropdownInteractionType",
"resolved": "\"click\" | \"mouseover\" | undefined",
"references": {
"DropdownInteractionType": {
"location": "import",
"path": "./meta/types",
"id": "src/components/mds-dropdown/meta/types.ts::DropdownInteractionType"
}
}
},
"docs": {
"tags": [],
"text": "Specifies if the component is triggered from the caller on mouseover or click event"
},
"internal": false
},
{
"name": "target",

@@ -1084,2 +1138,7 @@ "type": "string",

{
"name": "--mds-dropdown-mouseover-delay",
"docs": "Sets the delay duration of the component when the caller trigger mouseover event, it's used by the javascript code.",
"annotation": "prop"
},
{
"name": "--mds-dropdown-duration",

@@ -1218,4 +1277,8 @@ "docs": "Sets the duration of the dropdown animation.",

],
"./src/components/mds-dropdown/meta/dictionary.ts": [],
"./src/components/mds-dropdown/meta/event-detail.ts": [],
"./src/components/mds-dropdown/test/mds-dropdown.stories.tsx": [],
"./src/components/mds-dropdown/meta/types.ts": [],
"./src/components/mds-dropdown/test/mds-dropdown.stories.tsx": [
"./src/components/mds-dropdown/meta/dictionary"
],
"./src/dictionary/autocomplete.ts": [],

@@ -1222,0 +1285,0 @@ "./src/dictionary/button.ts": [],

@@ -8,4 +8,6 @@ /* eslint-disable */

import { HTMLStencilElement, JSXBase } from "./stencil-public-runtime";
import { DropdownInteractionType } from "./components/mds-dropdown/meta/types";
import { FloatingUIPlacement, FloatingUIStrategy } from "@type/floating-ui";
import { MdsDropdownEventDetail } from "./components/mds-dropdown/meta/event-detail";
export { DropdownInteractionType } from "./components/mds-dropdown/meta/types";
export { FloatingUIPlacement, FloatingUIStrategy } from "@type/floating-ui";

@@ -36,2 +38,6 @@ export { MdsDropdownEventDetail } from "./components/mds-dropdown/meta/event-detail";

/**
* Specifies if the component is triggered from the caller on mouseover or click event
*/
"interaction"?: DropdownInteractionType;
/**
* Sets distance between the dropdown and the caller.

@@ -125,2 +131,6 @@ */

/**
* Specifies if the component is triggered from the caller on mouseover or click event
*/
"interaction"?: DropdownInteractionType;
/**
* Sets distance between the dropdown and the caller.

@@ -127,0 +137,0 @@ */

import { EventEmitter } from '../../stencil-public-runtime';
import { FloatingUIPlacement, FloatingUIStrategy } from '@type/floating-ui';
import { MdsDropdownEventDetail } from './meta/event-detail';
import { DropdownInteractionType } from './meta/types';
/**

@@ -12,2 +13,3 @@ * @slot default - Add `text string`, `HTML elements` or `components` to this slot, elements will be shown when the component is triggered.

private cssBackdropDuration;
private cssMouseOverDelayDuration;
private cssBackdropZIndex;

@@ -17,2 +19,3 @@ private backdropEl;

private backdropTimer;
private mouseoverTimer;
private caller;

@@ -43,2 +46,6 @@ private cleanupAutoUpdate;

/**
* Specifies if the component is triggered from the caller on mouseover or click event
*/
readonly interaction?: DropdownInteractionType;
/**
* Specifies the id of the caller element.

@@ -96,2 +103,5 @@ */

private callerOnClick;
private callerOnMouseOver;
private closeDropdownMouseLeave;
private handleCloseDropdownMouseLeave;
private arrowInset;

@@ -98,0 +108,0 @@ private arrowTransform;

@@ -34,2 +34,12 @@ declare const _default: {

};
interaction: {
type: {
name: string;
};
description: string;
options: string[];
control: {
type: string;
};
};
offset: {

@@ -95,2 +105,3 @@ type: {

export declare const Flip: any;
export declare const Interaction: any;
export declare const Offset: any;

@@ -97,0 +108,0 @@ export declare const Placement: any;

{
"timestamp": "2024-02-19T11:09:01",
"timestamp": "2024-02-26T20:53:06",
"compiler": {

@@ -134,2 +134,38 @@ "name": "@stencil/core",

{
"name": "interaction",
"type": "\"click\" | \"mouseover\" | undefined",
"complexType": {
"original": "DropdownInteractionType",
"resolved": "\"click\" | \"mouseover\" | undefined",
"references": {
"DropdownInteractionType": {
"location": "import",
"path": "./meta/types",
"id": "src/components/mds-dropdown/meta/types.ts::DropdownInteractionType"
}
}
},
"mutable": false,
"attr": "interaction",
"reflectToAttr": true,
"docs": "Specifies if the component is triggered from the caller on mouseover or click event",
"docsTags": [],
"default": "'click'",
"values": [
{
"value": "click",
"type": "string"
},
{
"value": "mouseover",
"type": "string"
},
{
"type": "undefined"
}
],
"optional": true,
"required": false
},
{
"name": "offset",

@@ -494,2 +530,7 @@ "type": "number",

{
"name": "--mds-dropdown-mouseover-delay",
"annotation": "prop",
"docs": "Sets the delay duration of the component when the caller trigger mouseover event, it's used by the javascript code."
},
{
"name": "--mds-dropdown-transform-from",

@@ -643,2 +684,7 @@ "annotation": "prop",

},
"src/components/mds-dropdown/meta/types.ts::DropdownInteractionType": {
"declaration": "export type DropdownInteractionType =\n | 'click'\n | 'mouseover'",
"docstring": "",
"path": "src/components/mds-dropdown/meta/types.ts"
},
"src/type/floating-ui.ts::FloatingUIPlacement": {

@@ -645,0 +691,0 @@ "declaration": "export type FloatingUIPlacement =\n | 'bottom'\n | 'bottom-end'\n | 'bottom-start'\n | 'left'\n | 'left-end'\n | 'left-start'\n | 'right'\n | 'right-end'\n | 'right-start'\n | 'top'\n | 'top-end'\n | 'top-start'",

{
"name": "@maggioli-design-system/mds-dropdown",
"version": "5.1.1",
"version": "5.2.0",
"description": "mds-dropdown is a web-component from Magma Design System, built with StencilJS, TypeScript, Storybook. It's based on the web-component standard and it's designed to be agnostic from the JavaScirpt framework you are using.",

@@ -5,0 +5,0 @@ "main": "dist/index.cjs.js",

@@ -56,2 +56,3 @@ # mds-dropdown

| `flip` | `flip` | Specifies the placement of the component if no space is available where it is placed. | `boolean` | `false` |
| `interaction` | `interaction` | Specifies if the component is triggered from the caller on mouseover or click event | `"click" \| "mouseover" \| undefined` | `'click'` |
| `offset` | `offset` | Sets distance between the dropdown and the caller. | `number` | `24` |

@@ -86,14 +87,15 @@ | `placement` | `placement` | Specifies where the component should be placed relative to the caller. | `"bottom" \| "bottom-end" \| "bottom-start" \| "left" \| "left-end" \| "left-start" \| "right" \| "right-end" \| "right-start" \| "top" \| "top-end" \| "top-start"` | `'bottom'` |

| Name | Description |
| ---------------------------------- | --------------------------------------------------------------------------- |
| `--mds-dropdown-arrow-background` | Sets the fill color of the arrow. |
| `--mds-dropdown-backdrop-duration` | Sets the transition duration of the backdrop, used by component's code too. |
| `--mds-dropdown-backdrop-z-indx` | Sets the backdrop z-index, used by component's code too. |
| `--mds-dropdown-background` | Sets the background-color of the dropdown. |
| `--mds-dropdown-drop-shadow` | Sets the drop-shadow of the dropdown. |
| `--mds-dropdown-duration` | Sets the duration of the dropdown animation. |
| `--mds-dropdown-ease` | Sets the easing of the dropdown animation. |
| `--mds-dropdown-transform-from` | Sets the from animation transform of the dropdown. |
| `--mds-dropdown-transform-to` | Sets the to animation transform of the dropdown. |
| `--mds-dropdown-z-index` | Sets the z-index of the component. |
| Name | Description |
| ---------------------------------- | ------------------------------------------------------------------------------------------------------------------- |
| `--mds-dropdown-arrow-background` | Sets the fill color of the arrow. |
| `--mds-dropdown-backdrop-duration` | Sets the transition duration of the backdrop, used by component's code too. |
| `--mds-dropdown-backdrop-z-indx` | Sets the backdrop z-index, used by component's code too. |
| `--mds-dropdown-background` | Sets the background-color of the dropdown. |
| `--mds-dropdown-drop-shadow` | Sets the drop-shadow of the dropdown. |
| `--mds-dropdown-duration` | Sets the duration of the dropdown animation. |
| `--mds-dropdown-ease` | Sets the easing of the dropdown animation. |
| `--mds-dropdown-mouseover-delay` | Sets the delay duration of the component when the caller trigger mouseover event, it's used by the javascript code. |
| `--mds-dropdown-transform-from` | Sets the from animation transform of the dropdown. |
| `--mds-dropdown-transform-to` | Sets the to animation transform of the dropdown. |
| `--mds-dropdown-z-index` | Sets the z-index of the component. |

@@ -100,0 +102,0 @@

@@ -8,4 +8,6 @@ /* eslint-disable */

import { HTMLStencilElement, JSXBase } from "@stencil/core/internal";
import { DropdownInteractionType } from "./components/mds-dropdown/meta/types";
import { FloatingUIPlacement, FloatingUIStrategy } from "@type/floating-ui";
import { MdsDropdownEventDetail } from "./components/mds-dropdown/meta/event-detail";
export { DropdownInteractionType } from "./components/mds-dropdown/meta/types";
export { FloatingUIPlacement, FloatingUIStrategy } from "@type/floating-ui";

@@ -36,2 +38,6 @@ export { MdsDropdownEventDetail } from "./components/mds-dropdown/meta/event-detail";

/**
* Specifies if the component is triggered from the caller on mouseover or click event
*/
"interaction"?: DropdownInteractionType;
/**
* Sets distance between the dropdown and the caller.

@@ -125,2 +131,6 @@ */

/**
* Specifies if the component is triggered from the caller on mouseover or click event
*/
"interaction"?: DropdownInteractionType;
/**
* Sets distance between the dropdown and the caller.

@@ -127,0 +137,0 @@ */

@@ -17,2 +17,3 @@ # mds-dropdown

| `flip` | `flip` | Specifies the placement of the component if no space is available where it is placed. | `boolean` | `false` |
| `interaction` | `interaction` | Specifies if the component is triggered from the caller on mouseover or click event | `"click" \| "mouseover" \| undefined` | `'click'` |
| `offset` | `offset` | Sets distance between the dropdown and the caller. | `number` | `24` |

@@ -47,14 +48,15 @@ | `placement` | `placement` | Specifies where the component should be placed relative to the caller. | `"bottom" \| "bottom-end" \| "bottom-start" \| "left" \| "left-end" \| "left-start" \| "right" \| "right-end" \| "right-start" \| "top" \| "top-end" \| "top-start"` | `'bottom'` |

| Name | Description |
| ---------------------------------- | --------------------------------------------------------------------------- |
| `--mds-dropdown-arrow-background` | Sets the fill color of the arrow. |
| `--mds-dropdown-backdrop-duration` | Sets the transition duration of the backdrop, used by component's code too. |
| `--mds-dropdown-backdrop-z-indx` | Sets the backdrop z-index, used by component's code too. |
| `--mds-dropdown-background` | Sets the background-color of the dropdown. |
| `--mds-dropdown-drop-shadow` | Sets the drop-shadow of the dropdown. |
| `--mds-dropdown-duration` | Sets the duration of the dropdown animation. |
| `--mds-dropdown-ease` | Sets the easing of the dropdown animation. |
| `--mds-dropdown-transform-from` | Sets the from animation transform of the dropdown. |
| `--mds-dropdown-transform-to` | Sets the to animation transform of the dropdown. |
| `--mds-dropdown-z-index` | Sets the z-index of the component. |
| Name | Description |
| ---------------------------------- | ------------------------------------------------------------------------------------------------------------------- |
| `--mds-dropdown-arrow-background` | Sets the fill color of the arrow. |
| `--mds-dropdown-backdrop-duration` | Sets the transition duration of the backdrop, used by component's code too. |
| `--mds-dropdown-backdrop-z-indx` | Sets the backdrop z-index, used by component's code too. |
| `--mds-dropdown-background` | Sets the background-color of the dropdown. |
| `--mds-dropdown-drop-shadow` | Sets the drop-shadow of the dropdown. |
| `--mds-dropdown-duration` | Sets the duration of the dropdown animation. |
| `--mds-dropdown-ease` | Sets the easing of the dropdown animation. |
| `--mds-dropdown-mouseover-delay` | Sets the delay duration of the component when the caller trigger mouseover event, it's used by the javascript code. |
| `--mds-dropdown-transform-from` | Sets the from animation transform of the dropdown. |
| `--mds-dropdown-transform-to` | Sets the to animation transform of the dropdown. |
| `--mds-dropdown-z-index` | Sets the z-index of the component. |

@@ -61,0 +63,0 @@

@@ -1,1 +0,1 @@

import{p as a,b as e}from"./p-3706264e.js";export{s as setNonce}from"./p-3706264e.js";(()=>{const e=import.meta.url,d={};return""!==e&&(d.resourcesUrl=new URL(".",e).href),a(d)})().then((a=>e([["p-e5ef22ad",[[1,"mds-dropdown",{arrow:[4],arrowPadding:[2,"arrow-padding"],autoPlacement:[4,"auto-placement"],backdrop:[4],flip:[4],target:[1],offset:[2],placement:[1],shift:[4],shiftPadding:[2,"shift-padding"],smooth:[4],strategy:[1],visible:[1540],zIndex:[2,"z-index"]},null,{arrow:["arrowChanged"],arrowPadding:["arrowPaddingChanged"],autoPlacement:["autoPlacementChanged"],backdrop:["backdropChanged"],flip:["flipChanged"],offset:["offsetChanged"],placement:["placementChanged"],shift:["shiftChanged"],shiftPadding:["shiftPaddingChanged"],strategy:["strategyChanged"],visible:["visibleChanged"],zIndex:["zIndexChanged"]}]]]],a)));
import{p as a,b as e}from"./p-3706264e.js";export{s as setNonce}from"./p-3706264e.js";(()=>{const e=import.meta.url,d={};return""!==e&&(d.resourcesUrl=new URL(".",e).href),a(d)})().then((a=>e([["p-2d109ebb",[[1,"mds-dropdown",{arrow:[4],arrowPadding:[2,"arrow-padding"],autoPlacement:[4,"auto-placement"],backdrop:[4],flip:[4],interaction:[513],target:[1],offset:[2],placement:[1],shift:[4],shiftPadding:[2,"shift-padding"],smooth:[4],strategy:[1],visible:[1540],zIndex:[2,"z-index"]},null,{arrow:["arrowChanged"],arrowPadding:["arrowPaddingChanged"],autoPlacement:["autoPlacementChanged"],backdrop:["backdropChanged"],flip:["flipChanged"],offset:["offsetChanged"],placement:["placementChanged"],shift:["shiftChanged"],shiftPadding:["shiftPaddingChanged"],strategy:["strategyChanged"],visible:["visibleChanged"],zIndex:["zIndexChanged"]}]]]],a)));

@@ -1,1 +0,1 @@

System.register(["./p-b094388b.system.js"],(function(e,a){"use strict";var n,t;return{setters:[function(a){n=a.p;t=a.b;e("setNonce",a.s)}],execute:function(){var e=function(){var e=a.meta.url;var t={};if(e!==""){t.resourcesUrl=new URL(".",e).href}return n(t)};e().then((function(e){return t([["p-7bce0755.system",[[1,"mds-dropdown",{arrow:[4],arrowPadding:[2,"arrow-padding"],autoPlacement:[4,"auto-placement"],backdrop:[4],flip:[4],target:[1],offset:[2],placement:[1],shift:[4],shiftPadding:[2,"shift-padding"],smooth:[4],strategy:[1],visible:[1540],zIndex:[2,"z-index"]},null,{arrow:["arrowChanged"],arrowPadding:["arrowPaddingChanged"],autoPlacement:["autoPlacementChanged"],backdrop:["backdropChanged"],flip:["flipChanged"],offset:["offsetChanged"],placement:["placementChanged"],shift:["shiftChanged"],shiftPadding:["shiftPaddingChanged"],strategy:["strategyChanged"],visible:["visibleChanged"],zIndex:["zIndexChanged"]}]]]],e)}))}}}));
System.register(["./p-b094388b.system.js"],(function(e,a){"use strict";var n,t;return{setters:[function(a){n=a.p;t=a.b;e("setNonce",a.s)}],execute:function(){var e=function(){var e=a.meta.url;var t={};if(e!==""){t.resourcesUrl=new URL(".",e).href}return n(t)};e().then((function(e){return t([["p-4d77d3c5.system",[[1,"mds-dropdown",{arrow:[4],arrowPadding:[2,"arrow-padding"],autoPlacement:[4,"auto-placement"],backdrop:[4],flip:[4],interaction:[513],target:[1],offset:[2],placement:[1],shift:[4],shiftPadding:[2,"shift-padding"],smooth:[4],strategy:[1],visible:[1540],zIndex:[2,"z-index"]},null,{arrow:["arrowChanged"],arrowPadding:["arrowPaddingChanged"],autoPlacement:["autoPlacementChanged"],backdrop:["backdropChanged"],flip:["flipChanged"],offset:["offsetChanged"],placement:["placementChanged"],shift:["shiftChanged"],shiftPadding:["shiftPaddingChanged"],strategy:["strategyChanged"],visible:["visibleChanged"],zIndex:["zIndexChanged"]}]]]],e)}))}}}));

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc