@angular/core 19.2.20 → 19.2.22
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/event_dispatcher.d-K56StcHr.d.ts +1 -1
- package/fesm2022/core.mjs +32 -9
- package/fesm2022/core.mjs.map +1 -1
- package/fesm2022/primitives/di.mjs +1 -1
- package/fesm2022/primitives/di.mjs.map +1 -1
- package/fesm2022/primitives/event-dispatch.mjs +1 -1
- package/fesm2022/primitives/event-dispatch.mjs.map +1 -1
- package/fesm2022/primitives/signals.mjs +1 -1
- package/fesm2022/primitives/signals.mjs.map +1 -1
- package/fesm2022/rxjs-interop.mjs +1 -1
- package/fesm2022/rxjs-interop.mjs.map +1 -1
- package/fesm2022/testing.mjs +1 -1
- package/fesm2022/testing.mjs.map +1 -1
- package/fesm2022/untracked-BKcld_ew.mjs +1 -1
- package/fesm2022/untracked-BKcld_ew.mjs.map +1 -1
- package/index.d.ts +2 -2
- package/navigation_types.d-fAxd92YV.d.ts +1 -1
- package/package.json +1 -1
- package/primitives/di/index.d.ts +1 -1
- package/primitives/event-dispatch/index.d.ts +1 -1
- package/primitives/signals/index.d.ts +1 -1
- package/rxjs-interop/index.d.ts +1 -1
- package/schematics/bundles/add-bootstrap-context-to-server-main.cjs +1 -1
- package/schematics/bundles/apply_import_manager-QEWElZT-.cjs +1 -1
- package/schematics/bundles/change_tracker-BPk3UwXG.cjs +1 -1
- package/schematics/bundles/checker-DLkGMJj-.cjs +2 -2
- package/schematics/bundles/cleanup-unused-imports.cjs +1 -1
- package/schematics/bundles/compiler_host-CAfDJO3W.cjs +1 -1
- package/schematics/bundles/control-flow-migration.cjs +1 -1
- package/schematics/bundles/explicit-standalone-flag.cjs +1 -1
- package/schematics/bundles/imports-CIX-JgAN.cjs +1 -1
- package/schematics/bundles/index-BPwBW8Gv.cjs +1 -1
- package/schematics/bundles/index-iQYWEThN.cjs +11 -11
- package/schematics/bundles/inject-migration.cjs +1 -1
- package/schematics/bundles/leading_space-D9nQ8UQC.cjs +1 -1
- package/schematics/bundles/migrate_ts_type_references-BhOqwhYA.cjs +1 -1
- package/schematics/bundles/ng_decorators-B5HCqr20.cjs +1 -1
- package/schematics/bundles/nodes-B16H9JUd.cjs +1 -1
- package/schematics/bundles/output-migration.cjs +1 -1
- package/schematics/bundles/pending-tasks.cjs +1 -1
- package/schematics/bundles/project_paths-DePtMwan.cjs +1 -1
- package/schematics/bundles/project_tsconfig_paths-CDVxT6Ov.cjs +1 -1
- package/schematics/bundles/property_name-BBwFuqMe.cjs +1 -1
- package/schematics/bundles/provide-initializer.cjs +1 -1
- package/schematics/bundles/route-lazy-loading.cjs +1 -1
- package/schematics/bundles/self-closing-tags-migration.cjs +1 -1
- package/schematics/bundles/signal-input-migration.cjs +1 -1
- package/schematics/bundles/signal-queries-migration.cjs +1 -1
- package/schematics/bundles/signals.cjs +1 -1
- package/schematics/bundles/standalone-migration.cjs +1 -1
- package/testing/index.d.ts +1 -1
- package/weak_ref.d-DWHPG08n.d.ts +1 -1
package/fesm2022/core.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* @license Angular v19.2.
|
|
2
|
+
* @license Angular v19.2.22
|
|
3
3
|
* (c) 2010-2025 Google LLC. https://angular.io/
|
|
4
4
|
* License: MIT
|
|
5
5
|
*/
|
|
@@ -11510,9 +11510,9 @@ function validateAgainstEventProperties(name) {
|
|
|
11510
11510
|
}
|
|
11511
11511
|
function validateAgainstEventAttributes(name) {
|
|
11512
11512
|
if (name.toLowerCase().startsWith('on')) {
|
|
11513
|
-
|
|
11514
|
-
`
|
|
11515
|
-
|
|
11513
|
+
throw new RuntimeError(306 /* RuntimeErrorCode.INVALID_EVENT_BINDING */, ngDevMode &&
|
|
11514
|
+
`Binding to event attribute '${name}' is disallowed for security reasons, ` +
|
|
11515
|
+
`please use (${name.slice(2)})=...`);
|
|
11516
11516
|
}
|
|
11517
11517
|
}
|
|
11518
11518
|
function getSanitizer() {
|
|
@@ -12804,10 +12804,12 @@ function findDirectiveDefMatches(tView, tNode) {
|
|
|
12804
12804
|
function elementAttributeInternal(tNode, lView, name, value, sanitizer, namespace) {
|
|
12805
12805
|
if (ngDevMode) {
|
|
12806
12806
|
assertNotSame(value, NO_CHANGE, 'Incoming value should never be NO_CHANGE.');
|
|
12807
|
-
validateAgainstEventAttributes(name);
|
|
12808
12807
|
assertTNodeType(tNode, 2 /* TNodeType.Element */, `Attempted to set attribute \`${name}\` on a container node. ` +
|
|
12809
12808
|
`Host bindings are not valid on ng-container or ng-template.`);
|
|
12810
12809
|
}
|
|
12810
|
+
if (lView[TVIEW].firstUpdatePass) {
|
|
12811
|
+
validateAgainstEventAttributes(name);
|
|
12812
|
+
}
|
|
12811
12813
|
const element = getNativeByTNode(tNode, lView);
|
|
12812
12814
|
setElementAttribute(lView[RENDERER], element, namespace, tNode.value, name, value, sanitizer);
|
|
12813
12815
|
}
|
|
@@ -18086,7 +18088,7 @@ class ComponentFactory extends ComponentFactory$1 {
|
|
|
18086
18088
|
const cmpDef = this.componentDef;
|
|
18087
18089
|
ngDevMode && verifyNotAnOrphanComponent(cmpDef);
|
|
18088
18090
|
const tAttributes = rootSelectorOrNode
|
|
18089
|
-
? ['ng-version', '19.2.
|
|
18091
|
+
? ['ng-version', '19.2.22']
|
|
18090
18092
|
: // Extract attributes and classes from the first selector only to match VE behavior.
|
|
18091
18093
|
extractAttrsAndClassesFromSelector(this.componentDef.selectors[0]);
|
|
18092
18094
|
// Create the root view. Uses empty TView and ContentTemplate.
|
|
@@ -29476,7 +29478,7 @@ function i18nAttributesFirstPass(tView, index, values) {
|
|
|
29476
29478
|
// the compiler treats static i18n attributes as regular attribute bindings.
|
|
29477
29479
|
// Since this may not be the first i18n attribute on this element we need to pass in how
|
|
29478
29480
|
// many previous bindings there have already been.
|
|
29479
|
-
generateBindingUpdateOpCodes(updateOpCodes, message, previousElementIndex, attrName, countBindings(updateOpCodes),
|
|
29481
|
+
generateBindingUpdateOpCodes(updateOpCodes, message, previousElementIndex, attrName, countBindings(updateOpCodes), i18nSanitizeAttribute(attrName));
|
|
29480
29482
|
}
|
|
29481
29483
|
}
|
|
29482
29484
|
tView.data[index] = updateOpCodes;
|
|
@@ -29804,7 +29806,7 @@ function walkIcuTree(ast, tView, tIcu, lView, sharedUpdateOpCodes, create, remov
|
|
|
29804
29806
|
const hasBinding = !!attr.value.match(BINDING_REGEXP);
|
|
29805
29807
|
if (hasBinding) {
|
|
29806
29808
|
if (VALID_ATTRS.hasOwnProperty(lowerAttrName)) {
|
|
29807
|
-
generateBindingUpdateOpCodes(update, attr.value, newIndex, attr.name, 0,
|
|
29809
|
+
generateBindingUpdateOpCodes(update, attr.value, newIndex, attr.name, 0, i18nSanitizeAttribute(lowerAttrName));
|
|
29808
29810
|
}
|
|
29809
29811
|
else {
|
|
29810
29812
|
ngDevMode &&
|
|
@@ -29905,6 +29907,27 @@ function addCreateNodeAndAppend(create, marker, text, appendToParentIdx, createA
|
|
|
29905
29907
|
function addCreateAttribute(create, newIndex, attrName, attrValue) {
|
|
29906
29908
|
create.push((newIndex << 1 /* IcuCreateOpCode.SHIFT_REF */) | 1 /* IcuCreateOpCode.Attr */, attrName, attrValue);
|
|
29907
29909
|
}
|
|
29910
|
+
/**
|
|
29911
|
+
* Caches all keys of `SECURITY_SENSITIVE_ELEMENTS` in a Set to avoid recomputing
|
|
29912
|
+
* or scanning them on every invocation.
|
|
29913
|
+
*/
|
|
29914
|
+
const SECURITY_SENSITIVE_ATTRS = /* @__PURE__ */ (() => new Set(Object.values(SECURITY_SENSITIVE_ELEMENTS).flatMap((attrs) => (attrs ? [...attrs.keys()] : []))))();
|
|
29915
|
+
/**
|
|
29916
|
+
* Returns a sanitizer for the given attribute name or null if the attribute is not security sensitive.
|
|
29917
|
+
*
|
|
29918
|
+
* @param attrName The name of the attribute to sanitize.
|
|
29919
|
+
* @returns The sanitizer for the given attribute name.
|
|
29920
|
+
*/
|
|
29921
|
+
function i18nSanitizeAttribute(attrName) {
|
|
29922
|
+
const lowerAttrName = attrName.toLowerCase();
|
|
29923
|
+
if (SENSITIVE_ATTRS[lowerAttrName]) {
|
|
29924
|
+
return _sanitizeUrl;
|
|
29925
|
+
}
|
|
29926
|
+
if (SECURITY_SENSITIVE_ATTRS.has(lowerAttrName)) {
|
|
29927
|
+
return ɵɵvalidateAttribute;
|
|
29928
|
+
}
|
|
29929
|
+
return null;
|
|
29930
|
+
}
|
|
29908
29931
|
|
|
29909
29932
|
// i18nPostprocess consts
|
|
29910
29933
|
const ROOT_TEMPLATE_ID = 0;
|
|
@@ -34806,7 +34829,7 @@ class Version {
|
|
|
34806
34829
|
/**
|
|
34807
34830
|
* @publicApi
|
|
34808
34831
|
*/
|
|
34809
|
-
const VERSION = new Version('19.2.
|
|
34832
|
+
const VERSION = new Version('19.2.22');
|
|
34810
34833
|
|
|
34811
34834
|
/**
|
|
34812
34835
|
* Combination of NgModuleFactory and ComponentFactories.
|