From 1f1b56607be75d9e6b7adeb5ab9e6063e69997b8 Mon Sep 17 00:00:00 2001 From: jean-emmanuel Date: Thu, 9 Oct 2025 21:23:33 +0200 Subject: [PATCH] docs: color properties must use css syntax --- src/client/widgets/common/widget.mjs | 8 ++++---- src/client/widgets/sliders/fader.mjs | 2 +- src/client/widgets/sliders/knob.mjs | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/src/client/widgets/common/widget.mjs b/src/client/widgets/common/widget.mjs index 2fe053ca..4e3c9b81 100644 --- a/src/client/widgets/common/widget.mjs +++ b/src/client/widgets/common/widget.mjs @@ -74,10 +74,10 @@ class Widget extends EventEmitter { expand: {type: 'boolean|number', value: false, help: 'If parent\'s layout is `vertical` or `horizontal`, set this to `true` to stretch the widget to use available space automatically.'}, }, style: { - colorText: {type: 'string', value: 'auto', help: 'Text color. Set to "auto" to inherit from parent widget.'}, - colorWidget: {type: 'string', value: 'auto', help: 'Widget\'s default accent color. Set to "auto" to inherit from parent widget.'}, - colorStroke: {type: 'string', value: 'auto', help: 'Stroke color. Set to "auto" to use `colorWidget`.'}, - colorFill: {type: 'string', value: 'auto', help: 'Fill color. Set to "auto" to use `colorWidget`.'}, + colorText: {type: 'string', value: 'auto', help: 'Text color. Set to "auto" to inherit from parent widget. Must be a valid css color.'}, + colorWidget: {type: 'string', value: 'auto', help: 'Widget\'s default accent color. Set to "auto" to inherit from parent widget. Must be a valid css color.'}, + colorStroke: {type: 'string', value: 'auto', help: 'Stroke color. Set to "auto" to use `colorWidget`. Must be a valid css color.'}, + colorFill: {type: 'string', value: 'auto', help: 'Fill color. Set to "auto" to use `colorWidget`. Must be a valid css color.'}, alphaStroke: {type: 'number', value: 'auto', help: 'Stroke color opacity.'}, alphaFillOff: {type: 'number', value: 'auto', help: 'Fill color opacity (off).'}, alphaFillOn: {type: 'number', value: 'auto', help: 'Fill color opacity (on).'}, diff --git a/src/client/widgets/sliders/fader.mjs b/src/client/widgets/sliders/fader.mjs index 8b829585..3a4d9f1c 100644 --- a/src/client/widgets/sliders/fader.mjs +++ b/src/client/widgets/sliders/fader.mjs @@ -17,7 +17,7 @@ class Fader extends Slider { _separator_fader_style: 'Fader style', design: {type: 'string', value: 'default', choices: ['default', 'round', 'compact'], help: 'Design style'}, knobSize: {type: 'number', value: 'auto', help: 'Fader knob size'}, - colorKnob: {type: 'string', value: 'auto', help: 'Fader knob color'}, + colorKnob: {type: 'string', value: 'auto', help: 'Fader knob color. Must be a valid css color.'}, horizontal: {type: 'boolean', value: false, help: 'Set to `true` to display the fader horizontally'}, pips: {type: 'boolean', value: false, help: 'Set to `true` to show range breakpoints (ignored if `design` is `compact`)'}, dashed: {type: 'boolean|array', value: false, help: 'Set to `true` to display a dashed gauge. Can be set as an `array` of two numbers : `[dash_size, gap_size]`'}, diff --git a/src/client/widgets/sliders/knob.mjs b/src/client/widgets/sliders/knob.mjs index e21653e7..05aa44f0 100644 --- a/src/client/widgets/sliders/knob.mjs +++ b/src/client/widgets/sliders/knob.mjs @@ -19,7 +19,7 @@ class Knob extends Slider { 'Design style', 'Note: "solid" design uses "colorStroke" for the central knob color.' ]}, - colorKnob: {type: 'string', value: 'auto', help: 'Knob color'}, + colorKnob: {type: 'string', value: 'auto', help: 'Knob color. Must be a valid css color.'}, pips: {type: 'boolean', value: false, help: 'Set to `true` to show the scale\'s breakpoints'}, dashed: {type: 'boolean|array', value: false, help: 'Set to `true` to display a dashed gauge. Can be set as an `array` of two numbers : `[dash_size, gap_size]`'}, angle: {type: 'number', value: 270, help: 'Defines the angle\'s width of the knob, in degrees'},