@inchurch/matcha-theme 21.4.0 → 22.1.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.
Files changed (94) hide show
  1. package/abstracts/_colors.scss +236 -236
  2. package/abstracts/_elevation.scss +108 -108
  3. package/abstracts/_functions.scss +321 -321
  4. package/abstracts/_media-breakpoint.scss +26 -26
  5. package/abstracts/_theme-api.scss +219 -219
  6. package/abstracts/_typography.scss +128 -128
  7. package/base/_reset.scss +446 -445
  8. package/components/app-page-header.scss +260 -260
  9. package/components/matcha-accordion.scss +293 -293
  10. package/components/matcha-audio-player.scss +31 -31
  11. package/components/matcha-autocomplete.scss +145 -145
  12. package/components/matcha-avatar.scss +440 -301
  13. package/components/matcha-badge.scss +120 -120
  14. package/components/matcha-breadcrumb.scss +231 -231
  15. package/components/matcha-button-toggle.scss +383 -384
  16. package/components/matcha-buttons.scss +913 -913
  17. package/components/matcha-calendar.scss +218 -218
  18. package/components/matcha-cards.scss +230 -230
  19. package/components/matcha-chart-card.scss +53 -53
  20. package/components/matcha-checkbox.scss +255 -255
  21. package/components/matcha-chip.scss +292 -292
  22. package/components/matcha-color-pick.scss +34 -34
  23. package/components/matcha-command-palette.scss +316 -316
  24. package/components/matcha-contact.scss +35 -0
  25. package/components/matcha-crop.scss +406 -406
  26. package/components/matcha-date.scss +81 -81
  27. package/components/matcha-divider.scss +100 -100
  28. package/components/matcha-draggable.scss +23 -23
  29. package/components/matcha-drawer.scss +376 -376
  30. package/components/matcha-drop-image.scss +14 -14
  31. package/components/matcha-drop-list.scss +430 -430
  32. package/components/matcha-emoji.scss +69 -69
  33. package/components/matcha-empty-state.scss +230 -230
  34. package/components/matcha-file-uploader.scss +471 -471
  35. package/components/matcha-flag.scss +103 -103
  36. package/components/matcha-footer.scss +91 -91
  37. package/components/matcha-form-field.scss +606 -606
  38. package/components/matcha-form-section.scss +100 -100
  39. package/components/matcha-header.scss +135 -135
  40. package/components/matcha-highlight.scss +164 -164
  41. package/components/matcha-hint-text.scss +90 -90
  42. package/components/matcha-horizontal-tree.scss +316 -316
  43. package/components/matcha-icon.scss +98 -98
  44. package/components/matcha-image.scss +61 -61
  45. package/components/matcha-list.scss +211 -211
  46. package/components/matcha-menu.scss +99 -99
  47. package/components/matcha-modal.scss +210 -210
  48. package/components/matcha-nav.scss +581 -581
  49. package/components/matcha-notification.scss +413 -413
  50. package/components/matcha-option.scss +170 -170
  51. package/components/matcha-page-builder.scss +4196 -4196
  52. package/components/matcha-paginator.scss +689 -689
  53. package/components/matcha-panel.scss +194 -194
  54. package/components/matcha-profile-card.scss +50 -50
  55. package/components/matcha-progress-bar.scss +313 -313
  56. package/components/matcha-radio.scss +320 -320
  57. package/components/matcha-ripple.scss +7 -7
  58. package/components/matcha-scrollbar.scss +33 -33
  59. package/components/matcha-scrollbox-shadow.scss +120 -120
  60. package/components/matcha-section.scss +102 -102
  61. package/components/matcha-select-multiple.scss +56 -56
  62. package/components/matcha-select.scss +667 -667
  63. package/components/matcha-skeleton.scss +155 -155
  64. package/components/matcha-slide-toggle.scss +369 -369
  65. package/components/matcha-slider.scss +285 -285
  66. package/components/matcha-snack-bar.scss +259 -259
  67. package/components/matcha-spin.scss +164 -164
  68. package/components/matcha-spinner.scss +97 -97
  69. package/components/matcha-status-pill.scss +38 -18
  70. package/components/matcha-stepper.scss +376 -376
  71. package/components/matcha-table-cell.scss +49 -41
  72. package/components/matcha-table.scss +579 -579
  73. package/components/matcha-tabs.scss +600 -600
  74. package/components/matcha-text-editor.scss +105 -105
  75. package/components/matcha-time.scss +33 -33
  76. package/components/matcha-timepicker.scss +13 -13
  77. package/components/matcha-toolbar.scss +359 -359
  78. package/components/matcha-tooltip.scss +224 -224
  79. package/components/matcha-tree-view.scss +257 -257
  80. package/layout/matcha-page-layout.scss +778 -778
  81. package/main.scss +331 -329
  82. package/package.json +1 -1
  83. package/tokens/_animations-tokens.scss +37 -37
  84. package/tokens/_breakpoints-tokens.scss +35 -35
  85. package/tokens/_color-tokens.scss +274 -274
  86. package/tokens/_elevation-tokens.scss +33 -33
  87. package/tokens/_emit-tokens.scss +324 -324
  88. package/tokens/_material-palette.scss +1149 -1149
  89. package/tokens/_primitives.scss +98 -98
  90. package/tokens/_semantic-aliases.scss +120 -120
  91. package/tokens/_spacing-tokens.scss +94 -94
  92. package/tokens/_static-tokens.scss +137 -137
  93. package/tokens/_typography-tokens.scss +65 -65
  94. package/vendors/charts.scss +90 -90
