valtech-components 2.0.780 → 2.0.781
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/atoms/user-avatar/user-avatar.component.mjs +63 -16
- package/esm2022/lib/services/markdown-article/markdown-article-parser.mjs +52 -18
- package/esm2022/lib/version.mjs +2 -2
- package/fesm2022/valtech-components.mjs +115 -34
- package/fesm2022/valtech-components.mjs.map +1 -1
- package/lib/components/atoms/user-avatar/user-avatar.component.d.ts +7 -2
- package/lib/services/markdown-article/markdown-article-parser.d.ts +23 -1
- package/lib/version.d.ts +1 -1
- package/package.json +1 -1
|
@@ -21,6 +21,8 @@ import * as i0 from "@angular/core";
|
|
|
21
21
|
export declare class UserAvatarComponent {
|
|
22
22
|
private readonly props_;
|
|
23
23
|
private readonly imageFailed;
|
|
24
|
+
/** Indica si el `<img>` actual disparó su evento `load`. Conduce el fade-in. */
|
|
25
|
+
protected readonly imageLoaded: import("@angular/core").WritableSignal<boolean>;
|
|
24
26
|
set props(value: UserAvatarMetadata | undefined);
|
|
25
27
|
onClick: EventEmitter<void>;
|
|
26
28
|
/** Subscribers — usado para condicionar cursor/aria. */
|
|
@@ -28,9 +30,12 @@ export declare class UserAvatarComponent {
|
|
|
28
30
|
readonly resolvedProps: import("@angular/core").Signal<UserAvatarMetadata>;
|
|
29
31
|
/** Resuelve los campos del user (user prop > campos sueltos). */
|
|
30
32
|
private readonly resolvedUser;
|
|
31
|
-
/**
|
|
33
|
+
/**
|
|
34
|
+
* URL de imagen. Empty si la última carga falló — eso evita re-intentar
|
|
35
|
+
* con la misma URL cuando el browser ya marcó error. El placeholder
|
|
36
|
+
* (iniciales/icono) sigue visible debajo.
|
|
37
|
+
*/
|
|
32
38
|
readonly imageUrl: import("@angular/core").Signal<string>;
|
|
33
|
-
readonly showImage: import("@angular/core").Signal<boolean>;
|
|
34
39
|
/** Iniciales — 1-2 chars derivados de name (preferred) o email prefix. */
|
|
35
40
|
readonly initials: import("@angular/core").Signal<string>;
|
|
36
41
|
readonly sizeClass: import("@angular/core").Signal<"small" | "medium" | "large" | "xlarge" | "xsmall">;
|
|
@@ -1,4 +1,26 @@
|
|
|
1
1
|
import { ArticleMetadata } from '../../components/organisms/article/types';
|
|
2
|
+
export type CalloutType = 'NOTE' | 'TIP' | 'INFO' | 'WARNING' | 'CAUTION' | 'IMPORTANT';
|
|
3
|
+
/**
|
|
4
|
+
* Localized label per callout kind. Used as the prefix shown inside the
|
|
5
|
+
* resulting note element (e.g. `> [!NOTE] …` → `<val-notes-box prefix="Nota">`).
|
|
6
|
+
*
|
|
7
|
+
* Defaults to Spanish for back-compat. Pass a different map per locale when
|
|
8
|
+
* parsing translated documents so the prefix matches the body language.
|
|
9
|
+
*/
|
|
10
|
+
export type CalloutLabels = Record<CalloutType, string>;
|
|
11
|
+
/** Built-in label sets for the three platform locales. */
|
|
12
|
+
export declare const CALLOUT_LABELS: Record<'es' | 'en' | 'pt', CalloutLabels>;
|
|
13
|
+
/** Optional configuration for the parser. */
|
|
14
|
+
export interface ParseMarkdownArticleOptions extends Partial<ArticleMetadata> {
|
|
15
|
+
/**
|
|
16
|
+
* Locale used to pick built-in callout labels. Convenience shortcut so
|
|
17
|
+
* callers don't have to spread `CALLOUT_LABELS.en` themselves. Ignored
|
|
18
|
+
* when `calloutLabels` is provided explicitly.
|
|
19
|
+
*/
|
|
20
|
+
locale?: 'es' | 'en' | 'pt';
|
|
21
|
+
/** Override every callout label individually. Takes precedence over `locale`. */
|
|
22
|
+
calloutLabels?: CalloutLabels;
|
|
23
|
+
}
|
|
2
24
|
/**
|
|
3
25
|
* Pure Markdown → ArticleMetadata parser. No Angular deps — usable from Node scripts
|
|
4
26
|
* (build-time generation) and from the Angular `MarkdownArticleParserService` wrapper.
|
|
@@ -13,4 +35,4 @@ import { ArticleMetadata } from '../../components/organisms/article/types';
|
|
|
13
35
|
* - Tables → flattened into paragraphs with bold keys
|
|
14
36
|
* - Horizontal rules (---, ***, ___) → separator
|
|
15
37
|
*/
|
|
16
|
-
export declare function parseMarkdownArticle(markdown: string,
|
|
38
|
+
export declare function parseMarkdownArticle(markdown: string, options?: ParseMarkdownArticleOptions): ArticleMetadata;
|
package/lib/version.d.ts
CHANGED