Open BigJk opened 1 year ago
Hi, I'm interested in this one. Could you assign this for me?
@carlosfrodrigues Thanks for your interest. Feel free to just fork the project and start hacking 😃 I'm always open to merging pull requests that seems reasonable. If any questions come up we can discuss them here or over discord.
!IMAGE
tag should maybe be extended to take a optional default url like !IMAGE=https://.../some_test_image.png
so that a test image can be shown while editing the templateSomething that should be thought about is how the handling of sub-objects, arrays of objects, arrays of objects in sub-objects... should be handled in regards to the schema. Imagine the following data:
{
"obj": { "field_a": "test", "field_b": 1234 },
"arr": [
{ "field_a": "test", "field_b": 1234 },
{ "field_a": "test", "field_c": ["a", "b", "c"] }
]
}
How should this be described by the schema?
{
"obj": { "field_a": "!TEXT=default", "field_b": "!NUMBER=1234" },
"arr": [
// Do we describe the schema of the elements in a array
// by inserting a single object with definitions?
{
"field_a": "!TEXT=default",
"field_b": "!NUMBER=1234",
"field_c": "!MULTI_OPT:a,b,c=a"
}
]
}
I feel like there are a lot of questions that might need to be investigated before actually implementing something.
Feel free to share your thoughts 😃
Hi @BigJk ! 👋
I've just submitted a pull request (#50) for review. Please note that this PR is primarily for review purposes, and some functionalities, like the dropdown, are not yet fully functional.
I'd really appreciate it if you could take some time to review the changes I've made so far and provide feedback. Once we address the remaining issues, I'll ensure everything works smoothly.
Thank you for your attention and feedback! 🙏
Currently the "schema" of a templates data is derived kinda vaguely from the data skeleton. This is a relic from S&D just being a small proof-of-concept type of application at the beginning. Defining a image in the data skeleton already introduced a additional syntax inside the JSON.
it the future it should be possible to OPTIONALLY define what input should be shown for a field + some kind of default value for a preview while editing. A example to illustrate the idea:
That way we can map custom components to the same data types and which should make entry creation and editing more pleasant.