@ni/nimble-components 27.0.5 → 27.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (37) hide show
  1. package/dist/all-components-bundle.js +198 -60
  2. package/dist/all-components-bundle.js.map +1 -1
  3. package/dist/all-components-bundle.min.js +466 -445
  4. package/dist/all-components-bundle.min.js.map +1 -1
  5. package/dist/esm/src/table/components/header/index.d.ts +1 -0
  6. package/dist/esm/src/table/models/table-layout-manager.d.ts +20 -0
  7. package/dist/esm/src/table-column/base/models/column-internals.d.ts +9 -0
  8. package/dist/esm/src/table-column/base/types.d.ts +1 -0
  9. package/dist/esm/src/table-column/icon/index.d.ts +5 -0
  10. package/dist/esm/src/table-column/icon/types.d.ts +8 -0
  11. package/dist/esm/table/components/header/index.d.ts +1 -0
  12. package/dist/esm/table/components/header/index.js +4 -0
  13. package/dist/esm/table/components/header/index.js.map +1 -1
  14. package/dist/esm/table/components/header/template.js +25 -22
  15. package/dist/esm/table/components/header/template.js.map +1 -1
  16. package/dist/esm/table/models/table-layout-manager.d.ts +20 -0
  17. package/dist/esm/table/models/table-layout-manager.js +98 -23
  18. package/dist/esm/table/models/table-layout-manager.js.map +1 -1
  19. package/dist/esm/table/models/table-update-tracker.js +1 -1
  20. package/dist/esm/table/models/table-update-tracker.js.map +1 -1
  21. package/dist/esm/table/styles.js +2 -2
  22. package/dist/esm/table/styles.js.map +1 -1
  23. package/dist/esm/table/template.js +3 -0
  24. package/dist/esm/table/template.js.map +1 -1
  25. package/dist/esm/table-column/base/models/column-internals.d.ts +9 -0
  26. package/dist/esm/table-column/base/models/column-internals.js +15 -0
  27. package/dist/esm/table-column/base/models/column-internals.js.map +1 -1
  28. package/dist/esm/table-column/base/types.d.ts +1 -0
  29. package/dist/esm/table-column/base/types.js +13 -11
  30. package/dist/esm/table-column/base/types.js.map +1 -1
  31. package/dist/esm/table-column/icon/index.d.ts +5 -0
  32. package/dist/esm/table-column/icon/index.js +32 -1
  33. package/dist/esm/table-column/icon/index.js.map +1 -1
  34. package/dist/esm/table-column/icon/types.d.ts +8 -0
  35. package/dist/esm/table-column/icon/types.js +8 -0
  36. package/dist/esm/table-column/icon/types.js.map +1 -0
  37. package/package.json +1 -1
@@ -9961,8 +9961,8 @@ try{t=document.createElement(e)}catch(e){}if(!(t instanceof OO))throw new Error(
9961
9961
  >
9962
9962
  </${e}>
9963
9963
  `)
9964
- class FO{constructor(e){this.uniqueId=xa("table-column-slot"),this.sortOperation=_O,this.dataRecordFieldNames=[],this.groupingDisabled=!1,this.fractionalWidth=DO,this.minPixelWidth=IO,this.currentFractionalWidth=DO,this.currentSortDirection=CO.none,this.cellRecordFieldNames=e.cellRecordFieldNames,this.cellViewTemplate=RO(e.cellViewTag),this.groupHeaderViewTemplate=TO(e.groupHeaderViewTag),this.delegatedEvents=e.delegatedEvents,this.sortOperation=e.sortOperation??_O,this.validator=e.validator}fractionalWidthChanged(){this.currentFractionalWidth=this.fractionalWidth}pixelWidthChanged(){this.currentPixelWidth=this.pixelWidth}}function NO(e,...t){for(const n of t)if(e===n)return!0
9965
- return!1}e([g],FO.prototype,"columnConfig",void 0),e([g],FO.prototype,"operandDataRecordFieldName",void 0),e([g],FO.prototype,"sortOperation",void 0),e([g],FO.prototype,"dataRecordFieldNames",void 0),e([g],FO.prototype,"groupingDisabled",void 0),e([g],FO.prototype,"groupIndex",void 0),e([g],FO.prototype,"pixelWidth",void 0),e([g],FO.prototype,"fractionalWidth",void 0),e([g],FO.prototype,"minPixelWidth",void 0),e([g],FO.prototype,"currentFractionalWidth",void 0),e([g],FO.prototype,"currentPixelWidth",void 0),e([g],FO.prototype,"currentSortIndex",void 0),e([g],FO.prototype,"currentSortDirection",void 0)
9964
+ class FO{constructor(e){this.uniqueId=xa("table-column-slot"),this.sortOperation=_O,this.dataRecordFieldNames=[],this.groupingDisabled=!1,this.fractionalWidth=DO,this.minPixelWidth=IO,this.resizingDisabled=!1,this.hideHeaderIndicators=!1,this.currentFractionalWidth=DO,this.currentSortDirection=CO.none,this.cellRecordFieldNames=e.cellRecordFieldNames,this.cellViewTemplate=RO(e.cellViewTag),this.groupHeaderViewTemplate=TO(e.groupHeaderViewTag),this.delegatedEvents=e.delegatedEvents,this.sortOperation=e.sortOperation??_O,this.validator=e.validator}fractionalWidthChanged(){this.currentFractionalWidth=this.fractionalWidth}pixelWidthChanged(){this.currentPixelWidth=this.pixelWidth}}function NO(e,...t){for(const n of t)if(e===n)return!0
9965
+ return!1}e([g],FO.prototype,"columnConfig",void 0),e([g],FO.prototype,"operandDataRecordFieldName",void 0),e([g],FO.prototype,"sortOperation",void 0),e([g],FO.prototype,"dataRecordFieldNames",void 0),e([g],FO.prototype,"groupingDisabled",void 0),e([g],FO.prototype,"groupIndex",void 0),e([g],FO.prototype,"pixelWidth",void 0),e([g],FO.prototype,"fractionalWidth",void 0),e([g],FO.prototype,"minPixelWidth",void 0),e([g],FO.prototype,"resizingDisabled",void 0),e([g],FO.prototype,"hideHeaderIndicators",void 0),e([g],FO.prototype,"currentFractionalWidth",void 0),e([g],FO.prototype,"currentPixelWidth",void 0),e([g],FO.prototype,"currentSortIndex",void 0),e([g],FO.prototype,"currentSortDirection",void 0)
9966
9966
  class PO extends Vt{constructor(){super(...arguments),this.columnInternals=new FO(this.getColumnInternalsOptions()),this.columnHidden=!1,this.sortDirection=CO.none,this.sortingDisabled=!1,this.hasOverflow=!1}checkValidity(){return this.columnInternals.validator.isColumnValid}get validity(){return this.columnInternals.validator.getValidity()}get headerTextContent(){return this.contentSlot.assignedNodes().map((e=>e.textContent?.trim())).join(" ")}connectedCallback(){super.connectedCallback(),this.setAttribute("slot",this.columnInternals.uniqueId)}sortDirectionChanged(){this.sortingDisabled||(this.columnInternals.currentSortDirection=this.sortDirection)}sortIndexChanged(){this.sortingDisabled||(this.columnInternals.currentSortIndex=this.sortIndex)}sortingDisabledChanged(){this.sortingDisabled?(this.columnInternals.currentSortDirection=CO.none,this.columnInternals.currentSortIndex=void 0):(this.columnInternals.currentSortDirection=this.sortDirection,this.columnInternals.currentSortIndex=this.sortIndex)}}e([le({attribute:"column-id"})],PO.prototype,"columnId",void 0),e([le({attribute:"action-menu-slot"})],PO.prototype,"actionMenuSlot",void 0),e([le({attribute:"action-menu-label"})],PO.prototype,"actionMenuLabel",void 0),e([le({attribute:"column-hidden",mode:"boolean"})],PO.prototype,"columnHidden",void 0),e([le({attribute:"sort-index",converter:se})],PO.prototype,"sortIndex",void 0),e([le({attribute:"sort-direction"})],PO.prototype,"sortDirection",void 0),e([le({attribute:"sorting-disabled",mode:"boolean"})],PO.prototype,"sortingDisabled",void 0),e([g],PO.prototype,"hasOverflow",void 0)
9967
9967
  class LO{constructor(){this.duplicateRecordId=!1,this.missingRecordId=!1,this.invalidRecordId=!1,this.duplicateColumnId=!1,this.missingColumnId=!1,this.duplicateSortIndex=!1,this.duplicateGroupIndex=!1,this.idFieldNameNotConfigured=!1,this.invalidColumnConfiguration=!1,this.invalidParentIdConfiguration=!1,this.recordIds=new Set}getValidity(){return{duplicateRecordId:this.duplicateRecordId,missingRecordId:this.missingRecordId,invalidRecordId:this.invalidRecordId,duplicateColumnId:this.duplicateColumnId,missingColumnId:this.missingColumnId,duplicateSortIndex:this.duplicateSortIndex,duplicateGroupIndex:this.duplicateGroupIndex,idFieldNameNotConfigured:this.idFieldNameNotConfigured,invalidColumnConfiguration:this.invalidColumnConfiguration,invalidParentIdConfiguration:this.invalidParentIdConfiguration}}isValid(){return Object.values(this.getValidity()).every((e=>!1===e))}areRecordIdsValid(){const e=this.getValidity()
9968
9968
  return!e.duplicateRecordId&&!e.missingRecordId&&!e.invalidRecordId}validateIdFieldConfiguration(e,t,n){const i=e!==kO.none||"string"==typeof n
@@ -10079,8 +10079,8 @@ return!this.missingColumnId&&!this.duplicateColumnId}validateColumnSortIndices(e
10079
10079
  border-color: ${Ua};
10080
10080
  }
10081
10081
 
10082
- .column-divider.column-active,
10083
- .header-container:hover .column-divider {
10082
+ .column-divider.column-active.draggable,
10083
+ .header-container:hover .column-divider.draggable {
10084
10084
  display: block;
10085
10085
  }
10086
10086
 
@@ -10182,32 +10182,35 @@ return!this.missingColumnId&&!this.duplicateColumnId}validateColumnSortIndices(e
10182
10182
  @mousedown="${(e,t)=>!(t.event.detail>1)}"
10183
10183
  >
10184
10184
  <slot></slot>
10185
- ${""}
10186
- ${He((e=>e.sortDirection===CO.ascending),Z`
10187
- <${dg}
10188
- class="sort-indicator"
10189
- title="${e=>Zg.getValueFor(e)}"
10190
- aria-hidden="true"
10191
- ></${dg}>
10192
- `)}
10193
- ${He((e=>e.sortDirection===CO.descending),Z`
10194
- <${lg}
10195
- class="sort-indicator"
10196
- title="${e=>Gg.getValueFor(e)}"
10197
- aria-hidden="true"
10198
- ></${lg}>
10199
- `)}
10200
- ${He((e=>e.isGrouped),Z`
10201
- <${yg}
10202
- class="grouped-indicator"
10203
- title="${e=>Wg.getValueFor(e)}"
10204
- role="img"
10205
- aria-label="${e=>Wg.getValueFor(e)}"
10206
- ></${yg}>
10185
+
10186
+ ${He((e=>!e.indicatorsHidden),Z`
10187
+ ${""}
10188
+ ${He((e=>e.sortDirection===CO.ascending),Z`
10189
+ <${dg}
10190
+ class="sort-indicator"
10191
+ title="${e=>Zg.getValueFor(e)}"
10192
+ aria-hidden="true"
10193
+ ></${dg}>
10194
+ `)}
10195
+ ${He((e=>e.sortDirection===CO.descending),Z`
10196
+ <${lg}
10197
+ class="sort-indicator"
10198
+ title="${e=>Gg.getValueFor(e)}"
10199
+ aria-hidden="true"
10200
+ ></${lg}>
10201
+ `)}
10202
+ ${He((e=>e.isGrouped),Z`
10203
+ <${yg}
10204
+ class="grouped-indicator"
10205
+ title="${e=>Wg.getValueFor(e)}"
10206
+ role="img"
10207
+ aria-label="${e=>Wg.getValueFor(e)}"
10208
+ ></${yg}>
10209
+ `)}
10207
10210
  `)}
10208
10211
  </template>
10209
10212
  `
10210
- class BO extends Vt{constructor(){super(...arguments),this.sortDirection=CO.none,this.firstSortedColumn=!1,this.isGrouped=!1}sortDirectionChanged(e,t){this.updateAriaSort()}firstSortedColumnChanged(e,t){this.updateAriaSort()}updateAriaSort(){this.firstSortedColumn&&this.sortDirection!==CO.none?this.sortDirection===CO.ascending?this.ariaSort="ascending":this.ariaSort="descending":this.ariaSort=null}}e([le({attribute:"sort-direction"})],BO.prototype,"sortDirection",void 0),e([le({attribute:"first-sorted-column",mode:"boolean"})],BO.prototype,"firstSortedColumn",void 0),e([g],BO.prototype,"isGrouped",void 0)
10213
+ class BO extends Vt{constructor(){super(...arguments),this.sortDirection=CO.none,this.firstSortedColumn=!1,this.indicatorsHidden=!1,this.isGrouped=!1}sortDirectionChanged(e,t){this.updateAriaSort()}firstSortedColumnChanged(e,t){this.updateAriaSort()}updateAriaSort(){this.firstSortedColumn&&this.sortDirection!==CO.none?this.sortDirection===CO.ascending?this.ariaSort="ascending":this.ariaSort="descending":this.ariaSort=null}}e([le({attribute:"sort-direction"})],BO.prototype,"sortDirection",void 0),e([le({attribute:"first-sorted-column",mode:"boolean"})],BO.prototype,"firstSortedColumn",void 0),e([le({attribute:"indicators-hidden",mode:"boolean"})],BO.prototype,"indicatorsHidden",void 0),e([g],BO.prototype,"isGrouped",void 0)
10211
10214
  const qO=BO.compose({baseName:"table-header",template:HO,styles:VO})
10212
10215
  wi.getOrCreate().withPrefix("nimble").register(qO())
10213
10216
  const UO="nimble-table-header",jO=xe`
@@ -10692,6 +10695,7 @@ const sR="nimble-table-group-row",aR=Z`
10692
10695
  left
10693
10696
  ${(e,t)=>""+(t.parent.layoutManager.activeColumnIndex===t.index?"column-active":"")}
10694
10697
  ${(e,t)=>""+(t.parent.layoutManager.activeColumnDivider===t.parent.getLeftDividerIndex(t.index)?"divider-active":"")}
10698
+ ${(e,t)=>""+(t.parent.layoutManager.hasResizableColumnToLeft(t.index-1)?"draggable":"")}
10695
10699
  "
10696
10700
  @mousedown="${(e,t)=>t.parent.onLeftDividerMouseDown(t.event,t.index)}">
10697
10701
  </div>
@@ -10700,6 +10704,7 @@ const sR="nimble-table-group-row",aR=Z`
10700
10704
  class="header"
10701
10705
  sort-direction="${e=>"number"==typeof e.columnInternals.currentSortIndex?e.columnInternals.currentSortDirection:CO.none}"
10702
10706
  ?first-sorted-column="${(e,t)=>e===t.parent.firstSortedColumn}"
10707
+ ?indicators-hidden="${e=>e.columnInternals.hideHeaderIndicators}"
10703
10708
  @click="${(e,t)=>t.parent.toggleColumnSort(e,t.event.shiftKey)}"
10704
10709
  :isGrouped=${e=>"number"==typeof e.columnInternals.groupIndex&&!e.columnInternals.groupingDisabled}
10705
10710
  >
@@ -10712,6 +10717,7 @@ const sR="nimble-table-group-row",aR=Z`
10712
10717
  right
10713
10718
  ${(e,t)=>""+(t.parent.layoutManager.activeColumnIndex===t.index?"column-active":"")}
10714
10719
  ${(e,t)=>""+(t.parent.layoutManager.activeColumnDivider===t.parent.getRightDividerIndex(t.index)?"divider-active":"")}
10720
+ ${(e,t)=>""+(t.parent.layoutManager.hasResizableColumnToLeft(t.index)?"draggable":"")}
10715
10721
  "
10716
10722
  @mousedown="${(e,t)=>t.parent.onRightDividerMouseDown(t.event,t.index)}">
10717
10723
  </div>
@@ -10876,30 +10882,43 @@ class xR{constructor(e){this.table=e,this.isColumnBeingSized=!1,this.visibleColu
10876
10882
  for(let e=0;e<this.visibleColumns.length;e++)this.visibleColumns[e].columnInternals.currentPixelWidth=this.initialColumnWidths[e]?.initialPixelWidth
10877
10883
  this.currentTotalDelta=this.getAllowedSizeDelta(t.clientX-this.dragStart),this.performCascadeSizeLeft(this.leftColumnIndex,this.currentTotalDelta),this.performCascadeSizeRight(this.rightColumnIndex,this.currentTotalDelta)
10878
10884
  const n=this.getTotalColumnFixedWidth()-this.initialColumnTotalWidth
10879
- this.table.tableScrollableMinWidth=n>0?this.initialTableScrollableWidth+n:this.initialTableScrollableMinWidth},this.onDividerMouseUp=()=>{document.removeEventListener("mousemove",this.onDividerMouseMove),document.removeEventListener("mouseup",this.onDividerMouseUp),this.resetGridSizedColumns(),this.isColumnBeingSized=!1,this.activeColumnIndex=void 0,this.activeColumnDivider=void 0}}getGridTemplateColumns(){return this.getVisibleColumns().map((e=>{const{minPixelWidth:t,currentPixelWidth:n,currentFractionalWidth:i}=e.columnInternals
10880
- if(n){return`${Math.max(t,n)}px`}return`minmax(${t}px, ${i}fr)`})).join(" ")}beginColumnInteractiveSize(e,t){this.activeColumnDivider=t,this.leftColumnIndex=this.getLeftColumnIndexFromDivider(this.activeColumnDivider),this.rightColumnIndex=this.leftColumnIndex+1,this.activeColumnIndex=this.leftColumnIndex+this.activeColumnDivider%2,this.dragStart=e,this.currentTotalDelta=0,this.visibleColumns=this.getVisibleColumns(),this.setColumnsToFixedSize(),this.initialTableScrollableWidth=this.table.viewport.scrollWidth,this.initialTableScrollableMinWidth=this.table.tableScrollableMinWidth,this.initialColumnTotalWidth=this.getTotalColumnFixedWidth(),this.isColumnBeingSized=!0,document.addEventListener("mousemove",this.onDividerMouseMove),document.addEventListener("mouseup",this.onDividerMouseUp)}getTotalColumnFixedWidth(){let e=0
10885
+ this.table.tableScrollableMinWidth=n>0?this.initialTableScrollableWidth+n:this.initialTableScrollableMinWidth},this.onDividerMouseUp=()=>{document.removeEventListener("mousemove",this.onDividerMouseMove),document.removeEventListener("mouseup",this.onDividerMouseUp),this.resetGridSizedColumns(),this.isColumnBeingSized=!1,this.activeColumnIndex=void 0,this.activeColumnDivider=void 0,this.visibleColumns=[]}}getGridTemplateColumns(){return this.getVisibleColumns().map((e=>{const{minPixelWidth:t,currentPixelWidth:n,currentFractionalWidth:i}=e.columnInternals
10886
+ if(n){return`${Math.max(t,n)}px`}return`minmax(${t}px, ${i}fr)`})).join(" ")}beginColumnInteractiveSize(e,t){this.activeColumnDivider=t,this.leftColumnIndex=this.getLeftColumnIndexFromDivider(this.activeColumnDivider),this.rightColumnIndex=this.leftColumnIndex+1,this.activeColumnIndex=this.leftColumnIndex+this.activeColumnDivider%2,this.dragStart=e,this.currentTotalDelta=0,this.visibleColumns=this.getVisibleColumns(),this.setColumnsToFixedSize(),this.initialTableScrollableWidth=this.table.viewport.scrollWidth,this.initialTableScrollableMinWidth=this.table.tableScrollableMinWidth,this.initialColumnTotalWidth=this.getTotalColumnFixedWidth(),this.isColumnBeingSized=!0,document.addEventListener("mousemove",this.onDividerMouseMove),document.addEventListener("mouseup",this.onDividerMouseUp)}hasResizableColumnToLeft(e){return-1!==this.getFirstLeftResizableColumnIndex(e)}hasResizableColumnToRight(e){return-1!==this.getFirstRightResizableColumnIndex(e)}getTotalColumnFixedWidth(){let e=0
10881
10887
  for(const t of this.visibleColumns)e+=t.columnInternals.currentPixelWidth??0
10882
10888
  return e}setColumnsToFixedSize(){this.cacheGridSizedColumns()
10883
10889
  const e=this.table.getHeaderContainerElements()
10884
10890
  for(let t=0;t<e.length;t++)this.visibleColumns[t].columnInternals.currentPixelWidth=e[t].getBoundingClientRect().width
10885
10891
  this.cacheColumnInitialPixelWidths()}getAllowedSizeDelta(e){let t=0
10886
- if(e>0)return e
10887
- let n=this.leftColumnIndex
10888
- for(;n>=0;){const e=this.initialColumnWidths[n]
10889
- t+=e.initialPixelWidth-e.minPixelWidth,n-=1}return Math.max(e,-t)}performCascadeSizeLeft(e,t){let n=t
10890
- const i=this.initialColumnWidths[e],o=t<0?Math.max(i.minPixelWidth-i.initialPixelWidth,n):t,r=o
10891
- this.visibleColumns[e].columnInternals.currentPixelWidth+=r,r>n&&e>0&&t<0&&(n-=o,this.performCascadeSizeLeft(e-1,n))}performCascadeSizeRight(e,t){let n=t
10892
- const i=this.initialColumnWidths[e],o=t>0?Math.min(i.initialPixelWidth-i.minPixelWidth,n):t,r=o
10893
- this.visibleColumns[e].columnInternals.currentPixelWidth-=r,r<n&&e<this.visibleColumns.length-1&&t>0&&(n-=o,this.performCascadeSizeRight(e+1,n))}cacheGridSizedColumns(){this.gridSizedColumns=[]
10892
+ if(e>0)return this.hasResizableColumnToLeft(this.leftColumnIndex)?e:0
10893
+ if(!this.hasResizableColumnToRight(this.rightColumnIndex))return 0
10894
+ for(let e=this.leftColumnIndex;e>=0;e--){const n=this.initialColumnWidths[e],i=this.visibleColumns[e]
10895
+ i.columnInternals.resizingDisabled||(t+=n.initialPixelWidth-i.columnInternals.minPixelWidth)}return Math.max(e,-t)}getFirstLeftResizableColumnIndex(e){const t=0===this.visibleColumns.length?this.getVisibleColumns():this.visibleColumns
10896
+ for(let n=e;n>=0;n--){const e=t[n]
10897
+ if(!e)return-1
10898
+ if(!e.columnInternals.resizingDisabled)return n}return-1}getFirstRightResizableColumnIndex(e){const t=0===this.visibleColumns.length?this.getVisibleColumns():this.visibleColumns
10899
+ for(let n=e;n<t.length;n++){const e=t[n]
10900
+ if(!e)return-1
10901
+ if(!e.columnInternals.resizingDisabled)return n}return-1}performCascadeSizeLeft(e,t){const n=this.getFirstLeftResizableColumnIndex(e)
10902
+ if(-1===n)return
10903
+ let i=t
10904
+ const o=this.visibleColumns[n],r=this.initialColumnWidths[n],s=t<0?Math.max(o.columnInternals.minPixelWidth-r.initialPixelWidth,i):t,a=s
10905
+ o.columnInternals.currentPixelWidth+=a,a>i&&n>0&&t<0&&(i-=s,this.performCascadeSizeLeft(n-1,i))}performCascadeSizeRight(e,t){const n=this.getFirstRightResizableColumnIndex(e)
10906
+ if(-1===n)return
10907
+ let i=t
10908
+ const o=this.visibleColumns[n],r=this.initialColumnWidths[n]
10909
+ let s
10910
+ s=o.columnInternals.resizingDisabled?0:t>0?Math.min(r.initialPixelWidth-o.columnInternals.minPixelWidth,i):t
10911
+ const a=s
10912
+ o.columnInternals.currentPixelWidth-=a,a<i&&n<this.visibleColumns.length-1&&t>0&&(i-=s,this.performCascadeSizeRight(n+1,i))}cacheGridSizedColumns(){this.gridSizedColumns=[]
10894
10913
  for(const e of this.visibleColumns)void 0===e.columnInternals.currentPixelWidth&&this.gridSizedColumns.push(e)}cacheColumnInitialPixelWidths(){this.initialColumnWidths=[]
10895
- for(const e of this.visibleColumns)this.initialColumnWidths.push({initalColumnFractionalWidth:e.columnInternals.currentFractionalWidth,initialPixelWidth:e.columnInternals.currentPixelWidth,minPixelWidth:e.columnInternals.minPixelWidth})}resetGridSizedColumns(){if(!this.gridSizedColumns||0===this.gridSizedColumns.length)return
10914
+ for(const e of this.visibleColumns)this.initialColumnWidths.push({initalColumnFractionalWidth:e.columnInternals.currentFractionalWidth,initialPixelWidth:e.columnInternals.currentPixelWidth})}resetGridSizedColumns(){if(!this.gridSizedColumns||0===this.gridSizedColumns.length)return
10896
10915
  const e=this.gridSizedColumns.reduce(((e,t)=>e+t.columnInternals.currentPixelWidth),0),t=e/this.gridSizedColumns.length
10897
10916
  let n=0
10898
10917
  for(let e=0;e<this.visibleColumns.length&&n<this.gridSizedColumns.length;e++){const i=this.visibleColumns[e]
10899
10918
  i===this.gridSizedColumns[n]&&(n+=1,i.columnInternals.currentFractionalWidth=i.columnInternals.currentPixelWidth/t,i.columnInternals.currentPixelWidth=void 0)}}getVisibleColumns(){return this.table.columns.filter((e=>!e.columnHidden))}getLeftColumnIndexFromDivider(e){return Math.floor(e/2)}}e([g],xR.prototype,"isColumnBeingSized",void 0),e([g],xR.prototype,"activeColumnIndex",void 0),e([g],xR.prototype,"activeColumnDivider",void 0)
10900
10919
  const CR=(e,...t)=>{for(const n of t)if(e===n)return!0
10901
10920
  return!1},kR=["rowIds","rowParentIds","groupRows","columnIds","columnSort","columnWidths","columnDefinition","actionMenuSlots","selectionMode"]
10902
- class SR extends WE{constructor(e){super(kR),this.table=e,this.updateQueued=!1}get updateRowIds(){return this.isTracked("rowIds")}get updateRowParentIds(){return this.isTracked("rowParentIds")}get updateGroupRows(){return this.isTracked("groupRows")}get updateColumnIds(){return this.isTracked("columnIds")}get updateColumnSort(){return this.isTracked("columnSort")}get updateColumnWidths(){return this.isTracked("columnWidths")}get updateColumnDefinition(){return this.isTracked("columnDefinition")}get updateActionMenuSlots(){return this.isTracked("actionMenuSlots")}get updateSelectionMode(){return this.isTracked("selectionMode")}get requiresTanStackUpdate(){return this.isTracked("rowIds")||this.isTracked("rowParentIds")||this.isTracked("columnSort")||this.isTracked("columnDefinition")||this.isTracked("groupRows")||this.isTracked("selectionMode")}get requiresTanStackDataReset(){return this.isTracked("rowIds")||this.isTracked("columnDefinition")||this.isTracked("rowParentIds")}trackAllStateChanged(){this.trackAll(),this.queueUpdate()}get hasPendingUpdates(){return this.updateQueued}trackColumnPropertyChanged(e){CR(e,"columnId")?this.track("columnIds"):NO(e,"operandDataRecordFieldName","sortOperation")?this.track("columnDefinition"):CR(e,"sortingDisabled")||NO(e,"currentSortDirection","currentSortIndex")?this.track("columnSort"):CR(e,"columnHidden")||NO(e,"currentFractionalWidth","currentPixelWidth","minPixelWidth")?this.track("columnWidths"):CR(e,"actionMenuSlot")?this.track("actionMenuSlots"):NO(e,"groupIndex","groupingDisabled")&&this.track("groupRows"),this.queueUpdate()}trackColumnInstancesChanged(){this.track("columnIds"),this.track("columnDefinition"),this.track("columnSort"),this.track("columnWidths"),this.track("actionMenuSlots"),this.track("groupRows"),this.queueUpdate()}trackIdFieldNameChanged(){this.track("rowIds"),this.queueUpdate()}trackParentIdFieldNameChanged(){this.track("rowParentIds"),this.queueUpdate()}trackSelectionModeChanged(){this.track("selectionMode"),this.queueUpdate()}queueUpdate(){this.table.$fastController.isConnected&&(this.updateQueued||(this.updateQueued=!0,u.queueUpdate((()=>{this.table.update(),this.untrackAll(),this.updateQueued=!1}))))}}class $R{constructor(e){this.tanStackTable=e}reset(){}toggleIsRowSelected(e,t){e.isGroupRow&&e.selectionState===$O?this.deselectAllLeafRows(e.id):this.tanStackTable.getRow(e.id).toggleSelected(t,{selectChildren:e.isGroupRow})}selectSingleRow(e){if(e.isGroupRow)throw new Error("function not intended to select grouped rows")
10921
+ class SR extends WE{constructor(e){super(kR),this.table=e,this.updateQueued=!1}get updateRowIds(){return this.isTracked("rowIds")}get updateRowParentIds(){return this.isTracked("rowParentIds")}get updateGroupRows(){return this.isTracked("groupRows")}get updateColumnIds(){return this.isTracked("columnIds")}get updateColumnSort(){return this.isTracked("columnSort")}get updateColumnWidths(){return this.isTracked("columnWidths")}get updateColumnDefinition(){return this.isTracked("columnDefinition")}get updateActionMenuSlots(){return this.isTracked("actionMenuSlots")}get updateSelectionMode(){return this.isTracked("selectionMode")}get requiresTanStackUpdate(){return this.isTracked("rowIds")||this.isTracked("rowParentIds")||this.isTracked("columnSort")||this.isTracked("columnDefinition")||this.isTracked("groupRows")||this.isTracked("selectionMode")}get requiresTanStackDataReset(){return this.isTracked("rowIds")||this.isTracked("columnDefinition")||this.isTracked("rowParentIds")}trackAllStateChanged(){this.trackAll(),this.queueUpdate()}get hasPendingUpdates(){return this.updateQueued}trackColumnPropertyChanged(e){CR(e,"columnId")?this.track("columnIds"):NO(e,"operandDataRecordFieldName","sortOperation")?this.track("columnDefinition"):CR(e,"sortingDisabled")||NO(e,"currentSortDirection","currentSortIndex")?this.track("columnSort"):CR(e,"columnHidden")||NO(e,"currentFractionalWidth","currentPixelWidth","minPixelWidth","resizingDisabled")?this.track("columnWidths"):CR(e,"actionMenuSlot")?this.track("actionMenuSlots"):NO(e,"groupIndex","groupingDisabled")&&this.track("groupRows"),this.queueUpdate()}trackColumnInstancesChanged(){this.track("columnIds"),this.track("columnDefinition"),this.track("columnSort"),this.track("columnWidths"),this.track("actionMenuSlots"),this.track("groupRows"),this.queueUpdate()}trackIdFieldNameChanged(){this.track("rowIds"),this.queueUpdate()}trackParentIdFieldNameChanged(){this.track("rowParentIds"),this.queueUpdate()}trackSelectionModeChanged(){this.track("selectionMode"),this.queueUpdate()}queueUpdate(){this.table.$fastController.isConnected&&(this.updateQueued||(this.updateQueued=!0,u.queueUpdate((()=>{this.table.update(),this.untrackAll(),this.updateQueued=!1}))))}}class $R{constructor(e){this.tanStackTable=e}reset(){}toggleIsRowSelected(e,t){e.isGroupRow&&e.selectionState===$O?this.deselectAllLeafRows(e.id):this.tanStackTable.getRow(e.id).toggleSelected(t,{selectChildren:e.isGroupRow})}selectSingleRow(e){if(e.isGroupRow)throw new Error("function not intended to select grouped rows")
10903
10922
  const t=this.tanStackTable.getState().rowSelection,n=[]
10904
10923
  if(Object.entries(t).forEach((([e,t])=>{t&&n.push(e)})),1===n.length&&n[0]===e.id)return!1
10905
10924
  const i={}
@@ -11373,16 +11392,18 @@ const t=this.columnConfig.mappingConfigs.get(e)
11373
11392
  t instanceof eN?(this.severity=t.severity,this.text=t.text,this.visualizationTemplate=t.iconTemplate,this.textHidden=t.textHidden):t instanceof nN?(this.text=t.text,this.visualizationTemplate=t.spinnerTemplate,this.textHidden=t.textHidden):t instanceof iN&&(this.text=t.text,this.textHidden=!1)}resetState(){this.text=void 0,this.textHidden=!1,this.visualizationTemplate=void 0,this.severity=YF.default}}e([g],lN.prototype,"severity",void 0),e([g],lN.prototype,"text",void 0),e([g],lN.prototype,"visualizationTemplate",void 0),e([g],lN.prototype,"textHidden",void 0),e([g],lN.prototype,"hasOverflow",void 0)
11374
11393
  const cN=lN.compose({baseName:"table-column-icon-cell-view",template:aN,styles:sN})
11375
11394
  wi.getOrCreate().withPrefix("nimble").register(cN())
11376
- class dN extends(HR(VR(qF))){getColumnInternalsOptions(){return{cellRecordFieldNames:["value"],cellViewTag:"nimble-table-column-icon-cell-view",groupHeaderViewTag:"nimble-table-column-icon-group-header-view",delegatedEvents:[],sortOperation:_O,validator:new GF}}createColumnConfig(e){return{mappingConfigs:e}}createMappingConfig(e){if(e instanceof fv)return new eN(e.resolvedIcon,e.severity,e.text,e.textHidden)
11395
+ const dN="icon-size"
11396
+ class hN extends(HR(VR(qF))){minPixelWidthChanged(){this.widthMode!==dN&&(this.columnInternals.minPixelWidth=this.getConfiguredMinPixelWidth())}getColumnInternalsOptions(){return{cellRecordFieldNames:["value"],cellViewTag:"nimble-table-column-icon-cell-view",groupHeaderViewTag:"nimble-table-column-icon-group-header-view",delegatedEvents:[],sortOperation:_O,validator:new GF}}createColumnConfig(e){return{mappingConfigs:e}}createMappingConfig(e){if(e instanceof fv)return new eN(e.resolvedIcon,e.severity,e.text,e.textHidden)
11377
11397
  if(e instanceof gv)return new nN(e.text,e.textHidden)
11378
11398
  if(e instanceof hv)return new iN(e.text)
11379
- throw new Error("Unsupported mapping")}}const hN=dN.compose({baseName:"table-column-icon",template:jF,styles:UF})
11380
- wi.getOrCreate().withPrefix("nimble").register(hN())
11381
- const uN=class extends lF{updateText(){this.text="string"==typeof this.cellRecord?.value?this.cellRecord.value:""}}.compose({baseName:"table-column-text-cell-view",template:sF,styles:aF})
11399
+ throw new Error("Unsupported mapping")}widthModeChanged(){this.widthMode===dN?(this.columnInternals.resizingDisabled=!0,this.columnInternals.hideHeaderIndicators=!0,this.columnInternals.pixelWidth=32,this.columnInternals.minPixelWidth=32):(this.columnInternals.resizingDisabled=!1,this.columnInternals.hideHeaderIndicators=!1,this.columnInternals.pixelWidth=void 0,this.columnInternals.minPixelWidth=this.getConfiguredMinPixelWidth())}getConfiguredMinPixelWidth(){return"number"==typeof this.minPixelWidth?this.minPixelWidth:IO}}e([le({attribute:"width-mode"})],hN.prototype,"widthMode",void 0)
11400
+ const uN=hN.compose({baseName:"table-column-icon",template:jF,styles:UF})
11382
11401
  wi.getOrCreate().withPrefix("nimble").register(uN())
11383
- class pN extends(tF(eF)){placeholderChanged(){this.columnInternals.columnConfig={placeholder:this.placeholder}}getColumnInternalsOptions(){return{cellRecordFieldNames:["value"],cellViewTag:"nimble-table-column-text-cell-view",groupHeaderViewTag:YR,delegatedEvents:[],sortOperation:EO,validator:new FR([])}}}const fN=pN.compose({baseName:"table-column-text",template:zR,styles:LR})
11384
- wi.getOrCreate().withPrefix("nimble").register(fN())
11385
- const mN=xe`
11402
+ const pN=class extends lF{updateText(){this.text="string"==typeof this.cellRecord?.value?this.cellRecord.value:""}}.compose({baseName:"table-column-text-cell-view",template:sF,styles:aF})
11403
+ wi.getOrCreate().withPrefix("nimble").register(pN())
11404
+ class fN extends(tF(eF)){placeholderChanged(){this.columnInternals.columnConfig={placeholder:this.placeholder}}getColumnInternalsOptions(){return{cellRecordFieldNames:["value"],cellViewTag:"nimble-table-column-text-cell-view",groupHeaderViewTag:YR,delegatedEvents:[],sortOperation:EO,validator:new FR([])}}}const mN=fN.compose({baseName:"table-column-text",template:zR,styles:LR})
11405
+ wi.getOrCreate().withPrefix("nimble").register(mN())
11406
+ const gN=xe`
11386
11407
  ${Oo("grid")}
11387
11408
 
11388
11409
  :host {
@@ -11410,7 +11431,7 @@ const mN=xe`
11410
11431
  overflow: auto;
11411
11432
  }
11412
11433
  `
11413
- const gN=class extends so{constructor(){super(),this.activeindicator=!1}}.compose({baseName:"tabs",baseClass:so,template:(e,t)=>Z`
11434
+ const vN=class extends so{constructor(){super(),this.activeindicator=!1}}.compose({baseName:"tabs",baseClass:so,template:(e,t)=>Z`
11414
11435
  <template class="${e=>e.orientation}">
11415
11436
  ${nt(0,t)}
11416
11437
  <div class="tablist" part="tablist" role="tablist">
@@ -11429,9 +11450,9 @@ const gN=class extends so{constructor(){super(),this.activeindicator=!1}}.compos
11429
11450
  <slot name="tabpanel" ${Ye("tabpanels")}></slot>
11430
11451
  </div>
11431
11452
  </template>
11432
- `,styles:mN})
11433
- wi.getOrCreate().withPrefix("nimble").register(gN())
11434
- const vN=xe`
11453
+ `,styles:gN})
11454
+ wi.getOrCreate().withPrefix("nimble").register(vN())
11455
+ const bN=xe`
11435
11456
  ${Oo("flex")}
11436
11457
 
11437
11458
  :host {
@@ -11449,15 +11470,15 @@ const vN=xe`
11449
11470
  rgba(${za}, 0.3);
11450
11471
  margin: ${il} ${ol};
11451
11472
  }
11452
- `,bN=Z`
11473
+ `,yN=Z`
11453
11474
  <template slot="end">
11454
11475
  <div class="separator"></div>
11455
11476
  <slot></slot>
11456
11477
  </template>
11457
11478
  `
11458
- const yN=class extends Vt{}.compose({baseName:"tabs-toolbar",template:bN,styles:vN})
11459
- wi.getOrCreate().withPrefix("nimble").register(yN())
11460
- const wN="outline",xN="block",CN=xe`
11479
+ const wN=class extends Vt{}.compose({baseName:"tabs-toolbar",template:yN,styles:bN})
11480
+ wi.getOrCreate().withPrefix("nimble").register(wN())
11481
+ const xN="outline",CN="block",kN=xe`
11461
11482
  ${Oo("inline-flex")}
11462
11483
  ${Bm}
11463
11484
 
@@ -11597,12 +11618,12 @@ const wN="outline",xN="block",CN=xe`
11597
11618
  top: ${ol};
11598
11619
  right: var(--ni-private-scrollbar-width);
11599
11620
  }
11600
- `.withBehaviors(Hd(wN,xe`
11621
+ `.withBehaviors(Hd(xN,xe`
11601
11622
  .control {
11602
11623
  border-color: rgba(${za}, 0.3);
11603
11624
  background-color: transparent;
11604
11625
  }
11605
- `),Hd(xN,xe`
11626
+ `),Hd(CN,xe`
11606
11627
  .control {
11607
11628
  background-color: rgba(${za}, 0.1);
11608
11629
  }
@@ -11620,8 +11641,8 @@ const wN="outline",xN="block",CN=xe`
11620
11641
  border-bottom-color: ${Va};
11621
11642
  }
11622
11643
  `))
11623
- class kN extends ho{constructor(){super(...arguments),this.appearance=wN,this.errorVisible=!1,this.scrollbarWidth=-1,this.updateScrollbarWidthQueued=!1}connectedCallback(){super.connectedCallback(),this.resizeObserver=new ResizeObserver((()=>this.onResize())),this.resizeObserver.observe(this)}disconnectedCallback(){super.disconnectedCallback(),this.resizeObserver?.disconnect()}onTextAreaInput(){this.handleTextInput(),this.queueUpdateScrollbarWidth()}placeholderChanged(){this.queueUpdateScrollbarWidth()}valueChanged(e,t){super.valueChanged(e,t),this.queueUpdateScrollbarWidth()}onResize(){this.scrollbarWidth=this.control.offsetWidth-this.control.clientWidth}queueUpdateScrollbarWidth(){this.$fastController.isConnected&&(this.updateScrollbarWidthQueued||(this.updateScrollbarWidthQueued=!0,u.queueUpdate((()=>this.updateScrollbarWidth()))))}updateScrollbarWidth(){this.updateScrollbarWidthQueued=!1,this.scrollbarWidth=this.control.offsetWidth-this.control.clientWidth}}e([le],kN.prototype,"appearance",void 0),e([le({attribute:"error-text"})],kN.prototype,"errorText",void 0),e([le({attribute:"error-visible",mode:"boolean"})],kN.prototype,"errorVisible",void 0),e([g],kN.prototype,"scrollbarWidth",void 0)
11624
- const SN=kN.compose({baseName:"text-area",baseClass:ho,template:()=>Z`
11644
+ class SN extends ho{constructor(){super(...arguments),this.appearance=xN,this.errorVisible=!1,this.scrollbarWidth=-1,this.updateScrollbarWidthQueued=!1}connectedCallback(){super.connectedCallback(),this.resizeObserver=new ResizeObserver((()=>this.onResize())),this.resizeObserver.observe(this)}disconnectedCallback(){super.disconnectedCallback(),this.resizeObserver?.disconnect()}onTextAreaInput(){this.handleTextInput(),this.queueUpdateScrollbarWidth()}placeholderChanged(){this.queueUpdateScrollbarWidth()}valueChanged(e,t){super.valueChanged(e,t),this.queueUpdateScrollbarWidth()}onResize(){this.scrollbarWidth=this.control.offsetWidth-this.control.clientWidth}queueUpdateScrollbarWidth(){this.$fastController.isConnected&&(this.updateScrollbarWidthQueued||(this.updateScrollbarWidthQueued=!0,u.queueUpdate((()=>this.updateScrollbarWidth()))))}updateScrollbarWidth(){this.updateScrollbarWidthQueued=!1,this.scrollbarWidth=this.control.offsetWidth-this.control.clientWidth}}e([le],SN.prototype,"appearance",void 0),e([le({attribute:"error-text"})],SN.prototype,"errorText",void 0),e([le({attribute:"error-visible",mode:"boolean"})],SN.prototype,"errorVisible",void 0),e([g],SN.prototype,"scrollbarWidth",void 0)
11645
+ const $N=SN.compose({baseName:"text-area",baseClass:ho,template:()=>Z`
11625
11646
  <label
11626
11647
  part="label"
11627
11648
  for="control"
@@ -11678,9 +11699,9 @@ const SN=kN.compose({baseName:"text-area",baseClass:ho,template:()=>Z`
11678
11699
  ></${Zf}>
11679
11700
  ${Fm}
11680
11701
  </div>
11681
- `,styles:CN,shadowOptions:{delegatesFocus:!0}})
11682
- wi.getOrCreate().withPrefix("nimble").register(SN())
11683
- const $N="underline",MN="outline",_N="block",EN="frameless",IN=xe`
11702
+ `,styles:kN,shadowOptions:{delegatesFocus:!0}})
11703
+ wi.getOrCreate().withPrefix("nimble").register($N())
11704
+ const MN="underline",_N="outline",EN="block",IN="frameless",DN=xe`
11684
11705
  ${Oo("inline-block")}
11685
11706
  ${Bm}
11686
11707
 
@@ -11852,12 +11873,12 @@ const $N="underline",MN="outline",_N="block",EN="frameless",IN=xe`
11852
11873
  slot[name='actions']::slotted(*) {
11853
11874
  ${tl.cssCustomProperty}: 24px;
11854
11875
  }
11855
- `.withBehaviors(Hd($N,xe`
11876
+ `.withBehaviors(Hd(MN,xe`
11856
11877
  .root {
11857
11878
  border-bottom-width: ${al};
11858
11879
  padding-bottom: 0;
11859
11880
  }
11860
- `),Hd(_N,xe`
11881
+ `),Hd(EN,xe`
11861
11882
  .root {
11862
11883
  background-color: rgba(${za}, 0.1);
11863
11884
  }
@@ -11885,12 +11906,12 @@ const $N="underline",MN="outline",_N="block",EN="frameless",IN=xe`
11885
11906
  :host([disabled]) .root {
11886
11907
  background-color: rgba(${za}, 0.07);
11887
11908
  }
11888
- `),Hd(MN,xe`
11909
+ `),Hd(_N,xe`
11889
11910
  .root {
11890
11911
  border-width: ${al};
11891
11912
  padding: 0;
11892
11913
  }
11893
- `),Hd(EN,xe`
11914
+ `),Hd(IN,xe`
11894
11915
  .control {
11895
11916
  padding-left: ${al};
11896
11917
  padding-right: ${al};
@@ -11908,8 +11929,8 @@ const $N="underline",MN="outline",_N="block",EN="frameless",IN=xe`
11908
11929
  filter: invert(100%);
11909
11930
  }
11910
11931
  `))
11911
- class DN extends Vi{constructor(){super(...arguments),this.appearance=$N,this.errorVisible=!1,this.fullBleed=!1}}e([le],DN.prototype,"appearance",void 0),e([le({attribute:"error-text"})],DN.prototype,"errorText",void 0),e([le({attribute:"error-visible",mode:"boolean"})],DN.prototype,"errorVisible",void 0),e([le({attribute:"full-bleed",mode:"boolean"})],DN.prototype,"fullBleed",void 0)
11912
- const AN=DN.compose({baseName:"text-field",baseClass:Vi,template:(e,t)=>Z`
11932
+ class AN extends Vi{constructor(){super(...arguments),this.appearance=MN,this.errorVisible=!1,this.fullBleed=!1}}e([le],AN.prototype,"appearance",void 0),e([le({attribute:"error-text"})],AN.prototype,"errorText",void 0),e([le({attribute:"error-visible",mode:"boolean"})],AN.prototype,"errorVisible",void 0),e([le({attribute:"full-bleed",mode:"boolean"})],AN.prototype,"fullBleed",void 0)
11933
+ const TN=AN.compose({baseName:"text-field",baseClass:Vi,template:(e,t)=>Z`
11913
11934
  <template
11914
11935
  class="
11915
11936
  ${e=>e.readOnly?"readonly":""}
@@ -11969,7 +11990,7 @@ const AN=DN.compose({baseName:"text-field",baseClass:Vi,template:(e,t)=>Z`
11969
11990
  ${tt(0,t)}
11970
11991
  </div>
11971
11992
  </template>
11972
- `,styles:IN,shadowOptions:{delegatesFocus:!0},end:Z`
11993
+ `,styles:DN,shadowOptions:{delegatesFocus:!0},end:Z`
11973
11994
  <${Zf}
11974
11995
  severity="error"
11975
11996
  class="error-icon"
@@ -11979,8 +12000,8 @@ const AN=DN.compose({baseName:"text-field",baseClass:Vi,template:(e,t)=>Z`
11979
12000
  </span>
11980
12001
  ${Fm}
11981
12002
  `})
11982
- wi.getOrCreate().withPrefix("nimble").register(AN())
11983
- const TN=xe`
12003
+ wi.getOrCreate().withPrefix("nimble").register(TN())
12004
+ const ON=xe`
11984
12005
  ${Oo("inline-flex")}
11985
12006
 
11986
12007
  :host {
@@ -12065,7 +12086,7 @@ const TN=xe`
12065
12086
  .status-icon {
12066
12087
  opacity: 0.6;
12067
12088
  }
12068
- `)),ON=Z`
12089
+ `)),RN=Z`
12069
12090
  ${He((e=>e.tooltipVisible),Z`
12070
12091
  <${dh}
12071
12092
  class="anchored-region"
@@ -12098,11 +12119,11 @@ const TN=xe`
12098
12119
  </${dh}>
12099
12120
  `)}
12100
12121
  `
12101
- class RN extends Io{constructor(){super(...arguments),this.iconVisible=!1}}e([le],RN.prototype,"severity",void 0),e([le({attribute:"icon-visible",mode:"boolean"})],RN.prototype,"iconVisible",void 0)
12102
- const FN=RN.compose({baseName:"tooltip",baseClass:Io,template:ON,styles:TN})
12103
- wi.getOrCreate().withPrefix("nimble").register(FN())
12104
- const NN="group-selected",PN="all",LN="leaves-only",zN="none"
12105
- class VN{constructor(e,t,n){this.ltr=e,this.rtl=t,this.source=n,this.attached=null}handleChange({target:e,token:t}){this.attach(t.getValueFor(e))}attach(e){this.attached!==this[e]&&(null!==this.attached&&this.source.$fastController.removeStyles(this.attached),this.attached=this[e],null!==this.attached&&this.source.$fastController.addStyles(this.attached))}}const HN=xe`
12122
+ class FN extends Io{constructor(){super(...arguments),this.iconVisible=!1}}e([le],FN.prototype,"severity",void 0),e([le({attribute:"icon-visible",mode:"boolean"})],FN.prototype,"iconVisible",void 0)
12123
+ const NN=FN.compose({baseName:"tooltip",baseClass:Io,template:RN,styles:ON})
12124
+ wi.getOrCreate().withPrefix("nimble").register(NN())
12125
+ const PN="group-selected",LN="all",zN="leaves-only",VN="none"
12126
+ class HN{constructor(e,t,n){this.ltr=e,this.rtl=t,this.source=n,this.attached=null}handleChange({target:e,token:t}){this.attach(t.getValueFor(e))}attach(e){this.attached!==this[e]&&(null!==this.attached&&this.source.$fastController.removeStyles(this.attached),this.attached=this[e],null!==this.attached&&this.source.$fastController.addStyles(this.attached))}}const BN=xe`
12106
12127
  ${Oo("block")}
12107
12128
 
12108
12129
  :host {
@@ -12123,7 +12144,7 @@ class VN{constructor(e,t,n){this.ltr=e,this.rtl=t,this.source=n,this.attached=nu
12123
12144
  }
12124
12145
 
12125
12146
  ${""}
12126
- :host([${NN}])::after {
12147
+ :host([${PN}])::after {
12127
12148
  background: ${Ua};
12128
12149
  border-radius: 0px;
12129
12150
  content: '';
@@ -12145,7 +12166,7 @@ class VN{constructor(e,t,n){this.ltr=e,this.rtl=t,this.source=n,this.attached=nu
12145
12166
  background: ${Pa};
12146
12167
  }
12147
12168
 
12148
- :host([${NN}]) .positioning-region:hover {
12169
+ :host([${PN}]) .positioning-region:hover {
12149
12170
  background: ${Na};
12150
12171
  }
12151
12172
 
@@ -12251,7 +12272,7 @@ class VN{constructor(e,t,n){this.ltr=e,this.rtl=t,this.source=n,this.attached=nu
12251
12272
  display: block;
12252
12273
  }
12253
12274
  `.withBehaviors(new class{constructor(e,t){this.cache=new WeakMap,this.ltr=e,this.rtl=t}bind(e){this.attach(e)}unbind(e){const t=this.cache.get(e)
12254
- t&&Ea.unsubscribe(t)}attach(e){const t=this.cache.get(e)||new VN(this.ltr,this.rtl,e),n=Ea.getValueFor(e)
12275
+ t&&Ea.unsubscribe(t)}attach(e){const t=this.cache.get(e)||new HN(this.ltr,this.rtl,e),n=Ea.getValueFor(e)
12255
12276
  Ea.subscribe(t),t.attach(n),this.cache.set(e,t)}}(xe`
12256
12277
  .expand-collapse-button {
12257
12278
  left: var(
@@ -12283,8 +12304,8 @@ Ea.subscribe(t),t.attach(n),this.cache.set(e,t)}}(xe`
12283
12304
  transform: rotate(135deg);
12284
12305
  }
12285
12306
  `))
12286
- class BN extends Ao{constructor(){super(...arguments),this.groupSelected=!1}}e([le({attribute:"group-selected",mode:"boolean"})],BN.prototype,"groupSelected",void 0)
12287
- const qN=BN.compose({baseName:"tree-item",baseClass:Ao,template:(e,t)=>Z`
12307
+ class qN extends Ao{constructor(){super(...arguments),this.groupSelected=!1}}e([le({attribute:"group-selected",mode:"boolean"})],qN.prototype,"groupSelected",void 0)
12308
+ const UN=qN.compose({baseName:"tree-item",baseClass:Ao,template:(e,t)=>Z`
12288
12309
  <template
12289
12310
  role="treeitem"
12290
12311
  slot="${e=>e.isNestedItem()?"item":void 0}"
@@ -12324,9 +12345,9 @@ const qN=BN.compose({baseName:"tree-item",baseClass:Ao,template:(e,t)=>Z`
12324
12345
  </div>
12325
12346
  `)}
12326
12347
  </template>
12327
- `,styles:HN,expandCollapseGlyph:$h.data})
12328
- wi.getOrCreate().withPrefix("nimble").register(qN())
12329
- const UN=xe`
12348
+ `,styles:BN,expandCollapseGlyph:$h.data})
12349
+ wi.getOrCreate().withPrefix("nimble").register(UN())
12350
+ const jN=xe`
12330
12351
  ${Oo("flex")}
12331
12352
 
12332
12353
  :host {
@@ -12338,7 +12359,7 @@ const UN=xe`
12338
12359
  :host(${No}) {
12339
12360
  outline: none;
12340
12361
  }
12341
- `,jN=Z`
12362
+ `,WN=Z`
12342
12363
  <template
12343
12364
  role="tree"
12344
12365
  ${Pe("treeView")}
@@ -12352,246 +12373,246 @@ const UN=xe`
12352
12373
  <slot ${Ye("slottedTreeItems")}></slot>
12353
12374
  </template>
12354
12375
  `
12355
- class WN extends To{constructor(){super(...arguments),this.selectionMode=PN,this.selectedItems=[]}handleClick(e){if(e.defaultPrevented)return!1
12376
+ class ZN extends To{constructor(){super(...arguments),this.selectionMode=LN,this.selectedItems=[]}handleClick(e){if(e.defaultPrevented)return!1
12356
12377
  if(!(e.target instanceof Element&&Do(e.target)))return!0
12357
12378
  const t=e.target
12358
- return!t.disabled&&(this.canSelect(t)?t.selected=!0:this.itemHasChildren(t)&&(t.expanded=!t.expanded),!0)}canSelect(e){switch(this.selectionMode){case PN:return!0
12359
- case zN:return!1
12360
- case LN:return!this.itemHasChildren(e)
12361
- default:return!0}}itemHasChildren(e){return null!==e.querySelector('[role="treeitem"]')}selectedItemsChanged(){for(const e of Array.from(this.children))e instanceof BN&&(e.groupSelected=!1)
12379
+ return!t.disabled&&(this.canSelect(t)?t.selected=!0:this.itemHasChildren(t)&&(t.expanded=!t.expanded),!0)}canSelect(e){switch(this.selectionMode){case LN:return!0
12380
+ case VN:return!1
12381
+ case zN:return!this.itemHasChildren(e)
12382
+ default:return!0}}itemHasChildren(e){return null!==e.querySelector('[role="treeitem"]')}selectedItemsChanged(){for(const e of Array.from(this.children))e instanceof qN&&(e.groupSelected=!1)
12362
12383
  for(let e of this.selectedItems){for(;null!==e.parentElement&&e.parentElement!==this;)e=e.parentElement
12363
- e instanceof BN&&(e.groupSelected=!0)}}}e([le({attribute:"selection-mode"})],WN.prototype,"selectionMode",void 0),e([g],WN.prototype,"selectedItems",void 0)
12364
- const ZN=WN.compose({baseName:"tree-view",baseClass:To,template:jN,styles:UN})
12365
- wi.getOrCreate().withPrefix("nimble").register(ZN())
12366
- const GN=Z`<template slot="unit"></template>`
12367
- class KN{constructor(e,t,n){this.singular=e,this.plural=t,this.symbol=n}}class XN extends EF{constructor(e,{unitTranslations:t,scaledPrefixText:n}){if(super(e),!t.get("en"))throw new Error('English translations must exist with locale string "en"')
12368
- this.pluralRules=new Intl.PluralRules(this.locale),this.formatter=new Intl.NumberFormat(this.locale,this.intlNumberFormatOptions),this.unitTranslation=this.getTranslationToUse(t,this.locale),this.scaledPrefixText=n}static createFactory(e){return t=>new XN(t,e)}format(e){const t=this.formatter.format(e)
12384
+ e instanceof qN&&(e.groupSelected=!0)}}}e([le({attribute:"selection-mode"})],ZN.prototype,"selectionMode",void 0),e([g],ZN.prototype,"selectedItems",void 0)
12385
+ const GN=ZN.compose({baseName:"tree-view",baseClass:To,template:WN,styles:jN})
12386
+ wi.getOrCreate().withPrefix("nimble").register(GN())
12387
+ const KN=Z`<template slot="unit"></template>`
12388
+ class XN{constructor(e,t,n){this.singular=e,this.plural=t,this.symbol=n}}class YN extends EF{constructor(e,{unitTranslations:t,scaledPrefixText:n}){if(super(e),!t.get("en"))throw new Error('English translations must exist with locale string "en"')
12389
+ this.pluralRules=new Intl.PluralRules(this.locale),this.formatter=new Intl.NumberFormat(this.locale,this.intlNumberFormatOptions),this.unitTranslation=this.getTranslationToUse(t,this.locale),this.scaledPrefixText=n}static createFactory(e){return t=>new YN(t,e)}format(e){const t=this.formatter.format(e)
12369
12390
  if(""!==this.scaledPrefixText)return`${t} ${this.scaledPrefixText}${this.unitTranslation.symbol}`
12370
12391
  return`${t} ${"one"===this.pluralRules.select(e)?this.unitTranslation.singular:this.unitTranslation.plural}`}getTranslationToUse(e,t){const n=new Intl.Locale(t??"en"),i=n.language,o=n.region
12371
- return(o?e.get(`${i}-${o}`):void 0)??e.get(i)??e.get("en")}}const YN=new Map([["en",new KN("byte","bytes","B")],["fr",new KN("octet","octets","o")],["de",new KN("Byte","Byte","B")],["ja",new KN("バイト","バイト","B")],["zh",new KN("字节","字节","B")]]),JN=[[1,""],[1024,"Ki"],[1048576,"Mi"],[1024**3,"Gi"],[1024**4,"Ti"],[1024**5,"Pi"]]
12372
- const QN=new class extends AF{constructor(){super(JN.map((([e,t])=>new DF(e,XN.createFactory({unitTranslations:YN,scaledPrefixText:t})))))}},eP=[[1,"byte","long"],[1e3,"kilobyte","short"],[1e6,"megabyte","short"],[1e3**3,"gigabyte","short"],[1e3**4,"terabyte","short"],[1e3**5,"petabyte","short"]]
12373
- const tP=new class extends AF{constructor(){super(eP.map((([e,t,n])=>new DF(e,IF.createFactory({style:"unit",unit:t,unitDisplay:n})))))}}
12374
- class nP extends zF{constructor(){super(),this.binary=!1,this.resolvedUnitScale=tP}binaryChanged(){this.resolvedUnitScale=this.binary?QN:tP}}e([le({mode:"boolean"})],nP.prototype,"binary",void 0)
12375
- const iP=nP.compose({baseName:"unit-byte",template:GN})
12376
- wi.getOrCreate().withPrefix("nimble").register(iP())
12377
- const oP=[[1e-15,"f"],[1e-12,"p"],[1e-9,"n"],[10**-6,"μ"],[.001,"m"],[.01,"c"],[.1,"d"],[1,""],[1e3,"k"],[10**6,"M"],[10**9,"G"],[10**12,"T"],[10**15,"P"],[10**18,"E"]],rP=new Map([["en",new KN("volt","volts","V")],["fr",new KN("volt","volts","V")],["de",new KN("Volt","Volt","V")],["ja",new KN("ボルト","ボルト","V")],["zh",new KN("伏特","伏特","V")]])
12378
- const sP=new class extends AF{constructor(){super(oP.map((([e,t])=>new DF(e,XN.createFactory({unitTranslations:rP,scaledPrefixText:t})))))}}
12379
- const aP=class extends zF{constructor(){super(),this.resolvedUnitScale=sP}}.compose({baseName:"unit-volt",template:GN})
12380
- wi.getOrCreate().withPrefix("nimble").register(aP())
12381
- var lP={value:()=>{}}
12382
- function cP(){for(var e,t=0,n=arguments.length,i={};t<n;++t){if(!(e=arguments[t]+"")||e in i||/[\s.]/.test(e))throw new Error("illegal type: "+e)
12383
- i[e]=[]}return new dP(i)}function dP(e){this._=e}function hP(e,t){for(var n,i=0,o=e.length;i<o;++i)if((n=e[i]).name===t)return n.value}function uP(e,t,n){for(var i=0,o=e.length;i<o;++i)if(e[i].name===t){e[i]=lP,e=e.slice(0,i).concat(e.slice(i+1))
12384
- break}return null!=n&&e.push({name:t,value:n}),e}dP.prototype=cP.prototype={constructor:dP,on:function(e,t){var n,i,o=this._,r=(i=o,(e+"").trim().split(/^|\s+/).map((function(e){var t="",n=e.indexOf(".")
12392
+ return(o?e.get(`${i}-${o}`):void 0)??e.get(i)??e.get("en")}}const JN=new Map([["en",new XN("byte","bytes","B")],["fr",new XN("octet","octets","o")],["de",new XN("Byte","Byte","B")],["ja",new XN("バイト","バイト","B")],["zh",new XN("字节","字节","B")]]),QN=[[1,""],[1024,"Ki"],[1048576,"Mi"],[1024**3,"Gi"],[1024**4,"Ti"],[1024**5,"Pi"]]
12393
+ const eP=new class extends AF{constructor(){super(QN.map((([e,t])=>new DF(e,YN.createFactory({unitTranslations:JN,scaledPrefixText:t})))))}},tP=[[1,"byte","long"],[1e3,"kilobyte","short"],[1e6,"megabyte","short"],[1e3**3,"gigabyte","short"],[1e3**4,"terabyte","short"],[1e3**5,"petabyte","short"]]
12394
+ const nP=new class extends AF{constructor(){super(tP.map((([e,t,n])=>new DF(e,IF.createFactory({style:"unit",unit:t,unitDisplay:n})))))}}
12395
+ class iP extends zF{constructor(){super(),this.binary=!1,this.resolvedUnitScale=nP}binaryChanged(){this.resolvedUnitScale=this.binary?eP:nP}}e([le({mode:"boolean"})],iP.prototype,"binary",void 0)
12396
+ const oP=iP.compose({baseName:"unit-byte",template:KN})
12397
+ wi.getOrCreate().withPrefix("nimble").register(oP())
12398
+ const rP=[[1e-15,"f"],[1e-12,"p"],[1e-9,"n"],[10**-6,"μ"],[.001,"m"],[.01,"c"],[.1,"d"],[1,""],[1e3,"k"],[10**6,"M"],[10**9,"G"],[10**12,"T"],[10**15,"P"],[10**18,"E"]],sP=new Map([["en",new XN("volt","volts","V")],["fr",new XN("volt","volts","V")],["de",new XN("Volt","Volt","V")],["ja",new XN("ボルト","ボルト","V")],["zh",new XN("伏特","伏特","V")]])
12399
+ const aP=new class extends AF{constructor(){super(rP.map((([e,t])=>new DF(e,YN.createFactory({unitTranslations:sP,scaledPrefixText:t})))))}}
12400
+ const lP=class extends zF{constructor(){super(),this.resolvedUnitScale=aP}}.compose({baseName:"unit-volt",template:KN})
12401
+ wi.getOrCreate().withPrefix("nimble").register(lP())
12402
+ var cP={value:()=>{}}
12403
+ function dP(){for(var e,t=0,n=arguments.length,i={};t<n;++t){if(!(e=arguments[t]+"")||e in i||/[\s.]/.test(e))throw new Error("illegal type: "+e)
12404
+ i[e]=[]}return new hP(i)}function hP(e){this._=e}function uP(e,t){for(var n,i=0,o=e.length;i<o;++i)if((n=e[i]).name===t)return n.value}function pP(e,t,n){for(var i=0,o=e.length;i<o;++i)if(e[i].name===t){e[i]=cP,e=e.slice(0,i).concat(e.slice(i+1))
12405
+ break}return null!=n&&e.push({name:t,value:n}),e}hP.prototype=dP.prototype={constructor:hP,on:function(e,t){var n,i,o=this._,r=(i=o,(e+"").trim().split(/^|\s+/).map((function(e){var t="",n=e.indexOf(".")
12385
12406
  if(n>=0&&(t=e.slice(n+1),e=e.slice(0,n)),e&&!i.hasOwnProperty(e))throw new Error("unknown type: "+e)
12386
12407
  return{type:e,name:t}}))),s=-1,a=r.length
12387
12408
  if(!(arguments.length<2)){if(null!=t&&"function"!=typeof t)throw new Error("invalid callback: "+t)
12388
- for(;++s<a;)if(n=(e=r[s]).type)o[n]=uP(o[n],e.name,t)
12389
- else if(null==t)for(n in o)o[n]=uP(o[n],e.name,null)
12390
- return this}for(;++s<a;)if((n=(e=r[s]).type)&&(n=hP(o[n],e.name)))return n},copy:function(){var e={},t=this._
12409
+ for(;++s<a;)if(n=(e=r[s]).type)o[n]=pP(o[n],e.name,t)
12410
+ else if(null==t)for(n in o)o[n]=pP(o[n],e.name,null)
12411
+ return this}for(;++s<a;)if((n=(e=r[s]).type)&&(n=uP(o[n],e.name)))return n},copy:function(){var e={},t=this._
12391
12412
  for(var n in t)e[n]=t[n].slice()
12392
- return new dP(e)},call:function(e,t){if((n=arguments.length-2)>0)for(var n,i,o=new Array(n),r=0;r<n;++r)o[r]=arguments[r+2]
12413
+ return new hP(e)},call:function(e,t){if((n=arguments.length-2)>0)for(var n,i,o=new Array(n),r=0;r<n;++r)o[r]=arguments[r+2]
12393
12414
  if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e)
12394
12415
  for(r=0,n=(i=this._[e]).length;r<n;++r)i[r].value.apply(t,o)},apply:function(e,t,n){if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e)
12395
12416
  for(var i=this._[e],o=0,r=i.length;o<r;++o)i[o].value.apply(t,n)}}
12396
- var pP="http://www.w3.org/1999/xhtml",fP={svg:"http://www.w3.org/2000/svg",xhtml:pP,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"}
12397
- function mP(e){var t=e+="",n=t.indexOf(":")
12398
- return n>=0&&"xmlns"!==(t=e.slice(0,n))&&(e=e.slice(n+1)),fP.hasOwnProperty(t)?{space:fP[t],local:e}:e}function gP(e){return function(){var t=this.ownerDocument,n=this.namespaceURI
12399
- return n===pP&&t.documentElement.namespaceURI===pP?t.createElement(e):t.createElementNS(n,e)}}function vP(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function bP(e){var t=mP(e)
12400
- return(t.local?vP:gP)(t)}function yP(){}function wP(e){return null==e?yP:function(){return this.querySelector(e)}}function xP(){return[]}function CP(e){return null==e?xP:function(){return this.querySelectorAll(e)}}function kP(e){return function(){return null==(t=e.apply(this,arguments))?[]:Array.isArray(t)?t:Array.from(t)
12401
- var t}}function SP(e){return function(){return this.matches(e)}}function $P(e){return function(t){return t.matches(e)}}var MP=Array.prototype.find
12402
- function _P(){return this.firstElementChild}var EP=Array.prototype.filter
12403
- function IP(){return Array.from(this.children)}function DP(e){return new Array(e.length)}function AP(e,t){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=t}function TP(e,t,n,i,o,r){for(var s,a=0,l=t.length,c=r.length;a<c;++a)(s=t[a])?(s.__data__=r[a],i[a]=s):n[a]=new AP(e,r[a])
12404
- for(;a<l;++a)(s=t[a])&&(o[a]=s)}function OP(e,t,n,i,o,r,s){var a,l,c,d=new Map,h=t.length,u=r.length,p=new Array(h)
12417
+ var fP="http://www.w3.org/1999/xhtml",mP={svg:"http://www.w3.org/2000/svg",xhtml:fP,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"}
12418
+ function gP(e){var t=e+="",n=t.indexOf(":")
12419
+ return n>=0&&"xmlns"!==(t=e.slice(0,n))&&(e=e.slice(n+1)),mP.hasOwnProperty(t)?{space:mP[t],local:e}:e}function vP(e){return function(){var t=this.ownerDocument,n=this.namespaceURI
12420
+ return n===fP&&t.documentElement.namespaceURI===fP?t.createElement(e):t.createElementNS(n,e)}}function bP(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function yP(e){var t=gP(e)
12421
+ return(t.local?bP:vP)(t)}function wP(){}function xP(e){return null==e?wP:function(){return this.querySelector(e)}}function CP(){return[]}function kP(e){return null==e?CP:function(){return this.querySelectorAll(e)}}function SP(e){return function(){return null==(t=e.apply(this,arguments))?[]:Array.isArray(t)?t:Array.from(t)
12422
+ var t}}function $P(e){return function(){return this.matches(e)}}function MP(e){return function(t){return t.matches(e)}}var _P=Array.prototype.find
12423
+ function EP(){return this.firstElementChild}var IP=Array.prototype.filter
12424
+ function DP(){return Array.from(this.children)}function AP(e){return new Array(e.length)}function TP(e,t){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=t}function OP(e,t,n,i,o,r){for(var s,a=0,l=t.length,c=r.length;a<c;++a)(s=t[a])?(s.__data__=r[a],i[a]=s):n[a]=new TP(e,r[a])
12425
+ for(;a<l;++a)(s=t[a])&&(o[a]=s)}function RP(e,t,n,i,o,r,s){var a,l,c,d=new Map,h=t.length,u=r.length,p=new Array(h)
12405
12426
  for(a=0;a<h;++a)(l=t[a])&&(p[a]=c=s.call(l,l.__data__,a,t)+"",d.has(c)?o[a]=l:d.set(c,l))
12406
- for(a=0;a<u;++a)c=s.call(e,r[a],a,r)+"",(l=d.get(c))?(i[a]=l,l.__data__=r[a],d.delete(c)):n[a]=new AP(e,r[a])
12407
- for(a=0;a<h;++a)(l=t[a])&&d.get(p[a])===l&&(o[a]=l)}function RP(e){return e.__data__}function FP(e){return"object"==typeof e&&"length"in e?e:Array.from(e)}function NP(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}function PP(e){return function(){this.removeAttribute(e)}}function LP(e){return function(){this.removeAttributeNS(e.space,e.local)}}function zP(e,t){return function(){this.setAttribute(e,t)}}function VP(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function HP(e,t){return function(){var n=t.apply(this,arguments)
12408
- null==n?this.removeAttribute(e):this.setAttribute(e,n)}}function BP(e,t){return function(){var n=t.apply(this,arguments)
12409
- null==n?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,n)}}function qP(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function UP(e){return function(){this.style.removeProperty(e)}}function jP(e,t,n){return function(){this.style.setProperty(e,t,n)}}function WP(e,t,n){return function(){var i=t.apply(this,arguments)
12410
- null==i?this.style.removeProperty(e):this.style.setProperty(e,i,n)}}function ZP(e,t){return e.style.getPropertyValue(t)||qP(e).getComputedStyle(e,null).getPropertyValue(t)}function GP(e){return function(){delete this[e]}}function KP(e,t){return function(){this[e]=t}}function XP(e,t){return function(){var n=t.apply(this,arguments)
12411
- null==n?delete this[e]:this[e]=n}}function YP(e){return e.trim().split(/^|\s+/)}function JP(e){return e.classList||new QP(e)}function QP(e){this._node=e,this._names=YP(e.getAttribute("class")||"")}function eL(e,t){for(var n=JP(e),i=-1,o=t.length;++i<o;)n.add(t[i])}function tL(e,t){for(var n=JP(e),i=-1,o=t.length;++i<o;)n.remove(t[i])}function nL(e){return function(){eL(this,e)}}function iL(e){return function(){tL(this,e)}}function oL(e,t){return function(){(t.apply(this,arguments)?eL:tL)(this,e)}}function rL(){this.textContent=""}function sL(e){return function(){this.textContent=e}}function aL(e){return function(){var t=e.apply(this,arguments)
12412
- this.textContent=null==t?"":t}}function lL(){this.innerHTML=""}function cL(e){return function(){this.innerHTML=e}}function dL(e){return function(){var t=e.apply(this,arguments)
12413
- this.innerHTML=null==t?"":t}}function hL(){this.nextSibling&&this.parentNode.appendChild(this)}function uL(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function pL(){return null}function fL(){var e=this.parentNode
12414
- e&&e.removeChild(this)}function mL(){var e=this.cloneNode(!1),t=this.parentNode
12415
- return t?t.insertBefore(e,this.nextSibling):e}function gL(){var e=this.cloneNode(!0),t=this.parentNode
12416
- return t?t.insertBefore(e,this.nextSibling):e}function vL(e){return function(){var t=this.__on
12417
- if(t){for(var n,i=0,o=-1,r=t.length;i<r;++i)n=t[i],e.type&&n.type!==e.type||n.name!==e.name?t[++o]=n:this.removeEventListener(n.type,n.listener,n.options);++o?t.length=o:delete this.__on}}}function bL(e,t,n){return function(){var i,o=this.__on,r=function(e){return function(t){e.call(this,t,this.__data__)}}(t)
12427
+ for(a=0;a<u;++a)c=s.call(e,r[a],a,r)+"",(l=d.get(c))?(i[a]=l,l.__data__=r[a],d.delete(c)):n[a]=new TP(e,r[a])
12428
+ for(a=0;a<h;++a)(l=t[a])&&d.get(p[a])===l&&(o[a]=l)}function FP(e){return e.__data__}function NP(e){return"object"==typeof e&&"length"in e?e:Array.from(e)}function PP(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}function LP(e){return function(){this.removeAttribute(e)}}function zP(e){return function(){this.removeAttributeNS(e.space,e.local)}}function VP(e,t){return function(){this.setAttribute(e,t)}}function HP(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function BP(e,t){return function(){var n=t.apply(this,arguments)
12429
+ null==n?this.removeAttribute(e):this.setAttribute(e,n)}}function qP(e,t){return function(){var n=t.apply(this,arguments)
12430
+ null==n?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,n)}}function UP(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function jP(e){return function(){this.style.removeProperty(e)}}function WP(e,t,n){return function(){this.style.setProperty(e,t,n)}}function ZP(e,t,n){return function(){var i=t.apply(this,arguments)
12431
+ null==i?this.style.removeProperty(e):this.style.setProperty(e,i,n)}}function GP(e,t){return e.style.getPropertyValue(t)||UP(e).getComputedStyle(e,null).getPropertyValue(t)}function KP(e){return function(){delete this[e]}}function XP(e,t){return function(){this[e]=t}}function YP(e,t){return function(){var n=t.apply(this,arguments)
12432
+ null==n?delete this[e]:this[e]=n}}function JP(e){return e.trim().split(/^|\s+/)}function QP(e){return e.classList||new eL(e)}function eL(e){this._node=e,this._names=JP(e.getAttribute("class")||"")}function tL(e,t){for(var n=QP(e),i=-1,o=t.length;++i<o;)n.add(t[i])}function nL(e,t){for(var n=QP(e),i=-1,o=t.length;++i<o;)n.remove(t[i])}function iL(e){return function(){tL(this,e)}}function oL(e){return function(){nL(this,e)}}function rL(e,t){return function(){(t.apply(this,arguments)?tL:nL)(this,e)}}function sL(){this.textContent=""}function aL(e){return function(){this.textContent=e}}function lL(e){return function(){var t=e.apply(this,arguments)
12433
+ this.textContent=null==t?"":t}}function cL(){this.innerHTML=""}function dL(e){return function(){this.innerHTML=e}}function hL(e){return function(){var t=e.apply(this,arguments)
12434
+ this.innerHTML=null==t?"":t}}function uL(){this.nextSibling&&this.parentNode.appendChild(this)}function pL(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function fL(){return null}function mL(){var e=this.parentNode
12435
+ e&&e.removeChild(this)}function gL(){var e=this.cloneNode(!1),t=this.parentNode
12436
+ return t?t.insertBefore(e,this.nextSibling):e}function vL(){var e=this.cloneNode(!0),t=this.parentNode
12437
+ return t?t.insertBefore(e,this.nextSibling):e}function bL(e){return function(){var t=this.__on
12438
+ if(t){for(var n,i=0,o=-1,r=t.length;i<r;++i)n=t[i],e.type&&n.type!==e.type||n.name!==e.name?t[++o]=n:this.removeEventListener(n.type,n.listener,n.options);++o?t.length=o:delete this.__on}}}function yL(e,t,n){return function(){var i,o=this.__on,r=function(e){return function(t){e.call(this,t,this.__data__)}}(t)
12418
12439
  if(o)for(var s=0,a=o.length;s<a;++s)if((i=o[s]).type===e.type&&i.name===e.name)return this.removeEventListener(i.type,i.listener,i.options),this.addEventListener(i.type,i.listener=r,i.options=n),void(i.value=t)
12419
- this.addEventListener(e.type,r,n),i={type:e.type,name:e.name,value:t,listener:r,options:n},o?o.push(i):this.__on=[i]}}function yL(e,t,n){var i=qP(e),o=i.CustomEvent
12420
- "function"==typeof o?o=new o(t,n):(o=i.document.createEvent("Event"),n?(o.initEvent(t,n.bubbles,n.cancelable),o.detail=n.detail):o.initEvent(t,!1,!1)),e.dispatchEvent(o)}function wL(e,t){return function(){return yL(this,e,t)}}function xL(e,t){return function(){return yL(this,e,t.apply(this,arguments))}}AP.prototype={constructor:AP,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}},QP.prototype={add:function(e){this._names.indexOf(e)<0&&(this._names.push(e),this._node.setAttribute("class",this._names.join(" ")))},remove:function(e){var t=this._names.indexOf(e)
12440
+ this.addEventListener(e.type,r,n),i={type:e.type,name:e.name,value:t,listener:r,options:n},o?o.push(i):this.__on=[i]}}function wL(e,t,n){var i=UP(e),o=i.CustomEvent
12441
+ "function"==typeof o?o=new o(t,n):(o=i.document.createEvent("Event"),n?(o.initEvent(t,n.bubbles,n.cancelable),o.detail=n.detail):o.initEvent(t,!1,!1)),e.dispatchEvent(o)}function xL(e,t){return function(){return wL(this,e,t)}}function CL(e,t){return function(){return wL(this,e,t.apply(this,arguments))}}TP.prototype={constructor:TP,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}},eL.prototype={add:function(e){this._names.indexOf(e)<0&&(this._names.push(e),this._node.setAttribute("class",this._names.join(" ")))},remove:function(e){var t=this._names.indexOf(e)
12421
12442
  t>=0&&(this._names.splice(t,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}}
12422
- var CL=[null]
12423
- function kL(e,t){this._groups=e,this._parents=t}function SL(){return new kL([[document.documentElement]],CL)}function $L(e){return"string"==typeof e?new kL([[document.querySelector(e)]],[document.documentElement]):new kL([[e]],CL)}function ML(e,t){if(e=function(e){let t
12443
+ var kL=[null]
12444
+ function SL(e,t){this._groups=e,this._parents=t}function $L(){return new SL([[document.documentElement]],kL)}function ML(e){return"string"==typeof e?new SL([[document.querySelector(e)]],[document.documentElement]):new SL([[e]],kL)}function _L(e,t){if(e=function(e){let t
12424
12445
  for(;t=e.sourceEvent;)e=t
12425
12446
  return e}(e),void 0===t&&(t=e.currentTarget),t){var n=t.ownerSVGElement||t
12426
12447
  if(n.createSVGPoint){var i=n.createSVGPoint()
12427
12448
  return i.x=e.clientX,i.y=e.clientY,[(i=i.matrixTransform(t.getScreenCTM().inverse())).x,i.y]}if(t.getBoundingClientRect){var o=t.getBoundingClientRect()
12428
- return[e.clientX-o.left-t.clientLeft,e.clientY-o.top-t.clientTop]}}return[e.pageX,e.pageY]}kL.prototype=SL.prototype={constructor:kL,select:function(e){"function"!=typeof e&&(e=wP(e))
12449
+ return[e.clientX-o.left-t.clientLeft,e.clientY-o.top-t.clientTop]}}return[e.pageX,e.pageY]}SL.prototype=$L.prototype={constructor:SL,select:function(e){"function"!=typeof e&&(e=xP(e))
12429
12450
  for(var t=this._groups,n=t.length,i=new Array(n),o=0;o<n;++o)for(var r,s,a=t[o],l=a.length,c=i[o]=new Array(l),d=0;d<l;++d)(r=a[d])&&(s=e.call(r,r.__data__,d,a))&&("__data__"in r&&(s.__data__=r.__data__),c[d]=s)
12430
- return new kL(i,this._parents)},selectAll:function(e){e="function"==typeof e?kP(e):CP(e)
12451
+ return new SL(i,this._parents)},selectAll:function(e){e="function"==typeof e?SP(e):kP(e)
12431
12452
  for(var t=this._groups,n=t.length,i=[],o=[],r=0;r<n;++r)for(var s,a=t[r],l=a.length,c=0;c<l;++c)(s=a[c])&&(i.push(e.call(s,s.__data__,c,a)),o.push(s))
12432
- return new kL(i,o)},selectChild:function(e){return this.select(null==e?_P:function(e){return function(){return MP.call(this.children,e)}}("function"==typeof e?e:$P(e)))},selectChildren:function(e){return this.selectAll(null==e?IP:function(e){return function(){return EP.call(this.children,e)}}("function"==typeof e?e:$P(e)))},filter:function(e){"function"!=typeof e&&(e=SP(e))
12453
+ return new SL(i,o)},selectChild:function(e){return this.select(null==e?EP:function(e){return function(){return _P.call(this.children,e)}}("function"==typeof e?e:MP(e)))},selectChildren:function(e){return this.selectAll(null==e?DP:function(e){return function(){return IP.call(this.children,e)}}("function"==typeof e?e:MP(e)))},filter:function(e){"function"!=typeof e&&(e=$P(e))
12433
12454
  for(var t=this._groups,n=t.length,i=new Array(n),o=0;o<n;++o)for(var r,s=t[o],a=s.length,l=i[o]=[],c=0;c<a;++c)(r=s[c])&&e.call(r,r.__data__,c,s)&&l.push(r)
12434
- return new kL(i,this._parents)},data:function(e,t){if(!arguments.length)return Array.from(this,RP)
12435
- var n,i=t?OP:TP,o=this._parents,r=this._groups
12455
+ return new SL(i,this._parents)},data:function(e,t){if(!arguments.length)return Array.from(this,FP)
12456
+ var n,i=t?RP:OP,o=this._parents,r=this._groups
12436
12457
  "function"!=typeof e&&(n=e,e=function(){return n})
12437
- for(var s=r.length,a=new Array(s),l=new Array(s),c=new Array(s),d=0;d<s;++d){var h=o[d],u=r[d],p=u.length,f=FP(e.call(h,h&&h.__data__,d,o)),m=f.length,g=l[d]=new Array(m),v=a[d]=new Array(m)
12458
+ for(var s=r.length,a=new Array(s),l=new Array(s),c=new Array(s),d=0;d<s;++d){var h=o[d],u=r[d],p=u.length,f=NP(e.call(h,h&&h.__data__,d,o)),m=f.length,g=l[d]=new Array(m),v=a[d]=new Array(m)
12438
12459
  i(h,u,g,v,c[d]=new Array(p),f,t)
12439
- for(var b,y,w=0,x=0;w<m;++w)if(b=g[w]){for(w>=x&&(x=w+1);!(y=v[x])&&++x<m;);b._next=y||null}}return(a=new kL(a,o))._enter=l,a._exit=c,a},enter:function(){return new kL(this._enter||this._groups.map(DP),this._parents)},exit:function(){return new kL(this._exit||this._groups.map(DP),this._parents)},join:function(e,t,n){var i=this.enter(),o=this,r=this.exit()
12460
+ for(var b,y,w=0,x=0;w<m;++w)if(b=g[w]){for(w>=x&&(x=w+1);!(y=v[x])&&++x<m;);b._next=y||null}}return(a=new SL(a,o))._enter=l,a._exit=c,a},enter:function(){return new SL(this._enter||this._groups.map(AP),this._parents)},exit:function(){return new SL(this._exit||this._groups.map(AP),this._parents)},join:function(e,t,n){var i=this.enter(),o=this,r=this.exit()
12440
12461
  return"function"==typeof e?(i=e(i))&&(i=i.selection()):i=i.append(e+""),null!=t&&(o=t(o))&&(o=o.selection()),null==n?r.remove():n(r),i&&o?i.merge(o).order():o},merge:function(e){for(var t=e.selection?e.selection():e,n=this._groups,i=t._groups,o=n.length,r=i.length,s=Math.min(o,r),a=new Array(o),l=0;l<s;++l)for(var c,d=n[l],h=i[l],u=d.length,p=a[l]=new Array(u),f=0;f<u;++f)(c=d[f]||h[f])&&(p[f]=c)
12441
12462
  for(;l<o;++l)a[l]=n[l]
12442
- return new kL(a,this._parents)},selection:function(){return this},order:function(){for(var e=this._groups,t=-1,n=e.length;++t<n;)for(var i,o=e[t],r=o.length-1,s=o[r];--r>=0;)(i=o[r])&&(s&&4^i.compareDocumentPosition(s)&&s.parentNode.insertBefore(i,s),s=i)
12443
- return this},sort:function(e){function t(t,n){return t&&n?e(t.__data__,n.__data__):!t-!n}e||(e=NP)
12463
+ return new SL(a,this._parents)},selection:function(){return this},order:function(){for(var e=this._groups,t=-1,n=e.length;++t<n;)for(var i,o=e[t],r=o.length-1,s=o[r];--r>=0;)(i=o[r])&&(s&&4^i.compareDocumentPosition(s)&&s.parentNode.insertBefore(i,s),s=i)
12464
+ return this},sort:function(e){function t(t,n){return t&&n?e(t.__data__,n.__data__):!t-!n}e||(e=PP)
12444
12465
  for(var n=this._groups,i=n.length,o=new Array(i),r=0;r<i;++r){for(var s,a=n[r],l=a.length,c=o[r]=new Array(l),d=0;d<l;++d)(s=a[d])&&(c[d]=s)
12445
- c.sort(t)}return new kL(o,this._parents).order()},call:function(){var e=arguments[0]
12466
+ c.sort(t)}return new SL(o,this._parents).order()},call:function(){var e=arguments[0]
12446
12467
  return arguments[0]=this,e.apply(null,arguments),this},nodes:function(){return Array.from(this)},node:function(){for(var e=this._groups,t=0,n=e.length;t<n;++t)for(var i=e[t],o=0,r=i.length;o<r;++o){var s=i[o]
12447
12468
  if(s)return s}return null},size:function(){let e=0
12448
12469
  for(const t of this)++e
12449
12470
  return e},empty:function(){return!this.node()},each:function(e){for(var t=this._groups,n=0,i=t.length;n<i;++n)for(var o,r=t[n],s=0,a=r.length;s<a;++s)(o=r[s])&&e.call(o,o.__data__,s,r)
12450
- return this},attr:function(e,t){var n=mP(e)
12471
+ return this},attr:function(e,t){var n=gP(e)
12451
12472
  if(arguments.length<2){var i=this.node()
12452
- return n.local?i.getAttributeNS(n.space,n.local):i.getAttribute(n)}return this.each((null==t?n.local?LP:PP:"function"==typeof t?n.local?BP:HP:n.local?VP:zP)(n,t))},style:function(e,t,n){return arguments.length>1?this.each((null==t?UP:"function"==typeof t?WP:jP)(e,t,null==n?"":n)):ZP(this.node(),e)},property:function(e,t){return arguments.length>1?this.each((null==t?GP:"function"==typeof t?XP:KP)(e,t)):this.node()[e]},classed:function(e,t){var n=YP(e+"")
12453
- if(arguments.length<2){for(var i=JP(this.node()),o=-1,r=n.length;++o<r;)if(!i.contains(n[o]))return!1
12454
- return!0}return this.each(("function"==typeof t?oL:t?nL:iL)(n,t))},text:function(e){return arguments.length?this.each(null==e?rL:("function"==typeof e?aL:sL)(e)):this.node().textContent},html:function(e){return arguments.length?this.each(null==e?lL:("function"==typeof e?dL:cL)(e)):this.node().innerHTML},raise:function(){return this.each(hL)},lower:function(){return this.each(uL)},append:function(e){var t="function"==typeof e?e:bP(e)
12455
- return this.select((function(){return this.appendChild(t.apply(this,arguments))}))},insert:function(e,t){var n="function"==typeof e?e:bP(e),i=null==t?pL:"function"==typeof t?t:wP(t)
12456
- return this.select((function(){return this.insertBefore(n.apply(this,arguments),i.apply(this,arguments)||null)}))},remove:function(){return this.each(fL)},clone:function(e){return this.select(e?gL:mL)},datum:function(e){return arguments.length?this.property("__data__",e):this.node().__data__},on:function(e,t,n){var i,o,r=function(e){return e.trim().split(/^|\s+/).map((function(e){var t="",n=e.indexOf(".")
12473
+ return n.local?i.getAttributeNS(n.space,n.local):i.getAttribute(n)}return this.each((null==t?n.local?zP:LP:"function"==typeof t?n.local?qP:BP:n.local?HP:VP)(n,t))},style:function(e,t,n){return arguments.length>1?this.each((null==t?jP:"function"==typeof t?ZP:WP)(e,t,null==n?"":n)):GP(this.node(),e)},property:function(e,t){return arguments.length>1?this.each((null==t?KP:"function"==typeof t?YP:XP)(e,t)):this.node()[e]},classed:function(e,t){var n=JP(e+"")
12474
+ if(arguments.length<2){for(var i=QP(this.node()),o=-1,r=n.length;++o<r;)if(!i.contains(n[o]))return!1
12475
+ return!0}return this.each(("function"==typeof t?rL:t?iL:oL)(n,t))},text:function(e){return arguments.length?this.each(null==e?sL:("function"==typeof e?lL:aL)(e)):this.node().textContent},html:function(e){return arguments.length?this.each(null==e?cL:("function"==typeof e?hL:dL)(e)):this.node().innerHTML},raise:function(){return this.each(uL)},lower:function(){return this.each(pL)},append:function(e){var t="function"==typeof e?e:yP(e)
12476
+ return this.select((function(){return this.appendChild(t.apply(this,arguments))}))},insert:function(e,t){var n="function"==typeof e?e:yP(e),i=null==t?fL:"function"==typeof t?t:xP(t)
12477
+ return this.select((function(){return this.insertBefore(n.apply(this,arguments),i.apply(this,arguments)||null)}))},remove:function(){return this.each(mL)},clone:function(e){return this.select(e?vL:gL)},datum:function(e){return arguments.length?this.property("__data__",e):this.node().__data__},on:function(e,t,n){var i,o,r=function(e){return e.trim().split(/^|\s+/).map((function(e){var t="",n=e.indexOf(".")
12457
12478
  return n>=0&&(t=e.slice(n+1),e=e.slice(0,n)),{type:e,name:t}}))}(e+""),s=r.length
12458
- if(!(arguments.length<2)){for(a=t?bL:vL,i=0;i<s;++i)this.each(a(r[i],t,n))
12479
+ if(!(arguments.length<2)){for(a=t?yL:bL,i=0;i<s;++i)this.each(a(r[i],t,n))
12459
12480
  return this}var a=this.node().__on
12460
- if(a)for(var l,c=0,d=a.length;c<d;++c)for(i=0,l=a[c];i<s;++i)if((o=r[i]).type===l.type&&o.name===l.name)return l.value},dispatch:function(e,t){return this.each(("function"==typeof t?xL:wL)(e,t))},[Symbol.iterator]:function*(){for(var e=this._groups,t=0,n=e.length;t<n;++t)for(var i,o=e[t],r=0,s=o.length;r<s;++r)(i=o[r])&&(yield i)}}
12461
- const _L={capture:!0,passive:!1}
12462
- function EL(e){e.preventDefault(),e.stopImmediatePropagation()}function IL(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function DL(e,t){var n=Object.create(e.prototype)
12481
+ if(a)for(var l,c=0,d=a.length;c<d;++c)for(i=0,l=a[c];i<s;++i)if((o=r[i]).type===l.type&&o.name===l.name)return l.value},dispatch:function(e,t){return this.each(("function"==typeof t?CL:xL)(e,t))},[Symbol.iterator]:function*(){for(var e=this._groups,t=0,n=e.length;t<n;++t)for(var i,o=e[t],r=0,s=o.length;r<s;++r)(i=o[r])&&(yield i)}}
12482
+ const EL={capture:!0,passive:!1}
12483
+ function IL(e){e.preventDefault(),e.stopImmediatePropagation()}function DL(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function AL(e,t){var n=Object.create(e.prototype)
12463
12484
  for(var i in t)n[i]=t[i]
12464
- return n}function AL(){}var TL=.7,OL=1/TL,RL="\\s*([+-]?\\d+)\\s*",FL="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",NL="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",PL=/^#([0-9a-f]{3,8})$/,LL=new RegExp(`^rgb\\(${RL},${RL},${RL}\\)$`),zL=new RegExp(`^rgb\\(${NL},${NL},${NL}\\)$`),VL=new RegExp(`^rgba\\(${RL},${RL},${RL},${FL}\\)$`),HL=new RegExp(`^rgba\\(${NL},${NL},${NL},${FL}\\)$`),BL=new RegExp(`^hsl\\(${FL},${NL},${NL}\\)$`),qL=new RegExp(`^hsla\\(${FL},${NL},${NL},${FL}\\)$`),UL={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074}
12465
- function jL(){return this.rgb().formatHex()}function WL(){return this.rgb().formatRgb()}function ZL(e){var t,n
12466
- return e=(e+"").trim().toLowerCase(),(t=PL.exec(e))?(n=t[1].length,t=parseInt(t[1],16),6===n?GL(t):3===n?new YL(t>>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===n?KL(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===n?KL(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|240&t,((15&t)<<4|15&t)/255):null):(t=LL.exec(e))?new YL(t[1],t[2],t[3],1):(t=zL.exec(e))?new YL(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=VL.exec(e))?KL(t[1],t[2],t[3],t[4]):(t=HL.exec(e))?KL(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=BL.exec(e))?iz(t[1],t[2]/100,t[3]/100,1):(t=qL.exec(e))?iz(t[1],t[2]/100,t[3]/100,t[4]):UL.hasOwnProperty(e)?GL(UL[e]):"transparent"===e?new YL(NaN,NaN,NaN,0):null}function GL(e){return new YL(e>>16&255,e>>8&255,255&e,1)}function KL(e,t,n,i){return i<=0&&(e=t=n=NaN),new YL(e,t,n,i)}function XL(e,t,n,i){return 1===arguments.length?((o=e)instanceof AL||(o=ZL(o)),o?new YL((o=o.rgb()).r,o.g,o.b,o.opacity):new YL):new YL(e,t,n,null==i?1:i)
12467
- var o}function YL(e,t,n,i){this.r=+e,this.g=+t,this.b=+n,this.opacity=+i}function JL(){return`#${nz(this.r)}${nz(this.g)}${nz(this.b)}`}function QL(){const e=ez(this.opacity)
12468
- return`${1===e?"rgb(":"rgba("}${tz(this.r)}, ${tz(this.g)}, ${tz(this.b)}${1===e?")":`, ${e})`}`}function ez(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function tz(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function nz(e){return((e=tz(e))<16?"0":"")+e.toString(16)}function iz(e,t,n,i){return i<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new rz(e,t,n,i)}function oz(e){if(e instanceof rz)return new rz(e.h,e.s,e.l,e.opacity)
12469
- if(e instanceof AL||(e=ZL(e)),!e)return new rz
12470
- if(e instanceof rz)return e
12485
+ return n}function TL(){}var OL=.7,RL=1/OL,FL="\\s*([+-]?\\d+)\\s*",NL="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",PL="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",LL=/^#([0-9a-f]{3,8})$/,zL=new RegExp(`^rgb\\(${FL},${FL},${FL}\\)$`),VL=new RegExp(`^rgb\\(${PL},${PL},${PL}\\)$`),HL=new RegExp(`^rgba\\(${FL},${FL},${FL},${NL}\\)$`),BL=new RegExp(`^rgba\\(${PL},${PL},${PL},${NL}\\)$`),qL=new RegExp(`^hsl\\(${NL},${PL},${PL}\\)$`),UL=new RegExp(`^hsla\\(${NL},${PL},${PL},${NL}\\)$`),jL={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074}
12486
+ function WL(){return this.rgb().formatHex()}function ZL(){return this.rgb().formatRgb()}function GL(e){var t,n
12487
+ return e=(e+"").trim().toLowerCase(),(t=LL.exec(e))?(n=t[1].length,t=parseInt(t[1],16),6===n?KL(t):3===n?new JL(t>>8&15|t>>4&240,t>>4&15|240&t,(15&t)<<4|15&t,1):8===n?XL(t>>24&255,t>>16&255,t>>8&255,(255&t)/255):4===n?XL(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|240&t,((15&t)<<4|15&t)/255):null):(t=zL.exec(e))?new JL(t[1],t[2],t[3],1):(t=VL.exec(e))?new JL(255*t[1]/100,255*t[2]/100,255*t[3]/100,1):(t=HL.exec(e))?XL(t[1],t[2],t[3],t[4]):(t=BL.exec(e))?XL(255*t[1]/100,255*t[2]/100,255*t[3]/100,t[4]):(t=qL.exec(e))?oz(t[1],t[2]/100,t[3]/100,1):(t=UL.exec(e))?oz(t[1],t[2]/100,t[3]/100,t[4]):jL.hasOwnProperty(e)?KL(jL[e]):"transparent"===e?new JL(NaN,NaN,NaN,0):null}function KL(e){return new JL(e>>16&255,e>>8&255,255&e,1)}function XL(e,t,n,i){return i<=0&&(e=t=n=NaN),new JL(e,t,n,i)}function YL(e,t,n,i){return 1===arguments.length?((o=e)instanceof TL||(o=GL(o)),o?new JL((o=o.rgb()).r,o.g,o.b,o.opacity):new JL):new JL(e,t,n,null==i?1:i)
12488
+ var o}function JL(e,t,n,i){this.r=+e,this.g=+t,this.b=+n,this.opacity=+i}function QL(){return`#${iz(this.r)}${iz(this.g)}${iz(this.b)}`}function ez(){const e=tz(this.opacity)
12489
+ return`${1===e?"rgb(":"rgba("}${nz(this.r)}, ${nz(this.g)}, ${nz(this.b)}${1===e?")":`, ${e})`}`}function tz(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function nz(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function iz(e){return((e=nz(e))<16?"0":"")+e.toString(16)}function oz(e,t,n,i){return i<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new sz(e,t,n,i)}function rz(e){if(e instanceof sz)return new sz(e.h,e.s,e.l,e.opacity)
12490
+ if(e instanceof TL||(e=GL(e)),!e)return new sz
12491
+ if(e instanceof sz)return e
12471
12492
  var t=(e=e.rgb()).r/255,n=e.g/255,i=e.b/255,o=Math.min(t,n,i),r=Math.max(t,n,i),s=NaN,a=r-o,l=(r+o)/2
12472
- return a?(s=t===r?(n-i)/a+6*(n<i):n===r?(i-t)/a+2:(t-n)/a+4,a/=l<.5?r+o:2-r-o,s*=60):a=l>0&&l<1?0:s,new rz(s,a,l,e.opacity)}function rz(e,t,n,i){this.h=+e,this.s=+t,this.l=+n,this.opacity=+i}function sz(e){return(e=(e||0)%360)<0?e+360:e}function az(e){return Math.max(0,Math.min(1,e||0))}function lz(e,t,n){return 255*(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)}IL(AL,ZL,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:jL,formatHex:jL,formatHex8:function(){return this.rgb().formatHex8()},formatHsl:function(){return oz(this).formatHsl()},formatRgb:WL,toString:WL}),IL(YL,XL,DL(AL,{brighter(e){return e=null==e?OL:Math.pow(OL,e),new YL(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=null==e?TL:Math.pow(TL,e),new YL(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new YL(tz(this.r),tz(this.g),tz(this.b),ez(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:JL,formatHex:JL,formatHex8:function(){return`#${nz(this.r)}${nz(this.g)}${nz(this.b)}${nz(255*(isNaN(this.opacity)?1:this.opacity))}`},formatRgb:QL,toString:QL})),IL(rz,(function(e,t,n,i){return 1===arguments.length?oz(e):new rz(e,t,n,null==i?1:i)}),DL(AL,{brighter(e){return e=null==e?OL:Math.pow(OL,e),new rz(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=null==e?TL:Math.pow(TL,e),new rz(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+360*(this.h<0),t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,i=n+(n<.5?n:1-n)*t,o=2*n-i
12473
- return new YL(lz(e>=240?e-240:e+120,o,i),lz(e,o,i),lz(e<120?e+240:e-120,o,i),this.opacity)},clamp(){return new rz(sz(this.h),az(this.s),az(this.l),ez(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=ez(this.opacity)
12474
- return`${1===e?"hsl(":"hsla("}${sz(this.h)}, ${100*az(this.s)}%, ${100*az(this.l)}%${1===e?")":`, ${e})`}`}}))
12475
- var cz=e=>()=>e
12476
- function dz(e){return 1==(e=+e)?hz:function(t,n){return n-t?function(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(i){return Math.pow(e+i*t,n)}}(t,n,e):cz(isNaN(t)?n:t)}}function hz(e,t){var n=t-e
12477
- return n?function(e,t){return function(n){return e+n*t}}(e,n):cz(isNaN(e)?t:e)}var uz=function e(t){var n=dz(t)
12478
- function i(e,t){var i=n((e=XL(e)).r,(t=XL(t)).r),o=n(e.g,t.g),r=n(e.b,t.b),s=hz(e.opacity,t.opacity)
12493
+ return a?(s=t===r?(n-i)/a+6*(n<i):n===r?(i-t)/a+2:(t-n)/a+4,a/=l<.5?r+o:2-r-o,s*=60):a=l>0&&l<1?0:s,new sz(s,a,l,e.opacity)}function sz(e,t,n,i){this.h=+e,this.s=+t,this.l=+n,this.opacity=+i}function az(e){return(e=(e||0)%360)<0?e+360:e}function lz(e){return Math.max(0,Math.min(1,e||0))}function cz(e,t,n){return 255*(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)}DL(TL,GL,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:WL,formatHex:WL,formatHex8:function(){return this.rgb().formatHex8()},formatHsl:function(){return rz(this).formatHsl()},formatRgb:ZL,toString:ZL}),DL(JL,YL,AL(TL,{brighter(e){return e=null==e?RL:Math.pow(RL,e),new JL(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=null==e?OL:Math.pow(OL,e),new JL(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new JL(nz(this.r),nz(this.g),nz(this.b),tz(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:QL,formatHex:QL,formatHex8:function(){return`#${iz(this.r)}${iz(this.g)}${iz(this.b)}${iz(255*(isNaN(this.opacity)?1:this.opacity))}`},formatRgb:ez,toString:ez})),DL(sz,(function(e,t,n,i){return 1===arguments.length?rz(e):new sz(e,t,n,null==i?1:i)}),AL(TL,{brighter(e){return e=null==e?RL:Math.pow(RL,e),new sz(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=null==e?OL:Math.pow(OL,e),new sz(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+360*(this.h<0),t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,i=n+(n<.5?n:1-n)*t,o=2*n-i
12494
+ return new JL(cz(e>=240?e-240:e+120,o,i),cz(e,o,i),cz(e<120?e+240:e-120,o,i),this.opacity)},clamp(){return new sz(az(this.h),lz(this.s),lz(this.l),tz(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=tz(this.opacity)
12495
+ return`${1===e?"hsl(":"hsla("}${az(this.h)}, ${100*lz(this.s)}%, ${100*lz(this.l)}%${1===e?")":`, ${e})`}`}}))
12496
+ var dz=e=>()=>e
12497
+ function hz(e){return 1==(e=+e)?uz:function(t,n){return n-t?function(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(i){return Math.pow(e+i*t,n)}}(t,n,e):dz(isNaN(t)?n:t)}}function uz(e,t){var n=t-e
12498
+ return n?function(e,t){return function(n){return e+n*t}}(e,n):dz(isNaN(e)?t:e)}var pz=function e(t){var n=hz(t)
12499
+ function i(e,t){var i=n((e=YL(e)).r,(t=YL(t)).r),o=n(e.g,t.g),r=n(e.b,t.b),s=uz(e.opacity,t.opacity)
12479
12500
  return function(t){return e.r=i(t),e.g=o(t),e.b=r(t),e.opacity=s(t),e+""}}return i.gamma=e,i}(1)
12480
- function pz(e,t){t||(t=[])
12501
+ function fz(e,t){t||(t=[])
12481
12502
  var n,i=e?Math.min(t.length,e.length):0,o=t.slice()
12482
12503
  return function(r){for(n=0;n<i;++n)o[n]=e[n]*(1-r)+t[n]*r
12483
- return o}}function fz(e,t){var n,i=t?t.length:0,o=e?Math.min(i,e.length):0,r=new Array(o),s=new Array(i)
12484
- for(n=0;n<o;++n)r[n]=xz(e[n],t[n])
12504
+ return o}}function mz(e,t){var n,i=t?t.length:0,o=e?Math.min(i,e.length):0,r=new Array(o),s=new Array(i)
12505
+ for(n=0;n<o;++n)r[n]=Cz(e[n],t[n])
12485
12506
  for(;n<i;++n)s[n]=t[n]
12486
12507
  return function(e){for(n=0;n<o;++n)s[n]=r[n](e)
12487
- return s}}function mz(e,t){var n=new Date
12488
- return e=+e,t=+t,function(i){return n.setTime(e*(1-i)+t*i),n}}function gz(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function vz(e,t){var n,i={},o={}
12489
- for(n in null!==e&&"object"==typeof e||(e={}),null!==t&&"object"==typeof t||(t={}),t)n in e?i[n]=xz(e[n],t[n]):o[n]=t[n]
12508
+ return s}}function gz(e,t){var n=new Date
12509
+ return e=+e,t=+t,function(i){return n.setTime(e*(1-i)+t*i),n}}function vz(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}function bz(e,t){var n,i={},o={}
12510
+ for(n in null!==e&&"object"==typeof e||(e={}),null!==t&&"object"==typeof t||(t={}),t)n in e?i[n]=Cz(e[n],t[n]):o[n]=t[n]
12490
12511
  return function(e){for(n in i)o[n]=i[n](e)
12491
- return o}}var bz=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,yz=new RegExp(bz.source,"g")
12492
- function wz(e,t){var n,i,o,r=bz.lastIndex=yz.lastIndex=0,s=-1,a=[],l=[]
12493
- for(e+="",t+="";(n=bz.exec(e))&&(i=yz.exec(t));)(o=i.index)>r&&(o=t.slice(r,o),a[s]?a[s]+=o:a[++s]=o),(n=n[0])===(i=i[0])?a[s]?a[s]+=i:a[++s]=i:(a[++s]=null,l.push({i:s,x:gz(n,i)})),r=yz.lastIndex
12512
+ return o}}var yz=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,wz=new RegExp(yz.source,"g")
12513
+ function xz(e,t){var n,i,o,r=yz.lastIndex=wz.lastIndex=0,s=-1,a=[],l=[]
12514
+ for(e+="",t+="";(n=yz.exec(e))&&(i=wz.exec(t));)(o=i.index)>r&&(o=t.slice(r,o),a[s]?a[s]+=o:a[++s]=o),(n=n[0])===(i=i[0])?a[s]?a[s]+=i:a[++s]=i:(a[++s]=null,l.push({i:s,x:vz(n,i)})),r=wz.lastIndex
12494
12515
  return r<t.length&&(o=t.slice(r),a[s]?a[s]+=o:a[++s]=o),a.length<2?l[0]?function(e){return function(t){return e(t)+""}}(l[0].x):function(e){return function(){return e}}(t):(t=l.length,function(e){for(var n,i=0;i<t;++i)a[(n=l[i]).i]=n.x(e)
12495
- return a.join("")})}function xz(e,t){var n,i,o=typeof t
12496
- return null==t||"boolean"===o?cz(t):("number"===o?gz:"string"===o?(n=ZL(t))?(t=n,uz):wz:t instanceof ZL?uz:t instanceof Date?mz:(i=t,!ArrayBuffer.isView(i)||i instanceof DataView?Array.isArray(t)?fz:"function"!=typeof t.valueOf&&"function"!=typeof t.toString||isNaN(t)?vz:gz:pz))(e,t)}function Cz(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}var kz,Sz=180/Math.PI,$z={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1}
12497
- function Mz(e,t,n,i,o,r){var s,a,l
12498
- return(s=Math.sqrt(e*e+t*t))&&(e/=s,t/=s),(l=e*n+t*i)&&(n-=e*l,i-=t*l),(a=Math.sqrt(n*n+i*i))&&(n/=a,i/=a,l/=a),e*i<t*n&&(e=-e,t=-t,l=-l,s=-s),{translateX:o,translateY:r,rotate:Math.atan2(t,e)*Sz,skewX:Math.atan(l)*Sz,scaleX:s,scaleY:a}}function _z(e,t,n,i){function o(e){return e.length?e.pop()+" ":""}return function(r,s){var a=[],l=[]
12516
+ return a.join("")})}function Cz(e,t){var n,i,o=typeof t
12517
+ return null==t||"boolean"===o?dz(t):("number"===o?vz:"string"===o?(n=GL(t))?(t=n,pz):xz:t instanceof GL?pz:t instanceof Date?gz:(i=t,!ArrayBuffer.isView(i)||i instanceof DataView?Array.isArray(t)?mz:"function"!=typeof t.valueOf&&"function"!=typeof t.toString||isNaN(t)?bz:vz:fz))(e,t)}function kz(e,t){return e=+e,t=+t,function(n){return Math.round(e*(1-n)+t*n)}}var Sz,$z=180/Math.PI,Mz={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1}
12518
+ function _z(e,t,n,i,o,r){var s,a,l
12519
+ return(s=Math.sqrt(e*e+t*t))&&(e/=s,t/=s),(l=e*n+t*i)&&(n-=e*l,i-=t*l),(a=Math.sqrt(n*n+i*i))&&(n/=a,i/=a,l/=a),e*i<t*n&&(e=-e,t=-t,l=-l,s=-s),{translateX:o,translateY:r,rotate:Math.atan2(t,e)*$z,skewX:Math.atan(l)*$z,scaleX:s,scaleY:a}}function Ez(e,t,n,i){function o(e){return e.length?e.pop()+" ":""}return function(r,s){var a=[],l=[]
12499
12520
  return r=e(r),s=e(s),function(e,i,o,r,s,a){if(e!==o||i!==r){var l=s.push("translate(",null,t,null,n)
12500
- a.push({i:l-4,x:gz(e,o)},{i:l-2,x:gz(i,r)})}else(o||r)&&s.push("translate("+o+t+r+n)}(r.translateX,r.translateY,s.translateX,s.translateY,a,l),function(e,t,n,r){e!==t?(e-t>180?t+=360:t-e>180&&(e+=360),r.push({i:n.push(o(n)+"rotate(",null,i)-2,x:gz(e,t)})):t&&n.push(o(n)+"rotate("+t+i)}(r.rotate,s.rotate,a,l),function(e,t,n,r){e!==t?r.push({i:n.push(o(n)+"skewX(",null,i)-2,x:gz(e,t)}):t&&n.push(o(n)+"skewX("+t+i)}(r.skewX,s.skewX,a,l),function(e,t,n,i,r,s){if(e!==n||t!==i){var a=r.push(o(r)+"scale(",null,",",null,")")
12501
- s.push({i:a-4,x:gz(e,n)},{i:a-2,x:gz(t,i)})}else 1===n&&1===i||r.push(o(r)+"scale("+n+","+i+")")}(r.scaleX,r.scaleY,s.scaleX,s.scaleY,a,l),r=s=null,function(e){for(var t,n=-1,i=l.length;++n<i;)a[(t=l[n]).i]=t.x(e)
12502
- return a.join("")}}}var Ez=_z((function(e){const t=new("function"==typeof DOMMatrix?DOMMatrix:WebKitCSSMatrix)(e+"")
12503
- return t.isIdentity?$z:Mz(t.a,t.b,t.c,t.d,t.e,t.f)}),"px, ","px)","deg)"),Iz=_z((function(e){return null==e?$z:(kz||(kz=document.createElementNS("http://www.w3.org/2000/svg","g")),kz.setAttribute("transform",e),(e=kz.transform.baseVal.consolidate())?Mz((e=e.matrix).a,e.b,e.c,e.d,e.e,e.f):$z)}),", ",")",")")
12504
- function Dz(e){return((e=Math.exp(e))+1/e)/2}var Az,Tz,Oz=function e(t,n,i){function o(e,o){var r,s,a=e[0],l=e[1],c=e[2],d=o[0],h=o[1],u=o[2],p=d-a,f=h-l,m=p*p+f*f
12521
+ a.push({i:l-4,x:vz(e,o)},{i:l-2,x:vz(i,r)})}else(o||r)&&s.push("translate("+o+t+r+n)}(r.translateX,r.translateY,s.translateX,s.translateY,a,l),function(e,t,n,r){e!==t?(e-t>180?t+=360:t-e>180&&(e+=360),r.push({i:n.push(o(n)+"rotate(",null,i)-2,x:vz(e,t)})):t&&n.push(o(n)+"rotate("+t+i)}(r.rotate,s.rotate,a,l),function(e,t,n,r){e!==t?r.push({i:n.push(o(n)+"skewX(",null,i)-2,x:vz(e,t)}):t&&n.push(o(n)+"skewX("+t+i)}(r.skewX,s.skewX,a,l),function(e,t,n,i,r,s){if(e!==n||t!==i){var a=r.push(o(r)+"scale(",null,",",null,")")
12522
+ s.push({i:a-4,x:vz(e,n)},{i:a-2,x:vz(t,i)})}else 1===n&&1===i||r.push(o(r)+"scale("+n+","+i+")")}(r.scaleX,r.scaleY,s.scaleX,s.scaleY,a,l),r=s=null,function(e){for(var t,n=-1,i=l.length;++n<i;)a[(t=l[n]).i]=t.x(e)
12523
+ return a.join("")}}}var Iz=Ez((function(e){const t=new("function"==typeof DOMMatrix?DOMMatrix:WebKitCSSMatrix)(e+"")
12524
+ return t.isIdentity?Mz:_z(t.a,t.b,t.c,t.d,t.e,t.f)}),"px, ","px)","deg)"),Dz=Ez((function(e){return null==e?Mz:(Sz||(Sz=document.createElementNS("http://www.w3.org/2000/svg","g")),Sz.setAttribute("transform",e),(e=Sz.transform.baseVal.consolidate())?_z((e=e.matrix).a,e.b,e.c,e.d,e.e,e.f):Mz)}),", ",")",")")
12525
+ function Az(e){return((e=Math.exp(e))+1/e)/2}var Tz,Oz,Rz=function e(t,n,i){function o(e,o){var r,s,a=e[0],l=e[1],c=e[2],d=o[0],h=o[1],u=o[2],p=d-a,f=h-l,m=p*p+f*f
12505
12526
  if(m<1e-12)s=Math.log(u/c)/t,r=function(e){return[a+e*p,l+e*f,c*Math.exp(t*e*s)]}
12506
12527
  else{var g=Math.sqrt(m),v=(u*u-c*c+i*m)/(2*c*n*g),b=(u*u-c*c-i*m)/(2*u*n*g),y=Math.log(Math.sqrt(v*v+1)-v),w=Math.log(Math.sqrt(b*b+1)-b)
12507
- s=(w-y)/t,r=function(e){var i,o=e*s,r=Dz(y),d=c/(n*g)*(r*(i=t*o+y,((i=Math.exp(2*i))-1)/(i+1))-function(e){return((e=Math.exp(e))-1/e)/2}(y))
12508
- return[a+d*p,l+d*f,c*r/Dz(t*o+y)]}}return r.duration=1e3*s*t/Math.SQRT2,r}return o.rho=function(t){var n=Math.max(.001,+t),i=n*n
12509
- return e(n,i,i*i)},o}(Math.SQRT2,2,4),Rz=0,Fz=0,Nz=0,Pz=1e3,Lz=0,zz=0,Vz=0,Hz="object"==typeof performance&&performance.now?performance:Date,Bz="object"==typeof window&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)}
12510
- function qz(){return zz||(Bz(Uz),zz=Hz.now()+Vz)}function Uz(){zz=0}function jz(){this._call=this._time=this._next=null}function Wz(e,t,n){var i=new jz
12511
- return i.restart(e,t,n),i}function Zz(){zz=(Lz=Hz.now())+Vz,Rz=Fz=0
12512
- try{!function(){qz(),++Rz
12513
- for(var e,t=Az;t;)(e=zz-t._time)>=0&&t._call.call(void 0,e),t=t._next;--Rz}()}finally{Rz=0,function(){var e,t,n=Az,i=1/0
12514
- for(;n;)n._call?(i>n._time&&(i=n._time),e=n,n=n._next):(t=n._next,n._next=null,n=e?e._next=t:Az=t)
12515
- Tz=e,Kz(i)}(),zz=0}}function Gz(){var e=Hz.now(),t=e-Lz
12516
- t>Pz&&(Vz-=t,Lz=e)}function Kz(e){Rz||(Fz&&(Fz=clearTimeout(Fz)),e-zz>24?(e<1/0&&(Fz=setTimeout(Zz,e-Hz.now()-Vz)),Nz&&(Nz=clearInterval(Nz))):(Nz||(Lz=Hz.now(),Nz=setInterval(Gz,Pz)),Rz=1,Bz(Zz)))}function Xz(e,t,n){var i=new jz
12517
- return t=null==t?0:+t,i.restart((n=>{i.stop(),e(n+t)}),t,n),i}jz.prototype=Wz.prototype={constructor:jz,restart:function(e,t,n){if("function"!=typeof e)throw new TypeError("callback is not a function")
12518
- n=(null==n?qz():+n)+(null==t?0:+t),this._next||Tz===this||(Tz?Tz._next=this:Az=this,Tz=this),this._call=e,this._time=n,Kz()},stop:function(){this._call&&(this._call=null,this._time=1/0,Kz())}}
12519
- var Yz=cP("start","end","cancel","interrupt"),Jz=[],Qz=0,eV=1,tV=2,nV=3,iV=4,oV=5,rV=6
12520
- function sV(e,t,n,i,o,r){var s=e.__transition
12528
+ s=(w-y)/t,r=function(e){var i,o=e*s,r=Az(y),d=c/(n*g)*(r*(i=t*o+y,((i=Math.exp(2*i))-1)/(i+1))-function(e){return((e=Math.exp(e))-1/e)/2}(y))
12529
+ return[a+d*p,l+d*f,c*r/Az(t*o+y)]}}return r.duration=1e3*s*t/Math.SQRT2,r}return o.rho=function(t){var n=Math.max(.001,+t),i=n*n
12530
+ return e(n,i,i*i)},o}(Math.SQRT2,2,4),Fz=0,Nz=0,Pz=0,Lz=1e3,zz=0,Vz=0,Hz=0,Bz="object"==typeof performance&&performance.now?performance:Date,qz="object"==typeof window&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)}
12531
+ function Uz(){return Vz||(qz(jz),Vz=Bz.now()+Hz)}function jz(){Vz=0}function Wz(){this._call=this._time=this._next=null}function Zz(e,t,n){var i=new Wz
12532
+ return i.restart(e,t,n),i}function Gz(){Vz=(zz=Bz.now())+Hz,Fz=Nz=0
12533
+ try{!function(){Uz(),++Fz
12534
+ for(var e,t=Tz;t;)(e=Vz-t._time)>=0&&t._call.call(void 0,e),t=t._next;--Fz}()}finally{Fz=0,function(){var e,t,n=Tz,i=1/0
12535
+ for(;n;)n._call?(i>n._time&&(i=n._time),e=n,n=n._next):(t=n._next,n._next=null,n=e?e._next=t:Tz=t)
12536
+ Oz=e,Xz(i)}(),Vz=0}}function Kz(){var e=Bz.now(),t=e-zz
12537
+ t>Lz&&(Hz-=t,zz=e)}function Xz(e){Fz||(Nz&&(Nz=clearTimeout(Nz)),e-Vz>24?(e<1/0&&(Nz=setTimeout(Gz,e-Bz.now()-Hz)),Pz&&(Pz=clearInterval(Pz))):(Pz||(zz=Bz.now(),Pz=setInterval(Kz,Lz)),Fz=1,qz(Gz)))}function Yz(e,t,n){var i=new Wz
12538
+ return t=null==t?0:+t,i.restart((n=>{i.stop(),e(n+t)}),t,n),i}Wz.prototype=Zz.prototype={constructor:Wz,restart:function(e,t,n){if("function"!=typeof e)throw new TypeError("callback is not a function")
12539
+ n=(null==n?Uz():+n)+(null==t?0:+t),this._next||Oz===this||(Oz?Oz._next=this:Tz=this,Oz=this),this._call=e,this._time=n,Xz()},stop:function(){this._call&&(this._call=null,this._time=1/0,Xz())}}
12540
+ var Jz=dP("start","end","cancel","interrupt"),Qz=[],eV=0,tV=1,nV=2,iV=3,oV=4,rV=5,sV=6
12541
+ function aV(e,t,n,i,o,r){var s=e.__transition
12521
12542
  if(s){if(n in s)return}else e.__transition={}
12522
12543
  !function(e,t,n){var i,o=e.__transition
12523
- function r(e){n.state=eV,n.timer.restart(s,n.delay,n.time),n.delay<=e&&s(e-n.delay)}function s(r){var c,d,h,u
12524
- if(n.state!==eV)return l()
12525
- for(c in o)if((u=o[c]).name===n.name){if(u.state===nV)return Xz(s)
12526
- u.state===iV?(u.state=rV,u.timer.stop(),u.on.call("interrupt",e,e.__data__,u.index,u.group),delete o[c]):+c<t&&(u.state=rV,u.timer.stop(),u.on.call("cancel",e,e.__data__,u.index,u.group),delete o[c])}if(Xz((function(){n.state===nV&&(n.state=iV,n.timer.restart(a,n.delay,n.time),a(r))})),n.state=tV,n.on.call("start",e,e.__data__,n.index,n.group),n.state===tV){for(n.state=nV,i=new Array(h=n.tween.length),c=0,d=-1;c<h;++c)(u=n.tween[c].value.call(e,e.__data__,n.index,n.group))&&(i[++d]=u)
12527
- i.length=d+1}}function a(t){for(var o=t<n.duration?n.ease.call(null,t/n.duration):(n.timer.restart(l),n.state=oV,1),r=-1,s=i.length;++r<s;)i[r].call(e,o)
12528
- n.state===oV&&(n.on.call("end",e,e.__data__,n.index,n.group),l())}function l(){for(var i in n.state=rV,n.timer.stop(),delete o[t],o)return
12529
- delete e.__transition}o[t]=n,n.timer=Wz(r,0,n.time)}(e,n,{name:t,index:i,group:o,on:Yz,tween:Jz,time:r.time,delay:r.delay,duration:r.duration,ease:r.ease,timer:null,state:Qz})}function aV(e,t){var n=cV(e,t)
12530
- if(n.state>Qz)throw new Error("too late; already scheduled")
12531
- return n}function lV(e,t){var n=cV(e,t)
12532
- if(n.state>nV)throw new Error("too late; already running")
12533
- return n}function cV(e,t){var n=e.__transition
12544
+ function r(e){n.state=tV,n.timer.restart(s,n.delay,n.time),n.delay<=e&&s(e-n.delay)}function s(r){var c,d,h,u
12545
+ if(n.state!==tV)return l()
12546
+ for(c in o)if((u=o[c]).name===n.name){if(u.state===iV)return Yz(s)
12547
+ u.state===oV?(u.state=sV,u.timer.stop(),u.on.call("interrupt",e,e.__data__,u.index,u.group),delete o[c]):+c<t&&(u.state=sV,u.timer.stop(),u.on.call("cancel",e,e.__data__,u.index,u.group),delete o[c])}if(Yz((function(){n.state===iV&&(n.state=oV,n.timer.restart(a,n.delay,n.time),a(r))})),n.state=nV,n.on.call("start",e,e.__data__,n.index,n.group),n.state===nV){for(n.state=iV,i=new Array(h=n.tween.length),c=0,d=-1;c<h;++c)(u=n.tween[c].value.call(e,e.__data__,n.index,n.group))&&(i[++d]=u)
12548
+ i.length=d+1}}function a(t){for(var o=t<n.duration?n.ease.call(null,t/n.duration):(n.timer.restart(l),n.state=rV,1),r=-1,s=i.length;++r<s;)i[r].call(e,o)
12549
+ n.state===rV&&(n.on.call("end",e,e.__data__,n.index,n.group),l())}function l(){for(var i in n.state=sV,n.timer.stop(),delete o[t],o)return
12550
+ delete e.__transition}o[t]=n,n.timer=Zz(r,0,n.time)}(e,n,{name:t,index:i,group:o,on:Jz,tween:Qz,time:r.time,delay:r.delay,duration:r.duration,ease:r.ease,timer:null,state:eV})}function lV(e,t){var n=dV(e,t)
12551
+ if(n.state>eV)throw new Error("too late; already scheduled")
12552
+ return n}function cV(e,t){var n=dV(e,t)
12553
+ if(n.state>iV)throw new Error("too late; already running")
12554
+ return n}function dV(e,t){var n=e.__transition
12534
12555
  if(!n||!(n=n[t]))throw new Error("transition not found")
12535
- return n}function dV(e,t){var n,i,o,r=e.__transition,s=!0
12536
- if(r){for(o in t=null==t?null:t+"",r)(n=r[o]).name===t?(i=n.state>tV&&n.state<oV,n.state=rV,n.timer.stop(),n.on.call(i?"interrupt":"cancel",e,e.__data__,n.index,n.group),delete r[o]):s=!1
12537
- s&&delete e.__transition}}function hV(e,t){var n,i
12538
- return function(){var o=lV(this,e),r=o.tween
12556
+ return n}function hV(e,t){var n,i,o,r=e.__transition,s=!0
12557
+ if(r){for(o in t=null==t?null:t+"",r)(n=r[o]).name===t?(i=n.state>nV&&n.state<rV,n.state=sV,n.timer.stop(),n.on.call(i?"interrupt":"cancel",e,e.__data__,n.index,n.group),delete r[o]):s=!1
12558
+ s&&delete e.__transition}}function uV(e,t){var n,i
12559
+ return function(){var o=cV(this,e),r=o.tween
12539
12560
  if(r!==n)for(var s=0,a=(i=n=r).length;s<a;++s)if(i[s].name===t){(i=i.slice()).splice(s,1)
12540
- break}o.tween=i}}function uV(e,t,n){var i,o
12561
+ break}o.tween=i}}function pV(e,t,n){var i,o
12541
12562
  if("function"!=typeof n)throw new Error
12542
- return function(){var r=lV(this,e),s=r.tween
12563
+ return function(){var r=cV(this,e),s=r.tween
12543
12564
  if(s!==i){o=(i=s).slice()
12544
12565
  for(var a={name:t,value:n},l=0,c=o.length;l<c;++l)if(o[l].name===t){o[l]=a
12545
- break}l===c&&o.push(a)}r.tween=o}}function pV(e,t,n){var i=e._id
12546
- return e.each((function(){var e=lV(this,i);(e.value||(e.value={}))[t]=n.apply(this,arguments)})),function(e){return cV(e,i).value[t]}}function fV(e,t){var n
12547
- return("number"==typeof t?gz:t instanceof ZL?uz:(n=ZL(t))?(t=n,uz):wz)(e,t)}function mV(e){return function(){this.removeAttribute(e)}}function gV(e){return function(){this.removeAttributeNS(e.space,e.local)}}function vV(e,t,n){var i,o,r=n+""
12566
+ break}l===c&&o.push(a)}r.tween=o}}function fV(e,t,n){var i=e._id
12567
+ return e.each((function(){var e=cV(this,i);(e.value||(e.value={}))[t]=n.apply(this,arguments)})),function(e){return dV(e,i).value[t]}}function mV(e,t){var n
12568
+ return("number"==typeof t?vz:t instanceof GL?pz:(n=GL(t))?(t=n,pz):xz)(e,t)}function gV(e){return function(){this.removeAttribute(e)}}function vV(e){return function(){this.removeAttributeNS(e.space,e.local)}}function bV(e,t,n){var i,o,r=n+""
12548
12569
  return function(){var s=this.getAttribute(e)
12549
- return s===r?null:s===i?o:o=t(i=s,n)}}function bV(e,t,n){var i,o,r=n+""
12570
+ return s===r?null:s===i?o:o=t(i=s,n)}}function yV(e,t,n){var i,o,r=n+""
12550
12571
  return function(){var s=this.getAttributeNS(e.space,e.local)
12551
- return s===r?null:s===i?o:o=t(i=s,n)}}function yV(e,t,n){var i,o,r
12572
+ return s===r?null:s===i?o:o=t(i=s,n)}}function wV(e,t,n){var i,o,r
12552
12573
  return function(){var s,a,l=n(this)
12553
12574
  if(null!=l)return(s=this.getAttribute(e))===(a=l+"")?null:s===i&&a===o?r:(o=a,r=t(i=s,l))
12554
- this.removeAttribute(e)}}function wV(e,t,n){var i,o,r
12575
+ this.removeAttribute(e)}}function xV(e,t,n){var i,o,r
12555
12576
  return function(){var s,a,l=n(this)
12556
12577
  if(null!=l)return(s=this.getAttributeNS(e.space,e.local))===(a=l+"")?null:s===i&&a===o?r:(o=a,r=t(i=s,l))
12557
- this.removeAttributeNS(e.space,e.local)}}function xV(e,t){var n,i
12578
+ this.removeAttributeNS(e.space,e.local)}}function CV(e,t){var n,i
12558
12579
  function o(){var o=t.apply(this,arguments)
12559
- return o!==i&&(n=(i=o)&&function(e,t){return function(n){this.setAttributeNS(e.space,e.local,t.call(this,n))}}(e,o)),n}return o._value=t,o}function CV(e,t){var n,i
12580
+ return o!==i&&(n=(i=o)&&function(e,t){return function(n){this.setAttributeNS(e.space,e.local,t.call(this,n))}}(e,o)),n}return o._value=t,o}function kV(e,t){var n,i
12560
12581
  function o(){var o=t.apply(this,arguments)
12561
- return o!==i&&(n=(i=o)&&function(e,t){return function(n){this.setAttribute(e,t.call(this,n))}}(e,o)),n}return o._value=t,o}function kV(e,t){return function(){aV(this,e).delay=+t.apply(this,arguments)}}function SV(e,t){return t=+t,function(){aV(this,e).delay=t}}function $V(e,t){return function(){lV(this,e).duration=+t.apply(this,arguments)}}function MV(e,t){return t=+t,function(){lV(this,e).duration=t}}var _V=SL.prototype.constructor
12562
- function EV(e){return function(){this.style.removeProperty(e)}}var IV=0
12563
- function DV(e,t,n,i){this._groups=e,this._parents=t,this._name=n,this._id=i}function AV(){return++IV}var TV=SL.prototype
12564
- DV.prototype={constructor:DV,select:function(e){var t=this._name,n=this._id
12565
- "function"!=typeof e&&(e=wP(e))
12566
- for(var i=this._groups,o=i.length,r=new Array(o),s=0;s<o;++s)for(var a,l,c=i[s],d=c.length,h=r[s]=new Array(d),u=0;u<d;++u)(a=c[u])&&(l=e.call(a,a.__data__,u,c))&&("__data__"in a&&(l.__data__=a.__data__),h[u]=l,sV(h[u],t,n,u,h,cV(a,n)))
12567
- return new DV(r,this._parents,t,n)},selectAll:function(e){var t=this._name,n=this._id
12568
- "function"!=typeof e&&(e=CP(e))
12569
- for(var i=this._groups,o=i.length,r=[],s=[],a=0;a<o;++a)for(var l,c=i[a],d=c.length,h=0;h<d;++h)if(l=c[h]){for(var u,p=e.call(l,l.__data__,h,c),f=cV(l,n),m=0,g=p.length;m<g;++m)(u=p[m])&&sV(u,t,n,m,p,f)
12570
- r.push(p),s.push(l)}return new DV(r,s,t,n)},selectChild:TV.selectChild,selectChildren:TV.selectChildren,filter:function(e){"function"!=typeof e&&(e=SP(e))
12582
+ return o!==i&&(n=(i=o)&&function(e,t){return function(n){this.setAttribute(e,t.call(this,n))}}(e,o)),n}return o._value=t,o}function SV(e,t){return function(){lV(this,e).delay=+t.apply(this,arguments)}}function $V(e,t){return t=+t,function(){lV(this,e).delay=t}}function MV(e,t){return function(){cV(this,e).duration=+t.apply(this,arguments)}}function _V(e,t){return t=+t,function(){cV(this,e).duration=t}}var EV=$L.prototype.constructor
12583
+ function IV(e){return function(){this.style.removeProperty(e)}}var DV=0
12584
+ function AV(e,t,n,i){this._groups=e,this._parents=t,this._name=n,this._id=i}function TV(){return++DV}var OV=$L.prototype
12585
+ AV.prototype={constructor:AV,select:function(e){var t=this._name,n=this._id
12586
+ "function"!=typeof e&&(e=xP(e))
12587
+ for(var i=this._groups,o=i.length,r=new Array(o),s=0;s<o;++s)for(var a,l,c=i[s],d=c.length,h=r[s]=new Array(d),u=0;u<d;++u)(a=c[u])&&(l=e.call(a,a.__data__,u,c))&&("__data__"in a&&(l.__data__=a.__data__),h[u]=l,aV(h[u],t,n,u,h,dV(a,n)))
12588
+ return new AV(r,this._parents,t,n)},selectAll:function(e){var t=this._name,n=this._id
12589
+ "function"!=typeof e&&(e=kP(e))
12590
+ for(var i=this._groups,o=i.length,r=[],s=[],a=0;a<o;++a)for(var l,c=i[a],d=c.length,h=0;h<d;++h)if(l=c[h]){for(var u,p=e.call(l,l.__data__,h,c),f=dV(l,n),m=0,g=p.length;m<g;++m)(u=p[m])&&aV(u,t,n,m,p,f)
12591
+ r.push(p),s.push(l)}return new AV(r,s,t,n)},selectChild:OV.selectChild,selectChildren:OV.selectChildren,filter:function(e){"function"!=typeof e&&(e=$P(e))
12571
12592
  for(var t=this._groups,n=t.length,i=new Array(n),o=0;o<n;++o)for(var r,s=t[o],a=s.length,l=i[o]=[],c=0;c<a;++c)(r=s[c])&&e.call(r,r.__data__,c,s)&&l.push(r)
12572
- return new DV(i,this._parents,this._name,this._id)},merge:function(e){if(e._id!==this._id)throw new Error
12593
+ return new AV(i,this._parents,this._name,this._id)},merge:function(e){if(e._id!==this._id)throw new Error
12573
12594
  for(var t=this._groups,n=e._groups,i=t.length,o=n.length,r=Math.min(i,o),s=new Array(i),a=0;a<r;++a)for(var l,c=t[a],d=n[a],h=c.length,u=s[a]=new Array(h),p=0;p<h;++p)(l=c[p]||d[p])&&(u[p]=l)
12574
12595
  for(;a<i;++a)s[a]=t[a]
12575
- return new DV(s,this._parents,this._name,this._id)},selection:function(){return new _V(this._groups,this._parents)},transition:function(){for(var e=this._name,t=this._id,n=AV(),i=this._groups,o=i.length,r=0;r<o;++r)for(var s,a=i[r],l=a.length,c=0;c<l;++c)if(s=a[c]){var d=cV(s,t)
12576
- sV(s,e,n,c,a,{time:d.time+d.delay+d.duration,delay:0,duration:d.duration,ease:d.ease})}return new DV(i,this._parents,e,n)},call:TV.call,nodes:TV.nodes,node:TV.node,size:TV.size,empty:TV.empty,each:TV.each,on:function(e,t){var n=this._id
12577
- return arguments.length<2?cV(this.node(),n).on.on(e):this.each(function(e,t,n){var i,o,r=function(e){return(e+"").trim().split(/^|\s+/).every((function(e){var t=e.indexOf(".")
12578
- return t>=0&&(e=e.slice(0,t)),!e||"start"===e}))}(t)?aV:lV
12596
+ return new AV(s,this._parents,this._name,this._id)},selection:function(){return new EV(this._groups,this._parents)},transition:function(){for(var e=this._name,t=this._id,n=TV(),i=this._groups,o=i.length,r=0;r<o;++r)for(var s,a=i[r],l=a.length,c=0;c<l;++c)if(s=a[c]){var d=dV(s,t)
12597
+ aV(s,e,n,c,a,{time:d.time+d.delay+d.duration,delay:0,duration:d.duration,ease:d.ease})}return new AV(i,this._parents,e,n)},call:OV.call,nodes:OV.nodes,node:OV.node,size:OV.size,empty:OV.empty,each:OV.each,on:function(e,t){var n=this._id
12598
+ return arguments.length<2?dV(this.node(),n).on.on(e):this.each(function(e,t,n){var i,o,r=function(e){return(e+"").trim().split(/^|\s+/).every((function(e){var t=e.indexOf(".")
12599
+ return t>=0&&(e=e.slice(0,t)),!e||"start"===e}))}(t)?lV:cV
12579
12600
  return function(){var s=r(this,e),a=s.on
12580
- a!==i&&(o=(i=a).copy()).on(t,n),s.on=o}}(n,e,t))},attr:function(e,t){var n=mP(e),i="transform"===n?Iz:fV
12581
- return this.attrTween(e,"function"==typeof t?(n.local?wV:yV)(n,i,pV(this,"attr."+e,t)):null==t?(n.local?gV:mV)(n):(n.local?bV:vV)(n,i,t))},attrTween:function(e,t){var n="attr."+e
12601
+ a!==i&&(o=(i=a).copy()).on(t,n),s.on=o}}(n,e,t))},attr:function(e,t){var n=gP(e),i="transform"===n?Dz:mV
12602
+ return this.attrTween(e,"function"==typeof t?(n.local?xV:wV)(n,i,fV(this,"attr."+e,t)):null==t?(n.local?vV:gV)(n):(n.local?yV:bV)(n,i,t))},attrTween:function(e,t){var n="attr."+e
12582
12603
  if(arguments.length<2)return(n=this.tween(n))&&n._value
12583
12604
  if(null==t)return this.tween(n,null)
12584
12605
  if("function"!=typeof t)throw new Error
12585
- var i=mP(e)
12586
- return this.tween(n,(i.local?xV:CV)(i,t))},style:function(e,t,n){var i="transform"==(e+="")?Ez:fV
12606
+ var i=gP(e)
12607
+ return this.tween(n,(i.local?CV:kV)(i,t))},style:function(e,t,n){var i="transform"==(e+="")?Iz:mV
12587
12608
  return null==t?this.styleTween(e,function(e,t){var n,i,o
12588
- return function(){var r=ZP(this,e),s=(this.style.removeProperty(e),ZP(this,e))
12589
- return r===s?null:r===n&&s===i?o:o=t(n=r,i=s)}}(e,i)).on("end.style."+e,EV(e)):"function"==typeof t?this.styleTween(e,function(e,t,n){var i,o,r
12590
- return function(){var s=ZP(this,e),a=n(this),l=a+""
12591
- return null==a&&(this.style.removeProperty(e),l=a=ZP(this,e)),s===l?null:s===i&&l===o?r:(o=l,r=t(i=s,a))}}(e,i,pV(this,"style."+e,t))).each(function(e,t){var n,i,o,r,s="style."+t,a="end."+s
12592
- return function(){var l=lV(this,e),c=l.on,d=null==l.value[s]?r||(r=EV(t)):void 0
12609
+ return function(){var r=GP(this,e),s=(this.style.removeProperty(e),GP(this,e))
12610
+ return r===s?null:r===n&&s===i?o:o=t(n=r,i=s)}}(e,i)).on("end.style."+e,IV(e)):"function"==typeof t?this.styleTween(e,function(e,t,n){var i,o,r
12611
+ return function(){var s=GP(this,e),a=n(this),l=a+""
12612
+ return null==a&&(this.style.removeProperty(e),l=a=GP(this,e)),s===l?null:s===i&&l===o?r:(o=l,r=t(i=s,a))}}(e,i,fV(this,"style."+e,t))).each(function(e,t){var n,i,o,r,s="style."+t,a="end."+s
12613
+ return function(){var l=cV(this,e),c=l.on,d=null==l.value[s]?r||(r=IV(t)):void 0
12593
12614
  c===n&&o===d||(i=(n=c).copy()).on(a,o=d),l.on=i}}(this._id,e)):this.styleTween(e,function(e,t,n){var i,o,r=n+""
12594
- return function(){var s=ZP(this,e)
12615
+ return function(){var s=GP(this,e)
12595
12616
  return s===r?null:s===i?o:o=t(i=s,n)}}(e,i,t),n).on("end.style."+e,null)},styleTween:function(e,t,n){var i="style."+(e+="")
12596
12617
  if(arguments.length<2)return(i=this.tween(i))&&i._value
12597
12618
  if(null==t)return this.tween(i,null)
@@ -12599,7 +12620,7 @@ if("function"!=typeof t)throw new Error
12599
12620
  return this.tween(i,function(e,t,n){var i,o
12600
12621
  function r(){var r=t.apply(this,arguments)
12601
12622
  return r!==o&&(i=(o=r)&&function(e,t,n){return function(i){this.style.setProperty(e,t.call(this,i),n)}}(e,r,n)),i}return r._value=t,r}(e,t,null==n?"":n))},text:function(e){return this.tween("text","function"==typeof e?function(e){return function(){var t=e(this)
12602
- this.textContent=null==t?"":t}}(pV(this,"text",e)):function(e){return function(){this.textContent=e}}(null==e?"":e+""))},textTween:function(e){var t="text"
12623
+ this.textContent=null==t?"":t}}(fV(this,"text",e)):function(e){return function(){this.textContent=e}}(null==e?"":e+""))},textTween:function(e){var t="text"
12603
12624
  if(arguments.length<1)return(t=this.tween(t))&&t._value
12604
12625
  if(null==e)return this.tween(t,null)
12605
12626
  if("function"!=typeof e)throw new Error
@@ -12608,59 +12629,59 @@ function i(){var i=e.apply(this,arguments)
12608
12629
  return i!==n&&(t=(n=i)&&function(e){return function(t){this.textContent=e.call(this,t)}}(i)),t}return i._value=e,i}(e))},remove:function(){return this.on("end.remove",function(e){return function(){var t=this.parentNode
12609
12630
  for(var n in this.__transition)if(+n!==e)return
12610
12631
  t&&t.removeChild(this)}}(this._id))},tween:function(e,t){var n=this._id
12611
- if(e+="",arguments.length<2){for(var i,o=cV(this.node(),n).tween,r=0,s=o.length;r<s;++r)if((i=o[r]).name===e)return i.value
12612
- return null}return this.each((null==t?hV:uV)(n,e,t))},delay:function(e){var t=this._id
12613
- return arguments.length?this.each(("function"==typeof e?kV:SV)(t,e)):cV(this.node(),t).delay},duration:function(e){var t=this._id
12614
- return arguments.length?this.each(("function"==typeof e?$V:MV)(t,e)):cV(this.node(),t).duration},ease:function(e){var t=this._id
12632
+ if(e+="",arguments.length<2){for(var i,o=dV(this.node(),n).tween,r=0,s=o.length;r<s;++r)if((i=o[r]).name===e)return i.value
12633
+ return null}return this.each((null==t?uV:pV)(n,e,t))},delay:function(e){var t=this._id
12634
+ return arguments.length?this.each(("function"==typeof e?SV:$V)(t,e)):dV(this.node(),t).delay},duration:function(e){var t=this._id
12635
+ return arguments.length?this.each(("function"==typeof e?MV:_V)(t,e)):dV(this.node(),t).duration},ease:function(e){var t=this._id
12615
12636
  return arguments.length?this.each(function(e,t){if("function"!=typeof t)throw new Error
12616
- return function(){lV(this,e).ease=t}}(t,e)):cV(this.node(),t).ease},easeVarying:function(e){if("function"!=typeof e)throw new Error
12637
+ return function(){cV(this,e).ease=t}}(t,e)):dV(this.node(),t).ease},easeVarying:function(e){if("function"!=typeof e)throw new Error
12617
12638
  return this.each(function(e,t){return function(){var n=t.apply(this,arguments)
12618
12639
  if("function"!=typeof n)throw new Error
12619
- lV(this,e).ease=n}}(this._id,e))},end:function(){var e,t,n=this,i=n._id,o=n.size()
12640
+ cV(this,e).ease=n}}(this._id,e))},end:function(){var e,t,n=this,i=n._id,o=n.size()
12620
12641
  return new Promise((function(r,s){var a={value:s},l={value:function(){0==--o&&r()}}
12621
- n.each((function(){var n=lV(this,i),o=n.on
12622
- o!==e&&((t=(e=o).copy())._.cancel.push(a),t._.interrupt.push(a),t._.end.push(l)),n.on=t})),0===o&&r()}))},[Symbol.iterator]:TV[Symbol.iterator]}
12623
- var OV={time:null,delay:0,duration:250,ease:function(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}}
12624
- function RV(e,t){for(var n;!(n=e.__transition)||!(n=n[t]);)if(!(e=e.parentNode))throw new Error(`transition ${t} not found`)
12625
- return n}SL.prototype.interrupt=function(e){return this.each((function(){dV(this,e)}))},SL.prototype.transition=function(e){var t,n
12626
- e instanceof DV?(t=e._id,e=e._name):(t=AV(),(n=OV).time=qz(),e=null==e?null:e+"")
12627
- for(var i=this._groups,o=i.length,r=0;r<o;++r)for(var s,a=i[r],l=a.length,c=0;c<l;++c)(s=a[c])&&sV(s,e,t,c,a,n||RV(s,t))
12628
- return new DV(i,this._parents,e,t)}
12629
- var FV=e=>()=>e
12630
- function NV(e,{sourceEvent:t,target:n,transform:i,dispatch:o}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},transform:{value:i,enumerable:!0,configurable:!0},_:{value:o}})}function PV(e,t,n){this.k=e,this.x=t,this.y=n}PV.prototype={constructor:PV,scale:function(e){return 1===e?this:new PV(this.k*e,this.x,this.y)},translate:function(e,t){return 0===e&0===t?this:new PV(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}}
12631
- var LV=new PV(1,0,0)
12632
- function zV(e){e.stopImmediatePropagation()}function VV(e){e.preventDefault(),e.stopImmediatePropagation()}function HV(e){return!(e.ctrlKey&&"wheel"!==e.type||e.button)}function BV(){var e=this
12633
- return e instanceof SVGElement?(e=e.ownerSVGElement||e).hasAttribute("viewBox")?[[(e=e.viewBox.baseVal).x,e.y],[e.x+e.width,e.y+e.height]]:[[0,0],[e.width.baseVal.value,e.height.baseVal.value]]:[[0,0],[e.clientWidth,e.clientHeight]]}function qV(){return this.__zoom||LV}function UV(e){return-e.deltaY*(1===e.deltaMode?.05:e.deltaMode?1:.002)*(e.ctrlKey?10:1)}function jV(){return navigator.maxTouchPoints||"ontouchstart"in this}function WV(e,t,n){var i=e.invertX(t[0][0])-n[0][0],o=e.invertX(t[1][0])-n[1][0],r=e.invertY(t[0][1])-n[0][1],s=e.invertY(t[1][1])-n[1][1]
12634
- return e.translate(o>i?(i+o)/2:Math.min(0,i)||Math.max(0,o),s>r?(r+s)/2:Math.min(0,r)||Math.max(0,s))}function ZV(){var e,t,n,i=HV,o=BV,r=WV,s=UV,a=jV,l=[0,1/0],c=[[-1/0,-1/0],[1/0,1/0]],d=250,h=Oz,u=cP("start","zoom","end"),p=500,f=150,m=0,g=10
12635
- function v(e){e.property("__zoom",qV).on("wheel.zoom",S,{passive:!1}).on("mousedown.zoom",$).on("dblclick.zoom",M).filter(a).on("touchstart.zoom",_).on("touchmove.zoom",E).on("touchend.zoom touchcancel.zoom",I).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function b(e,t){return(t=Math.max(l[0],Math.min(l[1],t)))===e.k?e:new PV(t,e.x,e.y)}function y(e,t,n){var i=t[0]-n[0]*e.k,o=t[1]-n[1]*e.k
12636
- return i===e.x&&o===e.y?e:new PV(e.k,i,o)}function w(e){return[(+e[0][0]+ +e[1][0])/2,(+e[0][1]+ +e[1][1])/2]}function x(e,t,n,i){e.on("start.zoom",(function(){C(this,arguments).event(i).start()})).on("interrupt.zoom end.zoom",(function(){C(this,arguments).event(i).end()})).tween("zoom",(function(){var e=this,r=arguments,s=C(e,r).event(i),a=o.apply(e,r),l=null==n?w(a):"function"==typeof n?n.apply(e,r):n,c=Math.max(a[1][0]-a[0][0],a[1][1]-a[0][1]),d=e.__zoom,u="function"==typeof t?t.apply(e,r):t,p=h(d.invert(l).concat(c/d.k),u.invert(l).concat(c/u.k))
12642
+ n.each((function(){var n=cV(this,i),o=n.on
12643
+ o!==e&&((t=(e=o).copy())._.cancel.push(a),t._.interrupt.push(a),t._.end.push(l)),n.on=t})),0===o&&r()}))},[Symbol.iterator]:OV[Symbol.iterator]}
12644
+ var RV={time:null,delay:0,duration:250,ease:function(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}}
12645
+ function FV(e,t){for(var n;!(n=e.__transition)||!(n=n[t]);)if(!(e=e.parentNode))throw new Error(`transition ${t} not found`)
12646
+ return n}$L.prototype.interrupt=function(e){return this.each((function(){hV(this,e)}))},$L.prototype.transition=function(e){var t,n
12647
+ e instanceof AV?(t=e._id,e=e._name):(t=TV(),(n=RV).time=Uz(),e=null==e?null:e+"")
12648
+ for(var i=this._groups,o=i.length,r=0;r<o;++r)for(var s,a=i[r],l=a.length,c=0;c<l;++c)(s=a[c])&&aV(s,e,t,c,a,n||FV(s,t))
12649
+ return new AV(i,this._parents,e,t)}
12650
+ var NV=e=>()=>e
12651
+ function PV(e,{sourceEvent:t,target:n,transform:i,dispatch:o}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},transform:{value:i,enumerable:!0,configurable:!0},_:{value:o}})}function LV(e,t,n){this.k=e,this.x=t,this.y=n}LV.prototype={constructor:LV,scale:function(e){return 1===e?this:new LV(this.k*e,this.x,this.y)},translate:function(e,t){return 0===e&0===t?this:new LV(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}}
12652
+ var zV=new LV(1,0,0)
12653
+ function VV(e){e.stopImmediatePropagation()}function HV(e){e.preventDefault(),e.stopImmediatePropagation()}function BV(e){return!(e.ctrlKey&&"wheel"!==e.type||e.button)}function qV(){var e=this
12654
+ return e instanceof SVGElement?(e=e.ownerSVGElement||e).hasAttribute("viewBox")?[[(e=e.viewBox.baseVal).x,e.y],[e.x+e.width,e.y+e.height]]:[[0,0],[e.width.baseVal.value,e.height.baseVal.value]]:[[0,0],[e.clientWidth,e.clientHeight]]}function UV(){return this.__zoom||zV}function jV(e){return-e.deltaY*(1===e.deltaMode?.05:e.deltaMode?1:.002)*(e.ctrlKey?10:1)}function WV(){return navigator.maxTouchPoints||"ontouchstart"in this}function ZV(e,t,n){var i=e.invertX(t[0][0])-n[0][0],o=e.invertX(t[1][0])-n[1][0],r=e.invertY(t[0][1])-n[0][1],s=e.invertY(t[1][1])-n[1][1]
12655
+ return e.translate(o>i?(i+o)/2:Math.min(0,i)||Math.max(0,o),s>r?(r+s)/2:Math.min(0,r)||Math.max(0,s))}function GV(){var e,t,n,i=BV,o=qV,r=ZV,s=jV,a=WV,l=[0,1/0],c=[[-1/0,-1/0],[1/0,1/0]],d=250,h=Rz,u=dP("start","zoom","end"),p=500,f=150,m=0,g=10
12656
+ function v(e){e.property("__zoom",UV).on("wheel.zoom",S,{passive:!1}).on("mousedown.zoom",$).on("dblclick.zoom",M).filter(a).on("touchstart.zoom",_).on("touchmove.zoom",E).on("touchend.zoom touchcancel.zoom",I).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function b(e,t){return(t=Math.max(l[0],Math.min(l[1],t)))===e.k?e:new LV(t,e.x,e.y)}function y(e,t,n){var i=t[0]-n[0]*e.k,o=t[1]-n[1]*e.k
12657
+ return i===e.x&&o===e.y?e:new LV(e.k,i,o)}function w(e){return[(+e[0][0]+ +e[1][0])/2,(+e[0][1]+ +e[1][1])/2]}function x(e,t,n,i){e.on("start.zoom",(function(){C(this,arguments).event(i).start()})).on("interrupt.zoom end.zoom",(function(){C(this,arguments).event(i).end()})).tween("zoom",(function(){var e=this,r=arguments,s=C(e,r).event(i),a=o.apply(e,r),l=null==n?w(a):"function"==typeof n?n.apply(e,r):n,c=Math.max(a[1][0]-a[0][0],a[1][1]-a[0][1]),d=e.__zoom,u="function"==typeof t?t.apply(e,r):t,p=h(d.invert(l).concat(c/d.k),u.invert(l).concat(c/u.k))
12637
12658
  return function(e){if(1===e)e=u
12638
12659
  else{var t=p(e),n=c/t[2]
12639
- e=new PV(n,l[0]-t[0]*n,l[1]-t[1]*n)}s.zoom(null,e)}}))}function C(e,t,n){return!n&&e.__zooming||new k(e,t)}function k(e,t){this.that=e,this.args=t,this.active=0,this.sourceEvent=null,this.extent=o.apply(e,t),this.taps=0}function S(e,...t){if(i.apply(this,arguments)){var n=C(this,t).event(e),o=this.__zoom,a=Math.max(l[0],Math.min(l[1],o.k*Math.pow(2,s.apply(this,arguments)))),d=ML(e)
12660
+ e=new LV(n,l[0]-t[0]*n,l[1]-t[1]*n)}s.zoom(null,e)}}))}function C(e,t,n){return!n&&e.__zooming||new k(e,t)}function k(e,t){this.that=e,this.args=t,this.active=0,this.sourceEvent=null,this.extent=o.apply(e,t),this.taps=0}function S(e,...t){if(i.apply(this,arguments)){var n=C(this,t).event(e),o=this.__zoom,a=Math.max(l[0],Math.min(l[1],o.k*Math.pow(2,s.apply(this,arguments)))),d=_L(e)
12640
12661
  if(n.wheel)n.mouse[0][0]===d[0]&&n.mouse[0][1]===d[1]||(n.mouse[1]=o.invert(n.mouse[0]=d)),clearTimeout(n.wheel)
12641
12662
  else{if(o.k===a)return
12642
- n.mouse=[d,o.invert(d)],dV(this),n.start()}VV(e),n.wheel=setTimeout((function(){n.wheel=null,n.end()}),f),n.zoom("mouse",r(y(b(o,a),n.mouse[0],n.mouse[1]),n.extent,c))}}function $(e,...t){if(!n&&i.apply(this,arguments)){var o=e.currentTarget,s=C(this,t,!0).event(e),a=$L(e.view).on("mousemove.zoom",(function(e){if(VV(e),!s.moved){var t=e.clientX-d,n=e.clientY-h
12643
- s.moved=t*t+n*n>m}s.event(e).zoom("mouse",r(y(s.that.__zoom,s.mouse[0]=ML(e,o),s.mouse[1]),s.extent,c))}),!0).on("mouseup.zoom",(function(e){a.on("mousemove.zoom mouseup.zoom",null),function(e,t){var n=e.document.documentElement,i=$L(e).on("dragstart.drag",null)
12644
- t&&(i.on("click.drag",EL,_L),setTimeout((function(){i.on("click.drag",null)}),0)),"onselectstart"in n?i.on("selectstart.drag",null):(n.style.MozUserSelect=n.__noselect,delete n.__noselect)}(e.view,s.moved),VV(e),s.event(e).end()}),!0),l=ML(e,o),d=e.clientX,h=e.clientY
12645
- !function(e){var t=e.document.documentElement,n=$L(e).on("dragstart.drag",EL,_L)
12646
- "onselectstart"in t?n.on("selectstart.drag",EL,_L):(t.__noselect=t.style.MozUserSelect,t.style.MozUserSelect="none")}(e.view),zV(e),s.mouse=[l,this.__zoom.invert(l)],dV(this),s.start()}}function M(e,...t){if(i.apply(this,arguments)){var n=this.__zoom,s=ML(e.changedTouches?e.changedTouches[0]:e,this),a=n.invert(s),l=n.k*(e.shiftKey?.5:2),h=r(y(b(n,l),s,a),o.apply(this,t),c)
12647
- VV(e),d>0?$L(this).transition().duration(d).call(x,h,s,e):$L(this).call(v.transform,h,s,e)}}function _(n,...o){if(i.apply(this,arguments)){var r,s,a,l,c=n.touches,d=c.length,h=C(this,o,n.changedTouches.length===d).event(n)
12648
- for(zV(n),s=0;s<d;++s)l=[l=ML(a=c[s],this),this.__zoom.invert(l),a.identifier],h.touch0?h.touch1||h.touch0[2]===l[2]||(h.touch1=l,h.taps=0):(h.touch0=l,r=!0,h.taps=1+!!e)
12649
- e&&(e=clearTimeout(e)),r&&(h.taps<2&&(t=l[0],e=setTimeout((function(){e=null}),p)),dV(this),h.start())}}function E(e,...t){if(this.__zooming){var n,i,o,s,a=C(this,t).event(e),l=e.changedTouches,d=l.length
12650
- for(VV(e),n=0;n<d;++n)o=ML(i=l[n],this),a.touch0&&a.touch0[2]===i.identifier?a.touch0[0]=o:a.touch1&&a.touch1[2]===i.identifier&&(a.touch1[0]=o)
12663
+ n.mouse=[d,o.invert(d)],hV(this),n.start()}HV(e),n.wheel=setTimeout((function(){n.wheel=null,n.end()}),f),n.zoom("mouse",r(y(b(o,a),n.mouse[0],n.mouse[1]),n.extent,c))}}function $(e,...t){if(!n&&i.apply(this,arguments)){var o=e.currentTarget,s=C(this,t,!0).event(e),a=ML(e.view).on("mousemove.zoom",(function(e){if(HV(e),!s.moved){var t=e.clientX-d,n=e.clientY-h
12664
+ s.moved=t*t+n*n>m}s.event(e).zoom("mouse",r(y(s.that.__zoom,s.mouse[0]=_L(e,o),s.mouse[1]),s.extent,c))}),!0).on("mouseup.zoom",(function(e){a.on("mousemove.zoom mouseup.zoom",null),function(e,t){var n=e.document.documentElement,i=ML(e).on("dragstart.drag",null)
12665
+ t&&(i.on("click.drag",IL,EL),setTimeout((function(){i.on("click.drag",null)}),0)),"onselectstart"in n?i.on("selectstart.drag",null):(n.style.MozUserSelect=n.__noselect,delete n.__noselect)}(e.view,s.moved),HV(e),s.event(e).end()}),!0),l=_L(e,o),d=e.clientX,h=e.clientY
12666
+ !function(e){var t=e.document.documentElement,n=ML(e).on("dragstart.drag",IL,EL)
12667
+ "onselectstart"in t?n.on("selectstart.drag",IL,EL):(t.__noselect=t.style.MozUserSelect,t.style.MozUserSelect="none")}(e.view),VV(e),s.mouse=[l,this.__zoom.invert(l)],hV(this),s.start()}}function M(e,...t){if(i.apply(this,arguments)){var n=this.__zoom,s=_L(e.changedTouches?e.changedTouches[0]:e,this),a=n.invert(s),l=n.k*(e.shiftKey?.5:2),h=r(y(b(n,l),s,a),o.apply(this,t),c)
12668
+ HV(e),d>0?ML(this).transition().duration(d).call(x,h,s,e):ML(this).call(v.transform,h,s,e)}}function _(n,...o){if(i.apply(this,arguments)){var r,s,a,l,c=n.touches,d=c.length,h=C(this,o,n.changedTouches.length===d).event(n)
12669
+ for(VV(n),s=0;s<d;++s)l=[l=_L(a=c[s],this),this.__zoom.invert(l),a.identifier],h.touch0?h.touch1||h.touch0[2]===l[2]||(h.touch1=l,h.taps=0):(h.touch0=l,r=!0,h.taps=1+!!e)
12670
+ e&&(e=clearTimeout(e)),r&&(h.taps<2&&(t=l[0],e=setTimeout((function(){e=null}),p)),hV(this),h.start())}}function E(e,...t){if(this.__zooming){var n,i,o,s,a=C(this,t).event(e),l=e.changedTouches,d=l.length
12671
+ for(HV(e),n=0;n<d;++n)o=_L(i=l[n],this),a.touch0&&a.touch0[2]===i.identifier?a.touch0[0]=o:a.touch1&&a.touch1[2]===i.identifier&&(a.touch1[0]=o)
12651
12672
  if(i=a.that.__zoom,a.touch1){var h=a.touch0[0],u=a.touch0[1],p=a.touch1[0],f=a.touch1[1],m=(m=p[0]-h[0])*m+(m=p[1]-h[1])*m,g=(g=f[0]-u[0])*g+(g=f[1]-u[1])*g
12652
12673
  i=b(i,Math.sqrt(m/g)),o=[(h[0]+p[0])/2,(h[1]+p[1])/2],s=[(u[0]+f[0])/2,(u[1]+f[1])/2]}else{if(!a.touch0)return
12653
12674
  o=a.touch0[0],s=a.touch0[1]}a.zoom("touch",r(y(i,o,s),a.extent,c))}}function I(e,...i){if(this.__zooming){var o,r,s=C(this,i).event(e),a=e.changedTouches,l=a.length
12654
- for(zV(e),n&&clearTimeout(n),n=setTimeout((function(){n=null}),p),o=0;o<l;++o)r=a[o],s.touch0&&s.touch0[2]===r.identifier?delete s.touch0:s.touch1&&s.touch1[2]===r.identifier&&delete s.touch1
12675
+ for(VV(e),n&&clearTimeout(n),n=setTimeout((function(){n=null}),p),o=0;o<l;++o)r=a[o],s.touch0&&s.touch0[2]===r.identifier?delete s.touch0:s.touch1&&s.touch1[2]===r.identifier&&delete s.touch1
12655
12676
  if(s.touch1&&!s.touch0&&(s.touch0=s.touch1,delete s.touch1),s.touch0)s.touch0[1]=this.__zoom.invert(s.touch0[0])
12656
- else if(s.end(),2===s.taps&&(r=ML(r,this),Math.hypot(t[0]-r[0],t[1]-r[1])<g)){var c=$L(this).on("dblclick.zoom")
12677
+ else if(s.end(),2===s.taps&&(r=_L(r,this),Math.hypot(t[0]-r[0],t[1]-r[1])<g)){var c=ML(this).on("dblclick.zoom")
12657
12678
  c&&c.apply(this,arguments)}}}return v.transform=function(e,t,n,i){var o=e.selection?e.selection():e
12658
- o.property("__zoom",qV),e!==o?x(e,t,n,i):o.interrupt().each((function(){C(this,arguments).event(i).start().zoom(null,"function"==typeof t?t.apply(this,arguments):t).end()}))},v.scaleBy=function(e,t,n,i){v.scaleTo(e,(function(){return this.__zoom.k*("function"==typeof t?t.apply(this,arguments):t)}),n,i)},v.scaleTo=function(e,t,n,i){v.transform(e,(function(){var e=o.apply(this,arguments),i=this.__zoom,s=null==n?w(e):"function"==typeof n?n.apply(this,arguments):n,a=i.invert(s),l="function"==typeof t?t.apply(this,arguments):t
12679
+ o.property("__zoom",UV),e!==o?x(e,t,n,i):o.interrupt().each((function(){C(this,arguments).event(i).start().zoom(null,"function"==typeof t?t.apply(this,arguments):t).end()}))},v.scaleBy=function(e,t,n,i){v.scaleTo(e,(function(){return this.__zoom.k*("function"==typeof t?t.apply(this,arguments):t)}),n,i)},v.scaleTo=function(e,t,n,i){v.transform(e,(function(){var e=o.apply(this,arguments),i=this.__zoom,s=null==n?w(e):"function"==typeof n?n.apply(this,arguments):n,a=i.invert(s),l="function"==typeof t?t.apply(this,arguments):t
12659
12680
  return r(y(b(i,l),s,a),e,c)}),n,i)},v.translateBy=function(e,t,n,i){v.transform(e,(function(){return r(this.__zoom.translate("function"==typeof t?t.apply(this,arguments):t,"function"==typeof n?n.apply(this,arguments):n),o.apply(this,arguments),c)}),null,i)},v.translateTo=function(e,t,n,i,s){v.transform(e,(function(){var e=o.apply(this,arguments),s=this.__zoom,a=null==i?w(e):"function"==typeof i?i.apply(this,arguments):i
12660
- return r(LV.translate(a[0],a[1]).scale(s.k).translate("function"==typeof t?-t.apply(this,arguments):-t,"function"==typeof n?-n.apply(this,arguments):-n),e,c)}),i,s)},k.prototype={event:function(e){return e&&(this.sourceEvent=e),this},start:function(){return 1==++this.active&&(this.that.__zooming=this,this.emit("start")),this},zoom:function(e,t){return this.mouse&&"mouse"!==e&&(this.mouse[1]=t.invert(this.mouse[0])),this.touch0&&"touch"!==e&&(this.touch0[1]=t.invert(this.touch0[0])),this.touch1&&"touch"!==e&&(this.touch1[1]=t.invert(this.touch1[0])),this.that.__zoom=t,this.emit("zoom"),this},end:function(){return 0==--this.active&&(delete this.that.__zooming,this.emit("end")),this},emit:function(e){var t=$L(this.that).datum()
12661
- u.call(e,this.that,new NV(e,{sourceEvent:this.sourceEvent,target:v,type:e,transform:this.that.__zoom,dispatch:u}),t)}},v.wheelDelta=function(e){return arguments.length?(s="function"==typeof e?e:FV(+e),v):s},v.filter=function(e){return arguments.length?(i="function"==typeof e?e:FV(!!e),v):i},v.touchable=function(e){return arguments.length?(a="function"==typeof e?e:FV(!!e),v):a},v.extent=function(e){return arguments.length?(o="function"==typeof e?e:FV([[+e[0][0],+e[0][1]],[+e[1][0],+e[1][1]]]),v):o},v.scaleExtent=function(e){return arguments.length?(l[0]=+e[0],l[1]=+e[1],v):[l[0],l[1]]},v.translateExtent=function(e){return arguments.length?(c[0][0]=+e[0][0],c[1][0]=+e[1][0],c[0][1]=+e[0][1],c[1][1]=+e[1][1],v):[[c[0][0],c[0][1]],[c[1][0],c[1][1]]]},v.constrain=function(e){return arguments.length?(r=e,v):r},v.duration=function(e){return arguments.length?(d=+e,v):d},v.interpolate=function(e){return arguments.length?(h=e,v):h},v.on=function(){var e=u.on.apply(u,arguments)
12662
- return e===u?v:e},v.clickDistance=function(e){return arguments.length?(m=(e=+e)*e,v):Math.sqrt(m)},v.tapDistance=function(e){return arguments.length?(g=+e,v):g},v}PV.prototype
12663
- const GV=Z`
12681
+ return r(zV.translate(a[0],a[1]).scale(s.k).translate("function"==typeof t?-t.apply(this,arguments):-t,"function"==typeof n?-n.apply(this,arguments):-n),e,c)}),i,s)},k.prototype={event:function(e){return e&&(this.sourceEvent=e),this},start:function(){return 1==++this.active&&(this.that.__zooming=this,this.emit("start")),this},zoom:function(e,t){return this.mouse&&"mouse"!==e&&(this.mouse[1]=t.invert(this.mouse[0])),this.touch0&&"touch"!==e&&(this.touch0[1]=t.invert(this.touch0[0])),this.touch1&&"touch"!==e&&(this.touch1[1]=t.invert(this.touch1[0])),this.that.__zoom=t,this.emit("zoom"),this},end:function(){return 0==--this.active&&(delete this.that.__zooming,this.emit("end")),this},emit:function(e){var t=ML(this.that).datum()
12682
+ u.call(e,this.that,new PV(e,{sourceEvent:this.sourceEvent,target:v,type:e,transform:this.that.__zoom,dispatch:u}),t)}},v.wheelDelta=function(e){return arguments.length?(s="function"==typeof e?e:NV(+e),v):s},v.filter=function(e){return arguments.length?(i="function"==typeof e?e:NV(!!e),v):i},v.touchable=function(e){return arguments.length?(a="function"==typeof e?e:NV(!!e),v):a},v.extent=function(e){return arguments.length?(o="function"==typeof e?e:NV([[+e[0][0],+e[0][1]],[+e[1][0],+e[1][1]]]),v):o},v.scaleExtent=function(e){return arguments.length?(l[0]=+e[0],l[1]=+e[1],v):[l[0],l[1]]},v.translateExtent=function(e){return arguments.length?(c[0][0]=+e[0][0],c[1][0]=+e[1][0],c[0][1]=+e[0][1],c[1][1]=+e[1][1],v):[[c[0][0],c[0][1]],[c[1][0],c[1][1]]]},v.constrain=function(e){return arguments.length?(r=e,v):r},v.duration=function(e){return arguments.length?(d=+e,v):d},v.interpolate=function(e){return arguments.length?(h=e,v):h},v.on=function(){var e=u.on.apply(u,arguments)
12683
+ return e===u?v:e},v.clickDistance=function(e){return arguments.length?(m=(e=+e)*e,v):Math.sqrt(m)},v.tapDistance=function(e){return arguments.length?(g=+e,v):g},v}LV.prototype
12684
+ const KV=Z`
12664
12685
  <div class="wafer-map-container">
12665
12686
  <svg class="svg-root">
12666
12687
  <g ${Pe("zoomContainer")} transform=${e=>e.transform.toString()}>
@@ -12691,7 +12712,7 @@ const GV=Z`
12691
12712
  />
12692
12713
  </svg>
12693
12714
  </div>
12694
- `,KV=xe`
12715
+ `,XV=xe`
12695
12716
  :host {
12696
12717
  display: inline-block;
12697
12718
  width: 500px;
@@ -12780,76 +12801,76 @@ const GV=Z`
12780
12801
  outline-width: 0px;
12781
12802
  }
12782
12803
  `
12783
- function XV(e,t){return null==e||null==t?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function YV(e,t){return null==e||null==t?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function JV(e){let t,n,i
12804
+ function YV(e,t){return null==e||null==t?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function JV(e,t){return null==e||null==t?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function QV(e){let t,n,i
12784
12805
  function o(e,i,o=0,r=e.length){if(o<r){if(0!==t(i,i))return r
12785
12806
  do{const t=o+r>>>1
12786
- n(e[t],i)<0?o=t+1:r=t}while(o<r)}return o}return 2!==e.length?(t=XV,n=(t,n)=>XV(e(t),n),i=(t,n)=>e(t)-n):(t=e===XV||e===YV?e:QV,n=e,i=e),{left:o,center:function(e,t,n=0,r=e.length){const s=o(e,t,n,r-1)
12807
+ n(e[t],i)<0?o=t+1:r=t}while(o<r)}return o}return 2!==e.length?(t=YV,n=(t,n)=>YV(e(t),n),i=(t,n)=>e(t)-n):(t=e===YV||e===JV?e:eH,n=e,i=e),{left:o,center:function(e,t,n=0,r=e.length){const s=o(e,t,n,r-1)
12787
12808
  return s>n&&i(e[s-1],t)>-i(e[s],t)?s-1:s},right:function(e,i,o=0,r=e.length){if(o<r){if(0!==t(i,i))return r
12788
12809
  do{const t=o+r>>>1
12789
- n(e[t],i)<=0?o=t+1:r=t}while(o<r)}return o}}}function QV(){return 0}function eH(e){return null===e?NaN:+e}const tH=JV(XV).right
12790
- JV(eH).center
12791
- class nH extends Map{constructor(e,t=oH){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:t}}),null!=e)for(const[t,n]of e)this.set(t,n)}get(e){return super.get(iH(this,e))}has(e){return super.has(iH(this,e))}set(e,t){return super.set(function({_intern:e,_key:t},n){const i=t(n)
12810
+ n(e[t],i)<=0?o=t+1:r=t}while(o<r)}return o}}}function eH(){return 0}function tH(e){return null===e?NaN:+e}const nH=QV(YV).right
12811
+ QV(tH).center
12812
+ class iH extends Map{constructor(e,t=rH){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:t}}),null!=e)for(const[t,n]of e)this.set(t,n)}get(e){return super.get(oH(this,e))}has(e){return super.has(oH(this,e))}set(e,t){return super.set(function({_intern:e,_key:t},n){const i=t(n)
12792
12813
  return e.has(i)?e.get(i):(e.set(i,n),n)}(this,e),t)}delete(e){return super.delete(function({_intern:e,_key:t},n){const i=t(n)
12793
12814
  e.has(i)&&(n=e.get(i),e.delete(i))
12794
- return n}(this,e))}}function iH({_intern:e,_key:t},n){const i=t(n)
12795
- return e.has(i)?e.get(i):n}function oH(e){return null!==e&&"object"==typeof e?e.valueOf():e}const rH=Math.sqrt(50),sH=Math.sqrt(10),aH=Math.sqrt(2)
12796
- function lH(e,t,n){const i=(t-e)/Math.max(0,n),o=Math.floor(Math.log10(i)),r=i/Math.pow(10,o),s=r>=rH?10:r>=sH?5:r>=aH?2:1
12815
+ return n}(this,e))}}function oH({_intern:e,_key:t},n){const i=t(n)
12816
+ return e.has(i)?e.get(i):n}function rH(e){return null!==e&&"object"==typeof e?e.valueOf():e}const sH=Math.sqrt(50),aH=Math.sqrt(10),lH=Math.sqrt(2)
12817
+ function cH(e,t,n){const i=(t-e)/Math.max(0,n),o=Math.floor(Math.log10(i)),r=i/Math.pow(10,o),s=r>=sH?10:r>=aH?5:r>=lH?2:1
12797
12818
  let a,l,c
12798
- return o<0?(c=Math.pow(10,-o)/s,a=Math.round(e*c),l=Math.round(t*c),a/c<e&&++a,l/c>t&&--l,c=-c):(c=Math.pow(10,o)*s,a=Math.round(e/c),l=Math.round(t/c),a*c<e&&++a,l*c>t&&--l),l<a&&.5<=n&&n<2?lH(e,t,2*n):[a,l,c]}function cH(e,t,n){if(!((n=+n)>0))return[]
12819
+ return o<0?(c=Math.pow(10,-o)/s,a=Math.round(e*c),l=Math.round(t*c),a/c<e&&++a,l/c>t&&--l,c=-c):(c=Math.pow(10,o)*s,a=Math.round(e/c),l=Math.round(t/c),a*c<e&&++a,l*c>t&&--l),l<a&&.5<=n&&n<2?cH(e,t,2*n):[a,l,c]}function dH(e,t,n){if(!((n=+n)>0))return[]
12799
12820
  if((e=+e)===(t=+t))return[e]
12800
- const i=t<e,[o,r,s]=i?lH(t,e,n):lH(e,t,n)
12821
+ const i=t<e,[o,r,s]=i?cH(t,e,n):cH(e,t,n)
12801
12822
  if(!(r>=o))return[]
12802
12823
  const a=r-o+1,l=new Array(a)
12803
12824
  if(i)if(s<0)for(let e=0;e<a;++e)l[e]=(r-e)/-s
12804
12825
  else for(let e=0;e<a;++e)l[e]=(r-e)*s
12805
12826
  else if(s<0)for(let e=0;e<a;++e)l[e]=(o+e)/-s
12806
12827
  else for(let e=0;e<a;++e)l[e]=(o+e)*s
12807
- return l}function dH(e,t,n){return lH(e=+e,t=+t,n=+n)[2]}function hH(e,t,n=eH){if((i=e.length)&&!isNaN(t=+t)){if(t<=0||i<2)return+n(e[0],0,e)
12828
+ return l}function hH(e,t,n){return cH(e=+e,t=+t,n=+n)[2]}function uH(e,t,n=tH){if((i=e.length)&&!isNaN(t=+t)){if(t<=0||i<2)return+n(e[0],0,e)
12808
12829
  if(t>=1)return+n(e[i-1],i-1,e)
12809
12830
  var i,o=(i-1)*t,r=Math.floor(o),s=+n(e[r],r,e)
12810
- return s+(+n(e[r+1],r+1,e)-s)*(o-r)}}function uH(e,t,n){e=+e,t=+t,n=(o=arguments.length)<2?(t=e,e=0,1):o<3?1:+n
12831
+ return s+(+n(e[r+1],r+1,e)-s)*(o-r)}}function pH(e,t,n){e=+e,t=+t,n=(o=arguments.length)<2?(t=e,e=0,1):o<3?1:+n
12811
12832
  for(var i=-1,o=0|Math.max(0,Math.ceil((t-e)/n)),r=new Array(o);++i<o;)r[i]=e+i*n
12812
- return r}function pH(e,t){switch(arguments.length){case 0:break
12833
+ return r}function fH(e,t){switch(arguments.length){case 0:break
12813
12834
  case 1:this.range(e)
12814
12835
  break
12815
- default:this.range(t).domain(e)}return this}const fH=Symbol("implicit")
12816
- function mH(){var e=new nH,t=[],n=[],i=fH
12836
+ default:this.range(t).domain(e)}return this}const mH=Symbol("implicit")
12837
+ function gH(){var e=new iH,t=[],n=[],i=mH
12817
12838
  function o(o){let r=e.get(o)
12818
- if(void 0===r){if(i!==fH)return i
12839
+ if(void 0===r){if(i!==mH)return i
12819
12840
  e.set(o,r=t.push(o)-1)}return n[r%n.length]}return o.domain=function(n){if(!arguments.length)return t.slice()
12820
- t=[],e=new nH
12841
+ t=[],e=new iH
12821
12842
  for(const i of n)e.has(i)||e.set(i,t.push(i)-1)
12822
- return o},o.range=function(e){return arguments.length?(n=Array.from(e),o):n.slice()},o.unknown=function(e){return arguments.length?(i=e,o):i},o.copy=function(){return mH(t,n).unknown(i)},pH.apply(o,arguments),o}function gH(){var e,t,n=mH().unknown(void 0),i=n.domain,o=n.range,r=0,s=1,a=!1,l=0,c=0,d=.5
12843
+ return o},o.range=function(e){return arguments.length?(n=Array.from(e),o):n.slice()},o.unknown=function(e){return arguments.length?(i=e,o):i},o.copy=function(){return gH(t,n).unknown(i)},fH.apply(o,arguments),o}function vH(){var e,t,n=gH().unknown(void 0),i=n.domain,o=n.range,r=0,s=1,a=!1,l=0,c=0,d=.5
12823
12844
  function h(){var n=i().length,h=s<r,u=h?s:r,p=h?r:s
12824
12845
  e=(p-u)/Math.max(1,n-l+2*c),a&&(e=Math.floor(e)),u+=(p-u-e*(n-l))*d,t=e*(1-l),a&&(u=Math.round(u),t=Math.round(t))
12825
- var f=uH(n).map((function(t){return u+e*t}))
12826
- return o(h?f.reverse():f)}return delete n.unknown,n.domain=function(e){return arguments.length?(i(e),h()):i()},n.range=function(e){return arguments.length?([r,s]=e,r=+r,s=+s,h()):[r,s]},n.rangeRound=function(e){return[r,s]=e,r=+r,s=+s,a=!0,h()},n.bandwidth=function(){return t},n.step=function(){return e},n.round=function(e){return arguments.length?(a=!!e,h()):a},n.padding=function(e){return arguments.length?(l=Math.min(1,c=+e),h()):l},n.paddingInner=function(e){return arguments.length?(l=Math.min(1,e),h()):l},n.paddingOuter=function(e){return arguments.length?(c=+e,h()):c},n.align=function(e){return arguments.length?(d=Math.max(0,Math.min(1,e)),h()):d},n.copy=function(){return gH(i(),[r,s]).round(a).paddingInner(l).paddingOuter(c).align(d)},pH.apply(h(),arguments)}function vH(e){return+e}var bH=[0,1]
12827
- function yH(e){return e}function wH(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:(n=isNaN(t)?NaN:.5,function(){return n})
12828
- var n}function xH(e,t,n){var i=e[0],o=e[1],r=t[0],s=t[1]
12829
- return o<i?(i=wH(o,i),r=n(s,r)):(i=wH(i,o),r=n(r,s)),function(e){return r(i(e))}}function CH(e,t,n){var i=Math.min(e.length,t.length)-1,o=new Array(i),r=new Array(i),s=-1
12830
- for(e[i]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++s<i;)o[s]=wH(e[s],e[s+1]),r[s]=n(t[s],t[s+1])
12831
- return function(t){var n=tH(e,t,1,i)-1
12832
- return r[n](o[n](t))}}function kH(){var e,t,n,i,o,r,s=bH,a=bH,l=xz,c=yH
12846
+ var f=pH(n).map((function(t){return u+e*t}))
12847
+ return o(h?f.reverse():f)}return delete n.unknown,n.domain=function(e){return arguments.length?(i(e),h()):i()},n.range=function(e){return arguments.length?([r,s]=e,r=+r,s=+s,h()):[r,s]},n.rangeRound=function(e){return[r,s]=e,r=+r,s=+s,a=!0,h()},n.bandwidth=function(){return t},n.step=function(){return e},n.round=function(e){return arguments.length?(a=!!e,h()):a},n.padding=function(e){return arguments.length?(l=Math.min(1,c=+e),h()):l},n.paddingInner=function(e){return arguments.length?(l=Math.min(1,e),h()):l},n.paddingOuter=function(e){return arguments.length?(c=+e,h()):c},n.align=function(e){return arguments.length?(d=Math.max(0,Math.min(1,e)),h()):d},n.copy=function(){return vH(i(),[r,s]).round(a).paddingInner(l).paddingOuter(c).align(d)},fH.apply(h(),arguments)}function bH(e){return+e}var yH=[0,1]
12848
+ function wH(e){return e}function xH(e,t){return(t-=e=+e)?function(n){return(n-e)/t}:(n=isNaN(t)?NaN:.5,function(){return n})
12849
+ var n}function CH(e,t,n){var i=e[0],o=e[1],r=t[0],s=t[1]
12850
+ return o<i?(i=xH(o,i),r=n(s,r)):(i=xH(i,o),r=n(r,s)),function(e){return r(i(e))}}function kH(e,t,n){var i=Math.min(e.length,t.length)-1,o=new Array(i),r=new Array(i),s=-1
12851
+ for(e[i]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++s<i;)o[s]=xH(e[s],e[s+1]),r[s]=n(t[s],t[s+1])
12852
+ return function(t){var n=nH(e,t,1,i)-1
12853
+ return r[n](o[n](t))}}function SH(){var e,t,n,i,o,r,s=yH,a=yH,l=Cz,c=wH
12833
12854
  function d(){var e,t,n,l=Math.min(s.length,a.length)
12834
- return c!==yH&&(e=s[0],t=s[l-1],e>t&&(n=e,e=t,t=n),c=function(n){return Math.max(e,Math.min(t,n))}),i=l>2?CH:xH,o=r=null,h}function h(t){return null==t||isNaN(t=+t)?n:(o||(o=i(s.map(e),a,l)))(e(c(t)))}return h.invert=function(n){return c(t((r||(r=i(a,s.map(e),gz)))(n)))},h.domain=function(e){return arguments.length?(s=Array.from(e,vH),d()):s.slice()},h.range=function(e){return arguments.length?(a=Array.from(e),d()):a.slice()},h.rangeRound=function(e){return a=Array.from(e),l=Cz,d()},h.clamp=function(e){return arguments.length?(c=!!e||yH,d()):c!==yH},h.interpolate=function(e){return arguments.length?(l=e,d()):l},h.unknown=function(e){return arguments.length?(n=e,h):n},function(n,i){return e=n,t=i,d()}}function SH(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null
12855
+ return c!==wH&&(e=s[0],t=s[l-1],e>t&&(n=e,e=t,t=n),c=function(n){return Math.max(e,Math.min(t,n))}),i=l>2?kH:CH,o=r=null,h}function h(t){return null==t||isNaN(t=+t)?n:(o||(o=i(s.map(e),a,l)))(e(c(t)))}return h.invert=function(n){return c(t((r||(r=i(a,s.map(e),vz)))(n)))},h.domain=function(e){return arguments.length?(s=Array.from(e,bH),d()):s.slice()},h.range=function(e){return arguments.length?(a=Array.from(e),d()):a.slice()},h.rangeRound=function(e){return a=Array.from(e),l=kz,d()},h.clamp=function(e){return arguments.length?(c=!!e||wH,d()):c!==wH},h.interpolate=function(e){return arguments.length?(l=e,d()):l},h.unknown=function(e){return arguments.length?(n=e,h):n},function(n,i){return e=n,t=i,d()}}function $H(e,t){if((n=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null
12835
12856
  var n,i=e.slice(0,n)
12836
- return[i.length>1?i[0]+i.slice(2):i,+e.slice(n+1)]}function $H(e){return(e=SH(Math.abs(e)))?e[1]:NaN}var MH,_H=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i
12837
- function EH(e){if(!(t=_H.exec(e)))throw new Error("invalid format: "+e)
12857
+ return[i.length>1?i[0]+i.slice(2):i,+e.slice(n+1)]}function MH(e){return(e=$H(Math.abs(e)))?e[1]:NaN}var _H,EH=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i
12858
+ function IH(e){if(!(t=EH.exec(e)))throw new Error("invalid format: "+e)
12838
12859
  var t
12839
- return new IH({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}function IH(e){this.fill=void 0===e.fill?" ":e.fill+"",this.align=void 0===e.align?">":e.align+"",this.sign=void 0===e.sign?"-":e.sign+"",this.symbol=void 0===e.symbol?"":e.symbol+"",this.zero=!!e.zero,this.width=void 0===e.width?void 0:+e.width,this.comma=!!e.comma,this.precision=void 0===e.precision?void 0:+e.precision,this.trim=!!e.trim,this.type=void 0===e.type?"":e.type+""}function DH(e,t){var n=SH(e,t)
12860
+ return new DH({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}function DH(e){this.fill=void 0===e.fill?" ":e.fill+"",this.align=void 0===e.align?">":e.align+"",this.sign=void 0===e.sign?"-":e.sign+"",this.symbol=void 0===e.symbol?"":e.symbol+"",this.zero=!!e.zero,this.width=void 0===e.width?void 0:+e.width,this.comma=!!e.comma,this.precision=void 0===e.precision?void 0:+e.precision,this.trim=!!e.trim,this.type=void 0===e.type?"":e.type+""}function AH(e,t){var n=$H(e,t)
12840
12861
  if(!n)return e+""
12841
12862
  var i=n[0],o=n[1]
12842
- return o<0?"0."+new Array(-o).join("0")+i:i.length>o+1?i.slice(0,o+1)+"."+i.slice(o+1):i+new Array(o-i.length+2).join("0")}EH.prototype=IH.prototype,IH.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type}
12843
- var AH={"%":(e,t)=>(100*e).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:function(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)},e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>DH(100*e,t),r:DH,s:function(e,t){var n=SH(e,t)
12863
+ return o<0?"0."+new Array(-o).join("0")+i:i.length>o+1?i.slice(0,o+1)+"."+i.slice(o+1):i+new Array(o-i.length+2).join("0")}IH.prototype=DH.prototype,DH.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(void 0===this.width?"":Math.max(1,0|this.width))+(this.comma?",":"")+(void 0===this.precision?"":"."+Math.max(0,0|this.precision))+(this.trim?"~":"")+this.type}
12864
+ var TH={"%":(e,t)=>(100*e).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:function(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)},e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>AH(100*e,t),r:AH,s:function(e,t){var n=$H(e,t)
12844
12865
  if(!n)return e+""
12845
- var i=n[0],o=n[1],r=o-(MH=3*Math.max(-8,Math.min(8,Math.floor(o/3))))+1,s=i.length
12846
- return r===s?i:r>s?i+new Array(r-s+1).join("0"):r>0?i.slice(0,r)+"."+i.slice(r):"0."+new Array(1-r).join("0")+SH(e,Math.max(0,t+r-1))[0]},X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)}
12847
- function TH(e){return e}var OH,RH,FH,NH=Array.prototype.map,PH=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"]
12848
- function LH(e){var t,n,i=void 0===e.grouping||void 0===e.thousands?TH:(t=NH.call(e.grouping,Number),n=e.thousands+"",function(e,i){for(var o=e.length,r=[],s=0,a=t[0],l=0;o>0&&a>0&&(l+a+1>i&&(a=Math.max(1,i-l)),r.push(e.substring(o-=a,o+a)),!((l+=a+1)>i));)a=t[s=(s+1)%t.length]
12849
- return r.reverse().join(n)}),o=void 0===e.currency?"":e.currency[0]+"",r=void 0===e.currency?"":e.currency[1]+"",s=void 0===e.decimal?".":e.decimal+"",a=void 0===e.numerals?TH:function(e){return function(t){return t.replace(/[0-9]/g,(function(t){return e[+t]}))}}(NH.call(e.numerals,String)),l=void 0===e.percent?"%":e.percent+"",c=void 0===e.minus?"−":e.minus+"",d=void 0===e.nan?"NaN":e.nan+""
12850
- function h(e){var t=(e=EH(e)).fill,n=e.align,h=e.sign,u=e.symbol,p=e.zero,f=e.width,m=e.comma,g=e.precision,v=e.trim,b=e.type
12851
- "n"===b?(m=!0,b="g"):AH[b]||(void 0===g&&(g=12),v=!0,b="g"),(p||"0"===t&&"="===n)&&(p=!0,t="0",n="=")
12852
- var y="$"===u?o:"#"===u&&/[boxX]/.test(b)?"0"+b.toLowerCase():"",w="$"===u?r:/[%p]/.test(b)?l:"",x=AH[b],C=/[defgprs%]/.test(b)
12866
+ var i=n[0],o=n[1],r=o-(_H=3*Math.max(-8,Math.min(8,Math.floor(o/3))))+1,s=i.length
12867
+ return r===s?i:r>s?i+new Array(r-s+1).join("0"):r>0?i.slice(0,r)+"."+i.slice(r):"0."+new Array(1-r).join("0")+$H(e,Math.max(0,t+r-1))[0]},X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)}
12868
+ function OH(e){return e}var RH,FH,NH,PH=Array.prototype.map,LH=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"]
12869
+ function zH(e){var t,n,i=void 0===e.grouping||void 0===e.thousands?OH:(t=PH.call(e.grouping,Number),n=e.thousands+"",function(e,i){for(var o=e.length,r=[],s=0,a=t[0],l=0;o>0&&a>0&&(l+a+1>i&&(a=Math.max(1,i-l)),r.push(e.substring(o-=a,o+a)),!((l+=a+1)>i));)a=t[s=(s+1)%t.length]
12870
+ return r.reverse().join(n)}),o=void 0===e.currency?"":e.currency[0]+"",r=void 0===e.currency?"":e.currency[1]+"",s=void 0===e.decimal?".":e.decimal+"",a=void 0===e.numerals?OH:function(e){return function(t){return t.replace(/[0-9]/g,(function(t){return e[+t]}))}}(PH.call(e.numerals,String)),l=void 0===e.percent?"%":e.percent+"",c=void 0===e.minus?"−":e.minus+"",d=void 0===e.nan?"NaN":e.nan+""
12871
+ function h(e){var t=(e=IH(e)).fill,n=e.align,h=e.sign,u=e.symbol,p=e.zero,f=e.width,m=e.comma,g=e.precision,v=e.trim,b=e.type
12872
+ "n"===b?(m=!0,b="g"):TH[b]||(void 0===g&&(g=12),v=!0,b="g"),(p||"0"===t&&"="===n)&&(p=!0,t="0",n="=")
12873
+ var y="$"===u?o:"#"===u&&/[boxX]/.test(b)?"0"+b.toLowerCase():"",w="$"===u?r:/[%p]/.test(b)?l:"",x=TH[b],C=/[defgprs%]/.test(b)
12853
12874
  function k(e){var o,r,l,u=y,k=w
12854
12875
  if("c"===b)k=x(e)+k,e=""
12855
12876
  else{var S=(e=+e)<0||1/e<0
@@ -12858,7 +12879,7 @@ break
12858
12879
  case"0":0===o&&(o=i),t=i
12859
12880
  break
12860
12881
  default:if(!+e[i])break e
12861
- o>0&&(o=0)}return o>0?e.slice(0,o)+e.slice(t+1):e}(e)),S&&0==+e&&"+"!==h&&(S=!1),u=(S?"("===h?h:c:"-"===h||"("===h?"":h)+u,k=("s"===b?PH[8+MH/3]:"")+k+(S&&"("===h?")":""),C)for(o=-1,r=e.length;++o<r;)if(48>(l=e.charCodeAt(o))||l>57){k=(46===l?s+e.slice(o+1):e.slice(o))+k,e=e.slice(0,o)
12882
+ o>0&&(o=0)}return o>0?e.slice(0,o)+e.slice(t+1):e}(e)),S&&0==+e&&"+"!==h&&(S=!1),u=(S?"("===h?h:c:"-"===h||"("===h?"":h)+u,k=("s"===b?LH[8+_H/3]:"")+k+(S&&"("===h?")":""),C)for(o=-1,r=e.length;++o<r;)if(48>(l=e.charCodeAt(o))||l>57){k=(46===l?s+e.slice(o+1):e.slice(o))+k,e=e.slice(0,o)
12862
12883
  break}}m&&!p&&(e=i(e,1/0))
12863
12884
  var $=u.length+e.length+k.length,M=$<f?new Array(f-$+1).join(t):""
12864
12885
  switch(m&&p&&(e=i(M+e,M.length?f-k.length:1/0),M=""),n){case"<":e=u+e+k+M
@@ -12867,46 +12888,46 @@ case"=":e=u+M+e+k
12867
12888
  break
12868
12889
  case"^":e=M.slice(0,$=M.length>>1)+u+e+k+M.slice($)
12869
12890
  break
12870
- default:e=M+u+e+k}return a(e)}return g=void 0===g?6:/[gprs]/.test(b)?Math.max(1,Math.min(21,g)):Math.max(0,Math.min(20,g)),k.toString=function(){return e+""},k}return{format:h,formatPrefix:function(e,t){var n=h(((e=EH(e)).type="f",e)),i=3*Math.max(-8,Math.min(8,Math.floor($H(t)/3))),o=Math.pow(10,-i),r=PH[8+i/3]
12871
- return function(e){return n(o*e)+r}}}}function zH(e,t,n,i){var o,r=function(e,t,n){n=+n
12872
- const i=(t=+t)<(e=+e),o=i?dH(t,e,n):dH(e,t,n)
12891
+ default:e=M+u+e+k}return a(e)}return g=void 0===g?6:/[gprs]/.test(b)?Math.max(1,Math.min(21,g)):Math.max(0,Math.min(20,g)),k.toString=function(){return e+""},k}return{format:h,formatPrefix:function(e,t){var n=h(((e=IH(e)).type="f",e)),i=3*Math.max(-8,Math.min(8,Math.floor(MH(t)/3))),o=Math.pow(10,-i),r=LH[8+i/3]
12892
+ return function(e){return n(o*e)+r}}}}function VH(e,t,n,i){var o,r=function(e,t,n){n=+n
12893
+ const i=(t=+t)<(e=+e),o=i?hH(t,e,n):hH(e,t,n)
12873
12894
  return(i?-1:1)*(o<0?1/-o:o)}(e,t,n)
12874
- switch((i=EH(null==i?",f":i)).type){case"s":var s=Math.max(Math.abs(e),Math.abs(t))
12875
- return null!=i.precision||isNaN(o=function(e,t){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor($H(t)/3)))-$H(Math.abs(e)))}(r,s))||(i.precision=o),FH(i,s)
12876
- case"":case"e":case"g":case"p":case"r":null!=i.precision||isNaN(o=function(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,$H(t)-$H(e))+1}(r,Math.max(Math.abs(e),Math.abs(t))))||(i.precision=o-("e"===i.type))
12895
+ switch((i=IH(null==i?",f":i)).type){case"s":var s=Math.max(Math.abs(e),Math.abs(t))
12896
+ return null!=i.precision||isNaN(o=function(e,t){return Math.max(0,3*Math.max(-8,Math.min(8,Math.floor(MH(t)/3)))-MH(Math.abs(e)))}(r,s))||(i.precision=o),NH(i,s)
12897
+ case"":case"e":case"g":case"p":case"r":null!=i.precision||isNaN(o=function(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,MH(t)-MH(e))+1}(r,Math.max(Math.abs(e),Math.abs(t))))||(i.precision=o-("e"===i.type))
12877
12898
  break
12878
- case"f":case"%":null!=i.precision||isNaN(o=function(e){return Math.max(0,-$H(Math.abs(e)))}(r))||(i.precision=o-2*("%"===i.type))}return RH(i)}function VH(){var e=kH()(yH,yH)
12879
- return e.copy=function(){return t=e,VH().domain(t.domain()).range(t.range()).interpolate(t.interpolate()).clamp(t.clamp()).unknown(t.unknown())
12880
- var t},pH.apply(e,arguments),function(e){var t=e.domain
12899
+ case"f":case"%":null!=i.precision||isNaN(o=function(e){return Math.max(0,-MH(Math.abs(e)))}(r))||(i.precision=o-2*("%"===i.type))}return FH(i)}function HH(){var e=SH()(wH,wH)
12900
+ return e.copy=function(){return t=e,HH().domain(t.domain()).range(t.range()).interpolate(t.interpolate()).clamp(t.clamp()).unknown(t.unknown())
12901
+ var t},fH.apply(e,arguments),function(e){var t=e.domain
12881
12902
  return e.ticks=function(e){var n=t()
12882
- return cH(n[0],n[n.length-1],null==e?10:e)},e.tickFormat=function(e,n){var i=t()
12883
- return zH(i[0],i[i.length-1],null==e?10:e,n)},e.nice=function(n){null==n&&(n=10)
12903
+ return dH(n[0],n[n.length-1],null==e?10:e)},e.tickFormat=function(e,n){var i=t()
12904
+ return VH(i[0],i[i.length-1],null==e?10:e,n)},e.nice=function(n){null==n&&(n=10)
12884
12905
  var i,o,r=t(),s=0,a=r.length-1,l=r[s],c=r[a],d=10
12885
- for(c<l&&(o=l,l=c,c=o,o=s,s=a,a=o);d-- >0;){if((o=dH(l,c,n))===i)return r[s]=l,r[a]=c,t(r)
12906
+ for(c<l&&(o=l,l=c,c=o,o=s,s=a,a=o);d-- >0;){if((o=hH(l,c,n))===i)return r[s]=l,r[a]=c,t(r)
12886
12907
  if(o>0)l=Math.floor(l/o)*o,c=Math.ceil(c/o)*o
12887
12908
  else{if(!(o<0))break
12888
- l=Math.ceil(l*o)/o,c=Math.floor(c*o)/o}i=o}return e},e}(e)}function HH(){var e,t=[],n=[],i=[]
12909
+ l=Math.ceil(l*o)/o,c=Math.floor(c*o)/o}i=o}return e},e}(e)}function BH(){var e,t=[],n=[],i=[]
12889
12910
  function o(){var e=0,o=Math.max(1,n.length)
12890
- for(i=new Array(o-1);++e<o;)i[e-1]=hH(t,e/o)
12891
- return r}function r(t){return null==t||isNaN(t=+t)?e:n[tH(i,t)]}return r.invertExtent=function(e){var o=n.indexOf(e)
12911
+ for(i=new Array(o-1);++e<o;)i[e-1]=uH(t,e/o)
12912
+ return r}function r(t){return null==t||isNaN(t=+t)?e:n[nH(i,t)]}return r.invertExtent=function(e){var o=n.indexOf(e)
12892
12913
  return o<0?[NaN,NaN]:[o>0?i[o-1]:t[0],o<i.length?i[o]:t[t.length-1]]},r.domain=function(e){if(!arguments.length)return t.slice()
12893
12914
  t=[]
12894
12915
  for(let n of e)null==n||isNaN(n=+n)||t.push(n)
12895
- return t.sort(XV),o()},r.range=function(e){return arguments.length?(n=Array.from(e),o()):n.slice()},r.unknown=function(t){return arguments.length?(e=t,r):e},r.quantiles=function(){return i.slice()},r.copy=function(){return HH().domain(t).range(n).unknown(e)},pH.apply(r,arguments)}OH=LH({thousands:",",grouping:[3],currency:["$",""]}),RH=OH.format,FH=OH.formatPrefix
12896
- const BH="bottom-left",qH="bottom-right",UH="top-left",jH="top",WH="show",ZH="hide",GH="linear",KH="ordinal"
12897
- class XH{get containerDimensions(){return this._containerDimensions}get dieDimensions(){return this._dieDimensions}get margin(){return this._margin}get horizontalScale(){return this._horizontalScale}get verticalScale(){return this._verticalScale}constructor(e){this.wafermap=e,this.defaultPadding=0,this.baseMarginPercentage=.04}update(){const e={width:this.wafermap.canvasWidth,height:this.wafermap.canvasHeight},t=Math.min(e.width,e.height),n={top:(e.height-t)/2,right:(e.width-t)/2,bottom:(e.height-t)/2,left:(e.width-t)/2},i={top:t*this.baseMarginPercentage,right:t*this.baseMarginPercentage,bottom:t*this.baseMarginPercentage,left:t*this.baseMarginPercentage}
12916
+ return t.sort(YV),o()},r.range=function(e){return arguments.length?(n=Array.from(e),o()):n.slice()},r.unknown=function(t){return arguments.length?(e=t,r):e},r.quantiles=function(){return i.slice()},r.copy=function(){return BH().domain(t).range(n).unknown(e)},fH.apply(r,arguments)}RH=zH({thousands:",",grouping:[3],currency:["$",""]}),FH=RH.format,NH=RH.formatPrefix
12917
+ const qH="bottom-left",UH="bottom-right",jH="top-left",WH="top",ZH="show",GH="hide",KH="linear",XH="ordinal"
12918
+ class YH{get containerDimensions(){return this._containerDimensions}get dieDimensions(){return this._dieDimensions}get margin(){return this._margin}get horizontalScale(){return this._horizontalScale}get verticalScale(){return this._verticalScale}constructor(e){this.wafermap=e,this.defaultPadding=0,this.baseMarginPercentage=.04}update(){const e={width:this.wafermap.canvasWidth,height:this.wafermap.canvasHeight},t=Math.min(e.width,e.height),n={top:(e.height-t)/2,right:(e.width-t)/2,bottom:(e.height-t)/2,left:(e.width-t)/2},i={top:t*this.baseMarginPercentage,right:t*this.baseMarginPercentage,bottom:t*this.baseMarginPercentage,left:t*this.baseMarginPercentage}
12898
12919
  this._margin=this.calculateMarginAddition(i,n),this._containerDimensions=this.calculateContainerDimensions(e,this._margin)
12899
12920
  const o=Math.min(this._containerDimensions.width,this._containerDimensions.height),r=this.gridDimensionsValidAndDefined()?this.calculateGridDimensionsFromBoundingBox():this.calculateGridDimensionsFromDies(),s=this.wafermap.originLocation
12900
12921
  this._horizontalScale=this.createHorizontalScale(s,r,o),this._verticalScale=this.createVerticalScale(s,r,o),this._dieDimensions={width:Math.abs(this._horizontalScale(0)-this._horizontalScale(1)),height:Math.abs(this._verticalScale(0)-this._verticalScale(1))}}gridDimensionsValidAndDefined(){return!this.wafermap.validity.invalidGridDimensions&&"number"==typeof this.wafermap.gridMinX&&"number"==typeof this.wafermap.gridMinY&&"number"==typeof this.wafermap.gridMaxX&&"number"==typeof this.wafermap.gridMinX}calculateGridDimensionsFromBoundingBox(){const e={origin:{x:0,y:0},rows:0,cols:0}
12901
12922
  return"number"==typeof this.wafermap.gridMaxY&&"number"==typeof this.wafermap.gridMinY&&"number"==typeof this.wafermap.gridMaxX&&"number"==typeof this.wafermap.gridMinX&&(e.origin.x=this.wafermap.gridMinX,e.origin.y=this.wafermap.gridMinY,e.rows=this.wafermap.gridMaxY-this.wafermap.gridMinY+1,e.cols=this.wafermap.gridMaxX-this.wafermap.gridMinX+1),e}calculateGridDimensionsFromDies(){if(void 0===this.wafermap.diesTable)return{origin:{x:0,y:0},rows:0,cols:0}
12902
12923
  const e=this.wafermap.diesTable.getChild("colIndex").toArray(),t=this.wafermap.diesTable.getChild("rowIndex").toArray(),n={x:e[0],y:t[0]},i={x:e[0],y:t[0]}
12903
12924
  for(let o=0;o<e.length;o++)e[o]<n.x&&(n.x=e[o]),e[o]>i.x&&(i.x=e[o]),t[o]<n.y&&(n.y=t[o]),t[o]>i.y&&(i.y=t[o])
12904
- return{origin:n,rows:i.y-n.y+1,cols:i.x-n.x+1}}calculateContainerDimensions(e,t){return{width:e.width-t.left-t.right,height:e.height-t.top-t.bottom}}createHorizontalScale(e,t,n){const i=VH()
12905
- return e===BH||e===UH?i.domain([t.origin.x,t.origin.x+t.cols]).range([0,n]):i.domain([t.origin.x-1,t.origin.x+t.cols-1]).range([n,0])}createVerticalScale(e,t,n){const i=VH()
12906
- return e===BH||e===qH?i.domain([t.origin.y-1,t.origin.y+t.rows-1]).range([n,0]):i.domain([t.origin.y,t.origin.y+t.rows]).range([0,n])}calculateMarginAddition(e,t){return{top:e.top+t.top,right:e.right+t.right,bottom:e.bottom+t.bottom,left:e.left+t.left}}}class YH{get labelsFontSize(){return this._labelsFontSize}get colorScale(){return this._colorScale}constructor(e){this.wafermap=e,this.fontSizeFactor=.8,this.colorScaleResolution=10}update(){this._labelsFontSize=this.calculateLabelsFontSize(this.wafermap.experimentalDataManager.dieDimensions,this.wafermap.maxCharacters),this._colorScale=this.calculateColorScale()}calculateColorScale(){if(this.wafermap.colorScaleMode===GH){const e=this.wafermap.colorScale.values.map((e=>+e)),t=VH().domain(e).range(this.wafermap.colorScale.colors)
12925
+ return{origin:n,rows:i.y-n.y+1,cols:i.x-n.x+1}}calculateContainerDimensions(e,t){return{width:e.width-t.left-t.right,height:e.height-t.top-t.bottom}}createHorizontalScale(e,t,n){const i=HH()
12926
+ return e===qH||e===jH?i.domain([t.origin.x,t.origin.x+t.cols]).range([0,n]):i.domain([t.origin.x-1,t.origin.x+t.cols-1]).range([n,0])}createVerticalScale(e,t,n){const i=HH()
12927
+ return e===qH||e===UH?i.domain([t.origin.y-1,t.origin.y+t.rows-1]).range([n,0]):i.domain([t.origin.y,t.origin.y+t.rows]).range([0,n])}calculateMarginAddition(e,t){return{top:e.top+t.top,right:e.right+t.right,bottom:e.bottom+t.bottom,left:e.left+t.left}}}class JH{get labelsFontSize(){return this._labelsFontSize}get colorScale(){return this._colorScale}constructor(e){this.wafermap=e,this.fontSizeFactor=.8,this.colorScaleResolution=10}update(){this._labelsFontSize=this.calculateLabelsFontSize(this.wafermap.experimentalDataManager.dieDimensions,this.wafermap.maxCharacters),this._colorScale=this.calculateColorScale()}calculateColorScale(){if(this.wafermap.colorScaleMode===KH){const e=this.wafermap.colorScale.values.map((e=>+e)),t=HH().domain(e).range(this.wafermap.colorScale.colors)
12907
12928
  let n=e[0],i=e[0]
12908
12929
  e.forEach((e=>{e<n&&(n=e),e>i&&(i=e)}))
12909
- return cH(n,i,e.length*this.colorScaleResolution).map((e=>({color:t(e),value:e})))}return this.wafermap.colorScale.colors.map(((e,t)=>({color:e,value:+this.wafermap.colorScale.values[t]}))).sort(((e,t)=>e.value-t.value))}calculateLabelsFontSize(e,t){return Math.min(e.height,e.width/(.5*Math.max(2,t))*this.fontSizeFactor)}}class JH{get containerDimensions(){return this.computations.containerDimensions}get dieDimensions(){return this.computations.dieDimensions}get margin(){return this.computations.margin}get horizontalScale(){return this.computations.horizontalScale}get verticalScale(){return this.computations.verticalScale}get labelsFontSize(){return this.prerendering.labelsFontSize}get colorScale(){return this.prerendering.colorScale}constructor(e){this.wafermap=e,this.computations=new XH(e),this.prerendering=new YH(e)}updateComputations(){this.computations.update(),this.prerendering.update()}updatePrerendering(){this.prerendering.update()}}class QH{constructor(e){this.wafermap=e,this.minDieDim=50}updateSortedDiesAndDrawWafer(){this.dies=this.wafermap.dataManager.diesRenderInfo.sort(((e,t)=>e.fillStyle>t.fillStyle?1:t.fillStyle>e.fillStyle?-1:0)),this.drawWafer()}drawWafer(){this.wafermap.canvasContext.save(),this.clearCanvas(),this.scaleCanvas(),this.renderDies(),this.renderText(),this.wafermap.canvasContext.restore(),this.renderHover()}renderHover(){this.wafermap.hoverWidth=this.wafermap.dataManager.dieDimensions.width*this.wafermap.transform.k,this.wafermap.hoverHeight=this.wafermap.dataManager.dieDimensions.height*this.wafermap.transform.k,this.wafermap.hoverOpacity=void 0===this.wafermap.hoverDie?ZH:WH,this.wafermap.hoverTransform=this.calculateHoverTransform()}calculateHoverTransform(){if(void 0!==this.wafermap.hoverDie){const e=this.wafermap.dataManager.horizontalScale(this.wafermap.hoverDie.x)
12930
+ return dH(n,i,e.length*this.colorScaleResolution).map((e=>({color:t(e),value:e})))}return this.wafermap.colorScale.colors.map(((e,t)=>({color:e,value:+this.wafermap.colorScale.values[t]}))).sort(((e,t)=>e.value-t.value))}calculateLabelsFontSize(e,t){return Math.min(e.height,e.width/(.5*Math.max(2,t))*this.fontSizeFactor)}}class QH{get containerDimensions(){return this.computations.containerDimensions}get dieDimensions(){return this.computations.dieDimensions}get margin(){return this.computations.margin}get horizontalScale(){return this.computations.horizontalScale}get verticalScale(){return this.computations.verticalScale}get labelsFontSize(){return this.prerendering.labelsFontSize}get colorScale(){return this.prerendering.colorScale}constructor(e){this.wafermap=e,this.computations=new YH(e),this.prerendering=new JH(e)}updateComputations(){this.computations.update(),this.prerendering.update()}updatePrerendering(){this.prerendering.update()}}class eB{constructor(e){this.wafermap=e,this.minDieDim=50}updateSortedDiesAndDrawWafer(){this.dies=this.wafermap.dataManager.diesRenderInfo.sort(((e,t)=>e.fillStyle>t.fillStyle?1:t.fillStyle>e.fillStyle?-1:0)),this.drawWafer()}drawWafer(){this.wafermap.canvasContext.save(),this.clearCanvas(),this.scaleCanvas(),this.renderDies(),this.renderText(),this.wafermap.canvasContext.restore(),this.renderHover()}renderHover(){this.wafermap.hoverWidth=this.wafermap.dataManager.dieDimensions.width*this.wafermap.transform.k,this.wafermap.hoverHeight=this.wafermap.dataManager.dieDimensions.height*this.wafermap.transform.k,this.wafermap.hoverOpacity=void 0===this.wafermap.hoverDie?GH:ZH,this.wafermap.hoverTransform=this.calculateHoverTransform()}calculateHoverTransform(){if(void 0!==this.wafermap.hoverDie){const e=this.wafermap.dataManager.horizontalScale(this.wafermap.hoverDie.x)
12910
12931
  if(void 0===e)return""
12911
12932
  const t=this.wafermap.dataManager.verticalScale(this.wafermap.hoverDie.y)
12912
12933
  if(void 0===t)return""
@@ -12919,105 +12940,105 @@ if(e*t*(this.wafermap.transform.k||1)>=this.minDieDim){const n=this.wafermap.dat
12919
12940
  i.font=`${n.toString()}px sans-serif`,i.fillStyle="#ffffff",i.textAlign="center",i.lineCap="butt"
12920
12941
  const o=i.measureText("M"),r=this.wafermap.transform.invert([0,0]),s=this.wafermap.transform.invert([this.wafermap.canvas.width,this.wafermap.canvas.height])
12921
12942
  r[0]-=e,r[1]-=t
12922
- for(const n of this.dies)this.isDieVisible(n,r,s)&&i.fillText(n.text,n.x+e/2,n.y+t/2+o.width/2,e-e/100*20)}}clearCanvas(){this.wafermap.canvasContext.clearRect(0,0,this.wafermap.canvas.width,this.wafermap.canvas.height)}scaleCanvas(){this.wafermap.canvasContext.translate(this.wafermap.transform.x,this.wafermap.transform.y),this.wafermap.canvasContext.scale(this.wafermap.transform.k,this.wafermap.transform.k)}isDieVisible(e,t,n){return e.x>=t[0]&&e.x<n[0]&&e.y>=t[1]&&e.y<n[1]}}const eB=["highlightedTags","canvasWidth","canvasHeight","originLocation","gridMinX","gridMaxX","gridMinY","gridMaxY","dies","maxCharacters","colorScale","colorScaleMode","dieLabelsHidden","dieLabelsSuffix","transform","hoverDie"]
12923
- class tB extends WE{constructor(e){super(eB),this.wafermap=e,this.updateQueued=!1}get requiresEventsUpdate(){return this.isTracked("highlightedTags")||this.isTracked("canvasWidth")||this.isTracked("canvasHeight")||this.isTracked("originLocation")||this.isTracked("gridMinX")||this.isTracked("gridMaxX")||this.isTracked("gridMinY")||this.isTracked("gridMaxY")||this.isTracked("dies")||this.isTracked("maxCharacters")||this.isTracked("colorScale")||this.isTracked("colorScaleMode")||this.isTracked("dieLabelsHidden")||this.isTracked("dieLabelsSuffix")||this.isTracked("transform")}get requiresContainerDimensionsUpdate(){return this.isTracked("canvasWidth")||this.isTracked("canvasHeight")}get requiresScalesUpdate(){return this.isTracked("originLocation")||this.isTracked("gridMinX")||this.isTracked("gridMaxX")||this.isTracked("gridMinY")||this.isTracked("gridMaxY")||this.isTracked("dies")}get requiresLabelsFontSizeUpdate(){return this.isTracked("maxCharacters")}get requiresDiesRenderInfoUpdate(){return this.isTracked("highlightedTags")||this.isTracked("colorScale")||this.isTracked("colorScaleMode")||this.isTracked("dieLabelsHidden")||this.isTracked("dieLabelsSuffix")}get requiresDrawnWaferUpdate(){return this.isTracked("transform")}get requiresRenderHoverUpdate(){return this.isTracked("hoverDie")}queueUpdate(){this.wafermap.$fastController.isConnected&&!this.updateQueued&&(this.updateQueued=!0,void 0===this.wafermap.currentTask?u.queueUpdate((()=>{this.wafermap.update(),this.untrackAll(),this.updateQueued=!1})):(async()=>{await this.wafermap.currentTask,u.queueUpdate((()=>{this.wafermap.update(),this.untrackAll(),this.updateQueued=!1,this.wafermap.currentTask=void 0}))})())}}var nB,iB,oB,rB,sB,aB,lB,cB,dB
12924
- !function(e){e[e.Sparse=0]="Sparse",e[e.Dense=1]="Dense"}(nB||(nB={})),function(e){e[e.HALF=0]="HALF",e[e.SINGLE=1]="SINGLE",e[e.DOUBLE=2]="DOUBLE"}(iB||(iB={})),function(e){e[e.DAY=0]="DAY",e[e.MILLISECOND=1]="MILLISECOND"}(oB||(oB={})),function(e){e[e.SECOND=0]="SECOND",e[e.MILLISECOND=1]="MILLISECOND",e[e.MICROSECOND=2]="MICROSECOND",e[e.NANOSECOND=3]="NANOSECOND"}(rB||(rB={})),function(e){e[e.YEAR_MONTH=0]="YEAR_MONTH",e[e.DAY_TIME=1]="DAY_TIME",e[e.MONTH_DAY_NANO=2]="MONTH_DAY_NANO"}(sB||(sB={})),function(e){e[e.NONE=0]="NONE",e[e.Null=1]="Null",e[e.Int=2]="Int",e[e.Float=3]="Float",e[e.Binary=4]="Binary",e[e.Utf8=5]="Utf8",e[e.Bool=6]="Bool",e[e.Decimal=7]="Decimal",e[e.Date=8]="Date",e[e.Time=9]="Time",e[e.Timestamp=10]="Timestamp",e[e.Interval=11]="Interval",e[e.List=12]="List",e[e.Struct=13]="Struct",e[e.Union=14]="Union",e[e.FixedSizeBinary=15]="FixedSizeBinary",e[e.FixedSizeList=16]="FixedSizeList",e[e.Map=17]="Map",e[e.Duration=18]="Duration",e[e.LargeBinary=19]="LargeBinary",e[e.LargeUtf8=20]="LargeUtf8",e[e.Dictionary=-1]="Dictionary",e[e.Int8=-2]="Int8",e[e.Int16=-3]="Int16",e[e.Int32=-4]="Int32",e[e.Int64=-5]="Int64",e[e.Uint8=-6]="Uint8",e[e.Uint16=-7]="Uint16",e[e.Uint32=-8]="Uint32",e[e.Uint64=-9]="Uint64",e[e.Float16=-10]="Float16",e[e.Float32=-11]="Float32",e[e.Float64=-12]="Float64",e[e.DateDay=-13]="DateDay",e[e.DateMillisecond=-14]="DateMillisecond",e[e.TimestampSecond=-15]="TimestampSecond",e[e.TimestampMillisecond=-16]="TimestampMillisecond",e[e.TimestampMicrosecond=-17]="TimestampMicrosecond",e[e.TimestampNanosecond=-18]="TimestampNanosecond",e[e.TimeSecond=-19]="TimeSecond",e[e.TimeMillisecond=-20]="TimeMillisecond",e[e.TimeMicrosecond=-21]="TimeMicrosecond",e[e.TimeNanosecond=-22]="TimeNanosecond",e[e.DenseUnion=-23]="DenseUnion",e[e.SparseUnion=-24]="SparseUnion",e[e.IntervalDayTime=-25]="IntervalDayTime",e[e.IntervalYearMonth=-26]="IntervalYearMonth",e[e.DurationSecond=-27]="DurationSecond",e[e.DurationMillisecond=-28]="DurationMillisecond",e[e.DurationMicrosecond=-29]="DurationMicrosecond",e[e.DurationNanosecond=-30]="DurationNanosecond"}(aB||(aB={})),function(e){e[e.OFFSET=0]="OFFSET",e[e.DATA=1]="DATA",e[e.VALIDITY=2]="VALIDITY",e[e.TYPE=3]="TYPE"}(lB||(lB={}))
12925
- class hB{static isNull(e){return(null==e?void 0:e.typeId)===aB.Null}static isInt(e){return(null==e?void 0:e.typeId)===aB.Int}static isFloat(e){return(null==e?void 0:e.typeId)===aB.Float}static isBinary(e){return(null==e?void 0:e.typeId)===aB.Binary}static isLargeBinary(e){return(null==e?void 0:e.typeId)===aB.LargeBinary}static isUtf8(e){return(null==e?void 0:e.typeId)===aB.Utf8}static isLargeUtf8(e){return(null==e?void 0:e.typeId)===aB.LargeUtf8}static isBool(e){return(null==e?void 0:e.typeId)===aB.Bool}static isDecimal(e){return(null==e?void 0:e.typeId)===aB.Decimal}static isDate(e){return(null==e?void 0:e.typeId)===aB.Date}static isTime(e){return(null==e?void 0:e.typeId)===aB.Time}static isTimestamp(e){return(null==e?void 0:e.typeId)===aB.Timestamp}static isInterval(e){return(null==e?void 0:e.typeId)===aB.Interval}static isDuration(e){return(null==e?void 0:e.typeId)===aB.Duration}static isList(e){return(null==e?void 0:e.typeId)===aB.List}static isStruct(e){return(null==e?void 0:e.typeId)===aB.Struct}static isUnion(e){return(null==e?void 0:e.typeId)===aB.Union}static isFixedSizeBinary(e){return(null==e?void 0:e.typeId)===aB.FixedSizeBinary}static isFixedSizeList(e){return(null==e?void 0:e.typeId)===aB.FixedSizeList}static isMap(e){return(null==e?void 0:e.typeId)===aB.Map}static isDictionary(e){return(null==e?void 0:e.typeId)===aB.Dictionary}static isDenseUnion(e){return hB.isUnion(e)&&e.mode===nB.Dense}static isSparseUnion(e){return hB.isUnion(e)&&e.mode===nB.Sparse}constructor(e){this.typeId=e}}cB=Symbol.toStringTag,hB[cB]=((dB=hB.prototype).children=null,dB.ArrayType=Array,dB.OffsetArrayType=Int32Array,dB[Symbol.toStringTag]="DataType")
12926
- class uB extends hB{constructor(){super(aB.Null)}toString(){return"Null"}}uB[Symbol.toStringTag]=(e=>e[Symbol.toStringTag]="Null")(uB.prototype)
12927
- class pB extends hB{constructor(e,t){super(aB.Int),this.isSigned=e,this.bitWidth=t}get ArrayType(){switch(this.bitWidth){case 8:return this.isSigned?Int8Array:Uint8Array
12943
+ for(const n of this.dies)this.isDieVisible(n,r,s)&&i.fillText(n.text,n.x+e/2,n.y+t/2+o.width/2,e-e/100*20)}}clearCanvas(){this.wafermap.canvasContext.clearRect(0,0,this.wafermap.canvas.width,this.wafermap.canvas.height)}scaleCanvas(){this.wafermap.canvasContext.translate(this.wafermap.transform.x,this.wafermap.transform.y),this.wafermap.canvasContext.scale(this.wafermap.transform.k,this.wafermap.transform.k)}isDieVisible(e,t,n){return e.x>=t[0]&&e.x<n[0]&&e.y>=t[1]&&e.y<n[1]}}const tB=["highlightedTags","canvasWidth","canvasHeight","originLocation","gridMinX","gridMaxX","gridMinY","gridMaxY","dies","maxCharacters","colorScale","colorScaleMode","dieLabelsHidden","dieLabelsSuffix","transform","hoverDie"]
12944
+ class nB extends WE{constructor(e){super(tB),this.wafermap=e,this.updateQueued=!1}get requiresEventsUpdate(){return this.isTracked("highlightedTags")||this.isTracked("canvasWidth")||this.isTracked("canvasHeight")||this.isTracked("originLocation")||this.isTracked("gridMinX")||this.isTracked("gridMaxX")||this.isTracked("gridMinY")||this.isTracked("gridMaxY")||this.isTracked("dies")||this.isTracked("maxCharacters")||this.isTracked("colorScale")||this.isTracked("colorScaleMode")||this.isTracked("dieLabelsHidden")||this.isTracked("dieLabelsSuffix")||this.isTracked("transform")}get requiresContainerDimensionsUpdate(){return this.isTracked("canvasWidth")||this.isTracked("canvasHeight")}get requiresScalesUpdate(){return this.isTracked("originLocation")||this.isTracked("gridMinX")||this.isTracked("gridMaxX")||this.isTracked("gridMinY")||this.isTracked("gridMaxY")||this.isTracked("dies")}get requiresLabelsFontSizeUpdate(){return this.isTracked("maxCharacters")}get requiresDiesRenderInfoUpdate(){return this.isTracked("highlightedTags")||this.isTracked("colorScale")||this.isTracked("colorScaleMode")||this.isTracked("dieLabelsHidden")||this.isTracked("dieLabelsSuffix")}get requiresDrawnWaferUpdate(){return this.isTracked("transform")}get requiresRenderHoverUpdate(){return this.isTracked("hoverDie")}queueUpdate(){this.wafermap.$fastController.isConnected&&!this.updateQueued&&(this.updateQueued=!0,void 0===this.wafermap.currentTask?u.queueUpdate((()=>{this.wafermap.update(),this.untrackAll(),this.updateQueued=!1})):(async()=>{await this.wafermap.currentTask,u.queueUpdate((()=>{this.wafermap.update(),this.untrackAll(),this.updateQueued=!1,this.wafermap.currentTask=void 0}))})())}}var iB,oB,rB,sB,aB,lB,cB,dB,hB
12945
+ !function(e){e[e.Sparse=0]="Sparse",e[e.Dense=1]="Dense"}(iB||(iB={})),function(e){e[e.HALF=0]="HALF",e[e.SINGLE=1]="SINGLE",e[e.DOUBLE=2]="DOUBLE"}(oB||(oB={})),function(e){e[e.DAY=0]="DAY",e[e.MILLISECOND=1]="MILLISECOND"}(rB||(rB={})),function(e){e[e.SECOND=0]="SECOND",e[e.MILLISECOND=1]="MILLISECOND",e[e.MICROSECOND=2]="MICROSECOND",e[e.NANOSECOND=3]="NANOSECOND"}(sB||(sB={})),function(e){e[e.YEAR_MONTH=0]="YEAR_MONTH",e[e.DAY_TIME=1]="DAY_TIME",e[e.MONTH_DAY_NANO=2]="MONTH_DAY_NANO"}(aB||(aB={})),function(e){e[e.NONE=0]="NONE",e[e.Null=1]="Null",e[e.Int=2]="Int",e[e.Float=3]="Float",e[e.Binary=4]="Binary",e[e.Utf8=5]="Utf8",e[e.Bool=6]="Bool",e[e.Decimal=7]="Decimal",e[e.Date=8]="Date",e[e.Time=9]="Time",e[e.Timestamp=10]="Timestamp",e[e.Interval=11]="Interval",e[e.List=12]="List",e[e.Struct=13]="Struct",e[e.Union=14]="Union",e[e.FixedSizeBinary=15]="FixedSizeBinary",e[e.FixedSizeList=16]="FixedSizeList",e[e.Map=17]="Map",e[e.Duration=18]="Duration",e[e.LargeBinary=19]="LargeBinary",e[e.LargeUtf8=20]="LargeUtf8",e[e.Dictionary=-1]="Dictionary",e[e.Int8=-2]="Int8",e[e.Int16=-3]="Int16",e[e.Int32=-4]="Int32",e[e.Int64=-5]="Int64",e[e.Uint8=-6]="Uint8",e[e.Uint16=-7]="Uint16",e[e.Uint32=-8]="Uint32",e[e.Uint64=-9]="Uint64",e[e.Float16=-10]="Float16",e[e.Float32=-11]="Float32",e[e.Float64=-12]="Float64",e[e.DateDay=-13]="DateDay",e[e.DateMillisecond=-14]="DateMillisecond",e[e.TimestampSecond=-15]="TimestampSecond",e[e.TimestampMillisecond=-16]="TimestampMillisecond",e[e.TimestampMicrosecond=-17]="TimestampMicrosecond",e[e.TimestampNanosecond=-18]="TimestampNanosecond",e[e.TimeSecond=-19]="TimeSecond",e[e.TimeMillisecond=-20]="TimeMillisecond",e[e.TimeMicrosecond=-21]="TimeMicrosecond",e[e.TimeNanosecond=-22]="TimeNanosecond",e[e.DenseUnion=-23]="DenseUnion",e[e.SparseUnion=-24]="SparseUnion",e[e.IntervalDayTime=-25]="IntervalDayTime",e[e.IntervalYearMonth=-26]="IntervalYearMonth",e[e.DurationSecond=-27]="DurationSecond",e[e.DurationMillisecond=-28]="DurationMillisecond",e[e.DurationMicrosecond=-29]="DurationMicrosecond",e[e.DurationNanosecond=-30]="DurationNanosecond"}(lB||(lB={})),function(e){e[e.OFFSET=0]="OFFSET",e[e.DATA=1]="DATA",e[e.VALIDITY=2]="VALIDITY",e[e.TYPE=3]="TYPE"}(cB||(cB={}))
12946
+ class uB{static isNull(e){return(null==e?void 0:e.typeId)===lB.Null}static isInt(e){return(null==e?void 0:e.typeId)===lB.Int}static isFloat(e){return(null==e?void 0:e.typeId)===lB.Float}static isBinary(e){return(null==e?void 0:e.typeId)===lB.Binary}static isLargeBinary(e){return(null==e?void 0:e.typeId)===lB.LargeBinary}static isUtf8(e){return(null==e?void 0:e.typeId)===lB.Utf8}static isLargeUtf8(e){return(null==e?void 0:e.typeId)===lB.LargeUtf8}static isBool(e){return(null==e?void 0:e.typeId)===lB.Bool}static isDecimal(e){return(null==e?void 0:e.typeId)===lB.Decimal}static isDate(e){return(null==e?void 0:e.typeId)===lB.Date}static isTime(e){return(null==e?void 0:e.typeId)===lB.Time}static isTimestamp(e){return(null==e?void 0:e.typeId)===lB.Timestamp}static isInterval(e){return(null==e?void 0:e.typeId)===lB.Interval}static isDuration(e){return(null==e?void 0:e.typeId)===lB.Duration}static isList(e){return(null==e?void 0:e.typeId)===lB.List}static isStruct(e){return(null==e?void 0:e.typeId)===lB.Struct}static isUnion(e){return(null==e?void 0:e.typeId)===lB.Union}static isFixedSizeBinary(e){return(null==e?void 0:e.typeId)===lB.FixedSizeBinary}static isFixedSizeList(e){return(null==e?void 0:e.typeId)===lB.FixedSizeList}static isMap(e){return(null==e?void 0:e.typeId)===lB.Map}static isDictionary(e){return(null==e?void 0:e.typeId)===lB.Dictionary}static isDenseUnion(e){return uB.isUnion(e)&&e.mode===iB.Dense}static isSparseUnion(e){return uB.isUnion(e)&&e.mode===iB.Sparse}constructor(e){this.typeId=e}}dB=Symbol.toStringTag,uB[dB]=((hB=uB.prototype).children=null,hB.ArrayType=Array,hB.OffsetArrayType=Int32Array,hB[Symbol.toStringTag]="DataType")
12947
+ class pB extends uB{constructor(){super(lB.Null)}toString(){return"Null"}}pB[Symbol.toStringTag]=(e=>e[Symbol.toStringTag]="Null")(pB.prototype)
12948
+ class fB extends uB{constructor(e,t){super(lB.Int),this.isSigned=e,this.bitWidth=t}get ArrayType(){switch(this.bitWidth){case 8:return this.isSigned?Int8Array:Uint8Array
12928
12949
  case 16:return this.isSigned?Int16Array:Uint16Array
12929
12950
  case 32:return this.isSigned?Int32Array:Uint32Array
12930
- case 64:return this.isSigned?BigInt64Array:BigUint64Array}throw new Error(`Unrecognized ${this[Symbol.toStringTag]} type`)}toString(){return`${this.isSigned?"I":"Ui"}nt${this.bitWidth}`}}pB[Symbol.toStringTag]=(e=>(e.isSigned=null,e.bitWidth=null,e[Symbol.toStringTag]="Int"))(pB.prototype)
12931
- class fB extends hB{constructor(e){super(aB.Float),this.precision=e}get ArrayType(){switch(this.precision){case iB.HALF:return Uint16Array
12932
- case iB.SINGLE:return Float32Array
12933
- case iB.DOUBLE:return Float64Array}throw new Error(`Unrecognized ${this[Symbol.toStringTag]} type`)}toString(){return`Float${this.precision<<5||16}`}}fB[Symbol.toStringTag]=(e=>(e.precision=null,e[Symbol.toStringTag]="Float"))(fB.prototype)
12934
- class mB extends hB{constructor(){super(aB.Binary)}toString(){return"Binary"}}mB[Symbol.toStringTag]=(e=>(e.ArrayType=Uint8Array,e[Symbol.toStringTag]="Binary"))(mB.prototype)
12935
- class gB extends hB{constructor(){super(aB.LargeBinary)}toString(){return"LargeBinary"}}gB[Symbol.toStringTag]=(e=>(e.ArrayType=Uint8Array,e.OffsetArrayType=BigInt64Array,e[Symbol.toStringTag]="LargeBinary"))(gB.prototype)
12936
- class vB extends hB{constructor(){super(aB.Utf8)}toString(){return"Utf8"}}vB[Symbol.toStringTag]=(e=>(e.ArrayType=Uint8Array,e[Symbol.toStringTag]="Utf8"))(vB.prototype)
12937
- class bB extends hB{constructor(){super(aB.LargeUtf8)}toString(){return"LargeUtf8"}}bB[Symbol.toStringTag]=(e=>(e.ArrayType=Uint8Array,e.OffsetArrayType=BigInt64Array,e[Symbol.toStringTag]="LargeUtf8"))(bB.prototype)
12938
- class yB extends hB{constructor(){super(aB.Bool)}toString(){return"Bool"}}yB[Symbol.toStringTag]=(e=>(e.ArrayType=Uint8Array,e[Symbol.toStringTag]="Bool"))(yB.prototype)
12939
- class wB extends hB{constructor(e,t,n=128){super(aB.Decimal),this.scale=e,this.precision=t,this.bitWidth=n}toString(){return`Decimal[${this.precision}e${this.scale>0?"+":""}${this.scale}]`}}wB[Symbol.toStringTag]=(e=>(e.scale=null,e.precision=null,e.ArrayType=Uint32Array,e[Symbol.toStringTag]="Decimal"))(wB.prototype)
12940
- class xB extends hB{constructor(e){super(aB.Date),this.unit=e}toString(){return`Date${32*(this.unit+1)}<${oB[this.unit]}>`}}xB[Symbol.toStringTag]=(e=>(e.unit=null,e.ArrayType=Int32Array,e[Symbol.toStringTag]="Date"))(xB.prototype)
12941
- class CB extends hB{constructor(e,t){super(aB.Time),this.unit=e,this.bitWidth=t}toString(){return`Time${this.bitWidth}<${rB[this.unit]}>`}get ArrayType(){switch(this.bitWidth){case 32:return Int32Array
12942
- case 64:return BigInt64Array}throw new Error(`Unrecognized ${this[Symbol.toStringTag]} type`)}}CB[Symbol.toStringTag]=(e=>(e.unit=null,e.bitWidth=null,e[Symbol.toStringTag]="Time"))(CB.prototype)
12943
- class kB extends hB{constructor(e,t){super(aB.Timestamp),this.unit=e,this.timezone=t}toString(){return`Timestamp<${rB[this.unit]}${this.timezone?`, ${this.timezone}`:""}>`}}kB[Symbol.toStringTag]=(e=>(e.unit=null,e.timezone=null,e.ArrayType=Int32Array,e[Symbol.toStringTag]="Timestamp"))(kB.prototype)
12944
- class SB extends hB{constructor(e){super(aB.Interval),this.unit=e}toString(){return`Interval<${sB[this.unit]}>`}}SB[Symbol.toStringTag]=(e=>(e.unit=null,e.ArrayType=Int32Array,e[Symbol.toStringTag]="Interval"))(SB.prototype)
12945
- class $B extends hB{constructor(e){super(aB.Duration),this.unit=e}toString(){return`Duration<${rB[this.unit]}>`}}$B[Symbol.toStringTag]=(e=>(e.unit=null,e.ArrayType=BigInt64Array,e[Symbol.toStringTag]="Duration"))($B.prototype)
12946
- class MB extends hB{constructor(e){super(aB.List),this.children=[e]}toString(){return`List<${this.valueType}>`}get valueType(){return this.children[0].type}get valueField(){return this.children[0]}get ArrayType(){return this.valueType.ArrayType}}MB[Symbol.toStringTag]=(e=>(e.children=null,e[Symbol.toStringTag]="List"))(MB.prototype)
12947
- class _B extends hB{constructor(e){super(aB.Struct),this.children=e}toString(){return`Struct<{${this.children.map((e=>`${e.name}:${e.type}`)).join(", ")}}>`}}_B[Symbol.toStringTag]=(e=>(e.children=null,e[Symbol.toStringTag]="Struct"))(_B.prototype)
12948
- class EB extends hB{constructor(e,t,n){super(aB.Union),this.mode=e,this.children=n,this.typeIds=t=Int32Array.from(t),this.typeIdToChildIndex=t.reduce(((e,t,n)=>(e[t]=n)&&e||e),Object.create(null))}toString(){return`${this[Symbol.toStringTag]}<${this.children.map((e=>`${e.type}`)).join(" | ")}>`}}EB[Symbol.toStringTag]=(e=>(e.mode=null,e.typeIds=null,e.children=null,e.typeIdToChildIndex=null,e.ArrayType=Int8Array,e[Symbol.toStringTag]="Union"))(EB.prototype)
12949
- class IB extends hB{constructor(e){super(aB.FixedSizeBinary),this.byteWidth=e}toString(){return`FixedSizeBinary[${this.byteWidth}]`}}IB[Symbol.toStringTag]=(e=>(e.byteWidth=null,e.ArrayType=Uint8Array,e[Symbol.toStringTag]="FixedSizeBinary"))(IB.prototype)
12950
- class DB extends hB{constructor(e,t){super(aB.FixedSizeList),this.listSize=e,this.children=[t]}get valueType(){return this.children[0].type}get valueField(){return this.children[0]}get ArrayType(){return this.valueType.ArrayType}toString(){return`FixedSizeList[${this.listSize}]<${this.valueType}>`}}DB[Symbol.toStringTag]=(e=>(e.children=null,e.listSize=null,e[Symbol.toStringTag]="FixedSizeList"))(DB.prototype)
12951
- class AB extends hB{constructor(e,t=!1){var n,i,o
12952
- if(super(aB.Map),this.children=[e],this.keysSorted=t,e&&(e.name="entries",null===(n=null==e?void 0:e.type)||void 0===n?void 0:n.children)){const t=null===(i=null==e?void 0:e.type)||void 0===i?void 0:i.children[0]
12951
+ case 64:return this.isSigned?BigInt64Array:BigUint64Array}throw new Error(`Unrecognized ${this[Symbol.toStringTag]} type`)}toString(){return`${this.isSigned?"I":"Ui"}nt${this.bitWidth}`}}fB[Symbol.toStringTag]=(e=>(e.isSigned=null,e.bitWidth=null,e[Symbol.toStringTag]="Int"))(fB.prototype)
12952
+ class mB extends uB{constructor(e){super(lB.Float),this.precision=e}get ArrayType(){switch(this.precision){case oB.HALF:return Uint16Array
12953
+ case oB.SINGLE:return Float32Array
12954
+ case oB.DOUBLE:return Float64Array}throw new Error(`Unrecognized ${this[Symbol.toStringTag]} type`)}toString(){return`Float${this.precision<<5||16}`}}mB[Symbol.toStringTag]=(e=>(e.precision=null,e[Symbol.toStringTag]="Float"))(mB.prototype)
12955
+ class gB extends uB{constructor(){super(lB.Binary)}toString(){return"Binary"}}gB[Symbol.toStringTag]=(e=>(e.ArrayType=Uint8Array,e[Symbol.toStringTag]="Binary"))(gB.prototype)
12956
+ class vB extends uB{constructor(){super(lB.LargeBinary)}toString(){return"LargeBinary"}}vB[Symbol.toStringTag]=(e=>(e.ArrayType=Uint8Array,e.OffsetArrayType=BigInt64Array,e[Symbol.toStringTag]="LargeBinary"))(vB.prototype)
12957
+ class bB extends uB{constructor(){super(lB.Utf8)}toString(){return"Utf8"}}bB[Symbol.toStringTag]=(e=>(e.ArrayType=Uint8Array,e[Symbol.toStringTag]="Utf8"))(bB.prototype)
12958
+ class yB extends uB{constructor(){super(lB.LargeUtf8)}toString(){return"LargeUtf8"}}yB[Symbol.toStringTag]=(e=>(e.ArrayType=Uint8Array,e.OffsetArrayType=BigInt64Array,e[Symbol.toStringTag]="LargeUtf8"))(yB.prototype)
12959
+ class wB extends uB{constructor(){super(lB.Bool)}toString(){return"Bool"}}wB[Symbol.toStringTag]=(e=>(e.ArrayType=Uint8Array,e[Symbol.toStringTag]="Bool"))(wB.prototype)
12960
+ class xB extends uB{constructor(e,t,n=128){super(lB.Decimal),this.scale=e,this.precision=t,this.bitWidth=n}toString(){return`Decimal[${this.precision}e${this.scale>0?"+":""}${this.scale}]`}}xB[Symbol.toStringTag]=(e=>(e.scale=null,e.precision=null,e.ArrayType=Uint32Array,e[Symbol.toStringTag]="Decimal"))(xB.prototype)
12961
+ class CB extends uB{constructor(e){super(lB.Date),this.unit=e}toString(){return`Date${32*(this.unit+1)}<${rB[this.unit]}>`}}CB[Symbol.toStringTag]=(e=>(e.unit=null,e.ArrayType=Int32Array,e[Symbol.toStringTag]="Date"))(CB.prototype)
12962
+ class kB extends uB{constructor(e,t){super(lB.Time),this.unit=e,this.bitWidth=t}toString(){return`Time${this.bitWidth}<${sB[this.unit]}>`}get ArrayType(){switch(this.bitWidth){case 32:return Int32Array
12963
+ case 64:return BigInt64Array}throw new Error(`Unrecognized ${this[Symbol.toStringTag]} type`)}}kB[Symbol.toStringTag]=(e=>(e.unit=null,e.bitWidth=null,e[Symbol.toStringTag]="Time"))(kB.prototype)
12964
+ class SB extends uB{constructor(e,t){super(lB.Timestamp),this.unit=e,this.timezone=t}toString(){return`Timestamp<${sB[this.unit]}${this.timezone?`, ${this.timezone}`:""}>`}}SB[Symbol.toStringTag]=(e=>(e.unit=null,e.timezone=null,e.ArrayType=Int32Array,e[Symbol.toStringTag]="Timestamp"))(SB.prototype)
12965
+ class $B extends uB{constructor(e){super(lB.Interval),this.unit=e}toString(){return`Interval<${aB[this.unit]}>`}}$B[Symbol.toStringTag]=(e=>(e.unit=null,e.ArrayType=Int32Array,e[Symbol.toStringTag]="Interval"))($B.prototype)
12966
+ class MB extends uB{constructor(e){super(lB.Duration),this.unit=e}toString(){return`Duration<${sB[this.unit]}>`}}MB[Symbol.toStringTag]=(e=>(e.unit=null,e.ArrayType=BigInt64Array,e[Symbol.toStringTag]="Duration"))(MB.prototype)
12967
+ class _B extends uB{constructor(e){super(lB.List),this.children=[e]}toString(){return`List<${this.valueType}>`}get valueType(){return this.children[0].type}get valueField(){return this.children[0]}get ArrayType(){return this.valueType.ArrayType}}_B[Symbol.toStringTag]=(e=>(e.children=null,e[Symbol.toStringTag]="List"))(_B.prototype)
12968
+ class EB extends uB{constructor(e){super(lB.Struct),this.children=e}toString(){return`Struct<{${this.children.map((e=>`${e.name}:${e.type}`)).join(", ")}}>`}}EB[Symbol.toStringTag]=(e=>(e.children=null,e[Symbol.toStringTag]="Struct"))(EB.prototype)
12969
+ class IB extends uB{constructor(e,t,n){super(lB.Union),this.mode=e,this.children=n,this.typeIds=t=Int32Array.from(t),this.typeIdToChildIndex=t.reduce(((e,t,n)=>(e[t]=n)&&e||e),Object.create(null))}toString(){return`${this[Symbol.toStringTag]}<${this.children.map((e=>`${e.type}`)).join(" | ")}>`}}IB[Symbol.toStringTag]=(e=>(e.mode=null,e.typeIds=null,e.children=null,e.typeIdToChildIndex=null,e.ArrayType=Int8Array,e[Symbol.toStringTag]="Union"))(IB.prototype)
12970
+ class DB extends uB{constructor(e){super(lB.FixedSizeBinary),this.byteWidth=e}toString(){return`FixedSizeBinary[${this.byteWidth}]`}}DB[Symbol.toStringTag]=(e=>(e.byteWidth=null,e.ArrayType=Uint8Array,e[Symbol.toStringTag]="FixedSizeBinary"))(DB.prototype)
12971
+ class AB extends uB{constructor(e,t){super(lB.FixedSizeList),this.listSize=e,this.children=[t]}get valueType(){return this.children[0].type}get valueField(){return this.children[0]}get ArrayType(){return this.valueType.ArrayType}toString(){return`FixedSizeList[${this.listSize}]<${this.valueType}>`}}AB[Symbol.toStringTag]=(e=>(e.children=null,e.listSize=null,e[Symbol.toStringTag]="FixedSizeList"))(AB.prototype)
12972
+ class TB extends uB{constructor(e,t=!1){var n,i,o
12973
+ if(super(lB.Map),this.children=[e],this.keysSorted=t,e&&(e.name="entries",null===(n=null==e?void 0:e.type)||void 0===n?void 0:n.children)){const t=null===(i=null==e?void 0:e.type)||void 0===i?void 0:i.children[0]
12953
12974
  t&&(t.name="key")
12954
12975
  const n=null===(o=null==e?void 0:e.type)||void 0===o?void 0:o.children[1]
12955
- n&&(n.name="value")}}get keyType(){return this.children[0].type.children[0].type}get valueType(){return this.children[0].type.children[1].type}get childType(){return this.children[0].type}toString(){return`Map<{${this.children[0].type.children.map((e=>`${e.name}:${e.type}`)).join(", ")}}>`}}AB[Symbol.toStringTag]=(e=>(e.children=null,e.keysSorted=null,e[Symbol.toStringTag]="Map_"))(AB.prototype)
12956
- const TB=(OB=-1,()=>++OB)
12957
- var OB
12958
- class RB extends hB{constructor(e,t,n,i){super(aB.Dictionary),this.indices=t,this.dictionary=e,this.isOrdered=i||!1,this.id=null==n?TB():function(e){if("bigint"==typeof e&&(e<Number.MIN_SAFE_INTEGER||e>Number.MAX_SAFE_INTEGER))throw new TypeError(`${e} is not safe to convert to a number.`)
12959
- return Number(e)}(n)}get children(){return this.dictionary.children}get valueType(){return this.dictionary}get ArrayType(){return this.dictionary.ArrayType}toString(){return`Dictionary<${this.indices}, ${this.dictionary}>`}}RB[Symbol.toStringTag]=(e=>(e.id=null,e.indices=null,e.isOrdered=null,e.dictionary=null,e[Symbol.toStringTag]="Dictionary"))(RB.prototype)
12960
- class FB{constructor(e){this.wafermap=e,this.invalidGridDimensions=!1,this.invalidDiesTableSchema=!1}getValidity(){return{invalidGridDimensions:this.invalidGridDimensions,invalidDiesTableSchema:this.invalidDiesTableSchema}}isValid(){return Object.values(this.getValidity()).every((e=>!1===e))}validateGridDimensions(){return this.invalidGridDimensions=!1,void 0===this.wafermap.gridMinX&&void 0===this.wafermap.gridMaxX&&void 0===this.wafermap.gridMinY&&void 0===this.wafermap.gridMaxY?this.invalidGridDimensions=!1:("number"!=typeof this.wafermap.gridMinX||"number"!=typeof this.wafermap.gridMaxX||"number"!=typeof this.wafermap.gridMinY||"number"!=typeof this.wafermap.gridMaxY||this.wafermap.gridMaxX<this.wafermap.gridMinX||this.wafermap.gridMaxY<this.wafermap.gridMinY)&&(this.invalidGridDimensions=!0),!this.invalidGridDimensions}validateDiesTableSchema(){if(this.invalidDiesTableSchema=!1,void 0===this.wafermap.diesTable)this.invalidDiesTableSchema=!1
12976
+ n&&(n.name="value")}}get keyType(){return this.children[0].type.children[0].type}get valueType(){return this.children[0].type.children[1].type}get childType(){return this.children[0].type}toString(){return`Map<{${this.children[0].type.children.map((e=>`${e.name}:${e.type}`)).join(", ")}}>`}}TB[Symbol.toStringTag]=(e=>(e.children=null,e.keysSorted=null,e[Symbol.toStringTag]="Map_"))(TB.prototype)
12977
+ const OB=(RB=-1,()=>++RB)
12978
+ var RB
12979
+ class FB extends uB{constructor(e,t,n,i){super(lB.Dictionary),this.indices=t,this.dictionary=e,this.isOrdered=i||!1,this.id=null==n?OB():function(e){if("bigint"==typeof e&&(e<Number.MIN_SAFE_INTEGER||e>Number.MAX_SAFE_INTEGER))throw new TypeError(`${e} is not safe to convert to a number.`)
12980
+ return Number(e)}(n)}get children(){return this.dictionary.children}get valueType(){return this.dictionary}get ArrayType(){return this.dictionary.ArrayType}toString(){return`Dictionary<${this.indices}, ${this.dictionary}>`}}FB[Symbol.toStringTag]=(e=>(e.id=null,e.indices=null,e.isOrdered=null,e.dictionary=null,e[Symbol.toStringTag]="Dictionary"))(FB.prototype)
12981
+ class NB{constructor(e){this.wafermap=e,this.invalidGridDimensions=!1,this.invalidDiesTableSchema=!1}getValidity(){return{invalidGridDimensions:this.invalidGridDimensions,invalidDiesTableSchema:this.invalidDiesTableSchema}}isValid(){return Object.values(this.getValidity()).every((e=>!1===e))}validateGridDimensions(){return this.invalidGridDimensions=!1,void 0===this.wafermap.gridMinX&&void 0===this.wafermap.gridMaxX&&void 0===this.wafermap.gridMinY&&void 0===this.wafermap.gridMaxY?this.invalidGridDimensions=!1:("number"!=typeof this.wafermap.gridMinX||"number"!=typeof this.wafermap.gridMaxX||"number"!=typeof this.wafermap.gridMinY||"number"!=typeof this.wafermap.gridMaxY||this.wafermap.gridMaxX<this.wafermap.gridMinX||this.wafermap.gridMaxY<this.wafermap.gridMinY)&&(this.invalidGridDimensions=!0),!this.invalidGridDimensions}validateDiesTableSchema(){if(this.invalidDiesTableSchema=!1,void 0===this.wafermap.diesTable)this.invalidDiesTableSchema=!1
12961
12982
  else{const e=this.wafermap.diesTable.schema.fields,t=e.find((e=>"colIndex"===e.name)),n=e.find((e=>"rowIndex"===e.name)),i=e.find((e=>"value"===e.name))
12962
- t&&n&&i&&hB.isInt(t.type)&&32===t.type.bitWidth&&hB.isInt(n.type)&&32===n.type.bitWidth&&hB.isFloat(i.type)&&i.type.precision===iB.DOUBLE||(this.invalidDiesTableSchema=!0)}return!this.invalidDiesTableSchema}}
12983
+ t&&n&&i&&uB.isInt(t.type)&&32===t.type.bitWidth&&uB.isInt(n.type)&&32===n.type.bitWidth&&uB.isFloat(i.type)&&i.type.precision===oB.DOUBLE||(this.invalidDiesTableSchema=!0)}return!this.invalidDiesTableSchema}}
12963
12984
  /**
12964
12985
  * @license
12965
12986
  * Copyright 2019 Google LLC
12966
12987
  * SPDX-License-Identifier: Apache-2.0
12967
- */const NB=Symbol("Comlink.proxy"),PB=Symbol("Comlink.endpoint"),LB=Symbol("Comlink.releaseProxy"),zB=Symbol("Comlink.finalizer"),VB=Symbol("Comlink.thrown"),HB=e=>"object"==typeof e&&null!==e||"function"==typeof e,BB=new Map([["proxy",{canHandle:e=>HB(e)&&e[NB],serialize(e){const{port1:t,port2:n}=new MessageChannel
12968
- return qB(e,t),[n,[n]]},deserialize:e=>(e.start(),jB(e))}],["throw",{canHandle:e=>HB(e)&&VB in e,serialize({value:e}){let t
12988
+ */const PB=Symbol("Comlink.proxy"),LB=Symbol("Comlink.endpoint"),zB=Symbol("Comlink.releaseProxy"),VB=Symbol("Comlink.finalizer"),HB=Symbol("Comlink.thrown"),BB=e=>"object"==typeof e&&null!==e||"function"==typeof e,qB=new Map([["proxy",{canHandle:e=>BB(e)&&e[PB],serialize(e){const{port1:t,port2:n}=new MessageChannel
12989
+ return UB(e,t),[n,[n]]},deserialize:e=>(e.start(),WB(e))}],["throw",{canHandle:e=>BB(e)&&HB in e,serialize({value:e}){let t
12969
12990
  return t=e instanceof Error?{isError:!0,value:{message:e.message,name:e.name,stack:e.stack}}:{isError:!1,value:e},[t,[]]},deserialize(e){if(e.isError)throw Object.assign(new Error(e.value.message),e.value)
12970
12991
  throw e.value}}]])
12971
- function qB(e,t=globalThis,n=["*"]){t.addEventListener("message",(function i(o){if(!o||!o.data)return
12992
+ function UB(e,t=globalThis,n=["*"]){t.addEventListener("message",(function i(o){if(!o||!o.data)return
12972
12993
  if(!function(e,t){for(const n of e){if(t===n||"*"===n)return!0
12973
12994
  if(n instanceof RegExp&&n.test(t))return!0}return!1}(n,o.origin))return void console.warn(`Invalid origin '${o.origin}' for comlink proxy`)
12974
- const{id:r,type:s,path:a}=Object.assign({path:[]},o.data),l=(o.data.argumentList||[]).map(tq)
12995
+ const{id:r,type:s,path:a}=Object.assign({path:[]},o.data),l=(o.data.argumentList||[]).map(nq)
12975
12996
  let c
12976
12997
  try{const t=a.slice(0,-1).reduce(((e,t)=>e[t]),e),n=a.reduce(((e,t)=>e[t]),e)
12977
12998
  switch(s){case"GET":c=n
12978
12999
  break
12979
- case"SET":t[a.slice(-1)[0]]=tq(o.data.value),c=!0
13000
+ case"SET":t[a.slice(-1)[0]]=nq(o.data.value),c=!0
12980
13001
  break
12981
13002
  case"APPLY":c=n.apply(t,l)
12982
13003
  break
12983
- case"CONSTRUCT":c=function(e){return Object.assign(e,{[NB]:!0})}(new n(...l))
13004
+ case"CONSTRUCT":c=function(e){return Object.assign(e,{[PB]:!0})}(new n(...l))
12984
13005
  break
12985
13006
  case"ENDPOINT":{const{port1:t,port2:n}=new MessageChannel
12986
- qB(e,n),c=QB(t,[t])}break
13007
+ UB(e,n),c=eq(t,[t])}break
12987
13008
  case"RELEASE":c=void 0
12988
13009
  break
12989
- default:return}}catch(e){c={value:e,[VB]:0}}Promise.resolve(c).catch((e=>({value:e,[VB]:0}))).then((n=>{const[o,a]=eq(n)
12990
- t.postMessage(Object.assign(Object.assign({},o),{id:r}),a),"RELEASE"===s&&(t.removeEventListener("message",i),UB(t),zB in e&&"function"==typeof e[zB]&&e[zB]())})).catch((e=>{const[n,i]=eq({value:new TypeError("Unserializable return value"),[VB]:0})
12991
- t.postMessage(Object.assign(Object.assign({},n),{id:r}),i)}))})),t.start&&t.start()}function UB(e){(function(e){return"MessagePort"===e.constructor.name})(e)&&e.close()}function jB(e,t){return XB(e,[],t)}function WB(e){if(e)throw new Error("Proxy has been released and is not useable")}function ZB(e){return nq(e,{type:"RELEASE"}).then((()=>{UB(e)}))}const GB=new WeakMap,KB="FinalizationRegistry"in globalThis&&new FinalizationRegistry((e=>{const t=(GB.get(e)||0)-1
12992
- GB.set(e,t),0===t&&ZB(e)}))
12993
- function XB(e,t=[],n=function(){}){let i=!1
12994
- const o=new Proxy(n,{get(n,r){if(WB(i),r===LB)return()=>{!function(e){KB&&KB.unregister(e)}(o),ZB(e),i=!0}
13010
+ default:return}}catch(e){c={value:e,[HB]:0}}Promise.resolve(c).catch((e=>({value:e,[HB]:0}))).then((n=>{const[o,a]=tq(n)
13011
+ t.postMessage(Object.assign(Object.assign({},o),{id:r}),a),"RELEASE"===s&&(t.removeEventListener("message",i),jB(t),VB in e&&"function"==typeof e[VB]&&e[VB]())})).catch((e=>{const[n,i]=tq({value:new TypeError("Unserializable return value"),[HB]:0})
13012
+ t.postMessage(Object.assign(Object.assign({},n),{id:r}),i)}))})),t.start&&t.start()}function jB(e){(function(e){return"MessagePort"===e.constructor.name})(e)&&e.close()}function WB(e,t){return YB(e,[],t)}function ZB(e){if(e)throw new Error("Proxy has been released and is not useable")}function GB(e){return iq(e,{type:"RELEASE"}).then((()=>{jB(e)}))}const KB=new WeakMap,XB="FinalizationRegistry"in globalThis&&new FinalizationRegistry((e=>{const t=(KB.get(e)||0)-1
13013
+ KB.set(e,t),0===t&&GB(e)}))
13014
+ function YB(e,t=[],n=function(){}){let i=!1
13015
+ const o=new Proxy(n,{get(n,r){if(ZB(i),r===zB)return()=>{!function(e){XB&&XB.unregister(e)}(o),GB(e),i=!0}
12995
13016
  if("then"===r){if(0===t.length)return{then:()=>o}
12996
- const n=nq(e,{type:"GET",path:t.map((e=>e.toString()))}).then(tq)
12997
- return n.then.bind(n)}return XB(e,[...t,r])},set(n,o,r){WB(i)
12998
- const[s,a]=eq(r)
12999
- return nq(e,{type:"SET",path:[...t,o].map((e=>e.toString())),value:s},a).then(tq)},apply(n,o,r){WB(i)
13017
+ const n=iq(e,{type:"GET",path:t.map((e=>e.toString()))}).then(nq)
13018
+ return n.then.bind(n)}return YB(e,[...t,r])},set(n,o,r){ZB(i)
13019
+ const[s,a]=tq(r)
13020
+ return iq(e,{type:"SET",path:[...t,o].map((e=>e.toString())),value:s},a).then(nq)},apply(n,o,r){ZB(i)
13000
13021
  const s=t[t.length-1]
13001
- if(s===PB)return nq(e,{type:"ENDPOINT"}).then(tq)
13002
- if("bind"===s)return XB(e,t.slice(0,-1))
13003
- const[a,l]=YB(r)
13004
- return nq(e,{type:"APPLY",path:t.map((e=>e.toString())),argumentList:a},l).then(tq)},construct(n,o){WB(i)
13005
- const[r,s]=YB(o)
13006
- return nq(e,{type:"CONSTRUCT",path:t.map((e=>e.toString())),argumentList:r},s).then(tq)}})
13007
- return function(e,t){const n=(GB.get(t)||0)+1
13008
- GB.set(t,n),KB&&KB.register(e,t,e)}(o,e),o}function YB(e){const t=e.map(eq)
13022
+ if(s===LB)return iq(e,{type:"ENDPOINT"}).then(nq)
13023
+ if("bind"===s)return YB(e,t.slice(0,-1))
13024
+ const[a,l]=JB(r)
13025
+ return iq(e,{type:"APPLY",path:t.map((e=>e.toString())),argumentList:a},l).then(nq)},construct(n,o){ZB(i)
13026
+ const[r,s]=JB(o)
13027
+ return iq(e,{type:"CONSTRUCT",path:t.map((e=>e.toString())),argumentList:r},s).then(nq)}})
13028
+ return function(e,t){const n=(KB.get(t)||0)+1
13029
+ KB.set(t,n),XB&&XB.register(e,t,e)}(o,e),o}function JB(e){const t=e.map(tq)
13009
13030
  return[t.map((e=>e[0])),(n=t.map((e=>e[1])),Array.prototype.concat.apply([],n))]
13010
- var n}const JB=new WeakMap
13011
- function QB(e,t){return JB.set(e,t),e}function eq(e){for(const[t,n]of BB)if(n.canHandle(e)){const[i,o]=n.serialize(e)
13012
- return[{type:"HANDLER",name:t,value:i},o]}return[{type:"RAW",value:e},JB.get(e)||[]]}function tq(e){switch(e.type){case"HANDLER":return BB.get(e.name).deserialize(e.value)
13013
- case"RAW":return e.value}}function nq(e,t,n){return new Promise((i=>{const o=new Array(4).fill(0).map((()=>Math.floor(Math.random()*Number.MAX_SAFE_INTEGER).toString(16))).join("-")
13014
- e.addEventListener("message",(function t(n){n.data&&n.data.id&&n.data.id===o&&(e.removeEventListener("message",t),i(n.data))})),e.start&&e.start(),e.postMessage(Object.assign({id:o},t),n)}))}let iq
13015
- class oq{constructor(e){this.wafermap=e}async setupWafer(){if(void 0===this.matrixRenderer){const{matrixRenderer:e}=await(async()=>{if(void 0===iq){const e=new Blob(['var MatrixRenderer = (function (exports) {\n \'use strict\';\n\n /**\n * @license\n * Copyright 2019 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\n const proxyMarker = Symbol("Comlink.proxy");\n const createEndpoint = Symbol("Comlink.endpoint");\n const releaseProxy = Symbol("Comlink.releaseProxy");\n const finalizer = Symbol("Comlink.finalizer");\n const throwMarker = Symbol("Comlink.thrown");\n const isObject = (val) => (typeof val === "object" && val !== null) || typeof val === "function";\n /**\n * Internal transfer handle to handle objects marked to proxy.\n */\n const proxyTransferHandler = {\n canHandle: (val) => isObject(val) && val[proxyMarker],\n serialize(obj) {\n const { port1, port2 } = new MessageChannel();\n expose(obj, port1);\n return [port2, [port2]];\n },\n deserialize(port) {\n port.start();\n return wrap(port);\n },\n };\n /**\n * Internal transfer handler to handle thrown exceptions.\n */\n const throwTransferHandler = {\n canHandle: (value) => isObject(value) && throwMarker in value,\n serialize({ value }) {\n let serialized;\n if (value instanceof Error) {\n serialized = {\n isError: true,\n value: {\n message: value.message,\n name: value.name,\n stack: value.stack,\n },\n };\n }\n else {\n serialized = { isError: false, value };\n }\n return [serialized, []];\n },\n deserialize(serialized) {\n if (serialized.isError) {\n throw Object.assign(new Error(serialized.value.message), serialized.value);\n }\n throw serialized.value;\n },\n };\n /**\n * Allows customizing the serialization of certain values.\n */\n const transferHandlers = new Map([\n ["proxy", proxyTransferHandler],\n ["throw", throwTransferHandler],\n ]);\n function isAllowedOrigin(allowedOrigins, origin) {\n for (const allowedOrigin of allowedOrigins) {\n if (origin === allowedOrigin || allowedOrigin === "*") {\n return true;\n }\n if (allowedOrigin instanceof RegExp && allowedOrigin.test(origin)) {\n return true;\n }\n }\n return false;\n }\n function expose(obj, ep = globalThis, allowedOrigins = ["*"]) {\n ep.addEventListener("message", function callback(ev) {\n if (!ev || !ev.data) {\n return;\n }\n if (!isAllowedOrigin(allowedOrigins, ev.origin)) {\n console.warn(`Invalid origin \'${ev.origin}\' for comlink proxy`);\n return;\n }\n const { id, type, path } = Object.assign({ path: [] }, ev.data);\n const argumentList = (ev.data.argumentList || []).map(fromWireValue);\n let returnValue;\n try {\n const parent = path.slice(0, -1).reduce((obj, prop) => obj[prop], obj);\n const rawValue = path.reduce((obj, prop) => obj[prop], obj);\n switch (type) {\n case "GET" /* MessageType.GET */:\n {\n returnValue = rawValue;\n }\n break;\n case "SET" /* MessageType.SET */:\n {\n parent[path.slice(-1)[0]] = fromWireValue(ev.data.value);\n returnValue = true;\n }\n break;\n case "APPLY" /* MessageType.APPLY */:\n {\n returnValue = rawValue.apply(parent, argumentList);\n }\n break;\n case "CONSTRUCT" /* MessageType.CONSTRUCT */:\n {\n const value = new rawValue(...argumentList);\n returnValue = proxy(value);\n }\n break;\n case "ENDPOINT" /* MessageType.ENDPOINT */:\n {\n const { port1, port2 } = new MessageChannel();\n expose(obj, port2);\n returnValue = transfer(port1, [port1]);\n }\n break;\n case "RELEASE" /* MessageType.RELEASE */:\n {\n returnValue = undefined;\n }\n break;\n default:\n return;\n }\n }\n catch (value) {\n returnValue = { value, [throwMarker]: 0 };\n }\n Promise.resolve(returnValue)\n .catch((value) => {\n return { value, [throwMarker]: 0 };\n })\n .then((returnValue) => {\n const [wireValue, transferables] = toWireValue(returnValue);\n ep.postMessage(Object.assign(Object.assign({}, wireValue), { id }), transferables);\n if (type === "RELEASE" /* MessageType.RELEASE */) {\n // detach and deactive after sending release response above.\n ep.removeEventListener("message", callback);\n closeEndPoint(ep);\n if (finalizer in obj && typeof obj[finalizer] === "function") {\n obj[finalizer]();\n }\n }\n })\n .catch((error) => {\n // Send Serialization Error To Caller\n const [wireValue, transferables] = toWireValue({\n value: new TypeError("Unserializable return value"),\n [throwMarker]: 0,\n });\n ep.postMessage(Object.assign(Object.assign({}, wireValue), { id }), transferables);\n });\n });\n if (ep.start) {\n ep.start();\n }\n }\n function isMessagePort(endpoint) {\n return endpoint.constructor.name === "MessagePort";\n }\n function closeEndPoint(endpoint) {\n if (isMessagePort(endpoint))\n endpoint.close();\n }\n function wrap(ep, target) {\n return createProxy(ep, [], target);\n }\n function throwIfProxyReleased(isReleased) {\n if (isReleased) {\n throw new Error("Proxy has been released and is not useable");\n }\n }\n function releaseEndpoint(ep) {\n return requestResponseMessage(ep, {\n type: "RELEASE" /* MessageType.RELEASE */,\n }).then(() => {\n closeEndPoint(ep);\n });\n }\n const proxyCounter = new WeakMap();\n const proxyFinalizers = "FinalizationRegistry" in globalThis &&\n new FinalizationRegistry((ep) => {\n const newCount = (proxyCounter.get(ep) || 0) - 1;\n proxyCounter.set(ep, newCount);\n if (newCount === 0) {\n releaseEndpoint(ep);\n }\n });\n function registerProxy(proxy, ep) {\n const newCount = (proxyCounter.get(ep) || 0) + 1;\n proxyCounter.set(ep, newCount);\n if (proxyFinalizers) {\n proxyFinalizers.register(proxy, ep, proxy);\n }\n }\n function unregisterProxy(proxy) {\n if (proxyFinalizers) {\n proxyFinalizers.unregister(proxy);\n }\n }\n function createProxy(ep, path = [], target = function () { }) {\n let isProxyReleased = false;\n const proxy = new Proxy(target, {\n get(_target, prop) {\n throwIfProxyReleased(isProxyReleased);\n if (prop === releaseProxy) {\n return () => {\n unregisterProxy(proxy);\n releaseEndpoint(ep);\n isProxyReleased = true;\n };\n }\n if (prop === "then") {\n if (path.length === 0) {\n return { then: () => proxy };\n }\n const r = requestResponseMessage(ep, {\n type: "GET" /* MessageType.GET */,\n path: path.map((p) => p.toString()),\n }).then(fromWireValue);\n return r.then.bind(r);\n }\n return createProxy(ep, [...path, prop]);\n },\n set(_target, prop, rawValue) {\n throwIfProxyReleased(isProxyReleased);\n // FIXME: ES6 Proxy Handler `set` methods are supposed to return a\n // boolean. To show good will, we return true asynchronously ¯\\_(ツ)_/¯\n const [value, transferables] = toWireValue(rawValue);\n return requestResponseMessage(ep, {\n type: "SET" /* MessageType.SET */,\n path: [...path, prop].map((p) => p.toString()),\n value,\n }, transferables).then(fromWireValue);\n },\n apply(_target, _thisArg, rawArgumentList) {\n throwIfProxyReleased(isProxyReleased);\n const last = path[path.length - 1];\n if (last === createEndpoint) {\n return requestResponseMessage(ep, {\n type: "ENDPOINT" /* MessageType.ENDPOINT */,\n }).then(fromWireValue);\n }\n // We just pretend that `bind()` didn’t happen.\n if (last === "bind") {\n return createProxy(ep, path.slice(0, -1));\n }\n const [argumentList, transferables] = processArguments(rawArgumentList);\n return requestResponseMessage(ep, {\n type: "APPLY" /* MessageType.APPLY */,\n path: path.map((p) => p.toString()),\n argumentList,\n }, transferables).then(fromWireValue);\n },\n construct(_target, rawArgumentList) {\n throwIfProxyReleased(isProxyReleased);\n const [argumentList, transferables] = processArguments(rawArgumentList);\n return requestResponseMessage(ep, {\n type: "CONSTRUCT" /* MessageType.CONSTRUCT */,\n path: path.map((p) => p.toString()),\n argumentList,\n }, transferables).then(fromWireValue);\n },\n });\n registerProxy(proxy, ep);\n return proxy;\n }\n function myFlat(arr) {\n return Array.prototype.concat.apply([], arr);\n }\n function processArguments(argumentList) {\n const processed = argumentList.map(toWireValue);\n return [processed.map((v) => v[0]), myFlat(processed.map((v) => v[1]))];\n }\n const transferCache = new WeakMap();\n function transfer(obj, transfers) {\n transferCache.set(obj, transfers);\n return obj;\n }\n function proxy(obj) {\n return Object.assign(obj, { [proxyMarker]: true });\n }\n function toWireValue(value) {\n for (const [name, handler] of transferHandlers) {\n if (handler.canHandle(value)) {\n const [serializedValue, transferables] = handler.serialize(value);\n return [\n {\n type: "HANDLER" /* WireValueType.HANDLER */,\n name,\n value: serializedValue,\n },\n transferables,\n ];\n }\n }\n return [\n {\n type: "RAW" /* WireValueType.RAW */,\n value,\n },\n transferCache.get(value) || [],\n ];\n }\n function fromWireValue(value) {\n switch (value.type) {\n case "HANDLER" /* WireValueType.HANDLER */:\n return transferHandlers.get(value.name).deserialize(value.value);\n case "RAW" /* WireValueType.RAW */:\n return value.value;\n }\n }\n function requestResponseMessage(ep, msg, transfers) {\n return new Promise((resolve) => {\n const id = generateUUID();\n ep.addEventListener("message", function l(ev) {\n if (!ev.data || !ev.data.id || ev.data.id !== id) {\n return;\n }\n ep.removeEventListener("message", l);\n resolve(ev.data);\n });\n if (ep.start) {\n ep.start();\n }\n ep.postMessage(Object.assign({ id }, msg), transfers);\n });\n }\n function generateUUID() {\n return new Array(4)\n .fill(0)\n .map(() => Math.floor(Math.random() * Number.MAX_SAFE_INTEGER).toString(16))\n .join("-");\n }\n\n /**\n * MatrixRenderer class is meant to be used within a Web Worker context,\n * using Comlink to facilitate communication between the main thread and the worker.\n * The MatrixRenderer class manages a matrix of dies, once an instance of MatrixRenderer is created,\n * it is exposed to the main thread using Comlink\'s `expose` method.\n * This setup is used in the wafer-map component to perform heavy computational duties\n */\n class MatrixRenderer {\n constructor() {\n this.columnIndexes = Int32Array.from([]);\n this.rowIndexes = Int32Array.from([]);\n this.values = Float64Array.from([]);\n this.scaledColumnIndex = Float64Array.from([]);\n this.scaledRowIndex = Float64Array.from([]);\n this.columnIndexPositions = Int32Array.from([]);\n this.scaleX = 1;\n this.scaleY = 1;\n this.baseX = 1;\n this.baseY = 1;\n this.dieDimensions = { width: 1, height: 1 };\n this.transform = { k: 1, x: 0, y: 0 };\n this.smallestMarginPossible = 20;\n this.margin = {\n top: this.smallestMarginPossible,\n right: this.smallestMarginPossible,\n bottom: this.smallestMarginPossible,\n left: this.smallestMarginPossible\n };\n }\n calculateXScaledIndex(columnIndex) {\n return this.scaleX * columnIndex + this.baseX + this.margin.left;\n }\n calculateYScaledIndex(rowIndex) {\n return this.scaleY * rowIndex + this.baseY + this.margin.top;\n }\n setColumnIndexes(columnIndexes) {\n this.columnIndexes = columnIndexes;\n if (columnIndexes.length === 0 || this.columnIndexes[0] === undefined) {\n return;\n }\n const scaledColumnIndex = [\n this.calculateXScaledIndex(this.columnIndexes[0])\n ];\n const columnPositions = [0];\n let prev = this.columnIndexes[0];\n for (let i = 1; i < this.columnIndexes.length; i++) {\n const xIndex = this.columnIndexes[i];\n if (xIndex && xIndex !== prev) {\n const scaledX = this.calculateXScaledIndex(this.columnIndexes[i]);\n scaledColumnIndex.push(scaledX);\n columnPositions.push(i);\n prev = xIndex;\n }\n }\n this.scaledColumnIndex = Float64Array.from(scaledColumnIndex);\n this.columnIndexPositions = Int32Array.from(columnPositions);\n }\n setRowIndexes(rowIndexesBuffer) {\n this.rowIndexes = rowIndexesBuffer;\n this.scaledRowIndex = new Float64Array(this.rowIndexes.length);\n for (let i = 0; i < this.rowIndexes.length; i++) {\n this.scaledRowIndex[i] = this.calculateYScaledIndex(this.rowIndexes[i]);\n }\n }\n setMargin(margin) {\n this.margin = margin;\n }\n setCanvasCorners(topLeft, bottomRight) {\n this.topLeftCanvasCorner = topLeft;\n this.bottomRightCanvasCorner = bottomRight;\n }\n setDiesDimensions(data) {\n this.dieDimensions = { width: data.width, height: data.height };\n }\n setScaling(scaleX, scaleY) {\n this.scaleX = scaleX;\n this.scaleY = scaleY;\n }\n setBases(baseX, baseY) {\n this.baseX = baseX;\n this.baseY = baseY;\n }\n setTransform(transform) {\n this.transform = transform;\n }\n setCanvas(canvas) {\n this.canvas = canvas;\n this.context = canvas.getContext(\'2d\');\n }\n getMatrix() {\n return {\n columnIndexes: this.columnIndexes,\n rowIndexes: this.rowIndexes,\n values: this.values\n };\n }\n emptyMatrix() {\n this.columnIndexes = Int32Array.from([]);\n this.rowIndexes = Int32Array.from([]);\n this.values = Float64Array.from([]);\n }\n scaleCanvas() {\n this.context.translate(this.transform.x, this.transform.y);\n this.context.scale(this.transform.k, this.transform.k);\n }\n updateMatrix(data) {\n this.columnIndexes = Int32Array.from(data.columnIndexes);\n this.rowIndexes = Int32Array.from(data.rowIndexes);\n this.values = Float64Array.from(data.values);\n }\n setCanvasDimensions(data) {\n this.canvas.width = data.width;\n this.canvas.height = data.height;\n }\n getCanvasDimensions() {\n return {\n width: this.canvas.width,\n height: this.canvas.height\n };\n }\n clearCanvas() {\n this.context.clearRect(0, 0, this.canvas.width, this.canvas.height);\n }\n drawWafer() {\n this.context.restore();\n this.context.save();\n this.clearCanvas();\n this.scaleCanvas();\n if (this.topLeftCanvasCorner === undefined\n || this.bottomRightCanvasCorner === undefined) {\n throw new Error(\'Canvas corners are not set\');\n }\n for (let i = 0; i < this.scaledColumnIndex.length; i++) {\n const scaledX = this.scaledColumnIndex[i];\n if (!(scaledX >= this.topLeftCanvasCorner.x\n && scaledX < this.bottomRightCanvasCorner.x)) {\n continue;\n }\n // columnIndexPositions is used to get chunks to determine the start and end index of the column, it looks something like [0, 1, 4, 9, 12]\n // This means that the first column has a start index of 0 and an end index of 1, the second column has a start index of 1 and an end index of 4, and so on\n // scaledRowIndex is used when we reach the end of the columnIndexPositions, when columnIndexPositions is [0, 1, 4, 9, 12], scaledRowIndex is 13\n const columnEndIndex = this.columnIndexPositions[i + 1] !== undefined\n ? this.columnIndexPositions[i + 1]\n : this.scaledRowIndex.length;\n for (let columnStartIndex = this.columnIndexPositions[i]; columnStartIndex < columnEndIndex; columnStartIndex++) {\n const scaledY = this.scaledRowIndex[columnStartIndex];\n if (!(scaledY >= this.topLeftCanvasCorner.y\n && scaledY < this.bottomRightCanvasCorner.y)) {\n continue;\n }\n // Fill style is temporary green for all dies, will be replaced with a color based on the value of the die in a future implementation\n this.context.fillStyle = \'Green\';\n this.context.fillRect(scaledX, scaledY, this.dieDimensions.width, this.dieDimensions.height);\n }\n }\n }\n }\n expose(MatrixRenderer);\n\n exports.MatrixRenderer = MatrixRenderer;\n\n return exports;\n\n})({});\n'],{type:"text/javascript"})
13016
- iq=URL.createObjectURL(e)}const e=new Worker(iq),t=jB(e)
13031
+ var n}const QB=new WeakMap
13032
+ function eq(e,t){return QB.set(e,t),e}function tq(e){for(const[t,n]of qB)if(n.canHandle(e)){const[i,o]=n.serialize(e)
13033
+ return[{type:"HANDLER",name:t,value:i},o]}return[{type:"RAW",value:e},QB.get(e)||[]]}function nq(e){switch(e.type){case"HANDLER":return qB.get(e.name).deserialize(e.value)
13034
+ case"RAW":return e.value}}function iq(e,t,n){return new Promise((i=>{const o=new Array(4).fill(0).map((()=>Math.floor(Math.random()*Number.MAX_SAFE_INTEGER).toString(16))).join("-")
13035
+ e.addEventListener("message",(function t(n){n.data&&n.data.id&&n.data.id===o&&(e.removeEventListener("message",t),i(n.data))})),e.start&&e.start(),e.postMessage(Object.assign({id:o},t),n)}))}let oq
13036
+ class rq{constructor(e){this.wafermap=e}async setupWafer(){if(void 0===this.matrixRenderer){const{matrixRenderer:e}=await(async()=>{if(void 0===oq){const e=new Blob(['var MatrixRenderer = (function (exports) {\n \'use strict\';\n\n /**\n * @license\n * Copyright 2019 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n */\n const proxyMarker = Symbol("Comlink.proxy");\n const createEndpoint = Symbol("Comlink.endpoint");\n const releaseProxy = Symbol("Comlink.releaseProxy");\n const finalizer = Symbol("Comlink.finalizer");\n const throwMarker = Symbol("Comlink.thrown");\n const isObject = (val) => (typeof val === "object" && val !== null) || typeof val === "function";\n /**\n * Internal transfer handle to handle objects marked to proxy.\n */\n const proxyTransferHandler = {\n canHandle: (val) => isObject(val) && val[proxyMarker],\n serialize(obj) {\n const { port1, port2 } = new MessageChannel();\n expose(obj, port1);\n return [port2, [port2]];\n },\n deserialize(port) {\n port.start();\n return wrap(port);\n },\n };\n /**\n * Internal transfer handler to handle thrown exceptions.\n */\n const throwTransferHandler = {\n canHandle: (value) => isObject(value) && throwMarker in value,\n serialize({ value }) {\n let serialized;\n if (value instanceof Error) {\n serialized = {\n isError: true,\n value: {\n message: value.message,\n name: value.name,\n stack: value.stack,\n },\n };\n }\n else {\n serialized = { isError: false, value };\n }\n return [serialized, []];\n },\n deserialize(serialized) {\n if (serialized.isError) {\n throw Object.assign(new Error(serialized.value.message), serialized.value);\n }\n throw serialized.value;\n },\n };\n /**\n * Allows customizing the serialization of certain values.\n */\n const transferHandlers = new Map([\n ["proxy", proxyTransferHandler],\n ["throw", throwTransferHandler],\n ]);\n function isAllowedOrigin(allowedOrigins, origin) {\n for (const allowedOrigin of allowedOrigins) {\n if (origin === allowedOrigin || allowedOrigin === "*") {\n return true;\n }\n if (allowedOrigin instanceof RegExp && allowedOrigin.test(origin)) {\n return true;\n }\n }\n return false;\n }\n function expose(obj, ep = globalThis, allowedOrigins = ["*"]) {\n ep.addEventListener("message", function callback(ev) {\n if (!ev || !ev.data) {\n return;\n }\n if (!isAllowedOrigin(allowedOrigins, ev.origin)) {\n console.warn(`Invalid origin \'${ev.origin}\' for comlink proxy`);\n return;\n }\n const { id, type, path } = Object.assign({ path: [] }, ev.data);\n const argumentList = (ev.data.argumentList || []).map(fromWireValue);\n let returnValue;\n try {\n const parent = path.slice(0, -1).reduce((obj, prop) => obj[prop], obj);\n const rawValue = path.reduce((obj, prop) => obj[prop], obj);\n switch (type) {\n case "GET" /* MessageType.GET */:\n {\n returnValue = rawValue;\n }\n break;\n case "SET" /* MessageType.SET */:\n {\n parent[path.slice(-1)[0]] = fromWireValue(ev.data.value);\n returnValue = true;\n }\n break;\n case "APPLY" /* MessageType.APPLY */:\n {\n returnValue = rawValue.apply(parent, argumentList);\n }\n break;\n case "CONSTRUCT" /* MessageType.CONSTRUCT */:\n {\n const value = new rawValue(...argumentList);\n returnValue = proxy(value);\n }\n break;\n case "ENDPOINT" /* MessageType.ENDPOINT */:\n {\n const { port1, port2 } = new MessageChannel();\n expose(obj, port2);\n returnValue = transfer(port1, [port1]);\n }\n break;\n case "RELEASE" /* MessageType.RELEASE */:\n {\n returnValue = undefined;\n }\n break;\n default:\n return;\n }\n }\n catch (value) {\n returnValue = { value, [throwMarker]: 0 };\n }\n Promise.resolve(returnValue)\n .catch((value) => {\n return { value, [throwMarker]: 0 };\n })\n .then((returnValue) => {\n const [wireValue, transferables] = toWireValue(returnValue);\n ep.postMessage(Object.assign(Object.assign({}, wireValue), { id }), transferables);\n if (type === "RELEASE" /* MessageType.RELEASE */) {\n // detach and deactive after sending release response above.\n ep.removeEventListener("message", callback);\n closeEndPoint(ep);\n if (finalizer in obj && typeof obj[finalizer] === "function") {\n obj[finalizer]();\n }\n }\n })\n .catch((error) => {\n // Send Serialization Error To Caller\n const [wireValue, transferables] = toWireValue({\n value: new TypeError("Unserializable return value"),\n [throwMarker]: 0,\n });\n ep.postMessage(Object.assign(Object.assign({}, wireValue), { id }), transferables);\n });\n });\n if (ep.start) {\n ep.start();\n }\n }\n function isMessagePort(endpoint) {\n return endpoint.constructor.name === "MessagePort";\n }\n function closeEndPoint(endpoint) {\n if (isMessagePort(endpoint))\n endpoint.close();\n }\n function wrap(ep, target) {\n return createProxy(ep, [], target);\n }\n function throwIfProxyReleased(isReleased) {\n if (isReleased) {\n throw new Error("Proxy has been released and is not useable");\n }\n }\n function releaseEndpoint(ep) {\n return requestResponseMessage(ep, {\n type: "RELEASE" /* MessageType.RELEASE */,\n }).then(() => {\n closeEndPoint(ep);\n });\n }\n const proxyCounter = new WeakMap();\n const proxyFinalizers = "FinalizationRegistry" in globalThis &&\n new FinalizationRegistry((ep) => {\n const newCount = (proxyCounter.get(ep) || 0) - 1;\n proxyCounter.set(ep, newCount);\n if (newCount === 0) {\n releaseEndpoint(ep);\n }\n });\n function registerProxy(proxy, ep) {\n const newCount = (proxyCounter.get(ep) || 0) + 1;\n proxyCounter.set(ep, newCount);\n if (proxyFinalizers) {\n proxyFinalizers.register(proxy, ep, proxy);\n }\n }\n function unregisterProxy(proxy) {\n if (proxyFinalizers) {\n proxyFinalizers.unregister(proxy);\n }\n }\n function createProxy(ep, path = [], target = function () { }) {\n let isProxyReleased = false;\n const proxy = new Proxy(target, {\n get(_target, prop) {\n throwIfProxyReleased(isProxyReleased);\n if (prop === releaseProxy) {\n return () => {\n unregisterProxy(proxy);\n releaseEndpoint(ep);\n isProxyReleased = true;\n };\n }\n if (prop === "then") {\n if (path.length === 0) {\n return { then: () => proxy };\n }\n const r = requestResponseMessage(ep, {\n type: "GET" /* MessageType.GET */,\n path: path.map((p) => p.toString()),\n }).then(fromWireValue);\n return r.then.bind(r);\n }\n return createProxy(ep, [...path, prop]);\n },\n set(_target, prop, rawValue) {\n throwIfProxyReleased(isProxyReleased);\n // FIXME: ES6 Proxy Handler `set` methods are supposed to return a\n // boolean. To show good will, we return true asynchronously ¯\\_(ツ)_/¯\n const [value, transferables] = toWireValue(rawValue);\n return requestResponseMessage(ep, {\n type: "SET" /* MessageType.SET */,\n path: [...path, prop].map((p) => p.toString()),\n value,\n }, transferables).then(fromWireValue);\n },\n apply(_target, _thisArg, rawArgumentList) {\n throwIfProxyReleased(isProxyReleased);\n const last = path[path.length - 1];\n if (last === createEndpoint) {\n return requestResponseMessage(ep, {\n type: "ENDPOINT" /* MessageType.ENDPOINT */,\n }).then(fromWireValue);\n }\n // We just pretend that `bind()` didn’t happen.\n if (last === "bind") {\n return createProxy(ep, path.slice(0, -1));\n }\n const [argumentList, transferables] = processArguments(rawArgumentList);\n return requestResponseMessage(ep, {\n type: "APPLY" /* MessageType.APPLY */,\n path: path.map((p) => p.toString()),\n argumentList,\n }, transferables).then(fromWireValue);\n },\n construct(_target, rawArgumentList) {\n throwIfProxyReleased(isProxyReleased);\n const [argumentList, transferables] = processArguments(rawArgumentList);\n return requestResponseMessage(ep, {\n type: "CONSTRUCT" /* MessageType.CONSTRUCT */,\n path: path.map((p) => p.toString()),\n argumentList,\n }, transferables).then(fromWireValue);\n },\n });\n registerProxy(proxy, ep);\n return proxy;\n }\n function myFlat(arr) {\n return Array.prototype.concat.apply([], arr);\n }\n function processArguments(argumentList) {\n const processed = argumentList.map(toWireValue);\n return [processed.map((v) => v[0]), myFlat(processed.map((v) => v[1]))];\n }\n const transferCache = new WeakMap();\n function transfer(obj, transfers) {\n transferCache.set(obj, transfers);\n return obj;\n }\n function proxy(obj) {\n return Object.assign(obj, { [proxyMarker]: true });\n }\n function toWireValue(value) {\n for (const [name, handler] of transferHandlers) {\n if (handler.canHandle(value)) {\n const [serializedValue, transferables] = handler.serialize(value);\n return [\n {\n type: "HANDLER" /* WireValueType.HANDLER */,\n name,\n value: serializedValue,\n },\n transferables,\n ];\n }\n }\n return [\n {\n type: "RAW" /* WireValueType.RAW */,\n value,\n },\n transferCache.get(value) || [],\n ];\n }\n function fromWireValue(value) {\n switch (value.type) {\n case "HANDLER" /* WireValueType.HANDLER */:\n return transferHandlers.get(value.name).deserialize(value.value);\n case "RAW" /* WireValueType.RAW */:\n return value.value;\n }\n }\n function requestResponseMessage(ep, msg, transfers) {\n return new Promise((resolve) => {\n const id = generateUUID();\n ep.addEventListener("message", function l(ev) {\n if (!ev.data || !ev.data.id || ev.data.id !== id) {\n return;\n }\n ep.removeEventListener("message", l);\n resolve(ev.data);\n });\n if (ep.start) {\n ep.start();\n }\n ep.postMessage(Object.assign({ id }, msg), transfers);\n });\n }\n function generateUUID() {\n return new Array(4)\n .fill(0)\n .map(() => Math.floor(Math.random() * Number.MAX_SAFE_INTEGER).toString(16))\n .join("-");\n }\n\n /**\n * MatrixRenderer class is meant to be used within a Web Worker context,\n * using Comlink to facilitate communication between the main thread and the worker.\n * The MatrixRenderer class manages a matrix of dies, once an instance of MatrixRenderer is created,\n * it is exposed to the main thread using Comlink\'s `expose` method.\n * This setup is used in the wafer-map component to perform heavy computational duties\n */\n class MatrixRenderer {\n constructor() {\n this.columnIndexes = Int32Array.from([]);\n this.rowIndexes = Int32Array.from([]);\n this.values = Float64Array.from([]);\n this.scaledColumnIndex = Float64Array.from([]);\n this.scaledRowIndex = Float64Array.from([]);\n this.columnIndexPositions = Int32Array.from([]);\n this.scaleX = 1;\n this.scaleY = 1;\n this.baseX = 1;\n this.baseY = 1;\n this.dieDimensions = { width: 1, height: 1 };\n this.transform = { k: 1, x: 0, y: 0 };\n this.smallestMarginPossible = 20;\n this.margin = {\n top: this.smallestMarginPossible,\n right: this.smallestMarginPossible,\n bottom: this.smallestMarginPossible,\n left: this.smallestMarginPossible\n };\n }\n calculateXScaledIndex(columnIndex) {\n return this.scaleX * columnIndex + this.baseX + this.margin.left;\n }\n calculateYScaledIndex(rowIndex) {\n return this.scaleY * rowIndex + this.baseY + this.margin.top;\n }\n setColumnIndexes(columnIndexes) {\n this.columnIndexes = columnIndexes;\n if (columnIndexes.length === 0 || this.columnIndexes[0] === undefined) {\n return;\n }\n const scaledColumnIndex = [\n this.calculateXScaledIndex(this.columnIndexes[0])\n ];\n const columnPositions = [0];\n let prev = this.columnIndexes[0];\n for (let i = 1; i < this.columnIndexes.length; i++) {\n const xIndex = this.columnIndexes[i];\n if (xIndex && xIndex !== prev) {\n const scaledX = this.calculateXScaledIndex(this.columnIndexes[i]);\n scaledColumnIndex.push(scaledX);\n columnPositions.push(i);\n prev = xIndex;\n }\n }\n this.scaledColumnIndex = Float64Array.from(scaledColumnIndex);\n this.columnIndexPositions = Int32Array.from(columnPositions);\n }\n setRowIndexes(rowIndexesBuffer) {\n this.rowIndexes = rowIndexesBuffer;\n this.scaledRowIndex = new Float64Array(this.rowIndexes.length);\n for (let i = 0; i < this.rowIndexes.length; i++) {\n this.scaledRowIndex[i] = this.calculateYScaledIndex(this.rowIndexes[i]);\n }\n }\n setMargin(margin) {\n this.margin = margin;\n }\n setCanvasCorners(topLeft, bottomRight) {\n this.topLeftCanvasCorner = topLeft;\n this.bottomRightCanvasCorner = bottomRight;\n }\n setDiesDimensions(data) {\n this.dieDimensions = { width: data.width, height: data.height };\n }\n setScaling(scaleX, scaleY) {\n this.scaleX = scaleX;\n this.scaleY = scaleY;\n }\n setBases(baseX, baseY) {\n this.baseX = baseX;\n this.baseY = baseY;\n }\n setTransform(transform) {\n this.transform = transform;\n }\n setCanvas(canvas) {\n this.canvas = canvas;\n this.context = canvas.getContext(\'2d\');\n }\n getMatrix() {\n return {\n columnIndexes: this.columnIndexes,\n rowIndexes: this.rowIndexes,\n values: this.values\n };\n }\n emptyMatrix() {\n this.columnIndexes = Int32Array.from([]);\n this.rowIndexes = Int32Array.from([]);\n this.values = Float64Array.from([]);\n }\n scaleCanvas() {\n this.context.translate(this.transform.x, this.transform.y);\n this.context.scale(this.transform.k, this.transform.k);\n }\n updateMatrix(data) {\n this.columnIndexes = Int32Array.from(data.columnIndexes);\n this.rowIndexes = Int32Array.from(data.rowIndexes);\n this.values = Float64Array.from(data.values);\n }\n setCanvasDimensions(data) {\n this.canvas.width = data.width;\n this.canvas.height = data.height;\n }\n getCanvasDimensions() {\n return {\n width: this.canvas.width,\n height: this.canvas.height\n };\n }\n clearCanvas() {\n this.context.clearRect(0, 0, this.canvas.width, this.canvas.height);\n }\n drawWafer() {\n this.context.restore();\n this.context.save();\n this.clearCanvas();\n this.scaleCanvas();\n if (this.topLeftCanvasCorner === undefined\n || this.bottomRightCanvasCorner === undefined) {\n throw new Error(\'Canvas corners are not set\');\n }\n for (let i = 0; i < this.scaledColumnIndex.length; i++) {\n const scaledX = this.scaledColumnIndex[i];\n if (!(scaledX >= this.topLeftCanvasCorner.x\n && scaledX < this.bottomRightCanvasCorner.x)) {\n continue;\n }\n // columnIndexPositions is used to get chunks to determine the start and end index of the column, it looks something like [0, 1, 4, 9, 12]\n // This means that the first column has a start index of 0 and an end index of 1, the second column has a start index of 1 and an end index of 4, and so on\n // scaledRowIndex is used when we reach the end of the columnIndexPositions, when columnIndexPositions is [0, 1, 4, 9, 12], scaledRowIndex is 13\n const columnEndIndex = this.columnIndexPositions[i + 1] !== undefined\n ? this.columnIndexPositions[i + 1]\n : this.scaledRowIndex.length;\n for (let columnStartIndex = this.columnIndexPositions[i]; columnStartIndex < columnEndIndex; columnStartIndex++) {\n const scaledY = this.scaledRowIndex[columnStartIndex];\n if (!(scaledY >= this.topLeftCanvasCorner.y\n && scaledY < this.bottomRightCanvasCorner.y)) {\n continue;\n }\n // Fill style is temporary green for all dies, will be replaced with a color based on the value of the die in a future implementation\n this.context.fillStyle = \'Green\';\n this.context.fillRect(scaledX, scaledY, this.dieDimensions.width, this.dieDimensions.height);\n }\n }\n }\n }\n expose(MatrixRenderer);\n\n exports.MatrixRenderer = MatrixRenderer;\n\n return exports;\n\n})({});\n'],{type:"text/javascript"})
13037
+ oq=URL.createObjectURL(e)}const e=new Worker(oq),t=WB(e)
13017
13038
  return{matrixRenderer:await new t,terminate:()=>e.terminate()}})()
13018
13039
  this.matrixRenderer=e
13019
13040
  const t=this.wafermap.workerCanvas.transferControlToOffscreen()
13020
- await this.matrixRenderer.setCanvas(QB(t,[t]))}await this.matrixRenderer.setCanvasDimensions({width:this.wafermap.canvasWidth??0,height:this.wafermap.canvasHeight??0}),await this.matrixRenderer.setDiesDimensions(this.wafermap.experimentalDataManager.dieDimensions)
13041
+ await this.matrixRenderer.setCanvas(eq(t,[t]))}await this.matrixRenderer.setCanvasDimensions({width:this.wafermap.canvasWidth??0,height:this.wafermap.canvasHeight??0}),await this.matrixRenderer.setDiesDimensions(this.wafermap.experimentalDataManager.dieDimensions)
13021
13042
  const e=this.wafermap.experimentalDataManager.horizontalScale(1)-this.wafermap.experimentalDataManager.horizontalScale(0),t=this.wafermap.experimentalDataManager.verticalScale(1)-this.wafermap.experimentalDataManager.verticalScale(0)
13022
13043
  if(await this.matrixRenderer.setScaling(e,t),await this.matrixRenderer.setBases(this.wafermap.experimentalDataManager.horizontalScale(0),this.wafermap.experimentalDataManager.verticalScale(0)),await this.matrixRenderer.setMargin(this.wafermap.experimentalDataManager.margin),void 0===this.wafermap.diesTable)return await this.matrixRenderer.setColumnIndexes(Int32Array.from([])),void await this.matrixRenderer.setRowIndexes(Int32Array.from([]))
13023
13044
  const n=this.wafermap.diesTable.getChild("colIndex").toArray()
@@ -13025,18 +13046,18 @@ await this.matrixRenderer.setColumnIndexes(n)
13025
13046
  const i=this.wafermap.diesTable.getChild("rowIndex").toArray()
13026
13047
  await this.matrixRenderer.setRowIndexes(i)}async drawWafer(){await this.matrixRenderer.setTransform(this.wafermap.transform)
13027
13048
  const e=this.wafermap.transform.invert([0,0]),t=this.wafermap.transform.invert([this.wafermap.canvasWidth,this.wafermap.canvasHeight])
13028
- await this.matrixRenderer.setCanvasCorners({x:e[0]-this.wafermap.experimentalDataManager.dieDimensions.width,y:e[1]-this.wafermap.experimentalDataManager.dieDimensions.height},{x:t[0],y:t[1]}),await this.matrixRenderer.drawWafer(),this.renderHover()}renderHover(){this.wafermap.hoverWidth=this.wafermap.experimentalDataManager.dieDimensions.width*this.wafermap.transform.k,this.wafermap.hoverHeight=this.wafermap.experimentalDataManager.dieDimensions.height*this.wafermap.transform.k,this.wafermap.hoverOpacity=void 0===this.wafermap.hoverDie?ZH:WH,this.wafermap.hoverTransform=this.calculateHoverTransform()}calculateHoverTransform(){if(void 0!==this.wafermap.hoverDie){const e=this.wafermap.experimentalDataManager.horizontalScale(this.wafermap.hoverDie.x)
13049
+ await this.matrixRenderer.setCanvasCorners({x:e[0]-this.wafermap.experimentalDataManager.dieDimensions.width,y:e[1]-this.wafermap.experimentalDataManager.dieDimensions.height},{x:t[0],y:t[1]}),await this.matrixRenderer.drawWafer(),this.renderHover()}renderHover(){this.wafermap.hoverWidth=this.wafermap.experimentalDataManager.dieDimensions.width*this.wafermap.transform.k,this.wafermap.hoverHeight=this.wafermap.experimentalDataManager.dieDimensions.height*this.wafermap.transform.k,this.wafermap.hoverOpacity=void 0===this.wafermap.hoverDie?GH:ZH,this.wafermap.hoverTransform=this.calculateHoverTransform()}calculateHoverTransform(){if(void 0!==this.wafermap.hoverDie){const e=this.wafermap.experimentalDataManager.horizontalScale(this.wafermap.hoverDie.x)
13029
13050
  if(void 0===e)return""
13030
13051
  const t=this.wafermap.experimentalDataManager.verticalScale(this.wafermap.hoverDie.y)
13031
13052
  if(void 0===t)return""
13032
13053
  const n=this.wafermap.transform.apply([e+this.wafermap.experimentalDataManager.margin.left,t+this.wafermap.experimentalDataManager.margin.top])
13033
- return`translate(${n[0]}, ${n[1]})`}return""}}class rq{constructor(e){this.wafermap=e,this.onMouseMove=e=>{if(!this.wafermap.isExperimentalUpdate())return
13054
+ return`translate(${n[0]}, ${n[1]})`}return""}}class sq{constructor(e){this.wafermap=e,this.onMouseMove=e=>{if(!this.wafermap.isExperimentalUpdate())return
13034
13055
  const t=this.wafermap.transform.invert([e.offsetX,e.offsetY]),n=this.calculateDieCoordinates({x:t[0],y:t[1]})
13035
13056
  if(void 0===n)return void(this.wafermap.hoverDie=void 0)
13036
13057
  const i=this.wafermap.diesTable.getChild("colIndex").toArray(),o=this.wafermap.diesTable.getChild("rowIndex").toArray()
13037
13058
  for(let e=0;e<i.length;e++)if(i[e]===n.x&&o[e]===n.y)return void(this.wafermap.hoverDie={index:e,x:n.x,y:n.y})
13038
- this.wafermap.hoverDie=void 0},this.onMouseOut=e=>{this.wafermap.hoverDie=void 0}}connect(){this.wafermap.addEventListener("mousemove",this.onMouseMove),this.wafermap.addEventListener("mouseout",this.onMouseOut)}disconnect(){this.wafermap.removeEventListener("mousemove",this.onMouseMove),this.wafermap.removeEventListener("mouseout",this.onMouseOut)}calculateDieCoordinates(e){if(this.wafermap.isExperimentalUpdate()){const t=this.wafermap.originLocation,n=t===BH||t===UH?Math.floor:Math.ceil,i=t===BH||t===qH?Math.ceil:Math.floor
13039
- return{x:n(this.wafermap.experimentalDataManager.horizontalScale.invert(e.x-this.wafermap.experimentalDataManager.margin.left)),y:i(this.wafermap.experimentalDataManager.verticalScale.invert(e.y-this.wafermap.experimentalDataManager.margin.top))}}}}class sq{constructor(e){this.wafermap=e,this.scaleExtent=[1,100],this.minExtentPoint=[0,0],this.onWheelMove=e=>{e.preventDefault()},this.wafermapNotifier=m.getNotifier(this.wafermap),this.wafermapNotifier.subscribe(this,"canvasWidth"),this.wafermapNotifier.subscribe(this,"canvasHeight")}connect(){this.createZoomBehavior(),this.wafermap.addEventListener("wheel",this.onWheelMove,{passive:!1})}disconnect(){ZV().on("zoom",null)($L(this.wafermap)),this.wafermap.removeEventListener("wheel",this.onWheelMove)}handleChange(e,t){e!==this.wafermap||"canvasWidth"!==t&&"canvasHeight"!==t||this.createZoomBehavior()}createZoomBehavior(){ZV().scaleExtent(this.scaleExtent).translateExtent([this.minExtentPoint,[this.wafermap.canvasWidth,this.wafermap.canvasHeight]]).on("zoom",(e=>{this.wafermap.transform=e.transform}))($L(this.wafermap))}}class aq extends Vt{constructor(){super(...arguments),this.waferMapUpdateTracker=new tB(this.asRequiredFieldsWaferMap),this.originLocation=BH,this.gridMinX=void 0,this.gridMaxX=void 0,this.gridMinY=void 0,this.gridMaxY=void 0,this.orientation=jH,this.maxCharacters=4,this.dieLabelsHidden=!1,this.dieLabelsSuffix="",this.colorScaleMode=GH,this.experimentalDataManager=new JH(this.asRequiredFieldsWaferMap),this.dataManager=new class{get containerDimensions(){return this.computations.containerDimensions}get dieDimensions(){return this.computations.dieDimensions}get radius(){return this.computations.radius}get margin(){return this.computations.margin}get horizontalScale(){return this.computations.horizontalScale}get invertedHorizontalScale(){return this.computations.invertedHorizontalScale}get verticalScale(){return this.computations.verticalScale}get invertedVerticalScale(){return this.computations.invertedVerticalScale}get labelsFontSize(){return this.prerendering.labelsFontSize}get diesRenderInfo(){return this.prerendering.diesRenderInfo}get data(){return this.dataMap}constructor(e){this.wafermap=e,this.computations=new class{get containerDimensions(){return this._containerDimensions}get dieDimensions(){return this._dieDimensions}get radius(){return this._radius}get margin(){return this._margin}get horizontalScale(){return this._horizontalScale}get verticalScale(){return this._verticalScale}get invertedHorizontalScale(){return this._invertedHorizontalScale}get invertedVerticalScale(){return this._invertedVerticalScale}constructor(e){this.wafermap=e,this.defaultPadding=0,this.baseMarginPercentage=.04}updateContainerDimensions(){const e={width:this.wafermap.canvasWidth,height:this.wafermap.canvasHeight},t=Math.min(e.width,e.height),n={top:(e.height-t)/2,right:(e.width-t)/2,bottom:(e.height-t)/2,left:(e.width-t)/2},i={top:t*this.baseMarginPercentage,right:t*this.baseMarginPercentage,bottom:t*this.baseMarginPercentage,left:t*this.baseMarginPercentage}
13059
+ this.wafermap.hoverDie=void 0},this.onMouseOut=e=>{this.wafermap.hoverDie=void 0}}connect(){this.wafermap.addEventListener("mousemove",this.onMouseMove),this.wafermap.addEventListener("mouseout",this.onMouseOut)}disconnect(){this.wafermap.removeEventListener("mousemove",this.onMouseMove),this.wafermap.removeEventListener("mouseout",this.onMouseOut)}calculateDieCoordinates(e){if(this.wafermap.isExperimentalUpdate()){const t=this.wafermap.originLocation,n=t===qH||t===jH?Math.floor:Math.ceil,i=t===qH||t===UH?Math.ceil:Math.floor
13060
+ return{x:n(this.wafermap.experimentalDataManager.horizontalScale.invert(e.x-this.wafermap.experimentalDataManager.margin.left)),y:i(this.wafermap.experimentalDataManager.verticalScale.invert(e.y-this.wafermap.experimentalDataManager.margin.top))}}}}class aq{constructor(e){this.wafermap=e,this.scaleExtent=[1,100],this.minExtentPoint=[0,0],this.onWheelMove=e=>{e.preventDefault()},this.wafermapNotifier=m.getNotifier(this.wafermap),this.wafermapNotifier.subscribe(this,"canvasWidth"),this.wafermapNotifier.subscribe(this,"canvasHeight")}connect(){this.createZoomBehavior(),this.wafermap.addEventListener("wheel",this.onWheelMove,{passive:!1})}disconnect(){GV().on("zoom",null)(ML(this.wafermap)),this.wafermap.removeEventListener("wheel",this.onWheelMove)}handleChange(e,t){e!==this.wafermap||"canvasWidth"!==t&&"canvasHeight"!==t||this.createZoomBehavior()}createZoomBehavior(){GV().scaleExtent(this.scaleExtent).translateExtent([this.minExtentPoint,[this.wafermap.canvasWidth,this.wafermap.canvasHeight]]).on("zoom",(e=>{this.wafermap.transform=e.transform}))(ML(this.wafermap))}}class lq extends Vt{constructor(){super(...arguments),this.waferMapUpdateTracker=new nB(this.asRequiredFieldsWaferMap),this.originLocation=qH,this.gridMinX=void 0,this.gridMaxX=void 0,this.gridMinY=void 0,this.gridMaxY=void 0,this.orientation=WH,this.maxCharacters=4,this.dieLabelsHidden=!1,this.dieLabelsSuffix="",this.colorScaleMode=KH,this.experimentalDataManager=new QH(this.asRequiredFieldsWaferMap),this.dataManager=new class{get containerDimensions(){return this.computations.containerDimensions}get dieDimensions(){return this.computations.dieDimensions}get radius(){return this.computations.radius}get margin(){return this.computations.margin}get horizontalScale(){return this.computations.horizontalScale}get invertedHorizontalScale(){return this.computations.invertedHorizontalScale}get verticalScale(){return this.computations.verticalScale}get invertedVerticalScale(){return this.computations.invertedVerticalScale}get labelsFontSize(){return this.prerendering.labelsFontSize}get diesRenderInfo(){return this.prerendering.diesRenderInfo}get data(){return this.dataMap}constructor(e){this.wafermap=e,this.computations=new class{get containerDimensions(){return this._containerDimensions}get dieDimensions(){return this._dieDimensions}get radius(){return this._radius}get margin(){return this._margin}get horizontalScale(){return this._horizontalScale}get verticalScale(){return this._verticalScale}get invertedHorizontalScale(){return this._invertedHorizontalScale}get invertedVerticalScale(){return this._invertedVerticalScale}constructor(e){this.wafermap=e,this.defaultPadding=0,this.baseMarginPercentage=.04}updateContainerDimensions(){const e={width:this.wafermap.canvasWidth,height:this.wafermap.canvasHeight},t=Math.min(e.width,e.height),n={top:(e.height-t)/2,right:(e.width-t)/2,bottom:(e.height-t)/2,left:(e.width-t)/2},i={top:t*this.baseMarginPercentage,right:t*this.baseMarginPercentage,bottom:t*this.baseMarginPercentage,left:t*this.baseMarginPercentage}
13040
13061
  this._margin=this.calculateMarginAddition(i,n),this._containerDimensions=this.calculateContainerDimensions(e,this._margin)
13041
13062
  const o=Math.min(this._containerDimensions.width,this._containerDimensions.height)
13042
13063
  this._radius=o/2,this.updateScales()}updateScales(){const e=Math.min(this._containerDimensions.width,this._containerDimensions.height),t=this.gridDimensionsValidAndDefined()?this.calculateGridDimensionsFromBoundingBox():this.calculateGridDimensionsFromDies(this.wafermap.dies),n=this.wafermap.originLocation
@@ -13044,32 +13065,32 @@ this._horizontalScale=this.createHorizontalScale(n,t,e),this._invertedHorizontal
13044
13065
  return"number"==typeof this.wafermap.gridMaxY&&"number"==typeof this.wafermap.gridMinY&&"number"==typeof this.wafermap.gridMaxX&&"number"==typeof this.wafermap.gridMinX&&(e.origin.x=this.wafermap.gridMinX,e.origin.y=this.wafermap.gridMinY,e.rows=this.wafermap.gridMaxY-this.wafermap.gridMinY+1,e.cols=this.wafermap.gridMaxX-this.wafermap.gridMinX+1),e}calculateGridDimensionsFromDies(e){if(0===e.length||void 0===e[0])return{origin:{x:0,y:0},rows:0,cols:0}
13045
13066
  const t={x:e[0].x,y:e[0].y},n={x:e[0].x,y:e[0].y}
13046
13067
  for(const i of e)i.x<t.x&&(t.x=i.x),i.y<t.y&&(t.y=i.y),i.x>n.x&&(n.x=i.x),i.y>n.y&&(n.y=i.y)
13047
- return{origin:t,rows:n.y-t.y+1,cols:n.x-t.x+1}}calculateContainerDimensions(e,t){return{width:e.width-t.left-t.right,height:e.height-t.top-t.bottom}}createHorizontalScale(e,t,n){const i=gH().domain(uH(t.origin.x,t.origin.x+t.cols)).paddingInner(0).paddingOuter(0).align(0).round(!1)
13048
- return e===BH||e===UH?i.range([0,n]):i.range([n,0])}createInvertedHorizontalScale(e,t,n){const i=HH().domain([0,n])
13049
- return e===BH||e===UH?i.range(uH(t.origin.x,t.origin.x+t.cols)):i.range(uH(t.origin.x,t.origin.x+t.cols).reverse())}createVerticalScale(e,t,n){const i=gH().domain(uH(t.origin.y,t.origin.y+t.rows)).paddingInner(this.defaultPadding).paddingOuter(0).align(0).round(!1)
13050
- return e===BH||e===qH?i.range([n,0]):i.range([0,n])}createInvertedVerticalScale(e,t,n){const i=HH().domain([0,n])
13051
- return e===BH||e===qH?i.range(uH(t.origin.y,t.origin.y+t.rows).reverse()):i.range(uH(t.origin.y,t.origin.y+t.rows))}calculateMarginAddition(e,t){return{top:e.top+t.top,right:e.right+t.right,bottom:e.bottom+t.bottom,left:e.left+t.left}}}(e),this.prerendering=new class{get labelsFontSize(){return this._labelsFontSize}get diesRenderInfo(){return this._diesRenderInfo}constructor(e){this.wafermap=e,this.fontSizeFactor=.8,this.nonHighlightedOpacity=.3,this.emptyDieColor="rgba(218,223,236,1)",this.nanDieColor="rgba(122,122,122,1)"}updateLabelsFontSize(){this._labelsFontSize=this.calculateLabelsFontSize(this.wafermap.dataManager.dieDimensions,this.wafermap.maxCharacters),this.updateDiesRenderInfo()}updateDiesRenderInfo(){this.d3ColorScale=this.createD3ColorScale(this.wafermap.colorScale,this.wafermap.colorScaleMode)
13068
+ return{origin:t,rows:n.y-t.y+1,cols:n.x-t.x+1}}calculateContainerDimensions(e,t){return{width:e.width-t.left-t.right,height:e.height-t.top-t.bottom}}createHorizontalScale(e,t,n){const i=vH().domain(pH(t.origin.x,t.origin.x+t.cols)).paddingInner(0).paddingOuter(0).align(0).round(!1)
13069
+ return e===qH||e===jH?i.range([0,n]):i.range([n,0])}createInvertedHorizontalScale(e,t,n){const i=BH().domain([0,n])
13070
+ return e===qH||e===jH?i.range(pH(t.origin.x,t.origin.x+t.cols)):i.range(pH(t.origin.x,t.origin.x+t.cols).reverse())}createVerticalScale(e,t,n){const i=vH().domain(pH(t.origin.y,t.origin.y+t.rows)).paddingInner(this.defaultPadding).paddingOuter(0).align(0).round(!1)
13071
+ return e===qH||e===UH?i.range([n,0]):i.range([0,n])}createInvertedVerticalScale(e,t,n){const i=BH().domain([0,n])
13072
+ return e===qH||e===UH?i.range(pH(t.origin.y,t.origin.y+t.rows).reverse()):i.range(pH(t.origin.y,t.origin.y+t.rows))}calculateMarginAddition(e,t){return{top:e.top+t.top,right:e.right+t.right,bottom:e.bottom+t.bottom,left:e.left+t.left}}}(e),this.prerendering=new class{get labelsFontSize(){return this._labelsFontSize}get diesRenderInfo(){return this._diesRenderInfo}constructor(e){this.wafermap=e,this.fontSizeFactor=.8,this.nonHighlightedOpacity=.3,this.emptyDieColor="rgba(218,223,236,1)",this.nanDieColor="rgba(122,122,122,1)"}updateLabelsFontSize(){this._labelsFontSize=this.calculateLabelsFontSize(this.wafermap.dataManager.dieDimensions,this.wafermap.maxCharacters),this.updateDiesRenderInfo()}updateDiesRenderInfo(){this.d3ColorScale=this.createD3ColorScale(this.wafermap.colorScale,this.wafermap.colorScaleMode)
13052
13073
  const e=e=>null!==e
13053
13074
  void 0===this.wafermap.diesTable&&(this._diesRenderInfo=this.wafermap.dies.map((e=>this.computeDieRenderInfo(e))).filter(e))}computeDieRenderInfo(e){const t=this.wafermap.dataManager.margin,n=this.wafermap.dataManager.horizontalScale(e.x),i=this.wafermap.dataManager.verticalScale(e.y)
13054
- return void 0===n||void 0===i?null:{x:n+t.right,y:i+t.top,fillStyle:this.calculateFillStyle(e.value,this.wafermap.colorScaleMode,this.wafermap.highlightedTags,e.tags),text:this.buildLabel(e.value,this.wafermap.maxCharacters,this.wafermap.dieLabelsHidden,this.wafermap.dieLabelsSuffix)}}calculateLabelsFontSize(e,t){return Math.min(e.height,e.width/(.5*Math.max(2,t))*this.fontSizeFactor)}createD3ColorScale(e,t){return this.isColorScaleLinear(t)?VH().domain(e.values.map((e=>+e))).range(e.colors):mH().domain(e.values).range(e.colors)}dieHasData(e){return null!=e&&""!==e}buildLabel(e,t,n,i){if(n||!this.dieHasData(e))return""
13075
+ return void 0===n||void 0===i?null:{x:n+t.right,y:i+t.top,fillStyle:this.calculateFillStyle(e.value,this.wafermap.colorScaleMode,this.wafermap.highlightedTags,e.tags),text:this.buildLabel(e.value,this.wafermap.maxCharacters,this.wafermap.dieLabelsHidden,this.wafermap.dieLabelsSuffix)}}calculateLabelsFontSize(e,t){return Math.min(e.height,e.width/(.5*Math.max(2,t))*this.fontSizeFactor)}createD3ColorScale(e,t){return this.isColorScaleLinear(t)?HH().domain(e.values.map((e=>+e))).range(e.colors):gH().domain(e.values).range(e.colors)}dieHasData(e){return null!=e&&""!==e}buildLabel(e,t,n,i){if(n||!this.dieHasData(e))return""
13055
13076
  const o=`${e}${i}`
13056
13077
  return o.length>=t?`${o.substring(0,t)}…`:o}calculateOpacity(e,t){if(!t||0===t.length)return 1
13057
13078
  const n=new Set(t)
13058
- return e?.some((e=>n.has(e)))?1:this.nonHighlightedOpacity}isColorScaleLinear(e){return e===GH}isColorScaleOrdinal(e){return e===KH}calculateFillStyle(e,t,n,i){let o=this.emptyDieColor
13079
+ return e?.some((e=>n.has(e)))?1:this.nonHighlightedOpacity}isColorScaleLinear(e){return e===KH}isColorScaleOrdinal(e){return e===XH}calculateFillStyle(e,t,n,i){let o=this.emptyDieColor
13059
13080
  if(this.dieHasData(e)&&(isNaN(+e)?o=this.nanDieColor:this.isColorScaleLinear(t)?o=this.d3ColorScale(+e):this.isColorScaleOrdinal(t)&&(o=this.d3ColorScale(e))),void 0===o)return this.emptyDieColor
13060
13081
  let r=Ko(o)
13061
- return null===r?this.emptyDieColor:(r=new Ho(r.r,r.g,r.b,this.calculateOpacity(i,n)),r.toStringWebRGBA())}}(e)}updateContainerDimensions(){this.computations.updateContainerDimensions(),this.updateDataMap(),this.updateLabelsFontSize()}updateScales(){this.computations.updateScales(),this.updateDataMap(),this.updateLabelsFontSize()}updateLabelsFontSize(){this.prerendering.updateLabelsFontSize()}updateDiesRenderInfo(){this.prerendering.updateDiesRenderInfo()}getWaferMapDie(e){return this.dataMap.get(`${e.x}_${e.y}`)}updateDataMap(){this.dataMap=new Map(this.wafermap.dies.map((e=>[`${e.x}_${e.y}`,e])))}}(this.asRequiredFieldsWaferMap),this.workerRenderer=new oq(this.asRequiredFieldsWaferMap),this.renderer=new QH(this.asRequiredFieldsWaferMap),this.renderQueued=!1,this.transform=LV,this.hoverTransform="",this.hoverOpacity=ZH,this.hoverWidth=0,this.hoverHeight=0,this.highlightedTags=[],this.dies=[],this.colorScale={colors:[],values:[]},this.hoverHandler=new class{constructor(e){this.wafermap=e,this.onMouseMove=e=>{if(this.wafermap.isExperimentalUpdate())return
13082
+ return null===r?this.emptyDieColor:(r=new Ho(r.r,r.g,r.b,this.calculateOpacity(i,n)),r.toStringWebRGBA())}}(e)}updateContainerDimensions(){this.computations.updateContainerDimensions(),this.updateDataMap(),this.updateLabelsFontSize()}updateScales(){this.computations.updateScales(),this.updateDataMap(),this.updateLabelsFontSize()}updateLabelsFontSize(){this.prerendering.updateLabelsFontSize()}updateDiesRenderInfo(){this.prerendering.updateDiesRenderInfo()}getWaferMapDie(e){return this.dataMap.get(`${e.x}_${e.y}`)}updateDataMap(){this.dataMap=new Map(this.wafermap.dies.map((e=>[`${e.x}_${e.y}`,e])))}}(this.asRequiredFieldsWaferMap),this.workerRenderer=new rq(this.asRequiredFieldsWaferMap),this.renderer=new eB(this.asRequiredFieldsWaferMap),this.renderQueued=!1,this.transform=zV,this.hoverTransform="",this.hoverOpacity=GH,this.hoverWidth=0,this.hoverHeight=0,this.highlightedTags=[],this.dies=[],this.colorScale={colors:[],values:[]},this.hoverHandler=new class{constructor(e){this.wafermap=e,this.onMouseMove=e=>{if(this.wafermap.isExperimentalUpdate())return
13062
13083
  const t={x:e.offsetX,y:e.offsetY}
13063
13084
  if(!this.hoversOverDie(t))return void(this.wafermap.hoverDie=void 0)
13064
13085
  const n=this.wafermap.transform.invert([t.x,t.y]),i=this.calculateDieCoordinates({x:n[0],y:n[1]})
13065
- this.wafermap.hoverDie=void 0!==i?this.wafermap.dataManager.getWaferMapDie(i):void 0},this.onMouseOut=e=>{this.wafermap.hoverDie=void 0}}connect(){this.wafermap.addEventListener("mousemove",this.onMouseMove),this.wafermap.addEventListener("mouseout",this.onMouseOut)}disconnect(){this.wafermap.removeEventListener("mousemove",this.onMouseMove),this.wafermap.removeEventListener("mouseout",this.onMouseOut)}calculateDieCoordinates(e){if(!this.wafermap.isExperimentalUpdate()){const t=this.wafermap.originLocation,n=t===BH||t===UH?Math.floor:Math.ceil,i=t===BH||t===qH?Math.floor:Math.ceil
13086
+ this.wafermap.hoverDie=void 0!==i?this.wafermap.dataManager.getWaferMapDie(i):void 0},this.onMouseOut=e=>{this.wafermap.hoverDie=void 0}}connect(){this.wafermap.addEventListener("mousemove",this.onMouseMove),this.wafermap.addEventListener("mouseout",this.onMouseOut)}disconnect(){this.wafermap.removeEventListener("mousemove",this.onMouseMove),this.wafermap.removeEventListener("mouseout",this.onMouseOut)}calculateDieCoordinates(e){if(!this.wafermap.isExperimentalUpdate()){const t=this.wafermap.originLocation,n=t===qH||t===jH?Math.floor:Math.ceil,i=t===qH||t===UH?Math.floor:Math.ceil
13066
13087
  return{x:n(this.wafermap.dataManager.invertedHorizontalScale(e.x-this.wafermap.dataManager.margin.left)),y:i(this.wafermap.dataManager.invertedVerticalScale(e.y-this.wafermap.dataManager.margin.top))}}}hoversOverDie(e){const t=this.wafermap.canvasContext.getImageData(e.x,e.y,1,1).data
13067
13088
  let n=0
13068
13089
  for(const e of t)n+=e
13069
- return n>0}}(this.asRequiredFieldsWaferMap),this.experimentalHoverHandler=new rq(this.asRequiredFieldsWaferMap),this.zoomHandler=new sq(this.asRequiredFieldsWaferMap),this.resizeObserver=this.createResizeObserver(),this.waferMapValidator=new FB(this.asRequiredFieldsWaferMap)}get validity(){return this.waferMapValidator.getValidity()}connectedCallback(){super.connectedCallback(),this.canvasContext=this.canvas.getContext("2d",{willReadFrequently:!0}),this.hoverHandler.connect(),this.experimentalHoverHandler.connect(),this.zoomHandler.connect(),this.resizeObserver.observe(this),this.waferMapUpdateTracker.trackAll()}disconnectedCallback(){super.disconnectedCallback(),this.hoverHandler.disconnect(),this.experimentalHoverHandler.disconnect(),this.zoomHandler.disconnect(),this.resizeObserver.unobserve(this)}async experimentalUpdate(){this.validity.invalidDiesTableSchema||(this.waferMapUpdateTracker.requiresEventsUpdate?this.waferMapUpdateTracker.requiresContainerDimensionsUpdate||this.waferMapUpdateTracker.requiresScalesUpdate?(this.experimentalDataManager.updateComputations(),await this.workerRenderer.setupWafer(),await this.workerRenderer.drawWafer()):this.waferMapUpdateTracker.requiresLabelsFontSizeUpdate||this.waferMapUpdateTracker.requiresDiesRenderInfoUpdate?(this.experimentalDataManager.updatePrerendering(),await this.workerRenderer.drawWafer()):this.waferMapUpdateTracker.requiresDrawnWaferUpdate&&await this.workerRenderer.drawWafer():this.waferMapUpdateTracker.requiresRenderHoverUpdate&&this.workerRenderer.renderHover())}update(){this.validate(),this.isExperimentalUpdate()?this.currentTask=this.experimentalUpdate():this.waferMapUpdateTracker.requiresEventsUpdate?this.waferMapUpdateTracker.requiresContainerDimensionsUpdate?(this.dataManager.updateContainerDimensions(),this.renderer.updateSortedDiesAndDrawWafer()):this.waferMapUpdateTracker.requiresScalesUpdate?(this.dataManager.updateScales(),this.renderer.updateSortedDiesAndDrawWafer()):this.waferMapUpdateTracker.requiresLabelsFontSizeUpdate?(this.dataManager.updateLabelsFontSize(),this.renderer.updateSortedDiesAndDrawWafer()):this.waferMapUpdateTracker.requiresDiesRenderInfoUpdate?(this.dataManager.updateDiesRenderInfo(),this.renderer.updateSortedDiesAndDrawWafer()):this.waferMapUpdateTracker.requiresDrawnWaferUpdate&&this.renderer.drawWafer():this.waferMapUpdateTracker.requiresRenderHoverUpdate&&this.renderer.renderHover()}isExperimentalUpdate(){return void 0!==this.diesTable}validate(){this.waferMapValidator.validateGridDimensions(),this.waferMapValidator.validateDiesTableSchema()}createResizeObserver(){return new ResizeObserver((e=>{const t=e[0]
13090
+ return n>0}}(this.asRequiredFieldsWaferMap),this.experimentalHoverHandler=new sq(this.asRequiredFieldsWaferMap),this.zoomHandler=new aq(this.asRequiredFieldsWaferMap),this.resizeObserver=this.createResizeObserver(),this.waferMapValidator=new NB(this.asRequiredFieldsWaferMap)}get validity(){return this.waferMapValidator.getValidity()}connectedCallback(){super.connectedCallback(),this.canvasContext=this.canvas.getContext("2d",{willReadFrequently:!0}),this.hoverHandler.connect(),this.experimentalHoverHandler.connect(),this.zoomHandler.connect(),this.resizeObserver.observe(this),this.waferMapUpdateTracker.trackAll()}disconnectedCallback(){super.disconnectedCallback(),this.hoverHandler.disconnect(),this.experimentalHoverHandler.disconnect(),this.zoomHandler.disconnect(),this.resizeObserver.unobserve(this)}async experimentalUpdate(){this.validity.invalidDiesTableSchema||(this.waferMapUpdateTracker.requiresEventsUpdate?this.waferMapUpdateTracker.requiresContainerDimensionsUpdate||this.waferMapUpdateTracker.requiresScalesUpdate?(this.experimentalDataManager.updateComputations(),await this.workerRenderer.setupWafer(),await this.workerRenderer.drawWafer()):this.waferMapUpdateTracker.requiresLabelsFontSizeUpdate||this.waferMapUpdateTracker.requiresDiesRenderInfoUpdate?(this.experimentalDataManager.updatePrerendering(),await this.workerRenderer.drawWafer()):this.waferMapUpdateTracker.requiresDrawnWaferUpdate&&await this.workerRenderer.drawWafer():this.waferMapUpdateTracker.requiresRenderHoverUpdate&&this.workerRenderer.renderHover())}update(){this.validate(),this.isExperimentalUpdate()?this.currentTask=this.experimentalUpdate():this.waferMapUpdateTracker.requiresEventsUpdate?this.waferMapUpdateTracker.requiresContainerDimensionsUpdate?(this.dataManager.updateContainerDimensions(),this.renderer.updateSortedDiesAndDrawWafer()):this.waferMapUpdateTracker.requiresScalesUpdate?(this.dataManager.updateScales(),this.renderer.updateSortedDiesAndDrawWafer()):this.waferMapUpdateTracker.requiresLabelsFontSizeUpdate?(this.dataManager.updateLabelsFontSize(),this.renderer.updateSortedDiesAndDrawWafer()):this.waferMapUpdateTracker.requiresDiesRenderInfoUpdate?(this.dataManager.updateDiesRenderInfo(),this.renderer.updateSortedDiesAndDrawWafer()):this.waferMapUpdateTracker.requiresDrawnWaferUpdate&&this.renderer.drawWafer():this.waferMapUpdateTracker.requiresRenderHoverUpdate&&this.renderer.renderHover()}isExperimentalUpdate(){return void 0!==this.diesTable}validate(){this.waferMapValidator.validateGridDimensions(),this.waferMapValidator.validateDiesTableSchema()}createResizeObserver(){return new ResizeObserver((e=>{const t=e[0]
13070
13091
  if(void 0===t)return
13071
13092
  const{height:n,width:i}=t.contentRect
13072
- this.canvas.width=i,this.canvas.height=n,this.canvasWidth=i,this.canvasHeight=n}))}originLocationChanged(){this.waferMapUpdateTracker.track("originLocation"),this.waferMapUpdateTracker.queueUpdate()}gridMinXChanged(){this.waferMapUpdateTracker.track("gridMinX"),this.waferMapUpdateTracker.queueUpdate()}gridMaxXChanged(){this.waferMapUpdateTracker.track("gridMaxX"),this.waferMapUpdateTracker.queueUpdate()}gridMinYChanged(){this.waferMapUpdateTracker.track("gridMinY"),this.waferMapUpdateTracker.queueUpdate()}gridMaxYChanged(){this.waferMapUpdateTracker.track("gridMaxY"),this.waferMapUpdateTracker.queueUpdate()}maxCharactersChanged(){this.waferMapUpdateTracker.track("maxCharacters"),this.waferMapUpdateTracker.queueUpdate()}dieLabelsHiddenChanged(){this.waferMapUpdateTracker.track("dieLabelsHidden"),this.waferMapUpdateTracker.queueUpdate()}dieLabelsSuffixChanged(){this.waferMapUpdateTracker.track("dieLabelsSuffix"),this.waferMapUpdateTracker.queueUpdate()}colorScaleModeChanged(){this.waferMapUpdateTracker.track("colorScaleMode"),this.waferMapUpdateTracker.queueUpdate()}highlightedTagsChanged(){this.waferMapUpdateTracker.track("highlightedTags"),this.waferMapUpdateTracker.queueUpdate()}diesChanged(){this.waferMapUpdateTracker.track("dies"),this.waferMapUpdateTracker.queueUpdate()}diesTableChanged(){this.waferMapUpdateTracker.track("dies"),this.waferMapUpdateTracker.queueUpdate()}colorScaleChanged(){this.waferMapUpdateTracker.track("colorScale"),this.waferMapUpdateTracker.queueUpdate()}transformChanged(){this.waferMapUpdateTracker.track("transform"),this.waferMapUpdateTracker.queueUpdate()}canvasWidthChanged(){this.waferMapUpdateTracker.track("canvasWidth"),this.waferMapUpdateTracker.queueUpdate()}canvasHeightChanged(){this.waferMapUpdateTracker.track("canvasHeight"),this.waferMapUpdateTracker.queueUpdate()}hoverDieChanged(){this.$emit("die-hover",{currentDie:this.hoverDie}),this.waferMapUpdateTracker.track("hoverDie"),this.waferMapUpdateTracker.queueUpdate()}get asRequiredFieldsWaferMap(){return this}}e([le({attribute:"origin-location"})],aq.prototype,"originLocation",void 0),e([le({attribute:"grid-min-x",converter:se})],aq.prototype,"gridMinX",void 0),e([le({attribute:"grid-max-x",converter:se})],aq.prototype,"gridMaxX",void 0),e([le({attribute:"grid-min-y",converter:se})],aq.prototype,"gridMinY",void 0),e([le({attribute:"grid-max-y",converter:se})],aq.prototype,"gridMaxY",void 0),e([le],aq.prototype,"orientation",void 0),e([le({attribute:"max-characters",converter:se})],aq.prototype,"maxCharacters",void 0),e([le({attribute:"die-labels-hidden",mode:"boolean"})],aq.prototype,"dieLabelsHidden",void 0),e([le({attribute:"die-labels-suffix"})],aq.prototype,"dieLabelsSuffix",void 0),e([le({attribute:"color-scale-mode"})],aq.prototype,"colorScaleMode",void 0),e([g],aq.prototype,"renderer",void 0),e([g],aq.prototype,"canvasWidth",void 0),e([g],aq.prototype,"canvasHeight",void 0),e([g],aq.prototype,"transform",void 0),e([g],aq.prototype,"hoverTransform",void 0),e([g],aq.prototype,"hoverOpacity",void 0),e([g],aq.prototype,"hoverWidth",void 0),e([g],aq.prototype,"hoverHeight",void 0),e([g],aq.prototype,"hoverDie",void 0),e([g],aq.prototype,"highlightedTags",void 0),e([g],aq.prototype,"dies",void 0),e([g],aq.prototype,"diesTable",void 0),e([g],aq.prototype,"colorScale",void 0)
13073
- const lq=aq.compose({baseName:"wafer-map",template:GV,styles:KV})
13074
- wi.getOrCreate().withPrefix("nimble").register(lq())}()
13093
+ this.canvas.width=i,this.canvas.height=n,this.canvasWidth=i,this.canvasHeight=n}))}originLocationChanged(){this.waferMapUpdateTracker.track("originLocation"),this.waferMapUpdateTracker.queueUpdate()}gridMinXChanged(){this.waferMapUpdateTracker.track("gridMinX"),this.waferMapUpdateTracker.queueUpdate()}gridMaxXChanged(){this.waferMapUpdateTracker.track("gridMaxX"),this.waferMapUpdateTracker.queueUpdate()}gridMinYChanged(){this.waferMapUpdateTracker.track("gridMinY"),this.waferMapUpdateTracker.queueUpdate()}gridMaxYChanged(){this.waferMapUpdateTracker.track("gridMaxY"),this.waferMapUpdateTracker.queueUpdate()}maxCharactersChanged(){this.waferMapUpdateTracker.track("maxCharacters"),this.waferMapUpdateTracker.queueUpdate()}dieLabelsHiddenChanged(){this.waferMapUpdateTracker.track("dieLabelsHidden"),this.waferMapUpdateTracker.queueUpdate()}dieLabelsSuffixChanged(){this.waferMapUpdateTracker.track("dieLabelsSuffix"),this.waferMapUpdateTracker.queueUpdate()}colorScaleModeChanged(){this.waferMapUpdateTracker.track("colorScaleMode"),this.waferMapUpdateTracker.queueUpdate()}highlightedTagsChanged(){this.waferMapUpdateTracker.track("highlightedTags"),this.waferMapUpdateTracker.queueUpdate()}diesChanged(){this.waferMapUpdateTracker.track("dies"),this.waferMapUpdateTracker.queueUpdate()}diesTableChanged(){this.waferMapUpdateTracker.track("dies"),this.waferMapUpdateTracker.queueUpdate()}colorScaleChanged(){this.waferMapUpdateTracker.track("colorScale"),this.waferMapUpdateTracker.queueUpdate()}transformChanged(){this.waferMapUpdateTracker.track("transform"),this.waferMapUpdateTracker.queueUpdate()}canvasWidthChanged(){this.waferMapUpdateTracker.track("canvasWidth"),this.waferMapUpdateTracker.queueUpdate()}canvasHeightChanged(){this.waferMapUpdateTracker.track("canvasHeight"),this.waferMapUpdateTracker.queueUpdate()}hoverDieChanged(){this.$emit("die-hover",{currentDie:this.hoverDie}),this.waferMapUpdateTracker.track("hoverDie"),this.waferMapUpdateTracker.queueUpdate()}get asRequiredFieldsWaferMap(){return this}}e([le({attribute:"origin-location"})],lq.prototype,"originLocation",void 0),e([le({attribute:"grid-min-x",converter:se})],lq.prototype,"gridMinX",void 0),e([le({attribute:"grid-max-x",converter:se})],lq.prototype,"gridMaxX",void 0),e([le({attribute:"grid-min-y",converter:se})],lq.prototype,"gridMinY",void 0),e([le({attribute:"grid-max-y",converter:se})],lq.prototype,"gridMaxY",void 0),e([le],lq.prototype,"orientation",void 0),e([le({attribute:"max-characters",converter:se})],lq.prototype,"maxCharacters",void 0),e([le({attribute:"die-labels-hidden",mode:"boolean"})],lq.prototype,"dieLabelsHidden",void 0),e([le({attribute:"die-labels-suffix"})],lq.prototype,"dieLabelsSuffix",void 0),e([le({attribute:"color-scale-mode"})],lq.prototype,"colorScaleMode",void 0),e([g],lq.prototype,"renderer",void 0),e([g],lq.prototype,"canvasWidth",void 0),e([g],lq.prototype,"canvasHeight",void 0),e([g],lq.prototype,"transform",void 0),e([g],lq.prototype,"hoverTransform",void 0),e([g],lq.prototype,"hoverOpacity",void 0),e([g],lq.prototype,"hoverWidth",void 0),e([g],lq.prototype,"hoverHeight",void 0),e([g],lq.prototype,"hoverDie",void 0),e([g],lq.prototype,"highlightedTags",void 0),e([g],lq.prototype,"dies",void 0),e([g],lq.prototype,"diesTable",void 0),e([g],lq.prototype,"colorScale",void 0)
13094
+ const cq=lq.compose({baseName:"wafer-map",template:KV,styles:XV})
13095
+ wi.getOrCreate().withPrefix("nimble").register(cq())}()
13075
13096
  //# sourceMappingURL=all-components-bundle.min.js.map