@inchurch/matcha-theme 20.0.8 → 20.276.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 (99) hide show
  1. package/abstracts/_colors.scss +404 -404
  2. package/abstracts/_elevation.scss +102 -102
  3. package/abstracts/_functions.scss +1212 -1212
  4. package/abstracts/_media-breakpoint.scss +23 -23
  5. package/abstracts/_typography.scss +127 -127
  6. package/base/_reset.scss +438 -438
  7. package/components/app-page-header.scss +260 -0
  8. package/components/matcha-accordion.scss +294 -157
  9. package/components/matcha-avatar.scss +171 -31
  10. package/components/matcha-badge.scss +4 -4
  11. package/components/matcha-breadcrumb.scss +232 -126
  12. package/components/matcha-button-toggle.scss +44 -0
  13. package/components/matcha-buttons.scss +908 -784
  14. package/components/matcha-calendar.scss +70 -2
  15. package/components/matcha-cards.scss +28 -2
  16. package/components/matcha-checkbox.scss +191 -490
  17. package/components/matcha-chip.scss +297 -212
  18. package/components/matcha-command-palette.scss +291 -63
  19. package/components/matcha-crop.scss +407 -172
  20. package/components/matcha-date.scss +81 -81
  21. package/components/matcha-divider.scss +86 -31
  22. package/components/matcha-drawer.scss +201 -50
  23. package/components/matcha-drop-image.scss +14 -0
  24. package/components/matcha-drop-list.scss +42 -1
  25. package/components/matcha-empty-state.scss +195 -83
  26. package/components/matcha-flag.scss +93 -52
  27. package/components/matcha-footer.scss +68 -164
  28. package/components/matcha-form-field.scss +52 -0
  29. package/components/matcha-form-section.scss +101 -101
  30. package/components/matcha-header.scss +135 -325
  31. package/components/matcha-highlight.scss +65 -197
  32. package/components/matcha-hint-text.scss +21 -0
  33. package/components/matcha-horizontal-tree.scss +317 -317
  34. package/components/matcha-icon.scss +17 -25
  35. package/components/matcha-list.scss +5 -5
  36. package/components/matcha-menu.scss +13 -0
  37. package/components/matcha-modal.scss +58 -84
  38. package/components/matcha-nav.scss +361 -230
  39. package/components/matcha-notification.scss +413 -197
  40. package/components/matcha-option.scss +79 -23
  41. package/components/matcha-paginator.scss +689 -235
  42. package/components/matcha-panel.scss +42 -26
  43. package/components/matcha-profile-card.scss +50 -50
  44. package/components/matcha-progress-bar.scss +257 -153
  45. package/components/matcha-radio.scss +244 -452
  46. package/components/matcha-scrollbox-shadow.scss +122 -122
  47. package/components/matcha-select.scss +3 -3
  48. package/components/matcha-skeleton.scss +18 -0
  49. package/components/matcha-slide-toggle.scss +47 -2
  50. package/components/matcha-slider.scss +172 -75
  51. package/components/matcha-snack-bar.scss +114 -121
  52. package/components/matcha-spinner.scss +76 -57
  53. package/components/matcha-status-pill.scss +82 -0
  54. package/components/matcha-stepper.scss +377 -177
  55. package/components/matcha-table.scss +569 -785
  56. package/components/matcha-tabs.scss +624 -469
  57. package/components/matcha-text-editor.scss +98 -144
  58. package/components/matcha-toolbar.scss +359 -206
  59. package/components/matcha-tooltip.scss +156 -62
  60. package/components/matcha-tree-view.scss +189 -0
  61. package/components/matcha-uploader.scss +240 -62
  62. package/fonts/manrope/manrope-latin-ext.woff2 +0 -0
  63. package/fonts/manrope/manrope-latin.woff2 +0 -0
  64. package/layout/matcha-page-layout.scss +776 -0
  65. package/main.scss +232 -261
  66. package/package.json +1 -1
  67. package/tokens/_animations-tokens.scss +37 -37
  68. package/tokens/_breakpoints-tokens.scss +35 -26
  69. package/tokens/_color-tokens.scss +1152 -1152
  70. package/tokens/_css-custom-properties.scss +650 -568
  71. package/tokens/_spacing-tokens.scss +94 -94
  72. package/vendors/angular-editor.scss +56 -56
  73. package/vendors/angular-material-fixes.scss +297 -297
  74. package/vendors/charts.scss +92 -92
  75. package/vendors/ng5-slider.scss +56 -56
  76. package/vendors/ngx-material-timepicker.scss +50 -50
  77. package/fonts/CircularStd-Black.eot +0 -0
  78. package/fonts/CircularStd-Black.svg +0 -3426
  79. package/fonts/CircularStd-Black.ttf +0 -0
  80. package/fonts/CircularStd-Black.woff +0 -0
  81. package/fonts/CircularStd-Black.woff2 +0 -0
  82. package/fonts/CircularStd-Bold.eot +0 -0
  83. package/fonts/CircularStd-Bold.otf +0 -0
  84. package/fonts/CircularStd-Bold.svg +0 -13532
  85. package/fonts/CircularStd-Bold.ttf +0 -0
  86. package/fonts/CircularStd-Bold.woff +0 -0
  87. package/fonts/CircularStd-Bold.woff2 +0 -0
  88. package/fonts/CircularStd-Medium.eot +0 -0
  89. package/fonts/CircularStd-Medium.otf +0 -0
  90. package/fonts/CircularStd-Medium.svg +0 -13511
  91. package/fonts/CircularStd-Medium.ttf +0 -0
  92. package/fonts/CircularStd-Medium.woff +0 -0
  93. package/fonts/CircularStd-Medium.woff2 +0 -0
  94. package/fonts/CircularStd-Regular.eot +0 -0
  95. package/fonts/CircularStd-Regular.otf +0 -0
  96. package/fonts/CircularStd-Regular.svg +0 -2378
  97. package/fonts/CircularStd-Regular.ttf +0 -0
  98. package/fonts/CircularStd-Regular.woff +0 -0
  99. package/fonts/CircularStd-Regular.woff2 +0 -0
