valtech-components 4.0.29 → 4.0.31
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/account-view/account-view.component.mjs +13 -21
- package/esm2022/lib/components/organisms/avatar-upload/avatar-upload.component.mjs +25 -12
- package/esm2022/lib/components/organisms/edit-org-modal/edit-org-modal.component.mjs +57 -5
- package/esm2022/lib/components/organisms/login/types.mjs +9 -7
- package/esm2022/lib/components/organisms/organization-view/organization-view.component.mjs +49 -38
- package/esm2022/lib/components/organisms/profile-view/profile-view.component.mjs +2 -2
- package/esm2022/lib/components/organisms/switch-org-modal/switch-org-modal.component.mjs +59 -6
- package/esm2022/lib/components/organisms/switch-org-modal/switch-org-modal.i18n.mjs +3 -1
- package/esm2022/lib/services/org/types.mjs +1 -1
- package/esm2022/lib/version.mjs +2 -2
- package/fesm2022/valtech-components.mjs +204 -83
- package/fesm2022/valtech-components.mjs.map +1 -1
- package/lib/components/atoms/rights-footer/rights-footer.component.d.ts +1 -1
- package/lib/components/atoms/text/text.component.d.ts +1 -1
- package/lib/components/atoms/user-avatar/user-avatar.component.d.ts +1 -1
- package/lib/components/molecules/cta-card/cta-card.component.d.ts +1 -1
- package/lib/components/molecules/features-list/features-list.component.d.ts +1 -1
- package/lib/components/molecules/metric-card/metric-card.component.d.ts +1 -1
- package/lib/components/organisms/article/article.component.d.ts +5 -5
- package/lib/components/organisms/auth-cta/auth-cta.component.d.ts +1 -1
- package/lib/components/organisms/avatar-upload/avatar-upload.component.d.ts +10 -1
- package/lib/components/organisms/edit-org-modal/edit-org-modal.component.d.ts +5 -1
- package/lib/components/organisms/login/types.d.ts +6 -4
- package/lib/components/organisms/member-import-modal/member-import-modal.component.d.ts +1 -1
- package/lib/components/organisms/switch-org-modal/switch-org-modal.component.d.ts +6 -1
- package/lib/services/org/types.d.ts +2 -0
- package/lib/version.d.ts +1 -1
- package/package.json +1 -1
|
@@ -43,7 +43,7 @@ export declare class RightsFooterComponent {
|
|
|
43
43
|
/**
|
|
44
44
|
* Computed helper for color prop in template.
|
|
45
45
|
*/
|
|
46
|
-
propsColor: import("@angular/core").Signal<"
|
|
46
|
+
propsColor: import("@angular/core").Signal<"dark" | "primary" | "secondary" | "tertiary" | "success" | "warning" | "danger" | "light" | "medium">;
|
|
47
47
|
/**
|
|
48
48
|
* Computed helper for withMargin prop in template.
|
|
49
49
|
*/
|
|
@@ -11,7 +11,7 @@ export declare class TextComponent {
|
|
|
11
11
|
*/
|
|
12
12
|
displayContent: import("@angular/core").Signal<string>;
|
|
13
13
|
propsColor: import("@angular/core").Signal<import("@ionic/core").Color>;
|
|
14
|
-
propsSize: import("@angular/core").Signal<"
|
|
14
|
+
propsSize: import("@angular/core").Signal<"medium" | "small" | "large" | "xlarge">;
|
|
15
15
|
propsBold: import("@angular/core").Signal<boolean>;
|
|
16
16
|
propsProcessLinks: import("@angular/core").Signal<boolean>;
|
|
17
17
|
propsAllowPartialBold: import("@angular/core").Signal<boolean>;
|
|
@@ -38,7 +38,7 @@ export declare class UserAvatarComponent {
|
|
|
38
38
|
readonly imageUrl: import("@angular/core").Signal<string>;
|
|
39
39
|
/** Iniciales — 1-2 chars derivados de name (preferred) o email prefix. */
|
|
40
40
|
readonly initials: import("@angular/core").Signal<string>;
|
|
41
|
-
readonly sizeClass: import("@angular/core").Signal<"
|
|
41
|
+
readonly sizeClass: import("@angular/core").Signal<"medium" | "small" | "large" | "xlarge" | "xsmall">;
|
|
42
42
|
readonly shapeClass: import("@angular/core").Signal<"circle" | "square">;
|
|
43
43
|
/** Background — explicito o derivado deterministicamente del user. */
|
|
44
44
|
readonly bgColor: import("@angular/core").Signal<string>;
|
|
@@ -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>;
|
|
@@ -41,7 +41,7 @@ export declare class FeaturesListComponent {
|
|
|
41
41
|
iconColor: string;
|
|
42
42
|
iconSize: number;
|
|
43
43
|
mode: "horizontal" | "vertical";
|
|
44
|
-
gap: "
|
|
44
|
+
gap: "medium" | "small" | "large";
|
|
45
45
|
alignment: "center" | "start";
|
|
46
46
|
imageShape: "circle" | "square";
|
|
47
47
|
maxVisible: number;
|
|
@@ -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
|
}
|
|
@@ -45,7 +45,7 @@ export declare class ArticleComponent implements OnInit {
|
|
|
45
45
|
getVideoElement(element: ArticleElement): ArticleVideoElement;
|
|
46
46
|
getCustomElement(element: ArticleElement): ArticleCustomElement;
|
|
47
47
|
getQuoteTextProps(element: ArticleElement): {
|
|
48
|
-
size: "
|
|
48
|
+
size: "medium" | "small" | "large" | "xlarge";
|
|
49
49
|
color: import("@ionic/core").Color;
|
|
50
50
|
content?: string;
|
|
51
51
|
bold: boolean;
|
|
@@ -61,7 +61,7 @@ export declare class ArticleComponent implements OnInit {
|
|
|
61
61
|
showQuoteMark?: boolean;
|
|
62
62
|
};
|
|
63
63
|
getHighlightTextProps(element: ArticleElement): {
|
|
64
|
-
size: "
|
|
64
|
+
size: "medium" | "small" | "large" | "xlarge";
|
|
65
65
|
color: import("@ionic/core").Color;
|
|
66
66
|
content?: string;
|
|
67
67
|
bold: boolean;
|
|
@@ -76,7 +76,7 @@ export declare class ArticleComponent implements OnInit {
|
|
|
76
76
|
getHighlightColor(element: ArticleElement): string;
|
|
77
77
|
getButtonProps(element: ArticleElement): {
|
|
78
78
|
actionType?: import("valtech-components").ActionType;
|
|
79
|
-
expand?: "
|
|
79
|
+
expand?: "block" | "full";
|
|
80
80
|
link?: string;
|
|
81
81
|
href?: string;
|
|
82
82
|
routerLink?: string | any[];
|
|
@@ -92,8 +92,8 @@ export declare class ArticleComponent implements OnInit {
|
|
|
92
92
|
icon?: import("valtech-components").IconMetada;
|
|
93
93
|
shape?: "round";
|
|
94
94
|
size?: "default" | "small" | "large";
|
|
95
|
-
fill?: "
|
|
96
|
-
type: "
|
|
95
|
+
fill?: "solid" | "default" | "clear" | "outline";
|
|
96
|
+
type: "submit" | "button" | "reset";
|
|
97
97
|
token?: string;
|
|
98
98
|
ref?: any;
|
|
99
99
|
handler?: (value: any) => any;
|
|
@@ -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
|
resolvedBg: import("@angular/core").Signal<string>;
|
|
@@ -32,6 +32,15 @@ export declare class AvatarUploadComponent {
|
|
|
32
32
|
fileInput: ElementRef<HTMLInputElement>;
|
|
33
33
|
/** Component configuration */
|
|
34
34
|
readonly props: import("@angular/core").InputSignal<AvatarUploadMetadata>;
|
|
35
|
+
/** Custom storage path for the full-size image (e.g. 'orgs/{orgId}/logo.jpg').
|
|
36
|
+
* When provided, overrides the default 'users/{userId}/avatar.jpg' path. */
|
|
37
|
+
readonly customPath: import("@angular/core").InputSignal<string>;
|
|
38
|
+
/** Custom storage path for the thumbnail (e.g. 'orgs/{orgId}/thumb.jpg').
|
|
39
|
+
* When provided, overrides the default 'users/{userId}/thumb.jpg' path. */
|
|
40
|
+
readonly customThumbPath: import("@angular/core").InputSignal<string>;
|
|
41
|
+
/** When true, skips the AuthService.updateAvatar() backend sync call after upload.
|
|
42
|
+
* Use this when the caller will handle the backend update (e.g. via OrgService). */
|
|
43
|
+
readonly skipBackendSync: import("@angular/core").InputSignal<boolean>;
|
|
35
44
|
/** Emitted after successful upload and backend sync */
|
|
36
45
|
uploaded: EventEmitter<AvatarUploadResult>;
|
|
37
46
|
/** Emitted on any error during the process */
|
|
@@ -86,5 +95,5 @@ export declare class AvatarUploadComponent {
|
|
|
86
95
|
/** Emit error event */
|
|
87
96
|
private emitError;
|
|
88
97
|
static ɵfac: i0.ɵɵFactoryDeclaration<AvatarUploadComponent, never>;
|
|
89
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<AvatarUploadComponent, "val-avatar-upload", never, { "props": { "alias": "props"; "required": false; "isSignal": true; }; }, { "uploaded": "uploaded"; "error": "error"; "uploadStart": "uploadStart"; }, never, never, true, never>;
|
|
98
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<AvatarUploadComponent, "val-avatar-upload", never, { "props": { "alias": "props"; "required": false; "isSignal": true; }; "customPath": { "alias": "customPath"; "required": false; "isSignal": true; }; "customThumbPath": { "alias": "customThumbPath"; "required": false; "isSignal": true; }; "skipBackendSync": { "alias": "skipBackendSync"; "required": false; "isSignal": true; }; }, { "uploaded": "uploaded"; "error": "error"; "uploadStart": "uploadStart"; }, never, never, true, never>;
|
|
90
99
|
}
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { OnInit, WritableSignal } from '@angular/core';
|
|
2
|
+
import { AvatarUploadResult } from '../avatar-upload/types';
|
|
2
3
|
import { FormMetadata, FormSubmit } from '../../types';
|
|
3
4
|
import { Organization } from '../../../services/org/types';
|
|
4
5
|
import * as i0 from "@angular/core";
|
|
@@ -35,13 +36,16 @@ export declare class EditOrgModalComponent implements OnInit {
|
|
|
35
36
|
/** Namespace i18n con que la vista resuelve sus textos. */
|
|
36
37
|
i18nNamespace: string;
|
|
37
38
|
private readonly saving;
|
|
39
|
+
protected readonly logoUrl: WritableSignal<string>;
|
|
38
40
|
readonly formMeta: WritableSignal<FormMetadata>;
|
|
41
|
+
protected readonly orgInitials: import("@angular/core").Signal<string>;
|
|
39
42
|
constructor();
|
|
40
43
|
ngOnInit(): void;
|
|
41
|
-
|
|
44
|
+
protected get activeOrgId(): string;
|
|
42
45
|
private buildFormMeta;
|
|
43
46
|
onFormSubmit(event: FormSubmit): void;
|
|
44
47
|
private save;
|
|
48
|
+
onLogoUploaded(result: AvatarUploadResult): Promise<void>;
|
|
45
49
|
dismiss(): void;
|
|
46
50
|
t(key: string): string;
|
|
47
51
|
static ɵfac: i0.ɵɵFactoryDeclaration<EditOrgModalComponent, never>;
|
|
@@ -71,10 +71,12 @@ export declare const LOGIN_DEFAULTS: Required<Omit<LoginMetadata, 'logo' | 'lega
|
|
|
71
71
|
/**
|
|
72
72
|
* Logo por defecto de la card de login cuando el consumer no pasa `logo`.
|
|
73
73
|
*
|
|
74
|
-
* Usa el token CSS `--main-logo` (
|
|
75
|
-
*
|
|
76
|
-
*
|
|
77
|
-
*
|
|
74
|
+
* Usa el token CSS `--main-logo-mini` (el logo MINI/icono, el mismo que el
|
|
75
|
+
* side menu `val-menu`), resuelto por `val-image` vía `var(--main-logo-mini)`.
|
|
76
|
+
* Cada app del factory lo define en su `theme/variables.scss` (showcase →
|
|
77
|
+
* `main-icon.png`, bingo → `favicon-balls.svg`). NO es el lockup grande
|
|
78
|
+
* `--main-logo` del header. Así el login muestra SIEMPRE el icono de marca de
|
|
79
|
+
* la app sin acoplar la lib a una marca concreta — es el estándar del factory.
|
|
78
80
|
*
|
|
79
81
|
* Una app puede override pasando su propio `logo` en `LoginMetadata` (ej.
|
|
80
82
|
* showcase usa un mark propio `terminal.svg`).
|
|
@@ -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>>;
|
|
@@ -28,20 +28,25 @@ export declare class SwitchOrgModalComponent {
|
|
|
28
28
|
};
|
|
29
29
|
/** Callback tras un switch exitoso (pasado por `componentProps`). */
|
|
30
30
|
onSuccess?: () => void;
|
|
31
|
+
/** Callback al hacer clic en "Mi perfil" (pasado por `componentProps`). */
|
|
32
|
+
onProfileClick?: () => void;
|
|
31
33
|
/** Namespace i18n con que la vista resuelve sus textos. */
|
|
32
34
|
i18nNamespace: string;
|
|
33
35
|
readonly orgs: import("@angular/core").WritableSignal<Organization[]>;
|
|
34
36
|
readonly loading: import("@angular/core").WritableSignal<boolean>;
|
|
35
37
|
readonly query: import("@angular/core").WritableSignal<string>;
|
|
36
38
|
readonly switchingId: import("@angular/core").WritableSignal<string>;
|
|
39
|
+
protected readonly user: import("@angular/core").Signal<import("valtech-components").AuthUser>;
|
|
40
|
+
protected readonly userInitials: import("@angular/core").Signal<string>;
|
|
37
41
|
readonly activeOrgId: import("@angular/core").Signal<string>;
|
|
38
42
|
readonly filteredOrgs: import("@angular/core").Signal<Organization[]>;
|
|
39
43
|
constructor();
|
|
40
44
|
onQueryChange(value: string): void;
|
|
41
45
|
onSelect(org: Organization): Promise<void>;
|
|
42
46
|
private loadOrgs;
|
|
47
|
+
onProfile(): void;
|
|
43
48
|
dismiss(): void;
|
|
44
49
|
t(key: string): string;
|
|
45
50
|
static ɵfac: i0.ɵɵFactoryDeclaration<SwitchOrgModalComponent, never>;
|
|
46
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<SwitchOrgModalComponent, "val-switch-org-modal", never, { "_modalRef": { "alias": "_modalRef"; "required": false; }; "onSuccess": { "alias": "onSuccess"; "required": false; }; "i18nNamespace": { "alias": "i18nNamespace"; "required": false; }; }, {}, never, never, true, never>;
|
|
51
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<SwitchOrgModalComponent, "val-switch-org-modal", never, { "_modalRef": { "alias": "_modalRef"; "required": false; }; "onSuccess": { "alias": "onSuccess"; "required": false; }; "onProfileClick": { "alias": "onProfileClick"; "required": false; }; "i18nNamespace": { "alias": "i18nNamespace"; "required": false; }; }, {}, never, never, true, never>;
|
|
47
52
|
}
|
|
@@ -10,6 +10,7 @@ export interface Organization {
|
|
|
10
10
|
isActive: boolean;
|
|
11
11
|
createdAt: string;
|
|
12
12
|
updatedAt?: string;
|
|
13
|
+
logoUrl?: string;
|
|
13
14
|
}
|
|
14
15
|
export interface ListMyOrgsResponse {
|
|
15
16
|
operationId: string;
|
|
@@ -29,6 +30,7 @@ export interface CreateOrgRequest {
|
|
|
29
30
|
export interface UpdateOrgRequest {
|
|
30
31
|
name?: string;
|
|
31
32
|
description?: string;
|
|
33
|
+
logoUrl?: string;
|
|
32
34
|
}
|
|
33
35
|
export interface InviteUserRequest {
|
|
34
36
|
email?: string;
|
package/lib/version.d.ts
CHANGED