@angular/core 17.3.0-next.1 → 17.3.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.
Files changed (79) hide show
  1. package/esm2022/rxjs-interop/src/index.mjs +3 -1
  2. package/esm2022/rxjs-interop/src/output_from_observable.mjs +68 -0
  3. package/esm2022/rxjs-interop/src/output_to_observable.mjs +29 -0
  4. package/esm2022/rxjs-interop/src/to_observable.mjs +1 -1
  5. package/esm2022/src/application/application_ref.mjs +56 -40
  6. package/esm2022/src/authoring/input/input.mjs +4 -1
  7. package/esm2022/src/authoring/input/input_type_checking.mjs +1 -1
  8. package/esm2022/src/authoring/model/model.mjs +4 -1
  9. package/esm2022/src/authoring/model/model_signal.mjs +9 -18
  10. package/esm2022/src/authoring/output/output.mjs +35 -0
  11. package/esm2022/src/authoring/output/output_emitter_ref.mjs +85 -0
  12. package/esm2022/src/authoring/output/output_ref.mjs +9 -0
  13. package/esm2022/src/authoring/queries.mjs +7 -1
  14. package/esm2022/src/authoring.mjs +3 -2
  15. package/esm2022/src/change_detection/scheduling/zoneless_scheduling.mjs +1 -1
  16. package/esm2022/src/change_detection/scheduling/zoneless_scheduling_impl.mjs +10 -4
  17. package/esm2022/src/core_private_export.mjs +4 -4
  18. package/esm2022/src/di/contextual.mjs +9 -3
  19. package/esm2022/src/di/interface/provider.mjs +1 -1
  20. package/esm2022/src/di/metadata.mjs +1 -1
  21. package/esm2022/src/di/r3_injector.mjs +26 -15
  22. package/esm2022/src/errors.mjs +1 -1
  23. package/esm2022/src/event_emitter.mjs +18 -2
  24. package/esm2022/src/hydration/annotate.mjs +4 -2
  25. package/esm2022/src/hydration/api.mjs +28 -3
  26. package/esm2022/src/hydration/cleanup.mjs +18 -2
  27. package/esm2022/src/hydration/interfaces.mjs +1 -1
  28. package/esm2022/src/hydration/node_lookup_utils.mjs +59 -39
  29. package/esm2022/src/hydration/tokens.mjs +6 -1
  30. package/esm2022/src/i18n/utils.mjs +16 -0
  31. package/esm2022/src/render3/after_render_hooks.mjs +12 -9
  32. package/esm2022/src/render3/component_ref.mjs +103 -93
  33. package/esm2022/src/render3/i18n/i18n_apply.mjs +32 -7
  34. package/esm2022/src/render3/i18n/i18n_parse.mjs +50 -16
  35. package/esm2022/src/render3/instructions/control_flow.mjs +4 -2
  36. package/esm2022/src/render3/instructions/element.mjs +5 -3
  37. package/esm2022/src/render3/instructions/element_container.mjs +3 -2
  38. package/esm2022/src/render3/instructions/listener.mjs +7 -9
  39. package/esm2022/src/render3/instructions/render.mjs +3 -2
  40. package/esm2022/src/render3/instructions/template.mjs +4 -2
  41. package/esm2022/src/render3/instructions/text.mjs +4 -2
  42. package/esm2022/src/render3/interfaces/i18n.mjs +1 -1
  43. package/esm2022/src/render3/interfaces/view.mjs +1 -1
  44. package/esm2022/src/render3/node_manipulation.mjs +18 -5
  45. package/esm2022/src/render3/node_selector_matcher.mjs +37 -51
  46. package/esm2022/src/render3/queue_state_update.mjs +2 -4
  47. package/esm2022/src/render3/reactivity/effect.mjs +11 -7
  48. package/esm2022/src/render3/reactivity/signal.mjs +3 -4
  49. package/esm2022/src/render3/util/view_utils.mjs +2 -1
  50. package/esm2022/src/render3/view_manipulation.mjs +24 -17
  51. package/esm2022/src/sanitization/html_sanitizer.mjs +54 -14
  52. package/esm2022/src/util/assert.mjs +7 -1
  53. package/esm2022/src/version.mjs +1 -1
  54. package/esm2022/testing/src/component_fixture.mjs +15 -11
  55. package/esm2022/testing/src/logger.mjs +3 -3
  56. package/esm2022/testing/src/test_bed_compiler.mjs +26 -4
  57. package/fesm2022/core.mjs +14049 -13736
  58. package/fesm2022/core.mjs.map +1 -1
  59. package/fesm2022/primitives/signals.mjs +1 -1
  60. package/fesm2022/rxjs-interop.mjs +82 -3
  61. package/fesm2022/rxjs-interop.mjs.map +1 -1
  62. package/fesm2022/testing.mjs +38 -12
  63. package/fesm2022/testing.mjs.map +1 -1
  64. package/index.d.ts +210 -78
  65. package/package.json +1 -1
  66. package/primitives/signals/index.d.ts +1 -1
  67. package/rxjs-interop/index.d.ts +39 -1
  68. package/schematics/migrations/block-template-entities/bundle.js +25 -34
  69. package/schematics/migrations/block-template-entities/bundle.js.map +3 -3
  70. package/schematics/migrations/invalid-two-way-bindings/bundle.js +26387 -0
  71. package/schematics/migrations/invalid-two-way-bindings/bundle.js.map +7 -0
  72. package/schematics/migrations.json +5 -0
  73. package/schematics/ng-generate/control-flow-migration/bundle.js +25 -34
  74. package/schematics/ng-generate/control-flow-migration/bundle.js.map +3 -3
  75. package/schematics/ng-generate/standalone-migration/bundle.js +424 -351
  76. package/schematics/ng-generate/standalone-migration/bundle.js.map +4 -4
  77. package/testing/index.d.ts +1 -1
  78. package/esm2022/src/authoring/output.mjs +0 -33
  79. package/esm2022/src/is_internal.mjs +0 -15
