@sltsh/aion-tokens 1.2.0 → 1.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/states.js CHANGED
@@ -1,8 +1,8 @@
1
- import { compositeEmitted } from './oklch.js';
2
- import { ACCENTS, SYNTAX, comment, diffWash, findMatch, neutral, overlay } from './palette.js';
3
- import { lightComment, lightDecoration, lightDiffWash, lightEditorNeutral, lightFindMatch, lightOverlay, lightSyntax, } from './light.js';
1
+ import { compositeCssAlpha } from './oklch.js';
2
+ import { ACCENTS, SYNTAX, comment, decoration, diffWash, findMatch, neutral, overlay, secondaryDecoration } from './palette.js';
3
+ import { lightComment, lightDecoration, lightDiffWash, lightEditorNeutral, lightFindMatch, lightOverlay, lightSecondaryDecoration, lightSyntax, } from './light.js';
4
4
  export const SHIPPED = {
5
- neutral, overlay, diffWash, findMatch, comment,
5
+ neutral, overlay, diffWash, findMatch, comment, decoration, secondaryDecoration,
6
6
  syntax: Object.fromEntries(Object.keys(SYNTAX).map((role) => [role, ACCENTS[SYNTAX[role]]])),
7
7
  };
8
8
  export const LIGHT_SHIPPED = {
@@ -13,6 +13,7 @@ export const LIGHT_SHIPPED = {
13
13
  comment: lightComment,
14
14
  syntax: lightSyntax,
15
15
  decoration: lightDecoration,
16
+ secondaryDecoration: lightSecondaryDecoration,
16
17
  };
17
18
  const surfaces = (source) => ({
18
19
  editor: source.neutral.editor,
@@ -22,96 +23,133 @@ const surfaces = (source) => ({
22
23
  // it covers can raise it, which is why it may be the loudest decoration in the editor.
23
24
  findMatch: source.findMatch.current,
24
25
  });
25
- // A stack is the decorations the native editor paints over one another on the same
26
- // characters. A selection and a word highlight can both land on a word the caret is
27
- // already inside, so that pair is real.
28
- //
29
- // The current line and a selection cannot stack: VS Code renders the current-line
30
- // background only while every selection is empty, in `_shouldRenderInContent`. Gating a
31
- // state the renderer never produces held the current line at 1.05:1 against the editor
32
- // for no reader's benefit.
33
- const EDITOR_STACKS = [
34
- [],
35
- ['lineHighlight'],
36
- ['selection'],
37
- ['wordHighlight'],
38
- ['lineHighlight', 'wordHighlight'],
39
- ['selection', 'wordHighlight'],
26
+ export const RENDER_ORDER = [
27
+ 'lineHighlight', 'selection', 'inactiveSelection',
28
+ 'mergeCurrentHeader', 'mergeCommonHeader', 'mergeIncomingHeader',
29
+ 'focusedStackFrame', 'stackFrame', 'unchangedCode', 'findRange', 'fold',
30
+ 'removedLine', 'addedLine', 'mergeChange', 'rangeHighlight',
31
+ 'bracketMatch', 'removedWord', 'addedWord', 'covered', 'uncovered', 'hover',
32
+ 'mergeChangeWord', 'searchMatch', 'selectionHighlight', 'symbol',
33
+ 'wordHighlight', 'strongWord', 'findMatchOther', 'commentRange', 'activeCommentRange',
40
34
  ];
41
- const STACKS = {
42
- editor: EDITOR_STACKS,
43
- peekEditor: EDITOR_STACKS,
44
- hoverWidget: [[]],
45
- findMatch: [[], ['wordHighlight']],
35
+ // Light's decorations sit in three tiers by painted shift from the editor. Tier 1 is the
36
+ // selection, tier 2 the reading cues a reader looks for, tier 3 everything that only has to
37
+ // be seen. One ratio separates adjacent tiers; the owner approved it in Gate C.
38
+ export const LIGHT_TIER_RATIO = 1.35;
39
+ export const LIGHT_TIER = {
40
+ 1: ['selection'],
41
+ 2: ['wordHighlight', 'strongWord', 'selectionHighlight', 'findMatchOther', 'searchMatch',
42
+ 'addedWord', 'removedWord'],
43
+ 3: ['lineHighlight', 'inactiveSelection', 'findRange', 'fold', 'rangeHighlight', 'hover',
44
+ 'symbol', 'bracketMatch', 'stackFrame', 'focusedStackFrame', 'mergeCurrentHeader',
45
+ 'mergeCommonHeader', 'mergeIncomingHeader', 'unchangedCode', 'mergeChange', 'mergeChangeWord',
46
+ 'covered', 'uncovered', 'commentRange', 'activeCommentRange', 'addedLine', 'removedLine'],
46
47
  };
47
- // A diff wash goes on top of the selection, not under it. VS Code registers
48
- // `DecorationsOverlay` after `SelectionsOverlay` and both render into the same line
49
- // element in registration order, so the wash is the last layer before the glyph. The
50
- // bases it sits on are the plain line, the current line and the selection.
51
- const DIFF_LAYERS = [
52
- ['addedLine'],
53
- ['addedLine', 'addedWord'],
54
- ['removedLine'],
55
- ['removedLine', 'removedWord'],
48
+ const BASES = [[], ['lineHighlight'], ['selection'], ['inactiveSelection']];
49
+ const DIFFS = [[], ['addedLine'], ['addedLine', 'addedWord'], ['removedLine'],
50
+ ['removedLine', 'removedWord']];
51
+ const READING_TOPS = ['wordHighlight', 'findMatchOther', 'selectionHighlight'];
52
+ const OTHER_TOPS = [
53
+ 'findRange', 'rangeHighlight', 'fold', 'hover', 'symbol', 'strongWord', 'stackFrame',
54
+ 'focusedStackFrame', 'bracketMatch', 'commentRange', 'activeCommentRange',
55
+ 'mergeCurrentHeader', 'mergeIncomingHeader', 'mergeCommonHeader', 'mergeChange',
56
+ 'mergeChangeWord', 'searchMatch', 'covered', 'uncovered', 'unchangedCode',
56
57
  ];
57
- const DIFF_BASES = [[], ['lineHighlight'], ['selection']];
58
- // The other matches are a wash, and their own registration says they must be, so that the
59
- // decorations under them still read. The decoration renders in an editor, so the surfaces
60
- // are the editor and the peek editor, not a widget.
61
- const OTHER_MATCH_BASES = [
62
- [], ['lineHighlight'], ['selection'], ['selection', 'wordHighlight'],
63
- ];
64
- // The decorations VS Code paints in `DecorationsOverlay` land over the current line or the
65
- // selection. The inactive selection replaces the selection and, being a selection, never
66
- // shares a line with the current-line fill.
67
- const DECORATION_BASES = {
68
- selectionHighlight: [[], ['lineHighlight'], ['selection']],
69
- findRange: [[], ['lineHighlight'], ['selection']],
70
- rangeHighlight: [[], ['lineHighlight'], ['selection']],
71
- fold: [[], ['lineHighlight'], ['selection']],
72
- inactiveSelection: [[]],
58
+ const BASE = new Set(['lineHighlight', 'selection', 'inactiveSelection']);
59
+ const ADDED = new Set(['addedLine', 'addedWord']);
60
+ const REMOVED = new Set(['removedLine', 'removedWord']);
61
+ const TOP = new Set(READING_TOPS);
62
+ const OTHER = new Set(OTHER_TOPS);
63
+ const MERGE_EDITOR = new Set(['mergeChange', 'mergeChangeWord']);
64
+ // hideUnchangedRegionsFeature.ts applies diff-unchanged-lines to unchanged
65
+ // ranges, so it cannot occupy a character with an inserted or removed line.
66
+ // Merge Editor CodeEditorView creates its own widgets and applies editor-owned
67
+ // decorations; DiffEditorEditors creates separate widgets for the diff collections.
68
+ export function producible(layers) {
69
+ if ([...layers].some((name) => MERGE_EDITOR.has(name)) &&
70
+ [...layers].some((name) => ADDED.has(name) || REMOVED.has(name) || name === 'unchangedCode' || name === 'fold'))
71
+ return false;
72
+ if (layers.has('unchangedCode') &&
73
+ [...layers].some((name) => ADDED.has(name) || REMOVED.has(name)))
74
+ return false;
75
+ if ([...layers].filter((name) => BASE.has(name)).length > 1)
76
+ return false;
77
+ if ([...layers].some((name) => ADDED.has(name)) &&
78
+ [...layers].some((name) => REMOVED.has(name)))
79
+ return false;
80
+ if (layers.has('addedWord') && !layers.has('addedLine'))
81
+ return false;
82
+ if (layers.has('removedWord') && !layers.has('removedLine'))
83
+ return false;
84
+ return true;
85
+ }
86
+ // Coverage is the stated combinatorial bound intersected with producible.
87
+ // This co-occurrence bound is a product decision, not a renderer exclusion.
88
+ // The renderer permits more inline combinations than the guarantee enumerates.
89
+ export function covered(layers) {
90
+ if (!producible(layers))
91
+ return false;
92
+ const others = [...layers].filter((name) => OTHER.has(name));
93
+ return others.length <= 1 && (others.length === 0 ||
94
+ ![...layers].some((name) => TOP.has(name)));
95
+ }
96
+ export const orderStack = (layers) => RENDER_ORDER.filter((name) => layers.has(name));
97
+ export const stackName = (surface, layers) => [surface, ...layers].join(' + ');
98
+ const coveredStacks = () => {
99
+ const stacks = [];
100
+ for (const base of BASES)
101
+ for (const diff of DIFFS) {
102
+ const pair = [...base, ...diff];
103
+ for (let mask = 0; mask < (1 << READING_TOPS.length); mask += 1) {
104
+ const layers = new Set(pair);
105
+ READING_TOPS.forEach((name, index) => { if (mask & (1 << index))
106
+ layers.add(name); });
107
+ if (covered(layers))
108
+ stacks.push(orderStack(layers));
109
+ }
110
+ for (const name of OTHER_TOPS) {
111
+ const layers = new Set([...pair, name]);
112
+ if (covered(layers))
113
+ stacks.push(orderStack(layers));
114
+ }
115
+ }
116
+ return stacks;
73
117
  };
74
- // The complete set of backgrounds the contrast guarantee covers. Anything absent here is
75
- // outside the claim, and `README.md` says so rather than implying every state passes.
118
+ const EDITOR_STACKS = coveredStacks();
119
+ // Peek retains the legacy base/reading-top/decoration domain. New secondary
120
+ // contexts are not claimed without positive applicability evidence for a peek widget.
121
+ const SECONDARY = new Set(Object.keys(secondaryDecoration));
122
+ const PEEK_STACKS = EDITOR_STACKS.filter((stack) => !stack.some((name) => ADDED.has(name) || REMOVED.has(name) || SECONDARY.has(name)));
123
+ // colorThemeCss.ts emits Color.toString() for CSS variables; direct theming rules
124
+ // interpolate the same Color. HexA parsing rounds alpha to three decimals, then
125
+ // CSS.formatRGBA rounds to two. Selection highlight additionally calls transparent(.5).
126
+ export function paintedAlpha(name, authored) {
127
+ const emitted = Math.round(authored * 255) / 255;
128
+ const parsed = Math.round(emitted * 1000) / 1000;
129
+ const painted = name === 'selectionHighlight' ? Math.round(parsed * 0.5 * 1000) / 1000 : parsed;
130
+ return Number(painted.toFixed(2));
131
+ }
132
+ export function stackBackground(source, base, layers) {
133
+ return layers.reduce((under, name) => {
134
+ const value = name in source.overlay ? source.overlay[name]
135
+ : name in source.diffWash ? source.diffWash[name]
136
+ : name in source.decoration ? source.decoration[name]
137
+ : source.secondaryDecoration[name];
138
+ return compositeCssAlpha(value.color, paintedAlpha(name, value.alpha), under);
139
+ }, base);
140
+ }
76
141
  export function readingStates(source = SHIPPED) {
77
- const stackOn = (base, names) => names.reduce((under, name) => compositeEmitted(source.overlay[name].color, source.overlay[name].alpha, under), base);
78
- const washOn = (base, names) => names.reduce((under, name) => compositeEmitted(source.diffWash[name].color, source.diffWash[name].alpha, under), base);
79
142
  const surface = surfaces(source);
80
143
  const rows = [];
81
- for (const [name, base] of Object.entries(surface)) {
82
- for (const stack of STACKS[name]) {
83
- rows.push({ name: [name, ...stack].join(' + '), background: stackOn(base, stack) });
84
- }
85
- }
86
- for (const base of DIFF_BASES) {
87
- for (const layer of DIFF_LAYERS) {
88
- rows.push({
89
- name: ['editor', ...base, ...layer].join(' + '),
90
- background: washOn(stackOn(surface.editor, base), layer),
91
- });
92
- }
144
+ for (const stack of EDITOR_STACKS) {
145
+ rows.push({ name: stackName('editor', stack), background: stackBackground(source, surface.editor, stack) });
93
146
  }
94
- for (const base of OTHER_MATCH_BASES) {
95
- for (const name of ['editor', 'peekEditor']) {
96
- rows.push({
97
- name: [name, ...base, 'findMatchOther'].join(' + '),
98
- background: stackOn(stackOn(surface[name], base), ['findMatchOther']),
99
- });
100
- }
101
- }
102
- if (source.decoration !== undefined) {
103
- const decoration = source.decoration;
104
- for (const [name, bases] of Object.entries(DECORATION_BASES)) {
105
- for (const base of bases) {
106
- for (const surfaceName of ['editor', 'peekEditor']) {
107
- rows.push({
108
- name: [surfaceName, ...base, name].join(' + '),
109
- background: compositeEmitted(decoration[name].color, decoration[name].alpha, stackOn(surface[surfaceName], base)),
110
- });
111
- }
112
- }
113
- }
147
+ for (const stack of PEEK_STACKS) {
148
+ rows.push({ name: stackName('peekEditor', stack), background: stackBackground(source, surface.peekEditor, stack) });
114
149
  }
150
+ rows.push({ name: 'hoverWidget', background: surface.hoverWidget });
151
+ rows.push({ name: 'findMatch', background: surface.findMatch });
152
+ rows.push({ name: 'findMatch + wordHighlight', background: surface.findMatch });
115
153
  return rows;
116
154
  }
117
155
  export const readingForegrounds = (source = SHIPPED) => ({
@@ -1 +1 @@
1
- {"version":3,"file":"states.js","sourceRoot":"","sources":["../src/states.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,gBAAgB,EAAE,MAAM,YAAY,CAAC;AAE9C,OAAO,EAAE,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,QAAQ,EAAE,SAAS,EAAE,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc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B,GAAG,CAAC,SAAsB,OAAO,EAAyB,EAAE,CAAC,CAAC;IAC3F,OAAO,EAAE,MAAM,CAAC,OAAO;IACvB,WAAW,EAAE,MAAM,CAAC,OAAO,CAAC,aAAa;IACzC,GAAG,MAAM,CAAC,MAAM;CACjB,CAAC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sltsh/aion-tokens",
3
- "version": "1.2.0",
3
+ "version": "1.3.0",
4
4
  "description": "The Aion colour system: OKLCH definitions, contrast invariants and sRGB emitters.",
5
5
  "license": "MIT",
6
6
  "type": "module",