@skyux/packages 15.0.0-alpha.0 → 15.0.0-alpha.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/collection.json +9 -0
- package/migrations.json +26 -16
- package/package.json +70 -71
- package/src/schematics/migrations/all/migrate-dragula-polyfill/migrate-dragula-polyfill.schematic.d.ts +9 -0
- package/src/schematics/migrations/all/migrate-dragula-polyfill/migrate-dragula-polyfill.schematic.js +102 -0
- package/src/schematics/migrations/all/migrate-dragula-polyfill/migrate-dragula-polyfill.schematic.js.map +1 -0
- package/src/schematics/migrations/{update-14/remove-dragula/remove-dragula.d.ts → update-15/add-compat-stylesheets/add-compat-stylesheet.schematic.d.ts} +0 -3
- package/src/schematics/migrations/update-15/add-compat-stylesheets/add-compat-stylesheet.schematic.js +140 -0
- package/src/schematics/migrations/update-15/add-compat-stylesheets/add-compat-stylesheet.schematic.js.map +1 -0
- package/src/schematics/migrations/update-15/legacy-i18n-services/legacy-i18n-services.schematic.d.ts +7 -0
- package/src/schematics/migrations/update-15/legacy-i18n-services/legacy-i18n-services.schematic.js +59 -0
- package/src/schematics/migrations/update-15/legacy-i18n-services/legacy-i18n-services.schematic.js.map +1 -0
- package/src/schematics/migrations/update-15/migrate-sdk-testing-imports/migrate-sdk-testing-imports.schematic.d.ts +8 -0
- package/src/schematics/migrations/update-15/migrate-sdk-testing-imports/migrate-sdk-testing-imports.schematic.js +58 -0
- package/src/schematics/migrations/update-15/migrate-sdk-testing-imports/migrate-sdk-testing-imports.schematic.js.map +1 -0
- package/src/schematics/migrations/update-15/remove-timepicker-retain-invalid-values/remove-timepicker-retain-invalid-values.schematic.d.ts +6 -0
- package/src/schematics/migrations/update-15/remove-timepicker-retain-invalid-values/remove-timepicker-retain-invalid-values.schematic.js +71 -0
- package/src/schematics/migrations/update-15/remove-timepicker-retain-invalid-values/remove-timepicker-retain-invalid-values.schematic.js.map +1 -0
- package/src/schematics/ng-generate/convert-grid-to-data-grid/convert-grid-to-data-grid.schematic.d.ts +6 -0
- package/src/schematics/ng-generate/convert-grid-to-data-grid/convert-grid-to-data-grid.schematic.js +15 -0
- package/src/schematics/ng-generate/convert-grid-to-data-grid/convert-grid-to-data-grid.schematic.js.map +1 -0
- package/src/schematics/ng-generate/convert-grid-to-data-grid/schema.d.ts +9 -0
- package/src/schematics/{migrations/update-14/replace-deprecated-css-vars-and-classes/types/public-api-token.js → ng-generate/convert-grid-to-data-grid/schema.js} +1 -1
- package/src/schematics/ng-generate/convert-grid-to-data-grid/schema.js.map +1 -0
- package/src/schematics/ng-generate/convert-grid-to-data-grid/schema.json +13 -0
- package/src/schematics/ng-generate/migrate-karma-to-vitest/migrate-karma-to-vitest.schematic.d.ts +7 -0
- package/src/schematics/ng-generate/migrate-karma-to-vitest/migrate-karma-to-vitest.schematic.js +121 -0
- package/src/schematics/ng-generate/migrate-karma-to-vitest/migrate-karma-to-vitest.schematic.js.map +1 -0
- package/src/schematics/ng-generate/standalone/standalone.schematic.js +1 -1
- package/src/schematics/ng-generate/standalone/standalone.schematic.js.map +1 -1
- package/src/schematics/rules/convert-grid-to-data-grid/convert-grid-to-data-grid.d.ts +2 -0
- package/src/schematics/rules/convert-grid-to-data-grid/convert-grid-to-data-grid.js +545 -0
- package/src/schematics/rules/convert-grid-to-data-grid/convert-grid-to-data-grid.js.map +1 -0
- package/src/schematics/rules/convert-page-summary-to-page-header/convert-page-summary-to-page-header.js +1 -1
- package/src/schematics/rules/convert-progress-indicator-wizard-to-tab-wizard/convert-progress-indicator-wizard-to-tab-wizard.js +3 -3
- package/src/schematics/rules/convert-progress-indicator-wizard-to-tab-wizard/convert-progress-indicator-wizard-to-tab-wizard.js.map +1 -1
- package/src/schematics/utility/template.d.ts +1 -0
- package/src/schematics/utility/template.js +12 -0
- package/src/schematics/utility/template.js.map +1 -1
- package/src/schematics/utility/typescript/combine-imports.d.ts +7 -0
- package/src/schematics/utility/typescript/combine-imports.js +52 -0
- package/src/schematics/utility/typescript/combine-imports.js.map +1 -0
- package/src/schematics/utility/typescript/imports.d.ts +25 -0
- package/src/schematics/utility/typescript/imports.js +59 -0
- package/src/schematics/utility/typescript/imports.js.map +1 -0
- package/src/schematics/utility/typescript/ng-ast.d.ts +1 -1
- package/src/schematics/utility/typescript/ng-ast.js +2 -1
- package/src/schematics/utility/typescript/ng-ast.js.map +1 -1
- package/src/schematics/utility/typescript/remove-class-reference.d.ts +15 -0
- package/src/schematics/utility/typescript/remove-class-reference.js +67 -0
- package/src/schematics/utility/typescript/remove-class-reference.js.map +1 -0
- package/src/schematics/utility/typescript/remove-import.js +39 -25
- package/src/schematics/utility/typescript/remove-import.js.map +1 -1
- package/src/schematics/utility/typescript/swap-imported-class.d.ts +1 -1
- package/src/schematics/utility/typescript/swap-imported-class.js +82 -32
- package/src/schematics/utility/typescript/swap-imported-class.js.map +1 -1
- package/src/schematics/utility/visit-project-files.js +7 -1
- package/src/schematics/utility/visit-project-files.js.map +1 -1
- package/src/version.js +1 -1
- package/src/polyfills.js +0 -6
- package/src/schematics/migrations/update-14/remove-dragula/remove-dragula.js +0 -98
- package/src/schematics/migrations/update-14/remove-dragula/remove-dragula.js.map +0 -1
- package/src/schematics/migrations/update-14/replace-deprecated-css-vars-and-classes/replace-deprecated-css-vars-and-classes.d.ts +0 -23
- package/src/schematics/migrations/update-14/replace-deprecated-css-vars-and-classes/replace-deprecated-css-vars-and-classes.js +0 -106
- package/src/schematics/migrations/update-14/replace-deprecated-css-vars-and-classes/replace-deprecated-css-vars-and-classes.js.map +0 -1
- package/src/schematics/migrations/update-14/replace-deprecated-css-vars-and-classes/types/public-api-style-group.d.ts +0 -8
- package/src/schematics/migrations/update-14/replace-deprecated-css-vars-and-classes/types/public-api-style-group.js +0 -3
- package/src/schematics/migrations/update-14/replace-deprecated-css-vars-and-classes/types/public-api-style-group.js.map +0 -1
- package/src/schematics/migrations/update-14/replace-deprecated-css-vars-and-classes/types/public-api-style.d.ts +0 -10
- package/src/schematics/migrations/update-14/replace-deprecated-css-vars-and-classes/types/public-api-style.js +0 -3
- package/src/schematics/migrations/update-14/replace-deprecated-css-vars-and-classes/types/public-api-style.js.map +0 -1
- package/src/schematics/migrations/update-14/replace-deprecated-css-vars-and-classes/types/public-api-styles.d.ts +0 -6
- package/src/schematics/migrations/update-14/replace-deprecated-css-vars-and-classes/types/public-api-styles.js +0 -3
- package/src/schematics/migrations/update-14/replace-deprecated-css-vars-and-classes/types/public-api-styles.js.map +0 -1
- package/src/schematics/migrations/update-14/replace-deprecated-css-vars-and-classes/types/public-api-token-group.d.ts +0 -7
- package/src/schematics/migrations/update-14/replace-deprecated-css-vars-and-classes/types/public-api-token-group.js +0 -3
- package/src/schematics/migrations/update-14/replace-deprecated-css-vars-and-classes/types/public-api-token-group.js.map +0 -1
- package/src/schematics/migrations/update-14/replace-deprecated-css-vars-and-classes/types/public-api-token.d.ts +0 -9
- package/src/schematics/migrations/update-14/replace-deprecated-css-vars-and-classes/types/public-api-token.js.map +0 -1
- package/src/schematics/migrations/update-14/replace-deprecated-css-vars-and-classes/types/public-api-tokens.d.ts +0 -6
- package/src/schematics/migrations/update-14/replace-deprecated-css-vars-and-classes/types/public-api-tokens.js +0 -3
- package/src/schematics/migrations/update-14/replace-deprecated-css-vars-and-classes/types/public-api-tokens.js.map +0 -1
- package/src/schematics/migrations/update-14/uninstall-prettier-schematics/uninstall-prettier-schematics.d.ts +0 -2
- package/src/schematics/migrations/update-14/uninstall-prettier-schematics/uninstall-prettier-schematics.js +0 -8
- package/src/schematics/migrations/update-14/uninstall-prettier-schematics/uninstall-prettier-schematics.js.map +0 -1
package/collection.json
CHANGED
|
@@ -26,11 +26,20 @@
|
|
|
26
26
|
"factory": "./src/schematics/ng-generate/convert-page-summary-to-page-header/convert-page-summary-to-page-header.schematic",
|
|
27
27
|
"schema": "./src/schematics/ng-generate/convert-page-summary-to-page-header/schema.json"
|
|
28
28
|
},
|
|
29
|
+
"convert-grid-to-data-grid": {
|
|
30
|
+
"description": "Convert <sky-grid> components to <sky-data-grid> components.",
|
|
31
|
+
"factory": "./src/schematics/ng-generate/convert-grid-to-data-grid/convert-grid-to-data-grid.schematic",
|
|
32
|
+
"schema": "./src/schematics/ng-generate/convert-grid-to-data-grid/schema.json"
|
|
33
|
+
},
|
|
29
34
|
"convert-progress-indicator-wizard-to-tab-wizard": {
|
|
30
35
|
"description": "Convert <sky-progress-indicator> components using wizard to use <sky-tabset> components.",
|
|
31
36
|
"factory": "./src/schematics/ng-generate/convert-progress-indicator-wizard-to-tab-wizard/convert-progress-indicator-wizard-to-tab-wizard.schematic",
|
|
32
37
|
"schema": "./src/schematics/ng-generate/convert-progress-indicator-wizard-to-tab-wizard/schema.json"
|
|
33
38
|
},
|
|
39
|
+
"migrate-karma-to-vitest": {
|
|
40
|
+
"description": "Replace the @skyux-sdk/testing Jasmine matchers with the @skyux-sdk/vitest matchers.",
|
|
41
|
+
"factory": "./src/schematics/ng-generate/migrate-karma-to-vitest/migrate-karma-to-vitest.schematic"
|
|
42
|
+
},
|
|
34
43
|
"remove-compat-stylesheets": {
|
|
35
44
|
"description": "Remove SKY UX compatibility stylesheets.",
|
|
36
45
|
"factory": "./src/schematics/ng-generate/remove-compat-stylesheets/remove-compat-stylesheets.schematic",
|
package/migrations.json
CHANGED
|
@@ -1,39 +1,49 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schematics": {
|
|
3
3
|
"noop": {
|
|
4
|
-
"version": "15.0.0-alpha.
|
|
4
|
+
"version": "15.0.0-alpha.10",
|
|
5
5
|
"factory": "./src/schematics/migrations/all/noop/noop.schematic",
|
|
6
6
|
"description": "Update all SKY UX component packages"
|
|
7
7
|
},
|
|
8
8
|
"i18n-resources-module": {
|
|
9
|
-
"version": "15.0.0-alpha.
|
|
9
|
+
"version": "15.0.0-alpha.10",
|
|
10
10
|
"factory": "./src/schematics/migrations/all/i18n-resources-module/i18n-resources-module.schematic",
|
|
11
11
|
"description": "Regenerate i18n resources modules for libraries."
|
|
12
12
|
},
|
|
13
13
|
"remove-old-compat-stylesheets": {
|
|
14
|
-
"version": "
|
|
14
|
+
"version": "15.0.0-alpha.10",
|
|
15
15
|
"factory": "./src/schematics/migrations/all/remove-old-compat-stylesheets/remove-old-compat-stylesheets.schematic",
|
|
16
16
|
"description": "Remove backward compatible stylesheets for older versions of SKY UX."
|
|
17
17
|
},
|
|
18
18
|
"workspace-check": {
|
|
19
|
-
"version": "
|
|
19
|
+
"version": "15.0.0-alpha.10",
|
|
20
20
|
"factory": "./src/schematics/migrations/all/workspace-check/workspace-check.schematic",
|
|
21
21
|
"description": "Log warnings if the workspace is not configured correctly."
|
|
22
22
|
},
|
|
23
|
-
"
|
|
24
|
-
"version": "
|
|
25
|
-
"factory": "./src/schematics/migrations/
|
|
26
|
-
"description": "
|
|
23
|
+
"migrate-dragula-polyfill": {
|
|
24
|
+
"version": "15.0.0-alpha.10",
|
|
25
|
+
"factory": "./src/schematics/migrations/all/migrate-dragula-polyfill/migrate-dragula-polyfill.schematic",
|
|
26
|
+
"description": "Remove the @skyux/packages/polyfills entry from project config, replacing it with a local copy when Dragula is still installed."
|
|
27
27
|
},
|
|
28
|
-
"remove-
|
|
29
|
-
"version": "
|
|
30
|
-
"factory": "./src/schematics/migrations/update-
|
|
31
|
-
"description": "Remove
|
|
28
|
+
"remove-timepicker-retain-invalid-values": {
|
|
29
|
+
"version": "15.0.0-alpha.10",
|
|
30
|
+
"factory": "./src/schematics/migrations/update-15/remove-timepicker-retain-invalid-values/remove-timepicker-retain-invalid-values.schematic",
|
|
31
|
+
"description": "Remove the skyTimepickerRetainInvalidValues input from timepicker inputs since retaining invalid values is now the default behavior."
|
|
32
32
|
},
|
|
33
|
-
"
|
|
34
|
-
"version": "
|
|
35
|
-
"factory": "./src/schematics/migrations/update-
|
|
36
|
-
"description": "
|
|
33
|
+
"add-compat-stylesheets": {
|
|
34
|
+
"version": "15.0.0-alpha.10",
|
|
35
|
+
"factory": "./src/schematics/migrations/update-15/add-compat-stylesheets/add-compat-stylesheet.schematic",
|
|
36
|
+
"description": "Add a backwards-compatible stylesheet with styles that have been removed from components in SKY UX 15."
|
|
37
|
+
},
|
|
38
|
+
"migrate-sdk-testing-imports": {
|
|
39
|
+
"version": "15.0.0-alpha.10",
|
|
40
|
+
"factory": "./src/schematics/migrations/update-15/migrate-sdk-testing-imports/migrate-sdk-testing-imports.schematic",
|
|
41
|
+
"description": "Move SkyAppTestUtility, SkyAppTestUtilityDomEventOptions, and SkyBy imports from the deprecated @skyux-sdk/testing package to @skyux/core/testing."
|
|
42
|
+
},
|
|
43
|
+
"legacy-i18n-services": {
|
|
44
|
+
"version": "15.0.0-alpha.10",
|
|
45
|
+
"factory": "./src/schematics/migrations/update-15/legacy-i18n-services/legacy-i18n-services.schematic",
|
|
46
|
+
"description": "Replace SkyAppResourcesService and SkyLibResourcesService with their legacy equivalents since the originals now emit whenever the locale changes."
|
|
37
47
|
}
|
|
38
48
|
}
|
|
39
49
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@skyux/packages",
|
|
3
|
-
"version": "15.0.0-alpha.
|
|
3
|
+
"version": "15.0.0-alpha.10",
|
|
4
4
|
"author": "Blackbaud, Inc.",
|
|
5
5
|
"description": "Handles the `ng update` command for SKY UX component libraries.",
|
|
6
6
|
"keywords": [
|
|
@@ -23,9 +23,6 @@
|
|
|
23
23
|
},
|
|
24
24
|
"./package.json": {
|
|
25
25
|
"default": "./package.json"
|
|
26
|
-
},
|
|
27
|
-
"./polyfills": {
|
|
28
|
-
"default": "./src/polyfills.js"
|
|
29
26
|
}
|
|
30
27
|
},
|
|
31
28
|
"schematics": "./collection.json",
|
|
@@ -35,84 +32,86 @@
|
|
|
35
32
|
"ng-update": {
|
|
36
33
|
"migrations": "./migrations.json",
|
|
37
34
|
"packageGroup": {
|
|
38
|
-
"@skyux/packages": "15.0.0-alpha.
|
|
35
|
+
"@skyux/packages": "15.0.0-alpha.10",
|
|
39
36
|
"@blackbaud/angular-tree-component": "^1.0.0",
|
|
40
|
-
"@skyux-sdk/eslint-schematics": "15.0.0-alpha.
|
|
41
|
-
"@skyux-sdk/stylelint-schematics": "15.0.0-alpha.
|
|
42
|
-
"@skyux-sdk/testing": "15.0.0-alpha.
|
|
43
|
-
"@skyux-sdk/testing-schematics": "15.0.0-alpha.
|
|
44
|
-
"@skyux/
|
|
45
|
-
"@skyux/
|
|
46
|
-
"@skyux/
|
|
47
|
-
"@skyux/
|
|
48
|
-
"@skyux/
|
|
49
|
-
"@skyux/
|
|
50
|
-
"@skyux/
|
|
51
|
-
"@skyux/
|
|
52
|
-
"@skyux/
|
|
53
|
-
"@skyux/
|
|
54
|
-
"@skyux/
|
|
55
|
-
"@skyux/
|
|
56
|
-
"@skyux/
|
|
57
|
-
"@skyux/
|
|
58
|
-
"@skyux/
|
|
59
|
-
"@skyux/
|
|
60
|
-
"@skyux/
|
|
61
|
-
"@skyux/
|
|
62
|
-
"@skyux/
|
|
63
|
-
"@skyux/
|
|
64
|
-
"@skyux/
|
|
65
|
-
"@skyux/
|
|
66
|
-
"@skyux/
|
|
67
|
-
"@skyux/
|
|
68
|
-
"@skyux/
|
|
69
|
-
"@skyux/
|
|
70
|
-
"@skyux/
|
|
71
|
-
"@skyux/
|
|
72
|
-
"@skyux/
|
|
73
|
-
"@skyux/
|
|
74
|
-
"@skyux/list-builder
|
|
75
|
-
"@skyux/
|
|
76
|
-
"@skyux/
|
|
77
|
-
"@skyux/
|
|
78
|
-
"@skyux/
|
|
79
|
-
"@skyux/
|
|
80
|
-
"@skyux/
|
|
81
|
-
"@skyux/
|
|
82
|
-
"@skyux/
|
|
83
|
-
"@skyux/
|
|
84
|
-
"@skyux/
|
|
85
|
-
"@skyux/
|
|
86
|
-
"@skyux/
|
|
87
|
-
"@skyux/
|
|
88
|
-
"@skyux/
|
|
89
|
-
"@skyux/
|
|
90
|
-
"@skyux/
|
|
91
|
-
"@skyux/
|
|
92
|
-
"@skyux/
|
|
93
|
-
"
|
|
94
|
-
"
|
|
95
|
-
"ag-grid-
|
|
96
|
-
"
|
|
97
|
-
"
|
|
98
|
-
"
|
|
99
|
-
"skyux
|
|
100
|
-
"
|
|
37
|
+
"@skyux-sdk/eslint-schematics": "15.0.0-alpha.10",
|
|
38
|
+
"@skyux-sdk/stylelint-schematics": "15.0.0-alpha.10",
|
|
39
|
+
"@skyux-sdk/testing": "15.0.0-alpha.10",
|
|
40
|
+
"@skyux-sdk/testing-schematics": "15.0.0-alpha.10",
|
|
41
|
+
"@skyux-sdk/vitest": "15.0.0-alpha.10",
|
|
42
|
+
"@skyux/a11y": "15.0.0-alpha.10",
|
|
43
|
+
"@skyux/action-bars": "15.0.0-alpha.10",
|
|
44
|
+
"@skyux/ag-grid": "15.0.0-alpha.10",
|
|
45
|
+
"@skyux/angular-tree-component": "15.0.0-alpha.10",
|
|
46
|
+
"@skyux/animations": "15.0.0-alpha.10",
|
|
47
|
+
"@skyux/assets": "15.0.0-alpha.10",
|
|
48
|
+
"@skyux/autonumeric": "15.0.0-alpha.10",
|
|
49
|
+
"@skyux/avatar": "15.0.0-alpha.10",
|
|
50
|
+
"@skyux/charts": "15.0.0-alpha.10",
|
|
51
|
+
"@skyux/code-examples": "15.0.0-alpha.10",
|
|
52
|
+
"@skyux/colorpicker": "15.0.0-alpha.10",
|
|
53
|
+
"@skyux/config": "15.0.0-alpha.10",
|
|
54
|
+
"@skyux/core": "15.0.0-alpha.10",
|
|
55
|
+
"@skyux/data-grid": "15.0.0-alpha.10",
|
|
56
|
+
"@skyux/data-manager": "15.0.0-alpha.10",
|
|
57
|
+
"@skyux/datetime": "15.0.0-alpha.10",
|
|
58
|
+
"@skyux/docs-tools": "15.0.0-alpha.10",
|
|
59
|
+
"@skyux/errors": "15.0.0-alpha.10",
|
|
60
|
+
"@skyux/filter-bar": "15.0.0-alpha.10",
|
|
61
|
+
"@skyux/flyout": "15.0.0-alpha.10",
|
|
62
|
+
"@skyux/forms": "15.0.0-alpha.10",
|
|
63
|
+
"@skyux/grids": "15.0.0-alpha.10",
|
|
64
|
+
"@skyux/help-inline": "15.0.0-alpha.10",
|
|
65
|
+
"@skyux/i18n": "15.0.0-alpha.10",
|
|
66
|
+
"@skyux/icon": "15.0.0-alpha.10",
|
|
67
|
+
"@skyux/icons": "^11.4.0",
|
|
68
|
+
"@skyux/indicators": "15.0.0-alpha.10",
|
|
69
|
+
"@skyux/inline-form": "15.0.0-alpha.10",
|
|
70
|
+
"@skyux/layout": "15.0.0-alpha.10",
|
|
71
|
+
"@skyux/list-builder": "15.0.0-alpha.10",
|
|
72
|
+
"@skyux/list-builder-common": "15.0.0-alpha.10",
|
|
73
|
+
"@skyux/list-builder-view-checklist": "15.0.0-alpha.10",
|
|
74
|
+
"@skyux/list-builder-view-grids": "15.0.0-alpha.10",
|
|
75
|
+
"@skyux/lists": "15.0.0-alpha.10",
|
|
76
|
+
"@skyux/lookup": "15.0.0-alpha.10",
|
|
77
|
+
"@skyux/manifest": "15.0.0-alpha.10",
|
|
78
|
+
"@skyux/modals": "15.0.0-alpha.10",
|
|
79
|
+
"@skyux/navbar": "15.0.0-alpha.10",
|
|
80
|
+
"@skyux/pages": "15.0.0-alpha.10",
|
|
81
|
+
"@skyux/phone-field": "15.0.0-alpha.10",
|
|
82
|
+
"@skyux/popovers": "15.0.0-alpha.10",
|
|
83
|
+
"@skyux/progress-indicator": "15.0.0-alpha.10",
|
|
84
|
+
"@skyux/router": "15.0.0-alpha.10",
|
|
85
|
+
"@skyux/split-view": "15.0.0-alpha.10",
|
|
86
|
+
"@skyux/tabs": "15.0.0-alpha.10",
|
|
87
|
+
"@skyux/text-editor": "15.0.0-alpha.10",
|
|
88
|
+
"@skyux/theme": "15.0.0-alpha.10",
|
|
89
|
+
"@skyux/tiles": "15.0.0-alpha.10",
|
|
90
|
+
"@skyux/toast": "15.0.0-alpha.10",
|
|
91
|
+
"@skyux/validation": "15.0.0-alpha.10",
|
|
92
|
+
"ag-grid-angular": "^36.1.0",
|
|
93
|
+
"ag-grid-community": "^36.1.0",
|
|
94
|
+
"ag-grid-enterprise": "^36.0.2",
|
|
95
|
+
"autonumeric": "^4.10.10",
|
|
96
|
+
"eslint-config-skyux": "15.0.0-alpha.10",
|
|
97
|
+
"skyux-eslint": "15.0.0-alpha.10",
|
|
98
|
+
"skyux-stylelint": "15.0.0-alpha.10",
|
|
99
|
+
"stylelint-config-skyux": "15.0.0-alpha.10"
|
|
101
100
|
}
|
|
102
101
|
},
|
|
103
102
|
"peerDependencies": {
|
|
104
|
-
"@angular/cli": "^22.
|
|
105
|
-
"@angular/core": "^22.
|
|
103
|
+
"@angular/cli": "^22.1.4",
|
|
104
|
+
"@angular/core": "^22.1.2",
|
|
106
105
|
"typescript": "^6.0.3"
|
|
107
106
|
},
|
|
108
107
|
"dependencies": {
|
|
109
|
-
"@blackbaud/skyux-design-tokens": "
|
|
110
|
-
"fs-extra": "11.3.
|
|
108
|
+
"@blackbaud/skyux-design-tokens": "7.0.0-alpha.10",
|
|
109
|
+
"fs-extra": "11.3.6",
|
|
111
110
|
"jsonc-parser": "3.3.1",
|
|
112
111
|
"parse5": "7.3.0",
|
|
113
112
|
"tslib": "^2.8.1"
|
|
114
113
|
},
|
|
115
|
-
"sideEffects":
|
|
114
|
+
"sideEffects": false,
|
|
116
115
|
"main": "./src/index.js",
|
|
117
116
|
"types": "./src/index.d.ts",
|
|
118
117
|
"type": "commonjs"
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { Rule } from '@angular-devkit/schematics';
|
|
2
|
+
/**
|
|
3
|
+
* Removes the \`@skyux/packages/polyfills\` entry from every project's build
|
|
4
|
+
* and test options and their configurations. When Dragula is still installed
|
|
5
|
+
* (directly or transitively) — or when its usage cannot be determined — the
|
|
6
|
+
* entry is replaced with a local copy of the polyfill so those consumers keep
|
|
7
|
+
* working without depending on \`@skyux/packages/polyfills\`.
|
|
8
|
+
*/
|
|
9
|
+
export default function migrateDragulaPolyfill(): Rule;
|
package/src/schematics/migrations/all/migrate-dragula-polyfill/migrate-dragula-polyfill.schematic.js
ADDED
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.default = migrateDragulaPolyfill;
|
|
4
|
+
const utility_1 = require("@schematics/angular/utility");
|
|
5
|
+
const workspace_1 = require("../../../utility/workspace");
|
|
6
|
+
const PACKAGES_POLYFILL = '@skyux/packages/polyfills';
|
|
7
|
+
const LOCAL_POLYFILL_FILENAME = 'dragula-polyfill.js';
|
|
8
|
+
const LOCAL_POLYFILL_CONTENT = `'use strict';
|
|
9
|
+
|
|
10
|
+
// Fix for crossvent \`global is not defined\` error. The crossvent library is used by Dragula,
|
|
11
|
+
// which in turn is used by some third-party libraries.
|
|
12
|
+
// https://github.com/bevacqua/dragula/issues/602
|
|
13
|
+
window.global = window;
|
|
14
|
+
`;
|
|
15
|
+
/**
|
|
16
|
+
* Removes the \`@skyux/packages/polyfills\` entry from every project's build
|
|
17
|
+
* and test options and their configurations. When Dragula is still installed
|
|
18
|
+
* (directly or transitively) — or when its usage cannot be determined — the
|
|
19
|
+
* entry is replaced with a local copy of the polyfill so those consumers keep
|
|
20
|
+
* working without depending on \`@skyux/packages/polyfills\`.
|
|
21
|
+
*/
|
|
22
|
+
function migrateDragulaPolyfill() {
|
|
23
|
+
return (tree, context) => {
|
|
24
|
+
const dragulaNeeded = isDragulaNeeded(tree, context);
|
|
25
|
+
return (0, utility_1.updateWorkspace)((workspace) => {
|
|
26
|
+
for (const project of workspace.projects.values()) {
|
|
27
|
+
migrateProjectPolyfills(tree, project, dragulaNeeded);
|
|
28
|
+
}
|
|
29
|
+
});
|
|
30
|
+
};
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* Migrates the \`@skyux/packages/polyfills\` entry out of a single project's
|
|
34
|
+
* build and test options and every configuration of each.
|
|
35
|
+
*/
|
|
36
|
+
function migrateProjectPolyfills(tree, project, dragulaNeeded) {
|
|
37
|
+
const localPolyfillPath = `${(0, workspace_1.getSourceRoot)(project)}/${LOCAL_POLYFILL_FILENAME}`;
|
|
38
|
+
// Polyfills can be set on the target options and overridden per configuration.
|
|
39
|
+
const optionSets = ['build', 'test'].flatMap((targetName) => {
|
|
40
|
+
const target = project.targets.get(targetName);
|
|
41
|
+
return [target?.options, ...Object.values(target?.configurations ?? {})];
|
|
42
|
+
});
|
|
43
|
+
for (const options of optionSets) {
|
|
44
|
+
const polyfills = options?.['polyfills'];
|
|
45
|
+
if (!Array.isArray(polyfills)) {
|
|
46
|
+
continue;
|
|
47
|
+
}
|
|
48
|
+
const index = polyfills.indexOf(PACKAGES_POLYFILL);
|
|
49
|
+
if (index === -1) {
|
|
50
|
+
continue;
|
|
51
|
+
}
|
|
52
|
+
if (dragulaNeeded) {
|
|
53
|
+
if (!tree.exists(localPolyfillPath)) {
|
|
54
|
+
tree.create(localPolyfillPath, LOCAL_POLYFILL_CONTENT);
|
|
55
|
+
}
|
|
56
|
+
polyfills.splice(index, 1, localPolyfillPath);
|
|
57
|
+
}
|
|
58
|
+
else {
|
|
59
|
+
polyfills.splice(index, 1);
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
/**
|
|
64
|
+
* Determines whether the local polyfill shim should be retained. Returns \`true\`
|
|
65
|
+
* when Dragula is installed, and — conservatively — also when its usage cannot
|
|
66
|
+
* be determined (missing, malformed, or unsupported \`package-lock.json\`), so a
|
|
67
|
+
* broken \`@skyux/packages/polyfills\` reference is never left behind.
|
|
68
|
+
*/
|
|
69
|
+
function isDragulaNeeded(tree, context) {
|
|
70
|
+
const buffer = tree.read('package-lock.json');
|
|
71
|
+
if (!buffer) {
|
|
72
|
+
context.logger.warn('A "package-lock.json" file was not found; retaining a local copy of ' +
|
|
73
|
+
`"${PACKAGES_POLYFILL}" because Dragula usage could not be determined.`);
|
|
74
|
+
return true;
|
|
75
|
+
}
|
|
76
|
+
let lockFile;
|
|
77
|
+
try {
|
|
78
|
+
lockFile = JSON.parse(buffer.toString());
|
|
79
|
+
}
|
|
80
|
+
catch {
|
|
81
|
+
context.logger.warn('The "package-lock.json" file could not be parsed; retaining a local ' +
|
|
82
|
+
`copy of "${PACKAGES_POLYFILL}" because Dragula usage could not be ` +
|
|
83
|
+
'determined.');
|
|
84
|
+
return true;
|
|
85
|
+
}
|
|
86
|
+
if (!lockFile.packages) {
|
|
87
|
+
context.logger.warn('The "package-lock.json" file uses an unsupported lockfile version; ' +
|
|
88
|
+
`retaining a local copy of "${PACKAGES_POLYFILL}" because Dragula ` +
|
|
89
|
+
'usage could not be determined.');
|
|
90
|
+
return true;
|
|
91
|
+
}
|
|
92
|
+
return isDragulaInstalled(lockFile.packages);
|
|
93
|
+
}
|
|
94
|
+
/**
|
|
95
|
+
* Determines whether Dragula is installed anywhere in the dependency tree by
|
|
96
|
+
* checking every package path recorded in the lockfile.
|
|
97
|
+
*/
|
|
98
|
+
function isDragulaInstalled(packages) {
|
|
99
|
+
return Object.keys(packages).some((packagePath) => packagePath === 'node_modules/dragula' ||
|
|
100
|
+
packagePath.endsWith('/node_modules/dragula'));
|
|
101
|
+
}
|
|
102
|
+
//# sourceMappingURL=migrate-dragula-polyfill.schematic.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"migrate-dragula-polyfill.schematic.js","sourceRoot":"","sources":["../../../../../../../../../libs/components/packages/src/schematics/migrations/all/migrate-dragula-polyfill/migrate-dragula-polyfill.schematic.ts"],"names":[],"mappings":";;AAyBA,yCAUC;AAlCD,yDAGqC;AAErC,0DAA2D;AAE3D,MAAM,iBAAiB,GAAG,2BAA2B,CAAC;AACtD,MAAM,uBAAuB,GAAG,qBAAqB,CAAC;AACtD,MAAM,sBAAsB,GAAG;;;;;;CAM9B,CAAC;AAEF;;;;;;GAMG;AACH,SAAwB,sBAAsB;IAC5C,OAAO,CAAC,IAAI,EAAE,OAAO,EAAE,EAAE;QACvB,MAAM,aAAa,GAAG,eAAe,CAAC,IA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C,WAAW,EAAE,EAAE,CACd,WAAW,KAAK,sBAAsB;QACtC,WAAW,CAAC,QAAQ,CAAC,uBAAuB,CAAC,CAChD,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,140 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.default = default_1;
|
|
4
|
+
const schematics_1 = require("@angular-devkit/schematics");
|
|
5
|
+
const utility_1 = require("@schematics/angular/utility");
|
|
6
|
+
const workspace_1 = require("@schematics/angular/utility/workspace");
|
|
7
|
+
const version_1 = require("../../../../version");
|
|
8
|
+
const tree_1 = require("../../../utility/tree");
|
|
9
|
+
const workspace_2 = require("../../../utility/workspace");
|
|
10
|
+
const COMPAT_CSS_FILE_NAME = `skyux${version_1.VERSION.major}-compat.css`;
|
|
11
|
+
const compatStyles = {
|
|
12
|
+
libraries: [
|
|
13
|
+
{
|
|
14
|
+
name: '@skyux/theme',
|
|
15
|
+
components: [
|
|
16
|
+
{
|
|
17
|
+
name: 'button',
|
|
18
|
+
styles: [
|
|
19
|
+
{
|
|
20
|
+
css: `
|
|
21
|
+
:root {
|
|
22
|
+
--sky-compat-btn-disabled-pointer-events: none;
|
|
23
|
+
}
|
|
24
|
+
`,
|
|
25
|
+
instructions: `
|
|
26
|
+
Pointer events are no longer disabled on elements with the "sky-btn-disabled" class or the "disabled" attribute. To address this change, remove this block of code, then either add the "disabled" attribute to the element (preferred) or update any click and keyboard handlers to ignore interaction while the element is disabled.`,
|
|
27
|
+
},
|
|
28
|
+
],
|
|
29
|
+
},
|
|
30
|
+
],
|
|
31
|
+
},
|
|
32
|
+
],
|
|
33
|
+
};
|
|
34
|
+
function getProjectAppPath(project) {
|
|
35
|
+
return `${(0, workspace_2.getSourceRoot)(project)}/app`;
|
|
36
|
+
}
|
|
37
|
+
function buildCommentBlock(message) {
|
|
38
|
+
return `/${'*'.repeat(79)}
|
|
39
|
+
* ${message.replace(/(?![^\n]{1,75}$)([^\n]{1,75})\s/g, '$1\n * ')}
|
|
40
|
+
${'*'.repeat(79)}/`;
|
|
41
|
+
}
|
|
42
|
+
function buildComponentCss(component) {
|
|
43
|
+
let contents = buildCommentBlock(`COMPONENT: ${component.name.toUpperCase()}`);
|
|
44
|
+
for (const style of component.styles) {
|
|
45
|
+
contents += `
|
|
46
|
+
|
|
47
|
+
${buildCommentBlock(style.instructions.trim())}
|
|
48
|
+
|
|
49
|
+
${style.css.trim()}
|
|
50
|
+
`;
|
|
51
|
+
}
|
|
52
|
+
return contents;
|
|
53
|
+
}
|
|
54
|
+
function writeStylesheet(sourceRoot, contents) {
|
|
55
|
+
const filePath = `${sourceRoot}/${COMPAT_CSS_FILE_NAME}`;
|
|
56
|
+
return (tree) => {
|
|
57
|
+
if (tree.exists(filePath)) {
|
|
58
|
+
tree.overwrite(filePath, contents);
|
|
59
|
+
}
|
|
60
|
+
else {
|
|
61
|
+
tree.create(filePath, contents);
|
|
62
|
+
}
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
function addStylesheetToStylesArray(styles, filePath) {
|
|
66
|
+
if (styles && !styles.includes(filePath)) {
|
|
67
|
+
styles.push(filePath);
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
function addStylesheetToWorkspace() {
|
|
71
|
+
return () => (0, utility_1.updateWorkspace)((workspace) => {
|
|
72
|
+
for (const project of workspace.projects.values()) {
|
|
73
|
+
for (const targetName of ['build', 'test']) {
|
|
74
|
+
if (project.extensions['projectType'] === 'application') {
|
|
75
|
+
const target = project.targets.get(targetName);
|
|
76
|
+
const sourceRoot = getProjectAppPath(project);
|
|
77
|
+
const filePath = `${sourceRoot}/${COMPAT_CSS_FILE_NAME}`;
|
|
78
|
+
/* istanbul ignore else */
|
|
79
|
+
if (target && target.options) {
|
|
80
|
+
target.options['styles'] ??= [];
|
|
81
|
+
addStylesheetToStylesArray(target.options['styles'], filePath);
|
|
82
|
+
// A configuration's `styles` array replaces (rather than
|
|
83
|
+
// merges with) the target's base `styles` array, so any
|
|
84
|
+
// configuration that already declares its own `styles` needs
|
|
85
|
+
// the compatibility stylesheet appended too.
|
|
86
|
+
for (const configuration of Object.values(target.configurations ?? {})) {
|
|
87
|
+
addStylesheetToStylesArray(configuration?.['styles'], filePath);
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
});
|
|
94
|
+
}
|
|
95
|
+
function getCompatStyles(tree) {
|
|
96
|
+
let contents = '';
|
|
97
|
+
const packageJson = JSON.parse((0, tree_1.readRequiredFile)(tree, '/package.json'));
|
|
98
|
+
for (const library of compatStyles.libraries) {
|
|
99
|
+
if (packageJson.dependencies?.[library.name] ||
|
|
100
|
+
packageJson.devDependencies?.[library.name]) {
|
|
101
|
+
for (const component of library.components) {
|
|
102
|
+
contents += `
|
|
103
|
+
${buildComponentCss(component)}`;
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
return contents
|
|
108
|
+
? `${buildCommentBlock(`TODO: The following component libraries introduced visual breaking ` +
|
|
109
|
+
`changes in SKY UX ${version_1.VERSION.major}. Each block of CSS reintroduces ` +
|
|
110
|
+
`the styles that were changed or removed for backward compatibility. ` +
|
|
111
|
+
`You will need to do the following before migrating to the next major ` +
|
|
112
|
+
`version of SKY UX:
|
|
113
|
+
- Address each of the changes by following the instructions
|
|
114
|
+
in each block of CSS, then remove the block.
|
|
115
|
+
- Delete this file after all blocks have been addressed.
|
|
116
|
+
- Remove each occurrence of this file in your project's
|
|
117
|
+
angular.json file.`)}
|
|
118
|
+
${contents}`
|
|
119
|
+
: undefined;
|
|
120
|
+
}
|
|
121
|
+
function default_1() {
|
|
122
|
+
return async (tree) => {
|
|
123
|
+
const workspace = await (0, workspace_1.getWorkspace)(tree);
|
|
124
|
+
const styles = getCompatStyles(tree);
|
|
125
|
+
const rules = [];
|
|
126
|
+
for (const [, projectDefinition] of workspace.projects.entries()) {
|
|
127
|
+
if (projectDefinition.extensions['projectType'] === 'application') {
|
|
128
|
+
if (styles) {
|
|
129
|
+
const sourcePath = getProjectAppPath(projectDefinition);
|
|
130
|
+
rules.push(writeStylesheet(sourcePath, styles));
|
|
131
|
+
}
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
if (styles) {
|
|
135
|
+
rules.push(addStylesheetToWorkspace());
|
|
136
|
+
}
|
|
137
|
+
return (0, schematics_1.chain)(rules);
|
|
138
|
+
};
|
|
139
|
+
}
|
|
140
|
+
//# sourceMappingURL=add-compat-stylesheet.schematic.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"add-compat-stylesheet.schematic.js","sourceRoot":"","sources":["../../../../../../../../../libs/components/packages/src/schematics/migrations/update-15/add-compat-stylesheets/add-compat-stylesheet.schematic.ts"],"names":[],"mappings":";;AA6KA,4BAqBC;AAlMD,2DAA+D;AAC/D,yDAGqC;AACrC,qEAAqE;AAErE,iDAA8C;AAC9C,gDAAyD;AACzD,0DAA2D;AAE3D,MAAM,oBAAoB,GAAG,QAAQ,iBAAO,CAAC,KAAK,aAAa,CAAC;AAYhE,MAAM,YAAY,GAAgB;IAChC,SAAS,EAAE;QACT;YACE,IAAI,EAAE,cAAc;YACpB,UAAU,EAAE;gBACV;oBACE,IAAI,EAAE,QAAQ;oBACd,MAAM,EAAE;wBACN;4BACE,GAAG,EAAE;;;;CAIlB;4BACa,YAAY,EAAE;uUAC2S;yBAC1T;qBACF;iBACF;aACF;SACF;KACF;CACF,CAAC;AAEF,SAAS,iBAAiB,CAAC,OAA0B;IACnD,OAAO,GAAG,IAAA,yBAAa,EAAC,OAAO,CAAC,MAAM,CAAC;AACzC,CAAC;AAED,SAAS,iBAAiB,CAAC,OAAe;IACxC,OAAO,IAAI,GAAG,CAAC,MAAM,CAAC,EAAE,CAAC;KACtB,OAAO,CAAC,OAAO,CAAC,kCAAkC,EAAE,SAAS,CAAC;GAChE,GAAG,CAAC,MAAM,CAAC,EAAE,CA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
import { Rule } from '@angular-devkit/schematics';
|
|
2
|
+
/**
|
|
3
|
+
* Replaces the resources services with their "legacy" equivalents, which emit
|
|
4
|
+
* once and complete. The original services now emit again whenever the locale
|
|
5
|
+
* changes.
|
|
6
|
+
*/
|
|
7
|
+
export default function (): Rule;
|
package/src/schematics/migrations/update-15/legacy-i18n-services/legacy-i18n-services.schematic.js
ADDED
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.default = default_1;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const workspace_1 = require("@schematics/angular/utility/workspace");
|
|
6
|
+
const typescript_1 = tslib_1.__importDefault(require("typescript"));
|
|
7
|
+
const ng_ast_1 = require("../../../utility/typescript/ng-ast");
|
|
8
|
+
const swap_imported_class_1 = require("../../../utility/typescript/swap-imported-class");
|
|
9
|
+
const visit_project_files_1 = require("../../../utility/visit-project-files");
|
|
10
|
+
const MODULE_NAME = '@skyux/i18n';
|
|
11
|
+
const CLASS_NAMES = {
|
|
12
|
+
SkyAppResourcesService: 'SkyAppResourcesLegacyService',
|
|
13
|
+
SkyLibResourcesService: 'SkyLibResourcesLegacyService',
|
|
14
|
+
};
|
|
15
|
+
/**
|
|
16
|
+
* Whether the reference is the `SkyLibResourcesService.addResources()` static
|
|
17
|
+
* call. Only the observables returned by the instance methods changed, so
|
|
18
|
+
* static calls -- which generated resources modules rely on -- are left alone.
|
|
19
|
+
*/
|
|
20
|
+
function isStaticAddResourcesReference(node) {
|
|
21
|
+
const parent = node.parent;
|
|
22
|
+
return (typescript_1.default.isPropertyAccessExpression(parent) &&
|
|
23
|
+
parent.expression === node &&
|
|
24
|
+
parent.name.text === 'addResources');
|
|
25
|
+
}
|
|
26
|
+
async function updateSourceFiles(tree) {
|
|
27
|
+
const workspace = await (0, workspace_1.getWorkspace)(tree);
|
|
28
|
+
workspace.projects.forEach((project) => {
|
|
29
|
+
(0, visit_project_files_1.visitProjectFiles)(tree, project.sourceRoot || project.root, (filePath) => {
|
|
30
|
+
if (!filePath.endsWith('.ts')) {
|
|
31
|
+
return;
|
|
32
|
+
}
|
|
33
|
+
const content = tree.readText(filePath);
|
|
34
|
+
if (!Object.keys(CLASS_NAMES).some((name) => content.includes(name))) {
|
|
35
|
+
return;
|
|
36
|
+
}
|
|
37
|
+
const recorder = tree.beginUpdate(filePath);
|
|
38
|
+
(0, swap_imported_class_1.swapImportedClass)(recorder, filePath, (0, ng_ast_1.parseSourceFile)(tree, filePath), [
|
|
39
|
+
{
|
|
40
|
+
classNames: CLASS_NAMES,
|
|
41
|
+
moduleName: MODULE_NAME,
|
|
42
|
+
filter: (node) => !isStaticAddResourcesReference(node),
|
|
43
|
+
},
|
|
44
|
+
]);
|
|
45
|
+
tree.commitUpdate(recorder);
|
|
46
|
+
});
|
|
47
|
+
});
|
|
48
|
+
}
|
|
49
|
+
/**
|
|
50
|
+
* Replaces the resources services with their "legacy" equivalents, which emit
|
|
51
|
+
* once and complete. The original services now emit again whenever the locale
|
|
52
|
+
* changes.
|
|
53
|
+
*/
|
|
54
|
+
function default_1() {
|
|
55
|
+
return async (tree) => {
|
|
56
|
+
await updateSourceFiles(tree);
|
|
57
|
+
};
|
|
58
|
+
}
|
|
59
|
+
//# sourceMappingURL=legacy-i18n-services.schematic.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"legacy-i18n-services.schematic.js","sourceRoot":"","sources":["../../../../../../../../../libs/components/packages/src/schematics/migrations/update-15/legacy-i18n-services/legacy-i18n-services.schematic.ts"],"names":[],"mappings":";;AAkEA,4BAIC;;AArED,qEAAqE;AAErE,oEAA4B;AAE5B,+DAAqE;AACrE,yFAAoF;AACpF,8EAAyE;AAEzE,MAAM,WAAW,GAAG,aAAa,CAAC;AAElC,MAAM,WAAW,GAA2B;IAC1C,sBAAsB,EAAE,8BAA8B;IACtD,sBAAsB,EAAE,8BAA8B;CACvD,CAAC;AA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AI,CAAC,YAAY,CAAC,QAAQ,CAAC,CAAC;QAC9B,CAAC,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;AACL,CAAC;AAED;;;;GAIG;AACH;IACE,OAAO,KAAK,EAAE,IAAU,EAAiB,EAAE;QACzC,MAAM,iBAAiB,CAAC,IAAI,CAAC,CAAC;IAChC,CAAC,CAAC;AACJ,CAAC"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Rule } from '@angular-devkit/schematics';
|
|
2
|
+
/**
|
|
3
|
+
* Moves `SkyAppTestUtility`, `SkyAppTestUtilityDomEventOptions`, and `SkyBy`
|
|
4
|
+
* imports from the deprecated `@skyux-sdk/testing` package to
|
|
5
|
+
* `@skyux/core/testing`, and drops the deprecated dependency once nothing else
|
|
6
|
+
* in the workspace imports it.
|
|
7
|
+
*/
|
|
8
|
+
export default function (): Rule;
|