2021-02-05 18:22:23 +00:00
---
title: oh-knob-card - Knob Card
component: oh-knob-card
label: Knob Card
description: Display a knob in a card to visualize and control a quantifiable item
source: https://github.com/openhab/openhab-webui/edit/main/bundles/org.openhab.ui/doc/components/oh-knob-card.md
2021-03-01 14:42:17 +00:00
prev: /docs/ui/components/
2021-02-05 18:22:23 +00:00
---
2021-02-05 14:16:35 +00:00
# oh-knob-card - Knob Card
2023-02-12 19:21:15 +00:00

2021-03-01 14:42:17 +00:00
[[toc]]
<!-- Note: you can overwrite the definition - provided description and add your own intro/additional sections instead -->
<!-- DO NOT REMOVE the following comments if you intend to keep the definition - provided description -->
2021-02-05 14:16:35 +00:00
<!-- GENERATED componentDescription -->
Display a knob in a card to visualize and control a quantifiable item
<!-- GENERATED /componentDescription -->
## Configuration
2021-03-01 14:42:17 +00:00
<!-- DO NOT REMOVE the following comments -->
2021-02-05 14:16:35 +00:00
<!-- GENERATED props -->
### Card
2021-03-01 14:42:17 +00:00
< div class = "props" >
< PropGroup name = "card" label = "Card" >
Parameters of the card
< PropBlock type = "TEXT" name = "title" label = "Title" >
< PropDescription >
Title of the card
< / PropDescription >
< / PropBlock >
< PropBlock type = "TEXT" name = "footer" label = "Footer text" >
< PropDescription >
Footer of the card
< / PropDescription >
< / PropBlock >
< PropBlock type = "BOOLEAN" name = "noBorder" label = "No Border" >
< PropDescription >
Do not render the card border
< / PropDescription >
< / PropBlock >
< PropBlock type = "BOOLEAN" name = "noShadow" label = "No Shadow" >
< PropDescription >
Do not render a shadow effect to the card
< / PropDescription >
< / PropBlock >
< PropBlock type = "BOOLEAN" name = "outline" label = "Outline" >
< PropDescription >
Show the card outline
< / PropDescription >
< / PropBlock >
< / PropGroup >
< / div >
2021-02-05 14:16:35 +00:00
2023-02-12 19:55:05 +00:00
### Knob & Round Slider
2021-03-01 14:42:17 +00:00
< div class = "props" >
2023-02-12 19:55:05 +00:00
< PropGroup name = "knob" label = "Knob & Round Slider" >
2023-02-12 19:21:15 +00:00
Parameters are passed to the underlying < a target = "_blank" class = "external text-color-blue" href = "https://github.com/kramer99/vue-knob-control#properties" > knob control< / a > or < a target = "_blank" class = "external text-color-blue" href = "https://github.com/soundar24/vue-round-slider#props" > round-slider control< / a >
2021-03-01 14:42:17 +00:00
< PropBlock type = "TEXT" name = "item" label = "Item" context = "item" >
< PropDescription >
Item to control
< / PropDescription >
< / PropBlock >
2023-02-12 19:21:15 +00:00
< PropBlock type = "BOOLEAN" name = "useSliderControl" label = "Use Slider Control" >
< PropDescription >
Use < a class = "external text-color-blue" target = "_blank" href = "https://vue.roundsliderui.com/" > round-slider control< / a > instead of knob control (allows more customization) - parameters are advanced!
< / PropDescription >
< / PropBlock >
2021-03-01 14:42:17 +00:00
< PropBlock type = "INTEGER" name = "min" label = "Min" >
< PropDescription >
Minimum value (default 0)
< / PropDescription >
< / PropBlock >
< PropBlock type = "INTEGER" name = "max" label = "Max" >
< PropDescription >
Maximum value (default 100)
< / PropDescription >
< / PropBlock >
2023-02-12 19:21:15 +00:00
< PropBlock type = "TEXT" name = "circleShape" label = "Circle Shape" >
< PropDescription >
full, pie, half-top/-bottom/-left/-right, quarter-top-left/-right, quarter-bottom-left/-right - slider control only!
< / PropDescription >
< / PropBlock >
< PropBlock type = "INTEGER" name = "startAngle" label = "Start Angle" >
< PropDescription >
Angle of circle where the round slider should start (default 0); 0 is 9 o'clock; only if circleShape is not set - slider control only!
< / PropDescription >
< / PropBlock >
< PropBlock type = "INTEGER" name = "endAngle" label = "End Angle" >
< PropDescription >
Angle of circle where the round slider should start (default 360); 360 is 9 o'clock; only if circleShape is not set - slider control only!
< / PropDescription >
< / PropBlock >
2021-03-01 14:42:17 +00:00
< PropBlock type = "DECIMAL" name = "stepSize" label = "Step" >
< PropDescription >
Minimum interval between values (default 1)
< / PropDescription >
< / PropBlock >
< PropBlock type = "BOOLEAN" name = "disabled" label = "Disabled" >
< PropDescription >
Disable the slider (usually set via an expression since the value will not be displayed when disabled)
< / PropDescription >
< / PropBlock >
< PropBlock type = "INTEGER" name = "size" label = "Size" >
< PropDescription >
Visual size of the control in px (or % if responsive is true)
< / PropDescription >
< / PropBlock >
< PropBlock type = "TEXT" name = "primaryColor" label = "Primary Color" >
< PropDescription >
Color of the value arc (HTML value, default #409eff )
< / PropDescription >
< / PropBlock >
< PropBlock type = "TEXT" name = "secondaryColor" label = "Secondary Color" >
< PropDescription >
Color of the rest of the control (HTML value, default #dcdfe6 )
< / PropDescription >
< / PropBlock >
< PropBlock type = "TEXT" name = "textColor" label = "Text Color" >
< PropDescription >
Color of the value text (HTML value, default #000000 )
< / PropDescription >
< / PropBlock >
2023-02-12 19:21:15 +00:00
< PropBlock type = "TEXT" name = "borderColor" label = "Border Color" >
< PropDescription >
Sets the border color of the slider. By default it will inherit the primaryColor value (HTML value, default #000000 ) - slider control only!
< / PropDescription >
< / PropBlock >
< PropBlock type = "INTEGER" name = "borderWidth" label = "Border Width" >
< PropDescription >
Indicates the border width of the slider - slider control only!
< / PropDescription >
< / PropBlock >
< PropBlock type = "INTEGER" name = "strokeWidth" label = "Stroke Width" >
< PropDescription >
Thickness of the arcs (default 17)
< / PropDescription >
< / PropBlock >
< PropBlock type = "TEXT" name = "lineCap" label = "Line End Type" >
< PropDescription >
butt, round, square, none - slider control only!
< / PropDescription >
< / PropBlock >
2023-03-06 08:58:30 +00:00
< PropBlock type = "TEXT" name = "dottedPath" label = "Dotted Path" >
2021-03-01 14:42:17 +00:00
< PropDescription >
2023-02-12 19:21:15 +00:00
Length of dotted path segments (css stroke-dasharray) - slider control only!
2021-03-01 14:42:17 +00:00
< / PropDescription >
< / PropBlock >
< PropBlock type = "BOOLEAN" name = "responsive" label = "Responsive" >
< PropDescription >
Size the control using percentages instead of pixels
< / PropDescription >
< / PropBlock >
2021-06-27 16:17:32 +00:00
< PropBlock type = "BOOLEAN" name = "releaseOnly" label = "Send command only on release" >
2021-05-16 18:25:36 +00:00
< PropDescription >
2021-06-27 16:17:32 +00:00
If enabled, no commands are sent during sliding
< / PropDescription >
< / PropBlock >
< PropBlock type = "INTEGER" name = "commandInterval" label = "Command Interval" >
< PropDescription >
Time to wait between subsequent commands in ms (default 200)
2021-05-16 18:25:36 +00:00
< / PropDescription >
< / PropBlock >
< PropBlock type = "INTEGER" name = "delayStateDisplay" label = "Delay State Display" >
< PropDescription >
Time to wait before switching from displaying user input to displaying item state in ms (default 2000)
< / PropDescription >
< / PropBlock >
2021-03-01 14:42:17 +00:00
< / PropGroup >
< / div >
2021-02-05 14:16:35 +00:00
2021-03-01 14:42:17 +00:00
<!-- GENERATED /props -->
2021-02-05 14:16:35 +00:00
2021-03-01 14:42:17 +00:00
<!-- If applicable describe how properties are forwarded to a underlying component from Framework7, ECharts, etc.:
### Inherited Properties
2021-02-05 14:16:35 +00:00
2021-03-01 14:42:17 +00:00
-->
2021-02-05 14:16:35 +00:00
2021-03-01 14:42:17 +00:00
<!-- If applicable describe the slots recognized by the component and what they represent:
### Slots
2021-02-05 14:16:35 +00:00
2021-03-01 14:42:17 +00:00
#### `default`
2021-02-05 14:16:35 +00:00
2021-03-01 14:42:17 +00:00
The contents of the oh-knob-card.
2021-02-05 14:16:35 +00:00
2021-03-01 14:42:17 +00:00
-->
2021-02-05 14:16:35 +00:00
2021-03-01 14:42:17 +00:00
<!-- Add as many examples as desired - put the YAML in a details container when it becomes too long (~150/200+ lines):
## Examples
2021-02-05 14:16:35 +00:00
2021-03-01 14:42:17 +00:00
### Example 1
2021-02-05 14:16:35 +00:00
2021-03-01 14:42:17 +00:00

2021-02-05 14:16:35 +00:00
2021-03-01 14:42:17 +00:00
```yaml
component: oh-knob-card
config:
prop1: value1
prop2: value2
```
2021-02-05 14:16:35 +00:00
2021-03-01 14:42:17 +00:00
### Example 2
2021-02-05 14:16:35 +00:00
2021-03-01 14:42:17 +00:00

2021-02-05 14:16:35 +00:00
2021-03-01 14:42:17 +00:00
::: details YAML
```yaml
component: oh-knob-card
config:
prop1: value1
prop2: value2
slots
```
:::
2021-02-05 14:16:35 +00:00
2021-03-01 14:42:17 +00:00
-->
2021-02-05 14:16:35 +00:00
2021-03-01 14:42:17 +00:00
<!-- Try to clean up URLs to the forum (https://community.openhab.org/t/<threadID>[/<postID>] should suffice)
## Community Resources
2021-02-05 14:16:35 +00:00
2021-03-01 14:42:17 +00:00
- [Community Post 1 ](https://community.openhab.org/t/12345 )
- [Community Post 2 ](https://community.openhab.org/t/23456 )
-->