Re: [csswg-drafts] [css-lists] How to control the gap between the marker and the text? (#4571)

Ok, reading further, `::marker` is specified in [[CSS-DISPLAY-3]](https://www.w3.org/TR/css-pseudo-4/#biblio-css-display-3) and [[CSS-LISTS-3]](https://www.w3.org/TR/css-pseudo-4/#biblio-css-lists-3).

CSS Counter styles 3 tells the [following about the predefined symbolic markers (6.3)](https://drafts.csswg.org/css-counter-styles-3/#simple-symbolic):
```

@counter-style disc {
  system: cyclic;
  symbols: \2022;
  /* • */
  suffix: " ";
}

@counter-style circle {
  system: cyclic;
  symbols: \25E6;
  /* ◦ */
  suffix: " ";
}

@counter-style square {
  system: cyclic;
  symbols: \25AA;
  /* ▪ */
  suffix: " ";
}
```

There's no way to override the suffix in any way. You can only create your own counter style fragment and set the list-style-type to it.

But, if you compare the predefined counter styles, e.g. disc, you'll notice that implementation is not exactly the same. The gap is not the same and the size is different. All tests pass, and there is only one test for symbolic counter styles, `disclosure-open` and `disclosure-closed`: https://test.csswg.org/harness/test/css-counter-styles-3_dev/single/disclosure-styles/format/html5/

And the tests themselves are invalid. they use `disclosure-open2` and `disclosure-closed2` instead of overriding `disclosure-open` and `disclosure-closed`. So there's no way to override predefined `@counter-style`, their implementation seems to be completely detached from the fragment.

I think the test should be modified and extended:

1. Add more predefined markers
2. Test the ability to override user-agent's `@counter-style`
3. Test the ability to create your own `@counter-style`

-- 
GitHub Notification of comment by Vanuan
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/4571#issuecomment-2231726656 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Tuesday, 16 July 2024 19:58:18 UTC