Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: update command build to @openlabs/ui #331

Merged
merged 1 commit into from
May 31, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions packages/theme/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "@openlabs/theme",
"version": "0.1.0",
"description": "Open UI. OpenLand's official framework design system 🎨",
"description": "Open UI. OpenLabs's official framework design system 🎨",
"author": "Open Labs",
"publishConfig": {
"access": "public"
Expand Down Expand Up @@ -31,7 +31,7 @@
"./package.json": "./package.json"
},
"scripts": {
"compile": "tsup --watch",
"compile": "tsup --dts --watch",
"build": "tsup --dts",
"clean": "rm -rf .turbo node_modules dist"
},
Expand Down
5 changes: 2 additions & 3 deletions packages/theme/tsup.config.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
import { defineConfig } from 'tsup'

export default defineConfig(options => ({
export default defineConfig({
name: 'theme',
entryPoints: ['./src/index.ts'],
format: ['cjs', 'esm'],
clean: true,
target: 'es2019',
...options,
}))
})
2 changes: 1 addition & 1 deletion packages/ui/pre-build.mjs → packages/ui/build.mjs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/* eslint-disable no-console */
import fs from 'node:fs'

const filePath = './index.ts'
const filePath = './src/index.ts'
const backupFilePath = `${filePath}.backup.ts`

fs.copyFile(filePath, backupFilePath, (err) => {
Expand Down
26 changes: 0 additions & 26 deletions packages/ui/index.ts

This file was deleted.

20 changes: 12 additions & 8 deletions packages/ui/package.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
{
"name": "@openlabs/ui",
"type": "module",
"version": "0.1.0",
"description": "Open UI. OpenLand's official framework design system 🎨",
"author": "Open Lab",
"description": "Open UI. OpenLabs's official framework design system 🎨",
"author": "Open Labs",
"license": "MIT",
"homepage": "https://github.com/OpenLabs-dev/openui#readme",
"repository": {
Expand All @@ -19,12 +18,17 @@
"open"
],
"sideEffects": false,
"main": "./dist/index.cjs",
"module": "./dist/index.js",
"types": "./dist/index.d.ts",
"exports": {
".": {
"types": "./dist/index.d.ts",
"import": "./dist/index.mjs",
"require": "./dist/index.js"
},
"./package.json": "./package.json"
},
"scripts": {
"compile": "tsup --watch",
"prebuild": "node ./pre-build.mjs",
"compile": "tsup --dts --watch",
"prebuild": "node ./build.mjs",
"build": "tsup --dts",
"clean": "rm -rf .turbo node_modules dist"
},
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
28 changes: 28 additions & 0 deletions packages/ui/src/index.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
'use client'

export * from '@openlabs/theme'
export * from './components/accordion'
export * from './components/alert'
export * from './components/aspect-ratio'
export * from './components/avatar'
export * from './components/badge'
export * from './components/breadcrumb'
export * from './components/button'
export * from './components/card'
export * from './components/carousel'
export * from './components/label'
export * from './components/tooltip'
export * from './components/tabs'
export * from './components/table'
export * from './components/skeleton'
export * from './components/sheet'
export * from './components/separator'
export * from './components/select'
export * from './components/checkbox'
export * from './components/dialog'
export * from './components/input'
export * from './components/scroll-area'
export * from './components/popover'
export * from './components/progress'
export * from './components/dropdown'
export * from './components/slider'
7 changes: 3 additions & 4 deletions packages/ui/tsup.config.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,9 @@
import { defineConfig } from 'tsup'

export default defineConfig(options => ({
export default defineConfig({
name: 'react',
entryPoints: ['./index.ts'],
entryPoints: ['./src/index.ts'],
format: ['cjs', 'esm'],
clean: true,
target: 'es2019',
...options,
}))
})
Loading