@types/chrome 0.0.210 → 0.0.211

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. chrome/README.md +1 -1
  2. chrome/index.d.ts +20 -0
  3. chrome/package.json +2 -2
chrome/README.md CHANGED
@@ -8,7 +8,7 @@ This package contains type definitions for Chrome extension development (http://
8
8
  Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/chrome.
9
9
 
10
10
  ### Additional Details
11
- * Last updated: Mon, 23 Jan 2023 22:02:42 GMT
11
+ * Last updated: Wed, 01 Feb 2023 20:32:42 GMT
12
12
  * Dependencies: [@types/filesystem](https://npmjs.com/package/@types/filesystem), [@types/har-format](https://npmjs.com/package/@types/har-format)
13
13
  * Global values: `chrome`
14
14
 
chrome/index.d.ts CHANGED
@@ -6303,6 +6303,11 @@ declare namespace chrome.permissions {
6303
6303
  addListener(callback: (permissions: Permissions) => void): void;
6304
6304
  }
6305
6305
 
6306
+ /**
6307
+ * Checks if the extension has the specified permissions.
6308
+ * @return A Promise that resolves with boolean: True if the extension has the specified permissions.
6309
+ */
6310
+ export function contains(permissions: Permissions): Promise<boolean>;
6306
6311
  /**
6307
6312
  * Checks if the extension has the specified permissions.
6308
6313
  * @param callback The callback parameter should be a function that looks like this:
@@ -6310,6 +6315,11 @@ declare namespace chrome.permissions {
6310
6315
  * Parameter result: True if the extension has the specified permissions.
6311
6316
  */
6312
6317
  export function contains(permissions: Permissions, callback: (result: boolean) => void): void;
6318
+ /**
6319
+ * Gets the extension's current set of permissions.
6320
+ * @return A Promise that resolves with Permissions object describing the extension's active permissions.
6321
+ */
6322
+ export function getAll(): Promise<Permissions>;
6313
6323
  /**
6314
6324
  * Gets the extension's current set of permissions.
6315
6325
  * @param callback The callback parameter should be a function that looks like this:
@@ -6317,6 +6327,11 @@ declare namespace chrome.permissions {
6317
6327
  * Parameter permissions: The extension's active permissions.
6318
6328
  */
6319
6329
  export function getAll(callback: (permissions: Permissions) => void): void;
6330
+ /**
6331
+ * Requests access to the specified permissions. These permissions must be defined in the optional_permissions field of the manifest. If there are any problems requesting the permissions, runtime.lastError will be set.
6332
+ * @return A Promise that resolves with boolean: True if the user granted the specified permissions.
6333
+ */
6334
+ export function request(permissions: Permissions): Promise<boolean>;
6320
6335
  /**
6321
6336
  * Requests access to the specified permissions. These permissions must be defined in the optional_permissions field of the manifest. If there are any problems requesting the permissions, runtime.lastError will be set.
6322
6337
  * @param callback If you specify the callback parameter, it should be a function that looks like this:
@@ -6324,6 +6339,11 @@ declare namespace chrome.permissions {
6324
6339
  * Parameter granted: True if the user granted the specified permissions.
6325
6340
  */
6326
6341
  export function request(permissions: Permissions, callback?: (granted: boolean) => void): void;
6342
+ /**
6343
+ * Removes access to the specified permissions. If there are any problems removing the permissions, runtime.lastError will be set.
6344
+ * @return A Promise that resolves with boolean: True if the permissions were removed.
6345
+ */
6346
+ export function remove(permissions: Permissions): Promise<boolean>;
6327
6347
  /**
6328
6348
  * Removes access to the specified permissions. If there are any problems removing the permissions, runtime.lastError will be set.
6329
6349
  * @param callback If you specify the callback parameter, it should be a function that looks like this:
chrome/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/chrome",
3
- "version": "0.0.210",
3
+ "version": "0.0.211",
4
4
  "description": "TypeScript definitions for Chrome extension development",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/chrome",
6
6
  "license": "MIT",
@@ -88,6 +88,6 @@
88
88
  "@types/filesystem": "*",
89
89
  "@types/har-format": "*"
90
90
  },
91
- "typesPublisherContentHash": "1b96144927e9fdbe3bbaea4b866d276a1c4a71b590a0c7df9b7662de34a0a16e",
91
+ "typesPublisherContentHash": "23719af7372ea8b3372a83987789fd3e0520ecad7ce7427143568da76aa3fb4b",
92
92
  "typeScriptVersion": "4.2"
93
93
  }