Freeboard / freeboard

A damn-sexy, open source real-time dashboard builder for IOT and other web mashups. A free open-source alternative to Geckoboard.
http://freeboard.io
MIT License
6.45k stars 1.2k forks source link

Cleaner separation of dashboard and editor #83

Open shannoncruey opened 9 years ago

shannoncruey commented 9 years ago

I'm loving Freeboard! I'm using it embedded in another application and it's suiting my needs very well.

However, by it's nature, certain things are sort of hardcoded (such as the assumption the editor will always be included in the markup) and it causes my integration to be less than perfect. One example: in freeboard.js around line 626 is this:

    if(!editing)
    {
        $("#toggle-header-icon").addClass("icon-wrench").removeClass("icon-chevron-up");
        $(".gridster .gs_w").css({cursor: "default"});
        $("#main-header").animate({"top": "-" + barHeight + "px"}, animateLength);

Every pixel is precious, and this code forces an inline style of top: 10 on #board-content which I can't override with a custom css.

I'd love to see an example of a "view only" board with no editor, padding, margins or inline styles. I've gotten close but struggled to get it perfect without editing the actual freeboard javascript.

How about separating the two, where the pure dashboard code has no additional styles or animations for the editor? I think this would allow much more seamless integration, and hopefully get more people using this great tool!

nzfarmer1 commented 9 years ago

+1 for this feature!

dr1999ara commented 2 years ago

After about 7 years, +10 for this feature from us who have never written a line of code in js :))