@praxisui/settings-panel 10.0.0-rc.60 → 10.0.0-rc.62
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.
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { inject, Renderer2, signal, DestroyRef, ViewContainerRef, HostListener, ViewChild, ViewEncapsulation, ChangeDetectionStrategy, Component, InjectionToken,
|
|
2
|
+
import { inject, Renderer2, signal, DestroyRef, Injector, afterNextRender, ViewContainerRef, HostListener, ViewChild, ViewEncapsulation, ChangeDetectionStrategy, Component, InjectionToken, Injectable, ElementRef, ChangeDetectorRef, ENVIRONMENT_INITIALIZER } from '@angular/core';
|
|
3
3
|
import * as i2 from '@angular/common';
|
|
4
4
|
import { CommonModule, NgStyle, NgClass } from '@angular/common';
|
|
5
5
|
import { InteractivityChecker, CdkTrapFocus } from '@angular/cdk/a11y';
|
|
@@ -14,10 +14,10 @@ import { MatProgressSpinnerModule } from '@angular/material/progress-spinner';
|
|
|
14
14
|
import * as i4$1 from '@angular/material/tooltip';
|
|
15
15
|
import { MatTooltipModule } from '@angular/material/tooltip';
|
|
16
16
|
import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
|
|
17
|
-
import { filter, switchMap, debounceTime, distinctUntilChanged } from 'rxjs/operators';
|
|
17
|
+
import { finalize, filter, switchMap, map, debounceTime, distinctUntilChanged } from 'rxjs/operators';
|
|
18
18
|
import { firstValueFrom, isObservable, of, from, Subject, ReplaySubject, take, takeUntil, BehaviorSubject } from 'rxjs';
|
|
19
19
|
import * as i1$2 from '@praxisui/core';
|
|
20
|
-
import { providePraxisI18n, PraxisI18nService, ApiConfigStorage, ASYNC_CONFIG_STORAGE, PraxisIconButtonComponent, PraxisIconDirective, SETTINGS_PANEL_DATA as SETTINGS_PANEL_DATA$1, PraxisLayerScaleStyleService, SETTINGS_PANEL_BRIDGE, SURFACE_DRAWER_BRIDGE, SURFACE_DRAWER_CONTENT_DATA, SURFACE_DRAWER_REF, GlobalConfigService, FieldControlType, IconPickerService, LoggerService, ComponentMetadataRegistry } from '@praxisui/core';
|
|
20
|
+
import { providePraxisI18n, PraxisI18nService, PraxisContextSwitchGuard, ApiConfigStorage, ASYNC_CONFIG_STORAGE, DeferredAsyncConfigStorage, parseConfigPersistenceError, PraxisIconButtonComponent, PraxisIconDirective, SETTINGS_PANEL_DATA as SETTINGS_PANEL_DATA$1, PraxisLayerScaleStyleService, SETTINGS_PANEL_BRIDGE, SURFACE_DRAWER_BRIDGE, SURFACE_DRAWER_CONTENT_DATA, SURFACE_DRAWER_REF, GlobalConfigService, FieldControlType, IconPickerService, LoggerService, ComponentMetadataRegistry } from '@praxisui/core';
|
|
21
21
|
import { ConfirmDialogComponent } from '@praxisui/dynamic-fields';
|
|
22
22
|
import * as i1$1 from '@angular/cdk/overlay';
|
|
23
23
|
import { ComponentPortal } from '@angular/cdk/portal';
|
|
@@ -469,11 +469,22 @@ const PRAXIS_SETTINGS_PANEL_EN_US = {
|
|
|
469
469
|
'Switch to tenant scope': 'Switch to tenant scope',
|
|
470
470
|
'Switch to personal scope': 'Switch to personal scope',
|
|
471
471
|
'Reset to tenant baseline': 'Reset to tenant baseline',
|
|
472
|
+
'Discard personal customizations and restore the shared tenant baseline?': 'Discard personal customizations and restore the shared tenant baseline?',
|
|
473
|
+
'Code: {{code}}': 'Code: {{code}}',
|
|
474
|
+
'Correlation ID: {{id}}': 'Correlation ID: {{id}}',
|
|
472
475
|
'Dismiss error': 'Dismiss error',
|
|
473
476
|
'Save failed: sensitive criteria cannot be shared at tenant scope.': 'Sensitive criteria cannot be published to shared tenant scope. Remove restricted criteria or save at your personal scope.',
|
|
474
477
|
'Save failed: configuration was modified by another user. Reload and try again.': 'Revision conflict detected (ETag): the configuration changed concurrently. Reload before retrying.',
|
|
475
478
|
'Save failed: you do not have permission to publish at this scope.': 'Insufficient permissions to publish changes at this configuration scope.',
|
|
479
|
+
'Save failed: configuration contains validation errors.': 'Configuration failed server validation. Review the fields and try again.',
|
|
480
|
+
'Save failed: network or persistence acknowledgment error.': 'Connection failed or the storage backend did not acknowledge persistence. Try again.',
|
|
481
|
+
'Save failed: server error while persisting configuration.': 'Server error while persisting the configuration. Please try again shortly.',
|
|
476
482
|
'Save failed: unable to persist configuration.': 'Unable to persist the configuration. Please try again shortly.',
|
|
483
|
+
'Reset failed: configuration was modified by another user. Reload and try again.': 'Revision conflict detected (ETag): the configuration changed concurrently. Reload before resetting.',
|
|
484
|
+
'Reset failed: you do not have permission to reset at this scope.': 'Insufficient permissions to reset changes at this configuration scope.',
|
|
485
|
+
'Reset failed: network or persistence acknowledgment error.': 'Connection failed or the storage backend did not acknowledge the reset. Try again.',
|
|
486
|
+
'Reset failed: server error while resetting configuration.': 'Server error while resetting the configuration. Please try again shortly.',
|
|
487
|
+
'Reset failed: unable to reset configuration.': 'Unable to reset the configuration. Please try again shortly.',
|
|
477
488
|
};
|
|
478
489
|
|
|
479
490
|
const PRAXIS_SETTINGS_PANEL_PT_BR = {
|
|
@@ -517,11 +528,22 @@ const PRAXIS_SETTINGS_PANEL_PT_BR = {
|
|
|
517
528
|
'Switch to tenant scope': 'Publicar para organização (Tenant)',
|
|
518
529
|
'Switch to personal scope': 'Salvar apenas no meu perfil',
|
|
519
530
|
'Reset to tenant baseline': 'Restaurar padrão da organização',
|
|
531
|
+
'Discard personal customizations and restore the shared tenant baseline?': 'Descartar as personalizações individuais e restaurar o padrão compartilhado da organização (Tenant)?',
|
|
532
|
+
'Code: {{code}}': 'Código: {{code}}',
|
|
533
|
+
'Correlation ID: {{id}}': 'Correlação: {{id}}',
|
|
520
534
|
'Dismiss error': 'Dispensar aviso',
|
|
521
535
|
'Save failed: sensitive criteria cannot be shared at tenant scope.': 'Critérios sensíveis não podem ser publicados no escopo compartilhado da organização (Tenant). Remova os critérios restritos ou salve no seu escopo pessoal.',
|
|
522
536
|
'Save failed: configuration was modified by another user. Reload and try again.': 'Conflito de revisão (ETag): outra alteração foi salva antes. Recarregue a configuração e tente novamente.',
|
|
523
537
|
'Save failed: you do not have permission to publish at this scope.': 'Sem permissão para publicar alterações neste escopo de configuração.',
|
|
538
|
+
'Save failed: configuration contains validation errors.': 'A configuração falhou na validação do servidor. Revise os campos e tente novamente.',
|
|
539
|
+
'Save failed: network or persistence acknowledgment error.': 'Falha de conexão ou ausência de confirmação ao persistir a configuração. Tente novamente.',
|
|
540
|
+
'Save failed: server error while persisting configuration.': 'Erro interno no servidor ao salvar a configuração. Tente novamente em instantes.',
|
|
524
541
|
'Save failed: unable to persist configuration.': 'Não foi possível salvar a configuração. Tente novamente em instantes.',
|
|
542
|
+
'Reset failed: configuration was modified by another user. Reload and try again.': 'Conflito de revisão (ETag): outra alteração foi salva antes. Recarregue antes de redefinir.',
|
|
543
|
+
'Reset failed: you do not have permission to reset at this scope.': 'Sem permissão para redefinir alterações neste escopo de configuração.',
|
|
544
|
+
'Reset failed: network or persistence acknowledgment error.': 'Falha de conexão ou ausência de confirmação ao redefinir a configuração. Tente novamente.',
|
|
545
|
+
'Reset failed: server error while resetting configuration.': 'Erro interno no servidor ao redefinir a configuração. Tente novamente em instantes.',
|
|
546
|
+
'Reset failed: unable to reset configuration.': 'Não foi possível redefinir a configuração. Tente novamente em instantes.',
|
|
525
547
|
};
|
|
526
548
|
|
|
527
549
|
const PRAXIS_SETTINGS_PANEL_I18N_NAMESPACE = 'praxis-settings-panel';
|
|
@@ -587,7 +609,11 @@ function isScopeErrorAwareStorage(candidate) {
|
|
|
587
609
|
if (!candidate || typeof candidate !== 'object')
|
|
588
610
|
return false;
|
|
589
611
|
const record = candidate;
|
|
590
|
-
return 'writeScope' in record ||
|
|
612
|
+
return ('writeScope' in record ||
|
|
613
|
+
'saveError$' in record ||
|
|
614
|
+
'evaluateWriteTargetScope' in record ||
|
|
615
|
+
'canWriteScope' in record ||
|
|
616
|
+
'canWriteConfig' in record);
|
|
591
617
|
}
|
|
592
618
|
const DEFAULT_DIAGNOSTICS = {
|
|
593
619
|
showStatusMessage: true,
|
|
@@ -614,6 +640,8 @@ class SettingsPanelComponent {
|
|
|
614
640
|
configStorageKey;
|
|
615
641
|
showWriteScope = true;
|
|
616
642
|
canSwitchWriteScope = true;
|
|
643
|
+
persistSaveHandler;
|
|
644
|
+
persistResetHandler;
|
|
617
645
|
previewing = false;
|
|
618
646
|
previewElement = null;
|
|
619
647
|
previewScroll = [];
|
|
@@ -630,49 +658,54 @@ class SettingsPanelComponent {
|
|
|
630
658
|
// the panel's already-checked footer subscribed to those late state changes.
|
|
631
659
|
dirtyState = signal(false, ...(ngDevMode ? [{ debugName: "dirtyState" }] : /* istanbul ignore next */ []));
|
|
632
660
|
validState = signal(true, ...(ngDevMode ? [{ debugName: "validState" }] : /* istanbul ignore next */ []));
|
|
633
|
-
|
|
661
|
+
providerBusyState = signal(false, ...(ngDevMode ? [{ debugName: "providerBusyState" }] : /* istanbul ignore next */ []));
|
|
662
|
+
persistenceBusyState = signal(false, ...(ngDevMode ? [{ debugName: "persistenceBusyState" }] : /* istanbul ignore next */ []));
|
|
634
663
|
get isDirty() { return this.dirtyState(); }
|
|
635
664
|
set isDirty(value) { this.dirtyState.set(value); }
|
|
636
665
|
get isValid() { return this.validState(); }
|
|
637
666
|
set isValid(value) { this.validState.set(value); }
|
|
638
|
-
get isBusy() {
|
|
639
|
-
|
|
667
|
+
get isBusy() {
|
|
668
|
+
return this.providerBusyState() || this.persistenceBusyState();
|
|
669
|
+
}
|
|
670
|
+
set isBusy(value) {
|
|
671
|
+
this.providerBusyState.set(value);
|
|
672
|
+
}
|
|
640
673
|
diagnostics = {
|
|
641
674
|
...DEFAULT_DIAGNOSTICS,
|
|
642
675
|
};
|
|
643
676
|
lastSavedAt = null;
|
|
644
677
|
hasAppliedChanges = false;
|
|
678
|
+
saveFailedPendingRetry = false;
|
|
679
|
+
confirmDialogOpen = false;
|
|
680
|
+
saveErrorStreamBound = false;
|
|
681
|
+
get isConfirmDialogOpen() {
|
|
682
|
+
return this.confirmDialogOpen;
|
|
683
|
+
}
|
|
645
684
|
activePointerId = null;
|
|
646
685
|
dragStartX = 0;
|
|
647
686
|
dragStartWidth = 0;
|
|
648
687
|
collapsedWidthBeforeExpand = null;
|
|
649
688
|
destroyRef = inject(DestroyRef);
|
|
689
|
+
injector = inject(Injector);
|
|
650
690
|
i18n = inject(PraxisI18nService);
|
|
691
|
+
contextSwitchGuard = inject(PraxisContextSwitchGuard, { optional: true });
|
|
651
692
|
directApiStorage = inject(ApiConfigStorage, { optional: true });
|
|
652
693
|
asyncConfigStorage = inject(ASYNC_CONFIG_STORAGE, {
|
|
653
694
|
optional: true,
|
|
654
695
|
});
|
|
655
|
-
scopeErrorStorage = this.
|
|
656
|
-
? isScopeErrorAwareStorage(this.asyncConfigStorage)
|
|
657
|
-
? this.asyncConfigStorage
|
|
658
|
-
: null
|
|
659
|
-
: this.directApiStorage;
|
|
696
|
+
scopeErrorStorage = this.resolveScopeErrorStorage();
|
|
660
697
|
storageSaveError = signal(null, ...(ngDevMode ? [{ debugName: "storageSaveError" }] : /* istanbul ignore next */ []));
|
|
661
698
|
applyActionLabel = this.actionLabel('Apply');
|
|
662
699
|
saveActionLabel = this.actionLabel('Save & Close');
|
|
663
700
|
contentHost;
|
|
701
|
+
saveErrorBanner;
|
|
664
702
|
constructor(cdr, dialog, elementRef, overlayContainer) {
|
|
665
703
|
this.cdr = cdr;
|
|
666
704
|
this.dialog = dialog;
|
|
667
705
|
this.elementRef = elementRef;
|
|
668
706
|
this.overlayContainer = overlayContainer;
|
|
707
|
+
this.contextSwitchGuard?.registerDirtyCheck(this.titleId, () => this.isDirty || this.hasAppliedChanges, { destroyRef: this.destroyRef });
|
|
669
708
|
this.destroyRef.onDestroy(() => this.restorePreviewPage());
|
|
670
|
-
this.scopeErrorStorage?.saveError$
|
|
671
|
-
?.pipe(takeUntilDestroyed(this.destroyRef))
|
|
672
|
-
.subscribe((err) => {
|
|
673
|
-
this.storageSaveError.set(err ?? null);
|
|
674
|
-
this.cdr.markForCheck();
|
|
675
|
-
});
|
|
676
709
|
}
|
|
677
710
|
get canInspectPreview() {
|
|
678
711
|
return !!this.previewTarget && this.interactionActive && this.isValid && !this.isBusy;
|
|
@@ -814,7 +847,12 @@ class SettingsPanelComponent {
|
|
|
814
847
|
this.previewScroll = [];
|
|
815
848
|
}
|
|
816
849
|
get canApply() {
|
|
817
|
-
return !this.previewing &&
|
|
850
|
+
return (!this.previewing &&
|
|
851
|
+
this.interactionActive &&
|
|
852
|
+
this.isDirty &&
|
|
853
|
+
this.isValid &&
|
|
854
|
+
!this.isBusy &&
|
|
855
|
+
!this.confirmDialogOpen);
|
|
818
856
|
}
|
|
819
857
|
get panelInlineStyles() {
|
|
820
858
|
return {
|
|
@@ -830,7 +868,12 @@ class SettingsPanelComponent {
|
|
|
830
868
|
return this.tx('Resize panel');
|
|
831
869
|
}
|
|
832
870
|
get canSave() {
|
|
833
|
-
return !this.previewing &&
|
|
871
|
+
return (!this.previewing &&
|
|
872
|
+
this.interactionActive &&
|
|
873
|
+
(this.isDirty || this.hasAppliedChanges || this.saveFailedPendingRetry) &&
|
|
874
|
+
this.isValid &&
|
|
875
|
+
!this.isBusy &&
|
|
876
|
+
!this.confirmDialogOpen);
|
|
834
877
|
}
|
|
835
878
|
setInteractionActive(active) {
|
|
836
879
|
if (active === this.interactionActive)
|
|
@@ -873,7 +916,7 @@ class SettingsPanelComponent {
|
|
|
873
916
|
if (!this.isValid) {
|
|
874
917
|
return this.tx('The configuration contains errors that need to be fixed.');
|
|
875
918
|
}
|
|
876
|
-
if (!this.isDirty) {
|
|
919
|
+
if (!this.isDirty && !this.hasAppliedChanges && !this.saveFailedPendingRetry) {
|
|
877
920
|
return this.tx('No changes to apply or save.');
|
|
878
921
|
}
|
|
879
922
|
return '';
|
|
@@ -892,7 +935,7 @@ class SettingsPanelComponent {
|
|
|
892
935
|
return 'busy';
|
|
893
936
|
if (!this.isValid && this.diagnostics.exposeValidationState)
|
|
894
937
|
return 'invalid';
|
|
895
|
-
if (this.isDirty)
|
|
938
|
+
if (this.isDirty || this.saveFailedPendingRetry)
|
|
896
939
|
return 'dirty';
|
|
897
940
|
if (this.hasAppliedChanges)
|
|
898
941
|
return 'applied';
|
|
@@ -930,16 +973,38 @@ class SettingsPanelComponent {
|
|
|
930
973
|
return this.showWriteScope && this.activeWriteScope !== null;
|
|
931
974
|
}
|
|
932
975
|
get canToggleWriteScope() {
|
|
933
|
-
|
|
934
|
-
this.interactionActive
|
|
935
|
-
|
|
936
|
-
|
|
976
|
+
if (!this.canSwitchWriteScope ||
|
|
977
|
+
!this.interactionActive ||
|
|
978
|
+
this.isBusy ||
|
|
979
|
+
this.confirmDialogOpen ||
|
|
980
|
+
typeof this.scopeErrorStorage?.setWriteScope !== 'function') {
|
|
981
|
+
return false;
|
|
982
|
+
}
|
|
983
|
+
const nextScope = this.activeWriteScope === 'tenant' ? 'user' : 'tenant';
|
|
984
|
+
const decision = this.scopeErrorStorage?.evaluateWriteTargetScope?.(this.configStorageKey ?? '', { scope: nextScope });
|
|
985
|
+
return decision ? decision.allowed : true;
|
|
986
|
+
}
|
|
987
|
+
resolveTenantResetStorage() {
|
|
988
|
+
const primary = this.asyncConfigStorage;
|
|
989
|
+
if (typeof primary?.deletePersonalOverrideAndReloadTenantBaseline === 'function') {
|
|
990
|
+
return primary;
|
|
991
|
+
}
|
|
992
|
+
if (typeof this.scopeErrorStorage?.deletePersonalOverrideAndReloadTenantBaseline === 'function') {
|
|
993
|
+
return this.scopeErrorStorage;
|
|
994
|
+
}
|
|
995
|
+
return null;
|
|
937
996
|
}
|
|
938
997
|
get canResetPersonalOverride() {
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
!this.
|
|
942
|
-
|
|
998
|
+
if (this.activeWriteScope !== 'user' ||
|
|
999
|
+
!this.configStorageKey ||
|
|
1000
|
+
!this.interactionActive ||
|
|
1001
|
+
this.isBusy ||
|
|
1002
|
+
this.confirmDialogOpen ||
|
|
1003
|
+
!this.resolveTenantResetStorage()) {
|
|
1004
|
+
return false;
|
|
1005
|
+
}
|
|
1006
|
+
const decision = this.scopeErrorStorage?.evaluateWriteTargetScope?.(this.configStorageKey, { scope: 'user' });
|
|
1007
|
+
return decision ? decision.allowed : true;
|
|
943
1008
|
}
|
|
944
1009
|
get writeScopeLabel() {
|
|
945
1010
|
return this.activeWriteScope === 'tenant'
|
|
@@ -955,32 +1020,148 @@ class SettingsPanelComponent {
|
|
|
955
1020
|
const err = this.storageSaveError();
|
|
956
1021
|
if (!err)
|
|
957
1022
|
return '';
|
|
958
|
-
|
|
1023
|
+
const isClear = err.operation === 'clear';
|
|
1024
|
+
const upperCode = err.errorCode?.trim().toUpperCase() ?? '';
|
|
1025
|
+
if (err.errorCode === 'SHARED_CONFIG_SENSITIVE_CRITERIA_DENIED') {
|
|
959
1026
|
return this.tx('Save failed: sensitive criteria cannot be shared at tenant scope.');
|
|
960
1027
|
}
|
|
1028
|
+
if (err.status === 403 ||
|
|
1029
|
+
err.errorCode === 'write_disabled' ||
|
|
1030
|
+
err.errorCode === 'scope_forbidden' ||
|
|
1031
|
+
err.errorCode === 'read_only_mode' ||
|
|
1032
|
+
err.errorCode === 'governance_denied' ||
|
|
1033
|
+
upperCode === 'GOVERNANCE_DENIED' ||
|
|
1034
|
+
upperCode === 'POLICY_DENIED' ||
|
|
1035
|
+
upperCode.includes('GOVERNANCE') ||
|
|
1036
|
+
err.errorCode?.endsWith('_DISABLED') ||
|
|
1037
|
+
upperCode === 'READ_ONLY') {
|
|
1038
|
+
return this.tx(isClear
|
|
1039
|
+
? 'Reset failed: you do not have permission to reset at this scope.'
|
|
1040
|
+
: 'Save failed: you do not have permission to publish at this scope.');
|
|
1041
|
+
}
|
|
1042
|
+
if (err.status === 422 && !isClear) {
|
|
1043
|
+
return (err.title?.trim() ||
|
|
1044
|
+
this.tx('Save failed: configuration contains validation errors.'));
|
|
1045
|
+
}
|
|
961
1046
|
if (err.status === 409 || err.status === 412) {
|
|
962
|
-
return this.tx(
|
|
1047
|
+
return this.tx(isClear
|
|
1048
|
+
? 'Reset failed: configuration was modified by another user. Reload and try again.'
|
|
1049
|
+
: 'Save failed: configuration was modified by another user. Reload and try again.');
|
|
1050
|
+
}
|
|
1051
|
+
if (err.errorCode === 'NETWORK_ERROR' ||
|
|
1052
|
+
err.errorCode === 'WRITE_UNACKNOWLEDGED') {
|
|
1053
|
+
return this.tx(isClear
|
|
1054
|
+
? 'Reset failed: network or persistence acknowledgment error.'
|
|
1055
|
+
: 'Save failed: network or persistence acknowledgment error.');
|
|
1056
|
+
}
|
|
1057
|
+
if (err.errorCode === 'CLIENT_ERROR') {
|
|
1058
|
+
return (err.detail?.trim() ||
|
|
1059
|
+
err.title?.trim() ||
|
|
1060
|
+
err.message?.trim() ||
|
|
1061
|
+
this.tx(isClear
|
|
1062
|
+
? 'Reset failed: unable to reset configuration.'
|
|
1063
|
+
: 'Save failed: unable to persist configuration.'));
|
|
1064
|
+
}
|
|
1065
|
+
if (typeof err.status === 'number' && err.status >= 500) {
|
|
1066
|
+
return this.tx(isClear
|
|
1067
|
+
? 'Reset failed: server error while resetting configuration.'
|
|
1068
|
+
: 'Save failed: server error while persisting configuration.');
|
|
1069
|
+
}
|
|
1070
|
+
return (err.title?.trim() ||
|
|
1071
|
+
this.tx(isClear
|
|
1072
|
+
? 'Reset failed: unable to reset configuration.'
|
|
1073
|
+
: 'Save failed: unable to persist configuration.'));
|
|
1074
|
+
}
|
|
1075
|
+
get saveErrorFieldMessages() {
|
|
1076
|
+
const err = this.storageSaveError();
|
|
1077
|
+
if (!err)
|
|
1078
|
+
return [];
|
|
1079
|
+
const raw = (err.raw && typeof err.raw === 'object' ? err.raw : null);
|
|
1080
|
+
const rawError = (raw?.['error'] && typeof raw['error'] === 'object' ? raw['error'] : raw);
|
|
1081
|
+
const source = err['fieldErrors'] ??
|
|
1082
|
+
rawError?.['fieldErrors'] ??
|
|
1083
|
+
rawError?.['violations'] ??
|
|
1084
|
+
rawError?.['errors'];
|
|
1085
|
+
const result = [];
|
|
1086
|
+
if (Array.isArray(source)) {
|
|
1087
|
+
for (const item of source) {
|
|
1088
|
+
if (typeof item === 'string' && item.trim()) {
|
|
1089
|
+
result.push(item.trim());
|
|
1090
|
+
}
|
|
1091
|
+
else if (item && typeof item === 'object') {
|
|
1092
|
+
const entry = item;
|
|
1093
|
+
const field = typeof entry['field'] === 'string'
|
|
1094
|
+
? entry['field'].trim()
|
|
1095
|
+
: typeof entry['propertyPath'] === 'string'
|
|
1096
|
+
? entry['propertyPath'].trim()
|
|
1097
|
+
: typeof entry['path'] === 'string'
|
|
1098
|
+
? entry['path'].trim()
|
|
1099
|
+
: '';
|
|
1100
|
+
const msg = typeof entry['message'] === 'string'
|
|
1101
|
+
? entry['message'].trim()
|
|
1102
|
+
: typeof entry['defaultMessage'] === 'string'
|
|
1103
|
+
? entry['defaultMessage'].trim()
|
|
1104
|
+
: '';
|
|
1105
|
+
if (msg) {
|
|
1106
|
+
result.push(field ? `${field}: ${msg}` : msg);
|
|
1107
|
+
}
|
|
1108
|
+
}
|
|
1109
|
+
}
|
|
1110
|
+
}
|
|
1111
|
+
else if (source && typeof source === 'object') {
|
|
1112
|
+
for (const [field, val] of Object.entries(source)) {
|
|
1113
|
+
if (typeof val === 'string' && val.trim()) {
|
|
1114
|
+
result.push(`${field}: ${val.trim()}`);
|
|
1115
|
+
}
|
|
1116
|
+
else if (Array.isArray(val)) {
|
|
1117
|
+
for (const msg of val) {
|
|
1118
|
+
if (typeof msg === 'string' && msg.trim()) {
|
|
1119
|
+
result.push(`${field}: ${msg.trim()}`);
|
|
1120
|
+
}
|
|
1121
|
+
}
|
|
1122
|
+
}
|
|
1123
|
+
}
|
|
1124
|
+
}
|
|
1125
|
+
return result;
|
|
1126
|
+
}
|
|
1127
|
+
get canSwitchToPersonalScopeFromError() {
|
|
1128
|
+
const err = this.storageSaveError();
|
|
1129
|
+
if (!err ||
|
|
1130
|
+
err.errorCode !== 'SHARED_CONFIG_SENSITIVE_CRITERIA_DENIED' ||
|
|
1131
|
+
this.activeWriteScope !== 'tenant') {
|
|
1132
|
+
return false;
|
|
963
1133
|
}
|
|
964
|
-
|
|
965
|
-
|
|
1134
|
+
const key = this.configStorageKey ?? '';
|
|
1135
|
+
const decision = this.scopeErrorStorage?.evaluateWriteTargetScope?.(key, {
|
|
1136
|
+
scope: 'user',
|
|
1137
|
+
});
|
|
1138
|
+
if (decision) {
|
|
1139
|
+
return decision.allowed;
|
|
966
1140
|
}
|
|
967
|
-
return this.
|
|
1141
|
+
return this.scopeErrorStorage?.canWriteScope?.('user', key) ?? true;
|
|
968
1142
|
}
|
|
969
1143
|
toggleWriteScope() {
|
|
970
1144
|
if (!this.canToggleWriteScope)
|
|
971
1145
|
return;
|
|
972
1146
|
if (typeof this.scopeErrorStorage?.toggleWriteScope === 'function') {
|
|
973
|
-
this.scopeErrorStorage.toggleWriteScope();
|
|
1147
|
+
this.scopeErrorStorage.toggleWriteScope(this.configStorageKey);
|
|
974
1148
|
}
|
|
975
1149
|
else {
|
|
976
1150
|
const next = this.activeWriteScope === 'tenant' ? 'user' : 'tenant';
|
|
977
|
-
this.scopeErrorStorage?.setWriteScope?.(next);
|
|
1151
|
+
this.scopeErrorStorage?.setWriteScope?.(next, this.configStorageKey);
|
|
978
1152
|
}
|
|
979
1153
|
this.scopeErrorStorage?.clearSaveError?.();
|
|
980
1154
|
this.cdr.markForCheck();
|
|
981
1155
|
}
|
|
982
1156
|
switchToPersonalScopeFromError() {
|
|
983
|
-
this.
|
|
1157
|
+
if (!this.canSwitchToPersonalScopeFromError)
|
|
1158
|
+
return;
|
|
1159
|
+
if (this.configStorageKey) {
|
|
1160
|
+
this.scopeErrorStorage?.setWriteScope?.('user', this.configStorageKey);
|
|
1161
|
+
}
|
|
1162
|
+
else {
|
|
1163
|
+
this.scopeErrorStorage?.setWriteScope?.('user');
|
|
1164
|
+
}
|
|
984
1165
|
this.dismissSaveError();
|
|
985
1166
|
}
|
|
986
1167
|
dismissSaveError() {
|
|
@@ -990,21 +1171,186 @@ class SettingsPanelComponent {
|
|
|
990
1171
|
}
|
|
991
1172
|
resetPersonalOverrideToTenant() {
|
|
992
1173
|
const key = this.configStorageKey;
|
|
993
|
-
const
|
|
994
|
-
|
|
1174
|
+
const resetStorage = this.resolveTenantResetStorage();
|
|
1175
|
+
const fn = resetStorage?.deletePersonalOverrideAndReloadTenantBaseline;
|
|
1176
|
+
if (!key ||
|
|
1177
|
+
typeof fn !== 'function' ||
|
|
1178
|
+
this.isBusy ||
|
|
1179
|
+
this.destroyRef.destroyed ||
|
|
1180
|
+
!this.interactionActive ||
|
|
1181
|
+
this.confirmDialogOpen) {
|
|
995
1182
|
return;
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
.
|
|
1000
|
-
this.
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1183
|
+
}
|
|
1184
|
+
const dialogData = {
|
|
1185
|
+
title: this.tx('Reset to tenant baseline'),
|
|
1186
|
+
message: this.tx('Discard personal customizations and restore the shared tenant baseline?'),
|
|
1187
|
+
confirmText: this.tx('Reset'),
|
|
1188
|
+
cancelText: this.tx('Cancel'),
|
|
1189
|
+
type: 'warning',
|
|
1190
|
+
icon: 'restart_alt',
|
|
1191
|
+
};
|
|
1192
|
+
this.confirmDialogOpen = true;
|
|
1193
|
+
this.dialog
|
|
1194
|
+
.open(ConfirmDialogComponent, { data: dialogData, autoFocus: false })
|
|
1195
|
+
.afterClosed()
|
|
1196
|
+
.pipe(finalize(() => {
|
|
1197
|
+
this.confirmDialogOpen = false;
|
|
1198
|
+
}), filter((confirmed) => Boolean(confirmed)), takeUntilDestroyed(this.destroyRef))
|
|
1199
|
+
.subscribe(() => {
|
|
1200
|
+
if (this.isBusy || this.destroyRef.destroyed) {
|
|
1201
|
+
return;
|
|
1202
|
+
}
|
|
1203
|
+
const gateError = this.checkWriteGate('clear', 'user');
|
|
1204
|
+
if (gateError) {
|
|
1205
|
+
this.handlePersistenceFailure(gateError, 'clear');
|
|
1206
|
+
return;
|
|
1207
|
+
}
|
|
1208
|
+
this.persistenceBusyState.set(true);
|
|
1209
|
+
this.dismissSaveError();
|
|
1005
1210
|
this.cdr.markForCheck();
|
|
1211
|
+
let baselineObs;
|
|
1212
|
+
try {
|
|
1213
|
+
baselineObs = fn.call(resetStorage, key);
|
|
1214
|
+
}
|
|
1215
|
+
catch (syncError) {
|
|
1216
|
+
this.persistenceBusyState.set(false);
|
|
1217
|
+
this.handlePersistenceFailure(syncError, 'clear');
|
|
1218
|
+
if (!this.destroyRef.destroyed) {
|
|
1219
|
+
this.cdr.markForCheck();
|
|
1220
|
+
}
|
|
1221
|
+
return;
|
|
1222
|
+
}
|
|
1223
|
+
firstValueFrom(baselineObs)
|
|
1224
|
+
.then((tenantBaseline) => {
|
|
1225
|
+
if (this.destroyRef.destroyed) {
|
|
1226
|
+
return;
|
|
1227
|
+
}
|
|
1228
|
+
this.saveFailedPendingRetry = false;
|
|
1229
|
+
this.hasAppliedChanges = false;
|
|
1230
|
+
this.lastSavedAt = null;
|
|
1231
|
+
this.isDirty = false;
|
|
1232
|
+
this.ref?.notifyTenantBaselineRestored?.(tenantBaseline ?? null);
|
|
1233
|
+
if (tenantBaseline !== null && tenantBaseline !== undefined) {
|
|
1234
|
+
if (typeof this.contentRef?.instance?.acceptAppliedValue === 'function') {
|
|
1235
|
+
this.contentRef.instance.acceptAppliedValue(tenantBaseline);
|
|
1236
|
+
}
|
|
1237
|
+
else {
|
|
1238
|
+
this.contentRef?.instance?.reset?.();
|
|
1239
|
+
}
|
|
1240
|
+
this.ref?.apply?.(tenantBaseline);
|
|
1241
|
+
}
|
|
1242
|
+
else {
|
|
1243
|
+
this.contentRef?.instance?.reset?.();
|
|
1244
|
+
this.ref?.reset?.();
|
|
1245
|
+
}
|
|
1246
|
+
})
|
|
1247
|
+
.catch((error) => {
|
|
1248
|
+
if (this.destroyRef.destroyed) {
|
|
1249
|
+
return;
|
|
1250
|
+
}
|
|
1251
|
+
this.handlePersistenceFailure(error, 'clear');
|
|
1252
|
+
})
|
|
1253
|
+
.finally(() => {
|
|
1254
|
+
if (this.destroyRef.destroyed) {
|
|
1255
|
+
return;
|
|
1256
|
+
}
|
|
1257
|
+
this.persistenceBusyState.set(false);
|
|
1258
|
+
this.cdr.markForCheck();
|
|
1259
|
+
});
|
|
1006
1260
|
});
|
|
1007
1261
|
}
|
|
1262
|
+
matchesPanelStorageKey(err) {
|
|
1263
|
+
if (!err)
|
|
1264
|
+
return true;
|
|
1265
|
+
const errKey = err.key?.trim() || '';
|
|
1266
|
+
if (!errKey)
|
|
1267
|
+
return true;
|
|
1268
|
+
const activeKey = this.configStorageKey?.trim() || '';
|
|
1269
|
+
return Boolean(activeKey && errKey === activeKey);
|
|
1270
|
+
}
|
|
1271
|
+
resolveScopeErrorStorage() {
|
|
1272
|
+
if (this.asyncConfigStorage) {
|
|
1273
|
+
const maybeDeferred = this.asyncConfigStorage;
|
|
1274
|
+
const unwrap = maybeDeferred.unwrapDelegate;
|
|
1275
|
+
const resolved = this.asyncConfigStorage instanceof DeferredAsyncConfigStorage ||
|
|
1276
|
+
typeof unwrap === 'function'
|
|
1277
|
+
? unwrap.call(maybeDeferred)
|
|
1278
|
+
: this.asyncConfigStorage;
|
|
1279
|
+
return isScopeErrorAwareStorage(resolved) ? resolved : null;
|
|
1280
|
+
}
|
|
1281
|
+
return this.directApiStorage;
|
|
1282
|
+
}
|
|
1283
|
+
checkWriteGate(operation, scopeOverride) {
|
|
1284
|
+
const key = this.configStorageKey?.trim() ?? '';
|
|
1285
|
+
const evaluate = this.scopeErrorStorage?.evaluateWriteTargetScope;
|
|
1286
|
+
if (typeof evaluate !== 'function') {
|
|
1287
|
+
return null;
|
|
1288
|
+
}
|
|
1289
|
+
const decision = evaluate.call(this.scopeErrorStorage, key, {
|
|
1290
|
+
scope: scopeOverride ?? this.activeWriteScope ?? undefined,
|
|
1291
|
+
});
|
|
1292
|
+
if (decision.allowed) {
|
|
1293
|
+
return null;
|
|
1294
|
+
}
|
|
1295
|
+
return {
|
|
1296
|
+
operation,
|
|
1297
|
+
key,
|
|
1298
|
+
scope: decision.scope,
|
|
1299
|
+
status: decision.code === 'governance_denied' ? 422 : 403,
|
|
1300
|
+
errorCode: decision.code ?? 'scope_forbidden',
|
|
1301
|
+
title: this.tx(operation === 'clear'
|
|
1302
|
+
? 'Reset failed: you do not have permission to reset at this scope.'
|
|
1303
|
+
: 'Save failed: you do not have permission to publish at this scope.'),
|
|
1304
|
+
detail: decision.reason ?? undefined,
|
|
1305
|
+
message: decision.reason ??
|
|
1306
|
+
this.tx(operation === 'clear'
|
|
1307
|
+
? 'Reset failed: you do not have permission to reset at this scope.'
|
|
1308
|
+
: 'Save failed: you do not have permission to publish at this scope.'),
|
|
1309
|
+
timestamp: Date.now(),
|
|
1310
|
+
};
|
|
1311
|
+
}
|
|
1312
|
+
isPrebuiltSaveError(error) {
|
|
1313
|
+
return (Boolean(error) &&
|
|
1314
|
+
typeof error === 'object' &&
|
|
1315
|
+
'timestamp' in error &&
|
|
1316
|
+
'status' in error &&
|
|
1317
|
+
'message' in error &&
|
|
1318
|
+
'operation' in error);
|
|
1319
|
+
}
|
|
1320
|
+
handlePersistenceFailure(error, operation = 'save') {
|
|
1321
|
+
if (this.destroyRef.destroyed) {
|
|
1322
|
+
return;
|
|
1323
|
+
}
|
|
1324
|
+
const isEmptyError = error instanceof Error && error.name === 'EmptyError';
|
|
1325
|
+
const parsed = this.isPrebuiltSaveError(error)
|
|
1326
|
+
? error
|
|
1327
|
+
: isEmptyError
|
|
1328
|
+
? (this.storageSaveError() ??
|
|
1329
|
+
parseConfigPersistenceError(error, {
|
|
1330
|
+
key: this.configStorageKey,
|
|
1331
|
+
scope: this.activeWriteScope ?? undefined,
|
|
1332
|
+
operation,
|
|
1333
|
+
}))
|
|
1334
|
+
: (parseConfigPersistenceError(error, {
|
|
1335
|
+
key: this.configStorageKey,
|
|
1336
|
+
scope: this.activeWriteScope ?? undefined,
|
|
1337
|
+
operation,
|
|
1338
|
+
}) ?? this.storageSaveError());
|
|
1339
|
+
if (operation !== 'clear') {
|
|
1340
|
+
this.saveFailedPendingRetry = true;
|
|
1341
|
+
}
|
|
1342
|
+
this.storageSaveError.set(parsed);
|
|
1343
|
+
this.ref?.reportPersistenceError?.(parsed);
|
|
1344
|
+
this.cdr.markForCheck();
|
|
1345
|
+
afterNextRender(() => {
|
|
1346
|
+
if (this.destroyRef.destroyed)
|
|
1347
|
+
return;
|
|
1348
|
+
const banner = this.saveErrorBanner?.nativeElement;
|
|
1349
|
+
if (banner?.isConnected) {
|
|
1350
|
+
banner.focus({ preventScroll: true });
|
|
1351
|
+
}
|
|
1352
|
+
}, { injector: this.injector });
|
|
1353
|
+
}
|
|
1008
1354
|
tx(text, params) {
|
|
1009
1355
|
const translated = this.i18n.t(text, params, text, PRAXIS_SETTINGS_PANEL_I18N_NAMESPACE);
|
|
1010
1356
|
return translated?.trim() ? translated : text;
|
|
@@ -1040,7 +1386,36 @@ class SettingsPanelComponent {
|
|
|
1040
1386
|
instance.isBusy$
|
|
1041
1387
|
.pipe(takeUntilDestroyed(this.destroyRef))
|
|
1042
1388
|
.subscribe((busy) => {
|
|
1043
|
-
this.
|
|
1389
|
+
this.providerBusyState.set(busy);
|
|
1390
|
+
this.cdr.markForCheck();
|
|
1391
|
+
});
|
|
1392
|
+
}
|
|
1393
|
+
if (!this.saveErrorStreamBound) {
|
|
1394
|
+
this.saveErrorStreamBound = true;
|
|
1395
|
+
let replayingInitial = true;
|
|
1396
|
+
this.scopeErrorStorage?.saveError$
|
|
1397
|
+
?.pipe(takeUntilDestroyed(this.destroyRef))
|
|
1398
|
+
.subscribe((err) => {
|
|
1399
|
+
if (replayingInitial) {
|
|
1400
|
+
return;
|
|
1401
|
+
}
|
|
1402
|
+
if (err && !this.matchesPanelStorageKey(err)) {
|
|
1403
|
+
return;
|
|
1404
|
+
}
|
|
1405
|
+
this.storageSaveError.set(err ?? null);
|
|
1406
|
+
this.cdr.markForCheck();
|
|
1407
|
+
});
|
|
1408
|
+
replayingInitial = false;
|
|
1409
|
+
}
|
|
1410
|
+
const refError$ = ref?.persistenceError$;
|
|
1411
|
+
if (refError$) {
|
|
1412
|
+
refError$
|
|
1413
|
+
.pipe(takeUntilDestroyed(this.destroyRef))
|
|
1414
|
+
.subscribe((err) => {
|
|
1415
|
+
if (err && !this.matchesPanelStorageKey(err)) {
|
|
1416
|
+
return;
|
|
1417
|
+
}
|
|
1418
|
+
this.storageSaveError.set(err);
|
|
1044
1419
|
this.cdr.markForCheck();
|
|
1045
1420
|
});
|
|
1046
1421
|
}
|
|
@@ -1087,6 +1462,12 @@ class SettingsPanelComponent {
|
|
|
1087
1462
|
return new Set(Object.keys(declaredInputs));
|
|
1088
1463
|
}
|
|
1089
1464
|
onReset() {
|
|
1465
|
+
if (this.isBusy ||
|
|
1466
|
+
this.destroyRef.destroyed ||
|
|
1467
|
+
!this.interactionActive ||
|
|
1468
|
+
this.confirmDialogOpen) {
|
|
1469
|
+
return;
|
|
1470
|
+
}
|
|
1090
1471
|
const dialogData = {
|
|
1091
1472
|
title: this.tx('Reset Changes'),
|
|
1092
1473
|
message: this.tx('Are you sure you want to reset all changes?'),
|
|
@@ -1095,16 +1476,58 @@ class SettingsPanelComponent {
|
|
|
1095
1476
|
type: 'warning',
|
|
1096
1477
|
icon: 'restart_alt',
|
|
1097
1478
|
};
|
|
1479
|
+
this.confirmDialogOpen = true;
|
|
1098
1480
|
this.dialog
|
|
1099
1481
|
.open(ConfirmDialogComponent, { data: dialogData, autoFocus: false })
|
|
1100
1482
|
.afterClosed()
|
|
1101
|
-
.pipe(
|
|
1483
|
+
.pipe(finalize(() => {
|
|
1484
|
+
this.confirmDialogOpen = false;
|
|
1485
|
+
}), filter((confirmed) => Boolean(confirmed)), takeUntilDestroyed(this.destroyRef))
|
|
1102
1486
|
.subscribe(() => {
|
|
1103
|
-
this.
|
|
1104
|
-
|
|
1105
|
-
|
|
1487
|
+
if (!this.persistResetHandler) {
|
|
1488
|
+
this.finalizeReset();
|
|
1489
|
+
return;
|
|
1490
|
+
}
|
|
1491
|
+
void this.runAsyncResetFlow();
|
|
1106
1492
|
});
|
|
1107
1493
|
}
|
|
1494
|
+
finalizeReset() {
|
|
1495
|
+
this.contentRef?.instance?.reset?.();
|
|
1496
|
+
this.lastSavedAt = null;
|
|
1497
|
+
this.hasAppliedChanges = false;
|
|
1498
|
+
this.saveFailedPendingRetry = false;
|
|
1499
|
+
this.dismissSaveError();
|
|
1500
|
+
this.ref.reset();
|
|
1501
|
+
this.cdr.markForCheck();
|
|
1502
|
+
}
|
|
1503
|
+
async runAsyncResetFlow() {
|
|
1504
|
+
if (!this.persistResetHandler) {
|
|
1505
|
+
this.finalizeReset();
|
|
1506
|
+
return;
|
|
1507
|
+
}
|
|
1508
|
+
const gateError = this.checkWriteGate('clear');
|
|
1509
|
+
if (gateError) {
|
|
1510
|
+
this.handlePersistenceFailure(gateError, 'clear');
|
|
1511
|
+
return;
|
|
1512
|
+
}
|
|
1513
|
+
this.dismissSaveError();
|
|
1514
|
+
this.persistenceBusyState.set(true);
|
|
1515
|
+
this.cdr.markForCheck();
|
|
1516
|
+
try {
|
|
1517
|
+
const result = this.persistResetHandler();
|
|
1518
|
+
if (isObservable(result) || result instanceof Promise) {
|
|
1519
|
+
await this.awaitResult(result);
|
|
1520
|
+
}
|
|
1521
|
+
this.persistenceBusyState.set(false);
|
|
1522
|
+
if (!this.destroyRef.destroyed) {
|
|
1523
|
+
this.finalizeReset();
|
|
1524
|
+
}
|
|
1525
|
+
}
|
|
1526
|
+
catch (error) {
|
|
1527
|
+
this.persistenceBusyState.set(false);
|
|
1528
|
+
this.handlePersistenceFailure(error, 'clear');
|
|
1529
|
+
}
|
|
1530
|
+
}
|
|
1108
1531
|
onApply() {
|
|
1109
1532
|
if (!this.canApply)
|
|
1110
1533
|
return;
|
|
@@ -1113,6 +1536,7 @@ class SettingsPanelComponent {
|
|
|
1113
1536
|
// publish a preview based only on the state captured before validation.
|
|
1114
1537
|
if (value === undefined || !this.isValid || this.isBusy || !this.interactionActive)
|
|
1115
1538
|
return;
|
|
1539
|
+
this.saveFailedPendingRetry = false;
|
|
1116
1540
|
this.ref.apply(value);
|
|
1117
1541
|
// Applying can synchronously clear the editor's draft. Saving still needs
|
|
1118
1542
|
// to invoke the provider again, never replay a cached geometry request.
|
|
@@ -1124,30 +1548,92 @@ class SettingsPanelComponent {
|
|
|
1124
1548
|
return;
|
|
1125
1549
|
this.dismissSaveError();
|
|
1126
1550
|
const instance = this.contentRef?.instance;
|
|
1127
|
-
|
|
1128
|
-
|
|
1129
|
-
|
|
1130
|
-
|
|
1131
|
-
|
|
1551
|
+
let rawResult;
|
|
1552
|
+
try {
|
|
1553
|
+
const result = instance?.onSave?.();
|
|
1554
|
+
rawResult =
|
|
1555
|
+
result !== undefined || isObservable(result) || result instanceof Promise
|
|
1556
|
+
? result
|
|
1557
|
+
: instance?.getSettingsValue?.();
|
|
1132
1558
|
}
|
|
1133
|
-
|
|
1134
|
-
|
|
1559
|
+
catch (error) {
|
|
1560
|
+
this.handlePersistenceFailure(error, 'save');
|
|
1561
|
+
return;
|
|
1562
|
+
}
|
|
1563
|
+
if (isObservable(rawResult) || rawResult instanceof Promise) {
|
|
1564
|
+
void this.runAsyncSaveFlow(rawResult, false);
|
|
1565
|
+
return;
|
|
1135
1566
|
}
|
|
1136
|
-
|
|
1137
|
-
|
|
1567
|
+
if (!this.canProceedWithSave(rawResult)) {
|
|
1568
|
+
return;
|
|
1138
1569
|
}
|
|
1139
|
-
|
|
1140
|
-
|
|
1570
|
+
if (!this.persistSaveHandler) {
|
|
1571
|
+
this.emitSave(rawResult);
|
|
1572
|
+
return;
|
|
1573
|
+
}
|
|
1574
|
+
void this.runAsyncSaveFlow(rawResult, true);
|
|
1575
|
+
}
|
|
1576
|
+
async runAsyncSaveFlow(rawResult, alreadyResolved) {
|
|
1577
|
+
this.persistenceBusyState.set(true);
|
|
1578
|
+
this.cdr.markForCheck();
|
|
1579
|
+
try {
|
|
1580
|
+
const value = alreadyResolved
|
|
1581
|
+
? rawResult
|
|
1582
|
+
: await this.awaitResult(rawResult);
|
|
1583
|
+
if (!this.canProceedWithSave(value)) {
|
|
1584
|
+
this.persistenceBusyState.set(false);
|
|
1585
|
+
this.cdr.markForCheck();
|
|
1586
|
+
return;
|
|
1587
|
+
}
|
|
1588
|
+
if (this.persistSaveHandler) {
|
|
1589
|
+
const gateError = this.checkWriteGate('save');
|
|
1590
|
+
if (gateError) {
|
|
1591
|
+
this.persistenceBusyState.set(false);
|
|
1592
|
+
this.handlePersistenceFailure(gateError, 'save');
|
|
1593
|
+
return;
|
|
1594
|
+
}
|
|
1595
|
+
const persisted = this.persistSaveHandler(value);
|
|
1596
|
+
if (isObservable(persisted) || persisted instanceof Promise) {
|
|
1597
|
+
await this.awaitResult(persisted);
|
|
1598
|
+
}
|
|
1599
|
+
if (!this.canProceedWithSave(value)) {
|
|
1600
|
+
this.persistenceBusyState.set(false);
|
|
1601
|
+
this.cdr.markForCheck();
|
|
1602
|
+
return;
|
|
1603
|
+
}
|
|
1604
|
+
}
|
|
1605
|
+
this.persistenceBusyState.set(false);
|
|
1141
1606
|
this.emitSave(value);
|
|
1142
1607
|
}
|
|
1608
|
+
catch (error) {
|
|
1609
|
+
this.persistenceBusyState.set(false);
|
|
1610
|
+
this.handlePersistenceFailure(error, 'save');
|
|
1611
|
+
}
|
|
1612
|
+
}
|
|
1613
|
+
awaitResult(result) {
|
|
1614
|
+
if (isObservable(result)) {
|
|
1615
|
+
return firstValueFrom(result);
|
|
1616
|
+
}
|
|
1617
|
+
if (result instanceof Promise) {
|
|
1618
|
+
return result;
|
|
1619
|
+
}
|
|
1620
|
+
return Promise.resolve(result);
|
|
1621
|
+
}
|
|
1622
|
+
canProceedWithSave(value) {
|
|
1623
|
+
return (value !== undefined &&
|
|
1624
|
+
this.isValid &&
|
|
1625
|
+
!this.providerBusyState() &&
|
|
1626
|
+
this.interactionActive &&
|
|
1627
|
+
!this.destroyRef.destroyed);
|
|
1143
1628
|
}
|
|
1144
1629
|
emitSave(value) {
|
|
1145
1630
|
// Recheck after synchronous validation or asynchronous completion. Dirty
|
|
1146
1631
|
// may legitimately be cleared by a successful provider; it is not a veto.
|
|
1147
|
-
if (
|
|
1632
|
+
if (!this.canProceedWithSave(value) || this.isBusy)
|
|
1148
1633
|
return;
|
|
1149
1634
|
this.lastSavedAt = Date.now();
|
|
1150
1635
|
this.hasAppliedChanges = false;
|
|
1636
|
+
this.saveFailedPendingRetry = false;
|
|
1151
1637
|
this.isDirty = false;
|
|
1152
1638
|
this.ref.save(value);
|
|
1153
1639
|
this.cdr.markForCheck();
|
|
@@ -1261,13 +1747,19 @@ class SettingsPanelComponent {
|
|
|
1261
1747
|
}
|
|
1262
1748
|
}
|
|
1263
1749
|
onCancel() {
|
|
1750
|
+
if (this.isBusy || this.confirmDialogOpen) {
|
|
1751
|
+
return;
|
|
1752
|
+
}
|
|
1264
1753
|
this.requestClose('cancel')
|
|
1265
|
-
.pipe(filter((confirmed) => confirmed))
|
|
1754
|
+
.pipe(filter((confirmed) => Boolean(confirmed)), takeUntilDestroyed(this.destroyRef))
|
|
1266
1755
|
.subscribe(() => {
|
|
1267
1756
|
this.ref.close('cancel');
|
|
1268
1757
|
});
|
|
1269
1758
|
}
|
|
1270
1759
|
requestClose(reason) {
|
|
1760
|
+
if (this.isBusy || this.confirmDialogOpen) {
|
|
1761
|
+
return of(false);
|
|
1762
|
+
}
|
|
1271
1763
|
if (this.previewing) {
|
|
1272
1764
|
this.returnFromPreview();
|
|
1273
1765
|
if (reason === 'esc' || reason === 'backdrop')
|
|
@@ -1284,11 +1776,11 @@ class SettingsPanelComponent {
|
|
|
1284
1776
|
}));
|
|
1285
1777
|
}
|
|
1286
1778
|
handleKeydown(event) {
|
|
1287
|
-
if (!this.interactionActive) {
|
|
1779
|
+
if (!this.interactionActive || this.confirmDialogOpen) {
|
|
1288
1780
|
return;
|
|
1289
1781
|
}
|
|
1290
1782
|
if (event.key === 'Escape') {
|
|
1291
|
-
if (this.shouldDeferEscape(event)) {
|
|
1783
|
+
if (this.isBusy || this.shouldDeferEscape(event)) {
|
|
1292
1784
|
return;
|
|
1293
1785
|
}
|
|
1294
1786
|
event.preventDefault();
|
|
@@ -1298,13 +1790,17 @@ class SettingsPanelComponent {
|
|
|
1298
1790
|
this.onCancel();
|
|
1299
1791
|
}
|
|
1300
1792
|
else if (event.key === 'Enter' && (event.ctrlKey || event.metaKey)) {
|
|
1301
|
-
|
|
1302
|
-
|
|
1793
|
+
if (this.canSave) {
|
|
1794
|
+
event.preventDefault();
|
|
1795
|
+
this.onSave();
|
|
1796
|
+
}
|
|
1303
1797
|
}
|
|
1304
1798
|
else if ((event.key === 's' || event.key === 'S') &&
|
|
1305
1799
|
(event.ctrlKey || event.metaKey)) {
|
|
1306
|
-
|
|
1307
|
-
|
|
1800
|
+
if (this.canSave) {
|
|
1801
|
+
event.preventDefault();
|
|
1802
|
+
this.onSave();
|
|
1803
|
+
}
|
|
1308
1804
|
}
|
|
1309
1805
|
}
|
|
1310
1806
|
shouldDeferEscape(event) {
|
|
@@ -1380,9 +1876,12 @@ class SettingsPanelComponent {
|
|
|
1380
1876
|
}
|
|
1381
1877
|
}
|
|
1382
1878
|
confirmDiscardIfNeeded() {
|
|
1383
|
-
if (!this.isDirty) {
|
|
1879
|
+
if (!this.isDirty && !this.saveFailedPendingRetry) {
|
|
1384
1880
|
return of(true);
|
|
1385
1881
|
}
|
|
1882
|
+
if (this.confirmDialogOpen) {
|
|
1883
|
+
return of(false);
|
|
1884
|
+
}
|
|
1386
1885
|
const dialogData = {
|
|
1387
1886
|
title: this.tx('Discard unsaved draft'),
|
|
1388
1887
|
message: this.tx(this.hasAppliedChanges
|
|
@@ -1393,12 +1892,16 @@ class SettingsPanelComponent {
|
|
|
1393
1892
|
type: 'warning',
|
|
1394
1893
|
icon: 'warning',
|
|
1395
1894
|
};
|
|
1895
|
+
this.confirmDialogOpen = true;
|
|
1396
1896
|
return this.dialog
|
|
1397
1897
|
.open(ConfirmDialogComponent, { data: dialogData, autoFocus: false })
|
|
1398
|
-
.afterClosed()
|
|
1898
|
+
.afterClosed()
|
|
1899
|
+
.pipe(finalize(() => {
|
|
1900
|
+
this.confirmDialogOpen = false;
|
|
1901
|
+
}), map((confirmed) => Boolean(confirmed)), takeUntilDestroyed(this.destroyRef));
|
|
1399
1902
|
}
|
|
1400
1903
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: SettingsPanelComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: i1.MatDialog }, { token: i0.ElementRef }, { token: i1$1.OverlayContainer }], target: i0.ɵɵFactoryTarget.Component });
|
|
1401
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.14", type: SettingsPanelComponent, isStandalone: true, selector: "praxis-settings-panel", host: { listeners: { "document:keydown": "handleKeydown($event)", "document:pointermove": "onDocumentPointerMove($event)", "document:pointerup": "onDocumentPointerEnd($event)", "document:pointercancel": "onDocumentPointerEnd($event)" } }, providers: [providePraxisSettingsPanelI18n()], viewQueries: [{ propertyName: "focusTrap", first: true, predicate: CdkTrapFocus, descendants: true }, { propertyName: "contentHost", first: true, predicate: ["contentHost"], descendants: true, read: ViewContainerRef, static: true }], ngImport: i0, template: "<div\n class=\"settings-panel\"\n data-testid=\"settings-panel-root\"\n [class.expanded]=\"expanded\"\n [class.settings-panel--preview]=\"previewing\"\n [class.is-resizable]=\"showResizeHandle\"\n [ngStyle]=\"panelInlineStyles\"\n role=\"dialog\"\n [attr.aria-modal]=\"interactionActive ? 'true' : null\"\n [attr.aria-hidden]=\"interactionActive ? null : 'true'\"\n [attr.inert]=\"interactionActive ? null : ''\"\n [attr.aria-labelledby]=\"previewing ? titleId + '-preview' : titleId\"\n [cdkTrapFocus]=\"interactionActive\"\n [cdkTrapFocusAutoCapture]=\"true\"\n >\n @if (showResizeHandle && !previewing) {\n <div\n class=\"settings-panel__resize-handle\"\n role=\"separator\"\n tabindex=\"0\"\n aria-orientation=\"vertical\"\n [attr.aria-label]=\"resizeHandleLabel\"\n (pointerdown)=\"onResizeHandlePointerDown($event)\"\n (keydown)=\"onResizeHandleKeydown($event)\"\n ></div>\n }\n @if (previewing) {\n <section class=\"settings-panel-preview-bar\" data-testid=\"settings-panel-preview-bar\">\n <div><strong [id]=\"titleId + '-preview'\">{{ tx('Page preview') }}</strong><p>{{ tx('Inspect the result. Return to keep editing; nothing is saved here.') }}</p></div>\n <button mat-flat-button type=\"button\" data-testid=\"settings-panel-return\" (click)=\"returnFromPreview()\">{{ tx('Back to settings') }}</button>\n </section>\n }\n <header class=\"settings-panel-header\" [hidden]=\"previewing\">\n <h2 class=\"settings-panel-title\" [id]=\"titleId\">\n @if (titleIcon) {\n <mat-icon class=\"title-icon\" [praxisIcon]=\"titleIcon\"></mat-icon>\n }\n <span>{{ title }}</span>\n </h2>\n <span class=\"spacer\"></span>\n @if (previewTarget) {\n <button mat-stroked-button type=\"button\" data-testid=\"settings-panel-preview\" [disabled]=\"!canInspectPreview\" (click)=\"showPreview()\">\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'visibility'\"></mat-icon>{{ tx('View result') }}\n </button>\n }\n <button\n [praxisIconButton]=\"expanded ? 'close_fullscreen' : 'open_in_full'\"\n size=\"compact\"\n type=\"button\"\n data-testid=\"settings-panel-toggle-expand\"\n [attr.aria-label]=\"expanded ? tx('Collapse panel') : tx('Expand panel')\"\n [attr.aria-expanded]=\"expanded\"\n [matTooltip]=\"expanded ? tx('Collapse panel') : tx('Expand panel')\"\n (click)=\"toggleExpand()\"\n ></button>\n <button\n praxisIconButton=\"close\"\n size=\"compact\"\n type=\"button\"\n data-testid=\"settings-panel-close-icon\"\n [attr.aria-label]=\"tx('Close')\"\n [matTooltip]=\"tx('Close')\"\n (click)=\"onCancel()\"\n ></button>\n </header>\n @if (hasContextNavigation && !previewing) {\n <nav\n class=\"settings-panel-context-nav\"\n data-testid=\"settings-panel-context-nav\"\n [attr.aria-label]=\"tx('Context navigation')\"\n >\n @if (contextNavigation?.targets?.length) {\n <div class=\"settings-panel-context-nav__targets\">\n <button\n praxisIconButton=\"chevron_left\"\n size=\"compact\"\n type=\"button\"\n data-testid=\"settings-panel-prev-target\"\n [disabled]=\"!canSelectPreviousTarget\"\n [attr.aria-label]=\"tx('Previous item')\"\n [matTooltip]=\"tx('Previous item')\"\n (click)=\"selectPreviousTarget()\"\n ></button>\n <select\n #targetSelect\n class=\"settings-panel-context-nav__target-select\"\n data-testid=\"settings-panel-target-select\"\n [disabled]=\"isBusy || !interactionActive\"\n [attr.aria-label]=\"tx('Editing target')\"\n [value]=\"contextNavigation?.activeTargetId || ''\"\n (change)=\"selectContextTarget(targetSelect.value, targetSelect)\"\n >\n @for (target of contextNavigation?.targets || []; track target.id) {\n <option [value]=\"target.id\" [selected]=\"target.id === contextNavigation?.activeTargetId\">\n {{ target.label }}\n </option>\n }\n </select>\n <button\n praxisIconButton=\"chevron_right\"\n size=\"compact\"\n type=\"button\"\n data-testid=\"settings-panel-next-target\"\n [disabled]=\"!canSelectNextTarget\"\n [attr.aria-label]=\"tx('Next item')\"\n [matTooltip]=\"tx('Next item')\"\n (click)=\"selectNextTarget()\"\n ></button>\n </div>\n }\n @if (contextNavigation?.modes?.length) {\n <div\n class=\"settings-panel-context-nav__modes\"\n role=\"group\"\n [attr.aria-label]=\"tx('Editing modes')\"\n >\n @for (mode of contextNavigation?.modes || []; track mode.id) {\n <button\n type=\"button\"\n class=\"settings-panel-context-nav__mode-btn\"\n [class.is-active]=\"mode.id === contextNavigation?.activeModeId\"\n [disabled]=\"mode.disabled || isBusy || !interactionActive\"\n [attr.aria-pressed]=\"mode.id === contextNavigation?.activeModeId\"\n [attr.title]=\"mode.label\"\n [attr.data-testid]=\"'settings-panel-mode-' + mode.id\"\n (click)=\"selectContextMode(mode.id)\"\n >\n {{ mode.label }}\n </button>\n }\n </div>\n }\n </nav>\n }\n @if (showStatusMessage && !previewing) {\n <div\n class=\"settings-panel-status\"\n [attr.data-status]=\"statusTone\"\n role=\"status\"\n aria-live=\"polite\"\n >\n <mat-icon\n aria-hidden=\"true\"\n [praxisIcon]=\"\n statusTone === 'dirty' || statusTone === 'invalid'\n ? 'warning'\n : statusTone === 'saved'\n ? 'check_circle'\n : statusTone === 'busy'\n ? 'autorenew'\n : 'info'\n \"\n ></mat-icon>\n <span>{{ statusMessage }}</span>\n @if (showWriteScopeControls) {\n <span class=\"spacer\"></span>\n <span\n class=\"settings-panel-scope\"\n [attr.data-scope]=\"activeWriteScope\"\n data-testid=\"settings-panel-write-scope\"\n >\n <span class=\"settings-panel-scope__label\">{{ writeScopeLabel }}</span>\n @if (canToggleWriteScope) {\n <button\n mat-stroked-button\n type=\"button\"\n class=\"settings-panel-scope__toggle\"\n data-testid=\"settings-panel-scope-toggle\"\n [matTooltip]=\"writeScopeToggleLabel\"\n (click)=\"toggleWriteScope()\"\n >\n {{ writeScopeToggleLabel }}\n </button>\n }\n @if (canResetPersonalOverride) {\n <button\n mat-button\n type=\"button\"\n class=\"settings-panel-scope__reset\"\n data-testid=\"settings-panel-reset-personal-override\"\n (click)=\"resetPersonalOverrideToTenant()\"\n >\n {{ tx('Reset to tenant baseline') }}\n </button>\n }\n </span>\n }\n </div>\n }\n @if (storageSaveError(); as saveErr) {\n <div\n class=\"settings-panel-save-error\"\n role=\"alert\"\n aria-live=\"assertive\"\n data-testid=\"settings-panel-save-error\"\n [attr.data-error-code]=\"saveErr.errorCode || saveErr.status || 'save-error'\"\n >\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'error_outline'\"></mat-icon>\n <div class=\"settings-panel-save-error__content\">\n <p class=\"settings-panel-save-error__message\">{{ formattedSaveErrorMessage }}</p>\n @if (saveErr.detail) {\n <p class=\"settings-panel-save-error__detail\">{{ saveErr.detail }}</p>\n }\n @if ((saveErr.errorCode === 'SHARED_CONFIG_SENSITIVE_CRITERIA_DENIED' || saveErr.status === 422) && activeWriteScope === 'tenant') {\n <button\n mat-stroked-button\n type=\"button\"\n class=\"settings-panel-save-error__action\"\n data-testid=\"settings-panel-switch-personal\"\n (click)=\"switchToPersonalScopeFromError()\"\n >\n {{ tx('Switch to personal scope') }}\n </button>\n }\n </div>\n <button\n praxisIconButton=\"close\"\n size=\"compact\"\n type=\"button\"\n data-testid=\"settings-panel-save-error-dismiss\"\n [attr.aria-label]=\"tx('Dismiss error')\"\n (click)=\"dismissSaveError()\"\n ></button>\n </div>\n }\n <div class=\"settings-panel-body\" [hidden]=\"previewing\">\n <ng-template #contentHost></ng-template>\n </div>\n <footer class=\"settings-panel-footer\" [hidden]=\"previewing\">\n <button\n mat-button\n type=\"button\"\n data-testid=\"settings-panel-reset\"\n (mousedown)=\"$event.stopPropagation()\"\n (click)=\"$event.stopPropagation(); onReset()\"\n [disabled]=\"isBusy\"\n >\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'restart_alt'\"></mat-icon>\n <span>{{ tx('Reset') }}</span>\n </button>\n <span class=\"spacer\"></span>\n <button\n mat-button\n type=\"button\"\n data-testid=\"settings-panel-cancel\"\n (mousedown)=\"$event.stopPropagation()\"\n (click)=\"$event.stopPropagation(); onCancel()\"\n [disabled]=\"isBusy\"\n >\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'close'\"></mat-icon>\n <span>{{ tx('Cancel') }}</span>\n </button>\n <button\n mat-stroked-button\n type=\"button\"\n data-testid=\"settings-panel-apply\"\n (mousedown)=\"$event.stopPropagation()\"\n (click)=\"$event.stopPropagation(); onApply()\"\n [disabled]=\"!canApply\"\n [matTooltip]=\"applySaveDisabledReason\"\n [matTooltipDisabled]=\"canApply || !diagnostics.showDisabledReason\"\n [attr.aria-busy]=\"isBusy\"\n [attr.aria-label]=\"applyActionLabel || 'Apply'\"\n >\n @if (showBusyIndicator) {\n <mat-progress-spinner\n mode=\"indeterminate\"\n diameter=\"20\"\n ></mat-progress-spinner>\n }\n @if (!showBusyIndicator) {\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'done'\"></mat-icon>\n <span class=\"settings-panel-action-label settings-panel-action-label--apply\">{{ applyActionLabel }}</span>\n }\n </button>\n <button\n mat-flat-button\n color=\"primary\"\n type=\"button\"\n data-testid=\"settings-panel-save\"\n (mousedown)=\"$event.stopPropagation()\"\n (click)=\"$event.stopPropagation(); onSave()\"\n [disabled]=\"!canSave\"\n [matTooltip]=\"applySaveDisabledReason\"\n [matTooltipDisabled]=\"canSave || !diagnostics.showDisabledReason\"\n [attr.aria-busy]=\"isBusy\"\n [attr.aria-label]=\"saveActionLabel || 'Save & Close'\"\n >\n @if (showBusyIndicator) {\n <mat-progress-spinner\n mode=\"indeterminate\"\n diameter=\"20\"\n ></mat-progress-spinner>\n }\n @if (!showBusyIndicator) {\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'save'\"></mat-icon>\n <span class=\"settings-panel-action-label settings-panel-action-label--save\">{{ saveActionLabel }}</span>\n }\n </button>\n </footer>\n</div>\n", styles: ["@charset \"UTF-8\";praxis-settings-panel{display:block;height:100%;width:100%;min-width:0;flex:1 1 auto;box-sizing:border-box}praxis-settings-panel .settings-panel{position:relative;container:settings-panel-shell/inline-size;--pfx-settings-panel-surface-container: var( --md-sys-color-surface-container, #ffffff );--pfx-settings-panel-surface-container-high: var( --md-sys-color-surface-container-high, #f7f7f7 );--pfx-settings-panel-surface-container-low: var( --md-sys-color-surface-container-low, #f2f4f7 );--pfx-settings-panel-surface: var(--md-sys-color-surface, #ffffff);--pfx-settings-panel-on-surface: var(--md-sys-color-on-surface, #111827);--pfx-settings-panel-on-surface-variant: var( --md-sys-color-on-surface-variant, rgba(17, 24, 39, .72) );--pfx-settings-panel-outline: var( --md-sys-color-outline, rgba(15, 23, 42, .24) );--pfx-settings-panel-outline-variant: var( --md-sys-color-outline-variant, rgba(15, 23, 42, .12) );--pfx-settings-panel-primary: var(--md-sys-color-primary, #2563eb);--pfx-settings-panel-primary-container: var( --md-sys-color-primary-container, rgba(37, 99, 235, .14) );--pfx-settings-panel-on-primary-container: var( --md-sys-color-on-primary-container, #0f172a );--pfx-settings-panel-secondary: var( --md-sys-color-secondary, var(--pfx-settings-panel-primary) );--pfx-settings-panel-error: var(--md-sys-color-error, #b3261e);--pfx-settings-panel-error-container: var( --md-sys-color-error-container, rgba(179, 38, 30, .14) );--pfx-settings-panel-alert-bg: color-mix( in srgb, var(--pfx-settings-panel-error-container) 78%, var(--pfx-settings-panel-surface) );--pfx-settings-panel-alert-fg: var(--pfx-settings-panel-error);--pfx-settings-panel-scope-bg: var(--pfx-settings-panel-surface);--pfx-settings-panel-scope-fg: var(--pfx-settings-panel-on-surface-variant);--pfx-settings-panel-border-radius: 0px;--mat-divider-color: var(--pfx-settings-panel-outline-variant);--mat-expansion-container-background-color: var( --pfx-settings-panel-surface-container );--mat-expansion-container-text-color: var(--pfx-settings-panel-on-surface);--mat-expansion-header-text-color: var(--pfx-settings-panel-on-surface);--mat-expansion-header-description-color: var( --pfx-settings-panel-on-surface-variant );--mat-expansion-header-indicator-color: var( --pfx-settings-panel-on-surface-variant );--mat-button-toggle-selected-state-background-color: var( --pfx-settings-panel-primary-container );--mat-button-toggle-selected-state-text-color: var( --pfx-settings-panel-on-primary-container );display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:auto auto auto auto 1fr auto;grid-template-areas:\"header\" \"context-nav\" \"status\" \"alert\" \"body\" \"footer\";min-width:0;height:100%;max-width:var(--pfx-settings-panel-max-width, 100%);background:var(--pfx-settings-panel-surface-container);color:var(--pfx-settings-panel-on-surface);border-left:1px solid var(--pfx-settings-panel-outline-variant);border-radius:var(--pfx-settings-panel-border-radius, 0px);width:var(--pfx-settings-panel-width, 100%);box-sizing:border-box;box-shadow:var(--pfx-settings-panel-elevation, var(--md-sys-elevation-level2, 0 8px 24px rgba(0, 0, 0, .16)));overflow:hidden}praxis-settings-panel .settings-panel__resize-handle{position:absolute;inset:0 auto 0 0;width:12px;cursor:col-resize;touch-action:none;z-index:3;outline:none}praxis-settings-panel .settings-panel__resize-handle:before{content:\"\";position:absolute;inset:0 auto 0 4px;width:2px;background:transparent;transition:background-color var(--pfx-side-panel-motion-duration, .16s) ease,opacity var(--pfx-side-panel-motion-duration, .16s) ease;opacity:0}praxis-settings-panel .settings-panel.is-resizable:hover .settings-panel__resize-handle:before,praxis-settings-panel .settings-panel__resize-handle:focus-visible:before{opacity:1;background:var(--pfx-settings-panel-outline)}praxis-settings-panel .settings-panel-header{grid-area:header;display:flex;align-items:center;gap:var(--pfx-settings-panel-header-gap, 8px);padding:12px var(--pfx-settings-panel-header-padding-x, 20px);min-height:var(--pfx-settings-panel-header-height, 64px);border-bottom:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-high);box-shadow:var(--pfx-settings-panel-header-shadow, var(--md-sys-elevation-level1, 0 2px 6px rgba(0, 0, 0, .08)));flex-shrink:0;min-width:0;max-width:100%}praxis-settings-panel .settings-panel-header .spacer{flex:1 1 auto;min-width:0}praxis-settings-panel .settings-panel-context-nav{grid-area:context-nav;display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px 12px;padding:8px var(--pfx-settings-panel-header-padding-x, 20px);border-bottom:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-low);min-width:0;max-width:100%}praxis-settings-panel .settings-panel-context-nav__targets{display:flex;align-items:center;gap:4px;min-width:0;flex:1 1 200px}praxis-settings-panel .settings-panel-context-nav__target-select{flex:1 1 auto;min-width:0;min-height:34px;padding:4px 10px;border-radius:8px;border:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface);color:var(--pfx-settings-panel-on-surface);font:inherit;font-size:.84rem;font-weight:600}praxis-settings-panel .settings-panel-context-nav__modes{display:inline-flex;align-items:center;flex-wrap:wrap;gap:4px;padding:2px;max-width:100%;border-radius:999px;border:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface)}praxis-settings-panel .settings-panel-context-nav__mode-btn{appearance:none;border:none;background:transparent;color:var(--pfx-settings-panel-on-surface-variant);font:inherit;font-size:.78rem;font-weight:600;padding:5px 12px;border-radius:999px;white-space:nowrap;flex-shrink:0;cursor:pointer;transition:background-color .14s ease,color .14s ease}praxis-settings-panel .settings-panel-context-nav__mode-btn.is-active{background:var(--pfx-settings-panel-primary-container);color:var(--pfx-settings-panel-on-primary-container)}praxis-settings-panel .settings-panel-context-nav__mode-btn:disabled{opacity:.42;cursor:not-allowed}praxis-settings-panel .settings-panel-status{grid-area:status;display:flex;align-items:center;gap:8px;min-height:36px;padding:6px var(--pfx-settings-panel-status-padding-x, 20px);border-bottom:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-high);color:var(--pfx-settings-panel-on-surface);font-size:.85rem;font-weight:500;min-width:0;max-width:100%}praxis-settings-panel .settings-panel-status mat-icon{width:18px;height:18px;font-size:18px}praxis-settings-panel .settings-panel-status[data-status=dirty],praxis-settings-panel .settings-panel-status[data-status=invalid]{color:var(--pfx-settings-panel-error);background:color-mix(in srgb,var(--pfx-settings-panel-error-container) 30%,var(--pfx-settings-panel-surface-container-high))}praxis-settings-panel .settings-panel-status[data-status=saved]{color:var(--pfx-settings-panel-primary);background:color-mix(in srgb,var(--pfx-settings-panel-primary-container) 28%,var(--pfx-settings-panel-surface-container-high))}praxis-settings-panel .settings-panel-scope{display:inline-flex;align-items:center;flex-wrap:wrap;gap:6px;padding:2px 8px;border-radius:999px;border:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-scope-bg);color:var(--pfx-settings-panel-scope-fg);font-size:.75rem;font-weight:600}praxis-settings-panel .settings-panel-scope[data-scope=tenant]{border-color:color-mix(in srgb,var(--pfx-settings-panel-primary) 42%,var(--pfx-settings-panel-outline-variant));background:var(--pfx-settings-panel-primary-container);color:var(--pfx-settings-panel-on-primary-container)}praxis-settings-panel .settings-panel-scope__toggle,praxis-settings-panel .settings-panel-scope__reset{height:24px;line-height:22px;font-size:.72rem;padding:0 8px}praxis-settings-panel .settings-panel-save-error{grid-area:alert;display:flex;align-items:flex-start;gap:10px;padding:10px var(--pfx-settings-panel-status-padding-x, 20px);background:var(--pfx-settings-panel-alert-bg);color:var(--pfx-settings-panel-alert-fg);border-bottom:1px solid color-mix(in srgb,var(--pfx-settings-panel-error) 32%,var(--pfx-settings-panel-outline-variant));font-size:.82rem}praxis-settings-panel .settings-panel-save-error__content{flex:1 1 auto;min-width:0;display:flex;flex-direction:column;gap:4px}praxis-settings-panel .settings-panel-save-error__message{margin:0;font-weight:600;line-height:1.35}praxis-settings-panel .settings-panel-save-error__detail{margin:0;font-size:.78rem;color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel-save-error__action{align-self:flex-start;margin-top:2px}praxis-settings-panel .settings-panel-body{grid-area:body;overflow-y:auto;overflow-x:hidden;scroll-padding-top:var(--pfx-settings-panel-scroll-padding-start, 16px);scroll-padding-bottom:var(--pfx-settings-panel-scroll-padding-end, 88px);min-height:0;padding:var(--pfx-settings-panel-body-padding, 8px 16px 24px);background:var(--pfx-settings-panel-surface);display:flex;flex-direction:column;min-width:0;max-width:100%}praxis-settings-panel .settings-panel-body>*{min-width:0;max-width:100%}praxis-settings-panel .settings-panel-content{display:block;min-width:0;max-width:100%}praxis-settings-panel .settings-panel-content>*{min-width:0;max-width:100%;box-sizing:border-box}praxis-settings-panel .settings-panel-footer{grid-area:footer;border-top:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-high);box-shadow:var(--pfx-settings-panel-footer-shadow, var(--md-sys-elevation-level1, 0 -2px 6px rgba(0, 0, 0, .08)));display:flex;align-items:center;flex-wrap:wrap;padding:var(--pfx-settings-panel-footer-padding, 12px 20px);column-gap:var(--pfx-settings-panel-footer-gap, 12px);row-gap:8px;flex-shrink:0;min-width:0;max-width:100%}praxis-settings-panel .spacer{flex:1}praxis-settings-panel .settings-panel-title{display:inline-flex;align-items:center;flex:1 1 auto;gap:var(--pfx-settings-panel-title-gap, 8px);font-weight:700;line-height:1.2;letter-spacing:.2px;margin:0;min-width:0;overflow:visible;white-space:normal}praxis-settings-panel .settings-panel-title span{min-width:0;overflow:visible;white-space:normal}praxis-settings-panel .settings-panel-title mat-icon{color:var(--pfx-settings-panel-primary)}praxis-settings-panel .settings-panel-title .title-icon{width:20px;height:20px;font-size:20px}praxis-settings-panel .settings-panel-footer button{display:inline-flex;align-items:center}praxis-settings-panel .settings-panel-footer button .mat-icon{flex:0 0 20px;font-size:20px;width:20px;height:20px;line-height:1;display:inline-flex;align-items:center;justify-content:center;overflow:hidden}praxis-settings-panel .settings-panel-footer .mat-button-wrapper{display:inline-flex;align-items:center;gap:var(--pfx-settings-panel-button-gap, 8px)}praxis-settings-panel .settings-panel-footer .mat-progress-spinner{margin-right:8px}praxis-settings-panel .settings-panel-footer .mat-flat-button[color=primary]{font-weight:600}praxis-settings-panel .settings-panel-footer .mdc-button__label{display:inline-flex;align-items:center;gap:var(--pfx-settings-panel-button-gap, 8px);line-height:1}praxis-settings-panel .settings-panel-footer .mdc-button__label>span{display:inline-flex;align-items:center;line-height:1}praxis-settings-panel .settings-panel-footer .mdc-button__label .mat-icon{display:inline-flex;align-items:center;justify-content:center;line-height:1}@container settings-panel-shell (max-width: 520px){praxis-settings-panel .settings-panel-footer{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);align-items:stretch;padding:10px 12px;column-gap:8px}praxis-settings-panel .settings-panel-footer .spacer{display:none}praxis-settings-panel .settings-panel-footer button{justify-content:center;width:100%;min-width:0;min-height:44px;height:auto;padding:8px}praxis-settings-panel .settings-panel-action-label{white-space:normal;overflow-wrap:anywhere;text-align:center}praxis-settings-panel .settings-panel-footer .mdc-button__label{min-width:0;max-width:100%}praxis-settings-panel .settings-panel-footer .mdc-button__label>span{min-width:0;line-height:1.25}}@container settings-panel-shell (max-width: 280px){praxis-settings-panel .settings-panel-footer{grid-template-columns:minmax(0,1fr)}}praxis-settings-panel .settings-panel .mat-divider{background-color:var(--pfx-settings-panel-outline-variant)}praxis-settings-panel .settings-panel .mat-expansion-panel{background:var(--pfx-settings-panel-surface-container);border:1px solid var(--pfx-settings-panel-outline-variant);border-radius:var(--md-sys-shape-corner-medium, 12px);box-shadow:var(--md-sys-elevation-level1, 0 2px 8px rgba(0, 0, 0, .08));color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-expansion-panel-header{background:var(--pfx-settings-panel-surface-container);color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-content{color:var(--pfx-settings-panel-on-surface);flex-wrap:wrap;gap:4px 12px;min-width:0;overflow:visible}praxis-settings-panel .settings-panel .mat-expansion-panel:not(.mat-expanded) .mat-expansion-panel-header:hover{background:color-mix(in srgb,var(--pfx-settings-panel-surface-container-high) 84%,var(--pfx-settings-panel-primary) 16%)}praxis-settings-panel .settings-panel .mat-expansion-panel.mat-expanded>.mat-expansion-panel-header{background:var(--pfx-settings-panel-surface-container-high)}praxis-settings-panel .settings-panel .mat-expansion-panel-header mat-icon,praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-icon{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-title,praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-description{color:var(--pfx-settings-panel-on-surface);min-width:0;overflow:visible;white-space:normal}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-description{color:var(--pfx-settings-panel-on-surface-variant);flex-wrap:wrap;gap:8px}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-title>*,praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-description>*{color:inherit}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-title small,praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-description small{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-indicator,praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-indicator:after{color:var(--pfx-settings-panel-on-surface-variant);border-color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-expansion-panel .mat-action-row{border-top-color:var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-low)}praxis-settings-panel .settings-panel .mat-accordion,praxis-settings-panel .settings-panel .mat-accordion .mat-expansion-panel-spacing{background:transparent}praxis-settings-panel .settings-panel .mat-expansion-panel-content,praxis-settings-panel .settings-panel .mat-expansion-panel-content-wrapper,praxis-settings-panel .settings-panel .mat-expansion-panel-body{background:var(--pfx-settings-panel-surface-container);color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-expansion-panel .mat-expansion-panel-body{padding:8px}praxis-settings-panel .settings-panel .mat-expansion-panel .mat-expansion-panel-body>*{color:inherit}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mat-mdc-tab-header{border-bottom:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-low)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab{min-width:0}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab .mdc-tab__text-label{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab:hover .mdc-tab__text-label,praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab:focus .mdc-tab__text-label{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab.mdc-tab--active .mdc-tab__text-label{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mat-mdc-tab-header-pagination{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mat-mdc-tab-header-pagination-chevron{border-color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mat-mdc-tab-header-pagination:not(.mat-mdc-tab-header-pagination-disabled):hover{background:color-mix(in srgb,var(--pfx-settings-panel-surface-container-high) 84%,var(--pfx-settings-panel-primary) 16%)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab-indicator__content--underline{border-color:var(--pfx-settings-panel-primary)}praxis-settings-panel .settings-panel .mat-mdc-card{background:var(--pfx-settings-panel-surface-container-low);border:1px solid var(--pfx-settings-panel-outline-variant);color:var(--pfx-settings-panel-on-surface);box-shadow:var(--md-sys-elevation-level1, 0 2px 8px rgba(0, 0, 0, .08))}praxis-settings-panel .settings-panel .mat-mdc-card-subtitle{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-mdc-card-title,praxis-settings-panel .settings-panel .mat-mdc-card-content{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-form-field{width:100%;align-self:start;--mdc-filled-text-field-container-color: var( --pfx-settings-panel-surface-container );--mdc-filled-text-field-hover-container-color: var( --pfx-settings-panel-surface-container-high );--mdc-filled-text-field-focus-container-color: var( --pfx-settings-panel-surface-container-high );--mdc-filled-text-field-active-indicator-color: var( --pfx-settings-panel-outline-variant );--mdc-filled-text-field-hover-active-indicator-color: var( --pfx-settings-panel-secondary );--mdc-filled-text-field-focus-active-indicator-color: var( --pfx-settings-panel-primary );--mdc-filled-text-field-label-text-color: var( --pfx-settings-panel-on-surface-variant );--mdc-filled-text-field-focus-label-text-color: var( --pfx-settings-panel-primary );--mdc-filled-text-field-input-text-color: var( --pfx-settings-panel-on-surface );--mdc-filled-text-field-caret-color: var(--pfx-settings-panel-primary);--mdc-outlined-text-field-outline-color: var( --pfx-settings-panel-outline-variant );--mdc-outlined-text-field-hover-outline-color: var( --pfx-settings-panel-secondary );--mdc-outlined-text-field-focus-outline-color: var( --pfx-settings-panel-primary );--mdc-outlined-text-field-label-text-color: var( --pfx-settings-panel-on-surface-variant );--mdc-outlined-text-field-focus-label-text-color: var( --pfx-settings-panel-primary );--mdc-outlined-text-field-input-text-color: var( --pfx-settings-panel-on-surface );--mdc-outlined-text-field-caret-color: var(--pfx-settings-panel-primary);--mat-form-field-focus-select-arrow-color: var( --pfx-settings-panel-primary );--mat-form-field-enabled-select-arrow-color: var( --pfx-settings-panel-on-surface-variant )}praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-text-field-wrapper.mdc-text-field--filled,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled{background-color:var(--pfx-settings-panel-surface-container);border-radius:var(--md-sys-shape-corner-small, 8px) var(--md-sys-shape-corner-small, 8px) 0 0}praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled .mat-mdc-form-field-flex,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled .mat-mdc-form-field-infix,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled .mat-mdc-form-field-focus-overlay{background:var(--pfx-settings-panel-surface-container);color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-text-field-wrapper.mdc-text-field--outlined,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--outlined,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--outlined .mat-mdc-form-field-flex,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--outlined .mat-mdc-form-field-infix{background:transparent;background-color:transparent;color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-form-field-focus-overlay{opacity:0}praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled .mdc-floating-label,praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-select-placeholder,praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-select-arrow,praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-floating-label{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-select-value,praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-select-value-text,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled .mdc-text-field__input,praxis-settings-panel .settings-panel .mat-mdc-form-field input,praxis-settings-panel .settings-panel .mat-mdc-form-field textarea,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field__input{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--focused:not(.mdc-text-field--invalid) .mat-mdc-floating-label,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled.mdc-text-field--focused .mdc-floating-label{color:var(--pfx-settings-panel-primary)}praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--invalid .mat-mdc-floating-label{color:var(--pfx-settings-panel-error)}praxis-settings-panel .settings-panel .mat-mdc-form-field-subscript-wrapper{position:relative;box-sizing:border-box}praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-form-field-hint-wrapper,praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-form-field-error-wrapper{position:relative;top:auto;left:auto;right:auto;padding-top:4px;line-height:1.35}praxis-settings-panel .settings-panel .mat-mdc-form-field-bottom-align:before{display:none}praxis-settings-panel .settings-panel .mat-mdc-form-field-subscript-wrapper,praxis-settings-panel .settings-panel .mat-mdc-form-field-hint-wrapper,praxis-settings-panel .settings-panel .mat-mdc-form-field-error-wrapper,praxis-settings-panel .settings-panel .mat-mdc-hint{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-button-toggle-group{border-color:var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-low)}praxis-settings-panel .settings-panel .mat-button-toggle{background:var(--pfx-settings-panel-surface-container-low);color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-button-toggle+.mat-button-toggle{border-left-color:var(--pfx-settings-panel-outline-variant)}praxis-settings-panel .settings-panel .mat-button-toggle-group .mat-button-toggle-checked{background:var(--pfx-settings-panel-primary-container);color:var(--pfx-settings-panel-on-primary-container)}praxis-settings-panel .settings-panel .mat-button-toggle .mat-icon,praxis-settings-panel .settings-panel .mat-button-toggle-checked .mat-icon{color:inherit}praxis-settings-panel .settings-panel .mat-mdc-slide-toggle .mdc-label{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .pfx-editor-section{box-sizing:border-box;width:100%;min-width:0;padding:16px;border-radius:16px;border:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-low)}praxis-settings-panel .settings-panel .pfx-editor-subgroup{display:grid;gap:12px;padding-top:14px;border-top:1px solid color-mix(in srgb,var(--pfx-settings-panel-outline-variant) 70%,transparent)}praxis-settings-panel .settings-panel .pfx-editor-subgroup:first-child{padding-top:0;border-top:0}praxis-settings-panel .settings-panel .pfx-editor-grid-12{display:grid;grid-template-columns:repeat(12,minmax(0,1fr));gap:12px;min-width:0}praxis-settings-panel .settings-panel .pfx-editor-toggle-cluster{display:flex;flex-wrap:wrap;align-items:center;gap:12px 20px}.settings-panel{grid-template-columns:minmax(0,1fr);min-width:0;max-width:100%}.settings-panel-body{overflow-x:hidden;min-width:0}.settings-panel-body>*{min-width:0;max-width:100%}.praxis-settings-panel-backdrop{background:var(--pfx-settings-panel-backdrop, var(--pfx-backdrop, rgba(8, 15, 26, .42)));backdrop-filter:blur(var(--pfx-settings-panel-backdrop-blur, var(--pfx-backdrop-blur, 6px))) saturate(110%);-webkit-backdrop-filter:blur(var(--pfx-settings-panel-backdrop-blur, var(--pfx-backdrop-blur, 6px))) saturate(110%)}:is(.cdk-overlay-pane.praxis-settings-panel-pane,.praxis-settings-panel-pane){position:fixed;top:0;right:0;display:flex;align-items:stretch;height:100vh;max-width:var(--pfx-settings-panel-pane-max-width, 100vw);max-height:100vh;z-index:var(--pfx-settings-panel-z-index, var(--praxis-layer-settings-panel, 1220));transition:width var(--pfx-side-panel-motion-duration-enter, .3s) var(--pfx-side-panel-motion-easing-enter, ease)}.praxis-settings-panel-pane .settings-panel{pointer-events:auto}@media(prefers-reduced-motion:reduce){.praxis-settings-panel-pane{transition:none}}:is(.cdk-overlay-pane.praxis-settings-panel-pane.praxis-settings-panel-pane--preview,.praxis-settings-panel-pane.praxis-settings-panel-pane--preview){top:auto;bottom:12px;right:12px;height:auto;width:min(560px,100vw - 24px);min-width:0;transition:none}.praxis-settings-panel-backdrop.praxis-settings-panel-backdrop--preview{background:transparent;backdrop-filter:none;-webkit-backdrop-filter:none}.praxis-settings-preview-target{outline:2px solid var(--md-sys-color-primary);outline-offset:3px}praxis-settings-panel .settings-panel [hidden]{display:none}praxis-settings-panel .settings-panel .settings-panel-header[hidden],praxis-settings-panel .settings-panel .settings-panel-body[hidden],praxis-settings-panel .settings-panel .settings-panel-footer[hidden]{display:none}praxis-settings-panel .settings-panel--preview{height:auto;min-height:0;grid-template-rows:auto;border-radius:16px}praxis-settings-panel .settings-panel-preview-bar{display:flex;align-items:center;gap:16px;padding:16px;color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel-preview-bar p{margin:4px 0 0;color:var(--pfx-settings-panel-on-surface-variant);font-size:.875rem}praxis-settings-panel .settings-panel-preview-bar button{flex-shrink:0}@container settings-panel-shell (max-width: 599px){praxis-settings-panel .settings-panel-header:not([hidden]){display:grid;grid-template-columns:minmax(0,1fr) auto auto;align-items:start}praxis-settings-panel .settings-panel-header .spacer{display:none}praxis-settings-panel .settings-panel-header .settings-panel-title{grid-column:1;grid-row:1;overflow-wrap:anywhere}praxis-settings-panel .settings-panel-header [data-testid=settings-panel-toggle-expand]{grid-column:2;grid-row:1}praxis-settings-panel .settings-panel-header [data-testid=settings-panel-close-icon]{grid-column:3;grid-row:1}praxis-settings-panel .settings-panel-header [data-testid=settings-panel-preview]{grid-column:1/-1;grid-row:2;justify-self:start;max-width:100%}praxis-settings-panel .settings-panel-preview-bar{flex-direction:column;align-items:stretch;gap:8px}}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i4.MatButton, selector: " button[matButton], a[matButton], button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button], a[mat-button], a[mat-raised-button], a[mat-flat-button], a[mat-stroked-button] ", inputs: ["matButton"], exportAs: ["matButton", "matAnchor"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: PraxisIconButtonComponent, selector: "button[praxisIconButton]", inputs: ["praxisIconButton", "size", "appearance", "presentation", "pressed", "busy"] }, { kind: "directive", type: PraxisIconDirective, selector: "mat-icon[praxisIcon]", inputs: ["praxisIcon"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i4$1.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "directive", type: CdkTrapFocus, selector: "[cdkTrapFocus]", inputs: ["cdkTrapFocus", "cdkTrapFocusAutoCapture"], exportAs: ["cdkTrapFocus"] }, { kind: "ngmodule", type: MatProgressSpinnerModule }, { kind: "component", type: i7.MatProgressSpinner, selector: "mat-progress-spinner, mat-spinner", inputs: ["color", "mode", "value", "diameter", "strokeWidth"], exportAs: ["matProgressSpinner"] }, { kind: "ngmodule", type: MatDialogModule }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1904
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.14", type: SettingsPanelComponent, isStandalone: true, selector: "praxis-settings-panel", host: { listeners: { "document:keydown": "handleKeydown($event)", "document:pointermove": "onDocumentPointerMove($event)", "document:pointerup": "onDocumentPointerEnd($event)", "document:pointercancel": "onDocumentPointerEnd($event)" } }, providers: [providePraxisSettingsPanelI18n()], viewQueries: [{ propertyName: "focusTrap", first: true, predicate: CdkTrapFocus, descendants: true }, { propertyName: "contentHost", first: true, predicate: ["contentHost"], descendants: true, read: ViewContainerRef, static: true }, { propertyName: "saveErrorBanner", first: true, predicate: ["saveErrorBanner"], descendants: true }], ngImport: i0, template: "<div\n class=\"settings-panel\"\n data-testid=\"settings-panel-root\"\n [class.expanded]=\"expanded\"\n [class.settings-panel--preview]=\"previewing\"\n [class.is-resizable]=\"showResizeHandle\"\n [ngStyle]=\"panelInlineStyles\"\n role=\"dialog\"\n [attr.aria-modal]=\"interactionActive ? 'true' : null\"\n [attr.aria-hidden]=\"interactionActive ? null : 'true'\"\n [attr.inert]=\"interactionActive ? null : ''\"\n [attr.aria-labelledby]=\"previewing ? titleId + '-preview' : titleId\"\n [cdkTrapFocus]=\"interactionActive\"\n [cdkTrapFocusAutoCapture]=\"true\"\n >\n @if (showResizeHandle && !previewing) {\n <div\n class=\"settings-panel__resize-handle\"\n role=\"separator\"\n tabindex=\"0\"\n aria-orientation=\"vertical\"\n [attr.aria-label]=\"resizeHandleLabel\"\n (pointerdown)=\"onResizeHandlePointerDown($event)\"\n (keydown)=\"onResizeHandleKeydown($event)\"\n ></div>\n }\n @if (previewing) {\n <section class=\"settings-panel-preview-bar\" data-testid=\"settings-panel-preview-bar\">\n <div><strong [id]=\"titleId + '-preview'\">{{ tx('Page preview') }}</strong><p>{{ tx('Inspect the result. Return to keep editing; nothing is saved here.') }}</p></div>\n <button mat-flat-button type=\"button\" data-testid=\"settings-panel-return\" (click)=\"returnFromPreview()\">{{ tx('Back to settings') }}</button>\n </section>\n }\n <header class=\"settings-panel-header\" [hidden]=\"previewing\">\n <h2 class=\"settings-panel-title\" [id]=\"titleId\">\n @if (titleIcon) {\n <mat-icon class=\"title-icon\" [praxisIcon]=\"titleIcon\"></mat-icon>\n }\n <span>{{ title }}</span>\n </h2>\n <span class=\"spacer\"></span>\n @if (previewTarget) {\n <button mat-stroked-button type=\"button\" data-testid=\"settings-panel-preview\" [disabled]=\"!canInspectPreview\" (click)=\"showPreview()\">\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'visibility'\"></mat-icon>{{ tx('View result') }}\n </button>\n }\n <button\n [praxisIconButton]=\"expanded ? 'close_fullscreen' : 'open_in_full'\"\n size=\"compact\"\n type=\"button\"\n data-testid=\"settings-panel-toggle-expand\"\n [attr.aria-label]=\"expanded ? tx('Collapse panel') : tx('Expand panel')\"\n [attr.aria-expanded]=\"expanded\"\n [matTooltip]=\"expanded ? tx('Collapse panel') : tx('Expand panel')\"\n (click)=\"toggleExpand()\"\n ></button>\n <button\n praxisIconButton=\"close\"\n size=\"compact\"\n type=\"button\"\n data-testid=\"settings-panel-close-icon\"\n [disabled]=\"isBusy\"\n [attr.aria-label]=\"tx('Close')\"\n [matTooltip]=\"tx('Close')\"\n (click)=\"onCancel()\"\n ></button>\n </header>\n @if (hasContextNavigation && !previewing) {\n <nav\n class=\"settings-panel-context-nav\"\n data-testid=\"settings-panel-context-nav\"\n [attr.aria-label]=\"tx('Context navigation')\"\n >\n @if (contextNavigation?.targets?.length) {\n <div class=\"settings-panel-context-nav__targets\">\n <button\n praxisIconButton=\"chevron_left\"\n size=\"compact\"\n type=\"button\"\n data-testid=\"settings-panel-prev-target\"\n [disabled]=\"!canSelectPreviousTarget\"\n [attr.aria-label]=\"tx('Previous item')\"\n [matTooltip]=\"tx('Previous item')\"\n (click)=\"selectPreviousTarget()\"\n ></button>\n <select\n #targetSelect\n class=\"settings-panel-context-nav__target-select\"\n data-testid=\"settings-panel-target-select\"\n [disabled]=\"isBusy || !interactionActive\"\n [attr.aria-label]=\"tx('Editing target')\"\n [value]=\"contextNavigation?.activeTargetId || ''\"\n (change)=\"selectContextTarget(targetSelect.value, targetSelect)\"\n >\n @for (target of contextNavigation?.targets || []; track target.id) {\n <option [value]=\"target.id\" [selected]=\"target.id === contextNavigation?.activeTargetId\">\n {{ target.label }}\n </option>\n }\n </select>\n <button\n praxisIconButton=\"chevron_right\"\n size=\"compact\"\n type=\"button\"\n data-testid=\"settings-panel-next-target\"\n [disabled]=\"!canSelectNextTarget\"\n [attr.aria-label]=\"tx('Next item')\"\n [matTooltip]=\"tx('Next item')\"\n (click)=\"selectNextTarget()\"\n ></button>\n </div>\n }\n @if (contextNavigation?.modes?.length) {\n <div\n class=\"settings-panel-context-nav__modes\"\n role=\"group\"\n [attr.aria-label]=\"tx('Editing modes')\"\n >\n @for (mode of contextNavigation?.modes || []; track mode.id) {\n <button\n type=\"button\"\n class=\"settings-panel-context-nav__mode-btn\"\n [class.is-active]=\"mode.id === contextNavigation?.activeModeId\"\n [disabled]=\"mode.disabled || isBusy || !interactionActive\"\n [attr.aria-pressed]=\"mode.id === contextNavigation?.activeModeId\"\n [attr.title]=\"mode.label\"\n [attr.data-testid]=\"'settings-panel-mode-' + mode.id\"\n (click)=\"selectContextMode(mode.id)\"\n >\n {{ mode.label }}\n </button>\n }\n </div>\n }\n </nav>\n }\n @if (showStatusMessage && !previewing) {\n <div\n class=\"settings-panel-status\"\n [attr.data-status]=\"statusTone\"\n role=\"status\"\n aria-live=\"polite\"\n >\n <mat-icon\n aria-hidden=\"true\"\n [praxisIcon]=\"\n statusTone === 'dirty' || statusTone === 'invalid'\n ? 'warning'\n : statusTone === 'saved'\n ? 'check_circle'\n : statusTone === 'busy'\n ? 'autorenew'\n : 'info'\n \"\n ></mat-icon>\n <span>{{ statusMessage }}</span>\n @if (showWriteScopeControls) {\n <span class=\"spacer\"></span>\n <span\n class=\"settings-panel-scope\"\n [attr.data-scope]=\"activeWriteScope\"\n data-testid=\"settings-panel-write-scope\"\n >\n <span class=\"settings-panel-scope__label\">{{ writeScopeLabel }}</span>\n @if (canToggleWriteScope) {\n <button\n mat-stroked-button\n type=\"button\"\n class=\"settings-panel-scope__toggle\"\n data-testid=\"settings-panel-scope-toggle\"\n [matTooltip]=\"writeScopeToggleLabel\"\n (click)=\"toggleWriteScope()\"\n >\n {{ writeScopeToggleLabel }}\n </button>\n }\n @if (canResetPersonalOverride) {\n <button\n mat-button\n type=\"button\"\n class=\"settings-panel-scope__reset\"\n data-testid=\"settings-panel-reset-personal-override\"\n [disabled]=\"isBusy || isConfirmDialogOpen\"\n (click)=\"resetPersonalOverrideToTenant()\"\n >\n {{ tx('Reset to tenant baseline') }}\n </button>\n }\n </span>\n }\n </div>\n }\n @if (!previewing && storageSaveError(); as saveErr) {\n <div\n #saveErrorBanner\n tabindex=\"-1\"\n class=\"settings-panel-save-error\"\n role=\"alert\"\n aria-live=\"assertive\"\n aria-atomic=\"true\"\n data-testid=\"settings-panel-save-error\"\n [attr.data-error-code]=\"saveErr.errorCode || saveErr.status || 'save-error'\"\n [attr.data-correlation-id]=\"saveErr.correlationId || null\"\n >\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'error_outline'\"></mat-icon>\n <div class=\"settings-panel-save-error__content\">\n <p class=\"settings-panel-save-error__message\">{{ formattedSaveErrorMessage }}</p>\n @if (saveErr.detail && saveErr.detail !== formattedSaveErrorMessage && saveErr.detail !== saveErrorFieldMessages.join('; ')) {\n <p class=\"settings-panel-save-error__detail\">{{ saveErr.detail }}</p>\n } @else if (saveErr.title && saveErr.title !== formattedSaveErrorMessage) {\n <p class=\"settings-panel-save-error__detail\">{{ saveErr.title }}</p>\n }\n @if (saveErr.errorCode || saveErr.correlationId) {\n <p class=\"settings-panel-save-error__meta\" data-testid=\"settings-panel-save-error-meta\">\n @if (saveErr.errorCode) {\n <span>{{ tx('Code: {{code}}', { code: saveErr.errorCode }) }}</span>\n }\n @if (saveErr.correlationId) {\n <span>{{ tx('Correlation ID: {{id}}', { id: saveErr.correlationId }) }}</span>\n }\n </p>\n }\n @if (saveErrorFieldMessages.length > 0) {\n <ul class=\"settings-panel-save-error__fields\" data-testid=\"settings-panel-save-error-fields\">\n @for (fieldMsg of saveErrorFieldMessages; track $index) {\n <li>{{ fieldMsg }}</li>\n }\n </ul>\n }\n @if (canSwitchToPersonalScopeFromError) {\n <button\n mat-stroked-button\n type=\"button\"\n class=\"settings-panel-save-error__action\"\n data-testid=\"settings-panel-switch-personal\"\n (click)=\"switchToPersonalScopeFromError()\"\n >\n {{ tx('Switch to personal scope') }}\n </button>\n }\n </div>\n <button\n praxisIconButton=\"close\"\n size=\"compact\"\n type=\"button\"\n data-testid=\"settings-panel-save-error-dismiss\"\n [attr.aria-label]=\"tx('Dismiss error')\"\n (click)=\"dismissSaveError()\"\n ></button>\n </div>\n }\n <div class=\"settings-panel-body\" [hidden]=\"previewing\">\n <ng-template #contentHost></ng-template>\n </div>\n <footer class=\"settings-panel-footer\" [hidden]=\"previewing\">\n <button\n mat-button\n type=\"button\"\n data-testid=\"settings-panel-reset\"\n (mousedown)=\"$event.stopPropagation()\"\n (click)=\"$event.stopPropagation(); onReset()\"\n [disabled]=\"isBusy || isConfirmDialogOpen\"\n >\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'restart_alt'\"></mat-icon>\n <span>{{ tx('Reset') }}</span>\n </button>\n <span class=\"spacer\"></span>\n <button\n mat-button\n type=\"button\"\n data-testid=\"settings-panel-cancel\"\n (mousedown)=\"$event.stopPropagation()\"\n (click)=\"$event.stopPropagation(); onCancel()\"\n [disabled]=\"isBusy || isConfirmDialogOpen\"\n >\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'close'\"></mat-icon>\n <span>{{ tx('Cancel') }}</span>\n </button>\n <button\n mat-stroked-button\n type=\"button\"\n data-testid=\"settings-panel-apply\"\n (mousedown)=\"$event.stopPropagation()\"\n (click)=\"$event.stopPropagation(); onApply()\"\n [disabled]=\"!canApply\"\n [matTooltip]=\"applySaveDisabledReason\"\n [matTooltipDisabled]=\"canApply || !diagnostics.showDisabledReason\"\n [attr.aria-busy]=\"isBusy\"\n [attr.aria-label]=\"applyActionLabel || 'Apply'\"\n >\n @if (showBusyIndicator) {\n <mat-progress-spinner\n mode=\"indeterminate\"\n diameter=\"20\"\n ></mat-progress-spinner>\n }\n @if (!showBusyIndicator) {\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'done'\"></mat-icon>\n <span class=\"settings-panel-action-label settings-panel-action-label--apply\">{{ applyActionLabel }}</span>\n }\n </button>\n <button\n mat-flat-button\n color=\"primary\"\n type=\"button\"\n data-testid=\"settings-panel-save\"\n (mousedown)=\"$event.stopPropagation()\"\n (click)=\"$event.stopPropagation(); onSave()\"\n [disabled]=\"!canSave\"\n [matTooltip]=\"applySaveDisabledReason\"\n [matTooltipDisabled]=\"canSave || !diagnostics.showDisabledReason\"\n [attr.aria-busy]=\"isBusy\"\n [attr.aria-label]=\"saveActionLabel || 'Save & Close'\"\n >\n @if (showBusyIndicator) {\n <mat-progress-spinner\n mode=\"indeterminate\"\n diameter=\"20\"\n ></mat-progress-spinner>\n }\n @if (!showBusyIndicator) {\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'save'\"></mat-icon>\n <span class=\"settings-panel-action-label settings-panel-action-label--save\">{{ saveActionLabel }}</span>\n }\n </button>\n </footer>\n</div>\n", styles: ["@charset \"UTF-8\";praxis-settings-panel{display:block;height:100%;width:100%;min-width:0;flex:1 1 auto;box-sizing:border-box}praxis-settings-panel .settings-panel{position:relative;container:settings-panel-shell/inline-size;--pfx-settings-panel-surface-container: var( --md-sys-color-surface-container, #ffffff );--pfx-settings-panel-surface-container-high: var( --md-sys-color-surface-container-high, #f7f7f7 );--pfx-settings-panel-surface-container-low: var( --md-sys-color-surface-container-low, #f2f4f7 );--pfx-settings-panel-surface: var(--md-sys-color-surface, #ffffff);--pfx-settings-panel-on-surface: var(--md-sys-color-on-surface, #111827);--pfx-settings-panel-on-surface-variant: var( --md-sys-color-on-surface-variant, rgba(17, 24, 39, .72) );--pfx-settings-panel-outline: var( --md-sys-color-outline, rgba(15, 23, 42, .24) );--pfx-settings-panel-outline-variant: var( --md-sys-color-outline-variant, rgba(15, 23, 42, .12) );--pfx-settings-panel-primary: var(--md-sys-color-primary, #2563eb);--pfx-settings-panel-primary-container: var( --md-sys-color-primary-container, rgba(37, 99, 235, .14) );--pfx-settings-panel-on-primary-container: var( --md-sys-color-on-primary-container, #0f172a );--pfx-settings-panel-secondary: var( --md-sys-color-secondary, var(--pfx-settings-panel-primary) );--pfx-settings-panel-error: var(--md-sys-color-error, #b3261e);--pfx-settings-panel-error-container: var( --md-sys-color-error-container, rgba(179, 38, 30, .14) );--pfx-settings-panel-alert-bg: color-mix( in srgb, var(--pfx-settings-panel-error-container) 78%, var(--pfx-settings-panel-surface) );--pfx-settings-panel-alert-fg: var(--pfx-settings-panel-error);--pfx-settings-panel-scope-bg: var(--pfx-settings-panel-surface);--pfx-settings-panel-scope-fg: var(--pfx-settings-panel-on-surface-variant);--pfx-settings-panel-border-radius: 0px;--mat-divider-color: var(--pfx-settings-panel-outline-variant);--mat-expansion-container-background-color: var( --pfx-settings-panel-surface-container );--mat-expansion-container-text-color: var(--pfx-settings-panel-on-surface);--mat-expansion-header-text-color: var(--pfx-settings-panel-on-surface);--mat-expansion-header-description-color: var( --pfx-settings-panel-on-surface-variant );--mat-expansion-header-indicator-color: var( --pfx-settings-panel-on-surface-variant );--mat-button-toggle-selected-state-background-color: var( --pfx-settings-panel-primary-container );--mat-button-toggle-selected-state-text-color: var( --pfx-settings-panel-on-primary-container );display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:auto auto auto auto 1fr auto;grid-template-areas:\"header\" \"context-nav\" \"status\" \"alert\" \"body\" \"footer\";min-width:0;height:100%;max-width:var(--pfx-settings-panel-max-width, 100%);background:var(--pfx-settings-panel-surface-container);color:var(--pfx-settings-panel-on-surface);border-left:1px solid var(--pfx-settings-panel-outline-variant);border-radius:var(--pfx-settings-panel-border-radius, 0px);width:var(--pfx-settings-panel-width, 100%);box-sizing:border-box;box-shadow:var(--pfx-settings-panel-elevation, var(--md-sys-elevation-level2, 0 8px 24px rgba(0, 0, 0, .16)));overflow:hidden}praxis-settings-panel .settings-panel__resize-handle{position:absolute;inset:0 auto 0 0;width:12px;cursor:col-resize;touch-action:none;z-index:3;outline:none}praxis-settings-panel .settings-panel__resize-handle:before{content:\"\";position:absolute;inset:0 auto 0 4px;width:2px;background:transparent;transition:background-color var(--pfx-side-panel-motion-duration, .16s) ease,opacity var(--pfx-side-panel-motion-duration, .16s) ease;opacity:0}praxis-settings-panel .settings-panel.is-resizable:hover .settings-panel__resize-handle:before,praxis-settings-panel .settings-panel__resize-handle:focus-visible:before{opacity:1;background:var(--pfx-settings-panel-outline)}praxis-settings-panel .settings-panel-header{grid-area:header;display:flex;align-items:center;gap:var(--pfx-settings-panel-header-gap, 8px);padding:12px var(--pfx-settings-panel-header-padding-x, 20px);min-height:var(--pfx-settings-panel-header-height, 64px);border-bottom:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-high);box-shadow:var(--pfx-settings-panel-header-shadow, var(--md-sys-elevation-level1, 0 2px 6px rgba(0, 0, 0, .08)));flex-shrink:0;min-width:0;max-width:100%}praxis-settings-panel .settings-panel-header .spacer{flex:1 1 auto;min-width:0}praxis-settings-panel .settings-panel-context-nav{grid-area:context-nav;display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px 12px;padding:8px var(--pfx-settings-panel-header-padding-x, 20px);border-bottom:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-low);min-width:0;max-width:100%}praxis-settings-panel .settings-panel-context-nav__targets{display:flex;align-items:center;gap:4px;min-width:0;flex:1 1 200px}praxis-settings-panel .settings-panel-context-nav__target-select{flex:1 1 auto;min-width:0;min-height:34px;padding:4px 10px;border-radius:8px;border:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface);color:var(--pfx-settings-panel-on-surface);font:inherit;font-size:.84rem;font-weight:600}praxis-settings-panel .settings-panel-context-nav__modes{display:inline-flex;align-items:center;flex-wrap:wrap;gap:4px;padding:2px;max-width:100%;border-radius:999px;border:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface)}praxis-settings-panel .settings-panel-context-nav__mode-btn{appearance:none;border:none;background:transparent;color:var(--pfx-settings-panel-on-surface-variant);font:inherit;font-size:.78rem;font-weight:600;padding:5px 12px;border-radius:999px;white-space:nowrap;flex-shrink:0;cursor:pointer;transition:background-color .14s ease,color .14s ease}praxis-settings-panel .settings-panel-context-nav__mode-btn.is-active{background:var(--pfx-settings-panel-primary-container);color:var(--pfx-settings-panel-on-primary-container)}praxis-settings-panel .settings-panel-context-nav__mode-btn:disabled{opacity:.42;cursor:not-allowed}praxis-settings-panel .settings-panel-status{grid-area:status;display:flex;align-items:center;gap:8px;min-height:36px;padding:6px var(--pfx-settings-panel-status-padding-x, 20px);border-bottom:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-high);color:var(--pfx-settings-panel-on-surface);font-size:.85rem;font-weight:500;min-width:0;max-width:100%}praxis-settings-panel .settings-panel-status mat-icon{width:18px;height:18px;font-size:18px}praxis-settings-panel .settings-panel-status[data-status=dirty],praxis-settings-panel .settings-panel-status[data-status=invalid]{color:var(--pfx-settings-panel-error);background:color-mix(in srgb,var(--pfx-settings-panel-error-container) 30%,var(--pfx-settings-panel-surface-container-high))}praxis-settings-panel .settings-panel-status[data-status=saved]{color:var(--pfx-settings-panel-primary);background:color-mix(in srgb,var(--pfx-settings-panel-primary-container) 28%,var(--pfx-settings-panel-surface-container-high))}praxis-settings-panel .settings-panel-scope{display:inline-flex;align-items:center;flex-wrap:wrap;gap:6px;padding:2px 8px;border-radius:999px;border:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-scope-bg);color:var(--pfx-settings-panel-scope-fg);font-size:.75rem;font-weight:600}praxis-settings-panel .settings-panel-scope[data-scope=tenant]{border-color:color-mix(in srgb,var(--pfx-settings-panel-primary) 42%,var(--pfx-settings-panel-outline-variant));background:var(--pfx-settings-panel-primary-container);color:var(--pfx-settings-panel-on-primary-container)}praxis-settings-panel .settings-panel-scope__toggle,praxis-settings-panel .settings-panel-scope__reset{height:24px;line-height:22px;font-size:.72rem;padding:0 8px}praxis-settings-panel .settings-panel-save-error{grid-area:alert;display:flex;align-items:flex-start;gap:10px;padding:10px var(--pfx-settings-panel-status-padding-x, 20px);background:var(--pfx-settings-panel-alert-bg);color:var(--pfx-settings-panel-alert-fg);border-bottom:1px solid color-mix(in srgb,var(--pfx-settings-panel-error) 32%,var(--pfx-settings-panel-outline-variant));font-size:.82rem}praxis-settings-panel .settings-panel-save-error__content{flex:1 1 auto;min-width:0;display:flex;flex-direction:column;gap:4px}praxis-settings-panel .settings-panel-save-error__message{margin:0;font-weight:600;line-height:1.35}praxis-settings-panel .settings-panel-save-error:focus-visible,praxis-settings-panel .settings-panel-save-error:focus{outline:2px solid var(--pfx-settings-panel-error);outline-offset:-2px}praxis-settings-panel .settings-panel-save-error__detail{margin:0;font-size:.78rem;color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel-save-error__meta{margin:2px 0 0;display:flex;flex-wrap:wrap;gap:6px 12px;font-size:.72rem;font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel-save-error__fields{margin:2px 0 0;padding-inline-start:16px;font-size:.78rem;color:var(--pfx-settings-panel-on-surface-variant);display:flex;flex-direction:column;gap:2px}praxis-settings-panel .settings-panel-save-error__action{align-self:flex-start;margin-top:2px}praxis-settings-panel .settings-panel-body{grid-area:body;container-type:inline-size;overflow-y:auto;overflow-x:hidden;scroll-padding-top:var(--pfx-settings-panel-scroll-padding-start, 16px);scroll-padding-bottom:var(--pfx-settings-panel-scroll-padding-end, 88px);min-height:0;padding:var(--pfx-settings-panel-body-padding, 8px 16px 24px);background:var(--pfx-settings-panel-surface);display:flex;flex-direction:column;min-width:0;max-width:100%}praxis-settings-panel .settings-panel-body>*{min-width:0;max-width:100%}praxis-settings-panel .settings-panel-content{display:block;min-width:0;max-width:100%}praxis-settings-panel .settings-panel-content>*{min-width:0;max-width:100%;box-sizing:border-box}praxis-settings-panel .settings-panel-footer{grid-area:footer;border-top:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-high);box-shadow:var(--pfx-settings-panel-footer-shadow, var(--md-sys-elevation-level1, 0 -2px 6px rgba(0, 0, 0, .08)));display:flex;align-items:center;flex-wrap:wrap;padding:var(--pfx-settings-panel-footer-padding, 12px 20px);column-gap:var(--pfx-settings-panel-footer-gap, 12px);row-gap:8px;flex-shrink:0;min-width:0;max-width:100%}praxis-settings-panel .spacer{flex:1}praxis-settings-panel .settings-panel-title{display:inline-flex;align-items:center;flex:1 1 auto;gap:var(--pfx-settings-panel-title-gap, 8px);font-weight:700;line-height:1.2;letter-spacing:.2px;margin:0;min-width:0;overflow:visible;white-space:normal}praxis-settings-panel .settings-panel-title span{min-width:0;overflow:visible;white-space:normal}praxis-settings-panel .settings-panel-title mat-icon{color:var(--pfx-settings-panel-primary)}praxis-settings-panel .settings-panel-title .title-icon{width:20px;height:20px;font-size:20px}praxis-settings-panel .settings-panel-footer button{display:inline-flex;align-items:center}praxis-settings-panel .settings-panel-footer button .mat-icon{flex:0 0 20px;font-size:20px;width:20px;height:20px;line-height:1;display:inline-flex;align-items:center;justify-content:center;overflow:hidden}praxis-settings-panel .settings-panel-footer .mat-button-wrapper{display:inline-flex;align-items:center;gap:var(--pfx-settings-panel-button-gap, 8px)}praxis-settings-panel .settings-panel-footer .mat-progress-spinner{margin-right:8px}praxis-settings-panel .settings-panel-footer .mat-flat-button[color=primary]{font-weight:600}praxis-settings-panel .settings-panel-footer .mdc-button__label{display:inline-flex;align-items:center;gap:var(--pfx-settings-panel-button-gap, 8px);line-height:1}praxis-settings-panel .settings-panel-footer .mdc-button__label>span{display:inline-flex;align-items:center;line-height:1}praxis-settings-panel .settings-panel-footer .mdc-button__label .mat-icon{display:inline-flex;align-items:center;justify-content:center;line-height:1}@container settings-panel-shell (max-width: 520px){praxis-settings-panel .settings-panel-footer{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);align-items:stretch;padding:10px 12px;column-gap:8px}praxis-settings-panel .settings-panel-footer .spacer{display:none}praxis-settings-panel .settings-panel-footer button{justify-content:center;width:100%;min-width:0;min-height:44px;height:auto;padding:8px}praxis-settings-panel .settings-panel-action-label{white-space:normal;overflow-wrap:anywhere;text-align:center}praxis-settings-panel .settings-panel-footer .mdc-button__label{min-width:0;max-width:100%}praxis-settings-panel .settings-panel-footer .mdc-button__label>span{min-width:0;line-height:1.25}}@container settings-panel-shell (max-width: 280px){praxis-settings-panel .settings-panel-footer{grid-template-columns:minmax(0,1fr)}}praxis-settings-panel .settings-panel .mat-divider{background-color:var(--pfx-settings-panel-outline-variant)}praxis-settings-panel .settings-panel .mat-expansion-panel{background:var(--pfx-settings-panel-surface-container);border:1px solid var(--pfx-settings-panel-outline-variant);border-radius:var(--md-sys-shape-corner-medium, 12px);box-shadow:var(--md-sys-elevation-level1, 0 2px 8px rgba(0, 0, 0, .08));color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-expansion-panel-header{background:var(--pfx-settings-panel-surface-container);color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-content{color:var(--pfx-settings-panel-on-surface);flex-wrap:wrap;gap:4px 12px;min-width:0;overflow:visible}praxis-settings-panel .settings-panel .mat-expansion-panel:not(.mat-expanded) .mat-expansion-panel-header:hover{background:color-mix(in srgb,var(--pfx-settings-panel-surface-container-high) 84%,var(--pfx-settings-panel-primary) 16%)}praxis-settings-panel .settings-panel .mat-expansion-panel.mat-expanded>.mat-expansion-panel-header{background:var(--pfx-settings-panel-surface-container-high)}praxis-settings-panel .settings-panel .mat-expansion-panel-header mat-icon,praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-icon{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-title,praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-description{color:var(--pfx-settings-panel-on-surface);min-width:0;overflow:visible;white-space:normal}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-description{color:var(--pfx-settings-panel-on-surface-variant);flex-wrap:wrap;gap:8px}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-title>*,praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-description>*{color:inherit}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-title small,praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-description small{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-indicator,praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-indicator:after{color:var(--pfx-settings-panel-on-surface-variant);border-color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-expansion-panel .mat-action-row{border-top-color:var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-low)}praxis-settings-panel .settings-panel .mat-accordion,praxis-settings-panel .settings-panel .mat-accordion .mat-expansion-panel-spacing{background:transparent}praxis-settings-panel .settings-panel .mat-expansion-panel-content,praxis-settings-panel .settings-panel .mat-expansion-panel-content-wrapper,praxis-settings-panel .settings-panel .mat-expansion-panel-body{background:var(--pfx-settings-panel-surface-container);color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-expansion-panel .mat-expansion-panel-body{padding:8px}praxis-settings-panel .settings-panel .mat-expansion-panel .mat-expansion-panel-body>*{color:inherit}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mat-mdc-tab-header{border-bottom:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-low)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab{min-width:0}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab .mdc-tab__text-label{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab:hover .mdc-tab__text-label,praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab:focus .mdc-tab__text-label{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab.mdc-tab--active .mdc-tab__text-label{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mat-mdc-tab-header-pagination{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mat-mdc-tab-header-pagination-chevron{border-color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mat-mdc-tab-header-pagination:not(.mat-mdc-tab-header-pagination-disabled):hover{background:color-mix(in srgb,var(--pfx-settings-panel-surface-container-high) 84%,var(--pfx-settings-panel-primary) 16%)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab-indicator__content--underline{border-color:var(--pfx-settings-panel-primary)}praxis-settings-panel .settings-panel .mat-mdc-card{background:var(--pfx-settings-panel-surface-container-low);border:1px solid var(--pfx-settings-panel-outline-variant);color:var(--pfx-settings-panel-on-surface);box-shadow:var(--md-sys-elevation-level1, 0 2px 8px rgba(0, 0, 0, .08))}praxis-settings-panel .settings-panel .mat-mdc-card-subtitle{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-mdc-card-title,praxis-settings-panel .settings-panel .mat-mdc-card-content{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-form-field{width:100%;align-self:start;--mdc-filled-text-field-container-color: var( --pfx-settings-panel-surface-container );--mdc-filled-text-field-hover-container-color: var( --pfx-settings-panel-surface-container-high );--mdc-filled-text-field-focus-container-color: var( --pfx-settings-panel-surface-container-high );--mdc-filled-text-field-active-indicator-color: var( --pfx-settings-panel-outline-variant );--mdc-filled-text-field-hover-active-indicator-color: var( --pfx-settings-panel-secondary );--mdc-filled-text-field-focus-active-indicator-color: var( --pfx-settings-panel-primary );--mdc-filled-text-field-label-text-color: var( --pfx-settings-panel-on-surface-variant );--mdc-filled-text-field-focus-label-text-color: var( --pfx-settings-panel-primary );--mdc-filled-text-field-input-text-color: var( --pfx-settings-panel-on-surface );--mdc-filled-text-field-caret-color: var(--pfx-settings-panel-primary);--mdc-outlined-text-field-outline-color: var( --pfx-settings-panel-outline-variant );--mdc-outlined-text-field-hover-outline-color: var( --pfx-settings-panel-secondary );--mdc-outlined-text-field-focus-outline-color: var( --pfx-settings-panel-primary );--mdc-outlined-text-field-label-text-color: var( --pfx-settings-panel-on-surface-variant );--mdc-outlined-text-field-focus-label-text-color: var( --pfx-settings-panel-primary );--mdc-outlined-text-field-input-text-color: var( --pfx-settings-panel-on-surface );--mdc-outlined-text-field-caret-color: var(--pfx-settings-panel-primary);--mat-form-field-focus-select-arrow-color: var( --pfx-settings-panel-primary );--mat-form-field-enabled-select-arrow-color: var( --pfx-settings-panel-on-surface-variant )}praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-text-field-wrapper.mdc-text-field--filled,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled{background-color:var(--pfx-settings-panel-surface-container);border-radius:var(--md-sys-shape-corner-small, 8px) var(--md-sys-shape-corner-small, 8px) 0 0}praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled .mat-mdc-form-field-flex,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled .mat-mdc-form-field-infix,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled .mat-mdc-form-field-focus-overlay{background:var(--pfx-settings-panel-surface-container);color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-text-field-wrapper.mdc-text-field--outlined,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--outlined,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--outlined .mat-mdc-form-field-flex,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--outlined .mat-mdc-form-field-infix{background:transparent;background-color:transparent;color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-form-field-focus-overlay{opacity:0}praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled .mdc-floating-label,praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-select-placeholder,praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-select-arrow,praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-floating-label{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-select-value,praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-select-value-text,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled .mdc-text-field__input,praxis-settings-panel .settings-panel .mat-mdc-form-field input,praxis-settings-panel .settings-panel .mat-mdc-form-field textarea,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field__input{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--focused:not(.mdc-text-field--invalid) .mat-mdc-floating-label,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled.mdc-text-field--focused .mdc-floating-label{color:var(--pfx-settings-panel-primary)}praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--invalid .mat-mdc-floating-label{color:var(--pfx-settings-panel-error)}praxis-settings-panel .settings-panel .mat-mdc-form-field-subscript-wrapper{position:relative;box-sizing:border-box}praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-form-field-hint-wrapper,praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-form-field-error-wrapper{position:relative;top:auto;left:auto;right:auto;padding-top:4px;line-height:1.35}praxis-settings-panel .settings-panel .mat-mdc-form-field-bottom-align:before{display:none}praxis-settings-panel .settings-panel .mat-mdc-form-field-subscript-wrapper,praxis-settings-panel .settings-panel .mat-mdc-form-field-hint-wrapper,praxis-settings-panel .settings-panel .mat-mdc-form-field-error-wrapper,praxis-settings-panel .settings-panel .mat-mdc-hint{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-button-toggle-group{border-color:var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-low)}praxis-settings-panel .settings-panel .mat-button-toggle{background:var(--pfx-settings-panel-surface-container-low);color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-button-toggle+.mat-button-toggle{border-left-color:var(--pfx-settings-panel-outline-variant)}praxis-settings-panel .settings-panel .mat-button-toggle-group .mat-button-toggle-checked{background:var(--pfx-settings-panel-primary-container);color:var(--pfx-settings-panel-on-primary-container)}praxis-settings-panel .settings-panel .mat-button-toggle .mat-icon,praxis-settings-panel .settings-panel .mat-button-toggle-checked .mat-icon{color:inherit}praxis-settings-panel .settings-panel .mat-mdc-slide-toggle .mdc-label{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .pfx-editor-section{box-sizing:border-box;width:100%;min-width:0;padding:16px;border-radius:16px;border:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-low)}praxis-settings-panel .settings-panel .pfx-editor-subgroup{display:grid;gap:12px;padding-top:14px;border-top:1px solid color-mix(in srgb,var(--pfx-settings-panel-outline-variant) 70%,transparent)}praxis-settings-panel .settings-panel .pfx-editor-subgroup:first-child{padding-top:0;border-top:0}praxis-settings-panel .settings-panel .pfx-editor-grid-12{display:grid;grid-template-columns:repeat(12,minmax(0,1fr));gap:12px;min-width:0}praxis-settings-panel .settings-panel .pfx-editor-toggle-cluster{display:flex;flex-wrap:wrap;align-items:center;gap:12px 20px}.settings-panel{grid-template-columns:minmax(0,1fr);min-width:0;max-width:100%}.settings-panel-body{overflow-x:hidden;min-width:0}.settings-panel-body>*{min-width:0;max-width:100%}.praxis-settings-panel-backdrop{background:var(--pfx-settings-panel-backdrop, var(--pfx-backdrop, rgba(8, 15, 26, .42)));backdrop-filter:blur(var(--pfx-settings-panel-backdrop-blur, var(--pfx-backdrop-blur, 6px))) saturate(110%);-webkit-backdrop-filter:blur(var(--pfx-settings-panel-backdrop-blur, var(--pfx-backdrop-blur, 6px))) saturate(110%)}:is(.cdk-overlay-pane.praxis-settings-panel-pane,.praxis-settings-panel-pane){position:fixed;top:0;right:0;display:flex;align-items:stretch;height:100vh;max-width:var(--pfx-settings-panel-pane-max-width, 100vw);max-height:100vh;z-index:var(--pfx-settings-panel-z-index, var(--praxis-z-settings-panel, var(--praxis-layer-settings-panel, 1220)));transition:width var(--pfx-side-panel-motion-duration-enter, .3s) var(--pfx-side-panel-motion-easing-enter, ease)}.praxis-settings-panel-pane .settings-panel{pointer-events:auto}@media(prefers-reduced-motion:reduce){.praxis-settings-panel-pane{transition:none}}:is(.cdk-overlay-pane.praxis-settings-panel-pane.praxis-settings-panel-pane--preview,.praxis-settings-panel-pane.praxis-settings-panel-pane--preview){top:auto;bottom:12px;right:12px;height:auto;width:min(560px,100vw - 24px);min-width:0;transition:none}.praxis-settings-panel-backdrop.praxis-settings-panel-backdrop--preview{background:transparent;backdrop-filter:none;-webkit-backdrop-filter:none}.praxis-settings-preview-target{outline:2px solid var(--md-sys-color-primary);outline-offset:3px}praxis-settings-panel .settings-panel [hidden]{display:none}praxis-settings-panel .settings-panel .settings-panel-header[hidden],praxis-settings-panel .settings-panel .settings-panel-body[hidden],praxis-settings-panel .settings-panel .settings-panel-footer[hidden]{display:none}praxis-settings-panel .settings-panel--preview{height:auto;min-height:0;grid-template-rows:auto;border-radius:16px}praxis-settings-panel .settings-panel-preview-bar{display:flex;align-items:center;gap:16px;padding:16px;color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel-preview-bar p{margin:4px 0 0;color:var(--pfx-settings-panel-on-surface-variant);font-size:.875rem}praxis-settings-panel .settings-panel-preview-bar button{flex-shrink:0}@container settings-panel-shell (max-width: 599px){praxis-settings-panel .settings-panel-header:not([hidden]){display:grid;grid-template-columns:minmax(0,1fr) auto auto;align-items:start}praxis-settings-panel .settings-panel-header .spacer{display:none}praxis-settings-panel .settings-panel-header .settings-panel-title{grid-column:1;grid-row:1;overflow-wrap:anywhere}praxis-settings-panel .settings-panel-header [data-testid=settings-panel-toggle-expand]{grid-column:2;grid-row:1}praxis-settings-panel .settings-panel-header [data-testid=settings-panel-close-icon]{grid-column:3;grid-row:1}praxis-settings-panel .settings-panel-header [data-testid=settings-panel-preview]{grid-column:1/-1;grid-row:2;justify-self:start;max-width:100%}praxis-settings-panel .settings-panel-preview-bar{flex-direction:column;align-items:stretch;gap:8px}}@media(prefers-reduced-transparency:reduce){.praxis-settings-panel-backdrop{backdrop-filter:none;-webkit-backdrop-filter:none;background:var(--pfx-backdrop-opaque, rgba(8, 15, 26, .72))}}@media(forced-colors:active){praxis-settings-panel .settings-panel{border:1px solid CanvasText;background:Canvas;color:CanvasText}praxis-settings-panel .settings-panel-save-error,praxis-settings-panel .settings-panel-scope{border:1px solid CanvasText;background:Canvas;color:CanvasText}.praxis-settings-panel-backdrop{backdrop-filter:none;-webkit-backdrop-filter:none;background:Canvas;opacity:.75}}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { kind: "ngmodule", type: MatButtonModule }, { kind: "component", type: i4.MatButton, selector: " button[matButton], a[matButton], button[mat-button], button[mat-raised-button], button[mat-flat-button], button[mat-stroked-button], a[mat-button], a[mat-raised-button], a[mat-flat-button], a[mat-stroked-button] ", inputs: ["matButton"], exportAs: ["matButton", "matAnchor"] }, { kind: "ngmodule", type: MatIconModule }, { kind: "component", type: i3.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", type: PraxisIconButtonComponent, selector: "button[praxisIconButton]", inputs: ["praxisIconButton", "size", "appearance", "presentation", "pressed", "busy"] }, { kind: "directive", type: PraxisIconDirective, selector: "mat-icon[praxisIcon]", inputs: ["praxisIcon"] }, { kind: "ngmodule", type: MatTooltipModule }, { kind: "directive", type: i4$1.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "directive", type: CdkTrapFocus, selector: "[cdkTrapFocus]", inputs: ["cdkTrapFocus", "cdkTrapFocusAutoCapture"], exportAs: ["cdkTrapFocus"] }, { kind: "ngmodule", type: MatProgressSpinnerModule }, { kind: "component", type: i7.MatProgressSpinner, selector: "mat-progress-spinner, mat-spinner", inputs: ["color", "mode", "value", "diameter", "strokeWidth"], exportAs: ["matProgressSpinner"] }, { kind: "ngmodule", type: MatDialogModule }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None });
|
|
1402
1905
|
}
|
|
1403
1906
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: SettingsPanelComponent, decorators: [{
|
|
1404
1907
|
type: Component,
|
|
@@ -1413,13 +1916,16 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.14", ngImpo
|
|
|
1413
1916
|
CdkTrapFocus,
|
|
1414
1917
|
MatProgressSpinnerModule,
|
|
1415
1918
|
MatDialogModule,
|
|
1416
|
-
], changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, providers: [providePraxisSettingsPanelI18n()], template: "<div\n class=\"settings-panel\"\n data-testid=\"settings-panel-root\"\n [class.expanded]=\"expanded\"\n [class.settings-panel--preview]=\"previewing\"\n [class.is-resizable]=\"showResizeHandle\"\n [ngStyle]=\"panelInlineStyles\"\n role=\"dialog\"\n [attr.aria-modal]=\"interactionActive ? 'true' : null\"\n [attr.aria-hidden]=\"interactionActive ? null : 'true'\"\n [attr.inert]=\"interactionActive ? null : ''\"\n [attr.aria-labelledby]=\"previewing ? titleId + '-preview' : titleId\"\n [cdkTrapFocus]=\"interactionActive\"\n [cdkTrapFocusAutoCapture]=\"true\"\n >\n @if (showResizeHandle && !previewing) {\n <div\n class=\"settings-panel__resize-handle\"\n role=\"separator\"\n tabindex=\"0\"\n aria-orientation=\"vertical\"\n [attr.aria-label]=\"resizeHandleLabel\"\n (pointerdown)=\"onResizeHandlePointerDown($event)\"\n (keydown)=\"onResizeHandleKeydown($event)\"\n ></div>\n }\n @if (previewing) {\n <section class=\"settings-panel-preview-bar\" data-testid=\"settings-panel-preview-bar\">\n <div><strong [id]=\"titleId + '-preview'\">{{ tx('Page preview') }}</strong><p>{{ tx('Inspect the result. Return to keep editing; nothing is saved here.') }}</p></div>\n <button mat-flat-button type=\"button\" data-testid=\"settings-panel-return\" (click)=\"returnFromPreview()\">{{ tx('Back to settings') }}</button>\n </section>\n }\n <header class=\"settings-panel-header\" [hidden]=\"previewing\">\n <h2 class=\"settings-panel-title\" [id]=\"titleId\">\n @if (titleIcon) {\n <mat-icon class=\"title-icon\" [praxisIcon]=\"titleIcon\"></mat-icon>\n }\n <span>{{ title }}</span>\n </h2>\n <span class=\"spacer\"></span>\n @if (previewTarget) {\n <button mat-stroked-button type=\"button\" data-testid=\"settings-panel-preview\" [disabled]=\"!canInspectPreview\" (click)=\"showPreview()\">\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'visibility'\"></mat-icon>{{ tx('View result') }}\n </button>\n }\n <button\n [praxisIconButton]=\"expanded ? 'close_fullscreen' : 'open_in_full'\"\n size=\"compact\"\n type=\"button\"\n data-testid=\"settings-panel-toggle-expand\"\n [attr.aria-label]=\"expanded ? tx('Collapse panel') : tx('Expand panel')\"\n [attr.aria-expanded]=\"expanded\"\n [matTooltip]=\"expanded ? tx('Collapse panel') : tx('Expand panel')\"\n (click)=\"toggleExpand()\"\n ></button>\n <button\n praxisIconButton=\"close\"\n size=\"compact\"\n type=\"button\"\n data-testid=\"settings-panel-close-icon\"\n [attr.aria-label]=\"tx('Close')\"\n [matTooltip]=\"tx('Close')\"\n (click)=\"onCancel()\"\n ></button>\n </header>\n @if (hasContextNavigation && !previewing) {\n <nav\n class=\"settings-panel-context-nav\"\n data-testid=\"settings-panel-context-nav\"\n [attr.aria-label]=\"tx('Context navigation')\"\n >\n @if (contextNavigation?.targets?.length) {\n <div class=\"settings-panel-context-nav__targets\">\n <button\n praxisIconButton=\"chevron_left\"\n size=\"compact\"\n type=\"button\"\n data-testid=\"settings-panel-prev-target\"\n [disabled]=\"!canSelectPreviousTarget\"\n [attr.aria-label]=\"tx('Previous item')\"\n [matTooltip]=\"tx('Previous item')\"\n (click)=\"selectPreviousTarget()\"\n ></button>\n <select\n #targetSelect\n class=\"settings-panel-context-nav__target-select\"\n data-testid=\"settings-panel-target-select\"\n [disabled]=\"isBusy || !interactionActive\"\n [attr.aria-label]=\"tx('Editing target')\"\n [value]=\"contextNavigation?.activeTargetId || ''\"\n (change)=\"selectContextTarget(targetSelect.value, targetSelect)\"\n >\n @for (target of contextNavigation?.targets || []; track target.id) {\n <option [value]=\"target.id\" [selected]=\"target.id === contextNavigation?.activeTargetId\">\n {{ target.label }}\n </option>\n }\n </select>\n <button\n praxisIconButton=\"chevron_right\"\n size=\"compact\"\n type=\"button\"\n data-testid=\"settings-panel-next-target\"\n [disabled]=\"!canSelectNextTarget\"\n [attr.aria-label]=\"tx('Next item')\"\n [matTooltip]=\"tx('Next item')\"\n (click)=\"selectNextTarget()\"\n ></button>\n </div>\n }\n @if (contextNavigation?.modes?.length) {\n <div\n class=\"settings-panel-context-nav__modes\"\n role=\"group\"\n [attr.aria-label]=\"tx('Editing modes')\"\n >\n @for (mode of contextNavigation?.modes || []; track mode.id) {\n <button\n type=\"button\"\n class=\"settings-panel-context-nav__mode-btn\"\n [class.is-active]=\"mode.id === contextNavigation?.activeModeId\"\n [disabled]=\"mode.disabled || isBusy || !interactionActive\"\n [attr.aria-pressed]=\"mode.id === contextNavigation?.activeModeId\"\n [attr.title]=\"mode.label\"\n [attr.data-testid]=\"'settings-panel-mode-' + mode.id\"\n (click)=\"selectContextMode(mode.id)\"\n >\n {{ mode.label }}\n </button>\n }\n </div>\n }\n </nav>\n }\n @if (showStatusMessage && !previewing) {\n <div\n class=\"settings-panel-status\"\n [attr.data-status]=\"statusTone\"\n role=\"status\"\n aria-live=\"polite\"\n >\n <mat-icon\n aria-hidden=\"true\"\n [praxisIcon]=\"\n statusTone === 'dirty' || statusTone === 'invalid'\n ? 'warning'\n : statusTone === 'saved'\n ? 'check_circle'\n : statusTone === 'busy'\n ? 'autorenew'\n : 'info'\n \"\n ></mat-icon>\n <span>{{ statusMessage }}</span>\n @if (showWriteScopeControls) {\n <span class=\"spacer\"></span>\n <span\n class=\"settings-panel-scope\"\n [attr.data-scope]=\"activeWriteScope\"\n data-testid=\"settings-panel-write-scope\"\n >\n <span class=\"settings-panel-scope__label\">{{ writeScopeLabel }}</span>\n @if (canToggleWriteScope) {\n <button\n mat-stroked-button\n type=\"button\"\n class=\"settings-panel-scope__toggle\"\n data-testid=\"settings-panel-scope-toggle\"\n [matTooltip]=\"writeScopeToggleLabel\"\n (click)=\"toggleWriteScope()\"\n >\n {{ writeScopeToggleLabel }}\n </button>\n }\n @if (canResetPersonalOverride) {\n <button\n mat-button\n type=\"button\"\n class=\"settings-panel-scope__reset\"\n data-testid=\"settings-panel-reset-personal-override\"\n (click)=\"resetPersonalOverrideToTenant()\"\n >\n {{ tx('Reset to tenant baseline') }}\n </button>\n }\n </span>\n }\n </div>\n }\n @if (storageSaveError(); as saveErr) {\n <div\n class=\"settings-panel-save-error\"\n role=\"alert\"\n aria-live=\"assertive\"\n data-testid=\"settings-panel-save-error\"\n [attr.data-error-code]=\"saveErr.errorCode || saveErr.status || 'save-error'\"\n >\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'error_outline'\"></mat-icon>\n <div class=\"settings-panel-save-error__content\">\n <p class=\"settings-panel-save-error__message\">{{ formattedSaveErrorMessage }}</p>\n @if (saveErr.detail) {\n <p class=\"settings-panel-save-error__detail\">{{ saveErr.detail }}</p>\n }\n @if ((saveErr.errorCode === 'SHARED_CONFIG_SENSITIVE_CRITERIA_DENIED' || saveErr.status === 422) && activeWriteScope === 'tenant') {\n <button\n mat-stroked-button\n type=\"button\"\n class=\"settings-panel-save-error__action\"\n data-testid=\"settings-panel-switch-personal\"\n (click)=\"switchToPersonalScopeFromError()\"\n >\n {{ tx('Switch to personal scope') }}\n </button>\n }\n </div>\n <button\n praxisIconButton=\"close\"\n size=\"compact\"\n type=\"button\"\n data-testid=\"settings-panel-save-error-dismiss\"\n [attr.aria-label]=\"tx('Dismiss error')\"\n (click)=\"dismissSaveError()\"\n ></button>\n </div>\n }\n <div class=\"settings-panel-body\" [hidden]=\"previewing\">\n <ng-template #contentHost></ng-template>\n </div>\n <footer class=\"settings-panel-footer\" [hidden]=\"previewing\">\n <button\n mat-button\n type=\"button\"\n data-testid=\"settings-panel-reset\"\n (mousedown)=\"$event.stopPropagation()\"\n (click)=\"$event.stopPropagation(); onReset()\"\n [disabled]=\"isBusy\"\n >\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'restart_alt'\"></mat-icon>\n <span>{{ tx('Reset') }}</span>\n </button>\n <span class=\"spacer\"></span>\n <button\n mat-button\n type=\"button\"\n data-testid=\"settings-panel-cancel\"\n (mousedown)=\"$event.stopPropagation()\"\n (click)=\"$event.stopPropagation(); onCancel()\"\n [disabled]=\"isBusy\"\n >\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'close'\"></mat-icon>\n <span>{{ tx('Cancel') }}</span>\n </button>\n <button\n mat-stroked-button\n type=\"button\"\n data-testid=\"settings-panel-apply\"\n (mousedown)=\"$event.stopPropagation()\"\n (click)=\"$event.stopPropagation(); onApply()\"\n [disabled]=\"!canApply\"\n [matTooltip]=\"applySaveDisabledReason\"\n [matTooltipDisabled]=\"canApply || !diagnostics.showDisabledReason\"\n [attr.aria-busy]=\"isBusy\"\n [attr.aria-label]=\"applyActionLabel || 'Apply'\"\n >\n @if (showBusyIndicator) {\n <mat-progress-spinner\n mode=\"indeterminate\"\n diameter=\"20\"\n ></mat-progress-spinner>\n }\n @if (!showBusyIndicator) {\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'done'\"></mat-icon>\n <span class=\"settings-panel-action-label settings-panel-action-label--apply\">{{ applyActionLabel }}</span>\n }\n </button>\n <button\n mat-flat-button\n color=\"primary\"\n type=\"button\"\n data-testid=\"settings-panel-save\"\n (mousedown)=\"$event.stopPropagation()\"\n (click)=\"$event.stopPropagation(); onSave()\"\n [disabled]=\"!canSave\"\n [matTooltip]=\"applySaveDisabledReason\"\n [matTooltipDisabled]=\"canSave || !diagnostics.showDisabledReason\"\n [attr.aria-busy]=\"isBusy\"\n [attr.aria-label]=\"saveActionLabel || 'Save & Close'\"\n >\n @if (showBusyIndicator) {\n <mat-progress-spinner\n mode=\"indeterminate\"\n diameter=\"20\"\n ></mat-progress-spinner>\n }\n @if (!showBusyIndicator) {\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'save'\"></mat-icon>\n <span class=\"settings-panel-action-label settings-panel-action-label--save\">{{ saveActionLabel }}</span>\n }\n </button>\n </footer>\n</div>\n", styles: ["@charset \"UTF-8\";praxis-settings-panel{display:block;height:100%;width:100%;min-width:0;flex:1 1 auto;box-sizing:border-box}praxis-settings-panel .settings-panel{position:relative;container:settings-panel-shell/inline-size;--pfx-settings-panel-surface-container: var( --md-sys-color-surface-container, #ffffff );--pfx-settings-panel-surface-container-high: var( --md-sys-color-surface-container-high, #f7f7f7 );--pfx-settings-panel-surface-container-low: var( --md-sys-color-surface-container-low, #f2f4f7 );--pfx-settings-panel-surface: var(--md-sys-color-surface, #ffffff);--pfx-settings-panel-on-surface: var(--md-sys-color-on-surface, #111827);--pfx-settings-panel-on-surface-variant: var( --md-sys-color-on-surface-variant, rgba(17, 24, 39, .72) );--pfx-settings-panel-outline: var( --md-sys-color-outline, rgba(15, 23, 42, .24) );--pfx-settings-panel-outline-variant: var( --md-sys-color-outline-variant, rgba(15, 23, 42, .12) );--pfx-settings-panel-primary: var(--md-sys-color-primary, #2563eb);--pfx-settings-panel-primary-container: var( --md-sys-color-primary-container, rgba(37, 99, 235, .14) );--pfx-settings-panel-on-primary-container: var( --md-sys-color-on-primary-container, #0f172a );--pfx-settings-panel-secondary: var( --md-sys-color-secondary, var(--pfx-settings-panel-primary) );--pfx-settings-panel-error: var(--md-sys-color-error, #b3261e);--pfx-settings-panel-error-container: var( --md-sys-color-error-container, rgba(179, 38, 30, .14) );--pfx-settings-panel-alert-bg: color-mix( in srgb, var(--pfx-settings-panel-error-container) 78%, var(--pfx-settings-panel-surface) );--pfx-settings-panel-alert-fg: var(--pfx-settings-panel-error);--pfx-settings-panel-scope-bg: var(--pfx-settings-panel-surface);--pfx-settings-panel-scope-fg: var(--pfx-settings-panel-on-surface-variant);--pfx-settings-panel-border-radius: 0px;--mat-divider-color: var(--pfx-settings-panel-outline-variant);--mat-expansion-container-background-color: var( --pfx-settings-panel-surface-container );--mat-expansion-container-text-color: var(--pfx-settings-panel-on-surface);--mat-expansion-header-text-color: var(--pfx-settings-panel-on-surface);--mat-expansion-header-description-color: var( --pfx-settings-panel-on-surface-variant );--mat-expansion-header-indicator-color: var( --pfx-settings-panel-on-surface-variant );--mat-button-toggle-selected-state-background-color: var( --pfx-settings-panel-primary-container );--mat-button-toggle-selected-state-text-color: var( --pfx-settings-panel-on-primary-container );display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:auto auto auto auto 1fr auto;grid-template-areas:\"header\" \"context-nav\" \"status\" \"alert\" \"body\" \"footer\";min-width:0;height:100%;max-width:var(--pfx-settings-panel-max-width, 100%);background:var(--pfx-settings-panel-surface-container);color:var(--pfx-settings-panel-on-surface);border-left:1px solid var(--pfx-settings-panel-outline-variant);border-radius:var(--pfx-settings-panel-border-radius, 0px);width:var(--pfx-settings-panel-width, 100%);box-sizing:border-box;box-shadow:var(--pfx-settings-panel-elevation, var(--md-sys-elevation-level2, 0 8px 24px rgba(0, 0, 0, .16)));overflow:hidden}praxis-settings-panel .settings-panel__resize-handle{position:absolute;inset:0 auto 0 0;width:12px;cursor:col-resize;touch-action:none;z-index:3;outline:none}praxis-settings-panel .settings-panel__resize-handle:before{content:\"\";position:absolute;inset:0 auto 0 4px;width:2px;background:transparent;transition:background-color var(--pfx-side-panel-motion-duration, .16s) ease,opacity var(--pfx-side-panel-motion-duration, .16s) ease;opacity:0}praxis-settings-panel .settings-panel.is-resizable:hover .settings-panel__resize-handle:before,praxis-settings-panel .settings-panel__resize-handle:focus-visible:before{opacity:1;background:var(--pfx-settings-panel-outline)}praxis-settings-panel .settings-panel-header{grid-area:header;display:flex;align-items:center;gap:var(--pfx-settings-panel-header-gap, 8px);padding:12px var(--pfx-settings-panel-header-padding-x, 20px);min-height:var(--pfx-settings-panel-header-height, 64px);border-bottom:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-high);box-shadow:var(--pfx-settings-panel-header-shadow, var(--md-sys-elevation-level1, 0 2px 6px rgba(0, 0, 0, .08)));flex-shrink:0;min-width:0;max-width:100%}praxis-settings-panel .settings-panel-header .spacer{flex:1 1 auto;min-width:0}praxis-settings-panel .settings-panel-context-nav{grid-area:context-nav;display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px 12px;padding:8px var(--pfx-settings-panel-header-padding-x, 20px);border-bottom:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-low);min-width:0;max-width:100%}praxis-settings-panel .settings-panel-context-nav__targets{display:flex;align-items:center;gap:4px;min-width:0;flex:1 1 200px}praxis-settings-panel .settings-panel-context-nav__target-select{flex:1 1 auto;min-width:0;min-height:34px;padding:4px 10px;border-radius:8px;border:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface);color:var(--pfx-settings-panel-on-surface);font:inherit;font-size:.84rem;font-weight:600}praxis-settings-panel .settings-panel-context-nav__modes{display:inline-flex;align-items:center;flex-wrap:wrap;gap:4px;padding:2px;max-width:100%;border-radius:999px;border:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface)}praxis-settings-panel .settings-panel-context-nav__mode-btn{appearance:none;border:none;background:transparent;color:var(--pfx-settings-panel-on-surface-variant);font:inherit;font-size:.78rem;font-weight:600;padding:5px 12px;border-radius:999px;white-space:nowrap;flex-shrink:0;cursor:pointer;transition:background-color .14s ease,color .14s ease}praxis-settings-panel .settings-panel-context-nav__mode-btn.is-active{background:var(--pfx-settings-panel-primary-container);color:var(--pfx-settings-panel-on-primary-container)}praxis-settings-panel .settings-panel-context-nav__mode-btn:disabled{opacity:.42;cursor:not-allowed}praxis-settings-panel .settings-panel-status{grid-area:status;display:flex;align-items:center;gap:8px;min-height:36px;padding:6px var(--pfx-settings-panel-status-padding-x, 20px);border-bottom:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-high);color:var(--pfx-settings-panel-on-surface);font-size:.85rem;font-weight:500;min-width:0;max-width:100%}praxis-settings-panel .settings-panel-status mat-icon{width:18px;height:18px;font-size:18px}praxis-settings-panel .settings-panel-status[data-status=dirty],praxis-settings-panel .settings-panel-status[data-status=invalid]{color:var(--pfx-settings-panel-error);background:color-mix(in srgb,var(--pfx-settings-panel-error-container) 30%,var(--pfx-settings-panel-surface-container-high))}praxis-settings-panel .settings-panel-status[data-status=saved]{color:var(--pfx-settings-panel-primary);background:color-mix(in srgb,var(--pfx-settings-panel-primary-container) 28%,var(--pfx-settings-panel-surface-container-high))}praxis-settings-panel .settings-panel-scope{display:inline-flex;align-items:center;flex-wrap:wrap;gap:6px;padding:2px 8px;border-radius:999px;border:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-scope-bg);color:var(--pfx-settings-panel-scope-fg);font-size:.75rem;font-weight:600}praxis-settings-panel .settings-panel-scope[data-scope=tenant]{border-color:color-mix(in srgb,var(--pfx-settings-panel-primary) 42%,var(--pfx-settings-panel-outline-variant));background:var(--pfx-settings-panel-primary-container);color:var(--pfx-settings-panel-on-primary-container)}praxis-settings-panel .settings-panel-scope__toggle,praxis-settings-panel .settings-panel-scope__reset{height:24px;line-height:22px;font-size:.72rem;padding:0 8px}praxis-settings-panel .settings-panel-save-error{grid-area:alert;display:flex;align-items:flex-start;gap:10px;padding:10px var(--pfx-settings-panel-status-padding-x, 20px);background:var(--pfx-settings-panel-alert-bg);color:var(--pfx-settings-panel-alert-fg);border-bottom:1px solid color-mix(in srgb,var(--pfx-settings-panel-error) 32%,var(--pfx-settings-panel-outline-variant));font-size:.82rem}praxis-settings-panel .settings-panel-save-error__content{flex:1 1 auto;min-width:0;display:flex;flex-direction:column;gap:4px}praxis-settings-panel .settings-panel-save-error__message{margin:0;font-weight:600;line-height:1.35}praxis-settings-panel .settings-panel-save-error__detail{margin:0;font-size:.78rem;color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel-save-error__action{align-self:flex-start;margin-top:2px}praxis-settings-panel .settings-panel-body{grid-area:body;overflow-y:auto;overflow-x:hidden;scroll-padding-top:var(--pfx-settings-panel-scroll-padding-start, 16px);scroll-padding-bottom:var(--pfx-settings-panel-scroll-padding-end, 88px);min-height:0;padding:var(--pfx-settings-panel-body-padding, 8px 16px 24px);background:var(--pfx-settings-panel-surface);display:flex;flex-direction:column;min-width:0;max-width:100%}praxis-settings-panel .settings-panel-body>*{min-width:0;max-width:100%}praxis-settings-panel .settings-panel-content{display:block;min-width:0;max-width:100%}praxis-settings-panel .settings-panel-content>*{min-width:0;max-width:100%;box-sizing:border-box}praxis-settings-panel .settings-panel-footer{grid-area:footer;border-top:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-high);box-shadow:var(--pfx-settings-panel-footer-shadow, var(--md-sys-elevation-level1, 0 -2px 6px rgba(0, 0, 0, .08)));display:flex;align-items:center;flex-wrap:wrap;padding:var(--pfx-settings-panel-footer-padding, 12px 20px);column-gap:var(--pfx-settings-panel-footer-gap, 12px);row-gap:8px;flex-shrink:0;min-width:0;max-width:100%}praxis-settings-panel .spacer{flex:1}praxis-settings-panel .settings-panel-title{display:inline-flex;align-items:center;flex:1 1 auto;gap:var(--pfx-settings-panel-title-gap, 8px);font-weight:700;line-height:1.2;letter-spacing:.2px;margin:0;min-width:0;overflow:visible;white-space:normal}praxis-settings-panel .settings-panel-title span{min-width:0;overflow:visible;white-space:normal}praxis-settings-panel .settings-panel-title mat-icon{color:var(--pfx-settings-panel-primary)}praxis-settings-panel .settings-panel-title .title-icon{width:20px;height:20px;font-size:20px}praxis-settings-panel .settings-panel-footer button{display:inline-flex;align-items:center}praxis-settings-panel .settings-panel-footer button .mat-icon{flex:0 0 20px;font-size:20px;width:20px;height:20px;line-height:1;display:inline-flex;align-items:center;justify-content:center;overflow:hidden}praxis-settings-panel .settings-panel-footer .mat-button-wrapper{display:inline-flex;align-items:center;gap:var(--pfx-settings-panel-button-gap, 8px)}praxis-settings-panel .settings-panel-footer .mat-progress-spinner{margin-right:8px}praxis-settings-panel .settings-panel-footer .mat-flat-button[color=primary]{font-weight:600}praxis-settings-panel .settings-panel-footer .mdc-button__label{display:inline-flex;align-items:center;gap:var(--pfx-settings-panel-button-gap, 8px);line-height:1}praxis-settings-panel .settings-panel-footer .mdc-button__label>span{display:inline-flex;align-items:center;line-height:1}praxis-settings-panel .settings-panel-footer .mdc-button__label .mat-icon{display:inline-flex;align-items:center;justify-content:center;line-height:1}@container settings-panel-shell (max-width: 520px){praxis-settings-panel .settings-panel-footer{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);align-items:stretch;padding:10px 12px;column-gap:8px}praxis-settings-panel .settings-panel-footer .spacer{display:none}praxis-settings-panel .settings-panel-footer button{justify-content:center;width:100%;min-width:0;min-height:44px;height:auto;padding:8px}praxis-settings-panel .settings-panel-action-label{white-space:normal;overflow-wrap:anywhere;text-align:center}praxis-settings-panel .settings-panel-footer .mdc-button__label{min-width:0;max-width:100%}praxis-settings-panel .settings-panel-footer .mdc-button__label>span{min-width:0;line-height:1.25}}@container settings-panel-shell (max-width: 280px){praxis-settings-panel .settings-panel-footer{grid-template-columns:minmax(0,1fr)}}praxis-settings-panel .settings-panel .mat-divider{background-color:var(--pfx-settings-panel-outline-variant)}praxis-settings-panel .settings-panel .mat-expansion-panel{background:var(--pfx-settings-panel-surface-container);border:1px solid var(--pfx-settings-panel-outline-variant);border-radius:var(--md-sys-shape-corner-medium, 12px);box-shadow:var(--md-sys-elevation-level1, 0 2px 8px rgba(0, 0, 0, .08));color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-expansion-panel-header{background:var(--pfx-settings-panel-surface-container);color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-content{color:var(--pfx-settings-panel-on-surface);flex-wrap:wrap;gap:4px 12px;min-width:0;overflow:visible}praxis-settings-panel .settings-panel .mat-expansion-panel:not(.mat-expanded) .mat-expansion-panel-header:hover{background:color-mix(in srgb,var(--pfx-settings-panel-surface-container-high) 84%,var(--pfx-settings-panel-primary) 16%)}praxis-settings-panel .settings-panel .mat-expansion-panel.mat-expanded>.mat-expansion-panel-header{background:var(--pfx-settings-panel-surface-container-high)}praxis-settings-panel .settings-panel .mat-expansion-panel-header mat-icon,praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-icon{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-title,praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-description{color:var(--pfx-settings-panel-on-surface);min-width:0;overflow:visible;white-space:normal}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-description{color:var(--pfx-settings-panel-on-surface-variant);flex-wrap:wrap;gap:8px}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-title>*,praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-description>*{color:inherit}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-title small,praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-description small{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-indicator,praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-indicator:after{color:var(--pfx-settings-panel-on-surface-variant);border-color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-expansion-panel .mat-action-row{border-top-color:var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-low)}praxis-settings-panel .settings-panel .mat-accordion,praxis-settings-panel .settings-panel .mat-accordion .mat-expansion-panel-spacing{background:transparent}praxis-settings-panel .settings-panel .mat-expansion-panel-content,praxis-settings-panel .settings-panel .mat-expansion-panel-content-wrapper,praxis-settings-panel .settings-panel .mat-expansion-panel-body{background:var(--pfx-settings-panel-surface-container);color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-expansion-panel .mat-expansion-panel-body{padding:8px}praxis-settings-panel .settings-panel .mat-expansion-panel .mat-expansion-panel-body>*{color:inherit}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mat-mdc-tab-header{border-bottom:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-low)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab{min-width:0}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab .mdc-tab__text-label{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab:hover .mdc-tab__text-label,praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab:focus .mdc-tab__text-label{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab.mdc-tab--active .mdc-tab__text-label{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mat-mdc-tab-header-pagination{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mat-mdc-tab-header-pagination-chevron{border-color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mat-mdc-tab-header-pagination:not(.mat-mdc-tab-header-pagination-disabled):hover{background:color-mix(in srgb,var(--pfx-settings-panel-surface-container-high) 84%,var(--pfx-settings-panel-primary) 16%)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab-indicator__content--underline{border-color:var(--pfx-settings-panel-primary)}praxis-settings-panel .settings-panel .mat-mdc-card{background:var(--pfx-settings-panel-surface-container-low);border:1px solid var(--pfx-settings-panel-outline-variant);color:var(--pfx-settings-panel-on-surface);box-shadow:var(--md-sys-elevation-level1, 0 2px 8px rgba(0, 0, 0, .08))}praxis-settings-panel .settings-panel .mat-mdc-card-subtitle{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-mdc-card-title,praxis-settings-panel .settings-panel .mat-mdc-card-content{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-form-field{width:100%;align-self:start;--mdc-filled-text-field-container-color: var( --pfx-settings-panel-surface-container );--mdc-filled-text-field-hover-container-color: var( --pfx-settings-panel-surface-container-high );--mdc-filled-text-field-focus-container-color: var( --pfx-settings-panel-surface-container-high );--mdc-filled-text-field-active-indicator-color: var( --pfx-settings-panel-outline-variant );--mdc-filled-text-field-hover-active-indicator-color: var( --pfx-settings-panel-secondary );--mdc-filled-text-field-focus-active-indicator-color: var( --pfx-settings-panel-primary );--mdc-filled-text-field-label-text-color: var( --pfx-settings-panel-on-surface-variant );--mdc-filled-text-field-focus-label-text-color: var( --pfx-settings-panel-primary );--mdc-filled-text-field-input-text-color: var( --pfx-settings-panel-on-surface );--mdc-filled-text-field-caret-color: var(--pfx-settings-panel-primary);--mdc-outlined-text-field-outline-color: var( --pfx-settings-panel-outline-variant );--mdc-outlined-text-field-hover-outline-color: var( --pfx-settings-panel-secondary );--mdc-outlined-text-field-focus-outline-color: var( --pfx-settings-panel-primary );--mdc-outlined-text-field-label-text-color: var( --pfx-settings-panel-on-surface-variant );--mdc-outlined-text-field-focus-label-text-color: var( --pfx-settings-panel-primary );--mdc-outlined-text-field-input-text-color: var( --pfx-settings-panel-on-surface );--mdc-outlined-text-field-caret-color: var(--pfx-settings-panel-primary);--mat-form-field-focus-select-arrow-color: var( --pfx-settings-panel-primary );--mat-form-field-enabled-select-arrow-color: var( --pfx-settings-panel-on-surface-variant )}praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-text-field-wrapper.mdc-text-field--filled,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled{background-color:var(--pfx-settings-panel-surface-container);border-radius:var(--md-sys-shape-corner-small, 8px) var(--md-sys-shape-corner-small, 8px) 0 0}praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled .mat-mdc-form-field-flex,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled .mat-mdc-form-field-infix,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled .mat-mdc-form-field-focus-overlay{background:var(--pfx-settings-panel-surface-container);color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-text-field-wrapper.mdc-text-field--outlined,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--outlined,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--outlined .mat-mdc-form-field-flex,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--outlined .mat-mdc-form-field-infix{background:transparent;background-color:transparent;color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-form-field-focus-overlay{opacity:0}praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled .mdc-floating-label,praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-select-placeholder,praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-select-arrow,praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-floating-label{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-select-value,praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-select-value-text,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled .mdc-text-field__input,praxis-settings-panel .settings-panel .mat-mdc-form-field input,praxis-settings-panel .settings-panel .mat-mdc-form-field textarea,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field__input{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--focused:not(.mdc-text-field--invalid) .mat-mdc-floating-label,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled.mdc-text-field--focused .mdc-floating-label{color:var(--pfx-settings-panel-primary)}praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--invalid .mat-mdc-floating-label{color:var(--pfx-settings-panel-error)}praxis-settings-panel .settings-panel .mat-mdc-form-field-subscript-wrapper{position:relative;box-sizing:border-box}praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-form-field-hint-wrapper,praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-form-field-error-wrapper{position:relative;top:auto;left:auto;right:auto;padding-top:4px;line-height:1.35}praxis-settings-panel .settings-panel .mat-mdc-form-field-bottom-align:before{display:none}praxis-settings-panel .settings-panel .mat-mdc-form-field-subscript-wrapper,praxis-settings-panel .settings-panel .mat-mdc-form-field-hint-wrapper,praxis-settings-panel .settings-panel .mat-mdc-form-field-error-wrapper,praxis-settings-panel .settings-panel .mat-mdc-hint{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-button-toggle-group{border-color:var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-low)}praxis-settings-panel .settings-panel .mat-button-toggle{background:var(--pfx-settings-panel-surface-container-low);color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-button-toggle+.mat-button-toggle{border-left-color:var(--pfx-settings-panel-outline-variant)}praxis-settings-panel .settings-panel .mat-button-toggle-group .mat-button-toggle-checked{background:var(--pfx-settings-panel-primary-container);color:var(--pfx-settings-panel-on-primary-container)}praxis-settings-panel .settings-panel .mat-button-toggle .mat-icon,praxis-settings-panel .settings-panel .mat-button-toggle-checked .mat-icon{color:inherit}praxis-settings-panel .settings-panel .mat-mdc-slide-toggle .mdc-label{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .pfx-editor-section{box-sizing:border-box;width:100%;min-width:0;padding:16px;border-radius:16px;border:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-low)}praxis-settings-panel .settings-panel .pfx-editor-subgroup{display:grid;gap:12px;padding-top:14px;border-top:1px solid color-mix(in srgb,var(--pfx-settings-panel-outline-variant) 70%,transparent)}praxis-settings-panel .settings-panel .pfx-editor-subgroup:first-child{padding-top:0;border-top:0}praxis-settings-panel .settings-panel .pfx-editor-grid-12{display:grid;grid-template-columns:repeat(12,minmax(0,1fr));gap:12px;min-width:0}praxis-settings-panel .settings-panel .pfx-editor-toggle-cluster{display:flex;flex-wrap:wrap;align-items:center;gap:12px 20px}.settings-panel{grid-template-columns:minmax(0,1fr);min-width:0;max-width:100%}.settings-panel-body{overflow-x:hidden;min-width:0}.settings-panel-body>*{min-width:0;max-width:100%}.praxis-settings-panel-backdrop{background:var(--pfx-settings-panel-backdrop, var(--pfx-backdrop, rgba(8, 15, 26, .42)));backdrop-filter:blur(var(--pfx-settings-panel-backdrop-blur, var(--pfx-backdrop-blur, 6px))) saturate(110%);-webkit-backdrop-filter:blur(var(--pfx-settings-panel-backdrop-blur, var(--pfx-backdrop-blur, 6px))) saturate(110%)}:is(.cdk-overlay-pane.praxis-settings-panel-pane,.praxis-settings-panel-pane){position:fixed;top:0;right:0;display:flex;align-items:stretch;height:100vh;max-width:var(--pfx-settings-panel-pane-max-width, 100vw);max-height:100vh;z-index:var(--pfx-settings-panel-z-index, var(--praxis-layer-settings-panel, 1220));transition:width var(--pfx-side-panel-motion-duration-enter, .3s) var(--pfx-side-panel-motion-easing-enter, ease)}.praxis-settings-panel-pane .settings-panel{pointer-events:auto}@media(prefers-reduced-motion:reduce){.praxis-settings-panel-pane{transition:none}}:is(.cdk-overlay-pane.praxis-settings-panel-pane.praxis-settings-panel-pane--preview,.praxis-settings-panel-pane.praxis-settings-panel-pane--preview){top:auto;bottom:12px;right:12px;height:auto;width:min(560px,100vw - 24px);min-width:0;transition:none}.praxis-settings-panel-backdrop.praxis-settings-panel-backdrop--preview{background:transparent;backdrop-filter:none;-webkit-backdrop-filter:none}.praxis-settings-preview-target{outline:2px solid var(--md-sys-color-primary);outline-offset:3px}praxis-settings-panel .settings-panel [hidden]{display:none}praxis-settings-panel .settings-panel .settings-panel-header[hidden],praxis-settings-panel .settings-panel .settings-panel-body[hidden],praxis-settings-panel .settings-panel .settings-panel-footer[hidden]{display:none}praxis-settings-panel .settings-panel--preview{height:auto;min-height:0;grid-template-rows:auto;border-radius:16px}praxis-settings-panel .settings-panel-preview-bar{display:flex;align-items:center;gap:16px;padding:16px;color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel-preview-bar p{margin:4px 0 0;color:var(--pfx-settings-panel-on-surface-variant);font-size:.875rem}praxis-settings-panel .settings-panel-preview-bar button{flex-shrink:0}@container settings-panel-shell (max-width: 599px){praxis-settings-panel .settings-panel-header:not([hidden]){display:grid;grid-template-columns:minmax(0,1fr) auto auto;align-items:start}praxis-settings-panel .settings-panel-header .spacer{display:none}praxis-settings-panel .settings-panel-header .settings-panel-title{grid-column:1;grid-row:1;overflow-wrap:anywhere}praxis-settings-panel .settings-panel-header [data-testid=settings-panel-toggle-expand]{grid-column:2;grid-row:1}praxis-settings-panel .settings-panel-header [data-testid=settings-panel-close-icon]{grid-column:3;grid-row:1}praxis-settings-panel .settings-panel-header [data-testid=settings-panel-preview]{grid-column:1/-1;grid-row:2;justify-self:start;max-width:100%}praxis-settings-panel .settings-panel-preview-bar{flex-direction:column;align-items:stretch;gap:8px}}\n"] }]
|
|
1919
|
+
], changeDetection: ChangeDetectionStrategy.OnPush, encapsulation: ViewEncapsulation.None, providers: [providePraxisSettingsPanelI18n()], template: "<div\n class=\"settings-panel\"\n data-testid=\"settings-panel-root\"\n [class.expanded]=\"expanded\"\n [class.settings-panel--preview]=\"previewing\"\n [class.is-resizable]=\"showResizeHandle\"\n [ngStyle]=\"panelInlineStyles\"\n role=\"dialog\"\n [attr.aria-modal]=\"interactionActive ? 'true' : null\"\n [attr.aria-hidden]=\"interactionActive ? null : 'true'\"\n [attr.inert]=\"interactionActive ? null : ''\"\n [attr.aria-labelledby]=\"previewing ? titleId + '-preview' : titleId\"\n [cdkTrapFocus]=\"interactionActive\"\n [cdkTrapFocusAutoCapture]=\"true\"\n >\n @if (showResizeHandle && !previewing) {\n <div\n class=\"settings-panel__resize-handle\"\n role=\"separator\"\n tabindex=\"0\"\n aria-orientation=\"vertical\"\n [attr.aria-label]=\"resizeHandleLabel\"\n (pointerdown)=\"onResizeHandlePointerDown($event)\"\n (keydown)=\"onResizeHandleKeydown($event)\"\n ></div>\n }\n @if (previewing) {\n <section class=\"settings-panel-preview-bar\" data-testid=\"settings-panel-preview-bar\">\n <div><strong [id]=\"titleId + '-preview'\">{{ tx('Page preview') }}</strong><p>{{ tx('Inspect the result. Return to keep editing; nothing is saved here.') }}</p></div>\n <button mat-flat-button type=\"button\" data-testid=\"settings-panel-return\" (click)=\"returnFromPreview()\">{{ tx('Back to settings') }}</button>\n </section>\n }\n <header class=\"settings-panel-header\" [hidden]=\"previewing\">\n <h2 class=\"settings-panel-title\" [id]=\"titleId\">\n @if (titleIcon) {\n <mat-icon class=\"title-icon\" [praxisIcon]=\"titleIcon\"></mat-icon>\n }\n <span>{{ title }}</span>\n </h2>\n <span class=\"spacer\"></span>\n @if (previewTarget) {\n <button mat-stroked-button type=\"button\" data-testid=\"settings-panel-preview\" [disabled]=\"!canInspectPreview\" (click)=\"showPreview()\">\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'visibility'\"></mat-icon>{{ tx('View result') }}\n </button>\n }\n <button\n [praxisIconButton]=\"expanded ? 'close_fullscreen' : 'open_in_full'\"\n size=\"compact\"\n type=\"button\"\n data-testid=\"settings-panel-toggle-expand\"\n [attr.aria-label]=\"expanded ? tx('Collapse panel') : tx('Expand panel')\"\n [attr.aria-expanded]=\"expanded\"\n [matTooltip]=\"expanded ? tx('Collapse panel') : tx('Expand panel')\"\n (click)=\"toggleExpand()\"\n ></button>\n <button\n praxisIconButton=\"close\"\n size=\"compact\"\n type=\"button\"\n data-testid=\"settings-panel-close-icon\"\n [disabled]=\"isBusy\"\n [attr.aria-label]=\"tx('Close')\"\n [matTooltip]=\"tx('Close')\"\n (click)=\"onCancel()\"\n ></button>\n </header>\n @if (hasContextNavigation && !previewing) {\n <nav\n class=\"settings-panel-context-nav\"\n data-testid=\"settings-panel-context-nav\"\n [attr.aria-label]=\"tx('Context navigation')\"\n >\n @if (contextNavigation?.targets?.length) {\n <div class=\"settings-panel-context-nav__targets\">\n <button\n praxisIconButton=\"chevron_left\"\n size=\"compact\"\n type=\"button\"\n data-testid=\"settings-panel-prev-target\"\n [disabled]=\"!canSelectPreviousTarget\"\n [attr.aria-label]=\"tx('Previous item')\"\n [matTooltip]=\"tx('Previous item')\"\n (click)=\"selectPreviousTarget()\"\n ></button>\n <select\n #targetSelect\n class=\"settings-panel-context-nav__target-select\"\n data-testid=\"settings-panel-target-select\"\n [disabled]=\"isBusy || !interactionActive\"\n [attr.aria-label]=\"tx('Editing target')\"\n [value]=\"contextNavigation?.activeTargetId || ''\"\n (change)=\"selectContextTarget(targetSelect.value, targetSelect)\"\n >\n @for (target of contextNavigation?.targets || []; track target.id) {\n <option [value]=\"target.id\" [selected]=\"target.id === contextNavigation?.activeTargetId\">\n {{ target.label }}\n </option>\n }\n </select>\n <button\n praxisIconButton=\"chevron_right\"\n size=\"compact\"\n type=\"button\"\n data-testid=\"settings-panel-next-target\"\n [disabled]=\"!canSelectNextTarget\"\n [attr.aria-label]=\"tx('Next item')\"\n [matTooltip]=\"tx('Next item')\"\n (click)=\"selectNextTarget()\"\n ></button>\n </div>\n }\n @if (contextNavigation?.modes?.length) {\n <div\n class=\"settings-panel-context-nav__modes\"\n role=\"group\"\n [attr.aria-label]=\"tx('Editing modes')\"\n >\n @for (mode of contextNavigation?.modes || []; track mode.id) {\n <button\n type=\"button\"\n class=\"settings-panel-context-nav__mode-btn\"\n [class.is-active]=\"mode.id === contextNavigation?.activeModeId\"\n [disabled]=\"mode.disabled || isBusy || !interactionActive\"\n [attr.aria-pressed]=\"mode.id === contextNavigation?.activeModeId\"\n [attr.title]=\"mode.label\"\n [attr.data-testid]=\"'settings-panel-mode-' + mode.id\"\n (click)=\"selectContextMode(mode.id)\"\n >\n {{ mode.label }}\n </button>\n }\n </div>\n }\n </nav>\n }\n @if (showStatusMessage && !previewing) {\n <div\n class=\"settings-panel-status\"\n [attr.data-status]=\"statusTone\"\n role=\"status\"\n aria-live=\"polite\"\n >\n <mat-icon\n aria-hidden=\"true\"\n [praxisIcon]=\"\n statusTone === 'dirty' || statusTone === 'invalid'\n ? 'warning'\n : statusTone === 'saved'\n ? 'check_circle'\n : statusTone === 'busy'\n ? 'autorenew'\n : 'info'\n \"\n ></mat-icon>\n <span>{{ statusMessage }}</span>\n @if (showWriteScopeControls) {\n <span class=\"spacer\"></span>\n <span\n class=\"settings-panel-scope\"\n [attr.data-scope]=\"activeWriteScope\"\n data-testid=\"settings-panel-write-scope\"\n >\n <span class=\"settings-panel-scope__label\">{{ writeScopeLabel }}</span>\n @if (canToggleWriteScope) {\n <button\n mat-stroked-button\n type=\"button\"\n class=\"settings-panel-scope__toggle\"\n data-testid=\"settings-panel-scope-toggle\"\n [matTooltip]=\"writeScopeToggleLabel\"\n (click)=\"toggleWriteScope()\"\n >\n {{ writeScopeToggleLabel }}\n </button>\n }\n @if (canResetPersonalOverride) {\n <button\n mat-button\n type=\"button\"\n class=\"settings-panel-scope__reset\"\n data-testid=\"settings-panel-reset-personal-override\"\n [disabled]=\"isBusy || isConfirmDialogOpen\"\n (click)=\"resetPersonalOverrideToTenant()\"\n >\n {{ tx('Reset to tenant baseline') }}\n </button>\n }\n </span>\n }\n </div>\n }\n @if (!previewing && storageSaveError(); as saveErr) {\n <div\n #saveErrorBanner\n tabindex=\"-1\"\n class=\"settings-panel-save-error\"\n role=\"alert\"\n aria-live=\"assertive\"\n aria-atomic=\"true\"\n data-testid=\"settings-panel-save-error\"\n [attr.data-error-code]=\"saveErr.errorCode || saveErr.status || 'save-error'\"\n [attr.data-correlation-id]=\"saveErr.correlationId || null\"\n >\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'error_outline'\"></mat-icon>\n <div class=\"settings-panel-save-error__content\">\n <p class=\"settings-panel-save-error__message\">{{ formattedSaveErrorMessage }}</p>\n @if (saveErr.detail && saveErr.detail !== formattedSaveErrorMessage && saveErr.detail !== saveErrorFieldMessages.join('; ')) {\n <p class=\"settings-panel-save-error__detail\">{{ saveErr.detail }}</p>\n } @else if (saveErr.title && saveErr.title !== formattedSaveErrorMessage) {\n <p class=\"settings-panel-save-error__detail\">{{ saveErr.title }}</p>\n }\n @if (saveErr.errorCode || saveErr.correlationId) {\n <p class=\"settings-panel-save-error__meta\" data-testid=\"settings-panel-save-error-meta\">\n @if (saveErr.errorCode) {\n <span>{{ tx('Code: {{code}}', { code: saveErr.errorCode }) }}</span>\n }\n @if (saveErr.correlationId) {\n <span>{{ tx('Correlation ID: {{id}}', { id: saveErr.correlationId }) }}</span>\n }\n </p>\n }\n @if (saveErrorFieldMessages.length > 0) {\n <ul class=\"settings-panel-save-error__fields\" data-testid=\"settings-panel-save-error-fields\">\n @for (fieldMsg of saveErrorFieldMessages; track $index) {\n <li>{{ fieldMsg }}</li>\n }\n </ul>\n }\n @if (canSwitchToPersonalScopeFromError) {\n <button\n mat-stroked-button\n type=\"button\"\n class=\"settings-panel-save-error__action\"\n data-testid=\"settings-panel-switch-personal\"\n (click)=\"switchToPersonalScopeFromError()\"\n >\n {{ tx('Switch to personal scope') }}\n </button>\n }\n </div>\n <button\n praxisIconButton=\"close\"\n size=\"compact\"\n type=\"button\"\n data-testid=\"settings-panel-save-error-dismiss\"\n [attr.aria-label]=\"tx('Dismiss error')\"\n (click)=\"dismissSaveError()\"\n ></button>\n </div>\n }\n <div class=\"settings-panel-body\" [hidden]=\"previewing\">\n <ng-template #contentHost></ng-template>\n </div>\n <footer class=\"settings-panel-footer\" [hidden]=\"previewing\">\n <button\n mat-button\n type=\"button\"\n data-testid=\"settings-panel-reset\"\n (mousedown)=\"$event.stopPropagation()\"\n (click)=\"$event.stopPropagation(); onReset()\"\n [disabled]=\"isBusy || isConfirmDialogOpen\"\n >\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'restart_alt'\"></mat-icon>\n <span>{{ tx('Reset') }}</span>\n </button>\n <span class=\"spacer\"></span>\n <button\n mat-button\n type=\"button\"\n data-testid=\"settings-panel-cancel\"\n (mousedown)=\"$event.stopPropagation()\"\n (click)=\"$event.stopPropagation(); onCancel()\"\n [disabled]=\"isBusy || isConfirmDialogOpen\"\n >\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'close'\"></mat-icon>\n <span>{{ tx('Cancel') }}</span>\n </button>\n <button\n mat-stroked-button\n type=\"button\"\n data-testid=\"settings-panel-apply\"\n (mousedown)=\"$event.stopPropagation()\"\n (click)=\"$event.stopPropagation(); onApply()\"\n [disabled]=\"!canApply\"\n [matTooltip]=\"applySaveDisabledReason\"\n [matTooltipDisabled]=\"canApply || !diagnostics.showDisabledReason\"\n [attr.aria-busy]=\"isBusy\"\n [attr.aria-label]=\"applyActionLabel || 'Apply'\"\n >\n @if (showBusyIndicator) {\n <mat-progress-spinner\n mode=\"indeterminate\"\n diameter=\"20\"\n ></mat-progress-spinner>\n }\n @if (!showBusyIndicator) {\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'done'\"></mat-icon>\n <span class=\"settings-panel-action-label settings-panel-action-label--apply\">{{ applyActionLabel }}</span>\n }\n </button>\n <button\n mat-flat-button\n color=\"primary\"\n type=\"button\"\n data-testid=\"settings-panel-save\"\n (mousedown)=\"$event.stopPropagation()\"\n (click)=\"$event.stopPropagation(); onSave()\"\n [disabled]=\"!canSave\"\n [matTooltip]=\"applySaveDisabledReason\"\n [matTooltipDisabled]=\"canSave || !diagnostics.showDisabledReason\"\n [attr.aria-busy]=\"isBusy\"\n [attr.aria-label]=\"saveActionLabel || 'Save & Close'\"\n >\n @if (showBusyIndicator) {\n <mat-progress-spinner\n mode=\"indeterminate\"\n diameter=\"20\"\n ></mat-progress-spinner>\n }\n @if (!showBusyIndicator) {\n <mat-icon aria-hidden=\"true\" [praxisIcon]=\"'save'\"></mat-icon>\n <span class=\"settings-panel-action-label settings-panel-action-label--save\">{{ saveActionLabel }}</span>\n }\n </button>\n </footer>\n</div>\n", styles: ["@charset \"UTF-8\";praxis-settings-panel{display:block;height:100%;width:100%;min-width:0;flex:1 1 auto;box-sizing:border-box}praxis-settings-panel .settings-panel{position:relative;container:settings-panel-shell/inline-size;--pfx-settings-panel-surface-container: var( --md-sys-color-surface-container, #ffffff );--pfx-settings-panel-surface-container-high: var( --md-sys-color-surface-container-high, #f7f7f7 );--pfx-settings-panel-surface-container-low: var( --md-sys-color-surface-container-low, #f2f4f7 );--pfx-settings-panel-surface: var(--md-sys-color-surface, #ffffff);--pfx-settings-panel-on-surface: var(--md-sys-color-on-surface, #111827);--pfx-settings-panel-on-surface-variant: var( --md-sys-color-on-surface-variant, rgba(17, 24, 39, .72) );--pfx-settings-panel-outline: var( --md-sys-color-outline, rgba(15, 23, 42, .24) );--pfx-settings-panel-outline-variant: var( --md-sys-color-outline-variant, rgba(15, 23, 42, .12) );--pfx-settings-panel-primary: var(--md-sys-color-primary, #2563eb);--pfx-settings-panel-primary-container: var( --md-sys-color-primary-container, rgba(37, 99, 235, .14) );--pfx-settings-panel-on-primary-container: var( --md-sys-color-on-primary-container, #0f172a );--pfx-settings-panel-secondary: var( --md-sys-color-secondary, var(--pfx-settings-panel-primary) );--pfx-settings-panel-error: var(--md-sys-color-error, #b3261e);--pfx-settings-panel-error-container: var( --md-sys-color-error-container, rgba(179, 38, 30, .14) );--pfx-settings-panel-alert-bg: color-mix( in srgb, var(--pfx-settings-panel-error-container) 78%, var(--pfx-settings-panel-surface) );--pfx-settings-panel-alert-fg: var(--pfx-settings-panel-error);--pfx-settings-panel-scope-bg: var(--pfx-settings-panel-surface);--pfx-settings-panel-scope-fg: var(--pfx-settings-panel-on-surface-variant);--pfx-settings-panel-border-radius: 0px;--mat-divider-color: var(--pfx-settings-panel-outline-variant);--mat-expansion-container-background-color: var( --pfx-settings-panel-surface-container );--mat-expansion-container-text-color: var(--pfx-settings-panel-on-surface);--mat-expansion-header-text-color: var(--pfx-settings-panel-on-surface);--mat-expansion-header-description-color: var( --pfx-settings-panel-on-surface-variant );--mat-expansion-header-indicator-color: var( --pfx-settings-panel-on-surface-variant );--mat-button-toggle-selected-state-background-color: var( --pfx-settings-panel-primary-container );--mat-button-toggle-selected-state-text-color: var( --pfx-settings-panel-on-primary-container );display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:auto auto auto auto 1fr auto;grid-template-areas:\"header\" \"context-nav\" \"status\" \"alert\" \"body\" \"footer\";min-width:0;height:100%;max-width:var(--pfx-settings-panel-max-width, 100%);background:var(--pfx-settings-panel-surface-container);color:var(--pfx-settings-panel-on-surface);border-left:1px solid var(--pfx-settings-panel-outline-variant);border-radius:var(--pfx-settings-panel-border-radius, 0px);width:var(--pfx-settings-panel-width, 100%);box-sizing:border-box;box-shadow:var(--pfx-settings-panel-elevation, var(--md-sys-elevation-level2, 0 8px 24px rgba(0, 0, 0, .16)));overflow:hidden}praxis-settings-panel .settings-panel__resize-handle{position:absolute;inset:0 auto 0 0;width:12px;cursor:col-resize;touch-action:none;z-index:3;outline:none}praxis-settings-panel .settings-panel__resize-handle:before{content:\"\";position:absolute;inset:0 auto 0 4px;width:2px;background:transparent;transition:background-color var(--pfx-side-panel-motion-duration, .16s) ease,opacity var(--pfx-side-panel-motion-duration, .16s) ease;opacity:0}praxis-settings-panel .settings-panel.is-resizable:hover .settings-panel__resize-handle:before,praxis-settings-panel .settings-panel__resize-handle:focus-visible:before{opacity:1;background:var(--pfx-settings-panel-outline)}praxis-settings-panel .settings-panel-header{grid-area:header;display:flex;align-items:center;gap:var(--pfx-settings-panel-header-gap, 8px);padding:12px var(--pfx-settings-panel-header-padding-x, 20px);min-height:var(--pfx-settings-panel-header-height, 64px);border-bottom:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-high);box-shadow:var(--pfx-settings-panel-header-shadow, var(--md-sys-elevation-level1, 0 2px 6px rgba(0, 0, 0, .08)));flex-shrink:0;min-width:0;max-width:100%}praxis-settings-panel .settings-panel-header .spacer{flex:1 1 auto;min-width:0}praxis-settings-panel .settings-panel-context-nav{grid-area:context-nav;display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap;gap:8px 12px;padding:8px var(--pfx-settings-panel-header-padding-x, 20px);border-bottom:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-low);min-width:0;max-width:100%}praxis-settings-panel .settings-panel-context-nav__targets{display:flex;align-items:center;gap:4px;min-width:0;flex:1 1 200px}praxis-settings-panel .settings-panel-context-nav__target-select{flex:1 1 auto;min-width:0;min-height:34px;padding:4px 10px;border-radius:8px;border:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface);color:var(--pfx-settings-panel-on-surface);font:inherit;font-size:.84rem;font-weight:600}praxis-settings-panel .settings-panel-context-nav__modes{display:inline-flex;align-items:center;flex-wrap:wrap;gap:4px;padding:2px;max-width:100%;border-radius:999px;border:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface)}praxis-settings-panel .settings-panel-context-nav__mode-btn{appearance:none;border:none;background:transparent;color:var(--pfx-settings-panel-on-surface-variant);font:inherit;font-size:.78rem;font-weight:600;padding:5px 12px;border-radius:999px;white-space:nowrap;flex-shrink:0;cursor:pointer;transition:background-color .14s ease,color .14s ease}praxis-settings-panel .settings-panel-context-nav__mode-btn.is-active{background:var(--pfx-settings-panel-primary-container);color:var(--pfx-settings-panel-on-primary-container)}praxis-settings-panel .settings-panel-context-nav__mode-btn:disabled{opacity:.42;cursor:not-allowed}praxis-settings-panel .settings-panel-status{grid-area:status;display:flex;align-items:center;gap:8px;min-height:36px;padding:6px var(--pfx-settings-panel-status-padding-x, 20px);border-bottom:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-high);color:var(--pfx-settings-panel-on-surface);font-size:.85rem;font-weight:500;min-width:0;max-width:100%}praxis-settings-panel .settings-panel-status mat-icon{width:18px;height:18px;font-size:18px}praxis-settings-panel .settings-panel-status[data-status=dirty],praxis-settings-panel .settings-panel-status[data-status=invalid]{color:var(--pfx-settings-panel-error);background:color-mix(in srgb,var(--pfx-settings-panel-error-container) 30%,var(--pfx-settings-panel-surface-container-high))}praxis-settings-panel .settings-panel-status[data-status=saved]{color:var(--pfx-settings-panel-primary);background:color-mix(in srgb,var(--pfx-settings-panel-primary-container) 28%,var(--pfx-settings-panel-surface-container-high))}praxis-settings-panel .settings-panel-scope{display:inline-flex;align-items:center;flex-wrap:wrap;gap:6px;padding:2px 8px;border-radius:999px;border:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-scope-bg);color:var(--pfx-settings-panel-scope-fg);font-size:.75rem;font-weight:600}praxis-settings-panel .settings-panel-scope[data-scope=tenant]{border-color:color-mix(in srgb,var(--pfx-settings-panel-primary) 42%,var(--pfx-settings-panel-outline-variant));background:var(--pfx-settings-panel-primary-container);color:var(--pfx-settings-panel-on-primary-container)}praxis-settings-panel .settings-panel-scope__toggle,praxis-settings-panel .settings-panel-scope__reset{height:24px;line-height:22px;font-size:.72rem;padding:0 8px}praxis-settings-panel .settings-panel-save-error{grid-area:alert;display:flex;align-items:flex-start;gap:10px;padding:10px var(--pfx-settings-panel-status-padding-x, 20px);background:var(--pfx-settings-panel-alert-bg);color:var(--pfx-settings-panel-alert-fg);border-bottom:1px solid color-mix(in srgb,var(--pfx-settings-panel-error) 32%,var(--pfx-settings-panel-outline-variant));font-size:.82rem}praxis-settings-panel .settings-panel-save-error__content{flex:1 1 auto;min-width:0;display:flex;flex-direction:column;gap:4px}praxis-settings-panel .settings-panel-save-error__message{margin:0;font-weight:600;line-height:1.35}praxis-settings-panel .settings-panel-save-error:focus-visible,praxis-settings-panel .settings-panel-save-error:focus{outline:2px solid var(--pfx-settings-panel-error);outline-offset:-2px}praxis-settings-panel .settings-panel-save-error__detail{margin:0;font-size:.78rem;color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel-save-error__meta{margin:2px 0 0;display:flex;flex-wrap:wrap;gap:6px 12px;font-size:.72rem;font-family:ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel-save-error__fields{margin:2px 0 0;padding-inline-start:16px;font-size:.78rem;color:var(--pfx-settings-panel-on-surface-variant);display:flex;flex-direction:column;gap:2px}praxis-settings-panel .settings-panel-save-error__action{align-self:flex-start;margin-top:2px}praxis-settings-panel .settings-panel-body{grid-area:body;container-type:inline-size;overflow-y:auto;overflow-x:hidden;scroll-padding-top:var(--pfx-settings-panel-scroll-padding-start, 16px);scroll-padding-bottom:var(--pfx-settings-panel-scroll-padding-end, 88px);min-height:0;padding:var(--pfx-settings-panel-body-padding, 8px 16px 24px);background:var(--pfx-settings-panel-surface);display:flex;flex-direction:column;min-width:0;max-width:100%}praxis-settings-panel .settings-panel-body>*{min-width:0;max-width:100%}praxis-settings-panel .settings-panel-content{display:block;min-width:0;max-width:100%}praxis-settings-panel .settings-panel-content>*{min-width:0;max-width:100%;box-sizing:border-box}praxis-settings-panel .settings-panel-footer{grid-area:footer;border-top:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-high);box-shadow:var(--pfx-settings-panel-footer-shadow, var(--md-sys-elevation-level1, 0 -2px 6px rgba(0, 0, 0, .08)));display:flex;align-items:center;flex-wrap:wrap;padding:var(--pfx-settings-panel-footer-padding, 12px 20px);column-gap:var(--pfx-settings-panel-footer-gap, 12px);row-gap:8px;flex-shrink:0;min-width:0;max-width:100%}praxis-settings-panel .spacer{flex:1}praxis-settings-panel .settings-panel-title{display:inline-flex;align-items:center;flex:1 1 auto;gap:var(--pfx-settings-panel-title-gap, 8px);font-weight:700;line-height:1.2;letter-spacing:.2px;margin:0;min-width:0;overflow:visible;white-space:normal}praxis-settings-panel .settings-panel-title span{min-width:0;overflow:visible;white-space:normal}praxis-settings-panel .settings-panel-title mat-icon{color:var(--pfx-settings-panel-primary)}praxis-settings-panel .settings-panel-title .title-icon{width:20px;height:20px;font-size:20px}praxis-settings-panel .settings-panel-footer button{display:inline-flex;align-items:center}praxis-settings-panel .settings-panel-footer button .mat-icon{flex:0 0 20px;font-size:20px;width:20px;height:20px;line-height:1;display:inline-flex;align-items:center;justify-content:center;overflow:hidden}praxis-settings-panel .settings-panel-footer .mat-button-wrapper{display:inline-flex;align-items:center;gap:var(--pfx-settings-panel-button-gap, 8px)}praxis-settings-panel .settings-panel-footer .mat-progress-spinner{margin-right:8px}praxis-settings-panel .settings-panel-footer .mat-flat-button[color=primary]{font-weight:600}praxis-settings-panel .settings-panel-footer .mdc-button__label{display:inline-flex;align-items:center;gap:var(--pfx-settings-panel-button-gap, 8px);line-height:1}praxis-settings-panel .settings-panel-footer .mdc-button__label>span{display:inline-flex;align-items:center;line-height:1}praxis-settings-panel .settings-panel-footer .mdc-button__label .mat-icon{display:inline-flex;align-items:center;justify-content:center;line-height:1}@container settings-panel-shell (max-width: 520px){praxis-settings-panel .settings-panel-footer{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);align-items:stretch;padding:10px 12px;column-gap:8px}praxis-settings-panel .settings-panel-footer .spacer{display:none}praxis-settings-panel .settings-panel-footer button{justify-content:center;width:100%;min-width:0;min-height:44px;height:auto;padding:8px}praxis-settings-panel .settings-panel-action-label{white-space:normal;overflow-wrap:anywhere;text-align:center}praxis-settings-panel .settings-panel-footer .mdc-button__label{min-width:0;max-width:100%}praxis-settings-panel .settings-panel-footer .mdc-button__label>span{min-width:0;line-height:1.25}}@container settings-panel-shell (max-width: 280px){praxis-settings-panel .settings-panel-footer{grid-template-columns:minmax(0,1fr)}}praxis-settings-panel .settings-panel .mat-divider{background-color:var(--pfx-settings-panel-outline-variant)}praxis-settings-panel .settings-panel .mat-expansion-panel{background:var(--pfx-settings-panel-surface-container);border:1px solid var(--pfx-settings-panel-outline-variant);border-radius:var(--md-sys-shape-corner-medium, 12px);box-shadow:var(--md-sys-elevation-level1, 0 2px 8px rgba(0, 0, 0, .08));color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-expansion-panel-header{background:var(--pfx-settings-panel-surface-container);color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-content{color:var(--pfx-settings-panel-on-surface);flex-wrap:wrap;gap:4px 12px;min-width:0;overflow:visible}praxis-settings-panel .settings-panel .mat-expansion-panel:not(.mat-expanded) .mat-expansion-panel-header:hover{background:color-mix(in srgb,var(--pfx-settings-panel-surface-container-high) 84%,var(--pfx-settings-panel-primary) 16%)}praxis-settings-panel .settings-panel .mat-expansion-panel.mat-expanded>.mat-expansion-panel-header{background:var(--pfx-settings-panel-surface-container-high)}praxis-settings-panel .settings-panel .mat-expansion-panel-header mat-icon,praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-icon{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-title,praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-description{color:var(--pfx-settings-panel-on-surface);min-width:0;overflow:visible;white-space:normal}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-description{color:var(--pfx-settings-panel-on-surface-variant);flex-wrap:wrap;gap:8px}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-title>*,praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-description>*{color:inherit}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-title small,praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-panel-header-description small{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-indicator,praxis-settings-panel .settings-panel .mat-expansion-panel-header .mat-expansion-indicator:after{color:var(--pfx-settings-panel-on-surface-variant);border-color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-expansion-panel .mat-action-row{border-top-color:var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-low)}praxis-settings-panel .settings-panel .mat-accordion,praxis-settings-panel .settings-panel .mat-accordion .mat-expansion-panel-spacing{background:transparent}praxis-settings-panel .settings-panel .mat-expansion-panel-content,praxis-settings-panel .settings-panel .mat-expansion-panel-content-wrapper,praxis-settings-panel .settings-panel .mat-expansion-panel-body{background:var(--pfx-settings-panel-surface-container);color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-expansion-panel .mat-expansion-panel-body{padding:8px}praxis-settings-panel .settings-panel .mat-expansion-panel .mat-expansion-panel-body>*{color:inherit}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mat-mdc-tab-header{border-bottom:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-low)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab{min-width:0}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab .mdc-tab__text-label{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab:hover .mdc-tab__text-label,praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab:focus .mdc-tab__text-label{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab.mdc-tab--active .mdc-tab__text-label{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mat-mdc-tab-header-pagination{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mat-mdc-tab-header-pagination-chevron{border-color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mat-mdc-tab-header-pagination:not(.mat-mdc-tab-header-pagination-disabled):hover{background:color-mix(in srgb,var(--pfx-settings-panel-surface-container-high) 84%,var(--pfx-settings-panel-primary) 16%)}praxis-settings-panel .settings-panel .mat-mdc-tab-group .mdc-tab-indicator__content--underline{border-color:var(--pfx-settings-panel-primary)}praxis-settings-panel .settings-panel .mat-mdc-card{background:var(--pfx-settings-panel-surface-container-low);border:1px solid var(--pfx-settings-panel-outline-variant);color:var(--pfx-settings-panel-on-surface);box-shadow:var(--md-sys-elevation-level1, 0 2px 8px rgba(0, 0, 0, .08))}praxis-settings-panel .settings-panel .mat-mdc-card-subtitle{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-mdc-card-title,praxis-settings-panel .settings-panel .mat-mdc-card-content{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-form-field{width:100%;align-self:start;--mdc-filled-text-field-container-color: var( --pfx-settings-panel-surface-container );--mdc-filled-text-field-hover-container-color: var( --pfx-settings-panel-surface-container-high );--mdc-filled-text-field-focus-container-color: var( --pfx-settings-panel-surface-container-high );--mdc-filled-text-field-active-indicator-color: var( --pfx-settings-panel-outline-variant );--mdc-filled-text-field-hover-active-indicator-color: var( --pfx-settings-panel-secondary );--mdc-filled-text-field-focus-active-indicator-color: var( --pfx-settings-panel-primary );--mdc-filled-text-field-label-text-color: var( --pfx-settings-panel-on-surface-variant );--mdc-filled-text-field-focus-label-text-color: var( --pfx-settings-panel-primary );--mdc-filled-text-field-input-text-color: var( --pfx-settings-panel-on-surface );--mdc-filled-text-field-caret-color: var(--pfx-settings-panel-primary);--mdc-outlined-text-field-outline-color: var( --pfx-settings-panel-outline-variant );--mdc-outlined-text-field-hover-outline-color: var( --pfx-settings-panel-secondary );--mdc-outlined-text-field-focus-outline-color: var( --pfx-settings-panel-primary );--mdc-outlined-text-field-label-text-color: var( --pfx-settings-panel-on-surface-variant );--mdc-outlined-text-field-focus-label-text-color: var( --pfx-settings-panel-primary );--mdc-outlined-text-field-input-text-color: var( --pfx-settings-panel-on-surface );--mdc-outlined-text-field-caret-color: var(--pfx-settings-panel-primary);--mat-form-field-focus-select-arrow-color: var( --pfx-settings-panel-primary );--mat-form-field-enabled-select-arrow-color: var( --pfx-settings-panel-on-surface-variant )}praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-text-field-wrapper.mdc-text-field--filled,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled{background-color:var(--pfx-settings-panel-surface-container);border-radius:var(--md-sys-shape-corner-small, 8px) var(--md-sys-shape-corner-small, 8px) 0 0}praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled .mat-mdc-form-field-flex,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled .mat-mdc-form-field-infix,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled .mat-mdc-form-field-focus-overlay{background:var(--pfx-settings-panel-surface-container);color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-text-field-wrapper.mdc-text-field--outlined,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--outlined,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--outlined .mat-mdc-form-field-flex,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--outlined .mat-mdc-form-field-infix{background:transparent;background-color:transparent;color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-form-field-focus-overlay{opacity:0}praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled .mdc-floating-label,praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-select-placeholder,praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-select-arrow,praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-floating-label{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-select-value,praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-select-value-text,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled .mdc-text-field__input,praxis-settings-panel .settings-panel .mat-mdc-form-field input,praxis-settings-panel .settings-panel .mat-mdc-form-field textarea,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field__input{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--focused:not(.mdc-text-field--invalid) .mat-mdc-floating-label,praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--filled.mdc-text-field--focused .mdc-floating-label{color:var(--pfx-settings-panel-primary)}praxis-settings-panel .settings-panel .mat-mdc-form-field .mdc-text-field--invalid .mat-mdc-floating-label{color:var(--pfx-settings-panel-error)}praxis-settings-panel .settings-panel .mat-mdc-form-field-subscript-wrapper{position:relative;box-sizing:border-box}praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-form-field-hint-wrapper,praxis-settings-panel .settings-panel .mat-mdc-form-field .mat-mdc-form-field-error-wrapper{position:relative;top:auto;left:auto;right:auto;padding-top:4px;line-height:1.35}praxis-settings-panel .settings-panel .mat-mdc-form-field-bottom-align:before{display:none}praxis-settings-panel .settings-panel .mat-mdc-form-field-subscript-wrapper,praxis-settings-panel .settings-panel .mat-mdc-form-field-hint-wrapper,praxis-settings-panel .settings-panel .mat-mdc-form-field-error-wrapper,praxis-settings-panel .settings-panel .mat-mdc-hint{color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-button-toggle-group{border-color:var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-low)}praxis-settings-panel .settings-panel .mat-button-toggle{background:var(--pfx-settings-panel-surface-container-low);color:var(--pfx-settings-panel-on-surface-variant)}praxis-settings-panel .settings-panel .mat-button-toggle+.mat-button-toggle{border-left-color:var(--pfx-settings-panel-outline-variant)}praxis-settings-panel .settings-panel .mat-button-toggle-group .mat-button-toggle-checked{background:var(--pfx-settings-panel-primary-container);color:var(--pfx-settings-panel-on-primary-container)}praxis-settings-panel .settings-panel .mat-button-toggle .mat-icon,praxis-settings-panel .settings-panel .mat-button-toggle-checked .mat-icon{color:inherit}praxis-settings-panel .settings-panel .mat-mdc-slide-toggle .mdc-label{color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel .pfx-editor-section{box-sizing:border-box;width:100%;min-width:0;padding:16px;border-radius:16px;border:1px solid var(--pfx-settings-panel-outline-variant);background:var(--pfx-settings-panel-surface-container-low)}praxis-settings-panel .settings-panel .pfx-editor-subgroup{display:grid;gap:12px;padding-top:14px;border-top:1px solid color-mix(in srgb,var(--pfx-settings-panel-outline-variant) 70%,transparent)}praxis-settings-panel .settings-panel .pfx-editor-subgroup:first-child{padding-top:0;border-top:0}praxis-settings-panel .settings-panel .pfx-editor-grid-12{display:grid;grid-template-columns:repeat(12,minmax(0,1fr));gap:12px;min-width:0}praxis-settings-panel .settings-panel .pfx-editor-toggle-cluster{display:flex;flex-wrap:wrap;align-items:center;gap:12px 20px}.settings-panel{grid-template-columns:minmax(0,1fr);min-width:0;max-width:100%}.settings-panel-body{overflow-x:hidden;min-width:0}.settings-panel-body>*{min-width:0;max-width:100%}.praxis-settings-panel-backdrop{background:var(--pfx-settings-panel-backdrop, var(--pfx-backdrop, rgba(8, 15, 26, .42)));backdrop-filter:blur(var(--pfx-settings-panel-backdrop-blur, var(--pfx-backdrop-blur, 6px))) saturate(110%);-webkit-backdrop-filter:blur(var(--pfx-settings-panel-backdrop-blur, var(--pfx-backdrop-blur, 6px))) saturate(110%)}:is(.cdk-overlay-pane.praxis-settings-panel-pane,.praxis-settings-panel-pane){position:fixed;top:0;right:0;display:flex;align-items:stretch;height:100vh;max-width:var(--pfx-settings-panel-pane-max-width, 100vw);max-height:100vh;z-index:var(--pfx-settings-panel-z-index, var(--praxis-z-settings-panel, var(--praxis-layer-settings-panel, 1220)));transition:width var(--pfx-side-panel-motion-duration-enter, .3s) var(--pfx-side-panel-motion-easing-enter, ease)}.praxis-settings-panel-pane .settings-panel{pointer-events:auto}@media(prefers-reduced-motion:reduce){.praxis-settings-panel-pane{transition:none}}:is(.cdk-overlay-pane.praxis-settings-panel-pane.praxis-settings-panel-pane--preview,.praxis-settings-panel-pane.praxis-settings-panel-pane--preview){top:auto;bottom:12px;right:12px;height:auto;width:min(560px,100vw - 24px);min-width:0;transition:none}.praxis-settings-panel-backdrop.praxis-settings-panel-backdrop--preview{background:transparent;backdrop-filter:none;-webkit-backdrop-filter:none}.praxis-settings-preview-target{outline:2px solid var(--md-sys-color-primary);outline-offset:3px}praxis-settings-panel .settings-panel [hidden]{display:none}praxis-settings-panel .settings-panel .settings-panel-header[hidden],praxis-settings-panel .settings-panel .settings-panel-body[hidden],praxis-settings-panel .settings-panel .settings-panel-footer[hidden]{display:none}praxis-settings-panel .settings-panel--preview{height:auto;min-height:0;grid-template-rows:auto;border-radius:16px}praxis-settings-panel .settings-panel-preview-bar{display:flex;align-items:center;gap:16px;padding:16px;color:var(--pfx-settings-panel-on-surface)}praxis-settings-panel .settings-panel-preview-bar p{margin:4px 0 0;color:var(--pfx-settings-panel-on-surface-variant);font-size:.875rem}praxis-settings-panel .settings-panel-preview-bar button{flex-shrink:0}@container settings-panel-shell (max-width: 599px){praxis-settings-panel .settings-panel-header:not([hidden]){display:grid;grid-template-columns:minmax(0,1fr) auto auto;align-items:start}praxis-settings-panel .settings-panel-header .spacer{display:none}praxis-settings-panel .settings-panel-header .settings-panel-title{grid-column:1;grid-row:1;overflow-wrap:anywhere}praxis-settings-panel .settings-panel-header [data-testid=settings-panel-toggle-expand]{grid-column:2;grid-row:1}praxis-settings-panel .settings-panel-header [data-testid=settings-panel-close-icon]{grid-column:3;grid-row:1}praxis-settings-panel .settings-panel-header [data-testid=settings-panel-preview]{grid-column:1/-1;grid-row:2;justify-self:start;max-width:100%}praxis-settings-panel .settings-panel-preview-bar{flex-direction:column;align-items:stretch;gap:8px}}@media(prefers-reduced-transparency:reduce){.praxis-settings-panel-backdrop{backdrop-filter:none;-webkit-backdrop-filter:none;background:var(--pfx-backdrop-opaque, rgba(8, 15, 26, .72))}}@media(forced-colors:active){praxis-settings-panel .settings-panel{border:1px solid CanvasText;background:Canvas;color:CanvasText}praxis-settings-panel .settings-panel-save-error,praxis-settings-panel .settings-panel-scope{border:1px solid CanvasText;background:Canvas;color:CanvasText}.praxis-settings-panel-backdrop{backdrop-filter:none;-webkit-backdrop-filter:none;background:Canvas;opacity:.75}}\n"] }]
|
|
1417
1920
|
}], ctorParameters: () => [{ type: i0.ChangeDetectorRef }, { type: i1.MatDialog }, { type: i0.ElementRef }, { type: i1$1.OverlayContainer }], propDecorators: { focusTrap: [{
|
|
1418
1921
|
type: ViewChild,
|
|
1419
1922
|
args: [CdkTrapFocus]
|
|
1420
1923
|
}], contentHost: [{
|
|
1421
1924
|
type: ViewChild,
|
|
1422
1925
|
args: ['contentHost', { read: ViewContainerRef, static: true }]
|
|
1926
|
+
}], saveErrorBanner: [{
|
|
1927
|
+
type: ViewChild,
|
|
1928
|
+
args: ['saveErrorBanner']
|
|
1423
1929
|
}], handleKeydown: [{
|
|
1424
1930
|
type: HostListener,
|
|
1425
1931
|
args: ['document:keydown', ['$event']]
|
|
@@ -1439,14 +1945,18 @@ class SettingsPanelRef {
|
|
|
1439
1945
|
appliedSubject = new Subject();
|
|
1440
1946
|
savedSubject = new Subject();
|
|
1441
1947
|
resetSubject = new Subject();
|
|
1948
|
+
tenantBaselineRestoredSubject = new Subject();
|
|
1442
1949
|
closedSubject = new Subject();
|
|
1443
1950
|
sizeChangedSubject = new Subject();
|
|
1951
|
+
persistenceErrorSubject = new Subject();
|
|
1444
1952
|
sizePersistor;
|
|
1445
1953
|
applied$ = this.appliedSubject.asObservable();
|
|
1446
1954
|
saved$ = this.savedSubject.asObservable();
|
|
1447
1955
|
reset$ = this.resetSubject.asObservable();
|
|
1956
|
+
tenantBaselineRestored$ = this.tenantBaselineRestoredSubject.asObservable();
|
|
1448
1957
|
closed$ = this.closedSubject.asObservable();
|
|
1449
1958
|
sizeChanged$ = this.sizeChangedSubject.asObservable();
|
|
1959
|
+
persistenceError$ = this.persistenceErrorSubject.asObservable();
|
|
1450
1960
|
constructor(overlayRef) {
|
|
1451
1961
|
this.overlayRef = overlayRef;
|
|
1452
1962
|
}
|
|
@@ -1466,6 +1976,12 @@ class SettingsPanelRef {
|
|
|
1466
1976
|
reset() {
|
|
1467
1977
|
this.resetSubject.next();
|
|
1468
1978
|
}
|
|
1979
|
+
notifyTenantBaselineRestored(baseline) {
|
|
1980
|
+
this.tenantBaselineRestoredSubject.next(baseline);
|
|
1981
|
+
}
|
|
1982
|
+
reportPersistenceError(error) {
|
|
1983
|
+
this.persistenceErrorSubject.next(error);
|
|
1984
|
+
}
|
|
1469
1985
|
bindSizePersistor(fn) {
|
|
1470
1986
|
this.sizePersistor = fn;
|
|
1471
1987
|
}
|
|
@@ -1496,23 +2012,29 @@ class SettingsPanelRef {
|
|
|
1496
2012
|
this.appliedSubject.complete();
|
|
1497
2013
|
this.savedSubject.complete();
|
|
1498
2014
|
this.resetSubject.complete();
|
|
2015
|
+
this.tenantBaselineRestoredSubject.complete();
|
|
1499
2016
|
this.closedSubject.complete();
|
|
1500
2017
|
this.sizeChangedSubject.complete();
|
|
2018
|
+
this.persistenceErrorSubject.complete();
|
|
1501
2019
|
}
|
|
1502
2020
|
}
|
|
1503
2021
|
class DeferredSettingsPanelRef {
|
|
1504
2022
|
appliedSubject = new Subject();
|
|
1505
2023
|
savedSubject = new Subject();
|
|
1506
2024
|
resetSubject = new Subject();
|
|
2025
|
+
tenantBaselineRestoredSubject = new Subject();
|
|
1507
2026
|
closedSubject = new ReplaySubject(1);
|
|
1508
2027
|
sizeChangedSubject = new Subject();
|
|
2028
|
+
persistenceErrorSubject = new Subject();
|
|
1509
2029
|
target;
|
|
1510
2030
|
completed = false;
|
|
1511
2031
|
applied$ = this.appliedSubject.asObservable();
|
|
1512
2032
|
saved$ = this.savedSubject.asObservable();
|
|
1513
2033
|
reset$ = this.resetSubject.asObservable();
|
|
2034
|
+
tenantBaselineRestored$ = this.tenantBaselineRestoredSubject.asObservable();
|
|
1514
2035
|
closed$ = this.closedSubject.asObservable();
|
|
1515
2036
|
sizeChanged$ = this.sizeChangedSubject.asObservable();
|
|
2037
|
+
persistenceError$ = this.persistenceErrorSubject.asObservable();
|
|
1516
2038
|
resolve(target) {
|
|
1517
2039
|
if (this.completed) {
|
|
1518
2040
|
return;
|
|
@@ -1521,7 +2043,9 @@ class DeferredSettingsPanelRef {
|
|
|
1521
2043
|
target.applied$.subscribe((value) => this.appliedSubject.next(value));
|
|
1522
2044
|
target.saved$.subscribe((value) => this.savedSubject.next(value));
|
|
1523
2045
|
target.reset$.subscribe(() => this.resetSubject.next());
|
|
2046
|
+
target.tenantBaselineRestored$.subscribe((baseline) => this.tenantBaselineRestoredSubject.next(baseline));
|
|
1524
2047
|
target.sizeChanged$.subscribe((value) => this.sizeChangedSubject.next(value));
|
|
2048
|
+
target.persistenceError$.subscribe((error) => this.persistenceErrorSubject.next(error));
|
|
1525
2049
|
target.closed$.subscribe((reason) => {
|
|
1526
2050
|
this.closedSubject.next(reason);
|
|
1527
2051
|
this.complete();
|
|
@@ -1536,6 +2060,12 @@ class DeferredSettingsPanelRef {
|
|
|
1536
2060
|
reset() {
|
|
1537
2061
|
this.target?.reset();
|
|
1538
2062
|
}
|
|
2063
|
+
notifyTenantBaselineRestored(baseline) {
|
|
2064
|
+
this.target?.notifyTenantBaselineRestored(baseline);
|
|
2065
|
+
}
|
|
2066
|
+
reportPersistenceError(error) {
|
|
2067
|
+
this.target?.reportPersistenceError(error);
|
|
2068
|
+
}
|
|
1539
2069
|
bindSizePersistor(_fn) { }
|
|
1540
2070
|
setPreviewing(previewing) {
|
|
1541
2071
|
this.target?.setPreviewing(previewing);
|
|
@@ -1562,8 +2092,10 @@ class DeferredSettingsPanelRef {
|
|
|
1562
2092
|
this.appliedSubject.complete();
|
|
1563
2093
|
this.savedSubject.complete();
|
|
1564
2094
|
this.resetSubject.complete();
|
|
2095
|
+
this.tenantBaselineRestoredSubject.complete();
|
|
1565
2096
|
this.closedSubject.complete();
|
|
1566
2097
|
this.sizeChangedSubject.complete();
|
|
2098
|
+
this.persistenceErrorSubject.complete();
|
|
1567
2099
|
}
|
|
1568
2100
|
}
|
|
1569
2101
|
|
|
@@ -2259,6 +2791,8 @@ class SettingsPanelService {
|
|
|
2259
2791
|
if (config.canSwitchWriteScope !== undefined) {
|
|
2260
2792
|
panelRef.instance.canSwitchWriteScope = config.canSwitchWriteScope;
|
|
2261
2793
|
}
|
|
2794
|
+
panelRef.instance.persistSaveHandler = config.onSave;
|
|
2795
|
+
panelRef.instance.persistResetHandler = config.onReset;
|
|
2262
2796
|
panelRef.instance.previewTarget = config.previewTarget;
|
|
2263
2797
|
panelRef.instance.contextNavigation = config.contextNavigation;
|
|
2264
2798
|
this.currentPanelInstance = panelRef.instance;
|
|
@@ -2345,6 +2879,11 @@ function providePraxisSettingsPanelBridge() {
|
|
|
2345
2879
|
titleIcon: opts.titleIcon,
|
|
2346
2880
|
previewTarget: opts.previewTarget,
|
|
2347
2881
|
contextNavigation: opts.contextNavigation,
|
|
2882
|
+
configStorageKey: opts.configStorageKey,
|
|
2883
|
+
showWriteScope: opts.showWriteScope,
|
|
2884
|
+
canSwitchWriteScope: opts.canSwitchWriteScope,
|
|
2885
|
+
onSave: opts.onSave,
|
|
2886
|
+
onReset: opts.onReset,
|
|
2348
2887
|
content: {
|
|
2349
2888
|
component: opts.content.component,
|
|
2350
2889
|
inputs: (opts.content.inputs || undefined),
|