usnistgov / metaschema

Documentation for and implementations of the metaschema modeling language
https://pages.nist.gov/metaschema/
Other
36 stars 19 forks source link

Add allowed-value constraints tutorial #508

Closed aj-stein-nist closed 9 months ago

aj-stein-nist commented 10 months ago

Committer Notes

Begin the allowed-value constraints tutorial and potentially others, pending feedback. Closes #292.

All Submissions:

Changes to Core Features:

aj-stein-nist commented 9 months ago

I would like feedback before removing the draft status and final review.

  1. Specific, actionable grammar and spelling changes are always welcome. 😛
  2. After expanding our required and recommended value strategies, do we encourage me or require me to add a third section on "extending" constraint definitions and handling conflicts? That seems like an advanced topic, but relevant to the constraints tutorial here.
  3. Should I continue beyond allowed-values constraints tutorials and come up with examples of <index/>, <is-unique/>, <expect/>, and <matches/> or should that be separately scoped work for a separate tutorial or, as is convenient for me, include it here? (this will be Tutorial 2, I am implying with this answer you recommend the subject matter be Tutorial 3, or even 5 or 6 in a different order of complexity.)
aj-stein-nist commented 9 months ago

I also did some touch-ups on this to relabel the introduction correctly, highlight changes to the model, and more interestingly highlight relevant changes to the example document instances. I didn't realize the tabs and highlight wrapped directives were native Hugo configuration with the templates we use working out of the box, so I added that as well and it just works.

image

image

image

aj-stein-nist commented 9 months ago

Sorry for the delays, I will try to touch this up before the community call today.

aj-stein-nist commented 9 months ago

Re https://github.com/usnistgov/metaschema/pull/508#issuecomment-1894404675, I only got feedback from @david-waltermire that I should separate out the constraint type tutorials and not keep them in one massive tutorial. As this is tutorial 2, follow-on constraint tutorials will be 3, 4, or maybe 5 respectively. Will ask in today's meeting for more feedback but likely move to merge this once I apply PR recommendations and mark for final review and tentative merge. I will open new issues for the follow-on tutorials.

aj-stein-nist commented 9 months ago

Sorry for the delay, this is ready for final review with feedback from Updated in https://github.com/usnistgov/metaschema/pull/508/commits/889758b6fe05bdbb6c5dd410dc00aabe7d95b787 and feedback integrated.