diff --git a/.gitignore b/.gitignore index 716b3c5..fd2b78d 100644 --- a/.gitignore +++ b/.gitignore @@ -19,3 +19,7 @@ #!.yarn/cache node_modules/ .pnp.* + +# Library + +lib/ diff --git a/index.ts b/index.ts index ff68753..31096a8 100644 --- a/index.ts +++ b/index.ts @@ -1 +1,48 @@ import "./src/styles/main.less"; + +export * from "./src/Application/Application"; +export * from "./src/Application/ApplicationError"; +export * from "./src/Application/Kernel"; + +export * from "./src/Components/Card"; +export * from "./src/Components/Buttons/Buttons"; +export * from "./src/Components/Curtains/Curtains"; +export {useCurtain} from "./src/Components/Curtains/CurtainInstance"; +export type {CurtainContextState} from "./src/Components/Curtains/CurtainInstance"; +export * from "./src/Components/Dates/Calendar"; +export * from "./src/Components/Dates/Datepicker"; +export * from "./src/Components/Floating/Float"; +export * from "./src/Components/Floating/Tooltip"; +export * from "./src/Components/Forms/Checkbox"; +export * from "./src/Components/Forms/DatepickerInput"; +export * from "./src/Components/Forms/PasswordInput"; +export * from "./src/Components/Forms/Radio"; +export * from "./src/Components/Forms/RequiredField"; +export * from "./src/Components/Forms/TimepickerInput"; +export * from "./src/Components/Forms/ToggleSwitch"; +export * from "./src/Components/Loaders/GenericLoader"; +export * from "./src/Components/Loaders/ListLoader"; +export * from "./src/Components/Loaders/SpinningLoader"; +export * from "./src/Components/Menus/AppsMenu"; +export * from "./src/Components/Menus/MainMenu"; +export * from "./src/Components/Menus/MainMenuItem"; +export * from "./src/Components/Menus/Submenu"; +export * from "./src/Components/Menus/SubmenuFloat"; +export * from "./src/Components/Menus/SubmenuItem"; +export * from "./src/Components/Modals/Modals"; +export * from "./src/Components/Modals/ModalsTypes"; +export * from "./src/Components/Notifications/Notification"; +export * from "./src/Components/Notifications/Notifications"; +export * from "./src/Components/Pagination/Paginate"; +export * from "./src/Components/Pagination/Pagination"; +export * from "./src/Components/Select/OptionsSuggestions"; +export * from "./src/Components/Select/Select"; +export * from "./src/Components/Select/SimpleSuggestions"; +export * from "./src/Components/Select/Suggestible"; +export * from "./src/Components/Steps/Steps"; +export * from "./src/Components/Steps/StepsContext"; +export * from "./src/Components/Subapps/Subapps"; + +export * from "./src/Async"; +export * from "./src/GlobalState"; +export * from "./src/Utils"; diff --git a/package.json b/package.json index 19db8e1..b4dc24d 100644 --- a/package.json +++ b/package.json @@ -1,37 +1,37 @@ { - "name": "kernel-ui-core", - "description": "Kernel UI Core.", - "version": "1.0.0", - "scripts": { - "dev": "vite", - "build": "tsc && vite build" - }, - "type": "module", - "source": "index.ts", - "types": "lib/index.d.ts", - "main": "lib/index.js", - "dependencies": { - "@floating-ui/react": "^0.26.17", - "@fontsource-variable/jetbrains-mono": "^5.0.21", - "@fontsource-variable/manrope": "^5.0.20", - "@fontsource-variable/source-serif-4": "^5.0.19", - "@phosphor-icons/react": "^2.1.5", - "react": "^18.3.1", - "react-merge-refs": "^2.1.1", - "react-router-dom": "^6.24.1", - "uuid": "^10.0.0" - }, - "devDependencies": { - "@types/node": "^20.14.10", - "@types/react": "^18.3.3", - "@types/react-dom": "^18.3.0", - "@types/uuid": "^10", - "@vitejs/plugin-react": "^4.3.0", - "less": "^4.2.0", - "react-dom": "^18.3.1", - "typescript": "^5.4.5", - "vite": "^5.2.11", - "vite-plugin-dts": "^3.9.1" - }, - "packageManager": "yarn@4.2.2" + "version": "1.0.0-rc1", + "name": "@kernelui/core", + "description": "Kernel UI Core.", + "scripts": { + "dev": "vite", + "build": "tsc && vite build" + }, + "type": "module", + "source": "index.ts", + "types": "lib/index.d.ts", + "main": "lib/index.js", + "dependencies": { + "@floating-ui/react": "^0.26.17", + "@fontsource-variable/jetbrains-mono": "^5.0.21", + "@fontsource-variable/manrope": "^5.0.20", + "@fontsource-variable/source-serif-4": "^5.0.19", + "@phosphor-icons/react": "^2.1.5", + "react": "^18.3.1", + "react-merge-refs": "^2.1.1", + "react-router-dom": "^6.24.1", + "uuid": "^10.0.0" + }, + "devDependencies": { + "@types/node": "^20.14.10", + "@types/react": "^18.3.3", + "@types/react-dom": "^18.3.0", + "@types/uuid": "^10", + "@vitejs/plugin-react": "^4.3.0", + "less": "^4.2.0", + "react-dom": "^18.3.1", + "typescript": "^5.4.5", + "vite": "^5.2.11", + "vite-plugin-dts": "^3.9.1" + }, + "packageManager": "yarn@4.2.2" } diff --git a/vite.config.ts b/vite.config.ts index 0221dba..be8fc31 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -9,6 +9,7 @@ export default defineConfig(({ mode }: ConfigEnv): UserConfig => { build: { outDir: "lib", sourcemap: true, + minify: "esbuild", lib: { entry: "index.ts", formats: ["es"], @@ -23,6 +24,7 @@ export default defineConfig(({ mode }: ConfigEnv): UserConfig => { react(), dts({ insertTypesEntry: true, + exclude: ["demo", "node_modules"], }), ] }); diff --git a/yarn.lock b/yarn.lock index 01368f5..8ed5f6a 100644 --- a/yarn.lock +++ b/yarn.lock @@ -559,6 +559,32 @@ __metadata: languageName: node linkType: hard +"@kernelui/core@workspace:.": + version: 0.0.0-use.local + resolution: "@kernelui/core@workspace:." + dependencies: + "@floating-ui/react": "npm:^0.26.17" + "@fontsource-variable/jetbrains-mono": "npm:^5.0.21" + "@fontsource-variable/manrope": "npm:^5.0.20" + "@fontsource-variable/source-serif-4": "npm:^5.0.19" + "@phosphor-icons/react": "npm:^2.1.5" + "@types/node": "npm:^20.14.10" + "@types/react": "npm:^18.3.3" + "@types/react-dom": "npm:^18.3.0" + "@types/uuid": "npm:^10" + "@vitejs/plugin-react": "npm:^4.3.0" + less: "npm:^4.2.0" + react: "npm:^18.3.1" + react-dom: "npm:^18.3.1" + react-merge-refs: "npm:^2.1.1" + react-router-dom: "npm:^6.24.1" + typescript: "npm:^5.4.5" + uuid: "npm:^10.0.0" + vite: "npm:^5.2.11" + vite-plugin-dts: "npm:^3.9.1" + languageName: unknown + linkType: soft + "@microsoft/api-extractor-model@npm:7.28.13": version: 7.28.13 resolution: "@microsoft/api-extractor-model@npm:7.28.13" @@ -1833,32 +1859,6 @@ __metadata: languageName: node linkType: hard -"kernel-ui-core@workspace:.": - version: 0.0.0-use.local - resolution: "kernel-ui-core@workspace:." - dependencies: - "@floating-ui/react": "npm:^0.26.17" - "@fontsource-variable/jetbrains-mono": "npm:^5.0.21" - "@fontsource-variable/manrope": "npm:^5.0.20" - "@fontsource-variable/source-serif-4": "npm:^5.0.19" - "@phosphor-icons/react": "npm:^2.1.5" - "@types/node": "npm:^20.14.10" - "@types/react": "npm:^18.3.3" - "@types/react-dom": "npm:^18.3.0" - "@types/uuid": "npm:^10" - "@vitejs/plugin-react": "npm:^4.3.0" - less: "npm:^4.2.0" - react: "npm:^18.3.1" - react-dom: "npm:^18.3.1" - react-merge-refs: "npm:^2.1.1" - react-router-dom: "npm:^6.24.1" - typescript: "npm:^5.4.5" - uuid: "npm:^10.0.0" - vite: "npm:^5.2.11" - vite-plugin-dts: "npm:^3.9.1" - languageName: unknown - linkType: soft - "kolorist@npm:^1.8.0": version: 1.8.0 resolution: "kolorist@npm:1.8.0"