valtech-components 4.0.630 → 4.0.633
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/esm2022/lib/components/organisms/mini-games/chessimals-adventure-data.mjs +3 -3
- package/esm2022/lib/components/organisms/mini-games/chessimals-adventure.component.mjs +75 -20
- package/esm2022/lib/components/organisms/mini-games/chessimals-engine.mjs +10 -10
- package/esm2022/lib/components/organisms/mini-games/chessimals-game.component.mjs +11 -11
- package/esm2022/lib/components/organisms/mini-games/mini-games.i18n.mjs +5 -5
- package/esm2022/lib/components/organisms/mini-games/types.mjs +1 -1
- package/esm2022/lib/services/auth/auth.service.mjs +78 -1
- package/esm2022/lib/services/auth/types.mjs +1 -1
- package/esm2022/lib/version.mjs +2 -2
- package/fesm2022/valtech-components.mjs +177 -45
- package/fesm2022/valtech-components.mjs.map +1 -1
- package/lib/components/atoms/rights-footer/rights-footer.component.d.ts +1 -1
- package/lib/components/molecules/cta-card/cta-card.component.d.ts +1 -1
- package/lib/components/molecules/metric-card/metric-card.component.d.ts +1 -1
- package/lib/components/molecules/phone-display/phone-display.component.d.ts +1 -1
- package/lib/components/organisms/account-view/account-view.component.d.ts +1 -1
- package/lib/components/organisms/article/article.component.d.ts +1 -1
- package/lib/components/organisms/auth-cta/auth-cta.component.d.ts +1 -1
- package/lib/components/organisms/member-import-modal/member-import-modal.component.d.ts +1 -1
- package/lib/components/organisms/mini-games/chessimals-adventure.component.d.ts +4 -1
- package/lib/components/organisms/mini-games/chessimals-game.component.d.ts +1 -1
- package/lib/components/organisms/mini-games/memory-game.component.d.ts +1 -1
- package/lib/components/organisms/mini-games/types.d.ts +2 -2
- package/lib/components/organisms/notification-preferences-view/notification-preferences-view.component.d.ts +1 -1
- package/lib/components/organisms/organization-view/organization-view.component.d.ts +1 -1
- package/lib/services/auth/auth.service.d.ts +33 -0
- package/lib/services/auth/types.d.ts +35 -0
- package/lib/version.d.ts +1 -1
- package/package.json +1 -1
- /package/src/lib/assets/games/chessimals/challenge-avatars/{nightmare-magnus.png → nightmare-mandrill.png} +0 -0
|
@@ -39,7 +39,7 @@ export declare class RightsFooterComponent {
|
|
|
39
39
|
/**
|
|
40
40
|
* Computed helper for align prop in template.
|
|
41
41
|
*/
|
|
42
|
-
propsAlign: import("@angular/core").Signal<"center" | "
|
|
42
|
+
propsAlign: import("@angular/core").Signal<"center" | "right" | "left">;
|
|
43
43
|
/**
|
|
44
44
|
* Computed helper for color prop in template.
|
|
45
45
|
*/
|
|
@@ -35,7 +35,7 @@ export declare class CtaCardComponent {
|
|
|
35
35
|
/** Emitted with the token of the clicked action button */
|
|
36
36
|
onAction: EventEmitter<string>;
|
|
37
37
|
/** Merged configuration with defaults */
|
|
38
|
-
config: import("@angular/core").Signal<CtaCardMetadata & Required<Pick<CtaCardMetadata, "
|
|
38
|
+
config: import("@angular/core").Signal<CtaCardMetadata & Required<Pick<CtaCardMetadata, "padding" | "borderRadius" | "bordered" | "shadowed" | "align">>>;
|
|
39
39
|
getBackground(): string;
|
|
40
40
|
getColor(): string | null;
|
|
41
41
|
static ɵfac: i0.ɵɵFactoryDeclaration<CtaCardComponent, never>;
|
|
@@ -28,7 +28,7 @@ export declare class MetricCardComponent {
|
|
|
28
28
|
/** Emitted with the token of the clicked action */
|
|
29
29
|
onAction: EventEmitter<string>;
|
|
30
30
|
/** Merged configuration with defaults */
|
|
31
|
-
config: import("@angular/core").Signal<MetricCardMetadata & Required<Pick<MetricCardMetadata, "
|
|
31
|
+
config: import("@angular/core").Signal<MetricCardMetadata & Required<Pick<MetricCardMetadata, "padding" | "borderRadius" | "bordered" | "shadowed">>>;
|
|
32
32
|
static ɵfac: i0.ɵɵFactoryDeclaration<MetricCardComponent, never>;
|
|
33
33
|
static ɵcmp: i0.ɵɵComponentDeclaration<MetricCardComponent, "val-metric-card", never, { "props": { "alias": "props"; "required": false; "isSignal": true; }; }, { "onAction": "onAction"; }, never, never, true, never>;
|
|
34
34
|
}
|
|
@@ -6,7 +6,7 @@ export declare class PhoneDisplayComponent {
|
|
|
6
6
|
props: PhoneDisplayMetadata;
|
|
7
7
|
onClick: EventEmitter<string>;
|
|
8
8
|
protected rawPhone: import("@angular/core").Signal<string>;
|
|
9
|
-
protected mode: import("@angular/core").Signal<"button" | "
|
|
9
|
+
protected mode: import("@angular/core").Signal<"button" | "text" | "link">;
|
|
10
10
|
protected formatted: import("@angular/core").Signal<string>;
|
|
11
11
|
protected href: import("@angular/core").Signal<string>;
|
|
12
12
|
protected ariaLabel: import("@angular/core").Signal<string>;
|
|
@@ -34,7 +34,7 @@ export declare class AccountViewComponent {
|
|
|
34
34
|
* mergea con los defaults — `@Input` gana sobre route data.
|
|
35
35
|
*/
|
|
36
36
|
config?: AccountViewConfig;
|
|
37
|
-
readonly resolvedConfig: import("@angular/core").Signal<Required<Omit<AccountViewConfig, "
|
|
37
|
+
readonly resolvedConfig: import("@angular/core").Signal<Required<Omit<AccountViewConfig, "onOrgCreated" | "onOrgSwitched" | "onLoggedOut" | "onAccountDeleted">> & Pick<AccountViewConfig, "onOrgCreated" | "onOrgSwitched" | "onLoggedOut" | "onAccountDeleted">>;
|
|
38
38
|
/** Namespace i18n resuelto (capturado para llamadas no-reactivas). */
|
|
39
39
|
private get ns();
|
|
40
40
|
readonly createOrgOpen: import("@angular/core").WritableSignal<boolean>;
|
|
@@ -57,7 +57,7 @@ export declare class ArticleComponent implements OnInit {
|
|
|
57
57
|
linkConfig?: import("valtech-components").LinkProcessorConfig;
|
|
58
58
|
allowPartialBold?: boolean;
|
|
59
59
|
authorColor?: import("@ionic/core").Color;
|
|
60
|
-
alignment?: "center" | "
|
|
60
|
+
alignment?: "center" | "right" | "left";
|
|
61
61
|
showQuoteMark?: boolean;
|
|
62
62
|
};
|
|
63
63
|
getHighlightTextProps(element: ArticleElement): {
|
|
@@ -35,7 +35,7 @@ export declare class AuthCtaComponent {
|
|
|
35
35
|
onRegister: EventEmitter<void>;
|
|
36
36
|
constructor();
|
|
37
37
|
/** Merged configuration with defaults */
|
|
38
|
-
config: import("@angular/core").Signal<AuthCtaMetadata & Required<Pick<AuthCtaMetadata, "
|
|
38
|
+
config: import("@angular/core").Signal<AuthCtaMetadata & Required<Pick<AuthCtaMetadata, "padding" | "borderRadius" | "align">>>;
|
|
39
39
|
loginLabel: import("@angular/core").Signal<string>;
|
|
40
40
|
registerLabel: import("@angular/core").Signal<string>;
|
|
41
41
|
topLogoProps: import("@angular/core").Signal<{
|
|
@@ -28,7 +28,7 @@ export declare class MemberImportModalComponent implements OnInit {
|
|
|
28
28
|
/** Namespace i18n. */
|
|
29
29
|
i18nNamespace: string;
|
|
30
30
|
csv: string;
|
|
31
|
-
readonly importMode: import("@angular/core").WritableSignal<"
|
|
31
|
+
readonly importMode: import("@angular/core").WritableSignal<"file" | "paste">;
|
|
32
32
|
readonly onConflictControl: FormControl<string>;
|
|
33
33
|
readonly sendActivationControl: FormControl<boolean>;
|
|
34
34
|
readonly conflictSelectProps: import("@angular/core").Signal<Partial<InputMetadata>>;
|
|
@@ -24,8 +24,11 @@ export declare class ChessimalsAdventureComponent {
|
|
|
24
24
|
readonly actViews: import("@angular/core").Signal<AdventureActView[]>;
|
|
25
25
|
constructor();
|
|
26
26
|
t(key: string): string;
|
|
27
|
+
private readonly ADV_ACT_THEMES;
|
|
27
28
|
avatarSrc(profileId: string): string;
|
|
28
|
-
|
|
29
|
+
actAssetSrc(actId: string): string;
|
|
30
|
+
actBgSrc(actId: string): string;
|
|
31
|
+
nodeAssetSrc(type: ChessimalsAdventureNode['type']): string;
|
|
29
32
|
onNodeTap(nodeView: AdventureNodeView): void;
|
|
30
33
|
dismissEncounter(): void;
|
|
31
34
|
confirmPlay(): void;
|
|
@@ -133,7 +133,7 @@ export declare class ChessimalsGameComponent implements OnInit, OnDestroy {
|
|
|
133
133
|
readonly botProfiles: ChessimalsBotProfile[];
|
|
134
134
|
readonly challengeLadder: ChessimalsChallengeBot[];
|
|
135
135
|
readonly animals: ChessimalsAnimalView[];
|
|
136
|
-
readonly valtechComponentsVersion = "4.0.
|
|
136
|
+
readonly valtechComponentsVersion = "4.0.633";
|
|
137
137
|
readonly screen: import("@angular/core").WritableSignal<"home" | "challenge" | "path" | "game">;
|
|
138
138
|
readonly selectedBoardSize: import("@angular/core").WritableSignal<ChessimalsBoardSize>;
|
|
139
139
|
readonly selectedLocalMode: import("@angular/core").WritableSignal<ChessimalsLocalMode>;
|
|
@@ -58,7 +58,7 @@ export declare class MemoryGameComponent implements OnDestroy {
|
|
|
58
58
|
readonly playerName: import("@angular/core").Signal<string>;
|
|
59
59
|
readonly activePlayerAvatar: import("@angular/core").Signal<string>;
|
|
60
60
|
readonly activePlayerColor: import("@angular/core").Signal<string>;
|
|
61
|
-
readonly timeLabel: import("@angular/core").Signal<"
|
|
61
|
+
readonly timeLabel: import("@angular/core").Signal<"timeLeft" | "time">;
|
|
62
62
|
readonly formattedTime: import("@angular/core").Signal<string>;
|
|
63
63
|
readonly resultMedal: import("@angular/core").Signal<MemoryMedal>;
|
|
64
64
|
readonly resultSeconds: import("@angular/core").Signal<number>;
|
|
@@ -52,8 +52,8 @@ export type ChessimalsWinReason = 'promotion' | 'elimination' | 'resignation' |
|
|
|
52
52
|
export type ChessimalsGameMode = 'local' | 'online';
|
|
53
53
|
export type ChessimalsLocalMode = 'one-device' | 'bot';
|
|
54
54
|
export type ChessimalsBotDifficulty = 'easy' | 'normal' | 'hard' | 'master';
|
|
55
|
-
export type ChessimalsNightmareMode = 'none' | 'hunt' | 'pride' | '
|
|
56
|
-
export type ChessimalsBotProfileId = 'explorer' | 'bull' | 'hare' | 'hunter' | 'guardian' | 'jumper' | 'strategist' | 'predator' | 'cheetah' | 'sentinel' | 'oracle' | 'ambusher' | 'turtle' | 'storm' | 'matriarch' | 'anaconda' | '
|
|
55
|
+
export type ChessimalsNightmareMode = 'none' | 'hunt' | 'pride' | 'mandrill';
|
|
56
|
+
export type ChessimalsBotProfileId = 'explorer' | 'bull' | 'hare' | 'hunter' | 'guardian' | 'jumper' | 'strategist' | 'predator' | 'cheetah' | 'sentinel' | 'oracle' | 'ambusher' | 'turtle' | 'storm' | 'matriarch' | 'anaconda' | 'mandrill';
|
|
57
57
|
export type ChessimalsGameStatus = 'waiting' | 'in_progress' | 'finished' | 'expired';
|
|
58
58
|
export interface ChessimalsBotProfile {
|
|
59
59
|
id: ChessimalsBotProfileId;
|
|
@@ -90,7 +90,7 @@ export declare class NotificationPreferencesViewComponent implements OnInit, OnD
|
|
|
90
90
|
readonly busyLabel: import("@angular/core").Signal<string>;
|
|
91
91
|
readonly contextMessage: import("@angular/core").Signal<string>;
|
|
92
92
|
readonly alertVariant: import("@angular/core").Signal<"warning" | "danger" | "info">;
|
|
93
|
-
readonly alertIcon: import("@angular/core").Signal<"
|
|
93
|
+
readonly alertIcon: import("@angular/core").Signal<"close-circle-outline" | "alert-circle-outline">;
|
|
94
94
|
readonly toggleProps: import("@angular/core").Signal<ToggleInputMetadata>;
|
|
95
95
|
readonly retryButtonProps: import("@angular/core").Signal<Partial<ButtonMetadata>>;
|
|
96
96
|
readonly tokenPreview: import("@angular/core").Signal<string>;
|
|
@@ -53,7 +53,7 @@ export declare class OrganizationViewComponent {
|
|
|
53
53
|
* `resolvedConfig` mergea con los defaults — `@Input` gana sobre route data.
|
|
54
54
|
*/
|
|
55
55
|
config?: OrganizationViewConfig;
|
|
56
|
-
readonly resolvedConfig: import("@angular/core").Signal<Required<Omit<OrganizationViewConfig, "
|
|
56
|
+
readonly resolvedConfig: import("@angular/core").Signal<Required<Omit<OrganizationViewConfig, "onOrgEdited" | "onMemberInvited" | "onOwnershipTransferred" | "onLeftOrg" | "onOrgDeleted" | "onOrgCreated">> & Pick<OrganizationViewConfig, "onOrgEdited" | "onMemberInvited" | "onOwnershipTransferred" | "onLeftOrg" | "onOrgDeleted" | "onOrgCreated">>;
|
|
57
57
|
/** Namespace i18n resuelto (capturado para llamadas no-reactivas). */
|
|
58
58
|
private get ns();
|
|
59
59
|
readonly org: import("@angular/core").WritableSignal<Organization>;
|
|
@@ -104,6 +104,39 @@ export declare class AuthService implements OnDestroy {
|
|
|
104
104
|
* dev cross-site con cookie de terceros bloqueada) → invitado.
|
|
105
105
|
*/
|
|
106
106
|
private bootstrapSessionFromHintCookie;
|
|
107
|
+
/**
|
|
108
|
+
* Nombre de la sessionStorage key usada como guarda anti-loop del bridge.
|
|
109
|
+
* `sessionStorage` (no localStorage) — el guard debe expirar naturalmente al
|
|
110
|
+
* cerrar la pestaña; una sesión de familia recién iniciada en otra pestaña
|
|
111
|
+
* debe poder reintentar el bridge en una pestaña nueva.
|
|
112
|
+
*/
|
|
113
|
+
private static readonly SSO_BRIDGE_GUARD_KEY;
|
|
114
|
+
/**
|
|
115
|
+
* ¿Corresponde disparar el redirect al Auth Proxy Central (ADR-050 Modo B)?
|
|
116
|
+
*
|
|
117
|
+
* Falso si: la config no lo habilita, falta `ssoBridgeUrl`, no corremos en
|
|
118
|
+
* un browser real (SSR/tests), o esta pestaña YA volvió de un intento de
|
|
119
|
+
* bridge — sin este último guard, un bridge que redirige sin `?handoff`
|
|
120
|
+
* (sin sesión) dispararía un bucle infinito de redirects en cada
|
|
121
|
+
* `initialize()` posterior de la misma pestaña.
|
|
122
|
+
*/
|
|
123
|
+
private shouldBootstrapViaSSOBridge;
|
|
124
|
+
/**
|
|
125
|
+
* Navega la página completa al Auth Proxy Central con `redirect_uri` = la
|
|
126
|
+
* URL actual. El backend valida la cookie `valtech_refresh` (visible solo
|
|
127
|
+
* en su propio dominio, por eso el redirect debe ser top-level navigation
|
|
128
|
+
* y no un fetch) y redirige de vuelta con `?handoff=TOKEN` si hay sesión.
|
|
129
|
+
*
|
|
130
|
+
* Marca el guard ANTES de navegar — si el bridge redirige sin `?handoff`
|
|
131
|
+
* (sin sesión), el siguiente `initialize()` de esta pestaña no debe volver
|
|
132
|
+
* a intentar el bridge.
|
|
133
|
+
*/
|
|
134
|
+
private redirectToSSOBridge;
|
|
135
|
+
/**
|
|
136
|
+
* Navegación real (aislada en su propio método para poder espiarla en
|
|
137
|
+
* tests unitarios sin que Karma navegue de verdad el runner).
|
|
138
|
+
*/
|
|
139
|
+
private navigateToSSOBridgeUrl;
|
|
107
140
|
ngOnDestroy(): void;
|
|
108
141
|
/**
|
|
109
142
|
* Inicia sesión con email y contraseña.
|
|
@@ -84,6 +84,41 @@ export interface ValtechAuthConfig {
|
|
|
84
84
|
* credencial — el token real va en la cookie HttpOnly `valtech_refresh`.
|
|
85
85
|
*/
|
|
86
86
|
loggedInHintCookie?: string;
|
|
87
|
+
/**
|
|
88
|
+
* Bootstrapear la sesión vía el Auth Proxy Central cuando esta app NO
|
|
89
|
+
* comparte dominio raíz con el resto del factory (ADR-050, Modo B — ej. un
|
|
90
|
+
* producto con dominio propio como `sigify.com`, a diferencia de bingo/
|
|
91
|
+
* showcase bajo `*.myvaltech.com`).
|
|
92
|
+
*
|
|
93
|
+
* Cuando es `true`, no hay access token local NI cookie-hint legible
|
|
94
|
+
* (`bootstrapSessionFromHint` no aplica en este dominio — la cookie
|
|
95
|
+
* `Domain=.myvaltech.com` nunca llega aquí), e `initialize()` no viene de
|
|
96
|
+
* un retorno del bridge (ver más abajo), la app hace una navegación de
|
|
97
|
+
* página completa a `ssoBridgeUrl` con `redirect_uri` = la URL actual.
|
|
98
|
+
*
|
|
99
|
+
* El backend valida la cookie `valtech_refresh` (HttpOnly, sólo visible en
|
|
100
|
+
* su propio dominio) y:
|
|
101
|
+
* - si hay sesión activa: redirige de vuelta con `?handoff=TOKEN` — el
|
|
102
|
+
* `APP_INITIALIZER` de `HandoffService.detectAndExchangeHandoff()`
|
|
103
|
+
* (ya requerido por cross-app handoff, ver frontend/CLAUDE.md) instala
|
|
104
|
+
* la sesión sin pedir credenciales.
|
|
105
|
+
* - si no hay sesión: redirige de vuelta sin `?handoff` — la app cae a
|
|
106
|
+
* invitado, comportamiento normal.
|
|
107
|
+
*
|
|
108
|
+
* El usuario ve una redirección breve (dos cargas de página), tal como
|
|
109
|
+
* documenta el ADR-050 para este modo — no hay forma de evitarla sin
|
|
110
|
+
* iframe/popup, y esos rompen con el bloqueo de cookies de terceros.
|
|
111
|
+
*
|
|
112
|
+
* Requiere `ssoBridgeUrl` seteado y el `APP_INITIALIZER` de handoff
|
|
113
|
+
* cableado en `main.ts` (mismo requisito que el handoff cross-app manual).
|
|
114
|
+
*/
|
|
115
|
+
bootstrapSessionFromBridge?: boolean;
|
|
116
|
+
/**
|
|
117
|
+
* URL completa del endpoint `GET /v2/auth/sso-bridge` del Auth Proxy
|
|
118
|
+
* Central (ej: 'https://api.myvaltech.com/v2/auth/sso-bridge'). Requerido
|
|
119
|
+
* cuando `bootstrapSessionFromBridge` es `true`.
|
|
120
|
+
*/
|
|
121
|
+
ssoBridgeUrl?: string;
|
|
87
122
|
}
|
|
88
123
|
/**
|
|
89
124
|
* Estado completo de autenticación.
|
package/lib/version.d.ts
CHANGED
package/package.json
CHANGED
|
File without changes
|