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

Use dash instead of asterisk for unordered list items in generated Markdown #10

Open
5 tasks
david-waltermire opened this issue Jul 2, 2019 · 5 comments
Open
5 tasks

Comments

@david-waltermire
Copy link
Collaborator

User Story:

As an OSCAL content developer, I need to define OSCAL Markdown for unordered list items in a consistent way.

Goals:

  • Support MD004 using - consistently in Markdown for unordered list items.
  • Update content conversion to normalize all forms of list markers -, +, and * to use properly indented - characters.

Dependencies:

None.

Acceptance Criteria

  • All OSCAL website and readme documentation affected by the changes in this issue have been updated. Changes to the OSCAL website can be made in the docs/content directory of your branch.
  • A Pull Request (PR) is submitted that fully addresses the goals of this User Story. This issue is referenced in the PR.
  • The CI-CD build process runs without any reported errors on the PR. This can be confirmed by reviewing that all checks have passed in the PR.
@wendellpiez
Copy link
Collaborator

@david-waltermire-nist does Goal 2 imply that all ASCII 'bullet' signs including -, * and + should be mapped to HTML-style <ul><li> in our content conversion?

To permit all three markers raises a question as to the correct handling of mixed representations such as

* item
+ another item
* third item, or first?

The rule expressed at MD004 is designed to prevent this ambiguity, but we have no place in our processing chain to enforce the rule, meaning we need to define reasonable handling.

If we treat them all as usable with the same meaning, the following Markdown would describe a three-item list with three items in a sub-list inside the first item:

- bulleted list item
  + sublist-item
  + another sublist
  - still sublist
+ a second top-level list item
- top-level item usnistgov/OSCAL#3 

Alternatively, we could settle on a single bullet (item marker) and have all OSCAL use that. This is what we have now except using * not - (we could switch it).

To try and distinguish between valid (permissible) Markdown and invalid, implies we have a way to validate it over the JSON.

@wendellpiez
Copy link
Collaborator

@david-waltermire-nist if we had a unit test for Markdown conversion this Issue would be even easier to dispatch. Even without the unit test, let me know if you want - instead of * throughout, for ul/li: this is an easy change to make as long as the * would cease to work. At some future point we could return to the question of mixing marks.

@wendellpiez
Copy link
Collaborator

wendellpiez commented Jan 16, 2020

Decided today to avoid questions regarding semantics of bullet styles and settle on a single marker: the hyphen -. The work item is to replace * with - in OSCAL markdown.

Also on board:

  • Double check documentation on the site wrt bulleted lists in the Markdown format.
  • Make progress towards unit testing the markdown conversion (both ways).

NB: this will change JSON data where lists appear. Confirm which sample documents these are (which ones have any ul in the XML). This is not a long list.

@david-waltermire
Copy link
Collaborator Author

@wendellpiez Has this been done?

@david-waltermire david-waltermire transferred this issue from usnistgov/OSCAL Mar 15, 2021
@wendellpiez
Copy link
Collaborator

Like #9, this Issue depends on a complete spec of the current Metaschema-supported Markdown subset, with which it needs to be aligned.

It also depends on unit tests. Indeed, the Markdown unit tests probably already include tests for list conversion based on markers.

@david-waltermire david-waltermire transferred this issue from usnistgov/metaschema Jun 30, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants