@praxisui/core 9.0.5-rc.6 → 9.0.5-rc.8

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.
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "schemaVersion": "1.0.0",
3
- "generatedAt": "2026-08-12T11:44:06.033Z",
3
+ "generatedAt": "2026-08-12T14:05:00.897Z",
4
4
  "packageName": "@praxisui/core",
5
- "packageVersion": "9.0.5-rc.6",
5
+ "packageVersion": "9.0.5-rc.8",
6
6
  "sourceRegistry": "praxis-component-registry-ingestion",
7
7
  "sourceRegistryVersion": "1.0.0",
8
8
  "componentCount": 4,
@@ -2,7 +2,7 @@ import * as i0 from '@angular/core';
2
2
  import { Component, InjectionToken, Injectable, inject, Inject, Optional, makeEnvironmentProviders, APP_INITIALIZER, signal, computed, DestroyRef, ENVIRONMENT_INITIALIZER, ErrorHandler, Input, Directive, input, booleanAttribute, ChangeDetectionStrategy, EventEmitter, Output, SecurityContext, ViewContainerRef, SimpleChange, ContentChild, HostBinding, HostListener, ViewChildren, ViewChild, Injector, output, effect } from '@angular/core';
3
3
  import * as i1 from '@angular/common/http';
4
4
  import { HttpHeaders, HttpClient, HttpParams, HttpResponse, HttpContextToken, HTTP_INTERCEPTORS, withInterceptors } from '@angular/common/http';
5
- import { of, defer, throwError, from, EMPTY, BehaviorSubject, firstValueFrom, Subject, map as map$1, switchMap as switchMap$1, catchError as catchError$1 } from 'rxjs';
5
+ import { of, defer, throwError, from, EMPTY, BehaviorSubject, firstValueFrom, Subject, finalize as finalize$1, shareReplay as shareReplay$1, map as map$1, switchMap as switchMap$1, catchError as catchError$1 } from 'rxjs';
6
6
  import { switchMap, take, map, catchError, concatMap, tap, shareReplay, takeUntil, toArray, finalize } from 'rxjs/operators';
7
7
  import * as i1$3 from '@angular/common';
8
8
  import { Location, DOCUMENT, CommonModule } from '@angular/common';
@@ -13805,6 +13805,7 @@ class ResourceDiscoveryService {
13805
13805
  http = inject(HttpClient);
13806
13806
  schemaNormalizer = inject(SchemaNormalizerService);
13807
13807
  apiUrlConfig = inject(API_URL);
13808
+ surfaceCatalogInFlightByHref = new Map();
13808
13809
  getLinks(source, rel) {
13809
13810
  const candidate = this.extractLinks(source)?.[rel];
13810
13811
  if (!candidate) {
@@ -13826,7 +13827,19 @@ class ResourceDiscoveryService {
13826
13827
  return this.fetchJson(this.requireLinkHref(source, rel, options), options);
13827
13828
  }
13828
13829
  getSurfaces(source, options) {
13829
- return this.followLink(source, 'surfaces', options);
13830
+ const href = this.requireLinkHref(source, 'surfaces', options);
13831
+ const existing = this.surfaceCatalogInFlightByHref.get(href);
13832
+ if (existing) {
13833
+ return existing;
13834
+ }
13835
+ let request;
13836
+ request = this.fetchJson(href, options).pipe(finalize$1(() => {
13837
+ if (this.surfaceCatalogInFlightByHref.get(href) === request) {
13838
+ this.surfaceCatalogInFlightByHref.delete(href);
13839
+ }
13840
+ }), shareReplay$1({ bufferSize: 1, refCount: true }));
13841
+ this.surfaceCatalogInFlightByHref.set(href, request);
13842
+ return request;
13830
13843
  }
13831
13844
  getActions(source, options) {
13832
13845
  return this.followLink(source, 'actions', options);
@@ -41775,7 +41788,7 @@ class PraxisRelatedResourceOutletComponent {
41775
41788
  const discovery = this.injector.get(ResourceDiscoveryService);
41776
41789
  const catalog$ = discoverySource
41777
41790
  ? discovery.getSurfaces(discoverySource, options)
41778
- : discovery.fetchJson(href, options);
41791
+ : discovery.getSurfaces({ surfaces: { href: href } }, options);
41779
41792
  this.discoverySubscription = catalog$.subscribe({
41780
41793
  next: (response) => {
41781
41794
  if (this.discoveryRequestKey !== requestKey) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@praxisui/core",
3
- "version": "9.0.5-rc.6",
3
+ "version": "9.0.5-rc.8",
4
4
  "description": "Core library for Praxis UI Workspace: types, tokens, services and utilities shared across @praxisui/* packages.",
5
5
  "peerDependencies": {
6
6
  "@angular/common": "^21.0.0",
@@ -9349,6 +9349,7 @@ declare class ResourceDiscoveryService {
9349
9349
  private readonly http;
9350
9350
  private readonly schemaNormalizer;
9351
9351
  private readonly apiUrlConfig;
9352
+ private readonly surfaceCatalogInFlightByHref;
9352
9353
  getLinks(source: ResourceLinkSource | null | undefined, rel: string): HateoasLink[];
9353
9354
  getLink(source: ResourceLinkSource | null | undefined, rel: string): HateoasLink | null;
9354
9355
  hasLink(source: ResourceLinkSource | null | undefined, rel: string): boolean;