ldtk icon indicating copy to clipboard operation
ldtk copied to clipboard

Default values for enums

Open meepleek opened this issue 5 years ago • 5 comments

The default value input is missing for enums. Why is that exactly?

meepleek avatar Oct 21 '20 21:10 meepleek

There was an obscure (probably lazy) reason for that, but I can't remember it 🤔 I'll see what I can do :)

deepnight avatar Oct 22 '20 07:10 deepnight

To be done, this would required disambiguation between possible states:

  1. field is required, and "null" value should be displayed as an error,
  2. field is optional, but it has a default value if omitted,
  3. field can really be "null" because it has no default value.

Related #392

deepnight avatar Jan 07 '22 11:01 deepnight

#392 is marked as "wontdo" now. Does this issue have a chance?

eliasdaler avatar Jan 14 '22 14:01 eliasdaler

I'm not sure about the usefulness of #392, thus the "wontdo" tag. But if I happen to add a distinct "optional" flag from the current "nullable" flag, this could change.

This current issue ("default enum value") is, imho, far more useful, thus its current state.

deepnight avatar Jan 17 '22 08:01 deepnight

I agree. So if "default enum value" is happening, I'm happy! :D

eliasdaler avatar Jan 17 '22 13:01 eliasdaler

vote +1

JustusPan avatar Dec 14 '22 07:12 JustusPan

Added in 1.2.0 🥳

deepnight avatar Dec 20 '22 13:12 deepnight