@@ -1,237 +1,237 @@
1
- @use "functions" as *;
2
- @use "../tokens/primitives" as *;
3
- @use "sass:list";
4
-
5
- // Shade-classes SÓ das primitivas do Figma ($matcha-primitives — gerado de
6
- // tokens/matcha/primitives/colors.json pelo gen-primitives). Cada classe consome
7
- // var(--matcha-prim-{família}-{shade}); o contraste é computado em build a partir
8
- // do hex da primitiva (mode-independent — primitiva é valor fixo). Famílias não-paleta
9
- // (common/brand/neutral) ficam de fora. Substitui a antiga matriz Material 21×14
10
- // (getAllPalettes/$theme), que gerava "todas as cores" — agora só o que existe no Figma.
11
- @mixin colors-classes-static($theme: ()) {
12
- // theme-agnóstico: classes consomem var(--matcha-prim-*). $theme vestigial (default ()).
13
- $-skip: ("common", "brand", "neutral");
14
-
15
- @each $family, $shades in $matcha-primitives {
16
- @if not list.index($-skip, $family) {
17
- @each $shade, $hex in $shades {
18
- .#{$family}-#{$shade} {
19
- background-color: var(--matcha-prim-#{$family}-#{$shade}) !important;
20
- color: matcha-contrast-on($hex) !important;
21
- }
22
-
23
- .#{$family}-#{$shade}-bg {
24
- background-color: var(--matcha-prim-#{$family}-#{$shade}) !important;
25
- }
26
-
27
- .#{$family}-#{$shade}-fg {
28
- color: var(--matcha-prim-#{$family}-#{$shade}) !important;
29
- }
30
- }
31
- }
32
- }
33
- }
34
-
35
- // -------------------------------------------------------------------------------------------------------------------
36
- // @ Dynamic color classes generator
37
- // -------------------------------------------------------------------------------------------------------------------
38
- @mixin colors-classes-dynamic($theme: ()) {
39
- // theme-agnóstico: classes consomem var(--matcha-color-*). $theme vestigial (default ()).
40
- // Inclui colors-classes-static (linha abaixo) — app.theme chama SÓ este (sem dup).
41
-
42
- // Nomes de cor que viram utility classes. TODOS (semânticas + paleta) consomem
43
- // var(--matcha-color-*). As cores de paleta agora têm tokens emitidos no tema
44
- // (ver _emit-tokens — base/alpha/contrast mode-flipped), então o caminho
45
- // compile-time getRed($theme)/Material foi eliminado aqui. Value-preserving.
46
- $color-names: "red", "pink", "purple", "deep-purple", "indigo", "blue", "light-blue", "cyan", "teal",
47
- "green", "light-green", "lime", "yellow", "amber", "orange", "deep-orange", "brown", "grey", "blue-grey",
48
- "primary", "accent", "danger", "warn", "success", "info", "disabled";
49
-
50
- @include colors-classes-static($theme);
51
-
52
- @each $colorName in $color-names {
53
- .background-#{$colorName}-alpha {
54
- background: var(--matcha-color-#{$colorName}-alpha);
55
- }
56
-
57
- .#{$colorName} .ripple {
58
- background: var(--matcha-color-#{$colorName}-alpha);
59
- }
60
-
61
- .background-#{$colorName} {
62
- background: var(--matcha-color-#{$colorName});
63
- }
64
-
65
- .border-color-#{$colorName} {
66
- border-color: var(--matcha-color-#{$colorName});
67
- }
68
-
69
- .color-#{$colorName} {
70
- color: var(--matcha-color-#{$colorName}) !important;
71
- }
72
-
73
- .fill-#{$colorName} {
74
- fill: var(--matcha-color-#{$colorName});
75
- }
76
-
77
- .stroke-#{$colorName} {
78
- stroke: var(--matcha-color-#{$colorName});
79
- }
80
-
81
- .color-#{$colorName}-alpha {
82
- color: var(--matcha-color-#{$colorName}-alpha) !important;
83
- }
84
-
85
- .#{$colorName}-alpha {
86
- background: var(--matcha-color-#{$colorName}-alpha);
87
- color: var(--matcha-color-#{$colorName});
88
- }
89
-
90
- .#{$colorName} {
91
- background: var(--matcha-color-#{$colorName});
92
- color: var(--matcha-color-#{$colorName}-contrast);
93
- }
94
- }
95
-
96
- .background-basic-alpha {
97
- background: var(--matcha-color-fg-alpha);
98
- }
99
-
100
- .basic .ripple {
101
- background: var(--matcha-color-fg-alpha);
102
- }
103
-
104
- .background-basic {
105
- background: var(--matcha-color-surface);
106
- }
107
-
108
- .border-color-basic {
109
- border-color: var(--matcha-color-fg);
110
- }
111
-
112
- .color-basic {
113
- color: var(--matcha-color-fg) !important;
114
- }
115
-
116
- .fill-basic {
117
- fill: var(--matcha-color-surface);
118
- }
119
-
120
- .stroke-basic {
121
- stroke: var(--matcha-color-fg);
122
- }
123
-
124
- .color-basic-alpha {
125
- color: var(--matcha-color-fg-alpha) !important;
126
- }
127
-
128
- .basic-alpha {
129
- background: var(--matcha-color-fg-alpha);
130
- color: var(--matcha-color-fg);
131
- }
132
-
133
- .basic {
134
- background: var(--matcha-color-surface);
135
- color: var(--matcha-color-fg);
136
- }
137
-
138
- // Semantic surface & foreground aliases (used throughout templates)
139
- .background-fg { background: var(--matcha-color-fg); }
140
- .background-bg { background: var(--matcha-color-surface-bg); }
141
- .background-bg-alpha { background: var(--matcha-color-surface-bg-alpha); }
142
- .background-surface { background: var(--matcha-color-surface); }
143
- .background-surface-alpha { background: var(--matcha-color-surface-card-alpha); }
144
- .background-hint { background: var(--matcha-color-hint); }
145
- .color-fg { color: var(--matcha-color-fg) !important; }
146
- .color-hint { color: var(--matcha-color-hint) !important; }
147
- .color-label { color: var(--matcha-color-text-label) !important; }
148
- .color-placeholder { color: var(--matcha-color-text-placeholder) !important; }
149
-
150
- // Papéis de TEXTO semânticos (o gerador acima cobre fg/hint/label/placeholder,
151
- // mas NÃO os text-*). Consumidos amplamente nos templates do painel.
152
- .color-text-primary { color: var(--matcha-color-text-primary) !important; }
153
- .color-text-secondary { color: var(--matcha-color-text-secondary) !important; }
154
- .color-text-muted { color: var(--matcha-color-text-muted) !important; }
155
- .color-text-hint { color: var(--matcha-color-text-hint) !important; }
156
-
157
- .color-unset {
158
- color: unset;
159
- }
160
-
161
- .background-transparent {
162
- background: transparent;
163
- }
164
-
165
- $attributes: (
166
- color,
167
- border-color,
168
- background,
169
- fill,
170
- stroke
171
- );
172
-
173
- @each $attribute in $attributes {
174
- @if ($attribute !="color") {
175
- .#{$attribute}-bg {
176
- #{$attribute}: var(--matcha-color-surface-bg) !important;
177
- }
178
-
179
- .#{$attribute}-bg-alpha {
180
- #{$attribute}: var(--matcha-color-surface-bg-alpha) !important;
181
- }
182
-
183
- .#{$attribute}-bg-inverse {
184
- #{$attribute}: var(--matcha-color-surface-bg-inverse) !important;
185
- }
186
-
187
- .#{$attribute}-bg-alpha-inverse {
188
- #{$attribute}: var(--matcha-color-surface-bg-inverse-alpha) !important;
189
- }
190
-
191
- .#{$attribute}-surface-inverse {
192
- #{$attribute}: var(--matcha-color-surface-card-inverse) !important;
193
- }
194
- }
195
-
196
- .#{$attribute}-fg,
197
- .#{$attribute}-base,
198
- .#{$attribute}-text {
199
- #{$attribute}: var(--matcha-color-fg) !important;
200
- }
201
-
202
- .#{$attribute}-fg-inverse,
203
- .#{$attribute}-base-inverse,
204
- .#{$attribute}-text-inverse {
205
- #{$attribute}: var(--matcha-color-fg-inverse) !important;
206
- }
207
-
208
- .#{$attribute}-surface {
209
- #{$attribute}: var(--matcha-color-surface) !important;
210
- }
211
-
212
- .#{$attribute}-surface-alpha {
213
- #{$attribute}: var(--matcha-color-surface-card-alpha) !important;
214
- }
215
-
216
- .#{$attribute}-placeholder {
217
- #{$attribute}: var(--matcha-color-text-placeholder) !important;
218
-
219
- &-alpha {
220
- // placeholder-alpha (raro/legado) — usa o token grey-alpha runtime.
221
- background: var(--matcha-color-grey-alpha) !important;
222
- }
223
- }
224
-
225
- .#{$attribute}-label {
226
- #{$attribute}: var(--matcha-color-text-label) !important;
227
- }
228
-
229
- .#{$attribute}-disabled {
230
- #{$attribute}: var(--matcha-color-disabled) !important;
231
- }
232
-
233
- .#{$attribute}-disabled-icon {
234
- #{$attribute}: var(--matcha-color-interaction-disabled-fg) !important;
235
- }
236
- }
1
+ @use "functions" as *;
2
+ @use "../tokens/primitives" as *;
3
+ @use "sass:list";
4
+
5
+ // Shade-classes SÓ das primitivas do Figma ($matcha-primitives — gerado de
6
+ // tokens/matcha/primitives/colors.json pelo gen-primitives). Cada classe consome
7
+ // var(--matcha-prim-{família}-{shade}); o contraste é computado em build a partir
8
+ // do hex da primitiva (mode-independent — primitiva é valor fixo). Famílias não-paleta
9
+ // (common/brand/neutral) ficam de fora. Substitui a antiga matriz Material 21×14
10
+ // (getAllPalettes/$theme), que gerava "todas as cores" — agora só o que existe no Figma.
11
+ @mixin colors-classes-static($theme: ()) {
12
+ // theme-agnóstico: classes consomem var(--matcha-prim-*). $theme vestigial (default ()).
13
+ $-skip: ("common", "brand", "neutral");
14
+
15
+ @each $family, $shades in $matcha-primitives {
16
+ @if not list.index($-skip, $family) {
17
+ @each $shade, $hex in $shades {
18
+ .#{$family}-#{$shade} {
19
+ background-color: var(--matcha-prim-#{$family}-#{$shade}) !important;
20
+ color: matcha-contrast-on($hex) !important;
21
+ }
22
+
23
+ .#{$family}-#{$shade}-bg {
24
+ background-color: var(--matcha-prim-#{$family}-#{$shade}) !important;
25
+ }
26
+
27
+ .#{$family}-#{$shade}-fg {
28
+ color: var(--matcha-prim-#{$family}-#{$shade}) !important;
29
+ }
30
+ }
31
+ }
32
+ }
33
+ }
34
+
35
+ // -------------------------------------------------------------------------------------------------------------------
36
+ // @ Dynamic color classes generator
37
+ // -------------------------------------------------------------------------------------------------------------------
38
+ @mixin colors-classes-dynamic($theme: ()) {
39
+ // theme-agnóstico: classes consomem var(--matcha-color-*). $theme vestigial (default ()).
40
+ // Inclui colors-classes-static (linha abaixo) — app.theme chama SÓ este (sem dup).
41
+
42
+ // Nomes de cor que viram utility classes. TODOS (semânticas + paleta) consomem
43
+ // var(--matcha-color-*). As cores de paleta agora têm tokens emitidos no tema
44
+ // (ver _emit-tokens — base/alpha/contrast mode-flipped), então o caminho
45
+ // compile-time getRed($theme)/Material foi eliminado aqui. Value-preserving.
46
+ $color-names: "red", "pink", "purple", "deep-purple", "indigo", "blue", "light-blue", "cyan", "teal",
47
+ "green", "light-green", "lime", "yellow", "amber", "orange", "deep-orange", "brown", "grey", "blue-grey",
48
+ "primary", "accent", "danger", "warn", "success", "info", "disabled";
49
+
50
+ @include colors-classes-static($theme);
51
+
52
+ @each $colorName in $color-names {
53
+ .background-#{$colorName}-alpha {
54
+ background: var(--matcha-color-#{$colorName}-alpha);
55
+ }
56
+
57
+ .#{$colorName} .ripple {
58
+ background: var(--matcha-color-#{$colorName}-alpha);
59
+ }
60
+
61
+ .background-#{$colorName} {
62
+ background: var(--matcha-color-#{$colorName});
63
+ }
64
+
65
+ .border-color-#{$colorName} {
66
+ border-color: var(--matcha-color-#{$colorName});
67
+ }
68
+
69
+ .color-#{$colorName} {
70
+ color: var(--matcha-color-#{$colorName}) !important;
71
+ }
72
+
73
+ .fill-#{$colorName} {
74
+ fill: var(--matcha-color-#{$colorName});
75
+ }
76
+
77
+ .stroke-#{$colorName} {
78
+ stroke: var(--matcha-color-#{$colorName});
79
+ }
80
+
81
+ .color-#{$colorName}-alpha {
82
+ color: var(--matcha-color-#{$colorName}-alpha) !important;
83
+ }
84
+
85
+ .#{$colorName}-alpha {
86
+ background: var(--matcha-color-#{$colorName}-alpha);
87
+ color: var(--matcha-color-#{$colorName});
88
+ }
89
+
90
+ .#{$colorName} {
91
+ background: var(--matcha-color-#{$colorName});
92
+ color: var(--matcha-color-#{$colorName}-contrast);
93
+ }
94
+ }
95
+
96
+ .background-basic-alpha {
97
+ background: var(--matcha-color-fg-alpha);
98
+ }
99
+
100
+ .basic .ripple {
101
+ background: var(--matcha-color-fg-alpha);
102
+ }
103
+
104
+ .background-basic {
105
+ background: var(--matcha-color-surface);
106
+ }
107
+
108
+ .border-color-basic {
109
+ border-color: var(--matcha-color-fg);
110
+ }
111
+
112
+ .color-basic {
113
+ color: var(--matcha-color-fg) !important;
114
+ }
115
+
116
+ .fill-basic {
117
+ fill: var(--matcha-color-surface);
118
+ }
119
+
120
+ .stroke-basic {
121
+ stroke: var(--matcha-color-fg);
122
+ }
123
+
124
+ .color-basic-alpha {
125
+ color: var(--matcha-color-fg-alpha) !important;
126
+ }
127
+
128
+ .basic-alpha {
129
+ background: var(--matcha-color-fg-alpha);
130
+ color: var(--matcha-color-fg);
131
+ }
132
+
133
+ .basic {
134
+ background: var(--matcha-color-surface);
135
+ color: var(--matcha-color-fg);
136
+ }
137
+
138
+ // Semantic surface & foreground aliases (used throughout templates)
139
+ .background-fg { background: var(--matcha-color-fg); }
140
+ .background-bg { background: var(--matcha-color-surface-bg); }
141
+ .background-bg-alpha { background: var(--matcha-color-surface-bg-alpha); }
142
+ .background-surface { background: var(--matcha-color-surface); }
143
+ .background-surface-alpha { background: var(--matcha-color-surface-card-alpha); }
144
+ .background-hint { background: var(--matcha-color-hint); }
145
+ .color-fg { color: var(--matcha-color-fg) !important; }
146
+ .color-hint { color: var(--matcha-color-hint) !important; }
147
+ .color-label { color: var(--matcha-color-text-label) !important; }
148
+ .color-placeholder { color: var(--matcha-color-text-placeholder) !important; }
149
+
150
+ // Papéis de TEXTO semânticos (o gerador acima cobre fg/hint/label/placeholder,
151
+ // mas NÃO os text-*). Consumidos amplamente nos templates do painel.
152
+ .color-text-primary { color: var(--matcha-color-text-primary) !important; }
153
+ .color-text-secondary { color: var(--matcha-color-text-secondary) !important; }
154
+ .color-text-muted { color: var(--matcha-color-text-muted) !important; }
155
+ .color-text-hint { color: var(--matcha-color-text-hint) !important; }
156
+
157
+ .color-unset {
158
+ color: unset;
159
+ }
160
+
161
+ .background-transparent {
162
+ background: transparent;
163
+ }
164
+
165
+ $attributes: (
166
+ color,
167
+ border-color,
168
+ background,
169
+ fill,
170
+ stroke
171
+ );
172
+
173
+ @each $attribute in $attributes {
174
+ @if ($attribute !="color") {
175
+ .#{$attribute}-bg {
176
+ #{$attribute}: var(--matcha-color-surface-bg) !important;
177
+ }
178
+
179
+ .#{$attribute}-bg-alpha {
180
+ #{$attribute}: var(--matcha-color-surface-bg-alpha) !important;
181
+ }
182
+
183
+ .#{$attribute}-bg-inverse {
184
+ #{$attribute}: var(--matcha-color-surface-bg-inverse) !important;
185
+ }
186
+
187
+ .#{$attribute}-bg-alpha-inverse {
188
+ #{$attribute}: var(--matcha-color-surface-bg-inverse-alpha) !important;
189
+ }
190
+
191
+ .#{$attribute}-surface-inverse {
192
+ #{$attribute}: var(--matcha-color-surface-card-inverse) !important;
193
+ }
194
+ }
195
+
196
+ .#{$attribute}-fg,
197
+ .#{$attribute}-base,
198
+ .#{$attribute}-text {
199
+ #{$attribute}: var(--matcha-color-fg) !important;
200
+ }
201
+
202
+ .#{$attribute}-fg-inverse,
203
+ .#{$attribute}-base-inverse,
204
+ .#{$attribute}-text-inverse {
205
+ #{$attribute}: var(--matcha-color-fg-inverse) !important;
206
+ }
207
+
208
+ .#{$attribute}-surface {
209
+ #{$attribute}: var(--matcha-color-surface) !important;
210
+ }
211
+
212
+ .#{$attribute}-surface-alpha {
213
+ #{$attribute}: var(--matcha-color-surface-card-alpha) !important;
214
+ }
215
+
216
+ .#{$attribute}-placeholder {
217
+ #{$attribute}: var(--matcha-color-text-placeholder) !important;
218
+
219
+ &-alpha {
220
+ // placeholder-alpha (raro/legado) — usa o token grey-alpha runtime.
221
+ background: var(--matcha-color-grey-alpha) !important;
222
+ }
223
+ }
224
+
225
+ .#{$attribute}-label {
226
+ #{$attribute}: var(--matcha-color-text-label) !important;
227
+ }
228
+
229
+ .#{$attribute}-disabled {
230
+ #{$attribute}: var(--matcha-color-disabled) !important;
231
+ }
232
+
233
+ .#{$attribute}-disabled-icon {
234
+ #{$attribute}: var(--matcha-color-interaction-disabled-fg) !important;
235
+ }
236
+ }
237
237
  }