c00000fd
c00000fd

Reputation: 22283

How to update my Chrome Extension's tooltip or description?

I'm curious if I can update the tooltip for my Chrome Extension from JS while the app is already running?

Or, what is set up in the manifest.json file in the description parameter, or the one that's displayed at mouse-over event over my app's icon:

enter image description here

PS. That is not my actual app.

Upvotes: 1

Views: 1364

Answers (1)

Xan
Xan

Reputation: 77541

Read the docs for browserAction API:

chrome.browserAction.setTitle(object details)

Sets the title of the browser action. This shows up in the tooltip.

Invocation:

chrome.browserAction.setTitle({title: "My New Title"});

You can optionally limit this update to a particular tabId.

P.S. In the manifest, this is normally set by browser_action.default_title.

Upvotes: 7

Related Questions