w3c / csswg-drafts

CSS Working Group Editor Drafts
https://drafts.csswg.org/
Other
4.43k stars 656 forks source link

[css-counter-styles-3] Zhuyin (Mandarin Bopomofo) counter style #10685

Closed NightFurySL2001 closed 4 weeks ago

NightFurySL2001 commented 1 month ago

Propose to add Mandarin Bopomofo as a counter style in CSS. Although not as commonly used as Han numerals, it is sometimes used in sub-lists or headers, especially in dictionaries. The term "zhuyin" is used instead of "bopomofo" as the ordering is following modern Taiwanese Mandarin order (reference https://language.moe.gov.tw/001/Upload/files/site_content/M0001/juyin/html_ch/index.html) and not other bopomofo system. Other bopomofo ordering may be introduced at a later time.

Proposed ordering:

@counter-style zhuyin {
  system: alphabetic;
  symbols: "\3105" "\3106" "\3107" "\3108" "\3109" "\310A" "\310B" "\310C" "\310D" "\310E" "\310F" "\3110" "\3111" "\3112" "\3113" "\3114" "\3115" "\3116" "\3117" "\3118" "\3119" "\311A" "\311B" "\311C" "\311D" "\311E" "\311F" "\3120" "\3121" "\3122" "\3123" "\3124" "\3125" "\3126" "\3127" "\3128" "\3129";
  /* ㄅㄆㄇㄈㄉㄊㄋㄌㄍㄎㄏㄐㄑㄒㄓㄔㄕㄖㄗㄘㄙㄚㄛㄜㄝㄞㄟㄠㄡㄢㄣㄤㄥㄦㄧㄨㄩ */
  suffix: "、";
}

Example: image image image

nt1m commented 1 month ago

@vitorroriz

r12a commented 1 month ago

Whether or not this is recommended for inclusion in the CSS spec, and whether or not there are similar bopomofo-based counter styles, we could add this style to https://www.w3.org/TR/predefined-counter-styles/#chinese-styles (or to a new section therein). Should i do that?

r12a commented 1 month ago

Off topic

I noticed a curious feature of this style. The numbers 111, 222, 333, 444, etc. all end with the same letter.

ㄆㄩ、111 ㄉㄩ、222 ㄌㄩ、333 ㄏㄩ、444 ㄒㄩ、555

I tried it using https://r12a.github.io/app-counters/. At first, i thought my app was broken, but in fact it's because these numbers are all multiples of 37. I just thought that was an interesting factoid.

vitorroriz commented 1 month ago

I'm not able to judge the correctness of the style unfortunately. @r12a Is this something you think could be on UA styles rather than predefined?

r12a commented 1 month ago

@vitorroriz I don't think it's necessary to add this to browser style sheets if there are questions about the conventions of use. The Custom Counter Styles doc is intended to provide a customisable, tweakable starting point for content authors to define what they actually want to see in their document.

nt1m commented 1 month ago

@r12a @vitorroriz As of #8636, all pre-defined counter styles are required to be supported by the user agent (I think that's a good thing personally).

NightFurySL2001 commented 1 month ago

Seems to be common in certain publishers: image image https://taiwanebook.ncl.edu.tw/zh-tw/book/NTUL-2495770 image https://taiwanebook.ncl.edu.tw/zh-tw/book/NLPI-31120003401436

but I do understand if its not accepted.

jfkthame commented 1 month ago

Given the examples here, this seems like a pretty reasonable addition IMO.

NightFurySL2001 commented 1 month ago

Additional references from 國語辭典 (1948) : image image image

jfkthame commented 1 month ago

Is further CSS WG discussion needed here, or can it just be left to the i18n group to add this to the collection in https://www.w3.org/TR/predefined-counter-styles/? This is referenced from the CSS Counter Styles spec, so that should be sufficient for it to be added to browsers.

r12a commented 1 month ago

I'm planning to add the style to the predefined-counter-styles doc either tomorrow or Friday.

r12a commented 4 weeks ago

PR is at https://github.com/w3c/predefined-counter-styles/pull/66

@NFSL2001 what name should i use for you in the Acknowledgements section?

Btw, it's listed under the heading Bopomofo because that's the name of the writing system in Unicode.

NightFurySL2001 commented 4 weeks ago

Thank you, using '@NFSL2001' is fine. Agree to put under Bopomofo.

r12a commented 4 weeks ago

Published! Many thanks for the proposal, @NightFurySL2001. https://w3c.social/@webi18n/112966707496248878