@tilde-nlp/ngx-common 8.1.12 → 8.1.14
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.
|
@@ -7886,14 +7886,18 @@ var SubscriptionPlan;
|
|
|
7886
7886
|
SubscriptionPlan["EventAssistantUnlimited"] = "Event-Assistant-Unlimited";
|
|
7887
7887
|
})(SubscriptionPlan || (SubscriptionPlan = {}));
|
|
7888
7888
|
|
|
7889
|
+
const CUSTOM_TITLE_CONFIGURATION_TOKEN = new InjectionToken('CUSTOM_TITLE_CONFIGURATION_TOKEN');
|
|
7890
|
+
|
|
7889
7891
|
class CustomTitleStrategyService extends TitleStrategy {
|
|
7890
7892
|
#translateService;
|
|
7893
|
+
#config;
|
|
7891
7894
|
constructor() {
|
|
7892
7895
|
super();
|
|
7893
7896
|
this.#translateService = inject(TranslateService);
|
|
7894
7897
|
this.title = inject(Title);
|
|
7895
7898
|
this.appName = "APP_NAME";
|
|
7896
7899
|
this.owner = "OWNER";
|
|
7900
|
+
this.#config = inject(CUSTOM_TITLE_CONFIGURATION_TOKEN);
|
|
7897
7901
|
}
|
|
7898
7902
|
updateTitle(snapshot) {
|
|
7899
7903
|
if (this.subscription) {
|
|
@@ -7907,7 +7911,9 @@ class CustomTitleStrategyService extends TitleStrategy {
|
|
|
7907
7911
|
this.subscription = this.#translateService.stream(translationKeys, { appName: this.appName }).subscribe((translations) => {
|
|
7908
7912
|
let translatedTitle = `${translations[this.owner]} ${translations[this.appName]}`;
|
|
7909
7913
|
if (title && translations[title]) {
|
|
7910
|
-
translatedTitle
|
|
7914
|
+
translatedTitle = this.#config.isPageTitleFirst ?? false
|
|
7915
|
+
? `${translations[title]} | ${translatedTitle}`
|
|
7916
|
+
: `${translatedTitle} | ${translations[title]}`;
|
|
7911
7917
|
}
|
|
7912
7918
|
this.title.setTitle(translatedTitle);
|
|
7913
7919
|
});
|
|
@@ -7922,11 +7928,17 @@ class CustomTitleStrategyService extends TitleStrategy {
|
|
|
7922
7928
|
}]
|
|
7923
7929
|
}], () => [], null); })();
|
|
7924
7930
|
|
|
7925
|
-
const provideCustomTitleStrategy = () => {
|
|
7926
|
-
|
|
7927
|
-
|
|
7928
|
-
|
|
7929
|
-
|
|
7931
|
+
const provideCustomTitleStrategy = (customConfigProvider) => {
|
|
7932
|
+
const TITLE_STRATEGY_PROVIDERS = [
|
|
7933
|
+
{
|
|
7934
|
+
provide: TitleStrategy,
|
|
7935
|
+
useClass: CustomTitleStrategyService,
|
|
7936
|
+
},
|
|
7937
|
+
];
|
|
7938
|
+
if (customConfigProvider) {
|
|
7939
|
+
TITLE_STRATEGY_PROVIDERS.push(customConfigProvider);
|
|
7940
|
+
}
|
|
7941
|
+
return TITLE_STRATEGY_PROVIDERS;
|
|
7930
7942
|
};
|
|
7931
7943
|
|
|
7932
7944
|
class MissingTranslationHandlerService {
|
|
@@ -8809,20 +8821,8 @@ class AccessibilityDialogComponent {
|
|
|
8809
8821
|
this.currentContrast = AccessibilityContrasts.BASE;
|
|
8810
8822
|
this.#accessibility = inject(AccessibilityService);
|
|
8811
8823
|
this.contrasts = Object.values(AccessibilityContrasts);
|
|
8812
|
-
this.
|
|
8813
|
-
|
|
8814
|
-
text: 'ACCESSIBILITY.EASY_TO_READ',
|
|
8815
|
-
link: '/easy-read',
|
|
8816
|
-
},
|
|
8817
|
-
{
|
|
8818
|
-
text: 'ACCESSIBILITY.OTHER_SETTINGS',
|
|
8819
|
-
link: '/accessibility-features',
|
|
8820
|
-
},
|
|
8821
|
-
{
|
|
8822
|
-
text: 'ACCESSIBILITY.NOTIFICATION',
|
|
8823
|
-
link: '/accessibility-statement',
|
|
8824
|
-
}
|
|
8825
|
-
];
|
|
8824
|
+
this.data = inject(MAT_DIALOG_DATA);
|
|
8825
|
+
this.featureSources = [];
|
|
8826
8826
|
}
|
|
8827
8827
|
#accessibility;
|
|
8828
8828
|
ngOnInit() {
|
|
@@ -8830,6 +8830,7 @@ class AccessibilityDialogComponent {
|
|
|
8830
8830
|
this.currentContrast = this.#accessibility.getSavedContrast();
|
|
8831
8831
|
this.isTextMagnifierEnabled = this.#accessibility.getSavedTextMagnifierStatus();
|
|
8832
8832
|
this.isScreenMaskEnabled = this.#accessibility.getSavedScreenMaskStatus();
|
|
8833
|
+
this.setFeatureSources();
|
|
8833
8834
|
}
|
|
8834
8835
|
changeContrast(contrast) {
|
|
8835
8836
|
this.currentContrast = contrast;
|
|
@@ -8864,6 +8865,22 @@ class AccessibilityDialogComponent {
|
|
|
8864
8865
|
this.#accessibility.saveFontSize(this.selectedFontSizeIndex);
|
|
8865
8866
|
this.#accessibility.setFontSize(this.selectedFontSizeIndex);
|
|
8866
8867
|
}
|
|
8868
|
+
setFeatureSources() {
|
|
8869
|
+
this.featureSources = [
|
|
8870
|
+
{
|
|
8871
|
+
text: 'ACCESSIBILITY.EASY_TO_READ',
|
|
8872
|
+
link: `${this.data.baseUrl}easy-read`,
|
|
8873
|
+
},
|
|
8874
|
+
{
|
|
8875
|
+
text: 'ACCESSIBILITY.OTHER_SETTINGS',
|
|
8876
|
+
link: `${this.data.baseUrl}accessibility-features`,
|
|
8877
|
+
},
|
|
8878
|
+
{
|
|
8879
|
+
text: 'ACCESSIBILITY.NOTIFICATION',
|
|
8880
|
+
link: `${this.data.baseUrl}accessibility-statement`,
|
|
8881
|
+
}
|
|
8882
|
+
];
|
|
8883
|
+
}
|
|
8867
8884
|
static { this.ɵfac = function AccessibilityDialogComponent_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || AccessibilityDialogComponent)(); }; }
|
|
8868
8885
|
static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: AccessibilityDialogComponent, selectors: [["lib-accessibility-dialog"]], decls: 40, vars: 32, consts: [["mat-dialog-title", "", 1, "text-2-xl"], ["mat-dialog-content", ""], [1, "font-size-wrapper"], [1, "settings-title"], ["animationDuration", "0ms", 3, "selectedTabChange", "selectedIndex"], [3, "label"], [1, "contrast-wrapper"], [1, "contrast-option-wrapper"], [1, "contrast-option", 3, "class", "active"], [1, "visual-tools-wrapper"], ["mat-stroked-button", "", 3, "click"], ["mat-stroked-button", "", 1, "screen-mask-btn", 3, "click"], [1, "divider"], [1, "feature-links-wrapper"], [1, "feature-link", 3, "href"], ["mat-dialog-actions", ""], ["mat-flat-button", "", "mat-dialog-close", ""], [1, "contrast-option", 3, "click"], [1, "material-icons-outlined"]], template: function AccessibilityDialogComponent_Template(rf, ctx) { if (rf & 1) {
|
|
8869
8886
|
i0.ɵɵelementStart(0, "h1", 0);
|
|
@@ -9006,5 +9023,5 @@ class CustomTranslateLoader {
|
|
|
9006
9023
|
* Generated bundle index. Do not edit.
|
|
9007
9024
|
*/
|
|
9008
9025
|
|
|
9009
|
-
export { ALERT_CONFIGURATION_TOKEN, AccessibilityContrasts, AccessibilityDialogComponent, AccessibilityFontSizes, AccessibilityService, AccessibilityTextMagnifierService, AlertService, AuthHeadersHelper, COLLECTIONS_MENU, ClickOutsideDirective, ClickOutsideModule, CloseButtonComponent, CloseButtonModule, CombinedCollection, CombinedCollectionTooltipKey, CompanyProductComponent, CompanyProductModule, Confirmation, ConfirmationModalComponent, ConfirmationModalModule, ConfirmationService, ConversionHelper, CustomPaginatorInernationalizationHelper, CustomTitleStrategyService, CustomTranslateLoader, DISABLE_EXPORT_ATTRIBUTE_NAME, DOMService, DateAgoModule, DateAgoPipe, DomainTranslatePipe, DragAndDropDirective, DragAndDropModule, ERROR_CODES, EngineTermApiService, EngineTermCollectionScope, EngineTermCollectionSource, EngineTermCollectionStatus, EngineTermCollectionSubStatus, ExportFormat, ExtensionDialogComponent, ExtensionDialogModule, ExtensionDialogService, FILE_SIZE_UNIT, FileCategories, FileExtensionHelper, FileExtensions, FileSizeLabelPipe, FileTypeIcons, FileTypes, FileUploadComponent, FileUploadErrorTypeEnum, FileUploadModule, FilterBarComponent, FilterBarModule, FilterWithHighlightModule, FilterWithHighlightPipe, FooterComponent, FooterModule, GlobalMessageComponent, HashHelper, HtmlElementParseHelper, HtmlHelper, IconService, InlineMessageComponent, InlineMessageIconPosition, InlineMessageModule, InlineMessageType, LAST_USED_SYSTEM_LOCAL_STORAGE_KEY, LLMActions, LLMComponent, LLMModule, LLM_CONFIGURATION_TOKEN, LanguageTranslateModule, LanguageTranslatePipe, LanguageTranslateService, MatButtonLoadingDirective, MatButtonLoadingModule, MissingTranslationHandlerService, MissingTranslationHelper, MtCollectionStatus, MultiFunctionalTableComponent, MultiFunctionalTableModule, NewFeatureDialogWrapperComponent, NotificationMessageComponent, NotificationMessageModule, NotificationMessageType, NotificationService, OPEN_CLOSE_BTN_ICONS_TOKEN, ObjectLengthModule, ObjectLengthPipe, OpenCloseButtonComponent, OpenCloseButtonModule, OpenExtensionDialogComponent, Operations, PlausibleEventDirective, PlausibleHelper, PlausibleModule, ResolutionHelper, SCREEN_SIZE, SaveFileHelper, SelectLanguageDialogComponent, SidebarComponent, SidebarService, SortAlphabeticallyModule, SortAlphabeticallyPipe, SortByNumberPipe, SortDomainsPipe, SortHelper, SortLanguageListPipe, SortTranslationsByPropertyModule, SortTranslationsByPropertyPipe, SortTranslationsModule, SortTranslationsPipe, StatusDisplayComponent, StatusDisplayModule, SubscriptionComponent, SubscriptionPlan, SystemService, TerminologyApiService, TerminologyCollectionService, TerminologyComponent, TerminologyConfigService, TerminologyCreateCollectionComponent, TerminologyModule, TerminologyService, TextToSpeechComponent, TldLoaderComponent, TldLoaderModule, ToastComponent, ToastService, getFileSizeLabel, provideCustomTitleStrategy };
|
|
9026
|
+
export { ALERT_CONFIGURATION_TOKEN, AccessibilityContrasts, AccessibilityDialogComponent, AccessibilityFontSizes, AccessibilityService, AccessibilityTextMagnifierService, AlertService, AuthHeadersHelper, COLLECTIONS_MENU, CUSTOM_TITLE_CONFIGURATION_TOKEN, ClickOutsideDirective, ClickOutsideModule, CloseButtonComponent, CloseButtonModule, CombinedCollection, CombinedCollectionTooltipKey, CompanyProductComponent, CompanyProductModule, Confirmation, ConfirmationModalComponent, ConfirmationModalModule, ConfirmationService, ConversionHelper, CustomPaginatorInernationalizationHelper, CustomTitleStrategyService, CustomTranslateLoader, DISABLE_EXPORT_ATTRIBUTE_NAME, DOMService, DateAgoModule, DateAgoPipe, DomainTranslatePipe, DragAndDropDirective, DragAndDropModule, ERROR_CODES, EngineTermApiService, EngineTermCollectionScope, EngineTermCollectionSource, EngineTermCollectionStatus, EngineTermCollectionSubStatus, ExportFormat, ExtensionDialogComponent, ExtensionDialogModule, ExtensionDialogService, FILE_SIZE_UNIT, FileCategories, FileExtensionHelper, FileExtensions, FileSizeLabelPipe, FileTypeIcons, FileTypes, FileUploadComponent, FileUploadErrorTypeEnum, FileUploadModule, FilterBarComponent, FilterBarModule, FilterWithHighlightModule, FilterWithHighlightPipe, FooterComponent, FooterModule, GlobalMessageComponent, HashHelper, HtmlElementParseHelper, HtmlHelper, IconService, InlineMessageComponent, InlineMessageIconPosition, InlineMessageModule, InlineMessageType, LAST_USED_SYSTEM_LOCAL_STORAGE_KEY, LLMActions, LLMComponent, LLMModule, LLM_CONFIGURATION_TOKEN, LanguageTranslateModule, LanguageTranslatePipe, LanguageTranslateService, MatButtonLoadingDirective, MatButtonLoadingModule, MissingTranslationHandlerService, MissingTranslationHelper, MtCollectionStatus, MultiFunctionalTableComponent, MultiFunctionalTableModule, NewFeatureDialogWrapperComponent, NotificationMessageComponent, NotificationMessageModule, NotificationMessageType, NotificationService, OPEN_CLOSE_BTN_ICONS_TOKEN, ObjectLengthModule, ObjectLengthPipe, OpenCloseButtonComponent, OpenCloseButtonModule, OpenExtensionDialogComponent, Operations, PlausibleEventDirective, PlausibleHelper, PlausibleModule, ResolutionHelper, SCREEN_SIZE, SaveFileHelper, SelectLanguageDialogComponent, SidebarComponent, SidebarService, SortAlphabeticallyModule, SortAlphabeticallyPipe, SortByNumberPipe, SortDomainsPipe, SortHelper, SortLanguageListPipe, SortTranslationsByPropertyModule, SortTranslationsByPropertyPipe, SortTranslationsModule, SortTranslationsPipe, StatusDisplayComponent, StatusDisplayModule, SubscriptionComponent, SubscriptionPlan, SystemService, TerminologyApiService, TerminologyCollectionService, TerminologyComponent, TerminologyConfigService, TerminologyCreateCollectionComponent, TerminologyModule, TerminologyService, TextToSpeechComponent, TldLoaderComponent, TldLoaderModule, ToastComponent, ToastService, getFileSizeLabel, provideCustomTitleStrategy };
|
|
9010
9027
|
//# sourceMappingURL=tilde-nlp-ngx-common.mjs.map
|