@ukic/canary-web-components 2.0.0-canary.22 → 2.0.0-canary.24
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/core.cjs.js +1 -1
 - package/dist/cjs/ic-button_3.cjs.entry.js +5 -2
 - package/dist/cjs/ic-button_3.cjs.entry.js.map +1 -1
 - package/dist/cjs/ic-data-table.cjs.entry.js +5 -0
 - package/dist/cjs/ic-data-table.cjs.entry.js.map +1 -1
 - package/dist/cjs/ic-pagination_4.cjs.entry.js +2 -2
 - package/dist/cjs/ic-pagination_4.cjs.entry.js.map +1 -1
 - package/dist/cjs/ic-radio-group.cjs.entry.js +7 -0
 - package/dist/cjs/ic-radio-group.cjs.entry.js.map +1 -1
 - package/dist/cjs/ic-toast.cjs.entry.js +1 -1
 - package/dist/cjs/ic-toast.cjs.entry.js.map +1 -1
 - package/dist/cjs/loader.cjs.js +1 -1
 - package/dist/collection/components/ic-data-table/ic-data-table.js +26 -1
 - package/dist/collection/components/ic-data-table/ic-data-table.js.map +1 -1
 - package/dist/collection/components/ic-data-table/ic-data-table.types.js.map +1 -1
 - package/dist/collection/components/ic-data-table/story-data.js +6 -0
 - package/dist/collection/components/ic-data-table/story-data.js.map +1 -1
 - package/dist/collection/components/ic-data-table/test/basic/ic-data-table.spec.js +15 -0
 - package/dist/collection/components/ic-data-table/test/basic/ic-data-table.spec.js.map +1 -1
 - package/dist/components/ic-button2.js +5 -2
 - package/dist/components/ic-button2.js.map +1 -1
 - package/dist/components/ic-data-table.js +5 -0
 - package/dist/components/ic-data-table.js.map +1 -1
 - package/dist/components/ic-pagination2.js +2 -2
 - package/dist/components/ic-pagination2.js.map +1 -1
 - package/dist/components/ic-radio-group.js +8 -0
 - package/dist/components/ic-radio-group.js.map +1 -1
 - package/dist/components/ic-toast.js +1 -1
 - package/dist/components/ic-toast.js.map +1 -1
 - package/dist/core/core.esm.js +1 -1
 - package/dist/core/core.esm.js.map +1 -1
 - package/dist/core/p-1f9cb805.entry.js +2 -0
 - package/dist/core/p-1f9cb805.entry.js.map +1 -0
 - package/dist/core/p-2f7e6e38.entry.js +2 -0
 - package/dist/core/p-2f7e6e38.entry.js.map +1 -0
 - package/dist/core/p-b2c433e2.entry.js +2 -0
 - package/dist/core/p-b2c433e2.entry.js.map +1 -0
 - package/dist/core/{p-355c8532.entry.js → p-bee3fdb0.entry.js} +2 -2
 - package/dist/core/p-bee3fdb0.entry.js.map +1 -0
 - package/dist/core/p-ec9edecf.entry.js +2 -0
 - package/dist/core/p-ec9edecf.entry.js.map +1 -0
 - package/dist/esm/core.js +1 -1
 - package/dist/esm/ic-button_3.entry.js +5 -2
 - package/dist/esm/ic-button_3.entry.js.map +1 -1
 - package/dist/esm/ic-data-table.entry.js +5 -0
 - package/dist/esm/ic-data-table.entry.js.map +1 -1
 - package/dist/esm/ic-pagination_4.entry.js +2 -2
 - package/dist/esm/ic-pagination_4.entry.js.map +1 -1
 - package/dist/esm/ic-radio-group.entry.js +7 -0
 - package/dist/esm/ic-radio-group.entry.js.map +1 -1
 - package/dist/esm/ic-toast.entry.js +1 -1
 - package/dist/esm/ic-toast.entry.js.map +1 -1
 - package/dist/esm/loader.js +1 -1
 - package/dist/types/components/ic-data-table/ic-data-table.d.ts +6 -2
 - package/dist/types/components/ic-data-table/ic-data-table.types.d.ts +4 -0
 - package/dist/types/components.d.ts +9 -4
 - package/hydrate/index.js +20 -5
 - package/package.json +3 -3
 - package/dist/core/p-355c8532.entry.js.map +0 -1
 - package/dist/core/p-413e68be.entry.js +0 -2
 - package/dist/core/p-413e68be.entry.js.map +0 -1
 - package/dist/core/p-84eaa486.entry.js +0 -2
 - package/dist/core/p-84eaa486.entry.js.map +0 -1
 - package/dist/core/p-a787bba7.entry.js +0 -2
 - package/dist/core/p-a787bba7.entry.js.map +0 -1
 - package/dist/core/p-e9f5ebb3.entry.js +0 -2
 - package/dist/core/p-e9f5ebb3.entry.js.map +0 -1
 
| 
         @@ -0,0 +1 @@ 
     | 
