Page MenuHomePhabricator

Provide `tab-size` option and decision token
Closed, ResolvedPublic

Description

Background

A small token category, best in typography meta category situated: We also need to define tab-size. It's used in a few places in MediaWiki, and also in VitePress default styles.
This has to be a theme decision that we have to be able to cover.

Context is theme-ability of typographic style in <code> or <pre> elements, in an example like this:
https://www.mediawiki.org/wiki/Manual:Coding_conventions/CSS#Specificity

As folks have strong opinion over text styles, this might be asked to change when using Codex in context outside MediaWiki.

Proposal

theme options:
tab-size-100: 4

decisions
tab-size-base: tab-size-100

Goal

Define tab-size option and decision tokens.
With default value 4 in WikimediaUI theme.

Related Objects

StatusSubtypeAssignedTask
Duplicate STH
InvalidNone
In ProgressVolker_E
ResolvedNone
Resolvedbmartinezcalvo
In ProgressVolker_E
ResolvedVolker_E
ResolvedVolker_E
ResolvedVolker_E
Resolvedldelench_wmf
ResolvedVolker_E
Resolved EUdoh-WMF
OpenSarai-WMDE
ResolvedVolker_E
ResolvedSarai-WMDE
ResolvedCatrope
OpenNone
Resolvedovasileva
ResolvedBUG REPORTVolker_E
ResolvedVolker_E
ResolvedVolker_E
ResolvedVolker_E
ResolvedVolker_E
ResolvedSarai-WMDE
ResolvedVolker_E
Resolvedbmartinezcalvo
ResolvedCatrope
ResolvedDAbad
ResolvedVolker_E

Event Timeline

Change 855152 had a related patch set uploaded (by VolkerE; author: VolkerE):

[design/codex@main] [WIP] tokens: Add `tab-size` token

https://gerrit.wikimedia.org/r/855152

The classification of this token as part of the typography category appears to make sense. Would there be any other tab-size values that we'd need to document? Also: what's the reason we don't use the default value?

What you mention...

This has to be a theme decision that we have to be able to cover.

Would be enough to justify the creation of this single token. Nevertheless, it'd be great to document the exact use case that we're trying to cover and its reach. Neither this ticket nor the patch include any details regarding why is this token needed and how it will be used.

Change 855152 merged by jenkins-bot:

[design/codex@main] tokens: Add `tab-size` token

https://gerrit.wikimedia.org/r/855152

A small token category, best in typography meta category situated.

I need a little push to be convinced of the need to document this in Figma. We're making this token available specially for themers: do designers need to be exposed to this property? What do you think, @Volker_E and @bmartinezcalvo?

Not necessarily. There could be a minor case for layouting code blocks, but I think that's so rare that the existence of the token might be still not relied on.

Change 865151 had a related patch set uploaded (by Eric Gardner; author: Eric Gardner):

[mediawiki/core@master] Update Codex from v0.3.0 to v0.4.0

https://gerrit.wikimedia.org/r/865151

Change 865151 merged by jenkins-bot:

[mediawiki/core@master] Update Codex from v0.3.0 to v0.4.0

https://gerrit.wikimedia.org/r/865151

Volker_E claimed this task.