1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-15 15:53:27 +00:00
Files
browser/libs/common/src/models/domain/domain-service.ts
Jonathan Prusik beeb0354fd [PM-7174] New Notifications Settings and Excluded Domains components (#10059)
* add v2 notification settings component

* adjust filenames for future deprecation

* drop popup tab navigation for the notification settings view

* add refreshed excluded domains component

* do not allow edits of pre-existing excluded domains

* fix buttonType on bit-link button
2024-07-19 12:36:09 -04:00

26 lines
992 B
TypeScript

/*
See full documentation at:
https://bitwarden.com/help/uri-match-detection/#match-detection-options
Domain: "the top-level domain and second-level domain of the URI match the detected resource",
Host: "the hostname and (if specified) port of the URI matches the detected resource",
StartsWith: "the detected resource starts with the URI, regardless of what follows it",
Exact: "the URI matches the detected resource exactly",
RegularExpression: "the detected resource matches a specified regular expression",
Never: "never offer auto-fill for the item",
*/
export const UriMatchStrategy = {
Domain: 0,
Host: 1,
StartsWith: 2,
Exact: 3,
RegularExpression: 4,
Never: 5,
} as const;
export type UriMatchStrategySetting = (typeof UriMatchStrategy)[keyof typeof UriMatchStrategy];
// using uniqueness properties of object shape over Set for ease of state storability
export type NeverDomains = { [id: string]: null };
export type EquivalentDomains = string[][];