@@ -115,6 +115,47 @@
115
115
  }
116
116
  }
117
117
 
118
+ // =============================================================================
119
+ // DROP ZONE (matchaDropZone directive — reparenting target)
120
+ // =============================================================================
121
+
122
+ .matcha-drop-zone-cannot-accept {
123
+ border: 2px dashed getRed($theme) !important;
124
+ border-radius: 8px;
125
+ background-color: getRedAlpha($theme);
126
+ cursor: not-allowed;
127
+ transition: background-color 0.15s linear, border-color 0.15s linear;
128
+ }
129
+
130
+ // Fix C: quando o drop zone pai está rejeitado (vermelho), a lista filha
131
+ // recebendo o drag também deve ficar vermelha — não verde.
132
+ .matcha-drop-zone-cannot-accept .matcha-drop-list-container.matcha-drop-list-receiving {
133
+ background-color: getRedAlpha($theme);
134
+ border-color: getRed($theme);
135
+
136
+ &::before {
137
+ background: linear-gradient(45deg,
138
+ transparent 25%, getRedAlpha($theme) 25%, getRedAlpha($theme) 50%,
139
+ transparent 50%, transparent 75%, getRedAlpha($theme) 75%, getRedAlpha($theme));
140
+ background-size: 16px 16px;
141
+ animation: drop-zone-animation 0.8s linear infinite;
142
+ opacity: 0.6;
143
+ }
144
+ }
145
+
146
+ // =============================================================================
147
+ // GHOST CLONE (criado dinamicamente no body durante o drag)
148
+ // =============================================================================
149
+
150
+ .matcha-drag-ghost {
151
+ pointer-events: none;
152
+ opacity: 0.85;
153
+ z-index: 9999;
154
+ box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
155
+ border-radius: var(--matcha-radius-md, 4px);
156
+ will-change: transform;
157
+ }
158
+
118
159
  // =============================================================================
119
160
  // ITENS ARRASTÁVEIS — Template A
120
161
  // =============================================================================
@@ -240,7 +281,7 @@
240
281
  }
241
282
 
242
283
  small {
243
- font-size: var(--matcha-text-caption, 11px);
284
+ font-size: var(--matcha-text-p-tiny, 11px);
244
285
  font-style: italic;
245
286
  color: getForegroundAlpha($theme);
246
287
  }
