@walidsj/react-ui 0.0.0-stage → 0.1.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/LICENSE +17 -0
- package/README.md +163 -2
- package/dist/components/button/button.d.ts +14 -0
- package/dist/components/button/index.d.ts +2 -0
- package/dist/components/input/index.d.ts +2 -0
- package/dist/components/input/input.d.ts +5 -0
- package/dist/index.d.ts +4 -0
- package/dist/index.js +106 -0
- package/dist/index.js.map +1 -0
- package/dist/lib/cn.d.ts +2 -0
- package/dist/style.css +457 -0
- package/package.json +88 -4
package/LICENSE
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 Walid
|
|
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.
|
package/README.md
CHANGED
|
@@ -1,3 +1,164 @@
|
|
|
1
|
-
#
|
|
1
|
+
# @walidsj/react-ui
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
A customizable React design system built with Base UI, TypeScript, and
|
|
4
|
+
Tailwind CSS v4.
|
|
5
|
+
|
|
6
|
+
> Status: early development. Public APIs and visual tokens may change
|
|
7
|
+
> before `1.0.0`.
|
|
8
|
+
|
|
9
|
+
## Features
|
|
10
|
+
|
|
11
|
+
- Typed React components with native prop and ref forwarding.
|
|
12
|
+
- Base UI primitives for interactive behavior where appropriate.
|
|
13
|
+
- Custom visual styling with Tailwind CSS v4.
|
|
14
|
+
- Semantic design tokens with light and dark themes.
|
|
15
|
+
- Compiled stylesheet distributed with the npm package.
|
|
16
|
+
- ESM output with TypeScript declarations and tree-shaking support.
|
|
17
|
+
|
|
18
|
+
## Installation
|
|
19
|
+
|
|
20
|
+
``` bash
|
|
21
|
+
npm install @walidsj/react-ui
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
Requires React 19. The package is ESM-only.
|
|
25
|
+
|
|
26
|
+
## Usage
|
|
27
|
+
|
|
28
|
+
Import the compiled stylesheet once, then use components from the package
|
|
29
|
+
root:
|
|
30
|
+
|
|
31
|
+
``` tsx
|
|
32
|
+
import { Button, Input } from "@walidsj/react-ui";
|
|
33
|
+
import "@walidsj/react-ui/style.css";
|
|
34
|
+
|
|
35
|
+
export function Example() {
|
|
36
|
+
return (
|
|
37
|
+
<div style={{ display: "grid", gap: "1rem", maxWidth: "24rem" }}>
|
|
38
|
+
<Input aria-label="Full name" placeholder="Full name" />
|
|
39
|
+
<Button variant="primary" size="md">
|
|
40
|
+
Save changes
|
|
41
|
+
</Button>
|
|
42
|
+
</div>
|
|
43
|
+
);
|
|
44
|
+
}
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
## Components
|
|
48
|
+
|
|
49
|
+
### Button
|
|
50
|
+
|
|
51
|
+
Renders a native `<button>`, defaults to `type="button"`, and forwards
|
|
52
|
+
native button props and refs.
|
|
53
|
+
|
|
54
|
+
| Prop | Type | Default |
|
|
55
|
+
| ----------- | ---------------------------------------------------------- | ----------- |
|
|
56
|
+
| `variant` | `primary \| secondary \| outline \| ghost \| danger` | `primary` |
|
|
57
|
+
| `size` | `sm \| md \| lg` | `md` |
|
|
58
|
+
| `type` | Native button type | `button` |
|
|
59
|
+
| `disabled` | `boolean` | `false` |
|
|
60
|
+
| `className` | `string` | — |
|
|
61
|
+
|
|
62
|
+
Icon-only buttons must receive an accessible name from the consumer,
|
|
63
|
+
for example `aria-label`.
|
|
64
|
+
|
|
65
|
+
### Input
|
|
66
|
+
|
|
67
|
+
Renders a native `<input>` and forwards native input props and refs.
|
|
68
|
+
|
|
69
|
+
| Prop | Type | Default |
|
|
70
|
+
| ----------- | --------- | ------- |
|
|
71
|
+
| `invalid` | `boolean` | `false` |
|
|
72
|
+
| `className` | `string` | — |
|
|
73
|
+
|
|
74
|
+
`invalid` sets `aria-invalid="true"` and applies error styling. A
|
|
75
|
+
consumer-provided `aria-invalid` value is preserved when `invalid` is
|
|
76
|
+
not set. Labels, descriptions, and error messages are composed by the
|
|
77
|
+
consumer.
|
|
78
|
+
|
|
79
|
+
Both components merge `className` with their internal classes. Conflicting
|
|
80
|
+
Tailwind utilities are resolved with `tailwind-merge`.
|
|
81
|
+
|
|
82
|
+
## Styling
|
|
83
|
+
|
|
84
|
+
The package ships a precompiled stylesheet at
|
|
85
|
+
`@walidsj/react-ui/style.css`. Consumers do not need Tailwind or a Tailwind
|
|
86
|
+
configuration to compile the library's CSS.
|
|
87
|
+
|
|
88
|
+
The stylesheet includes only the utilities used by the published
|
|
89
|
+
components and the semantic theme tokens. It intentionally does not
|
|
90
|
+
include Tailwind Preflight, and it does not set the host application's
|
|
91
|
+
global background, text color, or font family.
|
|
92
|
+
|
|
93
|
+
### Theme tokens
|
|
94
|
+
|
|
95
|
+
Override these variables on a wrapping element to customize the theme:
|
|
96
|
+
|
|
97
|
+
| Token | Purpose |
|
|
98
|
+
| ---------------------------- | --------------------------- |
|
|
99
|
+
| `--ui-background` | Main component surface |
|
|
100
|
+
| `--ui-foreground` | Main text |
|
|
101
|
+
| `--ui-primary` | Primary action surface |
|
|
102
|
+
| `--ui-primary-foreground` | Text on primary surface |
|
|
103
|
+
| `--ui-secondary` | Secondary surface |
|
|
104
|
+
| `--ui-secondary-foreground` | Text on secondary surface |
|
|
105
|
+
| `--ui-muted` | Subtle surface |
|
|
106
|
+
| `--ui-muted-foreground` | Secondary text |
|
|
107
|
+
| `--ui-border` | Default border |
|
|
108
|
+
| `--ui-ring` | Focus ring |
|
|
109
|
+
| `--ui-danger` | Destructive action surface |
|
|
110
|
+
| `--ui-danger-foreground` | Text on destructive surface |
|
|
111
|
+
| `--ui-radius-sm` | Small radius |
|
|
112
|
+
| `--ui-radius-md` | Medium radius |
|
|
113
|
+
| `--ui-radius-lg` | Large radius |
|
|
114
|
+
|
|
115
|
+
``` css
|
|
116
|
+
.brand-theme {
|
|
117
|
+
--ui-primary: oklch(0.55 0.18 150);
|
|
118
|
+
--ui-ring: oklch(0.55 0.18 150);
|
|
119
|
+
--ui-radius-md: 0.25rem;
|
|
120
|
+
}
|
|
121
|
+
```
|
|
122
|
+
|
|
123
|
+
### Dark mode
|
|
124
|
+
|
|
125
|
+
Apply the `dark` class to any ancestor of the components:
|
|
126
|
+
|
|
127
|
+
``` tsx
|
|
128
|
+
<div className="dark">
|
|
129
|
+
<Button>Dark theme button</Button>
|
|
130
|
+
</div>
|
|
131
|
+
```
|
|
132
|
+
|
|
133
|
+
## Development
|
|
134
|
+
|
|
135
|
+
This repository uses Bun for dependency management and development
|
|
136
|
+
scripts.
|
|
137
|
+
|
|
138
|
+
``` bash
|
|
139
|
+
bun install
|
|
140
|
+
bun run typecheck
|
|
141
|
+
bun run lint
|
|
142
|
+
bun run test
|
|
143
|
+
bun run build
|
|
144
|
+
npm pack --dry-run
|
|
145
|
+
```
|
|
146
|
+
|
|
147
|
+
`bun run dev` watches the library build. `bun run test:watch` runs
|
|
148
|
+
Vitest in watch mode.
|
|
149
|
+
|
|
150
|
+
## Documentation
|
|
151
|
+
|
|
152
|
+
- Product requirements: `PRD.md`
|
|
153
|
+
- Design tokens and component rules: `DESIGN.md`
|
|
154
|
+
- Architecture: `ARCHITECTURE.md`
|
|
155
|
+
- Testing: `TESTING.md`
|
|
156
|
+
- Contributing: `CONTRIBUTING.md`
|
|
157
|
+
- Release: `RELEASE.md`
|
|
158
|
+
- Agent instructions: `AGENTS.md`
|
|
159
|
+
- Security: `SECURITY.md`
|
|
160
|
+
|
|
161
|
+
## License
|
|
162
|
+
|
|
163
|
+
MIT. See `LICENSE`.
|
|
164
|
+
# walid-ui
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { VariantProps } from 'class-variance-authority';
|
|
2
|
+
import { ComponentPropsWithoutRef } from 'react';
|
|
3
|
+
declare const buttonVariants: (props?: ({
|
|
4
|
+
variant?: "primary" | "secondary" | "outline" | "ghost" | "danger" | null | undefined;
|
|
5
|
+
size?: "sm" | "md" | "lg" | null | undefined;
|
|
6
|
+
} & import('class-variance-authority/types').ClassProp) | undefined) => string;
|
|
7
|
+
export type ButtonVariant = NonNullable<VariantProps<typeof buttonVariants>["variant"]>;
|
|
8
|
+
export type ButtonSize = NonNullable<VariantProps<typeof buttonVariants>["size"]>;
|
|
9
|
+
export interface ButtonProps extends ComponentPropsWithoutRef<"button"> {
|
|
10
|
+
variant?: ButtonVariant;
|
|
11
|
+
size?: ButtonSize;
|
|
12
|
+
}
|
|
13
|
+
export declare const Button: import('react').ForwardRefExoticComponent<ButtonProps & import('react').RefAttributes<HTMLButtonElement>>;
|
|
14
|
+
export {};
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { ComponentPropsWithoutRef } from 'react';
|
|
2
|
+
export interface InputProps extends ComponentPropsWithoutRef<"input"> {
|
|
3
|
+
invalid?: boolean;
|
|
4
|
+
}
|
|
5
|
+
export declare const Input: import('react').ForwardRefExoticComponent<InputProps & import('react').RefAttributes<HTMLInputElement>>;
|
package/dist/index.d.ts
ADDED
package/dist/index.js
ADDED
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
import { Button as Button$1 } from "@base-ui/react/button";
|
|
2
|
+
import { clsx } from "clsx";
|
|
3
|
+
import { forwardRef } from "react";
|
|
4
|
+
import { twMerge } from "tailwind-merge";
|
|
5
|
+
import { jsx } from "react/jsx-runtime";
|
|
6
|
+
import { Input as Input$1 } from "@base-ui/react/input";
|
|
7
|
+
// node_modules/class-variance-authority/dist/index.mjs
|
|
8
|
+
/**
|
|
9
|
+
* Copyright 2022 Joe Bell. All rights reserved.
|
|
10
|
+
*
|
|
11
|
+
* This file is licensed to you under the Apache License, Version 2.0
|
|
12
|
+
* (the "License"); you may not use this file except in compliance with the
|
|
13
|
+
* License. You may obtain a copy of the License at
|
|
14
|
+
*
|
|
15
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
16
|
+
*
|
|
17
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
18
|
+
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
|
19
|
+
* WARRANTIES OR REPRESENTATIONS OF ANY KIND, either express or implied. See the
|
|
20
|
+
* License for the specific language governing permissions and limitations under
|
|
21
|
+
* the License.
|
|
22
|
+
*/ var falsyToString = (value) => typeof value === "boolean" ? `${value}` : value === 0 ? "0" : value;
|
|
23
|
+
var cx = clsx;
|
|
24
|
+
var cva = (base, config) => (props) => {
|
|
25
|
+
var _config_compoundVariants;
|
|
26
|
+
if ((config === null || config === void 0 ? void 0 : config.variants) == null) return cx(base, props === null || props === void 0 ? void 0 : props.class, props === null || props === void 0 ? void 0 : props.className);
|
|
27
|
+
const { variants, defaultVariants } = config;
|
|
28
|
+
const getVariantClassNames = Object.keys(variants).map((variant) => {
|
|
29
|
+
const variantProp = props === null || props === void 0 ? void 0 : props[variant];
|
|
30
|
+
const defaultVariantProp = defaultVariants === null || defaultVariants === void 0 ? void 0 : defaultVariants[variant];
|
|
31
|
+
if (variantProp === null) return null;
|
|
32
|
+
const variantKey = falsyToString(variantProp) || falsyToString(defaultVariantProp);
|
|
33
|
+
return variants[variant][variantKey];
|
|
34
|
+
});
|
|
35
|
+
const propsWithoutUndefined = props && Object.entries(props).reduce((acc, param) => {
|
|
36
|
+
let [key, value] = param;
|
|
37
|
+
if (value === void 0) return acc;
|
|
38
|
+
acc[key] = value;
|
|
39
|
+
return acc;
|
|
40
|
+
}, {});
|
|
41
|
+
return cx(base, getVariantClassNames, config === null || config === void 0 ? void 0 : (_config_compoundVariants = config.compoundVariants) === null || _config_compoundVariants === void 0 ? void 0 : _config_compoundVariants.reduce((acc, param) => {
|
|
42
|
+
let { class: cvClass, className: cvClassName, ...compoundVariantOptions } = param;
|
|
43
|
+
return Object.entries(compoundVariantOptions).every((param) => {
|
|
44
|
+
let [key, value] = param;
|
|
45
|
+
return Array.isArray(value) ? value.includes({
|
|
46
|
+
...defaultVariants,
|
|
47
|
+
...propsWithoutUndefined
|
|
48
|
+
}[key]) : {
|
|
49
|
+
...defaultVariants,
|
|
50
|
+
...propsWithoutUndefined
|
|
51
|
+
}[key] === value;
|
|
52
|
+
}) ? [
|
|
53
|
+
...acc,
|
|
54
|
+
cvClass,
|
|
55
|
+
cvClassName
|
|
56
|
+
] : acc;
|
|
57
|
+
}, []), props === null || props === void 0 ? void 0 : props.class, props === null || props === void 0 ? void 0 : props.className);
|
|
58
|
+
};
|
|
59
|
+
// src/lib/cn.ts
|
|
60
|
+
function cn(...inputs) {
|
|
61
|
+
return twMerge(clsx(inputs));
|
|
62
|
+
}
|
|
63
|
+
// src/components/button/button.tsx
|
|
64
|
+
var buttonVariants = cva("inline-flex select-none items-center justify-center whitespace-nowrap rounded-ui-md font-medium transition-colors outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:pointer-events-none disabled:opacity-50", {
|
|
65
|
+
variants: {
|
|
66
|
+
variant: {
|
|
67
|
+
primary: "bg-primary text-primary-foreground hover:bg-primary/90 active:bg-primary/80",
|
|
68
|
+
secondary: "bg-secondary text-secondary-foreground hover:bg-secondary/80 active:bg-secondary/70",
|
|
69
|
+
outline: "border border-border bg-transparent text-foreground hover:bg-muted active:bg-muted/70",
|
|
70
|
+
ghost: "bg-transparent text-foreground hover:bg-muted active:bg-muted/70",
|
|
71
|
+
danger: "bg-danger text-danger-foreground hover:bg-danger/90 active:bg-danger/80"
|
|
72
|
+
},
|
|
73
|
+
size: {
|
|
74
|
+
sm: "h-8 gap-1.5 px-3 text-sm",
|
|
75
|
+
md: "h-10 gap-2 px-4 text-sm",
|
|
76
|
+
lg: "h-12 gap-2.5 px-6 text-base"
|
|
77
|
+
}
|
|
78
|
+
},
|
|
79
|
+
defaultVariants: {
|
|
80
|
+
variant: "primary",
|
|
81
|
+
size: "md"
|
|
82
|
+
}
|
|
83
|
+
});
|
|
84
|
+
var Button = forwardRef(function Button({ className, variant = "primary", size = "md", type = "button", ...props }, ref) {
|
|
85
|
+
return /* @__PURE__ */ jsx(Button$1, {
|
|
86
|
+
...props,
|
|
87
|
+
ref,
|
|
88
|
+
type,
|
|
89
|
+
className: cn(buttonVariants({
|
|
90
|
+
variant,
|
|
91
|
+
size
|
|
92
|
+
}), className)
|
|
93
|
+
});
|
|
94
|
+
});
|
|
95
|
+
// src/components/input/input.tsx
|
|
96
|
+
var Input = forwardRef(function Input({ className, invalid = false, "aria-invalid": ariaInvalid, ...props }, ref) {
|
|
97
|
+
return /* @__PURE__ */ jsx(Input$1, {
|
|
98
|
+
...props,
|
|
99
|
+
ref,
|
|
100
|
+
"aria-invalid": invalid || ariaInvalid,
|
|
101
|
+
className: cn("flex h-10 w-full rounded-ui-md border border-border bg-background px-3 py-2 text-sm text-foreground shadow-sm outline-none transition-colors placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-2 focus-visible:ring-ring/30 disabled:cursor-not-allowed disabled:opacity-50 aria-[invalid=true]:border-danger aria-[invalid=true]:focus-visible:ring-danger/30", className)
|
|
102
|
+
});
|
|
103
|
+
});
|
|
104
|
+
export { Button, Input };
|
|
105
|
+
|
|
106
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","names":["BaseButton","BaseInput"],"sources":["../node_modules/class-variance-authority/dist/index.mjs","../src/lib/cn.ts","../src/components/button/button.tsx","../src/components/input/input.tsx"],"sourcesContent":["/**\n * Copyright 2022 Joe Bell. All rights reserved.\n *\n * This file is licensed to you under the Apache License, Version 2.0\n * (the \"License\"); you may not use this file except in compliance with the\n * License. You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT\n * WARRANTIES OR REPRESENTATIONS OF ANY KIND, either express or implied. See the\n * License for the specific language governing permissions and limitations under\n * the License.\n */ import { clsx } from \"clsx\";\nconst falsyToString = (value)=>typeof value === \"boolean\" ? `${value}` : value === 0 ? \"0\" : value;\nexport const cx = clsx;\nexport const cva = (base, config)=>(props)=>{\n var _config_compoundVariants;\n if ((config === null || config === void 0 ? void 0 : config.variants) == null) return cx(base, props === null || props === void 0 ? void 0 : props.class, props === null || props === void 0 ? void 0 : props.className);\n const { variants, defaultVariants } = config;\n const getVariantClassNames = Object.keys(variants).map((variant)=>{\n const variantProp = props === null || props === void 0 ? void 0 : props[variant];\n const defaultVariantProp = defaultVariants === null || defaultVariants === void 0 ? void 0 : defaultVariants[variant];\n if (variantProp === null) return null;\n const variantKey = falsyToString(variantProp) || falsyToString(defaultVariantProp);\n return variants[variant][variantKey];\n });\n const propsWithoutUndefined = props && Object.entries(props).reduce((acc, param)=>{\n let [key, value] = param;\n if (value === undefined) {\n return acc;\n }\n acc[key] = value;\n return acc;\n }, {});\n const getCompoundVariantClassNames = config === null || config === void 0 ? void 0 : (_config_compoundVariants = config.compoundVariants) === null || _config_compoundVariants === void 0 ? void 0 : _config_compoundVariants.reduce((acc, param)=>{\n let { class: cvClass, className: cvClassName, ...compoundVariantOptions } = param;\n return Object.entries(compoundVariantOptions).every((param)=>{\n let [key, value] = param;\n return Array.isArray(value) ? value.includes({\n ...defaultVariants,\n ...propsWithoutUndefined\n }[key]) : ({\n ...defaultVariants,\n ...propsWithoutUndefined\n })[key] === value;\n }) ? [\n ...acc,\n cvClass,\n cvClassName\n ] : acc;\n }, []);\n return cx(base, getVariantClassNames, getCompoundVariantClassNames, props === null || props === void 0 ? void 0 : props.class, props === null || props === void 0 ? void 0 : props.className);\n };\n\n","import { type ClassValue, clsx } from \"clsx\";\nimport { twMerge } from \"tailwind-merge\";\n\nexport function cn(...inputs: ClassValue[]) {\n return twMerge(clsx(inputs));\n}\n","import { Button as BaseButton } from \"@base-ui/react/button\";\nimport { cva, type VariantProps } from \"class-variance-authority\";\nimport { type ComponentPropsWithoutRef, forwardRef, type Ref } from \"react\";\nimport { cn } from \"../../lib/cn\";\n\nconst buttonVariants = cva(\n \"inline-flex select-none items-center justify-center whitespace-nowrap rounded-ui-md font-medium transition-colors outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:pointer-events-none disabled:opacity-50\",\n {\n variants: {\n variant: {\n primary:\n \"bg-primary text-primary-foreground hover:bg-primary/90 active:bg-primary/80\",\n secondary:\n \"bg-secondary text-secondary-foreground hover:bg-secondary/80 active:bg-secondary/70\",\n outline:\n \"border border-border bg-transparent text-foreground hover:bg-muted active:bg-muted/70\",\n ghost:\n \"bg-transparent text-foreground hover:bg-muted active:bg-muted/70\",\n danger:\n \"bg-danger text-danger-foreground hover:bg-danger/90 active:bg-danger/80\",\n },\n size: {\n sm: \"h-8 gap-1.5 px-3 text-sm\",\n md: \"h-10 gap-2 px-4 text-sm\",\n lg: \"h-12 gap-2.5 px-6 text-base\",\n },\n },\n defaultVariants: {\n variant: \"primary\",\n size: \"md\",\n },\n },\n);\n\nexport type ButtonVariant = NonNullable<\n VariantProps<typeof buttonVariants>[\"variant\"]\n>;\nexport type ButtonSize = NonNullable<\n VariantProps<typeof buttonVariants>[\"size\"]\n>;\n\nexport interface ButtonProps extends ComponentPropsWithoutRef<\"button\"> {\n variant?: ButtonVariant;\n size?: ButtonSize;\n}\n\nexport const Button = forwardRef<HTMLButtonElement, ButtonProps>(\n function Button(\n { className, variant = \"primary\", size = \"md\", type = \"button\", ...props },\n ref,\n ) {\n return (\n <BaseButton\n {...props}\n ref={ref as Ref<HTMLElement>}\n type={type}\n className={cn(buttonVariants({ variant, size }), className)}\n />\n );\n },\n);\n","import { Input as BaseInput } from \"@base-ui/react/input\";\nimport { type ComponentPropsWithoutRef, forwardRef, type Ref } from \"react\";\nimport { cn } from \"../../lib/cn\";\n\nexport interface InputProps extends ComponentPropsWithoutRef<\"input\"> {\n invalid?: boolean;\n}\n\nexport const Input = forwardRef<HTMLInputElement, InputProps>(function Input(\n { className, invalid = false, \"aria-invalid\": ariaInvalid, ...props },\n ref,\n) {\n return (\n <BaseInput\n {...props}\n ref={ref as Ref<HTMLElement>}\n aria-invalid={invalid || ariaInvalid}\n className={cn(\n \"flex h-10 w-full rounded-ui-md border border-border bg-background px-3 py-2 text-sm text-foreground shadow-sm outline-none transition-colors placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-2 focus-visible:ring-ring/30 disabled:cursor-not-allowed disabled:opacity-50 aria-[invalid=true]:border-danger aria-[invalid=true]:focus-visible:ring-danger/30\",\n className,\n )}\n />\n );\n});\n"],"ignoreList":[0],"mappings":";;;;;;;;;;;;;;;;;;;;;GAeA,IAAM,iBAAiB,UAAQ,OAAO,UAAU,YAAY,GAAG,UAAU,UAAU,IAAI,MAAM;AAC7F,IAAa,KAAK;AAClB,IAAa,OAAO,MAAM,YAAU,UAAQ;CACpC,IAAI;CACJ,KAAK,WAAW,QAAQ,WAAW,KAAK,IAAI,KAAK,IAAI,OAAO,aAAa,MAAM,OAAO,GAAG,MAAM,UAAU,QAAQ,UAAU,KAAK,IAAI,KAAK,IAAI,MAAM,OAAO,UAAU,QAAQ,UAAU,KAAK,IAAI,KAAK,IAAI,MAAM,SAAS;CACvN,MAAM,EAAE,UAAU,oBAAoB;CACtC,MAAM,uBAAuB,OAAO,KAAK,QAAQ,CAAC,CAAC,KAAK,YAAU;EAC9D,MAAM,cAAc,UAAU,QAAQ,UAAU,KAAK,IAAI,KAAK,IAAI,MAAM;EACxE,MAAM,qBAAqB,oBAAoB,QAAQ,oBAAoB,KAAK,IAAI,KAAK,IAAI,gBAAgB;EAC7G,IAAI,gBAAgB,MAAM,OAAO;EACjC,MAAM,aAAa,cAAc,WAAW,KAAK,cAAc,kBAAkB;EACjF,OAAO,SAAS,QAAQ,CAAC;CAC7B,CAAC;CACD,MAAM,wBAAwB,SAAS,OAAO,QAAQ,KAAK,CAAC,CAAC,QAAQ,KAAK,UAAQ;EAC9E,IAAI,CAAC,KAAK,SAAS;EACnB,IAAI,UAAU,KAAA,GACV,OAAO;EAEX,IAAI,OAAO;EACX,OAAO;CACX,GAAG,CAAC,CAAC;CAkBL,OAAO,GAAG,MAAM,sBAjBqB,WAAW,QAAQ,WAAW,KAAK,IAAI,KAAK,KAAK,2BAA2B,OAAO,sBAAsB,QAAQ,6BAA6B,KAAK,IAAI,KAAK,IAAI,yBAAyB,QAAQ,KAAK,UAAQ;EAC/O,IAAI,EAAE,OAAO,SAAS,WAAW,aAAa,GAAG,2BAA2B;EAC5E,OAAO,OAAO,QAAQ,sBAAsB,CAAC,CAAC,OAAO,UAAQ;GACzD,IAAI,CAAC,KAAK,SAAS;GACnB,OAAO,MAAM,QAAQ,KAAK,IAAI,MAAM,SAAS;IACzC,GAAG;IACH,GAAG;GACP,EAAE,IAAI,IAAK;IACP,GAAG;IACH,GAAG;GACP,EAAG,SAAS;EAChB,CAAC,IAAI;GACD,GAAG;GACH;GACA;EACJ,IAAI;CACR,GAAG,CAAC,CAAC,GAC+D,UAAU,QAAQ,UAAU,KAAK,IAAI,KAAK,IAAI,MAAM,OAAO,UAAU,QAAQ,UAAU,KAAK,IAAI,KAAK,IAAI,MAAM,SAAS;AAChM;;ACnDJ,SAAgB,GAAG,GAAG,QAAsB;CAC1C,OAAO,QAAQ,KAAK,MAAM,CAAC;AAC7B;;ACAA,IAAM,iBAAiB,IACrB,iSACA;CACE,UAAU;EACR,SAAS;GACP,SACE;GACF,WACE;GACF,SACE;GACF,OACE;GACF,QACE;EACJ;EACA,MAAM;GACJ,IAAI;GACJ,IAAI;GACJ,IAAI;EACN;CACF;CACA,iBAAiB;EACf,SAAS;EACT,MAAM;CACR;AACF,CACF;AAcA,IAAa,SAAS,WACpB,SAAS,OACP,EAAE,WAAW,UAAU,WAAW,OAAO,MAAM,OAAO,UAAU,GAAG,SACnE,KACA;CACA,OACE,oBAACA,UAAD;EACE,GAAI;EACC;EACC;EACN,WAAW,GAAG,eAAe;GAAE;GAAS;EAAK,CAAC,GAAG,SAAS;CAC3D,CAAA;AAEL,CACF;;ACpDA,IAAa,QAAQ,WAAyC,SAAS,MACrE,EAAE,WAAW,UAAU,OAAO,gBAAgB,aAAa,GAAG,SAC9D,KACA;CACA,OACE,oBAACC,SAAD;EACE,GAAI;EACC;EACL,gBAAc,WAAW;EACzB,WAAW,GACT,+XACA,SACF;CACD,CAAA;AAEL,CAAC"}
|
package/dist/lib/cn.d.ts
ADDED
package/dist/style.css
ADDED
|
@@ -0,0 +1,457 @@
|
|
|
1
|
+
/*! tailwindcss v4.3.3 | MIT License | https://tailwindcss.com */
|
|
2
|
+
@layer properties {
|
|
3
|
+
@supports (((-webkit-hyphens: none)) and (not (margin-trim: inline))) or ((-moz-orient: inline) and (not (color: rgb(from red r g b)))) {
|
|
4
|
+
*, :before, :after, ::backdrop {
|
|
5
|
+
--tw-border-style: solid;
|
|
6
|
+
--tw-font-weight: initial;
|
|
7
|
+
--tw-shadow: 0 0 #0000;
|
|
8
|
+
--tw-shadow-color: initial;
|
|
9
|
+
--tw-shadow-alpha: 100%;
|
|
10
|
+
--tw-inset-shadow: 0 0 #0000;
|
|
11
|
+
--tw-inset-shadow-color: initial;
|
|
12
|
+
--tw-inset-shadow-alpha: 100%;
|
|
13
|
+
--tw-ring-color: initial;
|
|
14
|
+
--tw-ring-shadow: 0 0 #0000;
|
|
15
|
+
--tw-inset-ring-color: initial;
|
|
16
|
+
--tw-inset-ring-shadow: 0 0 #0000;
|
|
17
|
+
--tw-ring-inset: initial;
|
|
18
|
+
--tw-ring-offset-width: 0px;
|
|
19
|
+
--tw-ring-offset-color: #fff;
|
|
20
|
+
--tw-ring-offset-shadow: 0 0 #0000;
|
|
21
|
+
--tw-outline-style: solid;
|
|
22
|
+
}
|
|
23
|
+
}
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
@layer theme {
|
|
27
|
+
:root, :host {
|
|
28
|
+
--spacing: .25rem;
|
|
29
|
+
--text-sm: .875rem;
|
|
30
|
+
--text-sm--line-height: calc(1.25 / .875);
|
|
31
|
+
--text-base: 1rem;
|
|
32
|
+
--text-base--line-height: calc(1.5 / 1);
|
|
33
|
+
--font-weight-medium: 500;
|
|
34
|
+
--default-transition-duration: .15s;
|
|
35
|
+
--default-transition-timing-function: cubic-bezier(.4, 0, .2, 1);
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
@layer utilities {
|
|
40
|
+
.flex {
|
|
41
|
+
display: flex;
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
.inline-flex {
|
|
45
|
+
display: inline-flex;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
.h-8 {
|
|
49
|
+
height: calc(var(--spacing) * 8);
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
.h-10 {
|
|
53
|
+
height: calc(var(--spacing) * 10);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
.h-12 {
|
|
57
|
+
height: calc(var(--spacing) * 12);
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
.w-full {
|
|
61
|
+
width: 100%;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
.items-center {
|
|
65
|
+
align-items: center;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
.justify-center {
|
|
69
|
+
justify-content: center;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
.gap-1\.5 {
|
|
73
|
+
gap: calc(var(--spacing) * 1.5);
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
.gap-2 {
|
|
77
|
+
gap: calc(var(--spacing) * 2);
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
.gap-2\.5 {
|
|
81
|
+
gap: calc(var(--spacing) * 2.5);
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
.rounded-ui-md {
|
|
85
|
+
border-radius: var(--ui-radius-md);
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
.border {
|
|
89
|
+
border-style: var(--tw-border-style);
|
|
90
|
+
border-width: 1px;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
.border-border {
|
|
94
|
+
border-color: var(--ui-border);
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
.bg-background {
|
|
98
|
+
background-color: var(--ui-background);
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
.bg-danger {
|
|
102
|
+
background-color: var(--ui-danger);
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
.bg-primary {
|
|
106
|
+
background-color: var(--ui-primary);
|
|
107
|
+
}
|
|
108
|
+
|
|
109
|
+
.bg-secondary {
|
|
110
|
+
background-color: var(--ui-secondary);
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
.bg-transparent {
|
|
114
|
+
background-color: #0000;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
.px-3 {
|
|
118
|
+
padding-inline: calc(var(--spacing) * 3);
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
.px-4 {
|
|
122
|
+
padding-inline: calc(var(--spacing) * 4);
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
.px-6 {
|
|
126
|
+
padding-inline: calc(var(--spacing) * 6);
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
.py-2 {
|
|
130
|
+
padding-block: calc(var(--spacing) * 2);
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
.text-base {
|
|
134
|
+
font-size: var(--text-base);
|
|
135
|
+
line-height: var(--tw-leading, var(--text-base--line-height));
|
|
136
|
+
}
|
|
137
|
+
|
|
138
|
+
.text-sm {
|
|
139
|
+
font-size: var(--text-sm);
|
|
140
|
+
line-height: var(--tw-leading, var(--text-sm--line-height));
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
.font-medium {
|
|
144
|
+
--tw-font-weight: var(--font-weight-medium);
|
|
145
|
+
font-weight: var(--font-weight-medium);
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
.whitespace-nowrap {
|
|
149
|
+
white-space: nowrap;
|
|
150
|
+
}
|
|
151
|
+
|
|
152
|
+
.text-danger-foreground {
|
|
153
|
+
color: var(--ui-danger-foreground);
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
.text-foreground {
|
|
157
|
+
color: var(--ui-foreground);
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
.text-primary-foreground {
|
|
161
|
+
color: var(--ui-primary-foreground);
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
.text-secondary-foreground {
|
|
165
|
+
color: var(--ui-secondary-foreground);
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
.shadow-sm {
|
|
169
|
+
--tw-shadow: 0 1px 3px 0 var(--tw-shadow-color, #0000001a), 0 1px 2px -1px var(--tw-shadow-color, #0000001a);
|
|
170
|
+
box-shadow: var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow);
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
.outline {
|
|
174
|
+
outline-style: var(--tw-outline-style);
|
|
175
|
+
outline-width: 1px;
|
|
176
|
+
}
|
|
177
|
+
|
|
178
|
+
.transition-colors {
|
|
179
|
+
transition-property: color, background-color, border-color, outline-color, text-decoration-color, fill, stroke, --tw-gradient-from, --tw-gradient-via, --tw-gradient-to;
|
|
180
|
+
transition-timing-function: var(--tw-ease, var(--default-transition-timing-function));
|
|
181
|
+
transition-duration: var(--tw-duration, var(--default-transition-duration));
|
|
182
|
+
}
|
|
183
|
+
|
|
184
|
+
.outline-none {
|
|
185
|
+
--tw-outline-style: none;
|
|
186
|
+
outline-style: none;
|
|
187
|
+
}
|
|
188
|
+
|
|
189
|
+
.select-none {
|
|
190
|
+
-webkit-user-select: none;
|
|
191
|
+
user-select: none;
|
|
192
|
+
}
|
|
193
|
+
|
|
194
|
+
.placeholder\:text-muted-foreground::placeholder {
|
|
195
|
+
color: var(--ui-muted-foreground);
|
|
196
|
+
}
|
|
197
|
+
|
|
198
|
+
@media (hover: hover) {
|
|
199
|
+
.hover\:bg-danger\/90:hover {
|
|
200
|
+
background-color: var(--ui-danger);
|
|
201
|
+
}
|
|
202
|
+
|
|
203
|
+
@supports (color: color-mix(in lab, red, red)) {
|
|
204
|
+
.hover\:bg-danger\/90:hover {
|
|
205
|
+
background-color: color-mix(in oklab, var(--ui-danger) 90%, transparent);
|
|
206
|
+
}
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
.hover\:bg-muted:hover {
|
|
210
|
+
background-color: var(--ui-muted);
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
.hover\:bg-primary\/90:hover {
|
|
214
|
+
background-color: var(--ui-primary);
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
@supports (color: color-mix(in lab, red, red)) {
|
|
218
|
+
.hover\:bg-primary\/90:hover {
|
|
219
|
+
background-color: color-mix(in oklab, var(--ui-primary) 90%, transparent);
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
.hover\:bg-secondary\/80:hover {
|
|
224
|
+
background-color: var(--ui-secondary);
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
@supports (color: color-mix(in lab, red, red)) {
|
|
228
|
+
.hover\:bg-secondary\/80:hover {
|
|
229
|
+
background-color: color-mix(in oklab, var(--ui-secondary) 80%, transparent);
|
|
230
|
+
}
|
|
231
|
+
}
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
.focus-visible\:border-ring:focus-visible {
|
|
235
|
+
border-color: var(--ui-ring);
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
.focus-visible\:ring-2:focus-visible {
|
|
239
|
+
--tw-ring-shadow: var(--tw-ring-inset, ) 0 0 0 calc(2px + var(--tw-ring-offset-width)) var(--tw-ring-color, currentcolor);
|
|
240
|
+
box-shadow: var(--tw-inset-shadow), var(--tw-inset-ring-shadow), var(--tw-ring-offset-shadow), var(--tw-ring-shadow), var(--tw-shadow);
|
|
241
|
+
}
|
|
242
|
+
|
|
243
|
+
.focus-visible\:ring-ring:focus-visible, .focus-visible\:ring-ring\/30:focus-visible {
|
|
244
|
+
--tw-ring-color: var(--ui-ring);
|
|
245
|
+
}
|
|
246
|
+
|
|
247
|
+
@supports (color: color-mix(in lab, red, red)) {
|
|
248
|
+
.focus-visible\:ring-ring\/30:focus-visible {
|
|
249
|
+
--tw-ring-color: color-mix(in oklab, var(--ui-ring) 30%, transparent);
|
|
250
|
+
}
|
|
251
|
+
}
|
|
252
|
+
|
|
253
|
+
.focus-visible\:ring-offset-2:focus-visible {
|
|
254
|
+
--tw-ring-offset-width: 2px;
|
|
255
|
+
--tw-ring-offset-shadow: var(--tw-ring-inset, ) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);
|
|
256
|
+
}
|
|
257
|
+
|
|
258
|
+
.focus-visible\:ring-offset-background:focus-visible {
|
|
259
|
+
--tw-ring-offset-color: var(--ui-background);
|
|
260
|
+
}
|
|
261
|
+
|
|
262
|
+
.active\:bg-danger\/80:active {
|
|
263
|
+
background-color: var(--ui-danger);
|
|
264
|
+
}
|
|
265
|
+
|
|
266
|
+
@supports (color: color-mix(in lab, red, red)) {
|
|
267
|
+
.active\:bg-danger\/80:active {
|
|
268
|
+
background-color: color-mix(in oklab, var(--ui-danger) 80%, transparent);
|
|
269
|
+
}
|
|
270
|
+
}
|
|
271
|
+
|
|
272
|
+
.active\:bg-muted\/70:active {
|
|
273
|
+
background-color: var(--ui-muted);
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
@supports (color: color-mix(in lab, red, red)) {
|
|
277
|
+
.active\:bg-muted\/70:active {
|
|
278
|
+
background-color: color-mix(in oklab, var(--ui-muted) 70%, transparent);
|
|
279
|
+
}
|
|
280
|
+
}
|
|
281
|
+
|
|
282
|
+
.active\:bg-primary\/80:active {
|
|
283
|
+
background-color: var(--ui-primary);
|
|
284
|
+
}
|
|
285
|
+
|
|
286
|
+
@supports (color: color-mix(in lab, red, red)) {
|
|
287
|
+
.active\:bg-primary\/80:active {
|
|
288
|
+
background-color: color-mix(in oklab, var(--ui-primary) 80%, transparent);
|
|
289
|
+
}
|
|
290
|
+
}
|
|
291
|
+
|
|
292
|
+
.active\:bg-secondary\/70:active {
|
|
293
|
+
background-color: var(--ui-secondary);
|
|
294
|
+
}
|
|
295
|
+
|
|
296
|
+
@supports (color: color-mix(in lab, red, red)) {
|
|
297
|
+
.active\:bg-secondary\/70:active {
|
|
298
|
+
background-color: color-mix(in oklab, var(--ui-secondary) 70%, transparent);
|
|
299
|
+
}
|
|
300
|
+
}
|
|
301
|
+
|
|
302
|
+
.disabled\:pointer-events-none:disabled {
|
|
303
|
+
pointer-events: none;
|
|
304
|
+
}
|
|
305
|
+
|
|
306
|
+
.disabled\:cursor-not-allowed:disabled {
|
|
307
|
+
cursor: not-allowed;
|
|
308
|
+
}
|
|
309
|
+
|
|
310
|
+
.disabled\:opacity-50:disabled {
|
|
311
|
+
opacity: .5;
|
|
312
|
+
}
|
|
313
|
+
|
|
314
|
+
.aria-\[invalid\=true\]\:border-danger[aria-invalid="true"] {
|
|
315
|
+
border-color: var(--ui-danger);
|
|
316
|
+
}
|
|
317
|
+
|
|
318
|
+
.aria-\[invalid\=true\]\:focus-visible\:ring-danger\/30[aria-invalid="true"]:focus-visible {
|
|
319
|
+
--tw-ring-color: var(--ui-danger);
|
|
320
|
+
}
|
|
321
|
+
|
|
322
|
+
@supports (color: color-mix(in lab, red, red)) {
|
|
323
|
+
.aria-\[invalid\=true\]\:focus-visible\:ring-danger\/30[aria-invalid="true"]:focus-visible {
|
|
324
|
+
--tw-ring-color: color-mix(in oklab, var(--ui-danger) 30%, transparent);
|
|
325
|
+
}
|
|
326
|
+
}
|
|
327
|
+
}
|
|
328
|
+
|
|
329
|
+
:root {
|
|
330
|
+
--ui-background: oklch(100% 0 0);
|
|
331
|
+
--ui-foreground: oklch(24% .02 264);
|
|
332
|
+
--ui-primary: oklch(51% .23 277);
|
|
333
|
+
--ui-primary-foreground: oklch(99% 0 0);
|
|
334
|
+
--ui-secondary: oklch(95.5% .012 264);
|
|
335
|
+
--ui-secondary-foreground: oklch(30% .03 264);
|
|
336
|
+
--ui-muted: oklch(96% .008 264);
|
|
337
|
+
--ui-muted-foreground: oklch(50% .02 264);
|
|
338
|
+
--ui-border: oklch(89% .012 264);
|
|
339
|
+
--ui-ring: oklch(51% .23 277);
|
|
340
|
+
--ui-danger: oklch(55% .22 27);
|
|
341
|
+
--ui-danger-foreground: oklch(99% 0 0);
|
|
342
|
+
--ui-radius-sm: .375rem;
|
|
343
|
+
--ui-radius-md: .5rem;
|
|
344
|
+
--ui-radius-lg: .75rem;
|
|
345
|
+
}
|
|
346
|
+
|
|
347
|
+
.dark {
|
|
348
|
+
--ui-background: oklch(18% .02 264);
|
|
349
|
+
--ui-foreground: oklch(96% .006 264);
|
|
350
|
+
--ui-primary: oklch(68% .18 277);
|
|
351
|
+
--ui-primary-foreground: oklch(17% .03 277);
|
|
352
|
+
--ui-secondary: oklch(27% .02 264);
|
|
353
|
+
--ui-secondary-foreground: oklch(96% .006 264);
|
|
354
|
+
--ui-muted: oklch(25% .02 264);
|
|
355
|
+
--ui-muted-foreground: oklch(72% .02 264);
|
|
356
|
+
--ui-border: oklch(34% .015 264);
|
|
357
|
+
--ui-ring: oklch(68% .18 277);
|
|
358
|
+
--ui-danger: oklch(64% .2 27);
|
|
359
|
+
--ui-danger-foreground: oklch(17% .03 27);
|
|
360
|
+
}
|
|
361
|
+
|
|
362
|
+
@property --tw-border-style {
|
|
363
|
+
syntax: "*";
|
|
364
|
+
inherits: false;
|
|
365
|
+
initial-value: solid;
|
|
366
|
+
}
|
|
367
|
+
|
|
368
|
+
@property --tw-font-weight {
|
|
369
|
+
syntax: "*";
|
|
370
|
+
inherits: false
|
|
371
|
+
}
|
|
372
|
+
|
|
373
|
+
@property --tw-shadow {
|
|
374
|
+
syntax: "*";
|
|
375
|
+
inherits: false;
|
|
376
|
+
initial-value: 0 0 #0000;
|
|
377
|
+
}
|
|
378
|
+
|
|
379
|
+
@property --tw-shadow-color {
|
|
380
|
+
syntax: "*";
|
|
381
|
+
inherits: false
|
|
382
|
+
}
|
|
383
|
+
|
|
384
|
+
@property --tw-shadow-alpha {
|
|
385
|
+
syntax: "<percentage>";
|
|
386
|
+
inherits: false;
|
|
387
|
+
initial-value: 100%;
|
|
388
|
+
}
|
|
389
|
+
|
|
390
|
+
@property --tw-inset-shadow {
|
|
391
|
+
syntax: "*";
|
|
392
|
+
inherits: false;
|
|
393
|
+
initial-value: 0 0 #0000;
|
|
394
|
+
}
|
|
395
|
+
|
|
396
|
+
@property --tw-inset-shadow-color {
|
|
397
|
+
syntax: "*";
|
|
398
|
+
inherits: false
|
|
399
|
+
}
|
|
400
|
+
|
|
401
|
+
@property --tw-inset-shadow-alpha {
|
|
402
|
+
syntax: "<percentage>";
|
|
403
|
+
inherits: false;
|
|
404
|
+
initial-value: 100%;
|
|
405
|
+
}
|
|
406
|
+
|
|
407
|
+
@property --tw-ring-color {
|
|
408
|
+
syntax: "*";
|
|
409
|
+
inherits: false
|
|
410
|
+
}
|
|
411
|
+
|
|
412
|
+
@property --tw-ring-shadow {
|
|
413
|
+
syntax: "*";
|
|
414
|
+
inherits: false;
|
|
415
|
+
initial-value: 0 0 #0000;
|
|
416
|
+
}
|
|
417
|
+
|
|
418
|
+
@property --tw-inset-ring-color {
|
|
419
|
+
syntax: "*";
|
|
420
|
+
inherits: false
|
|
421
|
+
}
|
|
422
|
+
|
|
423
|
+
@property --tw-inset-ring-shadow {
|
|
424
|
+
syntax: "*";
|
|
425
|
+
inherits: false;
|
|
426
|
+
initial-value: 0 0 #0000;
|
|
427
|
+
}
|
|
428
|
+
|
|
429
|
+
@property --tw-ring-inset {
|
|
430
|
+
syntax: "*";
|
|
431
|
+
inherits: false
|
|
432
|
+
}
|
|
433
|
+
|
|
434
|
+
@property --tw-ring-offset-width {
|
|
435
|
+
syntax: "<length>";
|
|
436
|
+
inherits: false;
|
|
437
|
+
initial-value: 0;
|
|
438
|
+
}
|
|
439
|
+
|
|
440
|
+
@property --tw-ring-offset-color {
|
|
441
|
+
syntax: "*";
|
|
442
|
+
inherits: false;
|
|
443
|
+
initial-value: #fff;
|
|
444
|
+
}
|
|
445
|
+
|
|
446
|
+
@property --tw-ring-offset-shadow {
|
|
447
|
+
syntax: "*";
|
|
448
|
+
inherits: false;
|
|
449
|
+
initial-value: 0 0 #0000;
|
|
450
|
+
}
|
|
451
|
+
|
|
452
|
+
@property --tw-outline-style {
|
|
453
|
+
syntax: "*";
|
|
454
|
+
inherits: false;
|
|
455
|
+
initial-value: solid;
|
|
456
|
+
}
|
|
457
|
+
/*$vite$:1*/
|
package/package.json
CHANGED
|
@@ -1,6 +1,90 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@walidsj/react-ui",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"
|
|
5
|
-
"
|
|
6
|
-
|
|
3
|
+
"version": "0.1.1",
|
|
4
|
+
"description": "Accessible React components styled with Tailwind CSS v4 and built on Base UI primitives.",
|
|
5
|
+
"license": "MIT",
|
|
6
|
+
"author": "walidsj (https://github.com/walidsj)",
|
|
7
|
+
"repository": {
|
|
8
|
+
"type": "git",
|
|
9
|
+
"url": "git+https://github.com/walidsj/walid-ui.git"
|
|
10
|
+
},
|
|
11
|
+
"homepage": "https://github.com/walidsj/walid-ui#readme",
|
|
12
|
+
"bugs": {
|
|
13
|
+
"url": "https://github.com/walidsj/walid-ui/issues"
|
|
14
|
+
},
|
|
15
|
+
"type": "module",
|
|
16
|
+
"packageManager": "bun@1.4.4",
|
|
17
|
+
"main": "./dist/index.js",
|
|
18
|
+
"module": "./dist/index.js",
|
|
19
|
+
"types": "./dist/index.d.ts",
|
|
20
|
+
"exports": {
|
|
21
|
+
".": {
|
|
22
|
+
"types": "./dist/index.d.ts",
|
|
23
|
+
"import": "./dist/index.js"
|
|
24
|
+
},
|
|
25
|
+
"./style.css": "./dist/style.css",
|
|
26
|
+
"./package.json": "./package.json"
|
|
27
|
+
},
|
|
28
|
+
"files": [
|
|
29
|
+
"dist"
|
|
30
|
+
],
|
|
31
|
+
"sideEffects": [
|
|
32
|
+
"**/*.css"
|
|
33
|
+
],
|
|
34
|
+
"publishConfig": {
|
|
35
|
+
"access": "public"
|
|
36
|
+
},
|
|
37
|
+
"engines": {
|
|
38
|
+
"node": ">=20.19.0"
|
|
39
|
+
},
|
|
40
|
+
"keywords": [
|
|
41
|
+
"react",
|
|
42
|
+
"design-system",
|
|
43
|
+
"component-library",
|
|
44
|
+
"tailwindcss",
|
|
45
|
+
"base-ui",
|
|
46
|
+
"typescript"
|
|
47
|
+
],
|
|
48
|
+
"scripts": {
|
|
49
|
+
"dev": "vite build --watch",
|
|
50
|
+
"build": "vite build",
|
|
51
|
+
"typecheck": "tsc --noEmit",
|
|
52
|
+
"test": "vitest run",
|
|
53
|
+
"test:watch": "vitest",
|
|
54
|
+
"lint": "biome check .",
|
|
55
|
+
"format": "biome format --write .",
|
|
56
|
+
"format:check": "biome format .",
|
|
57
|
+
"clean": "rm -rf dist coverage",
|
|
58
|
+
"prepublishOnly": "bun run clean && bun run lint && bun run typecheck && bun run test && bun run build"
|
|
59
|
+
},
|
|
60
|
+
"peerDependencies": {
|
|
61
|
+
"react": "^19.0.0",
|
|
62
|
+
"react-dom": "^19.0.0"
|
|
63
|
+
},
|
|
64
|
+
"dependencies": {
|
|
65
|
+
"@base-ui/react": "^1.9.0",
|
|
66
|
+
"class-variance-authority": "^0.7.1",
|
|
67
|
+
"clsx": "^2.1.1",
|
|
68
|
+
"tailwind-merge": "^3.7.0"
|
|
69
|
+
},
|
|
70
|
+
"devDependencies": {
|
|
71
|
+
"@biomejs/biome": "2.6.3",
|
|
72
|
+
"@tailwindcss/vite": "4.3.3",
|
|
73
|
+
"@testing-library/dom": "10.4.2",
|
|
74
|
+
"@testing-library/jest-dom": "7.0.1",
|
|
75
|
+
"@testing-library/react": "16.3.3",
|
|
76
|
+
"@testing-library/user-event": "14.6.8",
|
|
77
|
+
"@types/node": "24.19.2",
|
|
78
|
+
"@types/react": "19.3.0",
|
|
79
|
+
"@types/react-dom": "19.3.0",
|
|
80
|
+
"@vitejs/plugin-react": "6.1.2",
|
|
81
|
+
"jsdom": "30.1.3",
|
|
82
|
+
"react": "19.3.1",
|
|
83
|
+
"react-dom": "19.3.1",
|
|
84
|
+
"tailwindcss": "4.3.3",
|
|
85
|
+
"typescript": "5.9.3",
|
|
86
|
+
"vite": "8.3.5",
|
|
87
|
+
"vite-plugin-dts": "5.1.2",
|
|
88
|
+
"vitest": "5.0.5"
|
|
89
|
+
}
|
|
90
|
+
}
|