rharuow-ds 1.5.0 → 1.5.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/README.md +50 -4
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -44,9 +44,9 @@ Um Design System moderno em React com integração completa ao React Hook Form,
|
|
|
44
44
|
## 🌟 Características
|
|
45
45
|
|
|
46
46
|
- ⚛️ **React 18+** com TypeScript
|
|
47
|
-
- 🧩 **
|
|
48
|
-
-
|
|
49
|
-
-
|
|
47
|
+
- 🧩 **11 componentes** prontos para uso (Input, Textarea, Select, AsyncSelect, MultiSelect, MultiAsyncSelect, RadioGroup, Button, Card, Table, Tooltip)
|
|
48
|
+
- 💡 **Filtro digitável** em componentes Select - Digite para encontrar opções rapidamente
|
|
49
|
+
- 🔗 **Integração nativa** com React Hook Form
|
|
50
50
|
- 🎨 **Customização via CSS Variables** - Mude o tema facilmente
|
|
51
51
|
- 🎯 **Componentes acessíveis** (ARIA)
|
|
52
52
|
- 📱 **Responsivo** por padrão
|
|
@@ -109,6 +109,7 @@ npm install react-hook-form
|
|
|
109
109
|
AsyncSelect,
|
|
110
110
|
MultiSelect,
|
|
111
111
|
RadioGroup,
|
|
112
|
+
Tooltip,
|
|
112
113
|
} from "rharuow-ds";
|
|
113
114
|
|
|
114
115
|
function App() {
|
|
@@ -169,7 +170,10 @@ npm install react-hook-form
|
|
|
169
170
|
{ label: "Grande", value: "lg" },
|
|
170
171
|
]}
|
|
171
172
|
/>
|
|
172
|
-
|
|
173
|
+
|
|
174
|
+
<Tooltip content="Clique para enviar o formulário" position="top">
|
|
175
|
+
<Button variant="default">Enviar</Button>
|
|
176
|
+
</Tooltip>
|
|
173
177
|
</div>
|
|
174
178
|
);
|
|
175
179
|
}
|
|
@@ -189,6 +193,7 @@ npm install react-hook-form
|
|
|
189
193
|
MultiAsyncSelect,
|
|
190
194
|
RadioGroup,
|
|
191
195
|
Button,
|
|
196
|
+
Tooltip,
|
|
192
197
|
} from "rharuow-ds";
|
|
193
198
|
|
|
194
199
|
function FormExample() {
|
|
@@ -395,6 +400,47 @@ Radio buttons modernos e criativos:
|
|
|
395
400
|
- ✅ Diferentes tamanhos (sm, md, lg)
|
|
396
401
|
- ✅ Animações ao selecionar
|
|
397
402
|
|
|
403
|
+
### 💡 **Tooltip**
|
|
404
|
+
|
|
405
|
+
Componente de tooltip inteligente e acessível:
|
|
406
|
+
|
|
407
|
+
- ✅ **Posicionamento automático**: top, bottom, left, right
|
|
408
|
+
- ✅ **Detecção de bordas**: Ajusta posição automaticamente se não couber na tela
|
|
409
|
+
- ✅ **Acessibilidade completa**: Suporte a navegação por teclado e screen readers
|
|
410
|
+
- ✅ **Animações suaves**: Transições de entrada e saída elegantes
|
|
411
|
+
- ✅ **Seta indicativa**: Aponta para o elemento que ativou o tooltip
|
|
412
|
+
- ✅ **Suporte a temas**: Variáveis CSS para light/dark mode
|
|
413
|
+
- ✅ **Flexível**: Funciona com qualquer elemento como trigger
|
|
414
|
+
- ✅ **Controle de estado**: Pode ser desabilitado conforme necessário
|
|
415
|
+
|
|
416
|
+
```tsx
|
|
417
|
+
// Tooltip básico
|
|
418
|
+
<Tooltip content="Informação útil" position="top">
|
|
419
|
+
<Button>Passe o mouse aqui</Button>
|
|
420
|
+
</Tooltip>
|
|
421
|
+
|
|
422
|
+
// Tooltip com texto
|
|
423
|
+
<Tooltip content="Clique para mais detalhes" position="right">
|
|
424
|
+
<span className="underline cursor-help">
|
|
425
|
+
Texto com tooltip
|
|
426
|
+
</span>
|
|
427
|
+
</Tooltip>
|
|
428
|
+
|
|
429
|
+
// Tooltip personalizado
|
|
430
|
+
<Tooltip
|
|
431
|
+
content="Tooltip customizado"
|
|
432
|
+
position="bottom"
|
|
433
|
+
className="bg-red-500 text-white"
|
|
434
|
+
>
|
|
435
|
+
<Button variant="outline">Hover aqui</Button>
|
|
436
|
+
</Tooltip>
|
|
437
|
+
|
|
438
|
+
// Tooltip desabilitado
|
|
439
|
+
<Tooltip content="Este não aparece" disabled>
|
|
440
|
+
<Button>Tooltip desabilitado</Button>
|
|
441
|
+
</Tooltip>
|
|
442
|
+
```
|
|
443
|
+
|
|
398
444
|
---
|
|
399
445
|
|
|
400
446
|
## 🎨 Customização de Tema
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "rharuow-ds",
|
|
3
|
-
"version": "1.5.
|
|
3
|
+
"version": "1.5.1",
|
|
4
4
|
"description": "Modern React Design System with 11 components: Table (Header, Body, Footer, Row, Cell), Card (Header, Body, Footer), Button, Input (with password support), Textarea, Select, AsyncSelect, MultiSelect, MultiAsyncSelect, RadioGroup, and Tooltip. Full React Hook Form integration, Tailwind CSS styling, CSS Variables for theme customization and dark mode support.",
|
|
5
5
|
"main": "dist/rharuow-ds.cjs.js",
|
|
6
6
|
"module": "dist/rharuow-ds.es.js",
|