valtech-components 2.0.283 → 2.0.286
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/_examples/custom-content-demo.component.mjs +57 -3
- package/esm2022/lib/services/lang-provider/lang-provider.service.mjs +7 -9
- package/fesm2022/valtech-components.mjs +62 -10
- package/fesm2022/valtech-components.mjs.map +1 -1
- package/lib/services/lang-provider/lang-provider.service.d.ts +5 -7
- package/package.json +1 -1
|
@@ -33,7 +33,7 @@ export declare class LangService {
|
|
|
33
33
|
constructor(config: ValtechConfig);
|
|
34
34
|
/**
|
|
35
35
|
* Observable that emits the current language whenever it changes.
|
|
36
|
-
* Use this to
|
|
36
|
+
* Use this to subscribe to language changes in components.
|
|
37
37
|
*/
|
|
38
38
|
get currentLang$(): Observable<LangOption>;
|
|
39
39
|
/**
|
|
@@ -41,22 +41,20 @@ export declare class LangService {
|
|
|
41
41
|
*/
|
|
42
42
|
get currentLang(): LangOption;
|
|
43
43
|
/**
|
|
44
|
-
* Set the current language and persist it to
|
|
45
|
-
* This will trigger updates in all
|
|
44
|
+
* Set the current language and persist it to localStorage.
|
|
45
|
+
* This will trigger updates in all reactive content subscriptions.
|
|
46
46
|
*
|
|
47
47
|
* @param lang - The language to set
|
|
48
48
|
*/
|
|
49
49
|
setLang(lang: LangOption): void;
|
|
50
50
|
/**
|
|
51
|
-
* Get
|
|
51
|
+
* Get content for a component class and key (legacy method).
|
|
52
52
|
*
|
|
53
|
-
* @param className - The component class name
|
|
54
|
-
* @returns The language text object for the current language
|
|
55
53
|
* @deprecated Use getText() or getContent() for better type safety
|
|
56
54
|
*/
|
|
57
55
|
Text(className: string): LanguageText;
|
|
58
56
|
/**
|
|
59
|
-
* Get a
|
|
57
|
+
* Get a single content string synchronously for the current language.
|
|
60
58
|
*
|
|
61
59
|
* @param className - The component class name
|
|
62
60
|
* @param key - The text key
|