@financinha/tokens 0.0.0-stage → 0.8.1
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/CHANGELOG.md +172 -0
- package/dist/fonts.css +7 -0
- package/dist/index.cjs +521 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +1250 -0
- package/dist/index.d.ts +1250 -0
- package/dist/index.js +483 -0
- package/dist/index.js.map +1 -0
- package/dist/theme.css +206 -0
- package/dist/tokens.css +323 -0
- package/package.json +60 -4
- package/README.md +0 -3
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,172 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
Formato: [Keep a Changelog](https://keepachangelog.com/). Versionamento: SemVer.
|
|
4
|
+
|
|
5
|
+
## [Não lançado]
|
|
6
|
+
|
|
7
|
+
## [0.8.0] — 2026-11-12
|
|
8
|
+
|
|
9
|
+
### Alterado
|
|
10
|
+
|
|
11
|
+
- **Publicação no npm público**, no lugar do GitHub Packages: instalar não exige mais token nem
|
|
12
|
+
`.npmrc`. As versões até a 0.7.1 continuam só no GitHub Packages.
|
|
13
|
+
|
|
14
|
+
## [0.7.1] — 2026-11-10
|
|
15
|
+
|
|
16
|
+
### Documentação
|
|
17
|
+
|
|
18
|
+
- CHANGELOG organizado por versão: os itens que estavam acumulados em "Não lançado" foram para a
|
|
19
|
+
versão em que saíram (0.4.0 a 0.7.0).
|
|
20
|
+
|
|
21
|
+
## [0.7.0] — 2026-11-05
|
|
22
|
+
|
|
23
|
+
### Adicionado
|
|
24
|
+
|
|
25
|
+
- **Duração `instant` (100 ms)**, a que menus, popovers, Select e modais já usam para abrir e fechar
|
|
26
|
+
(`duration-100` no Tailwind). Em CSS: `--ds-duration-instant` e `--ds-transition-instant`; em TS:
|
|
27
|
+
`duration.instant` e `transition.instant`.
|
|
28
|
+
|
|
29
|
+
## [0.6.0] — 2026-10-19
|
|
30
|
+
|
|
31
|
+
### Alterado
|
|
32
|
+
|
|
33
|
+
- **Escala de raio reduzida a três tamanhos** (quebra compatibilidade): `sm` 4 px (elementos
|
|
34
|
+
pequenos, como o checkbox), `md` 6 px (itens dentro de caixas, tooltip, skeleton) e `lg` 10 px (botões, campos,
|
|
35
|
+
cards, popovers, menus e modais), mais `none` e `full`. Sai o `xl`; `sm` passa de 6 para 4 px
|
|
36
|
+
e `md` de 8 para 6 px. No Tailwind, `rounded-xs`, `rounded-xl`, `rounded-2xl`, `rounded-3xl` e
|
|
37
|
+
`rounded-4xl` deixam de existir. No `ui`: botões, campos, popovers e caixas de menu passam de
|
|
38
|
+
8 para 10 px; card e modais de 12 para 10 px; itens de menu e do select seguem em 6 px (agora
|
|
39
|
+
`md`); checkbox de 4 px solto para `sm`; badge de `rounded-4xl` para `rounded-full`.
|
|
40
|
+
|
|
41
|
+
## [0.5.0] — 2026-10-19
|
|
42
|
+
|
|
43
|
+
### Adicionado
|
|
44
|
+
|
|
45
|
+
- **Entrelinha por tamanho** (`leading`, `--ds-leading-*`), sempre na grade de 4 px: 16, 20, 24,
|
|
46
|
+
28, 28, 32, 36, 40 e 48 px (de `xs` a `5xl`). No Tailwind, `text-*` já aplica a entrelinha do
|
|
47
|
+
tamanho. Os estilos de texto (`textStyles`) passam a usá-la, em vez de 1,5 em todos (que dava
|
|
48
|
+
18, 21, 27 e 30 px, fora da grade). `lineHeight.tight`/`base` continuam existindo.
|
|
49
|
+
- Três tamanhos de texto de destaque: `3xl` (28 px), `4xl` (32 px) e `5xl` (40 px), para títulos
|
|
50
|
+
de fluxo e de abertura (cancelamento, login). No Tailwind eles substituem os valores padrão
|
|
51
|
+
de `text-3xl`, `text-4xl` e `text-5xl` (30, 36 e 48 px).
|
|
52
|
+
|
|
53
|
+
### Alterado
|
|
54
|
+
|
|
55
|
+
- **Raio `xl` passa de 14 para 12 px**, o canto dos modais (igual ao do Portal). Botões e campos
|
|
56
|
+
continuam em `lg` (10 px).
|
|
57
|
+
- **Estilos de texto refeitos no formato da Vibe** (`textStyles`): nove funções no lugar
|
|
58
|
+
dos nomes por uso. Destaques `display1` (40 px) e `display2` (32 px), em bold; títulos `h1` (28 px), `h2` (24 px), `h3` (20 px) e `h4` (18 px); textos `text1` (16 px),
|
|
59
|
+
`text2` (14 px) e `text3` (12 px). O peso deixou de ser fixo: cada estilo tem um peso padrão
|
|
60
|
+
(`fontWeight`) e a lista de pesos permitidos (`weights`). `display1`, `display2`, `h1` e `h2` usam espaço entre letras
|
|
61
|
+
`tight` (-0,01em), os demais `normal`; a entrelinha acompanha o tamanho (`leading`). Saem
|
|
62
|
+
`body`, `bodySm`, `caption`, `label` e `button`: botão e rótulo de campo são `text2` em medium
|
|
63
|
+
(14 px, como o botão do `ui` e o Portal), e a legenda é `text3`.
|
|
64
|
+
|
|
65
|
+
## [0.4.0] — 2026-10-16
|
|
66
|
+
|
|
67
|
+
### Adicionado
|
|
68
|
+
|
|
69
|
+
- `neutral-0` (`#FFFFFF`, `--ds-neutral-0`, `bg-neutral-0`): o branco puro vira um degrau da escala
|
|
70
|
+
`neutral`. `background`, `card`, `popover` e os `...Foreground` sobre cor forte apontam para ele.
|
|
71
|
+
- `brand.coral` (`#EE6B55`, `--ds-brand-coral`): o coral do logo, só para logo,
|
|
72
|
+
ilustração e marketing; nunca em componentes ou estados.
|
|
73
|
+
- `neutral-800` (`#101A29`) e `neutral-900` (`#050C17`), que completam a escala.
|
|
74
|
+
- Token semântico `primary-hover` (`--ds-primary-hover`, `bg-primary-hover`).
|
|
75
|
+
|
|
76
|
+
### Alterado
|
|
77
|
+
|
|
78
|
+
- `primary-400` passa de `#902DFF` para **`#8534FF`** (valor do Figma), resolvendo a
|
|
79
|
+
divergência entre código e Figma.
|
|
80
|
+
- **Escala `primary` refeita** em volta de dois valores fixos (`400` = `#8534FF` e
|
|
81
|
+
`500` = `#5D11D0`, a cor oficial): passos regulares em OKLCH, `50` e `100` deixam de
|
|
82
|
+
ser iguais e os escuros (`600`–`900`) deixam de ser quase pretos.
|
|
83
|
+
- **A ação principal passa a ser o `primary-500`** (antes, `400`). Hover e pressionado
|
|
84
|
+
usam `primary-400`, sem terceiro tom; o botão também encolhe a 0,98 ao pressionar.
|
|
85
|
+
No modo escuro, a base é o `400` e o hover vai ao `500`.
|
|
86
|
+
- O fundo da sidebar passa de `primary-200` para `primary-50` (mesmo visual de antes).
|
|
87
|
+
- **Escala `neutral` refeita** em uma só família (matiz ~257°, o do `neutral-300`): `50`
|
|
88
|
+
(`#F5F5F7`, fundo do menu) e `300`–`700` intocados; `100` (`#E1E8F1`) e `200`
|
|
89
|
+
(`#CCD6E4`) ganham o matiz azul-ardósia, com saturação crescente até o `300`.
|
|
90
|
+
Bordas e fundos suaves ficam levemente mais azulados.
|
|
91
|
+
- **Régua única de luminosidade para as seis escalas** (`neutral`, `primary`, `support`,
|
|
92
|
+
`success`, `warning`, `danger`): cada degrau tem o mesmo papel em todas (`100` badge suave,
|
|
93
|
+
`300` sólido vivo com texto escuro, `400` vivo forte, `500` degrau AA, `600`–`900`
|
|
94
|
+
escuros). As escalas de status deixam de ser as do Tailwind: matiz fixo por escala,
|
|
95
|
+
`500` mais profundo e `800`/`900` na mesma luminosidade do `primary` (que ficou menos
|
|
96
|
+
escuro: `600`–`900` e `neutral-900` subiram um pouco).
|
|
97
|
+
- **Os degraus `900` (e `950`) foram removidos** das seis escalas: o `800` passa a ser o mais
|
|
98
|
+
escuro e os escuros (`600`–`800`) foram redistribuídos e ficaram menos escuros (luminosidade
|
|
99
|
+
~0,28 no `800`). Variantes dark do `Badge`/`Alert` usam o `800`/`700`; o texto dos badges
|
|
100
|
+
sólidos usa `neutral-800`.
|
|
101
|
+
- `destructive` (claro) passa de `danger-600` para `danger-500`; `chart-1…5` passam a usar
|
|
102
|
+
o `-400` de cada escala.
|
|
103
|
+
- Fundos suaves mais cheios em `support-100`, `success-50/100/200` e `warning-50/100/200` (o
|
|
104
|
+
âmbar deixa de ser bege e vira creme-amarelo); `primary-300` passa a `#A380FE` (mais intenso).
|
|
105
|
+
- `Badge`: o padrão suave passa a ser fundo `-100` + contorno `-200` + texto `-500`, em semibold
|
|
106
|
+
12 px (altura 24 px, espaçamentos em múltiplos de 4); novos variantes
|
|
107
|
+
`support` e `solid-*` (fundo `-300` + texto neutro escuro).
|
|
108
|
+
|
|
109
|
+
### Removido / renomeado (quebra de compatibilidade)
|
|
110
|
+
|
|
111
|
+
- A regra "`primary-600` é proibido" foi removida de todos os lugares: com a nova régua, o `600` é
|
|
112
|
+
um tom escuro normal (pressionado e fundos escuros), igual ao das outras escalas.
|
|
113
|
+
- **Escala `info` renomeada para `support`** (`info-*` → `support-*`, `--ds-info-*` →
|
|
114
|
+
`--ds-support-*`, `--color-info-*` → `--color-support-*`). Mesmos valores (azul): é a cor
|
|
115
|
+
de apoio para categorias (tipo de conta, tipo de meta, séries de gráfico), e não a cor de
|
|
116
|
+
"informação" — a Financinha não usa azul para informar. Os variantes `info` do `Alert` e
|
|
117
|
+
do `Badge` agora usam o lilás da marca (`primary-50/700`).
|
|
118
|
+
- **Escala `secondary` (coral/vermelho) removida** (`secondary-50`…`secondary-950`,
|
|
119
|
+
`--ds-secondary-*`, `--color-secondary-*`). Ela duplicava `danger` e lia-se como erro.
|
|
120
|
+
Use `danger-*` para erro e valor negativo. O `chart-5` passa a usar `danger-500`
|
|
121
|
+
(mesma cor de antes). O token semântico `secondary` (cinza do shadcn) NÃO mudou.
|
|
122
|
+
|
|
123
|
+
## [0.1.2] a [0.3.0] — 2026-07-02 a 2026-10-08
|
|
124
|
+
|
|
125
|
+
Sem registro neste arquivo. As mudanças estão nos commits `chore(release)` do histórico do git
|
|
126
|
+
(0.3.0 foi a separação em monorepo, com `@financinha/ui`).
|
|
127
|
+
|
|
128
|
+
## [0.1.1] — 2026-07-02
|
|
129
|
+
|
|
130
|
+
### Adicionado
|
|
131
|
+
|
|
132
|
+
- **Componentes React** (`@financinha/tokens/react`): `Button`, `Card` (+
|
|
133
|
+
`CardHeader`/`CardTitle`/`CardDescription`/`CardContent`/`CardFooter`),
|
|
134
|
+
`Banner`, `Spinner`, `Input`, `Textarea`, `Select`, `FormField`/`Label`,
|
|
135
|
+
`Switch`, `Checkbox`, `RadioGroup`, `Badge`, `Modal`, `EmptyState`, `Tooltip`.
|
|
136
|
+
- Storybook com Tailwind v4 (`@tailwindcss/vite`) e stories colocadas por
|
|
137
|
+
componente.
|
|
138
|
+
- Publicação automática no GitHub Packages a cada push na `main`
|
|
139
|
+
(`.github/workflows/publish.yml`), com bump semver por conventional commit.
|
|
140
|
+
|
|
141
|
+
## [0.1.0] — 2026-07-02
|
|
142
|
+
|
|
143
|
+
### Adicionado
|
|
144
|
+
|
|
145
|
+
- Primeira versão dos design tokens da Financinha como pacote instalável
|
|
146
|
+
(`@financinha/tokens`), consolidando os tokens de `financinha-web-front/src/ds`.
|
|
147
|
+
- **Cores:** escalas `neutral`, `primary`, `secondary`, `info`, `success`,
|
|
148
|
+
`warning`, `danger` + semânticas `semantic` (light), `semanticDark` e `chart`.
|
|
149
|
+
- **Tipografia:** Open Sans, `fontSize`, `fontWeight` (inclui `light` 300),
|
|
150
|
+
`lineHeight`, `letterSpacing`, `textStyles`.
|
|
151
|
+
- **Espaçamento** (`space` + `spacePx`), **radius**, **shadows**,
|
|
152
|
+
**transições** (`duration` + `easing` + `transition`), **breakpoints**, **z-index**.
|
|
153
|
+
- Três formatos de saída em paridade: TS tipado, `tokens.css` (`--ds-*`, light +
|
|
154
|
+
dark) e `theme.css` (preset Tailwind v4).
|
|
155
|
+
- Teste de paridade TS ↔ CSS (`vitest`) + checagem sem dependências (`lint:css`).
|
|
156
|
+
|
|
157
|
+
### Corrigido (pós-auditoria)
|
|
158
|
+
|
|
159
|
+
- **exports map**: tipos condicionais por formato (`import` → `.d.ts`, `require` →
|
|
160
|
+
`.d.cts`) — antes o CJS resolvia tipos ESM (FalseESM no `arethetypeswrong`).
|
|
161
|
+
- **Tailwind**: removidos os stops `neutral-800/900/950` default do Tailwind
|
|
162
|
+
(cinzas acromáticos) que sobreviviam ao override parcial 50–700 da marca.
|
|
163
|
+
- **Acessibilidade**: guidelines ganharam seção de contraste WCAG — tons de status
|
|
164
|
+
`-500` são preenchimento (não texto sobre branco), `text-muted` é decorativo,
|
|
165
|
+
placeholder nunca é rótulo, não confiar só na cor (SC 1.4.1).
|
|
166
|
+
- Notas de consumo: React Native (só JS, CSS é web-only), exports nomeados,
|
|
167
|
+
`fonts.css` exige rede/CSP.
|
|
168
|
+
|
|
169
|
+
### A resolver
|
|
170
|
+
|
|
171
|
+
- Reconciliar `primary-400`: código usa `#902DFF`, docs do Figma usam `#8534FF`.
|
|
172
|
+
Adotado `#902DFF` por ora.
|
package/dist/fonts.css
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @financinha/tokens — fonte base (Open Sans).
|
|
3
|
+
*
|
|
4
|
+
* Mesma origem do Figma Make. Importe no layout raiz, junto com tokens.css.
|
|
5
|
+
* Em produção, considere self-host (next/font, fontsource) para performance.
|
|
6
|
+
*/
|
|
7
|
+
@import url('https://fonts.googleapis.com/css2?family=Open+Sans:wght@300;400;500;600;700&display=swap');
|
package/dist/index.cjs
ADDED
|
@@ -0,0 +1,521 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
// src/tokens/palette.ts
|
|
4
|
+
var neutral = {
|
|
5
|
+
0: "#FFFFFF",
|
|
6
|
+
50: "#F5F5F7",
|
|
7
|
+
100: "#E1E8F1",
|
|
8
|
+
200: "#CCD6E4",
|
|
9
|
+
300: "#94A3B8",
|
|
10
|
+
400: "#64748B",
|
|
11
|
+
500: "#475569",
|
|
12
|
+
600: "#334155",
|
|
13
|
+
700: "#1E293B",
|
|
14
|
+
800: "#141E2E"
|
|
15
|
+
};
|
|
16
|
+
var primary = {
|
|
17
|
+
50: "#F7F5FF",
|
|
18
|
+
100: "#ECE8FF",
|
|
19
|
+
200: "#DCD4FE",
|
|
20
|
+
300: "#A380FE",
|
|
21
|
+
400: "#8534FF",
|
|
22
|
+
500: "#5D11D0",
|
|
23
|
+
600: "#4B1AA8",
|
|
24
|
+
700: "#391482",
|
|
25
|
+
800: "#29115D"
|
|
26
|
+
};
|
|
27
|
+
var brand = {
|
|
28
|
+
coral: "#EE6B55"
|
|
29
|
+
};
|
|
30
|
+
var support = {
|
|
31
|
+
50: "#F2F7FF",
|
|
32
|
+
100: "#E2EEFF",
|
|
33
|
+
200: "#C9DEFF",
|
|
34
|
+
300: "#6EA6FE",
|
|
35
|
+
400: "#3780F1",
|
|
36
|
+
500: "#1A65D4",
|
|
37
|
+
600: "#004199",
|
|
38
|
+
700: "#003277",
|
|
39
|
+
800: "#00245A"
|
|
40
|
+
};
|
|
41
|
+
var success = {
|
|
42
|
+
50: "#ECFDF3",
|
|
43
|
+
100: "#D3F9E3",
|
|
44
|
+
200: "#A9EBC3",
|
|
45
|
+
300: "#26D28D",
|
|
46
|
+
400: "#09A970",
|
|
47
|
+
500: "#007A4F",
|
|
48
|
+
600: "#035636",
|
|
49
|
+
700: "#004229",
|
|
50
|
+
800: "#00311D"
|
|
51
|
+
};
|
|
52
|
+
var warning = {
|
|
53
|
+
50: "#FFFAED",
|
|
54
|
+
100: "#FFEFC9",
|
|
55
|
+
200: "#F8DF9A",
|
|
56
|
+
300: "#FEB433",
|
|
57
|
+
400: "#E29B03",
|
|
58
|
+
500: "#8F6103",
|
|
59
|
+
600: "#633F00",
|
|
60
|
+
700: "#4C3000",
|
|
61
|
+
800: "#392200"
|
|
62
|
+
};
|
|
63
|
+
var danger = {
|
|
64
|
+
50: "#FFF4F3",
|
|
65
|
+
100: "#FFE6E5",
|
|
66
|
+
200: "#FFCFCC",
|
|
67
|
+
300: "#FF5C5C",
|
|
68
|
+
400: "#E64147",
|
|
69
|
+
500: "#CB2336",
|
|
70
|
+
600: "#89021C",
|
|
71
|
+
700: "#6B0113",
|
|
72
|
+
800: "#51010C"
|
|
73
|
+
};
|
|
74
|
+
var palette = {
|
|
75
|
+
neutral,
|
|
76
|
+
primary,
|
|
77
|
+
support,
|
|
78
|
+
success,
|
|
79
|
+
warning,
|
|
80
|
+
danger
|
|
81
|
+
};
|
|
82
|
+
|
|
83
|
+
// src/tokens/semantic.ts
|
|
84
|
+
var semantic = {
|
|
85
|
+
background: neutral[0],
|
|
86
|
+
foreground: neutral[700],
|
|
87
|
+
card: neutral[0],
|
|
88
|
+
cardForeground: neutral[700],
|
|
89
|
+
popover: neutral[0],
|
|
90
|
+
popoverForeground: neutral[700],
|
|
91
|
+
// primary-500 = cor oficial = ação principal da tela (regra de marca: uma por tela).
|
|
92
|
+
// Hover/pressionado = primary-400 (mais claro), sem terceiro tom.
|
|
93
|
+
primary: primary[500],
|
|
94
|
+
primaryHover: primary[400],
|
|
95
|
+
primaryForeground: neutral[0],
|
|
96
|
+
secondary: neutral[100],
|
|
97
|
+
secondaryForeground: neutral[700],
|
|
98
|
+
muted: neutral[50],
|
|
99
|
+
mutedForeground: neutral[400],
|
|
100
|
+
accent: neutral[100],
|
|
101
|
+
accentForeground: neutral[700],
|
|
102
|
+
// danger-500: o degrau "AA" de toda escala (texto/branco sobre ele passa WCAG AA).
|
|
103
|
+
destructive: danger[500],
|
|
104
|
+
border: neutral[200],
|
|
105
|
+
input: neutral[200],
|
|
106
|
+
// borda de campos de formulário
|
|
107
|
+
ring: primary[400],
|
|
108
|
+
sidebar: neutral[50],
|
|
109
|
+
// o fundo do menu e da tela em volta da página, como no portal (#F5F5F7)
|
|
110
|
+
sidebarForeground: neutral[700],
|
|
111
|
+
sidebarPrimary: primary[500],
|
|
112
|
+
sidebarPrimaryForeground: neutral[0],
|
|
113
|
+
sidebarAccent: primary[100],
|
|
114
|
+
sidebarAccentForeground: neutral[700],
|
|
115
|
+
sidebarBorder: neutral[200],
|
|
116
|
+
sidebarRing: primary[400]
|
|
117
|
+
};
|
|
118
|
+
var semanticDark = {
|
|
119
|
+
background: neutral[700],
|
|
120
|
+
foreground: neutral[50],
|
|
121
|
+
card: neutral[600],
|
|
122
|
+
cardForeground: neutral[50],
|
|
123
|
+
popover: neutral[600],
|
|
124
|
+
popoverForeground: neutral[50],
|
|
125
|
+
// No escuro o 500 some no fundo: a base é o 400 e o hover vai ao 500 (texto branco segue AA).
|
|
126
|
+
primary: primary[400],
|
|
127
|
+
primaryHover: primary[500],
|
|
128
|
+
primaryForeground: neutral[0],
|
|
129
|
+
secondary: neutral[500],
|
|
130
|
+
secondaryForeground: neutral[50],
|
|
131
|
+
muted: neutral[600],
|
|
132
|
+
mutedForeground: neutral[300],
|
|
133
|
+
accent: neutral[500],
|
|
134
|
+
accentForeground: neutral[50],
|
|
135
|
+
destructive: danger[400],
|
|
136
|
+
// neutral-500: visível tanto sobre background (700) quanto sobre card (600).
|
|
137
|
+
border: neutral[500],
|
|
138
|
+
input: neutral[500],
|
|
139
|
+
ring: primary[300],
|
|
140
|
+
sidebar: neutral[600],
|
|
141
|
+
sidebarForeground: neutral[50],
|
|
142
|
+
sidebarPrimary: primary[400],
|
|
143
|
+
sidebarPrimaryForeground: neutral[0],
|
|
144
|
+
sidebarAccent: neutral[700],
|
|
145
|
+
sidebarAccentForeground: neutral[50],
|
|
146
|
+
sidebarBorder: neutral[700],
|
|
147
|
+
sidebarRing: primary[300]
|
|
148
|
+
};
|
|
149
|
+
var chart = {
|
|
150
|
+
1: primary[400],
|
|
151
|
+
2: support[400],
|
|
152
|
+
3: success[400],
|
|
153
|
+
4: warning[400],
|
|
154
|
+
5: danger[400]
|
|
155
|
+
};
|
|
156
|
+
|
|
157
|
+
// src/tokens/colors.ts
|
|
158
|
+
var colors = {
|
|
159
|
+
neutral,
|
|
160
|
+
primary,
|
|
161
|
+
brand,
|
|
162
|
+
support,
|
|
163
|
+
success,
|
|
164
|
+
warning,
|
|
165
|
+
danger,
|
|
166
|
+
semantic,
|
|
167
|
+
semanticDark,
|
|
168
|
+
chart
|
|
169
|
+
};
|
|
170
|
+
|
|
171
|
+
// src/tokens/typography.ts
|
|
172
|
+
var fontFamily = {
|
|
173
|
+
sans: "'Open Sans', sans-serif",
|
|
174
|
+
mono: "'SFMono-Regular', Menlo, Monaco, Consolas, 'Liberation Mono', 'Courier New', monospace"
|
|
175
|
+
};
|
|
176
|
+
var fontSize = {
|
|
177
|
+
xs: "0.75rem",
|
|
178
|
+
// 12px
|
|
179
|
+
sm: "0.875rem",
|
|
180
|
+
// 14px
|
|
181
|
+
base: "1rem",
|
|
182
|
+
// 16px
|
|
183
|
+
lg: "1.125rem",
|
|
184
|
+
// 18px
|
|
185
|
+
xl: "1.25rem",
|
|
186
|
+
// 20px
|
|
187
|
+
"2xl": "1.5rem",
|
|
188
|
+
// 24px
|
|
189
|
+
"3xl": "1.75rem",
|
|
190
|
+
// 28px
|
|
191
|
+
"4xl": "2rem",
|
|
192
|
+
// 32px
|
|
193
|
+
"5xl": "2.5rem"
|
|
194
|
+
// 40px
|
|
195
|
+
};
|
|
196
|
+
var fontWeight = {
|
|
197
|
+
light: 300,
|
|
198
|
+
normal: 400,
|
|
199
|
+
medium: 500,
|
|
200
|
+
semibold: 600,
|
|
201
|
+
bold: 700
|
|
202
|
+
};
|
|
203
|
+
var leading = {
|
|
204
|
+
xs: "1rem",
|
|
205
|
+
// 16px
|
|
206
|
+
sm: "1.25rem",
|
|
207
|
+
// 20px
|
|
208
|
+
base: "1.5rem",
|
|
209
|
+
// 24px
|
|
210
|
+
lg: "1.75rem",
|
|
211
|
+
// 28px
|
|
212
|
+
xl: "1.75rem",
|
|
213
|
+
// 28px
|
|
214
|
+
"2xl": "2rem",
|
|
215
|
+
// 32px
|
|
216
|
+
"3xl": "2.25rem",
|
|
217
|
+
// 36px
|
|
218
|
+
"4xl": "2.5rem",
|
|
219
|
+
// 40px
|
|
220
|
+
"5xl": "3rem"
|
|
221
|
+
// 48px
|
|
222
|
+
};
|
|
223
|
+
var lineHeight = {
|
|
224
|
+
tight: 1.25,
|
|
225
|
+
base: 1.5
|
|
226
|
+
};
|
|
227
|
+
var letterSpacing = {
|
|
228
|
+
tight: "-0.01em",
|
|
229
|
+
normal: "0",
|
|
230
|
+
wide: "0.025em"
|
|
231
|
+
};
|
|
232
|
+
var textStyles = {
|
|
233
|
+
display1: {
|
|
234
|
+
fontSize: fontSize["5xl"],
|
|
235
|
+
// 40px
|
|
236
|
+
fontWeight: fontWeight.bold,
|
|
237
|
+
weights: [fontWeight.semibold, fontWeight.bold],
|
|
238
|
+
lineHeight: leading["5xl"],
|
|
239
|
+
letterSpacing: letterSpacing.tight
|
|
240
|
+
},
|
|
241
|
+
display2: {
|
|
242
|
+
fontSize: fontSize["4xl"],
|
|
243
|
+
// 32px
|
|
244
|
+
fontWeight: fontWeight.bold,
|
|
245
|
+
weights: [fontWeight.semibold, fontWeight.bold],
|
|
246
|
+
lineHeight: leading["4xl"],
|
|
247
|
+
letterSpacing: letterSpacing.tight
|
|
248
|
+
},
|
|
249
|
+
h1: {
|
|
250
|
+
fontSize: fontSize["3xl"],
|
|
251
|
+
// 28px
|
|
252
|
+
fontWeight: fontWeight.semibold,
|
|
253
|
+
weights: [fontWeight.medium, fontWeight.semibold, fontWeight.bold],
|
|
254
|
+
lineHeight: leading["3xl"],
|
|
255
|
+
letterSpacing: letterSpacing.tight
|
|
256
|
+
},
|
|
257
|
+
h2: {
|
|
258
|
+
fontSize: fontSize["2xl"],
|
|
259
|
+
// 24px
|
|
260
|
+
fontWeight: fontWeight.semibold,
|
|
261
|
+
weights: [fontWeight.medium, fontWeight.semibold, fontWeight.bold],
|
|
262
|
+
lineHeight: leading["2xl"],
|
|
263
|
+
letterSpacing: letterSpacing.tight
|
|
264
|
+
},
|
|
265
|
+
h3: {
|
|
266
|
+
fontSize: fontSize.xl,
|
|
267
|
+
// 20px
|
|
268
|
+
fontWeight: fontWeight.semibold,
|
|
269
|
+
weights: [fontWeight.medium, fontWeight.semibold, fontWeight.bold],
|
|
270
|
+
lineHeight: leading.xl,
|
|
271
|
+
letterSpacing: letterSpacing.normal
|
|
272
|
+
},
|
|
273
|
+
h4: {
|
|
274
|
+
fontSize: fontSize.lg,
|
|
275
|
+
// 18px
|
|
276
|
+
fontWeight: fontWeight.medium,
|
|
277
|
+
weights: [fontWeight.medium, fontWeight.semibold, fontWeight.bold],
|
|
278
|
+
lineHeight: leading.lg,
|
|
279
|
+
letterSpacing: letterSpacing.normal
|
|
280
|
+
},
|
|
281
|
+
text1: {
|
|
282
|
+
fontSize: fontSize.base,
|
|
283
|
+
// 16px
|
|
284
|
+
fontWeight: fontWeight.normal,
|
|
285
|
+
weights: [fontWeight.normal, fontWeight.medium, fontWeight.semibold],
|
|
286
|
+
lineHeight: leading.base,
|
|
287
|
+
letterSpacing: letterSpacing.normal
|
|
288
|
+
},
|
|
289
|
+
text2: {
|
|
290
|
+
fontSize: fontSize.sm,
|
|
291
|
+
// 14px
|
|
292
|
+
fontWeight: fontWeight.normal,
|
|
293
|
+
weights: [fontWeight.normal, fontWeight.medium, fontWeight.semibold],
|
|
294
|
+
lineHeight: leading.sm,
|
|
295
|
+
letterSpacing: letterSpacing.normal
|
|
296
|
+
},
|
|
297
|
+
text3: {
|
|
298
|
+
fontSize: fontSize.xs,
|
|
299
|
+
// 12px
|
|
300
|
+
fontWeight: fontWeight.normal,
|
|
301
|
+
weights: [fontWeight.normal, fontWeight.medium],
|
|
302
|
+
lineHeight: leading.xs,
|
|
303
|
+
letterSpacing: letterSpacing.normal
|
|
304
|
+
}
|
|
305
|
+
};
|
|
306
|
+
var typography = {
|
|
307
|
+
fontFamily,
|
|
308
|
+
fontSize,
|
|
309
|
+
fontWeight,
|
|
310
|
+
leading,
|
|
311
|
+
lineHeight,
|
|
312
|
+
letterSpacing,
|
|
313
|
+
textStyles
|
|
314
|
+
};
|
|
315
|
+
|
|
316
|
+
// src/tokens/spacing.ts
|
|
317
|
+
var space = {
|
|
318
|
+
0: "0",
|
|
319
|
+
1: "4px",
|
|
320
|
+
2: "8px",
|
|
321
|
+
3: "12px",
|
|
322
|
+
4: "16px",
|
|
323
|
+
5: "20px",
|
|
324
|
+
6: "24px",
|
|
325
|
+
8: "32px",
|
|
326
|
+
10: "40px",
|
|
327
|
+
12: "48px",
|
|
328
|
+
16: "64px"
|
|
329
|
+
};
|
|
330
|
+
var spacePx = {
|
|
331
|
+
0: 0,
|
|
332
|
+
1: 4,
|
|
333
|
+
2: 8,
|
|
334
|
+
3: 12,
|
|
335
|
+
4: 16,
|
|
336
|
+
5: 20,
|
|
337
|
+
6: 24,
|
|
338
|
+
8: 32,
|
|
339
|
+
10: 40,
|
|
340
|
+
12: 48,
|
|
341
|
+
16: 64
|
|
342
|
+
};
|
|
343
|
+
var spacing = { space, spacePx };
|
|
344
|
+
|
|
345
|
+
// src/tokens/radius.ts
|
|
346
|
+
var radius = {
|
|
347
|
+
none: "0",
|
|
348
|
+
sm: "4px",
|
|
349
|
+
// elementos pequenos
|
|
350
|
+
md: "6px",
|
|
351
|
+
// itens dentro de caixas, tooltip, skeleton
|
|
352
|
+
lg: "10px",
|
|
353
|
+
// base
|
|
354
|
+
full: "9999px"
|
|
355
|
+
};
|
|
356
|
+
|
|
357
|
+
// src/tokens/shadows.ts
|
|
358
|
+
var shadow = {
|
|
359
|
+
none: "none",
|
|
360
|
+
sm: "0 1px 2px rgba(0, 0, 0, 0.05)",
|
|
361
|
+
md: "0 1px 3px rgba(0, 0, 0, 0.10), 0 1px 2px rgba(0, 0, 0, 0.06)",
|
|
362
|
+
lg: "0 4px 6px -1px rgba(0, 0, 0, 0.10), 0 2px 4px -1px rgba(0, 0, 0, 0.06)",
|
|
363
|
+
xl: "0 20px 25px -5px rgba(0, 0, 0, 0.10), 0 10px 10px -5px rgba(0, 0, 0, 0.04)"
|
|
364
|
+
};
|
|
365
|
+
|
|
366
|
+
// src/tokens/transitions.ts
|
|
367
|
+
var duration = {
|
|
368
|
+
/** Abrir e fechar menus, popovers, Select e modais. */
|
|
369
|
+
instant: "100ms",
|
|
370
|
+
fast: "150ms",
|
|
371
|
+
base: "200ms",
|
|
372
|
+
slow: "300ms"
|
|
373
|
+
};
|
|
374
|
+
var easing = {
|
|
375
|
+
default: "ease",
|
|
376
|
+
in: "cubic-bezier(0.4, 0, 1, 1)",
|
|
377
|
+
out: "cubic-bezier(0, 0, 0.2, 1)",
|
|
378
|
+
inOut: "cubic-bezier(0.4, 0, 0.2, 1)"
|
|
379
|
+
};
|
|
380
|
+
var transition = {
|
|
381
|
+
instant: "0.1s ease",
|
|
382
|
+
fast: "0.15s ease",
|
|
383
|
+
base: "0.2s ease",
|
|
384
|
+
slow: "0.3s ease"
|
|
385
|
+
};
|
|
386
|
+
|
|
387
|
+
// src/tokens/breakpoints.ts
|
|
388
|
+
var breakpoints = {
|
|
389
|
+
xs: "480px",
|
|
390
|
+
sm: "576px",
|
|
391
|
+
md: "768px",
|
|
392
|
+
lg: "992px",
|
|
393
|
+
xl: "1200px",
|
|
394
|
+
xxl: "1600px"
|
|
395
|
+
};
|
|
396
|
+
var breakpointsPx = {
|
|
397
|
+
xs: 480,
|
|
398
|
+
sm: 576,
|
|
399
|
+
md: 768,
|
|
400
|
+
lg: 992,
|
|
401
|
+
xl: 1200,
|
|
402
|
+
xxl: 1600
|
|
403
|
+
};
|
|
404
|
+
|
|
405
|
+
// src/tokens/zIndex.ts
|
|
406
|
+
var zIndex = {
|
|
407
|
+
hide: -1,
|
|
408
|
+
base: 0,
|
|
409
|
+
dropdown: 1e3,
|
|
410
|
+
sticky: 1020,
|
|
411
|
+
fixed: 1030,
|
|
412
|
+
modalBackdrop: 1040,
|
|
413
|
+
modal: 1050,
|
|
414
|
+
popover: 1060,
|
|
415
|
+
tooltip: 1070,
|
|
416
|
+
toast: 1080
|
|
417
|
+
};
|
|
418
|
+
|
|
419
|
+
// src/tokens/opacity.ts
|
|
420
|
+
var opacity = {
|
|
421
|
+
0: "0",
|
|
422
|
+
5: "0.05",
|
|
423
|
+
10: "0.1",
|
|
424
|
+
20: "0.2",
|
|
425
|
+
40: "0.4",
|
|
426
|
+
60: "0.6",
|
|
427
|
+
80: "0.8",
|
|
428
|
+
100: "1"
|
|
429
|
+
};
|
|
430
|
+
|
|
431
|
+
// src/tokens/borderWidth.ts
|
|
432
|
+
var borderWidth = {
|
|
433
|
+
0: "0",
|
|
434
|
+
1: "1px",
|
|
435
|
+
2: "2px",
|
|
436
|
+
4: "4px",
|
|
437
|
+
8: "8px"
|
|
438
|
+
};
|
|
439
|
+
|
|
440
|
+
// src/tokens/blur.ts
|
|
441
|
+
var blur = {
|
|
442
|
+
none: "0",
|
|
443
|
+
sm: "4px",
|
|
444
|
+
md: "8px",
|
|
445
|
+
lg: "16px",
|
|
446
|
+
xl: "24px"
|
|
447
|
+
};
|
|
448
|
+
|
|
449
|
+
// src/tokens/iconSize.ts
|
|
450
|
+
var iconSize = {
|
|
451
|
+
xs: "12px",
|
|
452
|
+
sm: "16px",
|
|
453
|
+
md: "20px",
|
|
454
|
+
lg: "24px",
|
|
455
|
+
xl: "32px"
|
|
456
|
+
};
|
|
457
|
+
var iconSizePx = {
|
|
458
|
+
xs: 12,
|
|
459
|
+
sm: 16,
|
|
460
|
+
md: 20,
|
|
461
|
+
lg: 24,
|
|
462
|
+
xl: 32
|
|
463
|
+
};
|
|
464
|
+
|
|
465
|
+
// src/tokens/index.ts
|
|
466
|
+
var tokens = {
|
|
467
|
+
colors,
|
|
468
|
+
typography,
|
|
469
|
+
spacing,
|
|
470
|
+
radius,
|
|
471
|
+
shadow,
|
|
472
|
+
transition,
|
|
473
|
+
duration,
|
|
474
|
+
easing,
|
|
475
|
+
breakpoints,
|
|
476
|
+
zIndex,
|
|
477
|
+
opacity,
|
|
478
|
+
borderWidth,
|
|
479
|
+
blur,
|
|
480
|
+
iconSize
|
|
481
|
+
};
|
|
482
|
+
|
|
483
|
+
exports.blur = blur;
|
|
484
|
+
exports.borderWidth = borderWidth;
|
|
485
|
+
exports.brand = brand;
|
|
486
|
+
exports.breakpoints = breakpoints;
|
|
487
|
+
exports.breakpointsPx = breakpointsPx;
|
|
488
|
+
exports.chart = chart;
|
|
489
|
+
exports.colors = colors;
|
|
490
|
+
exports.danger = danger;
|
|
491
|
+
exports.duration = duration;
|
|
492
|
+
exports.easing = easing;
|
|
493
|
+
exports.fontFamily = fontFamily;
|
|
494
|
+
exports.fontSize = fontSize;
|
|
495
|
+
exports.fontWeight = fontWeight;
|
|
496
|
+
exports.iconSize = iconSize;
|
|
497
|
+
exports.iconSizePx = iconSizePx;
|
|
498
|
+
exports.leading = leading;
|
|
499
|
+
exports.letterSpacing = letterSpacing;
|
|
500
|
+
exports.lineHeight = lineHeight;
|
|
501
|
+
exports.neutral = neutral;
|
|
502
|
+
exports.opacity = opacity;
|
|
503
|
+
exports.palette = palette;
|
|
504
|
+
exports.primary = primary;
|
|
505
|
+
exports.radius = radius;
|
|
506
|
+
exports.semantic = semantic;
|
|
507
|
+
exports.semanticDark = semanticDark;
|
|
508
|
+
exports.shadow = shadow;
|
|
509
|
+
exports.space = space;
|
|
510
|
+
exports.spacePx = spacePx;
|
|
511
|
+
exports.spacing = spacing;
|
|
512
|
+
exports.success = success;
|
|
513
|
+
exports.support = support;
|
|
514
|
+
exports.textStyles = textStyles;
|
|
515
|
+
exports.tokens = tokens;
|
|
516
|
+
exports.transition = transition;
|
|
517
|
+
exports.typography = typography;
|
|
518
|
+
exports.warning = warning;
|
|
519
|
+
exports.zIndex = zIndex;
|
|
520
|
+
//# sourceMappingURL=index.cjs.map
|
|
521
|
+
//# sourceMappingURL=index.cjs.map
|