Show HN: Custom New Tab page for Firefox
github.com
github.com
For the record, you want to edit js/scripts/controllers.js and js/scripts/view/dashboard.html.
Replacing Helsinki in the openweathermap.org link with your plain text city name seems to work.
For Fahrenheit, replace the "var temp" line in controllers.js with:
var temp = Math.round(((parseInt(data.main.temp) - 273.15) * 9/5) + 32, 2) + "°F";
I didn't get the github.io pages working in less than a few minutes, so I just grabbed it locally where it'll probably work faster anyway. Thanks also for the great plugin link. Excellent work Jakke, beautiful typography. $scope.text = "Good " + $scope.getStateOfDay(moment().get('hour')) + ", today is " + moment().format('dddd MM/DD/YYYY') + ".";
which looks like 'Thursday 03/12/2015'; or you can change both lines to $scope.text = "Good " + $scope.getStateOfDay(moment().get('hour')) + ", today is " + moment().format('dddd, MMMM DD, YYYY') + ".";
which looks like 'Thursday, March 12, 2015'.- It doesn't work for FF on Android (I have never looked into it).
- It's true that setting browser.newtab.url does achieve similar functionality but only Custom-New-Tab properly places the focus!
- CNT can fix your "blanking the URL" problem. Check out the preferences.
Out of curiosity, why did you use Angular? For a simple, non-interactive page Angular seems like overkill.
Off topic: Thank you for the link to the Custom New Tab addon -- been thinking I wanted something like that in my Firefox but hadn't thought to actually look it up. That addon doesn't seem to work for current Firefox on Android, unfortunately. Btw, your link to the addon in your README makes the page show in Finnish, you might want to change your link to point to the English URL.
But what I'm missing most right now is a license file! Right now it's just copyrighted without giving anyone the permission to copy or modify it. I don't think that's your intention (If you don't want to think about it, the MIT licence is a good choice)
This is really slick- nice work!
EDIT: only works over HTTP, not HTTPS
Here's something I made, since your version doesn't work. It's a rip off of your work, but none of the code is taken and the temperature display works. It's much simpler, doesn't use any fancy JS, and is contained in 4 JS files including jquery and the quotes and the config.