@fluid-topics/ft-floating-menu 1.1.22 → 1.1.24

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -12,7 +12,6 @@ export declare class FtBaseFloatingMenu extends FtLitElement implements FtBaseFl
12
12
  forceMenuOpen: boolean;
13
13
  private container;
14
14
  private menuWrapper;
15
- private menuContent;
16
15
  private actionButton?;
17
16
  private customToggle;
18
17
  primary: boolean;
@@ -30,10 +29,10 @@ export declare class FtBaseFloatingMenu extends FtLitElement implements FtBaseFl
30
29
  disabled: boolean;
31
30
  closeMenuMatchers: string[];
32
31
  protected render(): import("lit").TemplateResult<1>;
33
- private onClick;
34
- private onClickItem;
35
- private hideOptions;
36
- private closeMenu;
32
+ toggleMenu(): void;
33
+ openMenu(): void;
34
+ closeMenu(): void;
35
+ private hideOptionsOnClickOutside;
37
36
  private onCloseEvent;
38
37
  private onContentClick;
39
38
  disconnectedCallback(): void;
@@ -10,8 +10,7 @@ import { eventPathContainsMatchingElement, FtLitElement, jsonProperty, } from "@
10
10
  import { classMap } from "lit/directives/class-map.js";
11
11
  import { FtFloatingMenuItem } from "./ft-floating-menu-item";
12
12
  import { FtIconVariants } from "@fluid-topics/ft-icon/build/ft-icon.properties";
