Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add fragment to YAML format #221

Merged
merged 3 commits into from
Dec 3, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 21 additions & 1 deletion _pages/yaml-file-format.md
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,14 @@ Three keys are always present:
</tbody></table>

The URI that identifies the concept documented in this YAML file.

If the YAML file also includes the key <code>fragment</code>,
this URI should be followed by a fragment identifier when used;
the meaning of the fragment is defined by the <code>fragment</code> entry.

tychonievich marked this conversation as resolved.
Show resolved Hide resolved
For example, if <code>uri</code> is "https://gedcom.io/terms/v7/RIN" and
<code>fragment</code> is "Source System", then a full URI might be
"https://gedcom.io/terms/v7/RIN#MyProgram" where the fragment identifier
"MyProgram" indicates the source system that generated the RIN payload value.
## Other keys

The following keys may appear in a YAML file.
Expand Down Expand Up @@ -184,6 +191,19 @@ Their names may be changed a YAML file with a `lang` other than `en`.
Standard structures may have an `extension tags` entry to list *fully compatible* extensions that predated the standard and can be converted to the `standard tag` without any other modification.
For example, 7.0's `UID` structure is fully compatible with the common 5.5.1 extension identified by tag `_UID`.

- <table><tbody>
<tr><th>Key</th><td><code>fragment</code></td></tr>
<tr><th>Type</th><td><code>str</code></td></tr>
<tr><th>Required by</th><td>—</td></tr>
<tr><th>Allowed by</th><td><code>type: uri</code></td></tr>
</tbody></table>

A recommended brief name or label for a fragment identifier, to show to users. Labels are user-centric; for programmer-centric explanations of the concept, see `specification`.

Labels are short to fit in forms and other constrained-space UI elements; for more detailed text see `help text`.

By being present in the YAML file, this field also implies that the URI should have a fragment identifier appended to it when used.

- <table><tbody>
<tr><th>Key</th><td><code>help text</code></td></tr>
<tr><th>Type</th><td><code>str</code></td></tr>
Expand Down
Loading