package/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Angular v17.3.0-next.1
2
+ * @license Angular v17.3.0
3
3
  * (c) 2010-2022 Google LLC. https://angular.io/
4
4
  * License: MIT
5
5
  */
@@ -644,6 +644,9 @@ export declare class ApplicationRef {
644
644
  private _destroyListeners;
645
645
  private readonly internalErrorHandler;
646
646
  private readonly afterRenderEffectManager;
647
+ private externalTestViews;
648
+ private beforeRender;
649
+ private afterTick;
647
650
  /**
648
651
  * Indicates whether this instance was destroyed.
649
652
  */
@@ -757,7 +760,6 @@ export declare class ApplicationRef {
757
760
  */
758
761
  tick(): void;
759
762
  private detectChangesInAttachedViews;
760
- private detectChangesInView;
761
763
  /**
762
764
  * Attaches a view so that it will be dirty checked.
763
765
  * The view will be automatically detached when it is destroyed.
@@ -1104,7 +1106,7 @@ declare interface ClassDebugInfo {
1104
1106
 
1105
1107
  /**
1106
1108
  * Configures the `Injector` to return an instance of `useClass` for a token.
1107
- * @see ["Dependency Injection Guide"](guide/dependency-injection).
1109
+ * @see [Dependency Injection Guide](guide/dependency-injection).
1108
1110
  *
1109
1111
  * @usageNotes
1110
1112
  *
@@ -1136,7 +1138,7 @@ export declare interface ClassProvider extends ClassSansProvider {
1136
1138
  * Configures the `Injector` to return a value by invoking a `useClass` function.
1137
1139
  * Base for `ClassProvider` decorator.
1138
1140
  *
1139
- * @see ["Dependency Injection Guide"](guide/dependency-injection).
1141
+ * @see [Dependency Injection Guide](guide/dependency-injection).
1140
1142
  *
1141
1143
  * @publicApi
1142
1144
  */
@@ -1817,7 +1819,7 @@ export declare function computed<T>(computation: () => T, options?: CreateComput
1817
1819
  /**
1818
1820
  * Configures the `Injector` to return an instance of a token.
1819
1821
  *
1820
- * @see ["Dependency Injection Guide"](guide/dependency-injection).
1822
+ * @see [Dependency Injection Guide](guide/dependency-injection).
1821
1823
  *
1822
1824
  * @usageNotes
1823
1825
  *
@@ -1844,7 +1846,7 @@ export declare interface ConstructorProvider extends ConstructorSansProvider {
1844
1846
  /**
1845
1847
  * Configures the `Injector` to return an instance of a token.
1846
1848
  *
1847
- * @see ["Dependency Injection Guide"](guide/dependency-injection).
1849
+ * @see [Dependency Injection Guide](guide/dependency-injection).
1848
1850
  *
1849
1851
  * @usageNotes
1850
1852
  *
@@ -2706,6 +2708,15 @@ declare interface DehydratedView {
2706
2708
  * nodes detected in this view at serialization time.
2707
2709
  */
2708
2710
  disconnectedNodes?: Set<number> | null;
2711
+ /**
2712
+ * A mapping from a view to the first child to begin claiming nodes.
2713
+ *
2714
+ * This mapping is generated by an i18n block, and is the source of
2715
+ * truth for the nodes inside of it. Once a view has been hydrated,
2716
+ * the node is removed from the map. The remaining entries indicate
2717
+ * dehydrated nodes that need to be cleaned up.
2718
+ */
2719
+ i18nNodes?: Map<number, RNode>;
2709
2720
  }
2710
2721
 
2711
2722
  /**
@@ -3801,7 +3812,7 @@ export declare class ErrorHandler {
3801
3812
  * @see [Observables in Angular](guide/observables-in-angular)
3802
3813
  * @publicApi
3803
3814
  */
3804
- export declare interface EventEmitter<T> extends Subject<T> {
3815
+ export declare interface EventEmitter<T> extends Subject<T>, OutputRef<T> {
3805
3816
  /**
3806
3817
  * Creates an instance of this class that can
3807
3818
  * deliver events synchronously or asynchronously.
@@ -3846,7 +3857,7 @@ export declare const EventEmitter: {
3846
3857
  /**
3847
3858
  * Configures the `Injector` to return a value of another `useExisting` token.
3848
3859
  *
3849
- * @see ["Dependency Injection Guide"](guide/dependency-injection).
3860
+ * @see [Dependency Injection Guide](guide/dependency-injection).
3850
3861
  *
3851
3862
  * @usageNotes
3852
3863
  *
@@ -3874,7 +3885,7 @@ export declare interface ExistingProvider extends ExistingSansProvider {
3874
3885
  * Configures the `Injector` to return a value of another `useExisting` token.
3875
3886
  *
3876
3887
  * @see {@link ExistingProvider}
3877
- * @see ["Dependency Injection Guide"](guide/dependency-injection).
3888
+ * @see [Dependency Injection Guide](guide/dependency-injection).
3878
3889
  *
3879
3890
  * @publicApi
3880
3891
  */
@@ -3902,7 +3913,7 @@ declare type FactoryFn<T> = {
3902
3913
 
3903
3914
  /**
3904
3915
  * Configures the `Injector` to return a value by invoking a `useFactory` function.
3905
- * @see ["Dependency Injection Guide"](guide/dependency-injection).
3916
+ * @see [Dependency Injection Guide](guide/dependency-injection).
3906
3917
  *
3907
3918
  * @usageNotes
3908
3919
  *
@@ -3934,7 +3945,7 @@ export declare interface FactoryProvider extends FactorySansProvider {
3934
3945
  * Configures the `Injector` to return a value by invoking a `useFactory` function.
3935
3946
  *
3936
3947
  * @see {@link FactoryProvider}
3937
- * @see ["Dependency Injection Guide"](guide/dependency-injection).
3948
+ * @see [Dependency Injection Guide](guide/dependency-injection).
3938
3949
  *
3939
3950
  * @publicApi
3940
3951
  */
@@ -4721,6 +4732,62 @@ declare interface I18nDebug {
4721
4732
  debug?: string[];
4722
4733
  }
4723
4734
 
4735
+ /**
4736
+ * Represents a simple DOM element in a translation, such as `<div>...</div>`
4737
+ */
4738
+ declare interface I18nElementNode {
4739
+ /** The AST node kind */
4740
+ kind: I18nNodeKind.ELEMENT;
4741
+ /** The LView index */
4742
+ index: number;
4743
+ /** The child nodes */
4744
+ children: Array<I18nNode>;
4745
+ }
4746
+
4747
+ /**
4748
+ * Represents an ICU in a translation.
4749
+ */
4750
+ declare interface I18nICUNode {
4751
+ /** The AST node kind */
4752
+ kind: I18nNodeKind.ICU;
4753
+ /** The LView index */
4754
+ index: number;
4755
+ /** The branching cases */
4756
+ cases: Array<Array<I18nNode>>;
4757
+ /** The LView index that stores the active case */
4758
+ currentCaseLViewIndex: number;
4759
+ }
4760
+
4761
+ declare type I18nNode = I18nTextNode | I18nElementNode | I18nICUNode | I18nPlaceholderNode;
4762
+
4763
+ declare const enum I18nNodeKind {
4764
+ TEXT = 0,
4765
+ ELEMENT = 1,
4766
+ PLACEHOLDER = 2,
4767
+ ICU = 3
4768
+ }
4769
+
4770
+ /**
4771
+ * Represents special content that is embedded into the translation. This can
4772
+ * either be a special built-in element, such as <ng-container> and <ng-content>,
4773
+ * or it can be a sub-template, for example, from a structural directive.
4774
+ */
4775
+ declare interface I18nPlaceholderNode {
4776
+ /** The AST node kind */
4777
+ kind: I18nNodeKind.PLACEHOLDER;
4778
+ /** The LView index */
4779
+ index: number;
4780
+ /** The child nodes */
4781
+ children: Array<I18nNode>;
4782
+ /** The placeholder type */
4783
+ type: I18nPlaceholderType;
4784
+ }
4785
+
4786
+ declare const enum I18nPlaceholderType {
4787
+ ELEMENT = 0,
4788
+ SUBTEMPLATE = 1
4789
+ }
4790
+
4724
4791
  /**
4725
4792
  * Stores a list of nodes which need to be removed.
4726
4793
  *
@@ -4732,6 +4799,16 @@ declare interface I18nRemoveOpCodes extends Array<number> {
4732
4799
  __brand__: 'I18nRemoveOpCodes';
4733
4800
  }
4734
4801
 
4802
+ /**
4803
+ * Represents a block of text in a translation, such as `Hello, {{ name }}!`.
4804
+ */
4805
+ declare interface I18nTextNode {
4806
+ /** The AST node kind */
4807
+ kind: I18nNodeKind.TEXT;
4808
+ /** The LView index */
4809
+ index: number;
4810
+ }
4811
+
4735
4812
  /**
4736
4813
  * Stores DOM operations which need to be applied to update DOM render tree due to changes in
4737
4814
  * expressions.
@@ -5189,7 +5266,7 @@ export declare interface InjectDecorator {
5189
5266
  * <code-example path="core/di/ts/metadata_spec.ts" region="InjectWithoutDecorator">
5190
5267
  * </code-example>
5191
5268
  *
5192
- * @see ["Dependency Injection Guide"](guide/dependency-injection)
5269
+ * @see [Dependency Injection Guide](guide/dependency-injection)
5193
5270
  *
5194
5271
  */
5195
5272
  (token: any): any;
@@ -6795,12 +6872,10 @@ export declare interface ModelOptions {
6795
6872
  *
6796
6873
  * @developerPreview
6797
6874
  */
6798
- export declare interface ModelSignal<T> extends WritableSignal<T> {
6875
+ export declare interface ModelSignal<T> extends WritableSignal<T>, OutputRef<T> {
6799
6876
  [SIGNAL]: InputSignalNode<T, T>;
6800
6877
  [ɵINPUT_SIGNAL_BRAND_READ_TYPE]: T;
6801
6878
  [ɵINPUT_SIGNAL_BRAND_WRITE_TYPE]: T;
6802
- /** @deprecated Do not use, will be removed. */
6803
- subscribe(callback: (value: T) => void): () => void;
6804
6879
  }
6805
6880
 
6806
6881
  /**
@@ -7401,6 +7476,12 @@ declare type NodeOutputBindings = Record<string, (number | string)[]>;
7401
7476
 
7402
7477
  declare const NODES = "n";
7403
7478
 
7479
+
7480
+ declare const enum NotificationType {
7481
+ RefreshViews = 0,
7482
+ AfterRenderHooks = 1
7483
+ }
7484
+
7404
7485
  declare const NUM_ROOT_NODES = "r";
7405
7486
 
7406
7487
  /**
@@ -7541,7 +7622,7 @@ export declare interface OptionalDecorator {
7541
7622
  * <code-example path="core/di/ts/metadata_spec.ts" region="Optional">
7542
7623
  * </code-example>
7543
7624
  *
7544
- * @see ["Dependency Injection Guide"](guide/dependency-injection).
7625
+ * @see [Dependency Injection Guide](guide/dependency-injection).
7545
7626
  */
7546
7627
  (): any;
7547
7628
  new (): Optional;
@@ -7565,6 +7646,29 @@ export declare interface Output {
7565
7646
  */
7566
7647
  export declare const Output: OutputDecorator;
7567
7648
 
7649
+ /**
7650
+ * The `output` function allows declaration of outputs in directives and
7651
+ * components.
7652
+ *
7653
+ * Initializes an output that can emit values to consumers of your
7654
+ * directive/component.
7655
+ *
7656
+ * @usageNotes
7657
+ * Initialize an output in your directive by declaring a
7658
+ * class field and initializing it with the `output()` function.
7659
+ *
7660
+ * ```ts
7661
+ * @Directive({..})
7662
+ * export class MyDir {
7663
+ * nameChange = output<string>(); // OutputEmitterRef<string>
7664
+ * onClick = output(); // OutputEmitterRef<void>
7665
+ * }
7666
+ * ```
7667
+ *
7668
+ * @developerPreview
7669
+ */
7670
+ export declare function output<T = void>(opts?: OutputOptions): OutputEmitterRef<T>;
7671
+
7568
7672
  /**
7569
7673
  * Type of the Output decorator / constructor function.
7570
7674
  *
@@ -7591,6 +7695,68 @@ export declare interface OutputDecorator {
7591
7695
  new (alias?: string): any;
7592
7696
  }
7593
7697
 
7698
+ /**
7699
+ * An `OutputEmitterRef` is created by the `output()` function and can be
7700
+ * used to emit values to consumers of your directive or component.
7701
+ *
7702
+ * Consumers of your directive/component can bind to the output and
7703
+ * subscribe to changes via the bound event syntax. For example:
7704
+ *
7705
+ * ```html
7706
+ * <my-comp (valueChange)="processNewValue($event)" />
7707
+ * ```
7708
+ *
7709
+ * @developerPreview
7710
+ */
7711
+ export declare class OutputEmitterRef<T> implements OutputRef<T> {
7712
+ private destroyed;
7713
+ private listeners;
7714
+ private errorHandler;
7715
+ constructor();
7716
+ subscribe(callback: (value: T) => void): OutputRefSubscription;
7717
+ /** Emits a new value to the output. */
7718
+ emit(value: T): void;
7719
+ }
7720
+
7721
+ /**
7722
+ * Options for declaring an output.
7723
+ *
7724
+ * @developerPreview
7725
+ */
7726
+ export declare interface OutputOptions {
7727
+ alias?: string;
7728
+ }
7729
+
7730
+ /**
7731
+ * A reference to an Angular output.
7732
+ *
7733
+ * @developerPreview
7734
+ */
7735
+ export declare interface OutputRef<T> {
7736
+ /**
7737
+ * Registers a callback that is invoked whenever the output
7738
+ * emits a new value of type `T`.
7739
+ *
7740
+ * Angular will automatically clean up the subscription when
7741
+ * the directive/component of the output is destroyed.
7742
+ */
7743
+ subscribe(callback: (value: T) => void): OutputRefSubscription;
7744
+ }
7745
+
7746
+
7747
+ /**
7748
+ * Function that can be used to manually clean up a
7749
+ * programmatic {@link OutputRef#subscribe} subscription.
7750
+ *
7751
+ * Note: Angular will automatically clean up subscriptions
7752
+ * when the directive/component of the output is destroyed.
7753
+ *
7754
+ * @developerPreview
7755
+ */
7756
+ export declare interface OutputRefSubscription {
7757
+ unsubscribe(): void;
7758
+ }
7759
+
7594
7760
  /**
7595
7761
  * A [DI token](guide/glossary#di-token "DI token definition") that indicates the root directory of
7596
7762
  * the application
@@ -7863,7 +8029,7 @@ declare type ProjectionSlots = (ɵCssSelectorList | '*')[];
7863
8029
 
7864
8030
  /**
7865
8031
  * Describes how the `Injector` should be configured.
7866
- * @see ["Dependency Injection Guide"](guide/dependency-injection).
8032
+ * @see [Dependency Injection Guide](guide/dependency-injection).
7867
8033
  *
7868
8034
  * @see {@link StaticProvider}
7869
8035
  *
@@ -9088,7 +9254,7 @@ export declare type StateKey<T> = string & {
9088
9254
 
9089
9255
  /**
9090
9256
  * Configures the `Injector` to return an instance of `useClass` for a token.
9091
- * @see ["Dependency Injection Guide"](guide/dependency-injection).
9257
+ * @see [Dependency Injection Guide](guide/dependency-injection).
9092
9258
  *
9093
9259
  * @usageNotes
9094
9260
  *
@@ -9140,7 +9306,7 @@ export declare interface StaticClassSansProvider {
9140
9306
  * A static provider provides tokens to an injector for various types of dependencies.
9141
9307
  *
9142
9308
  * @see {@link Injector.create()}
9143
- * @see ["Dependency Injection Guide"](guide/dependency-injection-providers).
9309
+ * @see [Dependency Injection Guide](guide/dependency-injection-providers).
9144
9310
  *
9145
9311
  * @publicApi
9146
9312
  */
@@ -9492,6 +9658,11 @@ declare interface TI18n {
9492
9658
  * DOM are required.
9493
9659
  */
9494
9660
  update: I18nUpdateOpCodes;
9661
+ /**
9662
+ * An AST representing the translated message. This is used for hydration (and serialization),
9663
+ * while the Update and Create OpCodes are used at runtime.
9664
+ */
9665
+ ast: Array<I18nNode>;
9495
9666
  }
9496
9667
 
9497
9668
  declare interface TIcu {
@@ -10837,7 +11008,7 @@ export declare type ValueEqualityFn<T> = (a: T, b: T) => boolean;
10837
11008
 
10838
11009
  /**
10839
11010
  * Configures the `Injector` to return a value for a token.
10840
- * @see ["Dependency Injection Guide"](guide/dependency-injection).
11011
+ * @see [Dependency Injection Guide](guide/dependency-injection).
10841
11012
  *
10842
11013
  * @usageNotes
10843
11014
  *
@@ -11410,14 +11581,11 @@ declare interface ViewRefTracker {
11410
11581
  detachView(viewRef: ViewRef): void;
11411
11582
  }
11412
11583
 
11413
- /** Symbol used distinguish `WritableSignal` from other non-writable signals and functions. */
11414
- declare const WRITABLE_SIGNAL: unique symbol;
11415
-
11416
11584
  /**
11417
11585
  * A `Signal` with a value that can be mutated via a setter interface.
11418
11586
  */
11419
11587
  export declare interface WritableSignal<T> extends Signal<T> {
11420
- [WRITABLE_SIGNAL]: T;
11588
+ [ɵWRITABLE_SIGNAL]: T;
11421
11589
  /**
11422
11590
  * Directly set the signal to a new value, and notify any dependents.
11423
11591
  */
@@ -11690,12 +11858,11 @@ export declare const enum ɵBypassType {
11690
11858
  Style = "Style"
11691
11859
  }
11692
11860
 
11693
-
11694
11861
  /**
11695
11862
  * Injectable that is notified when an `LView` is made aware of changes to application state.
11696
11863
  */
11697
11864
  export declare abstract class ɵChangeDetectionScheduler {
11698
- abstract notify(): void;
11865
+ abstract notify(source?: NotificationType): void;
11699
11866
  }
11700
11867
 
11701
11868
  export declare function ɵclearResolutionOfComponentResourcesQueue(): Map<Type<any>, Component>;
@@ -12014,6 +12181,8 @@ export declare enum ɵDeferBlockState {
12014
12181
  /** The deps tracker to be used in the current Angular app in dev mode. */
12015
12182
  export declare const ɵdepsTracker: DepsTracker;
12016
12183
 
12184
+ export declare function ɵdetectChangesInViewIfRequired(lView: LView, isFirstPass: boolean, notifyErrorHandler: boolean): void;
12185
+
12017
12186
 
12018
12187
  export declare function ɵdevModeEqual(a: any, b: any): boolean;
12019
12188
 
@@ -12338,6 +12507,9 @@ export declare function ɵgetLocaleCurrencyCode(locale: string): string | null;
12338
12507
  */
12339
12508
  export declare function ɵgetLocalePluralCase(locale: string): (value: number) => number;
12340
12509
 
12510
+ /** Gets the owning `DestroyRef` for the given output. */
12511
+ export declare function ɵgetOutputDestroyRef(ref: OutputRef<unknown>): DestroyRef | undefined;
12512
+
12341
12513
  export declare function ɵgetSanitizationBypassType(value: any): ɵBypassType | null;
12342
12514
 
12343
12515
  /**
@@ -12739,56 +12911,6 @@ export declare function ɵnoSideEffects<T>(fn: () => T): T;
12739
12911
 
12740
12912
  export declare const ɵNOT_FOUND_CHECK_ONLY_ELEMENT_INJECTOR: {};
12741
12913
 
12742
- /**
12743
- * The `outputs` function allows declaration of outputs in directives and
12744
- * components.
12745
- *
12746
- * Initializes an output that can emit values to consumers of your
12747
- * directive/component.
12748
- *
12749
- * @usageNotes
12750
- * Initialize an output in your directive by declaring a
12751
- * class field and initializing it with the `output()` function.
12752
- *
12753
- * ```ts
12754
- * @Directive({..})
12755
- * export class MyDir {
12756
- * nameChange = output<string>(); // OutputEmitter<string>
12757
- * onClick = output(); // OutputEmitter<void>
12758
- * }
12759
- * ```
12760
- *
12761
- * @developerPreview
12762
- */
12763
- export declare function ɵoutput<T = void>(opts?: ɵOutputOptions): ɵOutputEmitter<T>;
12764
-
12765
-
12766
- /**
12767
- * An `OutputEmitter` is created by the `output()` function and can be
12768
- * used to emit values to consumers of your directive or component.
12769
- *
12770
- * Consumers of your directive/component can bind to the output and
12771
- * subscribe to changes via the bound event syntax. For example:
12772
- *
12773
- * ```html
12774
- * <my-comp (valueChange)="processNewValue($event)" />
12775
- * ```
12776
- *
12777
- * @developerPreview
12778
- */
12779
- export declare interface ɵOutputEmitter<T> {
12780
- emit(value: T): void;
12781
- }
12782
-
12783
- /**
12784
- * Options for declaring an output.
12785
- *
12786
- * @developerPreview
12787
- */
12788
- export declare interface ɵOutputOptions {
12789
- alias?: string;
12790
- }
12791
-
12792
12914
  /**
12793
12915
  * Patch the definition of a component with directives and pipes from the compilation scope of
12794
12916
  * a given module.
@@ -13235,6 +13357,7 @@ export declare const enum ɵRuntimeErrorCode {
13235
13357
  REQUIRED_INPUT_NO_VALUE = -950,
13236
13358
  REQUIRED_QUERY_NO_VALUE = -951,
13237
13359
  REQUIRED_MODEL_NO_VALUE = -952,
13360
+ OUTPUT_REF_DESTROYED = 953,
13238
13361
  RUNTIME_DEPS_INVALID_IMPORTED_TYPE = 1000,
13239
13362
  RUNTIME_DEPS_ORPHAN_COMPONENT = 1001
13240
13363
  }
@@ -13433,7 +13556,7 @@ export declare type ɵUnwrapDirectiveSignalInputs<Dir, Fields extends keyof Dir>
13433
13556
  };
13434
13557
 
13435
13558
  /** Retrieves the `WriteT` of an `InputSignal` and `InputSignalWithTransform`. */
13436
- declare type ɵUnwrapInputSignalWriteType<Field> = Field extends InputSignalWithTransform<unknown, infer WriteT> ? WriteT : never;
13559
+ declare type ɵUnwrapInputSignalWriteType<Field> = Field extends InputSignalWithTransform<any, infer WriteT> ? WriteT : never;
13437
13560
 
13438
13561
  export declare function ɵunwrapSafeValue(value: ɵSafeValue): string;
13439
13562
 
@@ -13444,7 +13567,7 @@ export declare function ɵunwrapSafeValue<T>(value: T): T;
13444
13567
  * @codeGenApi
13445
13568
  */
13446
13569
  export declare function ɵunwrapWritableSignal<T>(value: T | {
13447
- [WRITABLE_SIGNAL]: T;
13570
+ [ɵWRITABLE_SIGNAL]: T;
13448
13571
  }): T;
13449
13572
 
13450
13573
  /**
@@ -13693,6 +13816,12 @@ export declare function ɵwhenStable(applicationRef: ApplicationRef): Promise<vo
13693
13816
  */
13694
13817
  export declare function ɵwithDomHydration(): EnvironmentProviders;
13695
13818
 
13819
+ /**
13820
+ * Returns a set of providers required to setup support for i18n hydration.
13821
+ * Requires hydration to be enabled separately.
13822
+ */
13823
+ export declare function ɵwithI18nHydration(): EnvironmentProviders;
13824
+
13696
13825
  /**
13697
13826
  * Returns a writable type version of type.
13698
13827
  *
@@ -13722,6 +13851,9 @@ export declare type ɵWritable<T> = {
13722
13851
  -readonly [K in keyof T]: T[K];
13723
13852
  };
13724
13853
 
13854
+ /** Symbol used distinguish `WritableSignal` from other non-writable signals and functions. */
13855
+ declare const ɵWRITABLE_SIGNAL: unique symbol;
13856
+
13725
13857
  /**
13726
13858
  * URL for the XSS security documentation.
13727
13859
  */
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@angular/core",
3
- "version": "17.3.0-next.1",
3
+ "version": "17.3.0",
4
4
  "description": "Angular - the core framework",
5
5
  "author": "angular",
6
6
  "license": "MIT",
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Angular v17.3.0-next.1
2
+ * @license Angular v17.3.0
3
3
  * (c) 2010-2022 Google LLC. https://angular.io/
4
4
  * License: MIT
5
5
  */
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license Angular v17.3.0-next.1
2
+ * @license Angular v17.3.0
3
3
  * (c) 2010-2022 Google LLC. https://angular.io/
4
4
  * License: MIT
5
5
  */
@@ -9,9 +9,47 @@ import { DestroyRef } from '@angular/core';
9
9
  import { Injector } from '@angular/core';
10
10
  import { MonoTypeOperatorFunction } from 'rxjs';
11
11
  import { Observable } from 'rxjs';
12
+ import { OutputOptions } from '@angular/core';
13
+ import { OutputRef } from '@angular/core';
12
14
  import { Signal } from '@angular/core';
13
15
  import { Subscribable } from 'rxjs';
14
16
 
17
+ /**
18
+ * Declares an Angular output that is using an RxJS observable as a source
19
+ * for events dispatched to parent subscribers.
20
+ *
21
+ * The behavior for an observable as source is defined as followed:
22
+ * 1. New values are forwarded to the Angular output (next notifications).
23
+ * 2. Errors notifications are not handled by Angular. You need to handle these manually.
24
+ * For example by using `catchError`.
25
+ * 3. Completion notifications stop the output from emitting new values.
26
+ *
27
+ * @usageNotes
28
+ * Initialize an output in your directive by declaring a
29
+ * class field and initializing it with the `outputFromObservable()` function.
30
+ *
31
+ * ```ts
32
+ * @Directive({..})
33
+ * export class MyDir {
34
+ * nameChange$ = <some-observable>;
35
+ * nameChange = outputFromObservable(this.nameChange$);
36
+ * }
37
+ * ```
38
+ *
39
+ * @developerPreview
40
+ */
41
+ export declare function outputFromObservable<T>(observable: Observable<T>, opts?: OutputOptions): OutputRef<T>;
42
+
43
+ /**
44
+ * Converts an Angular output declared via `output()` or `outputFromObservable()`
45
+ * to an observable.
46
+ *
47
+ * You can subscribe to the output via `Observable.subscribe` then.
48
+ *
49
+ * @developerPreview
50
+ */
51
+ export declare function outputToObservable<T>(ref: OutputRef<T>): Observable<T>;
52
+
15
53
  /**
16
54
  * Operator which completes the Observable when the calling context (component, directive, service,
17
55
  * etc) is destroyed.