You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Managed to do it by refactoring the fieldTitle function:
fieldTitle:SubSchema->Path->Maybe (HtmlF.Msg)
fieldTitle schema path =
schema.title
-- If it does not have a title, derive from property name, unCamelCasing it|>Maybe.orElse (List.last path |>Maybe.map (String.Case.convertCase ""TrueTrue))|>Maybe.map (\str -> span [ class "label-text"][ text str ])
I can provide a PR if you think this is correct 😉
(I was unsure if Path could be more than a list with one element, so I used List.last instead of List.head but maybe that is wrong and it is safe to just use List.head here? 🤔 )
I emailed Tomáš the other day with a consulting proposal where I can help you guys out with adapting the json-schema-form package to work with the JSON Form standard (implement all the layout stuff, etc.) and perhaps help you out with how to best use/integrate the package and how to design your forms to be user friendly etc. I have quite a lot of deep experience in building and designing declarative data driven forms in Elm.
Is this something you guys would be interested in? I don't know if Tomáš is the right person to reach out to about this, since I haven't gotten a reply yet.
Hello again! I just wonder if I should open this issue here or in the json-schema repo.
According to some specification here:
Is this easily implementable here in a decoder or should it be handled by the
json-schema
decoder?Let me know your thoughts and thanks for the quick responses! 🙇🏻
The text was updated successfully, but these errors were encountered: