@sankhyalabs/ezui 7.1.9 → 7.1.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/ApplicationUtils-5cc05979.js.gz +0 -0
- package/dist/cjs/CSSVarsUtils-f20973d1.js.gz +0 -0
- package/dist/cjs/CheckMode-ecb90b87.js.gz +0 -0
- package/dist/cjs/DialogType-2114c337.js.gz +0 -0
- package/dist/cjs/EzScrollDirection-b2c99895.js.gz +0 -0
- package/dist/cjs/FocusResolver-885f2173.js.gz +0 -0
- package/dist/cjs/FormLayout-18853e70.js.gz +0 -0
- package/dist/cjs/RichToolbarHelper-ea12328f.js.gz +0 -0
- package/dist/cjs/_commonjsHelpers-537d719a.js.gz +0 -0
- package/dist/cjs/app-globals-2fbe4b17.js.gz +0 -0
- package/dist/cjs/constants-72b7e05e.js.gz +0 -0
- package/dist/cjs/ez-actions-button.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-alert-list.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-alert.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-application.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-avatar.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-badge.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-breadcrumb.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-button.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-calendar.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-card-item.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-chart.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-check.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-chip.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-classic-combo-box.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-classic-input.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-classic-text-area.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-collapsible-box.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-combo-box-list_4.cjs.entry.js +1 -1
- package/dist/cjs/ez-combo-box-list_4.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-combo-box.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-date-input.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-date-time-input.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-dialog.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-double-list.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-dropdown.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-empty-card.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-file-item.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-filter-input.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-form-view.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-form.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-grid-view.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-grid.cjs.entry.js +1 -1
- package/dist/cjs/ez-grid.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-guide-navigator.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-icon.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-link-builder_6.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-list-item.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-list.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-loading-bar.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-modal-container.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-modal.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-multi-selection-list.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-number-input.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-pagination.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-popover-core.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-popover-plus_3.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-popover.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-popup.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-progress-bar.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-radio-button.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-rich-toolbar-item.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-scroller_2.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-search-plus.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-search-result-list.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-search.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-sidebar-navigator.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-skeleton.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-sortable-list.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-spinner.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-split-button.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-split-item.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-split-panel.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-tabselector.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-tag-input.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-tag.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-text-area.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-text-input.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-tile-medium.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-tile.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-time-input.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-toast.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-tooltip.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-tree.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-underface.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-upload.cjs.entry.js.gz +0 -0
- package/dist/cjs/ez-view-stack.cjs.entry.js.gz +0 -0
- package/dist/cjs/ezListHelper-0d3970b4.js.gz +0 -0
- package/dist/cjs/ezui.cjs.js.gz +0 -0
- package/dist/cjs/filter-column.cjs.entry.js +6 -1
- package/dist/cjs/filter-column.cjs.entry.js.gz +0 -0
- package/dist/cjs/floating-ui.dom.esm-f4d87617.js.gz +0 -0
- package/dist/cjs/index-1be40f19.js.gz +0 -0
- package/dist/cjs/index-a7b0c73d.js.gz +0 -0
- package/dist/cjs/index.cjs.js.gz +0 -0
- package/dist/cjs/loader.cjs.js.gz +0 -0
- package/dist/cjs/{purify-ca9603eb.js → purify-db11ac44.js} +677 -245
- package/dist/cjs/purify-db11ac44.js.gz +0 -0
- package/dist/cjs/search-column-316e2c59.js.gz +0 -0
- package/dist/cjs/searchFormatters-b7e1ed1e.js.gz +0 -0
- package/dist/collection/components/ez-actions-button/ez-actions-button.css.gz +0 -0
- package/dist/collection/components/ez-actions-button/ez-actions-button.js.gz +0 -0
- package/dist/collection/components/ez-alert/ez-alert.css.gz +0 -0
- package/dist/collection/components/ez-alert/ez-alert.js.gz +0 -0
- package/dist/collection/components/ez-alert-list/ez-alert-list.css.gz +0 -0
- package/dist/collection/components/ez-alert-list/ez-alert-list.js.gz +0 -0
- package/dist/collection/components/ez-application/ez-application.css.gz +0 -0
- package/dist/collection/components/ez-application/ez-application.js.gz +0 -0
- package/dist/collection/components/ez-avatar/ez-avatar.css.gz +0 -0
- package/dist/collection/components/ez-avatar/ez-avatar.js.gz +0 -0
- package/dist/collection/components/ez-badge/enum/sizes.js.gz +0 -0
- package/dist/collection/components/ez-badge/ez-badge.css.gz +0 -0
- package/dist/collection/components/ez-badge/ez-badge.js.gz +0 -0
- package/dist/collection/components/ez-badge/interfaces/IPosition.js.gz +0 -0
- package/dist/collection/components/ez-breadcrumb/ez-breadcrumb.css.gz +0 -0
- package/dist/collection/components/ez-breadcrumb/ez-breadcrumb.js.gz +0 -0
- package/dist/collection/components/ez-breadcrumb/subcomponents/breadcrumb-item.js.gz +0 -0
- package/dist/collection/components/ez-button/ez-button.css.gz +0 -0
- package/dist/collection/components/ez-button/ez-button.js.gz +0 -0
- package/dist/collection/components/ez-calendar/ez-calendar.css.gz +0 -0
- package/dist/collection/components/ez-calendar/ez-calendar.js.gz +0 -0
- package/dist/collection/components/ez-card-item/ez-card-item.css.gz +0 -0
- package/dist/collection/components/ez-card-item/ez-card-item.js.gz +0 -0
- package/dist/collection/components/ez-chart/components/BarChart.js.gz +0 -0
- package/dist/collection/components/ez-chart/components/ColumnChart.js.gz +0 -0
- package/dist/collection/components/ez-chart/components/DonutChart.js.gz +0 -0
- package/dist/collection/components/ez-chart/components/LineChart.js.gz +0 -0
- package/dist/collection/components/ez-chart/components/PieChart.js.gz +0 -0
- package/dist/collection/components/ez-chart/components/index.js.gz +0 -0
- package/dist/collection/components/ez-chart/ez-chart.css.gz +0 -0
- package/dist/collection/components/ez-chart/ez-chart.js.gz +0 -0
- package/dist/collection/components/ez-chart/interfaces/ChartAxis.js.gz +0 -0
- package/dist/collection/components/ez-chart/interfaces/ChartContext.js.gz +0 -0
- package/dist/collection/components/ez-chart/interfaces/ChartOptions.js.gz +0 -0
- package/dist/collection/components/ez-chart/interfaces/ChartSerie.js.gz +0 -0
- package/dist/collection/components/ez-chart/interfaces/ChartStrategies.js.gz +0 -0
- package/dist/collection/components/ez-chart/interfaces/ChartType.js.gz +0 -0
- package/dist/collection/components/ez-chart/interfaces/ChartTypeValue.js.gz +0 -0
- package/dist/collection/components/ez-chart/interfaces/index.js.gz +0 -0
- package/dist/collection/components/ez-chart/test/mock-chart.js.gz +0 -0
- package/dist/collection/components/ez-chart/types/BaseHighChartsRender.js.gz +0 -0
- package/dist/collection/components/ez-check/CheckMode.js.gz +0 -0
- package/dist/collection/components/ez-check/ez-check.css.gz +0 -0
- package/dist/collection/components/ez-check/ez-check.js.gz +0 -0
- package/dist/collection/components/ez-chip/ez-chip.css.gz +0 -0
- package/dist/collection/components/ez-chip/ez-chip.js.gz +0 -0
- package/dist/collection/components/ez-classic-combo-box/ez-classic-combo-box.css.gz +0 -0
- package/dist/collection/components/ez-classic-combo-box/ez-classic-combo-box.js.gz +0 -0
- package/dist/collection/components/ez-classic-combo-box/interfaces/IOption.js.gz +0 -0
- package/dist/collection/components/ez-classic-input/ez-classic-input.css.gz +0 -0
- package/dist/collection/components/ez-classic-input/ez-classic-input.js.gz +0 -0
- package/dist/collection/components/ez-classic-input/interfaces/optionsSetFocus.js.gz +0 -0
- package/dist/collection/components/ez-classic-input/utils/maskFormatter.js.gz +0 -0
- package/dist/collection/components/ez-classic-text-area/ez-classic-text-area.css.gz +0 -0
- package/dist/collection/components/ez-classic-text-area/ez-classic-text-area.js.gz +0 -0
- package/dist/collection/components/ez-classic-text-area/interfaces/optionsSetFocus.js.gz +0 -0
- package/dist/collection/components/ez-collapsible-box/ez-collapsible-box.css.gz +0 -0
- package/dist/collection/components/ez-collapsible-box/ez-collapsible-box.js.gz +0 -0
- package/dist/collection/components/ez-combo-box/ez-combo-box-list/ez-combo-box-list.css.gz +0 -0
- package/dist/collection/components/ez-combo-box/ez-combo-box-list/ez-combo-box-list.js.gz +0 -0
- package/dist/collection/components/ez-combo-box/ez-combo-box.css.gz +0 -0
- package/dist/collection/components/ez-combo-box/ez-combo-box.js.gz +0 -0
- package/dist/collection/components/ez-date-input/ez-date-input.css.gz +0 -0
- package/dist/collection/components/ez-date-input/ez-date-input.js.gz +0 -0
- package/dist/collection/components/ez-date-time-input/ez-date-time-input.css.gz +0 -0
- package/dist/collection/components/ez-date-time-input/ez-date-time-input.js.gz +0 -0
- package/dist/collection/components/ez-dialog/DialogType.js.gz +0 -0
- package/dist/collection/components/ez-dialog/ez-dialog.css.gz +0 -0
- package/dist/collection/components/ez-dialog/ez-dialog.js.gz +0 -0
- package/dist/collection/components/ez-double-list/doubleListHelper.js.gz +0 -0
- package/dist/collection/components/ez-double-list/ez-double-list.css.gz +0 -0
- package/dist/collection/components/ez-double-list/ez-double-list.js.gz +0 -0
- package/dist/collection/components/ez-dropdown/ez-dropdown.css.gz +0 -0
- package/dist/collection/components/ez-dropdown/ez-dropdown.js.gz +0 -0
- package/dist/collection/components/ez-dropdown/structure/DropdownItem.js.gz +0 -0
- package/dist/collection/components/ez-dropdown/structure/SubmenuControl.js.gz +0 -0
- package/dist/collection/components/ez-empty-card/ez-empty-card.css.gz +0 -0
- package/dist/collection/components/ez-empty-card/ez-empty-card.js.gz +0 -0
- package/dist/collection/components/ez-file-item/ez-file-item.css.gz +0 -0
- package/dist/collection/components/ez-file-item/ez-file-item.js.gz +0 -0
- package/dist/collection/components/ez-filter-input/ez-filter-input.css.gz +0 -0
- package/dist/collection/components/ez-filter-input/ez-filter-input.js.gz +0 -0
- package/dist/collection/components/ez-form/ez-form.css.gz +0 -0
- package/dist/collection/components/ez-form/ez-form.js.gz +0 -0
- package/dist/collection/components/ez-form/store/form.slice.js.gz +0 -0
- package/dist/collection/components/ez-form-view/custom-input/ez-custom-form-input.js.gz +0 -0
- package/dist/collection/components/ez-form-view/ez-form-view.css.gz +0 -0
- package/dist/collection/components/ez-form-view/ez-form-view.js.gz +0 -0
- package/dist/collection/components/ez-form-view/fieldbuilder/FieldBuilder.js.gz +0 -0
- package/dist/collection/components/ez-form-view/fieldbuilder/templates/CheckBox.tpl.js.gz +0 -0
- package/dist/collection/components/ez-form-view/fieldbuilder/templates/ComboBox.tpl.js.gz +0 -0
- package/dist/collection/components/ez-form-view/fieldbuilder/templates/DateInput.tpl.js.gz +0 -0
- package/dist/collection/components/ez-form-view/fieldbuilder/templates/FileInput.tpl.js.gz +0 -0
- package/dist/collection/components/ez-form-view/fieldbuilder/templates/NumberInput.tpl.js.gz +0 -0
- package/dist/collection/components/ez-form-view/fieldbuilder/templates/RichText.tpl.js.gz +0 -0
- package/dist/collection/components/ez-form-view/fieldbuilder/templates/SearchInput.tpl.js.gz +0 -0
- package/dist/collection/components/ez-form-view/fieldbuilder/templates/SearchInputPlus.tpl.js.gz +0 -0
- package/dist/collection/components/ez-form-view/fieldbuilder/templates/TextArea.tpl.js.gz +0 -0
- package/dist/collection/components/ez-form-view/fieldbuilder/templates/TextInput.tpl.js.gz +0 -0
- package/dist/collection/components/ez-form-view/interfaces/IFormViewField.js.gz +0 -0
- package/dist/collection/components/ez-form-view/interfaces/index.js.gz +0 -0
- package/dist/collection/components/ez-form-view/structure/index.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/EzGridController.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/AgGridController.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/DataSource.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/DataSourceInterceptor.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/GridEditionManager.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/components/EzGridCustomCellEditor.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/components/EzGridCustomCellRender.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/components/EzGridCustomHeader.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/components/cellRendererStatus.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/components/selectionHeader.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/components/test/constants/EzGridCustomCellEditorConstants.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/components/test/constants/EzGridCustomCellRenderConstants.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/editor/EzCellEditor.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/editor/EzCellRender.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/editor/GridEditorUtils.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/editor/IEditorMetadata.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/editor/IUICellEditor.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/editor/IUICellRender.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/editor/templates/ComboBox.tpl.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/editor/templates/DateInput.tpl.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/editor/templates/NumberInput.tpl.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/editor/templates/Search.tpl.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/editor/templates/SearchPlus.tpl.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/editor/templates/TextInput.tpl.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/mock/Server.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/test/constants/GridEditionMock.js.gz +0 -0
- package/dist/collection/components/ez-grid/controller/ag-grid/utils/buildLocaleText.js.gz +0 -0
- package/dist/collection/components/ez-grid/ez-grid.css.gz +0 -0
- package/dist/collection/components/ez-grid/ez-grid.js.gz +0 -0
- package/dist/collection/components/ez-grid/interfaces/IColumnFilter.js.gz +0 -0
- package/dist/collection/components/ez-grid/interfaces/ICustomFormatter.js.gz +0 -0
- package/dist/collection/components/ez-grid/interfaces/IGridMode.js.gz +0 -0
- package/dist/collection/components/ez-grid/interfaces/ISelection.js.gz +0 -0
- package/dist/collection/components/ez-grid/interfaces/ISelectionToastConfig.js.gz +0 -0
- package/dist/collection/components/ez-grid/interfaces/index.js.gz +0 -0
- package/dist/collection/components/ez-grid/subcomponents/filter-column.css.gz +0 -0
- package/dist/collection/components/ez-grid/subcomponents/filter-column.js +6 -1
- package/dist/collection/components/ez-grid/subcomponents/filter-column.js.gz +0 -0
- package/dist/collection/components/ez-grid/subcomponents/selection-counter.js.gz +0 -0
- package/dist/collection/components/ez-grid/subcomponents/utils/selectionCounterUtils.js.gz +0 -0
- package/dist/collection/components/ez-grid/test/resources/gridDataUnit.js.gz +0 -0
- package/dist/collection/components/ez-grid/utils/ColumnFilterManager.js.gz +0 -0
- package/dist/collection/components/ez-grid/utils/InMemoryFilterColumnDataSource.js.gz +0 -0
- package/dist/collection/components/ez-grid/utils/index.js.gz +0 -0
- package/dist/collection/components/ez-grid-view/ez-grid-view.css.gz +0 -0
- package/dist/collection/components/ez-grid-view/ez-grid-view.js.gz +0 -0
- package/dist/collection/components/ez-guide-navigator/ez-guide-navigator.css.gz +0 -0
- package/dist/collection/components/ez-guide-navigator/ez-guide-navigator.js.gz +0 -0
- package/dist/collection/components/ez-guide-navigator/interfaces/IGuideItem.js.gz +0 -0
- package/dist/collection/components/ez-guide-navigator/interfaces/index.js.gz +0 -0
- package/dist/collection/components/ez-icon/ez-icon.css.gz +0 -0
- package/dist/collection/components/ez-icon/ez-icon.js.gz +0 -0
- package/dist/collection/components/ez-list/ez-list.css.gz +0 -0
- package/dist/collection/components/ez-list/ez-list.js.gz +0 -0
- package/dist/collection/components/ez-list/ezListHelper.js.gz +0 -0
- package/dist/collection/components/ez-list-item/ez-list-item.css.gz +0 -0
- package/dist/collection/components/ez-list-item/ez-list-item.js.gz +0 -0
- package/dist/collection/components/ez-loading-bar/ez-loading-bar.css.gz +0 -0
- package/dist/collection/components/ez-loading-bar/ez-loading-bar.js.gz +0 -0
- package/dist/collection/components/ez-modal/ez-modal.css.gz +0 -0
- package/dist/collection/components/ez-modal/ez-modal.js.gz +0 -0
- package/dist/collection/components/ez-modal-container/ez-modal-container.css.gz +0 -0
- package/dist/collection/components/ez-modal-container/ez-modal-container.js.gz +0 -0
- package/dist/collection/components/ez-modal-container/index.js.gz +0 -0
- package/dist/collection/components/ez-modal-container/modal-action.js.gz +0 -0
- package/dist/collection/components/ez-modal-container/modal-button-status.js.gz +0 -0
- package/dist/collection/components/ez-multi-selection-list/ez-multi-selection-list.css.gz +0 -0
- package/dist/collection/components/ez-multi-selection-list/ez-multi-selection-list.js.gz +0 -0
- package/dist/collection/components/ez-multi-selection-list/interfaces/IMultiSelectionListDataSource.js.gz +0 -0
- package/dist/collection/components/ez-multi-selection-list/interfaces/IMultiSelectionOption.js.gz +0 -0
- package/dist/collection/components/ez-multi-selection-list/interfaces/IStaticOptionsFetchConfig.js.gz +0 -0
- package/dist/collection/components/ez-multi-selection-list/subcomponents/multi-selection-box-message.css.gz +0 -0
- package/dist/collection/components/ez-multi-selection-list/subcomponents/multi-selection-box-message.js.gz +0 -0
- package/dist/collection/components/ez-number-input/ez-number-input.css.gz +0 -0
- package/dist/collection/components/ez-number-input/ez-number-input.js.gz +0 -0
- package/dist/collection/components/ez-pagination/ez-pagination.css.gz +0 -0
- package/dist/collection/components/ez-pagination/ez-pagination.js.gz +0 -0
- package/dist/collection/components/ez-popover/ez-popover.css.gz +0 -0
- package/dist/collection/components/ez-popover/ez-popover.js.gz +0 -0
- package/dist/collection/components/ez-popover-plus/ez-popover-plus.css.gz +0 -0
- package/dist/collection/components/ez-popover-plus/ez-popover-plus.js.gz +0 -0
- package/dist/collection/components/ez-popover-plus/subcomponent/ez-popover-core.css.gz +0 -0
- package/dist/collection/components/ez-popover-plus/subcomponent/ez-popover-core.js.gz +0 -0
- package/dist/collection/components/ez-popup/ez-popup.css.gz +0 -0
- package/dist/collection/components/ez-popup/ez-popup.js.gz +0 -0
- package/dist/collection/components/ez-popup/interfaces/EzButtonProps.js.gz +0 -0
- package/dist/collection/components/ez-progress-bar/ez-progress-bar.css.gz +0 -0
- package/dist/collection/components/ez-progress-bar/ez-progress-bar.js.gz +0 -0
- package/dist/collection/components/ez-radio-button/ez-radio-button.css.gz +0 -0
- package/dist/collection/components/ez-radio-button/ez-radio-button.js.gz +0 -0
- package/dist/collection/components/ez-rich-text/ez-link-builder/ez-link-builder.css.gz +0 -0
- package/dist/collection/components/ez-rich-text/ez-link-builder/ez-link-builder.js.gz +0 -0
- package/dist/collection/components/ez-rich-text/ez-rich-text.css.gz +0 -0
- package/dist/collection/components/ez-rich-text/ez-rich-text.js.gz +0 -0
- package/dist/collection/components/ez-rich-text/ez-rich-toolbar/RichToolbarHelper.js.gz +0 -0
- package/dist/collection/components/ez-rich-text/ez-rich-toolbar/ez-rich-toolbar-arrows/ez-rich-toolbar-arrows.css.gz +0 -0
- package/dist/collection/components/ez-rich-text/ez-rich-toolbar/ez-rich-toolbar-arrows/ez-rich-toolbar-arrows.js.gz +0 -0
- package/dist/collection/components/ez-rich-text/ez-rich-toolbar/ez-rich-toolbar-configs/ez-rich-toolbar-configs.css.gz +0 -0
- package/dist/collection/components/ez-rich-text/ez-rich-toolbar/ez-rich-toolbar-configs/ez-rich-toolbar-configs.js.gz +0 -0
- package/dist/collection/components/ez-rich-text/ez-rich-toolbar/ez-rich-toolbar-item/ez-rich-toolbar-item.css.gz +0 -0
- package/dist/collection/components/ez-rich-text/ez-rich-toolbar/ez-rich-toolbar-item/ez-rich-toolbar-item.js.gz +0 -0
- package/dist/collection/components/ez-rich-text/ez-rich-toolbar/ez-rich-toolbar-letters/ez-rich-toolbar-letters.css.gz +0 -0
- package/dist/collection/components/ez-rich-text/ez-rich-toolbar/ez-rich-toolbar-letters/ez-rich-toolbar-letters.js.gz +0 -0
- package/dist/collection/components/ez-rich-text/ez-rich-toolbar/ez-rich-toolbar.css.gz +0 -0
- package/dist/collection/components/ez-rich-text/ez-rich-toolbar/ez-rich-toolbar.js.gz +0 -0
- package/dist/collection/components/ez-rich-text/ez-simple-image-uploader/ez-simple-image-uploader.css.gz +0 -0
- package/dist/collection/components/ez-rich-text/ez-simple-image-uploader/ez-simple-image-uploader.js.gz +0 -0
- package/dist/collection/components/ez-rich-text/ez-simple-image-uploader/test/resource/imageBase64.js.gz +0 -0
- package/dist/collection/components/ez-rich-text/ez-simple-image-uploader/utils/fileToBase64.js.gz +0 -0
- package/dist/collection/components/ez-rich-text/ez-simple-image-uploader/utils/formatBytes.js.gz +0 -0
- package/dist/collection/components/ez-scroller/EzScrollDirection.js.gz +0 -0
- package/dist/collection/components/ez-scroller/ez-scroller.css.gz +0 -0
- package/dist/collection/components/ez-scroller/ez-scroller.js.gz +0 -0
- package/dist/collection/components/ez-search/ez-search.css.gz +0 -0
- package/dist/collection/components/ez-search/ez-search.js.gz +0 -0
- package/dist/collection/components/ez-search/subcomponent/search-list/search-list.css.gz +0 -0
- package/dist/collection/components/ez-search/subcomponent/search-list/search-list.js.gz +0 -0
- package/dist/collection/components/ez-search/utils/searchFormatters.js.gz +0 -0
- package/dist/collection/components/ez-search-plus/ez-search-plus.css.gz +0 -0
- package/dist/collection/components/ez-search-plus/ez-search-plus.js.gz +0 -0
- package/dist/collection/components/ez-search-plus/subcomponent/ez-search-result-list/ez-search-result-list.css.gz +0 -0
- package/dist/collection/components/ez-search-plus/subcomponent/ez-search-result-list/ez-search-result-list.js.gz +0 -0
- package/dist/collection/components/ez-sidebar-button/ez-sidebar-button.css.gz +0 -0
- package/dist/collection/components/ez-sidebar-button/ez-sidebar-button.js.gz +0 -0
- package/dist/collection/components/ez-sidebar-navigator/ez-sidebar-navigator.css.gz +0 -0
- package/dist/collection/components/ez-sidebar-navigator/ez-sidebar-navigator.js.gz +0 -0
- package/dist/collection/components/ez-sidebar-navigator/interfaces/ModeMenuEnum.js.gz +0 -0
- package/dist/collection/components/ez-sidebar-navigator/interfaces/SizeMenuEnum.js.gz +0 -0
- package/dist/collection/components/ez-sidebar-navigator/interfaces/TypeMenuEnum.js.gz +0 -0
- package/dist/collection/components/ez-sidebar-navigator/interfaces/index.js.gz +0 -0
- package/dist/collection/components/ez-skeleton/ez-skeleton.constants.js.gz +0 -0
- package/dist/collection/components/ez-skeleton/ez-skeleton.css.gz +0 -0
- package/dist/collection/components/ez-skeleton/ez-skeleton.js.gz +0 -0
- package/dist/collection/components/ez-sortable-list/ez-sortable-list.css.gz +0 -0
- package/dist/collection/components/ez-sortable-list/ez-sortable-list.js.gz +0 -0
- package/dist/collection/components/ez-spinner/ez-spinner.css.gz +0 -0
- package/dist/collection/components/ez-spinner/ez-spinner.js.gz +0 -0
- package/dist/collection/components/ez-split-button/ez-split-button.css.gz +0 -0
- package/dist/collection/components/ez-split-button/ez-split-button.js.gz +0 -0
- package/dist/collection/components/ez-split-button/test/dropdownItems.js.gz +0 -0
- package/dist/collection/components/ez-split-panel/ez-split-panel.css.gz +0 -0
- package/dist/collection/components/ez-split-panel/ez-split-panel.js.gz +0 -0
- package/dist/collection/components/ez-split-panel/interfaces/IPanelSizeInfo.js.gz +0 -0
- package/dist/collection/components/ez-split-panel/structure/item/ez-split-item.css.gz +0 -0
- package/dist/collection/components/ez-split-panel/structure/item/ez-split-item.js.gz +0 -0
- package/dist/collection/components/ez-tabselector/ez-tabselector.css.gz +0 -0
- package/dist/collection/components/ez-tabselector/ez-tabselector.js.gz +0 -0
- package/dist/collection/components/ez-tag/ez-tag.css.gz +0 -0
- package/dist/collection/components/ez-tag/ez-tag.js.gz +0 -0
- package/dist/collection/components/ez-tag-input/ez-tag-input.css.gz +0 -0
- package/dist/collection/components/ez-tag-input/ez-tag-input.js.gz +0 -0
- package/dist/collection/components/ez-tag-input/interfaces/optionsSetFocus.js.gz +0 -0
- package/dist/collection/components/ez-text-area/ez-text-area.css.gz +0 -0
- package/dist/collection/components/ez-text-area/ez-text-area.js.gz +0 -0
- package/dist/collection/components/ez-text-edit/ez-text-edit.css.gz +0 -0
- package/dist/collection/components/ez-text-edit/ez-text-edit.js.gz +0 -0
- package/dist/collection/components/ez-text-input/ez-text-input.css.gz +0 -0
- package/dist/collection/components/ez-text-input/ez-text-input.js.gz +0 -0
- package/dist/collection/components/ez-tile/ez-tile.css.gz +0 -0
- package/dist/collection/components/ez-tile/ez-tile.js.gz +0 -0
- package/dist/collection/components/ez-tile-medium/ez-tile-medium.css.gz +0 -0
- package/dist/collection/components/ez-tile-medium/ez-tile-medium.js.gz +0 -0
- package/dist/collection/components/ez-time-input/ez-time-input.css.gz +0 -0
- package/dist/collection/components/ez-time-input/ez-time-input.js.gz +0 -0
- package/dist/collection/components/ez-toast/ez-toast.css.gz +0 -0
- package/dist/collection/components/ez-toast/ez-toast.js.gz +0 -0
- package/dist/collection/components/ez-tooltip/ez-tooltip.css.gz +0 -0
- package/dist/collection/components/ez-tooltip/ez-tooltip.js.gz +0 -0
- package/dist/collection/components/ez-tree/ez-tree.css.gz +0 -0
- package/dist/collection/components/ez-tree/ez-tree.js.gz +0 -0
- package/dist/collection/components/ez-tree/interfaces/ITree.js.gz +0 -0
- package/dist/collection/components/ez-tree/interfaces/ITreeItem.js.gz +0 -0
- package/dist/collection/components/ez-tree/interfaces/ITreeItemBadge.js.gz +0 -0
- package/dist/collection/components/ez-tree/subcomponents/DefaultIconResolver.js.gz +0 -0
- package/dist/collection/components/ez-tree/subcomponents/DefaultTooltipResolver.js.gz +0 -0
- package/dist/collection/components/ez-tree/subcomponents/TreeItem.js.gz +0 -0
- package/dist/collection/components/ez-tree/subcomponents/index.js.gz +0 -0
- package/dist/collection/components/ez-tree/types/Node.js.gz +0 -0
- package/dist/collection/components/ez-tree/types/Tree.js.gz +0 -0
- package/dist/collection/components/ez-tree/types/UpdateItemConfig.js.gz +0 -0
- package/dist/collection/components/ez-underface/ez-underface.css.gz +0 -0
- package/dist/collection/components/ez-underface/ez-underface.js.gz +0 -0
- package/dist/collection/components/ez-upload/RemoteFile.js.gz +0 -0
- package/dist/collection/components/ez-upload/ez-upload.css.gz +0 -0
- package/dist/collection/components/ez-upload/ez-upload.js.gz +0 -0
- package/dist/collection/components/ez-view-stack/ez-view-stack.css.gz +0 -0
- package/dist/collection/components/ez-view-stack/ez-view-stack.js.gz +0 -0
- package/dist/collection/global/app-init.js.gz +0 -0
- package/dist/collection/index.js.gz +0 -0
- package/dist/collection/servidor.js.gz +0 -0
- package/dist/collection/setupTests.js.gz +0 -0
- package/dist/collection/sw.js.gz +0 -0
- package/dist/collection/utils/ApplicationUtils.js.gz +0 -0
- package/dist/collection/utils/AssetsUtils.js.gz +0 -0
- package/dist/collection/utils/CSSVarsUtils.js.gz +0 -0
- package/dist/collection/utils/FocusResolver.js.gz +0 -0
- package/dist/collection/utils/ag-grid-license.js.gz +0 -0
- package/dist/collection/utils/constants.js.gz +0 -0
- package/dist/collection/utils/customEditor/interfaces/ICustomEditor.js.gz +0 -0
- package/dist/collection/utils/customEditor/interfaces/ICustomEditorInfo.js.gz +0 -0
- package/dist/collection/utils/customRender/interfaces/ICustomRender.js.gz +0 -0
- package/dist/collection/utils/customRender/interfaces/ICustomRenderInfo.js.gz +0 -0
- package/dist/collection/utils/form/DataBinder.js.gz +0 -0
- package/dist/collection/utils/form/FormMetadata.js.gz +0 -0
- package/dist/collection/utils/form/index.js.gz +0 -0
- package/dist/collection/utils/form/interfaces/FormLayout.js.gz +0 -0
- package/dist/collection/utils/form/interfaces/IDefaultConfig.js.gz +0 -0
- package/dist/collection/utils/form/interfaces/IFormCardConfig.js.gz +0 -0
- package/dist/collection/utils/form/interfaces/IFormConfig.js.gz +0 -0
- package/dist/collection/utils/form/interfaces/IFormSheetMetadata.js.gz +0 -0
- package/dist/collection/utils/form/interfaces/ISummaryField.js.gz +0 -0
- package/dist/collection/utils/form/interfaces/ITabConfig.js.gz +0 -0
- package/dist/collection/utils/form/interfaces/index.js.gz +0 -0
- package/dist/collection/utils/form/test/DataBinder.test.js.gz +0 -0
- package/dist/collection/utils/form/test/resources/metadataTest.js.gz +0 -0
- package/dist/collection/utils/i18n/elanguages.js.gz +0 -0
- package/dist/collection/utils/i18n/index.js.gz +0 -0
- package/dist/collection/utils/i18n/locales/en-us.js.gz +0 -0
- package/dist/collection/utils/i18n/locales/es-es.js.gz +0 -0
- package/dist/collection/utils/i18n/locales/pt-br.js.gz +0 -0
- package/dist/collection/utils/i18n/translations.js.gz +0 -0
- package/dist/collection/utils/index.js.gz +0 -0
- package/dist/collection/utils/interfaces/AbstractFieldMetadata.js.gz +0 -0
- package/dist/collection/utils/interfaces/IAction.js.gz +0 -0
- package/dist/collection/utils/interfaces/IFieldConfig.js.gz +0 -0
- package/dist/collection/utils/mock/ez-upload-mock.js.gz +0 -0
- package/dist/collection/utils/search/types.js.gz +0 -0
- package/dist/collection/utils/searchColumn/search-column.js.gz +0 -0
- package/dist/collection/utils/utils.js.gz +0 -0
- package/dist/collection/utils/validators/recordvalidator/IInvalidCells.js.gz +0 -0
- package/dist/collection/utils/validators/recordvalidator/IInvalidField.js.gz +0 -0
- package/dist/collection/utils/validators/recordvalidator/IRecordValidator.js.gz +0 -0
- package/dist/collection/utils/validators/recordvalidator/IValidationResult.js.gz +0 -0
- package/dist/collection/utils/validators/recordvalidator/IValidationSource.js.gz +0 -0
- package/dist/collection/utils/validators/recordvalidator/RecordValidationProcessor.js.gz +0 -0
- package/dist/custom-elements/index.js +683 -246
- package/dist/custom-elements/index.js.gz +0 -0
- package/dist/esm/ApplicationUtils-1569f757.js.gz +0 -0
- package/dist/esm/CSSVarsUtils-acba92d7.js.gz +0 -0
- package/dist/esm/CheckMode-bdb2ec19.js.gz +0 -0
- package/dist/esm/DialogType-54a62731.js.gz +0 -0
- package/dist/esm/EzScrollDirection-2df26c93.js.gz +0 -0
- package/dist/esm/FocusResolver-1ccbf850.js.gz +0 -0
- package/dist/esm/FormLayout-071d324c.js.gz +0 -0
- package/dist/esm/RichToolbarHelper-f3a149c4.js.gz +0 -0
- package/dist/esm/_commonjsHelpers-9943807e.js.gz +0 -0
- package/dist/esm/app-globals-c0ac93c0.js.gz +0 -0
- package/dist/esm/constants-3fabe81e.js.gz +0 -0
- package/dist/esm/ez-actions-button.entry.js.gz +0 -0
- package/dist/esm/ez-alert-list.entry.js.gz +0 -0
- package/dist/esm/ez-alert.entry.js.gz +0 -0
- package/dist/esm/ez-application.entry.js.gz +0 -0
- package/dist/esm/ez-avatar.entry.js.gz +0 -0
- package/dist/esm/ez-badge.entry.js.gz +0 -0
- package/dist/esm/ez-breadcrumb.entry.js.gz +0 -0
- package/dist/esm/ez-button.entry.js.gz +0 -0
- package/dist/esm/ez-calendar.entry.js.gz +0 -0
- package/dist/esm/ez-card-item.entry.js.gz +0 -0
- package/dist/esm/ez-chart.entry.js.gz +0 -0
- package/dist/esm/ez-check.entry.js.gz +0 -0
- package/dist/esm/ez-chip.entry.js.gz +0 -0
- package/dist/esm/ez-classic-combo-box.entry.js.gz +0 -0
- package/dist/esm/ez-classic-input.entry.js.gz +0 -0
- package/dist/esm/ez-classic-text-area.entry.js.gz +0 -0
- package/dist/esm/ez-collapsible-box.entry.js.gz +0 -0
- package/dist/esm/ez-combo-box-list_4.entry.js +1 -1
- package/dist/esm/ez-combo-box-list_4.entry.js.gz +0 -0
- package/dist/esm/ez-combo-box.entry.js.gz +0 -0
- package/dist/esm/ez-date-input.entry.js.gz +0 -0
- package/dist/esm/ez-date-time-input.entry.js.gz +0 -0
- package/dist/esm/ez-dialog.entry.js.gz +0 -0
- package/dist/esm/ez-double-list.entry.js.gz +0 -0
- package/dist/esm/ez-dropdown.entry.js.gz +0 -0
- package/dist/esm/ez-empty-card.entry.js.gz +0 -0
- package/dist/esm/ez-file-item.entry.js.gz +0 -0
- package/dist/esm/ez-filter-input.entry.js.gz +0 -0
- package/dist/esm/ez-form-view.entry.js.gz +0 -0
- package/dist/esm/ez-form.entry.js.gz +0 -0
- package/dist/esm/ez-grid-view.entry.js.gz +0 -0
- package/dist/esm/ez-grid.entry.js +1 -1
- package/dist/esm/ez-grid.entry.js.gz +0 -0
- package/dist/esm/ez-guide-navigator.entry.js.gz +0 -0
- package/dist/esm/ez-icon.entry.js.gz +0 -0
- package/dist/esm/ez-link-builder_6.entry.js.gz +0 -0
- package/dist/esm/ez-list-item.entry.js.gz +0 -0
- package/dist/esm/ez-list.entry.js.gz +0 -0
- package/dist/esm/ez-loading-bar.entry.js.gz +0 -0
- package/dist/esm/ez-modal-container.entry.js.gz +0 -0
- package/dist/esm/ez-modal.entry.js.gz +0 -0
- package/dist/esm/ez-multi-selection-list.entry.js.gz +0 -0
- package/dist/esm/ez-number-input.entry.js.gz +0 -0
- package/dist/esm/ez-pagination.entry.js.gz +0 -0
- package/dist/esm/ez-popover-core.entry.js.gz +0 -0
- package/dist/esm/ez-popover-plus_3.entry.js.gz +0 -0
- package/dist/esm/ez-popover.entry.js.gz +0 -0
- package/dist/esm/ez-popup.entry.js.gz +0 -0
- package/dist/esm/ez-progress-bar.entry.js.gz +0 -0
- package/dist/esm/ez-radio-button.entry.js.gz +0 -0
- package/dist/esm/ez-rich-toolbar-item.entry.js.gz +0 -0
- package/dist/esm/ez-scroller_2.entry.js.gz +0 -0
- package/dist/esm/ez-search-plus.entry.js.gz +0 -0
- package/dist/esm/ez-search-result-list.entry.js.gz +0 -0
- package/dist/esm/ez-search.entry.js.gz +0 -0
- package/dist/esm/ez-sidebar-navigator.entry.js.gz +0 -0
- package/dist/esm/ez-skeleton.entry.js.gz +0 -0
- package/dist/esm/ez-sortable-list.entry.js.gz +0 -0
- package/dist/esm/ez-spinner.entry.js.gz +0 -0
- package/dist/esm/ez-split-button.entry.js.gz +0 -0
- package/dist/esm/ez-split-item.entry.js.gz +0 -0
- package/dist/esm/ez-split-panel.entry.js.gz +0 -0
- package/dist/esm/ez-tabselector.entry.js.gz +0 -0
- package/dist/esm/ez-tag-input.entry.js.gz +0 -0
- package/dist/esm/ez-tag.entry.js.gz +0 -0
- package/dist/esm/ez-text-area.entry.js.gz +0 -0
- package/dist/esm/ez-text-input.entry.js.gz +0 -0
- package/dist/esm/ez-tile-medium.entry.js.gz +0 -0
- package/dist/esm/ez-tile.entry.js.gz +0 -0
- package/dist/esm/ez-time-input.entry.js.gz +0 -0
- package/dist/esm/ez-toast.entry.js.gz +0 -0
- package/dist/esm/ez-tooltip.entry.js.gz +0 -0
- package/dist/esm/ez-tree.entry.js.gz +0 -0
- package/dist/esm/ez-underface.entry.js.gz +0 -0
- package/dist/esm/ez-upload.entry.js.gz +0 -0
- package/dist/esm/ez-view-stack.entry.js.gz +0 -0
- package/dist/esm/ezListHelper-00fb9b8d.js.gz +0 -0
- package/dist/esm/ezui.js.gz +0 -0
- package/dist/esm/filter-column.entry.js +6 -1
- package/dist/esm/filter-column.entry.js.gz +0 -0
- package/dist/esm/floating-ui.dom.esm-ad30f2f0.js.gz +0 -0
- package/dist/esm/index-41363fa6.js.gz +0 -0
- package/dist/esm/index-baa5e267.js.gz +0 -0
- package/dist/esm/index.js.gz +0 -0
- package/dist/esm/loader.js.gz +0 -0
- package/dist/esm/polyfills/core-js.js.gz +0 -0
- package/dist/esm/polyfills/css-shim.js.gz +0 -0
- package/dist/esm/polyfills/dom.js.gz +0 -0
- package/dist/esm/polyfills/es5-html-element.js.gz +0 -0
- package/dist/esm/polyfills/index.js.gz +0 -0
- package/dist/esm/polyfills/system.js.gz +0 -0
- package/dist/esm/{purify-a818ad63.js → purify-d55d1f11.js} +677 -245
- package/dist/esm/purify-d55d1f11.js.gz +0 -0
- package/dist/esm/search-column-c20d2b01.js.gz +0 -0
- package/dist/esm/searchFormatters-8229207e.js.gz +0 -0
- package/dist/ezui/ezui.esm.js +1 -1
- package/dist/ezui/ezui.esm.js.gz +0 -0
- package/dist/ezui/index.esm.js.gz +0 -0
- package/dist/ezui/p-02d448bb.entry.js.gz +0 -0
- package/dist/ezui/p-04126429.js.gz +0 -0
- package/dist/ezui/p-05c32903.entry.js.gz +0 -0
- package/dist/ezui/p-0f7971cf.entry.js.gz +0 -0
- package/dist/ezui/p-110cfb7d.entry.js.gz +0 -0
- package/dist/ezui/p-112455b1.js.gz +0 -0
- package/dist/ezui/p-18384b91.entry.js.gz +0 -0
- package/dist/ezui/p-1e7a8633.entry.js.gz +0 -0
- package/dist/ezui/p-1f50fa05.entry.js.gz +0 -0
- package/dist/ezui/p-20c024f7.entry.js.gz +0 -0
- package/dist/ezui/p-23a36bb6.js.gz +0 -0
- package/dist/ezui/p-2528e988.entry.js.gz +0 -0
- package/dist/ezui/p-288631d1.entry.js.gz +0 -0
- package/dist/ezui/p-2a806303.js.gz +0 -0
- package/dist/ezui/{p-183db57c.entry.js → p-2cc07392.entry.js} +1 -1
- package/dist/ezui/p-2cc07392.entry.js.gz +0 -0
- package/dist/ezui/p-30ffb9ed.js.gz +0 -0
- package/dist/ezui/p-34a476a9.entry.js.gz +0 -0
- package/dist/ezui/p-351fb12f.entry.js.gz +0 -0
- package/dist/ezui/p-39761eca.entry.js.gz +0 -0
- package/dist/ezui/p-3afa1c6e.entry.js.gz +0 -0
- package/dist/ezui/p-3ce867cf.entry.js.gz +0 -0
- package/dist/ezui/p-3e767a74.js.gz +0 -0
- package/dist/ezui/p-40a60148.js.gz +0 -0
- package/dist/ezui/p-411c0222.entry.js.gz +0 -0
- package/dist/ezui/p-4314f87a.entry.js.gz +0 -0
- package/dist/ezui/p-48effc69.entry.js.gz +0 -0
- package/dist/ezui/p-4d30b703.entry.js.gz +0 -0
- package/dist/ezui/p-4fe123b6.entry.js.gz +0 -0
- package/dist/ezui/p-5554704c.js.gz +0 -0
- package/dist/ezui/p-5ed81457.entry.js.gz +0 -0
- package/dist/ezui/p-6020f3d5.entry.js.gz +0 -0
- package/dist/ezui/p-62a362b4.js +3 -0
- package/dist/ezui/p-62a362b4.js.gz +0 -0
- package/dist/ezui/p-6c51ccd1.entry.js.gz +0 -0
- package/dist/ezui/p-6ca0815e.entry.js.gz +0 -0
- package/dist/ezui/p-6cb82d33.entry.js.gz +0 -0
- package/dist/ezui/p-6d596a5a.entry.js.gz +0 -0
- package/dist/ezui/p-6de4cae1.entry.js.gz +0 -0
- package/dist/ezui/p-6f77a359.entry.js.gz +0 -0
- package/dist/ezui/p-721fd999.entry.js.gz +0 -0
- package/dist/ezui/p-7995dcb4.entry.js.gz +0 -0
- package/dist/ezui/p-7f37ee99.entry.js.gz +0 -0
- package/dist/ezui/p-7f792043.entry.js.gz +0 -0
- package/dist/ezui/p-7fe97ef5.entry.js.gz +0 -0
- package/dist/ezui/p-80dfc50b.js.gz +0 -0
- package/dist/ezui/p-859e3134.entry.js.gz +0 -0
- package/dist/ezui/p-8df1ca33.entry.js.gz +0 -0
- package/dist/ezui/p-91c9d50e.entry.js.gz +0 -0
- package/dist/ezui/p-93e1c917.entry.js.gz +0 -0
- package/dist/ezui/p-948f0fb2.entry.js.gz +0 -0
- package/dist/ezui/p-94deb71e.entry.js.gz +0 -0
- package/dist/ezui/p-967ed829.entry.js +1 -0
- package/dist/ezui/p-967ed829.entry.js.gz +0 -0
- package/dist/ezui/p-98bb8b16.js.gz +0 -0
- package/dist/ezui/p-9ab2add9.entry.js.gz +0 -0
- package/dist/ezui/p-9b215871.entry.js.gz +0 -0
- package/dist/ezui/p-9b3f3c02.entry.js.gz +0 -0
- package/dist/ezui/p-9f5fa3f9.entry.js.gz +0 -0
- package/dist/ezui/p-a0bf1fc7.entry.js.gz +0 -0
- package/dist/ezui/p-a278f26e.entry.js.gz +0 -0
- package/dist/ezui/p-a3075f52.entry.js.gz +0 -0
- package/dist/ezui/p-a3ada561.entry.js.gz +0 -0
- package/dist/ezui/p-a4083a7a.entry.js.gz +0 -0
- package/dist/ezui/p-a61fdd20.js.gz +0 -0
- package/dist/ezui/p-a63b20a0.entry.js.gz +0 -0
- package/dist/ezui/p-a80b1287.entry.js.gz +0 -0
- package/dist/ezui/p-ab574d59.js.gz +0 -0
- package/dist/ezui/p-b1e45320.js.gz +0 -0
- package/dist/ezui/p-b3d8034b.entry.js.gz +0 -0
- package/dist/ezui/p-b853763b.js.gz +0 -0
- package/dist/ezui/p-b989a33e.entry.js.gz +0 -0
- package/dist/ezui/p-baec56c9.js.gz +0 -0
- package/dist/ezui/p-bc2f844e.entry.js.gz +0 -0
- package/dist/ezui/{p-c9ef8551.entry.js → p-c2d1f276.entry.js} +1 -1
- package/dist/ezui/p-c2d1f276.entry.js.gz +0 -0
- package/dist/ezui/p-cde41310.entry.js.gz +0 -0
- package/dist/ezui/p-ce0b36d7.entry.js.gz +0 -0
- package/dist/ezui/p-d2645bdf.entry.js.gz +0 -0
- package/dist/ezui/p-d5eb2fad.entry.js.gz +0 -0
- package/dist/ezui/p-d6742c1e.entry.js.gz +0 -0
- package/dist/ezui/p-d6bb930d.entry.js.gz +0 -0
- package/dist/ezui/p-d6f50207.entry.js.gz +0 -0
- package/dist/ezui/p-d8cc640d.entry.js.gz +0 -0
- package/dist/ezui/p-dc628ed3.js.gz +0 -0
- package/dist/ezui/p-de862af4.entry.js.gz +0 -0
- package/dist/ezui/p-dee18824.entry.js.gz +0 -0
- package/dist/ezui/p-e5de42e7.entry.js.gz +0 -0
- package/dist/ezui/p-e75c7a23.entry.js.gz +0 -0
- package/dist/ezui/p-e7a7c594.entry.js.gz +0 -0
- package/dist/ezui/p-e8c57463.entry.js.gz +0 -0
- package/dist/ezui/p-ec7db713.js.gz +0 -0
- package/dist/ezui/p-ecd6409d.entry.js.gz +0 -0
- package/dist/ezui/p-ef8bd3e8.entry.js.gz +0 -0
- package/dist/ezui/p-f00c9dc2.entry.js.gz +0 -0
- package/dist/ezui/p-f34ec732.entry.js.gz +0 -0
- package/dist/ezui/p-fa6732f2.entry.js.gz +0 -0
- package/dist/index.cjs.js.gz +0 -0
- package/dist/index.js.gz +0 -0
- package/package.json +1 -1
- package/dist/cjs/purify-ca9603eb.js.gz +0 -0
- package/dist/esm/purify-a818ad63.js.gz +0 -0
- package/dist/ezui/p-183db57c.entry.js.gz +0 -0
- package/dist/ezui/p-197eb577.js +0 -3
- package/dist/ezui/p-197eb577.js.gz +0 -0
- package/dist/ezui/p-2b49aa22.entry.js +0 -1
- package/dist/ezui/p-2b49aa22.entry.js.gz +0 -0
- package/dist/ezui/p-c9ef8551.entry.js.gz +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { c as createCommonjsModule, a as commonjsGlobal } from './_commonjsHelpers-9943807e.js';
|
|
2
2
|
|
|
3
3
|
var purify = createCommonjsModule(function (module, exports) {
|
|
4
|
-
/*! @license DOMPurify 3.4.
|
|
4
|
+
/*! @license DOMPurify 3.4.10 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.4.10/LICENSE */
|
|
5
5
|
|
|
6
6
|
(function (global, factory) {
|
|
7
7
|
module.exports = factory() ;
|
|
@@ -333,6 +333,13 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
333
333
|
);
|
|
334
334
|
const DOCTYPE_NAME = seal(/^html$/i);
|
|
335
335
|
const CUSTOM_ELEMENT = seal(/^[a-z][.\w]*(-[.\w]+)+$/i);
|
|
336
|
+
// Markup-significant character probes used by _sanitizeElements.
|
|
337
|
+
// Shared module-level instances are safe despite the sticky /g flags:
|
|
338
|
+
// unapply() resets lastIndex for RegExp receivers before every call.
|
|
339
|
+
const ELEMENT_MARKUP_PROBE = seal(/<[/\w!]/g);
|
|
340
|
+
const COMMENT_MARKUP_PROBE = seal(/<[/\w]/g);
|
|
341
|
+
const FALLBACK_TAG_CLOSE = seal(/<\/no(script|embed|frames)/i);
|
|
342
|
+
const SELF_CLOSING_TAG = seal(/\/>/i);
|
|
336
343
|
|
|
337
344
|
/* eslint-disable @typescript-eslint/indent */
|
|
338
345
|
// https://developer.mozilla.org/en-US/docs/Web/API/Node/nodeType
|
|
@@ -345,7 +352,7 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
345
352
|
// Deprecated
|
|
346
353
|
entityNode: 6,
|
|
347
354
|
// Deprecated
|
|
348
|
-
|
|
355
|
+
processingInstruction: 7,
|
|
349
356
|
comment: 8,
|
|
350
357
|
document: 9,
|
|
351
358
|
documentType: 10,
|
|
@@ -405,10 +412,25 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
405
412
|
uponSanitizeShadowNode: []
|
|
406
413
|
};
|
|
407
414
|
};
|
|
415
|
+
/**
|
|
416
|
+
* Resolve a set-valued configuration option: a fresh set built from
|
|
417
|
+
* cfg[key] when it is an own array property (seeded with a clone of
|
|
418
|
+
* options.base when given, case-normalized via options.transform),
|
|
419
|
+
* the fallback set otherwise.
|
|
420
|
+
*
|
|
421
|
+
* @param cfg the cloned, prototype-free configuration object
|
|
422
|
+
* @param key the configuration property to read
|
|
423
|
+
* @param fallback the set to use when the option is absent or not an array
|
|
424
|
+
* @param options transform and optional base set to merge into
|
|
425
|
+
* @returns the resolved set
|
|
426
|
+
*/
|
|
427
|
+
const _resolveSetOption = function _resolveSetOption(cfg, key, fallback, options) {
|
|
428
|
+
return objectHasOwnProperty(cfg, key) && arrayIsArray(cfg[key]) ? addToSet(options.base ? clone(options.base) : {}, cfg[key], options.transform) : fallback;
|
|
429
|
+
};
|
|
408
430
|
function createDOMPurify() {
|
|
409
431
|
let window = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : getGlobal();
|
|
410
432
|
const DOMPurify = root => createDOMPurify(root);
|
|
411
|
-
DOMPurify.version = '3.4.
|
|
433
|
+
DOMPurify.version = '3.4.10';
|
|
412
434
|
DOMPurify.removed = [];
|
|
413
435
|
if (!window || !window.document || window.document.nodeType !== NODE_TYPE.document || !window.Element) {
|
|
414
436
|
// Not running in a browser, provide a factory function
|
|
@@ -449,23 +471,54 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
449
471
|
}
|
|
450
472
|
let trustedTypesPolicy;
|
|
451
473
|
let emptyHTML = '';
|
|
474
|
+
// The instance's own internal Trusted Types policy. Unlike a caller-supplied
|
|
475
|
+
// `TRUSTED_TYPES_POLICY`, this is created at most once — Trusted Types throws
|
|
476
|
+
// on duplicate policy names — and is the only policy allowed to persist
|
|
477
|
+
// across configurations and survive `clearConfig()`.
|
|
478
|
+
let defaultTrustedTypesPolicy;
|
|
479
|
+
let defaultTrustedTypesPolicyResolved = false;
|
|
452
480
|
// Tracks whether we are already inside a call to the configured Trusted Types
|
|
453
|
-
// policy
|
|
481
|
+
// policy (`createHTML` or `createScriptURL`). If a supplied policy callback
|
|
454
482
|
// itself calls `DOMPurify.sanitize` (the cause of #1422), `sanitize` would
|
|
455
483
|
// re-enter the policy and recurse until the stack overflows. We detect that
|
|
456
|
-
// re-entry and throw a clear, actionable error instead.
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
484
|
+
// re-entry and throw a clear, actionable error instead. The guard is shared
|
|
485
|
+
// across both callbacks, because either one re-entering `sanitize` triggers
|
|
486
|
+
// the same unbounded recursion.
|
|
487
|
+
let IN_TRUSTED_TYPES_POLICY = 0;
|
|
488
|
+
const _assertNotInTrustedTypesPolicy = function _assertNotInTrustedTypesPolicy() {
|
|
489
|
+
if (IN_TRUSTED_TYPES_POLICY > 0) {
|
|
490
|
+
throw typeErrorCreate('A configured TRUSTED_TYPES_POLICY callback (createHTML or ' + 'createScriptURL) must not call DOMPurify.sanitize, as that causes ' + 'infinite recursion. Do not pass a policy whose callbacks wrap ' + 'DOMPurify as TRUSTED_TYPES_POLICY; see the "DOMPurify and Trusted ' + 'Types" section of the README.');
|
|
461
491
|
}
|
|
462
|
-
|
|
492
|
+
};
|
|
493
|
+
const _createTrustedHTML = function _createTrustedHTML(html) {
|
|
494
|
+
_assertNotInTrustedTypesPolicy();
|
|
495
|
+
IN_TRUSTED_TYPES_POLICY++;
|
|
463
496
|
try {
|
|
464
497
|
return trustedTypesPolicy.createHTML(html);
|
|
465
498
|
} finally {
|
|
466
|
-
|
|
499
|
+
IN_TRUSTED_TYPES_POLICY--;
|
|
467
500
|
}
|
|
468
501
|
};
|
|
502
|
+
const _createTrustedScriptURL = function _createTrustedScriptURL(scriptUrl) {
|
|
503
|
+
_assertNotInTrustedTypesPolicy();
|
|
504
|
+
IN_TRUSTED_TYPES_POLICY++;
|
|
505
|
+
try {
|
|
506
|
+
return trustedTypesPolicy.createScriptURL(scriptUrl);
|
|
507
|
+
} finally {
|
|
508
|
+
IN_TRUSTED_TYPES_POLICY--;
|
|
509
|
+
}
|
|
510
|
+
};
|
|
511
|
+
// Lazily resolve (and cache) the instance's internal default policy.
|
|
512
|
+
// Resolution is attempted at most once: a successful `createPolicy` cannot be
|
|
513
|
+
// repeated (Trusted Types throws on duplicate names), and a failed or
|
|
514
|
+
// unsupported attempt must not be retried on every parse.
|
|
515
|
+
const _getDefaultTrustedTypesPolicy = function _getDefaultTrustedTypesPolicy() {
|
|
516
|
+
if (!defaultTrustedTypesPolicyResolved) {
|
|
517
|
+
defaultTrustedTypesPolicy = _createTrustedTypesPolicy(trustedTypes, currentScript);
|
|
518
|
+
defaultTrustedTypesPolicyResolved = true;
|
|
519
|
+
}
|
|
520
|
+
return defaultTrustedTypesPolicy;
|
|
521
|
+
};
|
|
469
522
|
const _document = document,
|
|
470
523
|
implementation = _document.implementation,
|
|
471
524
|
createNodeIterator = _document.createNodeIterator,
|
|
@@ -604,7 +657,17 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
604
657
|
let USE_PROFILES = {};
|
|
605
658
|
/* Tags to ignore content of when KEEP_CONTENT is true */
|
|
606
659
|
let FORBID_CONTENTS = null;
|
|
607
|
-
const DEFAULT_FORBID_CONTENTS = addToSet({}, ['annotation-xml', 'audio', 'colgroup', 'desc', 'foreignobject', 'head', 'iframe', 'math', 'mi', 'mn', 'mo', 'ms', 'mtext', 'noembed', 'noframes', 'noscript', 'plaintext', 'script',
|
|
660
|
+
const DEFAULT_FORBID_CONTENTS = addToSet({}, ['annotation-xml', 'audio', 'colgroup', 'desc', 'foreignobject', 'head', 'iframe', 'math', 'mi', 'mn', 'mo', 'ms', 'mtext', 'noembed', 'noframes', 'noscript', 'plaintext', 'script',
|
|
661
|
+
// <selectedcontent> mirrors the selected <option>'s subtree, cloned by
|
|
662
|
+
// the UA (customizable <select>) — including any on* handlers — and the
|
|
663
|
+
// engine re-mirrors synchronously whenever a removal changes which
|
|
664
|
+
// option/selectedcontent is current, even inside DOMPurify's inert
|
|
665
|
+
// DOMParser document. Hoisting its children on removal re-inserts a fresh
|
|
666
|
+
// mirror target ahead of the walk, which the engine refills, looping
|
|
667
|
+
// forever (DoS) and amplifying output. Dropping its content on removal
|
|
668
|
+
// (rather than hoisting) breaks that cascade; the content is a duplicate
|
|
669
|
+
// of the option, which is sanitized on its own. See campaign-3 F1/F6.
|
|
670
|
+
'selectedcontent', 'style', 'svg', 'template', 'thead', 'title', 'video', 'xmp']);
|
|
608
671
|
/* Tags that are safe for data: URIs */
|
|
609
672
|
let DATA_URI_TAGS = null;
|
|
610
673
|
const DEFAULT_DATA_URI_TAGS = addToSet({}, ['audio', 'video', 'img', 'source', 'image', 'track']);
|
|
@@ -620,8 +683,10 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
620
683
|
/* Allowed XHTML+XML namespaces */
|
|
621
684
|
let ALLOWED_NAMESPACES = null;
|
|
622
685
|
const DEFAULT_ALLOWED_NAMESPACES = addToSet({}, [MATHML_NAMESPACE, SVG_NAMESPACE, HTML_NAMESPACE], stringToString);
|
|
623
|
-
|
|
624
|
-
let
|
|
686
|
+
const DEFAULT_MATHML_TEXT_INTEGRATION_POINTS = freeze(['mi', 'mo', 'mn', 'ms', 'mtext']);
|
|
687
|
+
let MATHML_TEXT_INTEGRATION_POINTS = addToSet({}, DEFAULT_MATHML_TEXT_INTEGRATION_POINTS);
|
|
688
|
+
const DEFAULT_HTML_INTEGRATION_POINTS = freeze(['annotation-xml']);
|
|
689
|
+
let HTML_INTEGRATION_POINTS = addToSet({}, DEFAULT_HTML_INTEGRATION_POINTS);
|
|
625
690
|
// Certain elements are allowed in both SVG and HTML
|
|
626
691
|
// namespace. We need to specify them explicitly
|
|
627
692
|
// so that they don't get erroneously deleted from
|
|
@@ -663,14 +728,32 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
663
728
|
// HTML tags and attributes are not case-sensitive, converting to lowercase. Keeping XHTML as is.
|
|
664
729
|
transformCaseFunc = PARSER_MEDIA_TYPE === 'application/xhtml+xml' ? stringToString : stringToLowerCase;
|
|
665
730
|
/* Set configuration parameters */
|
|
666
|
-
ALLOWED_TAGS =
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
731
|
+
ALLOWED_TAGS = _resolveSetOption(cfg, 'ALLOWED_TAGS', DEFAULT_ALLOWED_TAGS, {
|
|
732
|
+
transform: transformCaseFunc
|
|
733
|
+
});
|
|
734
|
+
ALLOWED_ATTR = _resolveSetOption(cfg, 'ALLOWED_ATTR', DEFAULT_ALLOWED_ATTR, {
|
|
735
|
+
transform: transformCaseFunc
|
|
736
|
+
});
|
|
737
|
+
ALLOWED_NAMESPACES = _resolveSetOption(cfg, 'ALLOWED_NAMESPACES', DEFAULT_ALLOWED_NAMESPACES, {
|
|
738
|
+
transform: stringToString
|
|
739
|
+
});
|
|
740
|
+
URI_SAFE_ATTRIBUTES = _resolveSetOption(cfg, 'ADD_URI_SAFE_ATTR', DEFAULT_URI_SAFE_ATTRIBUTES, {
|
|
741
|
+
transform: transformCaseFunc,
|
|
742
|
+
base: DEFAULT_URI_SAFE_ATTRIBUTES
|
|
743
|
+
});
|
|
744
|
+
DATA_URI_TAGS = _resolveSetOption(cfg, 'ADD_DATA_URI_TAGS', DEFAULT_DATA_URI_TAGS, {
|
|
745
|
+
transform: transformCaseFunc,
|
|
746
|
+
base: DEFAULT_DATA_URI_TAGS
|
|
747
|
+
});
|
|
748
|
+
FORBID_CONTENTS = _resolveSetOption(cfg, 'FORBID_CONTENTS', DEFAULT_FORBID_CONTENTS, {
|
|
749
|
+
transform: transformCaseFunc
|
|
750
|
+
});
|
|
751
|
+
FORBID_TAGS = _resolveSetOption(cfg, 'FORBID_TAGS', clone({}), {
|
|
752
|
+
transform: transformCaseFunc
|
|
753
|
+
});
|
|
754
|
+
FORBID_ATTR = _resolveSetOption(cfg, 'FORBID_ATTR', clone({}), {
|
|
755
|
+
transform: transformCaseFunc
|
|
756
|
+
});
|
|
674
757
|
USE_PROFILES = objectHasOwnProperty(cfg, 'USE_PROFILES') ? cfg.USE_PROFILES && typeof cfg.USE_PROFILES === 'object' ? clone(cfg.USE_PROFILES) : cfg.USE_PROFILES : false;
|
|
675
758
|
ALLOW_ARIA_ATTR = cfg.ALLOW_ARIA_ATTR !== false; // Default true
|
|
676
759
|
ALLOW_DATA_ATTR = cfg.ALLOW_DATA_ATTR !== false; // Default true
|
|
@@ -689,8 +772,8 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
689
772
|
IN_PLACE = cfg.IN_PLACE || false; // Default false
|
|
690
773
|
IS_ALLOWED_URI$1 = isRegex(cfg.ALLOWED_URI_REGEXP) ? cfg.ALLOWED_URI_REGEXP : IS_ALLOWED_URI; // Default regexp
|
|
691
774
|
NAMESPACE = typeof cfg.NAMESPACE === 'string' ? cfg.NAMESPACE : HTML_NAMESPACE; // Default HTML namespace
|
|
692
|
-
MATHML_TEXT_INTEGRATION_POINTS = objectHasOwnProperty(cfg, 'MATHML_TEXT_INTEGRATION_POINTS') && cfg.MATHML_TEXT_INTEGRATION_POINTS && typeof cfg.MATHML_TEXT_INTEGRATION_POINTS === 'object' ? clone(cfg.MATHML_TEXT_INTEGRATION_POINTS) : addToSet({},
|
|
693
|
-
HTML_INTEGRATION_POINTS = objectHasOwnProperty(cfg, 'HTML_INTEGRATION_POINTS') && cfg.HTML_INTEGRATION_POINTS && typeof cfg.HTML_INTEGRATION_POINTS === 'object' ? clone(cfg.HTML_INTEGRATION_POINTS) : addToSet({},
|
|
775
|
+
MATHML_TEXT_INTEGRATION_POINTS = objectHasOwnProperty(cfg, 'MATHML_TEXT_INTEGRATION_POINTS') && cfg.MATHML_TEXT_INTEGRATION_POINTS && typeof cfg.MATHML_TEXT_INTEGRATION_POINTS === 'object' ? clone(cfg.MATHML_TEXT_INTEGRATION_POINTS) : addToSet({}, DEFAULT_MATHML_TEXT_INTEGRATION_POINTS); // Default built-in map
|
|
776
|
+
HTML_INTEGRATION_POINTS = objectHasOwnProperty(cfg, 'HTML_INTEGRATION_POINTS') && cfg.HTML_INTEGRATION_POINTS && typeof cfg.HTML_INTEGRATION_POINTS === 'object' ? clone(cfg.HTML_INTEGRATION_POINTS) : addToSet({}, DEFAULT_HTML_INTEGRATION_POINTS); // Default built-in map
|
|
694
777
|
const customElementHandling = objectHasOwnProperty(cfg, 'CUSTOM_ELEMENT_HANDLING') && cfg.CUSTOM_ELEMENT_HANDLING && typeof cfg.CUSTOM_ELEMENT_HANDLING === 'object' ? clone(cfg.CUSTOM_ELEMENT_HANDLING) : create(null);
|
|
695
778
|
CUSTOM_ELEMENT_HANDLING = create(null);
|
|
696
779
|
if (objectHasOwnProperty(customElementHandling, 'tagNameCheck') && isRegexOrFunction(customElementHandling.tagNameCheck)) {
|
|
@@ -702,6 +785,7 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
702
785
|
if (objectHasOwnProperty(customElementHandling, 'allowCustomizedBuiltInElements') && typeof customElementHandling.allowCustomizedBuiltInElements === 'boolean') {
|
|
703
786
|
CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements = customElementHandling.allowCustomizedBuiltInElements; // Default undefined
|
|
704
787
|
}
|
|
788
|
+
seal(CUSTOM_ELEMENT_HANDLING);
|
|
705
789
|
if (SAFE_FOR_TEMPLATES) {
|
|
706
790
|
ALLOW_DATA_ATTR = false;
|
|
707
791
|
}
|
|
@@ -785,6 +869,13 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
785
869
|
addToSet(ALLOWED_TAGS, ['tbody']);
|
|
786
870
|
delete FORBID_TAGS.tbody;
|
|
787
871
|
}
|
|
872
|
+
// Re-derive the active Trusted Types policy from this configuration on
|
|
873
|
+
// every parse. The active policy must never be sticky closure state that
|
|
874
|
+
// outlives the config that set it: a caller-supplied policy left in place
|
|
875
|
+
// after `clearConfig()` — or after a later call that supplied none, or
|
|
876
|
+
// `TRUSTED_TYPES_POLICY: null` — could sign a subsequent "default"
|
|
877
|
+
// `RETURN_TRUSTED_TYPE` result with a foreign, possibly unsafe policy.
|
|
878
|
+
// See GHSA-vxr8-fq34-vvx9.
|
|
788
879
|
if (cfg.TRUSTED_TYPES_POLICY) {
|
|
789
880
|
if (typeof cfg.TRUSTED_TYPES_POLICY.createHTML !== 'function') {
|
|
790
881
|
throw typeErrorCreate('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');
|
|
@@ -792,7 +883,7 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
792
883
|
if (typeof cfg.TRUSTED_TYPES_POLICY.createScriptURL !== 'function') {
|
|
793
884
|
throw typeErrorCreate('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');
|
|
794
885
|
}
|
|
795
|
-
//
|
|
886
|
+
// A caller-supplied policy applies to this configuration only.
|
|
796
887
|
const previousTrustedTypesPolicy = trustedTypesPolicy;
|
|
797
888
|
trustedTypesPolicy = cfg.TRUSTED_TYPES_POLICY;
|
|
798
889
|
// Sign local variables required by `sanitize`. If the supplied policy's
|
|
@@ -805,16 +896,30 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
805
896
|
trustedTypesPolicy = previousTrustedTypesPolicy;
|
|
806
897
|
throw error;
|
|
807
898
|
}
|
|
899
|
+
} else if (cfg.TRUSTED_TYPES_POLICY === null) {
|
|
900
|
+
// Explicit opt-out for this call: perform no Trusted Types signing and
|
|
901
|
+
// create nothing (so a strict `trusted-types` CSP that disallows a
|
|
902
|
+
// `dompurify` policy can still call `sanitize` from inside its own
|
|
903
|
+
// policy — see #1422). Resetting to `undefined` rather than a sticky
|
|
904
|
+
// `null` also drops any previously retained caller policy, so it cannot
|
|
905
|
+
// resurface on a later call, while still allowing the next config-less
|
|
906
|
+
// call to restore the internal default policy. See GHSA-vxr8-fq34-vvx9.
|
|
907
|
+
trustedTypesPolicy = undefined;
|
|
908
|
+
emptyHTML = '';
|
|
808
909
|
} else {
|
|
809
|
-
//
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
//
|
|
814
|
-
//
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
910
|
+
// No policy supplied: keep the currently active policy if one is set — a
|
|
911
|
+
// previously supplied policy is intentionally sticky across config-less
|
|
912
|
+
// calls — otherwise fall back to the instance's own internal policy,
|
|
913
|
+
// created at most once. (A policy supplied for a *single* call still
|
|
914
|
+
// lingers by design; what must not linger is a policy whose configuration
|
|
915
|
+
// has been torn down via `clearConfig()`, which restores the default.)
|
|
916
|
+
if (trustedTypesPolicy === undefined) {
|
|
917
|
+
trustedTypesPolicy = _getDefaultTrustedTypesPolicy();
|
|
918
|
+
}
|
|
919
|
+
// Sign internal variables only when a policy is active. A falsy policy
|
|
920
|
+
// (Trusted Types unsupported, creation failed, or an explicit opt-out)
|
|
921
|
+
// leaves `emptyHTML` as a plain string, so we never call `.createHTML` on
|
|
922
|
+
// a non-policy and throw. See #1422.
|
|
818
923
|
if (trustedTypesPolicy && typeof emptyHTML === 'string') {
|
|
819
924
|
emptyHTML = _createTrustedHTML('');
|
|
820
925
|
}
|
|
@@ -846,6 +951,77 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
846
951
|
* correctly. */
|
|
847
952
|
const ALL_SVG_TAGS = addToSet({}, [...svg$1, ...svgFilters, ...svgDisallowed]);
|
|
848
953
|
const ALL_MATHML_TAGS = addToSet({}, [...mathMl$1, ...mathMlDisallowed]);
|
|
954
|
+
/**
|
|
955
|
+
* Namespace rules for an element in the SVG namespace.
|
|
956
|
+
*
|
|
957
|
+
* @param tagName the element's lowercase tag name
|
|
958
|
+
* @param parent the (possibly simulated) parent node
|
|
959
|
+
* @param parentTagName the parent's lowercase tag name
|
|
960
|
+
* @returns true if a spec-compliant parser could produce this element
|
|
961
|
+
*/
|
|
962
|
+
const _checkSvgNamespace = function _checkSvgNamespace(tagName, parent, parentTagName) {
|
|
963
|
+
// The only way to switch from HTML namespace to SVG
|
|
964
|
+
// is via <svg>. If it happens via any other tag, then
|
|
965
|
+
// it should be killed.
|
|
966
|
+
if (parent.namespaceURI === HTML_NAMESPACE) {
|
|
967
|
+
return tagName === 'svg';
|
|
968
|
+
}
|
|
969
|
+
// The only way to switch from MathML to SVG is via <svg>
|
|
970
|
+
// if the parent is either <annotation-xml> or a MathML
|
|
971
|
+
// text integration point.
|
|
972
|
+
if (parent.namespaceURI === MATHML_NAMESPACE) {
|
|
973
|
+
return tagName === 'svg' && (parentTagName === 'annotation-xml' || MATHML_TEXT_INTEGRATION_POINTS[parentTagName]);
|
|
974
|
+
}
|
|
975
|
+
// We only allow elements that are defined in SVG
|
|
976
|
+
// spec. All others are disallowed in SVG namespace.
|
|
977
|
+
return Boolean(ALL_SVG_TAGS[tagName]);
|
|
978
|
+
};
|
|
979
|
+
/**
|
|
980
|
+
* Namespace rules for an element in the MathML namespace.
|
|
981
|
+
*
|
|
982
|
+
* @param tagName the element's lowercase tag name
|
|
983
|
+
* @param parent the (possibly simulated) parent node
|
|
984
|
+
* @param parentTagName the parent's lowercase tag name
|
|
985
|
+
* @returns true if a spec-compliant parser could produce this element
|
|
986
|
+
*/
|
|
987
|
+
const _checkMathMlNamespace = function _checkMathMlNamespace(tagName, parent, parentTagName) {
|
|
988
|
+
// The only way to switch from HTML namespace to MathML
|
|
989
|
+
// is via <math>. If it happens via any other tag, then
|
|
990
|
+
// it should be killed.
|
|
991
|
+
if (parent.namespaceURI === HTML_NAMESPACE) {
|
|
992
|
+
return tagName === 'math';
|
|
993
|
+
}
|
|
994
|
+
// The only way to switch from SVG to MathML is via
|
|
995
|
+
// <math> and HTML integration points
|
|
996
|
+
if (parent.namespaceURI === SVG_NAMESPACE) {
|
|
997
|
+
return tagName === 'math' && HTML_INTEGRATION_POINTS[parentTagName];
|
|
998
|
+
}
|
|
999
|
+
// We only allow elements that are defined in MathML
|
|
1000
|
+
// spec. All others are disallowed in MathML namespace.
|
|
1001
|
+
return Boolean(ALL_MATHML_TAGS[tagName]);
|
|
1002
|
+
};
|
|
1003
|
+
/**
|
|
1004
|
+
* Namespace rules for an element in the HTML namespace.
|
|
1005
|
+
*
|
|
1006
|
+
* @param tagName the element's lowercase tag name
|
|
1007
|
+
* @param parent the (possibly simulated) parent node
|
|
1008
|
+
* @param parentTagName the parent's lowercase tag name
|
|
1009
|
+
* @returns true if a spec-compliant parser could produce this element
|
|
1010
|
+
*/
|
|
1011
|
+
const _checkHtmlNamespace = function _checkHtmlNamespace(tagName, parent, parentTagName) {
|
|
1012
|
+
// The only way to switch from SVG to HTML is via
|
|
1013
|
+
// HTML integration points, and from MathML to HTML
|
|
1014
|
+
// is via MathML text integration points
|
|
1015
|
+
if (parent.namespaceURI === SVG_NAMESPACE && !HTML_INTEGRATION_POINTS[parentTagName]) {
|
|
1016
|
+
return false;
|
|
1017
|
+
}
|
|
1018
|
+
if (parent.namespaceURI === MATHML_NAMESPACE && !MATHML_TEXT_INTEGRATION_POINTS[parentTagName]) {
|
|
1019
|
+
return false;
|
|
1020
|
+
}
|
|
1021
|
+
// We disallow tags that are specific for MathML
|
|
1022
|
+
// or SVG and should never appear in HTML namespace
|
|
1023
|
+
return !ALL_MATHML_TAGS[tagName] && (COMMON_SVG_AND_HTML_ELEMENTS[tagName] || !ALL_SVG_TAGS[tagName]);
|
|
1024
|
+
};
|
|
849
1025
|
/**
|
|
850
1026
|
* @param element a DOM element whose namespace is being checked
|
|
851
1027
|
* @returns Return false if the element has a
|
|
@@ -868,51 +1044,13 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
868
1044
|
return false;
|
|
869
1045
|
}
|
|
870
1046
|
if (element.namespaceURI === SVG_NAMESPACE) {
|
|
871
|
-
|
|
872
|
-
// is via <svg>. If it happens via any other tag, then
|
|
873
|
-
// it should be killed.
|
|
874
|
-
if (parent.namespaceURI === HTML_NAMESPACE) {
|
|
875
|
-
return tagName === 'svg';
|
|
876
|
-
}
|
|
877
|
-
// The only way to switch from MathML to SVG is via`
|
|
878
|
-
// svg if parent is either <annotation-xml> or MathML
|
|
879
|
-
// text integration points.
|
|
880
|
-
if (parent.namespaceURI === MATHML_NAMESPACE) {
|
|
881
|
-
return tagName === 'svg' && (parentTagName === 'annotation-xml' || MATHML_TEXT_INTEGRATION_POINTS[parentTagName]);
|
|
882
|
-
}
|
|
883
|
-
// We only allow elements that are defined in SVG
|
|
884
|
-
// spec. All others are disallowed in SVG namespace.
|
|
885
|
-
return Boolean(ALL_SVG_TAGS[tagName]);
|
|
1047
|
+
return _checkSvgNamespace(tagName, parent, parentTagName);
|
|
886
1048
|
}
|
|
887
1049
|
if (element.namespaceURI === MATHML_NAMESPACE) {
|
|
888
|
-
|
|
889
|
-
// is via <math>. If it happens via any other tag, then
|
|
890
|
-
// it should be killed.
|
|
891
|
-
if (parent.namespaceURI === HTML_NAMESPACE) {
|
|
892
|
-
return tagName === 'math';
|
|
893
|
-
}
|
|
894
|
-
// The only way to switch from SVG to MathML is via
|
|
895
|
-
// <math> and HTML integration points
|
|
896
|
-
if (parent.namespaceURI === SVG_NAMESPACE) {
|
|
897
|
-
return tagName === 'math' && HTML_INTEGRATION_POINTS[parentTagName];
|
|
898
|
-
}
|
|
899
|
-
// We only allow elements that are defined in MathML
|
|
900
|
-
// spec. All others are disallowed in MathML namespace.
|
|
901
|
-
return Boolean(ALL_MATHML_TAGS[tagName]);
|
|
1050
|
+
return _checkMathMlNamespace(tagName, parent, parentTagName);
|
|
902
1051
|
}
|
|
903
1052
|
if (element.namespaceURI === HTML_NAMESPACE) {
|
|
904
|
-
|
|
905
|
-
// HTML integration points, and from MathML to HTML
|
|
906
|
-
// is via MathML text integration points
|
|
907
|
-
if (parent.namespaceURI === SVG_NAMESPACE && !HTML_INTEGRATION_POINTS[parentTagName]) {
|
|
908
|
-
return false;
|
|
909
|
-
}
|
|
910
|
-
if (parent.namespaceURI === MATHML_NAMESPACE && !MATHML_TEXT_INTEGRATION_POINTS[parentTagName]) {
|
|
911
|
-
return false;
|
|
912
|
-
}
|
|
913
|
-
// We disallow tags that are specific for MathML
|
|
914
|
-
// or SVG and should never appear in HTML namespace
|
|
915
|
-
return !ALL_MATHML_TAGS[tagName] && (COMMON_SVG_AND_HTML_ELEMENTS[tagName] || !ALL_SVG_TAGS[tagName]);
|
|
1053
|
+
return _checkHtmlNamespace(tagName, parent, parentTagName);
|
|
916
1054
|
}
|
|
917
1055
|
// For XHTML and XML documents that support custom namespaces
|
|
918
1056
|
if (PARSER_MEDIA_TYPE === 'application/xhtml+xml' && ALLOWED_NAMESPACES[element.namespaceURI]) {
|
|
@@ -937,7 +1075,74 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
937
1075
|
// eslint-disable-next-line unicorn/prefer-dom-node-remove
|
|
938
1076
|
getParentNode(node).removeChild(node);
|
|
939
1077
|
} catch (_) {
|
|
1078
|
+
/* The normal detach failed — this is reached for a parentless node
|
|
1079
|
+
(getParentNode() is null, so .removeChild throws). Element.prototype
|
|
1080
|
+
.remove() is itself a spec no-op on a parentless node, so a recorded
|
|
1081
|
+
"removal" would otherwise hand the caller back an intact,
|
|
1082
|
+
payload-bearing node (e.g. a detached IN_PLACE root the mXSS canary or
|
|
1083
|
+
the style-with-element-child rule decided to kill). Fail closed by
|
|
1084
|
+
throwing — exactly as a clobbered root does at the IN_PLACE entry —
|
|
1085
|
+
rather than trying to "neutralize" the node via its own methods.
|
|
1086
|
+
Neutralizing would mean calling getAttributeNames()/removeAttribute()
|
|
1087
|
+
on the node, both of which a <form> root can clobber via a named child
|
|
1088
|
+
(and _isClobbered does not even probe getAttributeNames), so the
|
|
1089
|
+
neutralize step could itself be silently defeated, leaving the payload
|
|
1090
|
+
intact. A throw touches only the cached, clobber-safe remove() and
|
|
1091
|
+
getParentNode(). Generalizes GHSA-r47g-fvhr-h676 (clobbered-form root)
|
|
1092
|
+
to every root-kill reason. REPORT-3.
|
|
1093
|
+
This lives inside the catch, so it never fires for a normally-removed
|
|
1094
|
+
in-tree node: those have a parent, removeChild() succeeds, and the
|
|
1095
|
+
catch is not entered. Only a kept (parentless) root reaches here. */
|
|
940
1096
|
remove(node);
|
|
1097
|
+
if (!getParentNode(node)) {
|
|
1098
|
+
throw typeErrorCreate('a node selected for removal could not be detached from its tree ' + 'and cannot be safely returned; refusing to sanitize in place');
|
|
1099
|
+
}
|
|
1100
|
+
}
|
|
1101
|
+
};
|
|
1102
|
+
/**
|
|
1103
|
+
* _neutralizeRoot
|
|
1104
|
+
*
|
|
1105
|
+
* Fail-closed teardown of an in-place root after the sanitize walk aborts
|
|
1106
|
+
* (campaign-3 F2). An internal throw mid-walk — e.g. a page-registered
|
|
1107
|
+
* custom element's reaction detaches a node so `_forceRemove`'s deliberate
|
|
1108
|
+
* parentless guard throws, or any other re-entrant engine mutation — would
|
|
1109
|
+
* otherwise leave the caller's *live* tree half-sanitized, with everything
|
|
1110
|
+
* after the abort point still carrying its handlers. There is no safe way
|
|
1111
|
+
* to resume the walk (the tree mutated under us), so we strip the root bare:
|
|
1112
|
+
* remove every child and every attribute, then let the caller's catch see
|
|
1113
|
+
* the original error. Clobber-safe (cached `remove`/`childNodes`/`attributes`
|
|
1114
|
+
* getters; the root was already clobber-pre-flighted at the IN_PLACE entry).
|
|
1115
|
+
*
|
|
1116
|
+
* @param root the in-place root to empty
|
|
1117
|
+
*/
|
|
1118
|
+
const _neutralizeRoot = function _neutralizeRoot(root) {
|
|
1119
|
+
const childNodes = getChildNodes(root);
|
|
1120
|
+
if (childNodes) {
|
|
1121
|
+
const snapshot = [];
|
|
1122
|
+
arrayForEach(childNodes, child => {
|
|
1123
|
+
arrayPush(snapshot, child);
|
|
1124
|
+
});
|
|
1125
|
+
arrayForEach(snapshot, child => {
|
|
1126
|
+
try {
|
|
1127
|
+
remove(child);
|
|
1128
|
+
} catch (_) {
|
|
1129
|
+
/* Best-effort teardown; a still-attached child is handled below */
|
|
1130
|
+
}
|
|
1131
|
+
});
|
|
1132
|
+
}
|
|
1133
|
+
const attributes = getAttributes(root);
|
|
1134
|
+
if (attributes) {
|
|
1135
|
+
for (let i = attributes.length - 1; i >= 0; --i) {
|
|
1136
|
+
const attribute = attributes[i];
|
|
1137
|
+
const name = attribute && attribute.name;
|
|
1138
|
+
if (typeof name === 'string') {
|
|
1139
|
+
try {
|
|
1140
|
+
root.removeAttribute(name);
|
|
1141
|
+
} catch (_) {
|
|
1142
|
+
/* Clobbered removeAttribute — ignore (fail-closed best effort) */
|
|
1143
|
+
}
|
|
1144
|
+
}
|
|
1145
|
+
}
|
|
941
1146
|
}
|
|
942
1147
|
};
|
|
943
1148
|
/**
|
|
@@ -972,6 +1177,72 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
972
1177
|
}
|
|
973
1178
|
}
|
|
974
1179
|
};
|
|
1180
|
+
/**
|
|
1181
|
+
* _stripDisallowedAttributes
|
|
1182
|
+
*
|
|
1183
|
+
* Removes every attribute the active configuration does not allow from a
|
|
1184
|
+
* single element, using the same allowlist as the main attribute pass (so
|
|
1185
|
+
* `on*` handlers go, but no `/^on/` blocklist is introduced). Used only to
|
|
1186
|
+
* neutralise nodes that are being discarded from an in-place tree.
|
|
1187
|
+
*
|
|
1188
|
+
* @param element the element to strip
|
|
1189
|
+
*/
|
|
1190
|
+
const _stripDisallowedAttributes = function _stripDisallowedAttributes(element) {
|
|
1191
|
+
const attributes = getAttributes(element);
|
|
1192
|
+
if (!attributes) {
|
|
1193
|
+
return;
|
|
1194
|
+
}
|
|
1195
|
+
for (let i = attributes.length - 1; i >= 0; --i) {
|
|
1196
|
+
const attribute = attributes[i];
|
|
1197
|
+
const name = attribute && attribute.name;
|
|
1198
|
+
if (typeof name !== 'string' || ALLOWED_ATTR[transformCaseFunc(name)]) {
|
|
1199
|
+
continue;
|
|
1200
|
+
}
|
|
1201
|
+
try {
|
|
1202
|
+
element.removeAttribute(name);
|
|
1203
|
+
} catch (_) {
|
|
1204
|
+
/* Clobbered removeAttribute on a doomed node — ignore */
|
|
1205
|
+
}
|
|
1206
|
+
}
|
|
1207
|
+
};
|
|
1208
|
+
/**
|
|
1209
|
+
* _neutralizeSubtree
|
|
1210
|
+
*
|
|
1211
|
+
* Completes the audit-5 F1 fix across every removal path. The KEEP_CONTENT
|
|
1212
|
+
* move-hoist neutralises only disallowed-tag removals; clobber, mXSS-canary,
|
|
1213
|
+
* namespace, comment, processing-instruction and KEEP_CONTENT:false removals
|
|
1214
|
+
* all drop their subtree wholesale via `_forceRemove`. On the IN_PLACE path
|
|
1215
|
+
* those dropped nodes are detached from the caller's LIVE tree but a
|
|
1216
|
+
* handler-bearing original among them (an `<img onerror>`/`<video>` that was
|
|
1217
|
+
* loading) keeps its queued resource event, which fires in page scope after
|
|
1218
|
+
* sanitize returns. This walks a removed subtree and strips every attribute
|
|
1219
|
+
* the active configuration does not allow — so `on*` handlers are cancelled
|
|
1220
|
+
* through the SAME allowlist that governs kept nodes, not a separate `/^on/`
|
|
1221
|
+
* blocklist. Run synchronously before sanitize returns, i.e. before any
|
|
1222
|
+
* queued event can fire. Hook-free by design: these nodes leave the output,
|
|
1223
|
+
* so firing attribute hooks for them would be surprising. Clobber-safe reads;
|
|
1224
|
+
* a doomed clobbered node may shadow `removeAttribute` (its own attributes are
|
|
1225
|
+
* irrelevant — it is discarded — while its non-clobbered descendants, e.g.
|
|
1226
|
+
* the `<img>`, are reached and scrubbed).
|
|
1227
|
+
*
|
|
1228
|
+
* @param root the root of a removed subtree to neutralise
|
|
1229
|
+
*/
|
|
1230
|
+
const _neutralizeSubtree = function _neutralizeSubtree(root) {
|
|
1231
|
+
const stack = [root];
|
|
1232
|
+
while (stack.length > 0) {
|
|
1233
|
+
const node = stack.pop();
|
|
1234
|
+
const nodeType = getNodeType ? getNodeType(node) : node.nodeType;
|
|
1235
|
+
if (nodeType === NODE_TYPE.element) {
|
|
1236
|
+
_stripDisallowedAttributes(node);
|
|
1237
|
+
}
|
|
1238
|
+
const childNodes = getChildNodes(node);
|
|
1239
|
+
if (childNodes) {
|
|
1240
|
+
for (let i = childNodes.length - 1; i >= 0; --i) {
|
|
1241
|
+
stack.push(childNodes[i]);
|
|
1242
|
+
}
|
|
1243
|
+
}
|
|
1244
|
+
}
|
|
1245
|
+
};
|
|
975
1246
|
/**
|
|
976
1247
|
* _initDocument
|
|
977
1248
|
*
|
|
@@ -1033,6 +1304,20 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
1033
1304
|
// eslint-disable-next-line no-bitwise
|
|
1034
1305
|
NodeFilter.SHOW_ELEMENT | NodeFilter.SHOW_COMMENT | NodeFilter.SHOW_TEXT | NodeFilter.SHOW_PROCESSING_INSTRUCTION | NodeFilter.SHOW_CDATA_SECTION, null);
|
|
1035
1306
|
};
|
|
1307
|
+
/**
|
|
1308
|
+
* Replace template expression syntax (mustache, ERB, template
|
|
1309
|
+
* literal) with a space; shared by all SAFE_FOR_TEMPLATES scrub
|
|
1310
|
+
* sites. Order matters: mustache, then ERB, then template literal.
|
|
1311
|
+
*
|
|
1312
|
+
* @param value the string to scrub
|
|
1313
|
+
* @returns the scrubbed string
|
|
1314
|
+
*/
|
|
1315
|
+
const _stripTemplateExpressions = function _stripTemplateExpressions(value) {
|
|
1316
|
+
value = stringReplace(value, MUSTACHE_EXPR$1, ' ');
|
|
1317
|
+
value = stringReplace(value, ERB_EXPR$1, ' ');
|
|
1318
|
+
value = stringReplace(value, TMPLIT_EXPR$1, ' ');
|
|
1319
|
+
return value;
|
|
1320
|
+
};
|
|
1036
1321
|
/**
|
|
1037
1322
|
* Strip template-engine expressions ({{...}}, ${...}, <%...%>) from the
|
|
1038
1323
|
* character data of an element subtree. Used as the final safety net for
|
|
@@ -1053,29 +1338,27 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
1053
1338
|
* @param node The root element whose character data should be scrubbed.
|
|
1054
1339
|
*/
|
|
1055
1340
|
const _scrubTemplateExpressions2 = function _scrubTemplateExpressions(node) {
|
|
1056
|
-
var _node$querySelectorAl
|
|
1341
|
+
var _node$querySelectorAl;
|
|
1057
1342
|
node.normalize();
|
|
1058
1343
|
const walker = createNodeIterator.call(node.ownerDocument || node, node,
|
|
1059
1344
|
// eslint-disable-next-line no-bitwise
|
|
1060
1345
|
NodeFilter.SHOW_TEXT | NodeFilter.SHOW_COMMENT | NodeFilter.SHOW_CDATA_SECTION | NodeFilter.SHOW_PROCESSING_INSTRUCTION, null);
|
|
1061
1346
|
let currentNode = walker.nextNode();
|
|
1062
1347
|
while (currentNode) {
|
|
1063
|
-
|
|
1064
|
-
arrayForEach([MUSTACHE_EXPR$1, ERB_EXPR$1, TMPLIT_EXPR$1], expr => {
|
|
1065
|
-
data = stringReplace(data, expr, ' ');
|
|
1066
|
-
});
|
|
1067
|
-
currentNode.data = data;
|
|
1348
|
+
currentNode.data = _stripTemplateExpressions(currentNode.data);
|
|
1068
1349
|
currentNode = walker.nextNode();
|
|
1069
1350
|
}
|
|
1070
1351
|
// NodeIterator does not descend into <template>.content per the DOM spec,
|
|
1071
1352
|
// so we must explicitly recurse into each template's content fragment,
|
|
1072
1353
|
// mirroring the approach used by _sanitizeShadowDOM.
|
|
1073
|
-
const templates = (_node$querySelectorAl =
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1354
|
+
const templates = (_node$querySelectorAl = node.querySelectorAll) === null || _node$querySelectorAl === void 0 ? void 0 : _node$querySelectorAl.call(node, 'template');
|
|
1355
|
+
if (templates) {
|
|
1356
|
+
arrayForEach(templates, tmpl => {
|
|
1357
|
+
if (_isDocumentFragment(tmpl.content)) {
|
|
1358
|
+
_scrubTemplateExpressions2(tmpl.content);
|
|
1359
|
+
}
|
|
1360
|
+
});
|
|
1361
|
+
}
|
|
1079
1362
|
};
|
|
1080
1363
|
/**
|
|
1081
1364
|
* _isClobbered
|
|
@@ -1171,10 +1454,104 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
1171
1454
|
}
|
|
1172
1455
|
};
|
|
1173
1456
|
function _executeHooks(hooks, currentNode, data) {
|
|
1457
|
+
if (hooks.length === 0) {
|
|
1458
|
+
return;
|
|
1459
|
+
}
|
|
1174
1460
|
arrayForEach(hooks, hook => {
|
|
1175
1461
|
hook.call(DOMPurify, currentNode, data, CONFIG);
|
|
1176
1462
|
});
|
|
1177
1463
|
}
|
|
1464
|
+
/**
|
|
1465
|
+
* Structural-threat checks that condemn a node regardless of the
|
|
1466
|
+
* allowlists: mXSS via namespace confusion, risky CSS construction,
|
|
1467
|
+
* processing instructions, markup-bearing comments. Pure predicate;
|
|
1468
|
+
* the caller removes. Check order is load-bearing.
|
|
1469
|
+
*
|
|
1470
|
+
* @param currentNode the node to inspect
|
|
1471
|
+
* @param tagName the node's transformCaseFunc'd tag name
|
|
1472
|
+
* @return true if the node must be removed
|
|
1473
|
+
*/
|
|
1474
|
+
const _isUnsafeNode = function _isUnsafeNode(currentNode, tagName) {
|
|
1475
|
+
/* Detect mXSS attempts abusing namespace confusion */
|
|
1476
|
+
if (SAFE_FOR_XML && currentNode.hasChildNodes() && !_isNode(currentNode.firstElementChild) && regExpTest(ELEMENT_MARKUP_PROBE, currentNode.textContent) && regExpTest(ELEMENT_MARKUP_PROBE, currentNode.innerHTML)) {
|
|
1477
|
+
return true;
|
|
1478
|
+
}
|
|
1479
|
+
/* Remove risky CSS construction leading to mXSS */
|
|
1480
|
+
if (SAFE_FOR_XML && currentNode.namespaceURI === HTML_NAMESPACE && tagName === 'style' && _isNode(currentNode.firstElementChild)) {
|
|
1481
|
+
return true;
|
|
1482
|
+
}
|
|
1483
|
+
/* Remove any occurrence of processing instructions */
|
|
1484
|
+
if (currentNode.nodeType === NODE_TYPE.processingInstruction) {
|
|
1485
|
+
return true;
|
|
1486
|
+
}
|
|
1487
|
+
/* Remove any kind of possibly harmful comments */
|
|
1488
|
+
if (SAFE_FOR_XML && currentNode.nodeType === NODE_TYPE.comment && regExpTest(COMMENT_MARKUP_PROBE, currentNode.data)) {
|
|
1489
|
+
return true;
|
|
1490
|
+
}
|
|
1491
|
+
return false;
|
|
1492
|
+
};
|
|
1493
|
+
/**
|
|
1494
|
+
* Handle a node whose tag is forbidden or not allowlisted: keep
|
|
1495
|
+
* allowed custom elements (false return exits _sanitizeElements
|
|
1496
|
+
* early - namespace/fallback checks and the afterSanitizeElements
|
|
1497
|
+
* hook are intentionally skipped for kept custom elements), else
|
|
1498
|
+
* hoist content per KEEP_CONTENT and remove.
|
|
1499
|
+
*
|
|
1500
|
+
* @param currentNode the disallowed node
|
|
1501
|
+
* @param tagName the node's transformCaseFunc'd tag name
|
|
1502
|
+
* @return true if the node was removed, false if kept
|
|
1503
|
+
*/
|
|
1504
|
+
const _sanitizeDisallowedNode = function _sanitizeDisallowedNode(currentNode, tagName) {
|
|
1505
|
+
/* Check if we have a custom element to handle */
|
|
1506
|
+
if (!FORBID_TAGS[tagName] && _isBasicCustomElement(tagName)) {
|
|
1507
|
+
if (CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof RegExp && regExpTest(CUSTOM_ELEMENT_HANDLING.tagNameCheck, tagName)) {
|
|
1508
|
+
return false;
|
|
1509
|
+
}
|
|
1510
|
+
if (CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof Function && CUSTOM_ELEMENT_HANDLING.tagNameCheck(tagName)) {
|
|
1511
|
+
return false;
|
|
1512
|
+
}
|
|
1513
|
+
}
|
|
1514
|
+
/* Keep content except for bad-listed elements.
|
|
1515
|
+
Use the cached prototype getters exclusively — the previous code
|
|
1516
|
+
had `|| currentNode.parentNode` / `|| currentNode.childNodes`
|
|
1517
|
+
fallbacks, but the cached getters always return the canonical
|
|
1518
|
+
value (or null for a real parent-less node), so the fallback
|
|
1519
|
+
path was dead in safe cases and a clobbering surface in unsafe
|
|
1520
|
+
ones. Falsy cached results stay falsy; the `if (childNodes &&
|
|
1521
|
+
parentNode)` check already gates correctly. */
|
|
1522
|
+
if (KEEP_CONTENT && !FORBID_CONTENTS[tagName]) {
|
|
1523
|
+
const parentNode = getParentNode(currentNode);
|
|
1524
|
+
const childNodes = getChildNodes(currentNode);
|
|
1525
|
+
if (childNodes && parentNode) {
|
|
1526
|
+
const childCount = childNodes.length;
|
|
1527
|
+
/* In-place: hoist the *original* children so the iterator visits
|
|
1528
|
+
and sanitises them through the same allowlist pass as every other
|
|
1529
|
+
node. The caller built the tree in the live document, so the
|
|
1530
|
+
originals carry already-queued resource events (`<img onerror>`,
|
|
1531
|
+
`<video>`/`<audio>` error, lazy/`onload`, …); cloning would leave
|
|
1532
|
+
those originals detached but still armed, firing in page scope
|
|
1533
|
+
while the returned tree looked clean. Moving is safe in-place: the
|
|
1534
|
+
root is pre-validated as an allowed tag and so is never the node
|
|
1535
|
+
being removed, which keeps `parentNode` inside the iterator root
|
|
1536
|
+
and the relocated child inside the serialised tree.
|
|
1537
|
+
Otherwise (string / DOM-copy paths): clone. The iterator is rooted
|
|
1538
|
+
at — and the result serialised from — `body`, so a restrictive
|
|
1539
|
+
ALLOWED_TAGS that removes `body` itself must leave its content in
|
|
1540
|
+
place, which only cloning does; and those paths parse into an
|
|
1541
|
+
inert document, so their discarded originals never had a queued
|
|
1542
|
+
event to neutralise.
|
|
1543
|
+
`childNodes` is live; a tail-to-head walk keeps `childNodes[i]`
|
|
1544
|
+
valid whether we move (drops the trailing entry) or clone (leaves
|
|
1545
|
+
the list intact). */
|
|
1546
|
+
for (let i = childCount - 1; i >= 0; --i) {
|
|
1547
|
+
const hoisted = IN_PLACE ? childNodes[i] : cloneNode(childNodes[i], true);
|
|
1548
|
+
parentNode.insertBefore(hoisted, getNextSibling(currentNode));
|
|
1549
|
+
}
|
|
1550
|
+
}
|
|
1551
|
+
}
|
|
1552
|
+
_forceRemove(currentNode);
|
|
1553
|
+
return true;
|
|
1554
|
+
};
|
|
1178
1555
|
/**
|
|
1179
1556
|
* _sanitizeElements
|
|
1180
1557
|
*
|
|
@@ -1185,7 +1562,6 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
1185
1562
|
* @return true if node was killed, false if left alive
|
|
1186
1563
|
*/
|
|
1187
1564
|
const _sanitizeElements = function _sanitizeElements(currentNode) {
|
|
1188
|
-
let content = null;
|
|
1189
1565
|
/* Execute a hook if present */
|
|
1190
1566
|
_executeHooks(hooks.beforeSanitizeElements, currentNode, null);
|
|
1191
1567
|
/* Check if element is clobbered or can clobber */
|
|
@@ -1200,58 +1576,14 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
1200
1576
|
tagName,
|
|
1201
1577
|
allowedTags: ALLOWED_TAGS
|
|
1202
1578
|
});
|
|
1203
|
-
/*
|
|
1204
|
-
if (
|
|
1205
|
-
_forceRemove(currentNode);
|
|
1206
|
-
return true;
|
|
1207
|
-
}
|
|
1208
|
-
/* Remove risky CSS construction leading to mXSS */
|
|
1209
|
-
if (SAFE_FOR_XML && currentNode.namespaceURI === HTML_NAMESPACE && tagName === 'style' && _isNode(currentNode.firstElementChild)) {
|
|
1210
|
-
_forceRemove(currentNode);
|
|
1211
|
-
return true;
|
|
1212
|
-
}
|
|
1213
|
-
/* Remove any occurrence of processing instructions */
|
|
1214
|
-
if (currentNode.nodeType === NODE_TYPE.progressingInstruction) {
|
|
1215
|
-
_forceRemove(currentNode);
|
|
1216
|
-
return true;
|
|
1217
|
-
}
|
|
1218
|
-
/* Remove any kind of possibly harmful comments */
|
|
1219
|
-
if (SAFE_FOR_XML && currentNode.nodeType === NODE_TYPE.comment && regExpTest(/<[/\w]/g, currentNode.data)) {
|
|
1579
|
+
/* Remove mXSS vectors, processing instructions and risky comments */
|
|
1580
|
+
if (_isUnsafeNode(currentNode, tagName)) {
|
|
1220
1581
|
_forceRemove(currentNode);
|
|
1221
1582
|
return true;
|
|
1222
1583
|
}
|
|
1223
1584
|
/* Remove element if anything forbids its presence */
|
|
1224
1585
|
if (FORBID_TAGS[tagName] || !(EXTRA_ELEMENT_HANDLING.tagCheck instanceof Function && EXTRA_ELEMENT_HANDLING.tagCheck(tagName)) && !ALLOWED_TAGS[tagName]) {
|
|
1225
|
-
|
|
1226
|
-
if (!FORBID_TAGS[tagName] && _isBasicCustomElement(tagName)) {
|
|
1227
|
-
if (CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof RegExp && regExpTest(CUSTOM_ELEMENT_HANDLING.tagNameCheck, tagName)) {
|
|
1228
|
-
return false;
|
|
1229
|
-
}
|
|
1230
|
-
if (CUSTOM_ELEMENT_HANDLING.tagNameCheck instanceof Function && CUSTOM_ELEMENT_HANDLING.tagNameCheck(tagName)) {
|
|
1231
|
-
return false;
|
|
1232
|
-
}
|
|
1233
|
-
}
|
|
1234
|
-
/* Keep content except for bad-listed elements.
|
|
1235
|
-
Use the cached prototype getters exclusively — the previous code
|
|
1236
|
-
had `|| currentNode.parentNode` / `|| currentNode.childNodes`
|
|
1237
|
-
fallbacks, but the cached getters always return the canonical
|
|
1238
|
-
value (or null for a real parent-less node), so the fallback
|
|
1239
|
-
path was dead in safe cases and a clobbering surface in unsafe
|
|
1240
|
-
ones. Falsy cached results stay falsy; the `if (childNodes &&
|
|
1241
|
-
parentNode)` check already gates correctly. */
|
|
1242
|
-
if (KEEP_CONTENT && !FORBID_CONTENTS[tagName]) {
|
|
1243
|
-
const parentNode = getParentNode(currentNode);
|
|
1244
|
-
const childNodes = getChildNodes(currentNode);
|
|
1245
|
-
if (childNodes && parentNode) {
|
|
1246
|
-
const childCount = childNodes.length;
|
|
1247
|
-
for (let i = childCount - 1; i >= 0; --i) {
|
|
1248
|
-
const childClone = cloneNode(childNodes[i], true);
|
|
1249
|
-
parentNode.insertBefore(childClone, getNextSibling(currentNode));
|
|
1250
|
-
}
|
|
1251
|
-
}
|
|
1252
|
-
}
|
|
1253
|
-
_forceRemove(currentNode);
|
|
1254
|
-
return true;
|
|
1586
|
+
return _sanitizeDisallowedNode(currentNode, tagName);
|
|
1255
1587
|
}
|
|
1256
1588
|
/* Check whether element has a valid namespace.
|
|
1257
1589
|
Realm-safe check (GHSA-hpcv-96wg-7vj8): use the cached Node.prototype
|
|
@@ -1265,17 +1597,14 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
1265
1597
|
return true;
|
|
1266
1598
|
}
|
|
1267
1599
|
/* Make sure that older browsers don't get fallback-tag mXSS */
|
|
1268
|
-
if ((tagName === 'noscript' || tagName === 'noembed' || tagName === 'noframes') && regExpTest(
|
|
1600
|
+
if ((tagName === 'noscript' || tagName === 'noembed' || tagName === 'noframes') && regExpTest(FALLBACK_TAG_CLOSE, currentNode.innerHTML)) {
|
|
1269
1601
|
_forceRemove(currentNode);
|
|
1270
1602
|
return true;
|
|
1271
1603
|
}
|
|
1272
1604
|
/* Sanitize element content to be template-safe */
|
|
1273
1605
|
if (SAFE_FOR_TEMPLATES && currentNode.nodeType === NODE_TYPE.text) {
|
|
1274
1606
|
/* Get the element's text content */
|
|
1275
|
-
content = currentNode.textContent;
|
|
1276
|
-
arrayForEach([MUSTACHE_EXPR$1, ERB_EXPR$1, TMPLIT_EXPR$1], expr => {
|
|
1277
|
-
content = stringReplace(content, expr, ' ');
|
|
1278
|
-
});
|
|
1607
|
+
const content = _stripTemplateExpressions(currentNode.textContent);
|
|
1279
1608
|
if (currentNode.textContent !== content) {
|
|
1280
1609
|
arrayPush(DOMPurify.removed, {
|
|
1281
1610
|
element: currentNode.cloneNode()
|
|
@@ -1310,7 +1639,7 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
1310
1639
|
(https://html.spec.whatwg.org/multipage/dom.html#embedding-custom-non-visible-data-with-the-data-*-attributes)
|
|
1311
1640
|
XML-compatible (https://html.spec.whatwg.org/multipage/infrastructure.html#xml-compatible and http://www.w3.org/TR/xml/#d0e804)
|
|
1312
1641
|
We don't need to check the value; it's always URI safe. */
|
|
1313
|
-
if (ALLOW_DATA_ATTR &&
|
|
1642
|
+
if (ALLOW_DATA_ATTR && regExpTest(DATA_ATTR$1, lcName)) ; else if (ALLOW_ARIA_ATTR && regExpTest(ARIA_ATTR$1, lcName)) ; else if (!nameIsPermitted) {
|
|
1314
1643
|
if (
|
|
1315
1644
|
// First condition does a very basic check if a) it's basically a valid custom element tagname AND
|
|
1316
1645
|
// b) if the tagName passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
|
|
@@ -1342,6 +1671,63 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
1342
1671
|
const _isBasicCustomElement = function _isBasicCustomElement(tagName) {
|
|
1343
1672
|
return !RESERVED_CUSTOM_ELEMENT_NAMES[stringToLowerCase(tagName)] && regExpTest(CUSTOM_ELEMENT$1, tagName);
|
|
1344
1673
|
};
|
|
1674
|
+
/**
|
|
1675
|
+
* Wrap an attribute value in the matching Trusted Types object when
|
|
1676
|
+
* the active policy requires it. Namespaced attributes pass through
|
|
1677
|
+
* unchanged (no TT support yet, see
|
|
1678
|
+
* https://bugs.chromium.org/p/chromium/issues/detail?id=1305293).
|
|
1679
|
+
*
|
|
1680
|
+
* @param lcTag lowercase tag name of the containing element
|
|
1681
|
+
* @param lcName lowercase attribute name
|
|
1682
|
+
* @param namespaceURI the attribute's namespace, if any
|
|
1683
|
+
* @param value the attribute value to wrap
|
|
1684
|
+
* @return the value, wrapped when Trusted Types demand it
|
|
1685
|
+
*/
|
|
1686
|
+
const _applyTrustedTypesToAttribute = function _applyTrustedTypesToAttribute(lcTag, lcName, namespaceURI, value) {
|
|
1687
|
+
if (trustedTypesPolicy && typeof trustedTypes === 'object' && typeof trustedTypes.getAttributeType === 'function' && !namespaceURI) {
|
|
1688
|
+
switch (trustedTypes.getAttributeType(lcTag, lcName)) {
|
|
1689
|
+
case 'TrustedHTML':
|
|
1690
|
+
{
|
|
1691
|
+
return _createTrustedHTML(value);
|
|
1692
|
+
}
|
|
1693
|
+
case 'TrustedScriptURL':
|
|
1694
|
+
{
|
|
1695
|
+
return _createTrustedScriptURL(value);
|
|
1696
|
+
}
|
|
1697
|
+
}
|
|
1698
|
+
}
|
|
1699
|
+
return value;
|
|
1700
|
+
};
|
|
1701
|
+
/**
|
|
1702
|
+
* Write a modified attribute value back onto the element. On
|
|
1703
|
+
* success, re-probe for clobbering introduced by the new value and
|
|
1704
|
+
* remove the element when found; otherwise pop the removal entry
|
|
1705
|
+
* recorded by the earlier _removeAttribute (long-standing pairing
|
|
1706
|
+
* with the SANITIZE_NAMED_PROPS path - do not "fix" casually). On
|
|
1707
|
+
* failure, remove the attribute instead.
|
|
1708
|
+
*
|
|
1709
|
+
* @param currentNode the element carrying the attribute
|
|
1710
|
+
* @param name the attribute name as present on the element
|
|
1711
|
+
* @param namespaceURI the attribute's namespace, if any
|
|
1712
|
+
* @param value the new attribute value
|
|
1713
|
+
*/
|
|
1714
|
+
const _setAttributeValue = function _setAttributeValue(currentNode, name, namespaceURI, value) {
|
|
1715
|
+
try {
|
|
1716
|
+
if (namespaceURI) {
|
|
1717
|
+
currentNode.setAttributeNS(namespaceURI, name, value);
|
|
1718
|
+
} else {
|
|
1719
|
+
/* Fallback to setAttribute() for browser-unrecognized namespaces e.g. "x-schema". */
|
|
1720
|
+
currentNode.setAttribute(name, value);
|
|
1721
|
+
}
|
|
1722
|
+
if (_isClobbered(currentNode)) {
|
|
1723
|
+
_forceRemove(currentNode);
|
|
1724
|
+
} else {
|
|
1725
|
+
arrayPop(DOMPurify.removed);
|
|
1726
|
+
}
|
|
1727
|
+
} catch (_) {
|
|
1728
|
+
_removeAttribute(name, currentNode);
|
|
1729
|
+
}
|
|
1730
|
+
};
|
|
1345
1731
|
/**
|
|
1346
1732
|
* _sanitizeAttributes
|
|
1347
1733
|
*
|
|
@@ -1368,6 +1754,7 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
1368
1754
|
forceKeepAttr: undefined
|
|
1369
1755
|
};
|
|
1370
1756
|
let l = attributes.length;
|
|
1757
|
+
const lcTag = transformCaseFunc(currentNode.nodeName);
|
|
1371
1758
|
/* Go backwards over all attributes; safely remove bad ones */
|
|
1372
1759
|
while (l--) {
|
|
1373
1760
|
const attr = attributes[l];
|
|
@@ -1405,7 +1792,7 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
1405
1792
|
_removeAttribute(name, currentNode);
|
|
1406
1793
|
continue;
|
|
1407
1794
|
}
|
|
1408
|
-
/* Did the hooks
|
|
1795
|
+
/* Did the hooks force-keep the attribute? */
|
|
1409
1796
|
if (hookEvent.forceKeepAttr) {
|
|
1410
1797
|
continue;
|
|
1411
1798
|
}
|
|
@@ -1415,56 +1802,24 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
1415
1802
|
continue;
|
|
1416
1803
|
}
|
|
1417
1804
|
/* Work around a security issue in jQuery 3.0 */
|
|
1418
|
-
if (!ALLOW_SELF_CLOSE_IN_ATTR && regExpTest(
|
|
1805
|
+
if (!ALLOW_SELF_CLOSE_IN_ATTR && regExpTest(SELF_CLOSING_TAG, value)) {
|
|
1419
1806
|
_removeAttribute(name, currentNode);
|
|
1420
1807
|
continue;
|
|
1421
1808
|
}
|
|
1422
1809
|
/* Sanitize attribute content to be template-safe */
|
|
1423
1810
|
if (SAFE_FOR_TEMPLATES) {
|
|
1424
|
-
|
|
1425
|
-
value = stringReplace(value, expr, ' ');
|
|
1426
|
-
});
|
|
1811
|
+
value = _stripTemplateExpressions(value);
|
|
1427
1812
|
}
|
|
1428
1813
|
/* Is `value` valid for this attribute? */
|
|
1429
|
-
const lcTag = transformCaseFunc(currentNode.nodeName);
|
|
1430
1814
|
if (!_isValidAttribute(lcTag, lcName, value)) {
|
|
1431
1815
|
_removeAttribute(name, currentNode);
|
|
1432
1816
|
continue;
|
|
1433
1817
|
}
|
|
1434
1818
|
/* Handle attributes that require Trusted Types */
|
|
1435
|
-
|
|
1436
|
-
if (namespaceURI) ; else {
|
|
1437
|
-
switch (trustedTypes.getAttributeType(lcTag, lcName)) {
|
|
1438
|
-
case 'TrustedHTML':
|
|
1439
|
-
{
|
|
1440
|
-
value = _createTrustedHTML(value);
|
|
1441
|
-
break;
|
|
1442
|
-
}
|
|
1443
|
-
case 'TrustedScriptURL':
|
|
1444
|
-
{
|
|
1445
|
-
value = trustedTypesPolicy.createScriptURL(value);
|
|
1446
|
-
break;
|
|
1447
|
-
}
|
|
1448
|
-
}
|
|
1449
|
-
}
|
|
1450
|
-
}
|
|
1819
|
+
value = _applyTrustedTypesToAttribute(lcTag, lcName, namespaceURI, value);
|
|
1451
1820
|
/* Handle invalid data-* attribute set by try-catching it */
|
|
1452
1821
|
if (value !== initValue) {
|
|
1453
|
-
|
|
1454
|
-
if (namespaceURI) {
|
|
1455
|
-
currentNode.setAttributeNS(namespaceURI, name, value);
|
|
1456
|
-
} else {
|
|
1457
|
-
/* Fallback to setAttribute() for browser-unrecognized namespaces e.g. "x-schema". */
|
|
1458
|
-
currentNode.setAttribute(name, value);
|
|
1459
|
-
}
|
|
1460
|
-
if (_isClobbered(currentNode)) {
|
|
1461
|
-
_forceRemove(currentNode);
|
|
1462
|
-
} else {
|
|
1463
|
-
arrayPop(DOMPurify.removed);
|
|
1464
|
-
}
|
|
1465
|
-
} catch (_) {
|
|
1466
|
-
_removeAttribute(name, currentNode);
|
|
1467
|
-
}
|
|
1822
|
+
_setAttributeValue(currentNode, name, namespaceURI, value);
|
|
1468
1823
|
}
|
|
1469
1824
|
}
|
|
1470
1825
|
/* Execute a hook if present */
|
|
@@ -1506,9 +1861,9 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
1506
1861
|
iterator also surfaces. */
|
|
1507
1862
|
const shadowNodeType = getNodeType ? getNodeType(shadowNode) : shadowNode.nodeType;
|
|
1508
1863
|
if (shadowNodeType === NODE_TYPE.element) {
|
|
1509
|
-
const innerSr = getShadowRoot
|
|
1864
|
+
const innerSr = getShadowRoot(shadowNode);
|
|
1510
1865
|
if (_isDocumentFragment(innerSr)) {
|
|
1511
|
-
|
|
1866
|
+
_sanitizeAttachedShadowRoots(innerSr);
|
|
1512
1867
|
_sanitizeShadowDOM2(innerSr);
|
|
1513
1868
|
}
|
|
1514
1869
|
}
|
|
@@ -1535,46 +1890,81 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
1535
1890
|
*
|
|
1536
1891
|
* @param root the subtree root to walk for attached shadow roots
|
|
1537
1892
|
*/
|
|
1538
|
-
const
|
|
1539
|
-
|
|
1540
|
-
|
|
1541
|
-
|
|
1542
|
-
|
|
1543
|
-
|
|
1544
|
-
|
|
1545
|
-
|
|
1546
|
-
|
|
1547
|
-
|
|
1548
|
-
|
|
1549
|
-
|
|
1550
|
-
|
|
1551
|
-
|
|
1552
|
-
|
|
1553
|
-
|
|
1554
|
-
|
|
1555
|
-
|
|
1556
|
-
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
|
|
1561
|
-
|
|
1562
|
-
|
|
1563
|
-
|
|
1564
|
-
|
|
1565
|
-
|
|
1566
|
-
|
|
1567
|
-
|
|
1568
|
-
|
|
1569
|
-
|
|
1570
|
-
|
|
1571
|
-
|
|
1572
|
-
|
|
1573
|
-
|
|
1574
|
-
|
|
1575
|
-
|
|
1576
|
-
|
|
1577
|
-
|
|
1893
|
+
const _sanitizeAttachedShadowRoots = function _sanitizeAttachedShadowRoots(root) {
|
|
1894
|
+
/* Iterative (explicit stack) rather than per-child recursion. DOM APIs
|
|
1895
|
+
impose no depth cap, so an attacker-shaped tree (JSON/CRDT/editor data
|
|
1896
|
+
built straight into the DOM — the IN_PLACE surface) deeper than the JS
|
|
1897
|
+
call-stack budget would otherwise overflow native recursion here and
|
|
1898
|
+
throw at the IN_PLACE entry pre-pass, before a single node is
|
|
1899
|
+
sanitized, leaving the caller's live tree untouched (fail-open). See
|
|
1900
|
+
campaign-3 F4. A heap stack keeps depth off the call stack.
|
|
1901
|
+
Each work item is either a node to descend into, or a deferred
|
|
1902
|
+
`_sanitizeShadowDOM` for an already-walked shadow root. The deferred
|
|
1903
|
+
form preserves the original post-order discipline: a shadow root's
|
|
1904
|
+
nested shadow roots are discovered before the outer shadow is
|
|
1905
|
+
sanitized (which may remove hosts). Pushes are in reverse of the
|
|
1906
|
+
desired processing order (LIFO): template content, then children, then
|
|
1907
|
+
the shadow-sanitize, then the shadow walk — so the order matches the
|
|
1908
|
+
previous recursion exactly. */
|
|
1909
|
+
const stack = [{
|
|
1910
|
+
node: root,
|
|
1911
|
+
shadow: null
|
|
1912
|
+
}];
|
|
1913
|
+
while (stack.length > 0) {
|
|
1914
|
+
const item = stack.pop();
|
|
1915
|
+
/* Deferred shadow-DOM sanitisation: runs after its subtree was walked. */
|
|
1916
|
+
if (item.shadow) {
|
|
1917
|
+
_sanitizeShadowDOM2(item.shadow);
|
|
1918
|
+
continue;
|
|
1919
|
+
}
|
|
1920
|
+
const node = item.node;
|
|
1921
|
+
const nodeType = getNodeType ? getNodeType(node) : node.nodeType;
|
|
1922
|
+
const isElement = nodeType === NODE_TYPE.element;
|
|
1923
|
+
/* (pushed last → processed first) Children, snapshotted in reverse so
|
|
1924
|
+
the first child is processed first. Snapshotting matters because a
|
|
1925
|
+
hook may detach siblings mid-walk. */
|
|
1926
|
+
const childNodes = getChildNodes(node);
|
|
1927
|
+
if (childNodes) {
|
|
1928
|
+
for (let i = childNodes.length - 1; i >= 0; --i) {
|
|
1929
|
+
stack.push({
|
|
1930
|
+
node: childNodes[i],
|
|
1931
|
+
shadow: null
|
|
1932
|
+
});
|
|
1933
|
+
}
|
|
1934
|
+
}
|
|
1935
|
+
/* (pushed before children → processed after them, matching the old
|
|
1936
|
+
"template content last" order) When the node is a <template>,
|
|
1937
|
+
descend into its content. */
|
|
1938
|
+
if (isElement) {
|
|
1939
|
+
const rootName = getNodeName ? getNodeName(node) : null;
|
|
1940
|
+
if (typeof rootName === 'string' && transformCaseFunc(rootName) === 'template') {
|
|
1941
|
+
const content = node.content;
|
|
1942
|
+
if (_isDocumentFragment(content)) {
|
|
1943
|
+
stack.push({
|
|
1944
|
+
node: content,
|
|
1945
|
+
shadow: null
|
|
1946
|
+
});
|
|
1947
|
+
}
|
|
1948
|
+
}
|
|
1949
|
+
}
|
|
1950
|
+
/* Shadow root (processed first): walk its subtree, then sanitise it.
|
|
1951
|
+
Realm-safe check (GHSA-hpcv-96wg-7vj8): nodeType-based detection
|
|
1952
|
+
rather than `instanceof DocumentFragment`, which is realm-bound and
|
|
1953
|
+
silently skipped foreign-realm shadow roots (e.g.
|
|
1954
|
+
iframe.contentDocument attachShadow). */
|
|
1955
|
+
if (isElement) {
|
|
1956
|
+
const sr = getShadowRoot(node);
|
|
1957
|
+
if (_isDocumentFragment(sr)) {
|
|
1958
|
+
/* Push the deferred sanitise first so it pops after the shadow
|
|
1959
|
+
walk we push next, i.e. nested shadow roots are discovered
|
|
1960
|
+
before this one is sanitised. */
|
|
1961
|
+
stack.push({
|
|
1962
|
+
node: null,
|
|
1963
|
+
shadow: sr
|
|
1964
|
+
}, {
|
|
1965
|
+
node: sr,
|
|
1966
|
+
shadow: null
|
|
1967
|
+
});
|
|
1578
1968
|
}
|
|
1579
1969
|
}
|
|
1580
1970
|
}
|
|
@@ -1610,11 +2000,14 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
1610
2000
|
}
|
|
1611
2001
|
/* Clean up removed elements */
|
|
1612
2002
|
DOMPurify.removed = [];
|
|
1613
|
-
/*
|
|
1614
|
-
|
|
1615
|
-
|
|
1616
|
-
|
|
1617
|
-
|
|
2003
|
+
/* Resolve IN_PLACE for this call without mutating persistent config.
|
|
2004
|
+
Writing the IN_PLACE closure variable here leaks under setConfig(),
|
|
2005
|
+
where _parseConfig is skipped on later calls: a single string call would
|
|
2006
|
+
disable in-place mode for every subsequent node call, returning a
|
|
2007
|
+
sanitized copy while leaving the caller's node — which in-place callers
|
|
2008
|
+
keep using and whose return value they ignore — unsanitized. REPORT-2. */
|
|
2009
|
+
const inPlace = IN_PLACE && typeof dirty !== 'string' && _isNode(dirty);
|
|
2010
|
+
if (inPlace) {
|
|
1618
2011
|
/* Do some early pre-sanitization to avoid unsafe root nodes.
|
|
1619
2012
|
Read nodeName through the cached prototype getter — a clobbering
|
|
1620
2013
|
child named "nodeName" on the form root would otherwise shadow
|
|
@@ -1641,8 +2034,16 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
1641
2034
|
throw typeErrorCreate('root node is clobbered and cannot be sanitized in-place');
|
|
1642
2035
|
}
|
|
1643
2036
|
/* Sanitize attached shadow roots before the main iterator runs.
|
|
1644
|
-
The iterator does not descend into shadow trees.
|
|
1645
|
-
|
|
2037
|
+
The iterator does not descend into shadow trees. Same fail-closed
|
|
2038
|
+
barrier as the main walk (campaign-3 F2): a custom-element reaction
|
|
2039
|
+
inside a shadow root could abort this pre-pass before the walk runs,
|
|
2040
|
+
which would otherwise leave the entire live tree unsanitized. */
|
|
2041
|
+
try {
|
|
2042
|
+
_sanitizeAttachedShadowRoots(dirty);
|
|
2043
|
+
} catch (error) {
|
|
2044
|
+
_neutralizeRoot(dirty);
|
|
2045
|
+
throw error;
|
|
2046
|
+
}
|
|
1646
2047
|
} else if (_isNode(dirty)) {
|
|
1647
2048
|
/* If dirty is a DOM element, append to an empty document to avoid
|
|
1648
2049
|
elements being stripped by the parser */
|
|
@@ -1662,7 +2063,7 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
1662
2063
|
descend into shadow trees. The walk routes every read through a
|
|
1663
2064
|
cached prototype getter so clobbering descendants on a form root
|
|
1664
2065
|
cannot hide a shadow host from this pass. */
|
|
1665
|
-
|
|
2066
|
+
_sanitizeAttachedShadowRoots(importedNode);
|
|
1666
2067
|
} else {
|
|
1667
2068
|
/* Exit directly if we have nothing to do */
|
|
1668
2069
|
if (!RETURN_DOM && !SAFE_FOR_TEMPLATES && !WHOLE_DOCUMENT &&
|
|
@@ -1682,23 +2083,50 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
1682
2083
|
_forceRemove(body.firstChild);
|
|
1683
2084
|
}
|
|
1684
2085
|
/* Get node iterator */
|
|
1685
|
-
const nodeIterator = _createNodeIterator(
|
|
1686
|
-
/* Now start iterating over the created document
|
|
1687
|
-
|
|
1688
|
-
|
|
1689
|
-
|
|
1690
|
-
|
|
1691
|
-
|
|
1692
|
-
|
|
1693
|
-
|
|
1694
|
-
|
|
1695
|
-
|
|
1696
|
-
|
|
1697
|
-
|
|
2086
|
+
const nodeIterator = _createNodeIterator(inPlace ? dirty : body);
|
|
2087
|
+
/* Now start iterating over the created document.
|
|
2088
|
+
The walk runs inside an exception barrier (campaign-3 F2): a re-entrant
|
|
2089
|
+
engine/custom-element mutation can detach a node mid-walk so
|
|
2090
|
+
`_forceRemove`'s parentless guard throws, aborting the loop. Without the
|
|
2091
|
+
barrier the caller's in-place tree would be left half-sanitized with the
|
|
2092
|
+
unvisited tail still armed. On any throw we fail closed — strip the
|
|
2093
|
+
in-place root bare — then rethrow so the existing throw contract is
|
|
2094
|
+
preserved. (String/DOM-copy paths never return the partial body, so the
|
|
2095
|
+
propagating throw is already fail-closed there.) */
|
|
2096
|
+
try {
|
|
2097
|
+
while (currentNode = nodeIterator.nextNode()) {
|
|
2098
|
+
/* Sanitize tags and elements */
|
|
2099
|
+
_sanitizeElements(currentNode);
|
|
2100
|
+
/* Check attributes next */
|
|
2101
|
+
_sanitizeAttributes(currentNode);
|
|
2102
|
+
/* Shadow DOM detected, sanitize it.
|
|
2103
|
+
Realm-safe check (GHSA-hpcv-96wg-7vj8): nodeType-based detection
|
|
2104
|
+
instead of instanceof, so foreign-realm <template>.content is
|
|
2105
|
+
walked correctly. */
|
|
2106
|
+
if (_isDocumentFragment(currentNode.content)) {
|
|
2107
|
+
_sanitizeShadowDOM2(currentNode.content);
|
|
2108
|
+
}
|
|
2109
|
+
}
|
|
2110
|
+
} catch (error) {
|
|
2111
|
+
if (inPlace) {
|
|
2112
|
+
_neutralizeRoot(dirty);
|
|
1698
2113
|
}
|
|
2114
|
+
throw error;
|
|
1699
2115
|
}
|
|
1700
2116
|
/* If we sanitized `dirty` in-place, return it. */
|
|
1701
|
-
if (
|
|
2117
|
+
if (inPlace) {
|
|
2118
|
+
/* Fail-closed completion of the audit-5 F1 fix: every node removed from
|
|
2119
|
+
the caller's live tree is detached but may still hold a queued
|
|
2120
|
+
resource-event handler that fires in page scope after we return. The
|
|
2121
|
+
move-hoist covers only disallowed-tag KEEP_CONTENT removals; strip the
|
|
2122
|
+
non-allow-listed attributes off every other removed subtree (clobber,
|
|
2123
|
+
mXSS, namespace, comments, KEEP_CONTENT:false, …) so those handlers are
|
|
2124
|
+
cancelled before any event can fire. Runs synchronously, pre-return. */
|
|
2125
|
+
arrayForEach(DOMPurify.removed, entry => {
|
|
2126
|
+
if (entry.element) {
|
|
2127
|
+
_neutralizeSubtree(entry.element);
|
|
2128
|
+
}
|
|
2129
|
+
});
|
|
1702
2130
|
if (SAFE_FOR_TEMPLATES) {
|
|
1703
2131
|
_scrubTemplateExpressions2(dirty);
|
|
1704
2132
|
}
|
|
@@ -1737,9 +2165,7 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
1737
2165
|
}
|
|
1738
2166
|
/* Sanitize final string template-safe */
|
|
1739
2167
|
if (SAFE_FOR_TEMPLATES) {
|
|
1740
|
-
|
|
1741
|
-
serializedHTML = stringReplace(serializedHTML, expr, ' ');
|
|
1742
|
-
});
|
|
2168
|
+
serializedHTML = _stripTemplateExpressions(serializedHTML);
|
|
1743
2169
|
}
|
|
1744
2170
|
return trustedTypesPolicy && RETURN_TRUSTED_TYPE ? _createTrustedHTML(serializedHTML) : serializedHTML;
|
|
1745
2171
|
};
|
|
@@ -1751,6 +2177,12 @@ var purify = createCommonjsModule(function (module, exports) {
|
|
|
1751
2177
|
DOMPurify.clearConfig = function () {
|
|
1752
2178
|
CONFIG = null;
|
|
1753
2179
|
SET_CONFIG = false;
|
|
2180
|
+
// Drop any caller-supplied Trusted Types policy so it cannot poison later
|
|
2181
|
+
// `RETURN_TRUSTED_TYPE` output. The internal default policy (cached, and
|
|
2182
|
+
// never recreated — Trusted Types throws on duplicate names) is restored by
|
|
2183
|
+
// the next `_parseConfig`. See GHSA-vxr8-fq34-vvx9.
|
|
2184
|
+
trustedTypesPolicy = defaultTrustedTypesPolicy;
|
|
2185
|
+
emptyHTML = '';
|
|
1754
2186
|
};
|
|
1755
2187
|
DOMPurify.isValidAttribute = function (tag, attr, value) {
|
|
1756
2188
|
/* Initialize shared config vars if necessary. */
|