diff --git a/_locales/en/messages.json b/_locales/en/messages.json index 2cf4d1d7..caa72dec 100644 --- a/_locales/en/messages.json +++ b/_locales/en/messages.json @@ -153,6 +153,10 @@ "message": "Show number of styles active for the current site on the toolbar button", "description": "Label for the checkbox controlling toolbar badge text." }, + "prefSmartIndent": { + "message": "Use smart indentation", + "description": "Label for the checkbox controlling smart indentation option for the style editor." + }, "sectionAdd": { "message": "Add another section", "description": "Label for the button to add a section" diff --git a/apply.js b/apply.js index 5429a4ab..cba52c65 100644 --- a/apply.js +++ b/apply.js @@ -1,7 +1,7 @@ chrome.extension.sendMessage({method: "getStyles", matchUrl: location.href, enabled: true, asHash: true}, applyStyles); chrome.extension.onMessage.addListener(function(request, sender, sendResponse) { - switch(request.name) { + switch (request.method) { case "styleDeleted": removeStyle(request.id); break; diff --git a/background.js b/background.js index c78051e8..2bb02a8d 100644 --- a/background.js +++ b/background.js @@ -2,7 +2,7 @@ // why the content script also asks for this stuff. chrome.webNavigation.onCommitted.addListener(function(data) { getStyles({matchUrl: data.url, enabled: true, asHash: true}, function(styleHash) { - chrome.tabs.sendMessage(data.tabId, {name: "styleApply", styles: styleHash}); + chrome.tabs.sendMessage(data.tabId, {method: "styleApply", styles: styleHash}); // Don't show the badge for frames if (data.frameId == 0) { chrome.browserAction.setBadgeText({text: getBadgeText(Object.keys(styleHash)), tabId: data.tabId}); @@ -291,7 +291,7 @@ function saveFromJSONComplete(id, callback) { } function saveFromJSONStyleReloaded(updateType, style, callback) { - notifyAllTabs({name:updateType, style: style}); + notifyAllTabs({method: updateType, style: style}); if (callback) { callback(style); } diff --git a/edit.html b/edit.html index c4f6d2f9..4effcdc5 100644 --- a/edit.html +++ b/edit.html @@ -1,8 +1,8 @@ - - - + + + + + @@ -98,6 +100,10 @@

+
+

+ +

diff --git a/edit.js b/edit.js index 7b94add5..d6324f1c 100644 --- a/edit.js +++ b/edit.js @@ -15,15 +15,15 @@ sectionTemplate.innerHTML = '