|
| 
      
 1 
     | 
    
         
            +
            {"version":3,"names":["icDataTableCss","DataTable","this","DENSITY_HEIGHT_MULTIPLIER","dense","default","spacious","DENSITY_PADDING_HEIGHT_DIFF","SORT_ICONS","unsorted","unsortedIcon","ascending","ascendingIcon","descending","descendingIcon","hasLoadedForOneSecond","resizeObserver","SHOW_HIDE_STRING","SHOW_HIDE_CSS_CLASS","TOOLTIP_STRING","TOOLTIP","TEXT_WRAP_STRING","TEXT_WRAP_CLASS","dataUpdated","rowHeightSet","initialLoad","icPageChangeEvent","itemsPerPageChange","DATA_ROW_HEIGHT_STRING","DEFAULT_LINE_HEIGHT","densityUpdate","updateSetRowHeight","typographyEl","fontSize","parseInt","getComputedStyle","document","documentElement","cellContainer","getCellContainer","rowHeight","parseFloat","getAttribute","scrollHeight","style","removeProperty","getTypographyElements","forEach","debounceDataTruncation","classList","contains","ResizeObserver","debounce","dataTruncation","observe","getLines","height","Math","floor","truncate","tooltip","clientHeight","closest","truncationPattern","addTooltipTruncation","addShowHideTruncation","setAttribute","appendChild","remove","isEmptyString","resetShowHideTruncation","getTooltip","shadowRoot","querySelector","showHideBtn","truncWrapper","getTruncWrapper","removeTooltip","removeTextWrap","tableCell","deleteTextWrapDataKey","array","Array","isArray","val","textWrap","startLoadingTimer","timerStarted","Date","now","setTimeout","minimumLoadingDisplayDuration","isObject","value","notDefaultDensity","density","getCellContent","cell","dataType","undefined","toLocaleDateString","getCellAlignment","alignment","Object","keys","includes","getObjectValue","getCellOptions","key","createUpdatingIndicator","appearance","description","max","min","progress","updatingOptions","h","colSpan","columns","length","class","fullWidth","type","size","setRowHeight","pxToRem","setTruncationClass","createCells","row","rowIndex","rowValues","values","rowKeys","index","rowOptions","getRowOptions","rowAlignment","rowEmphasis","headerIndex","indexOf","variableRowHeightVal","_a","variableRowHeight","call","assign","currentRowHeight","globalRowHeight","map","columnProps","cellSlotName","hasIcon","cellValue","scope","stickyRowHeaders","innerHTML","isSlotUsed","el","columnAlignment","vertical","_b","_c","_d","_e","horizontal","_f","_g","_h","_j","icon","name","Fragment","_k","onAllCells","variant","emphasis","href","createColumnHeaders","cellAlignment","colspan","title","updating","loading","hideOnHeader","sortable","id","getSortButtonLabel","onClick","sortRows","sortedColumn","sortedColumnOrder","onRowClick","selectedRow","createRows","data","showPagination","slice","fromRow","toRow","getSlotContent","sort","getSortFunction","label","getNextSortOption","option","sortOrders","sortOptions","sortOption","getComparison","targetRow","comparisonRow","targetRowValue","comparisonRowValue","find","col","valueOf","String","localeCompare","numeric","sensitivity","a","b","column","sortButton","previousSortedButton","nextSortOrderIndex","tableSorted","icSortChange","emit","columnName","sorted","from","querySelectorAll","updateTruncationTooltip","removeTooltipOnly","regenerateTooltip","updateScrollOffset","scrollOffset","scrollTop","itemsPerPageOptions","rangeLabelType","showItemsPerPageControl","showGoToPageControl","itemLabel","pageLabel","hideRangeLabel","defaultColumn","disconnectedCallback","disconnect","componentWillLoad","rowsPerPage","Number","paginationBarOptions","previousRowsPerPage","loadingOptions","showBackground","previousItemsPerPage","componentDidLoad","tableElement","tableContainer","clientWidth","scrollable","showLoadingIndicator","componentDidUpdate","truncateUpdatedData","tooltipEl","setProperty","allRows","newRows","createShowHideTruncation","checkMaxLines","setShowHideExpanded","addLineClampCSS","createTruncationTooltip","add","handleTypographyTruncationExpandToggle","detail","expanded","handlePageChange","target","parentElement","tableRowsContainer","previousPaginationPage","handleItemsPerPageChange","handleDensityChange","ev","clickListener","loadingHandler","newValue","truncationPatternHandler","dataHandler","newData","densityHandler","resetTruncation","then","rowHeightChangeHandler","oldValue","icRowHeightChange","resetRowHeights","loadingIndicator","rowOptionsIndex","textContent","createElement","setExternalPopperProps","strategy","render","caption","hideColumnHeaders","stickyColumnHeaders","tabIndex","onScroll","aligned","heading","labelDuration","ref","totalItems"],"sources":["src/components/ic-data-table/ic-data-table.css?tag=ic-data-table&encapsulation=shadow","src/components/ic-data-table/ic-data-table.tsx"],"sourcesContent":[":host {\n  position: relative;\n  display: block;\n  height: 100%;\n  max-height: 100%;\n}\n\ntbody {\n  vertical-align: top;\n}\n\n.table-container {\n  position: relative;\n  height: calc(100% - var(--ic-space-xxxs));\n  display: flex;\n  flex-direction: column;\n}\n\n.cell-container {\n  display: flex;\n  min-height: 1.5rem;\n  overflow-y: hidden;\n}\n\n.truncation-show-hide {\n  overflow: visible;\n  display: block;\n}\n\n.cell-icon.truncation-show-hide {\n  display: flex;\n}\n\n.cell-container:not(.data-type-element, .truncation-show-hide) {\n  overflow-x: hidden;\n}\n\nic-loading-indicator {\n  position: sticky;\n  top: 20px;\n}\n\n.table-row-container {\n  position: relative;\n  height: 100%;\n  overflow: auto;\n  transition: var(--ic-easing-transition-fast);\n  overflow-anchor: none;\n}\n\n:host([show-pagination=\"true\"]) .table-row-container {\n  height: calc(100% - 3.5625rem);\n}\n\ntable {\n  table-layout: fixed;\n  border-spacing: 0;\n  width: 100%;\n}\n\n.table-row-container:focus {\n  outline: none;\n  box-shadow: var(--ic-border-focus);\n  border-radius: var(--ic-border-radius);\n  transition: var(--ic-easing-transition-fast);\n  z-index: 1;\n}\n\n:host([embedded=\"true\"]) .table-row-container {\n  border: var(--ic-border-light);\n}\n\n.column-header-sticky {\n  position: sticky;\n  top: 0;\n  z-index: 1;\n}\n\n.column-header-overlay {\n  position: sticky;\n  top: 0;\n  z-index: 1;\n  box-shadow: 0 0.375rem var(--ic-space-xs) calc(var(--ic-space-xxs * -1))\n    rgb(0 0 0 / 20%);\n}\n\n.row-header-sticky {\n  position: sticky;\n  left: 0;\n}\n\n.column-header,\n.table-row {\n  box-sizing: border-box;\n}\n\n.table-row-selected {\n  background-color: var(--ic-table-row-selected) !important;\n}\n\n.sort-button {\n  margin-left: auto;\n}\n\n.sort-button:hover {\n  background-color: var(--ic-action-dark-bg-hover);\n}\n\n.sort-button:active {\n  background-color: var(--ic-action-dark-bg-active);\n}\n\n.sort-button svg {\n  color: var(--ic-architectural-black);\n}\n\n.sort-button-unsorted svg {\n  color: var(--ic-color-tertiary-text);\n}\n\n.table-density-dense {\n  padding: var(--ic-space-xxs) var(--ic-space-xs) !important;\n}\n\n.text-dense {\n  font-size: var(--ic-font-size-label);\n}\n\n.table-density-spacious {\n  padding: 0.625rem var(--ic-space-xs) !important;\n}\n\n.text-spacious {\n  font-size: 1.125rem;\n}\n\n.column-header-text {\n  font-weight: var(--ic-font-weight-bold);\n}\n\n.column-header,\n.row-header {\n  text-align: left;\n  padding: var(--ic-space-xs);\n  background-color: var(--ic-architectural-40);\n  border-right: var(--ic-border-light);\n  border-bottom: var(--ic-border-light);\n}\n\n.column-header:last-child {\n  border-right: none;\n}\n\n.scrollable .column-header:last-child {\n  border-right: var(--ic-border-light) !important;\n}\n\n:host([embedded=\"true\"]) tr:last-child .table-cell,\n:host([embedded=\"true\"]) tr:last-child .row-header {\n  border-bottom: none;\n}\n\n.column-header-alignment-left,\n.row-header-alignment-left,\n.cell-alignment-left {\n  text-align: left !important;\n  justify-content: start !important;\n}\n\n.column-header-alignment-right,\n.row-header-alignment-right,\n.cell-alignment-right {\n  text-align: right !important;\n  justify-content: end !important;\n}\n\n.cell-alignment-right.truncation-tooltip ic-tooltip ic-typography {\n  padding-right: calc(var(--ic-space-xxs) + var(--ic-space-xs));\n}\n\n.cell-alignment-right.truncation-show-hide ic-typography {\n  --ellipsis-padding-right: calc(var(--ic-space-xxs) + var(--ic-space-xs));\n}\n\n.column-header-alignment-center,\n.row-header-alignment-center,\n.cell-alignment-center {\n  text-align: center !important;\n  justify-content: center !important;\n}\n\n.table-row:nth-child(even) {\n  background-color: var(--ic-architectural-20);\n}\n\n.table-cell {\n  padding: var(--ic-space-xs);\n  border-bottom: solid var(--ic-architectural-100) var(--ic-space-1px);\n  overflow: hidden;\n}\n\n.data-type-string,\n.data-type-address {\n  text-align: left;\n  vertical-align: top;\n}\n\n.data-type-number,\n.data-type-date {\n  text-align: right;\n  justify-content: end;\n  vertical-align: top;\n}\n\n.cell-alignment-top {\n  vertical-align: top;\n  align-items: flex-start;\n}\n\n.cell-alignment-middle {\n  vertical-align: middle;\n  align-items: center;\n}\n\n.cell-alignment-bottom {\n  vertical-align: bottom;\n  align-items: flex-end;\n}\n\n.cell-emphasis-low {\n  color: var(--ic-color-secondary-text);\n}\n\n.cell-emphasis-high {\n  font-weight: var(--ic-font-weight-bold);\n}\n\n.pagination-container {\n  background-color: var(--ic-architectural-40);\n  border-top: var(--ic-border-light);\n}\n\n.screen-reader-sort-text,\n.table-caption {\n  position: absolute;\n  left: -100rem;\n}\n\n.table-cell,\n.column-header,\n.row-header {\n  word-wrap: break-word;\n  white-space: pre-wrap;\n}\n\n.loading-empty {\n  padding: var(--ic-space-xl) var(--ic-space-xxl);\n  margin-top: var(--ic-space-xl);\n}\n\n.updating-state {\n  padding: 0;\n  border-bottom: var(--ic-border-light);\n}\n\n.updating-state-headers {\n  border-bottom: none;\n}\n\n.loading {\n  position: absolute;\n  left: calc(50% - 5.9741rem);\n  opacity: 0;\n  transition: opacity var(--ic-transition-duration-slow);\n}\n\n.loading.show-background {\n  background-color: var(--ic-architectural-white);\n  border: var(--ic-border-light);\n}\n\n.loading.show {\n  opacity: 1;\n}\n\n.icon,\n::slotted(svg) {\n  height: var(--ic-space-lg);\n  width: var(--ic-space-lg);\n  margin-right: var(--ic-space-xxs);\n}\n\n.column-header-alignment-right > .icon,\n.row-header-alignment-right > .icon,\n.cell-alignment-right > .icon,\n.column-header-alignment-right > ::slotted(svg),\n.row-header-alignment-right > ::slotted(svg),\n.cell-alignment-right > ::slotted(svg) {\n  margin-right: auto;\n}\n\n.column-header-alignment-center > ic-typography,\n.row-header-alignment-right > ic-typography,\n.cell-alignment-center > ic-typography {\n  flex: 1;\n}\n\n.icon > svg {\n  height: var(--ic-space-lg);\n  width: var(--ic-space-lg);\n  display: inline-block;\n}\n\n.truncation-tooltip ic-typography {\n  display: -webkit-box;\n  -webkit-line-clamp: var(--ic-line-clamp, 0);\n  -webkit-box-orient: vertical;\n  overflow: hidden;\n}\n\n.truncation-tooltip ic-typography,\n.truncation-show-hide ic-typography {\n  white-space: normal;\n}\n\n.ic-tooltip-overflow {\n  overflow: hidden;\n}\n\n@media screen and (min-width: 576px) {\n  .column-header-inner-container {\n    display: flex;\n    align-items: center;\n  }\n}\n","/* eslint-disable @typescript-eslint/no-explicit-any */\nimport {\n  Component,\n  Element,\n  h,\n  Prop,\n  State,\n  Listen,\n  Watch,\n  Fragment,\n  Method,\n  Event,\n  EventEmitter,\n} from \"@stencil/core\";\nimport unsortedIcon from \"./assets/unsorted-icon.svg\";\nimport ascendingIcon from \"./assets/ascending-icon.svg\";\nimport descendingIcon from \"./assets/descending-icon.svg\";\nimport {\n  IcDataTableColumnDataTypes,\n  IcDataTableColumnObject,\n  IcDataTableDensityOptions,\n  IcDataTableRowHeights,\n  IcDataTableSortOrderOptions,\n  IcDataTableTruncationTypes,\n  IcDensityUpdateEventDetail,\n  IcSortEventDetail,\n} from \"./ic-data-table.types\";\nimport { IcThemeForegroundNoDefault } from \"@ukic/web-components/dist/types/utils/types\";\nimport { IcPaginationBarOptions } from \"../../utils/types\";\n// Unable to import helper functions via @ukic/web-components\nimport {\n  getSlotContent,\n  isEmptyString,\n  isSlotUsed,\n  pxToRem,\n  debounce,\n} from \"../../utils/helpers\";\n\n/**\n * @slot empty-state - Content is slotted below the table header when there is no data and the table is not loading.\n * @slot {COLUMN_KEY}-{ROW_INDEX}[-icon] - Each cell should have its own slot, named using the column tag and the row index, allowing for custom elements to be displayed. Include `-icon` at the end for that cell's icon slot.\n * @slot {COLUMN_KEY}-column-icon - The icon slot for a column header.\n * @slot title-bar - A custom ic-data-table-title-bar can be slotted above the column headers to display additional information about the table.\n * @slot pagination-bar - A custom ic-pagination-bar can be slotted below the data to provide enhanced control over how the data is interacted with when being fetched externally.\n */\n@Component({\n  tag: \"ic-data-table\",\n  styleUrl: \"ic-data-table.css\",\n  shadow: true,\n})\nexport class DataTable {\n  private DENSITY_HEIGHT_MULTIPLIER = {\n    dense: 0.8,\n    default: 1,\n    spacious: 1.2,\n  };\n\n  private DENSITY_PADDING_HEIGHT_DIFF = {\n    dense: 8,\n    default: 16,\n    spacious: 20,\n  };\n\n  private SORT_ICONS = {\n    unsorted: unsortedIcon,\n    ascending: ascendingIcon,\n    descending: descendingIcon,\n  };\n\n  private hasLoadedForOneSecond: boolean = true;\n  private loadingIndicator: HTMLIcLoadingIndicatorElement;\n  private timerStarted: number;\n  private resizeObserver: ResizeObserver = null;\n  private SHOW_HIDE_STRING = \"show-hide\";\n  private SHOW_HIDE_CSS_CLASS = `${this.SHOW_HIDE_STRING}-wrap`;\n  private TOOLTIP_STRING = \"tooltip\";\n  private TOOLTIP = `ic-${this.TOOLTIP_STRING}`;\n  private TEXT_WRAP_STRING = \"text-wrap\";\n  private TEXT_WRAP_CLASS = `.${this.TEXT_WRAP_STRING}`;\n  private dataUpdated = false;\n  private tableSorted: boolean;\n  private rowHeightSet = false;\n  private initialLoad: boolean = false;\n  private icPageChangeEvent: boolean = false;\n  private itemsPerPageChange: boolean = false;\n  private DATA_ROW_HEIGHT_STRING = \"data-row-height\";\n  private previousItemsPerPage: number;\n  private DEFAULT_LINE_HEIGHT = 24;\n  private densityUpdate: boolean = false;\n  private previousPaginationPage: number;\n\n  @Element() el: HTMLIcDataTableElement;\n\n  @State() fromRow: number = 0;\n\n  @State() previousRowsPerPage: number;\n\n  @State() rowsPerPage: number;\n\n  @State() scrollable: boolean = false;\n\n  @State() scrollOffset: number = 0;\n\n  @State() selectedRow: object;\n\n  @State() sortedColumn: string;\n\n  @State() sortedColumnOrder: IcDataTableSortOrderOptions;\n\n  @State() toRow: number;\n\n  @State() currentRowHeight: number;\n\n  /**\n   * The title for the table only visible to screen readers.\n   */\n  @Prop() caption!: string;\n\n  /**\n   * The column headers for the table.\n   */\n  @Prop() columns!: IcDataTableColumnObject[];\n\n  /**\n   * The row content for the table.\n   */\n  @Prop() data: { [key: string]: any }[];\n\n  /**\n   * Set the density of the table including font and padding.\n   */\n  @Prop({ mutable: true }) density?: IcDataTableDensityOptions = \"default\";\n\n  /**\n   * Applies a border to the table container.\n   */\n  @Prop() embedded?: boolean = false;\n\n  /**\n   * Sets the row height on all rows in the table that aren't set using the `variableRowHeight` method.\n   */\n  @Prop({ mutable: true }) globalRowHeight?: IcDataTableRowHeights = \"auto\";\n\n  /**\n   * If `true`, column headers will not be visible.\n   */\n  @Prop() hideColumnHeaders?: boolean = false;\n\n  /**\n   * When set to `true`, the full table will show a loading state, featuring a radial indicator.\n   */\n  @Prop({ mutable: true }) loading?: boolean = false;\n\n  /**\n   * Sets the props for the circular loading indicator used in the loading state.\n   */\n  @Prop() loadingOptions?: {\n    appearance?: IcThemeForegroundNoDefault;\n    description?: string;\n    label?: string;\n    labelDuration?: number;\n    max?: number;\n    min?: number;\n    progress?: number;\n    showBackground?: boolean;\n  };\n\n  /**\n   * The minimum amount of time the `loading` state displays for before showing the data. Used to prevent flashing in the component.\n   */\n  @Prop() minimumLoadingDisplayDuration?: number = 1000;\n\n  /**\n   * Sets the props for the built-in pagination bar. If the `pagination-bar` slot is used then this prop is ignored.\n   */\n  @Prop() paginationBarOptions?: IcPaginationBarOptions = {\n    itemsPerPageOptions: [\n      { label: \"10\", value: \"10\" },\n      { label: \"25\", value: \"25\" },\n      { label: \"50\", value: \"50\" },\n    ],\n    rangeLabelType: \"page\",\n    type: \"simple\",\n    showItemsPerPageControl: true,\n    showGoToPageControl: true,\n    alignment: \"right\",\n    appearance: \"default\",\n    itemLabel: \"Item\",\n    pageLabel: \"Page\",\n    hideRangeLabel: false,\n  };\n\n  /**\n   * If `true`, adds a pagination bar to the bottom of the table.\n   */\n  @Prop() showPagination?: boolean = false;\n\n  /**\n   * If `true`, allows table columns to be sorted using applied sort buttons.\n   */\n  @Prop() sortable?: boolean = false;\n\n  /**\n   * Sets the order columns will be sorted in and allows for 'default' sorts to be added.\n   */\n  @Prop() sortOptions?: {\n    sortOrders: IcDataTableSortOrderOptions[];\n    defaultColumn?: string;\n  } = {\n    sortOrders: [\"unsorted\", \"ascending\", \"descending\"],\n    defaultColumn: \"\",\n  };\n\n  /**\n   * If `true`, column headers will remain at the top of the table when scrolling vertically.\n   */\n  @Prop() stickyColumnHeaders?: boolean = false;\n\n  /**\n   * If `true`, row headers will remain to the left when scrolling horizontally.\n   */\n  @Prop() stickyRowHeaders?: boolean = false;\n\n  /**\n   * Sets the method used to truncate longer text in cells where textWrap is `false`.\n   * The `tooltip` truncation pattern allows the overflowing text to be seen in a tooltip. The `show-hide` truncation pattern allows the overflowing text to be shown and hidden using the ic-typography \"See more\" / \"See less\" buttons.\n   */\n  @Prop() truncationPattern?: IcDataTableTruncationTypes;\n\n  /**\n   * If `true`, the table displays a linear loading indicator below the header row to indicate an updating state.\n   */\n  @Prop() updating?: boolean = false;\n\n  /**\n   * Sets the props for the linear loading indicator used in the updating state.\n   */\n  @Prop() updatingOptions?: {\n    appearance?: IcThemeForegroundNoDefault;\n    description?: string;\n    max?: number;\n    min?: number;\n    progress?: number;\n  };\n\n  /**\n   * Allows for custom setting of row heights on individual rows based on an individual value from the `data` prop and the row index.\n   * If the function returns `null`, that row's height will be set to the `globalRowHeight` property.\n   */\n  @Prop({ mutable: true }) variableRowHeight?: (params: {\n    [key: string]: any;\n    index: number;\n  }) => IcDataTableRowHeights | null;\n\n  /**\n   * Emitted when the `globalRowHeight` or `variableRowHeight` properties change in the data table.\n   */\n  @Event() icRowHeightChange: EventEmitter<void>;\n\n  /**\n   * Emitted when a column sort button is clicked.\n   */\n  @Event() icSortChange: EventEmitter<IcSortEventDetail>;\n\n  disconnectedCallback(): void {\n    this.resizeObserver?.disconnect();\n  }\n\n  componentWillLoad(): void {\n    this.rowsPerPage = Number(\n      this.paginationBarOptions.itemsPerPageOptions[0].value\n    );\n    this.previousRowsPerPage = this.rowsPerPage;\n    this.toRow = this.rowsPerPage;\n    this.sortedColumn = this.sortOptions.defaultColumn;\n    this.sortedColumnOrder = this.sortOptions.sortOrders[0];\n    this.loadingOptions = {\n      ...this.loadingOptions,\n      showBackground: this.data?.length > 0,\n    };\n    this.initialLoad = true;\n    this.previousItemsPerPage = this.rowsPerPage;\n  }\n\n  componentDidLoad(): void {\n    const tableElement = this.el.shadowRoot.querySelector(\"table\");\n    const tableContainer = this.el.shadowRoot.querySelector(\".table-container\");\n\n    if (this.dataUpdated) {\n      this.dataUpdated = false;\n    }\n\n    if (\n      tableElement?.clientHeight > tableContainer?.clientHeight ||\n      tableElement?.clientWidth > tableContainer?.clientWidth\n    ) {\n      this.scrollable = true;\n    }\n    if (this.loading) {\n      this.startLoadingTimer();\n      this.showLoadingIndicator();\n    }\n\n    if (this.truncationPattern) {\n      this.getTypographyElements().forEach(\n        (typographyEl: HTMLIcTypographyElement) => {\n          if (!typographyEl.classList.contains(this.TEXT_WRAP_STRING)) {\n            this.dataTruncation(typographyEl);\n          }\n        }\n      );\n\n      this.debounceDataTruncation();\n    }\n\n    if (this.globalRowHeight !== \"auto\") {\n      this.updateSetRowHeight();\n    }\n  }\n\n  componentDidUpdate(): void {\n    this.truncateUpdatedData();\n  }\n\n  private truncateUpdatedData() {\n    if (this.dataUpdated) {\n      if (this.truncationPattern === this.SHOW_HIDE_STRING) {\n        this.resetShowHideTruncation();\n      }\n\n      if (this.truncationPattern === this.TOOLTIP_STRING) {\n        this.updateTruncationTooltip();\n      }\n\n      this.dataUpdated = false;\n    }\n\n    if (this.tableSorted) {\n      if (this.truncationPattern === this.TOOLTIP_STRING) {\n        this.updateTruncationTooltip();\n      }\n\n      this.tableSorted = false;\n    }\n\n    // This function recalculates the tooltip truncation when the rowHeight has been set.\n    // This is in componentDidUpdate so a setTimeout is not used to wait for the render to be complete\n    if (this.rowHeightSet) {\n      const fontSize = parseInt(\n        getComputedStyle(document.documentElement).fontSize\n      );\n\n      this.getTypographyElements().forEach(\n        (typographyEl: HTMLIcTypographyElement) => {\n          const cellContainer = this.getCellContainer(typographyEl);\n          const tooltipEl = this.getTooltip(typographyEl);\n\n          const rowHeight =\n            fontSize *\n            parseFloat(cellContainer.getAttribute(this.DATA_ROW_HEIGHT_STRING));\n\n          // If the set row height is bigger than the cell container even\n          // with textWrap, set the row height\n          if (\n            !cellContainer?.style?.height &&\n            rowHeight > cellContainer.clientHeight\n          ) {\n            cellContainer.style.setProperty(\n              \"height\",\n              cellContainer.getAttribute(this.DATA_ROW_HEIGHT_STRING)\n            );\n          }\n\n          if (this.truncationPattern) {\n            // If the set row height is bigger than the typography truncation wrapper\n            // scroll height, remove see more / see less button\n            if (this.truncationPattern === this.SHOW_HIDE_STRING) {\n              const truncWrapper = this.getTruncWrapper(typographyEl);\n              const showHideBtn =\n                typographyEl.shadowRoot.querySelector(\"button\");\n\n              if (\n                showHideBtn &&\n                truncWrapper?.scrollHeight <= cellContainer.clientHeight\n              ) {\n                this.resetShowHideTruncation(typographyEl);\n                return;\n              }\n            }\n\n            this.truncate(typographyEl, cellContainer, tooltipEl);\n          } else {\n            this.updateSetRowHeight(typographyEl);\n          }\n        }\n      );\n\n      this.rowHeightSet = false;\n    }\n\n    // Only run truncation on the new rows\n    // when the number of items per page has increased\n    if (this.itemsPerPageChange) {\n      const allRows = this.el.shadowRoot.querySelectorAll(\".table-row\");\n\n      if (this.rowsPerPage > this.previousItemsPerPage) {\n        const newRows = Array.from(allRows).slice(this.previousItemsPerPage);\n\n        newRows.forEach((row) => {\n          row\n            .querySelectorAll(\"ic-typography\")\n            .forEach((typographyEl: HTMLIcTypographyElement) => {\n              const cellContainer = this.getCellContainer(typographyEl);\n              const tooltipEl = this.getTooltip(typographyEl);\n\n              this.truncate(typographyEl, cellContainer, tooltipEl);\n            });\n        });\n      }\n\n      this.previousItemsPerPage = this.rowsPerPage;\n      this.itemsPerPageChange = false;\n    }\n\n    if (!this.initialLoad && this.icPageChangeEvent) {\n      if (this.truncationPattern === this.TOOLTIP_STRING) {\n        this.updateTruncationTooltip();\n      }\n\n      // set truncation to see more if opened and next/previous page is pressed\n      if (this.truncationPattern === this.SHOW_HIDE_STRING) {\n        this.getTypographyElements().forEach((typographyEl) => {\n          const cellContainer = this.getCellContainer(typographyEl);\n          const showHideBtn = typographyEl.shadowRoot.querySelector(\"button\");\n\n          if (\n            typographyEl?.scrollHeight > cellContainer.clientHeight &&\n            !showHideBtn\n          ) {\n            this.addShowHideTruncation(cellContainer, typographyEl);\n          }\n        });\n      }\n\n      this.icPageChangeEvent = false;\n    }\n\n    if (this.densityUpdate) {\n      this.getTypographyElements().forEach((typographyEl) => {\n        const cellContainer = this.getCellContainer(typographyEl);\n        const tooltipEl = this.getTooltip(typographyEl);\n\n        this.truncate(typographyEl, cellContainer, tooltipEl);\n      });\n\n      this.densityUpdate = false;\n    }\n  }\n\n  private updateSetRowHeight = (typographyEl?: HTMLIcTypographyElement) => {\n    const fontSize = parseInt(\n      getComputedStyle(document.documentElement).fontSize\n    );\n\n    if (typographyEl) {\n      const cellContainer = this.getCellContainer(typographyEl);\n\n      const rowHeight =\n        fontSize *\n        parseFloat(cellContainer.getAttribute(this.DATA_ROW_HEIGHT_STRING));\n\n      if (typographyEl.scrollHeight > rowHeight) {\n        cellContainer.style.removeProperty(\"height\");\n      }\n    } else {\n      this.getTypographyElements().forEach(\n        (typographyEl: HTMLIcTypographyElement) => {\n          const cellContainer = this.getCellContainer(typographyEl);\n\n          const rowHeight =\n            fontSize *\n            parseFloat(cellContainer.getAttribute(this.DATA_ROW_HEIGHT_STRING));\n\n          if (typographyEl.scrollHeight > rowHeight) {\n            cellContainer.style.removeProperty(\"height\");\n          }\n        }\n      );\n    }\n  };\n\n  private createShowHideTruncation(\n    typographyEl: HTMLIcTypographyElement,\n    cellContainer: HTMLElement\n  ) {\n    typographyEl.checkMaxLines(typographyEl.scrollHeight);\n    typographyEl.setAttribute(\n      \"max-lines\",\n      `${Math.floor(cellContainer?.clientHeight / this.DEFAULT_LINE_HEIGHT)}`\n    );\n    typographyEl.setShowHideExpanded(false);\n\n    cellContainer.style.height = null;\n  }\n\n  private debounceDataTruncation = () => {\n    this.getTypographyElements().forEach(\n      (typographyEl: HTMLIcTypographyElement) => {\n        if (!typographyEl.classList.contains(this.TEXT_WRAP_STRING)) {\n          this.resizeObserver = new ResizeObserver(\n            // This gets triggered twice due to updated data and see more/see less button\n            debounce(() => {\n              // console.log(\"resizeObserver triggered\");\n              this.dataTruncation(typographyEl);\n            }, 200) as ResizeObserverCallback\n          );\n\n          this.resizeObserver.observe(typographyEl);\n        }\n      }\n    );\n  };\n\n  private getLines = (height: number): number =>\n    Math.floor(height / this.DEFAULT_LINE_HEIGHT);\n\n  private truncate = (\n    typographyEl: HTMLIcTypographyElement,\n    cellContainer: HTMLElement,\n    tooltip: HTMLIcTooltipElement\n  ) => {\n    if (typographyEl?.scrollHeight > cellContainer?.clientHeight) {\n      //24 is the height of a single line\n      if (!typographyEl.closest(this.TEXT_WRAP_CLASS)) {\n        if (this.truncationPattern === this.TOOLTIP_STRING) {\n          this.addTooltipTruncation(typographyEl, cellContainer, tooltip);\n        }\n        if (this.truncationPattern === this.SHOW_HIDE_STRING) {\n          this.addShowHideTruncation(cellContainer, typographyEl);\n        }\n      }\n    } else {\n      if (this.truncationPattern === this.TOOLTIP_STRING && tooltip) {\n        typographyEl.setAttribute(\"style\", `--ic-line-clamp: 0`);\n\n        cellContainer.appendChild(typographyEl);\n        tooltip.remove();\n      }\n\n      if (\n        this.truncationPattern === this.SHOW_HIDE_STRING &&\n        !isEmptyString(typographyEl.getAttribute(\"max-lines\"))\n      ) {\n        this.resetShowHideTruncation(typographyEl);\n      }\n    }\n  };\n\n  private addTooltipTruncation(\n    typographyEl: HTMLIcTypographyElement,\n    cellContainer: HTMLElement,\n    tooltip: HTMLIcTooltipElement\n  ) {\n    this.addLineClampCSS(typographyEl, cellContainer);\n\n    if (!tooltip) {\n      this.createTruncationTooltip(typographyEl, cellContainer);\n    }\n  }\n\n  private addShowHideTruncation(\n    cellContainer: HTMLElement,\n    typographyEl: HTMLIcTypographyElement\n  ) {\n    cellContainer.classList.add(this.SHOW_HIDE_CSS_CLASS);\n    this.createShowHideTruncation(typographyEl, cellContainer);\n  }\n\n  private dataTruncation = (typographyEl: HTMLIcTypographyElement) => {\n    // Tooltip truncation mentioned in AC. Will need revisiting\n    const tooltip: HTMLIcTooltipElement = this.getTooltip(typographyEl);\n    const cellContainer = this.getCellContainer(typographyEl);\n    if (\n      cellContainer?.classList.contains(\"data-type-element\") ||\n      this.dataUpdated\n    ) {\n      return;\n    }\n\n    if (\n      this.truncationPattern === this.SHOW_HIDE_STRING &&\n      typographyEl.shadowRoot.querySelector(\"button\")\n    ) {\n      const showHideBtn = typographyEl.shadowRoot.querySelector(\"button\");\n      // If the see more/see less is present and the max lines is equal to the cell container\n      // remove the see more/see less button\n      if (showHideBtn) {\n        const truncWrapper = this.getTruncWrapper(typographyEl);\n\n        if (\n          this.getLines(truncWrapper.scrollHeight) ===\n          +typographyEl.getAttribute(\"max-lines\")\n        ) {\n          this.resetShowHideTruncation(typographyEl);\n        }\n      }\n    }\n\n    // Deals with setting and resetting row height and re-truncating data\n    if (this.rowHeightSet && this.truncationPattern === this.SHOW_HIDE_STRING) {\n      const truncWrapper = this.getTruncWrapper(typographyEl);\n      // cellContainer.clientHeight - 24 removes the extra line by see more/see less\n      if (\n        truncWrapper &&\n        cellContainer.clientHeight - this.DEFAULT_LINE_HEIGHT >\n          truncWrapper.scrollHeight\n      ) {\n        this.resetShowHideTruncation(typographyEl);\n        return;\n      }\n\n      if (typographyEl.scrollHeight > cellContainer.clientHeight) {\n        this.addShowHideTruncation(cellContainer, typographyEl);\n        return;\n      }\n    }\n\n    if (\n      typographyEl?.scrollHeight > 0 &&\n      cellContainer?.clientHeight > 0 &&\n      typographyEl?.scrollHeight === cellContainer?.clientHeight\n    ) {\n      if (tooltip) {\n        this.removeTooltip(cellContainer, typographyEl, tooltip);\n      }\n      return;\n    }\n\n    this.truncate(typographyEl, cellContainer, tooltip);\n  };\n\n  private getTruncWrapper(typographyEl: HTMLIcTypographyElement) {\n    return typographyEl.shadowRoot.querySelector(\".trunc-wrapper\");\n  }\n\n  // Set the height to initial if row height is set and the show / hide truncation\n  // is clicked\n  @Listen(\"typographyTruncationExpandToggle\")\n  handleTypographyTruncationExpandToggle({\n    detail,\n  }: CustomEvent<{\n    expanded: boolean;\n    typographyEl: HTMLIcTypographyElement;\n  }>) {\n    const { expanded, typographyEl } = detail;\n    const cellContainer = this.getCellContainer(typographyEl);\n\n    if (cellContainer.style.height && expanded) {\n      cellContainer.style.height = \"inherit\";\n    }\n  }\n\n  @Listen(\"icPageChange\")\n  handlePageChange({ detail, target }: CustomEvent<{ value: number }>): void {\n    if ((target as HTMLIcPaginationBarElement).parentElement !== this.el) {\n      this.fromRow = (detail.value - 1) * this.rowsPerPage;\n      this.toRow = this.fromRow + this.rowsPerPage;\n      const tableRowsContainer = this.el.shadowRoot.querySelector(\n        \".table-row-container\"\n      );\n      if (this.previousRowsPerPage === this.rowsPerPage) {\n        tableRowsContainer.scrollTop = 0;\n      } else if (this.previousRowsPerPage < this.rowsPerPage) {\n        tableRowsContainer.scrollTop = this.scrollOffset;\n        this.previousRowsPerPage = this.rowsPerPage;\n      } else {\n        this.previousRowsPerPage = this.rowsPerPage;\n      }\n    }\n\n    if (!this.initialLoad && this.previousPaginationPage !== detail.value) {\n      // This is to prevent icPageChange from triggering truncation on first load\n      this.icPageChangeEvent = true;\n    }\n\n    this.previousPaginationPage = detail.value;\n    this.initialLoad = false;\n  }\n\n  @Listen(\"icItemsPerPageChange\")\n  handleItemsPerPageChange({\n    detail,\n    target,\n  }: CustomEvent<{ value: number }>): void {\n    if ((target as HTMLIcPaginationBarElement).parentElement !== this.el) {\n      this.previousRowsPerPage = this.rowsPerPage;\n      this.rowsPerPage = detail.value;\n    }\n\n    this.itemsPerPageChange = true;\n  }\n\n  @Listen(\"icTableDensityUpdate\")\n  handleDensityChange(ev: CustomEvent<IcDensityUpdateEventDetail>): void {\n    this.density = ev.detail.value;\n  }\n\n  @Listen(\"click\", { target: \"window\" })\n  clickListener(ev: MouseEvent): void {\n    if (ev.target !== this.el) this.selectedRow = undefined;\n  }\n\n  @Watch(\"loading\")\n  loadingHandler(newValue: boolean): void {\n    if (newValue) this.startLoadingTimer();\n\n    if (this.loading) {\n      setTimeout(() => {\n        this.showLoadingIndicator();\n      }, 500);\n    }\n  }\n\n  @Watch(\"truncationPattern\")\n  truncationPatternHandler(newValue: IcDataTableTruncationTypes): void {\n    if (newValue === this.SHOW_HIDE_STRING) {\n      this.updateTruncationTooltip(true);\n\n      // Not using debounceDataTruncation here due to resizeObserver not being triggered\n      this.getTypographyElements().forEach(\n        (typographyEl: HTMLIcTypographyElement) => {\n          const cellContainer = this.getCellContainer(typographyEl);\n          const tooltip: HTMLIcTooltipElement = this.getTooltip(typographyEl);\n\n          this.truncate(typographyEl, cellContainer, tooltip);\n        }\n      );\n    }\n\n    if (newValue === this.TOOLTIP_STRING) {\n      // ResizeObserver is trigger here due to the see more/see less links being removed.\n      // The resizeObserver will also apply the tooltip where relevant\n      this.resetShowHideTruncation();\n    }\n  }\n\n  @Watch(\"data\")\n  async dataHandler(newData: { [key: string]: any }[]) {\n    this.loadingOptions = {\n      ...this.loadingOptions,\n      showBackground: newData?.length > 0,\n    };\n    if (this.loading) {\n      !this.hasLoadedForOneSecond\n        ? setTimeout(\n            () => (this.loading = false),\n            this.minimumLoadingDisplayDuration -\n              (Date.now() - this.timerStarted)\n          )\n        : (this.loading = false);\n    }\n    if (this.updating) this.updating = false;\n\n    this.dataUpdated = true;\n  }\n\n  @Watch(\"density\")\n  async densityHandler() {\n    this.densityUpdate = true;\n  }\n\n  private removeTextWrap = (): void => {\n    this.getTypographyElements().forEach(\n      (typographyEl: HTMLIcTypographyElement) => {\n        const tableCell = typographyEl.closest(\"td\");\n        if (tableCell.classList.contains(this.TEXT_WRAP_STRING)) {\n          tableCell.classList.remove(this.TEXT_WRAP_STRING);\n        }\n      }\n    );\n  };\n\n  private getCellContainer = (\n    typographyEl: HTMLIcTypographyElement\n  ): HTMLElement => {\n    return typographyEl.closest(\".cell-container\");\n  };\n\n  private deleteTextWrapDataKey = (\n    array: IcDataTableColumnObject[] | object[]\n  ) =>\n    Array.isArray(array) &&\n    array.forEach((val) => val.textWrap && delete val.textWrap);\n\n  private resetShowHideTruncation(typographyEl?: HTMLIcTypographyElement) {\n    if (typographyEl) {\n      const truncWrapper = this.getTruncWrapper(typographyEl);\n      const cellContainer = this.getCellContainer(typographyEl);\n\n      if (\n        truncWrapper?.scrollHeight > cellContainer?.clientHeight &&\n        !isEmptyString(typographyEl.getAttribute(\"max-lines\")) &&\n        Math.floor(cellContainer?.clientHeight / this.DEFAULT_LINE_HEIGHT) !==\n          +typographyEl.getAttribute(\"max-lines\")\n      ) {\n        typographyEl.checkMaxLines(truncWrapper.scrollHeight);\n        typographyEl.setAttribute(\n          \"max-lines\",\n          `${Math.floor(\n            cellContainer?.clientHeight / this.DEFAULT_LINE_HEIGHT\n          )}`\n        );\n        typographyEl.setShowHideExpanded(false);\n\n        cellContainer.style.height = null;\n      } else {\n        typographyEl.resetTruncation().then(() => {\n          cellContainer.style.setProperty(\n            \"height\",\n            cellContainer.getAttribute(this.DATA_ROW_HEIGHT_STRING)\n          );\n        });\n      }\n    } else {\n      this.getTypographyElements().forEach((typographyEl) => {\n        const cellContainer = this.getCellContainer(typographyEl);\n\n        typographyEl.resetTruncation().then(() => {\n          cellContainer.style.setProperty(\n            \"height\",\n            cellContainer.getAttribute(this.DATA_ROW_HEIGHT_STRING)\n          );\n        });\n      });\n    }\n  }\n\n  @Watch(\"globalRowHeight\")\n  @Watch(\"variableRowHeight\")\n  rowHeightChangeHandler(newValue: number, oldValue: number): void {\n    if (+newValue !== +oldValue) {\n      this.deleteTextWrapDataKey(this.data);\n      this.deleteTextWrapDataKey(this.columns);\n      this.removeTextWrap();\n\n      this.icRowHeightChange.emit();\n\n      this.rowHeightSet = true;\n    }\n  }\n\n  /**\n   * Resets the `globalRowHeight` prop to number or auto and sets the `variableRowHeight` prop to `null`.\n   */\n  @Method()\n  async resetRowHeights(rowHeight?: number | \"auto\"): Promise<void> {\n    this.globalRowHeight = rowHeight || \"auto\";\n    this.variableRowHeight = null;\n  }\n\n  private showLoadingIndicator() {\n    this.loadingIndicator.classList.add(\"show\");\n  }\n\n  private startLoadingTimer = (): void => {\n    this.hasLoadedForOneSecond = false;\n    this.timerStarted = Date.now();\n    setTimeout(() => {\n      this.hasLoadedForOneSecond = true;\n      this.timerStarted = null;\n    }, this.minimumLoadingDisplayDuration);\n  };\n\n  private isObject = (value: any) => typeof value === \"object\";\n\n  private notDefaultDensity = () => this.density !== \"default\";\n\n  private getCellContent = (\n    cell: any,\n    dataType: IcDataTableColumnDataTypes\n  ): any => {\n    switch (dataType) {\n      case \"element\":\n        return undefined;\n      case \"date\":\n        return (\n          cell instanceof Date ? cell : new Date(cell)\n        ).toLocaleDateString();\n      default:\n        return cell;\n    }\n  };\n\n  private getCellAlignment = (\n    cell: any,\n    alignment: \"horizontal\" | \"vertical\"\n  ) => {\n    if (this.isObject(cell) && Object.keys(cell).includes(\"cellAlignment\")) {\n      return this.getObjectValue(\n        this.getObjectValue(cell, \"cellAlignment\"),\n        alignment\n      );\n    }\n  };\n\n  private getCellOptions = (cell: any, key: string) => {\n    if (!(this.isObject(cell) && Object.keys(cell).includes(key))) return;\n\n    return this.getObjectValue(cell, key);\n  };\n\n  private createUpdatingIndicator = () => {\n    const { appearance, description, max, min, progress } =\n      this.updatingOptions || {};\n    return (\n      <th colSpan={this.columns.length} class=\"updating-state\">\n        <ic-loading-indicator\n          appearance={appearance}\n          description={description || \"Updating table data\"}\n          fullWidth={true}\n          max={max}\n          min={min}\n          progress={progress}\n          type=\"linear\"\n          size=\"small\"\n        ></ic-loading-indicator>\n      </th>\n    );\n  };\n\n  private setRowHeight = (height: number) => {\n    return pxToRem(\n      `${\n        height * this.DENSITY_HEIGHT_MULTIPLIER[this.density] -\n        this.DENSITY_PADDING_HEIGHT_DIFF[this.density]\n      }px`\n    );\n  };\n\n  private setTruncationClass = () => {\n    if (this.truncationPattern) {\n      return { [`truncation-${this.truncationPattern}`]: true };\n    }\n\n    return {};\n  };\n\n  private createCells = (row: object, rowIndex: number) => {\n    const rowValues = Object.values(row);\n    const rowKeys = Object.keys(row);\n    const index = rowIndex;\n\n    const rowOptions = this.getRowOptions(rowKeys, rowValues);\n    let rowAlignment: string;\n    let rowEmphasis: string;\n\n    const headerIndex = rowKeys.indexOf(\"header\");\n    if (headerIndex > -1) {\n      rowAlignment = this.getObjectValue(\n        rowValues[headerIndex],\n        \"rowAlignment\"\n      );\n      rowEmphasis = this.getObjectValue(rowValues[headerIndex], \"emphasis\");\n    }\n\n    const variableRowHeightVal = this.variableRowHeight?.({\n      ...row,\n      index,\n    });\n    const currentRowHeight = variableRowHeightVal\n      ? variableRowHeightVal !== \"auto\" && variableRowHeightVal\n      : this.globalRowHeight !== \"auto\" && this.globalRowHeight;\n\n    return rowValues.map((cell, index) => {\n      const columnProps = this.columns[index];\n      const cellSlotName = `${columnProps?.key}-${rowIndex}`;\n      const hasIcon = this.isObject(cell) && Object.keys(cell).includes(\"icon\");\n      const cellValue = (key: string) => this.getObjectValue(cell, key);\n\n      if (rowKeys[index] === \"header\") {\n        return (\n          <th\n            scope=\"row\"\n            colSpan={cellValue(\"colspan\")}\n            class={{\n              [\"row-header\"]: true,\n              [`row-header-alignment-${cellValue(\"cellAlignment\")}`]:\n                !!cellValue(\"cellAlignment\"),\n              [\"row-header-sticky\"]: this.stickyRowHeaders,\n            }}\n          >\n            {cellValue(\"title\")}\n          </th>\n        );\n      }\n\n      if (rowKeys[index] !== \"rowOptions\") {\n        return (\n          <td\n            class={{\n              [\"table-cell\"]: true,\n              [`table-density-${this.density}`]: this.notDefaultDensity(),\n            }}\n          >\n            <div\n              innerHTML={\n                columnProps?.dataType === \"element\" &&\n                !isSlotUsed(this.el, cellSlotName)\n                  ? (cell as string)\n                  : null\n              }\n              class={{\n                \"cell-container\": columnProps?.dataType !== \"element\",\n                [`cell-alignment-${\n                  columnProps?.columnAlignment?.vertical ||\n                  rowOptions?.rowAlignment?.vertical ||\n                  rowAlignment ||\n                  this.getCellAlignment(cell, \"vertical\")\n                }`]:\n                  !!columnProps?.columnAlignment?.vertical ||\n                  !!rowOptions?.rowAlignment?.vertical ||\n                  !!rowAlignment ||\n                  !!this.getCellAlignment(cell, \"vertical\"),\n                [`cell-alignment-${\n                  columnProps?.columnAlignment?.horizontal ||\n                  rowOptions?.rowAlignment?.horizontal ||\n                  this.getCellAlignment(cell, \"horizontal\")\n                }`]:\n                  !!columnProps?.columnAlignment?.horizontal ||\n                  !!rowOptions?.rowAlignment?.horizontal ||\n                  !!this.getCellAlignment(cell, \"horizontal\"),\n                [`data-type-${columnProps?.dataType}`]: true,\n                [this.TEXT_WRAP_STRING]:\n                  columnProps?.textWrap ||\n                  rowOptions?.textWrap ||\n                  !!this.getCellOptions(cell, \"textWrap\"),\n                [\"cell-icon\"]: hasIcon || !!columnProps?.icon?.icon,\n                ...this.setTruncationClass(),\n              }}\n              style={{\n                height:\n                  (this.truncationPattern || currentRowHeight) &&\n                  !columnProps.textWrap &&\n                  !rowOptions.textWrap &&\n                  !this.getCellOptions(cell, \"textWrap\") &&\n                  columnProps?.dataType !== \"element\"\n                    ? this.setRowHeight(currentRowHeight)\n                    : null,\n              }}\n              data-row-height={\n                this.truncationPattern || currentRowHeight\n                  ? this.setRowHeight(currentRowHeight)\n                  : null\n              }\n            >\n              {isSlotUsed(this.el, cellSlotName) ? (\n                <slot name={cellSlotName} />\n              ) : (\n                <Fragment>\n                  {isSlotUsed(this.el, `${cellSlotName}-icon`) ? (\n                    <slot name={`${cellSlotName}-icon`} />\n                  ) : (\n                    (hasIcon || columnProps?.icon?.onAllCells) && (\n                      <span\n                        class=\"icon\"\n                        innerHTML={cellValue(\"icon\") || columnProps?.icon.icon}\n                      ></span>\n                    )\n                  )}\n                  {columnProps?.dataType !== \"element\" &&\n                    !isSlotUsed(this.el, cellSlotName) && (\n                      <ic-typography\n                        variant=\"body\"\n                        class={{\n                          [`cell-emphasis-${\n                            (this.isObject(cell) && cellValue(\"emphasis\")) ||\n                            columnProps?.emphasis ||\n                            rowEmphasis\n                          }`]:\n                            (this.isObject(cell) && !!cellValue(\"emphasis\")) ||\n                            !!columnProps?.emphasis ||\n                            !!rowEmphasis,\n                          [`text-${this.density}`]: this.notDefaultDensity(),\n                        }}\n                      >\n                        {this.isObject(cell) &&\n                        columnProps?.dataType !== \"date\" ? (\n                          Object.keys(cell).includes(\"href\") ? (\n                            <ic-link href={cellValue(\"href\")}>\n                              {cellValue(\"data\")}\n                            </ic-link>\n                          ) : (\n                            cellValue(\"data\")\n                          )\n                        ) : (\n                          this.getCellContent(cell, columnProps?.dataType)\n                        )}\n                      </ic-typography>\n                    )}\n                </Fragment>\n              )}\n            </div>\n          </td>\n        );\n      }\n    });\n  };\n\n  private createColumnHeaders = () => {\n    return this.columns.map(({ cellAlignment, colspan, icon, key, title }) => (\n      <th\n        scope=\"col\"\n        class={{\n          [\"column-header\"]: true,\n          [`table-density-${this.density}`]: this.notDefaultDensity(),\n          [\"updating-state-headers\"]: this.updating && !this.loading,\n        }}\n        colSpan={colspan}\n      >\n        <div\n          class={{\n            \"column-header-inner-container\": true,\n            [`column-header-alignment-${cellAlignment}`]: !!cellAlignment,\n          }}\n        >\n          {isSlotUsed(this.el, `${key}-column-icon`) ? (\n            <slot name={`${key}-column-icon`} />\n          ) : (\n            icon &&\n            !icon.hideOnHeader && (\n              <span class=\"icon\" innerHTML={icon.icon}></span>\n            )\n          )}\n          <ic-typography\n            variant=\"body\"\n            class={{\n              [\"column-header-text\"]: true,\n              [`text-${this.density}`]: this.notDefaultDensity(),\n            }}\n          >\n            {title}\n          </ic-typography>\n          {this.sortable && (\n            <ic-button\n              variant=\"icon\"\n              id={`sort-button-${key}`}\n              aria-label={this.getSortButtonLabel(key)}\n              // eslint-disable-next-line react/jsx-no-bind\n              onClick={() => this.sortRows(key)}\n              innerHTML={\n                this.SORT_ICONS[\n                  this.sortedColumn === key\n                    ? this.sortedColumnOrder\n                    : \"unsorted\"\n                ]\n              }\n              class={{\n                [\"sort-button\"]: true,\n                [\"sort-button-unsorted\"]:\n                  this.sortedColumn !== key ||\n                  this.sortedColumnOrder === \"unsorted\",\n              }}\n            ></ic-button>\n          )}\n        </div>\n      </th>\n    ));\n  };\n\n  private onRowClick = (row: object) => {\n    this.selectedRow =\n      this.selectedRow !== row && !this.loading && !this.updating && row;\n  };\n\n  private createRows = () => {\n    const data = this.showPagination\n      ? this.data.slice(this.fromRow, this.toRow)\n      : this.data.slice();\n\n    /**\n     * Ensures that createCells has a value in data to map over to actually render the slot.\n     * Removes the need for the user to add it multiple times.\n     */\n    this.columns.forEach(({ key }) => {\n      data.forEach((row, rowIndex) => {\n        const cellSlotName = `${key}-${rowIndex}`;\n        if (isSlotUsed(this.el, cellSlotName)) {\n          row[key] = getSlotContent(this.el, cellSlotName);\n        }\n      });\n    });\n\n    return data\n      .sort(!this.sortable ? undefined : this.getSortFunction())\n      .map((row, index) => {\n        return (\n          <tr\n            // eslint-disable-next-line react/jsx-no-bind\n            onClick={() => this.onRowClick(row)}\n            class={{\n              [\"table-row\"]: true,\n              [\"table-row-selected\"]: this.selectedRow === row,\n            }}\n          >\n            {this.createCells(row, index)}\n          </tr>\n        );\n      });\n  };\n\n  private getObjectValue = (cell: object, key: string) => {\n    return Object.values(cell)[Object.keys(cell).indexOf(key)];\n  };\n\n  private getSortButtonLabel = (key: string) => {\n    let label = \"\";\n    const getNextSortOption = (option: IcDataTableSortOrderOptions) => {\n      const sortOrders = this.sortOptions.sortOrders;\n      return sortOrders[(sortOrders.indexOf(option) + 1) % sortOrders.length];\n    };\n\n    if (this.sortedColumn === key) {\n      const sortOption = getNextSortOption(this.sortedColumnOrder);\n      label = sortOption !== \"unsorted\" ? `Sort ${sortOption}` : \"Remove sort\";\n    } else {\n      label = `Sort ${getNextSortOption(\"unsorted\")}`;\n    }\n\n    return label;\n  };\n\n  private getComparison = (targetRow: any, comparisonRow: any): number => {\n    const targetRowValue = targetRow[this.sortedColumn];\n    const comparisonRowValue = comparisonRow[this.sortedColumn];\n    return this.columns.find((col) => col.key === this.sortedColumn)\n      .dataType === \"date\"\n      ? new Date(targetRowValue).valueOf() -\n          new Date(comparisonRowValue).valueOf()\n      : String(\n          this.isObject(targetRowValue)\n            ? Object.values(targetRowValue)[0]\n            : targetRowValue\n        ).localeCompare(\n          String(\n            this.isObject(comparisonRowValue)\n              ? Object.values(comparisonRowValue)[0]\n              : comparisonRowValue\n          ),\n          undefined,\n          { numeric: true, sensitivity: \"base\" }\n        );\n  };\n\n  private getSortFunction = () => {\n    switch (this.sortedColumnOrder) {\n      case \"ascending\":\n        return (a: any, b: any) => this.getComparison(a, b);\n      case \"descending\":\n        return (a: any, b: any) => this.getComparison(b, a);\n      default:\n        return undefined;\n    }\n  };\n\n  private sortRows = (column: string) => {\n    const sortButton = this.el.shadowRoot.querySelector(\n      `#sort-button-${column}`\n    ) as HTMLIcButtonElement;\n\n    const sortOrders = this.sortOptions.sortOrders;\n\n    if (column !== this.sortedColumn) {\n      if (this.sortedColumn) {\n        const previousSortedButton = this.el.shadowRoot.querySelector(\n          `#sort-button-${this.sortedColumn}`\n        ) as HTMLIcButtonElement;\n        previousSortedButton.setAttribute(\n          \"aria-label\",\n          this.getSortButtonLabel(column)\n        ); // Passing through unsorted column returns correct label for newly unsorted column\n      }\n      this.sortedColumn = column;\n      this.sortedColumnOrder = \"unsorted\";\n    }\n\n    let nextSortOrderIndex = sortOrders.indexOf(this.sortedColumnOrder) + 1;\n\n    if (nextSortOrderIndex > sortOrders.length - 1) {\n      nextSortOrderIndex = 0;\n    }\n\n    this.sortedColumnOrder = sortOrders[nextSortOrderIndex];\n\n    sortButton.setAttribute(\"aria-label\", this.getSortButtonLabel(column));\n\n    this.tableSorted = true;\n\n    this.icSortChange.emit({\n      columnName: column,\n      sorted: this.sortedColumnOrder,\n    });\n  };\n\n  private getTypographyElements = (): HTMLIcTypographyElement[] => {\n    return Array.from(\n      this.el.shadowRoot.querySelectorAll(\n        \"ic-typography:not(.column-header-text)\"\n      )\n    );\n  };\n\n  private getTooltip = (\n    typographyEl: HTMLIcTypographyElement\n  ): HTMLIcTooltipElement => {\n    return typographyEl.closest(this.TOOLTIP);\n  };\n\n  private updateTruncationTooltip = (removeTooltipOnly: boolean = false) => {\n    this.getTypographyElements().forEach(\n      (typographyEl: HTMLIcTypographyElement) => {\n        const tooltip = this.getTooltip(typographyEl);\n        const cellContainer = this.getCellContainer(typographyEl);\n\n        if (typographyEl.closest(this.TEXT_WRAP_CLASS)) {\n          this.removeTooltip(cellContainer, typographyEl, tooltip);\n          typographyEl.setAttribute(\"style\", `--ic-line-clamp: 0`);\n          return;\n        }\n\n        this.regenerateTooltip(\n          cellContainer,\n          typographyEl,\n          tooltip,\n          removeTooltipOnly\n        );\n      }\n    );\n  };\n\n  private updateScrollOffset = () => {\n    this.scrollOffset = this.el.shadowRoot.querySelector(\n      \".table-row-container\"\n    ).scrollTop;\n  };\n\n  private getRowOptions(rowKeys: string[], rowValues: any[]) {\n    const rowOptionsIndex = rowKeys.indexOf(\"rowOptions\");\n    return rowOptionsIndex > -1 && rowValues[rowOptionsIndex];\n  }\n\n  private regenerateTooltip(\n    cellContainer: HTMLElement,\n    typographyEl: HTMLIcTypographyElement,\n    tooltip: HTMLIcTooltipElement,\n    removeTooltipOnly?: boolean\n  ) {\n    // When sorting the table, instead of regenerating the tooltip,\n    // the tooltip details are updated\n    if (tooltip) {\n      if (this.tableSorted) {\n        tooltip.setAttribute(\"target\", typographyEl.id);\n        tooltip.setAttribute(\"label\", typographyEl.textContent);\n      } else {\n        this.removeTooltip(cellContainer, typographyEl, tooltip);\n      }\n      if (removeTooltipOnly) {\n        return;\n      }\n    }\n\n    // This add line clamp to data only when\n    // the data object has been updated\n    if (!typographyEl.getAttribute(\"style\") && this.dataUpdated) {\n      this.addLineClampCSS(typographyEl, cellContainer);\n    }\n\n    // Adding the tableSorted boolean prevents the tooltip\n    // being regenerated and flashing\n    if (\n      typographyEl?.scrollHeight > cellContainer?.clientHeight &&\n      !this.tableSorted\n    ) {\n      if (!typographyEl.getAttribute(\"style\")) {\n        this.addLineClampCSS(typographyEl, cellContainer);\n      }\n\n      this.createTruncationTooltip(typographyEl, cellContainer);\n    }\n  }\n\n  private removeTooltip(\n    cellContainer: HTMLElement,\n    typographyEl: HTMLIcTypographyElement,\n    tooltip: HTMLIcTooltipElement\n  ) {\n    cellContainer.appendChild(typographyEl);\n    if (tooltip) {\n      tooltip.remove();\n    }\n  }\n\n  private addLineClampCSS(\n    typographyEl: HTMLIcTypographyElement,\n    cellContainer: HTMLElement\n  ) {\n    typographyEl.setAttribute(\n      \"style\",\n      `--ic-line-clamp: ${this.getLines(cellContainer?.clientHeight)}`\n    );\n  }\n\n  private createTruncationTooltip(\n    typographyEl: HTMLIcTypographyElement,\n    cellContainer: HTMLElement\n  ) {\n    const tooltipEl = document.createElement(\"ic-tooltip\");\n    tooltipEl.setAttribute(\"target\", typographyEl.id);\n    tooltipEl.setAttribute(\"label\", typographyEl.textContent);\n    tooltipEl.classList.add(\"ic-tooltip-overflow\");\n    tooltipEl.setExternalPopperProps({\n      // This might need reverting back to absolute if the tooltip doesn't dynamically position itself correctly\n      strategy: \"fixed\",\n    });\n    cellContainer.appendChild(tooltipEl);\n    tooltipEl.appendChild(typographyEl);\n  }\n\n  render() {\n    const {\n      caption,\n      createColumnHeaders,\n      createRows,\n      createUpdatingIndicator,\n      data,\n      hideColumnHeaders,\n      loading,\n      loadingOptions,\n      paginationBarOptions,\n      scrollable,\n      scrollOffset,\n      showPagination,\n      sortable,\n      sortedColumnOrder,\n      sortedColumn,\n      stickyColumnHeaders,\n      updateScrollOffset,\n      updating,\n    } = this;\n\n    return (\n      <div class=\"table-container\">\n        {isSlotUsed(this.el, \"title-bar\") && <slot name=\"title-bar\" />}\n        <div\n          class={{\n            [\"table-row-container\"]: true,\n            scrollable,\n          }}\n          tabIndex={scrollable ? 0 : null}\n          onScroll={updateScrollOffset}\n        >\n          {isSlotUsed(this.el, \"title-bar\") && <slot name=\"title-bar\" />}\n          <table>\n            <caption class=\"table-caption\">{caption}</caption>\n            {!hideColumnHeaders && (\n              <thead\n                class={{\n                  [\"column-header-sticky\"]: stickyColumnHeaders,\n                  [\"column-header-overlay\"]:\n                    stickyColumnHeaders && scrollOffset !== 0,\n                }}\n              >\n                <tr>{createColumnHeaders()}</tr>\n              </thead>\n            )}\n            {updating &&\n              !loading &&\n              (hideColumnHeaders ? (\n                <thead>{createUpdatingIndicator()}</thead>\n              ) : (\n                createUpdatingIndicator()\n              ))}\n            {data?.length > 0 && !loading && <tbody>{createRows()}</tbody>}\n          </table>\n          {!data?.length &&\n            !loading &&\n            (isSlotUsed(this.el, \"empty-state\") ? (\n              <slot name=\"empty-state\" />\n            ) : (\n              <ic-empty-state\n                aligned=\"center\"\n                heading=\"No Data\"\n                class=\"loading-empty\"\n              ></ic-empty-state>\n            ))}\n        </div>\n        {loading && (\n          <ic-loading-indicator\n            appearance={loadingOptions?.appearance}\n            class={{\n              \"loading-empty\": loading,\n              loading: true,\n              \"show-background\": loadingOptions.showBackground,\n            }}\n            description={loadingOptions.description || \"Loading table data\"}\n            label={loadingOptions.label || \"Loading...\"}\n            labelDuration={loadingOptions?.labelDuration}\n            max={loadingOptions?.max}\n            min={loadingOptions?.min}\n            progress={loadingOptions?.progress}\n            ref={(el: HTMLIcLoadingIndicatorElement) =>\n              (this.loadingIndicator = el)\n            }\n          ></ic-loading-indicator>\n        )}\n        {(showPagination || isSlotUsed(this.el, \"pagination-bar\")) && (\n          <div class=\"pagination-container\">\n            {isSlotUsed(this.el, \"pagination-bar\") ? (\n              <slot name=\"pagination-bar\" />\n            ) : (\n              <ic-pagination-bar\n                totalItems={data.length}\n                type={paginationBarOptions.type}\n                rangeLabelType={paginationBarOptions.rangeLabelType}\n                showItemsPerPageControl={\n                  paginationBarOptions.showItemsPerPageControl\n                }\n                showGoToPageControl={paginationBarOptions.showGoToPageControl}\n                itemsPerPageOptions={paginationBarOptions.itemsPerPageOptions}\n                alignment={paginationBarOptions.alignment}\n                appearance={paginationBarOptions.appearance}\n                itemLabel={paginationBarOptions.itemLabel}\n                pageLabel={paginationBarOptions.pageLabel}\n                hideRangeLabel={paginationBarOptions.hideRangeLabel}\n              ></ic-pagination-bar>\n            )}\n          </div>\n        )}\n        {sortable && (\n          <div class=\"screen-reader-sort-text\" aria-live=\"polite\">\n            {sortedColumnOrder !== \"unsorted\" && sortedColumn\n              ? `${sortedColumn} sorted ${sortedColumnOrder}`\n              : \"table unsorted\"}\n          </div>\n        )}\n      </div>\n    );\n  }\n}\n"],"mappings":"4oBAAA,MAAMA,EAAiB,quK,MCkDVC,EAAS,M,yHACZC,KAAAC,0BAA4B,CAClCC,MAAO,GACPC,QAAS,EACTC,SAAU,KAGJJ,KAAAK,4BAA8B,CACpCH,MAAO,EACPC,QAAS,GACTC,SAAU,IAGJJ,KAAAM,WAAa,CACnBC,SAAUC,EACVC,UAAWC,EACXC,WAAYC,GAGNZ,KAAAa,sBAAiC,KAGjCb,KAAAc,eAAiC,KACjCd,KAAAe,iBAAmB,YACnBf,KAAAgB,oBAAsB,GAAGhB,KAAKe,wBAC9Bf,KAAAiB,eAAiB,UACjBjB,KAAAkB,QAAU,MAAMlB,KAAKiB,iBACrBjB,KAAAmB,iBAAmB,YACnBnB,KAAAoB,gBAAkB,IAAIpB,KAAKmB,mBAC3BnB,KAAAqB,YAAc,MAEdrB,KAAAsB,aAAe,MACftB,KAAAuB,YAAuB,MACvBvB,KAAAwB,kBAA6B,MAC7BxB,KAAAyB,mBAA8B,MAC9BzB,KAAA0B,uBAAyB,kBAEzB1B,KAAA2B,oBAAsB,GACtB3B,KAAA4B,cAAyB,MAmXzB5B,KAAA6B,mBAAsBC,IAC5B,MAAMC,EAAWC,SACfC,iBAAiBC,SAASC,iBAAiBJ,UAG7C,GAAID,EAAc,CAChB,MAAMM,EAAgBpC,KAAKqC,iBAAiBP,GAE5C,MAAMQ,EACJP,EACAQ,WAAWH,EAAcI,aAAaxC,KAAK0B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,IAAK4I,IAAc,MAAdA,SAAc,SAAdA,EAAgB5I,IACrBC,SAAU2I,IAAc,MAAdA,SAAc,SAAdA,EAAgB3I,SAC1BuM,IAAM7J,GACH1J,KAAKwS,iBAAmB9I,KAI7BsC,GAAkBvC,EAAWzJ,KAAK0J,GAAI,oBACtCxC,EAAA,OAAKI,MAAM,wBACRmC,EAAWzJ,KAAK0J,GAAI,kBACnBxC,EAAA,QAAMqD,KAAK,mBAEXrD,EAAA,qBACEsM,WAAYzH,EAAK1E,OACjBG,KAAMiI,EAAqBjI,KAC3BqH,eAAgBY,EAAqBZ,eACrCC,wBACEW,EAAqBX,wBAEvBC,oBAAqBU,EAAqBV,oBAC1CH,oBAAqBa,EAAqBb,oBAC1CxI,UAAWqJ,EAAqBrJ,UAChCQ,WAAY6I,EAAqB7I,WACjCoI,UAAWS,EAAqBT,UAChCC,UAAWQ,EAAqBR,UAChCC,eAAgBO,EAAqBP,kBAK5C7D,GACCnE,EAAA,OAAKI,MAAM,0BAAyB,YAAW,UAC5CqE,IAAsB,YAAcD,EACjC,GAAGA,YAAuBC,IAC1B,kB"}
         
     | 
