1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-20 10:13:31 +00:00

update disabled domain terminology to blocked domain terminology

This commit is contained in:
Jonathan Prusik
2024-11-11 15:29:27 -05:00
parent fd9719c63b
commit 427db638b1
8 changed files with 55 additions and 54 deletions

View File

@@ -28,9 +28,10 @@ const NEVER_DOMAINS = new KeyDefinition(DOMAIN_SETTINGS_DISK, "neverDomains", {
deserializer: (value: NeverDomains) => value ?? null,
});
const DISABLED_INTERACTIONS_URIS = new KeyDefinition(
// Domain exclusion list for content script injections
const BLOCKED_INTERACTIONS_URIS = new KeyDefinition(
DOMAIN_SETTINGS_DISK,
"disabledInteractionsUris",
"blockedInteractionsUris",
{
deserializer: (value: NeverDomains) => value ?? null,
},
@@ -55,8 +56,8 @@ export abstract class DomainSettingsService {
setShowFavicons: (newValue: boolean) => Promise<void>;
neverDomains$: Observable<NeverDomains>;
setNeverDomains: (newValue: NeverDomains) => Promise<void>;
disabledInteractionsUris$: Observable<NeverDomains>;
setDisabledInteractionsUris: (newValue: NeverDomains) => Promise<void>;
blockedInteractionsUris$: Observable<NeverDomains>;
setBlockedInteractionsUris: (newValue: NeverDomains) => Promise<void>;
equivalentDomains$: Observable<EquivalentDomains>;
setEquivalentDomains: (newValue: EquivalentDomains, userId: UserId) => Promise<void>;
defaultUriMatchStrategy$: Observable<UriMatchStrategySetting>;
@@ -71,8 +72,8 @@ export class DefaultDomainSettingsService implements DomainSettingsService {
private neverDomainsState: GlobalState<NeverDomains>;
readonly neverDomains$: Observable<NeverDomains>;
private disabledInteractionsUrisState: GlobalState<NeverDomains>;
readonly disabledInteractionsUris$: Observable<NeverDomains>;
private blockedInteractionsUrisState: GlobalState<NeverDomains>;
readonly blockedInteractionsUris$: Observable<NeverDomains>;
private equivalentDomainsState: ActiveUserState<EquivalentDomains>;
readonly equivalentDomains$: Observable<EquivalentDomains>;
@@ -87,8 +88,8 @@ export class DefaultDomainSettingsService implements DomainSettingsService {
this.neverDomainsState = this.stateProvider.getGlobal(NEVER_DOMAINS);
this.neverDomains$ = this.neverDomainsState.state$.pipe(map((x) => x ?? null));
this.disabledInteractionsUrisState = this.stateProvider.getGlobal(DISABLED_INTERACTIONS_URIS);
this.disabledInteractionsUris$ = this.disabledInteractionsUrisState.state$.pipe(
this.blockedInteractionsUrisState = this.stateProvider.getGlobal(BLOCKED_INTERACTIONS_URIS);
this.blockedInteractionsUris$ = this.blockedInteractionsUrisState.state$.pipe(
map((x) => x ?? null),
);
@@ -109,8 +110,8 @@ export class DefaultDomainSettingsService implements DomainSettingsService {
await this.neverDomainsState.update(() => newValue);
}
async setDisabledInteractionsUris(newValue: NeverDomains): Promise<void> {
await this.disabledInteractionsUrisState.update(() => newValue);
async setBlockedInteractionsUris(newValue: NeverDomains): Promise<void> {
await this.blockedInteractionsUrisState.update(() => newValue);
}
async setEquivalentDomains(newValue: EquivalentDomains, userId: UserId): Promise<void> {