OK, I had some time to go back to the CSS refactoring again today to fix the issue where the application doesn’t work if you don’t have the optional CSS override files (oops…). Unfortunately SASS limitations make it slightly less elegant, but it’s still pretty easy. The branch has been updated. I’m going to open a pull request. New instructions on customizing (from the README):
If you want to customize the styles of your dashboard and widgets, there are two options:
A. You can edit the application.scss file (and the individual widget .scss files) directly (not recommended; if you pull down updates from the master repository, your changes might conflict/be overwritten)
B. Create override files (recommended)
Create a couple of additional files in the assets/stylesheets directory: _application_custom.scss and _variables_custom.scss.
Open _application.scss and go to the bottom of the file. Uncomment the @import line.
Open _variables.scss and go to the bottom of the file. Uncomment the @import line.
Write your own SASS styles in _application_custom.scss (for general style customization) and _variables_custom.scss (for colors). You can customize those files without worrying about your changes getting overwritten if you pull down an update. The most you may have to do, if you update, will be to uncomment the @import lines again from steps 2 and 3.
_Note: The _variables.scss file (and your customizations from _variables_custom.scss) get imported into nearly every widget’s SCSS file, so it is a best practice to define varaibles for colors in _variables.scss or variables_custom.scss and reference those variables in the widget SCSS.
Just quickly learned how to use github and not sure if this is the correct way to do it, but here you go.
This is a dumb version just to get the camera widget to work, many things is hard coded, including the camera api link, http and https, so pleae improve it if you can. I am not a programmer, just getting lucky to get all the code working.
Yes, I also used the link from my ip cam to get the jpg to test the script then I decided to use the api from HASS as not all my cameras support the jpg from weblink.
Huge thanks for this project! Absolutely brilliant!
Two questions: is it possible to get a 24 hr clock? I tried to edit the clock.coffee but nothing happened, even after restart (and re-run) of the Docker container. I’m now re-building the container but it takes forever and a day so I’d rather not be doing that every time I want to change something (I’m not well versed in neither Linux nor programming so I’m probably missing something obvious here). Second question, is it possible to use other icons than Font Awesome and how would I go about finding/adding those?
Is it normal that each time after dashing restart, the dashboard interface require 10+ secs to load again? The problem I got is that I have a routine to restart the Raspberry pi server everyday, so who ever try to use the dashboard the 1st time after the server restart will need to wait for the page to load before they can turn on any light.
It will be good if this process can be forced behind the scene as soon as dashing is restarted.
This is expected behavior - Dashing recompiles all the CSS the first time it is started. I am not aware of an easy way to fix this in the product itself, but you could try running a wget command against your dashboard shortly after startup to get the process running. You should be able to automate this via startup scripts or a cron job.
[quote=“kenshin, post:517, topic:1896, full:true”]
It works. I put wget --spider 192.168.0.100:3030 in the startup script. Thanks you. [/quote]
Actually the above didn’t work at the end, looks like the wget doesn’t trigger the page reload process, thinking to use schedule reload from here https://github.com/aelse/dashing-reload
Andrew - been falling behind on updates and was wondering how you determine your current version? I want to get back to the latest version but wanted to see if there were any breaking changes I missed before I did it.
Just pulles your cam widget from github… could u maybe explain further how to configure a cam in there? like an example? I have a pi running with motioneyeos through hass and it works like a charm now i would like to have dashboard with this cam stream.