Model archicture: More metadata for traits
Traits need to be more descriptive, both as an aid to the catalog editor UI and to facilitate validation on load. Specifically:
- A trait representing an enumeration should be able to tell you its legal values.
- A string traits that really represents a date/time, a color, or markdown should indicate as such.
- Probably others.
Hi there, sorry to revive an old thread, I wanted to see if there has been a successor to TerriaJS/catalog-editor or Data Source Editor. There have been closed issues threads in 2022, #5654 and #5655, but it does not seem so. Also, make-schema is mentioned in terria-v7 dev env doc to produce JSON schemas for the catalog items, groups, types and the whole init files. These schemas could be useful to input to a json schema editor or headless CMS, has there been a replacement? Thanks!
Edit: on v8, the doc seem to be generated from buildprocess/generateDocs.ts, parsing ../lib/Models/Catalog/CatalogMemberFactory and const catalogMembers = CatalogMemberFactory.constructorsArray; into markdown files like doc/mkdocs.yml used by mkdocs, for example connecting-to-data/catalog-items.md
@jo-chemla Thank you for reviving this thread! Indeed, it would be great to have such a tool.
To the best of my knowledge, there has not been much progress in that direction since then. Most of the work is likely done within Terria's commercial product https://terria.io/, and I am unsure how much of it will be open-sourced.
However, there is plenty of information about prior work, which can serve as a solid foundation for community contributions.
Just for completeness' sake, here are the relevant links:
- https://github.com/TerriaJS/catalog-editor
- https://github.com/TerriaJS/generate-terriajs-schema
- https://github.com/TerriaJS/terriajs-schema
Thanks for the references to these old interactive Terria catalog editors!
I did not know Terria commercial offerings also consisted of a webui for catalog builder. It would indeed be great to also offer an oss version. Do you happen to know if the JSON schema docs are still available somewhere or is the current mkdocs doc building process only producing markdown files (for mkdoc to consume)?
If the JSON schemas still exist or are part of the build process, they can probably be ingested by a json schema UI editor like json-editor (demos here and there). Would make an complete webui catalog-editor, similar to Explore Data -> My Data -> Add Web Data, with all supported groups/references/items.
Edit: just noticed the app.terria.io app, where the product Data Explorer is advertised as free and seem to include the commercial Terria Catalog Builder, but no way to test it with a free account.