@types/chrome 0.2.6 → 0.2.7
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 +40 -1
- 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: Fri, 21 Aug 2026 19:38:26 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
|
@@ -4742,6 +4742,25 @@ declare namespace chrome {
|
|
|
4742
4742
|
*/
|
|
4743
4743
|
type CSSOrigin = "author" | "user";
|
|
4744
4744
|
|
|
4745
|
+
/**
|
|
4746
|
+
* Details of the CSS to remove. Either the code or the file property must be set, but both may not be set at the same time.
|
|
4747
|
+
* @since Chrome 87
|
|
4748
|
+
*/
|
|
4749
|
+
interface DeleteInjectionDetails {
|
|
4750
|
+
/** If allFrames is `true`, implies that the CSS should be removed from all frames of current page. By default, it's `false` and is only removed from the top frame. If `true` and `frameId` is set, then the code is removed from the selected frame and all of its child frames. */
|
|
4751
|
+
allFrames?: boolean;
|
|
4752
|
+
/** CSS code to remove. */
|
|
4753
|
+
code?: string;
|
|
4754
|
+
/** The origin of the CSS to remove. Defaults to `"author"`. */
|
|
4755
|
+
cssOrigin?: CSSOrigin;
|
|
4756
|
+
/** CSS file to remove. */
|
|
4757
|
+
file?: string;
|
|
4758
|
+
/** The frame from where the CSS should be removed. Defaults to 0 (the top-level frame). */
|
|
4759
|
+
frameId?: number;
|
|
4760
|
+
/** If matchAboutBlank is true, then the code is also removed from about:blank and about:srcdoc frames if your extension has access to its parent document. By default it is `false`. */
|
|
4761
|
+
matchAboutBlank?: boolean;
|
|
4762
|
+
}
|
|
4763
|
+
|
|
4745
4764
|
/**
|
|
4746
4765
|
* The document lifecycle of the frame.
|
|
4747
4766
|
* @since Chrome 106
|
|
@@ -11890,7 +11909,7 @@ declare namespace chrome {
|
|
|
11890
11909
|
* MV2 only
|
|
11891
11910
|
* @param tabId The ID of the tab in which to insert the CSS; defaults to the active tab of the current window.
|
|
11892
11911
|
* @param details Details of the CSS text to insert. Either the code or the file property must be set, but both may not be set at the same time.
|
|
11893
|
-
* @deprecated since Chrome
|
|
11912
|
+
* @deprecated since Chrome 91. Replaced by {@link scripting.insertCSS} in Manifest V3.
|
|
11894
11913
|
*/
|
|
11895
11914
|
function insertCSS(details: extensionTypes.InjectDetails): Promise<void>;
|
|
11896
11915
|
function insertCSS(tabId: number | undefined, details: extensionTypes.InjectDetails): Promise<void>;
|
|
@@ -11901,6 +11920,26 @@ declare namespace chrome {
|
|
|
11901
11920
|
callback: () => void,
|
|
11902
11921
|
): void;
|
|
11903
11922
|
|
|
11923
|
+
/**
|
|
11924
|
+
* Removes from a page CSS that was previously injected by a call to {@link tabs.insertCSS}.
|
|
11925
|
+
*
|
|
11926
|
+
* Can return its result via Promise in Manifest V3 or later since Chrome 88.
|
|
11927
|
+
*
|
|
11928
|
+
* MV2 only
|
|
11929
|
+
* @param tabId The ID of the tab from which to remove the CSS; defaults to the active tab of the current window.
|
|
11930
|
+
* @param details Details of the CSS text to remove. Either the code or the file property must be set, but both may not be set at the same time.
|
|
11931
|
+
* @since Chrome 87
|
|
11932
|
+
* @deprecated since Chrome 91. Replaced by {@link scripting.removeCSS} in Manifest V3.
|
|
11933
|
+
*/
|
|
11934
|
+
function removeCSS(details: extensionTypes.DeleteInjectionDetails): Promise<void>;
|
|
11935
|
+
function removeCSS(tabId: number | undefined, details: extensionTypes.DeleteInjectionDetails): Promise<void>;
|
|
11936
|
+
function removeCSS(details: extensionTypes.DeleteInjectionDetails, callback: () => void): void;
|
|
11937
|
+
function removeCSS(
|
|
11938
|
+
tabId: number | undefined,
|
|
11939
|
+
details: extensionTypes.DeleteInjectionDetails,
|
|
11940
|
+
callback: () => void,
|
|
11941
|
+
): void;
|
|
11942
|
+
|
|
11904
11943
|
/**
|
|
11905
11944
|
* Highlights the given tabs and focuses on the first of group. Will appear to do nothing if the specified tab is currently active.
|
|
11906
11945
|
*
|
chrome/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@types/chrome",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.7",
|
|
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": "47a32e4859f36cb5c33ad530ec591ce35a563d6725344169f0b57debde67a4d3",
|
|
98
98
|
"typeScriptVersion": "5.6"
|
|
99
99
|
}
|