@types/chrome 0.1.16 → 0.1.17
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- chrome/README.md +1 -1
- chrome/index.d.ts +38 -75
- chrome/package.json +2 -2
chrome/README.md
CHANGED
@@ -8,7 +8,7 @@ This package contains type definitions for chrome (https://developer.chrome.com/
|
|
8
8
|
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/chrome.
|
9
9
|
|
10
10
|
### Additional Details
|
11
|
-
* Last updated:
|
11
|
+
* Last updated: Wed, 01 Oct 2025 18:39:47 GMT
|
12
12
|
* Dependencies: [@types/filesystem](https://npmjs.com/package/@types/filesystem), [@types/har-format](https://npmjs.com/package/@types/har-format)
|
13
13
|
|
14
14
|
# Credits
|
chrome/index.d.ts
CHANGED
@@ -14103,27 +14103,26 @@ declare namespace chrome {
|
|
14103
14103
|
* If specified, the side panel options for the given tab will be returned.
|
14104
14104
|
* Otherwise, returns the default side panel options (used for any tab that doesn't have specific settings).
|
14105
14105
|
*/
|
14106
|
-
tabId?: number;
|
14106
|
+
tabId?: number | undefined;
|
14107
14107
|
}
|
14108
14108
|
|
14109
|
-
/**
|
14110
|
-
* @since Chrome 116
|
14111
|
-
*/
|
14109
|
+
/** @since Chrome 116 */
|
14112
14110
|
export type OpenOptions =
|
14113
14111
|
& {
|
14114
|
-
/**
|
14112
|
+
/**
|
14113
|
+
* The tab in which to open the side panel.
|
14115
14114
|
* If the corresponding tab has a tab-specific side panel, the panel will only be open for that tab.
|
14116
14115
|
* If there is not a tab-specific panel, the global panel will be open in the specified tab and any other tabs without a currently-open tab- specific panel.
|
14117
14116
|
* This will override any currently-active side panel (global or tab-specific) in the corresponding tab.
|
14118
|
-
* At least one of this and windowId must be provided. */
|
14119
|
-
tabId?: number;
|
14117
|
+
* At least one of this and `windowId` must be provided. */
|
14118
|
+
tabId?: number | undefined;
|
14120
14119
|
/**
|
14121
14120
|
* The window in which to open the side panel.
|
14122
|
-
* This is only applicable if the extension has a global (non-tab-specific) side panel or tabId is also specified.
|
14121
|
+
* This is only applicable if the extension has a global (non-tab-specific) side panel or `tabId` is also specified.
|
14123
14122
|
* This will override any currently-active global side panel the user has open in the given window.
|
14124
|
-
* At least one of this and tabId must be provided.
|
14123
|
+
* At least one of this and `tabId` must be provided.
|
14125
14124
|
*/
|
14126
|
-
windowId?: number;
|
14125
|
+
windowId?: number | undefined;
|
14127
14126
|
}
|
14128
14127
|
& ({
|
14129
14128
|
tabId: number;
|
@@ -14133,7 +14132,7 @@ declare namespace chrome {
|
|
14133
14132
|
|
14134
14133
|
export interface PanelBehavior {
|
14135
14134
|
/** Whether clicking the extension's icon will toggle showing the extension's entry in the side panel. Defaults to false. */
|
14136
|
-
openPanelOnActionClick?: boolean;
|
14135
|
+
openPanelOnActionClick?: boolean | undefined;
|
14137
14136
|
}
|
14138
14137
|
|
14139
14138
|
/** @since Chrome 140 */
|
@@ -14143,15 +14142,15 @@ declare namespace chrome {
|
|
14143
14142
|
|
14144
14143
|
export interface PanelOptions {
|
14145
14144
|
/** Whether the side panel should be enabled. This is optional. The default value is true. */
|
14146
|
-
enabled?: boolean;
|
14145
|
+
enabled?: boolean | undefined;
|
14147
14146
|
/** The path to the side panel HTML file to use. This must be a local resource within the extension package. */
|
14148
|
-
path?: string;
|
14147
|
+
path?: string | undefined;
|
14149
14148
|
/**
|
14150
14149
|
* If specified, the side panel options will only apply to the tab with this id.
|
14151
14150
|
* If omitted, these options set the default behavior (used for any tab that doesn't have specific settings).
|
14152
14151
|
* Note: if the same path is set for this tabId and the default tabId, then the panel for this tabId will be a different instance than the panel for the default tabId.
|
14153
14152
|
*/
|
14154
|
-
tabId?: number;
|
14153
|
+
tabId?: number | undefined;
|
14155
14154
|
}
|
14156
14155
|
|
14157
14156
|
/**
|
@@ -14177,84 +14176,48 @@ declare namespace chrome {
|
|
14177
14176
|
|
14178
14177
|
/**
|
14179
14178
|
* Returns the active panel configuration.
|
14180
|
-
*
|
14181
|
-
*
|
14182
|
-
*
|
14183
|
-
*/
|
14184
|
-
export function getOptions(
|
14185
|
-
|
14186
|
-
options: GetPanelOptions,
|
14187
|
-
callback: (options: PanelOptions) => void,
|
14188
|
-
): void;
|
14189
|
-
|
14190
|
-
export function getOptions(
|
14191
|
-
/** Specifies the context to return the configuration for. */
|
14192
|
-
options: GetPanelOptions,
|
14193
|
-
): Promise<PanelOptions>;
|
14179
|
+
*
|
14180
|
+
* Can return its result via Promise.
|
14181
|
+
* @param options Specifies the context to return the configuration for.
|
14182
|
+
*/
|
14183
|
+
export function getOptions(options: GetPanelOptions): Promise<PanelOptions>;
|
14184
|
+
export function getOptions(options: GetPanelOptions, callback: (options: PanelOptions) => void): void;
|
14194
14185
|
|
14195
14186
|
/**
|
14196
14187
|
* Returns the extension's current side panel behavior.
|
14197
|
-
*
|
14198
|
-
*
|
14199
|
-
* The promise resolves with the same type that is passed to the callback.
|
14188
|
+
*
|
14189
|
+
* Can return its result via Promise.
|
14200
14190
|
*/
|
14201
|
-
export function getPanelBehavior(
|
14202
|
-
callback: (behavior: PanelBehavior) => void,
|
14203
|
-
): void;
|
14204
|
-
|
14205
14191
|
export function getPanelBehavior(): Promise<PanelBehavior>;
|
14192
|
+
export function getPanelBehavior(callback: (behavior: PanelBehavior) => void): void;
|
14206
14193
|
|
14207
14194
|
/**
|
14208
|
-
* @since Chrome 116
|
14209
14195
|
* Opens the side panel for the extension. This may only be called in response to a user action.
|
14210
|
-
*
|
14211
|
-
*
|
14212
|
-
*
|
14196
|
+
*
|
14197
|
+
* Can return its result via Promise.
|
14198
|
+
* @param options Specifies the context in which to open the side panel.
|
14199
|
+
* @since Chrome 116
|
14213
14200
|
*/
|
14214
|
-
export function open(
|
14215
|
-
|
14216
|
-
options: OpenOptions,
|
14217
|
-
callback: () => void,
|
14218
|
-
): void;
|
14219
|
-
|
14220
|
-
export function open(
|
14221
|
-
/** Specifies the context in which to open the side panel. */
|
14222
|
-
options: OpenOptions,
|
14223
|
-
): Promise<void>;
|
14201
|
+
export function open(options: OpenOptions): Promise<void>;
|
14202
|
+
export function open(options: OpenOptions, callback: () => void): void;
|
14224
14203
|
|
14225
14204
|
/**
|
14226
14205
|
* Configures the side panel.
|
14227
|
-
*
|
14228
|
-
*
|
14229
|
-
*
|
14206
|
+
*
|
14207
|
+
* Can return its result via Promise.
|
14208
|
+
* @param options The configuration options to apply to the panel.
|
14230
14209
|
*/
|
14231
|
-
export function setOptions(
|
14232
|
-
|
14233
|
-
options: PanelOptions,
|
14234
|
-
callback: () => void,
|
14235
|
-
): void;
|
14236
|
-
|
14237
|
-
export function setOptions(
|
14238
|
-
/** The configuration options to apply to the panel. */
|
14239
|
-
options: PanelOptions,
|
14240
|
-
): Promise<void>;
|
14210
|
+
export function setOptions(options: PanelOptions): Promise<void>;
|
14211
|
+
export function setOptions(options: PanelOptions, callback: () => void): void;
|
14241
14212
|
|
14242
14213
|
/**
|
14243
14214
|
* Configures the extension's side panel behavior. This is an upsert operation.
|
14244
|
-
*
|
14245
|
-
*
|
14246
|
-
*
|
14215
|
+
*
|
14216
|
+
* Can return its result via Promise.
|
14217
|
+
* @param behavior The new behavior to be set.
|
14247
14218
|
*/
|
14248
|
-
export function setPanelBehavior(
|
14249
|
-
|
14250
|
-
behavior: PanelBehavior,
|
14251
|
-
callback: () => void,
|
14252
|
-
): void;
|
14253
|
-
|
14254
|
-
export function setPanelBehavior(
|
14255
|
-
/** The new behavior to be set. */
|
14256
|
-
behavior: PanelBehavior,
|
14257
|
-
): Promise<void>;
|
14219
|
+
export function setPanelBehavior(behavior: PanelBehavior): Promise<void>;
|
14220
|
+
export function setPanelBehavior(behavior: PanelBehavior, callback: () => void): void;
|
14258
14221
|
}
|
14259
14222
|
|
14260
14223
|
////////////////////
|
chrome/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@types/chrome",
|
3
|
-
"version": "0.1.
|
3
|
+
"version": "0.1.17",
|
4
4
|
"description": "TypeScript definitions for chrome",
|
5
5
|
"homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/chrome",
|
6
6
|
"license": "MIT",
|
@@ -94,6 +94,6 @@
|
|
94
94
|
"@types/har-format": "*"
|
95
95
|
},
|
96
96
|
"peerDependencies": {},
|
97
|
-
"typesPublisherContentHash": "
|
97
|
+
"typesPublisherContentHash": "6611bcded842c02d684735a90b3b71391663330da30a91d85cffb859330dabea",
|
98
98
|
"typeScriptVersion": "5.2"
|
99
99
|
}
|