-
Notifications
You must be signed in to change notification settings - Fork 44
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
12 changed files
with
1,212 additions
and
1,088 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
dist/ | ||
node_modules/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# Quack UI | ||
|
||
Quack UI is the official UI toolkit of Gaylord McDuck Enterprises. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
{ | ||
"name": "@gaylordmcduck/quack-ui", | ||
"version": "1.0.0", | ||
"description": "Quack UI", | ||
"license": "MIT", | ||
"type": "module", | ||
"main": "./dist/index.js", | ||
"types": "./dist/index.d.ts", | ||
"files": [ | ||
"dist" | ||
], | ||
"exports": { | ||
"./style.css": "./dist/style.css", | ||
".": { | ||
"import": "./dist/index.js" | ||
} | ||
}, | ||
"scripts": { | ||
"build": "tsc && vite build", | ||
"dev": "pnpm run build --watch" | ||
}, | ||
"devDependencies": { | ||
"@rollup/plugin-typescript": "^11.1.6", | ||
"@types/react": "^18.3.1", | ||
"@types/react-dom": "^18.3.0", | ||
"@vitejs/plugin-react": "^4.2.1", | ||
"rollup-plugin-node-externals": "^7.1.1", | ||
"typescript": "^5.4.5", | ||
"vite": "^5.2.10", | ||
"react": ">= 18.3.1", | ||
"react-dom": ">= 18.3.1" | ||
}, | ||
"dependencies": {}, | ||
"peerDependencies": { | ||
"react": ">= 18.3.1", | ||
"react-dom": ">= 18.3.1" | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
.button { | ||
border: 10px solid rgb(0 0 0); | ||
padding: 2rem; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
import { ComponentProps, FC } from "react"; | ||
import styles from "./Button.module.css"; | ||
|
||
type Props = ComponentProps<"button">; | ||
|
||
const Button: FC<Props> = (props) => { | ||
return <button {...props} className={styles.button} />; | ||
}; | ||
|
||
export default Button; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
import { ComponentProps, FC } from "react"; | ||
|
||
type Props = ComponentProps<"input">; | ||
|
||
const Input: FC<Props> = (props) => { | ||
return <input {...props} />; | ||
}; | ||
|
||
export default Input; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
export { default as Button } from "./components/Button"; | ||
export { default as Input } from "./components/Input"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
/* eslint-disable */ | ||
/// <reference types="vite/client" /> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
{ | ||
"compilerOptions": { | ||
"jsx": "react-jsx", | ||
"target": "ES2020", | ||
"useDefineForClassFields": true, | ||
"module": "ESNext", | ||
"lib": ["ES2020", "DOM", "DOM.Iterable"], | ||
"skipLibCheck": true, | ||
"baseUrl": ".", | ||
"paths": { | ||
"*": ["src/*"] | ||
}, | ||
|
||
/* Bundler mode */ | ||
"moduleResolution": "bundler", | ||
"resolveJsonModule": true, | ||
"isolatedModules": true, | ||
"noEmit": true, | ||
|
||
/* Linting */ | ||
"strict": true, | ||
"noUnusedLocals": true, | ||
"noUnusedParameters": true, | ||
"noFallthroughCasesInSwitch": true | ||
}, | ||
"include": ["src"], | ||
"exclude": ["node_modules", "dist"] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
import typescript from "@rollup/plugin-typescript"; | ||
import react from "@vitejs/plugin-react"; | ||
import { resolve } from "path"; | ||
import externals from "rollup-plugin-node-externals"; | ||
import { defineConfig } from "vite"; | ||
|
||
// https://vitejs.dev/config/ | ||
export default defineConfig({ | ||
build: { | ||
lib: { | ||
entry: resolve(__dirname, "src/index.tsx"), | ||
formats: ["es"], | ||
fileName: "index" | ||
}, | ||
rollupOptions: { | ||
external: [/^react/] | ||
} | ||
}, | ||
plugins: [ | ||
react(), | ||
typescript({ | ||
target: "es2020", | ||
rootDir: resolve(__dirname, "src"), | ||
declaration: true, | ||
declarationDir: resolve(__dirname, "dist"), | ||
exclude: resolve(__dirname, "node_modules/**"), | ||
allowSyntheticDefaultImports: true | ||
}), | ||
externals() | ||
] | ||
}); |
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
packages: | ||
- 'packages/*' |