@types/chrome 0.0.161 → 0.0.165

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 +40 -5
  3. chrome/package.json +3 -3
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: Sun, 24 Oct 2021 15:01:19 GMT
11
+ * Last updated: Tue, 30 Nov 2021 20:01:03 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
@@ -774,7 +774,7 @@ declare namespace chrome.browserAction {
774
774
 
775
775
  export interface BadgeTextDetails {
776
776
  /** Any number of characters can be passed, but only about four can fit in the space. */
777
- text?: string | undefined;
777
+ text?: string | null;
778
778
  /** Optional. Limits the change to when a particular tab is selected. Automatically resets when the tab is closed. */
779
779
  tabId?: number | undefined;
780
780
  }
@@ -2042,7 +2042,16 @@ declare namespace chrome.declarativeContent {
2042
2042
  constructor(options: PageStateMatcherProperties);
2043
2043
  }
2044
2044
 
2045
- /** Declarative event action that shows the extension's page action while the corresponding conditions are met. */
2045
+ /**
2046
+ * Declarative event action that enables the extension's action while the corresponding conditions are met.
2047
+ * Manifest v3.
2048
+ */
2049
+ export class ShowAction { }
2050
+
2051
+ /**
2052
+ * Declarative event action that shows the extension's page action while the corresponding conditions are met.
2053
+ * Manifest v2.
2054
+ */
2046
2055
  export class ShowPageAction { }
2047
2056
 
2048
2057
  /** Declarative event action that changes the icon of the page action while the corresponding conditions are met. */
@@ -2941,10 +2950,18 @@ declare namespace chrome.enterprise.platformKeys {
2941
2950
  id: string;
2942
2951
  /**
2943
2952
  * Implements the WebCrypto's SubtleCrypto interface. The cryptographic operations, including key generation, are hardware-backed.
2944
- * Only non-extractable RSASSA-PKCS1-V1_5 keys with modulusLength up to 2048 can be generated. Each key can be used for signing data at most once.
2953
+ * Only non-extractable RSASSA-PKCS1-V1_5 keys with modulusLength up to 2048 and ECDSA with namedCurve P-256 can be generated. Each key can be used for signing data at most once.
2945
2954
  * Keys generated on a specific Token cannot be used with any other Tokens, nor can they be used with window.crypto.subtle. Equally, Key objects created with window.crypto.subtle cannot be used with this interface.
2946
2955
  */
2947
2956
  subtleCrypto: SubtleCrypto;
2957
+ /**
2958
+ * Implements the WebCrypto's SubtleCrypto interface. The cryptographic operations, including key generation, are software-backed.
2959
+ * Protection of the keys, and thus implementation of the non-extractable property, is done in software, so the keys are less protected than hardware-backed keys.
2960
+ * Only non-extractable RSASSA-PKCS1-V1_5 keys with modulusLength up to 2048 can be generated. Each key can be used for signing data at most once.
2961
+ * Keys generated on a specific Token cannot be used with any other Tokens, nor can they be used with window.crypto.subtle. Equally, Key objects created with window.crypto.subtle cannot be used with this interface.
2962
+ * @since Chrome 97.
2963
+ */
2964
+ softwareBackedSubtleCrypto: SubtleCrypto;
2948
2965
  }
2949
2966
 
2950
2967
  /**
@@ -3074,6 +3091,14 @@ declare namespace chrome.enterprise.deviceAttributes {
3074
3091
  * @param callback Called with the Annotated Location of the device.
3075
3092
  */
3076
3093
  export function getDeviceAnnotatedLocation(callback: (annotatedLocation: string) => void): void;
3094
+ /**
3095
+ * @since Chrome 82.
3096
+ * @description
3097
+ * Fetches the device's hostname as set by DeviceHostnameTemplate policy.
3098
+ * If the current user is not affiliated or no hostname has been set by the the enterprise policy, returns an empty string.
3099
+ * @param callback Called with the hostname of the device.
3100
+ */
3101
+ export function getDeviceHostname(callback: (hostname: string) => void): void;
3077
3102
  }
3078
3103
 
3079
3104
  ////////////////////
@@ -10714,10 +10739,20 @@ declare namespace chrome.windows {
10714
10739
  }
10715
10740
 
10716
10741
  export interface WindowIdEvent
10717
- extends chrome.events.Event<(windowId: number, filters?: WindowEventFilter) => void> { }
10742
+ extends chrome.events.Event<(windowId: number) => void> {
10743
+ addListener(
10744
+ callback: (windowId: number) => void,
10745
+ filters?: WindowEventFilter,
10746
+ ): void;
10747
+ }
10718
10748
 
10719
10749
  export interface WindowReferenceEvent
10720
- extends chrome.events.Event<(window: Window, filters?: WindowEventFilter) => void> { }
10750
+ extends chrome.events.Event<(window: Window) => void> {
10751
+ addListener(
10752
+ callback: (window: Window) => void,
10753
+ filters?: WindowEventFilter,
10754
+ ): void;
10755
+ }
10721
10756
 
10722
10757
  /**
10723
10758
  * Specifies what type of browser window to create.
chrome/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/chrome",
3
- "version": "0.0.161",
3
+ "version": "0.0.165",
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",
@@ -98,6 +98,6 @@
98
98
  "@types/filesystem": "*",
99
99
  "@types/har-format": "*"
100
100
  },
101
- "typesPublisherContentHash": "5ce2fb452d2616bc8e715eab0fc861776fd281c290d911bb05426afd8c56fe21",
102
- "typeScriptVersion": "3.7"
101
+ "typesPublisherContentHash": "4a8618393a67775341d870f5bf2ae67d7e3e8cb773cc49410fffbe1a00bae61f",
102
+ "typeScriptVersion": "3.8"
103
103
  }