forked from GoogleChrome/chrome-extensions-samples
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
eslint: validate script imports (GoogleChrome#854)
Add https://github.com/import-js/eslint-plugin-import for validing script imports (eslint will fail if imported file does not exist). Also fixes prettier errors in api-samples.
- Loading branch information
1 parent
2b485f1
commit ad857a2
Showing
6 changed files
with
1,747 additions
and
74 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -173,7 +173,6 @@ <h2>Badge Text Color</h2> | |
</div> | ||
</section> | ||
|
||
|
||
<!-- badge - icon --> | ||
|
||
<section id="setIcon"> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,67 +1,74 @@ | ||
<!DOCTYPE html> | ||
<html lang="en"> | ||
<head> | ||
<meta charset="UTF-8"> | ||
<meta http-equiv="X-UA-Compatible" content="IE=edge"> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | ||
<title>Scripting Demo</title> | ||
<link rel="stylesheet" href="index.css"> | ||
<script defer src="index.js"></script> | ||
</head> | ||
<body> | ||
<form> | ||
<h1>Scripting Demo</h1> | ||
<div class="tabs"> | ||
<head> | ||
<meta charset="UTF-8" /> | ||
<meta http-equiv="X-UA-Compatible" content="IE=edge" /> | ||
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> | ||
<title>Scripting Demo</title> | ||
<link rel="stylesheet" href="index.css" /> | ||
<script defer src="index.js"></script> | ||
</head> | ||
<body> | ||
<form> | ||
<h1>Scripting Demo</h1> | ||
<div class="tabs"> | ||
<label> | ||
Dynamic | ||
<input type="radio" name="type" value="dynamic" checked /> | ||
</label> | ||
<label class="selected"> | ||
Programmatic | ||
<input type="radio" name="type" value="programmatic" /> | ||
</label> | ||
</div> | ||
<label> | ||
Dynamic | ||
<input type="radio" name="type" value="dynamic" checked></input> | ||
<span>Persist across sessions</span> | ||
<select name="persist" value="no"> | ||
<option value="no">No</option> | ||
<option value="yes">Yes</option> | ||
</select> | ||
</label> | ||
<label class="selected"> | ||
Programmatic | ||
<input type="radio" name="type" value="programmatic"></input> | ||
<label> | ||
<span>Run at</span> | ||
<select name="run-at" value="document_idle"> | ||
<option value="document_start">document_start</option> | ||
<option value="document_end">document_end</option> | ||
<option value="document_idle">document_idle</option> | ||
</select> | ||
</label> | ||
<label> | ||
<span>World</span> | ||
<select name="world" value="ISOLATED"> | ||
<option value="ISOLATED">ISOLATED</option> | ||
<option value="MAIN">MAIN</option> | ||
</select> | ||
</label> | ||
<label> | ||
<span>All Frames</span> | ||
<select name="all-frames" value="no"> | ||
<option value="no">No</option> | ||
<option value="yes">Yes</option> | ||
</select> | ||
</label> | ||
<label> | ||
<span>Matches</span> | ||
<input type="text" name="matches" value="https://example.com/*" /> | ||
</label> | ||
</div> | ||
<label> | ||
<span>Persist across sessions</span> | ||
<select name="persist" value="no"> | ||
<option value="no">No</option> | ||
<option value="yes">Yes</option> | ||
</select> | ||
</label> | ||
<label> | ||
<span>Run at</span> | ||
<select name="run-at" value="document_idle"> | ||
<option value="document_start">document_start</option> | ||
<option value="document_end">document_end</option> | ||
<option value="document_idle">document_idle</option> | ||
</select> | ||
</label> | ||
<label> | ||
<span>World</span> | ||
<select name="world" value="ISOLATED"> | ||
<option value="ISOLATED">ISOLATED</option> | ||
<option value="MAIN">MAIN</option> | ||
</select> | ||
</label> | ||
<label> | ||
<span>All Frames</span> | ||
<select name="all-frames" value="no"> | ||
<option value="no">No</option> | ||
<option value="yes">Yes</option> | ||
</select> | ||
</label> | ||
<label> | ||
<span>Matches</span> | ||
<input type="text" name="matches" value='https://example.com/*'> | ||
</label> | ||
<p class="hint">Note: Make sure you request the required <code>host_permissions</code> in the manifest.</p> | ||
<div class="buttons programmatic-buttons"> | ||
<button type="button" id="inject-programmatic">Execute Script</button> | ||
</div> | ||
<div class="buttons dynamic-buttons"> | ||
<button type="button" id="register-dynamic" disabled>Register Script</button> | ||
<button type="button" id="unregister-dynamic" disabled>Unregister Script</button> | ||
</div> | ||
</form> | ||
</body> | ||
<p class="hint"> | ||
Note: Make sure you request the required | ||
<code>host_permissions</code> in the manifest. | ||
</p> | ||
<div class="buttons programmatic-buttons"> | ||
<button type="button" id="inject-programmatic">Execute Script</button> | ||
</div> | ||
<div class="buttons dynamic-buttons"> | ||
<button type="button" id="register-dynamic" disabled> | ||
Register Script | ||
</button> | ||
<button type="button" id="unregister-dynamic" disabled> | ||
Unregister Script | ||
</button> | ||
</div> | ||
</form> | ||
</body> | ||
</html> |
Oops, something went wrong.