@unllamas/ui
Advanced tools
+1
-1
@@ -10,5 +10,5 @@ /** @type {import("eslint").Linter.Config} */ | ||
| }, | ||
| "ecmaVersion": 12, | ||
| "ecmaVersion": 2018, | ||
| "sourceType": "module" | ||
| }, | ||
| }; |
| > @unllamas/ui@0.0.3 lint /Users/macbook/Documents/Testing/component-test/packages/ui | ||
| > @unllamas/ui@0.0.4 lint /Users/macbook/Documents/Testing/component-test/packages/ui | ||
| > eslint . --max-warnings 0 | ||
+5
-4
| { | ||
| "name": "@unllamas/ui", | ||
| "version": "0.0.4", | ||
| "version": "0.0.5", | ||
| "private": false, | ||
@@ -13,4 +13,2 @@ "exports": { | ||
| "devDependencies": { | ||
| "@unllamas/eslint-config": "workspace:*", | ||
| "@unllamas/typescript-config": "workspace:*", | ||
| "@turbo/gen": "^1.10.12", | ||
@@ -21,5 +19,8 @@ "@types/eslint": "^8.44.7", | ||
| "@types/react-dom": "^18.2.0", | ||
| "@unllamas/eslint-config": "workspace:*", | ||
| "@unllamas/typescript-config": "workspace:*", | ||
| "eslint": "^8.53.0", | ||
| "react": "^18.2.0", | ||
| "typescript": "^5.2.2" | ||
| "typescript": "^5.2.2", | ||
| "webpack": "^5.89.0" | ||
| }, | ||
@@ -26,0 +27,0 @@ "dependencies": { |
+22
-2
| "use client"; | ||
| import { ButtonProps } from "./types"; | ||
| import { ReactNode } from "react"; | ||
| import { Color, Variant, Size } from "./types"; | ||
| import { theme } from "../theme"; | ||
| import { BaseButton } from "./style"; | ||
| export function Button(props: ButtonProps) { | ||
| export interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement> { | ||
| children: ReactNode; | ||
| color?: Color; | ||
| variant?: Variant; | ||
| size?: Size; | ||
| loading?: boolean; | ||
| disabled?: boolean; | ||
| componentName?: string; | ||
| tabIndex?: number; | ||
| onClick: () => any; | ||
| onTouchStart?: () => void; | ||
| onTouchEnd?: () => void; | ||
| onMouseDown?: () => void; | ||
| onMouseUp?: () => void; | ||
| } | ||
| export function Button(props: ButtonProps): JSX.Element { | ||
| const { | ||
@@ -63,1 +81,3 @@ children, | ||
| } | ||
| Button.displayName = "Button"; |
+0
-16
@@ -7,18 +7,2 @@ import { ReactNode } from "react"; | ||
| export interface ButtonProps { | ||
| children: ReactNode; | ||
| color?: Color; | ||
| variant?: Variant; | ||
| size?: Size; | ||
| loading?: boolean; | ||
| disabled?: boolean; | ||
| componentName?: string; | ||
| tabIndex?: number; | ||
| onClick: () => any; | ||
| onTouchStart?: () => void; | ||
| onTouchEnd?: () => void; | ||
| onMouseDown?: () => void; | ||
| onMouseUp?: () => void; | ||
| } | ||
| export interface BaseButtonProps { | ||
@@ -25,0 +9,0 @@ $background?: string; |
+1
-1
@@ -6,4 +6,4 @@ // Styles | ||
| // Components | ||
| export * from "./Button"; | ||
| export { Button, type ButtonProps } from "./Button"; | ||
| export * from "./Flex"; | ||
| export * from "./Divider"; |
8484
2.39%307
0.33%11
10%