valtech-components 4.0.208 → 4.0.209
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/molecules/load-more/load-more.component.mjs +7 -11
- package/esm2022/lib/components/organisms/organization-view/organization-view.component.mjs +9 -12
- package/esm2022/lib/components/organisms/switch-org-modal/switch-org-modal.component.mjs +5 -79
- package/esm2022/lib/components/organisms/switch-org-modal/switch-org-modal.i18n.mjs +1 -5
- package/esm2022/lib/components/organisms/toolbar/toolbar.component.mjs +3 -3
- package/esm2022/lib/components/templates/page-wrapper/page-wrapper.component.mjs +88 -10
- package/esm2022/lib/components/templates/page-wrapper/types.mjs +1 -1
- package/esm2022/lib/services/auth/org-switch.service.mjs +1 -11
- package/esm2022/lib/services/pdf/pdf.service.mjs +59 -0
- package/esm2022/lib/services/pdf/types.mjs +2 -0
- package/esm2022/lib/version.mjs +2 -2
- package/esm2022/public-api.mjs +3 -5
- package/fesm2022/valtech-components.mjs +163 -550
- package/fesm2022/valtech-components.mjs.map +1 -1
- package/lib/components/atoms/rights-footer/rights-footer.component.d.ts +2 -2
- 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/load-more/load-more.component.d.ts +1 -1
- package/lib/components/molecules/metric-card/metric-card.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 +5 -5
- package/lib/components/organisms/auth-cta/auth-cta.component.d.ts +1 -1
- package/lib/components/organisms/landing-steps/landing-steps.component.d.ts +1 -1
- package/lib/components/organisms/organization-view/organization-view.component.d.ts +1 -2
- package/lib/components/organisms/switch-org-modal/switch-org-modal.component.d.ts +1 -5
- package/lib/components/templates/page-wrapper/page-wrapper.component.d.ts +3 -1
- package/lib/components/templates/page-wrapper/types.d.ts +17 -0
- package/lib/services/auth/org-switch.service.d.ts +0 -9
- package/lib/services/pdf/pdf.service.d.ts +27 -0
- package/lib/services/pdf/types.d.ts +31 -0
- package/lib/version.d.ts +1 -1
- package/package.json +1 -1
- package/public-api.d.ts +2 -3
- package/src/lib/services/firebase/firebase-messaging-sw.js +145 -0
- package/esm2022/lib/components/molecules/reaction-bar/reaction-bar.component.mjs +0 -326
- package/esm2022/lib/components/molecules/reaction-bar/types.mjs +0 -2
- package/esm2022/lib/services/reactions/config.mjs +0 -22
- package/esm2022/lib/services/reactions/index.mjs +0 -3
- package/esm2022/lib/services/reactions/reactions.service.mjs +0 -89
- package/esm2022/lib/services/reactions/types.mjs +0 -2
- package/lib/components/molecules/reaction-bar/reaction-bar.component.d.ts +0 -44
- package/lib/components/molecules/reaction-bar/types.d.ts +0 -55
- package/lib/services/reactions/config.d.ts +0 -20
- package/lib/services/reactions/index.d.ts +0 -3
- package/lib/services/reactions/reactions.service.d.ts +0 -42
- package/lib/services/reactions/types.d.ts +0 -48
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
import { Observable } from 'rxjs';
|
|
2
|
-
import { ReactRequest, ReactResponse, GetCountsResponse, ReactionSet } from './types';
|
|
3
|
-
import * as i0 from "@angular/core";
|
|
4
|
-
/**
|
|
5
|
-
* Servicio para gestionar reacciones emoji configurables por contexto.
|
|
6
|
-
*
|
|
7
|
-
* Requiere provideValtechReactions() en el bootstrap de la app.
|
|
8
|
-
*
|
|
9
|
-
* @example
|
|
10
|
-
* const svc = inject(ReactionsService);
|
|
11
|
-
* svc.react({ entityRef: { entityType: 'post', entityId: '1' }, token: 'heart', appId: 'app' })
|
|
12
|
-
* .subscribe(res => console.log(res.counts));
|
|
13
|
-
*/
|
|
14
|
-
export declare class ReactionsService {
|
|
15
|
-
private http;
|
|
16
|
-
private config;
|
|
17
|
-
constructor();
|
|
18
|
-
private get apiUrl();
|
|
19
|
-
private get baseUrl();
|
|
20
|
-
/**
|
|
21
|
-
* Toggle reaccion — retorna estado nuevo + conteos actualizados.
|
|
22
|
-
*/
|
|
23
|
-
react(req: ReactRequest): Observable<ReactResponse>;
|
|
24
|
-
/**
|
|
25
|
-
* Conteos + reacciones del usuario para una entidad.
|
|
26
|
-
*/
|
|
27
|
-
getCounts(appId: string, entityType: string, entityId: string): Observable<GetCountsResponse>;
|
|
28
|
-
/**
|
|
29
|
-
* Solo mis tokens activos para una entidad.
|
|
30
|
-
*/
|
|
31
|
-
getMyReactions(appId: string, entityType: string, entityId: string): Observable<string[]>;
|
|
32
|
-
/**
|
|
33
|
-
* Obtener un set de reacciones por ID.
|
|
34
|
-
*/
|
|
35
|
-
getSet(setId: string): Observable<ReactionSet>;
|
|
36
|
-
/**
|
|
37
|
-
* Listar todos los sets disponibles para una app.
|
|
38
|
-
*/
|
|
39
|
-
listSets(appId: string): Observable<ReactionSet[]>;
|
|
40
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<ReactionsService, never>;
|
|
41
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<ReactionsService>;
|
|
42
|
-
}
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
export type ReactionSetContext = 'formal' | 'social' | 'celebration' | 'opinion' | 'custom';
|
|
2
|
-
export interface ReactionDefinition {
|
|
3
|
-
token: string;
|
|
4
|
-
emoji: string;
|
|
5
|
-
label: string;
|
|
6
|
-
icon: string;
|
|
7
|
-
order: number;
|
|
8
|
-
}
|
|
9
|
-
export interface ReactionSet {
|
|
10
|
-
setId: string;
|
|
11
|
-
appId: string;
|
|
12
|
-
name: string;
|
|
13
|
-
context: ReactionSetContext;
|
|
14
|
-
reactions: ReactionDefinition[];
|
|
15
|
-
isPreset: boolean;
|
|
16
|
-
createdAt: string;
|
|
17
|
-
updatedAt: string;
|
|
18
|
-
}
|
|
19
|
-
export interface ReactionCounts {
|
|
20
|
-
counts: Record<string, number>;
|
|
21
|
-
}
|
|
22
|
-
export interface ReactRequest {
|
|
23
|
-
entityRef: {
|
|
24
|
-
entityType: string;
|
|
25
|
-
entityId: string;
|
|
26
|
-
};
|
|
27
|
-
token: string;
|
|
28
|
-
appId: string;
|
|
29
|
-
}
|
|
30
|
-
export interface ReactResponse {
|
|
31
|
-
operationId: string;
|
|
32
|
-
token: string;
|
|
33
|
-
active: boolean;
|
|
34
|
-
counts: Record<string, number>;
|
|
35
|
-
}
|
|
36
|
-
export interface GetCountsResponse {
|
|
37
|
-
operationId: string;
|
|
38
|
-
counts: Record<string, number>;
|
|
39
|
-
myReactions: string[];
|
|
40
|
-
}
|
|
41
|
-
export interface GetMyReactionsResponse {
|
|
42
|
-
operationId: string;
|
|
43
|
-
tokens: string[];
|
|
44
|
-
}
|
|
45
|
-
export interface ValtechReactionsConfig {
|
|
46
|
-
apiUrl: string;
|
|
47
|
-
appId?: string;
|
|
48
|
-
}
|