platypush/platypush/backend/http/dist/static/js/chunk-21660230.f7af277b.js.map
2021-01-22 01:00:49 +01:00

1 line
No EOL
83 KiB
Text

{"version":3,"sources":["webpack:///./src/components/elements/RangeSlider.vue?740c","webpack:///./node_modules/@babel/runtime/helpers/esm/classCallCheck.js","webpack:///./node_modules/@babel/runtime/helpers/esm/createClass.js","webpack:///./src/components/panels/Light/color.js","webpack:///./src/components/MenuPanel.vue?28db","webpack:///./src/components/Light/Animate.vue?0b31","webpack:///./src/components/Light/Groups.vue?c6f4","webpack:///./src/components/Light/Light.vue?969e","webpack:///./src/components/panels/Light/Index.vue?72b0","webpack:///./src/components/panels/Light/Index.vue?2196","webpack:///./src/components/Light/Controls.vue?05cb","webpack:///./src/components/panels/Light/Index.vue","webpack:///./src/components/panels/Panel.vue","webpack:///./src/components/panels/Panel.vue?ceb9","webpack:///./src/components/Light/Groups.vue","webpack:///./src/components/MenuPanel.vue","webpack:///./src/components/MenuPanel.vue?756e","webpack:///./src/components/Light/Groups.vue?aa79","webpack:///./src/components/Light/Group.vue","webpack:///./src/components/Light/Light.vue","webpack:///./src/components/Light/Controls.vue","webpack:///./src/components/Light/Controls.vue?0df1","webpack:///./src/components/Light/Light.vue?94a9","webpack:///./src/components/Light/Scene.vue","webpack:///./src/components/Light/Scene.vue?f920","webpack:///./src/components/Light/Animate.vue","webpack:///./src/components/elements/RangeSlider.vue","webpack:///./src/components/elements/RangeSlider.vue?f117","webpack:///./src/components/Light/Animate.vue?18be","webpack:///./src/components/Light/Group.vue?5271","webpack:///./src/components/panels/Light/Index.vue?5e61","webpack:///./src/components/Light/Group.vue?f50d","webpack:///./src/components/Light/Controls.vue?eb12","webpack:///./src/components/Light/Group.vue?7b21"],"names":["_classCallCheck","instance","Constructor","TypeError","_defineProperties","target","props","i","length","descriptor","enumerable","configurable","writable","Object","defineProperty","key","_createClass","protoProps","staticProps","prototype","ColorConverter","ranges","this","hue","sat","bri","ct","keys","attr","x","xRange","yRange","h","s","l","normalize","a","Math","min","f","n","k","color","max","round","r","g","b","d","parseInt","y","brightness","z","Y","toFixed","X","Z","red","green","blue","pow","isNaN","map","c","parseFloat","rgbToHsl","rgb","xy","getRGB","getXY","xyToRgb","hslToRgb","console","debug","rgbToXY","class","selectedGroup","groups","loading-groups","loadingGroups","color-converter","colorConverter","$event","$emit","group","lights","displayedLights","scenes","scenesByGroup","animations","animationsByGroup","name","emits","config","type","default","pluginName","String","required","data","loading","mounted","value","anyLightsOn","groupsSorted","id","state","any_on","disabled","render","components","ToggleSwitch","MenuPanel","computed","entries","sort","localeCompare","values","__scopeId","title","close","selectedView","lightsSorted","light","selectedLight","collapsed","scenesSorted","scene","selectedScene","onSceneSelected","running-animations","ref","expandToggle","on","stopPropagation","range","rgbColor","onColorSelect","Loading","Slider","Boolean","avg","Array","reduce","sum","obj","forEach","getColor","toRGB","hex","toString","join","methods","event","slice","split","t","hsl","rgbToBri","toXY","toHSL","Controls","onSelect","animationRunning","toggleAnimation","selectedAnimation","color_transition","hue_range","sat_range","bri_range","hue_step","sat_step","bri_step","transition_seconds","step","duration","checked","selectedLights","filter","v","toggleSelectAll","input","changed","mouseup","mousedown","getEvent","$refs","self","mixins","Utils","RangeSlider","runningAnimations","animation","lightId","blink","select","eventType","warn","Animate","Light","Scene","groupName","sceneId","Group","Groups","Panel","loadingLights","initialGroup","Number","initialized","groupsByLight","groupId","initSelectedGroup","unwatch","$watch","newVal","refresh","onLightChange","plugin_name","light_id","onAnimationChange","subscribe","unmounted","unsubscribe"],"mappings":"kHAAA,W,4KCAe,SAASA,EAAgBC,EAAUC,GAChD,KAAMD,aAAoBC,GACxB,MAAM,IAAIC,UAAU,qCCFxB,SAASC,EAAkBC,EAAQC,GACjC,IAAK,IAAIC,EAAI,EAAGA,EAAID,EAAME,OAAQD,IAAK,CACrC,IAAIE,EAAaH,EAAMC,GACvBE,EAAWC,WAAaD,EAAWC,aAAc,EACjDD,EAAWE,cAAe,EACtB,UAAWF,IAAYA,EAAWG,UAAW,GACjDC,O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A,EAAMiE,cAAgBpM,KAAK0E,WAG/B,GAAK1E,KAAK+D,OAAOoE,EAAMkE,UAAvB,CAKA,IAAMjH,EAAI,kBAAQ+C,GACZwC,EAAUvF,EAAMiH,gBACfjH,EAAMiH,gBACNjH,EAAMZ,YACNY,EAAMgH,YAEbpM,KAAK6D,MAAM,gBAAiB,CAC1BsB,GAAIwF,EACJvF,MAAOA,SAZPpF,KAAKkM,WAgBTI,kBAvCO,SAuCWnE,GACZA,EAAMiE,cAAgBpM,KAAK0E,YAG/B1E,KAAKkM,YAITnH,QAhLa,WAiLX/E,KAAKuM,UAAUvM,KAAKmM,cAAe,kBAC/B,wDACJnM,KAAKuM,UAAUvM,KAAKsM,kBAAmB,sBACnC,2DACA,4DAEJtM,KAAK8L,qBAGPU,UA1La,WA2LXxM,KAAKyM,YAAY,mBACjBzM,KAAKyM,YAAY,yB,oBmBlNrB,GAAOlH,OAAS,EAChB,GAAOS,UAAY,kBAEJ,iB,yDCTf,W,kCCAA,W,uGCAA","file":"static/js/chunk-21660230.f7af277b.js","sourcesContent":["export * from \"-!../../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--8-oneOf-1-0!../../../node_modules/css-loader/dist/cjs.js??ref--8-oneOf-1-1!../../../node_modules/vue-loader-v16/dist/stylePostLoader.js!../../../node_modules/postcss-loader/src/index.js??ref--8-oneOf-1-2!../../../node_modules/sass-loader/dist/cjs.js??ref--8-oneOf-1-3!../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../node_modules/vue-loader-v16/dist/index.js??ref--0-1!./RangeSlider.vue?vue&type=style&index=0&id=0e677180&lang=scss&scoped=true\"","export default function _classCallCheck(instance, Constructor) {\n if (!(instance instanceof Constructor)) {\n throw new TypeError(\"Cannot call a class as a function\");\n }\n}","function _defineProperties(target, props) {\n for (var i = 0; i < props.length; i++) {\n var descriptor = props[i];\n descriptor.enumerable = descriptor.enumerable || false;\n descriptor.configurable = true;\n if (\"value\" in descriptor) descriptor.writable = true;\n Object.defineProperty(target, descriptor.key, descriptor);\n }\n}\n\nexport default function _createClass(Constructor, protoProps, staticProps) {\n if (protoProps) _defineProperties(Constructor.prototype, protoProps);\n if (staticProps) _defineProperties(Constructor, staticProps);\n return Constructor;\n}","export class ColorConverter {\n constructor(ranges) {\n this.ranges = {\n hue: [0, 360],\n sat: [0, 100],\n bri: [0, 100],\n ct: [154, 500],\n }\n\n if (ranges)\n for (const attr of Object.keys(this.ranges))\n if (ranges[attr])\n this.ranges[attr] = ranges[attr]\n }\n\n normalize(x, xRange, yRange) {\n return yRange[0] + (((x-xRange[0]) * (yRange[1]-yRange[0])) / (xRange[1]-xRange[0]))\n }\n\n hslToRgb(h, s, l) {\n [h, s, l] = [\n this.normalize(h, this.ranges.hue, [0, 360]),\n this.normalize(s, this.ranges.sat, [0, 100]),\n this.normalize(l, this.ranges.bri, [0, 100]),\n ]\n\n l /= 100\n const a = s * Math.min(l, 1 - l) / 100\n const f = n => {\n const k = (n + h / 30) % 12\n const color = l - a * Math.max(Math.min(k - 3, 9 - k, 1), -1)\n return Math.round(255 * color)\n }\n\n return [f(0), f(8), f(4)]\n }\n\n rgbToHsl(r, g, b){\n r /= 255\n g /= 255\n b /= 255;\n const max = Math.max(r, g, b), min = Math.min(r, g, b);\n let h, s, l = (max + min) / 2;\n\n if(max === min){\n h = s = 0; // achromatic\n } else {\n const d = max - min;\n s = l > 0.5 ? d / (2 - max - min) : d / (max + min);\n\n switch(max){\n case r: h = (g - b) / d + (g < b ? 6 : 0); break;\n case g: h = (b - r) / d + 2; break;\n case b: h = (r - g) / d + 4; break;\n }\n h /= 6;\n }\n\n return [\n parseInt(this.normalize(h, [0, 1], this.ranges.hue)),\n parseInt(this.normalize(s, [0, 1], this.ranges.sat)),\n parseInt(this.normalize(l, [0, 1], this.ranges.bri)),\n ]\n }\n\n xyToRgb(x, y, brightness) {\n // Set to maximum brightness if no custom value was given (Not the slick ECMAScript 6 way for compatibility reasons)\n if (brightness == null)\n brightness = this.ranges.bri[1];\n\n const z = 1.0 - x - y;\n const Y = (brightness / (this.ranges.bri[1]-1)).toFixed(2);\n const X = (Y / y) * x;\n const Z = (Y / y) * z;\n\n //Convert to RGB using Wide RGB D65 conversion\n let red \t= X * 1.656492 - Y * 0.354851 - Z * 0.255038;\n let green = -X * 0.707196 + Y * 1.655397 + Z * 0.036152;\n let blue \t= X * 0.051713 - Y * 0.121364 + Z * 1.011530;\n\n //If red, green or blue is larger than 1.0 set it back to the maximum of 1.0\n if (red > blue && red > green && red > 1.0) {\n green = green / red;\n blue = blue / red;\n red = 1.0;\n } else if (green > blue && green > red && green > 1.0) {\n red = red / green;\n blue = blue / green;\n green = 1.0;\n } else if (blue > red && blue > green && blue > 1.0) {\n red = red / blue;\n green = green / blue;\n blue = 1.0;\n }\n\n //Reverse gamma correction\n red \t= red <= 0.0031308 ? 12.92 * red : (1.0 + 0.055) * Math.pow(red, (1.0 / 2.4)) - 0.055;\n green \t= green <= 0.0031308 ? 12.92 * green : (1.0 + 0.055) * Math.pow(green, (1.0 / 2.4)) - 0.055;\n blue \t= blue <= 0.0031308 ? 12.92 * blue : (1.0 + 0.055) * Math.pow(blue, (1.0 / 2.4)) - 0.055;\n\n //Convert normalized decimal to decimal\n red \t= Math.round(red * 255);\n green \t= Math.round(green * 255);\n blue \t= Math.round(blue * 255);\n\n if (isNaN(red))\n red = 0;\n if (isNaN(green))\n green = 0;\n if (isNaN(blue))\n blue = 0;\n\n return [red, green, blue].map((c) => Math.min(Math.max(0, c), 255))\n }\n\n rgbToXY(red, green, blue) {\n if (red > 1) { red /= 255; }\n if (green > 1) { green /= 255; }\n if (blue > 1) { blue /= 255; }\n\n //Apply a gamma correction to the RGB values, which makes the color more vivid and more the like the color displayed on the screen of your device\n red \t= (red > 0.04045) ? Math.pow((red + 0.055) / (1.0 + 0.055), 2.4) : (red / 12.92);\n green \t= (green > 0.04045) ? Math.pow((green + 0.055) / (1.0 + 0.055), 2.4) : (green / 12.92);\n blue \t= (blue > 0.04045) ? Math.pow((blue + 0.055) / (1.0 + 0.055), 2.4) : (blue / 12.92);\n\n //RGB values to XYZ using the Wide RGB D65 conversion formula\n const X \t\t= red * 0.664511 + green * 0.154324 + blue * 0.162028;\n const Y \t\t= red * 0.283881 + green * 0.668433 + blue * 0.047685;\n const Z \t\t= red * 0.000088 + green * 0.072310 + blue * 0.986039;\n\n //Calculate the xy values from the XYZ values\n let x \t\t= parseFloat((X / (X + Y + Z)).toFixed(4));\n let y \t\t= parseFloat((Y / (X + Y + Z)).toFixed(4));\n\n if (isNaN(x))\n x = 0;\n if (isNaN(y))\n y = 0;\n\n return [x, y];\n }\n\n rgbToBri(red, green, blue) {\n return Math.min(2 * this.rgbToHsl(red, green, blue)[2], this.ranges.bri[1])\n }\n\n getRGB(color) {\n if (color.red != null && color.green != null && color.blue != null)\n return [color.red, color.green, color.blue]\n if (color.r != null && color.g != null && color.b != null)\n return [color.r, color.g, color.b]\n if (color.rgb)\n return color.rgb\n }\n\n getXY(color) {\n if (color.x != null && color.y != null)\n return [color.x, color.y]\n if (color.xy)\n return color.xy\n }\n\n toRGB(color) {\n const rgb = this.getRGB(color)\n if (rgb)\n return rgb\n\n const xy = this.getXY(color)\n if (xy && color.bri)\n return this.xyToRgb(...xy, color.bri)\n if (color.hue && color.sat && color.bri)\n return this.hslToRgb(color.hue, color.sat, color.bri)\n\n console.debug('Could not determine color space')\n console.debug(color)\n }\n\n toXY(color) {\n const xy = this.getXY(color)\n if (xy && color.bri)\n return [xy[0], xy[1], color.bri]\n\n const rgb = this.getRGB(color)\n if (rgb)\n return this.rgbToXY(...rgb)\n\n if (color.hue && color.sat && color.bri) {\n const rgb = this.hslToRgb(color.hue, color.sat, color.bri)\n return this.rgbToXY(...rgb)\n }\n\n console.debug('Could not determine color space')\n console.debug(color)\n }\n\n toHSL(color) {\n if (color.hue && color.sat && color.bri)\n return [color.hue, color.sat, color.bri]\n\n const rgb = this.getRGB(color)\n if (rgb)\n return this.rgbToHsl(...rgb)\n\n const xy = this.getXY(color)\n if (xy && color.bri) {\n const rgb = this.xyToRgb(...xy, color.bri)\n return this.rgbToHsl(...rgb)\n }\n\n console.debug('Could not determine color space')\n console.debug(color)\n }\n}\n","export * from \"-!../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--8-oneOf-1-0!../../node_modules/css-loader/dist/cjs.js??ref--8-oneOf-1-1!../../node_modules/vue-loader-v16/dist/stylePostLoader.js!../../node_modules/postcss-loader/src/index.js??ref--8-oneOf-1-2!../../node_modules/sass-loader/dist/cjs.js??ref--8-oneOf-1-3!../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../node_modules/vue-loader-v16/dist/index.js??ref--0-1!./MenuPanel.vue?vue&type=style&index=0&lang=scss\"","export * from \"-!../../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--8-oneOf-1-0!../../../node_modules/css-loader/dist/cjs.js??ref--8-oneOf-1-1!../../../node_modules/vue-loader-v16/dist/stylePostLoader.js!../../../node_modules/postcss-loader/src/index.js??ref--8-oneOf-1-2!../../../node_modules/sass-loader/dist/cjs.js??ref--8-oneOf-1-3!../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../node_modules/vue-loader-v16/dist/index.js??ref--0-1!./Animate.vue?vue&type=style&index=0&id=1739aaba&lang=scss&scoped=true\"","export * from \"-!../../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--8-oneOf-1-0!../../../node_modules/css-loader/dist/cjs.js??ref--8-oneOf-1-1!../../../node_modules/vue-loader-v16/dist/stylePostLoader.js!../../../node_modules/postcss-loader/src/index.js??ref--8-oneOf-1-2!../../../node_modules/sass-loader/dist/cjs.js??ref--8-oneOf-1-3!../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../node_modules/vue-loader-v16/dist/index.js??ref--0-1!./Groups.vue?vue&type=style&index=0&id=42318a2b&lang=scss&scoped=true\"","export * from \"-!../../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--8-oneOf-1-0!../../../node_modules/css-loader/dist/cjs.js??ref--8-oneOf-1-1!../../../node_modules/vue-loader-v16/dist/stylePostLoader.js!../../../node_modules/postcss-loader/src/index.js??ref--8-oneOf-1-2!../../../node_modules/sass-loader/dist/cjs.js??ref--8-oneOf-1-3!../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../node_modules/vue-loader-v16/dist/index.js??ref--0-1!./Light.vue?vue&type=style&index=0&id=52168252&lang=scss&scoped=true\"","export * from \"-!../../../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--8-oneOf-1-0!../../../../node_modules/css-loader/dist/cjs.js??ref--8-oneOf-1-1!../../../../node_modules/vue-loader-v16/dist/stylePostLoader.js!../../../../node_modules/postcss-loader/src/index.js??ref--8-oneOf-1-2!../../../../node_modules/sass-loader/dist/cjs.js??ref--8-oneOf-1-3!../../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../../node_modules/vue-loader-v16/dist/index.js??ref--0-1!./Index.vue?vue&type=style&index=1&lang=scss\"","export * from \"-!../../../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--8-oneOf-1-0!../../../../node_modules/css-loader/dist/cjs.js??ref--8-oneOf-1-1!../../../../node_modules/vue-loader-v16/dist/stylePostLoader.js!../../../../node_modules/postcss-loader/src/index.js??ref--8-oneOf-1-2!../../../../node_modules/sass-loader/dist/cjs.js??ref--8-oneOf-1-3!../../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../../node_modules/vue-loader-v16/dist/index.js??ref--0-1!./Index.vue?vue&type=style&index=0&id=0378547e&lang=scss&scoped=true\"","export * from \"-!../../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--8-oneOf-1-0!../../../node_modules/css-loader/dist/cjs.js??ref--8-oneOf-1-1!../../../node_modules/vue-loader-v16/dist/stylePostLoader.js!../../../node_modules/postcss-loader/src/index.js??ref--8-oneOf-1-2!../../../node_modules/sass-loader/dist/cjs.js??ref--8-oneOf-1-3!../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../node_modules/vue-loader-v16/dist/index.js??ref--0-1!./Controls.vue?vue&type=style&index=0&id=e2726892&lang=scss&scoped=true\"","<template>\n <div class=\"plugin lights-plugin\">\n <div class=\"panel\" v-if=\"selectedGroup == null && groups && Object.keys(groups).length\">\n <Groups :groups=\"groups\" :loading-groups=\"loadingGroups\" :color-converter=\"colorConverter\"\n @select=\"selectedGroup = $event\" @toggle=\"$emit('group-toggle', $event)\" />\n </div>\n <div class=\"panel\" v-else>\n <Group :group=\"groups[selectedGroup]\" :lights=\"displayedLights\" :scenes=\"scenesByGroup[selectedGroup]\"\n :color-converter=\"colorConverter\" :animations=\"animationsByGroup[selectedGroup]\" @close=\"selectedGroup = null\"\n @light-toggle=\"$emit('light-toggle', $event)\" @group-toggle=\"$emit('group-toggle', $event)\"\n @set-light=\"$emit('set-light', $event)\"\n @set-group=\"$emit('set-group', {groupId: selectedGroup, value: $event})\"\n @select-scene=\"$emit('select-scene', {groupId: selectedGroup, sceneId: $event})\"\n @start-animation=\"$emit('start-animation', $event)\" @stop-animation=\"$emit('stop-animation', $event)\" />\n </div>\n </div>\n</template>\n\n<script>\nimport Utils from \"@/Utils\";\nimport Panel from \"@/components/panels/Panel\";\nimport Groups from \"@/components/Light/Groups\";\nimport Group from \"@/components/Light/Group\";\nimport {ColorConverter} from \"@/components/panels/Light/color\";\n\n/**\n * Generic component for light plugins panels.\n */\nexport default {\n name: \"Light\",\n components: {Group, Groups},\n mixins: [Utils, Panel],\n emits: ['group-toggle', 'light-toggle', 'set-light', 'set-group', 'select-scene', 'start-animation', 'stop-animation',\n 'refresh', 'light-changed'],\n\n props: {\n lights: {\n type: Object,\n },\n\n groups: {\n type: Object,\n },\n\n scenes: {\n type: Object,\n },\n\n animations: {\n type: Object,\n },\n\n colorConverter: {\n type: Object,\n default: () => new ColorConverter(),\n },\n\n loadingLights: {\n type: Object,\n default: () => {},\n },\n\n loadingGroups: {\n type: Object,\n default: () => {},\n },\n\n pluginName: {\n type: String,\n },\n\n initialGroup: {\n type: [Number, String],\n },\n },\n\n data() {\n return {\n selectedGroup: null,\n initialized: false,\n }\n },\n\n computed: {\n displayedLights() {\n const selectedGroup = this.selectedGroup || this.initialGroup\n if (selectedGroup == null)\n return this.lights\n\n return this.groups[selectedGroup].lights.reduce((lights, lightId) => {\n lights[lightId] = this.lights[lightId]\n return lights\n }, {})\n },\n\n groupsByLight() {\n if (!this.groups)\n return {}\n\n return Object.entries(this.groups).reduce((obj, [groupId, group]) => {\n group.lights.forEach((lightId) => {\n if (!obj[lightId])\n obj[lightId] = {}\n obj[lightId][groupId] = group\n })\n\n return obj\n }, {})\n },\n\n scenesByGroup() {\n if (!this.scenes)\n return {}\n\n const self = this\n return Object.entries(this.scenes).reduce((obj, [sceneId, scene]) => {\n scene.lights.forEach((lightId) => {\n Object.keys(self.groupsByLight[lightId]).forEach((groupId) => {\n if (!obj[groupId])\n obj[groupId] = {}\n\n obj[groupId][sceneId] = scene\n })\n })\n\n return obj\n }, {})\n },\n\n animationsByGroup() {\n const self = this\n const animations = Object.entries(this.animations?.groups || {}).reduce((obj, [groupId, animation]) => {\n obj[groupId] = {}\n if (animation)\n obj[groupId][null] = animation\n\n return obj\n }, {})\n\n return {\n ...animations,\n ...Object.entries(this.animations?.lights || {}).reduce((obj, [lightId, animation]) => {\n const group = Object.values(self.groupsByLight[lightId])?.[0]\n if (group) {\n if (animation && group.id != null) {\n if (!obj[group.id])\n obj[group.id] = {}\n obj[group.id][lightId] = animation\n }\n }\n\n return obj\n }, {})\n }\n }\n },\n\n methods: {\n initSelectedGroup() {\n const self = this\n const unwatch = this.$watch(() => self.initialGroup, (newVal) => {\n if (!self.initialized) {\n self.initialized = true\n unwatch()\n if (self.selectedGroup == null && newVal != null) {\n self.selectedGroup = self.initialGroup\n }\n }\n })\n },\n\n refresh() {\n this.$emit('refresh')\n },\n\n onLightChange(event) {\n if (event.plugin_name !== this.pluginName)\n return\n\n if (!this.lights[event.light_id]) {\n this.refresh()\n return\n }\n\n const state = {...event}\n const lightId = state.light_id\n delete state.light_id\n delete state.type\n delete state.plugin_name\n\n this.$emit('light-changed', {\n id: lightId,\n state: state,\n })\n },\n\n onAnimationChange(event) {\n if (event.plugin_name !== this.pluginName)\n return\n\n this.refresh()\n },\n },\n\n mounted() {\n this.subscribe(this.onLightChange, 'on-light-change',\n 'platypush.message.event.light.LightStatusChangeEvent')\n this.subscribe(this.onAnimationChange, 'on-animation-change',\n 'platypush.message.event.light.LightAnimationStartedEvent',\n 'platypush.message.event.light.LightAnimationStoppedEvent')\n\n this.initSelectedGroup()\n },\n\n unmounted() {\n this.unsubscribe('on-light-change')\n this.unsubscribe('on-animation-change')\n },\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.plugin {\n width: 100%;\n height: 100%;\n display: flex;\n}\n\n.panel {\n width: 100%;\n height: 100%;\n box-shadow: none;\n overflow: auto;\n}\n</style>\n\n<style lang=\"scss\">\n.lights-plugin {\n .menu-panel {\n ul {\n li:not(.header) {\n padding: 1.5em 1em;\n }\n }\n }\n}\n</style>","<script>\nexport default {\n name: \"Panel\",\n emits: ['mounted'],\n props: {\n // Plugin configuration.\n config: {\n type: Object,\n default: () => {},\n },\n\n // Plugin name.\n pluginName: {\n type: String,\n required: true,\n },\n },\n\n data() {\n return {\n loading: false,\n }\n },\n\n mounted() {\n this.$emit('mounted', this)\n }\n}\n</script>\n","import script from \"./Panel.vue?vue&type=script&lang=js\"\nexport * from \"./Panel.vue?vue&type=script&lang=js\"\n\nexport default script","<template>\n <MenuPanel>\n <div class=\"panel-row header\">\n <div class=\"col-3\">\n <i class=\"icon fas fa-home\" />\n </div>\n <div class=\"col-6 name\">\n Rooms\n </div>\n <div class=\"col-3 pull-right\">\n <ToggleSwitch :value=\"anyLightsOn\" @input=\"$emit('toggle')\" />\n </div>\n </div>\n\n <div class=\"panel-row row group\" v-for=\"group in groupsSorted\" :key=\"group.id\" @click=\"$emit('select', group.id)\">\n <span class=\"name col-9\">\n {{ group.name || `[Group ${group.id}]` }}\n </span>\n <span class=\"controls col-3 pull-right\">\n <ToggleSwitch :value=\"group.state.any_on\" :disabled=\"group.id in (loadingGroups || {})\"\n @input=\"$emit('toggle', group)\" />\n </span>\n </div>\n </MenuPanel>\n</template>\n\n<script>\nimport MenuPanel from \"@/components/MenuPanel\";\nimport ToggleSwitch from \"@/components/elements/ToggleSwitch\";\nimport {ColorConverter} from \"@/components/panels/Light/color\";\n\nexport default {\n name: \"Groups\",\n components: {ToggleSwitch, MenuPanel},\n emits: ['select', 'toggle'],\n props: {\n groups: {\n type: Object,\n default: () => {},\n },\n\n loadingGroups: {\n type: Object,\n default: () => {},\n },\n\n colorConverter: {\n type: Object,\n default: () => new ColorConverter(),\n },\n },\n\n computed: {\n groupsSorted() {\n return Object.entries(this.groups)\n .sort((a, b) => a[1].name.localeCompare(b[1].name))\n .map(([id, group]) => {\n return {\n ...group,\n id: id,\n }\n })\n },\n\n anyLightsOn() {\n for (const group of Object.values(this.groups))\n if (group?.state?.any_on)\n return true\n\n return false\n },\n },\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.header {\n display: flex;\n align-items: center;\n padding-top: 0.75em !important;\n padding-bottom: 0.75em !important;\n\n .icon {\n margin-left: 0.5em;\n }\n\n .name {\n text-align: center;\n }\n}\n\n.group {\n display: flex;\n align-items: center;\n}\n</style>\n","<template>\n <div class=\"menu-panel\">\n <div class=\"content\">\n <slot />\n </div>\n </div>\n</template>\n\n<script>\nexport default {\n name: \"MenuPanel\",\n}\n</script>\n\n<style lang=\"scss\">\n.menu-panel {\n width: 100%;\n height: 100%;\n display: flex;\n flex-direction: column;\n align-items: center;\n background: $menu-panel-bg;\n padding-top: 2em;\n\n .content {\n background: $menu-panel-content-bg;\n border-radius: 15px;\n box-shadow: $plugin-panel-shadow;\n border: 0;\n\n .panel-row {\n display: flex;\n margin: 0 !important;\n padding: 1em;\n box-shadow: $plugin-panel-entry-shadow;\n cursor: pointer;\n border: 0;\n letter-spacing: 0.05em;\n\n &:hover {\n background: $hover-bg;\n }\n\n &:first-child {\n border-radius: 15px 15px 0 0;\n box-shadow: $plugin-panel-first-entry-shadow;\n }\n\n &:last-child {\n border-radius: 0 0 15px 15px;\n box-shadow: $plugin-panel-last-entry-shadow;\n }\n }\n\n .header {\n background: $menu-header-bg;\n font-weight: bold;\n box-shadow: $menu-header-shadow;\n\n &:hover {\n background: $menu-header-bg;\n }\n }\n }\n}\n\n@media screen and (max-width: $desktop) {\n .menu-panel {\n padding-top: 0;\n\n .content {\n min-width: 100%;\n\n .row {\n &:first-child {\n border-radius: 0;\n }\n\n &:last-child {\n border-radius: 0;\n }\n }\n }\n }\n}\n\n@media screen and (min-width: $desktop) {\n .menu-panel {\n .content {\n min-width: 75%;\n }\n }\n}\n\n@media screen and (min-width: $widescreen) {\n .menu-panel {\n .content {\n min-width: 50%;\n }\n }\n}\n\n@media screen and (min-width: $fullhd) {\n .menu-panel {\n .content {\n min-width: 35%;\n }\n }\n}\n</style>\n","import { render } from \"./MenuPanel.vue?vue&type=template&id=02113104&bindings={}\"\nimport script from \"./MenuPanel.vue?vue&type=script&lang=js\"\nexport * from \"./MenuPanel.vue?vue&type=script&lang=js\"\n\nimport \"./MenuPanel.vue?vue&type=style&index=0&lang=scss\"\nscript.render = render\n\nexport default script","import { render } from \"./Groups.vue?vue&type=template&id=42318a2b&scoped=true&bindings={\\\"groups\\\":\\\"props\\\",\\\"loadingGroups\\\":\\\"props\\\",\\\"colorConverter\\\":\\\"props\\\",\\\"groupsSorted\\\":\\\"options\\\",\\\"anyLightsOn\\\":\\\"options\\\"}\"\nimport script from \"./Groups.vue?vue&type=script&lang=js\"\nexport * from \"./Groups.vue?vue&type=script&lang=js\"\n\nimport \"./Groups.vue?vue&type=style&index=0&id=42318a2b&lang=scss&scoped=true\"\nscript.render = render\nscript.__scopeId = \"data-v-42318a2b\"\n\nexport default script","<template>\n <div class=\"light-group-container\">\n <MenuPanel>\n <div class=\"panel-row header\">\n <div class=\"col-3\" v-if=\"group\">\n <button class=\"back-btn\" title=\"Back\" @click=\"close\">\n <i class=\"fas fa-chevron-left\" />\n </button>\n </div>\n\n <div class=\"col-6 name\" :class=\"{selected: selectedView === 'group'}\"\n v-text=\"groupName\" @click=\"selectedView = selectedView === 'group' ? null : 'group'\" />\n\n <div class=\"col-3 pull-right\" v-if=\"group\">\n <ToggleSwitch :value=\"group.state.any_on\" @input=\"$emit('group-toggle', group)\" />\n </div>\n </div>\n\n <div class=\"no-lights\" v-if=\"!lights || !Object.keys(lights).length\">\n No lights found\n </div>\n\n <div class=\"lights-view\" v-else>\n <div class=\"row view-selector\">\n <button :class=\"{selected: selectedView === 'lights'}\" title=\"Lights\" @click=\"selectedView = 'lights'\">\n <i class=\"icon fas fa-lightbulb\" />\n </button>\n <button :class=\"{selected: selectedView === 'scenes'}\" title=\"Scenes\" @click=\"selectedView = 'scenes'\">\n <i class=\"icon far fa-image\" />\n </button>\n <button :class=\"{selected: selectedView === 'animate'}\" title=\"Animate\" @click=\"selectedView = 'animate'\">\n <i class=\"icon fas fa-video\" />\n </button>\n </div>\n\n <div class=\"view fade-in\" v-if=\"selectedView === 'lights'\">\n <keep-alive>\n <div class=\"panel-row row\" :class=\"{expanded: light.id === selectedLight}\"\n v-for=\"(light, id) in lightsSorted\" :key=\"id\"\n @click=\"selectedLight = selectedLight === light.id ? null : light.id\">\n <Light :light=\"light\" :group=\"group\" :collapsed=\"light.id !== selectedLight\"\n :color-converter=\"colorConverter\" @toggle=\"$emit('light-toggle', light)\"\n @set-light=\"$emit('set-light', {light: light, value: $event})\" />\n </div>\n </keep-alive>\n </div>\n\n <div class=\"view fade-in\" v-else-if=\"selectedView === 'scenes'\">\n <keep-alive>\n <div class=\"panel-row row\" :class=\"{selected: scene.id === selectedScene}\"\n v-for=\"(scene, id) in scenesSorted\" :key=\"id\" @click=\"onSceneSelected(scene.id)\">\n <Scene :scene=\"scene\" :group=\"group\" />\n </div>\n </keep-alive>\n </div>\n\n <div class=\"view group-controls fade-in\" v-else-if=\"selectedView === 'group'\">\n <keep-alive>\n <Controls :group=\"group\" :lights=\"lights\" :color-converter=\"colorConverter\"\n @set-group=\"$emit('set-group', $event)\" />\n </keep-alive>\n </div>\n\n <div class=\"view group-controls fade-in\" v-else-if=\"selectedView === 'animate'\">\n <keep-alive>\n <Animate :group=\"group\" :lights=\"lights\" :color-converter=\"colorConverter\" :running-animations=\"animations\"\n @start=\"$emit('start-animation', $event)\" @stop=\"$emit('stop-animation', $event)\" />\n </keep-alive>\n </div>\n </div>\n </MenuPanel>\n </div>\n</template>\n\n<script>\nimport Light from \"@/components/Light/Light\";\nimport Scene from \"@/components/Light/Scene\";\nimport Controls from \"@/components/Light/Controls\";\nimport MenuPanel from \"@/components/MenuPanel\";\nimport ToggleSwitch from \"@/components/elements/ToggleSwitch\";\nimport {ColorConverter} from \"@/components/panels/Light/color\";\nimport Animate from \"@/components/Light/Animate\";\n\nexport default {\n name: \"Group\",\n emits: ['close', 'group-toggle', 'light-toggle', 'set-light', 'select-scene', 'start-animation', 'stop-animation'],\n components: {Animate, ToggleSwitch, MenuPanel, Light, Scene, Controls},\n props: {\n lights: {\n type: Object,\n },\n\n group: {\n type: Object,\n },\n\n scenes: {\n type: Object,\n },\n\n animations: {\n type: Object,\n default: () => {},\n },\n\n colorConverter: {\n type: Object,\n default: () => new ColorConverter(),\n },\n },\n\n data() {\n return {\n selectedLight: null,\n selectedScene: null,\n selectedView: 'lights',\n }\n },\n\n computed: {\n lightsSorted() {\n if (!this.lights)\n return []\n\n return Object.entries(this.lights)\n .sort((a, b) => a[1].name.localeCompare(b[1].name))\n .map(([id, light]) => {\n return {\n ...light,\n id: id,\n }\n })\n },\n\n scenesSorted() {\n if (!this.scenes)\n return []\n\n return Object.entries(this.scenes)\n .sort((a, b) => a[1].name.localeCompare(b[1].name))\n .map(([id, scene]) => {\n return {\n ...scene,\n id: id,\n }\n })\n },\n\n groupName() {\n if (this.group?.name)\n return this.group.name\n if (this.group?.id != null)\n return `[Group ${this.group.id}]`\n return 'Lights'\n },\n },\n\n methods: {\n close(event) {\n event.stopPropagation()\n this.$emit('close')\n },\n\n onSceneSelected(sceneId) {\n this.selectedScene = sceneId\n this.$emit('select-scene', sceneId)\n },\n },\n}\n</script>\n\n<style lang=\"scss\">\n.light-group-container {\n width: 100%;\n min-height: 100%;\n\n .row.panel-row {\n flex-direction: column;\n\n &.expanded,\n &.selected {\n background: $selected-bg;\n }\n }\n\n .header {\n padding: 0.5em !important;\n display: flex;\n align-items: center;\n\n .back-btn {\n border: 0;\n background: none;\n\n &:hover {\n border: 0;\n color: $default-hover-fg;\n }\n }\n\n .name {\n text-align: center;\n\n &.selected {\n color: $selected-fg;\n }\n\n &:hover {\n color: $default-hover-fg;\n }\n }\n }\n\n .view-selector {\n width: 100%;\n border-radius: 0;\n\n button {\n width: 33.3%;\n padding: 1.5em;\n text-align: left;\n opacity: 0.8;\n box-shadow: $plugin-panel-entry-shadow;\n border-right: 0;\n\n &.selected {\n background: $selected-bg;\n }\n\n &:hover {\n background: $hover-bg;\n }\n }\n\n .icon {\n width: 100%;\n text-align: center;\n font-size: 1.2em;\n }\n }\n}\n</style>\n\n<style lang=\"scss\">\n.light-group-container {\n .group-controls {\n margin: 0;\n padding: 1em;\n background-color: $default-bg-6;\n border-radius: 0 0 1em 1em;\n\n .controls {\n margin: 0;\n padding: 1em;\n }\n }\n}\n</style>\n","<template>\n <div class=\"light\" :class=\"{expanded: !collapsed}\" ref=\"element\">\n <div class=\"row\">\n <span class=\"name col-9\" @click=\"expandToggle\">\n {{ light.name || `[Light ${light.id}]` }}\n </span>\n <span class=\"toggle col-3 pull-right\">\n <ToggleSwitch :value=\"light.state.on\" :disabled=\"loading\" @input=\"$emit('toggle', light)\" />\n </span>\n </div>\n\n <div class=\"row fade-in\" v-if=\"!collapsed\">\n <Controls :light=\"light\" :loading=\"loading\" :color-converter=\"colorConverter\"\n @set-light=\"$emit('set-light', $event)\" />\n </div>\n </div>\n</template>\n\n<script>\nimport ToggleSwitch from \"@/components/elements/ToggleSwitch\";\nimport Controls from \"@/components/Light/Controls\";\nimport {ColorConverter} from \"@/components/panels/Light/color\";\n\nexport default {\n name: \"Light\",\n components: {Controls, ToggleSwitch},\n emits: ['toggle', 'set-light', 'collapsed', 'expanded'],\n props: {\n light: {\n type: Object,\n default: () => {},\n },\n\n group: {\n type: Object,\n default: () => {},\n },\n\n loading: {\n type: Boolean,\n default: false,\n },\n\n collapsed: {\n type: Boolean,\n default: true,\n },\n\n colorConverter: {\n type: Object,\n default: () => new ColorConverter(),\n },\n },\n\n methods: {\n expandToggle() {\n this.$emit(this.collapsed ? 'expanded' : 'collapsed')\n },\n },\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.expanded {\n .name {\n font-size: 1.25em;\n }\n}\n</style>\n","<template>\n <div class=\"controls light-controls\" @click=\"$event.stopPropagation()\">\n <Loading v-if=\"loading\" />\n\n <div class=\"row\" v-if=\"state.bri != null\">\n <div class=\"col-1 icon\">\n <i class=\"fas fa-sun\" />\n </div>\n <div class=\"col-11 control\">\n <Slider :range=\"colorConverter.ranges.bri\" :disabled=\"loading\" :value=\"state.bri\"\n @mouseup.stop=\"$emit(light ? 'set-light' : 'set-group', {brightness: parseInt($event.target.value)})\" />\n </div>\n </div>\n\n <div class=\"row\" v-if=\"state.ct != null\">\n <div class=\"col-1 icon\">\n <i class=\"fas fa-thermometer-half\" />\n </div>\n <div class=\"col-11 control\">\n <Slider :range=\"colorConverter.ranges.ct\" :disabled=\"loading\" :value=\"state.ct\"\n @mouseup.stop=\"$emit(light ? 'set-light' : 'set-group', {temperature: parseInt($event.target.value)})\" />\n </div>\n </div>\n\n <label class=\"row\" v-if=\"rgbColor\">\n <span class=\"col-1 icon\">\n <i class=\"fas fa-palette\" />\n </span>\n <span class=\"col-11 control\">\n <input type=\"color\" :value=\"rgbColor\" @change.stop=\"onColorSelect\" />\n </span>\n </label>\n </div>\n</template>\n\n<script>\nimport Slider from \"@/components/elements/Slider\";\nimport Loading from \"@/components/Loading\";\nimport {ColorConverter} from \"@/components/panels/Light/color\";\n\nexport default {\n name: \"Controls\",\n components: {Loading, Slider},\n emits: ['set-light', 'set-group'],\n props: {\n light: {\n type: Object,\n },\n\n lights: {\n type: Object,\n },\n\n group: {\n type: Object,\n },\n\n loading: {\n type: Boolean,\n default: false,\n },\n\n colorConverter: {\n type: Object,\n default: () => new ColorConverter(),\n },\n },\n\n computed: {\n state() {\n if (this.light?.state)\n return this.light.state\n\n const state = this.group?.state || {}\n if (!this.lights)\n return state\n\n const avg = (values) => {\n if (!(values && values.length))\n return 0\n\n if (values[0] instanceof Array)\n return [...values[0].keys()].map((i) => {\n return avg(values.map((value) => value[i]))\n })\n\n return values.reduce((sum, value) => sum+value, 0) / values.length\n }\n\n return {\n ...state,\n ...Object.entries(\n Object.values(this.lights).reduce((obj, light) => {\n ['bri', 'hue', 'sat', 'rgb', 'xy', 'red', 'green', 'blue', 'ct'].forEach((attr) => {\n if (light.state?.[attr] != null) {\n obj[attr] = [...(obj[attr] || []), light.state[attr]]\n }\n })\n\n return obj\n }, {})\n ).reduce((obj, [attr, values]) => {\n obj[attr] = avg(values)\n return obj\n }, {})\n }\n },\n\n color() {\n return this.getColor(this.state)\n },\n\n rgbColor() {\n const rgb = this.colorConverter.toRGB(this.state)\n if (rgb)\n return '#' + rgb.map((x) => {\n let hex = x.toString(16)\n if (hex.length < 2)\n hex = '0' + hex\n return hex\n }).join('')\n\n return null\n },\n },\n\n methods: {\n onColorSelect(event) {\n const rgb = event.target.value.slice(1).split(/(?=(?:..)*$)/).map((t) => parseInt(`0x${t}`))\n this.$emit(this.light ? 'set-light' : 'set-group', {\n rgb: rgb,\n xy: this.colorConverter.rgbToXY(...rgb),\n hsl: this.colorConverter.rgbToHsl(...rgb),\n brightness: this.colorConverter.rgbToBri(...rgb),\n })\n },\n\n getColor(state) {\n return {\n rgb: this.colorConverter.toRGB(state),\n xy: this.colorConverter.toXY(state),\n hsl: this.colorConverter.toHSL(state),\n }\n },\n },\n}\n</script>\n\n<style lang=\"scss\" scoped>\n$light-controls-bg: white;\n\n.controls {\n width: 100%;\n display: flex;\n flex-direction: column;\n align-items: center;\n margin-top: 2.25em;\n background: $light-controls-bg;\n padding: 0.5em 1em;\n border-radius: 1em;\n box-shadow: $plugin-panel-shadow;\n\n .row {\n width: 100%;\n display: flex;\n align-items: center;\n }\n\n .control {\n padding-top: 0.25em;\n }\n\n .icon {\n opacity: 0.7;\n }\n\n input[type=color] {\n width: 100%;\n border: 0;\n }\n}\n</style>\n\n<style lang=\"scss\">\n.light-controls {\n .row {\n .slider {\n margin-top: 0.4em;\n }\n }\n}\n</style>\n","import { render } from \"./Controls.vue?vue&type=template&id=e2726892&scoped=true&bindings={\\\"light\\\":\\\"props\\\",\\\"lights\\\":\\\"props\\\",\\\"group\\\":\\\"props\\\",\\\"loading\\\":\\\"props\\\",\\\"colorConverter\\\":\\\"props\\\",\\\"state\\\":\\\"options\\\",\\\"color\\\":\\\"options\\\",\\\"rgbColor\\\":\\\"options\\\",\\\"onColorSelect\\\":\\\"options\\\",\\\"getColor\\\":\\\"options\\\"}\"\nimport script from \"./Controls.vue?vue&type=script&lang=js\"\nexport * from \"./Controls.vue?vue&type=script&lang=js\"\n\nimport \"./Controls.vue?vue&type=style&index=0&id=e2726892&lang=scss&scoped=true\"\nimport \"./Controls.vue?vue&type=style&index=1&lang=scss\"\nscript.render = render\nscript.__scopeId = \"data-v-e2726892\"\n\nexport default script","import { render } from \"./Light.vue?vue&type=template&id=52168252&scoped=true&bindings={\\\"light\\\":\\\"props\\\",\\\"group\\\":\\\"props\\\",\\\"loading\\\":\\\"props\\\",\\\"collapsed\\\":\\\"props\\\",\\\"colorConverter\\\":\\\"props\\\",\\\"expandToggle\\\":\\\"options\\\"}\"\nimport script from \"./Light.vue?vue&type=script&lang=js\"\nexport * from \"./Light.vue?vue&type=script&lang=js\"\n\nimport \"./Light.vue?vue&type=style&index=0&id=52168252&lang=scss&scoped=true\"\nscript.render = render\nscript.__scopeId = \"data-v-52168252\"\n\nexport default script","<template>\n <Loading v-if=\"loading\" />\n <div class=\"scene row name\" @click=\"onSelect\">\n {{ scene.name || `[Scene ${scene.id}]` }}\n </div>\n</template>\n\n<script>\nexport default {\n name: \"Light\",\n emits: ['select'],\n props: {\n scene: {\n type: Object,\n default: () => {},\n },\n\n group: {\n type: Object,\n default: () => {},\n },\n\n loading: {\n type: Boolean,\n default: false,\n },\n },\n\n methods: {\n onSelect() {\n if (this.loading)\n return false\n\n this.$emit('select')\n },\n },\n}\n</script>\n","import { render } from \"./Scene.vue?vue&type=template&id=6934d062&bindings={\\\"scene\\\":\\\"props\\\",\\\"group\\\":\\\"props\\\",\\\"loading\\\":\\\"props\\\",\\\"onSelect\\\":\\\"options\\\"}\"\nimport script from \"./Scene.vue?vue&type=script&lang=js\"\nexport * from \"./Scene.vue?vue&type=script&lang=js\"\nscript.render = render\n\nexport default script","<template>\n <div class=\"controls animation-controls\" @click=\"$event.stopPropagation()\">\n <Loading v-if=\"loading\" />\n\n <div class=\"animation-container\">\n <div class=\"animation-header\">\n <div class=\"row\">\n <div class=\"col-3\">\n Run Animation\n </div>\n <div class=\"col-9\">\n <ToggleSwitch :value=\"animationRunning\" @input=\"toggleAnimation\" />\n </div>\n </div>\n\n <div class=\"row\">\n <div class=\"col-3\">Animation</div>\n <div class=\"col-9\">\n <label>\n <select class=\"selector\" @click=\"selectedAnimation = $event.target.value\">\n <option value=\"color_transition\">Color transition</option>\n <option value=\"blink\">Blink</option>\n </select>\n </label>\n </div>\n </div>\n </div>\n\n <div class=\"animation\">\n <div class=\"row\" v-if=\"selectedAnimation === 'color_transition'\">\n <div class=\"col-3\">\n Hue range\n </div>\n <div class=\"col-9\">\n <RangeSlider :range=\"colorConverter.ranges.hue\" :disabled=\"loading\"\n :value=\"animations.color_transition.hue_range\"\n @mouseup=\"animations.color_transition.hue_range = $event.target.value\" />\n </div>\n </div>\n\n <div class=\"row\" v-if=\"selectedAnimation === 'color_transition'\">\n <div class=\"col-3\">\n Sat range\n </div>\n <div class=\"col-9\">\n <RangeSlider :range=\"colorConverter.ranges.sat\" :disabled=\"loading\"\n :value=\"animations.color_transition.sat_range\"\n @mouseup=\"animations.color_transition.sat_range = $event.target.value\" />\n </div>\n </div>\n\n <div class=\"row\" v-if=\"selectedAnimation === 'color_transition'\">\n <div class=\"col-3\">\n Bri range\n </div>\n <div class=\"col-9\">\n <RangeSlider :range=\"colorConverter.ranges.sat\" :disabled=\"loading\"\n :value=\"animations.color_transition.bri_range\"\n @mouseup=\"animations.color_transition.bri_range = $event.target.value\" />\n </div>\n </div>\n\n <div class=\"row\" v-if=\"selectedAnimation === 'color_transition'\">\n <div class=\"col-3\">\n Hue step\n </div>\n <div class=\"col-9\">\n <Slider :range=\"colorConverter.ranges.hue\" :disabled=\"loading\"\n :value=\"animations.color_transition.hue_step\"\n @mouseup=\"animations.color_transition.hue_step = parseFloat($event.target.value)\" />\n </div>\n </div>\n\n <div class=\"row\" v-if=\"selectedAnimation === 'color_transition'\">\n <div class=\"col-3\">\n Sat step\n </div>\n <div class=\"col-9\">\n <Slider :range=\"colorConverter.ranges.sat\" :disabled=\"loading\"\n :value=\"animations.color_transition.sat_step\"\n @mouseup=\"animations.color_transition.sat_step = parseFloat($event.target.value)\" />\n </div>\n </div>\n\n <div class=\"row\" v-if=\"selectedAnimation === 'color_transition'\">\n <div class=\"col-3\">\n Bri step\n </div>\n <div class=\"col-9\">\n <Slider :range=\"colorConverter.ranges.bri\" :disabled=\"loading\"\n :value=\"animations.color_transition.bri_step\"\n @mouseup=\"animations.color_transition.bri_step = parseFloat($event.target.value)\" />\n </div>\n </div>\n\n <div class=\"row\">\n <div class=\"col-3\">\n Refresh seconds\n </div>\n <div class=\"col-9\">\n <label>\n <input type=\"number\" :value=\"animations[selectedAnimation].transition_seconds\" step=\"0.1\"\n @input=\"animations[selectedAnimation].transition_seconds = parseFloat($event.target.value)\" >\n </label>\n </div>\n </div>\n\n <div class=\"row\">\n <div class=\"col-3\">\n Duration (seconds)\n </div>\n <div class=\"col-9\">\n <label>\n <input type=\"number\" :value=\"animations[selectedAnimation].duration\" step=\"5\"\n @input=\"animations[selectedAnimation].duration = $event.target.value?.length ? parseFloat($event.target.value) : null\" >\n </label>\n </div>\n </div>\n </div>\n </div>\n\n <div class=\"lights\">\n <div class=\"row\">\n <label>\n <input type=\"checkbox\"\n :checked=\"Object.keys(lights).length === Object.values(selectedLights).filter((v) => v).length\" @click=\"toggleSelectAll\">\n Select all lights\n </label>\n </div>\n\n <div class=\"row\" v-for=\"(light, id) in lights\" :key=\"id\">\n <label>\n <input type=\"checkbox\" v-model=\"selectedLights[id]\" @input=\"selectedLights[id] = !selectedLights[id]\">\n {{ light.name }}\n </label>\n </div>\n </div>\n </div>\n</template>\n\n<script>\nimport Loading from \"@/components/Loading\";\nimport {ColorConverter} from \"@/components/panels/Light/color\";\nimport RangeSlider from \"@/components/elements/RangeSlider\";\nimport Slider from \"@/components/elements/Slider\";\nimport ToggleSwitch from \"@/components/elements/ToggleSwitch\";\nimport Utils from \"@/Utils\";\n\nexport default {\n name: \"Animate\",\n mixins: [Utils],\n components: {ToggleSwitch, Slider, RangeSlider, Loading},\n emits: ['start', 'stop'],\n props: {\n lights: {\n type: Object,\n },\n\n group: {\n type: Object,\n },\n\n loading: {\n type: Boolean,\n default: false,\n },\n\n colorConverter: {\n type: Object,\n default: () => new ColorConverter(),\n },\n\n runningAnimations: {\n type: Object,\n default: () => {},\n }\n },\n\n data() {\n return {\n selectedAnimation: 'color_transition',\n animation: {},\n selectedLights: Object.keys(this.lights).reduce((obj, lightId) => {\n obj[lightId] = true\n return obj\n }, {}),\n animations: {\n color_transition: {\n hue_range: this.colorConverter.ranges.hue,\n sat_range: [\n parseInt((this.colorConverter.ranges.sat[1] - this.colorConverter.ranges.sat[0])/2),\n this.colorConverter.ranges.sat[1]\n ],\n bri_range: [\n parseInt((this.colorConverter.ranges.bri[1] - this.colorConverter.ranges.bri[0]) * 0.75),\n this.colorConverter.ranges.bri[1]\n ],\n\n hue_step: parseInt((this.colorConverter.ranges.hue[1] - this.colorConverter.ranges.hue[0]) / 25),\n sat_step: parseInt((this.colorConverter.ranges.sat[1] - this.colorConverter.ranges.sat[0]) / 50),\n bri_step: parseInt((this.colorConverter.ranges.bri[1] - this.colorConverter.ranges.bri[0]) / 50),\n transition_seconds: 1,\n duration: null,\n },\n\n blink: {\n transition_seconds: 1,\n duration: null,\n },\n },\n }\n },\n\n computed: {\n animationRunning() {\n return Object.keys(this.runningAnimations).length > 0\n },\n },\n\n methods: {\n toggleSelectAll() {\n const select = Object.values(this.selectedLights).filter((v) => v).length < Object.keys(this.lights).length\n Object.keys(this.lights).forEach((lightId) => {\n this.selectedLights[lightId] = select\n })\n },\n\n toggleAnimation() {\n const eventType = this.animationRunning ? 'stop' : 'start'\n const selectedLights = Object.entries(this.selectedLights).filter((light) => light[1]).map((light) => light[0])\n if (!selectedLights.length) {\n this.warn('No lights have been selected')\n return\n }\n\n this.$emit(eventType, {\n lights: selectedLights,\n animation: {\n ...this.animations[this.selectedAnimation],\n animation: this.selectedAnimation,\n },\n })\n },\n },\n}\n</script>\n\n<style lang=\"scss\" scoped>\n$light-controls-bg: white;\n\n.animation-container {\n width: 100%;\n\n .animation-header,\n .animation {\n padding-bottom: 0.5em;\n margin-bottom: 0.5em;\n box-shadow: $border-shadow-bottom;\n }\n}\n\n.controls {\n width: 100%;\n display: flex;\n flex-direction: column;\n align-items: center;\n margin-top: 2.25em;\n background: $light-controls-bg;\n padding: 0.5em 1em;\n border-radius: 1em;\n box-shadow: $plugin-panel-shadow;\n\n .selector {\n width: 100%;\n }\n\n .row {\n width: 100%;\n display: flex;\n align-items: center;\n padding: 0.5em 0;\n\n & > div:last-child {\n text-align: right;\n }\n }\n\n .control {\n padding-top: 0.25em;\n }\n\n .lights {\n padding-top: 0.5em;\n width: 100%;\n\n .row {\n display: flex;\n align-items: center;\n }\n\n label {\n width: 100%;\n }\n }\n}\n</style>\n","<template>\n <div class=\"range-slider\">\n <label>\n <input class=\"slider\" type=\"range\" :value=\"v\" :min=\"range[0]\" :max=\"range[1]\"\n :disabled=\"disabled\" @input=\"input\" @change=\"changed\" @mouseup=\"mouseup\" @mousedown=\"mousedown\"\n @touchstart=\"mouseup\" @touchend=\"mousedown\" :ref=\"`input_${i}`\" v-for=\"(v, i) in value\" :key=\"i\">\n </label>\n </div>\n</template>\n\n<script>\nexport default {\n name: \"RangeSlider\",\n emits: ['input', 'change', 'mouseup', 'mousedown'],\n props: {\n disabled: {\n type: Boolean,\n default: false,\n },\n\n range: {\n type: Array,\n default: () => [0, 100],\n },\n\n value: {\n type: Array,\n default: () => [0, 100],\n },\n },\n\n methods: {\n getEvent(event) {\n return {\n ...event,\n target: {\n ...event.target,\n value: Object.values(this.$refs).map((input) => parseFloat(input.value)).sort(),\n }\n }\n },\n\n input(event) {\n this.$emit('input', this.getEvent(event))\n },\n\n changed(event) {\n this.$emit('change', this.getEvent(event))\n },\n\n mouseup(event) {\n this.$emit('mouseup', this.getEvent(event))\n },\n\n mousedown(event) {\n this.$emit('mousedown', this.getEvent(event))\n },\n },\n\n mounted() {\n if (this.value) {\n const self = this\n this.value.forEach((v, i) => {\n self.$refs[`input_${i}`].value = v\n })\n }\n },\n}\n</script>\n\n<style lang=\"scss\" scoped>\n.range-slider {\n position: relative;\n display: flex;\n\n label {\n height: 2em;\n }\n\n .slider {\n @include appearance(none);\n @include transition(opacity .2s);\n background: none;\n width: 100%;\n height: 2em;\n position: absolute;\n left: 0;\n top: 0;\n margin: 0;\n padding: 0;\n border-radius: 1em;\n outline: none;\n pointer-events: none;\n overflow: hidden;\n z-index: 20;\n\n @mixin slider-thumb {\n @include appearance(none);\n position: relative;\n width: 1.5em;\n height: 1.5em;\n pointer-events: all;\n border-radius: 50%;\n border: 0;\n background: $slider-thumb-bg;\n cursor: pointer;\n z-index: 10;\n outline: 0;\n }\n\n &::-webkit-slider-thumb { @include slider-thumb }\n &::-moz-range-thumb { @include slider-thumb}\n &::-moz-range-track {\n @include appearance(none);\n position: relative;\n border: 0;\n }\n\n &::-moz-range-progress { height: 1em; }\n\n &:first-child {\n z-index: 21;\n &::-moz-range-progress { background: $slider-bg; }\n }\n\n &:last-child {\n background: $slider-bg;\n &::-moz-range-progress { background: $slider-progress-bg; }\n }\n\n &[disabled] {\n @mixin no-thumb {\n display: none;\n width: 0;\n }\n\n &::-moz-range-progress { background: none; }\n &::-webkit-slider-runnable-track { background: none; }\n &::-moz-range-thumb { @include no-thumb; }\n &::-webkit-slider-thumb { @include no-thumb; }\n }\n }\n}\n</style>","import { render } from \"./RangeSlider.vue?vue&type=template&id=0e677180&scoped=true&bindings={\\\"disabled\\\":\\\"props\\\",\\\"range\\\":\\\"props\\\",\\\"value\\\":\\\"props\\\",\\\"getEvent\\\":\\\"options\\\",\\\"input\\\":\\\"options\\\",\\\"changed\\\":\\\"options\\\",\\\"mouseup\\\":\\\"options\\\",\\\"mousedown\\\":\\\"options\\\"}\"\nimport script from \"./RangeSlider.vue?vue&type=script&lang=js\"\nexport * from \"./RangeSlider.vue?vue&type=script&lang=js\"\n\nimport \"./RangeSlider.vue?vue&type=style&index=0&id=0e677180&lang=scss&scoped=true\"\nscript.render = render\nscript.__scopeId = \"data-v-0e677180\"\n\nexport default script","import { render } from \"./Animate.vue?vue&type=template&id=1739aaba&scoped=true&bindings={\\\"lights\\\":\\\"props\\\",\\\"group\\\":\\\"props\\\",\\\"loading\\\":\\\"props\\\",\\\"colorConverter\\\":\\\"props\\\",\\\"runningAnimations\\\":\\\"props\\\",\\\"selectedAnimation\\\":\\\"data\\\",\\\"animation\\\":\\\"data\\\",\\\"selectedLights\\\":\\\"data\\\",\\\"animations\\\":\\\"data\\\",\\\"animationRunning\\\":\\\"options\\\",\\\"toggleSelectAll\\\":\\\"options\\\",\\\"toggleAnimation\\\":\\\"options\\\"}\"\nimport script from \"./Animate.vue?vue&type=script&lang=js\"\nexport * from \"./Animate.vue?vue&type=script&lang=js\"\n\nimport \"./Animate.vue?vue&type=style&index=0&id=1739aaba&lang=scss&scoped=true\"\nscript.render = render\nscript.__scopeId = \"data-v-1739aaba\"\n\nexport default script","import { render } from \"./Group.vue?vue&type=template&id=4de1a560&bindings={\\\"lights\\\":\\\"props\\\",\\\"group\\\":\\\"props\\\",\\\"scenes\\\":\\\"props\\\",\\\"animations\\\":\\\"props\\\",\\\"colorConverter\\\":\\\"props\\\",\\\"selectedLight\\\":\\\"data\\\",\\\"selectedScene\\\":\\\"data\\\",\\\"selectedView\\\":\\\"data\\\",\\\"lightsSorted\\\":\\\"options\\\",\\\"scenesSorted\\\":\\\"options\\\",\\\"groupName\\\":\\\"options\\\",\\\"close\\\":\\\"options\\\",\\\"onSceneSelected\\\":\\\"options\\\"}\"\nimport script from \"./Group.vue?vue&type=script&lang=js\"\nexport * from \"./Group.vue?vue&type=script&lang=js\"\n\nimport \"./Group.vue?vue&type=style&index=0&lang=scss\"\nimport \"./Group.vue?vue&type=style&index=1&lang=scss\"\nscript.render = render\n\nexport default script","import { render } from \"./Index.vue?vue&type=template&id=0378547e&scoped=true&bindings={\\\"lights\\\":\\\"props\\\",\\\"groups\\\":\\\"props\\\",\\\"scenes\\\":\\\"props\\\",\\\"animations\\\":\\\"props\\\",\\\"colorConverter\\\":\\\"props\\\",\\\"loadingLights\\\":\\\"props\\\",\\\"loadingGroups\\\":\\\"props\\\",\\\"pluginName\\\":\\\"props\\\",\\\"initialGroup\\\":\\\"props\\\",\\\"selectedGroup\\\":\\\"data\\\",\\\"initialized\\\":\\\"data\\\",\\\"displayedLights\\\":\\\"options\\\",\\\"groupsByLight\\\":\\\"options\\\",\\\"scenesByGroup\\\":\\\"options\\\",\\\"animationsByGroup\\\":\\\"options\\\",\\\"initSelectedGroup\\\":\\\"options\\\",\\\"refresh\\\":\\\"options\\\",\\\"onLightChange\\\":\\\"options\\\",\\\"onAnimationChange\\\":\\\"options\\\"}\"\nimport script from \"./Index.vue?vue&type=script&lang=js\"\nexport * from \"./Index.vue?vue&type=script&lang=js\"\n\nimport \"./Index.vue?vue&type=style&index=0&id=0378547e&lang=scss&scoped=true\"\nimport \"./Index.vue?vue&type=style&index=1&lang=scss\"\nscript.render = render\nscript.__scopeId = \"data-v-0378547e\"\n\nexport default script","export * from \"-!../../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--8-oneOf-1-0!../../../node_modules/css-loader/dist/cjs.js??ref--8-oneOf-1-1!../../../node_modules/vue-loader-v16/dist/stylePostLoader.js!../../../node_modules/postcss-loader/src/index.js??ref--8-oneOf-1-2!../../../node_modules/sass-loader/dist/cjs.js??ref--8-oneOf-1-3!../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../node_modules/vue-loader-v16/dist/index.js??ref--0-1!./Group.vue?vue&type=style&index=1&lang=scss\"","export * from \"-!../../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--8-oneOf-1-0!../../../node_modules/css-loader/dist/cjs.js??ref--8-oneOf-1-1!../../../node_modules/vue-loader-v16/dist/stylePostLoader.js!../../../node_modules/postcss-loader/src/index.js??ref--8-oneOf-1-2!../../../node_modules/sass-loader/dist/cjs.js??ref--8-oneOf-1-3!../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../node_modules/vue-loader-v16/dist/index.js??ref--0-1!./Controls.vue?vue&type=style&index=1&lang=scss\"","export * from \"-!../../../node_modules/mini-css-extract-plugin/dist/loader.js??ref--8-oneOf-1-0!../../../node_modules/css-loader/dist/cjs.js??ref--8-oneOf-1-1!../../../node_modules/vue-loader-v16/dist/stylePostLoader.js!../../../node_modules/postcss-loader/src/index.js??ref--8-oneOf-1-2!../../../node_modules/sass-loader/dist/cjs.js??ref--8-oneOf-1-3!../../../node_modules/cache-loader/dist/cjs.js??ref--0-0!../../../node_modules/vue-loader-v16/dist/index.js??ref--0-1!./Group.vue?vue&type=style&index=0&lang=scss\""],"sourceRoot":""}