@angular/material 15.0.0-next.4 → 15.0.0-rc.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/_index.scss +24 -20
- package/badge/_badge-legacy-index.scss +1 -1
- package/badge/_badge-theme.import.scss +1 -1
- package/badge/_badge-theme.scss +2 -2
- package/bottom-sheet/_bottom-sheet-legacy-index.scss +1 -1
- package/bottom-sheet/_bottom-sheet-theme.import.scss +1 -1
- package/bottom-sheet/_bottom-sheet-theme.scss +2 -2
- package/button/testing/index.d.ts +8 -0
- package/chips/index.d.ts +42 -12
- package/core/mdc-helpers/_mdc-helpers.scss +8 -6
- package/core/typography/_all-typography.scss +73 -81
- package/datepicker/_datepicker-legacy-index.scss +1 -1
- package/datepicker/_datepicker-theme.import.scss +1 -1
- package/datepicker/_datepicker-theme.scss +4 -2
- package/datepicker/index.d.ts +14 -2
- package/divider/_divider-legacy-index.scss +1 -1
- package/divider/_divider-theme.import.scss +1 -1
- package/divider/_divider-theme.scss +2 -2
- package/esm2020/autocomplete/autocomplete-origin.mjs +7 -7
- package/esm2020/autocomplete/autocomplete-trigger.mjs +7 -7
- package/esm2020/autocomplete/autocomplete.mjs +7 -7
- package/esm2020/autocomplete/module.mjs +5 -5
- package/esm2020/badge/badge-module.mjs +5 -5
- package/esm2020/badge/badge.mjs +4 -4
- package/esm2020/bottom-sheet/bottom-sheet-container.mjs +4 -4
- package/esm2020/bottom-sheet/bottom-sheet-module.mjs +5 -5
- package/esm2020/bottom-sheet/bottom-sheet.mjs +4 -4
- package/esm2020/button/button-base.mjs +7 -7
- package/esm2020/button/button.mjs +7 -7
- package/esm2020/button/fab.mjs +13 -13
- package/esm2020/button/icon-button.mjs +7 -7
- package/esm2020/button/module.mjs +5 -5
- package/esm2020/button/testing/button-harness-filters.mjs +1 -1
- package/esm2020/button/testing/button-harness.mjs +28 -2
- package/esm2020/button-toggle/button-toggle-module.mjs +5 -5
- package/esm2020/button-toggle/button-toggle.mjs +7 -7
- package/esm2020/card/card.mjs +43 -43
- package/esm2020/card/module.mjs +5 -5
- package/esm2020/checkbox/checkbox-required-validator.mjs +4 -4
- package/esm2020/checkbox/checkbox.mjs +8 -8
- package/esm2020/checkbox/module.mjs +9 -9
- package/esm2020/chips/chip-action.mjs +28 -6
- package/esm2020/chips/chip-edit-input.mjs +4 -4
- package/esm2020/chips/chip-grid.mjs +4 -4
- package/esm2020/chips/chip-icons.mjs +12 -18
- package/esm2020/chips/chip-input.mjs +4 -4
- package/esm2020/chips/chip-listbox.mjs +20 -4
- package/esm2020/chips/chip-option.mjs +24 -14
- package/esm2020/chips/chip-row.mjs +5 -5
- package/esm2020/chips/chip-set.mjs +14 -6
- package/esm2020/chips/chip.mjs +4 -4
- package/esm2020/chips/module.mjs +5 -5
- package/esm2020/core/common-behaviors/common-module.mjs +5 -5
- package/esm2020/core/datetime/index.mjs +9 -9
- package/esm2020/core/datetime/native-date-adapter.mjs +4 -4
- package/esm2020/core/error/error-options.mjs +7 -7
- package/esm2020/core/line/line.mjs +8 -8
- package/esm2020/core/option/index.mjs +5 -5
- package/esm2020/core/option/optgroup.mjs +7 -7
- package/esm2020/core/option/option.mjs +7 -7
- package/esm2020/core/ripple/index.mjs +5 -5
- package/esm2020/core/ripple/ripple.mjs +4 -4
- package/esm2020/core/selection/pseudo-checkbox/pseudo-checkbox-module.mjs +5 -5
- package/esm2020/core/selection/pseudo-checkbox/pseudo-checkbox.mjs +4 -4
- package/esm2020/core/version.mjs +1 -1
- package/esm2020/datepicker/calendar-body.mjs +4 -4
- package/esm2020/datepicker/calendar.mjs +7 -7
- package/esm2020/datepicker/date-range-input-parts.mjs +11 -11
- package/esm2020/datepicker/date-range-input.mjs +4 -4
- package/esm2020/datepicker/date-range-picker.mjs +4 -4
- package/esm2020/datepicker/date-range-selection-strategy.mjs +4 -4
- package/esm2020/datepicker/date-selection-model.mjs +10 -10
- package/esm2020/datepicker/datepicker-actions.mjs +10 -10
- package/esm2020/datepicker/datepicker-base.mjs +23 -10
- package/esm2020/datepicker/datepicker-input-base.mjs +4 -4
- package/esm2020/datepicker/datepicker-input.mjs +4 -4
- package/esm2020/datepicker/datepicker-intl.mjs +14 -6
- package/esm2020/datepicker/datepicker-module.mjs +5 -5
- package/esm2020/datepicker/datepicker-toggle.mjs +8 -8
- package/esm2020/datepicker/datepicker.mjs +4 -4
- package/esm2020/datepicker/month-view.mjs +4 -4
- package/esm2020/datepicker/multi-year-view.mjs +4 -4
- package/esm2020/datepicker/year-view.mjs +4 -4
- package/esm2020/dialog/dialog-container.mjs +7 -7
- package/esm2020/dialog/dialog-content-directives.mjs +13 -13
- package/esm2020/dialog/dialog.mjs +7 -7
- package/esm2020/dialog/module.mjs +5 -5
- package/esm2020/divider/divider-module.mjs +5 -5
- package/esm2020/divider/divider.mjs +4 -4
- package/esm2020/expansion/accordion.mjs +4 -4
- package/esm2020/expansion/expansion-module.mjs +5 -5
- package/esm2020/expansion/expansion-panel-content.mjs +4 -4
- package/esm2020/expansion/expansion-panel-header.mjs +10 -10
- package/esm2020/expansion/expansion-panel.mjs +7 -7
- package/esm2020/form-field/directives/error.mjs +4 -4
- package/esm2020/form-field/directives/floating-label.mjs +4 -4
- package/esm2020/form-field/directives/hint.mjs +4 -4
- package/esm2020/form-field/directives/label.mjs +4 -4
- package/esm2020/form-field/directives/line-ripple.mjs +4 -4
- package/esm2020/form-field/directives/notched-outline.mjs +4 -4
- package/esm2020/form-field/directives/prefix.mjs +4 -4
- package/esm2020/form-field/directives/suffix.mjs +4 -4
- package/esm2020/form-field/form-field-control.mjs +4 -4
- package/esm2020/form-field/form-field.mjs +4 -4
- package/esm2020/form-field/module.mjs +5 -5
- package/esm2020/grid-list/grid-list-module.mjs +5 -5
- package/esm2020/grid-list/grid-list.mjs +4 -4
- package/esm2020/grid-list/grid-tile.mjs +16 -16
- package/esm2020/icon/icon-module.mjs +5 -5
- package/esm2020/icon/icon-registry.mjs +4 -4
- package/esm2020/icon/icon.mjs +5 -4
- package/esm2020/icon/testing/fake-icon-registry.mjs +8 -8
- package/esm2020/input/input.mjs +4 -4
- package/esm2020/input/module.mjs +5 -5
- package/esm2020/legacy-autocomplete/autocomplete-module.mjs +5 -5
- package/esm2020/legacy-autocomplete/autocomplete-origin.mjs +4 -4
- package/esm2020/legacy-autocomplete/autocomplete-trigger.mjs +4 -4
- package/esm2020/legacy-autocomplete/autocomplete.mjs +4 -4
- package/esm2020/legacy-button/button-module.mjs +5 -5
- package/esm2020/legacy-button/button.mjs +7 -7
- package/esm2020/legacy-button/testing/button-harness.mjs +27 -2
- package/esm2020/legacy-button/testing/public-api.mjs +1 -1
- package/esm2020/legacy-card/card-module.mjs +5 -5
- package/esm2020/legacy-card/card.mjs +43 -43
- package/esm2020/legacy-checkbox/checkbox-module.mjs +5 -5
- package/esm2020/legacy-checkbox/checkbox.mjs +4 -4
- package/esm2020/legacy-chips/chip-input.mjs +4 -4
- package/esm2020/legacy-chips/chip-list.mjs +4 -4
- package/esm2020/legacy-chips/chip.mjs +13 -13
- package/esm2020/legacy-chips/chips-module.mjs +5 -5
- package/esm2020/legacy-core/option/index.mjs +5 -5
- package/esm2020/legacy-core/option/optgroup.mjs +4 -4
- package/esm2020/legacy-core/option/option.mjs +4 -4
- package/esm2020/legacy-dialog/dialog-container.mjs +4 -4
- package/esm2020/legacy-dialog/dialog-content-directives.mjs +13 -13
- package/esm2020/legacy-dialog/dialog-module.mjs +5 -5
- package/esm2020/legacy-dialog/dialog.mjs +4 -4
- package/esm2020/legacy-form-field/error.mjs +4 -4
- package/esm2020/legacy-form-field/form-field-module.mjs +5 -5
- package/esm2020/legacy-form-field/form-field.mjs +4 -4
- package/esm2020/legacy-form-field/hint.mjs +4 -4
- package/esm2020/legacy-form-field/label.mjs +4 -4
- package/esm2020/legacy-form-field/placeholder.mjs +4 -4
- package/esm2020/legacy-form-field/prefix.mjs +4 -4
- package/esm2020/legacy-form-field/suffix.mjs +4 -4
- package/esm2020/legacy-input/input-module.mjs +5 -5
- package/esm2020/legacy-input/input.mjs +6 -6
- package/esm2020/legacy-list/list-module.mjs +5 -5
- package/esm2020/legacy-list/list.mjs +19 -19
- package/esm2020/legacy-list/selection-list.mjs +7 -7
- package/esm2020/legacy-menu/menu-content.mjs +4 -4
- package/esm2020/legacy-menu/menu-item.mjs +4 -4
- package/esm2020/legacy-menu/menu-module.mjs +5 -5
- package/esm2020/legacy-menu/menu-trigger.mjs +4 -4
- package/esm2020/legacy-menu/menu.mjs +4 -4
- package/esm2020/legacy-paginator/paginator-module.mjs +5 -5
- package/esm2020/legacy-paginator/paginator.mjs +4 -4
- package/esm2020/legacy-progress-bar/progress-bar-module.mjs +5 -5
- package/esm2020/legacy-progress-bar/progress-bar.mjs +4 -4
- package/esm2020/legacy-progress-spinner/progress-spinner-module.mjs +5 -5
- package/esm2020/legacy-progress-spinner/progress-spinner.mjs +4 -4
- package/esm2020/legacy-radio/radio-module.mjs +5 -5
- package/esm2020/legacy-radio/radio.mjs +7 -7
- package/esm2020/legacy-select/select-module.mjs +5 -5
- package/esm2020/legacy-select/select.mjs +7 -7
- package/esm2020/legacy-slide-toggle/slide-toggle-module.mjs +5 -5
- package/esm2020/legacy-slide-toggle/slide-toggle.mjs +4 -4
- package/esm2020/legacy-slider/slider-module.mjs +5 -5
- package/esm2020/legacy-slider/slider.mjs +4 -4
- package/esm2020/legacy-snack-bar/simple-snack-bar.mjs +4 -4
- package/esm2020/legacy-snack-bar/snack-bar-container.mjs +4 -4
- package/esm2020/legacy-snack-bar/snack-bar-module.mjs +5 -5
- package/esm2020/legacy-snack-bar/snack-bar.mjs +4 -4
- package/esm2020/legacy-table/cell.mjs +22 -22
- package/esm2020/legacy-table/row.mjs +22 -22
- package/esm2020/legacy-table/table-module.mjs +5 -5
- package/esm2020/legacy-table/table.mjs +7 -7
- package/esm2020/legacy-table/text-column.mjs +4 -4
- package/esm2020/legacy-tabs/ink-bar.mjs +4 -4
- package/esm2020/legacy-tabs/tab-body.mjs +7 -7
- package/esm2020/legacy-tabs/tab-content.mjs +4 -4
- package/esm2020/legacy-tabs/tab-group.mjs +4 -4
- package/esm2020/legacy-tabs/tab-header.mjs +4 -4
- package/esm2020/legacy-tabs/tab-label-wrapper.mjs +4 -4
- package/esm2020/legacy-tabs/tab-label.mjs +4 -4
- package/esm2020/legacy-tabs/tab-nav-bar/tab-nav-bar.mjs +10 -10
- package/esm2020/legacy-tabs/tab.mjs +4 -4
- package/esm2020/legacy-tabs/tabs-module.mjs +5 -5
- package/esm2020/legacy-tooltip/tooltip-module.mjs +5 -5
- package/esm2020/legacy-tooltip/tooltip.mjs +7 -7
- package/esm2020/list/action-list.mjs +4 -4
- package/esm2020/list/list-base.mjs +11 -8
- package/esm2020/list/list-item-sections.mjs +19 -19
- package/esm2020/list/list-module.mjs +5 -5
- package/esm2020/list/list-option.mjs +4 -4
- package/esm2020/list/list.mjs +7 -7
- package/esm2020/list/nav-list.mjs +4 -4
- package/esm2020/list/selection-list.mjs +36 -6
- package/esm2020/list/subheader.mjs +4 -4
- package/esm2020/menu/menu-content.mjs +7 -7
- package/esm2020/menu/menu-item.mjs +4 -4
- package/esm2020/menu/menu-trigger.mjs +7 -7
- package/esm2020/menu/menu.mjs +10 -8
- package/esm2020/menu/module.mjs +5 -5
- package/esm2020/paginator/module.mjs +5 -5
- package/esm2020/paginator/paginator-intl.mjs +4 -4
- package/esm2020/paginator/paginator.mjs +7 -7
- package/esm2020/paginator/testing/paginator-harness.mjs +2 -2
- package/esm2020/progress-bar/module.mjs +5 -5
- package/esm2020/progress-bar/progress-bar.mjs +4 -4
- package/esm2020/progress-spinner/module.mjs +5 -5
- package/esm2020/progress-spinner/progress-spinner.mjs +4 -4
- package/esm2020/radio/module.mjs +5 -5
- package/esm2020/radio/radio.mjs +18 -18
- package/esm2020/select/module.mjs +5 -5
- package/esm2020/select/select.mjs +11 -10
- package/esm2020/sidenav/drawer.mjs +10 -10
- package/esm2020/sidenav/sidenav-module.mjs +5 -5
- package/esm2020/sidenav/sidenav.mjs +10 -10
- package/esm2020/slide-toggle/module.mjs +9 -9
- package/esm2020/slide-toggle/slide-toggle-required-validator.mjs +4 -4
- package/esm2020/slide-toggle/slide-toggle.mjs +8 -8
- package/esm2020/slider/global-change-and-input-listener.mjs +4 -4
- package/esm2020/slider/module.mjs +5 -5
- package/esm2020/slider/slider.mjs +10 -10
- package/esm2020/snack-bar/module.mjs +5 -5
- package/esm2020/snack-bar/simple-snack-bar.mjs +4 -4
- package/esm2020/snack-bar/snack-bar-container.mjs +7 -7
- package/esm2020/snack-bar/snack-bar-content.mjs +10 -10
- package/esm2020/snack-bar/snack-bar.mjs +7 -7
- package/esm2020/sort/sort-header-intl.mjs +4 -4
- package/esm2020/sort/sort-header.mjs +4 -4
- package/esm2020/sort/sort-module.mjs +5 -5
- package/esm2020/sort/sort.mjs +4 -4
- package/esm2020/stepper/step-content.mjs +4 -4
- package/esm2020/stepper/step-header.mjs +4 -4
- package/esm2020/stepper/step-label.mjs +4 -4
- package/esm2020/stepper/stepper-button.mjs +7 -7
- package/esm2020/stepper/stepper-icon.mjs +4 -4
- package/esm2020/stepper/stepper-intl.mjs +4 -4
- package/esm2020/stepper/stepper-module.mjs +5 -5
- package/esm2020/stepper/stepper.mjs +7 -7
- package/esm2020/table/cell.mjs +22 -22
- package/esm2020/table/module.mjs +5 -5
- package/esm2020/table/row.mjs +22 -22
- package/esm2020/table/table.mjs +7 -7
- package/esm2020/table/text-column.mjs +4 -4
- package/esm2020/tabs/module.mjs +5 -5
- package/esm2020/tabs/paginated-tab-header.mjs +11 -12
- package/esm2020/tabs/tab-body.mjs +10 -10
- package/esm2020/tabs/tab-content.mjs +4 -4
- package/esm2020/tabs/tab-group.mjs +7 -7
- package/esm2020/tabs/tab-header.mjs +8 -8
- package/esm2020/tabs/tab-label-wrapper.mjs +7 -7
- package/esm2020/tabs/tab-label.mjs +4 -4
- package/esm2020/tabs/tab-nav-bar/tab-nav-bar.mjs +16 -16
- package/esm2020/tabs/tab.mjs +7 -7
- package/esm2020/toolbar/toolbar-module.mjs +5 -5
- package/esm2020/toolbar/toolbar.mjs +7 -7
- package/esm2020/tooltip/module.mjs +5 -5
- package/esm2020/tooltip/tooltip.mjs +13 -13
- package/esm2020/tree/node.mjs +10 -10
- package/esm2020/tree/outlet.mjs +4 -4
- package/esm2020/tree/padding.mjs +4 -4
- package/esm2020/tree/toggle.mjs +4 -4
- package/esm2020/tree/tree-module.mjs +5 -5
- package/esm2020/tree/tree.mjs +4 -4
- package/fesm2015/autocomplete.mjs +22 -22
- package/fesm2015/autocomplete.mjs.map +1 -1
- package/fesm2015/badge.mjs +7 -7
- package/fesm2015/badge.mjs.map +1 -1
- package/fesm2015/bottom-sheet.mjs +10 -10
- package/fesm2015/bottom-sheet.mjs.map +1 -1
- package/fesm2015/button/testing.mjs +29 -1
- package/fesm2015/button/testing.mjs.map +1 -1
- package/fesm2015/button-toggle.mjs +10 -10
- package/fesm2015/button-toggle.mjs.map +1 -1
- package/fesm2015/button.mjs +34 -34
- package/fesm2015/button.mjs.map +1 -1
- package/fesm2015/card.mjs +46 -46
- package/fesm2015/card.mjs.map +1 -1
- package/fesm2015/checkbox.mjs +18 -18
- package/fesm2015/checkbox.mjs.map +1 -1
- package/fesm2015/chips.mjs +113 -63
- package/fesm2015/chips.mjs.map +1 -1
- package/fesm2015/core.mjs +59 -59
- package/fesm2015/core.mjs.map +1 -1
- package/fesm2015/datepicker.mjs +112 -89
- package/fesm2015/datepicker.mjs.map +1 -1
- package/fesm2015/dialog.mjs +28 -28
- package/fesm2015/dialog.mjs.map +1 -1
- package/fesm2015/divider.mjs +7 -7
- package/fesm2015/divider.mjs.map +1 -1
- package/fesm2015/expansion.mjs +25 -25
- package/fesm2015/expansion.mjs.map +1 -1
- package/fesm2015/form-field.mjs +34 -34
- package/fesm2015/form-field.mjs.map +1 -1
- package/fesm2015/grid-list.mjs +22 -22
- package/fesm2015/grid-list.mjs.map +1 -1
- package/fesm2015/icon/testing.mjs +7 -7
- package/fesm2015/icon/testing.mjs.map +1 -1
- package/fesm2015/icon.mjs +11 -10
- package/fesm2015/icon.mjs.map +1 -1
- package/fesm2015/input.mjs +7 -7
- package/fesm2015/input.mjs.map +1 -1
- package/fesm2015/legacy-autocomplete.mjs +13 -13
- package/fesm2015/legacy-autocomplete.mjs.map +1 -1
- package/fesm2015/legacy-button/testing.mjs +28 -1
- package/fesm2015/legacy-button/testing.mjs.map +1 -1
- package/fesm2015/legacy-button.mjs +10 -10
- package/fesm2015/legacy-button.mjs.map +1 -1
- package/fesm2015/legacy-card.mjs +46 -46
- package/fesm2015/legacy-card.mjs.map +1 -1
- package/fesm2015/legacy-checkbox.mjs +7 -7
- package/fesm2015/legacy-checkbox.mjs.map +1 -1
- package/fesm2015/legacy-chips.mjs +22 -22
- package/fesm2015/legacy-chips.mjs.map +1 -1
- package/fesm2015/legacy-core.mjs +10 -10
- package/fesm2015/legacy-core.mjs.map +1 -1
- package/fesm2015/legacy-dialog.mjs +22 -22
- package/fesm2015/legacy-dialog.mjs.map +1 -1
- package/fesm2015/legacy-form-field.mjs +25 -25
- package/fesm2015/legacy-form-field.mjs.map +1 -1
- package/fesm2015/legacy-input.mjs +9 -9
- package/fesm2015/legacy-input.mjs.map +1 -1
- package/fesm2015/legacy-list.mjs +28 -28
- package/fesm2015/legacy-list.mjs.map +1 -1
- package/fesm2015/legacy-menu.mjs +16 -16
- package/fesm2015/legacy-menu.mjs.map +1 -1
- package/fesm2015/legacy-paginator.mjs +7 -7
- package/fesm2015/legacy-paginator.mjs.map +1 -1
- package/fesm2015/legacy-progress-bar.mjs +7 -7
- package/fesm2015/legacy-progress-bar.mjs.map +1 -1
- package/fesm2015/legacy-progress-spinner.mjs +7 -7
- package/fesm2015/legacy-progress-spinner.mjs.map +1 -1
- package/fesm2015/legacy-radio.mjs +10 -10
- package/fesm2015/legacy-radio.mjs.map +1 -1
- package/fesm2015/legacy-select.mjs +10 -10
- package/fesm2015/legacy-select.mjs.map +1 -1
- package/fesm2015/legacy-slide-toggle.mjs +7 -7
- package/fesm2015/legacy-slide-toggle.mjs.map +1 -1
- package/fesm2015/legacy-slider.mjs +7 -7
- package/fesm2015/legacy-slider.mjs.map +1 -1
- package/fesm2015/legacy-snack-bar.mjs +13 -13
- package/fesm2015/legacy-snack-bar.mjs.map +1 -1
- package/fesm2015/legacy-table.mjs +55 -55
- package/fesm2015/legacy-table.mjs.map +1 -1
- package/fesm2015/legacy-tabs.mjs +40 -40
- package/fesm2015/legacy-tabs.mjs.map +1 -1
- package/fesm2015/legacy-tooltip.mjs +10 -10
- package/fesm2015/legacy-tooltip.mjs.map +1 -1
- package/fesm2015/list.mjs +86 -52
- package/fesm2015/list.mjs.map +1 -1
- package/fesm2015/menu.mjs +30 -27
- package/fesm2015/menu.mjs.map +1 -1
- package/fesm2015/paginator/testing.mjs +1 -1
- package/fesm2015/paginator/testing.mjs.map +1 -1
- package/fesm2015/paginator.mjs +13 -13
- package/fesm2015/paginator.mjs.map +1 -1
- package/fesm2015/progress-bar.mjs +7 -7
- package/fesm2015/progress-bar.mjs.map +1 -1
- package/fesm2015/progress-spinner.mjs +7 -7
- package/fesm2015/progress-spinner.mjs.map +1 -1
- package/fesm2015/radio.mjs +21 -21
- package/fesm2015/radio.mjs.map +1 -1
- package/fesm2015/select.mjs +15 -13
- package/fesm2015/select.mjs.map +1 -1
- package/fesm2015/sidenav.mjs +22 -22
- package/fesm2015/sidenav.mjs.map +1 -1
- package/fesm2015/slide-toggle.mjs +18 -18
- package/fesm2015/slide-toggle.mjs.map +1 -1
- package/fesm2015/slider.mjs +16 -16
- package/fesm2015/slider.mjs.map +1 -1
- package/fesm2015/snack-bar.mjs +28 -28
- package/fesm2015/snack-bar.mjs.map +1 -1
- package/fesm2015/sort.mjs +13 -13
- package/fesm2015/sort.mjs.map +1 -1
- package/fesm2015/stepper.mjs +31 -31
- package/fesm2015/stepper.mjs.map +1 -1
- package/fesm2015/table.mjs +55 -55
- package/fesm2015/table.mjs.map +1 -1
- package/fesm2015/tabs.mjs +69 -70
- package/fesm2015/tabs.mjs.map +1 -1
- package/fesm2015/toolbar.mjs +10 -10
- package/fesm2015/toolbar.mjs.map +1 -1
- package/fesm2015/tooltip.mjs +16 -16
- package/fesm2015/tooltip.mjs.map +1 -1
- package/fesm2015/tree.mjs +25 -25
- package/fesm2015/tree.mjs.map +1 -1
- package/fesm2020/autocomplete.mjs +22 -22
- package/fesm2020/autocomplete.mjs.map +1 -1
- package/fesm2020/badge.mjs +7 -7
- package/fesm2020/badge.mjs.map +1 -1
- package/fesm2020/bottom-sheet.mjs +10 -10
- package/fesm2020/bottom-sheet.mjs.map +1 -1
- package/fesm2020/button/testing.mjs +27 -1
- package/fesm2020/button/testing.mjs.map +1 -1
- package/fesm2020/button-toggle.mjs +10 -10
- package/fesm2020/button-toggle.mjs.map +1 -1
- package/fesm2020/button.mjs +34 -34
- package/fesm2020/button.mjs.map +1 -1
- package/fesm2020/card.mjs +46 -46
- package/fesm2020/card.mjs.map +1 -1
- package/fesm2020/checkbox.mjs +18 -18
- package/fesm2020/checkbox.mjs.map +1 -1
- package/fesm2020/chips.mjs +113 -63
- package/fesm2020/chips.mjs.map +1 -1
- package/fesm2020/core.mjs +59 -59
- package/fesm2020/core.mjs.map +1 -1
- package/fesm2020/datepicker.mjs +110 -89
- package/fesm2020/datepicker.mjs.map +1 -1
- package/fesm2020/dialog.mjs +28 -28
- package/fesm2020/dialog.mjs.map +1 -1
- package/fesm2020/divider.mjs +7 -7
- package/fesm2020/divider.mjs.map +1 -1
- package/fesm2020/expansion.mjs +25 -25
- package/fesm2020/expansion.mjs.map +1 -1
- package/fesm2020/form-field.mjs +34 -34
- package/fesm2020/form-field.mjs.map +1 -1
- package/fesm2020/grid-list.mjs +22 -22
- package/fesm2020/grid-list.mjs.map +1 -1
- package/fesm2020/icon/testing.mjs +7 -7
- package/fesm2020/icon/testing.mjs.map +1 -1
- package/fesm2020/icon.mjs +11 -10
- package/fesm2020/icon.mjs.map +1 -1
- package/fesm2020/input.mjs +7 -7
- package/fesm2020/input.mjs.map +1 -1
- package/fesm2020/legacy-autocomplete.mjs +13 -13
- package/fesm2020/legacy-autocomplete.mjs.map +1 -1
- package/fesm2020/legacy-button/testing.mjs +26 -1
- package/fesm2020/legacy-button/testing.mjs.map +1 -1
- package/fesm2020/legacy-button.mjs +10 -10
- package/fesm2020/legacy-button.mjs.map +1 -1
- package/fesm2020/legacy-card.mjs +46 -46
- package/fesm2020/legacy-card.mjs.map +1 -1
- package/fesm2020/legacy-checkbox.mjs +7 -7
- package/fesm2020/legacy-checkbox.mjs.map +1 -1
- package/fesm2020/legacy-chips.mjs +22 -22
- package/fesm2020/legacy-chips.mjs.map +1 -1
- package/fesm2020/legacy-core.mjs +10 -10
- package/fesm2020/legacy-core.mjs.map +1 -1
- package/fesm2020/legacy-dialog.mjs +22 -22
- package/fesm2020/legacy-dialog.mjs.map +1 -1
- package/fesm2020/legacy-form-field.mjs +25 -25
- package/fesm2020/legacy-form-field.mjs.map +1 -1
- package/fesm2020/legacy-input.mjs +9 -9
- package/fesm2020/legacy-input.mjs.map +1 -1
- package/fesm2020/legacy-list.mjs +28 -28
- package/fesm2020/legacy-list.mjs.map +1 -1
- package/fesm2020/legacy-menu.mjs +16 -16
- package/fesm2020/legacy-menu.mjs.map +1 -1
- package/fesm2020/legacy-paginator.mjs +7 -7
- package/fesm2020/legacy-paginator.mjs.map +1 -1
- package/fesm2020/legacy-progress-bar.mjs +7 -7
- package/fesm2020/legacy-progress-bar.mjs.map +1 -1
- package/fesm2020/legacy-progress-spinner.mjs +7 -7
- package/fesm2020/legacy-progress-spinner.mjs.map +1 -1
- package/fesm2020/legacy-radio.mjs +10 -10
- package/fesm2020/legacy-radio.mjs.map +1 -1
- package/fesm2020/legacy-select.mjs +10 -10
- package/fesm2020/legacy-select.mjs.map +1 -1
- package/fesm2020/legacy-slide-toggle.mjs +7 -7
- package/fesm2020/legacy-slide-toggle.mjs.map +1 -1
- package/fesm2020/legacy-slider.mjs +7 -7
- package/fesm2020/legacy-slider.mjs.map +1 -1
- package/fesm2020/legacy-snack-bar.mjs +13 -13
- package/fesm2020/legacy-snack-bar.mjs.map +1 -1
- package/fesm2020/legacy-table.mjs +55 -55
- package/fesm2020/legacy-table.mjs.map +1 -1
- package/fesm2020/legacy-tabs.mjs +40 -40
- package/fesm2020/legacy-tabs.mjs.map +1 -1
- package/fesm2020/legacy-tooltip.mjs +10 -10
- package/fesm2020/legacy-tooltip.mjs.map +1 -1
- package/fesm2020/list.mjs +85 -52
- package/fesm2020/list.mjs.map +1 -1
- package/fesm2020/menu.mjs +28 -26
- package/fesm2020/menu.mjs.map +1 -1
- package/fesm2020/paginator/testing.mjs +1 -1
- package/fesm2020/paginator/testing.mjs.map +1 -1
- package/fesm2020/paginator.mjs +13 -13
- package/fesm2020/paginator.mjs.map +1 -1
- package/fesm2020/progress-bar.mjs +7 -7
- package/fesm2020/progress-bar.mjs.map +1 -1
- package/fesm2020/progress-spinner.mjs +7 -7
- package/fesm2020/progress-spinner.mjs.map +1 -1
- package/fesm2020/radio.mjs +21 -21
- package/fesm2020/radio.mjs.map +1 -1
- package/fesm2020/select.mjs +14 -13
- package/fesm2020/select.mjs.map +1 -1
- package/fesm2020/sidenav.mjs +22 -22
- package/fesm2020/sidenav.mjs.map +1 -1
- package/fesm2020/slide-toggle.mjs +18 -18
- package/fesm2020/slide-toggle.mjs.map +1 -1
- package/fesm2020/slider.mjs +16 -16
- package/fesm2020/slider.mjs.map +1 -1
- package/fesm2020/snack-bar.mjs +28 -28
- package/fesm2020/snack-bar.mjs.map +1 -1
- package/fesm2020/sort.mjs +13 -13
- package/fesm2020/sort.mjs.map +1 -1
- package/fesm2020/stepper.mjs +31 -31
- package/fesm2020/stepper.mjs.map +1 -1
- package/fesm2020/table.mjs +55 -55
- package/fesm2020/table.mjs.map +1 -1
- package/fesm2020/tabs.mjs +69 -70
- package/fesm2020/tabs.mjs.map +1 -1
- package/fesm2020/toolbar.mjs +10 -10
- package/fesm2020/toolbar.mjs.map +1 -1
- package/fesm2020/tooltip.mjs +16 -16
- package/fesm2020/tooltip.mjs.map +1 -1
- package/fesm2020/tree.mjs +25 -25
- package/fesm2020/tree.mjs.map +1 -1
- package/grid-list/_grid-list-legacy-index.scss +1 -1
- package/grid-list/_grid-list-theme.import.scss +1 -1
- package/grid-list/_grid-list-theme.scss +2 -2
- package/icon/_icon-legacy-index.scss +1 -1
- package/icon/_icon-theme.import.scss +1 -1
- package/icon/_icon-theme.scss +2 -2
- package/legacy-button/testing/index.d.ts +5 -0
- package/list/index.d.ts +25 -3
- package/menu/index.d.ts +1 -0
- package/package.json +2 -2
- package/paginator/testing/index.d.ts +1 -1
- package/prebuilt-themes/deeppurple-amber.css +1 -1
- package/prebuilt-themes/indigo-pink.css +1 -1
- package/prebuilt-themes/pink-bluegrey.css +1 -1
- package/prebuilt-themes/purple-green.css +1 -1
- package/schematics/migration.json +0 -45
- package/schematics/ng-add/index.js +1 -1
- package/schematics/ng-add/index.mjs +1 -1
- package/schematics/ng-add/theming/theming.js +2 -3
- package/schematics/ng-add/theming/theming.mjs +2 -3
- package/schematics/ng-generate/address-form/files/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.spec.ts.template +10 -10
- package/schematics/ng-generate/address-form/index.js +6 -6
- package/schematics/ng-generate/address-form/index.mjs +6 -6
- package/schematics/ng-generate/dashboard/files/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.spec.ts.template +5 -5
- package/schematics/ng-generate/dashboard/index.js +4 -4
- package/schematics/ng-generate/dashboard/index.mjs +4 -4
- package/schematics/ng-generate/mdc-migration/index_bundled.js +440 -378
- package/schematics/ng-generate/mdc-migration/index_bundled.js.map +3 -3
- package/schematics/ng-generate/mdc-migration/mdc_migration_bundle_metadata.json +1 -1
- package/schematics/ng-generate/mdc-migration/schema.json +1 -1
- package/schematics/ng-generate/navigation/files/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.spec.ts.template +4 -4
- package/schematics/ng-generate/navigation/index.js +3 -3
- package/schematics/ng-generate/navigation/index.mjs +3 -3
- package/schematics/ng-generate/table/files/__path__/__name@dasherize@if-flat__/__name@dasherize__-datasource.ts.template +1 -1
- package/schematics/ng-generate/table/files/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.spec.ts.template +2 -2
- package/schematics/ng-generate/table/files/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.ts.template +2 -2
- package/schematics/ng-generate/table/index.js +3 -3
- package/schematics/ng-generate/table/index.mjs +3 -3
- package/schematics/ng-generate/tree/files/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.spec.ts.template +2 -2
- package/schematics/ng-generate/tree/index.js +2 -2
- package/schematics/ng-generate/tree/index.mjs +2 -2
- package/schematics/ng-update/index_bundled.js +55 -3103
- package/schematics/ng-update/index_bundled.js.map +3 -3
- package/schematics/ng-update/ng_update_index_metadata.json +1 -1
- package/sidenav/_sidenav-legacy-index.scss +1 -1
- package/sidenav/_sidenav-theme.import.scss +1 -1
- package/sidenav/_sidenav-theme.scss +2 -2
- package/slide-toggle/_slide-toggle-theme.scss +19 -19
- package/sort/_sort-legacy-index.scss +1 -1
- package/sort/_sort-theme.import.scss +1 -1
- package/sort/_sort-theme.scss +2 -2
|
@@ -3374,6 +3374,7 @@ var require_map_generator = __commonJS({
|
|
|
3374
3374
|
this.root = root2;
|
|
3375
3375
|
this.opts = opts;
|
|
3376
3376
|
this.css = cssString;
|
|
3377
|
+
this.usesFileUrls = !this.mapOpts.from && this.mapOpts.absolute;
|
|
3377
3378
|
}
|
|
3378
3379
|
isMap() {
|
|
3379
3380
|
if (typeof this.opts.map !== "undefined") {
|
|
@@ -3448,7 +3449,8 @@ var require_map_generator = __commonJS({
|
|
|
3448
3449
|
let from = node.source.input.from;
|
|
3449
3450
|
if (from && !already[from]) {
|
|
3450
3451
|
already[from] = true;
|
|
3451
|
-
this.
|
|
3452
|
+
let fromUrl = this.usesFileUrls ? this.toFileUrl(from) : this.toUrl(this.path(from));
|
|
3453
|
+
this.map.setSourceContent(fromUrl, node.source.input.css);
|
|
3452
3454
|
}
|
|
3453
3455
|
}
|
|
3454
3456
|
});
|
|
@@ -3564,15 +3566,18 @@ var require_map_generator = __commonJS({
|
|
|
3564
3566
|
}
|
|
3565
3567
|
return encodeURI(path).replace(/[#?]/g, encodeURIComponent);
|
|
3566
3568
|
}
|
|
3569
|
+
toFileUrl(path) {
|
|
3570
|
+
if (pathToFileURL) {
|
|
3571
|
+
return pathToFileURL(path).toString();
|
|
3572
|
+
} else {
|
|
3573
|
+
throw new Error("`map.absolute` option is not available in this PostCSS build");
|
|
3574
|
+
}
|
|
3575
|
+
}
|
|
3567
3576
|
sourcePath(node) {
|
|
3568
3577
|
if (this.mapOpts.from) {
|
|
3569
3578
|
return this.toUrl(this.mapOpts.from);
|
|
3570
|
-
} else if (this.
|
|
3571
|
-
|
|
3572
|
-
return pathToFileURL(node.source.input.from).toString();
|
|
3573
|
-
} else {
|
|
3574
|
-
throw new Error("`map.absolute` option is not available in this PostCSS build");
|
|
3575
|
-
}
|
|
3579
|
+
} else if (this.usesFileUrls) {
|
|
3580
|
+
return this.toFileUrl(node.source.input.from);
|
|
3576
3581
|
} else {
|
|
3577
3582
|
return this.toUrl(this.path(node.source.input.from));
|
|
3578
3583
|
}
|
|
@@ -3680,6 +3685,7 @@ var require_container = __commonJS({
|
|
|
3680
3685
|
var parse4;
|
|
3681
3686
|
var Rule2;
|
|
3682
3687
|
var AtRule2;
|
|
3688
|
+
var Root2;
|
|
3683
3689
|
function cleanSource(nodes) {
|
|
3684
3690
|
return nodes.map((i) => {
|
|
3685
3691
|
if (i.nodes)
|
|
@@ -3834,15 +3840,16 @@ var require_container = __commonJS({
|
|
|
3834
3840
|
}
|
|
3835
3841
|
}
|
|
3836
3842
|
insertBefore(exist, add) {
|
|
3837
|
-
|
|
3843
|
+
let existIndex = this.index(exist);
|
|
3838
3844
|
let type = exist === 0 ? "prepend" : false;
|
|
3839
|
-
let nodes = this.normalize(add, this.proxyOf.nodes[
|
|
3845
|
+
let nodes = this.normalize(add, this.proxyOf.nodes[existIndex], type).reverse();
|
|
3846
|
+
existIndex = this.index(exist);
|
|
3840
3847
|
for (let node of nodes)
|
|
3841
|
-
this.proxyOf.nodes.splice(
|
|
3848
|
+
this.proxyOf.nodes.splice(existIndex, 0, node);
|
|
3842
3849
|
let index2;
|
|
3843
3850
|
for (let id in this.indexes) {
|
|
3844
3851
|
index2 = this.indexes[id];
|
|
3845
|
-
if (
|
|
3852
|
+
if (existIndex <= index2) {
|
|
3846
3853
|
this.indexes[id] = index2 + nodes.length;
|
|
3847
3854
|
}
|
|
3848
3855
|
}
|
|
@@ -3850,14 +3857,15 @@ var require_container = __commonJS({
|
|
|
3850
3857
|
return this;
|
|
3851
3858
|
}
|
|
3852
3859
|
insertAfter(exist, add) {
|
|
3853
|
-
|
|
3854
|
-
let nodes = this.normalize(add, this.proxyOf.nodes[
|
|
3860
|
+
let existIndex = this.index(exist);
|
|
3861
|
+
let nodes = this.normalize(add, this.proxyOf.nodes[existIndex]).reverse();
|
|
3862
|
+
existIndex = this.index(exist);
|
|
3855
3863
|
for (let node of nodes)
|
|
3856
|
-
this.proxyOf.nodes.splice(
|
|
3864
|
+
this.proxyOf.nodes.splice(existIndex + 1, 0, node);
|
|
3857
3865
|
let index2;
|
|
3858
3866
|
for (let id in this.indexes) {
|
|
3859
3867
|
index2 = this.indexes[id];
|
|
3860
|
-
if (
|
|
3868
|
+
if (existIndex < index2) {
|
|
3861
3869
|
this.indexes[id] = index2 + nodes.length;
|
|
3862
3870
|
}
|
|
3863
3871
|
}
|
|
@@ -4036,6 +4044,9 @@ var require_container = __commonJS({
|
|
|
4036
4044
|
Container3.registerAtRule = (dependant) => {
|
|
4037
4045
|
AtRule2 = dependant;
|
|
4038
4046
|
};
|
|
4047
|
+
Container3.registerRoot = (dependant) => {
|
|
4048
|
+
Root2 = dependant;
|
|
4049
|
+
};
|
|
4039
4050
|
module2.exports = Container3;
|
|
4040
4051
|
Container3.default = Container3;
|
|
4041
4052
|
Container3.rebuild = (node) => {
|
|
@@ -4047,6 +4058,8 @@ var require_container = __commonJS({
|
|
|
4047
4058
|
Object.setPrototypeOf(node, Declaration2.prototype);
|
|
4048
4059
|
} else if (node.type === "comment") {
|
|
4049
4060
|
Object.setPrototypeOf(node, Comment3.prototype);
|
|
4061
|
+
} else if (node.type === "root") {
|
|
4062
|
+
Object.setPrototypeOf(node, Root2.prototype);
|
|
4050
4063
|
}
|
|
4051
4064
|
node[my] = true;
|
|
4052
4065
|
if (node.nodes) {
|
|
@@ -4258,6 +4271,7 @@ var require_root = __commonJS({
|
|
|
4258
4271
|
};
|
|
4259
4272
|
module2.exports = Root2;
|
|
4260
4273
|
Root2.default = Root2;
|
|
4274
|
+
Container3.registerRoot(Root2);
|
|
4261
4275
|
}
|
|
4262
4276
|
});
|
|
4263
4277
|
|
|
@@ -4271,19 +4285,21 @@ var require_list = __commonJS({
|
|
|
4271
4285
|
let current = "";
|
|
4272
4286
|
let split = false;
|
|
4273
4287
|
let func = 0;
|
|
4274
|
-
let
|
|
4288
|
+
let inQuote = false;
|
|
4289
|
+
let prevQuote = "";
|
|
4275
4290
|
let escape = false;
|
|
4276
4291
|
for (let letter of string) {
|
|
4277
4292
|
if (escape) {
|
|
4278
4293
|
escape = false;
|
|
4279
4294
|
} else if (letter === "\\") {
|
|
4280
4295
|
escape = true;
|
|
4281
|
-
} else if (
|
|
4282
|
-
if (letter ===
|
|
4283
|
-
|
|
4296
|
+
} else if (inQuote) {
|
|
4297
|
+
if (letter === prevQuote) {
|
|
4298
|
+
inQuote = false;
|
|
4284
4299
|
}
|
|
4285
4300
|
} else if (letter === '"' || letter === "'") {
|
|
4286
|
-
|
|
4301
|
+
inQuote = true;
|
|
4302
|
+
prevQuote = letter;
|
|
4287
4303
|
} else if (letter === "(") {
|
|
4288
4304
|
func += 1;
|
|
4289
4305
|
} else if (letter === ")") {
|
|
@@ -5502,7 +5518,7 @@ var require_processor = __commonJS({
|
|
|
5502
5518
|
var Root2 = require_root();
|
|
5503
5519
|
var Processor2 = class {
|
|
5504
5520
|
constructor(plugins = []) {
|
|
5505
|
-
this.version = "8.4.
|
|
5521
|
+
this.version = "8.4.18";
|
|
5506
5522
|
this.plugins = this.normalize(plugins);
|
|
5507
5523
|
}
|
|
5508
5524
|
use(plugin2) {
|
|
@@ -6259,16 +6275,16 @@ var StyleMigrator = class {
|
|
|
6259
6275
|
return this.mixinChanges.some((change) => atRule2.params.includes(`${namespace}.${change.old}`));
|
|
6260
6276
|
}
|
|
6261
6277
|
getMixinChange(namespace, atRule2) {
|
|
6262
|
-
var _a;
|
|
6278
|
+
var _a, _b;
|
|
6263
6279
|
const change = this.mixinChanges.find((c) => {
|
|
6264
6280
|
return atRule2.params.includes(`${namespace}.${c.old}`);
|
|
6265
6281
|
});
|
|
6266
6282
|
if (!change) {
|
|
6267
6283
|
return null;
|
|
6268
6284
|
}
|
|
6269
|
-
const replacements = [...change.new];
|
|
6285
|
+
const replacements = [...(_a = change.new) != null ? _a : []];
|
|
6270
6286
|
if (change.checkForDuplicates) {
|
|
6271
|
-
const mixinArgumentMatches = (
|
|
6287
|
+
const mixinArgumentMatches = (_b = atRule2.params) == null ? void 0 : _b.match(MIXIN_ARGUMENTS_REGEX);
|
|
6272
6288
|
atRule2.root().walkAtRules((rule2) => {
|
|
6273
6289
|
for (const index2 in replacements) {
|
|
6274
6290
|
const mixinName = replacements[index2] + (mixinArgumentMatches ? mixinArgumentMatches[0] : "");
|
|
@@ -6278,10 +6294,7 @@ var StyleMigrator = class {
|
|
|
6278
6294
|
}
|
|
6279
6295
|
});
|
|
6280
6296
|
}
|
|
6281
|
-
|
|
6282
|
-
return null;
|
|
6283
|
-
}
|
|
6284
|
-
return { old: change.old, new: replacements };
|
|
6297
|
+
return { old: change.old, new: replacements.length ? replacements : null };
|
|
6285
6298
|
}
|
|
6286
6299
|
isLegacySelector(rule2) {
|
|
6287
6300
|
return this.classChanges.some((change) => {
|
|
@@ -11718,9 +11731,39 @@ var BuiltinFunctionCall = class extends Call {
|
|
|
11718
11731
|
this.converter = converter;
|
|
11719
11732
|
}
|
|
11720
11733
|
};
|
|
11734
|
+
var animationKeywords = /* @__PURE__ */ new Set([
|
|
11735
|
+
"inherit",
|
|
11736
|
+
"initial",
|
|
11737
|
+
"revert",
|
|
11738
|
+
"unset",
|
|
11739
|
+
"alternate",
|
|
11740
|
+
"alternate-reverse",
|
|
11741
|
+
"normal",
|
|
11742
|
+
"reverse",
|
|
11743
|
+
"backwards",
|
|
11744
|
+
"both",
|
|
11745
|
+
"forwards",
|
|
11746
|
+
"none",
|
|
11747
|
+
"paused",
|
|
11748
|
+
"running",
|
|
11749
|
+
"ease",
|
|
11750
|
+
"ease-in",
|
|
11751
|
+
"ease-in-out",
|
|
11752
|
+
"ease-out",
|
|
11753
|
+
"linear",
|
|
11754
|
+
"step-start",
|
|
11755
|
+
"step-end",
|
|
11756
|
+
"end",
|
|
11757
|
+
"jump-both",
|
|
11758
|
+
"jump-end",
|
|
11759
|
+
"jump-none",
|
|
11760
|
+
"jump-start",
|
|
11761
|
+
"start"
|
|
11762
|
+
]);
|
|
11721
11763
|
var ShadowCss = class {
|
|
11722
11764
|
constructor() {
|
|
11723
11765
|
this.strictStyling = true;
|
|
11766
|
+
this._animationDeclarationKeyframesRe = /(^|\s+)(?:(?:(['"])((?:\\\\|\\\2|(?!\2).)+)\2)|(-?[A-Za-z][\w\-]*))(?=[,\s]|$)/g;
|
|
11724
11767
|
}
|
|
11725
11768
|
shimCssText(cssText, selector, hostSelector = "") {
|
|
11726
11769
|
const commentsWithHash = extractCommentsWithHash(cssText);
|
|
@@ -11733,6 +11776,34 @@ var ShadowCss = class {
|
|
|
11733
11776
|
cssText = this._insertPolyfillDirectivesInCssText(cssText);
|
|
11734
11777
|
return this._insertPolyfillRulesInCssText(cssText);
|
|
11735
11778
|
}
|
|
11779
|
+
_scopeKeyframesRelatedCss(cssText, scopeSelector) {
|
|
11780
|
+
const unscopedKeyframesSet = /* @__PURE__ */ new Set();
|
|
11781
|
+
const scopedKeyframesCssText = processRules(cssText, (rule2) => this._scopeLocalKeyframeDeclarations(rule2, scopeSelector, unscopedKeyframesSet));
|
|
11782
|
+
return processRules(scopedKeyframesCssText, (rule2) => this._scopeAnimationRule(rule2, scopeSelector, unscopedKeyframesSet));
|
|
11783
|
+
}
|
|
11784
|
+
_scopeLocalKeyframeDeclarations(rule2, scopeSelector, unscopedKeyframesSet) {
|
|
11785
|
+
return Object.assign(Object.assign({}, rule2), { selector: rule2.selector.replace(/(^@(?:-webkit-)?keyframes(?:\s+))(['"]?)(.+)\2(\s*)$/, (_, start, quote, keyframeName, endSpaces) => {
|
|
11786
|
+
unscopedKeyframesSet.add(unescapeQuotes(keyframeName, quote));
|
|
11787
|
+
return `${start}${quote}${scopeSelector}_${keyframeName}${quote}${endSpaces}`;
|
|
11788
|
+
}) });
|
|
11789
|
+
}
|
|
11790
|
+
_scopeAnimationKeyframe(keyframe, scopeSelector, unscopedKeyframesSet) {
|
|
11791
|
+
return keyframe.replace(/^(\s*)(['"]?)(.+?)\2(\s*)$/, (_, spaces1, quote, name, spaces2) => {
|
|
11792
|
+
name = `${unscopedKeyframesSet.has(unescapeQuotes(name, quote)) ? scopeSelector + "_" : ""}${name}`;
|
|
11793
|
+
return `${spaces1}${quote}${name}${quote}${spaces2}`;
|
|
11794
|
+
});
|
|
11795
|
+
}
|
|
11796
|
+
_scopeAnimationRule(rule2, scopeSelector, unscopedKeyframesSet) {
|
|
11797
|
+
let content = rule2.content.replace(/((?:^|\s+|;)(?:-webkit-)?animation(?:\s*):(?:\s*))([^;]+)/g, (_, start, animationDeclarations) => start + animationDeclarations.replace(this._animationDeclarationKeyframesRe, (original, leadingSpaces, quote = "", quotedName, nonQuotedName) => {
|
|
11798
|
+
if (quotedName) {
|
|
11799
|
+
return `${leadingSpaces}${this._scopeAnimationKeyframe(`${quote}${quotedName}${quote}`, scopeSelector, unscopedKeyframesSet)}`;
|
|
11800
|
+
} else {
|
|
11801
|
+
return animationKeywords.has(nonQuotedName) ? original : `${leadingSpaces}${this._scopeAnimationKeyframe(nonQuotedName, scopeSelector, unscopedKeyframesSet)}`;
|
|
11802
|
+
}
|
|
11803
|
+
}));
|
|
11804
|
+
content = content.replace(/((?:^|\s+|;)(?:-webkit-)?animation-name(?:\s*):(?:\s*))([^;]+)/g, (_match, start, commaSeparatedKeyframes) => `${start}${commaSeparatedKeyframes.split(",").map((keyframe) => this._scopeAnimationKeyframe(keyframe, scopeSelector, unscopedKeyframesSet)).join(",")}`);
|
|
11805
|
+
return Object.assign(Object.assign({}, rule2), { content });
|
|
11806
|
+
}
|
|
11736
11807
|
_insertPolyfillDirectivesInCssText(cssText) {
|
|
11737
11808
|
return cssText.replace(_cssContentNextSelectorRe, function(...m) {
|
|
11738
11809
|
return m[2] + "{";
|
|
@@ -11751,6 +11822,7 @@ var ShadowCss = class {
|
|
|
11751
11822
|
cssText = this._convertColonHostContext(cssText);
|
|
11752
11823
|
cssText = this._convertShadowDOMSelectors(cssText);
|
|
11753
11824
|
if (scopeSelector) {
|
|
11825
|
+
cssText = this._scopeKeyframesRelatedCss(cssText, scopeSelector);
|
|
11754
11826
|
cssText = this._scopeSelectors(cssText, scopeSelector, hostSelector);
|
|
11755
11827
|
}
|
|
11756
11828
|
cssText = cssText + "\n" + unscopedRules;
|
|
@@ -11969,11 +12041,14 @@ function extractCommentsWithHash(input) {
|
|
|
11969
12041
|
return input.match(_commentWithHashRe) || [];
|
|
11970
12042
|
}
|
|
11971
12043
|
var BLOCK_PLACEHOLDER = "%BLOCK%";
|
|
11972
|
-
var QUOTE_PLACEHOLDER = "%QUOTED%";
|
|
11973
12044
|
var _ruleRe = /(\s*)([^;\{\}]+?)(\s*)((?:{%BLOCK%}?\s*;?)|(?:\s*;))/g;
|
|
11974
|
-
var _quotedRe = /%QUOTED%/g;
|
|
11975
12045
|
var CONTENT_PAIRS = /* @__PURE__ */ new Map([["{", "}"]]);
|
|
11976
|
-
var
|
|
12046
|
+
var COMMA_IN_PLACEHOLDER = "%COMMA_IN_PLACEHOLDER%";
|
|
12047
|
+
var SEMI_IN_PLACEHOLDER = "%SEMI_IN_PLACEHOLDER%";
|
|
12048
|
+
var COLON_IN_PLACEHOLDER = "%COLON_IN_PLACEHOLDER%";
|
|
12049
|
+
var _cssCommaInPlaceholderReGlobal = new RegExp(COMMA_IN_PLACEHOLDER, "g");
|
|
12050
|
+
var _cssSemiInPlaceholderReGlobal = new RegExp(SEMI_IN_PLACEHOLDER, "g");
|
|
12051
|
+
var _cssColonInPlaceholderReGlobal = new RegExp(COLON_IN_PLACEHOLDER, "g");
|
|
11977
12052
|
var CssRule = class {
|
|
11978
12053
|
constructor(selector, content) {
|
|
11979
12054
|
this.selector = selector;
|
|
@@ -11981,11 +12056,10 @@ var CssRule = class {
|
|
|
11981
12056
|
}
|
|
11982
12057
|
};
|
|
11983
12058
|
function processRules(input, ruleCallback) {
|
|
11984
|
-
const
|
|
11985
|
-
const inputWithEscapedBlocks = escapeBlocks(
|
|
12059
|
+
const escaped = escapeInStrings(input);
|
|
12060
|
+
const inputWithEscapedBlocks = escapeBlocks(escaped, CONTENT_PAIRS, BLOCK_PLACEHOLDER);
|
|
11986
12061
|
let nextBlockIndex = 0;
|
|
11987
|
-
|
|
11988
|
-
return inputWithEscapedBlocks.escapedString.replace(_ruleRe, (...m) => {
|
|
12062
|
+
const escapedResult = inputWithEscapedBlocks.escapedString.replace(_ruleRe, (...m) => {
|
|
11989
12063
|
const selector = m[2];
|
|
11990
12064
|
let content = "";
|
|
11991
12065
|
let suffix = m[4];
|
|
@@ -11997,7 +12071,8 @@ function processRules(input, ruleCallback) {
|
|
|
11997
12071
|
}
|
|
11998
12072
|
const rule2 = ruleCallback(new CssRule(selector, content));
|
|
11999
12073
|
return `${m[1]}${rule2.selector}${m[3]}${contentPrefix}${rule2.content}${suffix}`;
|
|
12000
|
-
})
|
|
12074
|
+
});
|
|
12075
|
+
return unescapeInStrings(escapedResult);
|
|
12001
12076
|
}
|
|
12002
12077
|
var StringWithEscapedBlocks = class {
|
|
12003
12078
|
constructor(escapedString, blocks) {
|
|
@@ -12044,6 +12119,45 @@ function escapeBlocks(input, charPairs, placeholder) {
|
|
|
12044
12119
|
}
|
|
12045
12120
|
return new StringWithEscapedBlocks(resultParts.join(""), escapedBlocks);
|
|
12046
12121
|
}
|
|
12122
|
+
var ESCAPE_IN_STRING_MAP = {
|
|
12123
|
+
";": SEMI_IN_PLACEHOLDER,
|
|
12124
|
+
",": COMMA_IN_PLACEHOLDER,
|
|
12125
|
+
":": COLON_IN_PLACEHOLDER
|
|
12126
|
+
};
|
|
12127
|
+
function escapeInStrings(input) {
|
|
12128
|
+
let result = input;
|
|
12129
|
+
let currentQuoteChar = null;
|
|
12130
|
+
for (let i = 0; i < result.length; i++) {
|
|
12131
|
+
const char = result[i];
|
|
12132
|
+
if (char === "\\") {
|
|
12133
|
+
i++;
|
|
12134
|
+
} else {
|
|
12135
|
+
if (currentQuoteChar !== null) {
|
|
12136
|
+
if (char === currentQuoteChar) {
|
|
12137
|
+
currentQuoteChar = null;
|
|
12138
|
+
} else {
|
|
12139
|
+
const placeholder = ESCAPE_IN_STRING_MAP[char];
|
|
12140
|
+
if (placeholder) {
|
|
12141
|
+
result = `${result.substr(0, i)}${placeholder}${result.substr(i + 1)}`;
|
|
12142
|
+
i += placeholder.length - 1;
|
|
12143
|
+
}
|
|
12144
|
+
}
|
|
12145
|
+
} else if (char === "'" || char === '"') {
|
|
12146
|
+
currentQuoteChar = char;
|
|
12147
|
+
}
|
|
12148
|
+
}
|
|
12149
|
+
}
|
|
12150
|
+
return result;
|
|
12151
|
+
}
|
|
12152
|
+
function unescapeInStrings(input) {
|
|
12153
|
+
let result = input.replace(_cssCommaInPlaceholderReGlobal, ",");
|
|
12154
|
+
result = result.replace(_cssSemiInPlaceholderReGlobal, ";");
|
|
12155
|
+
result = result.replace(_cssColonInPlaceholderReGlobal, ":");
|
|
12156
|
+
return result;
|
|
12157
|
+
}
|
|
12158
|
+
function unescapeQuotes(str, isQuoted) {
|
|
12159
|
+
return !isQuoted ? str : str.replace(/((?:^|[^\\])(?:\\\\)*)\\(?=['"])/g, "$1");
|
|
12160
|
+
}
|
|
12047
12161
|
function combineHostContextSelectors(contextSelectors, otherSelectors) {
|
|
12048
12162
|
const hostMarker = _polyfillHostNoCombinator;
|
|
12049
12163
|
_polyfillHostRe.lastIndex = 0;
|
|
@@ -17197,12 +17311,10 @@ function SECURITY_SCHEMA() {
|
|
|
17197
17311
|
"del|cite",
|
|
17198
17312
|
"form|action",
|
|
17199
17313
|
"img|src",
|
|
17200
|
-
"img|srcset",
|
|
17201
17314
|
"input|src",
|
|
17202
17315
|
"ins|cite",
|
|
17203
17316
|
"q|cite",
|
|
17204
17317
|
"source|src",
|
|
17205
|
-
"source|srcset",
|
|
17206
17318
|
"track|src",
|
|
17207
17319
|
"video|poster",
|
|
17208
17320
|
"video|src"
|
|
@@ -17236,11 +17348,11 @@ var NUMBER = "number";
|
|
|
17236
17348
|
var STRING = "string";
|
|
17237
17349
|
var OBJECT = "object";
|
|
17238
17350
|
var SCHEMA = [
|
|
17239
|
-
"[Element]|textContent,%classList,className,id,innerHTML,*beforecopy,*beforecut,*beforepaste,*
|
|
17240
|
-
"[HTMLElement]^[Element]|accessKey,contentEditable,dir,!draggable,!hidden,innerText,lang,*abort,*auxclick,*blur,*cancel,*canplay,*canplaythrough,*change,*click,*close,*contextmenu,*cuechange,*dblclick,*drag,*dragend,*dragenter,*dragleave,*dragover,*dragstart,*drop,*durationchange,*emptied,*ended,*error,*focus,*gotpointercapture,*input,*invalid,*keydown,*keypress,*keyup,*load,*loadeddata,*loadedmetadata,*loadstart,*lostpointercapture,*mousedown,*mouseenter,*mouseleave,*mousemove,*mouseout,*mouseover,*mouseup,*mousewheel,*pause,*play,*playing,*pointercancel,*pointerdown,*pointerenter,*pointerleave,*pointermove,*pointerout,*pointerover,*pointerup,*progress,*ratechange,*reset,*resize,*scroll,*seeked,*seeking,*select,*
|
|
17241
|
-
"abbr,address,article,aside,b,bdi,bdo,cite,code,dd,dfn,dt,em,figcaption,figure,footer,header,i,kbd,main,mark,nav,noscript,rb,rp,rt,rtc,ruby,s,samp,section,small,strong,sub,sup,u,var,wbr^[HTMLElement]|accessKey,contentEditable,dir,!draggable,!hidden,innerText,lang,*abort,*auxclick,*blur,*cancel,*canplay,*canplaythrough,*change,*click,*close,*contextmenu,*cuechange,*dblclick,*drag,*dragend,*dragenter,*dragleave,*dragover,*dragstart,*drop,*durationchange,*emptied,*ended,*error,*focus,*gotpointercapture,*input,*invalid,*keydown,*keypress,*keyup,*load,*loadeddata,*loadedmetadata,*loadstart,*lostpointercapture,*mousedown,*mouseenter,*mouseleave,*mousemove,*mouseout,*mouseover,*mouseup,*mousewheel,*pause,*play,*playing,*pointercancel,*pointerdown,*pointerenter,*pointerleave,*pointermove,*pointerout,*pointerover,*pointerup,*progress,*ratechange,*reset,*resize,*scroll,*seeked,*seeking,*select,*
|
|
17242
|
-
"media^[HTMLElement]|!autoplay,!controls,%controlsList,%crossOrigin,#currentTime,!defaultMuted,#defaultPlaybackRate,!disableRemotePlayback,!loop,!muted,*encrypted,*waitingforkey,#playbackRate,preload,src,%srcObject,#volume",
|
|
17243
|
-
":svg:^[HTMLElement]
|
|
17351
|
+
"[Element]|textContent,%ariaAtomic,%ariaAutoComplete,%ariaBusy,%ariaChecked,%ariaColCount,%ariaColIndex,%ariaColSpan,%ariaCurrent,%ariaDescription,%ariaDisabled,%ariaExpanded,%ariaHasPopup,%ariaHidden,%ariaKeyShortcuts,%ariaLabel,%ariaLevel,%ariaLive,%ariaModal,%ariaMultiLine,%ariaMultiSelectable,%ariaOrientation,%ariaPlaceholder,%ariaPosInSet,%ariaPressed,%ariaReadOnly,%ariaRelevant,%ariaRequired,%ariaRoleDescription,%ariaRowCount,%ariaRowIndex,%ariaRowSpan,%ariaSelected,%ariaSetSize,%ariaSort,%ariaValueMax,%ariaValueMin,%ariaValueNow,%ariaValueText,%classList,className,elementTiming,id,innerHTML,*beforecopy,*beforecut,*beforepaste,*fullscreenchange,*fullscreenerror,*search,*webkitfullscreenchange,*webkitfullscreenerror,outerHTML,%part,#scrollLeft,#scrollTop,slot,*message,*mozfullscreenchange,*mozfullscreenerror,*mozpointerlockchange,*mozpointerlockerror,*webglcontextcreationerror,*webglcontextlost,*webglcontextrestored",
|
|
17352
|
+
"[HTMLElement]^[Element]|accessKey,autocapitalize,!autofocus,contentEditable,dir,!draggable,enterKeyHint,!hidden,innerText,inputMode,lang,nonce,*abort,*animationend,*animationiteration,*animationstart,*auxclick,*beforexrselect,*blur,*cancel,*canplay,*canplaythrough,*change,*click,*close,*contextmenu,*copy,*cuechange,*cut,*dblclick,*drag,*dragend,*dragenter,*dragleave,*dragover,*dragstart,*drop,*durationchange,*emptied,*ended,*error,*focus,*formdata,*gotpointercapture,*input,*invalid,*keydown,*keypress,*keyup,*load,*loadeddata,*loadedmetadata,*loadstart,*lostpointercapture,*mousedown,*mouseenter,*mouseleave,*mousemove,*mouseout,*mouseover,*mouseup,*mousewheel,*paste,*pause,*play,*playing,*pointercancel,*pointerdown,*pointerenter,*pointerleave,*pointermove,*pointerout,*pointerover,*pointerrawupdate,*pointerup,*progress,*ratechange,*reset,*resize,*scroll,*securitypolicyviolation,*seeked,*seeking,*select,*selectionchange,*selectstart,*slotchange,*stalled,*submit,*suspend,*timeupdate,*toggle,*transitioncancel,*transitionend,*transitionrun,*transitionstart,*volumechange,*waiting,*webkitanimationend,*webkitanimationiteration,*webkitanimationstart,*webkittransitionend,*wheel,outerText,!spellcheck,%style,#tabIndex,title,!translate,virtualKeyboardPolicy",
|
|
17353
|
+
"abbr,address,article,aside,b,bdi,bdo,cite,content,code,dd,dfn,dt,em,figcaption,figure,footer,header,hgroup,i,kbd,main,mark,nav,noscript,rb,rp,rt,rtc,ruby,s,samp,section,small,strong,sub,sup,u,var,wbr^[HTMLElement]|accessKey,autocapitalize,!autofocus,contentEditable,dir,!draggable,enterKeyHint,!hidden,innerText,inputMode,lang,nonce,*abort,*animationend,*animationiteration,*animationstart,*auxclick,*beforexrselect,*blur,*cancel,*canplay,*canplaythrough,*change,*click,*close,*contextmenu,*copy,*cuechange,*cut,*dblclick,*drag,*dragend,*dragenter,*dragleave,*dragover,*dragstart,*drop,*durationchange,*emptied,*ended,*error,*focus,*formdata,*gotpointercapture,*input,*invalid,*keydown,*keypress,*keyup,*load,*loadeddata,*loadedmetadata,*loadstart,*lostpointercapture,*mousedown,*mouseenter,*mouseleave,*mousemove,*mouseout,*mouseover,*mouseup,*mousewheel,*paste,*pause,*play,*playing,*pointercancel,*pointerdown,*pointerenter,*pointerleave,*pointermove,*pointerout,*pointerover,*pointerrawupdate,*pointerup,*progress,*ratechange,*reset,*resize,*scroll,*securitypolicyviolation,*seeked,*seeking,*select,*selectionchange,*selectstart,*slotchange,*stalled,*submit,*suspend,*timeupdate,*toggle,*transitioncancel,*transitionend,*transitionrun,*transitionstart,*volumechange,*waiting,*webkitanimationend,*webkitanimationiteration,*webkitanimationstart,*webkittransitionend,*wheel,outerText,!spellcheck,%style,#tabIndex,title,!translate,virtualKeyboardPolicy",
|
|
17354
|
+
"media^[HTMLElement]|!autoplay,!controls,%controlsList,%crossOrigin,#currentTime,!defaultMuted,#defaultPlaybackRate,!disableRemotePlayback,!loop,!muted,*encrypted,*waitingforkey,#playbackRate,preload,!preservesPitch,src,%srcObject,#volume",
|
|
17355
|
+
":svg:^[HTMLElement]|!autofocus,nonce,*abort,*animationend,*animationiteration,*animationstart,*auxclick,*beforexrselect,*blur,*cancel,*canplay,*canplaythrough,*change,*click,*close,*contextmenu,*copy,*cuechange,*cut,*dblclick,*drag,*dragend,*dragenter,*dragleave,*dragover,*dragstart,*drop,*durationchange,*emptied,*ended,*error,*focus,*formdata,*gotpointercapture,*input,*invalid,*keydown,*keypress,*keyup,*load,*loadeddata,*loadedmetadata,*loadstart,*lostpointercapture,*mousedown,*mouseenter,*mouseleave,*mousemove,*mouseout,*mouseover,*mouseup,*mousewheel,*paste,*pause,*play,*playing,*pointercancel,*pointerdown,*pointerenter,*pointerleave,*pointermove,*pointerout,*pointerover,*pointerrawupdate,*pointerup,*progress,*ratechange,*reset,*resize,*scroll,*securitypolicyviolation,*seeked,*seeking,*select,*selectionchange,*selectstart,*slotchange,*stalled,*submit,*suspend,*timeupdate,*toggle,*transitioncancel,*transitionend,*transitionrun,*transitionstart,*volumechange,*waiting,*webkitanimationend,*webkitanimationiteration,*webkitanimationstart,*webkittransitionend,*wheel,%style,#tabIndex",
|
|
17244
17356
|
":svg:graphics^:svg:|",
|
|
17245
17357
|
":svg:animation^:svg:|*begin,*end,*repeat",
|
|
17246
17358
|
":svg:geometry^:svg:|",
|
|
@@ -17248,16 +17360,17 @@ var SCHEMA = [
|
|
|
17248
17360
|
":svg:gradient^:svg:|",
|
|
17249
17361
|
":svg:textContent^:svg:graphics|",
|
|
17250
17362
|
":svg:textPositioning^:svg:textContent|",
|
|
17251
|
-
"a^[HTMLElement]|charset,coords,download,hash,host,hostname,href,hreflang,name,password,pathname,ping,port,protocol,referrerPolicy,rel,rev,search,shape,target,text,type,username",
|
|
17252
|
-
"area^[HTMLElement]|alt,coords,download,hash,host,hostname,href,!noHref,password,pathname,ping,port,protocol,referrerPolicy,rel,search,shape,target,username",
|
|
17363
|
+
"a^[HTMLElement]|charset,coords,download,hash,host,hostname,href,hreflang,name,password,pathname,ping,port,protocol,referrerPolicy,rel,%relList,rev,search,shape,target,text,type,username",
|
|
17364
|
+
"area^[HTMLElement]|alt,coords,download,hash,host,hostname,href,!noHref,password,pathname,ping,port,protocol,referrerPolicy,rel,%relList,search,shape,target,username",
|
|
17253
17365
|
"audio^media|",
|
|
17254
17366
|
"br^[HTMLElement]|clear",
|
|
17255
17367
|
"base^[HTMLElement]|href,target",
|
|
17256
|
-
"body^[HTMLElement]|aLink,background,bgColor,link,*beforeunload,*blur,*error,*focus,*hashchange,*languagechange,*load,*message,*offline,*online,*pagehide,*pageshow,*popstate,*rejectionhandled,*resize,*scroll,*storage,*unhandledrejection,*unload,text,vLink",
|
|
17257
|
-
"button^[HTMLElement]|!
|
|
17368
|
+
"body^[HTMLElement]|aLink,background,bgColor,link,*afterprint,*beforeprint,*beforeunload,*blur,*error,*focus,*hashchange,*languagechange,*load,*message,*messageerror,*offline,*online,*pagehide,*pageshow,*popstate,*rejectionhandled,*resize,*scroll,*storage,*unhandledrejection,*unload,text,vLink",
|
|
17369
|
+
"button^[HTMLElement]|!disabled,formAction,formEnctype,formMethod,!formNoValidate,formTarget,name,type,value",
|
|
17258
17370
|
"canvas^[HTMLElement]|#height,#width",
|
|
17259
17371
|
"content^[HTMLElement]|select",
|
|
17260
17372
|
"dl^[HTMLElement]|!compact",
|
|
17373
|
+
"data^[HTMLElement]|value",
|
|
17261
17374
|
"datalist^[HTMLElement]|",
|
|
17262
17375
|
"details^[HTMLElement]|!open",
|
|
17263
17376
|
"dialog^[HTMLElement]|!open,returnValue",
|
|
@@ -17268,22 +17381,22 @@ var SCHEMA = [
|
|
|
17268
17381
|
"font^[HTMLElement]|color,face,size",
|
|
17269
17382
|
"form^[HTMLElement]|acceptCharset,action,autocomplete,encoding,enctype,method,name,!noValidate,target",
|
|
17270
17383
|
"frame^[HTMLElement]|frameBorder,longDesc,marginHeight,marginWidth,name,!noResize,scrolling,src",
|
|
17271
|
-
"frameset^[HTMLElement]|cols,*beforeunload,*blur,*error,*focus,*hashchange,*languagechange,*load,*message,*offline,*online,*pagehide,*pageshow,*popstate,*rejectionhandled,*resize,*scroll,*storage,*unhandledrejection,*unload,rows",
|
|
17384
|
+
"frameset^[HTMLElement]|cols,*afterprint,*beforeprint,*beforeunload,*blur,*error,*focus,*hashchange,*languagechange,*load,*message,*messageerror,*offline,*online,*pagehide,*pageshow,*popstate,*rejectionhandled,*resize,*scroll,*storage,*unhandledrejection,*unload,rows",
|
|
17272
17385
|
"hr^[HTMLElement]|align,color,!noShade,size,width",
|
|
17273
17386
|
"head^[HTMLElement]|",
|
|
17274
17387
|
"h1,h2,h3,h4,h5,h6^[HTMLElement]|align",
|
|
17275
17388
|
"html^[HTMLElement]|version",
|
|
17276
|
-
"iframe^[HTMLElement]|align,!allowFullscreen,frameBorder,height,longDesc,marginHeight,marginWidth,name,referrerPolicy,%sandbox,scrolling,src,srcdoc,width",
|
|
17277
|
-
"img^[HTMLElement]|align,alt,border,%crossOrigin,#height,#hspace,!isMap,longDesc,lowsrc,name,referrerPolicy,sizes,src,srcset,useMap,#vspace,#width",
|
|
17278
|
-
"input^[HTMLElement]|accept,align,alt,
|
|
17389
|
+
"iframe^[HTMLElement]|align,allow,!allowFullscreen,!allowPaymentRequest,csp,frameBorder,height,loading,longDesc,marginHeight,marginWidth,name,referrerPolicy,%sandbox,scrolling,src,srcdoc,width",
|
|
17390
|
+
"img^[HTMLElement]|align,alt,border,%crossOrigin,decoding,#height,#hspace,!isMap,loading,longDesc,lowsrc,name,referrerPolicy,sizes,src,srcset,useMap,#vspace,#width",
|
|
17391
|
+
"input^[HTMLElement]|accept,align,alt,autocomplete,!checked,!defaultChecked,defaultValue,dirName,!disabled,%files,formAction,formEnctype,formMethod,!formNoValidate,formTarget,#height,!incremental,!indeterminate,max,#maxLength,min,#minLength,!multiple,name,pattern,placeholder,!readOnly,!required,selectionDirection,#selectionEnd,#selectionStart,#size,src,step,type,useMap,value,%valueAsDate,#valueAsNumber,#width",
|
|
17279
17392
|
"li^[HTMLElement]|type,#value",
|
|
17280
17393
|
"label^[HTMLElement]|htmlFor",
|
|
17281
17394
|
"legend^[HTMLElement]|align",
|
|
17282
|
-
"link^[HTMLElement]|as,charset,%crossOrigin,!disabled,href,hreflang,integrity,media,referrerPolicy,rel,%relList,rev,%sizes,target,type",
|
|
17395
|
+
"link^[HTMLElement]|as,charset,%crossOrigin,!disabled,href,hreflang,imageSizes,imageSrcset,integrity,media,referrerPolicy,rel,%relList,rev,%sizes,target,type",
|
|
17283
17396
|
"map^[HTMLElement]|name",
|
|
17284
17397
|
"marquee^[HTMLElement]|behavior,bgColor,direction,height,#hspace,#loop,#scrollAmount,#scrollDelay,!trueSpeed,#vspace,width",
|
|
17285
17398
|
"menu^[HTMLElement]|!compact",
|
|
17286
|
-
"meta^[HTMLElement]|content,httpEquiv,name,scheme",
|
|
17399
|
+
"meta^[HTMLElement]|content,httpEquiv,media,name,scheme",
|
|
17287
17400
|
"meter^[HTMLElement]|#high,#low,#max,#min,#optimum,#value",
|
|
17288
17401
|
"ins,del^[HTMLElement]|cite,dateTime",
|
|
17289
17402
|
"ol^[HTMLElement]|!compact,!reversed,#start,type",
|
|
@@ -17297,11 +17410,10 @@ var SCHEMA = [
|
|
|
17297
17410
|
"pre^[HTMLElement]|#width",
|
|
17298
17411
|
"progress^[HTMLElement]|#max,#value",
|
|
17299
17412
|
"q,blockquote,cite^[HTMLElement]|",
|
|
17300
|
-
"script^[HTMLElement]|!async,charset,%crossOrigin,!defer,event,htmlFor,integrity,src,text,type",
|
|
17301
|
-
"select^[HTMLElement]|autocomplete,!
|
|
17302
|
-
"shadow^[HTMLElement]|",
|
|
17413
|
+
"script^[HTMLElement]|!async,charset,%crossOrigin,!defer,event,htmlFor,integrity,!noModule,%referrerPolicy,src,text,type",
|
|
17414
|
+
"select^[HTMLElement]|autocomplete,!disabled,#length,!multiple,name,!required,#selectedIndex,#size,value",
|
|
17303
17415
|
"slot^[HTMLElement]|name",
|
|
17304
|
-
"source^[HTMLElement]
|
|
17416
|
+
"source^[HTMLElement]|#height,media,sizes,src,srcset,type,#width",
|
|
17305
17417
|
"span^[HTMLElement]|",
|
|
17306
17418
|
"style^[HTMLElement]|!disabled,media,type",
|
|
17307
17419
|
"caption^[HTMLElement]|align",
|
|
@@ -17311,12 +17423,13 @@ var SCHEMA = [
|
|
|
17311
17423
|
"tr^[HTMLElement]|align,bgColor,ch,chOff,vAlign",
|
|
17312
17424
|
"tfoot,thead,tbody^[HTMLElement]|align,ch,chOff,vAlign",
|
|
17313
17425
|
"template^[HTMLElement]|",
|
|
17314
|
-
"textarea^[HTMLElement]|
|
|
17426
|
+
"textarea^[HTMLElement]|autocomplete,#cols,defaultValue,dirName,!disabled,#maxLength,#minLength,name,placeholder,!readOnly,!required,#rows,selectionDirection,#selectionEnd,#selectionStart,value,wrap",
|
|
17427
|
+
"time^[HTMLElement]|dateTime",
|
|
17315
17428
|
"title^[HTMLElement]|text",
|
|
17316
17429
|
"track^[HTMLElement]|!default,kind,label,src,srclang",
|
|
17317
17430
|
"ul^[HTMLElement]|!compact,type",
|
|
17318
17431
|
"unknown^[HTMLElement]|",
|
|
17319
|
-
"video^media
|
|
17432
|
+
"video^media|!disablePictureInPicture,#height,*enterpictureinpicture,*leavepictureinpicture,!playsInline,poster,#width",
|
|
17320
17433
|
":svg:a^:svg:graphics|",
|
|
17321
17434
|
":svg:animate^:svg:animation|",
|
|
17322
17435
|
":svg:animateMotion^:svg:animation|",
|
|
@@ -17355,7 +17468,7 @@ var SCHEMA = [
|
|
|
17355
17468
|
":svg:filter^:svg:|",
|
|
17356
17469
|
":svg:foreignObject^:svg:graphics|",
|
|
17357
17470
|
":svg:g^:svg:graphics|",
|
|
17358
|
-
":svg:image^:svg:graphics|",
|
|
17471
|
+
":svg:image^:svg:graphics|decoding",
|
|
17359
17472
|
":svg:line^:svg:geometry|",
|
|
17360
17473
|
":svg:linearGradient^:svg:gradient|",
|
|
17361
17474
|
":svg:mpath^:svg:|",
|
|
@@ -21209,7 +21322,7 @@ function publishFacade(global2) {
|
|
|
21209
21322
|
const ng = global2.ng || (global2.ng = {});
|
|
21210
21323
|
ng.\u0275compilerFacade = new CompilerFacadeImpl();
|
|
21211
21324
|
}
|
|
21212
|
-
var VERSION = new Version("15.0.0-
|
|
21325
|
+
var VERSION = new Version("15.0.0-rc.0");
|
|
21213
21326
|
var _VisitorMode;
|
|
21214
21327
|
(function(_VisitorMode2) {
|
|
21215
21328
|
_VisitorMode2[_VisitorMode2["Extract"] = 0] = "Extract";
|
|
@@ -21274,25 +21387,38 @@ function replaceEndTag(html, node, tag) {
|
|
|
21274
21387
|
}
|
|
21275
21388
|
return replaceAt(html, node.endSourceSpan.start.offset + 2, node.name, tag);
|
|
21276
21389
|
}
|
|
21277
|
-
function
|
|
21390
|
+
function updateAttribute(html, node, name, update) {
|
|
21391
|
+
var _a;
|
|
21278
21392
|
const existingAttr = node.attributes.find((currentAttr) => currentAttr.name === name);
|
|
21279
|
-
if (existingAttr) {
|
|
21280
|
-
|
|
21281
|
-
|
|
21282
|
-
|
|
21283
|
-
|
|
21393
|
+
if (existingAttr && existingAttr.keySpan) {
|
|
21394
|
+
const updatedValue = update(((_a = existingAttr.valueSpan) == null ? void 0 : _a.toString()) || "");
|
|
21395
|
+
if (updatedValue == null) {
|
|
21396
|
+
return html.slice(0, existingAttr.sourceSpan.start.offset).trimEnd() + html.slice(existingAttr.sourceSpan.end.offset);
|
|
21397
|
+
} else if (updatedValue == "") {
|
|
21398
|
+
return html.slice(0, existingAttr.keySpan.end.offset) + html.slice(existingAttr.sourceSpan.end.offset);
|
|
21399
|
+
} else {
|
|
21400
|
+
if (existingAttr.valueSpan) {
|
|
21401
|
+
return html.slice(0, existingAttr.valueSpan.start.offset) + updatedValue + html.slice(existingAttr.valueSpan.end.offset);
|
|
21402
|
+
} else {
|
|
21403
|
+
return html.slice(0, existingAttr.keySpan.end.offset) + `="${updatedValue}"` + html.slice(existingAttr.keySpan.end.offset);
|
|
21404
|
+
}
|
|
21284
21405
|
}
|
|
21285
21406
|
}
|
|
21407
|
+
const newValue = update(null);
|
|
21408
|
+
if (newValue == null) {
|
|
21409
|
+
return html;
|
|
21410
|
+
}
|
|
21286
21411
|
const index2 = node.startSourceSpan.start.offset + node.name.length + 1;
|
|
21287
21412
|
const prefix = html.slice(0, index2);
|
|
21288
21413
|
const suffix = html.slice(index2);
|
|
21414
|
+
const attrText = newValue ? `${name}="${newValue}"` : `${name}`;
|
|
21289
21415
|
if (node.startSourceSpan.start.line === node.startSourceSpan.end.line) {
|
|
21290
|
-
return prefix
|
|
21416
|
+
return `${prefix} ${attrText}${suffix}`;
|
|
21291
21417
|
}
|
|
21292
21418
|
const attr = node.attributes[0];
|
|
21293
21419
|
const ctx = attr.sourceSpan.start.getContext(attr.sourceSpan.start.col + 1, 1);
|
|
21294
21420
|
const indentation = ctx.before;
|
|
21295
|
-
return prefix + indentation +
|
|
21421
|
+
return prefix + indentation + attrText + suffix;
|
|
21296
21422
|
}
|
|
21297
21423
|
function replaceAt(str, offset, oldSubstr, newSubstr) {
|
|
21298
21424
|
const index2 = offset;
|
|
@@ -21311,7 +21437,7 @@ var CardTemplateMigrator = class extends TemplateMigrator {
|
|
|
21311
21437
|
}
|
|
21312
21438
|
updates.push({
|
|
21313
21439
|
offset: node.startSourceSpan.start.offset,
|
|
21314
|
-
updateFn: (html) =>
|
|
21440
|
+
updateFn: (html) => updateAttribute(html, node, "appearance", () => "outlined")
|
|
21315
21441
|
});
|
|
21316
21442
|
});
|
|
21317
21443
|
return updates;
|
|
@@ -21752,193 +21878,6 @@ var RadioStylesMigrator = class extends StyleMigrator {
|
|
|
21752
21878
|
}
|
|
21753
21879
|
};
|
|
21754
21880
|
|
|
21755
|
-
// bazel-out/k8-fastbuild/bin/src/material/schematics/ng-generate/mdc-migration/rules/ts-migration/runtime-migrator.js
|
|
21756
|
-
var ts = __toESM(require("typescript"));
|
|
21757
|
-
|
|
21758
|
-
// bazel-out/k8-fastbuild/bin/src/material/schematics/ng-generate/mdc-migration/rules/ts-migration/import-replacements.js
|
|
21759
|
-
var REPLACEMENTS = {
|
|
21760
|
-
"button": {
|
|
21761
|
-
old: "@angular/material/legacy-button",
|
|
21762
|
-
new: "@angular/material/button"
|
|
21763
|
-
},
|
|
21764
|
-
"card": {
|
|
21765
|
-
old: "@angular/material/legacy-card",
|
|
21766
|
-
new: "@angular/material/card"
|
|
21767
|
-
},
|
|
21768
|
-
"checkbox": {
|
|
21769
|
-
old: "@angular/material/legacy-checkbox",
|
|
21770
|
-
new: "@angular/material/checkbox"
|
|
21771
|
-
},
|
|
21772
|
-
"chips": {
|
|
21773
|
-
old: "@angular/material/legacy-chips",
|
|
21774
|
-
new: "@angular/material/chips",
|
|
21775
|
-
additionalMatModuleNamePrefixes: ["chip"]
|
|
21776
|
-
},
|
|
21777
|
-
"dialog": {
|
|
21778
|
-
old: "@angular/material/legacy-dialog",
|
|
21779
|
-
new: "@angular/material/dialog",
|
|
21780
|
-
customReplacements: [{ old: "LegacyDialogRole", new: "DialogRole" }]
|
|
21781
|
-
},
|
|
21782
|
-
"autocomplete": {
|
|
21783
|
-
old: "@angular/material/legacy-autocomplete",
|
|
21784
|
-
new: "@angular/material/autocomplete"
|
|
21785
|
-
},
|
|
21786
|
-
"form-field": {
|
|
21787
|
-
old: "@angular/material/legacy-form-field",
|
|
21788
|
-
new: "@angular/material/form-field"
|
|
21789
|
-
},
|
|
21790
|
-
"input": {
|
|
21791
|
-
old: "@angular/material/legacy-input",
|
|
21792
|
-
new: "@angular/material/input"
|
|
21793
|
-
},
|
|
21794
|
-
"optgroup": {
|
|
21795
|
-
old: "@angular/material/legacy-core",
|
|
21796
|
-
new: "@angular/material/core"
|
|
21797
|
-
},
|
|
21798
|
-
"option": {
|
|
21799
|
-
old: "@angular/material/legacy-core",
|
|
21800
|
-
new: "@angular/material/core"
|
|
21801
|
-
},
|
|
21802
|
-
"select": {
|
|
21803
|
-
old: "@angular/material/legacy-select",
|
|
21804
|
-
new: "@angular/material/select"
|
|
21805
|
-
},
|
|
21806
|
-
"list": {
|
|
21807
|
-
old: "@angular/material/legacy-list",
|
|
21808
|
-
new: "@angular/material/list"
|
|
21809
|
-
},
|
|
21810
|
-
"menu": {
|
|
21811
|
-
old: "@angular/material/legacy-menu",
|
|
21812
|
-
new: "@angular/material/menu"
|
|
21813
|
-
},
|
|
21814
|
-
"progress-bar": {
|
|
21815
|
-
old: "@angular/material/legacy-progress-bar",
|
|
21816
|
-
new: "@angular/material/progress-bar"
|
|
21817
|
-
},
|
|
21818
|
-
"progress-spinner": {
|
|
21819
|
-
old: "@angular/material/legacy-progress-spinner",
|
|
21820
|
-
new: "@angular/material/progress-spinner"
|
|
21821
|
-
},
|
|
21822
|
-
"radio": {
|
|
21823
|
-
old: "@angular/material/legacy-radio",
|
|
21824
|
-
new: "@angular/material/radio"
|
|
21825
|
-
},
|
|
21826
|
-
"sidenav": {
|
|
21827
|
-
old: "@angular/material/legacy-sidenav",
|
|
21828
|
-
new: "@angular/material-experimental/legacy-sidenav"
|
|
21829
|
-
},
|
|
21830
|
-
"slide-toggle": {
|
|
21831
|
-
old: "@angular/material/legacy-slide-toggle",
|
|
21832
|
-
new: "@angular/material/slide-toggle"
|
|
21833
|
-
},
|
|
21834
|
-
"slider": {
|
|
21835
|
-
old: "@angular/material/legacy-slider",
|
|
21836
|
-
new: "@angular/material/slider"
|
|
21837
|
-
},
|
|
21838
|
-
"snack-bar": {
|
|
21839
|
-
old: "@angular/material/legacy-snack-bar",
|
|
21840
|
-
new: "@angular/material/snack-bar"
|
|
21841
|
-
},
|
|
21842
|
-
"table": {
|
|
21843
|
-
old: "@angular/material/legacy-table",
|
|
21844
|
-
new: "@angular/material/table"
|
|
21845
|
-
},
|
|
21846
|
-
"tabs": {
|
|
21847
|
-
old: "@angular/material/legacy-tabs",
|
|
21848
|
-
new: "@angular/material/tabs"
|
|
21849
|
-
},
|
|
21850
|
-
"paginator": {
|
|
21851
|
-
old: "@angular/material/legacy-paginator",
|
|
21852
|
-
new: "@angular/material/paginator"
|
|
21853
|
-
},
|
|
21854
|
-
"tooltip": {
|
|
21855
|
-
old: "@angular/material/legacy-tooltip",
|
|
21856
|
-
new: "@angular/material/tooltip"
|
|
21857
|
-
}
|
|
21858
|
-
};
|
|
21859
|
-
|
|
21860
|
-
// bazel-out/k8-fastbuild/bin/src/material/schematics/ng-generate/mdc-migration/rules/ts-migration/runtime-migrator.js
|
|
21861
|
-
var RuntimeMigrator = class {
|
|
21862
|
-
constructor(component) {
|
|
21863
|
-
var _a, _b;
|
|
21864
|
-
const replacements = REPLACEMENTS[component];
|
|
21865
|
-
this.oldImportModule = replacements.old;
|
|
21866
|
-
this.newImportModule = replacements.new;
|
|
21867
|
-
this.importSpecifierReplacements = this.getReplacementsFromComponentName(component);
|
|
21868
|
-
(_a = replacements.additionalMatModuleNamePrefixes) == null ? void 0 : _a.forEach((prefix) => {
|
|
21869
|
-
this.importSpecifierReplacements = this.importSpecifierReplacements.concat(this.getReplacementsFromComponentName(prefix));
|
|
21870
|
-
});
|
|
21871
|
-
(_b = replacements.customReplacements) == null ? void 0 : _b.forEach((replacement) => {
|
|
21872
|
-
this.importSpecifierReplacements = this.importSpecifierReplacements.concat(replacement);
|
|
21873
|
-
});
|
|
21874
|
-
console.log(this.importSpecifierReplacements);
|
|
21875
|
-
}
|
|
21876
|
-
getReplacementsFromComponentName(componentName) {
|
|
21877
|
-
const words = componentName.split("-");
|
|
21878
|
-
let firstLetterCapitalizedComponent = "";
|
|
21879
|
-
let capitalizedComponent = "";
|
|
21880
|
-
words.forEach((word) => {
|
|
21881
|
-
firstLetterCapitalizedComponent += word[0].toUpperCase() + word.slice(1);
|
|
21882
|
-
capitalizedComponent += word.toUpperCase() + "_";
|
|
21883
|
-
});
|
|
21884
|
-
capitalizedComponent = capitalizedComponent.slice(0, -1);
|
|
21885
|
-
const specifierReplacements = [
|
|
21886
|
-
{
|
|
21887
|
-
old: "MatLegacy" + firstLetterCapitalizedComponent,
|
|
21888
|
-
new: "Mat" + firstLetterCapitalizedComponent
|
|
21889
|
-
},
|
|
21890
|
-
{
|
|
21891
|
-
old: "MAT_LEGACY_" + capitalizedComponent,
|
|
21892
|
-
new: "MAT_" + capitalizedComponent
|
|
21893
|
-
}
|
|
21894
|
-
];
|
|
21895
|
-
return specifierReplacements;
|
|
21896
|
-
}
|
|
21897
|
-
updateImportOrExportSpecifier(specifier) {
|
|
21898
|
-
const newSpecifier = this._getNewSpecifier(specifier);
|
|
21899
|
-
if (!newSpecifier) {
|
|
21900
|
-
return null;
|
|
21901
|
-
}
|
|
21902
|
-
return ts.factory.createIdentifier(newSpecifier);
|
|
21903
|
-
}
|
|
21904
|
-
updateImportSpecifierWithPossibleAlias(importSpecifier) {
|
|
21905
|
-
var _a;
|
|
21906
|
-
const newImport = this._getNewSpecifier((_a = importSpecifier.propertyName) != null ? _a : importSpecifier.name);
|
|
21907
|
-
if (!newImport) {
|
|
21908
|
-
return null;
|
|
21909
|
-
}
|
|
21910
|
-
let newPropertyName;
|
|
21911
|
-
let newName;
|
|
21912
|
-
if (importSpecifier.propertyName && importSpecifier.name.text !== newImport) {
|
|
21913
|
-
newPropertyName = ts.factory.createIdentifier(newImport);
|
|
21914
|
-
newName = importSpecifier.name;
|
|
21915
|
-
} else {
|
|
21916
|
-
newPropertyName = void 0;
|
|
21917
|
-
newName = ts.factory.createIdentifier(newImport);
|
|
21918
|
-
}
|
|
21919
|
-
return ts.factory.createImportSpecifier(false, newPropertyName, newName);
|
|
21920
|
-
}
|
|
21921
|
-
updateModuleSpecifier(specifier) {
|
|
21922
|
-
if (specifier.text !== this.oldImportModule) {
|
|
21923
|
-
return null;
|
|
21924
|
-
}
|
|
21925
|
-
return ts.factory.createStringLiteral(this.newImportModule, this._isSingleQuoteLiteral(specifier));
|
|
21926
|
-
}
|
|
21927
|
-
_getNewSpecifier(node) {
|
|
21928
|
-
let newImport = null;
|
|
21929
|
-
this.importSpecifierReplacements.forEach((replacement) => {
|
|
21930
|
-
var _a;
|
|
21931
|
-
if ((_a = node.text) == null ? void 0 : _a.match(replacement.old)) {
|
|
21932
|
-
newImport = node.text.replace(replacement.old, replacement.new);
|
|
21933
|
-
}
|
|
21934
|
-
});
|
|
21935
|
-
return newImport;
|
|
21936
|
-
}
|
|
21937
|
-
_isSingleQuoteLiteral(literal2) {
|
|
21938
|
-
return literal2.getText()[0] !== `"`;
|
|
21939
|
-
}
|
|
21940
|
-
};
|
|
21941
|
-
|
|
21942
21881
|
// bazel-out/k8-fastbuild/bin/src/material/schematics/ng-generate/mdc-migration/rules/components/select/select-styles.js
|
|
21943
21882
|
var SelectStylesMigrator = class extends StyleMigrator {
|
|
21944
21883
|
constructor() {
|
|
@@ -22206,6 +22145,18 @@ var OptionStylesMigrator = class extends StyleMigrator {
|
|
|
22206
22145
|
{
|
|
22207
22146
|
old: "legacy-option-typography",
|
|
22208
22147
|
new: ["option-typography"]
|
|
22148
|
+
},
|
|
22149
|
+
{
|
|
22150
|
+
old: "legacy-core-theme",
|
|
22151
|
+
new: ["core-theme"]
|
|
22152
|
+
},
|
|
22153
|
+
{
|
|
22154
|
+
old: "legacy-core-color",
|
|
22155
|
+
new: ["core-color"]
|
|
22156
|
+
},
|
|
22157
|
+
{
|
|
22158
|
+
old: "legacy-core-typography",
|
|
22159
|
+
new: ["core-typography"]
|
|
22209
22160
|
}
|
|
22210
22161
|
];
|
|
22211
22162
|
this.classChanges = [
|
|
@@ -22229,104 +22180,149 @@ var OptionStylesMigrator = class extends StyleMigrator {
|
|
|
22229
22180
|
}
|
|
22230
22181
|
};
|
|
22231
22182
|
|
|
22183
|
+
// bazel-out/k8-fastbuild/bin/src/material/schematics/ng-generate/mdc-migration/rules/components/form-field/form-field-template.js
|
|
22184
|
+
var FormFieldTemplateMigrator = class extends TemplateMigrator {
|
|
22185
|
+
getUpdates(ast) {
|
|
22186
|
+
const updates = [];
|
|
22187
|
+
visitElements(ast.nodes, (node) => {
|
|
22188
|
+
if (node.name !== "mat-form-field") {
|
|
22189
|
+
return;
|
|
22190
|
+
}
|
|
22191
|
+
updates.push({
|
|
22192
|
+
offset: node.startSourceSpan.start.offset,
|
|
22193
|
+
updateFn: (html) => updateAttribute(html, node, "appearance", (old) => ["legacy", "standard"].includes(old || "") ? null : old)
|
|
22194
|
+
});
|
|
22195
|
+
});
|
|
22196
|
+
return updates;
|
|
22197
|
+
}
|
|
22198
|
+
};
|
|
22199
|
+
|
|
22232
22200
|
// bazel-out/k8-fastbuild/bin/src/material/schematics/ng-generate/mdc-migration/rules/index.js
|
|
22201
|
+
var LEGACY_MODULES = new Set([
|
|
22202
|
+
"legacy-autocomplete",
|
|
22203
|
+
"legacy-autocomplete/testing",
|
|
22204
|
+
"legacy-button",
|
|
22205
|
+
"legacy-button/testing",
|
|
22206
|
+
"legacy-card",
|
|
22207
|
+
"legacy-card/testing",
|
|
22208
|
+
"legacy-checkbox",
|
|
22209
|
+
"legacy-checkbox/testing",
|
|
22210
|
+
"legacy-chips",
|
|
22211
|
+
"legacy-chips/testing",
|
|
22212
|
+
"legacy-core",
|
|
22213
|
+
"legacy-core/testing",
|
|
22214
|
+
"legacy-dialog",
|
|
22215
|
+
"legacy-dialog/testing",
|
|
22216
|
+
"legacy-form-field",
|
|
22217
|
+
"legacy-form-field/testing",
|
|
22218
|
+
"legacy-input",
|
|
22219
|
+
"legacy-input/testing",
|
|
22220
|
+
"legacy-list",
|
|
22221
|
+
"legacy-list/testing",
|
|
22222
|
+
"legacy-menu",
|
|
22223
|
+
"legacy-menu/testing",
|
|
22224
|
+
"legacy-paginator",
|
|
22225
|
+
"legacy-paginator/testing",
|
|
22226
|
+
"legacy-progress-bar",
|
|
22227
|
+
"legacy-progress-bar/testing",
|
|
22228
|
+
"legacy-progress-spinner",
|
|
22229
|
+
"legacy-progress-spinner/testing",
|
|
22230
|
+
"legacy-radio",
|
|
22231
|
+
"legacy-radio/testing",
|
|
22232
|
+
"legacy-select",
|
|
22233
|
+
"legacy-select/testing",
|
|
22234
|
+
"legacy-slide-toggle",
|
|
22235
|
+
"legacy-slide-toggle/testing",
|
|
22236
|
+
"legacy-slider",
|
|
22237
|
+
"legacy-slider/testing",
|
|
22238
|
+
"legacy-snack-bar",
|
|
22239
|
+
"legacy-snack-bar/testing",
|
|
22240
|
+
"legacy-table",
|
|
22241
|
+
"legacy-table/testing",
|
|
22242
|
+
"legacy-tabs",
|
|
22243
|
+
"legacy-tabs/testing",
|
|
22244
|
+
"legacy-tooltip",
|
|
22245
|
+
"legacy-tooltip/testing"
|
|
22246
|
+
].map((name) => `@angular/material/${name}`));
|
|
22233
22247
|
var MIGRATORS = [
|
|
22234
22248
|
{
|
|
22235
22249
|
component: "autocomplete",
|
|
22236
|
-
styles: new AutocompleteStylesMigrator()
|
|
22237
|
-
runtime: new RuntimeMigrator("autocomplete")
|
|
22250
|
+
styles: new AutocompleteStylesMigrator()
|
|
22238
22251
|
},
|
|
22239
22252
|
{
|
|
22240
22253
|
component: "button",
|
|
22241
|
-
styles: new ButtonStylesMigrator()
|
|
22242
|
-
runtime: new RuntimeMigrator("button")
|
|
22254
|
+
styles: new ButtonStylesMigrator()
|
|
22243
22255
|
},
|
|
22244
22256
|
{
|
|
22245
22257
|
component: "card",
|
|
22246
22258
|
styles: new CardStylesMigrator(),
|
|
22247
|
-
runtime: new RuntimeMigrator("card"),
|
|
22248
22259
|
template: new CardTemplateMigrator()
|
|
22249
22260
|
},
|
|
22250
22261
|
{
|
|
22251
22262
|
component: "checkbox",
|
|
22252
|
-
styles: new CheckboxStylesMigrator()
|
|
22253
|
-
runtime: new RuntimeMigrator("checkbox")
|
|
22263
|
+
styles: new CheckboxStylesMigrator()
|
|
22254
22264
|
},
|
|
22255
22265
|
{
|
|
22256
22266
|
component: "chips",
|
|
22257
22267
|
styles: new ChipsStylesMigrator(),
|
|
22258
|
-
runtime: new RuntimeMigrator("chips"),
|
|
22259
22268
|
template: new ChipsTemplateMigrator()
|
|
22260
22269
|
},
|
|
22261
22270
|
{
|
|
22262
22271
|
component: "dialog",
|
|
22263
|
-
styles: new DialogStylesMigrator()
|
|
22264
|
-
runtime: new RuntimeMigrator("dialog")
|
|
22272
|
+
styles: new DialogStylesMigrator()
|
|
22265
22273
|
},
|
|
22266
22274
|
{
|
|
22267
22275
|
component: "form-field",
|
|
22268
22276
|
styles: new FormFieldStylesMigrator(),
|
|
22269
|
-
|
|
22277
|
+
template: new FormFieldTemplateMigrator()
|
|
22270
22278
|
},
|
|
22271
22279
|
{
|
|
22272
22280
|
component: "input",
|
|
22273
|
-
styles: new InputStylesMigrator()
|
|
22274
|
-
runtime: new RuntimeMigrator("input")
|
|
22281
|
+
styles: new InputStylesMigrator()
|
|
22275
22282
|
},
|
|
22276
22283
|
{
|
|
22277
22284
|
component: "list",
|
|
22278
|
-
styles: new ListStylesMigrator()
|
|
22279
|
-
runtime: new RuntimeMigrator("list")
|
|
22285
|
+
styles: new ListStylesMigrator()
|
|
22280
22286
|
},
|
|
22281
22287
|
{
|
|
22282
22288
|
component: "menu",
|
|
22283
|
-
styles: new MenuStylesMigrator()
|
|
22284
|
-
runtime: new RuntimeMigrator("menu")
|
|
22289
|
+
styles: new MenuStylesMigrator()
|
|
22285
22290
|
},
|
|
22286
22291
|
{
|
|
22287
22292
|
component: "optgroup",
|
|
22288
|
-
styles: new OptgroupStylesMigrator()
|
|
22289
|
-
runtime: new RuntimeMigrator("optgroup")
|
|
22293
|
+
styles: new OptgroupStylesMigrator()
|
|
22290
22294
|
},
|
|
22291
22295
|
{
|
|
22292
22296
|
component: "option",
|
|
22293
|
-
styles: new OptionStylesMigrator()
|
|
22294
|
-
runtime: new RuntimeMigrator("option")
|
|
22297
|
+
styles: new OptionStylesMigrator()
|
|
22295
22298
|
},
|
|
22296
22299
|
{
|
|
22297
22300
|
component: "paginator",
|
|
22298
|
-
styles: new PaginatorStylesMigrator()
|
|
22299
|
-
runtime: new RuntimeMigrator("paginator")
|
|
22301
|
+
styles: new PaginatorStylesMigrator()
|
|
22300
22302
|
},
|
|
22301
22303
|
{
|
|
22302
22304
|
component: "progress-bar",
|
|
22303
|
-
styles: new ProgressBarStylesMigrator()
|
|
22304
|
-
runtime: new RuntimeMigrator("progress-bar")
|
|
22305
|
+
styles: new ProgressBarStylesMigrator()
|
|
22305
22306
|
},
|
|
22306
22307
|
{
|
|
22307
22308
|
component: "progress-spinner",
|
|
22308
|
-
styles: new ProgressSpinnerStylesMigrator()
|
|
22309
|
-
runtime: new RuntimeMigrator("progress-spinner")
|
|
22309
|
+
styles: new ProgressSpinnerStylesMigrator()
|
|
22310
22310
|
},
|
|
22311
22311
|
{
|
|
22312
22312
|
component: "radio",
|
|
22313
|
-
styles: new RadioStylesMigrator()
|
|
22314
|
-
runtime: new RuntimeMigrator("radio")
|
|
22313
|
+
styles: new RadioStylesMigrator()
|
|
22315
22314
|
},
|
|
22316
22315
|
{
|
|
22317
22316
|
component: "select",
|
|
22318
|
-
styles: new SelectStylesMigrator()
|
|
22319
|
-
runtime: new RuntimeMigrator("select")
|
|
22317
|
+
styles: new SelectStylesMigrator()
|
|
22320
22318
|
},
|
|
22321
22319
|
{
|
|
22322
22320
|
component: "slide-toggle",
|
|
22323
|
-
styles: new SlideToggleStylesMigrator()
|
|
22324
|
-
runtime: new RuntimeMigrator("slide-toggle")
|
|
22321
|
+
styles: new SlideToggleStylesMigrator()
|
|
22325
22322
|
},
|
|
22326
22323
|
{
|
|
22327
22324
|
component: "slider",
|
|
22328
|
-
styles: new SliderStylesMigrator()
|
|
22329
|
-
runtime: new RuntimeMigrator("slider")
|
|
22325
|
+
styles: new SliderStylesMigrator()
|
|
22330
22326
|
},
|
|
22331
22327
|
{
|
|
22332
22328
|
component: "snack-bar",
|
|
@@ -22334,18 +22330,15 @@ var MIGRATORS = [
|
|
|
22334
22330
|
},
|
|
22335
22331
|
{
|
|
22336
22332
|
component: "table",
|
|
22337
|
-
styles: new TableStylesMigrator()
|
|
22338
|
-
runtime: new RuntimeMigrator("table")
|
|
22333
|
+
styles: new TableStylesMigrator()
|
|
22339
22334
|
},
|
|
22340
22335
|
{
|
|
22341
22336
|
component: "tabs",
|
|
22342
|
-
styles: new TabsStylesMigrator()
|
|
22343
|
-
runtime: new RuntimeMigrator("tabs")
|
|
22337
|
+
styles: new TabsStylesMigrator()
|
|
22344
22338
|
},
|
|
22345
22339
|
{
|
|
22346
22340
|
component: "tooltip",
|
|
22347
|
-
styles: new TooltipStylesMigrator()
|
|
22348
|
-
runtime: new RuntimeMigrator("tooltip")
|
|
22341
|
+
styles: new TooltipStylesMigrator()
|
|
22349
22342
|
}
|
|
22350
22343
|
];
|
|
22351
22344
|
|
|
@@ -22354,7 +22347,7 @@ var import_schematics4 = require("@angular/cdk/schematics");
|
|
|
22354
22347
|
|
|
22355
22348
|
// bazel-out/k8-fastbuild/bin/src/material/schematics/ng-generate/mdc-migration/rules/ts-migration/runtime-migration.js
|
|
22356
22349
|
var import_schematics3 = require("@angular/cdk/schematics");
|
|
22357
|
-
var
|
|
22350
|
+
var ts = __toESM(require("typescript"));
|
|
22358
22351
|
|
|
22359
22352
|
// bazel-out/k8-fastbuild/bin/src/material/schematics/ng-generate/mdc-migration/rules/theming-styles.js
|
|
22360
22353
|
var import_schematics = require("@angular/cdk/schematics");
|
|
@@ -22399,16 +22392,17 @@ var stringify3 = import_scss_syntax.default.stringify;
|
|
|
22399
22392
|
var parse3 = import_scss_syntax.default.parse;
|
|
22400
22393
|
|
|
22401
22394
|
// bazel-out/k8-fastbuild/bin/src/material/schematics/ng-generate/mdc-migration/rules/theming-styles.js
|
|
22402
|
-
var
|
|
22395
|
+
var COMPONENTS_MIXIN_NAME = /\.([^(;]*)/;
|
|
22403
22396
|
var ThemingStylesMigration = class extends import_schematics.Migration {
|
|
22404
22397
|
constructor() {
|
|
22405
22398
|
super(...arguments);
|
|
22406
22399
|
this.enabled = true;
|
|
22407
22400
|
}
|
|
22408
22401
|
visitStylesheet(stylesheet) {
|
|
22409
|
-
this.
|
|
22402
|
+
const migratedContent = this.migrate(stylesheet.content, stylesheet.filePath).replace(new RegExp(`${this.namespace}.define-legacy-typography-config\\(`, "g"), `${this.namespace}.define-typography-config(`);
|
|
22403
|
+
this.fileSystem.edit(stylesheet.filePath).remove(stylesheet.start, stylesheet.content.length).insertRight(stylesheet.start, migratedContent);
|
|
22410
22404
|
}
|
|
22411
|
-
migrate(styles) {
|
|
22405
|
+
migrate(styles, filename) {
|
|
22412
22406
|
const processor = new Processor([
|
|
22413
22407
|
{
|
|
22414
22408
|
postcssPlugin: "theming-styles-migration-plugin",
|
|
@@ -22419,7 +22413,13 @@ var ThemingStylesMigration = class extends import_schematics.Migration {
|
|
|
22419
22413
|
Rule: this.ruleHandler.bind(this)
|
|
22420
22414
|
}
|
|
22421
22415
|
]);
|
|
22422
|
-
|
|
22416
|
+
try {
|
|
22417
|
+
return processor.process(styles, { syntax: scss_syntax_exports }).toString();
|
|
22418
|
+
} catch (e) {
|
|
22419
|
+
this.context.logger.error(`${e}`);
|
|
22420
|
+
this.context.logger.warn(`Failed to process stylesheet: ${filename} (see error above).`);
|
|
22421
|
+
return styles;
|
|
22422
|
+
}
|
|
22423
22423
|
}
|
|
22424
22424
|
atUseHandler(atRule2) {
|
|
22425
22425
|
if (isAngularMaterialImport(atRule2)) {
|
|
@@ -22433,19 +22433,29 @@ var ThemingStylesMigration = class extends import_schematics.Migration {
|
|
|
22433
22433
|
if (migrator) {
|
|
22434
22434
|
const mixinChange = migrator.styles.getMixinChange(this.namespace, atRule2);
|
|
22435
22435
|
if (mixinChange) {
|
|
22436
|
-
|
|
22436
|
+
if (mixinChange.new) {
|
|
22437
|
+
replaceAtRuleWithMultiple(atRule2, mixinChange.old, mixinChange.new);
|
|
22438
|
+
} else {
|
|
22439
|
+
atRule2.remove();
|
|
22440
|
+
}
|
|
22437
22441
|
}
|
|
22438
|
-
} else if (atRule2.
|
|
22442
|
+
} else if (atRule2.parent && this.isCrossCuttingMixin(atRule2.params)) {
|
|
22439
22443
|
if (this.isPartialMigration()) {
|
|
22440
|
-
const mixinName = atRule2.params.match(
|
|
22441
|
-
const comment2 =
|
|
22444
|
+
const mixinName = atRule2.params.match(COMPONENTS_MIXIN_NAME)[1];
|
|
22445
|
+
const comment2 = `TODO(mdc-migration): Remove ${mixinName} once all legacy components are migrated`;
|
|
22442
22446
|
if (!addLegacyCommentForPartialMigrations(atRule2, comment2)) {
|
|
22443
22447
|
return;
|
|
22444
22448
|
}
|
|
22445
22449
|
}
|
|
22446
|
-
|
|
22450
|
+
replaceCrossCuttingMixin(atRule2, this.namespace);
|
|
22447
22451
|
}
|
|
22448
22452
|
}
|
|
22453
|
+
isCrossCuttingMixin(mixinText) {
|
|
22454
|
+
return [
|
|
22455
|
+
`${this.namespace}\\.all-legacy-component-`,
|
|
22456
|
+
`${this.namespace}\\.legacy-core([^-]|$)`
|
|
22457
|
+
].some((r) => new RegExp(r).test(mixinText));
|
|
22458
|
+
}
|
|
22449
22459
|
isPartialMigration() {
|
|
22450
22460
|
return this.upgradeData.length !== MIGRATORS.length;
|
|
22451
22461
|
}
|
|
@@ -22496,11 +22506,11 @@ function addCommentBeforeNode(node, comment2) {
|
|
|
22496
22506
|
node.parent.insertBefore(node, commentNode);
|
|
22497
22507
|
node.raws.before = "\n" + indentation;
|
|
22498
22508
|
}
|
|
22499
|
-
function
|
|
22500
|
-
|
|
22501
|
-
params:
|
|
22509
|
+
function replaceCrossCuttingMixin(atRule2, namespace) {
|
|
22510
|
+
atRule2.cloneBefore({
|
|
22511
|
+
params: atRule2.params.replace(`${namespace}.all-legacy-component`, `${namespace}.all-component`).replace(`${namespace}.legacy-core`, `${namespace}.core`)
|
|
22502
22512
|
});
|
|
22503
|
-
|
|
22513
|
+
atRule2.remove();
|
|
22504
22514
|
}
|
|
22505
22515
|
function replaceAtRuleWithMultiple(atRule2, textToReplace, replacements) {
|
|
22506
22516
|
var _a;
|
|
@@ -22550,37 +22560,103 @@ var RuntimeCodeMigration = class extends import_schematics3.Migration {
|
|
|
22550
22560
|
constructor() {
|
|
22551
22561
|
super(...arguments);
|
|
22552
22562
|
this.enabled = true;
|
|
22553
|
-
this._printer =
|
|
22563
|
+
this._printer = ts.createPrinter({ newLine: ts.NewLineKind.LineFeed });
|
|
22554
22564
|
this._hasPossibleTemplateMigrations = true;
|
|
22555
22565
|
}
|
|
22556
22566
|
visitNode(node) {
|
|
22557
|
-
if (
|
|
22567
|
+
if (ts.isSourceFile(node)) {
|
|
22568
|
+
this._migrateSourceFileReferences(node);
|
|
22569
|
+
} else if (this._isComponentDecorator(node)) {
|
|
22570
|
+
this._migrateComponentDecorator(node);
|
|
22571
|
+
} else if (this._isImportExpression(node)) {
|
|
22558
22572
|
this._migrateModuleSpecifier(node.arguments[0]);
|
|
22559
22573
|
} else if (this._isTypeImportExpression(node)) {
|
|
22560
22574
|
this._migrateModuleSpecifier(node.argument.literal);
|
|
22561
|
-
} else if (ts2.isImportDeclaration(node)) {
|
|
22562
|
-
this._migrateModuleSpecifier(node.moduleSpecifier, node.importClause);
|
|
22563
|
-
} else if (ts2.isDecorator(node) && (this._isNgModuleDecorator(node) || this._isComponentDecorator(node))) {
|
|
22564
|
-
this._migrateDecoratorProperties(node);
|
|
22565
22575
|
}
|
|
22566
22576
|
}
|
|
22567
|
-
|
|
22568
|
-
|
|
22577
|
+
_migrateSourceFileReferences(sourceFile) {
|
|
22578
|
+
const { importSpecifiersToNewNames, identifiersToImportSpecifiers, moduleSpecifiers } = this._findImportsToMigrate(sourceFile);
|
|
22579
|
+
[
|
|
22580
|
+
...this._renameModuleSpecifiers(moduleSpecifiers),
|
|
22581
|
+
...this._renameReferences(sourceFile, identifiersToImportSpecifiers, importSpecifiersToNewNames)
|
|
22582
|
+
].sort(([a], [b]) => b.getStart() - a.getStart()).forEach(([currentNode, newName]) => {
|
|
22583
|
+
this._printAndUpdateNode(sourceFile, currentNode, newName);
|
|
22584
|
+
});
|
|
22585
|
+
}
|
|
22586
|
+
_findImportsToMigrate(sourceFile) {
|
|
22587
|
+
var _a;
|
|
22588
|
+
const importSpecifiersToNewNames = /* @__PURE__ */ new Map();
|
|
22589
|
+
const moduleSpecifiers = /* @__PURE__ */ new Map();
|
|
22590
|
+
const identifiersToImportSpecifiers = /* @__PURE__ */ new Map();
|
|
22591
|
+
for (const statement of sourceFile.statements) {
|
|
22592
|
+
if (ts.isImportDeclaration(statement) && ts.isStringLiteral(statement.moduleSpecifier) && ((_a = statement.importClause) == null ? void 0 : _a.namedBindings) && ts.isNamedImports(statement.importClause.namedBindings) && LEGACY_MODULES.has(statement.moduleSpecifier.text)) {
|
|
22593
|
+
statement.importClause.namedBindings.elements.forEach((element) => {
|
|
22594
|
+
const oldName = (element.propertyName || element.name).text;
|
|
22595
|
+
const newName = this._removeLegacy(oldName);
|
|
22596
|
+
if (newName) {
|
|
22597
|
+
importSpecifiersToNewNames.set(element, newName);
|
|
22598
|
+
if (!element.propertyName) {
|
|
22599
|
+
identifiersToImportSpecifiers.set(oldName, element);
|
|
22600
|
+
}
|
|
22601
|
+
}
|
|
22602
|
+
});
|
|
22603
|
+
const newModuleSpecifier = this._removeLegacy(statement.moduleSpecifier.text);
|
|
22604
|
+
if (newModuleSpecifier) {
|
|
22605
|
+
moduleSpecifiers.set(statement.moduleSpecifier, newModuleSpecifier);
|
|
22606
|
+
}
|
|
22607
|
+
}
|
|
22608
|
+
}
|
|
22609
|
+
return { importSpecifiersToNewNames, identifiersToImportSpecifiers, moduleSpecifiers };
|
|
22610
|
+
}
|
|
22611
|
+
_renameReferences(sourceFile, identifiersToImportSpecifiers, importSpecifiersToNewNames) {
|
|
22612
|
+
if (importSpecifiersToNewNames.size === 0) {
|
|
22613
|
+
return [];
|
|
22614
|
+
}
|
|
22615
|
+
const replacements = [];
|
|
22616
|
+
const walk = (node) => {
|
|
22617
|
+
if (ts.isImportDeclaration(node)) {
|
|
22618
|
+
return;
|
|
22619
|
+
}
|
|
22620
|
+
if (ts.isIdentifier(node)) {
|
|
22621
|
+
const specifier = identifiersToImportSpecifiers.get(node.text);
|
|
22622
|
+
if (specifier && this._isReferenceToImport(node, specifier)) {
|
|
22623
|
+
replacements.push([node, importSpecifiersToNewNames.get(specifier)]);
|
|
22624
|
+
}
|
|
22625
|
+
}
|
|
22626
|
+
node.forEachChild(walk);
|
|
22627
|
+
};
|
|
22628
|
+
sourceFile.forEachChild(walk);
|
|
22629
|
+
importSpecifiersToNewNames.forEach((newName, specifier) => {
|
|
22630
|
+
if (specifier.propertyName) {
|
|
22631
|
+
replacements.push([
|
|
22632
|
+
specifier.name.text === newName ? specifier : specifier.propertyName,
|
|
22633
|
+
newName
|
|
22634
|
+
]);
|
|
22635
|
+
} else {
|
|
22636
|
+
replacements.push([specifier.name, newName]);
|
|
22637
|
+
}
|
|
22638
|
+
});
|
|
22639
|
+
return replacements;
|
|
22640
|
+
}
|
|
22641
|
+
_renameModuleSpecifiers(moduleSpecifiers) {
|
|
22642
|
+
const replacements = [];
|
|
22643
|
+
for (const [specifier, newName] of moduleSpecifiers.entries()) {
|
|
22644
|
+
const quoteStyle = specifier.getText()[0];
|
|
22645
|
+
replacements.push([specifier, quoteStyle + newName + quoteStyle]);
|
|
22646
|
+
}
|
|
22647
|
+
return replacements;
|
|
22648
|
+
}
|
|
22649
|
+
_migrateComponentDecorator(node) {
|
|
22650
|
+
if (!ts.isCallExpression(node.expression)) {
|
|
22569
22651
|
return;
|
|
22570
22652
|
}
|
|
22571
22653
|
const metadata = node.expression.arguments[0];
|
|
22572
|
-
if (!
|
|
22654
|
+
if (!ts.isObjectLiteralExpression(metadata)) {
|
|
22573
22655
|
return;
|
|
22574
22656
|
}
|
|
22575
22657
|
for (const prop of metadata.properties) {
|
|
22576
22658
|
if (prop.name) {
|
|
22577
22659
|
switch ((0, import_schematics3.getPropertyNameText)(prop.name)) {
|
|
22578
|
-
case "imports":
|
|
22579
|
-
this._migrateImportsAndExports(prop);
|
|
22580
|
-
break;
|
|
22581
|
-
case "exports":
|
|
22582
|
-
this._migrateImportsAndExports(prop);
|
|
22583
|
-
break;
|
|
22584
22660
|
case "styles":
|
|
22585
22661
|
this._migrateStyles(prop);
|
|
22586
22662
|
break;
|
|
@@ -22593,18 +22669,6 @@ var RuntimeCodeMigration = class extends import_schematics3.Migration {
|
|
|
22593
22669
|
}
|
|
22594
22670
|
}
|
|
22595
22671
|
}
|
|
22596
|
-
_migrateImportsAndExports(node) {
|
|
22597
|
-
node.initializer.forEachChild((specifier) => {
|
|
22598
|
-
var _a;
|
|
22599
|
-
for (const migrator of this.upgradeData) {
|
|
22600
|
-
const newSpecifier = (_a = migrator.runtime) == null ? void 0 : _a.updateImportOrExportSpecifier(specifier);
|
|
22601
|
-
if (newSpecifier) {
|
|
22602
|
-
this._printAndUpdateNode(specifier.getSourceFile(), specifier, newSpecifier);
|
|
22603
|
-
break;
|
|
22604
|
-
}
|
|
22605
|
-
}
|
|
22606
|
-
});
|
|
22607
|
-
}
|
|
22608
22672
|
_migrateStyles(node) {
|
|
22609
22673
|
if (!this._stylesMigration) {
|
|
22610
22674
|
this._stylesMigration = new ThemingStylesMigration(this.program, this.typeChecker, this.targetVersion, this.context, this.upgradeData, this.fileSystem, this.logger);
|
|
@@ -22626,7 +22690,7 @@ var RuntimeCodeMigration = class extends import_schematics3.Migration {
|
|
|
22626
22690
|
this._migratePropertyAssignment(node.initializer, this._templateMigration);
|
|
22627
22691
|
}
|
|
22628
22692
|
_migratePropertyAssignment(node, migration) {
|
|
22629
|
-
let migratedText = migration.migrate(node.text);
|
|
22693
|
+
let migratedText = migration.migrate(node.text, node.getSourceFile().fileName);
|
|
22630
22694
|
let migratedTextLines = migratedText.split("\n");
|
|
22631
22695
|
if (migratedTextLines.length > 1) {
|
|
22632
22696
|
migratedText = migratedTextLines.map((line, index2) => {
|
|
@@ -22643,56 +22707,54 @@ var RuntimeCodeMigration = class extends import_schematics3.Migration {
|
|
|
22643
22707
|
const quotation = node.getText().trimStart()[0];
|
|
22644
22708
|
migratedText = quotation + migratedText + quotation;
|
|
22645
22709
|
}
|
|
22646
|
-
this._printAndUpdateNode(node.getSourceFile(), node,
|
|
22710
|
+
this._printAndUpdateNode(node.getSourceFile(), node, ts.factory.createRegularExpressionLiteral(migratedText));
|
|
22647
22711
|
}
|
|
22648
|
-
_migrateModuleSpecifier(
|
|
22649
|
-
|
|
22650
|
-
|
|
22651
|
-
|
|
22652
|
-
|
|
22653
|
-
const importSpecifiers = importClause.namedBindings.elements;
|
|
22654
|
-
importSpecifiers.forEach((importSpecifer) => {
|
|
22655
|
-
var _a2;
|
|
22656
|
-
const newImportSpecifier = (_a2 = migrator.runtime) == null ? void 0 : _a2.updateImportSpecifierWithPossibleAlias(importSpecifer);
|
|
22657
|
-
if (newImportSpecifier) {
|
|
22658
|
-
this._printAndUpdateNode(sourceFile, importSpecifer, newImportSpecifier);
|
|
22659
|
-
}
|
|
22660
|
-
});
|
|
22661
|
-
}
|
|
22662
|
-
const newModuleSpecifier = (_b = (_a = migrator.runtime) == null ? void 0 : _a.updateModuleSpecifier(specifierLiteral)) != null ? _b : null;
|
|
22663
|
-
if (newModuleSpecifier !== null) {
|
|
22664
|
-
this._printAndUpdateNode(sourceFile, specifierLiteral, newModuleSpecifier);
|
|
22665
|
-
break;
|
|
22666
|
-
}
|
|
22712
|
+
_migrateModuleSpecifier(specifier) {
|
|
22713
|
+
const newName = this._removeLegacy(specifier.text);
|
|
22714
|
+
if (newName) {
|
|
22715
|
+
const quoteStyle = specifier.getText()[0];
|
|
22716
|
+
this._printAndUpdateNode(specifier.getSourceFile(), specifier, quoteStyle + newName + quoteStyle);
|
|
22667
22717
|
}
|
|
22668
22718
|
}
|
|
22669
|
-
|
|
22670
|
-
|
|
22671
|
-
if (!ts2.isCallExpression(call) || !ts2.isIdentifier(call.expression)) {
|
|
22719
|
+
_isComponentDecorator(node) {
|
|
22720
|
+
if (!ts.isDecorator(node)) {
|
|
22672
22721
|
return false;
|
|
22673
22722
|
}
|
|
22674
|
-
return call.expression.text === "NgModule";
|
|
22675
|
-
}
|
|
22676
|
-
_isComponentDecorator(node) {
|
|
22677
22723
|
const call = node.expression;
|
|
22678
|
-
if (!
|
|
22724
|
+
if (!ts.isCallExpression(call) || !ts.isIdentifier(call.expression)) {
|
|
22679
22725
|
return false;
|
|
22680
22726
|
}
|
|
22681
22727
|
return call.expression.text === "Component";
|
|
22682
22728
|
}
|
|
22683
22729
|
_isImportExpression(node) {
|
|
22684
|
-
return
|
|
22730
|
+
return ts.isCallExpression(node) && node.expression.kind === ts.SyntaxKind.ImportKeyword && node.arguments.length === 1 && ts.isStringLiteralLike(node.arguments[0]);
|
|
22685
22731
|
}
|
|
22686
22732
|
_isTypeImportExpression(node) {
|
|
22687
|
-
return
|
|
22733
|
+
return ts.isImportTypeNode(node) && ts.isLiteralTypeNode(node.argument) && ts.isStringLiteralLike(node.argument.literal);
|
|
22688
22734
|
}
|
|
22689
22735
|
_printAndUpdateNode(sourceFile, oldNode, newNode) {
|
|
22690
22736
|
const filePath = this.fileSystem.resolve(sourceFile.fileName);
|
|
22691
|
-
const newNodeText = this._printer.printNode(
|
|
22737
|
+
const newNodeText = typeof newNode === "string" ? newNode : this._printer.printNode(ts.EmitHint.Unspecified, newNode, sourceFile);
|
|
22692
22738
|
const start = oldNode.getStart();
|
|
22693
22739
|
const width = oldNode.getWidth();
|
|
22694
22740
|
this.fileSystem.edit(filePath).remove(start, width).insertRight(start, newNodeText);
|
|
22695
22741
|
}
|
|
22742
|
+
_isReferenceToImport(node, importSpecifier) {
|
|
22743
|
+
var _a, _b, _c, _d;
|
|
22744
|
+
if ((importSpecifier.propertyName || importSpecifier.name).text !== node.text) {
|
|
22745
|
+
return false;
|
|
22746
|
+
}
|
|
22747
|
+
const nodeSymbol = this.typeChecker.getTypeAtLocation(node).getSymbol();
|
|
22748
|
+
const importSymbol = this.typeChecker.getTypeAtLocation(importSpecifier).getSymbol();
|
|
22749
|
+
if (!nodeSymbol && !importSymbol) {
|
|
22750
|
+
return ((_b = (_a = this.typeChecker.getSymbolAtLocation(node)) == null ? void 0 : _a.declarations) == null ? void 0 : _b[0]) === importSpecifier;
|
|
22751
|
+
}
|
|
22752
|
+
return !!(((_c = nodeSymbol == null ? void 0 : nodeSymbol.declarations) == null ? void 0 : _c[0]) && ((_d = importSymbol == null ? void 0 : importSymbol.declarations) == null ? void 0 : _d[0])) && nodeSymbol.declarations[0] === importSymbol.declarations[0];
|
|
22753
|
+
}
|
|
22754
|
+
_removeLegacy(name) {
|
|
22755
|
+
const legacyRegex = /legacy[_-]?/i;
|
|
22756
|
+
return legacyRegex.test(name) ? name.replace(legacyRegex, "") : null;
|
|
22757
|
+
}
|
|
22696
22758
|
};
|
|
22697
22759
|
|
|
22698
22760
|
// bazel-out/k8-fastbuild/bin/src/material/schematics/ng-generate/mdc-migration/index.mjs
|
|
@@ -22730,10 +22792,10 @@ function getComponentsToMigrate(requested) {
|
|
|
22730
22792
|
}
|
|
22731
22793
|
return componentsToMigrate;
|
|
22732
22794
|
}
|
|
22733
|
-
function runMigrations(context, fileSystem, tsconfigPath, migrators, analyzedFiles, additionalStylesheetPaths) {
|
|
22795
|
+
function runMigrations(context, fileSystem, tsconfigPath, migrators, analyzedFiles, additionalStylesheetPaths, limitToDirectory) {
|
|
22734
22796
|
const program = import_schematics4.UpdateProject.createProgramFromTsconfig(tsconfigPath, fileSystem);
|
|
22735
22797
|
const project = new import_schematics4.UpdateProject(context, program, fileSystem, analyzedFiles, context.logger);
|
|
22736
|
-
return !project.migrate([ThemingStylesMigration, TemplateMigration, RuntimeCodeMigration], null, migrators, additionalStylesheetPaths).hasFailures;
|
|
22798
|
+
return !project.migrate([ThemingStylesMigration, TemplateMigration, RuntimeCodeMigration], null, migrators, additionalStylesheetPaths, limitToDirectory).hasFailures;
|
|
22737
22799
|
}
|
|
22738
22800
|
function mdc_migration_default(options) {
|
|
22739
22801
|
return (tree, context) => __async(this, null, function* () {
|
|
@@ -22748,8 +22810,10 @@ function mdc_migration_default(options) {
|
|
|
22748
22810
|
const analyzedFiles = /* @__PURE__ */ new Set();
|
|
22749
22811
|
const componentsToMigrate = getComponentsToMigrate(options.components);
|
|
22750
22812
|
const migrators = MIGRATORS.filter((m) => componentsToMigrate.has(m.component));
|
|
22751
|
-
let additionalStylesheetPaths = options.directory ? (0, import_schematics4.findStylesheetFiles)(tree, options.directory) : [];
|
|
22752
22813
|
let success = true;
|
|
22814
|
+
if (options.directory) {
|
|
22815
|
+
logger.info(`Limiting migration to: ${options.directory}`);
|
|
22816
|
+
}
|
|
22753
22817
|
logger.info(`Migrating components:
|
|
22754
22818
|
${[...componentsToMigrate].join("\n")}`);
|
|
22755
22819
|
for (const projectName of projectNames) {
|
|
@@ -22762,12 +22826,10 @@ ${[...componentsToMigrate].join("\n")}`);
|
|
|
22762
22826
|
logger.warn(`Skipping migration for project ${projectName}. Unable to determine 'tsconfig.json' file in workspace config.`);
|
|
22763
22827
|
continue;
|
|
22764
22828
|
}
|
|
22765
|
-
|
|
22766
|
-
additionalStylesheetPaths = (0, import_schematics4.findStylesheetFiles)(tree, project.root);
|
|
22767
|
-
}
|
|
22829
|
+
const additionalStylesheetPaths = (0, import_schematics4.findStylesheetFiles)(tree, project.root);
|
|
22768
22830
|
logger.info(`Migrating project: ${projectName}`);
|
|
22769
22831
|
for (const tsconfigPath of tsconfigPaths) {
|
|
22770
|
-
success && (success = runMigrations(context, fileSystem, tsconfigPath, migrators, analyzedFiles, additionalStylesheetPaths));
|
|
22832
|
+
success && (success = runMigrations(context, fileSystem, tsconfigPath, migrators, analyzedFiles, additionalStylesheetPaths, options.directory || void 0));
|
|
22771
22833
|
}
|
|
22772
22834
|
}
|
|
22773
22835
|
fileSystem.commitEdits();
|
|
@@ -22788,7 +22850,7 @@ ${[...componentsToMigrate].join("\n")}`);
|
|
|
22788
22850
|
* found in the LICENSE file at https://angular.io/license
|
|
22789
22851
|
*/
|
|
22790
22852
|
/**
|
|
22791
|
-
* @license Angular v15.0.0-
|
|
22853
|
+
* @license Angular v15.0.0-rc.0
|
|
22792
22854
|
* (c) 2010-2022 Google LLC. https://angular.io/
|
|
22793
22855
|
* License: MIT
|
|
22794
22856
|
*/
|