@@ -1,118 +1,230 @@
1
1
  // =============================================================================
2
- // matcha-empty-state.scss — Empty state placeholder
3
- // Aligned with Figma matcha/empty-state: Tamanho(2) × Ação(2) × Descrição(2)
2
+ // matcha-empty-state.scss — Figma DSV3 matcha/empty-state (14935:130)
3
+ // 6 variants: Tamanho (Padrão 400/Compacto 280) × Ação (Sim/Não) × Descrição (Sim/Não)
4
+ // + extensão DSV3: variantes semânticas (success/warning/error/info), slot media,
5
+ // heading level configurável, anúncio aria-live opt-in.
4
6
  // =============================================================================
5
7
 
6
8
  // ── Structural ──────────────────────────────────────────────────────────────
7
9
 
8
10
  matcha-empty-state {
9
- display: flex;
10
- flex-direction: column;
11
- align-items: center;
12
- justify-content: center;
13
- flex: 1;
14
- min-height: 0;
15
- width: 100%;
16
- padding: var(--matcha-space-600, 48px) var(--matcha-space-400, 32px);
17
- box-sizing: border-box;
18
- text-align: center;
19
- }
20
-
21
- .matcha-empty-state__content {
22
- display: flex;
23
- flex-direction: column;
24
- align-items: center;
25
- gap: var(--matcha-space-200, 16px);
26
- max-width: 400px;
27
- width: 100%;
28
- }
29
-
30
- .matcha-empty-state__icon {
31
- display: flex;
32
- align-items: center;
33
- justify-content: center;
34
- width: 64px;
35
- height: 64px;
36
- border-radius: var(--matcha-radius-xl, 16px);
37
- flex-shrink: 0;
11
+ display: flex;
12
+ flex-direction: column;
13
+ align-items: center;
14
+ justify-content: center;
15
+ gap: var(--matcha-space-200, 16px);
16
+ width: 400px;
17
+ max-width: 100%;
18
+ // Centraliza o bloco horizontalmente quando o parent é mais largo que 400px
19
+ // (canon Figma DSV3 — empty-state sempre no centro do container).
20
+ margin-inline: auto;
21
+ padding: var(--matcha-space-600, 48px) var(--matcha-space-400, 32px);
22
+ box-sizing: border-box;
23
+ text-align: center;
38
24
  }
39
25
 
