Skip to content

Commit

Permalink
fixed package
Browse files Browse the repository at this point in the history
  • Loading branch information
lukeshay committed Dec 28, 2023
1 parent ebd26a6 commit f370920
Show file tree
Hide file tree
Showing 8 changed files with 569 additions and 28 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ on:
workflow_dispatch:

env:
NODE_VERSION: "18"
NODE_VERSION: "20"
PNPM_VERSION: "8"

concurrency:
Expand Down
4 changes: 4 additions & 0 deletions apps/www/.scripts/gen-default-demos.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,10 @@ const demosContent = await Promise.all(
const content = newContentsLines
.join("\n")
.replaceAll("@/components/ui", `@lshay/ui/components/REPLACE_STYLE`)
.replaceAll(
/@\/registry\/[a-z-]+\/ui/gu,
`@lshay/ui/components/REPLACE_STYLE`,
)
.replaceAll("@/lib/utils", "@lshay/ui/lib/utils")
.replaceAll("export function", "function")
.replaceAll("export const", "const")
Expand Down
1 change: 1 addition & 0 deletions apps/www/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@
"react-dom": "^18.2.0",
"react-hook-form": "^7.45.2",
"react-icons": "^4.10.1",
"sonner": "^1.3.1",
"zod": "^3.21.4"
},
"devDependencies": {
Expand Down
34 changes: 34 additions & 0 deletions apps/www/src/overrides/DrawerDemo.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
import * as React from "react"
import {
Drawer,
DrawerClose,
DrawerContent,
DrawerDescription,
DrawerFooter,
DrawerHeader,
DrawerTitle,
DrawerTrigger,
} from "@lshay/ui/components/default/drawer"
import { Button } from "@lshay/ui/components/default/button"

function DrawerDemo(): React.ReactNode {
return (
<Drawer>
<DrawerTrigger>Open</DrawerTrigger>
<DrawerContent>
<DrawerHeader>
<DrawerTitle>Are you sure absolutely sure?</DrawerTitle>
<DrawerDescription>This action cannot be undone.</DrawerDescription>
</DrawerHeader>
<DrawerFooter>
<Button>Submit</Button>
<DrawerClose>
<Button variant="outline">Cancel</Button>
</DrawerClose>
</DrawerFooter>
</DrawerContent>
</Drawer>
)
}

export default DrawerDemo
35 changes: 35 additions & 0 deletions apps/www/src/overrides/PaginationDemo.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
import * as React from "react"
import {
Pagination,
PaginationContent,
PaginationEllipsis,
PaginationItem,
PaginationLink,
PaginationNext,
PaginationPrevious,
} from "@lshay/ui/components/default/pagination"

function PaginationDemo(): React.ReactNode {
return (
<Pagination>
<PaginationContent>
<PaginationItem>
<PaginationPrevious size="m" href="#" />
</PaginationItem>
<PaginationItem>
<PaginationLink size="m" href="#">
1
</PaginationLink>
</PaginationItem>
<PaginationItem>
<PaginationEllipsis />
</PaginationItem>
<PaginationItem>
<PaginationNext size="m" href="#" />
</PaginationItem>
</PaginationContent>
</Pagination>
)
}

export default PaginationDemo
2 changes: 1 addition & 1 deletion apps/www/ui
Submodule ui updated 181 files
95 changes: 90 additions & 5 deletions packages/ui/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,8 @@
"@types/react-dom": "^18.2.7",
"eslint": "^8.46.0",
"globby": "^13.2.2",
"lucide-react": "^0.298.0",
"prettier": "^3.0.1",
"lucide-react": "^0.303.0",
"prettier": "^3.1.0",
"react": "^18.0.0",
"react-dom": "^18.0.0",
"semver": "^7.5.4",
Expand Down Expand Up @@ -86,13 +86,18 @@
"clsx": "^2.0.0",
"cmdk": "^0.2.0",
"date-fns": "^2.30.0",
"react-day-picker": "^8.9.1",
"embla-carousel-react": "8.0.0-rc17",
"next-themes": "^0.2.1",
"react-day-picker": "^8.10.0",
"react-hook-form": "^7.45.2",
"tailwind-merge": "^2.1.0"
"react-resizable-panels": "^1.0.5",
"sonner": "^1.3.1",
"tailwind-merge": "^2.2.0",
"vaul": "^0.8.0"
},
"peerDependencies": {
"@radix-ui/react-icons": "^1.3.0",
"lucide-react": "^0.298.0",
"lucide-react": "^0.303.0",
"react": "^18.0.0",
"react-dom": "^18.0.0",
"tailwindcss": "^3.0.0"
Expand Down Expand Up @@ -153,6 +158,11 @@
"require": "./dist/cjs/components/default/ui/card.js",
"types": "./dist/types/components/default/ui/card.d.ts"
},
"./components/default/carousel": {
"import": "./dist/esm/components/default/ui/carousel.mjs",
"require": "./dist/cjs/components/default/ui/carousel.js",
"types": "./dist/types/components/default/ui/carousel.d.ts"
},
"./components/default/checkbox": {
"import": "./dist/esm/components/default/ui/checkbox.mjs",
"require": "./dist/cjs/components/default/ui/checkbox.js",
Expand All @@ -178,6 +188,11 @@
"require": "./dist/cjs/components/default/ui/dialog.js",
"types": "./dist/types/components/default/ui/dialog.d.ts"
},
"./components/default/drawer": {
"import": "./dist/esm/components/default/ui/drawer.mjs",
"require": "./dist/cjs/components/default/ui/drawer.js",
"types": "./dist/types/components/default/ui/drawer.d.ts"
},
"./components/default/dropdown-menu": {
"import": "./dist/esm/components/default/ui/dropdown-menu.mjs",
"require": "./dist/cjs/components/default/ui/dropdown-menu.js",
Expand Down Expand Up @@ -213,6 +228,11 @@
"require": "./dist/cjs/components/default/ui/navigation-menu.js",
"types": "./dist/types/components/default/ui/navigation-menu.d.ts"
},
"./components/default/pagination": {
"import": "./dist/esm/components/default/ui/pagination.mjs",
"require": "./dist/cjs/components/default/ui/pagination.js",
"types": "./dist/types/components/default/ui/pagination.d.ts"
},
"./components/default/popover": {
"import": "./dist/esm/components/default/ui/popover.mjs",
"require": "./dist/cjs/components/default/ui/popover.js",
Expand All @@ -228,6 +248,11 @@
"require": "./dist/cjs/components/default/ui/radio-group.js",
"types": "./dist/types/components/default/ui/radio-group.d.ts"
},
"./components/default/resizable": {
"import": "./dist/esm/components/default/ui/resizable.mjs",
"require": "./dist/cjs/components/default/ui/resizable.js",
"types": "./dist/types/components/default/ui/resizable.d.ts"
},
"./components/default/scroll-area": {
"import": "./dist/esm/components/default/ui/scroll-area.mjs",
"require": "./dist/cjs/components/default/ui/scroll-area.js",
Expand Down Expand Up @@ -258,6 +283,11 @@
"require": "./dist/cjs/components/default/ui/slider.js",
"types": "./dist/types/components/default/ui/slider.d.ts"
},
"./components/default/sonner": {
"import": "./dist/esm/components/default/ui/sonner.mjs",
"require": "./dist/cjs/components/default/ui/sonner.js",
"types": "./dist/types/components/default/ui/sonner.d.ts"
},
"./components/default/switch": {
"import": "./dist/esm/components/default/ui/switch.mjs",
"require": "./dist/cjs/components/default/ui/switch.js",
Expand Down Expand Up @@ -353,6 +383,11 @@
"require": "./dist/cjs/components/new-york/ui/card.js",
"types": "./dist/types/components/new-york/ui/card.d.ts"
},
"./components/new-york/carousel": {
"import": "./dist/esm/components/new-york/ui/carousel.mjs",
"require": "./dist/cjs/components/new-york/ui/carousel.js",
"types": "./dist/types/components/new-york/ui/carousel.d.ts"
},
"./components/new-york/checkbox": {
"import": "./dist/esm/components/new-york/ui/checkbox.mjs",
"require": "./dist/cjs/components/new-york/ui/checkbox.js",
Expand All @@ -378,6 +413,11 @@
"require": "./dist/cjs/components/new-york/ui/dialog.js",
"types": "./dist/types/components/new-york/ui/dialog.d.ts"
},
"./components/new-york/drawer": {
"import": "./dist/esm/components/new-york/ui/drawer.mjs",
"require": "./dist/cjs/components/new-york/ui/drawer.js",
"types": "./dist/types/components/new-york/ui/drawer.d.ts"
},
"./components/new-york/dropdown-menu": {
"import": "./dist/esm/components/new-york/ui/dropdown-menu.mjs",
"require": "./dist/cjs/components/new-york/ui/dropdown-menu.js",
Expand Down Expand Up @@ -413,6 +453,11 @@
"require": "./dist/cjs/components/new-york/ui/navigation-menu.js",
"types": "./dist/types/components/new-york/ui/navigation-menu.d.ts"
},
"./components/new-york/pagination": {
"import": "./dist/esm/components/new-york/ui/pagination.mjs",
"require": "./dist/cjs/components/new-york/ui/pagination.js",
"types": "./dist/types/components/new-york/ui/pagination.d.ts"
},
"./components/new-york/popover": {
"import": "./dist/esm/components/new-york/ui/popover.mjs",
"require": "./dist/cjs/components/new-york/ui/popover.js",
Expand All @@ -428,6 +473,11 @@
"require": "./dist/cjs/components/new-york/ui/radio-group.js",
"types": "./dist/types/components/new-york/ui/radio-group.d.ts"
},
"./components/new-york/resizable": {
"import": "./dist/esm/components/new-york/ui/resizable.mjs",
"require": "./dist/cjs/components/new-york/ui/resizable.js",
"types": "./dist/types/components/new-york/ui/resizable.d.ts"
},
"./components/new-york/scroll-area": {
"import": "./dist/esm/components/new-york/ui/scroll-area.mjs",
"require": "./dist/cjs/components/new-york/ui/scroll-area.js",
Expand Down Expand Up @@ -458,6 +508,11 @@
"require": "./dist/cjs/components/new-york/ui/slider.js",
"types": "./dist/types/components/new-york/ui/slider.d.ts"
},
"./components/new-york/sonner": {
"import": "./dist/esm/components/new-york/ui/sonner.mjs",
"require": "./dist/cjs/components/new-york/ui/sonner.js",
"types": "./dist/types/components/new-york/ui/sonner.d.ts"
},
"./components/new-york/switch": {
"import": "./dist/esm/components/new-york/ui/switch.mjs",
"require": "./dist/cjs/components/new-york/ui/switch.js",
Expand Down Expand Up @@ -544,6 +599,9 @@
"components/default/card": [
"dist/types/components/default/ui/card.d.ts"
],
"components/default/carousel": [
"dist/types/components/default/ui/carousel.d.ts"
],
"components/default/checkbox": [
"dist/types/components/default/ui/checkbox.d.ts"
],
Expand All @@ -559,6 +617,9 @@
"components/default/dialog": [
"dist/types/components/default/ui/dialog.d.ts"
],
"components/default/drawer": [
"dist/types/components/default/ui/drawer.d.ts"
],
"components/default/dropdown-menu": [
"dist/types/components/default/ui/dropdown-menu.d.ts"
],
Expand All @@ -580,6 +641,9 @@
"components/default/navigation-menu": [
"dist/types/components/default/ui/navigation-menu.d.ts"
],
"components/default/pagination": [
"dist/types/components/default/ui/pagination.d.ts"
],
"components/default/popover": [
"dist/types/components/default/ui/popover.d.ts"
],
Expand All @@ -589,6 +653,9 @@
"components/default/radio-group": [
"dist/types/components/default/ui/radio-group.d.ts"
],
"components/default/resizable": [
"dist/types/components/default/ui/resizable.d.ts"
],
"components/default/scroll-area": [
"dist/types/components/default/ui/scroll-area.d.ts"
],
Expand All @@ -607,6 +674,9 @@
"components/default/slider": [
"dist/types/components/default/ui/slider.d.ts"
],
"components/default/sonner": [
"dist/types/components/default/ui/sonner.d.ts"
],
"components/default/switch": [
"dist/types/components/default/ui/switch.d.ts"
],
Expand Down Expand Up @@ -664,6 +734,9 @@
"components/new-york/card": [
"dist/types/components/new-york/ui/card.d.ts"
],
"components/new-york/carousel": [
"dist/types/components/new-york/ui/carousel.d.ts"
],
"components/new-york/checkbox": [
"dist/types/components/new-york/ui/checkbox.d.ts"
],
Expand All @@ -679,6 +752,9 @@
"components/new-york/dialog": [
"dist/types/components/new-york/ui/dialog.d.ts"
],
"components/new-york/drawer": [
"dist/types/components/new-york/ui/drawer.d.ts"
],
"components/new-york/dropdown-menu": [
"dist/types/components/new-york/ui/dropdown-menu.d.ts"
],
Expand All @@ -700,6 +776,9 @@
"components/new-york/navigation-menu": [
"dist/types/components/new-york/ui/navigation-menu.d.ts"
],
"components/new-york/pagination": [
"dist/types/components/new-york/ui/pagination.d.ts"
],
"components/new-york/popover": [
"dist/types/components/new-york/ui/popover.d.ts"
],
Expand All @@ -709,6 +788,9 @@
"components/new-york/radio-group": [
"dist/types/components/new-york/ui/radio-group.d.ts"
],
"components/new-york/resizable": [
"dist/types/components/new-york/ui/resizable.d.ts"
],
"components/new-york/scroll-area": [
"dist/types/components/new-york/ui/scroll-area.d.ts"
],
Expand All @@ -727,6 +809,9 @@
"components/new-york/slider": [
"dist/types/components/new-york/ui/slider.d.ts"
],
"components/new-york/sonner": [
"dist/types/components/new-york/ui/sonner.d.ts"
],
"components/new-york/switch": [
"dist/types/components/new-york/ui/switch.d.ts"
],
Expand Down
Loading

0 comments on commit f370920

Please sign in to comment.