Skip to content

Commit

Permalink
add known purpose enum
Browse files Browse the repository at this point in the history
  • Loading branch information
csmccarthy committed Dec 27, 2024
1 parent c720337 commit 6540bc7
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"author": "Transcend Inc.",
"name": "@transcend-io/airgap.js-types",
"description": "TypeScript types for airgap.js interoperability with custom consent UIs",
"version": "12.8.1",
"version": "12.9.0",
"homepage": "https://github.com/transcend-io/airgap.js-types",
"repository": {
"type": "git",
Expand Down
13 changes: 13 additions & 0 deletions src/enums/purpose.ts
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,19 @@ export const ConfigurablePurpose = makeEnum({
export type ConfigurablePurpose =
typeof ConfigurablePurpose[keyof typeof ConfigurablePurpose];

/**
* Purposes that can be configured
*/
export const KnownDefaultPurpose = makeEnum({
/** The request is necessary for the essential features of the website */
Essential: 'Essential',
...ConfigurablePurpose,
});

/** Type override */
export type KnownDefaultPurpose =
typeof KnownDefaultPurpose[keyof typeof KnownDefaultPurpose];

/**
* Purposes used by the purpose map
*/
Expand Down

0 comments on commit 6540bc7

Please sign in to comment.