13
- import { autoPlacement, computePosition, platform, shift } from "@floating-ui/dom";
14
- import { offsetParent } from "composed-offset-position";
13
+ import { computeOffsetPosition } from "@fluid-topics/ft-wc-utils/build/floating";
15
14
  export class FloatingMenuCloseEvent extends CustomEvent {
16
15
  constructor() {
17
16
  super("close-ft-floating-menu");
@@ -33,11 +32,8 @@ class FtBaseFloatingMenu extends FtLitElement {
33
32
  this.verticalAlignment = "bottom";
34
33
  this.disabled = false;
35
34
  this.closeMenuMatchers = [];
36
- this.hideOptions = (e) => {
35
+ this.hideOptionsOnClickOutside = (e) => {
37
36
  this.menuOpen = this.menuOpen && e.composedPath().includes(this.container);
38
- if (!this.menuOpen) {
39
- document.removeEventListener("click", this.hideOptions);
40
- }
41
37
  };
42
38
  }
43
39
  render() {
@@ -52,7 +48,7 @@ class FtBaseFloatingMenu extends FtLitElement {
52
48
 
53
49
  <slot name="toggle"
54
50
  part="toggle"
55
- @click=${this.onClick}>
51
+ @click=${this.toggleMenu}>
56
52
  <ft-or-ftds-button id="actions-button"
57
53
  part="button"
58
54
  ?primary=${this.primary}
@@ -75,7 +71,7 @@ class FtBaseFloatingMenu extends FtLitElement {
75
71
  <div id="ft-floating-menu-options"
76
72
  class="ft-floating-menu--options"
77
73
  part="options"
78
- @select="${this.onClickItem}">
74
+ @select="${this.closeMenu}">
79
75
  <slot id="ft-floating-menu-content"
80
76
  @click=${this.onContentClick}
81
77
  @close-ft-floating-menu=${this.onCloseEvent}
@@ -85,12 +81,11 @@ class FtBaseFloatingMenu extends FtLitElement {
85
81
  </div>
86
82
  `;
87
83
  }
88
- onClick() {
84
+ toggleMenu() {
89
85
  this.menuOpen = !this.menuOpen;
90
- setTimeout(() => document.addEventListener("click", this.hideOptions));
91
86
  }
92
- onClickItem() {
93
- this.closeMenu();
87
+ openMenu() {
88
+ this.menuOpen = true;
94
89
  }
95
90
  closeMenu() {
96
91
  this.menuOpen = false;
@@ -102,39 +97,32 @@ class FtBaseFloatingMenu extends FtLitElement {
102
97
  onContentClick(e) {
103
98
  if (eventPathContainsMatchingElement(e, this.closeMenuMatchers, this)) {
104
99
  this.closeMenu();
105
- e.stopPropagation();
106
100
  }
107
101
  }
108
102
  disconnectedCallback() {
109
103
  super.disconnectedCallback();
110
- document.removeEventListener("click", this.hideOptions);
104
+ document.removeEventListener("click", this.hideOptionsOnClickOutside);
111
105
  }
112
106
  contentAvailableCallback(props) {
113
107
  super.contentAvailableCallback(props);
114
- if (["menuOpen"].some(p => props.has(p)) && this.menuOpen) {
115
- this.menuWrapper.classList.remove("ft-floating-menu--wrapper-positioned");
116
- this.positionMenuWrapper();
108
+ if (props.has("menuOpen")) {
109
+ if (this.menuOpen) {
110
+ this.menuWrapper.classList.remove("ft-floating-menu--wrapper-positioned");
111
+ this.positionMenuWrapper();
112
+ document.addEventListener("click", this.hideOptionsOnClickOutside);
113
+ }
114
+ else {
115
+ document.removeEventListener("click", this.hideOptionsOnClickOutside);
116
+ }
117
117
  }
118
118
  }
119
- positionMenuWrapper() {
119
+ async positionMenuWrapper() {
120
120
  this.menuWrapper.style.left = "";
121
121
  this.menuWrapper.style.top = "";
122
122
  const reference = this.customToggle.length > 0 ? this.customToggle[0] : this.actionButton;
123
- computePosition(reference, this.menuWrapper, {
124
- platform: {
125
- ...platform,
126
- getOffsetParent: (element) => {
127
- return platform.getOffsetParent(element, offsetParent);
128
- },
129
- },
130
- middleware: [
131
- shift({ crossAxis: true }),
132
- autoPlacement({ allowedPlacements: [this.convertPlacement()] }),
133
- ],
134
- }).then(({ x, y }) => {
135
- this.menuWrapper.style.left = `${x}px`;
136
- this.menuWrapper.style.top = `${y}px`;
137
- });
123
+ const { x, y } = await computeOffsetPosition(reference, this.menuWrapper, this.convertPlacement());
124
+ this.menuWrapper.style.left = `${x}px`;
125
+ this.menuWrapper.style.top = `${y}px`;
138
126
  this.menuWrapper.classList.add("ft-floating-menu--wrapper-positioned");
139
127
  }
140
128
  convertPlacement() {
@@ -163,9 +151,6 @@ __decorate([
163
151
  __decorate([
164
152
  query(".ft-floating-menu--wrapper")
165
153
  ], FtBaseFloatingMenu.prototype, "menuWrapper", void 0);
166
- __decorate([
167
- query("#ft-floating-menu-options")
168
- ], FtBaseFloatingMenu.prototype, "menuContent", void 0);
169
154
  __decorate([
170
155
  query("#actions-button")
171
156
  ], FtBaseFloatingMenu.prototype, "actionButton", void 0);
@@ -558,7 +558,7 @@ const Bo=Symbol.for(""),Fo=t=>{if(t?.r===Bo)return t?._$litStatic$},Do=t=>({_$li
558
558
  position: relative;
559
559
  word-break: break-word;
560
560
  }
561
- `,Jo=["start","end"],Qo=["top","right","bottom","left"].reduce(((t,o)=>t.concat(o,o+"-"+Jo[0],o+"-"+Jo[1])),[]),te=Math.min,oe=Math.max,ee=Math.round,re=t=>({x:t,y:t}),ie={left:"right",right:"left",bottom:"top",top:"bottom"},ne={start:"end",end:"start"};function ae(t,o,e){return oe(t,te(o,e))}function le(t,o){return"function"==typeof t?t(o):t}function ce(t){return t.split("-")[0]}function se(t){return t.split("-")[1]}function fe(t){return"x"===t?"y":"x"}function pe(t){return"y"===t?"height":"width"}function de(t){return["top","bottom"].includes(ce(t))?"y":"x"}function he(t){return fe(de(t))}function ye(t){return t.replace(/left|right|bottom|top/g,(t=>ie[t]))}function ge(t){return{...t,top:t.y,left:t.x,right:t.x+t.width,bottom:t.y+t.height}}function ue(t,o,e){let{reference:r,floating:i}=t;const n=de(o),a=he(o),l=pe(a),c=ce(o),s="y"===n,f=r.x+r.width/2-i.width/2,p=r.y+r.height/2-i.height/2,d=r[l]/2-i[l]/2;let h;switch(c){case"top":h={x:f,y:r.y-i.height};break;case"bottom":h={x:f,y:r.y+r.height};break;case"right":h={x:r.x+r.width,y:p};break;case"left":h={x:r.x-i.width,y:p};break;default:h={x:r.x,y:r.y}}switch(se(o)){case"start":h[a]-=d*(e&&s?-1:1);break;case"end":h[a]+=d*(e&&s?-1:1)}return h}async function be(t,o){var e;void 0===o&&(o={});const{x:r,y:i,platform:n,rects:a,elements:l,strategy:c}=t,{boundary:s="clippingAncestors",rootBoundary:f="viewport",elementContext:p="floating",altBoundary:d=!1,padding:h=0}=le(o,t),y=function(t){return"number"!=typeof t?function(t){return{top:0,right:0,bottom:0,left:0,...t}}(t):{top:t,right:t,bottom:t,left:t}}(h),g=l[d?"floating"===p?"reference":"floating":p],u=ge(await n.getClippingRect({element:null==(e=await(null==n.isElement?void 0:n.isElement(g)))||e?g:g.contextElement||await(null==n.getDocumentElement?void 0:n.getDocumentElement(l.floating)),boundary:s,rootBoundary:f,strategy:c})),b="floating"===p?{...a.floating,x:r,y:i}:a.reference,m=await(null==n.getOffsetParent?void 0:n.getOffsetParent(l.floating)),x=await(null==n.isElement?void 0:n.isElement(m))&&await(null==n.getScale?void 0:n.getScale(m))||{x:1,y:1},O=ge(n.convertOffsetParentRelativeRectToViewportRelativeRect?await n.convertOffsetParentRelativeRectToViewportRelativeRect({rect:b,offsetParent:m,strategy:c}):b);return{top:(u.top-O.top+y.top)/x.y,bottom:(O.bottom-u.bottom+y.bottom)/x.y,left:(u.left-O.left+y.left)/x.x,right:(O.right-u.right+y.right)/x.x}}function me(t,o,e){return(t?[...e.filter((o=>se(o)===t)),...e.filter((o=>se(o)!==t))]:e.filter((t=>ce(t)===t))).filter((e=>!t||(se(e)===t||!!o&&function(t){return t.replace(/start|end/g,(t=>ne[t]))}(e)!==e)))}const xe=function(t){return void 0===t&&(t={}),{name:"autoPlacement",options:t,async fn(o){var e,r,i;const{rects:n,middlewareData:a,placement:l,platform:c,elements:s}=o,{crossAxis:f=!1,alignment:p,allowedPlacements:d=Qo,autoAlignment:h=!0,...y}=le(t,o),g=void 0!==p||d===Qo?me(p||null,h,d):d,u=await be(o,y),b=(null==(e=a.autoPlacement)?void 0:e.index)||0,m=g[b];if(null==m)return{};const x=function(t,o,e){void 0===e&&(e=!1);const r=se(t),i=he(t),n=pe(i);let a="x"===i?r===(e?"end":"start")?"right":"left":"start"===r?"bottom":"top";return o.reference[n]>o.floating[n]&&(a=ye(a)),[a,ye(a)]}(m,n,await(null==c.isRTL?void 0:c.isRTL(s.floating)));if(l!==m)return{reset:{placement:g[0]}};const O=[u[ce(m)],u[x[0]],u[x[1]]],v=[...(null==(r=a.autoPlacement)?void 0:r.overflows)||[],{placement:m,overflows:O}],N=g[b+1];if(N)return{data:{index:b+1,overflows:v},reset:{placement:N}};const S=v.map((t=>{const o=se(t.placement);return[t.placement,o&&f?t.overflows.slice(0,2).reduce(((t,o)=>t+o),0):t.overflows[0],t.overflows]})).sort(((t,o)=>t[1]-o[1])),w=S.filter((t=>t[2].slice(0,se(t[0])?2:3).every((t=>t<=0)))),$=(null==(i=w[0])?void 0:i[0])||S[0][0];return $!==l?{data:{index:b+1,overflows:v},reset:{placement:$}}:{}}}},Oe=function(t){return void 0===t&&(t={}),{name:"shift",options:t,async fn(o){const{x:e,y:r,placement:i}=o,{mainAxis:n=!0,crossAxis:a=!1,limiter:l={fn:t=>{let{x:o,y:e}=t;return{x:o,y:e}}},...c}=le(t,o),s={x:e,y:r},f=await be(o,c),p=de(ce(i)),d=fe(p);let h=s[d],y=s[p];if(n){const t="y"===d?"bottom":"right";h=ae(h+f["y"===d?"top":"left"],h,h-f[t])}if(a){const t="y"===p?"bottom":"right";y=ae(y+f["y"===p?"top":"left"],y,y-f[t])}const g=l.fn({...o,[d]:h,[p]:y});return{...g,data:{x:g.x-e,y:g.y-r}}}}};function ve(t){return we(t)?(t.nodeName||"").toLowerCase():"#document"}function Ne(t){var o;return(null==t||null==(o=t.ownerDocument)?void 0:o.defaultView)||window}function Se(t){var o;return null==(o=(we(t)?t.ownerDocument:t.document)||window.document)?void 0:o.documentElement}function we(t){return t instanceof Node||t instanceof Ne(t).Node}function $e(t){return t instanceof Element||t instanceof Ne(t).Element}function Ce(t){return t instanceof HTMLElement||t instanceof Ne(t).HTMLElement}function Ie(t){return"undefined"!=typeof ShadowRoot&&(t instanceof ShadowRoot||t instanceof Ne(t).ShadowRoot)}function Re(t){const{overflow:o,overflowX:e,overflowY:r,display:i}=Le(t);return/auto|scroll|overlay|hidden|clip/.test(o+r+e)&&!["inline","contents"].includes(i)}function ke(t){return["table","td","th"].includes(ve(t))}function Ue(t){const o=We(),e=Le(t);return"none"!==e.transform||"none"!==e.perspective||!!e.containerType&&"normal"!==e.containerType||!o&&!!e.backdropFilter&&"none"!==e.backdropFilter||!o&&!!e.filter&&"none"!==e.filter||["transform","perspective","filter"].some((t=>(e.willChange||"").includes(t)))||["paint","layout","strict","content"].some((t=>(e.contain||"").includes(t)))}function We(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function Ee(t){return["html","body","#document"].includes(ve(t))}function Le(t){return Ne(t).getComputedStyle(t)}function Ke(t){return $e(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function Ze(t){if("html"===ve(t))return t;const o=t.assignedSlot||t.parentNode||Ie(t)&&t.host||Se(t);return Ie(o)?o.host:o}function ze(t){const o=Ze(t);return Ee(o)?t.ownerDocument?t.ownerDocument.body:t.body:Ce(o)&&Re(o)?o:ze(o)}function Be(t,o,e){var r;void 0===o&&(o=[]),void 0===e&&(e=!0);const i=ze(t),n=i===(null==(r=t.ownerDocument)?void 0:r.body),a=Ne(i);return n?o.concat(a,a.visualViewport||[],Re(i)?i:[],a.frameElement&&e?Be(a.frameElement):[]):o.concat(i,Be(i,[],e))}function Fe(t){const o=Le(t);let e=parseFloat(o.width)||0,r=parseFloat(o.height)||0;const i=Ce(t),n=i?t.offsetWidth:e,a=i?t.offsetHeight:r,l=ee(e)!==n||ee(r)!==a;return l&&(e=n,r=a),{width:e,height:r,$:l}}function De(t){return $e(t)?t:t.contextElement}function Ae(t){const o=De(t);if(!Ce(o))return re(1);const e=o.getBoundingClientRect(),{width:r,height:i,$:n}=Fe(o);let a=(n?ee(e.width):e.width)/r,l=(n?ee(e.height):e.height)/i;return a&&Number.isFinite(a)||(a=1),l&&Number.isFinite(l)||(l=1),{x:a,y:l}}const He=re(0);function Ge(t){const o=Ne(t);return We()&&o.visualViewport?{x:o.visualViewport.offsetLeft,y:o.visualViewport.offsetTop}:He}function Pe(t,o,e,r){void 0===o&&(o=!1),void 0===e&&(e=!1);const i=t.getBoundingClientRect(),n=De(t);let a=re(1);o&&(r?$e(r)&&(a=Ae(r)):a=Ae(t));const l=function(t,o,e){return void 0===o&&(o=!1),!(!e||o&&e!==Ne(t))&&o}(n,e,r)?Ge(n):re(0);let c=(i.left+l.x)/a.x,s=(i.top+l.y)/a.y,f=i.width/a.x,p=i.height/a.y;if(n){const t=Ne(n),o=r&&$e(r)?Ne(r):r;let e=t.frameElement;for(;e&&r&&o!==t;){const t=Ae(e),o=e.getBoundingClientRect(),r=Le(e),i=o.left+(e.clientLeft+parseFloat(r.paddingLeft))*t.x,n=o.top+(e.clientTop+parseFloat(r.paddingTop))*t.y;c*=t.x,s*=t.y,f*=t.x,p*=t.y,c+=i,s+=n,e=Ne(e).frameElement}}return ge({width:f,height:p,x:c,y:s})}function je(t){return Pe(Se(t)).left+Ke(t).scrollLeft}function Me(t,o,e){let r;if("viewport"===o)r=function(t,o){const e=Ne(t),r=Se(t),i=e.visualViewport;let n=r.clientWidth,a=r.clientHeight,l=0,c=0;if(i){n=i.width,a=i.height;const t=We();(!t||t&&"fixed"===o)&&(l=i.offsetLeft,c=i.offsetTop)}return{width:n,height:a,x:l,y:c}}(t,e);else if("document"===o)r=function(t){const o=Se(t),e=Ke(t),r=t.ownerDocument.body,i=oe(o.scrollWidth,o.clientWidth,r.scrollWidth,r.clientWidth),n=oe(o.scrollHeight,o.clientHeight,r.scrollHeight,r.clientHeight);let a=-e.scrollLeft+je(t);const l=-e.scrollTop;return"rtl"===Le(r).direction&&(a+=oe(o.clientWidth,r.clientWidth)-i),{width:i,height:n,x:a,y:l}}(Se(t));else if($e(o))r=function(t,o){const e=Pe(t,!0,"fixed"===o),r=e.top+t.clientTop,i=e.left+t.clientLeft,n=Ce(t)?Ae(t):re(1);return{width:t.clientWidth*n.x,height:t.clientHeight*n.y,x:i*n.x,y:r*n.y}}(o,e);else{const e=Ge(t);r={...o,x:o.x-e.x,y:o.y-e.y}}return ge(r)}function Te(t,o){const e=Ze(t);return!(e===o||!$e(e)||Ee(e))&&("fixed"===Le(e).position||Te(e,o))}function _e(t,o,e){const r=Ce(o),i=Se(o),n="fixed"===e,a=Pe(t,!0,n,o);let l={scrollLeft:0,scrollTop:0};const c=re(0);if(r||!r&&!n)if(("body"!==ve(o)||Re(i))&&(l=Ke(o)),r){const t=Pe(o,!0,n,o);c.x=t.x+o.clientLeft,c.y=t.y+o.clientTop}else i&&(c.x=je(i));return{x:a.left+l.scrollLeft-c.x,y:a.top+l.scrollTop-c.y,width:a.width,height:a.height}}function Ye(t,o){return Ce(t)&&"fixed"!==Le(t).position?o?o(t):t.offsetParent:null}function Ve(t,o){const e=Ne(t);if(!Ce(t))return e;let r=Ye(t,o);for(;r&&ke(r)&&"static"===Le(r).position;)r=Ye(r,o);return r&&("html"===ve(r)||"body"===ve(r)&&"static"===Le(r).position&&!Ue(r))?e:r||function(t){let o=Ze(t);for(;Ce(o)&&!Ee(o);){if(Ue(o))return o;o=Ze(o)}return null}(t)||e}const Xe={convertOffsetParentRelativeRectToViewportRelativeRect:function(t){let{rect:o,offsetParent:e,strategy:r}=t;const i=Ce(e),n=Se(e);if(e===n)return o;let a={scrollLeft:0,scrollTop:0},l=re(1);const c=re(0);if((i||!i&&"fixed"!==r)&&(("body"!==ve(e)||Re(n))&&(a=Ke(e)),Ce(e))){const t=Pe(e);l=Ae(e),c.x=t.x+e.clientLeft,c.y=t.y+e.clientTop}return{width:o.width*l.x,height:o.height*l.y,x:o.x*l.x-a.scrollLeft*l.x+c.x,y:o.y*l.y-a.scrollTop*l.y+c.y}},getDocumentElement:Se,getClippingRect:function(t){let{element:o,boundary:e,rootBoundary:r,strategy:i}=t;const n=[..."clippingAncestors"===e?function(t,o){const e=o.get(t);if(e)return e;let r=Be(t,[],!1).filter((t=>$e(t)&&"body"!==ve(t))),i=null;const n="fixed"===Le(t).position;let a=n?Ze(t):t;for(;$e(a)&&!Ee(a);){const o=Le(a),e=Ue(a);e||"fixed"!==o.position||(i=null),(n?!e&&!i:!e&&"static"===o.position&&i&&["absolute","fixed"].includes(i.position)||Re(a)&&!e&&Te(t,a))?r=r.filter((t=>t!==a)):i=o,a=Ze(a)}return o.set(t,r),r}(o,this._c):[].concat(e),r],a=n[0],l=n.reduce(((t,e)=>{const r=Me(o,e,i);return t.top=oe(r.top,t.top),t.right=te(r.right,t.right),t.bottom=te(r.bottom,t.bottom),t.left=oe(r.left,t.left),t}),Me(o,a,i));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}},getOffsetParent:Ve,getElementRects:async function(t){let{reference:o,floating:e,strategy:r}=t;const i=this.getOffsetParent||Ve,n=this.getDimensions;return{reference:_e(o,await i(e),r),floating:{x:0,y:0,...await n(e)}}},getClientRects:function(t){return Array.from(t.getClientRects())},getDimensions:function(t){return Fe(t)},getScale:Ae,isElement:$e,isRTL:function(t){return"rtl"===Le(t).direction}},qe=(t,o,e)=>{const r=new Map,i={platform:Xe,...e},n={...i.platform,_c:r};return(async(t,o,e)=>{const{placement:r="bottom",strategy:i="absolute",middleware:n=[],platform:a}=e,l=n.filter(Boolean),c=await(null==a.isRTL?void 0:a.isRTL(o));let s=await a.getElementRects({reference:t,floating:o,strategy:i}),{x:f,y:p}=ue(s,r,c),d=r,h={},y=0;for(let e=0;e<l.length;e++){const{name:n,fn:g}=l[e],{x:u,y:b,data:m,reset:x}=await g({x:f,y:p,initialPlacement:r,placement:d,strategy:i,middlewareData:h,rects:s,platform:a,elements:{reference:t,floating:o}});f=null!=u?u:f,p=null!=b?b:p,h={...h,[n]:{...h[n],...m}},x&&y<=50&&(y++,"object"==typeof x&&(x.placement&&(d=x.placement),x.rects&&(s=!0===x.rects?await a.getElementRects({reference:t,floating:o,strategy:i}):x.rects),({x:f,y:p}=ue(s,d,c))),e=-1)}return{x:f,y:p,placement:d,strategy:i,middlewareData:h}})(t,o,{...i,platform:n})};function Je(t){return function(t){for(let o=t;o;o=Qe(o))if(o instanceof Element&&"none"===getComputedStyle(o).display)return null;for(let o=Qe(t);o;o=Qe(o)){if(!(o instanceof Element))continue;const t=getComputedStyle(o);if("contents"!==t.display){if("static"!==t.position||"none"!==t.filter)return o;if("BODY"===o.tagName)return o}}return null}(t)}function Qe(t){return t.assignedSlot?t.assignedSlot:t.parentNode instanceof ShadowRoot?t.parentNode.host:t.parentNode}var tr,or,er,rr=function(t,o,e,r){for(var i,n=arguments.length,a=n<3?o:null===r?r=Object.getOwnPropertyDescriptor(o,e):r,l=t.length-1;l>=0;l--)(i=t[l])&&(a=(n<3?i(a):n>3?i(o,e,a):i(o,e))||a);return n>3&&a&&Object.defineProperty(o,e,a),a};class ir extends o.FtLitElement{constructor(){super(...arguments),this.text="",this.manual=!1,this.inline=!1,this.delay=500,this.position="bottom",this.visible=!1,this.validPositions=new Set(["top","bottom","left","right"]),this.hideDebounce=new o.Debouncer,this.revealDebouncer=new o.Debouncer}get validPosition(){return this.validPositions.has(this.position)?this.position:"bottom"}render(){return e.html`
561
+ `,Jo=["start","end"],Qo=["top","right","bottom","left"].reduce(((t,o)=>t.concat(o,o+"-"+Jo[0],o+"-"+Jo[1])),[]),te=Math.min,oe=Math.max,ee=Math.round,re=t=>({x:t,y:t}),ie={left:"right",right:"left",bottom:"top",top:"bottom"},ne={start:"end",end:"start"};function ae(t,o,e){return oe(t,te(o,e))}function le(t,o){return"function"==typeof t?t(o):t}function ce(t){return t.split("-")[0]}function se(t){return t.split("-")[1]}function fe(t){return"x"===t?"y":"x"}function pe(t){return"y"===t?"height":"width"}function de(t){return["top","bottom"].includes(ce(t))?"y":"x"}function he(t){return fe(de(t))}function ye(t){return t.replace(/left|right|bottom|top/g,(t=>ie[t]))}function ge(t){return{...t,top:t.y,left:t.x,right:t.x+t.width,bottom:t.y+t.height}}function ue(t,o,e){let{reference:r,floating:i}=t;const n=de(o),a=he(o),l=pe(a),c=ce(o),s="y"===n,f=r.x+r.width/2-i.width/2,p=r.y+r.height/2-i.height/2,d=r[l]/2-i[l]/2;let h;switch(c){case"top":h={x:f,y:r.y-i.height};break;case"bottom":h={x:f,y:r.y+r.height};break;case"right":h={x:r.x+r.width,y:p};break;case"left":h={x:r.x-i.width,y:p};break;default:h={x:r.x,y:r.y}}switch(se(o)){case"start":h[a]-=d*(e&&s?-1:1);break;case"end":h[a]+=d*(e&&s?-1:1)}return h}async function be(t,o){var e;void 0===o&&(o={});const{x:r,y:i,platform:n,rects:a,elements:l,strategy:c}=t,{boundary:s="clippingAncestors",rootBoundary:f="viewport",elementContext:p="floating",altBoundary:d=!1,padding:h=0}=le(o,t),y=function(t){return"number"!=typeof t?function(t){return{top:0,right:0,bottom:0,left:0,...t}}(t):{top:t,right:t,bottom:t,left:t}}(h),g=l[d?"floating"===p?"reference":"floating":p],u=ge(await n.getClippingRect({element:null==(e=await(null==n.isElement?void 0:n.isElement(g)))||e?g:g.contextElement||await(null==n.getDocumentElement?void 0:n.getDocumentElement(l.floating)),boundary:s,rootBoundary:f,strategy:c})),b="floating"===p?{...a.floating,x:r,y:i}:a.reference,m=await(null==n.getOffsetParent?void 0:n.getOffsetParent(l.floating)),x=await(null==n.isElement?void 0:n.isElement(m))&&await(null==n.getScale?void 0:n.getScale(m))||{x:1,y:1},O=ge(n.convertOffsetParentRelativeRectToViewportRelativeRect?await n.convertOffsetParentRelativeRectToViewportRelativeRect({rect:b,offsetParent:m,strategy:c}):b);return{top:(u.top-O.top+y.top)/x.y,bottom:(O.bottom-u.bottom+y.bottom)/x.y,left:(u.left-O.left+y.left)/x.x,right:(O.right-u.right+y.right)/x.x}}function me(t,o,e){return(t?[...e.filter((o=>se(o)===t)),...e.filter((o=>se(o)!==t))]:e.filter((t=>ce(t)===t))).filter((e=>!t||(se(e)===t||!!o&&function(t){return t.replace(/start|end/g,(t=>ne[t]))}(e)!==e)))}const xe=function(t){return void 0===t&&(t={}),{name:"autoPlacement",options:t,async fn(o){var e,r,i;const{rects:n,middlewareData:a,placement:l,platform:c,elements:s}=o,{crossAxis:f=!1,alignment:p,allowedPlacements:d=Qo,autoAlignment:h=!0,...y}=le(t,o),g=void 0!==p||d===Qo?me(p||null,h,d):d,u=await be(o,y),b=(null==(e=a.autoPlacement)?void 0:e.index)||0,m=g[b];if(null==m)return{};const x=function(t,o,e){void 0===e&&(e=!1);const r=se(t),i=he(t),n=pe(i);let a="x"===i?r===(e?"end":"start")?"right":"left":"start"===r?"bottom":"top";return o.reference[n]>o.floating[n]&&(a=ye(a)),[a,ye(a)]}(m,n,await(null==c.isRTL?void 0:c.isRTL(s.floating)));if(l!==m)return{reset:{placement:g[0]}};const O=[u[ce(m)],u[x[0]],u[x[1]]],v=[...(null==(r=a.autoPlacement)?void 0:r.overflows)||[],{placement:m,overflows:O}],N=g[b+1];if(N)return{data:{index:b+1,overflows:v},reset:{placement:N}};const S=v.map((t=>{const o=se(t.placement);return[t.placement,o&&f?t.overflows.slice(0,2).reduce(((t,o)=>t+o),0):t.overflows[0],t.overflows]})).sort(((t,o)=>t[1]-o[1])),w=S.filter((t=>t[2].slice(0,se(t[0])?2:3).every((t=>t<=0)))),$=(null==(i=w[0])?void 0:i[0])||S[0][0];return $!==l?{data:{index:b+1,overflows:v},reset:{placement:$}}:{}}}};function Oe(t){return Se(t)?(t.nodeName||"").toLowerCase():"#document"}function ve(t){var o;return(null==t||null==(o=t.ownerDocument)?void 0:o.defaultView)||window}function Ne(t){var o;return null==(o=(Se(t)?t.ownerDocument:t.document)||window.document)?void 0:o.documentElement}function Se(t){return t instanceof Node||t instanceof ve(t).Node}function we(t){return t instanceof Element||t instanceof ve(t).Element}function $e(t){return t instanceof HTMLElement||t instanceof ve(t).HTMLElement}function Ce(t){return"undefined"!=typeof ShadowRoot&&(t instanceof ShadowRoot||t instanceof ve(t).ShadowRoot)}function Ie(t){const{overflow:o,overflowX:e,overflowY:r,display:i}=Ee(t);return/auto|scroll|overlay|hidden|clip/.test(o+r+e)&&!["inline","contents"].includes(i)}function Re(t){return["table","td","th"].includes(Oe(t))}function ke(t){const o=Ue(),e=Ee(t);return"none"!==e.transform||"none"!==e.perspective||!!e.containerType&&"normal"!==e.containerType||!o&&!!e.backdropFilter&&"none"!==e.backdropFilter||!o&&!!e.filter&&"none"!==e.filter||["transform","perspective","filter"].some((t=>(e.willChange||"").includes(t)))||["paint","layout","strict","content"].some((t=>(e.contain||"").includes(t)))}function Ue(){return!("undefined"==typeof CSS||!CSS.supports)&&CSS.supports("-webkit-backdrop-filter","none")}function We(t){return["html","body","#document"].includes(Oe(t))}function Ee(t){return ve(t).getComputedStyle(t)}function Le(t){return we(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.pageXOffset,scrollTop:t.pageYOffset}}function Ke(t){if("html"===Oe(t))return t;const o=t.assignedSlot||t.parentNode||Ce(t)&&t.host||Ne(t);return Ce(o)?o.host:o}function Ze(t){const o=Ke(t);return We(o)?t.ownerDocument?t.ownerDocument.body:t.body:$e(o)&&Ie(o)?o:Ze(o)}function ze(t,o,e){var r;void 0===o&&(o=[]),void 0===e&&(e=!0);const i=Ze(t),n=i===(null==(r=t.ownerDocument)?void 0:r.body),a=ve(i);return n?o.concat(a,a.visualViewport||[],Ie(i)?i:[],a.frameElement&&e?ze(a.frameElement):[]):o.concat(i,ze(i,[],e))}function Be(t){const o=Ee(t);let e=parseFloat(o.width)||0,r=parseFloat(o.height)||0;const i=$e(t),n=i?t.offsetWidth:e,a=i?t.offsetHeight:r,l=ee(e)!==n||ee(r)!==a;return l&&(e=n,r=a),{width:e,height:r,$:l}}function Fe(t){return we(t)?t:t.contextElement}function De(t){const o=Fe(t);if(!$e(o))return re(1);const e=o.getBoundingClientRect(),{width:r,height:i,$:n}=Be(o);let a=(n?ee(e.width):e.width)/r,l=(n?ee(e.height):e.height)/i;return a&&Number.isFinite(a)||(a=1),l&&Number.isFinite(l)||(l=1),{x:a,y:l}}const Ae=re(0);function He(t){const o=ve(t);return Ue()&&o.visualViewport?{x:o.visualViewport.offsetLeft,y:o.visualViewport.offsetTop}:Ae}function Ge(t,o,e,r){void 0===o&&(o=!1),void 0===e&&(e=!1);const i=t.getBoundingClientRect(),n=Fe(t);let a=re(1);o&&(r?we(r)&&(a=De(r)):a=De(t));const l=function(t,o,e){return void 0===o&&(o=!1),!(!e||o&&e!==ve(t))&&o}(n,e,r)?He(n):re(0);let c=(i.left+l.x)/a.x,s=(i.top+l.y)/a.y,f=i.width/a.x,p=i.height/a.y;if(n){const t=ve(n),o=r&&we(r)?ve(r):r;let e=t.frameElement;for(;e&&r&&o!==t;){const t=De(e),o=e.getBoundingClientRect(),r=Ee(e),i=o.left+(e.clientLeft+parseFloat(r.paddingLeft))*t.x,n=o.top+(e.clientTop+parseFloat(r.paddingTop))*t.y;c*=t.x,s*=t.y,f*=t.x,p*=t.y,c+=i,s+=n,e=ve(e).frameElement}}return ge({width:f,height:p,x:c,y:s})}function Pe(t){return Ge(Ne(t)).left+Le(t).scrollLeft}function je(t,o,e){let r;if("viewport"===o)r=function(t,o){const e=ve(t),r=Ne(t),i=e.visualViewport;let n=r.clientWidth,a=r.clientHeight,l=0,c=0;if(i){n=i.width,a=i.height;const t=Ue();(!t||t&&"fixed"===o)&&(l=i.offsetLeft,c=i.offsetTop)}return{width:n,height:a,x:l,y:c}}(t,e);else if("document"===o)r=function(t){const o=Ne(t),e=Le(t),r=t.ownerDocument.body,i=oe(o.scrollWidth,o.clientWidth,r.scrollWidth,r.clientWidth),n=oe(o.scrollHeight,o.clientHeight,r.scrollHeight,r.clientHeight);let a=-e.scrollLeft+Pe(t);const l=-e.scrollTop;return"rtl"===Ee(r).direction&&(a+=oe(o.clientWidth,r.clientWidth)-i),{width:i,height:n,x:a,y:l}}(Ne(t));else if(we(o))r=function(t,o){const e=Ge(t,!0,"fixed"===o),r=e.top+t.clientTop,i=e.left+t.clientLeft,n=$e(t)?De(t):re(1);return{width:t.clientWidth*n.x,height:t.clientHeight*n.y,x:i*n.x,y:r*n.y}}(o,e);else{const e=He(t);r={...o,x:o.x-e.x,y:o.y-e.y}}return ge(r)}function Me(t,o){const e=Ke(t);return!(e===o||!we(e)||We(e))&&("fixed"===Ee(e).position||Me(e,o))}function Te(t,o,e){const r=$e(o),i=Ne(o),n="fixed"===e,a=Ge(t,!0,n,o);let l={scrollLeft:0,scrollTop:0};const c=re(0);if(r||!r&&!n)if(("body"!==Oe(o)||Ie(i))&&(l=Le(o)),r){const t=Ge(o,!0,n,o);c.x=t.x+o.clientLeft,c.y=t.y+o.clientTop}else i&&(c.x=Pe(i));return{x:a.left+l.scrollLeft-c.x,y:a.top+l.scrollTop-c.y,width:a.width,height:a.height}}function _e(t,o){return $e(t)&&"fixed"!==Ee(t).position?o?o(t):t.offsetParent:null}function Ye(t,o){const e=ve(t);if(!$e(t))return e;let r=_e(t,o);for(;r&&Re(r)&&"static"===Ee(r).position;)r=_e(r,o);return r&&("html"===Oe(r)||"body"===Oe(r)&&"static"===Ee(r).position&&!ke(r))?e:r||function(t){let o=Ke(t);for(;$e(o)&&!We(o);){if(ke(o))return o;o=Ke(o)}return null}(t)||e}const Ve={convertOffsetParentRelativeRectToViewportRelativeRect:function(t){let{rect:o,offsetParent:e,strategy:r}=t;const i=$e(e),n=Ne(e);if(e===n)return o;let a={scrollLeft:0,scrollTop:0},l=re(1);const c=re(0);if((i||!i&&"fixed"!==r)&&(("body"!==Oe(e)||Ie(n))&&(a=Le(e)),$e(e))){const t=Ge(e);l=De(e),c.x=t.x+e.clientLeft,c.y=t.y+e.clientTop}return{width:o.width*l.x,height:o.height*l.y,x:o.x*l.x-a.scrollLeft*l.x+c.x,y:o.y*l.y-a.scrollTop*l.y+c.y}},getDocumentElement:Ne,getClippingRect:function(t){let{element:o,boundary:e,rootBoundary:r,strategy:i}=t;const n=[..."clippingAncestors"===e?function(t,o){const e=o.get(t);if(e)return e;let r=ze(t,[],!1).filter((t=>we(t)&&"body"!==Oe(t))),i=null;const n="fixed"===Ee(t).position;let a=n?Ke(t):t;for(;we(a)&&!We(a);){const o=Ee(a),e=ke(a);e||"fixed"!==o.position||(i=null),(n?!e&&!i:!e&&"static"===o.position&&i&&["absolute","fixed"].includes(i.position)||Ie(a)&&!e&&Me(t,a))?r=r.filter((t=>t!==a)):i=o,a=Ke(a)}return o.set(t,r),r}(o,this._c):[].concat(e),r],a=n[0],l=n.reduce(((t,e)=>{const r=je(o,e,i);return t.top=oe(r.top,t.top),t.right=te(r.right,t.right),t.bottom=te(r.bottom,t.bottom),t.left=oe(r.left,t.left),t}),je(o,a,i));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}},getOffsetParent:Ye,getElementRects:async function(t){let{reference:o,floating:e,strategy:r}=t;const i=this.getOffsetParent||Ye,n=this.getDimensions;return{reference:Te(o,await i(e),r),floating:{x:0,y:0,...await n(e)}}},getClientRects:function(t){return Array.from(t.getClientRects())},getDimensions:function(t){return Be(t)},getScale:De,isElement:we,isRTL:function(t){return"rtl"===Ee(t).direction}},Xe=(t,o,e)=>{const r=new Map,i={platform:Ve,...e},n={...i.platform,_c:r};return(async(t,o,e)=>{const{placement:r="bottom",strategy:i="absolute",middleware:n=[],platform:a}=e,l=n.filter(Boolean),c=await(null==a.isRTL?void 0:a.isRTL(o));let s=await a.getElementRects({reference:t,floating:o,strategy:i}),{x:f,y:p}=ue(s,r,c),d=r,h={},y=0;for(let e=0;e<l.length;e++){const{name:n,fn:g}=l[e],{x:u,y:b,data:m,reset:x}=await g({x:f,y:p,initialPlacement:r,placement:d,strategy:i,middlewareData:h,rects:s,platform:a,elements:{reference:t,floating:o}});f=null!=u?u:f,p=null!=b?b:p,h={...h,[n]:{...h[n],...m}},x&&y<=50&&(y++,"object"==typeof x&&(x.placement&&(d=x.placement),x.rects&&(s=!0===x.rects?await a.getElementRects({reference:t,floating:o,strategy:i}):x.rects),({x:f,y:p}=ue(s,d,c))),e=-1)}return{x:f,y:p,placement:d,strategy:i,middlewareData:h}})(t,o,{...i,platform:n})};function qe(t){return function(t){for(let o=t;o;o=Je(o))if(o instanceof Element&&"none"===getComputedStyle(o).display)return null;for(let o=Je(t);o;o=Je(o)){if(!(o instanceof Element))continue;const t=getComputedStyle(o);if("contents"!==t.display){if("static"!==t.position||"none"!==t.filter)return o;if("BODY"===o.tagName)return o}}return null}(t)}function Je(t){return t.assignedSlot?t.assignedSlot:t.parentNode instanceof ShadowRoot?t.parentNode.host:t.parentNode}async function Qe(t,o,e){return Xe(t,o,{platform:{...Ve,getOffsetParent:t=>Ve.getOffsetParent(t,qe)},middleware:[(r={crossAxis:!0},void 0===r&&(r={}),{name:"shift",options:r,async fn(t){const{x:o,y:e,placement:i}=t,{mainAxis:n=!0,crossAxis:a=!1,limiter:l={fn:t=>{let{x:o,y:e}=t;return{x:o,y:e}}},...c}=le(r,t),s={x:o,y:e},f=await be(t,c),p=de(ce(i)),d=fe(p);let h=s[d],y=s[p];if(n){const t="y"===d?"bottom":"right";h=ae(h+f["y"===d?"top":"left"],h,h-f[t])}if(a){const t="y"===p?"bottom":"right";y=ae(y+f["y"===p?"top":"left"],y,y-f[t])}const g=l.fn({...t,[d]:h,[p]:y});return{...g,data:{x:g.x-o,y:g.y-e}}}}),xe({allowedPlacements:[e]})]});var r}var tr,or,er,rr=function(t,o,e,r){for(var i,n=arguments.length,a=n<3?o:null===r?r=Object.getOwnPropertyDescriptor(o,e):r,l=t.length-1;l>=0;l--)(i=t[l])&&(a=(n<3?i(a):n>3?i(o,e,a):i(o,e))||a);return n>3&&a&&Object.defineProperty(o,e,a),a};class ir extends o.FtLitElement{constructor(){super(...arguments),this.text="",this.manual=!1,this.inline=!1,this.delay=500,this.position="bottom",this.visible=!1,this.validPositions=new Set(["top","bottom","left","right"]),this.hideDebounce=new o.Debouncer,this.revealDebouncer=new o.Debouncer}get validPosition(){return this.validPositions.has(this.position)?this.position:"bottom"}render(){return e.html`
562
562
  <div part="container"
563
563
  class="ft-tooltip--container ${this.inline?"ft-tooltip--inline":""}"
564
564
  @mouseenter=${this.onHover}
@@ -576,7 +576,7 @@ const Bo=Symbol.for(""),Fo=t=>{if(t?.r===Bo)return t?._$litStatic$},Do=t=>({_$li
576
576
  </div>
577
577
  </div>
578
578
  </div>
579
- `}updated(t){t.has("visible")&&this.visible&&this.resetTooltipContent(),super.updated(t)}contentAvailableCallback(t){super.contentAvailableCallback(t),["visible","text"].some((o=>t.has(o)))&&this.visible&&this.positionTooltip()}async show(t){this.visible=!0,null!=t&&await this.hideDebounce.run((()=>{this.hide()}),t)}hide(){this.visible=!1}toggle(){this.visible=!this.visible}get slottedElement(){var t;return(null!==(t=this.slotNodes)&&void 0!==t?t:[]).filter((t=>t.nodeType==Node.ELEMENT_NODE))[0]}resetTooltipContent(){if(this.tooltip&&this.tooltipContent){const t=this.tooltipContent.style;switch(t.transition="none",this.validPosition){case"top":t.top=this.tooltip.clientHeight+"px",t.left="0";break;case"bottom":t.top=-this.tooltip.clientHeight+"px",t.left="0";break;case"left":t.top="0",t.left=this.tooltip.clientWidth+"px";break;case"right":t.top="0",t.left=-this.tooltip.clientWidth+"px"}}}positionTooltip(){this.resetTooltipContent(),this.tooltip&&this.slottedElement&&(this.tooltip.style.left="",this.tooltip.style.top="",qe(this.slottedElement,this.tooltip,{platform:{...Xe,getOffsetParent:t=>Xe.getOffsetParent(t,Je)},middleware:[Oe({crossAxis:!0}),xe({allowedPlacements:[this.position]})]}).then((({x:t,y:o})=>{this.tooltip&&(this.tooltip.style.left=`${t}px`,this.tooltip.style.top=`${o}px`)}))),this.revealDebouncer.run((()=>{this.tooltipContent&&(this.tooltipContent.style.transition="top var(--ft-transition-duration, 250ms), left var(--ft-transition-duration, 250ms)",this.tooltipContent.style.top="0",this.tooltipContent.style.left="0")}),this.manual?0:this.delay)}onTouch(){this.manual||(this.show(),setTimeout((()=>window.addEventListener("touchstart",(t=>{t.composedPath().includes(this.container)||this.onOut()}),{once:!0})),100))}onHover(){this.manual||this.show()}onOut(){this.manual||(this.revealDebouncer.cancel(),this.hide())}onClick(){this.manual||(this.revealDebouncer.cancel(),this.hide())}correctOutOfWindowPixels(t,o){return Math.max(t,Math.min(0,-o))}}ir.elementDefinitions={"ft-typography":jo},ir.styles=qo,rr([r.property()],ir.prototype,"text",void 0),rr([r.property({type:Boolean})],ir.prototype,"manual",void 0),rr([r.property({type:Boolean})],ir.prototype,"inline",void 0),rr([r.property({type:Number})],ir.prototype,"delay",void 0),rr([r.property()],ir.prototype,"position",void 0),rr([r.queryAssignedNodes()],ir.prototype,"slotNodes",void 0),rr([r.query(".ft-tooltip--container")],ir.prototype,"container",void 0),rr([r.query(".ft-tooltip")],ir.prototype,"tooltip",void 0),rr([r.query(".ft-tooltip--content")],ir.prototype,"tooltipContent",void 0),rr([r.state()],ir.prototype,"visible",void 0),rr([r.eventOptions({passive:!0})],ir.prototype,"onTouch",null),rr([r.eventOptions({passive:!0})],ir.prototype,"onHover",null),rr([r.eventOptions({passive:!0})],ir.prototype,"onOut",null),rr([r.eventOptions({passive:!0})],ir.prototype,"onClick",null),o.customElement("ft-tooltip")(ir),function(t){t.THUMBS_DOWN="&#xe94d;",t.THUMBS_DOWN_PLAIN="&#xe94e;",t.THUMBS_UP="&#xe94f;",t.THUMBS_UP_PLAIN="&#xe950;",t.STAR="&#xe94c;",t.STAR_PLAIN="&#xe900;",t.DESKTOP="&#xe95e;",t.LIFE_RING="&#xe975;",t.GLOBE="&#xe976;",t.PIGGY_BANK="&#xe977;",t.TABLET_LANDSCAPE="&#xe95f;",t.TABLET_PORTRAIT="&#xe960;",t.MOBILE_LANDSCAPE="&#xe961;",t.MOBILE_PORTRAIT="&#xe962;",t.ARROW_RIGHT_TO_LINE="&#xe95d;",t.THIN_ARROW_UP="&#xe95c;",t.CONTEXTUAL="&#xe95b;",t.CHART_SIMPLE="&#xe968;",t.BARS_PROGRESS="&#xe969;",t.LINE_CHART="&#xe96c;",t.STACKED_CHART="&#xe96d;",t.BOOK_OPEN_GEAR="&#xe96a;",t.BOOK_OPEN_GEAR_SLASH="&#xe96b;",t.DIAGRAM_SUNBURST="&#xe963;",t.DIAGRAM_SANKEY="&#xe964;",t.UNSTRUCTURED_DOC="&#xe95a;",t.RESET="&#xe958;",t.THIN_ARROW_LEFT="&#xe956;",t.THIN_ARROW_RIGHT="&#xe957;",t.MY_COLLECTIONS="&#xe955;",t.OFFLINE_SETTINGS="&#xe954;",t.MY_LIBRARY="&#xe959;",t.RATE_PLAIN="&#xe952;",t.RATE="&#xe953;",t.FEEDBACK_PLAIN="&#xe951;",t.PAUSE="&#xe949;",t.PLAY="&#xe94a;",t.RELATIVES_PLAIN="&#xe947;",t.RELATIVES="&#xe948;",t.SHORTCUT_MENU="&#xe946;",t.PRINT="&#xe944;",t.DEFAULT_ROLES="&#xe945;",t.ACCOUNT_SETTINGS="&#xe943;",t.ONLINE="&#xe941;",t.OFFLINE="&#xe816;",t.UPLOAD="&#xe940;",t.BOOK_PLAIN="&#xe93f;",t.SYNC="&#xe93d;",t.SHARED_PBK="&#xe931;",t.COLLECTIONS="&#xe92a;",t.SEARCH_IN_PUBLICATION="&#xe92f;",t.BOOKS="&#xe806;",t.LOCKER="&#xe93b;",t.ARROW_DOWN="&#xe92b;",t.ARROW_LEFT="&#xe92c;",t.ARROW_RIGHT="&#xe92d;",t.ARROW_UP="&#xe92e;",t.SAVE="&#xe93a;",t.MAILS_AND_NOTIFICATIONS="&#xe939;",t.DOT="&#xe936;",t.MINUS="&#xe937;",t.PLUS="&#xe938;",t.FILTERS="&#xe935;",t.STRIPE_ARROW_RIGHT="&#xe934;",t.STRIPE_ARROW_LEFT="&#xe933;",t.ATTACHMENTS="&#xe932;",t.ADD_BOOKMARK="&#xe804;",t.BOOKMARK="&#xe805;",t.EXPORT="&#xe80f;",t.MENU="&#xe807;",t.TAG="&#xe93e;",t.TAG_PLAIN="&#xe942;",t.COPY_TO_CLIPBOARD="&#xe930;",t.COLUMNS="&#xe928;",t.ARTICLE="&#xe927;",t.CLOSE_PLAIN="&#xe925;",t.CHECK_PLAIN="&#xe926;",t.LOGOUT="&#xe923;",t.SIGN_IN="&#xe922;",t.THIN_ARROW="&#xe921;",t.TRIANGLE_BOTTOM="&#xe91d;",t.TRIANGLE_LEFT="&#xe91e;",t.TRIANGLE_RIGHT="&#xe91f;",t.TRIANGLE_TOP="&#xe920;",t.FACET_HAS_DESCENDANT="&#xe91c;",t.MINUS_PLAIN="&#xe91a;",t.PLUS_PLAIN="&#xe91b;",t.INFO="&#xe919;",t.ICON_EXPAND="&#xe917;",t.ICON_COLLAPSE="&#xe918;",t.ADD_TO_PBK="&#xe800;",t.ALERT="&#xe801;",t.ADD_ALERT="&#xe802;",t.BACK_TO_SEARCH="&#xe803;",t.DOWNLOAD="&#xe808;",t.EDIT="&#xe809;",t.FEEDBACK="&#xe80a;",t.MODIFY_PBK="&#xe80c;",t.SCHEDULED="&#xe80d;",t.SEARCH="&#xe80e;",t.SHARE="&#xe80f1;",t.TOC="&#xe810;",t.WRITE_UGC="&#xe811;",t.TRASH="&#xe812;",t.EXTLINK="&#xe814;",t.EXTLINK_LIGHT="&#xe978;",t.CALENDAR="&#xe815;",t.BOOK="&#xe817;",t.DOWNLOAD_PLAIN="&#xe818;",t.CHECK="&#xe819;",t.TOPICS="&#xe901;",t.EYE="&#xf06e;",t.EYE_SLASH="&#xe970;",t.DISC="&#xe902;",t.CIRCLE="&#xe903;",t.SHARED="&#xe904;",t.SORT_UNSORTED="&#xe905;",t.SORT_UP="&#xe906;",t.SORT_DOWN="&#xe907;",t.WORKING="&#xe908;",t.CLOSE="&#xe909;",t.ZOOM_OUT="&#xe90a;",t.ZOOM_IN="&#xe90b;",t.ZOOM_REALSIZE="&#xe90c;",t.ZOOM_FULLSCREEN="&#xe90d;",t.ADMIN_RESTRICTED="&#xe90e;",t.ADMIN_THEME="&#xe911;",t.WARNING="&#xe913;",t.CONTEXT="&#xe914;",t.SEARCH_HOME="&#xe915;",t.STEPS="&#xe916;",t.HOME="&#xe80b;",t.TRANSLATE="&#xe924;",t.USER="&#xe813;",t.ADMIN="&#xe90f;",t.ANALYTICS="&#xe929;",t.ADMIN_KHUB="&#xe910;",t.ADMIN_USERS="&#xe912;",t.ADMIN_INTEGRATION="&#xe93c;",t.ADMIN_PORTAL="&#xe94b;",t.COMMENT_QUESTION="&#xe965;",t.COMMENT_QUESTION_PLAIN="&#xe966;",t.MESSAGE_BOT="&#xe967;",t.PIP="&#xe973;",t.PIP_WIDE="&#xe974;",t.EXPAND_WIDE="&#xe972;",t.X_MARK="&#xe971;",t.CLONE="&#xe979;",t.CLONE_LINK_SIMPLE="&#xe97a;"}(tr||(tr={})),function(t){t.UNKNOWN="&#xe90a;",t.ABW="&#xe900;",t.AUDIO="&#xe901;",t.AVI="&#xe902;",t.CHM="&#xe904;",t.CODE="&#xe905;",t.CSV="&#xe903;",t.DITA="&#xe906;",t.EPUB="&#xe907;",t.EXCEL="&#xe908;",t.FLAC="&#xe909;",t.GIF="&#xe90b;",t.GZIP="&#xe90c;",t.HTML="&#xe90d;",t.IMAGE="&#xe90e;",t.JPEG="&#xe90f;",t.JSON="&#xe910;",t.M4A="&#xe911;",t.MOV="&#xe912;",t.MP3="&#xe913;",t.MP4="&#xe914;",t.OGG="&#xe915;",t.PDF="&#xe916;",t.PNG="&#xe917;",t.POWERPOINT="&#xe918;",t.RAR="&#xe91a;",t.STP="&#xe91b;",t.TEXT="&#xe91c;",t.VIDEO="&#xe91e;",t.WAV="&#xe91f;",t.WMA="&#xe920;",t.WORD="&#xe921;",t.XML="&#xe922;",t.YAML="&#xe919;",t.ZIP="&#xe923;"}(or||(or={})),new Map([...["abw"].map((t=>[t,or.ABW])),...["3gp","act","aiff","aac","amr","au","awb","dct","dss","dvf","gsm","iklax","ivs","mmf","mpc","msv","opus","ra","rm","raw","sln","tta","vox","wv"].map((t=>[t,or.AUDIO])),...["avi"].map((t=>[t,or.AVI])),...["chm","xhs"].map((t=>[t,or.CHM])),...["java","py","php","php3","php4","php5","js","javascript","rb","rbw","c","cpp","cxx","h","hh","hpp","hxx","sh","bash","zsh","tcsh","ksh","csh","vb","scala","pl","prl","perl","groovy","ceylon","aspx","jsp","scpt","applescript","bas","bat","lua","jsp","mk","cmake","css","sass","less","m","mm","xcodeproj"].map((t=>[t,or.CODE])),...["csv"].map((t=>[t,or.CSV])),...["dita","ditamap","ditaval"].map((t=>[t,or.DITA])),...["epub"].map((t=>[t,or.EPUB])),...["xls","xlt","xlm","xlsx","xlsm","xltx","xltm","xlsb","xla","xlam","xll","xlw"].map((t=>[t,or.EXCEL])),...["flac"].map((t=>[t,or.FLAC])),...["gif"].map((t=>[t,or.GIF])),...["gzip","x-gzip","giz","gz","tgz"].map((t=>[t,or.GZIP])),...["html","htm","xhtml"].map((t=>[t,or.HTML])),...["ai","vml","xps","img","cpt","psd","psp","xcf","svg","svg+xml","bmp","bpg","ppm","pgm","pbm","pnm","rif","tif","tiff","webp","wmf"].map((t=>[t,or.IMAGE])),...["jpeg","jpg","jpe"].map((t=>[t,or.JPEG])),...["json"].map((t=>[t,or.JSON])),...["m4a","m4p"].map((t=>[t,or.M4A])),...["mov","qt"].map((t=>[t,or.MOV])),...["mp3"].map((t=>[t,or.MP3])),...["mp4","m4v"].map((t=>[t,or.MP4])),...["ogg","oga"].map((t=>[t,or.OGG])),...["pdf","ps"].map((t=>[t,or.PDF])),...["png"].map((t=>[t,or.PNG])),...["ppt","pot","pps","pptx","pptm","potx","potm","ppam","ppsx","ppsm","sldx","sldm"].map((t=>[t,or.POWERPOINT])),...["rar"].map((t=>[t,or.RAR])),...["stp"].map((t=>[t,or.STP])),...["txt","rtf","md","mdown"].map((t=>[t,or.TEXT])),...["webm","mkv","flv","vob","ogv","ogg","drc","mng","wmv","yuv","rm","rmvb","asf","mpg","mp2","mpeg","mpe","mpv","m2v","svi","3gp","3g2","mxf","roq","nsv"].map((t=>[t,or.VIDEO])),...["wav"].map((t=>[t,or.WAV])),...["wma"].map((t=>[t,or.WMA])),...["doc","dot","docx","docm","dotx","dotm","docb"].map((t=>[t,or.WORD])),...["xml","xsl","rdf"].map((t=>[t,or.XML])),...["yaml","yml","x-yaml"].map((t=>[t,or.YAML])),...["zip"].map((t=>[t,or.ZIP]))]),or.ABW,or.AUDIO,or.AVI,or.CHM,or.CODE,or.CSV,or.DITA,or.EPUB,or.EXCEL,or.FLAC,or.GIF,or.GZIP,or.HTML,or.IMAGE,or.JPEG,or.JSON,or.M4A,or.MOV,or.MP3,or.MP4,or.OGG,or.PDF,or.PNG,or.POWERPOINT,or.RAR,or.STP,or.TEXT,or.UNKNOWN,or.VIDEO,or.WAV,or.WMA,or.WORD,or.XML,or.YAML,or.ZIP,function(t){t.fluid_topics="fluid-topics",t.file_format="file-format",t.material="material"}(er||(er={}));var nr=function(t,o,e,r){for(var i,n=arguments.length,a=n<3?o:null===r?r=Object.getOwnPropertyDescriptor(o,e):r,l=t.length-1;l>=0;l--)(i=t[l])&&(a=(n<3?i(a):n>3?i(o,e,a):i(o,e))||a);return n>3&&a&&Object.defineProperty(o,e,a),a};class ar extends o.FtLitElement{constructor(){super(...arguments),this.resolvedIcon=e.nothing}render(){const t=this.variant&&Object.values(er).includes(this.variant)?this.variant:er.fluid_topics,o=t!==er.material||!!this.value;return e.html`
579
+ `}updated(t){t.has("visible")&&this.visible&&this.resetTooltipContent(),super.updated(t)}contentAvailableCallback(t){super.contentAvailableCallback(t),["visible","text"].some((o=>t.has(o)))&&this.visible&&this.positionTooltip()}async show(t){this.visible=!0,null!=t&&await this.hideDebounce.run((()=>{this.hide()}),t)}hide(){this.visible=!1}toggle(){this.visible=!this.visible}get slottedElement(){var t;return(null!==(t=this.slotNodes)&&void 0!==t?t:[]).filter((t=>t.nodeType==Node.ELEMENT_NODE))[0]}resetTooltipContent(){if(this.tooltip&&this.tooltipContent){const t=this.tooltipContent.style;switch(t.transition="none",this.validPosition){case"top":t.top=this.tooltip.clientHeight+"px",t.left="0";break;case"bottom":t.top=-this.tooltip.clientHeight+"px",t.left="0";break;case"left":t.top="0",t.left=this.tooltip.clientWidth+"px";break;case"right":t.top="0",t.left=-this.tooltip.clientWidth+"px"}}}positionTooltip(){this.resetTooltipContent(),this.tooltip&&this.slottedElement&&(this.tooltip.style.left="",this.tooltip.style.top="",Qe(this.slottedElement,this.tooltip,this.position).then((({x:t,y:o})=>{this.tooltip&&(this.tooltip.style.left=`${t}px`,this.tooltip.style.top=`${o}px`)}))),this.revealDebouncer.run((()=>{this.tooltipContent&&(this.tooltipContent.style.transition="top var(--ft-transition-duration, 250ms), left var(--ft-transition-duration, 250ms)",this.tooltipContent.style.top="0",this.tooltipContent.style.left="0")}),this.manual?0:this.delay)}onTouch(){this.manual||(this.show(),setTimeout((()=>window.addEventListener("touchstart",(t=>{t.composedPath().includes(this.container)||this.onOut()}),{once:!0})),100))}onHover(){this.manual||this.show()}onOut(){this.manual||(this.revealDebouncer.cancel(),this.hide())}onClick(){this.manual||(this.revealDebouncer.cancel(),this.hide())}correctOutOfWindowPixels(t,o){return Math.max(t,Math.min(0,-o))}}ir.elementDefinitions={"ft-typography":jo},ir.styles=qo,rr([r.property()],ir.prototype,"text",void 0),rr([r.property({type:Boolean})],ir.prototype,"manual",void 0),rr([r.property({type:Boolean})],ir.prototype,"inline",void 0),rr([r.property({type:Number})],ir.prototype,"delay",void 0),rr([r.property()],ir.prototype,"position",void 0),rr([r.queryAssignedNodes()],ir.prototype,"slotNodes",void 0),rr([r.query(".ft-tooltip--container")],ir.prototype,"container",void 0),rr([r.query(".ft-tooltip")],ir.prototype,"tooltip",void 0),rr([r.query(".ft-tooltip--content")],ir.prototype,"tooltipContent",void 0),rr([r.state()],ir.prototype,"visible",void 0),rr([r.eventOptions({passive:!0})],ir.prototype,"onTouch",null),rr([r.eventOptions({passive:!0})],ir.prototype,"onHover",null),rr([r.eventOptions({passive:!0})],ir.prototype,"onOut",null),rr([r.eventOptions({passive:!0})],ir.prototype,"onClick",null),o.customElement("ft-tooltip")(ir),function(t){t.THUMBS_DOWN="&#xe94d;",t.THUMBS_DOWN_PLAIN="&#xe94e;",t.THUMBS_UP="&#xe94f;",t.THUMBS_UP_PLAIN="&#xe950;",t.STAR="&#xe94c;",t.STAR_PLAIN="&#xe900;",t.DESKTOP="&#xe95e;",t.LIFE_RING="&#xe975;",t.GLOBE="&#xe976;",t.PIGGY_BANK="&#xe977;",t.TABLET_LANDSCAPE="&#xe95f;",t.TABLET_PORTRAIT="&#xe960;",t.MOBILE_LANDSCAPE="&#xe961;",t.MOBILE_PORTRAIT="&#xe962;",t.ARROW_RIGHT_TO_LINE="&#xe95d;",t.THIN_ARROW_UP="&#xe95c;",t.CONTEXTUAL="&#xe95b;",t.CHART_SIMPLE="&#xe968;",t.BARS_PROGRESS="&#xe969;",t.LINE_CHART="&#xe96c;",t.STACKED_CHART="&#xe96d;",t.CHART_BAR_NORMALIZED="&#xe97b;",t.BOOK_OPEN_GEAR="&#xe96a;",t.BOOK_OPEN_GEAR_SLASH="&#xe96b;",t.DIAGRAM_SUNBURST="&#xe963;",t.DIAGRAM_SANKEY="&#xe964;",t.UNSTRUCTURED_DOC="&#xe95a;",t.RESET="&#xe958;",t.THIN_ARROW_LEFT="&#xe956;",t.THIN_ARROW_RIGHT="&#xe957;",t.MY_COLLECTIONS="&#xe955;",t.OFFLINE_SETTINGS="&#xe954;",t.MY_LIBRARY="&#xe959;",t.RATE_PLAIN="&#xe952;",t.RATE="&#xe953;",t.FEEDBACK_PLAIN="&#xe951;",t.PAUSE="&#xe949;",t.PLAY="&#xe94a;",t.RELATIVES_PLAIN="&#xe947;",t.RELATIVES="&#xe948;",t.SHORTCUT_MENU="&#xe946;",t.PRINT="&#xe944;",t.DEFAULT_ROLES="&#xe945;",t.ACCOUNT_SETTINGS="&#xe943;",t.ONLINE="&#xe941;",t.OFFLINE="&#xe816;",t.UPLOAD="&#xe940;",t.BOOK_PLAIN="&#xe93f;",t.SYNC="&#xe93d;",t.SHARED_PBK="&#xe931;",t.COLLECTIONS="&#xe92a;",t.SEARCH_IN_PUBLICATION="&#xe92f;",t.BOOKS="&#xe806;",t.LOCKER="&#xe93b;",t.ARROW_DOWN="&#xe92b;",t.ARROW_LEFT="&#xe92c;",t.ARROW_RIGHT="&#xe92d;",t.ARROW_UP="&#xe92e;",t.SAVE="&#xe93a;",t.MAILS_AND_NOTIFICATIONS="&#xe939;",t.DOT="&#xe936;",t.MINUS="&#xe937;",t.PLUS="&#xe938;",t.FILTERS="&#xe935;",t.STRIPE_ARROW_RIGHT="&#xe934;",t.STRIPE_ARROW_LEFT="&#xe933;",t.ATTACHMENTS="&#xe932;",t.ADD_BOOKMARK="&#xe804;",t.BOOKMARK="&#xe805;",t.EXPORT="&#xe80f;",t.MENU="&#xe807;",t.TAG="&#xe93e;",t.TAG_PLAIN="&#xe942;",t.COPY_TO_CLIPBOARD="&#xe930;",t.COLUMNS="&#xe928;",t.ARTICLE="&#xe927;",t.CLOSE_PLAIN="&#xe925;",t.CHECK_PLAIN="&#xe926;",t.LOGOUT="&#xe923;",t.SIGN_IN="&#xe922;",t.THIN_ARROW="&#xe921;",t.TRIANGLE_BOTTOM="&#xe91d;",t.TRIANGLE_LEFT="&#xe91e;",t.TRIANGLE_RIGHT="&#xe91f;",t.TRIANGLE_TOP="&#xe920;",t.FACET_HAS_DESCENDANT="&#xe91c;",t.MINUS_PLAIN="&#xe91a;",t.PLUS_PLAIN="&#xe91b;",t.INFO="&#xe919;",t.ICON_EXPAND="&#xe917;",t.ICON_COLLAPSE="&#xe918;",t.ADD_TO_PBK="&#xe800;",t.ALERT="&#xe801;",t.ADD_ALERT="&#xe802;",t.BACK_TO_SEARCH="&#xe803;",t.DOWNLOAD="&#xe808;",t.EDIT="&#xe809;",t.FEEDBACK="&#xe80a;",t.MODIFY_PBK="&#xe80c;",t.SCHEDULED="&#xe80d;",t.SEARCH="&#xe80e;",t.SHARE="&#xe80f1;",t.TOC="&#xe810;",t.WRITE_UGC="&#xe811;",t.TRASH="&#xe812;",t.EXTLINK="&#xe814;",t.EXTLINK_LIGHT="&#xe978;",t.CALENDAR="&#xe815;",t.BOOK="&#xe817;",t.DOWNLOAD_PLAIN="&#xe818;",t.CHECK="&#xe819;",t.TOPICS="&#xe901;",t.EYE="&#xf06e;",t.EYE_SLASH="&#xe970;",t.DISC="&#xe902;",t.CIRCLE="&#xe903;",t.SHARED="&#xe904;",t.SORT_UNSORTED="&#xe905;",t.SORT_UP="&#xe906;",t.SORT_DOWN="&#xe907;",t.WORKING="&#xe908;",t.CLOSE="&#xe909;",t.ZOOM_OUT="&#xe90a;",t.ZOOM_IN="&#xe90b;",t.ZOOM_REALSIZE="&#xe90c;",t.ZOOM_FULLSCREEN="&#xe90d;",t.ADMIN_RESTRICTED="&#xe90e;",t.ADMIN_THEME="&#xe911;",t.WARNING="&#xe913;",t.CONTEXT="&#xe914;",t.SEARCH_HOME="&#xe915;",t.STEPS="&#xe916;",t.HOME="&#xe80b;",t.TRANSLATE="&#xe924;",t.USER="&#xe813;",t.ADMIN="&#xe90f;",t.ANALYTICS="&#xe929;",t.ADMIN_KHUB="&#xe910;",t.ADMIN_USERS="&#xe912;",t.ADMIN_INTEGRATION="&#xe93c;",t.ADMIN_PORTAL="&#xe94b;",t.COMMENT_QUESTION="&#xe965;",t.COMMENT_QUESTION_PLAIN="&#xe966;",t.MESSAGE_BOT="&#xe967;",t.PIP="&#xe973;",t.PIP_WIDE="&#xe974;",t.EXPAND_WIDE="&#xe972;",t.X_MARK="&#xe971;",t.CLONE="&#xe979;",t.CLONE_LINK_SIMPLE="&#xe97a;"}(tr||(tr={})),function(t){t.UNKNOWN="&#xe90a;",t.ABW="&#xe900;",t.AUDIO="&#xe901;",t.AVI="&#xe902;",t.CHM="&#xe904;",t.CODE="&#xe905;",t.CSV="&#xe903;",t.DITA="&#xe906;",t.EPUB="&#xe907;",t.EXCEL="&#xe908;",t.FLAC="&#xe909;",t.GIF="&#xe90b;",t.GZIP="&#xe90c;",t.HTML="&#xe90d;",t.IMAGE="&#xe90e;",t.JPEG="&#xe90f;",t.JSON="&#xe910;",t.M4A="&#xe911;",t.MOV="&#xe912;",t.MP3="&#xe913;",t.MP4="&#xe914;",t.OGG="&#xe915;",t.PDF="&#xe916;",t.PNG="&#xe917;",t.POWERPOINT="&#xe918;",t.RAR="&#xe91a;",t.STP="&#xe91b;",t.TEXT="&#xe91c;",t.VIDEO="&#xe91e;",t.WAV="&#xe91f;",t.WMA="&#xe920;",t.WORD="&#xe921;",t.XML="&#xe922;",t.YAML="&#xe919;",t.ZIP="&#xe923;"}(or||(or={})),new Map([...["abw"].map((t=>[t,or.ABW])),...["3gp","act","aiff","aac","amr","au","awb","dct","dss","dvf","gsm","iklax","ivs","mmf","mpc","msv","opus","ra","rm","raw","sln","tta","vox","wv"].map((t=>[t,or.AUDIO])),...["avi"].map((t=>[t,or.AVI])),...["chm","xhs"].map((t=>[t,or.CHM])),...["java","py","php","php3","php4","php5","js","javascript","rb","rbw","c","cpp","cxx","h","hh","hpp","hxx","sh","bash","zsh","tcsh","ksh","csh","vb","scala","pl","prl","perl","groovy","ceylon","aspx","jsp","scpt","applescript","bas","bat","lua","jsp","mk","cmake","css","sass","less","m","mm","xcodeproj"].map((t=>[t,or.CODE])),...["csv"].map((t=>[t,or.CSV])),...["dita","ditamap","ditaval"].map((t=>[t,or.DITA])),...["epub"].map((t=>[t,or.EPUB])),...["xls","xlt","xlm","xlsx","xlsm","xltx","xltm","xlsb","xla","xlam","xll","xlw"].map((t=>[t,or.EXCEL])),...["flac"].map((t=>[t,or.FLAC])),...["gif"].map((t=>[t,or.GIF])),...["gzip","x-gzip","giz","gz","tgz"].map((t=>[t,or.GZIP])),...["html","htm","xhtml"].map((t=>[t,or.HTML])),...["ai","vml","xps","img","cpt","psd","psp","xcf","svg","svg+xml","bmp","bpg","ppm","pgm","pbm","pnm","rif","tif","tiff","webp","wmf"].map((t=>[t,or.IMAGE])),...["jpeg","jpg","jpe"].map((t=>[t,or.JPEG])),...["json"].map((t=>[t,or.JSON])),...["m4a","m4p"].map((t=>[t,or.M4A])),...["mov","qt"].map((t=>[t,or.MOV])),...["mp3"].map((t=>[t,or.MP3])),...["mp4","m4v"].map((t=>[t,or.MP4])),...["ogg","oga"].map((t=>[t,or.OGG])),...["pdf","ps"].map((t=>[t,or.PDF])),...["png"].map((t=>[t,or.PNG])),...["ppt","pot","pps","pptx","pptm","potx","potm","ppam","ppsx","ppsm","sldx","sldm"].map((t=>[t,or.POWERPOINT])),...["rar"].map((t=>[t,or.RAR])),...["stp"].map((t=>[t,or.STP])),...["txt","rtf","md","mdown"].map((t=>[t,or.TEXT])),...["webm","mkv","flv","vob","ogv","ogg","drc","mng","wmv","yuv","rm","rmvb","asf","mpg","mp2","mpeg","mpe","mpv","m2v","svi","3gp","3g2","mxf","roq","nsv"].map((t=>[t,or.VIDEO])),...["wav"].map((t=>[t,or.WAV])),...["wma"].map((t=>[t,or.WMA])),...["doc","dot","docx","docm","dotx","dotm","docb"].map((t=>[t,or.WORD])),...["xml","xsl","rdf"].map((t=>[t,or.XML])),...["yaml","yml","x-yaml"].map((t=>[t,or.YAML])),...["zip"].map((t=>[t,or.ZIP]))]),or.ABW,or.AUDIO,or.AVI,or.CHM,or.CODE,or.CSV,or.DITA,or.EPUB,or.EXCEL,or.FLAC,or.GIF,or.GZIP,or.HTML,or.IMAGE,or.JPEG,or.JSON,or.M4A,or.MOV,or.MP3,or.MP4,or.OGG,or.PDF,or.PNG,or.POWERPOINT,or.RAR,or.STP,or.TEXT,or.UNKNOWN,or.VIDEO,or.WAV,or.WMA,or.WORD,or.XML,or.YAML,or.ZIP,function(t){t.fluid_topics="fluid-topics",t.file_format="file-format",t.material="material"}(er||(er={}));var nr=function(t,o,e,r){for(var i,n=arguments.length,a=n<3?o:null===r?r=Object.getOwnPropertyDescriptor(o,e):r,l=t.length-1;l>=0;l--)(i=t[l])&&(a=(n<3?i(a):n>3?i(o,e,a):i(o,e))||a);return n>3&&a&&Object.defineProperty(o,e,a),a};class ar extends o.FtLitElement{constructor(){super(...arguments),this.resolvedIcon=e.nothing}render(){const t=this.variant&&Object.values(er).includes(this.variant)?this.variant:er.fluid_topics,o=t!==er.material||!!this.value;return e.html`
580
580
  <i class="ft-icon ft-icon--${t}" part="icon icon-${t}">
581
581
  ${n.unsafeHTML(this.resolvedIcon)}
582
582
  <slot ?hidden=${o}></slot>
@@ -870,12 +870,12 @@ const Bo=Symbol.for(""),Fo=t=>{if(t?.r===Bo)return t?._$litStatic$},Do=t=>({_$li
870
870
  <slot></slot>
871
871
  </ft-typography>
872
872
  </div>
873
- `}onClick(t){this.dispatchEvent(new mr(this.value))}}xr.elementDefinitions={"ft-icon":ar,"ft-ripple":Qt,"ft-typography":jo},xr.styles=ur,br([r.property()],xr.prototype,"iconVariant",void 0),br([r.property()],xr.prototype,"icon",void 0),br([r.property()],xr.prototype,"value",void 0);var Or=function(t,o,e,r){for(var i,n=arguments.length,a=n<3?o:null===r?r=Object.getOwnPropertyDescriptor(o,e):r,l=t.length-1;l>=0;l--)(i=t[l])&&(a=(n<3?i(a):n>3?i(o,e,a):i(o,e))||a);return n>3&&a&&Object.defineProperty(o,e,a),a};class vr extends o.FtLitElement{constructor(){super(...arguments),this.menuOpen=!1,this.forceMenuOpen=!1,this.primary=!1,this.secondary=!1,this.tertiary=!1,this.neutral=!1,this.small=!1,this.iconVariant=er.fluid_topics,this.icon="SHORTCUT_MENU",this.horizontalAlignment="left",this.verticalAlignment="bottom",this.disabled=!1,this.closeMenuMatchers=[],this.hideOptions=t=>{this.menuOpen=this.menuOpen&&t.composedPath().includes(this.container),this.menuOpen||document.removeEventListener("click",this.hideOptions)}}render(){const t={"ft-floating-menu":!0,"ft-floating-menu--open":this.forceMenuOpen||this.menuOpen,["ft-floating-menu--"+this.horizontalAlignment.toLowerCase()]:!0,["ft-floating-menu--"+this.verticalAlignment.toLowerCase()]:!0};return e.html`
873
+ `}onClick(t){this.dispatchEvent(new mr(this.value))}}xr.elementDefinitions={"ft-icon":ar,"ft-ripple":Qt,"ft-typography":jo},xr.styles=ur,br([r.property()],xr.prototype,"iconVariant",void 0),br([r.property()],xr.prototype,"icon",void 0),br([r.property()],xr.prototype,"value",void 0);var Or=function(t,o,e,r){for(var i,n=arguments.length,a=n<3?o:null===r?r=Object.getOwnPropertyDescriptor(o,e):r,l=t.length-1;l>=0;l--)(i=t[l])&&(a=(n<3?i(a):n>3?i(o,e,a):i(o,e))||a);return n>3&&a&&Object.defineProperty(o,e,a),a};class vr extends o.FtLitElement{constructor(){super(...arguments),this.menuOpen=!1,this.forceMenuOpen=!1,this.primary=!1,this.secondary=!1,this.tertiary=!1,this.neutral=!1,this.small=!1,this.iconVariant=er.fluid_topics,this.icon="SHORTCUT_MENU",this.horizontalAlignment="left",this.verticalAlignment="bottom",this.disabled=!1,this.closeMenuMatchers=[],this.hideOptionsOnClickOutside=t=>{this.menuOpen=this.menuOpen&&t.composedPath().includes(this.container)}}render(){const t={"ft-floating-menu":!0,"ft-floating-menu--open":this.forceMenuOpen||this.menuOpen,["ft-floating-menu--"+this.horizontalAlignment.toLowerCase()]:!0,["ft-floating-menu--"+this.verticalAlignment.toLowerCase()]:!0};return e.html`
874
874
  <div class="${i.classMap(t)}">
875
875
 
876
876
  <slot name="toggle"
877
877
  part="toggle"
878
- @click=${this.onClick}>
878
+ @click=${this.toggleMenu}>
879
879
  <ft-or-ftds-button id="actions-button"
880
880
  part="button"
881
881
  ?primary=${this.primary}
@@ -898,7 +898,7 @@ const Bo=Symbol.for(""),Fo=t=>{if(t?.r===Bo)return t?._$litStatic$},Do=t=>({_$li
898
898
  <div id="ft-floating-menu-options"
899
899
  class="ft-floating-menu--options"
900
900
  part="options"
901
- @select="${this.onClickItem}">
901
+ @select="${this.closeMenu}">
902
902
  <slot id="ft-floating-menu-content"
903
903
  @click=${this.onContentClick}
904
904
  @close-ft-floating-menu=${this.onCloseEvent}
@@ -906,7 +906,7 @@ const Bo=Symbol.for(""),Fo=t=>{if(t?.r===Bo)return t?._$litStatic$},Do=t=>({_$li
906
906
  </div>
907
907
  </div>
908
908
  </div>
909
- `}onClick(){this.menuOpen=!this.menuOpen,setTimeout((()=>document.addEventListener("click",this.hideOptions)))}onClickItem(){this.closeMenu()}closeMenu(){this.menuOpen=!1}onCloseEvent(t){t.stopPropagation(),this.closeMenu()}onContentClick(t){o.eventPathContainsMatchingElement(t,this.closeMenuMatchers,this)&&(this.closeMenu(),t.stopPropagation())}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("click",this.hideOptions)}contentAvailableCallback(t){super.contentAvailableCallback(t),["menuOpen"].some((o=>t.has(o)))&&this.menuOpen&&(this.menuWrapper.classList.remove("ft-floating-menu--wrapper-positioned"),this.positionMenuWrapper())}positionMenuWrapper(){this.menuWrapper.style.left="",this.menuWrapper.style.top="";const t=this.customToggle.length>0?this.customToggle[0]:this.actionButton;qe(t,this.menuWrapper,{platform:{...Xe,getOffsetParent:t=>Xe.getOffsetParent(t,Je)},middleware:[Oe({crossAxis:!0}),xe({allowedPlacements:[this.convertPlacement()]})]}).then((({x:t,y:o})=>{this.menuWrapper.style.left=`${t}px`,this.menuWrapper.style.top=`${o}px`})),this.menuWrapper.classList.add("ft-floating-menu--wrapper-positioned")}convertPlacement(){switch(this.horizontalAlignment){case"left":return this.verticalAlignment+"-start";case"right":return this.verticalAlignment+"-end";case"center":return this.verticalAlignment+"-center"}}}vr.elementDefinitions={"ft-floating-menu-item":xr},Or([r.state()],vr.prototype,"menuOpen",void 0),Or([r.state()],vr.prototype,"forceMenuOpen",void 0),Or([r.query(".ft-floating-menu")],vr.prototype,"container",void 0),Or([r.query(".ft-floating-menu--wrapper")],vr.prototype,"menuWrapper",void 0),Or([r.query("#ft-floating-menu-options")],vr.prototype,"menuContent",void 0),Or([r.query("#actions-button")],vr.prototype,"actionButton",void 0),Or([r.queryAssignedElements({slot:"toggle"})],vr.prototype,"customToggle",void 0),Or([r.property({type:Boolean})],vr.prototype,"primary",void 0),Or([r.property({type:Boolean})],vr.prototype,"secondary",void 0),Or([r.property({type:Boolean})],vr.prototype,"tertiary",void 0),Or([r.property({type:Boolean})],vr.prototype,"neutral",void 0),Or([r.property({type:Boolean})],vr.prototype,"small",void 0),Or([r.property()],vr.prototype,"label",void 0),Or([r.property()],vr.prototype,"tooltipPosition",void 0),Or([r.property()],vr.prototype,"iconVariant",void 0),Or([r.property()],vr.prototype,"icon",void 0),Or([r.property()],vr.prototype,"text",void 0),Or([r.property()],vr.prototype,"horizontalAlignment",void 0),Or([r.property()],vr.prototype,"verticalAlignment",void 0),Or([r.property({type:Boolean})],vr.prototype,"disabled",void 0),Or([o.jsonProperty([])],vr.prototype,"closeMenuMatchers",void 0);class Nr extends vr{}Nr.elementDefinitions={"ft-or-ftds-button":pr},Nr.styles=l;class Sr extends vr{}Sr.elementDefinitions={"ft-or-ftds-button":yr},Sr.styles=l;const wr={color:o.FtCssVariableFactory.extend("--ft-floating-menu-label-color","",o.designSystemVariables.colorOnSurfaceMedium)},$r=e.css`
909
+ `}toggleMenu(){this.menuOpen=!this.menuOpen}openMenu(){this.menuOpen=!0}closeMenu(){this.menuOpen=!1}onCloseEvent(t){t.stopPropagation(),this.closeMenu()}onContentClick(t){o.eventPathContainsMatchingElement(t,this.closeMenuMatchers,this)&&this.closeMenu()}disconnectedCallback(){super.disconnectedCallback(),document.removeEventListener("click",this.hideOptionsOnClickOutside)}contentAvailableCallback(t){super.contentAvailableCallback(t),t.has("menuOpen")&&(this.menuOpen?(this.menuWrapper.classList.remove("ft-floating-menu--wrapper-positioned"),this.positionMenuWrapper(),document.addEventListener("click",this.hideOptionsOnClickOutside)):document.removeEventListener("click",this.hideOptionsOnClickOutside))}async positionMenuWrapper(){this.menuWrapper.style.left="",this.menuWrapper.style.top="";const t=this.customToggle.length>0?this.customToggle[0]:this.actionButton,{x:o,y:e}=await Qe(t,this.menuWrapper,this.convertPlacement());this.menuWrapper.style.left=`${o}px`,this.menuWrapper.style.top=`${e}px`,this.menuWrapper.classList.add("ft-floating-menu--wrapper-positioned")}convertPlacement(){switch(this.horizontalAlignment){case"left":return this.verticalAlignment+"-start";case"right":return this.verticalAlignment+"-end";case"center":return this.verticalAlignment+"-center"}}}vr.elementDefinitions={"ft-floating-menu-item":xr},Or([r.state()],vr.prototype,"menuOpen",void 0),Or([r.state()],vr.prototype,"forceMenuOpen",void 0),Or([r.query(".ft-floating-menu")],vr.prototype,"container",void 0),Or([r.query(".ft-floating-menu--wrapper")],vr.prototype,"menuWrapper",void 0),Or([r.query("#actions-button")],vr.prototype,"actionButton",void 0),Or([r.queryAssignedElements({slot:"toggle"})],vr.prototype,"customToggle",void 0),Or([r.property({type:Boolean})],vr.prototype,"primary",void 0),Or([r.property({type:Boolean})],vr.prototype,"secondary",void 0),Or([r.property({type:Boolean})],vr.prototype,"tertiary",void 0),Or([r.property({type:Boolean})],vr.prototype,"neutral",void 0),Or([r.property({type:Boolean})],vr.prototype,"small",void 0),Or([r.property()],vr.prototype,"label",void 0),Or([r.property()],vr.prototype,"tooltipPosition",void 0),Or([r.property()],vr.prototype,"iconVariant",void 0),Or([r.property()],vr.prototype,"icon",void 0),Or([r.property()],vr.prototype,"text",void 0),Or([r.property()],vr.prototype,"horizontalAlignment",void 0),Or([r.property()],vr.prototype,"verticalAlignment",void 0),Or([r.property({type:Boolean})],vr.prototype,"disabled",void 0),Or([o.jsonProperty([])],vr.prototype,"closeMenuMatchers",void 0);class Nr extends vr{}Nr.elementDefinitions={"ft-or-ftds-button":pr},Nr.styles=l;class Sr extends vr{}Sr.elementDefinitions={"ft-or-ftds-button":yr},Sr.styles=l;const wr={color:o.FtCssVariableFactory.extend("--ft-floating-menu-label-color","",o.designSystemVariables.colorOnSurfaceMedium)},$r=e.css`
910
910
  .ft-floating-menu-label {
911
911
  padding: 4px 8px;
912
912
  }