valtech-components 2.0.825 → 2.0.827
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/services/auth/auth.service.mjs +3 -1
- package/esm2022/lib/services/firebase/firebase.service.mjs +12 -2
- package/esm2022/lib/services/firebase/notifications.service.mjs +10 -3
- package/esm2022/lib/services/refreshable-stream/refreshable-stream.mjs +16 -4
- package/esm2022/lib/version.mjs +2 -2
- package/fesm2022/valtech-components.mjs +37 -6
- 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/features-list/features-list.component.d.ts +1 -1
- package/lib/components/molecules/username-input/username-input.component.d.ts +1 -1
- package/lib/components/organisms/article/article.component.d.ts +5 -5
- package/lib/components/organisms/toolbar/toolbar.component.d.ts +2 -2
- package/lib/components/templates/page-wrapper/page-wrapper.component.d.ts +2 -2
- package/lib/version.d.ts +1 -1
- package/package.json +1 -1
- package/src/lib/services/firebase/firebase-messaging-sw.js +19 -8
|
@@ -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<"medium" | "primary" | "secondary" | "tertiary" | "success" | "warning" | "danger" | "light" | "dark">;
|
|
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<"small" | "medium" | "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<"small" | "medium" | "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>;
|
|
@@ -48,7 +48,7 @@ export declare class FeaturesListComponent {
|
|
|
48
48
|
iconColor: string;
|
|
49
49
|
iconSize: number;
|
|
50
50
|
mode: "horizontal" | "vertical";
|
|
51
|
-
gap: "
|
|
51
|
+
gap: "small" | "medium" | "large";
|
|
52
52
|
alignment: "center" | "start";
|
|
53
53
|
}>;
|
|
54
54
|
/** Resolved icon color (handles Ionic colors and CSS colors) */
|
|
@@ -36,7 +36,7 @@ export declare class UsernameInputComponent implements OnInit, OnDestroy {
|
|
|
36
36
|
hasError: import("@angular/core").Signal<boolean>;
|
|
37
37
|
showStatusMessage: import("@angular/core").Signal<boolean>;
|
|
38
38
|
statusColor: import("@angular/core").Signal<"success" | "danger">;
|
|
39
|
-
statusMessage: import("@angular/core").Signal<"Username disponible" | "Username ya está en uso"
|
|
39
|
+
statusMessage: import("@angular/core").Signal<"" | "Username disponible" | "Username ya está en uso">;
|
|
40
40
|
errorMessage: import("@angular/core").Signal<string>;
|
|
41
41
|
ngOnInit(): void;
|
|
42
42
|
ngOnDestroy(): void;
|
|
@@ -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: "small" | "medium" | "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: "small" | "medium" | "large" | "xlarge";
|
|
65
65
|
color: import("@ionic/core").Color;
|
|
66
66
|
content?: string;
|
|
67
67
|
bold: boolean;
|
|
@@ -90,9 +90,9 @@ export declare class ArticleComponent implements OnInit {
|
|
|
90
90
|
contentInterpolation?: Record<string, string | number>;
|
|
91
91
|
icon?: import("valtech-components").IconMetada;
|
|
92
92
|
shape?: "round";
|
|
93
|
-
size?: "
|
|
94
|
-
fill?: "default" | "
|
|
95
|
-
type: "
|
|
93
|
+
size?: "small" | "large" | "default";
|
|
94
|
+
fill?: "default" | "clear" | "outline" | "solid";
|
|
95
|
+
type: "button" | "submit" | "reset";
|
|
96
96
|
token?: string;
|
|
97
97
|
ref?: any;
|
|
98
98
|
handler?: (value: any) => any;
|
|
@@ -72,8 +72,8 @@ export declare class ToolbarComponent implements OnInit {
|
|
|
72
72
|
};
|
|
73
73
|
showFlags?: boolean;
|
|
74
74
|
color: import("@ionic/core").Color;
|
|
75
|
-
size?: "
|
|
76
|
-
fill?: "default" | "
|
|
75
|
+
size?: "small" | "large" | "default";
|
|
76
|
+
fill?: "default" | "clear" | "outline" | "solid";
|
|
77
77
|
shape?: "round";
|
|
78
78
|
expand?: "full" | "block";
|
|
79
79
|
disabled?: boolean;
|
|
@@ -50,7 +50,7 @@ export declare class PageWrapperComponent implements ViewWillEnter, ViewWillLeav
|
|
|
50
50
|
* Default header configuration (cached to avoid infinite change detection).
|
|
51
51
|
*/
|
|
52
52
|
private readonly defaultHeader;
|
|
53
|
-
headerProps: import("@angular/core").Signal<{
|
|
53
|
+
headerProps: import("@angular/core").Signal<import("valtech-components").HeaderMetadata | {
|
|
54
54
|
bordered: boolean;
|
|
55
55
|
translucent: boolean;
|
|
56
56
|
toolbar: {
|
|
@@ -77,7 +77,7 @@ export declare class PageWrapperComponent implements ViewWillEnter, ViewWillLeav
|
|
|
77
77
|
};
|
|
78
78
|
}[];
|
|
79
79
|
};
|
|
80
|
-
}
|
|
80
|
+
}>;
|
|
81
81
|
contentId: import("@angular/core").Signal<string>;
|
|
82
82
|
propsFooter: import("@angular/core").Signal<import("valtech-components").CompanyFooterMetadata>;
|
|
83
83
|
contentMaxWidth: import("@angular/core").Signal<ContainerSize>;
|
package/lib/version.d.ts
CHANGED
package/package.json
CHANGED
|
@@ -42,21 +42,32 @@ if (!self.FIREBASE_CONFIG) {
|
|
|
42
42
|
messaging.onBackgroundMessage((payload) => {
|
|
43
43
|
console.log('[SW] Mensaje recibido en background:', payload);
|
|
44
44
|
|
|
45
|
-
|
|
45
|
+
// Web push usa mensajes data-only (sin bloque `notification`) para que el
|
|
46
|
+
// navegador NO auto-muestre una notificación duplicada — el SW es el único
|
|
47
|
+
// que la pinta. Title/body/icon llegan dentro de `data`. Se mantiene el
|
|
48
|
+
// fallback a `payload.notification` por compatibilidad con mensajes
|
|
49
|
+
// legacy o nativos que sí traen el bloque.
|
|
50
|
+
const data = payload.data || {};
|
|
51
|
+
const notificationTitle =
|
|
52
|
+
payload.notification?.title || data.title || 'Nueva notificación';
|
|
53
|
+
const notificationBody = payload.notification?.body || data.body || '';
|
|
54
|
+
const notificationIcon =
|
|
55
|
+
payload.notification?.icon || data.icon || '/assets/icon/favicon.ico';
|
|
56
|
+
|
|
46
57
|
const notificationOptions = {
|
|
47
|
-
body:
|
|
48
|
-
icon:
|
|
58
|
+
body: notificationBody,
|
|
59
|
+
icon: notificationIcon,
|
|
49
60
|
image: payload.notification?.image,
|
|
50
61
|
badge: '/assets/icon/badge.png',
|
|
51
|
-
tag: payload.messageId || 'default',
|
|
62
|
+
tag: payload.messageId || data.messageId || 'default',
|
|
52
63
|
data: {
|
|
53
|
-
...
|
|
54
|
-
messageId: payload.messageId,
|
|
64
|
+
...data,
|
|
65
|
+
messageId: payload.messageId || data.messageId,
|
|
55
66
|
title: notificationTitle,
|
|
56
|
-
body:
|
|
67
|
+
body: notificationBody,
|
|
57
68
|
},
|
|
58
69
|
vibrate: [200, 100, 200],
|
|
59
|
-
requireInteraction:
|
|
70
|
+
requireInteraction: data.require_interaction === 'true',
|
|
60
71
|
};
|
|
61
72
|
|
|
62
73
|
return self.registration.showNotification(notificationTitle, notificationOptions);
|