26
+ // ── Container do ícone — 64×64 com bg disabled e opacity 0.4 ────────────────
27
+ .matcha-empty-state__icon-container {
28
+ display: flex;
29
+ align-items: center;
30
+ justify-content: center;
31
+ flex-shrink: 0;
32
+ width: 64px;
33
+ height: 64px;
34
+ border-radius: var(--matcha-radius-xl, 16px);
35
+ background-color: var(--matcha-color-interaction-disabled-bg, #282C34);
36
+ opacity: var(--matcha-opacity-overlay-soft, 0.4);
37
+ overflow: hidden;
38
+ }
39
+
40
+ // ── Ícone dentro do container — 28×28 (Figma exato) ────────────────────────
41
+ matcha-empty-state .matcha-empty-state__icon-container .matcha-empty-state__icon,
42
+ matcha-empty-state .matcha-empty-state__icon-container matcha-icon {
43
+ font-size: 28px;
44
+ width: 28px;
45
+ height: 28px;
46
+ line-height: 28px;
47
+ color: var(--matcha-color-text-primary, #E8EAED);
48
+ }
49
+
50
+ // ── Variantes semânticas — colorem o container do ícone ────────────────────
51
+ matcha-empty-state[variant="success"] .matcha-empty-state__icon-container {
52
+ background-color: var(--matcha-color-success, #4caf50);
53
+ }
54
+ matcha-empty-state[variant="warning"] .matcha-empty-state__icon-container {
55
+ background-color: var(--matcha-color-warn, #ff9800);
56
+ }
57
+ matcha-empty-state[variant="error"] .matcha-empty-state__icon-container {
58
+ background-color: var(--matcha-color-danger, #f44336);
59
+ }
60
+ matcha-empty-state[variant="info"] .matcha-empty-state__icon-container {
61
+ background-color: var(--matcha-color-info, #64B5F6);
62
+ }
63
+
64
+ // Em variantes semânticas, ícone fica branco/contraste, sem opacity baixa
65
+ matcha-empty-state[variant]:not([variant="default"]) .matcha-empty-state__icon-container {
66
+ opacity: 1;
67
+ }
68
+ matcha-empty-state[variant]:not([variant="default"]) .matcha-empty-state__icon-container .matcha-empty-state__icon,
69
+ matcha-empty-state[variant]:not([variant="default"]) .matcha-empty-state__icon-container matcha-icon {
70
+ color: var(--matcha-color-on-feedback, #FFFFFF);
71
+ }
72
+
73
+ // Pareamento canônico por variant — usa o token *-contrast de cada feedback,
74
+ // que respeita WCAG AA em ambos os themes (preto em dark / branco em light
75
+ // pros tons claros; e o inverso pros tons escuros).
76
+ // !important: a regra global do matcha-icon (`matcha-icon { color: ... }`)
77
+ // tem mesma specificity que esses descendant selectors em alguns casos, e o
78
+ // browser cai no source order. !important garante que o contrast vence sempre.
79
+ matcha-empty-state[variant="success"] .matcha-empty-state__icon-container .matcha-empty-state__icon,
80
+ matcha-empty-state[variant="success"] .matcha-empty-state__icon-container matcha-icon {
81
+ color: var(--matcha-color-success-contrast) !important;
82
+ }
83
+ matcha-empty-state[variant="warning"] .matcha-empty-state__icon-container .matcha-empty-state__icon,
84
+ matcha-empty-state[variant="warning"] .matcha-empty-state__icon-container matcha-icon {
85
+ color: var(--matcha-color-warn-contrast) !important;
86
+ }
87
+ matcha-empty-state[variant="error"] .matcha-empty-state__icon-container .matcha-empty-state__icon,
88
+ matcha-empty-state[variant="error"] .matcha-empty-state__icon-container matcha-icon {
89
+ color: var(--matcha-color-danger-contrast) !important;
90
+ }
91
+ matcha-empty-state[variant="info"] .matcha-empty-state__icon-container .matcha-empty-state__icon,
92
+ matcha-empty-state[variant="info"] .matcha-empty-state__icon-container matcha-icon {
93
+ color: var(--matcha-color-info-contrast) !important;
94
+ }
95
+
96
+ // ── Slot media (ilustração custom) — 64×64 default, 48×48 compact ──────────
97
+ matcha-empty-state [matchaEmptyStateMedia] {
98
+ display: block;
99
+ flex-shrink: 0;
100
+ max-width: 120px;
101
+ max-height: 120px;
102
+ object-fit: contain;
103
+ }
104
+
105
+ // Quando slot media presente, esconde o container do ícone padrão
106
+ matcha-empty-state:has([matchaEmptyStateMedia]) .matcha-empty-state__icon-container {
107
+ display: none;
108
+ }
109
+
110
+ // ── Bloco texto — título + descrição ────────────────────────────────────────
40
111
  .matcha-empty-state__text {
41
- display: flex;
42
- flex-direction: column;
43
- align-items: center;
44
- gap: var(--matcha-space-100, 8px);
112
+ display: flex;
113
+ flex-direction: column;
114
+ align-items: center;
115
+ gap: var(--matcha-space-100, 8px);
116
+ width: 100%;
45
117
  }
46
118
 
119
+ // ── Título — matcha/text/button-lg (16/600/22, letter-spacing 0.2) ─────────
47
120
  .matcha-empty-state__title {
48
- font-size: var(--matcha-text-lg, 16px);
49
- font-weight: var(--matcha-weight-semibold, 600);
50
- line-height: 1.4;
51
- margin: 0;
121
+ font-family: var(--matcha-font-family);
122
+ font-size: var(--matcha-text-label-lg, 16px);
123
+ font-weight: var(--matcha-weight-semibold, 600);
124
+ line-height: var(--matcha-leading-label-lg, 22px);
125
+ letter-spacing: 0.2px;
126
+ color: var(--matcha-color-text-primary, #E8EAED);
127
+ margin: 0;
128
+ max-width: 336px;
52
129
  }
53
130
 
131
+ // ── Descrição — matcha/text/body-md (14/400/20) — w fixo 210px (Figma) ─────
54
132
  .matcha-empty-state__description {
55
- font-size: var(--matcha-text-md, 14px);
56
- font-weight: var(--matcha-weight-regular, 400);
57
- line-height: 1.5;
58
- max-width: 320px;
59
- margin: 0;
133
+ font-family: var(--matcha-font-family);
134
+ font-size: var(--matcha-text-body-md, 14px);
135
+ font-weight: var(--matcha-weight-regular, 400);
136
+ line-height: var(--matcha-leading-body-md, 20px);
137
+ color: var(--matcha-color-text-secondary);
138
+ margin: 0;
139
+ max-width: 210px;
60
140
  }
61
141
 
142
+ // ── Slot da ação — suporta múltiplas ações com gap padrão ──────────────────
62
143
  .matcha-empty-state__action {
63
- display: inline-flex;
64
- align-items: center;
65
- justify-content: center;
144
+ display: inline-flex;
145
+ flex-wrap: wrap;
146
+ align-items: center;
147
+ justify-content: center;
148
+ gap: var(--matcha-space-100, 8px);
66
149
  }
67
150
 
68
- // ── Compact variant ──
151
+ // Esconde container vazio (sem ng-content projetado)
152
+ .matcha-empty-state__action:empty {
153
+ display: none;
154
+ }
155
+
156
+ // ── Compact variant — 280px largura, ícone menor, padding reduzido ─────────
157
+ matcha-empty-state[size="compact"],
69
158
  matcha-empty-state.matcha-empty-state--compact {
70
- padding: var(--matcha-space-300, 24px) var(--matcha-space-200, 16px);
159
+ width: 280px;
160
+ padding: var(--matcha-space-300, 24px) var(--matcha-space-200, 16px);
161
+ gap: var(--matcha-space-150, 12px);
162
+
163
+ .matcha-empty-state__icon-container {
164
+ width: 48px;
165
+ height: 48px;
166
+ border-radius: var(--matcha-radius-lg, 12px);
167
+ }
71
168
 
72
- .matcha-empty-state__content {
73
- max-width: 280px;
74
- gap: var(--matcha-space-150, 12px);
75
- }
169
+ .matcha-empty-state__icon,
170
+ matcha-icon.matcha-empty-state__icon {
171
+ font-size: 20px;
172
+ width: 20px;
173
+ height: 20px;
174
+ line-height: 20px;
175
+ }
76
176
 
77
- .matcha-empty-state__icon {
78
- width: 40px;
79
- height: 40px;
80
- border-radius: var(--matcha-radius-lg, 8px);
81
- }
177
+ .matcha-empty-state__title {
178
+ font-size: var(--matcha-text-body-md, 14px);
179
+ line-height: var(--matcha-leading-body-md, 20px);
180
+ max-width: 240px;
181
+ }
82
182
 
83
- .matcha-empty-state__title {
84
- font-size: var(--matcha-text-md, 14px);
85
- }
183
+ .matcha-empty-state__description {
184
+ max-width: 240px;
185
+ }
86
186
  }
87
187
 
88
- // ── Responsive fallback ──
188
+ // ── Responsive: telas pequenas reduzem padding lateral ─────────────────────
89
189
  @media (max-width: 479px) {
90
- matcha-empty-state:not(.matcha-empty-state--compact) {
91
- padding: var(--matcha-space-400, 32px) var(--matcha-space-250, 20px);
92
-
93
- .matcha-empty-state__icon {
94
- width: 48px;
95
- height: 48px;
96
- border-radius: var(--matcha-radius-lg, 8px);
190
+ matcha-empty-state:not([size="compact"]):not(.matcha-empty-state--compact) {
191
+ padding: var(--matcha-space-400, 32px) var(--matcha-space-250, 20px);
97
192
  }
98
- }
99
193
  }
100
194
 
101
195
  // =============================================================================
102
- // Theme
196
+ // Theme mixin — vazia. Tudo via CSS custom properties globais.
103
197
  // =============================================================================
104
198
 
105
199
  @mixin matcha-empty-state-theme($theme) {
106
- .matcha-empty-state__icon {
107
- background-color: var(--matcha-color-disabled-bg, #{getDisabled($theme)});
108
- opacity: var(--matcha-opacity-disabled, 0.38);
109
- }
110
-
111
- .matcha-empty-state__title {
112
- color: var(--matcha-color-fg, #{getForeground($theme)});
113
- }
114
-
115
- .matcha-empty-state__description {
116
- color: var(--matcha-color-hint, #{getGrey($theme)});
117
- }
200
+ // Sem overrides — tokens globais bastam.
201
+ }
202
+
203
+ // ── Forced colors ──
204
+ @media (forced-colors: active) {
205
+ matcha-empty-state {
206
+ .matcha-empty-state__icon-container {
207
+ background: Canvas !important;
208
+ border: 1px solid CanvasText !important;
209
+ opacity: 1 !important;
210
+
211
+ matcha-icon { color: CanvasText !important; }
212
+ }
213
+ }
214
+ }
215
+
216
+ // ── Reduced motion ──
217
+ @media (prefers-reduced-motion: reduce) {
218
+ matcha-empty-state * {
219
+ transition: none !important;
220
+ animation: none !important;
221
+ }
222
+ }
223
+
224
+ // ── Print ──
225
+ // Empty state é informacional — mantém visível, ação pode hide.
226
+ @media print {
227
+ matcha-empty-state .matcha-empty-state__action {
228
+ display: none !important;
229
+ }
118
230
  }
@@ -1,62 +1,103 @@
1
- @use "sass:map";
2
-
3
1
  // =============================================================================
4
- // matcha-flag.scss — Country flags & payment brand flags
5
- // Aligned with Figma matcha/flag/país + matcha/flag/pagamento:
6
- // País: 4 variants (Brasil, EUA, Portugal, Espanha) — 22×16px (2:3)
7
- // Pagamento: 20 variants (Mastercard, Visa, PIX...) — 32×24px
8
- // Used in: phone DDI selector, payment forms, transaction lists
9
- // Angular: matcha-flag
2
+ // matcha-flag.scss — Bandeiras (country) + Pagamento (payment)
3
+ //
4
+ // 1:1 Figma DSV3 (i04CyWczuVctwRjE5VbJh7):
5
+ // - matcha/flag/country (3969:15347) — 24x24 frame, 22x16 flag (2:3)
6
+ // - matcha/flag/payment (3205:13569) — 32x24 SVG card (4:3)
7
+ //
8
+ // API host attrs (set pelo MatchaFlagComponent):
9
+ // data-set — country | payment
10
+ // data-name — slug (brasil, visa, pix, etc.)
11
+ // data-size — sm | md | lg
12
+ //
13
+ // Componentes:
14
+ // .matcha-flag — host (inline-flex, alinha + tamanho)
15
+ // .matcha-flag__emoji — span unicode (country)
16
+ // .matcha-flag__svg — wrapper innerHTML SVG (payment)
17
+ //
18
+ // Usado em: matcha-phone (DDI), forms de pagamento, transaction lists, hero CTA.
10
19
  // =============================================================================
11
20
 
12
- // ── Layout ──────────────────────────────────────────────────────────────────
13
-
14
- .matcha-flag {
15
- display: inline-flex;
16
- align-items: center;
17
- justify-content: center;
18
- flex-shrink: 0;
19
- overflow: hidden;
20
-
21
- img, svg {
22
- width: 100%;
23
- height: 100%;
24
- object-fit: cover;
25
- }
26
- }
27
-
28
- // ── Country flags (2:3 ratio) ───────────────────────────────────────────────
21
+ @mixin matcha-flag($theme) {
29
22
 
30
- .matcha-flag--country {
31
- width: 22px;
32
- height: 16px;
33
- border-radius: var(--matcha-radius-sm, 2px);
34
- }
23
+ // ── Host ─────────────────────────────────────────────────────────────────
24
+ .matcha-flag {
25
+ display: inline-flex;
26
+ align-items: center;
27
+ justify-content: center;
28
+ flex-shrink: 0;
29
+ overflow: hidden;
30
+ line-height: 1;
31
+ // Default size = md (sobrescrito por data-size abaixo)
32
+ width: var(--matcha-flag-w, 32px);
33
+ height: var(--matcha-flag-h, 24px);
34
+ border-radius: var(--matcha-radius-sm, 2px);
35
+ }
35
36
 
36
- .matcha-flag--country-lg {
37
- width: 32px;
38
- height: 24px;
39
- border-radius: var(--matcha-radius-sm, 2px);
40
- }
37
+ // ── Emoji (country) ─────────────────────────────────────────────────────
38
+ // Emoji ocupa o box todo; font-size ditando o tamanho do glyph.
39
+ .matcha-flag__emoji {
40
+ font-size: calc(var(--matcha-flag-h, 24px) * 0.95);
41
+ line-height: 1;
42
+ // Emoji-style render — força o emoji color (algumas fonts renderizam
43
+ // o codepoint como texto B&W; emoji color preserva as cores nacionais)
44
+ font-family: 'Apple Color Emoji', 'Segoe UI Emoji', 'Noto Color Emoji', sans-serif;
45
+ font-variant-emoji: emoji;
46
+ }
41
47
 
42
- // ── Payment flags (4:3 ratio) ───────────────────────────────────────────────
48
+ // ── SVG (payment) ───────────────────────────────────────────────────────
49
+ .matcha-flag__svg {
50
+ display: inline-flex;
51
+ width: 100%;
52
+ height: 100%;
43
53
 
44
- .matcha-flag--payment {
45
- width: 32px;
46
- height: 24px;
47
- border-radius: var(--matcha-radius-sm, 2px);
48
- }
49
-
50
- .matcha-flag--payment-lg {
51
- width: 48px;
52
- height: 36px;
53
- border-radius: var(--matcha-radius-md, 4px);
54
- }
54
+ svg {
55
+ width: 100%;
56
+ height: 100%;
57
+ display: block;
58
+ }
59
+ }
55
60
 
56
- // ── Theme (border for visibility on dark/light) ────────────────────────────
61
+ // ── Set: country 2:3 aspect ratio ─────────────────────────────────────
62
+ .matcha-flag[data-set="country"] {
63
+ --matcha-flag-w: 22px;
64
+ --matcha-flag-h: 16px;
65
+ }
66
+ .matcha-flag[data-set="country"][data-size="small"],
67
+ .matcha-flag[data-set="country"][data-size="sm"] {
68
+ --matcha-flag-w: 16px;
69
+ --matcha-flag-h: 12px;
70
+ }
71
+ .matcha-flag[data-set="country"][data-size="medium"],
72
+ .matcha-flag[data-set="country"][data-size="md"] {
73
+ --matcha-flag-w: 22px;
74
+ --matcha-flag-h: 16px;
75
+ }
76
+ .matcha-flag[data-set="country"][data-size="large"],
77
+ .matcha-flag[data-set="country"][data-size="lg"] {
78
+ --matcha-flag-w: 32px;
79
+ --matcha-flag-h: 24px;
80
+ }
57
81
 
58
- @mixin matcha-flag-theme($theme) {
59
- .matcha-flag {
60
- border: var(--matcha-border-hairline, 1px) solid var(--matcha-color-border, #{getGrey($theme)});
61
- }
82
+ // ── Set: payment — 4:3 aspect ratio ─────────────────────────────────────
83
+ .matcha-flag[data-set="payment"] {
84
+ --matcha-flag-w: 32px;
85
+ --matcha-flag-h: 24px;
86
+ }
87
+ .matcha-flag[data-set="payment"][data-size="small"],
88
+ .matcha-flag[data-set="payment"][data-size="sm"] {
89
+ --matcha-flag-w: 24px;
90
+ --matcha-flag-h: 18px;
91
+ }
92
+ .matcha-flag[data-set="payment"][data-size="medium"],
93
+ .matcha-flag[data-set="payment"][data-size="md"] {
94
+ --matcha-flag-w: 32px;
95
+ --matcha-flag-h: 24px;
96
+ }
97
+ .matcha-flag[data-set="payment"][data-size="large"],
98
+ .matcha-flag[data-set="payment"][data-size="lg"] {
99
+ --matcha-flag-w: 48px;
100
+ --matcha-flag-h: 36px;
101
+ border-radius: var(--matcha-radius-md, 4px);
102
+ }
62
103
  }