| Index: chrome/common/extensions/docs/static/activeTab.html
|
| diff --git a/chrome/common/extensions/docs/static/activeTab.html b/chrome/common/extensions/docs/static/activeTab.html
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..e56d6b0882290235e5963d18053bd6e3c939e64f
|
| --- /dev/null
|
| +++ b/chrome/common/extensions/docs/static/activeTab.html
|
| @@ -0,0 +1,30 @@
|
| +<div id="pageData-name" class="pageData">The activeTab permission</div>
|
| +
|
| +<p>
|
| +The <code>activeTab</code> permission allows extensions to access the active tab in response to user gestures like clicking an <a href="browserAction.html">extension button</a> or <a href="contextMenus.html">context menu item</a>.
|
| +</p>
|
| +
|
| +<p>
|
| +Many extensions only need access to a page in response to a user gesture on the extension. For example, consider a web clipping extension that has a browser action and context menu item. The extension doesn't need to run automatically on all pages, it only needs to run when one of its UI surfaces is acted upon.
|
| +</p>
|
| +
|
| +<p>
|
| +Without <code>activeTab</code> the extension would need to request both the <code><all_urls></code> and <code>tabs</code> permissions, showing a scary warning on installation. With <code>activeTab</code> none of that will be necessary.
|
| +</p>
|
| +
|
| +</p>
|
| +Formally, the <code>activeTab</code> permission allows an extension to use <a href="tabs.html#method-executeScript">tabs.executeScript</a> and <a href="tabs.html#method-insertCSS">tabs.insertCSS</a> on any tab the extension has been invoked on, including any frames with the same security origin. The permission lasts until the tab is navigated.
|
| +</p>
|
| +
|
| +<p>
|
| +The <code>activeTab</code> permission is activated whenever a piece of extension UI is acted upon by a user. At the time of writing, examples of such UI include:
|
| +<ul>
|
| + <li>clicking on an extension’s browser action,
|
| + <li>clicking on an extension’s page action,
|
| + <li>clicking on an extension’s script badge,
|
| + <li>accepting a suggestion from an extension’s omnibox,
|
| + <li>invoking an action from an extension’s context menu, and
|
| + <li>executing a command configured for an extension.
|
| +</ul>
|
| +But this list will grow over time as more types of extension UIs are added.
|
| +</p>
|
|
|