| 
         @@ -0,0 +1,2 @@ 
     | 
|
| 
      
 1 
     | 
    
         
            +
            import{r as t,c as i,h as e,H as s,g as a}from"./p-8455d1bb.js";import{c as o}from"./p-e081702e.js";import{i as n,V as r,a as c,K as d,d as l}from"./p-8128572e.js";import{I as h}from"./p-fd186591.js";const m='/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */html{line-height:1.15;-webkit-text-size-adjust:100%;}body{margin:0}main{display:block}h1{font-size:2em;margin:0.67em 0}hr{box-sizing:content-box;height:0;overflow:visible;}pre{font-family:monospace, monospace;font-size:1em;}a{background-color:transparent}abbr[title]{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted;}b,strong{font-weight:bolder}code,kbd,samp{font-family:monospace, monospace;font-size:1em;}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-0.25em}sup{top:-0.5em}img{border-style:none}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0;}button,input{overflow:visible}button,select{text-transform:none}button,[type="button"],[type="reset"],[type="submit"]{-webkit-appearance:button}button::-moz-focus-inner,[type="button"]::-moz-focus-inner,[type="reset"]::-moz-focus-inner,[type="submit"]::-moz-focus-inner{border-style:none;padding:0}button:-moz-focusring,[type="button"]:-moz-focusring,[type="reset"]:-moz-focusring,[type="submit"]:-moz-focusring{outline:1px dotted ButtonText}fieldset{padding:0.35em 0.75em 0.625em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal;}progress{vertical-align:baseline}textarea{overflow:auto}[type="checkbox"],[type="radio"]{box-sizing:border-box;padding:0;}[type="number"]::-webkit-inner-spin-button,[type="number"]::-webkit-outer-spin-button{height:auto}[type="search"]{-webkit-appearance:textfield;outline-offset:-2px;}[type="search"]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit;}details{display:block}summary{display:list-item}template{display:none}[hidden]{display:none}html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;font-size:100%;font-style:inherit;vertical-align:baseline}@media (prefers-reduced-motion: no-preference){:host{animation:fadein var(--ic-transition-duration-slow) ease-in-out}:host(.hidden){animation:fadeout var(--ic-transition-duration-slow) ease-in-out}}:host{--bottom-position:var(--ic-space-xl);position:fixed;bottom:var(--bottom-position);left:50%;transform:translate(-50%);z-index:var(--ic-z-index-toast)}:host(.hidden){display:none}.container{max-width:32.5rem;min-width:18rem;box-shadow:var(--ic-elevation-overlay);min-height:3.5rem;background-color:var(--ic-architectural-800);color:var(--ic-color-white-text);display:flex;align-items:center;position:relative;border-radius:var(--ic-border-radius)}.toast-icon-container{height:100%;display:flex;align-items:center}.divider{height:100%;width:var(--ic-space-xs);position:absolute;border-radius:var(--ic-space-xxxs) 0 0 var(--ic-space-xxxs)}.divider-neutral{background-color:var(--ic-status-unknown)}.divider-info{background-color:var(--ic-status-info-contrast)}.divider-warning{background-color:var(--ic-status-warning-contrast)}.divider-error{background-color:var(--ic-status-error-contrast)}.divider-success{background-color:var(--ic-status-success-contrast)}.toast-icon,::slotted(svg){height:var(--ic-space-lg);width:var(--ic-space-lg);margin-left:var(--ic-space-md)}:host([variant="neutral"]) .toast-icon svg,::slotted(svg){fill:var(--ic-status-unknown)}:host([variant="info"]) .toast-icon svg{fill:var(--ic-status-info-contrast)}:host([variant="warning"]) .toast-icon svg{fill:var(--ic-status-warning-contrast)}:host([variant="error"]) .toast-icon svg{fill:var(--ic-status-error-contrast)}:host([variant="success"]) .toast-icon svg{fill:var(--ic-status-success-contrast)}.toast-content{margin-left:var(--ic-space-xs);width:100%}.no-icon{margin-left:var(--ic-space-md)}.toast-message{padding:var(--ic-space-xs) var(--ic-space-xs) var(--ic-space-xs) 0}.toast-action-container{padding-bottom:var(--ic-space-md)}ic-button,.toast-dismiss-timer{padding:var(--ic-space-xs)}@media (max-width: 576px){:host{--bottom-position:var(--ic-space-lg);width:calc(100% - 2 * var(--ic-space-md))}}@media (min-width: 993px){:host{--bottom-position:calc(var(--ic-space-xl) + var(--ic-space-xs))}}@media (forced-colors: active){.container{border:var(--ic-hc-border)}}@keyframes fadein{from{bottom:0;opacity:0}to{bottom:var(--bottom-position);opacity:1}}@keyframes fadeout{from{bottom:var(--bottom-position);opacity:1}to{bottom:0;opacity:0}}';const u=1e3;const p=70;const b=140;const f=class{constructor(e){t(this,e);this.icDismiss=i(this,"icDismiss",7);this.interactiveElements=[];this.dismissAction=()=>{this.icDismiss.emit()};this.handleProgressChange=()=>{this.timerProgress-=u/this.autoDismissTimeout*100};this.timerProgress=100;this.visible=false;this.autoDismissTimeout=5e3;this.dismissButtonAriaLabel="dismiss";this.dismissMode="manual";this.heading=undefined;this.message=undefined;this.neutralIconAriaLabel=undefined;this.variant=undefined}dismissModeChangeHandler(t){this.isManual=t==="manual"}disconnectedCallback(){window.clearTimeout(this.dismissTimeout);window.clearInterval(this.timerRefreshInterval)}componentWillLoad(){var t,i;this.handleLongText(this.heading.length>p,((t=this.message)===null||t===void 0?void 0:t.length)>b);if(this.autoDismissTimeout<5e3)this.autoDismissTimeout=5e3;if(n(this.el,"action"))this.dismissMode="manual";this.isManual=this.dismissMode==="manual";if(n(this.el,"neutral-icon"))this.variant="neutral";if(this.variant==="neutral"){this.neutralVariantLabel=(i=this.neutralIconAriaLabel)!==null&&i!==void 0?i:r[this.variant].ariaLabel}if(this.isManual){const t=l(this.message)?`. ${this.message}`:"";this.el.setAttribute("aria-label",this.variant?this.neutralVariantLabel||r[this.variant].ariaLabel:this.heading);(this.variant||this.message)&&this.el.setAttribute("aria-description",this.variant?`${this.heading}${t}`:this.message)}}componentDidLoad(){c([{prop:this.heading,propName:"heading"}],"Toast");const t=d(this.el,"action");const i=this.el.shadowRoot.querySelector("ic-button");if(t)this.interactiveElements.push(t);if(i)this.interactiveElements.push(i)}handleDismiss(){this.visible=false;clearInterval(this.timerRefreshInterval);this.timerProgress=100}handleKeyboard(t){if(this.isManual&&this.visible){switch(t.key){case"Tab":t.preventDefault();this.findNextInteractiveElement(t.shiftKey).setFocus();break;case"Escape":!t.repeat&&this.dismissAction();t.stopImmediatePropagation();break}}}handleTimer(t){if(!this.isManual){switch(t.type){case"mouseenter":window.clearTimeout(this.dismissTimeout);window.clearInterval(this.timerRefreshInterval);this.timerProgress=100;break;case"mouseleave":this.dismissTimeout=window.setTimeout(this.dismissAction,this.autoDismissTimeout);this.timerRefreshInterval=window.setInterval(this.handleProgressChange,u);break}}}async setVisible(){if(!this.visible)this.visible=true;if(!this.isManual){this.dismissTimeout=window.setTimeout(this.dismissAction,this.autoDismissTimeout);this.timerRefreshInterval=window.setInterval(this.handleProgressChange,u);return null}else{window.setTimeout((()=>this.interactiveElements[0].setFocus()),200);return document.activeElement}}handleLongText(t,i){if(i||t){console.error(`Too many characters in toast ${t?"heading":""}${t&&i?" and ":""}${i?"message":""}. Refer to character limits specified in the prop description`)}}findNextInteractiveElement(t){const i=this.interactiveElements[0];const e=this.interactiveElements[this.interactiveElements.length-1];if(this.isActive(t?i:e))return t?e:i;let s;return this.interactiveElements.some(((t,i)=>{if(!this.isActive(t))return false;s=i;return true}))?this.interactiveElements[s+(t?-1:1)]:i}isActive(t){return t===this.el?!!this.el.shadowRoot.activeElement:document.activeElement===t}render(){const{variant:t,heading:i,message:a,visible:c,isManual:d,dismissButtonAriaLabel:l}=this;return e(s,{class:{["hidden"]:!c},role:d?"dialog":"status"},e("div",{class:"container"},t&&c&&e("div",{class:"toast-icon-container"},e("div",{class:{["divider"]:true,[`divider-${t}`]:true}}),t==="neutral"?e("slot",{name:"neutral-icon"}):e("span",{class:"toast-icon",innerHTML:r[t].icon})),e("div",{class:{["toast-content"]:true,["no-icon"]:t==="neutral"&&!n(this.el,"neutral-icon")}},e("div",{class:"toast-message"},e("ic-typography",{variant:"subtitle-large"},c&&e("h5",null,i)),a&&e("ic-typography",{variant:"body"},c&&e("p",null,a))),n(this.el,"action")&&e("div",{class:"toast-action-container"},e("slot",{name:"action"}))),!d?e("ic-loading-indicator",{class:"toast-dismiss-timer",appearance:"light",size:"icon",progress:this.timerProgress}):e("ic-button",{id:"dismiss-button",innerHTML:o,onClick:this.dismissAction,variant:"icon",appearance:h.Light,"aria-label":l})))}get el(){return a(this)}static get watchers(){return{dismissMode:["dismissModeChangeHandler"]}}};f.style=m;export{f as ic_toast};
         
     | 
