Skip to content

Commit 3db172e

Browse files
Williangalvanipatrickelectric
authored andcommitted
frontend: fix InlineParameterEditor not displaying zero values
The truthiness check `if (this.param?.value)` treated 0 as falsy, so `internal_new_value_as_string` was never set and the field showed the placeholder label instead of "0". Use `this.param != null` to check for parameter existence regardless of its value. Made-with: Cursor
1 parent 29fc497 commit 3db172e

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

core/frontend/src/components/parameter-editor/InlineParameterEditor.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -322,7 +322,7 @@ export default Vue.extend({
322322
.map((value) => parseFloat(value))
323323
.includes(this.internal_new_value)
324324
}
325-
if (this.param?.value) {
325+
if (this.param != null) {
326326
this.internal_new_value_as_string = this.internal_new_value.toString()
327327
}
328328

0 commit comments

Comments
 (0)