By jrockowitz on
Change record status:
Published (View all published change records)
Project:
Introduced in branch:
8.x-5.x
Introduced in version:
8.x-5.0-rc1
Issue links:
Description:
The displayed output of the 'range' element was not easily customizable because it was rendered using JavaScript. The displayed output could only be positioned to the right of the range input.
Summary
- Output can now be positioned to the left, right, above, or below the range element.
- Output related element properties were renamed.
- Output element properties now conform to sub element standard. For example, all #output__PROPERTY_NAME will automatically be added to the output element.
- Output number element now supports customizable attributes (i.e. class, style, and attributes)
- Output number element's width automatically resized to the max value's length.
- Default range properties are always defined (#min: 0, #max: 100, and #step: 1)
- CSS (css/webform.element.range.css) and JS (js/webform.element.range.js) were update.
Before
range:
'#type': range
'#title': Range
'#range__output': true
'#range__output_prefix': '$'
'#range__output_suffix': '.00'
After
range:
'#type': range
'#title': Range
'#output': right
'#output__field_prefix': '$'
'#output__field_suffix': '.00'
'#output__attributes':
style: 'background-color: yellow'
Screenshot

| Attachment | Size |
|---|---|
| Screen Shot 2018-01-01 at 8.22.40 AM.png | 41.51 KB |
| Test Element Range Webform Demo Site.png | 43.17 KB |
Impacts:
Site builders, administrators, editors
Module developers
Themers