@angular/compiler 15.1.0 → 15.1.2
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/esm2020/src/render3/partial/class_metadata.mjs +1 -1
- package/esm2020/src/render3/partial/directive.mjs +1 -1
- package/esm2020/src/render3/partial/factory.mjs +1 -1
- package/esm2020/src/render3/partial/injectable.mjs +1 -1
- package/esm2020/src/render3/partial/injector.mjs +1 -1
- package/esm2020/src/render3/partial/ng_module.mjs +1 -1
- package/esm2020/src/render3/partial/pipe.mjs +1 -1
- package/esm2020/src/shadow_css.mjs +11 -2
- package/esm2020/src/version.mjs +1 -1
- package/fesm2015/compiler.mjs +20 -10
- package/fesm2015/compiler.mjs.map +1 -1
- package/fesm2015/testing.mjs +1 -1
- package/fesm2020/compiler.mjs +19 -10
- package/fesm2020/compiler.mjs.map +1 -1
- package/fesm2020/testing.mjs +1 -1
- package/index.d.ts +1 -1
- package/package.json +2 -2
- package/testing/index.d.ts +1 -1
package/fesm2015/compiler.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Angular v15.1.
|
|
2
|
+
* @license Angular v15.1.2
|
|
3
3
|
* (c) 2010-2022 Google LLC. https://angular.io/
|
|
4
4
|
* License: MIT
|
|
5
5
|
*/
|
|
@@ -7553,6 +7553,7 @@ const animationKeywords = new Set([
|
|
|
7553
7553
|
*/
|
|
7554
7554
|
class ShadowCss {
|
|
7555
7555
|
constructor() {
|
|
7556
|
+
// TODO: Is never re-assigned, could be removed.
|
|
7556
7557
|
this.strictStyling = true;
|
|
7557
7558
|
/**
|
|
7558
7559
|
* Regular expression used to extrapolate the possible keyframes from an
|
|
@@ -8014,6 +8015,7 @@ class ShadowCss {
|
|
|
8014
8015
|
// return a selector with [name] suffix on each simple selector
|
|
8015
8016
|
// e.g. .foo.bar > .zot becomes .foo[name].bar[name] > .zot[name] /** @internal */
|
|
8016
8017
|
_applyStrictSelectorScope(selector, scopeSelector, hostSelector) {
|
|
8018
|
+
var _a;
|
|
8017
8019
|
const isRe = /\[is=([^\]]*)\]/g;
|
|
8018
8020
|
scopeSelector = scopeSelector.replace(isRe, (_, ...parts) => parts[0]);
|
|
8019
8021
|
const attrName = '[' + scopeSelector + ']';
|
|
@@ -8060,6 +8062,13 @@ class ShadowCss {
|
|
|
8060
8062
|
while ((res = sep.exec(selector)) !== null) {
|
|
8061
8063
|
const separator = res[1];
|
|
8062
8064
|
const part = selector.slice(startIndex, res.index).trim();
|
|
8065
|
+
// A space following an escaped hex value and followed by another hex character
|
|
8066
|
+
// (ie: ".\fc ber" for ".über") is not a separator between 2 selectors
|
|
8067
|
+
// also keep in mind that backslashes are replaced by a placeholder by SafeSelector
|
|
8068
|
+
// These escaped selectors happen for example when esbuild runs with optimization.minify.
|
|
8069
|
+
if (part.match(_placeholderRe) && ((_a = selector[res.index + 1]) === null || _a === void 0 ? void 0 : _a.match(/[a-fA-F\d]/))) {
|
|
8070
|
+
continue;
|
|
8071
|
+
}
|
|
8063
8072
|
shouldScope = shouldScope || part.indexOf(_polyfillHostNoCombinator) > -1;
|
|
8064
8073
|
const scopedPart = shouldScope ? _scopeSelectorPart(part) : part;
|
|
8065
8074
|
scopedSelector += `${scopedPart} ${separator} `;
|
|
@@ -8099,7 +8108,7 @@ class SafeSelector {
|
|
|
8099
8108
|
});
|
|
8100
8109
|
}
|
|
8101
8110
|
restore(content) {
|
|
8102
|
-
return content.replace(
|
|
8111
|
+
return content.replace(_placeholderRe, (_ph, index) => this.placeholders[+index]);
|
|
8103
8112
|
}
|
|
8104
8113
|
content() {
|
|
8105
8114
|
return this._content;
|
|
@@ -8147,6 +8156,7 @@ const _polyfillHostRe = /-shadowcsshost/gim;
|
|
|
8147
8156
|
const _colonHostRe = /:host/gim;
|
|
8148
8157
|
const _colonHostContextRe = /:host-context/gim;
|
|
8149
8158
|
const _commentRe = /\/\*[\s\S]*?\*\//g;
|
|
8159
|
+
const _placeholderRe = /__ph-(\d+)__/g;
|
|
8150
8160
|
function stripComments(input) {
|
|
8151
8161
|
return input.replace(_commentRe, '');
|
|
8152
8162
|
}
|
|
@@ -19871,7 +19881,7 @@ function publishFacade(global) {
|
|
|
19871
19881
|
* @description
|
|
19872
19882
|
* Entry point for all public APIs of the compiler package.
|
|
19873
19883
|
*/
|
|
19874
|
-
const VERSION = new Version('15.1.
|
|
19884
|
+
const VERSION = new Version('15.1.2');
|
|
19875
19885
|
|
|
19876
19886
|
class CompilerConfig {
|
|
19877
19887
|
constructor({ defaultEncapsulation = ViewEncapsulation.Emulated, useJit = true, missingTranslation = null, preserveWhitespaces, strictInjectionParameters } = {}) {
|
|
@@ -21798,7 +21808,7 @@ const MINIMUM_PARTIAL_LINKER_VERSION$6 = '12.0.0';
|
|
|
21798
21808
|
function compileDeclareClassMetadata(metadata) {
|
|
21799
21809
|
const definitionMap = new DefinitionMap();
|
|
21800
21810
|
definitionMap.set('minVersion', literal(MINIMUM_PARTIAL_LINKER_VERSION$6));
|
|
21801
|
-
definitionMap.set('version', literal('15.1.
|
|
21811
|
+
definitionMap.set('version', literal('15.1.2'));
|
|
21802
21812
|
definitionMap.set('ngImport', importExpr(Identifiers.core));
|
|
21803
21813
|
definitionMap.set('type', metadata.type);
|
|
21804
21814
|
definitionMap.set('decorators', metadata.decorators);
|
|
@@ -21902,7 +21912,7 @@ function createDirectiveDefinitionMap(meta) {
|
|
|
21902
21912
|
var _a;
|
|
21903
21913
|
const definitionMap = new DefinitionMap();
|
|
21904
21914
|
definitionMap.set('minVersion', literal(MINIMUM_PARTIAL_LINKER_VERSION$5));
|
|
21905
|
-
definitionMap.set('version', literal('15.1.
|
|
21915
|
+
definitionMap.set('version', literal('15.1.2'));
|
|
21906
21916
|
// e.g. `type: MyDirective`
|
|
21907
21917
|
definitionMap.set('type', meta.internalType);
|
|
21908
21918
|
if (meta.isStandalone) {
|
|
@@ -22127,7 +22137,7 @@ const MINIMUM_PARTIAL_LINKER_VERSION$4 = '12.0.0';
|
|
|
22127
22137
|
function compileDeclareFactoryFunction(meta) {
|
|
22128
22138
|
const definitionMap = new DefinitionMap();
|
|
22129
22139
|
definitionMap.set('minVersion', literal(MINIMUM_PARTIAL_LINKER_VERSION$4));
|
|
22130
|
-
definitionMap.set('version', literal('15.1.
|
|
22140
|
+
definitionMap.set('version', literal('15.1.2'));
|
|
22131
22141
|
definitionMap.set('ngImport', importExpr(Identifiers.core));
|
|
22132
22142
|
definitionMap.set('type', meta.internalType);
|
|
22133
22143
|
definitionMap.set('deps', compileDependencies(meta.deps));
|
|
@@ -22162,7 +22172,7 @@ function compileDeclareInjectableFromMetadata(meta) {
|
|
|
22162
22172
|
function createInjectableDefinitionMap(meta) {
|
|
22163
22173
|
const definitionMap = new DefinitionMap();
|
|
22164
22174
|
definitionMap.set('minVersion', literal(MINIMUM_PARTIAL_LINKER_VERSION$3));
|
|
22165
|
-
definitionMap.set('version', literal('15.1.
|
|
22175
|
+
definitionMap.set('version', literal('15.1.2'));
|
|
22166
22176
|
definitionMap.set('ngImport', importExpr(Identifiers.core));
|
|
22167
22177
|
definitionMap.set('type', meta.internalType);
|
|
22168
22178
|
// Only generate providedIn property if it has a non-null value
|
|
@@ -22213,7 +22223,7 @@ function compileDeclareInjectorFromMetadata(meta) {
|
|
|
22213
22223
|
function createInjectorDefinitionMap(meta) {
|
|
22214
22224
|
const definitionMap = new DefinitionMap();
|
|
22215
22225
|
definitionMap.set('minVersion', literal(MINIMUM_PARTIAL_LINKER_VERSION$2));
|
|
22216
|
-
definitionMap.set('version', literal('15.1.
|
|
22226
|
+
definitionMap.set('version', literal('15.1.2'));
|
|
22217
22227
|
definitionMap.set('ngImport', importExpr(Identifiers.core));
|
|
22218
22228
|
definitionMap.set('type', meta.internalType);
|
|
22219
22229
|
definitionMap.set('providers', meta.providers);
|
|
@@ -22243,7 +22253,7 @@ function compileDeclareNgModuleFromMetadata(meta) {
|
|
|
22243
22253
|
function createNgModuleDefinitionMap(meta) {
|
|
22244
22254
|
const definitionMap = new DefinitionMap();
|
|
22245
22255
|
definitionMap.set('minVersion', literal(MINIMUM_PARTIAL_LINKER_VERSION$1));
|
|
22246
|
-
definitionMap.set('version', literal('15.1.
|
|
22256
|
+
definitionMap.set('version', literal('15.1.2'));
|
|
22247
22257
|
definitionMap.set('ngImport', importExpr(Identifiers.core));
|
|
22248
22258
|
definitionMap.set('type', meta.internalType);
|
|
22249
22259
|
// We only generate the keys in the metadata if the arrays contain values.
|
|
@@ -22294,7 +22304,7 @@ function compileDeclarePipeFromMetadata(meta) {
|
|
|
22294
22304
|
function createPipeDefinitionMap(meta) {
|
|
22295
22305
|
const definitionMap = new DefinitionMap();
|
|
22296
22306
|
definitionMap.set('minVersion', literal(MINIMUM_PARTIAL_LINKER_VERSION));
|
|
22297
|
-
definitionMap.set('version', literal('15.1.
|
|
22307
|
+
definitionMap.set('version', literal('15.1.2'));
|
|
22298
22308
|
definitionMap.set('ngImport', importExpr(Identifiers.core));
|
|
22299
22309
|
// e.g. `type: MyPipe`
|
|
22300
22310
|
definitionMap.set('type', meta.internalType);
|