stalefish 7.0.1 → 7.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -91,12 +91,14 @@ class Selectbox extends Component {
91
91
  <option value="${required ? 'Select an option' : ''}" ${!holdingPen[property] ? { selected: 'true' } : ''} ${required ? { disabled: 'disabled' } : ''}>${required ? 'Select an option' : ''}</option>
92
92
  ${options.map(option => {
93
93
  let optionValue
94
+ let optionName
94
95
  if (typeof option === 'object' && option.value !== undefined) {
95
96
  optionValue = option.value
97
+ optionName = option.name
96
98
  } else {
97
99
  optionValue = option
98
100
  }
99
- return html`<option value="${optionValue}" ${holdingPen[property] === optionValue ? { selected: 'true' } : ''}>${optionValue}</option>`
101
+ return html`<option value="${optionValue}" ${holdingPen[property] === optionValue ? { selected: 'true' } : ''}>${optionName || optionValue}</option>`
100
102
  })}
101
103
  </select>
102
104
  </label>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "stalefish",
3
- "version": "7.0.1",
3
+ "version": "7.0.2",
4
4
  "description": "Simple function based component library for halfcab tagged template literals",
5
5
  "main": "index.mjs",
6
6
  "module": "index.mjs",