@telia-ace/widget-core-flamingo 1.1.22-rc.0 → 1.1.22-rc.2
Sign up to get free protection for your applications and to get access to all the features.
- package/index.js +28 -17
- package/index.mjs +290 -267
- package/models/application.d.ts +2 -0
- package/package.json +1 -1
- package/services/texts.service.d.ts +9 -0
- package/types.d.ts +1 -0
package/models/application.d.ts
CHANGED
@@ -1,6 +1,7 @@
|
|
1
1
|
import { Trigger } from '../components/trigger.component';
|
2
2
|
import { Wrapper } from '../components/wrapper.component';
|
3
3
|
import { ComponentPlatform } from '../services/component-platform';
|
4
|
+
import { TextsService } from '../services/texts.service';
|
4
5
|
import { ApplicationOptions, PluginType, RenderStrategy, TriggerIcon, WidgetConfig } from '../types';
|
5
6
|
import { Container } from './container';
|
6
7
|
export declare class Application {
|
@@ -9,6 +10,7 @@ export declare class Application {
|
|
9
10
|
settings: WidgetConfig;
|
10
11
|
private options;
|
11
12
|
platform: ComponentPlatform;
|
13
|
+
texts: TextsService;
|
12
14
|
root?: Wrapper;
|
13
15
|
renderStrategy: RenderStrategy;
|
14
16
|
triggerIcon?: TriggerIcon;
|
package/package.json
CHANGED
@@ -0,0 +1,9 @@
|
|
1
|
+
export interface ITextsService {
|
2
|
+
loadTexts(texts: Record<string, string>): void;
|
3
|
+
get(key: string): string | null;
|
4
|
+
}
|
5
|
+
export declare class TextsService implements ITextsService {
|
6
|
+
private texts;
|
7
|
+
loadTexts(texts: Record<string, string>): void;
|
8
|
+
get(key: string, fallback?: string): string | null;
|
9
|
+
}
|