| 
      
 2 
     | 
    
         
            +
            //# sourceMappingURL=p-2f7e6e38.entry.js.map
         
     | 
| 
         @@ -0,0 +1 @@ 
     | 
|
| 
      
 1 
     | 
    
         
            +
            {"version":3,"names":["icToastCss","AUTO_DISMISS_TIMER_REFRESH_RATE_MS","TOAST_HEADING_CHAR_LIMIT","TOAST_MESSAGE_CHAR_LIMIT","Toast","constructor","hostRef","this","interactiveElements","dismissAction","icDismiss","emit","handleProgressChange","timerProgress","autoDismissTimeout","visible","dismissButtonAriaLabel","dismissMode","heading","undefined","message","neutralIconAriaLabel","variant","dismissModeChangeHandler","newValue","isManual","disconnectedCallback","window","clearTimeout","dismissTimeout","clearInterval","timerRefreshInterval","componentWillLoad","_a","_b","handleLongText","length","isSlotUsed","el","neutralVariantLabel","VARIANT_ICONS","ariaLabel","toastMessage","isPropDefined","setAttribute","componentDidLoad","onComponentRequiredPropUndefined","prop","propName","actionContent","getSlot","dismissButton","shadowRoot","querySelector","push","handleDismiss","handleKeyboard","ev","key","preventDefault","findNextInteractiveElement","shiftKey","setFocus","repeat","stopImmediatePropagation","handleTimer","type","setTimeout","setInterval","setVisible","document","activeElement","headingTooLong","messageTooLong","console","error","isBackwards","firstEl","lastEl","isActive","currentIndex","some","index","targetEl","render","h","Host","class","role","name","innerHTML","icon","appearance","size","progress","id","closeIcon","onClick","IcThemeForegroundEnum","Light"],"sources":["../web-components/dist/collection/components/ic-toast/ic-toast.css?tag=ic-toast&encapsulation=shadow","../web-components/dist/collection/components/ic-toast/ic-toast.js"],"sourcesContent":["/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */\n\n/* Document\n   ========================================================================== */\n\n/**\n * 1. Correct the line height in all browsers.\n * 2. Prevent adjustments of font size after orientation changes in iOS.\n */\n\nhtml {\n  line-height: 1.15; /* 1 */\n  -webkit-text-size-adjust: 100%; /* 2 */\n}\n\n/* Sections\n     ========================================================================== */\n\n/**\n   * Remove the margin in all browsers.\n   */\n\nbody {\n  margin: 0;\n}\n\n/**\n   * Render the `main` element consistently in IE.\n   */\n\nmain {\n  display: block;\n}\n\n/**\n   * Correct the font size and margin on `h1` elements within `section` and\n   * `article` contexts in Chrome, Firefox, and Safari.\n   */\n\nh1 {\n  font-size: 2em;\n  margin: 0.67em 0;\n}\n\n/* Grouping content\n     ========================================================================== */\n\n/**\n   * 1. Add the correct box sizing in Firefox.\n   * 2. Show the overflow in Edge and IE.\n   */\n\nhr {\n  box-sizing: content-box; /* 1 */\n  height: 0; /* 1 */\n  overflow: visible; /* 2 */\n}\n\n/**\n   * 1. Correct the inheritance and scaling of font size in all browsers.\n   * 2. Correct the odd `em` font sizing in all browsers.\n   */\n\npre {\n  font-family: monospace, monospace; /* 1 */\n  font-size: 1em; /* 2 */\n}\n\n/* Text-level semantics\n     ========================================================================== */\n\n/**\n   * Remove the gray background on active links in IE 10.\n   */\n\na {\n  background-color: transparent;\n}\n\n/**\n   * 1. Remove the bottom border in Chrome 57-\n   * 2. Add the correct text decoration in Chrome, Edge, IE, Opera, and Safari.\n   */\n\nabbr[title] {\n  border-bottom: none; /* 1 */\n  text-decoration: underline; /* 2 */\n  -webkit-text-decoration: underline dotted;\n          text-decoration: underline dotted; /* 2 */\n}\n\n/**\n   * Add the correct font weight in Chrome, Edge, and Safari.\n   */\n\nb,\nstrong {\n  font-weight: bolder;\n}\n\n/**\n   * 1. Correct the inheritance and scaling of font size in all browsers.\n   * 2. Correct the odd `em` font sizing in all browsers.\n   */\n\ncode,\nkbd,\nsamp {\n  font-family: monospace, monospace; /* 1 */\n  font-size: 1em; /* 2 */\n}\n\n/**\n   * Add the correct font size in all browsers.\n   */\n\nsmall {\n  font-size: 80%;\n}\n\n/**\n   * Prevent `sub` and `sup` elements from affecting the line height in\n   * all browsers.\n   */\n\nsub,\nsup {\n  font-size: 75%;\n  line-height: 0;\n  position: relative;\n  vertical-align: baseline;\n}\n\nsub {\n  bottom: -0.25em;\n}\n\nsup {\n  top: -0.5em;\n}\n\n/* Embedded content\n     ========================================================================== */\n\n/**\n   * Remove the border on images inside links in IE 10.\n   */\n\nimg {\n  border-style: none;\n}\n\n/* Forms\n     ========================================================================== */\n\n/**\n   * 1. Change the font styles in all browsers.\n   * 2. Remove the margin in Firefox and Safari.\n   */\n\nbutton,\ninput,\noptgroup,\nselect,\ntextarea {\n  font-family: inherit; /* 1 */\n  font-size: 100%; /* 1 */\n  line-height: 1.15; /* 1 */\n  margin: 0; /* 2 */\n}\n\n/**\n   * Show the overflow in IE.\n   * 1. Show the overflow in Edge.\n   */\n\nbutton,\ninput {\n  /* 1 */\n  overflow: visible;\n}\n\n/**\n   * Remove the inheritance of text transform in Edge, Firefox, and IE.\n   * 1. Remove the inheritance of text transform in Firefox.\n   */\n\nbutton,\nselect {\n  /* 1 */\n  text-transform: none;\n}\n\n/**\n   * Correct the inability to style clickable types in iOS and Safari.\n   */\n\nbutton,\n[type=\"button\"],\n[type=\"reset\"],\n[type=\"submit\"] {\n  -webkit-appearance: button;\n}\n\n/**\n   * Remove the inner border and padding in Firefox.\n   */\n\nbutton::-moz-focus-inner,\n[type=\"button\"]::-moz-focus-inner,\n[type=\"reset\"]::-moz-focus-inner,\n[type=\"submit\"]::-moz-focus-inner {\n  border-style: none;\n  padding: 0;\n}\n\n/**\n   * Restore the focus styles unset by the previous rule.\n   */\n\nbutton:-moz-focusring,\n[type=\"button\"]:-moz-focusring,\n[type=\"reset\"]:-moz-focusring,\n[type=\"submit\"]:-moz-focusring {\n  outline: 1px dotted ButtonText;\n}\n\n/**\n   * Correct the padding in Firefox.\n   */\n\nfieldset {\n  padding: 0.35em 0.75em 0.625em;\n}\n\n/**\n   * 1. Correct the text wrapping in Edge and IE.\n   * 2. Correct the color inheritance from `fieldset` elements in IE.\n   * 3. Remove the padding so developers are not caught out when they zero out\n   *    `fieldset` elements in all browsers.\n   */\n\nlegend {\n  box-sizing: border-box; /* 1 */\n  color: inherit; /* 2 */\n  display: table; /* 1 */\n  max-width: 100%; /* 1 */\n  padding: 0; /* 3 */\n  white-space: normal; /* 1 */\n}\n\n/**\n   * Add the correct vertical alignment in Chrome, Firefox, and Opera.\n   */\n\nprogress {\n  vertical-align: baseline;\n}\n\n/**\n   * Remove the default vertical scrollbar in IE 10+.\n   */\n\ntextarea {\n  overflow: auto;\n}\n\n/**\n   * 1. Add the correct box sizing in IE 10.\n   * 2. Remove the padding in IE 10.\n   */\n\n[type=\"checkbox\"],\n[type=\"radio\"] {\n  box-sizing: border-box; /* 1 */\n  padding: 0; /* 2 */\n}\n\n/**\n   * Correct the cursor style of increment and decrement buttons in Chrome.\n   */\n\n[type=\"number\"]::-webkit-inner-spin-button,\n[type=\"number\"]::-webkit-outer-spin-button {\n  height: auto;\n}\n\n/**\n   * 1. Correct the odd appearance in Chrome and Safari.\n   * 2. Correct the outline style in Safari.\n   */\n\n[type=\"search\"] {\n  -webkit-appearance: textfield; /* 1 */\n  outline-offset: -2px; /* 2 */\n}\n\n/**\n   * Remove the inner padding in Chrome and Safari on macOS.\n   */\n\n[type=\"search\"]::-webkit-search-decoration {\n  -webkit-appearance: none;\n}\n\n/**\n   * 1. Correct the inability to style clickable types in iOS and Safari.\n   * 2. Change font properties to `inherit` in Safari.\n   */\n\n::-webkit-file-upload-button {\n  -webkit-appearance: button; /* 1 */\n  font: inherit; /* 2 */\n}\n\n/* Interactive\n     ========================================================================== */\n\n/*\n   * Add the correct display in Edge, IE 10+, and Firefox.\n   */\n\ndetails {\n  display: block;\n}\n\n/*\n   * Add the correct display in all browsers.\n   */\n\nsummary {\n  display: list-item;\n}\n\n/* Misc\n     ========================================================================== */\n\n/**\n   * Add the correct display in IE 10+.\n   */\n\ntemplate {\n  display: none;\n}\n\n/**\n   * Add the correct display in IE 10.\n   */\n\n[hidden] {\n  display: none;\n}\n\nhtml,\nbody,\ndiv,\nspan,\napplet,\nobject,\niframe,\nh1,\nh2,\nh3,\nh4,\nh5,\nh6,\np,\nblockquote,\npre,\na,\nabbr,\nacronym,\naddress,\nbig,\ncite,\ncode,\ndel,\ndfn,\nem,\nimg,\nins,\nkbd,\nq,\ns,\nsamp,\nsmall,\nstrike,\nstrong,\nsub,\nsup,\ntt,\nvar,\nb,\nu,\ni,\ncenter,\ndl,\ndt,\ndd,\nol,\nul,\nli,\nfieldset,\nform,\nlabel,\nlegend,\ntable,\ncaption,\ntbody,\ntfoot,\nthead,\ntr,\nth,\ntd,\narticle,\naside,\ncanvas,\ndetails,\nembed,\nfigure,\nfigcaption,\nfooter,\nheader,\nhgroup,\nmenu,\nnav,\noutput,\nruby,\nsection,\nsummary,\ntime,\nmark,\naudio,\nvideo {\n  margin: 0;\n  padding: 0;\n  border: 0;\n  font-size: 100%;\n  font-style: inherit;\n  vertical-align: baseline;\n}\n\n\n/**\n * @prop --ic-z-index-toast: z-index of toast\n */\n\n@media (prefers-reduced-motion: no-preference) {\n  :host {\n    animation: fadein var(--ic-transition-duration-slow) ease-in-out;\n  }\n\n  :host(.hidden) {\n    animation: fadeout var(--ic-transition-duration-slow) ease-in-out;\n  }\n}\n\n:host {\n  --bottom-position: var(--ic-space-xl);\n\n  position: fixed;\n  bottom: var(--bottom-position);\n  left: 50%;\n  transform: translate(-50%);\n  z-index: var(--ic-z-index-toast);\n}\n\n:host(.hidden) {\n  display: none;\n}\n\n.container {\n  max-width: 32.5rem;\n  min-width: 18rem;\n  box-shadow: var(--ic-elevation-overlay);\n  min-height: 3.5rem;\n  background-color: var(--ic-architectural-800);\n  color: var(--ic-color-white-text);\n  display: flex;\n  align-items: center;\n  position: relative;\n  border-radius: var(--ic-border-radius);\n}\n\n.toast-icon-container {\n  height: 100%;\n  display: flex;\n  align-items: center;\n}\n\n.divider {\n  height: 100%;\n  width: var(--ic-space-xs);\n  position: absolute;\n  border-radius: var(--ic-space-xxxs) 0 0 var(--ic-space-xxxs);\n}\n\n.divider-neutral {\n  background-color: var(--ic-status-unknown);\n}\n\n.divider-info {\n  background-color: var(--ic-status-info-contrast);\n}\n\n.divider-warning {\n  background-color: var(--ic-status-warning-contrast);\n}\n\n.divider-error {\n  background-color: var(--ic-status-error-contrast);\n}\n\n.divider-success {\n  background-color: var(--ic-status-success-contrast);\n}\n\n.toast-icon,\n::slotted(svg) {\n  height: var(--ic-space-lg);\n  width: var(--ic-space-lg);\n  margin-left: var(--ic-space-md);\n}\n\n:host([variant=\"neutral\"]) .toast-icon svg,\n::slotted(svg) {\n  fill: var(--ic-status-unknown);\n}\n\n:host([variant=\"info\"]) .toast-icon svg {\n  fill: var(--ic-status-info-contrast);\n}\n\n:host([variant=\"warning\"]) .toast-icon svg {\n  fill: var(--ic-status-warning-contrast);\n}\n\n:host([variant=\"error\"]) .toast-icon svg {\n  fill: var(--ic-status-error-contrast);\n}\n\n:host([variant=\"success\"]) .toast-icon svg {\n  fill: var(--ic-status-success-contrast);\n}\n\n.toast-content {\n  margin-left: var(--ic-space-xs);\n  width: 100%;\n}\n\n.no-icon {\n  margin-left: var(--ic-space-md);\n}\n\n.toast-message {\n  padding: var(--ic-space-xs) var(--ic-space-xs) var(--ic-space-xs) 0;\n}\n\n.toast-action-container {\n  padding-bottom: var(--ic-space-md);\n}\n\nic-button,\n.toast-dismiss-timer {\n  padding: var(--ic-space-xs);\n}\n\n@media (max-width: 576px) {\n  :host {\n    --bottom-position: var(--ic-space-lg);\n\n    width: calc(100% - 2 * var(--ic-space-md));\n  }\n}\n\n@media (min-width: 993px) {\n  :host {\n    --bottom-position: calc(var(--ic-space-xl) + var(--ic-space-xs));\n  }\n}\n\n@media (forced-colors: active) {\n  .container {\n    border: var(--ic-hc-border);\n  }\n}\n\n@keyframes fadein {\n  from {\n    bottom: 0;\n    opacity: 0;\n  }\n\n  to {\n    bottom: var(--bottom-position);\n    opacity: 1;\n  }\n}\n\n@keyframes fadeout {\n  from {\n    bottom: var(--bottom-position);\n    opacity: 1;\n  }\n\n  to {\n    bottom: 0;\n    opacity: 0;\n  }\n}\n","import { h, Host, } from \"@stencil/core\";\nimport closeIcon from \"../../assets/close-icon.svg\";\nimport { VARIANT_ICONS } from \"../../utils/constants\";\nimport { getSlot, isPropDefined, isSlotUsed, onComponentRequiredPropUndefined, } from \"../../utils/helpers\";\nimport { IcThemeForegroundEnum, } from \"../../utils/types\";\nconst AUTO_DISMISS_TIMER_REFRESH_RATE_MS = 1000;\nconst TOAST_HEADING_CHAR_LIMIT = 70;\nconst TOAST_MESSAGE_CHAR_LIMIT = 140;\n/**\n * @slot action - IcButton or IcLink is placed below header and message. If used will default toast to manual `dismiss` type.\n * @slot neutral-icon - A custom neutral icon is placed on the left side of the component. If used will default toast to `neutral` variant.\n */\nexport class Toast {\n    constructor() {\n        this.interactiveElements = [];\n        this.dismissAction = () => {\n            this.icDismiss.emit();\n        };\n        this.handleProgressChange = () => {\n            this.timerProgress -=\n                (AUTO_DISMISS_TIMER_REFRESH_RATE_MS / this.autoDismissTimeout) * 100;\n        };\n        this.timerProgress = 100;\n        this.visible = false;\n        this.autoDismissTimeout = 5000;\n        this.dismissButtonAriaLabel = \"dismiss\";\n        this.dismissMode = \"manual\";\n        this.heading = undefined;\n        this.message = undefined;\n        this.neutralIconAriaLabel = undefined;\n        this.variant = undefined;\n    }\n    dismissModeChangeHandler(newValue) {\n        this.isManual = newValue === \"manual\";\n    }\n    disconnectedCallback() {\n        window.clearTimeout(this.dismissTimeout);\n        window.clearInterval(this.timerRefreshInterval);\n    }\n    componentWillLoad() {\n        var _a, _b;\n        this.handleLongText(this.heading.length > TOAST_HEADING_CHAR_LIMIT, ((_a = this.message) === null || _a === void 0 ? void 0 : _a.length) > TOAST_MESSAGE_CHAR_LIMIT);\n        if (this.autoDismissTimeout < 5000)\n            this.autoDismissTimeout = 5000;\n        if (isSlotUsed(this.el, \"action\"))\n            this.dismissMode = \"manual\";\n        this.isManual = this.dismissMode === \"manual\";\n        if (isSlotUsed(this.el, \"neutral-icon\"))\n            this.variant = \"neutral\";\n        if (this.variant === \"neutral\") {\n            this.neutralVariantLabel =\n                (_b = this.neutralIconAriaLabel) !== null && _b !== void 0 ? _b : VARIANT_ICONS[this.variant].ariaLabel;\n        }\n        if (this.isManual) {\n            const toastMessage = isPropDefined(this.message)\n                ? `. ${this.message}`\n                : \"\";\n            this.el.setAttribute(\"aria-label\", this.variant\n                ? this.neutralVariantLabel || VARIANT_ICONS[this.variant].ariaLabel\n                : this.heading);\n            (this.variant || this.message) &&\n                this.el.setAttribute(\"aria-description\", this.variant ? `${this.heading}${toastMessage}` : this.message);\n        }\n    }\n    componentDidLoad() {\n        onComponentRequiredPropUndefined([{ prop: this.heading, propName: \"heading\" }], \"Toast\");\n        const actionContent = getSlot(this.el, \"action\");\n        const dismissButton = this.el.shadowRoot.querySelector(\"ic-button\");\n        if (actionContent)\n            this.interactiveElements.push(actionContent);\n        if (dismissButton)\n            this.interactiveElements.push(dismissButton);\n    }\n    handleDismiss() {\n        this.visible = false;\n        clearInterval(this.timerRefreshInterval);\n        this.timerProgress = 100;\n    }\n    handleKeyboard(ev) {\n        if (this.isManual && this.visible) {\n            switch (ev.key) {\n                case \"Tab\":\n                    ev.preventDefault();\n                    this.findNextInteractiveElement(ev.shiftKey).setFocus();\n                    break;\n                case \"Escape\":\n                    !ev.repeat && this.dismissAction();\n                    ev.stopImmediatePropagation();\n                    break;\n            }\n        }\n    }\n    handleTimer(ev) {\n        if (!this.isManual) {\n            switch (ev.type) {\n                case \"mouseenter\":\n                    window.clearTimeout(this.dismissTimeout);\n                    window.clearInterval(this.timerRefreshInterval);\n                    this.timerProgress = 100;\n                    break;\n                case \"mouseleave\":\n                    this.dismissTimeout = window.setTimeout(this.dismissAction, this.autoDismissTimeout);\n                    this.timerRefreshInterval = window.setInterval(this.handleProgressChange, AUTO_DISMISS_TIMER_REFRESH_RATE_MS);\n                    break;\n            }\n        }\n    }\n    /**\n     * @internal Used to display the individual toast.\n     * @returns The element that previously had focus before the toast appeared\n     */\n    async setVisible() {\n        if (!this.visible)\n            this.visible = true;\n        if (!this.isManual) {\n            this.dismissTimeout = window.setTimeout(this.dismissAction, this.autoDismissTimeout);\n            this.timerRefreshInterval = window.setInterval(this.handleProgressChange, AUTO_DISMISS_TIMER_REFRESH_RATE_MS);\n            return null;\n        }\n        else {\n            window.setTimeout(() => this.interactiveElements[0].setFocus(), 200);\n            return document.activeElement;\n        }\n    }\n    handleLongText(headingTooLong, messageTooLong) {\n        if (messageTooLong || headingTooLong) {\n            console.error(`Too many characters in toast ${headingTooLong ? \"heading\" : \"\"}${headingTooLong && messageTooLong ? \" and \" : \"\"}${messageTooLong ? \"message\" : \"\"}. Refer to character limits specified in the prop description`);\n        }\n    }\n    findNextInteractiveElement(isBackwards) {\n        const firstEl = this.interactiveElements[0];\n        const lastEl = this.interactiveElements[this.interactiveElements.length - 1];\n        if (this.isActive(isBackwards ? firstEl : lastEl))\n            return isBackwards ? lastEl : firstEl;\n        let currentIndex;\n        return this.interactiveElements.some((el, index) => {\n            if (!this.isActive(el))\n                return false;\n            currentIndex = index;\n            return true;\n        })\n            ? this.interactiveElements[currentIndex + (isBackwards ? -1 : 1)]\n            : firstEl;\n    }\n    isActive(targetEl) {\n        return targetEl === this.el\n            ? !!this.el.shadowRoot.activeElement\n            : document.activeElement === targetEl;\n    }\n    render() {\n        const { variant, heading, message, visible, isManual, dismissButtonAriaLabel, } = this;\n        return (h(Host, { class: { [\"hidden\"]: !visible }, role: isManual ? \"dialog\" : \"status\" }, h(\"div\", { class: \"container\" }, variant && visible && (h(\"div\", { class: \"toast-icon-container\" }, h(\"div\", { class: {\n                [\"divider\"]: true,\n                [`divider-${variant}`]: true,\n            } }), variant === \"neutral\" ? (h(\"slot\", { name: \"neutral-icon\" })) : (h(\"span\", { class: \"toast-icon\", innerHTML: VARIANT_ICONS[variant].icon })))), h(\"div\", { class: {\n                [\"toast-content\"]: true,\n                [\"no-icon\"]: variant === \"neutral\" && !isSlotUsed(this.el, \"neutral-icon\"),\n            } }, h(\"div\", { class: \"toast-message\" }, h(\"ic-typography\", { variant: \"subtitle-large\" }, visible && h(\"h5\", null, heading)), message && (h(\"ic-typography\", { variant: \"body\" }, visible && h(\"p\", null, message)))), isSlotUsed(this.el, \"action\") && (h(\"div\", { class: \"toast-action-container\" }, h(\"slot\", { name: \"action\" })))), !isManual ? (h(\"ic-loading-indicator\", { class: \"toast-dismiss-timer\", appearance: \"light\", size: \"icon\", progress: this.timerProgress })) : (h(\"ic-button\", { id: \"dismiss-button\", innerHTML: closeIcon, onClick: this.dismissAction, variant: \"icon\", appearance: IcThemeForegroundEnum.Light, \"aria-label\": dismissButtonAriaLabel })))));\n    }\n    static get is() { return \"ic-toast\"; }\n    static get encapsulation() { return \"shadow\"; }\n    static get originalStyleUrls() {\n        return {\n            \"$\": [\"ic-toast.css\"]\n        };\n    }\n    static get styleUrls() {\n        return {\n            \"$\": [\"ic-toast.css\"]\n        };\n    }\n    static get properties() {\n        return {\n            \"autoDismissTimeout\": {\n                \"type\": \"number\",\n                \"mutable\": true,\n                \"complexType\": {\n                    \"original\": \"number\",\n                    \"resolved\": \"number\",\n                    \"references\": {}\n                },\n                \"required\": false,\n                \"optional\": true,\n                \"docs\": {\n                    \"tags\": [],\n                    \"text\": \"If toast dismissMode is set to `automatic`, use this prop to define the time before the toast dismisses (in MILLISECONDS)\\n(NOTE: Has a minimum value of `5000ms`)\"\n                },\n                \"attribute\": \"auto-dismiss-timeout\",\n                \"reflect\": false,\n                \"defaultValue\": \"5000\"\n            },\n            \"dismissButtonAriaLabel\": {\n                \"type\": \"string\",\n                \"mutable\": false,\n                \"complexType\": {\n                    \"original\": \"string\",\n                    \"resolved\": \"string\",\n                    \"references\": {}\n                },\n                \"required\": false,\n                \"optional\": true,\n                \"docs\": {\n                    \"tags\": [],\n                    \"text\": \"If toast can be manually dismissed, this prop sets a custom aria-label for the ic-button component\"\n                },\n                \"attribute\": \"dismiss-button-aria-label\",\n                \"reflect\": false,\n                \"defaultValue\": \"\\\"dismiss\\\"\"\n            },\n            \"dismissMode\": {\n                \"type\": \"string\",\n                \"mutable\": true,\n                \"complexType\": {\n                    \"original\": \"IcActivationTypes\",\n                    \"resolved\": \"\\\"automatic\\\" | \\\"manual\\\"\",\n                    \"references\": {\n                        \"IcActivationTypes\": {\n                            \"location\": \"import\",\n                            \"path\": \"../../utils/types\",\n                            \"id\": \"src/utils/types.ts::IcActivationTypes\"\n                        }\n                    }\n                },\n                \"required\": false,\n                \"optional\": true,\n                \"docs\": {\n                    \"tags\": [],\n                    \"text\": \"How the toast will be dismissed. If manual will display a dismiss button.\"\n                },\n                \"attribute\": \"dismiss-mode\",\n                \"reflect\": false,\n                \"defaultValue\": \"\\\"manual\\\"\"\n            },\n            \"heading\": {\n                \"type\": \"string\",\n                \"mutable\": false,\n                \"complexType\": {\n                    \"original\": \"string\",\n                    \"resolved\": \"string\",\n                    \"references\": {}\n                },\n                \"required\": true,\n                \"optional\": false,\n                \"docs\": {\n                    \"tags\": [],\n                    \"text\": \"The title to display at the start of the toast. (NOTE: Should be no more than `70` characters)\"\n                },\n                \"attribute\": \"heading\",\n                \"reflect\": false\n            },\n            \"message\": {\n                \"type\": \"string\",\n                \"mutable\": false,\n                \"complexType\": {\n                    \"original\": \"string\",\n                    \"resolved\": \"string\",\n                    \"references\": {}\n                },\n                \"required\": false,\n                \"optional\": true,\n                \"docs\": {\n                    \"tags\": [],\n                    \"text\": \"The main body message of the toast. (NOTE: Should be no more than `140` characters)\"\n                },\n                \"attribute\": \"message\",\n                \"reflect\": false\n            },\n            \"neutralIconAriaLabel\": {\n                \"type\": \"string\",\n                \"mutable\": false,\n                \"complexType\": {\n                    \"original\": \"string\",\n                    \"resolved\": \"string\",\n                    \"references\": {}\n                },\n                \"required\": false,\n                \"optional\": true,\n                \"docs\": {\n                    \"tags\": [],\n                    \"text\": \"Provides a custom alt-text to be announced to screen readers, if slotting a custom neutral icon\"\n                },\n                \"attribute\": \"neutral-icon-aria-label\",\n                \"reflect\": false\n            },\n            \"variant\": {\n                \"type\": \"string\",\n                \"mutable\": true,\n                \"complexType\": {\n                    \"original\": \"IcStatusVariants\",\n                    \"resolved\": \"\\\"error\\\" | \\\"info\\\" | \\\"neutral\\\" | \\\"success\\\" | \\\"warning\\\"\",\n                    \"references\": {\n                        \"IcStatusVariants\": {\n                            \"location\": \"import\",\n                            \"path\": \"../../utils/types\",\n                            \"id\": \"src/utils/types.ts::IcStatusVariants\"\n                        }\n                    }\n                },\n                \"required\": false,\n                \"optional\": true,\n                \"docs\": {\n                    \"tags\": [],\n                    \"text\": \"The variant of the toast being rendered\"\n                },\n                \"attribute\": \"variant\",\n                \"reflect\": false\n            }\n        };\n    }\n    static get states() {\n        return {\n            \"timerProgress\": {},\n            \"visible\": {}\n        };\n    }\n    static get events() {\n        return [{\n                \"method\": \"icDismiss\",\n                \"name\": \"icDismiss\",\n                \"bubbles\": true,\n                \"cancelable\": true,\n                \"composed\": true,\n                \"docs\": {\n                    \"tags\": [],\n                    \"text\": \"Is emitted when the user dismisses the toast\"\n                },\n                \"complexType\": {\n                    \"original\": \"void\",\n                    \"resolved\": \"void\",\n                    \"references\": {}\n                }\n            }];\n    }\n    static get methods() {\n        return {\n            \"setVisible\": {\n                \"complexType\": {\n                    \"signature\": \"() => Promise<HTMLElement>\",\n                    \"parameters\": [],\n                    \"references\": {\n                        \"Promise\": {\n                            \"location\": \"global\",\n                            \"id\": \"global::Promise\"\n                        },\n                        \"HTMLElement\": {\n                            \"location\": \"global\",\n                            \"id\": \"global::HTMLElement\"\n                        }\n                    },\n                    \"return\": \"Promise<HTMLElement>\"\n                },\n                \"docs\": {\n                    \"text\": \"\",\n                    \"tags\": [{\n                            \"name\": \"internal\",\n                            \"text\": \"Used to display the individual toast.\"\n                        }, {\n                            \"name\": \"returns\",\n                            \"text\": \"The element that previously had focus before the toast appeared\"\n                        }]\n                }\n            }\n        };\n    }\n    static get elementRef() { return \"el\"; }\n    static get watchers() {\n        return [{\n                \"propName\": \"dismissMode\",\n                \"methodName\": \"dismissModeChangeHandler\"\n            }];\n    }\n    static get listeners() {\n        return [{\n                \"name\": \"icDismiss\",\n                \"method\": \"handleDismiss\",\n                \"target\": undefined,\n                \"capture\": true,\n                \"passive\": false\n            }, {\n                \"name\": \"keydown\",\n                \"method\": \"handleKeyboard\",\n                \"target\": \"document\",\n                \"capture\": false,\n                \"passive\": false\n            }, {\n                \"name\": \"mouseenter\",\n                \"method\": \"handleTimer\",\n                \"target\": undefined,\n                \"capture\": false,\n                \"passive\": true\n            }, {\n                \"name\": \"mouseleave\",\n                \"method\": \"handleTimer\",\n                \"target\": undefined,\n                \"capture\": false,\n                \"passive\": true\n            }];\n    }\n}\n//# sourceMappingURL=ic-toast.js.map\n"],"mappings":"wMAAA,MAAMA,EAAa,0tJCKnB,MAAMC,EAAqC,IAC3C,MAAMC,EAA2B,GACjC,MAAMC,EAA2B,I,MAKpBC,EAAK,MACd,WAAAC,CAAAC,G,+CACIC,KAAKC,oBAAsB,GAC3BD,KAAKE,cAAgB,KACjBF,KAAKG,UAAUC,MAAM,EAEzBJ,KAAKK,qBAAuB,KACxBL,KAAKM,eACAZ,EAAqCM,KAAKO,mBAAsB,GAAG,EAE5EP,KAAKM,cAAgB,IACrBN,KAAKQ,QAAU,MACfR,KAAKO,mBAAqB,IAC1BP,KAAKS,uBAAyB,UAC9BT,KAAKU,YAAc,SACnBV,KAAKW,QAAUC,UACfZ,KAAKa,QAAUD,UACfZ,KAAKc,qBAAuBF,UAC5BZ,KAAKe,QAAUH,S,CAEnB,wBAAAI,CAAyBC,GACrBjB,KAAKkB,SAAWD,IAAa,Q,CAEjC,oBAAAE,GACIC,OAAOC,aAAarB,KAAKsB,gBACzBF,OAAOG,cAAcvB,KAAKwB,qB,CAE9B,iBAAAC,GACI,IAAIC,EAAIC,EACR3B,KAAK4B,eAAe5B,KAAKW,QAAQkB,OAASlC,IAA4B+B,EAAK1B,KAAKa,WAAa,MAAQa,SAAY,OAAS,EAAIA,EAAGG,QAAUjC,GAC3I,GAAII,KAAKO,mBAAqB,IAC1BP,KAAKO,mBAAqB,IAC9B,GAAIuB,EAAW9B,KAAK+B,GAAI,UACpB/B,KAAKU,YAAc,SACvBV,KAAKkB,SAAWlB,KAAKU,cAAgB,SACrC,GAAIoB,EAAW9B,KAAK+B,GAAI,gBACpB/B,KAAKe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ClF,OAAQ8E,EAAEC,EAAM,CAAEC,MAAO,CAAE,CAAC,WAAYxE,GAAWyE,KAAM/D,EAAW,SAAW,UAAY4D,EAAE,MAAO,CAAEE,MAAO,aAAejE,GAAWP,GAAYsE,EAAE,MAAO,CAAEE,MAAO,wBAA0BF,EAAE,MAAO,CAAEE,MAAO,CACzM,CAAC,WAAY,KACb,CAAC,WAAWjE,KAAY,QACtBA,IAAY,UAAa+D,EAAE,OAAQ,CAAEI,KAAM,iBAAsBJ,EAAE,OAAQ,CAAEE,MAAO,aAAcG,UAAWlD,EAAclB,GAASqE,QAAYN,EAAE,MAAO,CAAEE,MAAO,CACpK,CAAC,iBAAkB,KACnB,CAAC,WAAYjE,IAAY,YAAce,EAAW9B,KAAK+B,GAAI,kBAC1D+C,EAAE,MAAO,CAAEE,MAAO,iBAAmBF,EAAE,gBAAiB,CAAE/D,QAAS,kBAAoBP,GAAWsE,EAAE,KAAM,KAAMnE,IAAWE,GAAYiE,EAAE,gBAAiB,CAAE/D,QAAS,QAAUP,GAAWsE,EAAE,IAAK,KAAMjE,KAAaiB,EAAW9B,KAAK+B,GAAI,WAAc+C,EAAE,MAAO,CAAEE,MAAO,0BAA4BF,EAAE,OAAQ,CAAEI,KAAM,cAAiBhE,EAAY4D,EAAE,uBAAwB,CAAEE,MAAO,sBAAuBK,WAAY,QAASC,KAAM,OAAQC,SAAUvF,KAAKM,gBAAqBwE,EAAE,YAAa,CAAEU,GAAI,iBAAkBL,UAAWM,EAAWC,QAAS1F,KAAKE,cAAea,QAAS,OAAQsE,WAAYM,EAAsBC,MAAO,aAAcnF,K"}
         
     | 
