Skip to content
This repository has been archived by the owner on Dec 11, 2019. It is now read-only.

Extension API: chrome.i18n.getMessage #4755

Closed
jonathansampson opened this issue Oct 13, 2016 · 4 comments
Closed

Extension API: chrome.i18n.getMessage #4755

jonathansampson opened this issue Oct 13, 2016 · 4 comments
Labels
feature/extensions fixed-with-brave-core This issue will automatically resolved with the replacement of Muon with Brave Core. wontfix

Comments

@jonathansampson
Copy link
Collaborator

jonathansampson commented Oct 13, 2016

https://developer.chrome.com/extensions/i18n#method-getMessage

Blocks #8327, #6366, #9828

@jonathansampson
Copy link
Collaborator Author

jonathansampson commented Oct 13, 2016

I'm temporarily working around this issue by providing a stub with the methods I need. The following defines responses for predefined messages, and returns the message key for all other messages.

Browser.i18n = chrome.i18n || {
    getMessage: function (string) {
        switch (string) {
            case "@@extension_id":
                return "pioclpoplcdbaefihamjohnefbikjilc";
            case "@@ui_locale":
                return "en-US";
            case "@@bidi_dir":
                return "ltr";
            case "@@bidi_reversed_dir":
                return "rtl";
            case "@@bidi_start_edge":
                return "left"
            case "@@bidi_end_edge":
                return "right";
            default:
                return string.toString();
        }
    }
}

@cndouglas
Copy link

Related to/duplicate of #4474.

@jonathansampson jonathansampson changed the title Evernote: Cannot call chrome.i18n.getMessage (chrome.i18n is undefined) Extension APIs: chrome.i18n.getMessage May 10, 2017
@jonathansampson
Copy link
Collaborator Author

Reopening as we are now tracking these issues on a more granular level.

@jonathansampson jonathansampson mentioned this issue Jul 2, 2017
30 tasks
@jonathansampson jonathansampson changed the title Extension APIs: chrome.i18n.getMessage Extension API: chrome.i18n.getMessage Jul 2, 2017
@bsclifton bsclifton added this to the Triage Backlog milestone Nov 27, 2017
@bsclifton
Copy link
Member

I think it's fair to say we won't be implementing this. We'll get this for free when switching over to Brave Core. Marking as wontfix since the fix won't happen in browser-laptop

@bsclifton bsclifton added wontfix fixed-with-brave-core This issue will automatically resolved with the replacement of Muon with Brave Core. labels Jun 18, 2018
@bsclifton bsclifton removed this from the Triage Backlog milestone Jun 18, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
feature/extensions fixed-with-brave-core This issue will automatically resolved with the replacement of Muon with Brave Core. wontfix
Projects
None yet
Development

No branches or pull requests

3 participants