@tylertech/forge 2.20.0 → 2.21.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/custom-elements.json +37 -3
- package/dist/esm/app-bar/help-button/index.js +1 -1
- package/dist/esm/app-bar/index.js +1 -1
- package/dist/esm/autocomplete/index.js +1 -1
- package/dist/esm/chunks/{chunk.JMRXBELV.js → chunk.2VWASAUU.js} +2 -2
- package/dist/esm/chunks/{chunk.JMRXBELV.js.map → chunk.2VWASAUU.js.map} +3 -3
- package/dist/esm/chunks/{chunk.IDMAZQXY.js → chunk.326IKRDS.js} +2 -2
- package/dist/esm/chunks/{chunk.YW3PMPBB.js → chunk.B7LJJMMF.js} +2 -2
- package/dist/esm/chunks/{chunk.YW3PMPBB.js.map → chunk.B7LJJMMF.js.map} +1 -1
- package/dist/esm/chunks/{chunk.TVI6D4GA.js → chunk.ECIGY5TD.js} +2 -2
- package/dist/esm/chunks/{chunk.VFRPE3S3.js → chunk.FCTKNIBN.js} +2 -2
- package/dist/esm/chunks/{chunk.VFRPE3S3.js.map → chunk.FCTKNIBN.js.map} +2 -2
- package/dist/esm/chunks/chunk.Q7HX26UO.js +7 -0
- package/dist/esm/chunks/chunk.Q7HX26UO.js.map +7 -0
- package/dist/esm/chunks/{chunk.54KXJVRY.js → chunk.UQTJSPU4.js} +2 -2
- package/dist/esm/chunks/chunk.Y7YPNMPI.js +7 -0
- package/dist/esm/chunks/chunk.Y7YPNMPI.js.map +7 -0
- package/dist/esm/chunks/{chunk.CD33V3IO.js → chunk.ZWL2Q7E6.js} +2 -2
- package/dist/esm/chunks/{chunk.CD33V3IO.js.map → chunk.ZWL2Q7E6.js.map} +3 -3
- package/dist/esm/index.js +1 -1
- package/dist/esm/menu/index.js +1 -1
- package/dist/esm/paginator/index.js +1 -1
- package/dist/esm/split-view/index.js +1 -1
- package/dist/esm/split-view/split-view/index.js +1 -1
- package/dist/esm/split-view/split-view-panel/index.js +1 -1
- package/dist/esm/stepper/index.js +1 -1
- package/dist/esm/stepper/stepper/index.js +1 -1
- package/dist/esm/table/index.js +1 -1
- package/esm/autocomplete/autocomplete-foundation.js +2 -2
- package/esm/menu/menu-adapter.d.ts +3 -3
- package/esm/menu/menu-constants.d.ts +1 -1
- package/esm/menu/menu-foundation.d.ts +1 -0
- package/esm/menu/menu-foundation.js +11 -8
- package/esm/paginator/paginator-constants.d.ts +9 -0
- package/esm/paginator/paginator-foundation.d.ts +5 -2
- package/esm/paginator/paginator-foundation.js +29 -8
- package/esm/paginator/paginator.d.ts +3 -1
- package/esm/paginator/paginator.js +3 -0
- package/esm/split-view/split-view-panel/split-view-panel.js +1 -1
- package/esm/stepper/stepper/stepper-foundation.js +1 -1
- package/esm/table/table-foundation.js +1 -5
- package/package.json +1 -1
- package/dist/esm/chunks/chunk.23QPY6PU.js +0 -7
- package/dist/esm/chunks/chunk.23QPY6PU.js.map +0 -7
- package/dist/esm/chunks/chunk.XY3WCDVX.js +0 -7
- package/dist/esm/chunks/chunk.XY3WCDVX.js.map +0 -7
- /package/dist/esm/chunks/{chunk.IDMAZQXY.js.map → chunk.326IKRDS.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.TVI6D4GA.js.map → chunk.ECIGY5TD.js.map} +0 -0
- /package/dist/esm/chunks/{chunk.54KXJVRY.js.map → chunk.UQTJSPU4.js.map} +0 -0
package/package.json
CHANGED
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright 2023 Tyler Technologies, Inc.
|
|
4
|
-
* License: Apache-2.0
|
|
5
|
-
*/
|
|
6
|
-
import{a as k}from"./chunk.D43PPRFO.js";import{e as V,h as B,j as H}from"./chunk.WOTVTBJS.js";import{c as x}from"./chunk.SXTM6OK4.js";import{a as m,b as N}from"./chunk.DYF2MREZ.js";import{d as K}from"./chunk.JD4APKZS.js";import{b as A}from"./chunk.BL4IBI6G.js";import{e as F}from"./chunk.3C44DXZ2.js";import{d as P}from"./chunk.MZLPUI6R.js";import{d as w}from"./chunk.IWICN773.js";import{a as S}from"./chunk.5KC43VFL.js";import{a as p}from"./chunk.KTGSZEAG.js";import{a as T,b as D,d as y}from"./chunk.QOA2O575.js";import{a as L,e as C}from"./chunk.HOXFK44F.js";import{m as M}from"./chunk.4LA6HEA7.js";import{a as g,b as O,i as I,k as _}from"./chunk.J2M2MXP2.js";import{a as c,b,f as a}from"./chunk.MCIQXNKY.js";var l=`${D}menu`,U={POPUP:"forge-menu__popup",MENU:"mdc-menu"},G={TOGGLE:`.${l}__toggle,[${l}-toggle],button,[type=button],[role=button],a,[tabindex]:not([tabindex^="-"])`,MENU_LIST:"forge-list"},R={OPEN:"open",PLACEMENT:"placement",SELECTED_INDEX:"selected-index",SELECTED_VALUE:"selected-value",DENSE:"dense",ICON_CLASS:"icon-class",PERSIST_SELECTION:"persist-selection",MODE:"mode",SYNC_POPUP_WIDTH:"sync-popup-width",POPUP_CLASSES:"popup-classes",OPTION_LIMIT:"option-limit",OBSERVE_SCROLL:"observe-scroll",OBSERVE_SCROLL_THRESHOLD:"observe-scroll-threshold"},$={SELECT:`${l}-select`,OPEN:`${l}-open`,CLOSE:`${l}-close`,ACTIVE_CHANGE:`${l}-active-change`},z={CHILD_MOUSE_LEAVE_TIMEOUT:300,POPUP_MOUSE_LEAVE_TIMEOUT:500},i={elementName:l,classes:U,selectors:G,attributes:R,events:$,numbers:z};var u=class extends S{constructor(e){super(e);this._childMenus=new Map}getDropdownElement(){var e,t;return(t=(e=this._listDropdown)==null?void 0:e.dropdownElement)!=null?t:null}hasTargetElement(){return!!this._targetElement}initializeTarget(){this._targetElement=this._component.querySelector(i.selectors.TOGGLE),this._targetElement||(this._targetElement=this._component.firstElementChild)}initializeAccessibility(e){!this._targetElement||(this._targetElement.setAttribute("aria-atomic","true"),this._targetElement.setAttribute("aria-live","assertive"),this._targetElement.setAttribute("aria-haspopup","true"),this._targetElement.setAttribute("aria-expanded","false"),this._targetElement.hasAttribute("aria-label")||this._targetElement.setAttribute("aria-label",this._targetElement.textContent||""))}addTargetListener(e,t,n=!1){this._targetElement&&this._targetElement.addEventListener(e,t,n)}removeTargetListener(e,t){this._targetElement&&this._targetElement.removeEventListener(e,t)}attachMenu(e){this._listDropdown||!this._targetElement||(this._listDropdown=new B(this._targetElement,e),this._listDropdown.open(),this._targetElement.setAttribute("aria-expanded","true"),this._targetElement.setAttribute("aria-controls",`list-dropdown-popup-${e.id}`))}setOptions(e){this._listDropdown&&this._listDropdown.setOptions(e)}detachMenu(){this._targetElement&&(this._targetElement.removeAttribute("aria-activedescendant"),this._targetElement.removeAttribute("aria-expanded"),this._targetElement.removeAttribute("aria-controls")),this._listDropdown&&(this._listDropdown.close(),this._listDropdown.destroy(),this._listDropdown=void 0)}setActiveOption(e){var t;(t=this._listDropdown)==null||t.activateOption(e)}activateFirstOption(){var e;(e=this._listDropdown)==null||e.activateFirstOption()}setCascadeTargetInactive(){let e=this._targetElement;e!=null&&e.active&&(e.active=!1)}getActiveOptionIndex(){var e,t;return(t=(e=this._listDropdown)==null?void 0:e.getActiveOptionIndex())!=null?t:-1}focusTarget(){this._targetElement&&this._targetElement.focus()}isTargetFocused(){return document.activeElement===this._targetElement}updateActiveDescendant(e){!this._targetElement||(e?this._targetElement.setAttribute("aria-activedescendant",e):this._targetElement.removeAttribute("aria-activedescendant"))}addDropdownListener(e,t){!this._listDropdown||!this._listDropdown.dropdownElement||this._listDropdown.dropdownElement.addEventListener(e,t)}isOwnElement(e){return!this._targetElement||!this._listDropdown||!this._listDropdown.dropdownElement?!1:this._targetElement.contains(e)||!!this._listDropdown.dropdownElement.contains(e)}propagateKey(e){var t;(t=this._listDropdown)==null||t.handleKey(e)}proxyKeyboardEventToChild(e,t){if(!this.getDropdownElement())return;let n=this._getOpenChildMenu(t);n&&n.propagateKeyEvent(e)}toggleChildMenu(e,t){let r=this._getListItems()[e].parentElement;r&&r.tagName.toLowerCase()===i.elementName&&(t===void 0?r.open=!r.open:r.open=t,r.activateFirstOption())}createChildMenu(e,t,n,o,r){let d=document.createElement("forge-menu");return d.style.display="block",d.addEventListener(i.events.OPEN,()=>{this._childMenus.set(e,d),n(e)}),d.addEventListener(i.events.CLOSE,()=>{this._childMenus.delete(e),o(e)}),d.addEventListener(i.events.SELECT,f=>{f.stopPropagation(),r(b(c({},f.detail),{parentValue:t}))}),d}closeOtherChildMenus(e){let t=[];this._childMenus.forEach((n,o)=>{o!==e&&(n.open=!1,t.push(o))}),t.forEach(n=>this._childMenus.delete(n))}setSelectedValues(e){var t;(t=this._listDropdown)==null||t.setSelectedValues(e)}_getOpenChildMenu(e){if(!this.getDropdownElement())return null;let t=this._getOwnList(e);return t?t.querySelector(`${i.elementName}[${i.attributes.OPEN}]`):null}_getOwnList(e){let t=this.getDropdownElement();return t?t.querySelector(`${m.elementName}[id="list-dropdown-list-${e}"]`):null}_getListItems(){let e=this.getDropdownElement();if(!e)return[];let t=e.querySelector(m.elementName);return t?Array.from(t.querySelectorAll(N.elementName)):[]}};var h=class extends H{constructor(e){super({popupTimeout:i.numbers.POPUP_MOUSE_LEAVE_TIMEOUT,targetTimeout:i.numbers.CHILD_MOUSE_LEAVE_TIMEOUT});this._adapter=e;this._placement="bottom-start";this._fallbackPlacements=[];this._dense=!1;this._iconClass=y;this._persistSelection=!1;this._mode="click";this._identifier=g(),this._clickListener=t=>this._onTargetClick(t),this._blurListener=t=>this._onTargetBlur(t),this._selectListener=t=>this._handleSelectEvent(t),this._keydownListener=t=>this.onKeydown(t),this._activeChangeListener=t=>this._onActiveOptionChanged(t)}initialize(){this._adapter.initializeTarget(),this._adapter.initializeAccessibility(this._identifier),this._initializeInteractionListeners()}disconnect(){this._open&&this._closeDropdown(),this._destroyInteractionListeners()}activateFirstOption(){this._adapter.activateFirstOption()}_applyMode(){!this._adapter.hasTargetElement()||(this._mode!=="cascade"?this._adapter.addTargetListener("click",this._clickListener):this._attachCascadingListeners())}_initializeInteractionListeners(){!this._adapter.hasTargetElement()||(this._applyMode(),this._adapter.addTargetListener("keydown",this._keydownListener,!0),this._adapter.addTargetListener("focusout",this._blurListener))}_destroyInteractionListeners(){!this._adapter.hasTargetElement()||(this._adapter.removeTargetListener("keydown",this._clickListener),this._adapter.removeTargetListener("focusout",this._blurListener),this._adapter.removeTargetListener("click",this._clickListener),this._detachCascadingListeners())}_attachCascadingListeners(){this._adapter.addTargetListener("mouseenter",this._targetMouseEnterListener),this._adapter.addTargetListener("mouseleave",this._targetMouseLeaveListener),this._adapter.addDocumentListener("mousemove",this._documentMouseMoveListener)}_detachCascadingListeners(){this._adapter.removeTargetListener("mouseenter",this._targetMouseEnterListener),this._adapter.removeTargetListener("mouseleave",this._targetMouseLeaveListener),this._adapter.removeDocumentListener("mousemove",this._documentMouseMoveListener)}get _nonDividerOptions(){return this._flatOptions.filter(e=>!e.divider)}get _flatOptions(){return V(this._options,1)?this._options.reduce((e,t)=>e.concat(t.options),[]):this._options}_onTargetClick(e){if(this._open){this._closeDropdown();return}this.open=!this._open,this._open&&this._adapter.focusTarget()}_onTargetBlur(e){this._open&&this._closeDropdown()}_onActiveOptionChanged(e){let t={id:e},n=this._adapter.emitHostEvent(i.events.ACTIVE_CHANGE,t,!0,!0);this._mode!=="cascade"&&n&&this._adapter.updateActiveDescendant(e)}onKeydown(e){if(this._childOpen){this._adapter.proxyKeyboardEventToChild(e,this._identifier);return}switch(e.code){case"Tab":this._open&&this._selectActiveOption();break;case"Escape":this._open&&(e.preventDefault(),e.stopPropagation(),this._closeDropdown());break;case"Space":e.preventDefault(),this._open?this._closeDropdown():this._openDropdown({fromKeyboard:!0});break;case"Home":case"End":this._open&&(e.preventDefault(),this._adapter.propagateKey(e.code));break;case"Enter":if(e.preventDefault(),!this._open){e.preventDefault(),this._openDropdown({fromKeyboard:!0});return}e.stopImmediatePropagation(),this._adapter.propagateKey(e.code);let t=this._adapter.getActiveOptionIndex(),n=this._nonDividerOptions[t];n&&n.options&&n.options.length&&this._adapter.toggleChildMenu(t);break;case"ArrowUp":case"ArrowDown":if(this._open&&e.stopImmediatePropagation(),e.preventDefault(),!this._open&&e.code==="ArrowDown"){this._openDropdown({fromKeyboard:!0}),this._adapter.activateFirstOption();return}this._adapter.propagateKey(e.code);break;case"ArrowLeft":this._open&&e.stopImmediatePropagation(),this._mode==="cascade"&&this._open&&this._closeDropdown();break;case"ArrowRight":if(this._open&&e.stopImmediatePropagation(),!this._open)return;let o=this._adapter.getActiveOptionIndex(),r=this._nonDividerOptions[o];if(r&&r.options){this._adapter.toggleChildMenu(o,e.code==="ArrowRight");return}break}}async _openMenu({fromKeyboard:e}={}){this._open=!0;let t=[];if(typeof this._optionsFactory=="function")this._loadOptionsAsync(),this._options=[];else{if(!this._options||!this._options.length)return;t=this._options}this._persistSelection||t.forEach(r=>r.selected=!1),this._mapIconToLeadingIcon();let n=this._persistSelection?this._getSelectedValues():[],o={id:this._identifier,type:"menu",options:this._options,selectedValues:n,iconClass:this._iconClass,dense:this._dense,multiple:!1,popupStatic:!0,allowBusy:!0,asyncStyle:"spinner",optionBuilder:this._optionBuilder,optionLimit:this._optionLimit,headerBuilder:this._popupHeaderBuilder,footerBuilder:this._popupFooterBuilder,observeScroll:this._observeScroll,observeScrollThreshold:this._observeScrollThreshold,popupPlacement:this._placement,popupFallbackPlacements:this._fallbackPlacements,activeStartIndex:e?0:void 0,popupClasses:[i.classes.POPUP,i.classes.MENU,...this._popupClasses],syncWidth:this._syncPopupWidth,activeChangeCallback:this._activeChangeListener,selectCallback:this._selectListener,popupOffset:this._popupOffset,cascadingElementFactory:r=>this._createCascadingElement(r)};this._adapter.setHostAttribute(i.attributes.OPEN,""),this._adapter.attachMenu(o),this._mode==="cascade"&&(this._adapter.addDropdownListener("mouseenter",this._childPopupMouseEnterListener),this._adapter.addDropdownListener("mouseleave",this._childPopupMouseLeaveListener)),this._adapter.addDropdownListener(i.events.ACTIVE_CHANGE,r=>{this._onActiveOptionChanged(r.detail.id)}),this._adapter.emitHostEvent(i.events.OPEN)}_closeMenu(){this._open=!1,this._childOpen=!1,this._adapter.detachMenu(),this._activeMouseLeaveTimeout!==void 0&&window.clearTimeout(this._activeMouseLeaveTimeout),this._adapter.removeHostAttribute(i.attributes.OPEN),this._adapter.emitHostEvent(i.events.CLOSE)}_loadOptionsAsync(){return this._optionsFactory?Promise.resolve(this._optionsFactory()).then(e=>{if(this._persistSelection||e.forEach(t=>t.selected=!1),this._open)if(e&&I(e)&&e.length){this._options=e,this._adapter.setOptions(e);let t=this._getSelectedValues();t.length&&this._adapter.setSelectedValues(t)}else this._open&&this._closeDropdown()}).catch(e=>{console.error("An unexpected error ocurred while opening the menu:",e),this._open&&this._closeDropdown()}):(this._open&&this._closeMenu(),Promise.resolve())}_handleSelectEvent(e){let t=this._nonDividerOptions.findIndex(n=>n.value===e);t<0||this._selectOptionByIndex(t)}_selectActiveOption(){let e=this._adapter.getActiveOptionIndex();e>=0&&this._nonDividerOptions[e]&&this._selectOptionByIndex(e)}_selectOptionByIndex(e){let{options:t,value:n}=this._nonDividerOptions[e];if(t){this._adapter.setActiveOption(e);return}this._closeDropdown();let o={index:e,value:n};!this._adapter.emitHostEvent(i.events.SELECT,o,!0,!0)||(this._selectedValue=this._persistSelection?n:void 0)}_getSelectedValues(){let e=this._flatOptions.filter(t=>t.selected).map(t=>t.value);return this._selectedValue!==void 0&&e.push(this._selectedValue),e}_onCascadingOptionSelected(e){this._persistSelection&&(this._selectedValue=e.value),this._adapter.emitHostEvent(i.events.SELECT,e),this._closeDropdown()}_onCascadingChildOpen(e){super._clearMouseLeaveTimeout(),this._adapter.closeOtherChildMenus(e),this._childOpen=!0,this._adapter.setActiveOption(e)}_onCascadingChildClose(e){this._childOpen=!1}_closeDropdown(){this._closeMenu()}_openDropdown({fromKeyboard:e}={}){this._openMenu({fromKeyboard:e})}_setCascadeTargetInactive(){this._adapter.setCascadeTargetInactive()}_isOwnElement(e){return this._adapter.isOwnElement(e)}_createCascadingElement({index:e,options:t,parentValue:n}){let o=this._adapter.createChildMenu(e,n,this._onCascadingChildOpen.bind(this),this._onCascadingChildClose.bind(this),this._onCascadingOptionSelected.bind(this));return o.mode="cascade",o.popupOffset={x:0,y:-8},o.dense=this._dense,o.placement="right-start",o.fallbackPlacements=["left-start","right-start"],o.persistSelection=this._persistSelection,this._persistSelection&&(o.selectedValue=this._selectedValue),o.options=t,o.optionBuilder=this._optionBuilder,o.iconClass=this._iconClass,o}_mapIconToLeadingIcon(){this._flatOptions.filter(e=>e.icon).forEach(e=>e.leadingIcon=e.icon)}get open(){return this._open}set open(e){e=Boolean(e),this._open!==e&&(this._open=e,e?this._openDropdown():this._closeDropdown())}set options(e){if(typeof e=="function")this.optionsFactory=e;else if(this.optionsFactory=void 0,this._options=e.map(t=>c({},t)),this._open&&(this._mapIconToLeadingIcon(),this._adapter.setOptions(this._options),this._persistSelection)){let t=this._getSelectedValues();t.length&&this._adapter.setSelectedValues(t)}}get options(){return this._options?this._flatOptions.map(e=>c({},e)):[]}set optionsFactory(e){this._optionsFactory=e}set selectedIndex(e){let t=this._nonDividerOptions[e];t&&t.value!==this._selectedValue&&(this.selectedValue=t.value)}get selectedIndex(){return this._selectedValue!==void 0?this._nonDividerOptions.findIndex(e=>e.value===this._selectedValue):-1}set selectedValue(e){this._selectedValue!==e&&(this._selectedValue=e,this._adapter.setSelectedValues(this._selectedValue))}get selectedValue(){return this._selectedValue}get placement(){return this._placement}set placement(e){this._placement!==e&&(this._placement=e||"bottom-start",this._adapter.setHostAttribute(i.attributes.PLACEMENT,this._placement))}get fallbackPlacements(){return this._fallbackPlacements}set fallbackPlacements(e){this._fallbackPlacements=Array.isArray(e)?e:[]}get dense(){return this._dense}set dense(e){this._dense=e}get iconClass(){return this._iconClass}set iconClass(e){this._iconClass=e}get persistSelection(){return this._persistSelection}set persistSelection(e){this._persistSelection!==e&&(this._persistSelection=e,this._adapter.toggleHostAttribute(i.attributes.PERSIST_SELECTION,this._persistSelection),this._persistSelection||(this._flatOptions.forEach(t=>t.selected=!1),this._selectedValue=void 0))}get mode(){return this._mode}set mode(e){this._mode!==e&&(this._mode=e,this._destroyInteractionListeners(),this._applyMode(),this._adapter.setHostAttribute(i.attributes.MODE,this._mode))}get popupOffset(){return this._popupOffset}set popupOffset(e){this._popupOffset=e}get optionBuilder(){return this._optionBuilder}set optionBuilder(e){this._optionBuilder=e}get popupElement(){return this._adapter.getDropdownElement()}};var q="<template><slot></slot></template>",W=":host{display:inline-block}:host([hidden]){display:none}",s=class extends k{constructor(){super();w.define(P),this._foundation=new h(new u(this)),C(this,q,W)}static get observedAttributes(){return[i.attributes.OPEN,i.attributes.PLACEMENT,i.attributes.SELECTED_INDEX,i.attributes.SELECTED_VALUE,i.attributes.DENSE,i.attributes.ICON_CLASS,i.attributes.PERSIST_SELECTION,i.attributes.MODE,i.attributes.SYNC_POPUP_WIDTH,i.attributes.POPUP_CLASSES,i.attributes.OPTION_LIMIT,i.attributes.OBSERVE_SCROLL,i.attributes.OBSERVE_SCROLL_THRESHOLD]}connectedCallback(){this.querySelector(i.selectors.TOGGLE)?this._foundation.initialize():M(this,i.selectors.TOGGLE).then(()=>this._foundation.initialize())}attributeChangedCallback(e,t,n){switch(super.attributeChangedCallback(e,t,n),e){case i.attributes.OPEN:this._foundation.open=O(n);break;case i.attributes.PLACEMENT:this._foundation.placement=n;break;case i.attributes.SELECTED_INDEX:this._foundation.selectedIndex=Number(n);break;case i.attributes.SELECTED_VALUE:this._foundation.selectedValue=n;break;case i.attributes.DENSE:this._foundation.dense=_(n);break;case i.attributes.ICON_CLASS:this._foundation.iconClass=n;break;case i.attributes.PERSIST_SELECTION:this.persistSelection=_(n);break;case i.attributes.MODE:this.mode=n;break}}disconnectedCallback(){this._foundation.disconnect()}propagateKeyEvent(e){this._foundation.onKeydown(e)}activateFirstOption(){this._foundation.activateFirstOption()}};a([p()],s.prototype,"open",2),a([p()],s.prototype,"options",2),a([p()],s.prototype,"selectedIndex",2),a([p()],s.prototype,"selectedValue",2),a([p()],s.prototype,"placement",2),a([p()],s.prototype,"fallbackPlacements",2),a([p()],s.prototype,"dense",2),a([p()],s.prototype,"iconClass",2),a([p()],s.prototype,"persistSelection",2),a([p()],s.prototype,"mode",2),a([p()],s.prototype,"popupOffset",2),a([p()],s.prototype,"optionBuilder",2),a([p({set:!1})],s.prototype,"popupElement",2),s=a([T({name:i.elementName,dependencies:[F,x,K,A]})],s);function Ye(){L(s)}export{i as a,u as b,h as c,s as d,Ye as e};
|
|
7
|
-
//# sourceMappingURL=chunk.23QPY6PU.js.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../src/menu/menu-constants.ts", "../../src/menu/menu-adapter.ts", "../../src/menu/menu-foundation.ts", "../../src/menu/menu.ts", "../../src/menu/index.ts"],
|
|
4
|
-
"sourcesContent": ["import { COMPONENT_NAME_PREFIX } from '../constants';\nimport { IListDropdownOption, IListDropdownOptionGroup } from '../list-dropdown';\n\nconst elementName: keyof HTMLElementTagNameMap = `${COMPONENT_NAME_PREFIX}menu`;\n\nconst classes = {\n POPUP: 'forge-menu__popup',\n MENU: 'mdc-menu'\n};\n\nconst selectors = {\n TOGGLE: `.${elementName}__toggle,[${elementName}-toggle],button,[type=button],[role=button],a,[tabindex]:not([tabindex^=\"-\"])`,\n MENU_LIST: 'forge-list'\n};\n\nconst attributes = {\n OPEN: 'open',\n PLACEMENT: 'placement',\n SELECTED_INDEX: 'selected-index',\n SELECTED_VALUE: 'selected-value',\n DENSE: 'dense',\n ICON_CLASS: 'icon-class',\n PERSIST_SELECTION: 'persist-selection',\n MODE: 'mode',\n SYNC_POPUP_WIDTH: 'sync-popup-width',\n POPUP_CLASSES: 'popup-classes',\n OPTION_LIMIT: 'option-limit',\n OBSERVE_SCROLL: 'observe-scroll',\n OBSERVE_SCROLL_THRESHOLD: 'observe-scroll-threshold'\n};\n\nconst events = {\n SELECT: `${elementName}-select`,\n OPEN: `${elementName}-open`,\n CLOSE: `${elementName}-close`,\n ACTIVE_CHANGE: `${elementName}-active-change`\n};\n\nconst numbers = {\n CHILD_MOUSE_LEAVE_TIMEOUT: 300,\n POPUP_MOUSE_LEAVE_TIMEOUT: 500\n};\n\nexport const MENU_CONSTANTS = {\n elementName,\n classes,\n selectors,\n attributes,\n events,\n numbers\n};\n\nexport interface IMenuSelectEventData<T = any, K = any> {\n index: number;\n value?: T;\n parentValue?: K;\n}\n\nexport interface IMenuActiveChangeEventData {\n id: string;\n}\n\nexport interface IMenuOption<T = any> extends IListDropdownOption<T> {\n icon?: string;\n selected?: boolean;\n}\n\nexport interface IMenuOptionGroup extends IListDropdownOptionGroup {}\n\nexport type MenuOptionBuilder = (option: IMenuOption, parentElement: HTMLElement) => HTMLElement | string | void;\nexport type MenuOptionFactory = (() => IMenuOption[]) | (() => Promise<IMenuOption[]>);\nexport type MenuMode = 'click' | 'cascade';\n", "import { BaseAdapter, IBaseAdapter } from '../core/base/base-adapter';\nimport { IMenuOption } from './index';\nimport { IMenuComponent } from './menu';\nimport { MENU_CONSTANTS, IMenuSelectEventData } from './menu-constants';\nimport { IListDropdownConfig, IListDropdown, ListDropdown } from '../list-dropdown';\nimport { IListComponent, IListItemComponent, LIST_CONSTANTS, LIST_ITEM_CONSTANTS } from '../list';\n\nexport interface IMenuAdapter extends IBaseAdapter {\n getDropdownElement(): HTMLElement | null;\n initializeTarget(): void;\n initializeAccessibility(id: string): void;\n hasTargetElement(): boolean;\n addTargetListener(event: string, callback: (event: Event) => void, bubbles?: boolean): void;\n removeTargetListener(event: string, callback: (event: Event) => void): void;\n attachMenu(config: IListDropdownConfig): void;\n detachMenu(): void;\n setOptions(options: IMenuOption[]): void;\n getActiveOptionIndex(): number;\n setActiveOption(index: number): void;\n activateFirstOption(): void;\n setCascadeTargetInactive(): void;\n propagateKey(key: string): void;\n proxyKeyboardEventToChild(evt: KeyboardEvent, id: string): void;\n toggleChildMenu(index: number, open?: boolean): void;\n focusTarget(): void;\n isTargetFocused(): boolean;\n updateActiveDescendant(id: string): void;\n isOwnElement(element: Element): boolean;\n addDropdownListener(type: string, listener: (evt: any) => void): void;\n createChildMenu(index: number, parentValue: any, openCb: (index: number) => void, closeCb: (index: number) => void, selectCb: (data: IMenuSelectEventData) => void): IMenuComponent;\n closeOtherChildMenus(excludeIndex?: number): void;\n setSelectedValues(values: any[]): void;\n}\n\nexport class MenuAdapter extends BaseAdapter<IMenuComponent> implements IMenuAdapter {\n private _targetElement: HTMLElement | null;\n private _listDropdown?: IListDropdown;\n private _childMenus = new Map<number, IMenuComponent>();\n\n constructor(component: IMenuComponent) {\n super(component);\n }\n\n public getDropdownElement(): HTMLElement | null {\n return this._listDropdown?.dropdownElement ?? null;\n }\n\n public hasTargetElement(): boolean {\n return !!this._targetElement;\n }\n\n public initializeTarget(): void {\n this._targetElement = this._component.querySelector(MENU_CONSTANTS.selectors.TOGGLE);\n if (!this._targetElement) {\n this._targetElement = this._component.firstElementChild as HTMLElement;\n }\n }\n\n public initializeAccessibility(id: string): void {\n if (!this._targetElement) {\n return;\n }\n\n this._targetElement.setAttribute('aria-atomic', 'true');\n this._targetElement.setAttribute('aria-live', 'assertive');\n this._targetElement.setAttribute('aria-haspopup', 'true');\n this._targetElement.setAttribute('aria-expanded', 'false');\n\n if (!this._targetElement.hasAttribute('aria-label')) {\n this._targetElement.setAttribute('aria-label', this._targetElement.textContent || '');\n }\n }\n\n public addTargetListener(event: string, callback: (event: Event) => void, bubbles = false): void {\n if (this._targetElement) {\n this._targetElement.addEventListener(event, callback, bubbles);\n }\n }\n\n public removeTargetListener(event: string, callback: (event: Event) => void): void {\n if (this._targetElement) {\n this._targetElement.removeEventListener(event, callback);\n }\n }\n\n public attachMenu(config: IListDropdownConfig): void {\n if (this._listDropdown || !this._targetElement) {\n return;\n }\n this._listDropdown = new ListDropdown(this._targetElement as HTMLElement, config);\n this._listDropdown.open();\n this._targetElement.setAttribute('aria-expanded', 'true');\n this._targetElement.setAttribute('aria-controls', `list-dropdown-popup-${config.id}`);\n }\n\n public setOptions(options: IMenuOption[]): void {\n if (this._listDropdown) {\n this._listDropdown.setOptions(options);\n }\n }\n\n public detachMenu(): void {\n if (this._targetElement) {\n this._targetElement.removeAttribute('aria-activedescendant');\n this._targetElement.removeAttribute('aria-expanded');\n this._targetElement.removeAttribute('aria-controls');\n }\n\n if (this._listDropdown) {\n this._listDropdown.close();\n this._listDropdown.destroy();\n this._listDropdown = undefined;\n }\n }\n\n public setActiveOption(index: number): void {\n this._listDropdown?.activateOption(index);\n }\n\n public activateFirstOption(): void {\n this._listDropdown?.activateFirstOption();\n }\n\n public setCascadeTargetInactive(): void {\n const listItem = this._targetElement as IListItemComponent;\n if (listItem?.active) {\n listItem.active = false;\n }\n }\n\n public getActiveOptionIndex(): number {\n return this._listDropdown?.getActiveOptionIndex() ?? -1;\n }\n\n public focusTarget(): void {\n if (this._targetElement) {\n this._targetElement.focus();\n }\n }\n\n public isTargetFocused(): boolean {\n return document.activeElement === this._targetElement;\n }\n\n public updateActiveDescendant(id: string): void {\n if (!this._targetElement) {\n return;\n }\n if (id) {\n this._targetElement.setAttribute('aria-activedescendant', id);\n } else {\n this._targetElement.removeAttribute('aria-activedescendant');\n }\n }\n\n public addDropdownListener(type: string, listener: (evt: any) => void): void {\n if (!this._listDropdown || !this._listDropdown.dropdownElement) {\n return;\n }\n this._listDropdown.dropdownElement.addEventListener(type, listener);\n }\n\n public isOwnElement(el: Element): boolean {\n if (!this._targetElement || !this._listDropdown || !this._listDropdown.dropdownElement) {\n return false;\n }\n return this._targetElement.contains(el) || !!this._listDropdown.dropdownElement.contains(el);\n }\n\n public propagateKey(key: string): void {\n this._listDropdown?.handleKey(key);\n }\n\n public proxyKeyboardEventToChild(evt: KeyboardEvent, id: string): void {\n if (!this.getDropdownElement()) {\n return;\n }\n const openMenu = this._getOpenChildMenu(id);\n if (openMenu) {\n openMenu.propagateKeyEvent(evt);\n }\n }\n\n public toggleChildMenu(index: number, open?: boolean): void {\n const listItems = this._getListItems();\n const listItem = listItems[index];\n const childMenu = listItem.parentElement as IMenuComponent;\n if (childMenu && childMenu.tagName.toLowerCase() === MENU_CONSTANTS.elementName) {\n if (open === undefined) {\n childMenu.open = !childMenu.open;\n } else {\n childMenu.open = open;\n }\n childMenu.activateFirstOption();\n }\n }\n\n public createChildMenu(index: number, parentValue: any, openCb: (index: number) => void, closeCb: (index: number) => void, selectCb: (data: IMenuSelectEventData) => void): IMenuComponent {\n const menu = document.createElement('forge-menu');\n menu.style.display = 'block';\n\n // Set listeners to notify the parent menu when anything important happens within a child menu that needs to be propagated to the root menu\n menu.addEventListener(MENU_CONSTANTS.events.OPEN, () => {\n this._childMenus.set(index, menu);\n openCb(index);\n });\n menu.addEventListener(MENU_CONSTANTS.events.CLOSE, () => {\n this._childMenus.delete(index);\n closeCb(index);\n });\n menu.addEventListener(MENU_CONSTANTS.events.SELECT, (evt: CustomEvent<IMenuSelectEventData>) => {\n evt.stopPropagation();\n selectCb({ ...evt.detail, parentValue });\n });\n\n return menu;\n }\n\n public closeOtherChildMenus(excludeIndex?: number): void {\n const menusToRemove: number[] = [];\n this._childMenus.forEach((menu, index) => {\n if (index !== excludeIndex) {\n menu.open = false;\n menusToRemove.push(index);\n }\n });\n menusToRemove.forEach(index => this._childMenus.delete(index));\n }\n\n public setSelectedValues(values: any[]): void {\n this._listDropdown?.setSelectedValues(values);\n }\n\n private _getOpenChildMenu(id: string): IMenuComponent | null {\n if (!this.getDropdownElement()) {\n return null;\n }\n const list = this._getOwnList(id);\n return list ? list.querySelector(`${MENU_CONSTANTS.elementName}[${MENU_CONSTANTS.attributes.OPEN}]`) : null;\n }\n\n private _getOwnList(id: string): IListComponent | null {\n const popup = this.getDropdownElement();\n if (!popup) {\n return null;\n }\n return popup.querySelector(`${LIST_CONSTANTS.elementName}[id=\"list-dropdown-list-${id}\"]`);\n }\n\n private _getListItems(): IListItemComponent[] {\n const popup = this.getDropdownElement();\n if (!popup) {\n return [];\n }\n const listElement = popup.querySelector(LIST_CONSTANTS.elementName);\n if (listElement) {\n return Array.from(listElement.querySelectorAll(LIST_ITEM_CONSTANTS.elementName)) as IListItemComponent[];\n }\n return [];\n }\n}\n", "import { ICustomElementFoundation, isArray, randomChars } from '@tylertech/forge-core';\nimport { ICON_CLASS_NAME } from '../constants';\nimport { CascadingListDropdownAwareFoundation, IListDropdownCascadingElementFactoryConfig, IListDropdownConfig, ListDropdownAsyncStyle, ListDropdownType } from '../list-dropdown';\nimport { isListDropdownOptionType, ListDropdownOptionType } from '../list-dropdown/list-dropdown-utils';\nimport { IPopupPosition, PopupPlacement } from '../popup';\nimport { IMenuOption } from './index';\nimport { IMenuAdapter } from './menu-adapter';\nimport { IMenuActiveChangeEventData, IMenuOptionGroup, IMenuSelectEventData, MenuMode, MenuOptionBuilder, MenuOptionFactory, MENU_CONSTANTS } from './menu-constants';\n\nexport interface IMenuFoundation extends ICustomElementFoundation {\n initialize(): void;\n disconnect(): void;\n onKeydown(evt: KeyboardEvent): void;\n open: boolean;\n options: Array<IMenuOption | IMenuOptionGroup>;\n optionsFactory: MenuOptionFactory | undefined;\n selectedIndex: number;\n selectedValue: any;\n placement: PopupPlacement;\n fallbackPlacements: PopupPlacement[];\n dense: boolean;\n iconClass: string;\n persistSelection: boolean;\n mode: MenuMode;\n popupOffset: IPopupPosition;\n optionBuilder: MenuOptionBuilder | undefined;\n activateFirstOption(): void;\n}\n\nexport class MenuFoundation extends CascadingListDropdownAwareFoundation<IMenuOption | IMenuOptionGroup> implements IMenuFoundation {\n private _optionsFactory: MenuOptionFactory | undefined;\n private _placement: PopupPlacement = 'bottom-start';\n private _fallbackPlacements: PopupPlacement[] = [];\n private _dense = false;\n private _selectedValue: any;\n private _iconClass = ICON_CLASS_NAME;\n private _persistSelection = false;\n private _mode: MenuMode = 'click';\n private _popupOffset: IPopupPosition;\n private _optionBuilder: MenuOptionBuilder | undefined;\n private _identifier: string;\n private _clickListener: (evt: MouseEvent) => void;\n private _blurListener: (evt: MouseEvent) => void;\n private _selectListener: (value: any) => void;\n private _keydownListener: (evt: KeyboardEvent) => void;\n private _activeChangeListener: (id: string) => void;\n \n constructor(private _adapter: IMenuAdapter) {\n super({\n popupTimeout: MENU_CONSTANTS.numbers.POPUP_MOUSE_LEAVE_TIMEOUT,\n targetTimeout: MENU_CONSTANTS.numbers.CHILD_MOUSE_LEAVE_TIMEOUT\n });\n this._identifier = randomChars();\n this._clickListener = evt => this._onTargetClick(evt);\n this._blurListener = evt => this._onTargetBlur(evt);\n this._selectListener = value => this._handleSelectEvent(value);\n this._keydownListener = evt => this.onKeydown(evt);\n this._activeChangeListener = id => this._onActiveOptionChanged(id);\n }\n\n public initialize(): void {\n this._adapter.initializeTarget();\n this._adapter.initializeAccessibility(this._identifier);\n this._initializeInteractionListeners();\n }\n\n public disconnect(): void {\n if (this._open) {\n this._closeDropdown();\n }\n this._destroyInteractionListeners();\n }\n\n public activateFirstOption(): void {\n this._adapter.activateFirstOption();\n }\n\n private _applyMode(): void {\n if (!this._adapter.hasTargetElement()) {\n return;\n }\n\n if (this._mode !== 'cascade') {\n this._adapter.addTargetListener('click', this._clickListener);\n } else {\n this._attachCascadingListeners();\n }\n }\n\n private _initializeInteractionListeners(): void {\n if (!this._adapter.hasTargetElement()) {\n return;\n }\n this._applyMode();\n this._adapter.addTargetListener('keydown', this._keydownListener, true);\n this._adapter.addTargetListener('focusout', this._blurListener);\n }\n\n private _destroyInteractionListeners(): void {\n if (!this._adapter.hasTargetElement()) {\n return;\n }\n this._adapter.removeTargetListener('keydown', this._clickListener);\n this._adapter.removeTargetListener('focusout', this._blurListener);\n this._adapter.removeTargetListener('click', this._clickListener);\n this._detachCascadingListeners();\n }\n\n protected _attachCascadingListeners(): void {\n this._adapter.addTargetListener('mouseenter', this._targetMouseEnterListener);\n this._adapter.addTargetListener('mouseleave', this._targetMouseLeaveListener);\n\n // We listen for document mousemove events only to track mouse coords for use when determining\n // if popups should open/close after specific delays\n this._adapter.addDocumentListener('mousemove', this._documentMouseMoveListener);\n }\n\n protected _detachCascadingListeners(): void {\n this._adapter.removeTargetListener('mouseenter', this._targetMouseEnterListener);\n this._adapter.removeTargetListener('mouseleave', this._targetMouseLeaveListener);\n this._adapter.removeDocumentListener('mousemove', this._documentMouseMoveListener);\n }\n\n private get _nonDividerOptions(): IMenuOption[] {\n return this._flatOptions.filter(o => !o.divider);\n }\n\n private get _flatOptions(): IMenuOption[] {\n if (isListDropdownOptionType(this._options, ListDropdownOptionType.Group)) {\n return (this._options as IMenuOptionGroup[]).reduce((previousValue, currentValue) => previousValue.concat(currentValue.options), [] as IMenuOption[]) as IMenuOption[];\n }\n return this._options as IMenuOption[];\n }\n\n private _onTargetClick(evt: MouseEvent): void {\n if (this._open) {\n this._closeDropdown();\n return;\n }\n this.open = !this._open;\n if (this._open) {\n this._adapter.focusTarget();\n }\n }\n\n private _onTargetBlur(evt: Event): void {\n if (this._open) {\n this._closeDropdown();\n }\n }\n\n private _onActiveOptionChanged(id: string): void {\n // We need to dispatch an event when the active descendant changes to propagate that to the proper target element\n const data: IMenuActiveChangeEventData = { id };\n const canSetActiveDescendant = this._adapter.emitHostEvent(MENU_CONSTANTS.events.ACTIVE_CHANGE, data, true, true);\n if (this._mode !== 'cascade' && canSetActiveDescendant) {\n this._adapter.updateActiveDescendant(id);\n }\n }\n\n public onKeydown(evt: KeyboardEvent): void {\n // If we have any child menus open, we need to proxy the keyboard events to those and exit\n if (this._childOpen) {\n this._adapter.proxyKeyboardEventToChild(evt, this._identifier);\n return;\n }\n\n switch (evt.code) {\n case 'Tab':\n if (this._open) {\n this._selectActiveOption();\n }\n break;\n case 'Escape':\n if (this._open) {\n evt.preventDefault();\n evt.stopPropagation();\n this._closeDropdown();\n }\n break;\n case 'Space':\n evt.preventDefault();\n\n if (this._open) {\n this._closeDropdown();\n } else {\n this._openDropdown({ fromKeyboard: true });\n }\n break;\n case 'Home':\n case 'End':\n if (this._open) {\n evt.preventDefault();\n this._adapter.propagateKey(evt.code);\n }\n break;\n case 'Enter':\n evt.preventDefault();\n\n if (!this._open) {\n evt.preventDefault();\n this._openDropdown({ fromKeyboard: true });\n return;\n }\n\n evt.stopImmediatePropagation();\n\n this._adapter.propagateKey(evt.code);\n\n // Check if we need to toggle the child menu open state\n const activeIndex = this._adapter.getActiveOptionIndex();\n const activeOption = this._nonDividerOptions[activeIndex];\n if (activeOption && activeOption.options && activeOption.options.length) {\n this._adapter.toggleChildMenu(activeIndex);\n }\n break;\n case 'ArrowUp':\n case 'ArrowDown':\n if (this._open) {\n evt.stopImmediatePropagation();\n }\n\n evt.preventDefault();\n\n if (!this._open && evt.code === 'ArrowDown') {\n this._openDropdown({ fromKeyboard: true });\n this._adapter.activateFirstOption();\n return;\n }\n\n this._adapter.propagateKey(evt.code);\n break;\n case 'ArrowLeft':\n if (this._open) {\n evt.stopImmediatePropagation();\n }\n if (this._mode === 'cascade' && this._open) {\n this._closeDropdown();\n }\n break;\n case 'ArrowRight':\n if (this._open) {\n evt.stopImmediatePropagation();\n }\n if (!this._open) {\n return;\n }\n const hoveredIndex = this._adapter.getActiveOptionIndex();\n const hoveredOption = this._nonDividerOptions[hoveredIndex];\n if (hoveredOption && hoveredOption.options) {\n this._adapter.toggleChildMenu(hoveredIndex, evt.code === 'ArrowRight');\n return;\n }\n break;\n }\n }\n\n private async _openMenu({ fromKeyboard }: { fromKeyboard?: boolean } = {}): Promise<void> {\n this._open = true;\n let options: IMenuOption[] = [];\n\n if (typeof this._optionsFactory === 'function') {\n this._loadOptionsAsync();\n this._options = [];\n } else {\n if (!this._options || !this._options.length) {\n return;\n }\n options = this._options as IMenuOption[];\n }\n\n if (!this._persistSelection) {\n options.forEach(o => o.selected = false);\n }\n\n this._mapIconToLeadingIcon();\n\n const selectedValues = this._persistSelection ? this._getSelectedValues() : [];\n\n const config: IListDropdownConfig = {\n id: this._identifier,\n type: ListDropdownType.Menu,\n options: this._options,\n selectedValues,\n iconClass: this._iconClass,\n dense: this._dense,\n multiple: false,\n popupStatic: true,\n allowBusy: true,\n asyncStyle: ListDropdownAsyncStyle.Spinner,\n optionBuilder: this._optionBuilder,\n optionLimit: this._optionLimit,\n headerBuilder: this._popupHeaderBuilder,\n footerBuilder: this._popupFooterBuilder,\n observeScroll: this._observeScroll,\n observeScrollThreshold: this._observeScrollThreshold,\n popupPlacement: this._placement,\n popupFallbackPlacements: this._fallbackPlacements,\n activeStartIndex: fromKeyboard ? 0 : undefined,\n popupClasses: [\n MENU_CONSTANTS.classes.POPUP,\n MENU_CONSTANTS.classes.MENU,\n ...this._popupClasses as string[]\n ],\n syncWidth: this._syncPopupWidth,\n activeChangeCallback: this._activeChangeListener,\n selectCallback: this._selectListener,\n popupOffset: this._popupOffset,\n cascadingElementFactory: params => this._createCascadingElement(params)\n };\n\n this._adapter.setHostAttribute(MENU_CONSTANTS.attributes.OPEN, '');\n this._adapter.attachMenu(config);\n\n // If this menu is in a hover mode, we need to listen for mouse enter/leave events to know when the user is hovering over the popup\n if (this._mode === 'cascade') {\n this._adapter.addDropdownListener('mouseenter', this._childPopupMouseEnterListener);\n this._adapter.addDropdownListener('mouseleave', this._childPopupMouseLeaveListener);\n }\n \n this._adapter.addDropdownListener(MENU_CONSTANTS.events.ACTIVE_CHANGE, (evt: CustomEvent<IMenuActiveChangeEventData>) => {\n this._onActiveOptionChanged(evt.detail.id);\n });\n this._adapter.emitHostEvent(MENU_CONSTANTS.events.OPEN);\n }\n\n private _closeMenu(): void {\n this._open = false;\n this._childOpen = false;\n this._adapter.detachMenu();\n\n if (this._activeMouseLeaveTimeout !== undefined) {\n window.clearTimeout(this._activeMouseLeaveTimeout);\n }\n\n this._adapter.removeHostAttribute(MENU_CONSTANTS.attributes.OPEN);\n this._adapter.emitHostEvent(MENU_CONSTANTS.events.CLOSE);\n }\n\n private _loadOptionsAsync(): Promise<void> {\n if (!this._optionsFactory) {\n if (this._open) {\n this._closeMenu();\n }\n return Promise.resolve();\n }\n\n return Promise.resolve(this._optionsFactory())\n .then(results => {\n if (!this._persistSelection) {\n results.forEach(o => o.selected = false);\n }\n\n if (this._open) {\n if (results && isArray(results) && results.length) {\n this._options = results;\n this._adapter.setOptions(results);\n const selectedValues = this._getSelectedValues();\n if (selectedValues.length) {\n this._adapter.setSelectedValues(selectedValues);\n }\n } else if (this._open) {\n this._closeDropdown();\n }\n }\n })\n .catch(e => {\n console.error('An unexpected error ocurred while opening the menu:', e);\n if (this._open) {\n this._closeDropdown();\n }\n });\n }\n\n private _handleSelectEvent(value: any): void {\n const index = this._nonDividerOptions.findIndex(o => o.value === value);\n if (index < 0) {\n return;\n }\n this._selectOptionByIndex(index);\n }\n\n private _selectActiveOption(): void {\n const index = this._adapter.getActiveOptionIndex();\n if (index >= 0 && this._nonDividerOptions[index]) {\n this._selectOptionByIndex(index);\n }\n }\n\n private _selectOptionByIndex(index: number): void {\n const { options, value } = this._nonDividerOptions[index];\n\n // We ignore selections if the option has child options\n if (options) {\n this._adapter.setActiveOption(index);\n return;\n }\n\n this._closeDropdown();\n \n const data: IMenuSelectEventData = { index, value };\n const isCancelled = !this._adapter.emitHostEvent(MENU_CONSTANTS.events.SELECT, data, true, true);\n if (!isCancelled) {\n this._selectedValue = this._persistSelection ? value : undefined;\n }\n }\n\n private _getSelectedValues(): any[] {\n const values = this._flatOptions.filter(o => o.selected).map(o => o.value);\n if (this._selectedValue !== undefined) {\n values.push(this._selectedValue);\n }\n return values;\n }\n\n /** Called when a child menu option is selected. */\n protected _onCascadingOptionSelected(data: IMenuSelectEventData): void {\n if (this._persistSelection) {\n this._selectedValue = data.value;\n }\n this._adapter.emitHostEvent(MENU_CONSTANTS.events.SELECT, data);\n this._closeDropdown();\n }\n\n /** Called when a child menu is opened off of one of our menu options. */\n protected _onCascadingChildOpen(index: number): void {\n super._clearMouseLeaveTimeout();\n this._adapter.closeOtherChildMenus(index);\n this._childOpen = true;\n this._adapter.setActiveOption(index);\n }\n\n /** Called when a child menu is closed off of one of our menu options. */\n protected _onCascadingChildClose(index: number): void {\n this._childOpen = false;\n }\n\n protected _closeDropdown(): void {\n this._closeMenu();\n }\n\n protected _openDropdown({ fromKeyboard }: { fromKeyboard?: boolean } = {}): void {\n this._openMenu({ fromKeyboard });\n }\n\n protected _setCascadeTargetInactive(): void {\n this._adapter.setCascadeTargetInactive();\n }\n\n protected _isOwnElement(element: Element): boolean {\n return this._adapter.isOwnElement(element);\n }\n\n private _createCascadingElement({ index, options, parentValue }: IListDropdownCascadingElementFactoryConfig): HTMLElement {\n const menu = this._adapter.createChildMenu(\n index,\n parentValue,\n this._onCascadingChildOpen.bind(this),\n this._onCascadingChildClose.bind(this),\n this._onCascadingOptionSelected.bind(this)\n );\n menu.mode = 'cascade';\n menu.popupOffset = { x: 0, y: -8 };\n menu.dense = this._dense;\n menu.placement = 'right-start';\n menu.fallbackPlacements = ['left-start', 'right-start']; // Cascading menus should only fallback to left or right placement if needed\n menu.persistSelection = this._persistSelection;\n if (this._persistSelection) {\n menu.selectedValue = this._selectedValue;\n }\n menu.options = options;\n menu.optionBuilder = this._optionBuilder;\n menu.iconClass = this._iconClass;\n\n return menu;\n }\n\n private _mapIconToLeadingIcon(): void {\n // For backwards compatibility with old API, map the old \"icon\" property to the new \"leadingIcon\" property (if exists)\n this._flatOptions.filter(o => o.icon).forEach(o => o.leadingIcon = o.icon);\n }\n\n public get open(): boolean {\n return this._open;\n }\n public set open(value: boolean) {\n value = Boolean(value);\n if (this._open !== value) {\n this._open = value;\n if (value) {\n this._openDropdown();\n } else {\n this._closeDropdown();\n }\n }\n }\n\n public set options(options: IMenuOption[]) {\n if (typeof options === 'function') {\n this.optionsFactory = options;\n } else {\n this.optionsFactory = undefined;\n // Intentional shallow copy of member properties. These member objects have properties that are references to functions.\n // The typical JSON.parse(JSON.stringify(object)) will not work here. If this becomes an issue we'll add a deepClone\n // function to the core library.\n this._options = options.map(o => ({ ...o }));\n \n if (this._open) {\n this._mapIconToLeadingIcon();\n this._adapter.setOptions(this._options as IMenuOption[]);\n if (this._persistSelection) {\n const selectedValues = this._getSelectedValues();\n if (selectedValues.length) {\n this._adapter.setSelectedValues(selectedValues);\n }\n }\n }\n }\n }\n public get options(): IMenuOption[] {\n if (!this._options) {\n return [];\n }\n\n // Intentional shallow copy of member properties. These member objects have properties that are references to functions.\n // The typical JSON.parse(JSON.stringify(object)) will not work here. If this becomes an issue we'll add a deepClone\n // function to the core library.\n return this._flatOptions.map(o => ({ ...o }));\n }\n\n public set optionsFactory(factory: MenuOptionFactory | undefined) {\n this._optionsFactory = factory;\n }\n\n public set selectedIndex(value: number) {\n const option = this._nonDividerOptions[value];\n if (option && option.value !== this._selectedValue) {\n this.selectedValue = option.value;\n }\n }\n public get selectedIndex(): number {\n return this._selectedValue !== undefined ? this._nonDividerOptions.findIndex(o => o.value === this._selectedValue) : -1;\n }\n\n public set selectedValue(value: any) {\n if (this._selectedValue !== value) {\n this._selectedValue = value;\n this._adapter.setSelectedValues(this._selectedValue);\n }\n }\n public get selectedValue(): any {\n return this._selectedValue;\n }\n\n public get placement(): PopupPlacement {\n return this._placement;\n }\n public set placement(value: PopupPlacement) {\n if (this._placement !== value) {\n this._placement = value || 'bottom-start';\n this._adapter.setHostAttribute(MENU_CONSTANTS.attributes.PLACEMENT, this._placement);\n }\n }\n\n public get fallbackPlacements(): PopupPlacement[] {\n return this._fallbackPlacements;\n }\n public set fallbackPlacements(value: PopupPlacement[]) {\n this._fallbackPlacements = Array.isArray(value) ? value : [];\n }\n\n public get dense(): boolean {\n return this._dense;\n }\n public set dense(value: boolean) {\n this._dense = value;\n }\n\n public get iconClass(): string {\n return this._iconClass;\n }\n public set iconClass(value: string) {\n this._iconClass = value;\n }\n\n public get persistSelection(): boolean {\n return this._persistSelection;\n }\n public set persistSelection(value: boolean) {\n if (this._persistSelection === value) {\n return;\n }\n\n this._persistSelection = value;\n this._adapter.toggleHostAttribute(MENU_CONSTANTS.attributes.PERSIST_SELECTION, this._persistSelection);\n\n if (!this._persistSelection) {\n this._flatOptions.forEach(o => o.selected = false);\n this._selectedValue = undefined;\n }\n }\n\n public get mode(): MenuMode {\n return this._mode;\n }\n public set mode(value: MenuMode) {\n if (this._mode !== value) {\n this._mode = value;\n this._destroyInteractionListeners();\n this._applyMode();\n this._adapter.setHostAttribute(MENU_CONSTANTS.attributes.MODE, this._mode);\n }\n }\n\n public get popupOffset(): IPopupPosition {\n return this._popupOffset;\n }\n public set popupOffset(value: IPopupPosition) {\n this._popupOffset = value;\n }\n\n public get optionBuilder(): MenuOptionBuilder | undefined {\n return this._optionBuilder;\n }\n public set optionBuilder(cb: MenuOptionBuilder | undefined) {\n this._optionBuilder = cb;\n }\n\n public get popupElement(): HTMLElement | null {\n return this._adapter.getDropdownElement();\n }\n}\n", "import { attachShadowTemplate, coerceBoolean, CustomElement, ensureChild, FoundationProperty, isDefined } from '@tylertech/forge-core';\nimport { tylIconArrowRight } from '@tylertech/tyler-icons/standard';\nimport { CircularProgressComponent } from '../circular-progress';\nimport { IconRegistry } from '../icon';\nimport { LinearProgressComponent } from '../linear-progress';\nimport { ListComponent } from '../list';\nimport { IListDropdownAware, ListDropdownAware } from '../list-dropdown/list-dropdown-aware';\nimport { IPopupPosition, PopupComponent, PopupPlacement } from '../popup';\nimport { MenuAdapter } from './menu-adapter';\nimport { IMenuActiveChangeEventData, IMenuOption, IMenuOptionGroup, IMenuSelectEventData, MenuMode, MenuOptionBuilder, MenuOptionFactory, MENU_CONSTANTS } from './menu-constants';\nimport { MenuFoundation } from './menu-foundation';\nconst template = '<template><slot></slot></template>';\nconst styles = ':host{display:inline-block}:host([hidden]){display:none}';\n\nexport interface IMenuComponent extends IListDropdownAware {\n open: boolean;\n options: Array<IMenuOption | IMenuOptionGroup> | MenuOptionFactory;\n selectedIndex: number;\n selectedValue: number;\n placement: PopupPlacement;\n fallbackPlacements: PopupPlacement[];\n dense: boolean;\n iconClass: string;\n persistSelection: boolean;\n mode: MenuMode;\n popupOffset: IPopupPosition;\n optionBuilder: MenuOptionBuilder | undefined;\n popupElement: HTMLElement | undefined;\n propagateKeyEvent(evt: KeyboardEvent): void;\n activateFirstOption(): void;\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'forge-menu': IMenuComponent;\n }\n\n interface HTMLElementEventMap {\n 'forge-menu-select': CustomEvent<IMenuSelectEventData>;\n 'forge-menu-open': CustomEvent<void>;\n 'forge-menu-close': CustomEvent<void>;\n 'forge-menu-active-change': CustomEvent<IMenuActiveChangeEventData>;\n }\n}\n\n/**\n * The web component class behind the `<forge-menu>` custom element.\n * \n * @tag forge-menu\n */\n@CustomElement({\n name: MENU_CONSTANTS.elementName,\n dependencies: [\n PopupComponent,\n ListComponent,\n CircularProgressComponent,\n LinearProgressComponent\n ]\n})\nexport class MenuComponent extends ListDropdownAware implements IMenuComponent {\n public static get observedAttributes(): string[] {\n return [\n MENU_CONSTANTS.attributes.OPEN,\n MENU_CONSTANTS.attributes.PLACEMENT,\n MENU_CONSTANTS.attributes.SELECTED_INDEX,\n MENU_CONSTANTS.attributes.SELECTED_VALUE,\n MENU_CONSTANTS.attributes.DENSE,\n MENU_CONSTANTS.attributes.ICON_CLASS,\n MENU_CONSTANTS.attributes.PERSIST_SELECTION,\n MENU_CONSTANTS.attributes.MODE,\n MENU_CONSTANTS.attributes.SYNC_POPUP_WIDTH,\n MENU_CONSTANTS.attributes.POPUP_CLASSES,\n MENU_CONSTANTS.attributes.OPTION_LIMIT,\n MENU_CONSTANTS.attributes.OBSERVE_SCROLL,\n MENU_CONSTANTS.attributes.OBSERVE_SCROLL_THRESHOLD\n ];\n }\n\n private _foundation: MenuFoundation;\n\n constructor() {\n super();\n IconRegistry.define(tylIconArrowRight);\n this._foundation = new MenuFoundation(new MenuAdapter(this));\n attachShadowTemplate(this, template, styles);\n }\n\n public connectedCallback(): void {\n if (this.querySelector(MENU_CONSTANTS.selectors.TOGGLE)) {\n this._foundation.initialize();\n } else {\n ensureChild(this, MENU_CONSTANTS.selectors.TOGGLE).then(() => this._foundation.initialize());\n }\n }\n\n public attributeChangedCallback(name: string, oldValue: string, newValue: string): void {\n super.attributeChangedCallback(name, oldValue, newValue);\n switch (name) {\n case MENU_CONSTANTS.attributes.OPEN:\n this._foundation.open = isDefined(newValue);\n break;\n case MENU_CONSTANTS.attributes.PLACEMENT:\n this._foundation.placement = newValue as PopupPlacement;\n break;\n case MENU_CONSTANTS.attributes.SELECTED_INDEX:\n this._foundation.selectedIndex = Number(newValue);\n break;\n case MENU_CONSTANTS.attributes.SELECTED_VALUE:\n this._foundation.selectedValue = newValue;\n break;\n case MENU_CONSTANTS.attributes.DENSE:\n this._foundation.dense = coerceBoolean(newValue);\n break;\n case MENU_CONSTANTS.attributes.ICON_CLASS:\n this._foundation.iconClass = newValue;\n break;\n case MENU_CONSTANTS.attributes.PERSIST_SELECTION:\n this.persistSelection = coerceBoolean(newValue);\n break;\n case MENU_CONSTANTS.attributes.MODE:\n this.mode = newValue as MenuMode;\n break;\n }\n }\n\n public disconnectedCallback(): void {\n this._foundation.disconnect();\n }\n\n /** Gets/sets the open state. */\n @FoundationProperty()\n public declare open: boolean;\n\n /** Gets/sets the array of options to display in the menu. */\n @FoundationProperty()\n public declare options: Array<IMenuOption | IMenuOptionGroup> | MenuOptionFactory;\n\n /** Gets/sets the selected option to the index. Does not support cascading menus. */\n @FoundationProperty()\n public declare selectedIndex: number;\n\n /** Gets/sets the value of the option to select. */\n @FoundationProperty()\n public declare selectedValue: any;\n\n /** Gets/sets the menu placement (default is bottom-left). */\n @FoundationProperty()\n public declare placement: `${PopupPlacement}`;\n\n /** Gets/sets the fallback menu placement for overriding the default of any side. */\n @FoundationProperty()\n public declare fallbackPlacements: `${PopupPlacement}`[];\n\n /** Gets/sets dense state of the list options used in the menu popup. */\n @FoundationProperty()\n public declare dense: boolean;\n\n /** Gets/sets the class name to use for option icons. */\n @FoundationProperty()\n public declare iconClass: string;\n\n /**\n * Gets/sets whether selection of menu items is persisted.\n * @deprecated Please use `<forge-select-dropdown>` for handling selection states.\n */\n @FoundationProperty()\n public declare persistSelection: boolean;\n\n /** Gets/sets the mode that this menu is using. */\n @FoundationProperty()\n public declare mode: MenuMode;\n\n /** Sets the position adjustment on the internal popup element. */\n @FoundationProperty()\n public declare popupOffset: IPopupPosition;\n\n /** Sets the callback that will be executed for each option in the dropdown for producing custom option templates. */\n @FoundationProperty()\n public declare optionBuilder: MenuOptionBuilder;\n\n /** Gets the currently active popup element when the dropdown is open. */\n @FoundationProperty({ set: false })\n public declare popupElement: HTMLElement | undefined;\n\n /** Force propagates the key event from another element this component. */\n public propagateKeyEvent(evt: KeyboardEvent): void {\n this._foundation.onKeydown(evt);\n }\n\n public activateFirstOption(): void {\n this._foundation.activateFirstOption();\n }\n}\n", "import { defineCustomElement } from '@tylertech/forge-core';\n\nimport { MenuComponent } from './menu';\n\nexport * from './menu-adapter';\nexport * from './menu-constants';\nexport * from './menu-foundation';\nexport * from './menu';\n\nexport function defineMenuComponent(): void {\n defineCustomElement(MenuComponent);\n}\n"],
|
|
5
|
-
"mappings": "wsBAGA,IAAMA,EAA2C,GAAGC,QAE9CC,EAAU,CACd,MAAO,oBACP,KAAM,UACR,EAEMC,EAAY,CAChB,OAAQ,IAAIH,cAAwBA,iFACpC,UAAW,YACb,EAEMI,EAAa,CACjB,KAAM,OACN,UAAW,YACX,eAAgB,iBAChB,eAAgB,iBAChB,MAAO,QACP,WAAY,aACZ,kBAAmB,oBACnB,KAAM,OACN,iBAAkB,mBAClB,cAAe,gBACf,aAAc,eACd,eAAgB,iBAChB,yBAA0B,0BAC5B,EAEMC,EAAS,CACb,OAAQ,GAAGL,WACX,KAAM,GAAGA,SACT,MAAO,GAAGA,UACV,cAAe,GAAGA,iBACpB,EAEMM,EAAU,CACd,0BAA2B,IAC3B,0BAA2B,GAC7B,EAEaC,EAAiB,CAC5B,YAAAP,EACA,QAAAE,EACA,UAAAC,EACA,WAAAC,EACA,OAAAC,EACA,QAAAC,CACF,EChBO,IAAME,EAAN,cAA0BC,CAAoD,CAKnF,YAAYC,EAA2B,CACrC,MAAMA,CAAS,EAHjB,KAAQ,YAAc,IAAI,GAI1B,CAEO,oBAAyC,CA3ClD,IAAAC,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AAmB,GA9GThB,EA+GI,oBAIAe,EAAA,CADdC,EAAmB,GAlHThB,EAmHI,2BAIAe,EAAA,CADdC,EAAmB,GAtHThB,EAuHI,6BAIAe,EAAA,CADdC,EAAmB,CAAE,IAAK,EAAM,CAAC,GA1HvBhB,EA2HI,4BA3HJA,EAANe,EAAA,CATNE,EAAc,CACb,KAAMV,EAAe,YACrB,aAAc,CACZW,EACAC,EACAC,EACAC,CACF,CACF,CAAC,GACYrB,GClDN,SAASsB,IAA4B,CAC1CC,EAAoBC,CAAa,CACnC",
|
|
6
|
-
"names": ["elementName", "COMPONENT_NAME_PREFIX", "classes", "selectors", "attributes", "events", "numbers", "MENU_CONSTANTS", "MenuAdapter", "BaseAdapter", "component", "_a", "_b", "MENU_CONSTANTS", "id", "event", "callback", "bubbles", "config", "ListDropdown", "options", "index", "listItem", "type", "listener", "el", "key", "evt", "openMenu", "open", "childMenu", "parentValue", "openCb", "closeCb", "selectCb", "menu", "__spreadProps", "__spreadValues", "excludeIndex", "menusToRemove", "values", "list", "popup", "LIST_CONSTANTS", "listElement", "LIST_ITEM_CONSTANTS", "MenuFoundation", "CascadingListDropdownAwareFoundation", "_adapter", "MENU_CONSTANTS", "ICON_CLASS_NAME", "randomChars", "evt", "value", "id", "o", "isListDropdownOptionType", "previousValue", "currentValue", "data", "canSetActiveDescendant", "activeIndex", "activeOption", "hoveredIndex", "hoveredOption", "fromKeyboard", "options", "selectedValues", "config", "params", "results", "isArray", "index", "values", "element", "parentValue", "menu", "__spreadValues", "factory", "option", "cb", "template", "styles", "MenuComponent", "ListDropdownAware", "IconRegistry", "tylIconArrowRight", "MenuFoundation", "MenuAdapter", "attachShadowTemplate", "MENU_CONSTANTS", "ensureChild", "name", "oldValue", "newValue", "isDefined", "coerceBoolean", "evt", "__decorateClass", "FoundationProperty", "CustomElement", "PopupComponent", "ListComponent", "CircularProgressComponent", "LinearProgressComponent", "defineMenuComponent", "defineCustomElement", "MenuComponent"]
|
|
7
|
-
}
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright 2023 Tyler Technologies, Inc.
|
|
4
|
-
* License: Apache-2.0
|
|
5
|
-
*/
|
|
6
|
-
import{d as M}from"./chunk.M2ATVI24.js";import{b as R}from"./chunk.RLWX5BFQ.js";import{n as z,r as O,s as F,u as k}from"./chunk.MZLPUI6R.js";import{d as C}from"./chunk.73GVVX4K.js";import{d as G,l as w}from"./chunk.IWICN773.js";import{a as B}from"./chunk.5KC43VFL.js";import{a as p}from"./chunk.KTGSZEAG.js";import{a as x,b as N}from"./chunk.QOA2O575.js";import{a as T,e as y,g as n,j as _,l as I}from"./chunk.HOXFK44F.js";import{d as A,f as u,g as L,t as S}from"./chunk.4LA6HEA7.js";import{b as h,i as E,k as c,l as d}from"./chunk.J2M2MXP2.js";import{a as v,b as P,f as s}from"./chunk.MCIQXNKY.js";var U=`${N}paginator`,g={LABEL:"forge-paginator__label",PAGE_SIZE_OPTIONS:"forge-paginator__page-size-options",RANGE_LABEL:"forge-paginator__range-label",RANGE_LABEL_ALTERNATIVE:"forge-paginator__range-label--alternative",FIRST_PAGE_BUTTON:"forge-paginator__first-page",PREVIOUS_PAGE_BUTTON:"forge-paginator__previous-page",NEXT_PAGE_BUTTON:"forge-paginator__next-page",LAST_PAGE_BUTTON:"forge-paginator__last-page",ROOT:"forge-paginator",ALTERNATIVE:"forge-paginator--alternative",ALIGNMENT_START:"forge-paginator--alignment-start",ALIGNMENT_SPACE_BETWEEN:"forge-paginator--alignment-center",ALIGNMENT_END:"forge-paginator--alignment-end"},D={LABEL:`.${g.LABEL}`,PAGE_SIZE_SELECT:`.${g.PAGE_SIZE_OPTIONS}`,RANGE_LABEL:`.${g.RANGE_LABEL}`,FIRST_PAGE_BUTTON:`.${g.FIRST_PAGE_BUTTON} > button`,FIRST_PAGE_ICON_BUTTON:`.${g.FIRST_PAGE_BUTTON}`,PREVIOUS_PAGE_BUTTON:`.${g.PREVIOUS_PAGE_BUTTON} > button`,NEXT_PAGE_BUTTON:`.${g.NEXT_PAGE_BUTTON} > button`,LAST_PAGE_BUTTON:`.${g.LAST_PAGE_BUTTON} > button`,LAST_PAGE_ICON_BUTTON:`.${g.LAST_PAGE_BUTTON}`,ROOT:`.${g.ROOT}`,RANGE_LABEL_ALTERNATIVE:`.${g.RANGE_LABEL_ALTERNATIVE}`},H={PAGE_INDEX:"page-index",PAGE_SIZE:"page-size",OFFSET:"offset",PAGE_SIZE_OPTIONS:"page-size-options",TOTAL:"total",LABEL:"label",FIRST_LAST:"first-last",FIRST:"first",DISABLED:"disabled",ALTERNATIVE:"alternative",ALIGNMENT:"alignment"},$={CHANGE:`${U}-change`},Z={DEFAULT_PAGE_INDEX:0,DEFAULT_TOTAL:0,DEFAULT_PAGE_SIZE:25,DEFAULT_PAGE_SIZE_OPTIONS:[5,15,25,50,100]},X={DEFAULT_LABEL:"Rows per page:",RANGE_SEPARATOR_LABEL:"of",FIRST_PAGE:"first-page",PREVIOUS_PAGE:"previous-page",NEXT_PAGE:"next-page",LAST_PAGE:"last-page",PAGE_SIZE:"page-size"},i={elementName:U,classes:g,selectors:D,attributes:H,events:$,numbers:Z,strings:X};var b=class{constructor(e){this._adapter=e;this._pageIndex=i.numbers.DEFAULT_PAGE_INDEX;this._pageSize=i.numbers.DEFAULT_PAGE_SIZE;this._offset=0;this._total=i.numbers.DEFAULT_TOTAL;this._pageSizeOptions=i.numbers.DEFAULT_PAGE_SIZE_OPTIONS.map(e=>({label:`${e}`,value:`${e}`}));this._label=i.strings.DEFAULT_LABEL;this._firstLast=!1;this._first=!1;this._disabled=!1;this._alignment="space-between";this._pageSizeListener=t=>this._onPageSizeChanged(t),this._firstPageListener=t=>this._onFirstPage(t),this._previousPageListener=t=>this._onPreviousPage(t),this._nextPageListener=t=>this._onNextPage(t),this._lastPageListener=t=>this._onLastPage(t)}initialize(){this._updateRangeLabel(),this._adapter.setLabel(this._label),this._adapter.setPageSizeOptions(this._pageSizeOptions),this._adapter.setPageSize(this._pageSize),this._attachListeners(),this._toggleFirstLastButtons(),this._syncInteractionState()}disconnect(){this._detachListeners()}focus(e){this._adapter.handleFocusMove(null,e)}_attachListeners(){this._adapter.attachPageSizeChangeListener(this._pageSizeListener),this._adapter.attachFirstPageListener(this._firstPageListener),this._adapter.attachPreviousPageListener(this._previousPageListener),this._adapter.attachNextPageListener(this._nextPageListener),this._adapter.attachLastPageListener(this._lastPageListener)}_detachListeners(){this._adapter.detachPageSizeChangeListener(this._pageSizeListener),this._adapter.detachFirstPageListener(this._firstPageListener),this._adapter.detachPreviousPageListener(this._previousPageListener),this._adapter.detachNextPageListener(this._nextPageListener),this._adapter.detachLastPageListener(this._lastPageListener)}_onFirstPage(e){if(e.stopPropagation(),!this._hasFirstPage())return;let t=0;this._emitChangeEvent(i.strings.FIRST_PAGE,{pageIndex:t})&&this._applyPageIndex(t)}_onPreviousPage(e){if(e.stopPropagation(),!this._hasPreviousPage())return;let t=this._pageIndex-1;this._emitChangeEvent(i.strings.PREVIOUS_PAGE,{pageIndex:t})&&this._applyPageIndex(t)}_onNextPage(e){if(e.stopPropagation(),!this._hasNextPage())return;let t=this._pageIndex+1;this._emitChangeEvent(i.strings.NEXT_PAGE,{pageIndex:t})&&this._applyPageIndex(t)}_onLastPage(e){if(e.stopPropagation(),!this._hasLastPage())return;let t=this._getMaxPages();this._emitChangeEvent(i.strings.LAST_PAGE,{pageIndex:t})&&this._applyPageIndex(t)}_onPageSizeChanged(e){e.stopPropagation();let t=Number(e.detail);this._emitChangeEvent(i.strings.PAGE_SIZE,{pageIndex:0,pageSize:t})?(this._applyPageIndex(0),this._applyPageSize(t)):e.preventDefault()}_emitChangeEvent(e,{pageSize:t=this._pageSize,pageIndex:a=this._pageIndex}={}){let o=a*t,l={type:e,pageSize:t,pageIndex:a,offset:o};return this._adapter.emitHostEvent(i.events.CHANGE,l,!0,!0)}_getMaxPages(){return Math.ceil(this._total/this._pageSize)-1}_updateRangeLabel(){if(this.pageSize>1){let e=this._pageIndex*this._pageSize,a=(Math.floor(e/this._pageSize)||0)*this._pageSize+1,o=e<this._total?Math.min(e+this._pageSize,this._total):e+this._pageSize;this._rangeLabel=`${a}-${o} ${i.strings.RANGE_SEPARATOR_LABEL} ${this._total}`}else this._rangeLabel=`${this._pageIndex+1} ${i.strings.RANGE_SEPARATOR_LABEL} ${this._total}`;this._adapter.setRangeLabel(this._rangeLabel)}_syncInteractionState(){this._adapter.enableFirstPageButton(),this._adapter.enablePreviousPageButton(),this._adapter.enableNextPageButton(),this._adapter.enableLastPageButton(),this._hasFirstPage()||(this._adapter.hasFocus()&&this._adapter.handleFocusMove("first"),this._adapter.disableFirstPageButton()),this._hasPreviousPage()||(this._adapter.hasFocus()&&this._adapter.handleFocusMove("previous"),this._adapter.disablePreviousPageButton()),this._hasNextPage()||(this._adapter.hasFocus()&&this._adapter.handleFocusMove("next"),this._adapter.disableNextPageButton()),this._hasLastPage()||(this._adapter.hasFocus()&&this._adapter.handleFocusMove("last"),this._adapter.disableLastPageButton())}_toggleFirstLastButtons(){this._toggleFirstButton(),this._firstLast?this._adapter.hasLastPageButton()||this._adapter.showLastPageButton():this._adapter.hasLastPageButton()&&this._adapter.hideLastPageButton()}_toggleFirstButton(){this._first||this._firstLast?this._adapter.hasFirstPageButton()||this._adapter.showFirstPageButton():this._adapter.hasFirstPageButton()&&this._adapter.hideFirstPageButton()}_hasFirstPage(){return this._hasPreviousPage()}_hasPreviousPage(){return this._pageIndex>0&&this._pageSize>0}_hasNextPage(){let e=this._getMaxPages();return this._pageIndex<e&&this._pageSize>0}_hasLastPage(){return this._hasNextPage()}_computePageIndexFromOffset(e){e>=this._total&&(this._total>=this._pageSize?e=this._total-this._pageSize:e=0);let t=Math.min(Math.max(e,0),this._total),a=Math.floor(t/this._pageSize);this._applyPageIndex(a)}_computeOffset(){this._total>0&&(this._offset=this._pageIndex*this._pageSize)}_applyPageIndex(e){this._pageIndex=e,this._computeOffset(),this._updateRangeLabel(),this._syncInteractionState(),this._adapter.toggleHostAttribute(i.attributes.PAGE_INDEX,this._pageIndex!=null,this._pageIndex.toString())}_applyPageSize(e){this._pageSize=e,this._adapter.setPageSize(this._pageSize),this._computeOffset(),this._updateRangeLabel(),this._syncInteractionState()}_applyTotal(e){this._total=e,this._updateRangeLabel(),this._offset>0&&this._total>0&&this._computePageIndexFromOffset(this._offset),this._syncInteractionState()}_applyAlternativeAlignment(){this._adapter.setHostAttribute(i.attributes.ALIGNMENT,this._alignment),this._adapter.setAlignment(this._alignment)}_applyDisabled(e){this._disabled=e,e?(this._adapter.disablePageSizeSelect(),this._adapter.disableFirstPageButton(),this._adapter.disablePreviousPageButton(),this._adapter.disableNextPageButton(),this._adapter.disableLastPageButton()):(this._adapter.enablePageSizeSelect(),this._syncInteractionState())}get pageIndex(){return this._pageIndex}set pageIndex(e){this._pageIndex!==e&&(h(e)?this._applyPageIndex(e):this._adapter.removeHostAttribute(i.attributes.PAGE_INDEX))}get pageSize(){return this._pageSize}set pageSize(e){this._pageSize!==e&&(this._applyPageSize(e),this._adapter.setHostAttribute(i.attributes.PAGE_SIZE,`${this._pageSize}`))}get offset(){return this._offset}set offset(e){this._offset!==e&&(this._offset=e,this._computePageIndexFromOffset(e))}get total(){return this._total}set total(e){this._total!==e&&(this._applyTotal(e),this._adapter.setHostAttribute(i.attributes.TOTAL,`${this._total}`))}get pageSizeOptions(){return this._pageSizeOptions.map(e=>Number(e.value))}set pageSizeOptions(e){if(E(e)){if(this._pageSizeOptions=e.map(t=>({label:t.toString(),value:t.toString()})).sort((t,a)=>d(t.value)-d(a.value)),this._adapter.setPageSizeOptions(this._pageSizeOptions),this._adapter.attachPageSizeChangeListener(this._pageSizeListener),this._adapter.setPageSizeVisibility(!0),h(this._pageSize)&&this._pageSizeOptions.length&&!this._pageSizeOptions.find(t=>d(t.value)===this._pageSize)){let t=d(this._pageSizeOptions[0].value);this._applyPageSize(t)}}else e.toString().toLowerCase()==="false"&&(this._adapter.detachPageSizeChangeListener(this._pageSizeListener),this._adapter.setPageSizeVisibility(!1))}get label(){return this._label}set label(e){this._label!==e&&(this._label=e,this._adapter.setLabel(this._label),this._adapter.setHostAttribute(i.attributes.LABEL,h(this._label)?this._label.toString():""))}get firstLast(){return this._firstLast}set firstLast(e){e=Boolean(e),this._firstLast!==e&&(this._firstLast=e,this._toggleFirstLastButtons(),this._adapter.toggleHostAttribute(i.attributes.FIRST_LAST,this._firstLast))}get first(){return this._first}set first(e){e=Boolean(e),this._first!==e&&(this._first=e,this._toggleFirstButton(),this._adapter.toggleHostAttribute(i.attributes.FIRST,this._first))}get disabled(){return this._disabled}set disabled(e){e=Boolean(e),this._disabled!==e&&(this._applyDisabled(e),this._adapter.toggleHostAttribute(i.attributes.DISABLED,this._disabled))}get alternative(){return this._alternative}set alternative(e){e!==this._alternative&&(this._alternative=e,this._adapter.setAlternative(this._alternative),this._applyAlternativeAlignment(),this._adapter.toggleHostAttribute(i.attributes.ALTERNATIVE,this._alternative))}get alignment(){return this._alignment}set alignment(e){e!==this._alignment&&(this._alignment=e,this._applyAlternativeAlignment())}};var f=class extends B{constructor(t){super(t);this._labelElement=n(t,i.selectors.LABEL),this._root=n(t,i.selectors.ROOT),this._pageSizeSelect=n(t,i.selectors.PAGE_SIZE_SELECT),this._rangeLabel=n(t,i.selectors.RANGE_LABEL),this._rangeLabelAlternative=n(t,i.selectors.RANGE_LABEL_ALTERNATIVE),this._firstPageButton=n(t,i.selectors.FIRST_PAGE_BUTTON),this._firstPageIconButton=n(t,i.selectors.FIRST_PAGE_ICON_BUTTON),this._previousPageButton=n(t,i.selectors.PREVIOUS_PAGE_BUTTON),this._nextPageButton=n(t,i.selectors.NEXT_PAGE_BUTTON),this._lastPageButton=n(t,i.selectors.LAST_PAGE_BUTTON),this._lastPageIconButton=n(t,i.selectors.LAST_PAGE_ICON_BUTTON)}setLabel(t){this._labelElement.textContent=t}setPageSizeOptions(t){A(this._pageSizeSelect),this._pageSizeSelect.options=t}setPageSize(t){this._pageSizeSelect.value=t.toString()}setRangeLabel(t){this._rangeLabel.innerText=t,this._rangeLabelAlternative.innerText=t}hasFirstPageButton(){return!!n(this._component,i.selectors.FIRST_PAGE_ICON_BUTTON)}showFirstPageButton(){this._firstPagePlaceholder=_(this._component,!0,i.elementName,i.selectors.FIRST_PAGE_ICON_BUTTON,this._firstPageIconButton,this._firstPagePlaceholder)}hideFirstPageButton(){this._firstPagePlaceholder=_(this._component,!1,i.elementName,i.selectors.FIRST_PAGE_ICON_BUTTON,this._firstPageIconButton,this._firstPagePlaceholder)}hasLastPageButton(){return!!n(this._component,i.selectors.LAST_PAGE_ICON_BUTTON)}showLastPageButton(){this._lastPagePlaceholder=_(this._component,!0,i.elementName,i.selectors.LAST_PAGE_ICON_BUTTON,this._lastPageIconButton,this._lastPagePlaceholder)}hideLastPageButton(){this._lastPagePlaceholder=_(this._component,!1,i.elementName,i.selectors.LAST_PAGE_ICON_BUTTON,this._lastPageIconButton,this._lastPagePlaceholder)}attachPageSizeChangeListener(t){this._pageSizeSelect.addEventListener("change",t)}attachFirstPageListener(t){this._firstPageButton.addEventListener("click",t)}attachPreviousPageListener(t){this._previousPageButton.addEventListener("click",t)}attachNextPageListener(t){this._nextPageButton.addEventListener("click",t)}attachLastPageListener(t){this._lastPageButton.addEventListener("click",t)}detachPageSizeChangeListener(t){this._pageSizeSelect.removeEventListener("change",t)}detachFirstPageListener(t){this._firstPageButton.removeEventListener("click",t)}detachPreviousPageListener(t){this._previousPageButton.removeEventListener("click",t)}detachNextPageListener(t){this._nextPageButton.removeEventListener("click",t)}detachLastPageListener(t){this._lastPageButton.removeEventListener("click",t)}disableFirstPageButton(){this._firstPageButton.setAttribute("disabled","disabled")}enableFirstPageButton(){this._firstPageButton.removeAttribute("disabled")}disablePreviousPageButton(){this._previousPageButton.setAttribute("disabled","disabled")}enablePreviousPageButton(){this._previousPageButton.removeAttribute("disabled")}disableNextPageButton(){this._nextPageButton.setAttribute("disabled","disabled")}enableNextPageButton(){this._nextPageButton.removeAttribute("disabled")}disablePageSizeSelect(){this._pageSizeSelect.setAttribute("disabled","disabled")}enablePageSizeSelect(){this._pageSizeSelect.removeAttribute("disabled")}setPageSizeVisibility(t){t?this._pageSizeSelect.style.removeProperty("display"):this._pageSizeSelect.style.display="none"}disableLastPageButton(){this._lastPageButton.setAttribute("disabled","disabled")}enableLastPageButton(){this._lastPageButton.removeAttribute("disabled")}setAlternative(t){S(this._root,t,i.classes.ALTERNATIVE)}setAlignment(t){switch(L([i.classes.ALIGNMENT_SPACE_BETWEEN,i.classes.ALIGNMENT_START,i.classes.ALIGNMENT_END],this._root),t){case"start":u(i.classes.ALIGNMENT_START,this._root);break;case"end":u(i.classes.ALIGNMENT_END,this._root);break;case"space-between":default:u(i.classes.ALIGNMENT_SPACE_BETWEEN,this._root);break}}hasFocus(){return this._component.matches(":focus")}handleFocusMove(t,a){if(!(t&&!this.hasFocus()))switch(t){case"first":this._tryFocus([this._nextPageButton,this._lastPageButton,this._previousPageButton,this._pageSizeSelect],a);break;case"last":this._tryFocus([this._previousPageButton,this._firstPageButton,this._nextPageButton,this._pageSizeSelect],a);break;case"previous":this._tryFocus([this._nextPageButton,this._lastPageButton,this._firstPageButton,this._pageSizeSelect]);break;case"next":this._tryFocus([this._previousPageButton,this._firstPageButton,this._lastPageButton,this._pageSizeSelect],a);break;case"page-size":this._tryFocus([this._nextPageButton,this._lastPageButton,this._firstPageButton,this._previousPageButton],a);break;default:this._tryFocus([this._firstPageButton,this._previousPageButton,this._nextPageButton,this._lastPageButton,this._pageSizeSelect],a);break}}_tryFocus(t,a){let o=typeof(a==null?void 0:a.preventScroll)=="boolean"?a.preventScroll:!0;for(let l of t)if(l&&l.isConnected&&!l.disabled){l.focus(P(v({},a),{preventScroll:o}));return}}};var V='<template><div class="forge-paginator" part="root"><div class="forge-paginator__container" part="container"><div class="forge-paginator__label" part="label"></div><forge-select class="forge-paginator__page-size-options" aria-label="Choose page size" density="dense" part="page-size-options"></forge-select><div class="forge-paginator__range-label" part="range-label"></div><forge-icon-button class="forge-paginator__first-page" part="first-page-button"><button aria-label="First Page" part="first-page-button-element"><forge-icon name="first_page" part="first-page-icon"></forge-icon></button><forge-tooltip position="top">Go to the first page</forge-tooltip></forge-icon-button><forge-icon-button class="forge-paginator__previous-page" part="previous-page-button"><button aria-label="Previous Page" part="previous-page-button-element"><forge-icon name="keyboard_arrow_left" part="previous-page-button-icon"></forge-icon></button><forge-tooltip position="top">Go to the previous page</forge-tooltip></forge-icon-button><div class="forge-paginator__range-label--alternative" part="range-label-alternative"></div><forge-icon-button class="forge-paginator__next-page" part="next-page-button"><button aria-label="Next Page" part="next-page-button-element"><forge-icon name="keyboard_arrow_right" part="next-page-icon"></forge-icon></button><forge-tooltip position="top">Go to the next page</forge-tooltip></forge-icon-button><forge-icon-button class="forge-paginator__last-page" part="last-page-button"><button aria-label="Last Page" part="last-page-button-element"><forge-icon name="last_page" part="last-page-icon"></forge-icon></button><forge-tooltip position="top">Go to the last page</forge-tooltip></forge-icon-button></div></div></template>',j='.forge-icon-button{display:-webkit-inline-box;display:inline-flex;-webkit-box-pack:center;justify-content:center;-webkit-box-align:center;align-items:center;position:relative;-webkit-box-sizing:border-box;box-sizing:border-box;border:none;outline:0;background-color:transparent;fill:currentColor;color:inherit;font-size:24px;text-decoration:none;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;width:48px;height:48px;padding:12px}.forge-icon-button forge-icon,.forge-icon-button img,.forge-icon-button svg{width:24px;height:24px}.forge-icon-button:disabled{color:rgba(0,0,0,.38);color:var(--mdc-theme-text-disabled-on-light,rgba(0,0,0,.38))}.forge-icon-button:disabled{cursor:default;pointer-events:none}.forge-icon-button__icon{display:inline-block}.forge-icon-button__icon.forge-icon-button__icon--on{display:none}.forge-icon-button--on .forge-icon-button__icon{display:none}.forge-icon-button--on .forge-icon-button__icon.forge-icon-button__icon--on{display:inline-block}@-webkit-keyframes mdc-ripple-fg-radius-in{from{-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1);-webkit-transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1);transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1)}to{-webkit-transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1));transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1))}}@keyframes mdc-ripple-fg-radius-in{from{-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1);-webkit-transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1);transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1)}to{-webkit-transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1));transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1))}}@-webkit-keyframes mdc-ripple-fg-opacity-in{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@keyframes mdc-ripple-fg-opacity-in{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@-webkit-keyframes mdc-ripple-fg-opacity-out{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}@keyframes mdc-ripple-fg-opacity-out{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}.forge-icon-button{--mdc-ripple-fg-size:0;--mdc-ripple-left:0;--mdc-ripple-top:0;--mdc-ripple-fg-scale:1;--mdc-ripple-fg-translate-end:0;--mdc-ripple-fg-translate-start:0;-webkit-tap-highlight-color:transparent;will-change:transform,opacity}.forge-icon-button::after,.forge-icon-button::before{position:absolute;border-radius:50%;opacity:0;pointer-events:none;content:""}.forge-icon-button::before{-webkit-transition:opacity 15ms linear,background-color 15ms linear;transition:opacity 15ms linear,background-color 15ms linear;z-index:1;z-index:var(--mdc-ripple-z-index,1)}.forge-icon-button::after{z-index:0;z-index:var(--mdc-ripple-z-index,0)}.forge-icon-button.mdc-ripple-upgraded::before{-webkit-transform:scale(var(--mdc-ripple-fg-scale,1));transform:scale(var(--mdc-ripple-fg-scale,1))}.forge-icon-button.mdc-ripple-upgraded::after{top:0;left:0;-webkit-transform:scale(0);transform:scale(0);-webkit-transform-origin:center center;transform-origin:center center}.forge-icon-button.mdc-ripple-upgraded--unbounded::after{top:var(--mdc-ripple-top,0);left:var(--mdc-ripple-left,0)}.forge-icon-button.mdc-ripple-upgraded--foreground-activation::after{-webkit-animation:mdc-ripple-fg-radius-in 225ms forwards,mdc-ripple-fg-opacity-in 75ms forwards;animation:mdc-ripple-fg-radius-in 225ms forwards,mdc-ripple-fg-opacity-in 75ms forwards}.forge-icon-button.mdc-ripple-upgraded--foreground-deactivation::after{-webkit-animation:mdc-ripple-fg-opacity-out 150ms;animation:mdc-ripple-fg-opacity-out 150ms;-webkit-transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1));transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1))}.forge-icon-button::after,.forge-icon-button::before{top:calc(50% - 50%);left:calc(50% - 50%);width:100%;height:100%}.forge-icon-button.mdc-ripple-upgraded::after,.forge-icon-button.mdc-ripple-upgraded::before{top:var(--mdc-ripple-top,calc(50% - 50%));left:var(--mdc-ripple-left,calc(50% - 50%));width:var(--mdc-ripple-fg-size,100%);height:var(--mdc-ripple-fg-size,100%)}.forge-icon-button.mdc-ripple-upgraded::after{width:var(--mdc-ripple-fg-size,100%);height:var(--mdc-ripple-fg-size,100%)}.forge-icon-button::after,.forge-icon-button::before{background-color:#000;background-color:var(--mdc-ripple-color,var(--mdc-theme-on-surface,#000))}.forge-icon-button.mdc-ripple-surface--hover::before,.forge-icon-button:hover::before{opacity:.04;opacity:var(--mdc-ripple-hover-opacity, .04)}.forge-icon-button.mdc-ripple-upgraded--background-focused::before,.forge-icon-button:not(.mdc-ripple-upgraded):focus::before{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-focus-opacity, .12)}.forge-icon-button:not(.mdc-ripple-upgraded)::after{-webkit-transition:opacity 150ms linear;transition:opacity 150ms linear}.forge-icon-button:not(.mdc-ripple-upgraded):active::after{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-press-opacity, .12)}.forge-icon-button.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}forge-icon-button{position:relative;display:inline-block;overflow:visible}.forge-icon-button--on{color:#3f51b5;color:var(--mdc-theme-primary,#3f51b5)}.forge-icon-button--on::after,.forge-icon-button--on::before{background-color:#3f51b5;background-color:var(--mdc-ripple-color,var(--mdc-theme-primary,#3f51b5))}.forge-icon-button--on.mdc-ripple-surface--hover::before,.forge-icon-button--on:hover::before{opacity:.04;opacity:var(--mdc-ripple-hover-opacity, .04)}.forge-icon-button--on.mdc-ripple-upgraded--background-focused::before,.forge-icon-button--on:not(.mdc-ripple-upgraded):focus::before{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-focus-opacity, .12)}.forge-icon-button--on:not(.mdc-ripple-upgraded)::after{-webkit-transition:opacity 150ms linear;transition:opacity 150ms linear}.forge-icon-button--on:not(.mdc-ripple-upgraded):active::after{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-press-opacity, .12)}.forge-icon-button--on.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}.forge-icon-button--on::before{background-color:#3f51b5;background-color:var(--mdc-theme-primary,#3f51b5);opacity:.08}.forge-icon-button--dense{width:28px;height:28px;padding:2px;padding:0}.forge-icon-button--dense-1{width:44px;height:44px;padding:10px}.forge-icon-button--dense-2{width:40px;height:40px;padding:8px}.forge-icon-button--dense-3{width:36px;height:36px;padding:6px}.forge-icon-button--dense-4{width:32px;height:32px;padding:4px}.forge-icon-button--dense-5{width:28px;height:28px;padding:2px}.forge-icon-button--dense-6{width:24px;height:24px;padding:0}.forge-icon-button--with-badge forge-badge{z-index:1;z-index:var(--forge-z-index-surface,1);pointer-events:none;--forge-badge-max-width:32px;--forge-badge-border:1px solid transparent}.forge-icon-button--with-badge forge-badge[app-bar-context]{--forge-badge-border:2px solid var(--forge-app-bar-theme-background)}.forge-paginator{display:inline-block}.forge-paginator--alternative{display:-webkit-box;display:flex}.forge-paginator--alternative .forge-paginator__label,.forge-paginator--alternative .forge-paginator__page-size-options,.forge-paginator--alternative .forge-paginator__range-label{display:none}.forge-paginator--alternative .forge-paginator__range-label--alternative{display:inline-block;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto,sans-serif;font-family:var(--mdc-typography-body2-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:.875rem;font-size:var(--mdc-typography-body2-font-size, .875rem);line-height:1.25rem;line-height:var(--mdc-typography-body2-line-height, 1.25rem);font-weight:400;font-weight:var(--mdc-typography-body2-font-weight,400);letter-spacing:.0178571429em;letter-spacing:var(--mdc-typography-body2-letter-spacing, .0178571429em);text-decoration:inherit;-webkit-text-decoration:var(--mdc-typography-body2-text-decoration,inherit);text-decoration:var(--mdc-typography-body2-text-decoration,inherit);text-transform:inherit;text-transform:var(--mdc-typography-body2-text-transform,inherit);margin:0 12px}.forge-paginator__range-label--alternative{display:none}.forge-paginator__container{display:-webkit-box;display:flex;-webkit-box-align:center;align-items:center}.forge-paginator__label{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto,sans-serif;font-family:var(--mdc-typography-caption-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:.75rem;font-size:var(--mdc-typography-caption-font-size, .75rem);line-height:1.25rem;line-height:var(--mdc-typography-caption-line-height, 1.25rem);font-weight:400;font-weight:var(--mdc-typography-caption-font-weight,400);letter-spacing:.0333333333em;letter-spacing:var(--mdc-typography-caption-letter-spacing, .0333333333em);text-decoration:inherit;-webkit-text-decoration:var(--mdc-typography-caption-text-decoration,inherit);text-decoration:var(--mdc-typography-caption-text-decoration,inherit);text-transform:inherit;text-transform:var(--mdc-typography-caption-text-transform,inherit);margin-right:16px}.forge-paginator__page-size-options{margin-right:16px}.forge-paginator__range-label{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto,sans-serif;font-family:var(--mdc-typography-caption-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:.75rem;font-size:var(--mdc-typography-caption-font-size, .75rem);line-height:1.25rem;line-height:var(--mdc-typography-caption-line-height, 1.25rem);font-weight:400;font-weight:var(--mdc-typography-caption-font-weight,400);letter-spacing:.0333333333em;letter-spacing:var(--mdc-typography-caption-letter-spacing, .0333333333em);text-decoration:inherit;-webkit-text-decoration:var(--mdc-typography-caption-text-decoration,inherit);text-decoration:var(--mdc-typography-caption-text-decoration,inherit);text-transform:inherit;text-transform:var(--mdc-typography-caption-text-transform,inherit);margin-right:8px}.forge-paginator__first-page,.forge-paginator__last-page,.forge-paginator__next-page,.forge-paginator__previous-page{color:rgba(0,0,0,.87);color:var(--mdc-theme-text-primary-on-background,rgba(0,0,0,.87))}:host{display:inline-block}:host([hidden]){display:none}:host([alternative]) .forge-paginator--alignment-center .forge-paginator__container{-webkit-box-pack:center;justify-content:center}:host([alternative]) .forge-paginator--alignment-center .forge-paginator__range-label--alternative{margin:0 auto}:host([alternative]) .forge-paginator--alignment-start .forge-paginator__container{-webkit-box-pack:start;justify-content:flex-start}:host([alternative]) .forge-paginator--alignment-end .forge-paginator__container{-webkit-box-pack:end;justify-content:flex-end}:host([alternative]) .forge-paginator .forge-paginator__container{-webkit-box-flex:1;flex:1}',r=class extends I{constructor(){super();G.define([z,O,F,k]),y(this,V,j),this._foundation=new b(new f(this))}static get observedAttributes(){return[i.attributes.PAGE_INDEX,i.attributes.PAGE_SIZE,i.attributes.OFFSET,i.attributes.TOTAL,i.attributes.PAGE_SIZE_OPTIONS,i.attributes.LABEL,i.attributes.FIRST_LAST,i.attributes.FIRST,i.attributes.DISABLED,i.attributes.ALTERNATIVE,i.attributes.ALIGNMENT]}connectedCallback(){this._foundation.initialize()}disconnectedCallback(){this._foundation.disconnect()}attributeChangedCallback(t,a,o){switch(t){case i.attributes.PAGE_INDEX:this.pageIndex=Number(o)||i.numbers.DEFAULT_PAGE_INDEX;break;case i.attributes.PAGE_SIZE:this.pageSize=Number(o)||i.numbers.DEFAULT_PAGE_SIZE;break;case i.attributes.OFFSET:this.offset=Number(o);break;case i.attributes.TOTAL:this.total=Number(o)||i.numbers.DEFAULT_TOTAL;break;case i.attributes.PAGE_SIZE_OPTIONS:this.pageSizeOptions=o;break;case i.attributes.LABEL:this.label=o;break;case i.attributes.FIRST_LAST:this.firstLast=c(o);break;case i.attributes.FIRST:this.first=c(o);break;case i.attributes.DISABLED:this.disabled=c(o);break;case i.attributes.ALTERNATIVE:this.alternative=c(o);break;case i.attributes.ALIGNMENT:this.alignment=o;break}}focus(t){this._foundation.focus(t)}};s([p()],r.prototype,"pageIndex",2),s([p()],r.prototype,"pageSize",2),s([p()],r.prototype,"offset",2),s([p()],r.prototype,"total",2),s([p()],r.prototype,"pageSizeOptions",2),s([p()],r.prototype,"label",2),s([p()],r.prototype,"firstLast",2),s([p()],r.prototype,"first",2),s([p()],r.prototype,"disabled",2),s([p()],r.prototype,"alternative",2),s([p()],r.prototype,"alignment",2),r=s([x({name:i.elementName,dependencies:[R,M,w,C]})],r);function St(){T(r)}export{i as a,b,f as c,r as d,St as e};
|
|
7
|
-
//# sourceMappingURL=chunk.XY3WCDVX.js.map
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"version": 3,
|
|
3
|
-
"sources": ["../../src/paginator/paginator-constants.ts", "../../src/paginator/paginator-foundation.ts", "../../src/paginator/paginator-adapter.ts", "../../src/paginator/paginator.ts", "../../src/paginator/index.ts"],
|
|
4
|
-
"sourcesContent": ["import { COMPONENT_NAME_PREFIX } from '../constants';\n\nconst elementName: keyof HTMLElementTagNameMap = `${COMPONENT_NAME_PREFIX}paginator`;\n\nconst classes = {\n LABEL: 'forge-paginator__label',\n PAGE_SIZE_OPTIONS: 'forge-paginator__page-size-options',\n RANGE_LABEL: 'forge-paginator__range-label',\n RANGE_LABEL_ALTERNATIVE: 'forge-paginator__range-label--alternative',\n FIRST_PAGE_BUTTON: 'forge-paginator__first-page',\n PREVIOUS_PAGE_BUTTON: 'forge-paginator__previous-page',\n NEXT_PAGE_BUTTON: 'forge-paginator__next-page',\n LAST_PAGE_BUTTON: 'forge-paginator__last-page',\n ROOT: 'forge-paginator',\n ALTERNATIVE: 'forge-paginator--alternative',\n ALIGNMENT_START: 'forge-paginator--alignment-start',\n ALIGNMENT_SPACE_BETWEEN: 'forge-paginator--alignment-center',\n ALIGNMENT_END: 'forge-paginator--alignment-end'\n};\n\nconst selectors = {\n LABEL: `.${classes.LABEL}`,\n PAGE_SIZE_SELECT: `.${classes.PAGE_SIZE_OPTIONS}`,\n RANGE_LABEL: `.${classes.RANGE_LABEL}`,\n FIRST_PAGE_BUTTON: `.${classes.FIRST_PAGE_BUTTON} > button`,\n FIRST_PAGE_ICON_BUTTON: `.${classes.FIRST_PAGE_BUTTON}`,\n PREVIOUS_PAGE_BUTTON: `.${classes.PREVIOUS_PAGE_BUTTON} > button`,\n NEXT_PAGE_BUTTON: `.${classes.NEXT_PAGE_BUTTON} > button`,\n LAST_PAGE_BUTTON: `.${classes.LAST_PAGE_BUTTON} > button`,\n LAST_PAGE_ICON_BUTTON: `.${classes.LAST_PAGE_BUTTON}`,\n ROOT: `.${classes.ROOT}`,\n RANGE_LABEL_ALTERNATIVE: `.${classes.RANGE_LABEL_ALTERNATIVE}`\n};\n\nconst attributes = {\n PAGE_INDEX: 'page-index',\n PAGE_SIZE: 'page-size',\n OFFSET: 'offset',\n PAGE_SIZE_OPTIONS: 'page-size-options',\n TOTAL: 'total',\n LABEL: 'label',\n FIRST_LAST: 'first-last',\n FIRST: 'first',\n DISABLED: 'disabled',\n ALTERNATIVE: 'alternative',\n ALIGNMENT: 'alignment'\n};\n\nconst events = {\n CHANGE: `${elementName}-change`\n};\n\nconst numbers = {\n DEFAULT_PAGE_INDEX: 0,\n DEFAULT_TOTAL: 0,\n DEFAULT_PAGE_SIZE: 25,\n DEFAULT_PAGE_SIZE_OPTIONS: [5, 15, 25, 50, 100]\n};\n\nconst strings = {\n DEFAULT_LABEL: 'Rows per page:',\n RANGE_SEPARATOR_LABEL: 'of',\n FIRST_PAGE: 'first-page',\n PREVIOUS_PAGE: 'previous-page',\n NEXT_PAGE: 'next-page',\n LAST_PAGE: 'last-page',\n PAGE_SIZE: 'page-size'\n};\n\nexport const PAGINATOR_CONSTANTS = {\n elementName,\n classes,\n selectors,\n attributes,\n events,\n numbers,\n strings\n};\n\nexport type PaginatorAlternativeAlignment = 'start' | 'space-between' | 'end';\nexport interface IPaginatorChangeEvent {\n type: string;\n pageSize: number;\n pageIndex: number;\n offset: number;\n}\n", "import { coerceNumber, ICustomElementFoundation, isArray, isDefined } from '@tylertech/forge-core';\nimport { IPaginatorAdapter, PaginatorFieldIdentifier } from './paginator-adapter';\nimport { PaginatorAlternativeAlignment, PAGINATOR_CONSTANTS, IPaginatorChangeEvent } from './paginator-constants';\nimport { ISelectOption } from '../select';\n\nexport interface IPaginatorFoundation extends ICustomElementFoundation {\n pageIndex: number;\n pageSize: number;\n offset: number;\n total: number;\n pageSizeOptions: number[] | boolean;\n pageSizeLabel: string;\n focus(options?: FocusOptions): void;\n}\n\nexport class PaginatorFoundation {\n private _pageIndex = PAGINATOR_CONSTANTS.numbers.DEFAULT_PAGE_INDEX;\n private _pageSize = PAGINATOR_CONSTANTS.numbers.DEFAULT_PAGE_SIZE;\n private _offset = 0;\n private _total = PAGINATOR_CONSTANTS.numbers.DEFAULT_TOTAL;\n private _pageSizeOptions: ISelectOption[] = PAGINATOR_CONSTANTS.numbers.DEFAULT_PAGE_SIZE_OPTIONS.map(o => ({ label: `${o}`, value: `${o}` }));\n private _label = PAGINATOR_CONSTANTS.strings.DEFAULT_LABEL;\n private _firstLast = false;\n private _first = false;\n private _disabled = false;\n private _alternative: boolean;\n private _alignment: PaginatorAlternativeAlignment = 'space-between';\n private _rangeLabel: string;\n\n private _firstPageListener: (evt: Event) => void;\n private _previousPageListener: (evt: Event) => void;\n private _nextPageListener: (evt: Event) => void;\n private _lastPageListener: (evt: Event) => void;\n private _pageSizeListener: (evt: Event) => void;\n\n constructor(private _adapter: IPaginatorAdapter) {\n this._pageSizeListener = (evt: CustomEvent<number>) => this._onPageSizeChanged(evt);\n this._firstPageListener = (evt: Event) => this._onFirstPage(evt);\n this._previousPageListener = (evt: Event) => this._onPreviousPage(evt);\n this._nextPageListener = (evt: Event) => this._onNextPage(evt);\n this._lastPageListener = (evt: Event) => this._onLastPage(evt);\n }\n\n public initialize(): void {\n this._updateRangeLabel();\n this._adapter.setLabel(this._label);\n this._adapter.setPageSizeOptions(this._pageSizeOptions);\n this._adapter.setPageSize(this._pageSize);\n this._attachListeners();\n this._toggleFirstLastButtons();\n this._syncInteractionState();\n }\n\n public disconnect(): void {\n this._detachListeners();\n }\n\n public focus(options?: FocusOptions): void {\n this._adapter.handleFocusMove(null, options);\n }\n\n private _attachListeners(): void {\n this._adapter.attachPageSizeChangeListener(this._pageSizeListener);\n this._adapter.attachFirstPageListener(this._firstPageListener);\n this._adapter.attachPreviousPageListener(this._previousPageListener);\n this._adapter.attachNextPageListener(this._nextPageListener);\n this._adapter.attachLastPageListener(this._lastPageListener);\n }\n\n private _detachListeners(): void {\n this._adapter.detachPageSizeChangeListener(this._pageSizeListener);\n this._adapter.detachFirstPageListener(this._firstPageListener);\n this._adapter.detachPreviousPageListener(this._previousPageListener);\n this._adapter.detachNextPageListener(this._nextPageListener);\n this._adapter.detachLastPageListener(this._lastPageListener);\n }\n\n private _onFirstPage(evt: Event): void {\n evt.stopPropagation();\n\n if (!this._hasFirstPage()) {\n return;\n }\n\n const firstPage = 0;\n const canPage = this._emitChangeEvent(PAGINATOR_CONSTANTS.strings.FIRST_PAGE, { pageIndex: firstPage });\n if (canPage) {\n this._applyPageIndex(firstPage);\n }\n }\n\n private _onPreviousPage(evt: Event): void {\n evt.stopPropagation();\n\n if (!this._hasPreviousPage()) {\n return;\n }\n \n const prevPage = this._pageIndex - 1;\n const canPage = this._emitChangeEvent(PAGINATOR_CONSTANTS.strings.PREVIOUS_PAGE, { pageIndex: prevPage });\n if (canPage) {\n this._applyPageIndex(prevPage);\n }\n }\n\n private _onNextPage(evt: Event): void {\n evt.stopPropagation();\n\n if (!this._hasNextPage()) {\n return;\n }\n\n const nextPage = this._pageIndex + 1;\n const canPage = this._emitChangeEvent(PAGINATOR_CONSTANTS.strings.NEXT_PAGE, { pageIndex: nextPage });\n if (canPage) {\n this._applyPageIndex(nextPage);\n }\n }\n\n private _onLastPage(evt: Event): void {\n evt.stopPropagation();\n\n if (!this._hasLastPage()) {\n return;\n }\n\n const lastPage = this._getMaxPages();\n const canPage = this._emitChangeEvent(PAGINATOR_CONSTANTS.strings.LAST_PAGE, { pageIndex: lastPage });\n if (canPage) {\n this._applyPageIndex(lastPage);\n }\n }\n\n private _onPageSizeChanged(evt: CustomEvent): void {\n evt.stopPropagation();\n\n const pageSize = Number(evt.detail);\n const canPage = this._emitChangeEvent(PAGINATOR_CONSTANTS.strings.PAGE_SIZE, { pageIndex: 0, pageSize });\n if (canPage) {\n this._applyPageIndex(0);\n this._applyPageSize(pageSize);\n } else {\n evt.preventDefault();\n }\n }\n\n private _emitChangeEvent(type: string, { pageSize = this._pageSize, pageIndex = this._pageIndex } = {}): boolean {\n const offset = pageIndex * pageSize;\n const detail: IPaginatorChangeEvent = { type, pageSize, pageIndex, offset };\n return this._adapter.emitHostEvent(PAGINATOR_CONSTANTS.events.CHANGE, detail, true, true);\n }\n\n private _getMaxPages(): number {\n return Math.ceil(this._total / this._pageSize) - 1;\n }\n\n private _updateRangeLabel(): void {\n if (this.pageSize > 1) {\n const startIndex = this._pageIndex * this._pageSize;\n const indexStart = Math.floor(startIndex / this._pageSize) || 0;\n const pageStart = (indexStart * this._pageSize) + 1;\n const pageEnd = startIndex < this._total ? Math.min(startIndex + this._pageSize, this._total) : startIndex + this._pageSize;\n this._rangeLabel = `${pageStart}-${pageEnd} ${PAGINATOR_CONSTANTS.strings.RANGE_SEPARATOR_LABEL} ${this._total}`;\n } else {\n this._rangeLabel = `${this._pageIndex + 1} ${PAGINATOR_CONSTANTS.strings.RANGE_SEPARATOR_LABEL} ${this._total}`;\n }\n this._adapter.setRangeLabel(this._rangeLabel);\n }\n\n private _syncInteractionState(): void {\n this._adapter.enableFirstPageButton();\n this._adapter.enablePreviousPageButton();\n this._adapter.enableNextPageButton();\n this._adapter.enableLastPageButton();\n\n if (!this._hasFirstPage()) {\n if (this._adapter.hasFocus()) {\n this._adapter.handleFocusMove('first');\n }\n this._adapter.disableFirstPageButton();\n }\n\n if (!this._hasPreviousPage()) {\n if (this._adapter.hasFocus()) {\n this._adapter.handleFocusMove('previous');\n }\n this._adapter.disablePreviousPageButton();\n }\n\n if (!this._hasNextPage()) {\n if (this._adapter.hasFocus()) {\n this._adapter.handleFocusMove('next');\n }\n this._adapter.disableNextPageButton();\n }\n\n if (!this._hasLastPage()) {\n if (this._adapter.hasFocus()) {\n this._adapter.handleFocusMove('last');\n }\n this._adapter.disableLastPageButton();\n }\n }\n\n private _toggleFirstLastButtons(): void {\n this._toggleFirstButton();\n if (this._firstLast) {\n if (!this._adapter.hasLastPageButton()) {\n this._adapter.showLastPageButton();\n }\n } else {\n if (this._adapter.hasLastPageButton()) {\n this._adapter.hideLastPageButton();\n }\n }\n }\n\n private _toggleFirstButton(): void {\n if (this._first || this._firstLast) {\n if (!this._adapter.hasFirstPageButton()) {\n this._adapter.showFirstPageButton();\n }\n } else {\n if (this._adapter.hasFirstPageButton()) {\n this._adapter.hideFirstPageButton();\n }\n }\n }\n\n private _hasFirstPage(): boolean {\n return this._hasPreviousPage();\n }\n\n private _hasPreviousPage(): boolean {\n return this._pageIndex > 0 && this._pageSize > 0;\n }\n\n private _hasNextPage(): boolean {\n const maxPages = this._getMaxPages();\n return this._pageIndex < maxPages && this._pageSize > 0;\n }\n\n private _hasLastPage(): boolean {\n return this._hasNextPage();\n }\n\n private _computePageIndexFromOffset(value: number): void {\n if (value >= this._total) {\n if (this._total >= this._pageSize) {\n value = this._total - this._pageSize;\n } else {\n value = 0;\n }\n }\n const clampedValue = Math.min(Math.max(value, 0), this._total);\n const pageIndex = Math.floor(clampedValue / this._pageSize);\n this._applyPageIndex(pageIndex);\n }\n\n private _computeOffset(): void {\n if (this._total > 0) {\n this._offset = this._pageIndex * this._pageSize;\n }\n }\n\n private _applyPageIndex(value: number): void {\n this._pageIndex = value;\n this._computeOffset();\n this._updateRangeLabel();\n this._syncInteractionState();\n this._adapter.toggleHostAttribute(PAGINATOR_CONSTANTS.attributes.PAGE_INDEX, this._pageIndex != null, this._pageIndex.toString());\n }\n\n private _applyPageSize(value: number): void {\n this._pageSize = value;\n this._adapter.setPageSize(this._pageSize);\n this._computeOffset();\n this._updateRangeLabel();\n this._syncInteractionState();\n }\n\n private _applyTotal(value: number): void {\n this._total = value;\n this._updateRangeLabel();\n\n if (this._offset > 0 && this._total > 0) {\n this._computePageIndexFromOffset(this._offset);\n }\n\n this._syncInteractionState();\n }\n\n private _applyAlternativeAlignment(): void {\n this._adapter.setHostAttribute(PAGINATOR_CONSTANTS.attributes.ALIGNMENT, this._alignment);\n this._adapter.setAlignment(this._alignment);\n }\n\n private _applyDisabled(disabled: boolean): void {\n this._disabled = disabled;\n if (disabled) {\n this._adapter.disablePageSizeSelect();\n this._adapter.disableFirstPageButton();\n this._adapter.disablePreviousPageButton();\n this._adapter.disableNextPageButton();\n this._adapter.disableLastPageButton();\n } else {\n this._adapter.enablePageSizeSelect();\n this._syncInteractionState();\n }\n }\n\n public get pageIndex(): number {\n return this._pageIndex;\n }\n public set pageIndex(value: number) {\n if (this._pageIndex !== value) {\n if (isDefined(value)) {\n this._applyPageIndex(value);\n } else {\n this._adapter.removeHostAttribute(PAGINATOR_CONSTANTS.attributes.PAGE_INDEX);\n }\n }\n }\n\n public get pageSize(): number {\n return this._pageSize;\n }\n public set pageSize(value: number) {\n if (this._pageSize !== value) {\n this._applyPageSize(value);\n this._adapter.setHostAttribute(PAGINATOR_CONSTANTS.attributes.PAGE_SIZE, `${this._pageSize}`);\n }\n }\n\n public get offset(): number {\n return this._offset;\n }\n public set offset(value: number) {\n if (this._offset !== value) {\n this._offset = value;\n this._computePageIndexFromOffset(value);\n }\n }\n\n public get total(): number {\n return this._total;\n }\n public set total(value: number) {\n if (this._total !== value) {\n this._applyTotal(value);\n this._adapter.setHostAttribute(PAGINATOR_CONSTANTS.attributes.TOTAL, `${this._total}`);\n }\n }\n\n public get pageSizeOptions(): number[] | boolean {\n return this._pageSizeOptions.map(o => Number(o.value));\n }\n public set pageSizeOptions(options: number[] | boolean) {\n if (isArray(options)) {\n this._pageSizeOptions = (options as number[])\n .map(o => ({ label: o.toString(), value: o.toString() }))\n .sort((a, b) => coerceNumber(a.value) - coerceNumber(b.value));\n this._adapter.setPageSizeOptions(this._pageSizeOptions);\n this._adapter.attachPageSizeChangeListener(this._pageSizeListener);\n this._adapter.setPageSizeVisibility(true);\n if (isDefined(this._pageSize) && this._pageSizeOptions.length && !this._pageSizeOptions.find(o => coerceNumber(o.value) === this._pageSize)) {\n const pageSize = coerceNumber(this._pageSizeOptions[0].value);\n this._applyPageSize(pageSize);\n }\n } else if (options.toString().toLowerCase() === 'false') {\n this._adapter.detachPageSizeChangeListener(this._pageSizeListener);\n this._adapter.setPageSizeVisibility(false);\n }\n }\n\n public get label(): string {\n return this._label;\n }\n public set label(value: string) {\n if (this._label !== value) {\n this._label = value;\n this._adapter.setLabel(this._label);\n this._adapter.setHostAttribute(PAGINATOR_CONSTANTS.attributes.LABEL, isDefined(this._label) ? this._label.toString() : '');\n }\n }\n\n public get firstLast(): boolean {\n return this._firstLast;\n }\n public set firstLast(value: boolean) {\n value = Boolean(value);\n if (this._firstLast !== value) {\n this._firstLast = value;\n this._toggleFirstLastButtons();\n this._adapter.toggleHostAttribute(PAGINATOR_CONSTANTS.attributes.FIRST_LAST, this._firstLast);\n }\n }\n\n public get first(): boolean {\n return this._first;\n }\n public set first(value: boolean) {\n value = Boolean(value);\n if (this._first !== value) {\n this._first = value;\n this._toggleFirstButton();\n this._adapter.toggleHostAttribute(PAGINATOR_CONSTANTS.attributes.FIRST, this._first);\n }\n }\n\n public get disabled(): boolean {\n return this._disabled;\n }\n public set disabled(value: boolean) {\n value = Boolean(value);\n if (this._disabled !== value) {\n this._applyDisabled(value);\n this._adapter.toggleHostAttribute(PAGINATOR_CONSTANTS.attributes.DISABLED, this._disabled);\n }\n }\n\n public get alternative(): boolean {\n return this._alternative;\n }\n public set alternative(value: boolean) {\n if (value !== this._alternative) {\n this._alternative = value;\n this._adapter.setAlternative(this._alternative);\n this._applyAlternativeAlignment();\n this._adapter.toggleHostAttribute(PAGINATOR_CONSTANTS.attributes.ALTERNATIVE, this._alternative);\n }\n }\n\n public get alignment(): PaginatorAlternativeAlignment {\n return this._alignment;\n }\n public set alignment(value: PaginatorAlternativeAlignment) {\n if (value !== this._alignment) {\n this._alignment = value;\n this._applyAlternativeAlignment();\n }\n }\n}\n", "import { addClass, getShadowElement, removeAllChildren, removeClass, toggleElementPlaceholder, toggleClass } from '@tylertech/forge-core';\nimport { BaseAdapter, IBaseAdapter } from '../core/base/base-adapter';\nimport { IIconButtonComponent } from '../icon-button';\nimport { ISelectComponent, ISelectOption } from '../select';\nimport { IPaginatorComponent } from './paginator';\nimport { PaginatorAlternativeAlignment, PAGINATOR_CONSTANTS } from './paginator-constants';\n\nexport type PaginatorFieldIdentifier = 'first' | 'last' | 'previous' | 'next' | 'page-size';\n\nexport interface IPaginatorAdapter extends IBaseAdapter {\n setLabel(value: string): void;\n setPageSizeOptions(options: ISelectOption[]): void;\n setPageSize(value: number): void;\n setRangeLabel(value: string): void;\n hasFirstPageButton(): boolean;\n showFirstPageButton(): void;\n hideFirstPageButton(): void;\n hasLastPageButton(): boolean;\n showLastPageButton(): void;\n hideLastPageButton(): void;\n attachPageSizeChangeListener(listener: (evt: CustomEvent) => void): void;\n attachFirstPageListener(listener: (evt: Event) => void): void;\n attachPreviousPageListener(listener: (evt: Event) => void): void;\n attachNextPageListener(listener: (evt: Event) => void): void;\n attachLastPageListener(listener: (evt: Event) => void): void;\n detachPageSizeChangeListener(listener: (evt: CustomEvent) => void): void;\n detachFirstPageListener(listener: (evt: Event) => void): void;\n detachPreviousPageListener(listener: (evt: Event) => void): void;\n detachNextPageListener(listener: (evt: Event) => void): void;\n detachLastPageListener(listener: (evt: Event) => void): void;\n disableFirstPageButton(): void;\n enableFirstPageButton(): void;\n disablePreviousPageButton(): void;\n enablePreviousPageButton(): void;\n disableNextPageButton(): void;\n enableNextPageButton(): void;\n disablePageSizeSelect(): void;\n enablePageSizeSelect(): void;\n setPageSizeVisibility(visible: boolean): void;\n disableLastPageButton(): void;\n enableLastPageButton(): void;\n setAlternative(alternative: boolean): void;\n setAlignment(alignment: PaginatorAlternativeAlignment): void;\n hasFocus(): boolean;\n handleFocusMove(from?: PaginatorFieldIdentifier | null, options?: FocusOptions): void;\n}\n\n/**\n * Provides facilities for interacting with the internal DOM of `PaginatorComponent`.\n */\nexport class PaginatorAdapter extends BaseAdapter<IPaginatorComponent> implements IPaginatorAdapter {\n private _labelElement: HTMLElement;\n private _root: HTMLElement;\n private _pageSizeSelect: ISelectComponent;\n private _rangeLabel: HTMLElement;\n private _rangeLabelAlternative: HTMLElement;\n private _firstPageButton: HTMLButtonElement;\n private _firstPageIconButton: IIconButtonComponent;\n private _firstPagePlaceholder: Comment;\n private _previousPageButton: HTMLButtonElement;\n private _nextPageButton: HTMLButtonElement;\n private _lastPageButton: HTMLButtonElement;\n private _lastPageIconButton: IIconButtonComponent;\n private _lastPagePlaceholder: Comment;\n\n constructor(component: IPaginatorComponent) {\n super(component);\n this._labelElement = getShadowElement(component, PAGINATOR_CONSTANTS.selectors.LABEL);\n this._root = getShadowElement(component, PAGINATOR_CONSTANTS.selectors.ROOT);\n this._pageSizeSelect = getShadowElement(component, PAGINATOR_CONSTANTS.selectors.PAGE_SIZE_SELECT) as ISelectComponent;\n this._rangeLabel = getShadowElement(component, PAGINATOR_CONSTANTS.selectors.RANGE_LABEL);\n this._rangeLabelAlternative = getShadowElement(component, PAGINATOR_CONSTANTS.selectors.RANGE_LABEL_ALTERNATIVE);\n this._firstPageButton = getShadowElement(component, PAGINATOR_CONSTANTS.selectors.FIRST_PAGE_BUTTON) as HTMLButtonElement;\n this._firstPageIconButton = getShadowElement(component, PAGINATOR_CONSTANTS.selectors.FIRST_PAGE_ICON_BUTTON) as IIconButtonComponent;\n this._previousPageButton = getShadowElement(component, PAGINATOR_CONSTANTS.selectors.PREVIOUS_PAGE_BUTTON) as HTMLButtonElement;\n this._nextPageButton = getShadowElement(component, PAGINATOR_CONSTANTS.selectors.NEXT_PAGE_BUTTON) as HTMLButtonElement;\n this._lastPageButton = getShadowElement(component, PAGINATOR_CONSTANTS.selectors.LAST_PAGE_BUTTON) as HTMLButtonElement;\n this._lastPageIconButton = getShadowElement(component, PAGINATOR_CONSTANTS.selectors.LAST_PAGE_ICON_BUTTON) as IIconButtonComponent;\n }\n\n public setLabel(value: string): void {\n this._labelElement.textContent = value;\n }\n\n public setPageSizeOptions(options: ISelectOption[]): void {\n removeAllChildren(this._pageSizeSelect);\n this._pageSizeSelect.options = options;\n }\n\n public setPageSize(value: number): void {\n this._pageSizeSelect.value = value.toString();\n }\n\n public setRangeLabel(value: string): void {\n this._rangeLabel.innerText = value;\n this._rangeLabelAlternative.innerText = value;\n }\n\n public hasFirstPageButton(): boolean {\n return !!getShadowElement(this._component, PAGINATOR_CONSTANTS.selectors.FIRST_PAGE_ICON_BUTTON);\n }\n\n public showFirstPageButton(): void {\n this._firstPagePlaceholder = toggleElementPlaceholder(\n this._component,\n true,\n PAGINATOR_CONSTANTS.elementName,\n PAGINATOR_CONSTANTS.selectors.FIRST_PAGE_ICON_BUTTON,\n this._firstPageIconButton,\n this._firstPagePlaceholder\n );\n }\n\n public hideFirstPageButton(): void {\n this._firstPagePlaceholder = toggleElementPlaceholder(\n this._component,\n false,\n PAGINATOR_CONSTANTS.elementName,\n PAGINATOR_CONSTANTS.selectors.FIRST_PAGE_ICON_BUTTON,\n this._firstPageIconButton,\n this._firstPagePlaceholder\n );\n }\n\n public hasLastPageButton(): boolean {\n return !!getShadowElement(this._component, PAGINATOR_CONSTANTS.selectors.LAST_PAGE_ICON_BUTTON);\n }\n\n public showLastPageButton(): void {\n this._lastPagePlaceholder = toggleElementPlaceholder(\n this._component,\n true,\n PAGINATOR_CONSTANTS.elementName,\n PAGINATOR_CONSTANTS.selectors.LAST_PAGE_ICON_BUTTON,\n this._lastPageIconButton,\n this._lastPagePlaceholder\n );\n }\n\n public hideLastPageButton(): void {\n this._lastPagePlaceholder = toggleElementPlaceholder(\n this._component,\n false,\n PAGINATOR_CONSTANTS.elementName,\n PAGINATOR_CONSTANTS.selectors.LAST_PAGE_ICON_BUTTON,\n this._lastPageIconButton,\n this._lastPagePlaceholder\n );\n }\n\n public attachPageSizeChangeListener(listener: (evt: CustomEvent) => void): void {\n this._pageSizeSelect.addEventListener('change', listener);\n }\n\n public attachFirstPageListener(listener: (evt: Event) => void): void {\n this._firstPageButton.addEventListener('click', listener);\n }\n\n public attachPreviousPageListener(listener: (evt: Event) => void): void {\n this._previousPageButton.addEventListener('click', listener);\n }\n\n public attachNextPageListener(listener: (evt: Event) => void): void {\n this._nextPageButton.addEventListener('click', listener);\n }\n\n public attachLastPageListener(listener: (evt: Event) => void): void {\n this._lastPageButton.addEventListener('click', listener);\n }\n\n public detachPageSizeChangeListener(listener: (evt: CustomEvent) => void): void {\n this._pageSizeSelect.removeEventListener('change', listener);\n }\n\n public detachFirstPageListener(listener: (evt: Event) => void): void {\n this._firstPageButton.removeEventListener('click', listener);\n }\n\n public detachPreviousPageListener(listener: (evt: Event) => void): void {\n this._previousPageButton.removeEventListener('click', listener);\n }\n\n public detachNextPageListener(listener: (evt: Event) => void): void {\n this._nextPageButton.removeEventListener('click', listener);\n }\n\n public detachLastPageListener(listener: (evt: Event) => void): void {\n this._lastPageButton.removeEventListener('click', listener);\n }\n\n public disableFirstPageButton(): void {\n this._firstPageButton.setAttribute('disabled', 'disabled');\n }\n\n public enableFirstPageButton(): void {\n this._firstPageButton.removeAttribute('disabled');\n }\n\n public disablePreviousPageButton(): void {\n this._previousPageButton.setAttribute('disabled', 'disabled');\n }\n\n public enablePreviousPageButton(): void {\n this._previousPageButton.removeAttribute('disabled');\n }\n\n public disableNextPageButton(): void {\n this._nextPageButton.setAttribute('disabled', 'disabled');\n }\n\n public enableNextPageButton(): void {\n this._nextPageButton.removeAttribute('disabled');\n }\n\n public disablePageSizeSelect(): void {\n this._pageSizeSelect.setAttribute('disabled', 'disabled');\n }\n\n public enablePageSizeSelect(): void {\n this._pageSizeSelect.removeAttribute('disabled');\n }\n\n public setPageSizeVisibility(visible: boolean): void {\n if (visible) {\n this._pageSizeSelect.style.removeProperty('display');\n } else {\n this._pageSizeSelect.style.display = 'none';\n }\n }\n\n public disableLastPageButton(): void {\n this._lastPageButton.setAttribute('disabled', 'disabled');\n }\n\n public enableLastPageButton(): void {\n this._lastPageButton.removeAttribute('disabled');\n }\n\n public setAlternative(alternative: boolean): void {\n toggleClass(this._root, alternative, PAGINATOR_CONSTANTS.classes.ALTERNATIVE);\n }\n\n public setAlignment(alignment: PaginatorAlternativeAlignment): void {\n removeClass([\n PAGINATOR_CONSTANTS.classes.ALIGNMENT_SPACE_BETWEEN,\n PAGINATOR_CONSTANTS.classes.ALIGNMENT_START,\n PAGINATOR_CONSTANTS.classes.ALIGNMENT_END\n ], this._root);\n\n switch (alignment) {\n case 'start':\n addClass(PAGINATOR_CONSTANTS.classes.ALIGNMENT_START, this._root);\n break;\n case 'end':\n addClass(PAGINATOR_CONSTANTS.classes.ALIGNMENT_END, this._root);\n break;\n case 'space-between':\n default:\n addClass(PAGINATOR_CONSTANTS.classes.ALIGNMENT_SPACE_BETWEEN, this._root);\n break;\n }\n }\n\n public hasFocus(): boolean {\n return this._component.matches(':focus');\n }\n\n public handleFocusMove(from?: PaginatorFieldIdentifier, options?: FocusOptions): void {\n if (from && !this.hasFocus()) {\n return; // We can only move focus elsewhere within the element if the element already contains focus\n }\n\n switch (from) {\n case 'first':\n this._tryFocus([\n this._nextPageButton,\n this._lastPageButton,\n this._previousPageButton,\n this._pageSizeSelect\n ], options);\n break;\n case 'last':\n this._tryFocus([\n this._previousPageButton,\n this._firstPageButton,\n this._nextPageButton,\n this._pageSizeSelect\n ], options);\n break;\n case 'previous':\n this._tryFocus([\n this._nextPageButton,\n this._lastPageButton,\n this._firstPageButton,\n this._pageSizeSelect\n ]);\n break;\n case 'next':\n this._tryFocus([\n this._previousPageButton,\n this._firstPageButton,\n this._lastPageButton,\n this._pageSizeSelect\n ], options);\n break;\n case 'page-size':\n this._tryFocus([\n this._nextPageButton,\n this._lastPageButton,\n this._firstPageButton,\n this._previousPageButton\n ], options);\n break;\n default:\n this._tryFocus([\n this._firstPageButton,\n this._previousPageButton,\n this._nextPageButton,\n this._lastPageButton,\n this._pageSizeSelect\n ], options);\n break;\n }\n }\n\n private _tryFocus(elements: Array<HTMLButtonElement | ISelectComponent>, options?: FocusOptions): void {\n const preventScroll = typeof options?.preventScroll === 'boolean' ? options.preventScroll : true;\n for (const el of elements) {\n if (el && el.isConnected && !el.disabled) {\n el.focus({ ...options, preventScroll });\n return;\n }\n }\n }\n}\n", "import { CustomElement, attachShadowTemplate, FoundationProperty, coerceBoolean } from '@tylertech/forge-core';\nimport { tylIconFirstPage, tylIconLastPage, tylIconKeyboardArrowRight, tylIconKeyboardArrowLeft } from '@tylertech/tyler-icons/standard';\nimport { PaginatorAlternativeAlignment, PAGINATOR_CONSTANTS, IPaginatorChangeEvent } from './paginator-constants';\nimport { PaginatorFoundation } from './paginator-foundation';\nimport { PaginatorAdapter } from './paginator-adapter';\nimport { IconButtonComponent } from '../icon-button';\nimport { SelectComponent } from '../select';\nimport { IconComponent, IconRegistry } from '../icon';\nimport { BaseComponent, IBaseComponent } from '../core/base/base-component';\nimport { TooltipComponent } from '../tooltip';\n\nconst template = '<template><div class=\\\"forge-paginator\\\" part=\\\"root\\\"><div class=\\\"forge-paginator__container\\\" part=\\\"container\\\"><div class=\\\"forge-paginator__label\\\" part=\\\"label\\\"></div><forge-select class=\\\"forge-paginator__page-size-options\\\" aria-label=\\\"Choose page size\\\" density=\\\"dense\\\" part=\\\"page-size-options\\\"></forge-select><div class=\\\"forge-paginator__range-label\\\" part=\\\"range-label\\\"></div><forge-icon-button class=\\\"forge-paginator__first-page\\\" part=\\\"first-page-button\\\"><button aria-label=\\\"First Page\\\" part=\\\"first-page-button-element\\\"><forge-icon name=\\\"first_page\\\" part=\\\"first-page-icon\\\"></forge-icon></button><forge-tooltip position=\\\"top\\\">Go to the first page</forge-tooltip></forge-icon-button><forge-icon-button class=\\\"forge-paginator__previous-page\\\" part=\\\"previous-page-button\\\"><button aria-label=\\\"Previous Page\\\" part=\\\"previous-page-button-element\\\"><forge-icon name=\\\"keyboard_arrow_left\\\" part=\\\"previous-page-button-icon\\\"></forge-icon></button><forge-tooltip position=\\\"top\\\">Go to the previous page</forge-tooltip></forge-icon-button><div class=\\\"forge-paginator__range-label--alternative\\\" part=\\\"range-label-alternative\\\"></div><forge-icon-button class=\\\"forge-paginator__next-page\\\" part=\\\"next-page-button\\\"><button aria-label=\\\"Next Page\\\" part=\\\"next-page-button-element\\\"><forge-icon name=\\\"keyboard_arrow_right\\\" part=\\\"next-page-icon\\\"></forge-icon></button><forge-tooltip position=\\\"top\\\">Go to the next page</forge-tooltip></forge-icon-button><forge-icon-button class=\\\"forge-paginator__last-page\\\" part=\\\"last-page-button\\\"><button aria-label=\\\"Last Page\\\" part=\\\"last-page-button-element\\\"><forge-icon name=\\\"last_page\\\" part=\\\"last-page-icon\\\"></forge-icon></button><forge-tooltip position=\\\"top\\\">Go to the last page</forge-tooltip></forge-icon-button></div></div></template>';\nconst styles = '.forge-icon-button{display:-webkit-inline-box;display:inline-flex;-webkit-box-pack:center;justify-content:center;-webkit-box-align:center;align-items:center;position:relative;-webkit-box-sizing:border-box;box-sizing:border-box;border:none;outline:0;background-color:transparent;fill:currentColor;color:inherit;font-size:24px;text-decoration:none;cursor:pointer;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;width:48px;height:48px;padding:12px}.forge-icon-button forge-icon,.forge-icon-button img,.forge-icon-button svg{width:24px;height:24px}.forge-icon-button:disabled{color:rgba(0,0,0,.38);color:var(--mdc-theme-text-disabled-on-light,rgba(0,0,0,.38))}.forge-icon-button:disabled{cursor:default;pointer-events:none}.forge-icon-button__icon{display:inline-block}.forge-icon-button__icon.forge-icon-button__icon--on{display:none}.forge-icon-button--on .forge-icon-button__icon{display:none}.forge-icon-button--on .forge-icon-button__icon.forge-icon-button__icon--on{display:inline-block}@-webkit-keyframes mdc-ripple-fg-radius-in{from{-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1);-webkit-transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1);transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1)}to{-webkit-transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1));transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1))}}@keyframes mdc-ripple-fg-radius-in{from{-webkit-animation-timing-function:cubic-bezier(0.4,0,0.2,1);animation-timing-function:cubic-bezier(0.4,0,0.2,1);-webkit-transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1);transform:translate(var(--mdc-ripple-fg-translate-start,0)) scale(1)}to{-webkit-transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1));transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1))}}@-webkit-keyframes mdc-ripple-fg-opacity-in{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@keyframes mdc-ripple-fg-opacity-in{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:0}to{opacity:var(--mdc-ripple-fg-opacity, 0)}}@-webkit-keyframes mdc-ripple-fg-opacity-out{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}@keyframes mdc-ripple-fg-opacity-out{from{-webkit-animation-timing-function:linear;animation-timing-function:linear;opacity:var(--mdc-ripple-fg-opacity, 0)}to{opacity:0}}.forge-icon-button{--mdc-ripple-fg-size:0;--mdc-ripple-left:0;--mdc-ripple-top:0;--mdc-ripple-fg-scale:1;--mdc-ripple-fg-translate-end:0;--mdc-ripple-fg-translate-start:0;-webkit-tap-highlight-color:transparent;will-change:transform,opacity}.forge-icon-button::after,.forge-icon-button::before{position:absolute;border-radius:50%;opacity:0;pointer-events:none;content:\\\"\\\"}.forge-icon-button::before{-webkit-transition:opacity 15ms linear,background-color 15ms linear;transition:opacity 15ms linear,background-color 15ms linear;z-index:1;z-index:var(--mdc-ripple-z-index,1)}.forge-icon-button::after{z-index:0;z-index:var(--mdc-ripple-z-index,0)}.forge-icon-button.mdc-ripple-upgraded::before{-webkit-transform:scale(var(--mdc-ripple-fg-scale,1));transform:scale(var(--mdc-ripple-fg-scale,1))}.forge-icon-button.mdc-ripple-upgraded::after{top:0;left:0;-webkit-transform:scale(0);transform:scale(0);-webkit-transform-origin:center center;transform-origin:center center}.forge-icon-button.mdc-ripple-upgraded--unbounded::after{top:var(--mdc-ripple-top,0);left:var(--mdc-ripple-left,0)}.forge-icon-button.mdc-ripple-upgraded--foreground-activation::after{-webkit-animation:mdc-ripple-fg-radius-in 225ms forwards,mdc-ripple-fg-opacity-in 75ms forwards;animation:mdc-ripple-fg-radius-in 225ms forwards,mdc-ripple-fg-opacity-in 75ms forwards}.forge-icon-button.mdc-ripple-upgraded--foreground-deactivation::after{-webkit-animation:mdc-ripple-fg-opacity-out 150ms;animation:mdc-ripple-fg-opacity-out 150ms;-webkit-transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1));transform:translate(var(--mdc-ripple-fg-translate-end,0)) scale(var(--mdc-ripple-fg-scale,1))}.forge-icon-button::after,.forge-icon-button::before{top:calc(50% - 50%);left:calc(50% - 50%);width:100%;height:100%}.forge-icon-button.mdc-ripple-upgraded::after,.forge-icon-button.mdc-ripple-upgraded::before{top:var(--mdc-ripple-top,calc(50% - 50%));left:var(--mdc-ripple-left,calc(50% - 50%));width:var(--mdc-ripple-fg-size,100%);height:var(--mdc-ripple-fg-size,100%)}.forge-icon-button.mdc-ripple-upgraded::after{width:var(--mdc-ripple-fg-size,100%);height:var(--mdc-ripple-fg-size,100%)}.forge-icon-button::after,.forge-icon-button::before{background-color:#000;background-color:var(--mdc-ripple-color,var(--mdc-theme-on-surface,#000))}.forge-icon-button.mdc-ripple-surface--hover::before,.forge-icon-button:hover::before{opacity:.04;opacity:var(--mdc-ripple-hover-opacity, .04)}.forge-icon-button.mdc-ripple-upgraded--background-focused::before,.forge-icon-button:not(.mdc-ripple-upgraded):focus::before{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-focus-opacity, .12)}.forge-icon-button:not(.mdc-ripple-upgraded)::after{-webkit-transition:opacity 150ms linear;transition:opacity 150ms linear}.forge-icon-button:not(.mdc-ripple-upgraded):active::after{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-press-opacity, .12)}.forge-icon-button.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}forge-icon-button{position:relative;display:inline-block;overflow:visible}.forge-icon-button--on{color:#3f51b5;color:var(--mdc-theme-primary,#3f51b5)}.forge-icon-button--on::after,.forge-icon-button--on::before{background-color:#3f51b5;background-color:var(--mdc-ripple-color,var(--mdc-theme-primary,#3f51b5))}.forge-icon-button--on.mdc-ripple-surface--hover::before,.forge-icon-button--on:hover::before{opacity:.04;opacity:var(--mdc-ripple-hover-opacity, .04)}.forge-icon-button--on.mdc-ripple-upgraded--background-focused::before,.forge-icon-button--on:not(.mdc-ripple-upgraded):focus::before{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-focus-opacity, .12)}.forge-icon-button--on:not(.mdc-ripple-upgraded)::after{-webkit-transition:opacity 150ms linear;transition:opacity 150ms linear}.forge-icon-button--on:not(.mdc-ripple-upgraded):active::after{-webkit-transition-duration:75ms;transition-duration:75ms;opacity:.12;opacity:var(--mdc-ripple-press-opacity, .12)}.forge-icon-button--on.mdc-ripple-upgraded{--mdc-ripple-fg-opacity:var(--mdc-ripple-press-opacity, 0.12)}.forge-icon-button--on::before{background-color:#3f51b5;background-color:var(--mdc-theme-primary,#3f51b5);opacity:.08}.forge-icon-button--dense{width:28px;height:28px;padding:2px;padding:0}.forge-icon-button--dense-1{width:44px;height:44px;padding:10px}.forge-icon-button--dense-2{width:40px;height:40px;padding:8px}.forge-icon-button--dense-3{width:36px;height:36px;padding:6px}.forge-icon-button--dense-4{width:32px;height:32px;padding:4px}.forge-icon-button--dense-5{width:28px;height:28px;padding:2px}.forge-icon-button--dense-6{width:24px;height:24px;padding:0}.forge-icon-button--with-badge forge-badge{z-index:1;z-index:var(--forge-z-index-surface,1);pointer-events:none;--forge-badge-max-width:32px;--forge-badge-border:1px solid transparent}.forge-icon-button--with-badge forge-badge[app-bar-context]{--forge-badge-border:2px solid var(--forge-app-bar-theme-background)}.forge-paginator{display:inline-block}.forge-paginator--alternative{display:-webkit-box;display:flex}.forge-paginator--alternative .forge-paginator__label,.forge-paginator--alternative .forge-paginator__page-size-options,.forge-paginator--alternative .forge-paginator__range-label{display:none}.forge-paginator--alternative .forge-paginator__range-label--alternative{display:inline-block;-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto,sans-serif;font-family:var(--mdc-typography-body2-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:.875rem;font-size:var(--mdc-typography-body2-font-size, .875rem);line-height:1.25rem;line-height:var(--mdc-typography-body2-line-height, 1.25rem);font-weight:400;font-weight:var(--mdc-typography-body2-font-weight,400);letter-spacing:.0178571429em;letter-spacing:var(--mdc-typography-body2-letter-spacing, .0178571429em);text-decoration:inherit;-webkit-text-decoration:var(--mdc-typography-body2-text-decoration,inherit);text-decoration:var(--mdc-typography-body2-text-decoration,inherit);text-transform:inherit;text-transform:var(--mdc-typography-body2-text-transform,inherit);margin:0 12px}.forge-paginator__range-label--alternative{display:none}.forge-paginator__container{display:-webkit-box;display:flex;-webkit-box-align:center;align-items:center}.forge-paginator__label{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto,sans-serif;font-family:var(--mdc-typography-caption-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:.75rem;font-size:var(--mdc-typography-caption-font-size, .75rem);line-height:1.25rem;line-height:var(--mdc-typography-caption-line-height, 1.25rem);font-weight:400;font-weight:var(--mdc-typography-caption-font-weight,400);letter-spacing:.0333333333em;letter-spacing:var(--mdc-typography-caption-letter-spacing, .0333333333em);text-decoration:inherit;-webkit-text-decoration:var(--mdc-typography-caption-text-decoration,inherit);text-decoration:var(--mdc-typography-caption-text-decoration,inherit);text-transform:inherit;text-transform:var(--mdc-typography-caption-text-transform,inherit);margin-right:16px}.forge-paginator__page-size-options{margin-right:16px}.forge-paginator__range-label{-moz-osx-font-smoothing:grayscale;-webkit-font-smoothing:antialiased;font-family:Roboto,sans-serif;font-family:var(--mdc-typography-caption-font-family, var(--mdc-typography-font-family, Roboto, sans-serif));font-size:.75rem;font-size:var(--mdc-typography-caption-font-size, .75rem);line-height:1.25rem;line-height:var(--mdc-typography-caption-line-height, 1.25rem);font-weight:400;font-weight:var(--mdc-typography-caption-font-weight,400);letter-spacing:.0333333333em;letter-spacing:var(--mdc-typography-caption-letter-spacing, .0333333333em);text-decoration:inherit;-webkit-text-decoration:var(--mdc-typography-caption-text-decoration,inherit);text-decoration:var(--mdc-typography-caption-text-decoration,inherit);text-transform:inherit;text-transform:var(--mdc-typography-caption-text-transform,inherit);margin-right:8px}.forge-paginator__first-page,.forge-paginator__last-page,.forge-paginator__next-page,.forge-paginator__previous-page{color:rgba(0,0,0,.87);color:var(--mdc-theme-text-primary-on-background,rgba(0,0,0,.87))}:host{display:inline-block}:host([hidden]){display:none}:host([alternative]) .forge-paginator--alignment-center .forge-paginator__container{-webkit-box-pack:center;justify-content:center}:host([alternative]) .forge-paginator--alignment-center .forge-paginator__range-label--alternative{margin:0 auto}:host([alternative]) .forge-paginator--alignment-start .forge-paginator__container{-webkit-box-pack:start;justify-content:flex-start}:host([alternative]) .forge-paginator--alignment-end .forge-paginator__container{-webkit-box-pack:end;justify-content:flex-end}:host([alternative]) .forge-paginator .forge-paginator__container{-webkit-box-flex:1;flex:1}';\n\nexport interface IPaginatorComponent extends IBaseComponent {\n pageIndex: number;\n pageSize: number;\n offset: number;\n total: number;\n pageSizeOptions: number[] | boolean;\n label: string;\n firstLast: boolean;\n first: boolean;\n disabled: boolean;\n alternative: boolean;\n alignment: PaginatorAlternativeAlignment;\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'forge-paginator': IPaginatorComponent;\n }\n\n interface HTMLElementEventMap {\n 'forge-paginator-change': CustomEvent<IPaginatorChangeEvent>;\n }\n}\n\n/**\n * @tag forge-paginator\n */\n@CustomElement({\n name: PAGINATOR_CONSTANTS.elementName,\n dependencies: [\n IconButtonComponent,\n SelectComponent,\n IconComponent,\n TooltipComponent\n ]\n})\nexport class PaginatorComponent extends BaseComponent implements IPaginatorComponent {\n public static get observedAttributes(): string[] {\n return [\n PAGINATOR_CONSTANTS.attributes.PAGE_INDEX,\n PAGINATOR_CONSTANTS.attributes.PAGE_SIZE,\n PAGINATOR_CONSTANTS.attributes.OFFSET,\n PAGINATOR_CONSTANTS.attributes.TOTAL,\n PAGINATOR_CONSTANTS.attributes.PAGE_SIZE_OPTIONS,\n PAGINATOR_CONSTANTS.attributes.LABEL,\n PAGINATOR_CONSTANTS.attributes.FIRST_LAST,\n PAGINATOR_CONSTANTS.attributes.FIRST,\n PAGINATOR_CONSTANTS.attributes.DISABLED,\n PAGINATOR_CONSTANTS.attributes.ALTERNATIVE,\n PAGINATOR_CONSTANTS.attributes.ALIGNMENT\n ];\n }\n\n private _foundation: PaginatorFoundation;\n\n constructor() {\n super();\n IconRegistry.define([\n tylIconFirstPage,\n tylIconKeyboardArrowLeft,\n tylIconKeyboardArrowRight,\n tylIconLastPage\n ]);\n attachShadowTemplate(this, template, styles);\n this._foundation = new PaginatorFoundation(new PaginatorAdapter(this));\n }\n\n public connectedCallback(): void {\n this._foundation.initialize();\n }\n\n public disconnectedCallback(): void {\n this._foundation.disconnect();\n }\n\n public attributeChangedCallback(name: string, oldValue: string, newValue: string): void {\n switch (name) {\n case PAGINATOR_CONSTANTS.attributes.PAGE_INDEX:\n this.pageIndex = Number(newValue) || PAGINATOR_CONSTANTS.numbers.DEFAULT_PAGE_INDEX;\n break;\n case PAGINATOR_CONSTANTS.attributes.PAGE_SIZE:\n this.pageSize = Number(newValue) || PAGINATOR_CONSTANTS.numbers.DEFAULT_PAGE_SIZE;\n break;\n case PAGINATOR_CONSTANTS.attributes.OFFSET:\n this.offset = Number(newValue);\n break;\n case PAGINATOR_CONSTANTS.attributes.TOTAL:\n this.total = Number(newValue) || PAGINATOR_CONSTANTS.numbers.DEFAULT_TOTAL;\n break;\n case PAGINATOR_CONSTANTS.attributes.PAGE_SIZE_OPTIONS:\n this.pageSizeOptions = newValue as any;\n break;\n case PAGINATOR_CONSTANTS.attributes.LABEL:\n this.label = newValue;\n break;\n case PAGINATOR_CONSTANTS.attributes.FIRST_LAST:\n this.firstLast = coerceBoolean(newValue);\n break;\n case PAGINATOR_CONSTANTS.attributes.FIRST:\n this.first = coerceBoolean(newValue);\n break;\n case PAGINATOR_CONSTANTS.attributes.DISABLED:\n this.disabled = coerceBoolean(newValue);\n break;\n case PAGINATOR_CONSTANTS.attributes.ALTERNATIVE:\n this.alternative = coerceBoolean(newValue);\n break;\n case PAGINATOR_CONSTANTS.attributes.ALIGNMENT:\n this.alignment = newValue as PaginatorAlternativeAlignment;\n break;\n }\n }\n\n /** The zero-based page index. Default is 0. */\n @FoundationProperty()\n public declare pageIndex: number;\n\n /** Number of items to display on a page. By default set to 25. */\n @FoundationProperty()\n public declare pageSize: number;\n\n /** Sets page index by providing the number of items to skip. The getter for this property returns the number of items to skip. */\n @FoundationProperty()\n public declare offset: number;\n\n /** The total number of items to be paginated. Default is 0. */\n @FoundationProperty()\n public declare total: number;\n\n /** The set of provided page size options to display to the user. */\n @FoundationProperty()\n public declare pageSizeOptions: number[] | boolean;\n\n /** A label for the paginator. Default is \"Rows per page:\". */\n @FoundationProperty()\n public declare label: string;\n\n /** Whether to show the first page and last page buttons. Default is false. */\n @FoundationProperty()\n public declare firstLast: boolean;\n\n /** Whether to show the first page button. Default is false. */\n @FoundationProperty()\n public declare first: boolean;\n\n /** Whether the paginator is disabled. Default is false. */\n @FoundationProperty()\n public declare disabled: boolean;\n\n @FoundationProperty()\n public declare alternative: boolean;\n\n @FoundationProperty()\n public declare alignment: PaginatorAlternativeAlignment;\n\n public override focus(options?: FocusOptions): void {\n this._foundation.focus(options);\n }\n}\n", "import { defineCustomElement } from '@tylertech/forge-core';\n\nimport { PaginatorComponent } from './paginator';\n\nexport * from './paginator-adapter';\nexport * from './paginator-constants';\nexport * from './paginator-foundation';\nexport * from './paginator';\n\nexport function definePaginatorComponent(): void {\n defineCustomElement(PaginatorComponent);\n}\n"],
|
|
5
|
-
"mappings": "ulBAEA,IAAMA,EAA2C,GAAGC,aAE9CC,EAAU,CACd,MAAO,yBACP,kBAAmB,qCACnB,YAAa,+BACb,wBAAyB,4CACzB,kBAAmB,8BACnB,qBAAsB,iCACtB,iBAAkB,6BAClB,iBAAkB,6BAClB,KAAM,kBACN,YAAa,+BACb,gBAAiB,mCACjB,wBAAyB,oCACzB,cAAe,gCACjB,EAEMC,EAAY,CAChB,MAAO,IAAID,EAAQ,QACnB,iBAAkB,IAAIA,EAAQ,oBAC9B,YAAa,IAAIA,EAAQ,cACzB,kBAAmB,IAAIA,EAAQ,6BAC/B,uBAAwB,IAAIA,EAAQ,oBACpC,qBAAsB,IAAIA,EAAQ,gCAClC,iBAAkB,IAAIA,EAAQ,4BAC9B,iBAAkB,IAAIA,EAAQ,4BAC9B,sBAAuB,IAAIA,EAAQ,mBACnC,KAAM,IAAIA,EAAQ,OAClB,wBAAyB,IAAIA,EAAQ,yBACvC,EAEME,EAAa,CACjB,WAAY,aACZ,UAAW,YACX,OAAQ,SACR,kBAAmB,oBACnB,MAAO,QACP,MAAO,QACP,WAAY,aACZ,MAAO,QACP,SAAU,WACV,YAAa,cACb,UAAW,WACb,EAEMC,EAAS,CACb,OAAQ,GAAGL,UACb,EAEMM,EAAU,CACd,mBAAoB,EACpB,cAAe,EACf,kBAAmB,GACnB,0BAA2B,CAAC,EAAG,GAAI,GAAI,GAAI,GAAG,CAChD,EAEMC,EAAU,CACd,cAAe,iBACf,sBAAuB,KACvB,WAAY,aACZ,cAAe,gBACf,UAAW,YACX,UAAW,YACX,UAAW,WACb,EAEaC,EAAsB,CACjC,YAAAR,EACA,QAAAE,EACA,UAAAC,EACA,WAAAC,EACA,OAAAC,EACA,QAAAC,EACA,QAAAC,CACF,EC9DO,IAAME,EAAN,KAA0B,CAoB/B,YAAoBC,EAA6B,CAA7B,cAAAA,E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TjB,EAqHI,yBArHJA,EAANgB,EAAA,CATNE,EAAc,CACb,KAAMR,EAAoB,YAC1B,aAAc,CACZS,EACAC,EACAC,EACAC,CACF,CACF,CAAC,GACYtB,GCzCN,SAASuB,IAAiC,CAC/CC,EAAoBC,CAAkB,CACxC",
|
|
6
|
-
"names": ["elementName", "COMPONENT_NAME_PREFIX", "classes", "selectors", "attributes", "events", "numbers", "strings", "PAGINATOR_CONSTANTS", "PaginatorFoundation", "_adapter", "PAGINATOR_CONSTANTS", "o", "evt", "options", "firstPage", "prevPage", "nextPage", "lastPage", "pageSize", "type", "pageIndex", "offset", "detail", "startIndex", "pageStart", "pageEnd", "maxPages", "value", "clampedValue", "disabled", "isDefined", "isArray", "a", "b", "coerceNumber", "PaginatorAdapter", "BaseAdapter", "component", "getShadowElement", "PAGINATOR_CONSTANTS", "value", "options", "removeAllChildren", "toggleElementPlaceholder", "listener", "visible", "alternative", "toggleClass", "alignment", "removeClass", "addClass", "from", "elements", "preventScroll", "el", "__spreadProps", "__spreadValues", "template", "styles", "PaginatorComponent", "BaseComponent", "IconRegistry", "tylIconFirstPage", "tylIconKeyboardArrowLeft", "tylIconKeyboardArrowRight", "tylIconLastPage", "attachShadowTemplate", "PaginatorFoundation", "PaginatorAdapter", "PAGINATOR_CONSTANTS", "name", "oldValue", "newValue", "coerceBoolean", "options", "__decorateClass", "FoundationProperty", "CustomElement", "IconButtonComponent", "SelectComponent", "IconComponent", "TooltipComponent", "definePaginatorComponent", "defineCustomElement", "PaginatorComponent"]
|
|
7
|
-
}
|
|
File without changes
|
|
File without changes
|
|
File without changes
|