Support costom note types
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 245
- Forks
- 80
- Avg merge
- 10h 46m
- Merged PRs (30d)
- 2
Description
In ECMA-426, we have more types of "notes" than the two supported by ecmarkup. For example, in http://tc39.es/ecma426/#sec-linking-inline you can see an "Example" and an "Issue".
We currently make them work by using <emu-note example>/<emu-note issue> with some custom CSS, but we have to inject the "Example"/"Issue" title through CSS so it's not user-selectable.
It'd be great if Ecmarkup:
- allowed custom values for
emu-note'stypeattribute, and used it to generate the label and to maintain the counter,type="editor"would be special-cased to have "editor's note" rather than just "editor" as the label - the various colors were customizable through CSS variables, so that we could simply do
emu-note[type=example] { --note-text-color: #574b0f; --note-border-color: #e0cb52; --note-background-color: #fcfaee; }
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Review ecmarkup's current emu-note handling and compare it with ECMA-426's spec.emu lines 26–55, which demonstrate the existing CSS workaround. Done means custom note types produce selectable labels and counters, editor notes use the requested special label, and note colors can be set through CSS variables.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- css, typescript
- Domain
- tooling
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100