@alishenriques/design-system 0.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.
package/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Alisson Henriques
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md ADDED
@@ -0,0 +1,33 @@
1
+ # @alishenriques/design-system
2
+
3
+ Biblioteca de componentes React isolada, usada no [portfólio](https://github.com/alishenriques/alis-portfolio) e reaproveitável em projetos futuros. Publicada no npm público.
4
+
5
+ Arquitetura completa e convenções: [`docs/ai`](https://github.com/alishenriques/alis-portfolio/tree/main/docs/ai) no repositório principal.
6
+
7
+ ## Uso
8
+
9
+ ```bash
10
+ yarn add @alishenriques/design-system
11
+ ```
12
+
13
+ ```tsx
14
+ import { Button } from "@alishenriques/design-system";
15
+ import "@alishenriques/design-system/styles.css";
16
+ ```
17
+
18
+ Requer `react` e `react-dom` 19 como peer dependencies.
19
+
20
+ ## Desenvolvimento
21
+
22
+ ```bash
23
+ yarn install
24
+ yarn dev # build em watch
25
+ ```
26
+
27
+ `yarn lint` · `yarn typecheck` · `yarn test` · `yarn build`
28
+
29
+ ## Componentes
30
+
31
+ - `Button` (`primary`, `ghost`)
32
+
33
+ Estilos via CSS Modules e tokens `--ds-*` (`src/tokens.css`).
@@ -0,0 +1,7 @@
1
+ import { ButtonHTMLAttributes, ReactNode } from 'react';
2
+ export type ButtonVariant = "primary" | "ghost";
3
+ export type ButtonProps = {
4
+ children: ReactNode;
5
+ variant?: ButtonVariant;
6
+ } & ButtonHTMLAttributes<HTMLButtonElement>;
7
+ export declare function Button({ children, variant, type, className, ...props }: ButtonProps): import("react").JSX.Element;
@@ -0,0 +1,2 @@
1
+ export { Button } from './Button';
2
+ export type { ButtonProps, ButtonVariant } from './Button';
@@ -0,0 +1 @@
1
+ :root{--ds-color-bg: #0b0b0f;--ds-color-fg: #f4f1ea;--ds-color-muted: #9a958c;--ds-color-accent: #c8ff00;--ds-color-accent-ink: #111111;--ds-radius-sm: 8px;--ds-radius-md: 16px;--ds-space-2: .5rem;--ds-space-3: .75rem;--ds-space-4: 1rem;--ds-font-sans: "Geist", "Segoe UI", sans-serif;--ds-motion-fast: .18s cubic-bezier(.22, 1, .36, 1)}._button_1jhtl_1{display:inline-flex;align-items:center;justify-content:center;gap:var(--ds-space-2);border:0;border-radius:var(--ds-radius-sm);padding:var(--ds-space-3) var(--ds-space-4);font-family:var(--ds-font-sans);font-weight:600;letter-spacing:.01em;cursor:pointer;transition:transform var(--ds-motion-fast),background-color var(--ds-motion-fast),box-shadow var(--ds-motion-fast)}._button_1jhtl_1:hover{transform:translateY(-1px)}._button_1jhtl_1:active{transform:translateY(0)}._button_1jhtl_1:disabled{cursor:not-allowed;opacity:.5;transform:none}._primary_1jhtl_33{background:var(--ds-color-accent);color:var(--ds-color-accent-ink);box-shadow:0 0 0 0 transparent}._primary_1jhtl_33:hover:not(:disabled){box-shadow:0 8px 24px color-mix(in srgb,var(--ds-color-accent) 35%,transparent)}._ghost_1jhtl_43{background:transparent;color:var(--ds-color-fg);box-shadow:inset 0 0 0 1px color-mix(in srgb,var(--ds-color-fg) 22%,transparent)}
@@ -0,0 +1,2 @@
1
+ export { Button } from './components/Button';
2
+ export type { ButtonProps, ButtonVariant } from './components/Button';
package/dist/index.js ADDED
@@ -0,0 +1,19 @@
1
+ import { jsx as _ } from "react/jsx-runtime";
2
+ const c = "_button_1jhtl_1", i = "_primary_1jhtl_33", l = "_ghost_1jhtl_43", o = {
3
+ button: c,
4
+ primary: i,
5
+ ghost: l
6
+ };
7
+ function m({
8
+ children: n,
9
+ variant: t = "primary",
10
+ type: s = "button",
11
+ className: r,
12
+ ...a
13
+ }) {
14
+ const u = [o.button, o[t], r].filter(Boolean).join(" ");
15
+ return /* @__PURE__ */ _("button", { type: s, className: u, "data-variant": t, ...a, children: n });
16
+ }
17
+ export {
18
+ m as Button
19
+ };
package/package.json ADDED
@@ -0,0 +1,64 @@
1
+ {
2
+ "name": "@alishenriques/design-system",
3
+ "version": "0.1.0",
4
+ "description": "Isolated design system for Alis portfolio and future products",
5
+ "type": "module",
6
+ "main": "./dist/index.js",
7
+ "module": "./dist/index.js",
8
+ "types": "./dist/index.d.ts",
9
+ "exports": {
10
+ ".": {
11
+ "types": "./dist/index.d.ts",
12
+ "import": "./dist/index.js"
13
+ },
14
+ "./styles.css": "./dist/design-system.css"
15
+ },
16
+ "files": [
17
+ "dist"
18
+ ],
19
+ "sideEffects": [
20
+ "**/*.css"
21
+ ],
22
+ "scripts": {
23
+ "dev": "vite build --watch",
24
+ "build": "vite build",
25
+ "lint": "eslint src",
26
+ "typecheck": "tsc --noEmit",
27
+ "test": "vitest run",
28
+ "test:watch": "vitest"
29
+ },
30
+ "peerDependencies": {
31
+ "react": "^19.0.0",
32
+ "react-dom": "^19.0.0"
33
+ },
34
+ "devDependencies": {
35
+ "@eslint/js": "^9.36.0",
36
+ "@testing-library/dom": "^10.4.2",
37
+ "@testing-library/jest-dom": "^6.8.0",
38
+ "@testing-library/react": "^16.3.0",
39
+ "@types/node": "^22",
40
+ "@types/react": "^19.1.13",
41
+ "@types/react-dom": "^19.1.9",
42
+ "@vitejs/plugin-react": "^5.0.3",
43
+ "eslint": "^9.36.0",
44
+ "eslint-plugin-react-hooks": "^5.2.0",
45
+ "jsdom": "^27.0.0",
46
+ "react": "^19.1.1",
47
+ "react-dom": "^19.1.1",
48
+ "typescript": "^5.9.2",
49
+ "typescript-eslint": "^8.44.1",
50
+ "vite": "^7.1.7",
51
+ "vite-plugin-dts": "^4.5.4",
52
+ "vitest": "^3.2.4"
53
+ },
54
+ "packageManager": "yarn@4.9.2",
55
+ "repository": {
56
+ "type": "git",
57
+ "url": "git+https://github.com/alishenriques/alis-design-system.git"
58
+ },
59
+ "license": "MIT",
60
+ "publishConfig": {
61
+ "access": "public",
62
+ "provenance": true
63
+ }
64
+ }