diff --git a/Gruntfile.js b/Gruntfile.js index 8e3b23318..fbd73f33a 100644 --- a/Gruntfile.js +++ b/Gruntfile.js @@ -35,6 +35,13 @@ module.exports = function (grunt) { }, tasks: ['browserify:dev'], }, + html: { + files: ['<%= config.app %>/{,*/}*.html'], + options: { + livereload: '<%= connect.options.livereload %>' + }, + tasks: ['copy'], + }, gruntfile: { files: ['Gruntfile.js'] }, @@ -98,6 +105,7 @@ module.exports = function (grunt) { '<%= config.dist %>/scripts/background.js': ['<%= config.app %>/scripts/background.js'], '<%= config.dist %>/scripts/contentscript.js': ['<%= config.app %>/scripts/contentscript.js'], '<%= config.dist %>/scripts/inpage.js': ['<%= config.app %>/scripts/inpage.js'], + '<%= config.dist %>/scripts/popup.js': ['<%= config.app %>/scripts/popup.js'], }, }, dev: { @@ -108,6 +116,7 @@ module.exports = function (grunt) { '<%= config.dist %>/scripts/background.js': ['<%= config.app %>/scripts/background.js'], '<%= config.dist %>/scripts/contentscript.js': ['<%= config.app %>/scripts/contentscript.js'], '<%= config.dist %>/scripts/inpage.js': ['<%= config.app %>/scripts/inpage.js'], + '<%= config.dist %>/scripts/popup.js': ['<%= config.app %>/scripts/popup.js'], }, }, }, diff --git a/app/manifest.json b/app/manifest.json index d760eea0f..5d1df7b54 100644 --- a/app/manifest.json +++ b/app/manifest.json @@ -19,7 +19,8 @@ "19": "images/icon-19.png", "38": "images/icon-38.png" }, - "default_title": "metamask" + "default_title": "MetaMask", + "default_popup": "popup.html" }, "content_scripts": [ { diff --git a/app/popup.html b/app/popup.html new file mode 100644 index 000000000..b72d499d1 --- /dev/null +++ b/app/popup.html @@ -0,0 +1,24 @@ + + + + + Typo Blaster + + + + + + \ No newline at end of file diff --git a/app/scripts/background.js b/app/scripts/background.js index 429f7fb3e..b880b1b8c 100644 --- a/app/scripts/background.js +++ b/app/scripts/background.js @@ -4,14 +4,31 @@ const identitiesUrl = 'https://alpha.metamask.io/identities/' // var unsignedTxs = {} -var zeroClient = ZeroClientProvider({ +var zeroClient = new ZeroClientProvider({ rpcUrl: 'https://rawrpc.metamask.io/', }) -// setup badge click handler -chrome.browserAction.onClicked.addListener(function(activeTab) { - chrome.tabs.create({ url: identitiesUrl }) -}) +// // setup badge click handler +// chrome.browserAction.onClicked.addListener(function(activeTab) { +// // chrome.tabs.create({ url: identitiesUrl }) +// tabbernackle() +// }) + + +// function tabbernackle(){ +// chrome.tabs.create({ +// url: 'about:blank',//chrome.extension.getURL('dialog.html'), +// active: false +// }, function(tab) { +// // After the tab has been created, open a window to inject the tab +// chrome.windows.create({ +// tabId: tab.id, +// type: 'panel', +// focused: true +// // incognito, top, left, ... +// }); +// }); +// } // setup messaging chrome.runtime.onConnect.addListener(connectRemote) diff --git a/app/scripts/popup.js b/app/scripts/popup.js new file mode 100644 index 000000000..53dabeb33 --- /dev/null +++ b/app/scripts/popup.js @@ -0,0 +1 @@ +document.body.innerHTML = "real talk" \ No newline at end of file