@taiga-ui/cdk 3.25.0-dev.main-7547cea → 3.25.0-dev.main-9c8bbc6
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/esm2015/interfaces/month-like.js +1 -1
- package/interfaces/month-like.d.ts +1 -1
- package/package.json +1 -1
- package/schematics/ng-add/steps/wrap-with-tui-root.js +3 -3
- package/schematics/ng-update/steps/replace-const.d.ts +1 -1
- package/schematics/ng-update/steps/replace-const.js +2 -2
- package/schematics/ng-update/v3/constants/{consts.d.ts → constants.d.ts} +1 -1
- package/schematics/ng-update/v3/constants/{consts.js → constants.js} +2 -2
- package/schematics/ng-update/v3/constants/enums.js +4 -0
- package/schematics/ng-update/v3/index.js +2 -2
- package/schematics/ng-update/v3/steps/migrate-polymorpheus.d.ts +1 -1
- package/schematics/ng-update/v3/steps/migrate-textfield-controller.d.ts +1 -1
- package/schematics/ng-update/v3/steps/miscellaneous.js +4 -0
- package/schematics/utils/get-standalone-bootstrap-function.js +3 -3
- package/schematics/utils/templates/get-component-templates.d.ts +1 -1
- package/schematics/utils/templates/ng-component-input-manipulations.d.ts +1 -1
- package/schematics/utils/templates/template-resource.d.ts +1 -1
- /package/schematics/ng-update/interfaces/{template-resourse.d.ts → template-resource.d.ts} +0 -0
- /package/schematics/ng-update/interfaces/{template-resourse.js → template-resource.js} +0 -0
@@ -1,2 +1,2 @@
|
|
1
1
|
export {};
|
2
|
-
//# sourceMappingURL=data:application/json;base64,
|
2
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoibW9udGgtbGlrZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uL3Byb2plY3RzL2Nkay9pbnRlcmZhY2VzL21vbnRoLWxpa2UudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IiIsInNvdXJjZXNDb250ZW50IjpbImltcG9ydCB7VHVpWWVhckxpa2V9IGZyb20gJy4veWVhci1saWtlJztcblxuLyoqXG4gKiBPcHRpb25hbGx5IGhhcyB5ZWFyIGFuZC9vciBtb250aFxuICovXG5leHBvcnQgaW50ZXJmYWNlIFR1aU1vbnRoTGlrZSBleHRlbmRzIFR1aVllYXJMaWtlIHtcbiAgICByZWFkb25seSBtb250aD86IG51bWJlcjtcbn1cbiJdfQ==
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@taiga-ui/cdk",
|
3
|
-
"version": "3.25.0-dev.main-
|
3
|
+
"version": "3.25.0-dev.main-9c8bbc6",
|
4
4
|
"description": "Base library for creating Angular components and applications using Taiga UI principles regarding of actual visual appearance",
|
5
5
|
"keywords": [
|
6
6
|
"angular",
|
@@ -50,9 +50,9 @@ function addTuiRootComponent(filePath, context, tree) {
|
|
50
50
|
context.logger.info(`Content of the app was wrapped with tui-root component in ${filePath}`);
|
51
51
|
}
|
52
52
|
function getAppTemplatePath(mainPath) {
|
53
|
-
const
|
54
|
-
if (
|
55
|
-
const [componentIdentifier] =
|
53
|
+
const standaloneBootstrapFunction = get_standalone_bootstrap_function_1.getStandaloneBootstrapFunction(mainPath);
|
54
|
+
if (standaloneBootstrapFunction) {
|
55
|
+
const [componentIdentifier] = standaloneBootstrapFunction.getArguments();
|
56
56
|
const component = get_component_from_identifier_1.getComponentFromIdentifier(componentIdentifier);
|
57
57
|
return component && getTemplatePathFromComponent(component);
|
58
58
|
}
|
@@ -1,4 +1,4 @@
|
|
1
1
|
import { TuiSchema } from '../../ng-add/schema';
|
2
2
|
import { ReplacementConst } from '../interfaces/replacement-const';
|
3
|
-
export declare function replaceConstants(options: TuiSchema,
|
3
|
+
export declare function replaceConstants(options: TuiSchema, constants: readonly ReplacementConst[]): void;
|
4
4
|
export declare function replaceConst({ from, to }: ReplacementConst): void;
|
@@ -6,10 +6,10 @@ const add_unique_import_1 = require("../../utils/add-unique-import");
|
|
6
6
|
const colored_log_1 = require("../../utils/colored-log");
|
7
7
|
const get_named_import_references_1 = require("../../utils/get-named-import-references");
|
8
8
|
const import_manipulations_1 = require("../../utils/import-manipulations");
|
9
|
-
function replaceConstants(options,
|
9
|
+
function replaceConstants(options, constants) {
|
10
10
|
!options[`skip-logs`] &&
|
11
11
|
colored_log_1.infoLog(`${colored_log_1.SMALL_TAB_SYMBOL}${colored_log_1.REPLACE_SYMBOL} replacing constants...`);
|
12
|
-
|
12
|
+
constants.forEach(constToReplace => replaceConst(constToReplace));
|
13
13
|
!options[`skip-logs`] &&
|
14
14
|
colored_log_1.successLog(`${colored_log_1.SMALL_TAB_SYMBOL}${colored_log_1.SUCCESS_SYMBOL} constants replaced \n`);
|
15
15
|
}
|
@@ -1,2 +1,2 @@
|
|
1
1
|
import { ReplacementConst } from '../../interfaces/replacement-const';
|
2
|
-
export declare const
|
2
|
+
export declare const CONSTANTS_TO_REPLACE: ReplacementConst[];
|
@@ -1,7 +1,7 @@
|
|
1
1
|
"use strict";
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
3
|
-
exports.
|
4
|
-
exports.
|
3
|
+
exports.CONSTANTS_TO_REPLACE = void 0;
|
4
|
+
exports.CONSTANTS_TO_REPLACE = [
|
5
5
|
{
|
6
6
|
from: {
|
7
7
|
name: `EMPTY_VALIDATOR`,
|
@@ -182,18 +182,22 @@ exports.ENUMS_TO_REPLACE = [
|
|
182
182
|
Bittersweet: `support-06`,
|
183
183
|
Pinkie: `support-07`,
|
184
184
|
Charm: `support-08`,
|
185
|
+
// cspell:disable-next-line
|
185
186
|
Amethist: `support-09`,
|
186
187
|
Helio: `support-10`,
|
187
188
|
Lilac: `support-11`,
|
188
189
|
Malibu: `support-12`,
|
189
190
|
Havelock: `support-13`,
|
191
|
+
// cspell:disable-next-line
|
190
192
|
Picton: `support-14`,
|
191
193
|
Mint: `support-15`,
|
192
194
|
Fountain: `support-16`,
|
195
|
+
// cspell:disable-next-line
|
193
196
|
Puertorico: `support-17`,
|
194
197
|
Bay: `support-18`,
|
195
198
|
Forest: `support-19`,
|
196
199
|
York: `support-20`,
|
200
|
+
// cspell:disable-next-line
|
197
201
|
Feijoa: `support-21`,
|
198
202
|
},
|
199
203
|
keepAsType: false,
|
@@ -19,7 +19,7 @@ const replace_services_1 = require("../steps/replace-services");
|
|
19
19
|
const show_warnings_1 = require("../steps/show-warnings");
|
20
20
|
const get_file_system_1 = require("../utils/get-file-system");
|
21
21
|
const migrate_expand_templates_1 = require("../v3-5/steps/migrate-expand-templates");
|
22
|
-
const
|
22
|
+
const constants_1 = require("./constants/constants");
|
23
23
|
const enums_1 = require("./constants/enums");
|
24
24
|
const modules_1 = require("./constants/modules");
|
25
25
|
const services_1 = require("./constants/services");
|
@@ -68,7 +68,7 @@ function main(options) {
|
|
68
68
|
replace_deep_import_1.replaceDeepImports(options);
|
69
69
|
replace_enums_1.replaceEnums(options, enums_1.ENUMS_TO_REPLACE);
|
70
70
|
rename_types_1.renameTypes(options, types_1.TYPES_TO_RENAME);
|
71
|
-
replace_const_1.replaceConstants(options,
|
71
|
+
replace_const_1.replaceConstants(options, constants_1.CONSTANTS_TO_REPLACE);
|
72
72
|
replace_services_1.replaceServices(options, services_1.SERVICES_TO_REPLACE);
|
73
73
|
replace_styles_1.replaceStyles();
|
74
74
|
show_warnings_1.showWarnings(context, warnings_1.MIGRATION_WARNINGS);
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { UpdateRecorder } from '@angular-devkit/schematics';
|
2
2
|
import { DevkitFileSystem } from 'ng-morph/project/classes/devkit-file-system';
|
3
|
-
import { TemplateResource } from '../../interfaces/template-
|
3
|
+
import { TemplateResource } from '../../interfaces/template-resource';
|
4
4
|
export declare function migratePolymorpheus({ resource, fileSystem, recorder, }: {
|
5
5
|
resource: TemplateResource;
|
6
6
|
recorder: UpdateRecorder;
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { UpdateRecorder } from '@angular-devkit/schematics';
|
2
2
|
import { DevkitFileSystem } from 'ng-morph/project/classes/devkit-file-system';
|
3
|
-
import { TemplateResource } from '../../interfaces/template-
|
3
|
+
import { TemplateResource } from '../../interfaces/template-resource';
|
4
4
|
export declare function migrateTextfieldController({ resource, fileSystem, recorder, }: {
|
5
5
|
resource: TemplateResource;
|
6
6
|
recorder: UpdateRecorder;
|
@@ -4,10 +4,10 @@ exports.getStandaloneBootstrapFunction = void 0;
|
|
4
4
|
const ng_morph_1 = require("ng-morph");
|
5
5
|
const get_named_import_references_1 = require("./get-named-import-references");
|
6
6
|
function getStandaloneBootstrapFunction(path) {
|
7
|
-
const
|
7
|
+
const standaloneBootstrapIdentifier = get_named_import_references_1.getNamedImportReferences(`bootstrapApplication`, `@angular/platform-browser`, path)
|
8
8
|
.map(ref => ref.getParent())
|
9
9
|
.filter(node => ng_morph_1.Node.isCallExpression(node))[0];
|
10
|
-
const
|
11
|
-
return
|
10
|
+
const standaloneBootstrapFunction = standaloneBootstrapIdentifier;
|
11
|
+
return standaloneBootstrapFunction || null;
|
12
12
|
}
|
13
13
|
exports.getStandaloneBootstrapFunction = getStandaloneBootstrapFunction;
|
@@ -1,3 +1,3 @@
|
|
1
1
|
import { ClassDeclaration, Pattern, Query, StructureType } from 'ng-morph';
|
2
|
-
import { TemplateResource } from '../../ng-update/interfaces/template-
|
2
|
+
import { TemplateResource } from '../../ng-update/interfaces/template-resource';
|
3
3
|
export declare function getComponentTemplates(pattern: Pattern, query?: Query<Omit<StructureType<ClassDeclaration>, 'kind'>>): TemplateResource[];
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import { DevkitFileSystem } from 'ng-morph/project/classes/devkit-file-system';
|
2
2
|
import { Element } from 'parse5';
|
3
|
-
import { TemplateResource } from '../../ng-update/interfaces/template-
|
3
|
+
import { TemplateResource } from '../../ng-update/interfaces/template-resource';
|
4
4
|
/**
|
5
5
|
* Replace component input property by new value
|
6
6
|
* ___
|
@@ -1,5 +1,5 @@
|
|
1
1
|
import { DevkitFileSystem } from 'ng-morph';
|
2
|
-
import { TemplateResource } from '../../ng-update/interfaces/template-
|
2
|
+
import { TemplateResource } from '../../ng-update/interfaces/template-resource';
|
3
3
|
export declare function getTemplateFromTemplateResource(templateRes: TemplateResource, fileSystem: DevkitFileSystem): string;
|
4
4
|
export declare function getPathFromTemplateResource(templateRes: TemplateResource): string;
|
5
5
|
export declare function getTemplateOffset(templateRes: TemplateResource): number;
|
File without changes
|
File without changes
|