I have made a template object "levelbar".
This object is working fine for me. But now I want to make it universally applicable, not only in one place but in several flows. So I want de style sheet migrate from "Widget in a group" to ."site section". Can anybody tell me what is the best way to make a "style"-object for this kind of template nodes, so I don't need a style sheet within de template node anymore?
[{"id":"99cfa91925e450ee","type":"ui_template","z":"7c6ad896ba8a384a","group":"1ee7777a616ea4cf","name":"test CSS","order":1,"width":8,"height":2,"format":"<head>\n <style>\n * {\n box-sizing: border-box;\n }\n\n .container {\n width: 100%;\n font-size: 80%;\n }\n\n .topic {\n font-size: 95%;\n font-weight: 500;\n color: #00cc66;\n }\n\n .val {\n width: 20%;\n text-align: right;\n font-weight: 700;\n background-color: #333333;\n float: left;\n }\n .accum {\n width: 20%;\n text-align: right;\n font-weight: 700;\n background-color: #333333;\n float: left;\n }\n\n .units {\n height: 0.8em;\n line-height: 2.5em;\n text-align: center;\n padding: 0;\n margin: 0;\n float: right;\n font-size: 65%;\n }\n\n .box {\n width: 60%;\n background-color: #544e4e;\n float: left;\n }\n\n .levelBox {\n padding-top: 7px;\n padding-bottom: 7px;\n }\n\n .levelGreen {\n background-color: #00B33C;\n }\n\n .levelRed {\n background-color: red;\n }\n\n </style>\n</head>\n\n<body>\n\n <p style=\"font-size: 100%; text-align: center;\">{{msg.title}}</p>\n\n <div class=\"container\">\n\n <p><span class=\"topic\">{{msg.topic}}</span></p>\n <div class=\"val\">\n <span>{{msg.val}} </span>\n <span class=\"units\">{{msg.valunit}} </span>\n </div>\n <div class=\"box\">\n <div class=\"levelBox levelRed\" style=\"width:{{msg.valperc}};\"></div>\n </div>\n <div class=\"accum\">\n <span>{{msg.accum}} </span>\n <span class=\"units\">{{msg.accumunit}} </span>\n </div>\n\n\n </div>\n \n</body>\n\n","storeOutMessages":false,"fwdInMessages":false,"resendOnRefresh":true,"templateScope":"local","className":"","x":960,"y":1220,"wires":[[]]},{"id":"dae74185e46cfec7","type":"function","z":"7c6ad896ba8a384a","name":"Prepare levelbar","func":"let val = msg.payload;\nlet scale = 2000;\nlet perc = (val / scale * 100).toString() + \"%\";\n\n\nmsg.title = \"test levelbar\";\nmsg.topic = \"Flow\";\nmsg.val = val;\nmsg.valperc = perc;\nmsg.valunit = \"L/h\";\nmsg.accum = 23.5;\nmsg.accumunit = \"m³\";\n\n\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","libs":[],"x":780,"y":1220,"wires":[["99cfa91925e450ee"]]},{"id":"4fe7e9250730fc37","type":"ui_slider","z":"7c6ad896ba8a384a","name":"","label":"slider","tooltip":"","group":"1ee7777a616ea4cf","order":2,"width":8,"height":1,"passthru":true,"outs":"all","topic":"topic","topicType":"msg","min":0,"max":"2000","step":1,"className":"","x":590,"y":1220,"wires":[["dae74185e46cfec7"]]},{"id":"1ee7777a616ea4cf","type":"ui_group","name":"Test CSS","tab":"ad12ad91.ab672","order":1,"disp":true,"width":"8","collapse":false,"className":""},{"id":"ad12ad91.ab672","type":"ui_tab","name":"Test","icon":"dashboard","disabled":false,"hidden":false}]