| 
         @@ -0,0 +1,2 @@ 
     | 
|
| 
      
 1 
     | 
    
         
            +
            import{r as t,c as i,f as o,h as a,H as e,g as r}from"./p-8455d1bb.js";import{y as n,k as s,x as c,X as l,l as d,i as h,d as u,a as b}from"./p-8128572e.js";import{I as v}from"./p-fd186591.js";import{c as p}from"./p-aae38bee.js";const g=`<svg width="24" height="24" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg">\n    <path d="M7 9.5L12 14.5L17 9.5H7Z" fill="currentColor"/>\n</svg>`;const m='/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */html{line-height:1.15;-webkit-text-size-adjust:100%;}body{margin:0}main{display:block}h1{font-size:2em;margin:0.67em 0}hr{box-sizing:content-box;height:0;overflow:visible;}pre{font-family:monospace, monospace;font-size:1em;}a{background-color:transparent}abbr[title]{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted;}b,strong{font-weight:bolder}code,kbd,samp{font-family:monospace, monospace;font-size:1em;}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-0.25em}sup{top:-0.5em}img{border-style:none}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0;}button,input{overflow:visible}button,select{text-transform:none}button,[type="button"],[type="reset"],[type="submit"]{-webkit-appearance:button}button::-moz-focus-inner,[type="button"]::-moz-focus-inner,[type="reset"]::-moz-focus-inner,[type="submit"]::-moz-focus-inner{border-style:none;padding:0}button:-moz-focusring,[type="button"]:-moz-focusring,[type="reset"]:-moz-focusring,[type="submit"]:-moz-focusring{outline:1px dotted ButtonText}fieldset{padding:0.35em 0.75em 0.625em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal;}progress{vertical-align:baseline}textarea{overflow:auto}[type="checkbox"],[type="radio"]{box-sizing:border-box;padding:0;}[type="number"]::-webkit-inner-spin-button,[type="number"]::-webkit-outer-spin-button{height:auto}[type="search"]{-webkit-appearance:textfield;outline-offset:-2px;}[type="search"]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit;}details{display:block}summary{display:list-item}template{display:none}[hidden]{display:none}html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;font-size:100%;font-style:inherit;vertical-align:baseline}:host{display:inline-block;position:relative;--button-default:var(--ic-action-default);--button-default-hover:var(--ic-action-default-hover);--button-default-active:var(--ic-action-default-active);--button-default-background-hover:var(--ic-action-default-bg-hover);--button-default-background-active:var(--ic-action-default-bg-active);--icon-width:100%;--icon-height:100%}.button,::slotted(a){font-family:var(--ic-font-body-family);text-decoration:none;font-weight:600;font-size:0.875rem;transition:var(--ic-easing-transition-fast);border-radius:var(--ic-border-radius);min-width:var(--min-width, 6.25rem);display:inline-flex;flex-direction:row;justify-content:center;align-items:center;background:none;border:none;box-sizing:border-box;white-space:nowrap;vertical-align:middle}:host(.with-badge) .button{border-radius:0.2188rem}.button:hover,::slotted(a:hover){cursor:pointer}.button:focus,::slotted(a:focus){box-shadow:var(--ic-border-focus)}.button:focus-visible,::slotted(a:focus-visible){outline:var(--ic-hc-focus-outline)}:host(.dark) .button,:host(.dark) ::slotted(a){--button-default:var(--ic-action-dark);--button-default-hover:var(--ic-action-dark);--button-default-active:var(--ic-action-dark);--button-default-background-hover:var(--ic-action-dark-bg-hover);--button-default-background-active:var(--ic-action-dark-bg-active)}:host(.light) .button,:host(.light) ::slotted(a){--button-default:var(--ic-action-light);--button-default-hover:var(--ic-action-light);--button-default-active:var(--ic-action-light);--button-default-background-hover:var(--ic-action-light-bg-hover);--button-default-background-active:var(--ic-action-light-bg-active)}:host(.white-background) .button,:host(.white-background) ::slotted(a){--button-default-background-hover:var(--ic-action-default-bg-hover-no-alpha);--button-default-background-active:var(\n    --ic-action-default-bg-active-no-alpha\n  );background-color:var(--ic-architectural-white)}:host(.white-background.dark) .button,:host(.white-background.dark) ::slotted(a){--button-default-background-hover:var(--ic-action-dark-bg-hover-no-alpha);--button-default-background-active:var(--ic-action-dark-bg-active-no-alpha)}:host(.button-variant-primary.light) .button,:host(.button-variant-primary.light) ::slotted(a){color:var(--ic-color-primary-text);--button-default-hover:var(--ic-action-light-hover);--button-default-active:var(--ic-action-light-active)}:host(.button-variant-primary.dark) .button,:host(.button-variant-primary.dark) ::slotted(a){--button-default-hover:var(--ic-action-dark-hover);--button-default-active:var(--ic-action-dark-active)}:host(.disabled),:host(.disabled) .button,:host(.disabled) ::slotted(a),:host(.loading),:host(.loading) .button{pointer-events:none}:host(.top-icon) .button{flex-direction:column;--height:fit-content}:host(.top-icon) .button .icon-container{margin-right:0}:host(.button-variant-primary) .button,:host(.button-variant-primary) ::slotted(a){color:var(--ic-color-white-text);background-color:var(--button-default)}:host(.button-variant-primary) .button:hover{background-color:var(--button-default-hover)}:host(.button-variant-primary.loading) .button,:host(.button-variant-primary) .button:active{background-color:var(--button-default-active)}:host(.button-variant-primary.disabled) .button,:host(.button-variant-primary.disabled) ::slotted(a){background:var(--ic-architectural-200);color:var(--ic-architectural-300)}:host(.button-variant-primary.light.disabled) .button,:host(.button-variant-primary.light.disabled) ::slotted(a){background:var(--ic-architectural-600);color:var(--ic-architectural-500)}:host(.button-variant-secondary) .button,:host(.button-variant-secondary) ::slotted(a){border:var(--ic-border-width) solid var(--button-default);color:var(--button-default)}:host(.button-variant-secondary) .button:hover,:host(.button-variant-secondary) ::slotted(a:hover){background-color:var(--button-default-background-hover);border-color:var(--button-default-hover);color:var(--button-default-hover)}:host(.button-variant-secondary) .button:active,:host(.button-variant-secondary) ::slotted(a:active),:host(.button-variant-secondary.loading) .button{border-color:var(--button-default-active);background-color:var(--button-default-background-active);color:var(--button-default-active)}:host(.button-variant-secondary.disabled) .button,:host(.button-variant-secondary.disabled) ::slotted(a){border-color:var(--ic-architectural-300);color:var(--ic-architectural-300);background:none}:host(.button-variant-secondary.light.disabled) .button,:host(.button-variant-secondary.light.disabled) ::slotted(a){border-color:var(--ic-architectural-500);color:var(--ic-architectural-500)}:host(.button-variant-tertiary) .button,:host(.button-variant-tertiary) ::slotted(a){color:var(--button-default)}:host(.button-variant-tertiary) .button:hover,:host(.button-variant-tertiary) ::slotted(a:hover){background-color:var(--button-default-background-hover);color:var(--button-default-hover)}:host(.button-variant-tertiary) .button:active,:host(.button-variant-tertiary) ::slotted(a:active),:host(.button-variant-tertiary.loading) .button{background-color:var(--button-default-background-active);color:var(--button-default-active)}:host(.button-variant-tertiary.disabled) .button,:host(.button-variant-tertiary.disabled) ::slotted(a){color:var(--ic-architectural-300);background:none}:host(.button-variant-tertiary.light.disabled) .button,:host(.button-variant-tertiary.light.disabled) ::slotted(a){color:var(--ic-architectural-500)}:host(.button-variant-destructive) .button,:host(.button-variant-destructive) ::slotted(a){color:var(--ic-color-white-text);background-color:var(--ic-action-destructive);text-transform:uppercase}:host(.button-variant-destructive) .button:hover{background-color:var(--ic-action-destructive-hover)}:host(.button-variant-destructive) .button:active,:host(.button-variant-destructive.loading) .button{background-color:var(--ic-action-destructive-active)}:host(.button-variant-destructive.disabled) .button,:host(.button-variant-destructive.disabled) ::slotted(a){background:var(--ic-architectural-200);color:var(--ic-architectural-300)}:host(.button-variant-icon) .button,:host(.button-variant-icon) ::slotted(a){color:var(--button-default);min-width:0;gap:var(--ic-space-xs);margin:var(--ic-space-1px) 0}:host(.button-variant-icon) .icon-container{width:var(--ic-space-lg) !important;height:var(--ic-space-lg) !important}:host(.button-variant-icon) .button:hover,:host(.button-variant-icon) ::slotted(a:hover){background-color:var(--button-default-background-hover);color:var(--button-default-hover)}:host(.button-variant-icon) .button:active:not(:focus),:host(.button-variant-icon) ::slotted(a:active:not(:focus)),:host(.button-variant-icon.loading) .button{background-color:var(--button-default-background-active);color:var(--button-default-active)}:host(.button-variant-icon.disabled) .button,:host(.button-variant-icon.disabled) ::slotted(a){color:var(--ic-architectural-300);background:none}:host(.button-variant-icon-primary) .button,:host(.button-variant-icon-primary) ::slotted(a){color:var(--ic-color-white-text);background-color:var(--button-default);min-width:0;gap:var(--ic-space-xs);margin:var(--ic-space-1px) 0}:host(.button-variant-icon-primary) .icon-container{width:var(--ic-space-lg) !important;height:var(--ic-space-lg) !important}:host(.button-variant-icon-primary) .button:hover,:host(.button-variant-icon-primary) ::slotted(a:hover){background-color:var(--button-default-hover)}:host(.button-variant-icon-primary) .button:active,:host(.button-variant-icon-primary) ::slotted(a:active),:host(.button-variant-icon-primary.loading) .button{background:var(--button-default-active)}:host(.button-variant-icon-primary.loading) .button ic-loading-indicator{--inner-color:var(--ic-architectural-white)}:host(.button-variant-icon-primary.disabled) .button,:host(.button-variant-icon-primary.disabled) ::slotted(a){color:var(--ic-architectural-300);background:var(--ic-architectural-200)}:host(.button-variant-icon-primary.light) .button,:host(.button-variant-icon-primary.light) ::slotted(a){color:var(--ic-color-primary-text)}:host(.button-variant-icon-primary.light) .button:hover,:host(.button-variant-icon-primary.light) ::slotted(a:hover){background:var(--ic-action-light-hover)}:host(.button-variant-icon-primary.light) .button:active,:host(.button-variant-icon-primary.light) ::slotted(a:active),:host(.button-variant-icon-primary.light.loading) .button,:host(.button-variant-icon-primary.light.loading) ::slotted(a){background:var(--ic-action-light-active)}:host(.button-variant-icon-primary.dark) .button:hover,:host(.button-variant-icon-primary.dark) ::slotted(a:hover){background:var(--ic-action-dark-hover)}:host(.button-variant-icon-primary.dark) .button:active,:host(.button-variant-icon-primary.dark) ::slotted(a:active),:host(.button-variant-icon-primary.dark.loading) .button,:host(.button-variant-icon-primary.dark.loading) ::slotted(a){background:var(--ic-action-dark-active)}:host(.button-variant-icon-secondary) .button,:host(.button-variant-icon-secondary) ::slotted(a){border:var(--ic-border-width) solid var(--button-default);color:var(--button-default);min-width:0;gap:var(--ic-space-xs);margin:var(--ic-space-1px) 0}:host(.button-variant-icon-secondary) .icon-container{width:var(--ic-space-lg) !important;height:var(--ic-space-lg) !important}:host(.button-variant-icon-secondary) .button:hover,:host(.button-variant-icon-secondary) ::slotted(a:hover){background-color:var(--button-default-background-hover);border-color:var(--button-default-hover);color:var(--button-default-hover)}:host(.button-variant-icon-secondary) .button:active,:host(.button-variant-icon-secondary) ::slotted(a:active),:host(.button-variant-icon-secondary.loading) .button{border-color:var(--button-default-active);background-color:var(--button-default-background-active);color:var(--button-default-active)}:host(.button-variant-icon-secondary.disabled) .button,:host(.button-variant-icon-secondary.disabled) .button:hover,:host(.button-variant-icon-secondary.disabled) .button:active,:host(.button-variant-icon-secondary.disabled) ::slotted(a),:host(.button-variant-icon-secondary.disabled) ::slotted(a:hover),:host(.button-variant-icon-secondary.disabled) ::slotted(a:active){border-color:var(--ic-architectural-300);color:var(--ic-architectural-300);background:none}:host(.button-variant-icon-secondary.light.disabled) .button,:host(.button-variant-icon-secondary.light.disabled) .button:hover,:host(.button-variant-icon-secondary.light.disabled) .button:active,:host(.button-variant-icon-secondary.light.disabled) ::slotted(a),:host(.button-variant-icon-secondary.light.disabled) ::slotted(a:hover),:host(.button-variant-icon-secondary.light.disabled) ::slotted(a:active){border-color:var(--ic-architectural-500);color:var(--ic-architectural-500)}:host(.button-variant-icon-tertiary) .button,:host(.button-variant-icon-tertiary) ::slotted(a){color:var(--button-default);min-width:0;gap:var(--ic-space-xs);margin:var(--ic-space-1px) 0}:host(.button-variant-icon-tertiary) .icon-container{width:var(--ic-space-lg) !important;height:var(--ic-space-lg) !important}:host(.button-variant-icon-tertiary) .button:hover,:host(.button-variant-icon-tertiary) ::slotted(a:hover){background-color:var(--button-default-background-hover);color:var(--button-default-hover)}:host(.button-variant-icon-tertiary) .button:active,:host(.button-variant-icon-tertiary) ::slotted(a:active),:host(.button-variant-icon-tertiary.loading) .button{background-color:var(--button-default-background-active);color:var(--button-default-active)}:host(.button-variant-icon-tertiary.disabled) .button,:host(.button-variant-icon-tertiary.disabled) .button:hover,:host(.button-variant-icon-tertiary.disabled) .button:active,:host(.button-variant-icon-tertiary.disabled) ::slotted(a),:host(.button-variant-icon-tertiary.disabled) ::slotted(a:hover),:host(.button-variant-icon-tertiary.disabled) ::slotted(a:active){color:var(--ic-architectural-300);background:none}:host(.button-variant-icon-destructive) .button,:host(.button-variant-icon-destructive) ::slotted(a){color:var(--ic-color-white-text);background-color:var(--ic-action-destructive);min-width:0;gap:var(--ic-space-xs);margin:var(--ic-space-1px) 0}:host(.button-variant-icon-destructive) .icon-container{width:var(--ic-space-lg) !important;height:var(--ic-space-lg) !important}:host(.button-variant-icon-destructive) .button:hover,:host(.button-variant-icon-destructive) ::slotted(a:hover){background-color:var(--ic-action-destructive-hover)}:host(.button-variant-icon-destructive) .button:active,:host(.button-variant-icon-destructive) ::slotted(a:active),:host(.button-variant-icon-destructive.loading) .button{background-color:var(--ic-action-destructive-active)}:host(.button-variant-icon-destructive.loading) .button ic-loading-indicator{--inner-color:var(--ic-architectural-white)}:host(.button-variant-icon-destructive.disabled) .button,:host(.button-variant-icon-destructive.disabled) .button:hover,:host(.button-variant-icon-destructive.disabled) .button:active,:host(.button-variant-icon-destructive.disabled) ::slotted(a),:host(.button-variant-icon-destructive.disabled) ::slotted(a:hover),:host(.button-variant-icon-destructive.disabled) ::slotted(a:active){background:var(--ic-architectural-200);color:var(--ic-architectural-300)}:host(.button-size-default) .button{height:var(--height, 2.5rem);padding:var(--ic-space-xs) var(--ic-space-md)}:host(.button-size-small) .button{height:var(--height, var(--ic-space-xl));padding:var(--ic-space-xxs) var(--ic-space-md)}:host(.button-size-large) .button{height:var(--height, var(--ic-space-xxl));padding:var(--ic-space-sm) var(--ic-space-md)}:host(.button-size-default.button-variant-icon) .button,:host(.button-size-default.button-variant-icon-primary) .button,:host(.button-size-default.button-variant-icon-secondary) .button,:host(.button-size-default.button-variant-icon-tertiary) .button,:host(.button-size-default.button-variant-icon-destructive) .button,:host(.button-size-default.button-variant-icon-primary) ::slotted(a),:host(.button-size-default.button-variant-icon-secondary) ::slotted(a),:host(.button-size-default.button-variant-icon-tertiary) ::slotted(a),:host(.button-size-default.button-variant-icon-destructive) ::slotted(a),:host(.button-size-default.button-variant-icon) ::slotted(a){height:var(--height, var(--ic-space-xl));width:var(--ic-space-xl);padding:0.375rem}:host(.button-size-small.button-variant-icon) .button,:host(.button-size-small.button-variant-icon-primary) .button,:host(.button-size-small.button-variant-icon-secondary) .button,:host(.button-size-small.button-variant-icon-tertiary) .button,:host(.button-size-small.button-variant-icon-destructive) .button,:host(.button-size-small.button-variant-icon-primary) ::slotted(a),:host(.button-size-small.button-variant-icon-secondary) ::slotted(a),:host(.button-size-small.button-variant-icon-tertiary) ::slotted(a),:host(.button-size-small.button-variant-icon-destructive) ::slotted(a),:host(.button-size-small.button-variant-icon) ::slotted(a){height:var(--height, var(--ic-space-lg));width:var(--ic-space-lg);padding:var(--ic-space-xxs)}:host(.button-size-large.button-variant-icon) .button,:host(.button-size-large.button-variant-icon-primary) .button,:host(.button-size-large.button-variant-icon-secondary) .button,:host(.button-size-large.button-variant-icon-tertiary) .button,:host(.button-size-large.button-variant-icon-destructive) .button,:host(.button-size-large.button-variant-icon-primary) ::slotted(a),:host(.button-size-large.button-variant-icon-secondary) ::slotted(a),:host(.button-size-large.button-variant-icon-tertiary) ::slotted(a),:host(.button-size-large.button-variant-icon-destructive) ::slotted(a),:host(.button-size-large.button-variant-icon) ::slotted(a){height:var(--height, 2.5rem);width:2.5rem;padding:var(--ic-space-xs)}:host(.full-width),:host(.full-width) .button,:host(.full-width) ::slotted(a){width:100%}div.loading-container{position:relative;align-items:center;width:100%}ic-loading-indicator{--outer-color:transparent}@keyframes loading-animation{0%{width:0%;left:0%}25%{width:0%;left:0%;opacity:0}50%{width:100%;left:0%;opacity:1}75%{width:0%;left:100%}100%{width:0%;left:100%;opacity:0}}div.icon-container{box-sizing:border-box;width:var(--ic-space-lg);height:var(--ic-space-lg);display:flex;justify-content:center;align-items:center;margin-right:var(--ic-space-xs)}div.right-icon{margin-right:auto;margin-left:var(--ic-space-xs)}:host(.full-width) .right-icon{margin-right:var(--ic-space-xs)}::slotted(:not(ic-badge)){width:var(--icon-width) !important;height:var(--icon-height) !important;fill:currentcolor !important;pointer-events:none}:host(.button-variant-icon) .button .icon-container{margin:0;pointer-events:none}:host(.search-submit-button) ::slotted(svg){--icon-height:1.25rem;--icon-width:1.25rem}:host(.search-submit-button-small) ::slotted(svg){--icon-height:1rem;--icon-width:1rem}:host(.clear-button){margin:0 var(--ic-space-xxs)}:host(.clear-button) .button:focus,:host(.calendar-button) .button:focus{box-shadow:none}:host(.search-submit-button) .button:focus{box-shadow:none}:host(.search-submit-button) .button:not(:active):focus{box-shadow:none;background-color:var(--ic-action-default-bg-hover)}:host(.search-submit-button){display:flex;align-items:center;margin:0 var(--ic-space-xxs)}:host(.menu-close-button) ::slotted(svg){--icon-height:0.875rem;--icon-width:0.875rem}:host(.popout-menu-button) .button{height:var(--height);justify-content:left;border-radius:0;white-space:pre-line;text-align:start}:host(.popout-menu-button) div.icon-container{flex:none}:host(.popout-menu-button) .button:focus{box-shadow:var(--ic-border-focus-inset);border-radius:var(--ic-border-radius-inset)}.ic-button-describedby{display:none}:host .ic-tooltip{display:block}:host .arrow-dropdown{margin-top:auto}:host .dropdown-expanded{transform:rotate(180deg);margin-bottom:var(--ic-space-xxxs)}:host(.dropdown-no-icon) .button{padding-right:var(--ic-space-xs)}slot[name="router-item"]::slotted(a){pointer-events:all}::slotted(a){font-size:0.875rem !important;border:none !important;vertical-align:middle !important}:host(.white-background) ::slotted(a){background-color:var(--ic-architectural-white) !important}:host(.button-variant-primary) ::slotted(a){background-color:var(--button-default) !important}:host(.button-variant-primary) ::slotted(a:hover){background-color:var(--button-default-hover) !important}:host(.button-variant-primary) ::slotted(a:active){background-color:var(--button-default-active) !important}:host(.button-variant-primary.disabled) ::slotted(a),:host(.button-variant-destructive.disabled) ::slotted(a){background:var(--ic-architectural-200) !important}:host(.button-variant-primary.light.disabled) ::slotted(a){background:var(--ic-architectural-600) !important}:host(.button-variant-secondary) ::slotted(a){border:var(--ic-border-width) solid var(--button-default) !important}:host(.button-variant-secondary) ::slotted(a:hover){background-color:var(--button-default-background-hover) !important;border-color:var(--button-default-hover) !important}:host(.button-variant-secondary) ::slotted(a:active){border-color:var(--button-default-active) !important;background-color:var(--button-default-background-active) !important}:host(.button-variant-secondary.disabled) ::slotted(a),:host(.button-variant-secondary.disabled) ::slotted(a:hover),:host(.button-variant-secondary.disabled) ::slotted(a:active),:host(.button-variant-tertiary.disabled) ::slotted(a),:host(.button-variant-tertiary.disabled) ::slotted(a:hover),:host(.button-variant-tertiary.disabled) ::slotted(a:active){border-color:var(--ic-architectural-300) !important;background:none !important}:host(.button-variant-secondary.light.disabled) ::slotted(a),:host(.button-variant-secondary.light.disabled) ::slotted(a:hover),:host(.button-variant-secondary.light.disabled) ::slotted(a:active),:host(.button-variant-tertiary.light.disabled) ::slotted(a),:host(.button-variant-tertiary.light.disabled) ::slotted(a:hover),:host(.button-variant-tertiary.light.disabled) ::slotted(a:active){border-color:var(--ic-architectural-500) !important}:host(.button-variant-tertiary) ::slotted(a:hover),:host(.button-variant-icon) ::slotted(a:hover){background-color:var(--button-default-background-hover) !important}:host(.button-variant-tertiary) ::slotted(a:active:not(:focus)),:host(.button-variant-tertiary) ::slotted(a:active:focus),:host(.button-variant-tertiary) ::slotted(a:active),:host(.button-variant-icon) ::slotted(a:active:not(:focus)){background-color:var(--button-default-background-active) !important}:host(.button-variant-icon.disabled) ::slotted(a),:host(.button-variant-icon.disabled) ::slotted(a:hover),:host(.button-variant-icon.disabled) ::slotted(a:active){background:none !important}:host(.button-variant-destructive) ::slotted(a){background-color:var(--ic-action-destructive) !important}:host(.button-variant-destructive) ::slotted(a:hover){background-color:var(--ic-action-destructive-hover) !important}:host(.button-variant-destructive) ::slotted(a:active){background-color:var(--ic-action-destructive-active) !important}:host(.button-size-default) ::slotted(a){height:var(--height, 2.5rem) !important;padding:var(--ic-space-xs) var(--ic-space-md) !important}:host(.button-size-small) ::slotted(a){height:var(--height, var(--ic-space-xl)) !important;padding:var(--ic-space-xxs) var(--ic-space-md) !important}:host(.button-size-large) ::slotted(a){height:var(--height, var(--ic-space-xxl)) !important;padding:var(--ic-space-sm) var(--ic-space-md) !important}:host(.button-size-default.button-variant-icon) ::slotted(a){height:var(--height, var(--ic-space-xl)) !important;padding:0.375rem !important}:host(.button-size-small.button-variant-icon) ::slotted(a){padding:var(--ic-space-xxs) !important}:host(.button-size-large.button-variant-icon) ::slotted(a){padding:var(--ic-space-xs) !important}@media (forced-colors: active){.button,::slotted(a){border:0.125rem solid transparent !important}}:host(.flip) ::slotted(svg){transform:scaleX(-1)}';var f=undefined&&undefined.__rest||function(t,i){var o={};for(var a in t)if(Object.prototype.hasOwnProperty.call(t,a)&&i.indexOf(a)<0)o[a]=t[a];if(t!=null&&typeof Object.getOwnPropertySymbols==="function")for(var e=0,a=Object.getOwnPropertySymbols(t);e<a.length;e++){if(i.indexOf(a[e])<0&&Object.prototype.propertyIsEnumerable.call(t,a[e]))o[a[e]]=t[a[e]]}return o};let y=0;const k=class{constructor(a){t(this,a);this.icBlur=i(this,"icBlur",7);this.icFileSelection=i(this,"icFileSelection",7);this.icFocus=i(this,"icFocus",7);this.buttonIdNum=y++;this.hasTooltip=false;this.inheritedAttributes={};this.describedbyEl=null;this.describedById=null;this.mutationObserver=null;this.hostMutationObserver=null;this.handleClick=()=>{if((this.el.type==="submit"||this.el.type==="reset")&&!this.hasRouterSlot()&&!!this.el.closest("FORM")){const t=document.createElement("button");t.setAttribute("type",this.el.type);t.style.display="none";this.el.closest("FORM").appendChild(t);t.click();t.remove()}};this.handleKeyDown=t=>{if(t.key==="Escape"&&this.hasTooltip){this.closeButtonTooltip(t)}};this.onFocus=()=>{this.icFocus.emit()};this.onBlur=()=>{this.icBlur.emit()};this.mutationCallback=()=>{this.describedByContent=this.describedbyEl.innerText};this.hostMutationCallback=t=>{let i=false;t.forEach((({attributeName:t})=>{const o=this.el.getAttribute(t);if(t==="title")this.title=o;else if(t==="aria-label")this.ariaLabel=o;if(n.includes(t)){this.inheritedAttributes[t]=o;i=true}}));if(i){o(this)}};this.setHasTooltip=()=>{this.hasTooltip=!this.disableTooltip&&(!!this.title||this.isIconVariant())};this.isIconVariant=()=>this.variant.startsWith("icon");this.ariaLabel=null;this.describedByContent=null;this.title=null;this.accept="*";this.appearance="default";this.ariaControlsId=undefined;this.ariaOwnsId=undefined;this.disabled=false;this.disableTooltip=false;this.download=false;this.dropdown=false;this.dropdownExpanded=false;this.fileUpload=false;this.fileInputName=`ic-button-file-upload-input-${y++}`;this.form=undefined;this.formaction=undefined;this.formenctype=undefined;this.formmethod=undefined;this.formnovalidate=undefined;this.formtarget=undefined;this.fullWidth=false;this.href=undefined;this.hreflang=undefined;this.loading=false;this.multiple=false;this.referrerpolicy=undefined;this.rel=undefined;this.selectedFiles=undefined;this.size="default";this.target=undefined;this.tooltipPlacement="bottom";this.transparentBackground=true;this.type="button";this.variant="primary"}watchDisabledHandler(){s(this.disabled,this.el)}disconnectedCallback(){if(this.mutationObserver!==null&&this.mutationObserver!==undefined){this.mutationObserver.disconnect()}if(this.hostMutationObserver!==null&&this.hostMutationObserver!==undefined){this.hostMutationObserver.disconnect()}}componentWillUpdate(){if(this.loading){this.el.style.setProperty("--min-width",`${this.el.getBoundingClientRect().width}px`)}this.setHasTooltip()}componentWillLoad(){const t=c(this.el,[...n,"title"]),{title:i,"aria-label":o}=t,a=f(t,["title","aria-label"]);this.title=i;this.ariaLabel=o;this.inheritedAttributes=a;s(this.disabled,this.el);this.el.setAttribute("exportparts","button");this.id=this.el.id||null;this.setHasTooltip();if(!this.hasTooltip){const t=this.inheritedAttributes["aria-describedby"];if(t!==undefined){this.describedById=t;const i=this.el.parentElement.querySelector(`#${t}`);if(i){this.describedByContent=i.innerText;this.describedbyEl=i}}}}componentDidLoad(){this.updateTheme();if(typeof MutationObserver!=="undefined"){if(this.describedById){this.mutationObserver=new MutationObserver(this.mutationCallback);this.mutationObserver.observe(this.describedbyEl,{characterData:true,childList:true,subtree:true})}this.hostMutationObserver=new MutationObserver(this.hostMutationCallback);this.hostMutationObserver.observe(this.el,{attributes:true})}}componentWillRender(){const t=this.hasIconSlot("left")?this.el.querySelector(`[slot="left-icon"]`):this.hasIconSlot("right")?this.el.querySelector(`[slot="right-icon"]`):null;t===null||t===void 0?void 0:t.setAttribute("viewBox","0 0 24 24")}handleHostClick(t){if(!this.hasRouterSlot()){if(this.fileUpload){l(this.icFileSelection,this.el,this.multiple,this.fileInputName,this.selectedFiles,this.disabled,this.accept)}if(this.disabled||this.loading){t.stopImmediatePropagation()}if(this.dropdown){this.dropdownExpanded=!this.dropdownExpanded}}}themeChangeHandler({detail:t}){this.updateTheme(t.mode)}async setFocus(){var t;(t=this.buttonEl)===null||t===void 0?void 0:t.focus()}async closeButtonTooltip(t){const i=this.el.shadowRoot.querySelector("ic-tooltip");if(await i.isTooltipVisible()){i.displayTooltip(false);t.preventDefault();t.stopImmediatePropagation()}}hasIconSlot(t){const i=t?`${t}-`:"";return this.el.querySelector(`[slot="${i}icon"]`)!==null}hasRouterSlot(){this.routerSlot=this.el.querySelector('[slot="router-item"]');if(this.routerSlot){this.routerSlot.ariaLabel=this.routerSlot.textContent}return!!this.routerSlot}updateTheme(t=null){const i=d(this.el,t);if(i!==v.Default){this.appearance=i}}render(){const t=this.href&&"a"||"button";const{title:i,ariaLabel:o,inheritedAttributes:r}=this;const n=t==="button"?{type:this.type,disabled:this.disabled,form:this.form,formaction:this.formaction,formenctype:this.formenctype,formmethod:this.formmethod,formnovalidate:this.formnovalidate,formtarget:this.formtarget}:{download:this.download!==false?this.download:null,href:this.href,rel:this.rel,target:this.target,referrerpolicy:this.referrerpolicy,hreflang:this.hreflang};let s=null;let c=null;if(this.hasTooltip){c=this.id!==null?`ic-button-with-tooltip-${this.id}`:`ic-button-with-tooltip-${this.buttonIdNum}`;s=this.variant==="icon"&&!!o?null:`ic-tooltip-${c}`}else{s=this.describedById}const l=()=>a(t,Object.assign({class:"button","aria-disabled":this.loading||this.disabled?"true":null,"aria-label":this.loading?"Loading":o,"aria-expanded":this.dropdown&&`${this.dropdownExpanded}`},n,r,{onFocus:this.onFocus,onBlur:this.onBlur,ref:t=>this.buttonEl=t,"aria-describedby":s,part:"button"}),this.hasIconSlot()&&!this.loading&&a("div",{class:"icon-container"},a("slot",{name:"icon"})),this.hasIconSlot("left")&&!this.loading&&a("div",{class:"icon-container"},a("slot",{name:"left-icon"})),this.hasIconSlot("top")&&!this.hasIconSlot("left")&&!this.hasIconSlot("right")&&!this.loading&&a("div",{class:"icon-container"},a("slot",{name:"top-icon"})),this.loading?a("div",{class:"loading-container"},a("ic-loading-indicator",{type:"linear",appearance:this.variant==="primary"||this.variant==="destructive"||this.appearance===v.Dark||this.appearance===v.Light?"light":"dark"})):a("slot",null),this.hasIconSlot("right")&&!this.loading&&!this.dropdown&&a("div",{class:{"icon-container":true,"right-icon":true}},a("slot",{name:"right-icon"})),this.dropdown&&!this.loading&&this.variant!=="icon"&&this.variant!=="destructive"&&a("span",{class:{["arrow-dropdown"]:!this.dropdownExpanded,["dropdown-expanded"]:this.dropdownExpanded},innerHTML:g}));return a(e,{class:{["disabled"]:this.disabled&&!this.loading,[`button-variant-${this.variant}`]:true,[`button-size-${this.size}`]:true,["loading"]:this.loading,["dark"]:this.appearance===v.Dark,["light"]:this.appearance===v.Light,["full-width"]:this.fullWidth,["with-badge"]:h(this.el,"badge"),["dropdown-no-icon"]:this.dropdown&&!h(this.el,"icon")&&!h(this.el,"left-icon"),["top-icon"]:h(this.el,"top-icon"),["white-background"]:this.variant==="secondary"&&!this.transparentBackground&&this.appearance!=="light"},onClick:this.handleClick,onKeyDown:this.handleKeyDown,"aria-owns":this.ariaOwnsId,"aria-controls":this.ariaControlsId,"aria-expanded":this.dropdown&&`${this.dropdownExpanded}`},this.hasTooltip&&a("ic-tooltip",{id:s,label:i||o,target:c,placement:this.tooltipPlacement,silent:this.isIconVariant()&&!!o},this.hasRouterSlot()?a("slot",{name:"router-item"}):a(l,null)),h(this.el,"badge")&&a("slot",{name:"badge"}),!this.hasTooltip&&(this.hasRouterSlot()?a("slot",{name:"router-item"}):a(l,null)),this.describedByContent&&a("span",{id:s,class:"ic-button-describedby"},this.describedByContent))}static get delegatesFocus(){return true}get el(){return r(this)}static get watchers(){return{disabled:["watchDisabledHandler"]}}};k.style=m;const x='/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */html{line-height:1.15;-webkit-text-size-adjust:100%;}body{margin:0}main{display:block}h1{font-size:2em;margin:0.67em 0}hr{box-sizing:content-box;height:0;overflow:visible;}pre{font-family:monospace, monospace;font-size:1em;}a{background-color:transparent}abbr[title]{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted;}b,strong{font-weight:bolder}code,kbd,samp{font-family:monospace, monospace;font-size:1em;}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-0.25em}sup{top:-0.5em}img{border-style:none}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0;}button,input{overflow:visible}button,select{text-transform:none}button,[type="button"],[type="reset"],[type="submit"]{-webkit-appearance:button}button::-moz-focus-inner,[type="button"]::-moz-focus-inner,[type="reset"]::-moz-focus-inner,[type="submit"]::-moz-focus-inner{border-style:none;padding:0}button:-moz-focusring,[type="button"]:-moz-focusring,[type="reset"]:-moz-focusring,[type="submit"]:-moz-focusring{outline:1px dotted ButtonText}fieldset{padding:0.35em 0.75em 0.625em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal;}progress{vertical-align:baseline}textarea{overflow:auto}[type="checkbox"],[type="radio"]{box-sizing:border-box;padding:0;}[type="number"]::-webkit-inner-spin-button,[type="number"]::-webkit-outer-spin-button{height:auto}[type="search"]{-webkit-appearance:textfield;outline-offset:-2px;}[type="search"]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit;}details{display:block}summary{display:list-item}template{display:none}[hidden]{display:none}html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;font-size:100%;font-style:inherit;vertical-align:baseline}:host{display:block;--linear-border-radius:0.25rem;--inner-color:var(--ic-action-default);--outer-color:var(--ic-architectural-100);--label-color:var(--ic-color-primary-text);--margin:none;--linear-line-height:var(--ic-space-xs)}:host(.light){--inner-color:var(--ic-architectural-white);--outer-color:var(--ic-architectural-800);--label-color:var(--ic-architectural-white)}.ic-loading-container{display:flex;flex-direction:column;justify-content:center;align-items:center}:host([size="small"]){--circular-diameter:2.5rem;--linear-line-height:var(--ic-space-xxs)}:host([size="default"]){--circular-diameter:5rem}:host([size="large"]){--circular-diameter:7.5rem}:host([size="icon"]){display:inline-block;--margin:var(--ic-space-xxxs);--circular-diameter:1.25rem}:host(.label){--margin:0 0 var(--ic-space-xs) 0}.ic-loading-label{color:var(--label-color);margin-left:var(--label-margin-left)}.ic-loading-circular-outer{height:var(--circular-diameter);width:var(--circular-diameter)}.ic-loading-circular-outer.indeterminate{animation:circular-animation 1s linear;animation-iteration-count:infinite}@keyframes circular-animation{100%{transform:rotate(360deg)}}.ic-loading-circular-outer,.ic-loading-linear-outer{margin:var(--margin)}.ic-loading-linear-outer{background-color:var(--outer-color);height:var(--linear-line-height);width:100%;border-radius:var(--linear-border-radius);overflow:hidden}.ic-loading-linear-inner{position:relative;height:100%;background-color:var(--inner-color);border-radius:var(--linear-border-radius)}.indeterminate>.ic-loading-linear-inner{animation:linear-animation 2s infinite}.determinate>.ic-loading-linear-inner{transition:width 0.5s;width:var(--linear-width)}:host(.full-width){--linear-border-radius:none}@keyframes linear-animation{0%{width:0%;left:-1%}25%{width:0%;left:-1%}50%{width:101%;left:-1%}75%{width:0%;left:101%}100%{width:0%;left:101%}}.ic-loading-circular-svg{position:relative;width:100%;height:100%;transform:rotate(-90deg)}.ic-loading-circular-svg circle{width:100%;height:100%;fill:none;stroke:var(--compact-step-outer-color, var(--outer-color));stroke-width:var(--circular-line-width);stroke-linecap:round}.ic-loading-circular-svg circle:nth-child(2){--circular-indeterminate:calc(\n    (0.25 * var(--stroke-dasharray)) - var(--stroke-dasharray)\n  );stroke-dasharray:var(--stroke-dasharray), var(--stroke-dasharray);stroke-dashoffset:var(--stroke-dashoffset, var(--circular-indeterminate));stroke:var(--compact-step-inner-color, var(--inner-color))}:host(.inner-label) .ic-loading-circular-inner{display:grid}:host(.inner-label) .ic-loading-circular-svg,.inner-text{grid-column:1;grid-row:1}:host(.not-required.compact-step-progress-indicator) .ic-loading-circular-svg circle:nth-child(2){stroke:var(--ic-architectural-300)}.inner-text{display:flex;align-items:center;justify-content:center;width:var(--ic-space-lg);height:inherit;overflow:hidden;margin:auto;color:var(--compact-step-inner-color, var(--ic-status-info))}:host(.not-required.compact-step-progress-indicator) .inner-text{color:var(--ic-color-tertiary-text)}:host(.light.not-required.compact-step-progress-indicator) .inner-text{color:var(--ic-architectural-400)}@media (forced-colors: active){.indeterminate>.ic-loading-circular-inner{forced-color-adjust:none}.ic-loading-linear-outer{border:var(--ic-hc-border)}.ic-loading-linear-inner{background-color:canvastext}.ic-loading-circular-svg circle{stroke:Background}.ic-loading-circular-svg circle:nth-child(2){stroke:canvastext}:host(.not-required.compact-step-progress-indicator) .ic-loading-circular-svg circle:nth-child(2){stroke:GrayText}}';const w=class{constructor(i){t(this,i);this.updateCircularProgressMeter=()=>{if(!this.indeterminate){this.circularMeter.style.setProperty("--progress-value",String(this.progress))}};this.getLabel=(t,i)=>new Promise((()=>{this.interval=setInterval((()=>{if(t<this.labelList.length-1){t++}else{t=0}i(this.labelList[t])}),this.labelDuration)}));this.getLabelVariant=()=>{var t;let i="h4";const o=(t=this.outerElement)===null||t===void 0?void 0:t.offsetWidth;if(this.size==="small"||this.type==="circular"&&o<60){i="label"}else if(this.size==="large"||this.type==="circular"&&o>=120){i="h2"}return i};this.setCircleLineWidth=()=>{const{offsetWidth:t}=this.outerElement;const i=this.el.classList.contains("compact-step-progress-indicator")?40:0;const o=this.el.classList.contains("toast-dismiss-timer")?20:0;if(t||i||o){this.circularLineWidth=(i||o||t)*.1;this.circularDiameter=i||o||t;this.outerElement.style.setProperty("--circular-line-width",`${this.circularLineWidth}px`)}};this.setLinearDeterminateWidth=()=>{if(!this.innerElement)return;const t=Math.min(this.max,Math.max(this.min,this.progress));const i=(t-this.min)/(this.max-this.min);this.showSecond=i>.5;if(this.showSecond){this.innerElement.classList.remove("clip")}else{this.innerElement.classList.add("clip")}this.innerElement.style.setProperty("--linear-width",`${i*100}%`)};this.calcOuterClass=()=>{let t=`ic-loading-${this.type}-outer`;t+=this.indeterminate?" indeterminate":" determinate";return t};this.updateLabel=()=>{if(u(this.label)){this.labelList=this.label.split("/");const t=0;this.indicatorLabel=this.labelList[t];if(this.labelList.length>1){this.getLabel(t,(t=>{this.indicatorLabel=t}))}}};this.setCircleXY=()=>{if(this.circularDiameter>0){const t=this.circularDiameter/2;const i=t;const o=t;const a=t-this.circularLineWidth/2;this.setDashSteps(a);return{x:i,y:o,r:a}}return{x:0,y:0,r:0}};this.setDashSteps=t=>{const i=2*Math.PI*t;const o=Math.min(Math.max(this.progress,this.min),this.max);const a=-1-(o-this.min)/(this.max-this.min);this.circularMeter.style.setProperty("--stroke-dasharray",`${i}px`);if(!this.indeterminate){this.circularMeter.style.setProperty("--circular-steps-max",String(this.max));this.circularMeter.style.setProperty("--stroke-dashoffset",`${a*i}px`)}};this.circularDiameter=undefined;this.circularLineWidth=undefined;this.indeterminate=undefined;this.indicatorLabel=undefined;this.showSecond=false;this.appearance="dark";this.description="Loading";this.fullWidth=false;this.innerLabel=undefined;this.labelDuration=8e3;this.max=100;this.min=0;this.size="default";this.type="circular";this.label=undefined;this.progress=undefined}watchPropHandler(){this.updateLabel()}watchProgressHandler(){if(this.type==="circular"){this.updateCircularProgressMeter()}}disconnectedCallback(){clearInterval(this.interval)}componentWillLoad(){this.indeterminate=this.progress===undefined;this.updateLabel();this.el.setAttribute("exportparts","ic-loading-container")}componentDidLoad(){if(this.type==="circular"){this.setCircleLineWidth();this.circularMeter=this.el.shadowRoot.querySelector(".ic-loading-circular-svg circle:nth-child(2)");this.updateCircularProgressMeter()}if(Number(this.progress)>=0&&this.type==="linear"){this.setLinearDeterminateWidth()}}componentWillUpdate(){this.indeterminate=this.progress===undefined}componentDidUpdate(){if(Number(this.progress)>=0&&this.type==="linear"){this.setLinearDeterminateWidth()}}render(){const{appearance:t,label:i,description:o,size:r,fullWidth:n,innerLabel:s}=this;const{x:c,y:l,r:d}=this.setCircleXY();return a(e,{class:{["light"]:t===v.Light,["label"]:!!i,["full-width"]:n,["inner-label"]:!!s}},a("div",{class:"ic-loading-container",part:"ic-loading-container"},a("div",{ref:t=>this.outerElement=t,class:this.calcOuterClass(),role:"progressbar","aria-labelledby":this.label&&this.size!=="icon"&&"ic-loading-label","aria-label":o,"aria-valuenow":this.progress,"aria-valuemin":this.min,"aria-valuemax":this.max},a("div",{ref:t=>this.innerElement=t,class:`ic-loading-${this.type}-inner`},this.innerLabel&&this.innerLabel!==undefined&&this.size==="small"&&a("ic-typography",{variant:"subtitle-small",class:"inner-text"},this.innerLabel),this.type==="circular"&&a("svg",{class:"ic-loading-circular-svg",viewBox:`0 0 ${this.circularDiameter||0} ${this.circularDiameter||0}`},a("circle",{cx:`${c}`,cy:`${l}`,r:`${d}`}),a("circle",{cx:`${c}`,cy:`${l}`,r:`${d}`})))),i&&r!=="icon"&&a("ic-typography",{id:"ic-loading-label",class:"ic-loading-label",role:"status",variant:this.getLabelVariant()},a("p",null,this.indicatorLabel))))}get el(){return r(this)}static get watchers(){return{label:["watchPropHandler"],progress:["watchProgressHandler"]}}};w.style=x;const z='/*! normalize.css v8.0.1 | MIT License | github.com/necolas/normalize.css */html{line-height:1.15;-webkit-text-size-adjust:100%;}body{margin:0}main{display:block}h1{font-size:2em;margin:0.67em 0}hr{box-sizing:content-box;height:0;overflow:visible;}pre{font-family:monospace, monospace;font-size:1em;}a{background-color:transparent}abbr[title]{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted;}b,strong{font-weight:bolder}code,kbd,samp{font-family:monospace, monospace;font-size:1em;}small{font-size:80%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sub{bottom:-0.25em}sup{top:-0.5em}img{border-style:none}button,input,optgroup,select,textarea{font-family:inherit;font-size:100%;line-height:1.15;margin:0;}button,input{overflow:visible}button,select{text-transform:none}button,[type="button"],[type="reset"],[type="submit"]{-webkit-appearance:button}button::-moz-focus-inner,[type="button"]::-moz-focus-inner,[type="reset"]::-moz-focus-inner,[type="submit"]::-moz-focus-inner{border-style:none;padding:0}button:-moz-focusring,[type="button"]:-moz-focusring,[type="reset"]:-moz-focusring,[type="submit"]:-moz-focusring{outline:1px dotted ButtonText}fieldset{padding:0.35em 0.75em 0.625em}legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal;}progress{vertical-align:baseline}textarea{overflow:auto}[type="checkbox"],[type="radio"]{box-sizing:border-box;padding:0;}[type="number"]::-webkit-inner-spin-button,[type="number"]::-webkit-outer-spin-button{height:auto}[type="search"]{-webkit-appearance:textfield;outline-offset:-2px;}[type="search"]::-webkit-search-decoration{-webkit-appearance:none}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit;}details{display:block}summary{display:list-item}template{display:none}[hidden]{display:none}html,body,div,span,applet,object,iframe,h1,h2,h3,h4,h5,h6,p,blockquote,pre,a,abbr,acronym,address,big,cite,code,del,dfn,em,img,ins,kbd,q,s,samp,small,strike,strong,sub,sup,tt,var,b,u,i,center,dl,dt,dd,ol,ul,li,fieldset,form,label,legend,table,caption,tbody,tfoot,thead,tr,th,td,article,aside,canvas,details,embed,figure,figcaption,footer,header,hgroup,menu,nav,output,ruby,section,summary,time,mark,audio,video{margin:0;padding:0;border:0;font-size:100%;font-style:inherit;vertical-align:baseline}:host(.ic-tooltip){width:-moz-max-content;width:max-content;height:-moz-max-content;height:max-content}:host(.ic-tooltip) .ic-tooltip-container{background-color:var(--ic-architectural-800);color:#ffff;text-align:center;padding:var(--ic-space-xxxs) var(--ic-space-xs);border-radius:var(--ic-border-radius);border:var(--ic-border-width) solid var(--ic-architectural-40);position:absolute;max-width:20rem;display:none;z-index:var(--ic-z-index-tooltip);box-shadow:var(--ic-elevation-overlay)}:host(.tooltip-navigation-item:not(.tooltip-navigation-item-side-nav-collapsed)) .ic-tooltip-container,:host(.tooltip-disabled) .ic-tooltip-container{display:none !important}:host(.tooltip-long-label-navigation-item-side-nav-expanded) .ic-tooltip-container[data-show]{display:block !important}:host(.ic-tooltip) .ic-tooltip-arrow,:host(.ic-tooltip) .ic-tooltip-arrow::before{position:absolute;background:inherit}:host(.ic-tooltip) .ic-tooltip-arrow{visibility:hidden;width:var(--ic-space-md);height:var(--ic-space-md)}:host(.ic-tooltip) .ic-tooltip-arrow::before{visibility:visible;content:"";border:var(--ic-border-width) solid var(--ic-architectural-40);width:100%;height:100%}:host(.ic-tooltip) .ic-tooltip-container[data-show]{display:block}:host(.ic-tooltip) .ic-tooltip-container[data-popper-placement^="top"]>.ic-tooltip-arrow{height:var(--ic-space-xxxs)}:host(.ic-tooltip) .ic-tooltip-container[data-popper-placement^="top"]>.ic-tooltip-arrow::before{border-radius:0 0 var(--ic-border-radius) var(--ic-border-radius);left:0;top:var(--ic-space-xxxs);border-top:0;transform:translateX(var(--tooltip-arrow-translate))}:host(.ic-tooltip) .ic-tooltip-container[data-popper-placement^="bottom"]>.ic-tooltip-arrow{top:calc(-1 * var(--ic-space-xxs));height:var(--ic-space-xxxs)}:host(.ic-tooltip) .ic-tooltip-container[data-popper-placement^="bottom"]>.ic-tooltip-arrow::before{border-radius:var(--ic-border-radius) var(--ic-border-radius) 0 0;left:0;top:var(--ic-space-1px);border-bottom:0;transform:translateX(var(--tooltip-arrow-translate))}:host(.ic-tooltip) .ic-tooltip-container[data-popper-placement^="left"]>.ic-tooltip-arrow{width:var(--ic-space-xxxs);right:calc(-1 * var(--ic-space-1px))}:host(.ic-tooltip) .ic-tooltip-container[data-popper-placement^="left"]>.ic-tooltip-arrow::before{border-radius:0 var(--ic-border-radius) var(--ic-border-radius) 0;border-left:0;top:calc(-1 * var(--ic-space-1px))}:host(.ic-tooltip) .ic-tooltip-container[data-popper-placement^="right"]>.ic-tooltip-arrow{width:var(--ic-space-xxxs);left:calc(-1 * var(--ic-space-xxs))}:host(.ic-tooltip) .ic-tooltip-container[data-popper-placement^="right"]>.ic-tooltip-arrow::before{border-radius:var(--ic-border-radius) 0 0 var(--ic-border-radius);border-right:0;top:calc(-1 * var(--ic-space-1px))}:host(.on-dialog) .ic-tooltip-container{transform:translate(\n    var(--tooltip-translate-x),\n    var(--tooltip-translate-y)\n  ) !important}@media screen and (max-width: 576px){:host(.ic-tooltip) .ic-tooltip-container{max-width:18.875rem}}@media (forced-colors: active){:host(.ic-tooltip) .ic-tooltip-container,:host(.ic-tooltip) .ic-tooltip-arrow::before{border:var(--ic-hc-border)}}';const $=class{constructor(i){t(this,i);this.delayedHideEvents=["mouseleave"];this.dialogOverflow=false;this.instantHideEvents=["focusout"];this.mouseOverTool=false;this.persistTooltip=false;this.onDialog=false;this.showEvents=[!this.disableHover&&"mouseenter",!this.disableHover&&"focusin",!this.disableClick&&"click"];this.getTooltipTranslate=t=>{const i=this.el.children[0].getBoundingClientRect();let o;let a;switch(this.placement){case"bottom":o=i.left-t.left-.5*i.width;a=i.bottom-t.top;break;case"bottom-start":o=i.left-t.left;a=i.bottom-t.top;break;case"bottom-end":o=i.right-t.right;a=i.bottom-t.top;break;case"top":o=i.left-t.left-.5*i.width;a=i.top-t.bottom;break;case"top-start":o=i.left-t.left;a=i.top-t.bottom;break;case"top-end":o=i.right-t.right;a=i.top-t.bottom;break;case"left":case"left-start":o=i.right-t.right-i.width;a=i.bottom-t.top-i.height;break;case"left-end":o=i.right-t.right-i.width;a=i.top-t.bottom+i.height;break;case"right":case"right-start":o=i.left-t.left+i.width;a=i.bottom-t.top-i.height;break;case"right-end":o=i.left-t.left+i.width;a=i.top-t.bottom+i.height;break}if(this.dialogOverflow&&o<0){if(this.placement.includes("top")||this.placement.includes("bottom")){this.toolTip.style.setProperty("--tooltip-arrow-translate",`${o}px`);o=i.left-t.left}if(this.placement.includes("left")){this.placement="right";o=i.left-t.left+i.width}}this.toolTip.style.setProperty("--tooltip-translate-x",`${o}px`);this.toolTip.style.setProperty("--tooltip-translate-y",`${a}px`)};this.show=()=>{if(this.label){this.toolTip.setAttribute("data-show","");if(this.onDialog){this.el.classList.add("on-dialog");const t=this.icDialogEl.shadowRoot.querySelector("dialog").getBoundingClientRect();this.getTooltipTranslate(t)}this.popperInstance=p(this.el,this.toolTip,Object.assign({placement:this.placement,modifiers:[{name:"offset",options:{offset:[0,10]}},{name:"arrow",options:{element:this.arrow}},{name:"eventListeners",options:{scroll:false,resize:false}}]},this.popperProps))}else{console.warn(`Tooltip can't display without prop 'label' set`)}};this.hide=()=>{this.toolTip.removeAttribute("data-show");this.persistTooltip=false;if(this.popperInstance!==undefined){this.popperInstance.destroy()}};this.checkCloseTooltip=()=>{setTimeout((()=>{if(!this.mouseOverTool&&!this.persistTooltip){this.hide()}}),100)};this.mouseEnterTooltip=()=>{this.mouseOverTool=true};this.mouseLeaveTooltip=()=>{this.mouseOverTool=false;this.checkCloseTooltip()};this.handleKeyDown=t=>{if(t.key==="Escape"&&!this.persistTooltip){this.hide()}};this.manageEventListeners=t=>{const i=t==="add"?"addEventListener":"removeEventListener";this.showEvents.forEach((t=>{this.el[i](t,this.show);if(this.toolTip!==undefined){this.toolTip[i](t,this.mouseEnterTooltip)}}));if(!this.persistTooltip){this.instantHideEvents.forEach((t=>{this.el[i](t,this.hide)}))}this.delayedHideEvents.forEach((t=>{this.el[i](t,this.checkCloseTooltip);if(this.toolTip!==undefined){this.toolTip[i](t,this.mouseLeaveTooltip)}}));document[i]("keydown",this.handleKeyDown)};this.disableClick=false;this.disableHover=false;this.maxLines=undefined;this.placement="bottom";this.silent=false;this.target=undefined;this.label=undefined;this.popperProps={}}async setExternalPopperProps(t){this.popperProps=t}disconnectedCallback(){this.manageEventListeners("remove");if(this.popperInstance!==undefined){this.popperInstance.destroy()}}componentDidLoad(){var t;this.manageEventListeners("add");this.icDialogEl=this.el.closest("ic-dialog");this.dialogOverflow=((t=this.icDialogEl)===null||t===void 0?void 0:t.getAttribute("data-overflow"))==="true";this.onDialog=this.icDialogEl!==null;b([{prop:this.label,propName:"label"}],"Tooltip")}componentDidRender(){const t=this.el.shadowRoot.querySelector(".ic-tooltip-container > ic-typography");this.maxLines>0&&t.setAttribute("style",`--truncation-max-lines: ${this.maxLines}`)}async displayTooltip(t,i){this.persistTooltip=i;t?this.show():this.hide()}async isTooltipVisible(){return Promise.resolve(this.toolTip.hasAttribute("data-show"))}render(){const{label:t,maxLines:i,silent:o}=this;return a(e,{class:{"ic-tooltip":true}},a("div",{ref:t=>this.toolTip=t,role:"tooltip",class:"ic-tooltip-container","aria-hidden":`${o}`},a("ic-typography",{maxLines:i,variant:"caption"},t),a("div",{ref:t=>this.arrow=t,class:"ic-tooltip-arrow"})),a("slot",null))}get el(){return r(this)}};$.style=z;export{k as ic_button,w as ic_loading_indicator,$ as ic_tooltip};
         
     | 
| 
      
 2 
     | 
    
         
            +
            //# sourceMappingURL=p-b2c433e2.entry.js.map
         
     |