diff --git a/.gitignore b/.gitignore index 08a198642..90af7c23d 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,5 @@ node_modules bare.css -/packages/*/dist +/packages/*/package +# lerna doesn't look at package-locks iirc +**/*/package-lock.json \ No newline at end of file diff --git a/package.json b/package.json index 60ff29e75..54591244a 100644 --- a/package.json +++ b/package.json @@ -38,12 +38,15 @@ "devDependencies": { "@commitlint/cli": "^17.0.3", "@commitlint/config-conventional": "^17.0.3", + "@sveltejs/adapter-auto": "next", + "@sveltejs/package": "^1.0.0-next.6", "husky": "^8.0.1", "lerna": "^5.2.0", "lint-staged": "^13.0.3", "prettier": "~2.7.1", "prettier-plugin-svelte": "^2.7.0", "sass": "^1.54.0", - "svelte": "^3.49.0" + "svelte": "^3.49.0", + "svelte-preprocess": "^4.10.6" } } diff --git a/packages/accordion/package.json b/packages/accordion/package.json index d55b3ec0b..0bf25baf0 100644 --- a/packages/accordion/package.json +++ b/packages/accordion/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Accordion", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -54,7 +53,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/accordion/src/Accordion.svelte b/packages/accordion/src/lib/Accordion.svelte similarity index 100% rename from packages/accordion/src/Accordion.svelte rename to packages/accordion/src/lib/Accordion.svelte diff --git a/packages/accordion/src/Header.svelte b/packages/accordion/src/lib/Header.svelte similarity index 100% rename from packages/accordion/src/Header.svelte rename to packages/accordion/src/lib/Header.svelte diff --git a/packages/accordion/src/Panel.svelte b/packages/accordion/src/lib/Panel.svelte similarity index 100% rename from packages/accordion/src/Panel.svelte rename to packages/accordion/src/lib/Panel.svelte diff --git a/packages/accordion/src/Panel.types.ts b/packages/accordion/src/lib/Panel.types.ts similarity index 100% rename from packages/accordion/src/Panel.types.ts rename to packages/accordion/src/lib/Panel.types.ts diff --git a/packages/accordion/src/ambient.d.ts b/packages/accordion/src/lib/ambient.d.ts similarity index 100% rename from packages/accordion/src/ambient.d.ts rename to packages/accordion/src/lib/ambient.d.ts diff --git a/packages/accordion/src/index.ts b/packages/accordion/src/lib/index.ts similarity index 100% rename from packages/accordion/src/index.ts rename to packages/accordion/src/lib/index.ts diff --git a/packages/accordion/svelte.config.js b/packages/accordion/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/accordion/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/autocomplete/package.json b/packages/autocomplete/package.json index ec2467711..096cef541 100644 --- a/packages/autocomplete/package.json +++ b/packages/autocomplete/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Autocomplete", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -53,7 +52,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/autocomplete/src/Autocomplete.svelte b/packages/autocomplete/src/lib/Autocomplete.svelte similarity index 100% rename from packages/autocomplete/src/Autocomplete.svelte rename to packages/autocomplete/src/lib/Autocomplete.svelte diff --git a/packages/autocomplete/src/ambient.d.ts b/packages/autocomplete/src/lib/ambient.d.ts similarity index 100% rename from packages/autocomplete/src/ambient.d.ts rename to packages/autocomplete/src/lib/ambient.d.ts diff --git a/packages/autocomplete/src/index.ts b/packages/autocomplete/src/lib/index.ts similarity index 100% rename from packages/autocomplete/src/index.ts rename to packages/autocomplete/src/lib/index.ts diff --git a/packages/autocomplete/svelte.config.js b/packages/autocomplete/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/autocomplete/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/badge/package.json b/packages/badge/package.json index 0824486c2..1542d07f8 100644 --- a/packages/badge/package.json +++ b/packages/badge/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Badge", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -51,7 +50,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/badge/src/Badge.svelte b/packages/badge/src/lib/Badge.svelte similarity index 100% rename from packages/badge/src/Badge.svelte rename to packages/badge/src/lib/Badge.svelte diff --git a/packages/badge/src/ambient.d.ts b/packages/badge/src/lib/ambient.d.ts similarity index 100% rename from packages/badge/src/ambient.d.ts rename to packages/badge/src/lib/ambient.d.ts diff --git a/packages/badge/src/index.ts b/packages/badge/src/lib/index.ts similarity index 100% rename from packages/badge/src/index.ts rename to packages/badge/src/lib/index.ts diff --git a/packages/badge/svelte.config.js b/packages/badge/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/badge/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/banner/package.json b/packages/banner/package.json index 5bea2dfb0..33b2e171b 100644 --- a/packages/banner/package.json +++ b/packages/banner/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Banner", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -47,7 +46,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/banner/src/Banner.svelte b/packages/banner/src/lib/Banner.svelte similarity index 100% rename from packages/banner/src/Banner.svelte rename to packages/banner/src/lib/Banner.svelte diff --git a/packages/banner/src/Banner.types.ts b/packages/banner/src/lib/Banner.types.ts similarity index 100% rename from packages/banner/src/Banner.types.ts rename to packages/banner/src/lib/Banner.types.ts diff --git a/packages/banner/src/Fixed.svelte b/packages/banner/src/lib/Fixed.svelte similarity index 100% rename from packages/banner/src/Fixed.svelte rename to packages/banner/src/lib/Fixed.svelte diff --git a/packages/banner/src/ambient.d.ts b/packages/banner/src/lib/ambient.d.ts similarity index 100% rename from packages/banner/src/ambient.d.ts rename to packages/banner/src/lib/ambient.d.ts diff --git a/packages/banner/src/index.ts b/packages/banner/src/lib/index.ts similarity index 100% rename from packages/banner/src/index.ts rename to packages/banner/src/lib/index.ts diff --git a/packages/banner/svelte.config.js b/packages/banner/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/banner/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/bottom-app-bar/package.json b/packages/bottom-app-bar/package.json index 8e62901aa..8c30ccb4a 100644 --- a/packages/bottom-app-bar/package.json +++ b/packages/bottom-app-bar/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Bottom App Bar", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -49,7 +48,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/bottom-app-bar/src/AutoAdjust.svelte b/packages/bottom-app-bar/src/lib/AutoAdjust.svelte similarity index 100% rename from packages/bottom-app-bar/src/AutoAdjust.svelte rename to packages/bottom-app-bar/src/lib/AutoAdjust.svelte diff --git a/packages/bottom-app-bar/src/BottomAppBar.svelte b/packages/bottom-app-bar/src/lib/BottomAppBar.svelte similarity index 100% rename from packages/bottom-app-bar/src/BottomAppBar.svelte rename to packages/bottom-app-bar/src/lib/BottomAppBar.svelte diff --git a/packages/bottom-app-bar/src/FixedAdjust.ts b/packages/bottom-app-bar/src/lib/FixedAdjust.ts similarity index 100% rename from packages/bottom-app-bar/src/FixedAdjust.ts rename to packages/bottom-app-bar/src/lib/FixedAdjust.ts diff --git a/packages/bottom-app-bar/src/Section.svelte b/packages/bottom-app-bar/src/lib/Section.svelte similarity index 100% rename from packages/bottom-app-bar/src/Section.svelte rename to packages/bottom-app-bar/src/lib/Section.svelte diff --git a/packages/bottom-app-bar/src/StandardAdjust.ts b/packages/bottom-app-bar/src/lib/StandardAdjust.ts similarity index 100% rename from packages/bottom-app-bar/src/StandardAdjust.ts rename to packages/bottom-app-bar/src/lib/StandardAdjust.ts diff --git a/packages/bottom-app-bar/src/ambient.d.ts b/packages/bottom-app-bar/src/lib/ambient.d.ts similarity index 100% rename from packages/bottom-app-bar/src/ambient.d.ts rename to packages/bottom-app-bar/src/lib/ambient.d.ts diff --git a/packages/bottom-app-bar/src/index.ts b/packages/bottom-app-bar/src/lib/index.ts similarity index 100% rename from packages/bottom-app-bar/src/index.ts rename to packages/bottom-app-bar/src/lib/index.ts diff --git a/packages/bottom-app-bar/svelte.config.js b/packages/bottom-app-bar/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/bottom-app-bar/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/button/package.json b/packages/button/package.json index 07a62725c..f53fd82b8 100644 --- a/packages/button/package.json +++ b/packages/button/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Button", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -52,7 +51,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/button/src/Button.svelte b/packages/button/src/lib/Button.svelte similarity index 100% rename from packages/button/src/Button.svelte rename to packages/button/src/lib/Button.svelte diff --git a/packages/button/src/Group.svelte b/packages/button/src/lib/Group.svelte similarity index 100% rename from packages/button/src/Group.svelte rename to packages/button/src/lib/Group.svelte diff --git a/packages/button/src/GroupItem.ts b/packages/button/src/lib/GroupItem.ts similarity index 100% rename from packages/button/src/GroupItem.ts rename to packages/button/src/lib/GroupItem.ts diff --git a/packages/button/src/ambient.d.ts b/packages/button/src/lib/ambient.d.ts similarity index 100% rename from packages/button/src/ambient.d.ts rename to packages/button/src/lib/ambient.d.ts diff --git a/packages/button/src/index.ts b/packages/button/src/lib/index.ts similarity index 100% rename from packages/button/src/index.ts rename to packages/button/src/lib/index.ts diff --git a/packages/button/svelte.config.js b/packages/button/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/button/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/card/package.json b/packages/card/package.json index 0ec1a0fdb..993345ee1 100644 --- a/packages/card/package.json +++ b/packages/card/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Card", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -52,7 +51,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/card/src/ActionButtons.ts b/packages/card/src/lib/ActionButtons.ts similarity index 100% rename from packages/card/src/ActionButtons.ts rename to packages/card/src/lib/ActionButtons.ts diff --git a/packages/card/src/ActionIcons.ts b/packages/card/src/lib/ActionIcons.ts similarity index 100% rename from packages/card/src/ActionIcons.ts rename to packages/card/src/lib/ActionIcons.ts diff --git a/packages/card/src/Actions.svelte b/packages/card/src/lib/Actions.svelte similarity index 100% rename from packages/card/src/Actions.svelte rename to packages/card/src/lib/Actions.svelte diff --git a/packages/card/src/Card.svelte b/packages/card/src/lib/Card.svelte similarity index 100% rename from packages/card/src/Card.svelte rename to packages/card/src/lib/Card.svelte diff --git a/packages/card/src/Content.ts b/packages/card/src/lib/Content.ts similarity index 100% rename from packages/card/src/Content.ts rename to packages/card/src/lib/Content.ts diff --git a/packages/card/src/Media.svelte b/packages/card/src/lib/Media.svelte similarity index 100% rename from packages/card/src/Media.svelte rename to packages/card/src/lib/Media.svelte diff --git a/packages/card/src/MediaContent.ts b/packages/card/src/lib/MediaContent.ts similarity index 100% rename from packages/card/src/MediaContent.ts rename to packages/card/src/lib/MediaContent.ts diff --git a/packages/card/src/PrimaryAction.svelte b/packages/card/src/lib/PrimaryAction.svelte similarity index 100% rename from packages/card/src/PrimaryAction.svelte rename to packages/card/src/lib/PrimaryAction.svelte diff --git a/packages/card/src/ambient.d.ts b/packages/card/src/lib/ambient.d.ts similarity index 100% rename from packages/card/src/ambient.d.ts rename to packages/card/src/lib/ambient.d.ts diff --git a/packages/card/src/index.ts b/packages/card/src/lib/index.ts similarity index 100% rename from packages/card/src/index.ts rename to packages/card/src/lib/index.ts diff --git a/packages/card/svelte.config.js b/packages/card/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/card/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/checkbox/package.json b/packages/checkbox/package.json index 33a791244..e32f991cf 100644 --- a/packages/checkbox/package.json +++ b/packages/checkbox/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Checkbox", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -48,7 +47,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/checkbox/src/Checkbox.svelte b/packages/checkbox/src/lib/Checkbox.svelte similarity index 100% rename from packages/checkbox/src/Checkbox.svelte rename to packages/checkbox/src/lib/Checkbox.svelte diff --git a/packages/checkbox/src/ambient.d.ts b/packages/checkbox/src/lib/ambient.d.ts similarity index 100% rename from packages/checkbox/src/ambient.d.ts rename to packages/checkbox/src/lib/ambient.d.ts diff --git a/packages/checkbox/src/index.ts b/packages/checkbox/src/lib/index.ts similarity index 100% rename from packages/checkbox/src/index.ts rename to packages/checkbox/src/lib/index.ts diff --git a/packages/checkbox/svelte.config.js b/packages/checkbox/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/checkbox/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/chips/package.json b/packages/chips/package.json index c5fe60705..b67be4bac 100644 --- a/packages/chips/package.json +++ b/packages/chips/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Chips", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -50,7 +49,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/chips/src/Checkmark.svelte b/packages/chips/src/lib/Checkmark.svelte similarity index 100% rename from packages/chips/src/Checkmark.svelte rename to packages/chips/src/lib/Checkmark.svelte diff --git a/packages/chips/src/Chip.svelte b/packages/chips/src/lib/Chip.svelte similarity index 100% rename from packages/chips/src/Chip.svelte rename to packages/chips/src/lib/Chip.svelte diff --git a/packages/chips/src/Chip.types.ts b/packages/chips/src/lib/Chip.types.ts similarity index 100% rename from packages/chips/src/Chip.types.ts rename to packages/chips/src/lib/Chip.types.ts diff --git a/packages/chips/src/LeadingIcon.svelte b/packages/chips/src/lib/LeadingIcon.svelte similarity index 100% rename from packages/chips/src/LeadingIcon.svelte rename to packages/chips/src/lib/LeadingIcon.svelte diff --git a/packages/chips/src/Set.svelte b/packages/chips/src/lib/Set.svelte similarity index 100% rename from packages/chips/src/Set.svelte rename to packages/chips/src/lib/Set.svelte diff --git a/packages/chips/src/Text.svelte b/packages/chips/src/lib/Text.svelte similarity index 100% rename from packages/chips/src/Text.svelte rename to packages/chips/src/lib/Text.svelte diff --git a/packages/chips/src/Text.types.ts b/packages/chips/src/lib/Text.types.ts similarity index 100% rename from packages/chips/src/Text.types.ts rename to packages/chips/src/lib/Text.types.ts diff --git a/packages/chips/src/TrailingAction.svelte b/packages/chips/src/lib/TrailingAction.svelte similarity index 100% rename from packages/chips/src/TrailingAction.svelte rename to packages/chips/src/lib/TrailingAction.svelte diff --git a/packages/chips/src/TrailingAction.types.ts b/packages/chips/src/lib/TrailingAction.types.ts similarity index 100% rename from packages/chips/src/TrailingAction.types.ts rename to packages/chips/src/lib/TrailingAction.types.ts diff --git a/packages/chips/src/TrailingIcon.svelte b/packages/chips/src/lib/TrailingIcon.svelte similarity index 100% rename from packages/chips/src/TrailingIcon.svelte rename to packages/chips/src/lib/TrailingIcon.svelte diff --git a/packages/chips/src/ambient.d.ts b/packages/chips/src/lib/ambient.d.ts similarity index 100% rename from packages/chips/src/ambient.d.ts rename to packages/chips/src/lib/ambient.d.ts diff --git a/packages/chips/src/index.ts b/packages/chips/src/lib/index.ts similarity index 100% rename from packages/chips/src/index.ts rename to packages/chips/src/lib/index.ts diff --git a/packages/chips/svelte.config.js b/packages/chips/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/chips/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/circular-progress/package.json b/packages/circular-progress/package.json index f3eef10d3..2f98ed92c 100644 --- a/packages/circular-progress/package.json +++ b/packages/circular-progress/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Circular Progress", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -47,7 +46,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/circular-progress/src/CircularProgress.svelte b/packages/circular-progress/src/lib/CircularProgress.svelte similarity index 100% rename from packages/circular-progress/src/CircularProgress.svelte rename to packages/circular-progress/src/lib/CircularProgress.svelte diff --git a/packages/circular-progress/src/ambient.d.ts b/packages/circular-progress/src/lib/ambient.d.ts similarity index 100% rename from packages/circular-progress/src/ambient.d.ts rename to packages/circular-progress/src/lib/ambient.d.ts diff --git a/packages/circular-progress/src/index.ts b/packages/circular-progress/src/lib/index.ts similarity index 100% rename from packages/circular-progress/src/index.ts rename to packages/circular-progress/src/lib/index.ts diff --git a/packages/circular-progress/svelte.config.js b/packages/circular-progress/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/circular-progress/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/common/classadder.js b/packages/common/classadder.js index 405f68e06..0a5230942 100644 --- a/packages/common/classadder.js +++ b/packages/common/classadder.js @@ -1 +1 @@ -export * from './dist/classadder/index.js'; +export * from './package/classadder/index.js'; diff --git a/packages/common/index.js b/packages/common/index.js index 2b8395cdb..5bf210a89 100644 --- a/packages/common/index.js +++ b/packages/common/index.js @@ -1 +1 @@ -export * from './dist/index.js'; +export * from './package/index.js'; diff --git a/packages/common/internal.js b/packages/common/internal.js index 8de1b9026..cd2b81adf 100644 --- a/packages/common/internal.js +++ b/packages/common/internal.js @@ -1 +1 @@ -export * from './dist/internal/index.js'; +export * from './package/internal/index.js'; diff --git a/packages/common/package.json b/packages/common/package.json index e1f70c01e..3d2742ed5 100644 --- a/packages/common/package.json +++ b/packages/common/package.json @@ -3,23 +3,23 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Common", "type": "module", - "svelte": "./dist/index.js", + "svelte": "./package/index.js", "exports": { "./package.json": "./package.json", - ".": "./dist/index.js", - "./classadder": "./dist/classadder/index.js", - "./internal": "./dist/internal/index.js" + ".": "./package/index.js", + "./classadder": "./package/classadder/index.js", + "./internal": "./package/internal/index.js" }, "typesVersions": { "*": { "classadder": [ - "./src/classadder/index.ts" + "./package/classadder/index.d.ts" ], "internal": [ - "./src/internal/index.ts" + "./package/internal/index.d.ts" ], "*": [ - "./src/*" + "./package/*" ] } }, @@ -33,11 +33,9 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "svelte-package", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -56,7 +54,6 @@ "devDependencies": { "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" }, diff --git a/packages/common/src/CommonIcon.svelte b/packages/common/src/lib/CommonIcon.svelte similarity index 100% rename from packages/common/src/CommonIcon.svelte rename to packages/common/src/lib/CommonIcon.svelte diff --git a/packages/common/src/CommonLabel.svelte b/packages/common/src/lib/CommonLabel.svelte similarity index 100% rename from packages/common/src/CommonLabel.svelte rename to packages/common/src/lib/CommonLabel.svelte diff --git a/packages/common/src/ContextFragment.svelte b/packages/common/src/lib/ContextFragment.svelte similarity index 100% rename from packages/common/src/ContextFragment.svelte rename to packages/common/src/lib/ContextFragment.svelte diff --git a/packages/common/src/SmuiElement.svelte b/packages/common/src/lib/SmuiElement.svelte similarity index 100% rename from packages/common/src/SmuiElement.svelte rename to packages/common/src/lib/SmuiElement.svelte diff --git a/packages/common/src/Svg.svelte b/packages/common/src/lib/Svg.svelte similarity index 100% rename from packages/common/src/Svg.svelte rename to packages/common/src/lib/Svg.svelte diff --git a/packages/common/src/ambient.d.ts b/packages/common/src/lib/ambient.d.ts similarity index 100% rename from packages/common/src/ambient.d.ts rename to packages/common/src/lib/ambient.d.ts diff --git a/packages/common/src/classadder/ClassAdder.svelte b/packages/common/src/lib/classadder/ClassAdder.svelte similarity index 100% rename from packages/common/src/classadder/ClassAdder.svelte rename to packages/common/src/lib/classadder/ClassAdder.svelte diff --git a/packages/common/src/classadder/ClassAdder.types.ts b/packages/common/src/lib/classadder/ClassAdder.types.ts similarity index 100% rename from packages/common/src/classadder/ClassAdder.types.ts rename to packages/common/src/lib/classadder/ClassAdder.types.ts diff --git a/packages/common/src/classadder/classAdderBuilder.ts b/packages/common/src/lib/classadder/classAdderBuilder.ts similarity index 100% rename from packages/common/src/classadder/classAdderBuilder.ts rename to packages/common/src/lib/classadder/classAdderBuilder.ts diff --git a/packages/common/src/classadder/index.ts b/packages/common/src/lib/classadder/index.ts similarity index 100% rename from packages/common/src/classadder/index.ts rename to packages/common/src/lib/classadder/index.ts diff --git a/packages/common/src/index.ts b/packages/common/src/lib/index.ts similarity index 100% rename from packages/common/src/index.ts rename to packages/common/src/lib/index.ts diff --git a/packages/common/src/internal/announce.ts b/packages/common/src/lib/internal/announce.ts similarity index 100% rename from packages/common/src/internal/announce.ts rename to packages/common/src/lib/internal/announce.ts diff --git a/packages/common/src/internal/classMap.ts b/packages/common/src/lib/internal/classMap.ts similarity index 100% rename from packages/common/src/internal/classMap.ts rename to packages/common/src/lib/internal/classMap.ts diff --git a/packages/common/src/internal/dispatch.ts b/packages/common/src/lib/internal/dispatch.ts similarity index 100% rename from packages/common/src/internal/dispatch.ts rename to packages/common/src/lib/internal/dispatch.ts diff --git a/packages/common/src/internal/exclude.ts b/packages/common/src/lib/internal/exclude.ts similarity index 100% rename from packages/common/src/internal/exclude.ts rename to packages/common/src/lib/internal/exclude.ts diff --git a/packages/common/src/internal/forwardEventsBuilder.ts b/packages/common/src/lib/internal/forwardEventsBuilder.ts similarity index 100% rename from packages/common/src/internal/forwardEventsBuilder.ts rename to packages/common/src/lib/internal/forwardEventsBuilder.ts diff --git a/packages/common/src/internal/index.ts b/packages/common/src/lib/internal/index.ts similarity index 100% rename from packages/common/src/internal/index.ts rename to packages/common/src/lib/internal/index.ts diff --git a/packages/common/src/internal/prefixFilter.ts b/packages/common/src/lib/internal/prefixFilter.ts similarity index 100% rename from packages/common/src/internal/prefixFilter.ts rename to packages/common/src/lib/internal/prefixFilter.ts diff --git a/packages/common/src/internal/useActions.ts b/packages/common/src/lib/internal/useActions.ts similarity index 100% rename from packages/common/src/internal/useActions.ts rename to packages/common/src/lib/internal/useActions.ts diff --git a/packages/common/src/smui.types.ts b/packages/common/src/lib/smui.types.ts similarity index 100% rename from packages/common/src/smui.types.ts rename to packages/common/src/lib/smui.types.ts diff --git a/packages/common/svelte.config.js b/packages/common/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/common/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/data-table/package.json b/packages/data-table/package.json index 1b0f8b6a7..87c537da7 100644 --- a/packages/data-table/package.json +++ b/packages/data-table/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Data Table", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -52,7 +51,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/data-table/src/Body.svelte b/packages/data-table/src/lib/Body.svelte similarity index 100% rename from packages/data-table/src/Body.svelte rename to packages/data-table/src/lib/Body.svelte diff --git a/packages/data-table/src/Body.types.ts b/packages/data-table/src/lib/Body.types.ts similarity index 100% rename from packages/data-table/src/Body.types.ts rename to packages/data-table/src/lib/Body.types.ts diff --git a/packages/data-table/src/Cell.svelte b/packages/data-table/src/lib/Cell.svelte similarity index 100% rename from packages/data-table/src/Cell.svelte rename to packages/data-table/src/lib/Cell.svelte diff --git a/packages/data-table/src/Cell.types.ts b/packages/data-table/src/lib/Cell.types.ts similarity index 100% rename from packages/data-table/src/Cell.types.ts rename to packages/data-table/src/lib/Cell.types.ts diff --git a/packages/data-table/src/DataTable.svelte b/packages/data-table/src/lib/DataTable.svelte similarity index 100% rename from packages/data-table/src/DataTable.svelte rename to packages/data-table/src/lib/DataTable.svelte diff --git a/packages/data-table/src/DataTable.types.ts b/packages/data-table/src/lib/DataTable.types.ts similarity index 100% rename from packages/data-table/src/DataTable.types.ts rename to packages/data-table/src/lib/DataTable.types.ts diff --git a/packages/data-table/src/Head.svelte b/packages/data-table/src/lib/Head.svelte similarity index 100% rename from packages/data-table/src/Head.svelte rename to packages/data-table/src/lib/Head.svelte diff --git a/packages/data-table/src/Head.types.ts b/packages/data-table/src/lib/Head.types.ts similarity index 100% rename from packages/data-table/src/Head.types.ts rename to packages/data-table/src/lib/Head.types.ts diff --git a/packages/data-table/src/Pagination.svelte b/packages/data-table/src/lib/Pagination.svelte similarity index 100% rename from packages/data-table/src/Pagination.svelte rename to packages/data-table/src/lib/Pagination.svelte diff --git a/packages/data-table/src/Row.svelte b/packages/data-table/src/lib/Row.svelte similarity index 100% rename from packages/data-table/src/Row.svelte rename to packages/data-table/src/lib/Row.svelte diff --git a/packages/data-table/src/Row.types.ts b/packages/data-table/src/lib/Row.types.ts similarity index 100% rename from packages/data-table/src/Row.types.ts rename to packages/data-table/src/lib/Row.types.ts diff --git a/packages/data-table/src/ambient.d.ts b/packages/data-table/src/lib/ambient.d.ts similarity index 100% rename from packages/data-table/src/ambient.d.ts rename to packages/data-table/src/lib/ambient.d.ts diff --git a/packages/data-table/src/index.ts b/packages/data-table/src/lib/index.ts similarity index 100% rename from packages/data-table/src/index.ts rename to packages/data-table/src/lib/index.ts diff --git a/packages/data-table/svelte.config.js b/packages/data-table/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/data-table/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/dialog/package.json b/packages/dialog/package.json index 494435520..cb6fd699b 100644 --- a/packages/dialog/package.json +++ b/packages/dialog/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Dialog", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -49,7 +48,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/dialog/src/Actions.ts b/packages/dialog/src/lib/Actions.ts similarity index 100% rename from packages/dialog/src/Actions.ts rename to packages/dialog/src/lib/Actions.ts diff --git a/packages/dialog/src/Content.ts b/packages/dialog/src/lib/Content.ts similarity index 100% rename from packages/dialog/src/Content.ts rename to packages/dialog/src/lib/Content.ts diff --git a/packages/dialog/src/Dialog.svelte b/packages/dialog/src/lib/Dialog.svelte similarity index 100% rename from packages/dialog/src/Dialog.svelte rename to packages/dialog/src/lib/Dialog.svelte diff --git a/packages/dialog/src/Header.ts b/packages/dialog/src/lib/Header.ts similarity index 100% rename from packages/dialog/src/Header.ts rename to packages/dialog/src/lib/Header.ts diff --git a/packages/dialog/src/InitialFocus.ts b/packages/dialog/src/lib/InitialFocus.ts similarity index 100% rename from packages/dialog/src/InitialFocus.ts rename to packages/dialog/src/lib/InitialFocus.ts diff --git a/packages/dialog/src/Title.ts b/packages/dialog/src/lib/Title.ts similarity index 100% rename from packages/dialog/src/Title.ts rename to packages/dialog/src/lib/Title.ts diff --git a/packages/dialog/src/ambient.d.ts b/packages/dialog/src/lib/ambient.d.ts similarity index 100% rename from packages/dialog/src/ambient.d.ts rename to packages/dialog/src/lib/ambient.d.ts diff --git a/packages/dialog/src/index.ts b/packages/dialog/src/lib/index.ts similarity index 100% rename from packages/dialog/src/index.ts rename to packages/dialog/src/lib/index.ts diff --git a/packages/dialog/svelte.config.js b/packages/dialog/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/dialog/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/drawer/package.json b/packages/drawer/package.json index ea9b60fd4..afac9efc6 100644 --- a/packages/drawer/package.json +++ b/packages/drawer/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Drawer", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -48,7 +47,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/drawer/src/AppContent.ts b/packages/drawer/src/lib/AppContent.ts similarity index 100% rename from packages/drawer/src/AppContent.ts rename to packages/drawer/src/lib/AppContent.ts diff --git a/packages/drawer/src/Content.ts b/packages/drawer/src/lib/Content.ts similarity index 100% rename from packages/drawer/src/Content.ts rename to packages/drawer/src/lib/Content.ts diff --git a/packages/drawer/src/Drawer.svelte b/packages/drawer/src/lib/Drawer.svelte similarity index 100% rename from packages/drawer/src/Drawer.svelte rename to packages/drawer/src/lib/Drawer.svelte diff --git a/packages/drawer/src/Header.ts b/packages/drawer/src/lib/Header.ts similarity index 100% rename from packages/drawer/src/Header.ts rename to packages/drawer/src/lib/Header.ts diff --git a/packages/drawer/src/Scrim.svelte b/packages/drawer/src/lib/Scrim.svelte similarity index 100% rename from packages/drawer/src/Scrim.svelte rename to packages/drawer/src/lib/Scrim.svelte diff --git a/packages/drawer/src/Subtitle.ts b/packages/drawer/src/lib/Subtitle.ts similarity index 100% rename from packages/drawer/src/Subtitle.ts rename to packages/drawer/src/lib/Subtitle.ts diff --git a/packages/drawer/src/Title.ts b/packages/drawer/src/lib/Title.ts similarity index 100% rename from packages/drawer/src/Title.ts rename to packages/drawer/src/lib/Title.ts diff --git a/packages/drawer/src/ambient.d.ts b/packages/drawer/src/lib/ambient.d.ts similarity index 100% rename from packages/drawer/src/ambient.d.ts rename to packages/drawer/src/lib/ambient.d.ts diff --git a/packages/drawer/src/index.ts b/packages/drawer/src/lib/index.ts similarity index 100% rename from packages/drawer/src/index.ts rename to packages/drawer/src/lib/index.ts diff --git a/packages/drawer/svelte.config.js b/packages/drawer/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/drawer/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/fab/package.json b/packages/fab/package.json index be838c31a..3fb82e707 100644 --- a/packages/fab/package.json +++ b/packages/fab/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Floating Action Button", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -49,7 +48,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/fab/src/Fab.svelte b/packages/fab/src/lib/Fab.svelte similarity index 100% rename from packages/fab/src/Fab.svelte rename to packages/fab/src/lib/Fab.svelte diff --git a/packages/fab/src/ambient.d.ts b/packages/fab/src/lib/ambient.d.ts similarity index 100% rename from packages/fab/src/ambient.d.ts rename to packages/fab/src/lib/ambient.d.ts diff --git a/packages/fab/src/index.ts b/packages/fab/src/lib/index.ts similarity index 100% rename from packages/fab/src/index.ts rename to packages/fab/src/lib/index.ts diff --git a/packages/fab/svelte.config.js b/packages/fab/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/fab/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/floating-label/package.json b/packages/floating-label/package.json index add573a74..b7fbe0935 100644 --- a/packages/floating-label/package.json +++ b/packages/floating-label/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Floating Label", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -47,7 +46,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/floating-label/src/FloatingLabel.svelte b/packages/floating-label/src/lib/FloatingLabel.svelte similarity index 100% rename from packages/floating-label/src/FloatingLabel.svelte rename to packages/floating-label/src/lib/FloatingLabel.svelte diff --git a/packages/floating-label/src/FloatingLabel.types.ts b/packages/floating-label/src/lib/FloatingLabel.types.ts similarity index 100% rename from packages/floating-label/src/FloatingLabel.types.ts rename to packages/floating-label/src/lib/FloatingLabel.types.ts diff --git a/packages/floating-label/src/ambient.d.ts b/packages/floating-label/src/lib/ambient.d.ts similarity index 100% rename from packages/floating-label/src/ambient.d.ts rename to packages/floating-label/src/lib/ambient.d.ts diff --git a/packages/floating-label/src/index.ts b/packages/floating-label/src/lib/index.ts similarity index 100% rename from packages/floating-label/src/index.ts rename to packages/floating-label/src/lib/index.ts diff --git a/packages/floating-label/svelte.config.js b/packages/floating-label/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/floating-label/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/form-field/package.json b/packages/form-field/package.json index 24acefe77..974fcf76f 100644 --- a/packages/form-field/package.json +++ b/packages/form-field/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Form Field", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -49,7 +48,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/form-field/src/FormField.svelte b/packages/form-field/src/lib/FormField.svelte similarity index 100% rename from packages/form-field/src/FormField.svelte rename to packages/form-field/src/lib/FormField.svelte diff --git a/packages/form-field/src/ambient.d.ts b/packages/form-field/src/lib/ambient.d.ts similarity index 100% rename from packages/form-field/src/ambient.d.ts rename to packages/form-field/src/lib/ambient.d.ts diff --git a/packages/form-field/src/index.ts b/packages/form-field/src/lib/index.ts similarity index 100% rename from packages/form-field/src/index.ts rename to packages/form-field/src/lib/index.ts diff --git a/packages/form-field/svelte.config.js b/packages/form-field/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/form-field/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/icon-button/package.json b/packages/icon-button/package.json index b2939e808..e8996ba29 100644 --- a/packages/icon-button/package.json +++ b/packages/icon-button/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Icon Button", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -49,7 +48,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/icon-button/src/IconButton.svelte b/packages/icon-button/src/lib/IconButton.svelte similarity index 100% rename from packages/icon-button/src/IconButton.svelte rename to packages/icon-button/src/lib/IconButton.svelte diff --git a/packages/icon-button/src/ambient.d.ts b/packages/icon-button/src/lib/ambient.d.ts similarity index 100% rename from packages/icon-button/src/ambient.d.ts rename to packages/icon-button/src/lib/ambient.d.ts diff --git a/packages/icon-button/src/index.ts b/packages/icon-button/src/lib/index.ts similarity index 100% rename from packages/icon-button/src/index.ts rename to packages/icon-button/src/lib/index.ts diff --git a/packages/icon-button/svelte.config.js b/packages/icon-button/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/icon-button/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/image-list/package.json b/packages/image-list/package.json index 95a555bdf..9a00ac96d 100644 --- a/packages/image-list/package.json +++ b/packages/image-list/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Image List", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -47,7 +46,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/image-list/src/Image.ts b/packages/image-list/src/lib/Image.ts similarity index 100% rename from packages/image-list/src/Image.ts rename to packages/image-list/src/lib/Image.ts diff --git a/packages/image-list/src/ImageAspectContainer.ts b/packages/image-list/src/lib/ImageAspectContainer.ts similarity index 100% rename from packages/image-list/src/ImageAspectContainer.ts rename to packages/image-list/src/lib/ImageAspectContainer.ts diff --git a/packages/image-list/src/ImageList.svelte b/packages/image-list/src/lib/ImageList.svelte similarity index 100% rename from packages/image-list/src/ImageList.svelte rename to packages/image-list/src/lib/ImageList.svelte diff --git a/packages/image-list/src/Item.ts b/packages/image-list/src/lib/Item.ts similarity index 100% rename from packages/image-list/src/Item.ts rename to packages/image-list/src/lib/Item.ts diff --git a/packages/image-list/src/Supporting.ts b/packages/image-list/src/lib/Supporting.ts similarity index 100% rename from packages/image-list/src/Supporting.ts rename to packages/image-list/src/lib/Supporting.ts diff --git a/packages/image-list/src/ambient.d.ts b/packages/image-list/src/lib/ambient.d.ts similarity index 100% rename from packages/image-list/src/ambient.d.ts rename to packages/image-list/src/lib/ambient.d.ts diff --git a/packages/image-list/src/index.ts b/packages/image-list/src/lib/index.ts similarity index 100% rename from packages/image-list/src/index.ts rename to packages/image-list/src/lib/index.ts diff --git a/packages/image-list/svelte.config.js b/packages/image-list/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/image-list/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/layout-grid/package.json b/packages/layout-grid/package.json index 8fbf23b97..4a6f0eafe 100644 --- a/packages/layout-grid/package.json +++ b/packages/layout-grid/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Layout Grid", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -47,7 +46,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/layout-grid/src/Cell.svelte b/packages/layout-grid/src/lib/Cell.svelte similarity index 100% rename from packages/layout-grid/src/Cell.svelte rename to packages/layout-grid/src/lib/Cell.svelte diff --git a/packages/layout-grid/src/InnerGrid.svelte b/packages/layout-grid/src/lib/InnerGrid.svelte similarity index 100% rename from packages/layout-grid/src/InnerGrid.svelte rename to packages/layout-grid/src/lib/InnerGrid.svelte diff --git a/packages/layout-grid/src/LayoutGrid.svelte b/packages/layout-grid/src/lib/LayoutGrid.svelte similarity index 100% rename from packages/layout-grid/src/LayoutGrid.svelte rename to packages/layout-grid/src/lib/LayoutGrid.svelte diff --git a/packages/layout-grid/src/ambient.d.ts b/packages/layout-grid/src/lib/ambient.d.ts similarity index 100% rename from packages/layout-grid/src/ambient.d.ts rename to packages/layout-grid/src/lib/ambient.d.ts diff --git a/packages/layout-grid/src/index.ts b/packages/layout-grid/src/lib/index.ts similarity index 100% rename from packages/layout-grid/src/index.ts rename to packages/layout-grid/src/lib/index.ts diff --git a/packages/layout-grid/svelte.config.js b/packages/layout-grid/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/layout-grid/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/line-ripple/package.json b/packages/line-ripple/package.json index 00d70c1de..f63fb5052 100644 --- a/packages/line-ripple/package.json +++ b/packages/line-ripple/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Line Ripple", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -47,7 +46,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/line-ripple/src/LineRipple.svelte b/packages/line-ripple/src/lib/LineRipple.svelte similarity index 100% rename from packages/line-ripple/src/LineRipple.svelte rename to packages/line-ripple/src/lib/LineRipple.svelte diff --git a/packages/line-ripple/src/ambient.d.ts b/packages/line-ripple/src/lib/ambient.d.ts similarity index 100% rename from packages/line-ripple/src/ambient.d.ts rename to packages/line-ripple/src/lib/ambient.d.ts diff --git a/packages/line-ripple/src/index.ts b/packages/line-ripple/src/lib/index.ts similarity index 100% rename from packages/line-ripple/src/index.ts rename to packages/line-ripple/src/lib/index.ts diff --git a/packages/line-ripple/svelte.config.js b/packages/line-ripple/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/line-ripple/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/linear-progress/package.json b/packages/linear-progress/package.json index 34b1fd46f..b47f6bf2d 100644 --- a/packages/linear-progress/package.json +++ b/packages/linear-progress/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Linear Progress", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -47,7 +46,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/linear-progress/src/LinearProgress.svelte b/packages/linear-progress/src/lib/LinearProgress.svelte similarity index 100% rename from packages/linear-progress/src/LinearProgress.svelte rename to packages/linear-progress/src/lib/LinearProgress.svelte diff --git a/packages/linear-progress/src/ambient.d.ts b/packages/linear-progress/src/lib/ambient.d.ts similarity index 100% rename from packages/linear-progress/src/ambient.d.ts rename to packages/linear-progress/src/lib/ambient.d.ts diff --git a/packages/linear-progress/src/index.ts b/packages/linear-progress/src/lib/index.ts similarity index 100% rename from packages/linear-progress/src/index.ts rename to packages/linear-progress/src/lib/index.ts diff --git a/packages/linear-progress/svelte.config.js b/packages/linear-progress/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/linear-progress/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/list/package.json b/packages/list/package.json index 90d96b431..45b6f2ef2 100644 --- a/packages/list/package.json +++ b/packages/list/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - List", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -50,7 +49,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/list/src/Graphic.svelte b/packages/list/src/lib/Graphic.svelte similarity index 100% rename from packages/list/src/Graphic.svelte rename to packages/list/src/lib/Graphic.svelte diff --git a/packages/list/src/Group.ts b/packages/list/src/lib/Group.ts similarity index 100% rename from packages/list/src/Group.ts rename to packages/list/src/lib/Group.ts diff --git a/packages/list/src/Item.svelte b/packages/list/src/lib/Item.svelte similarity index 100% rename from packages/list/src/Item.svelte rename to packages/list/src/lib/Item.svelte diff --git a/packages/list/src/Item.types.ts b/packages/list/src/lib/Item.types.ts similarity index 100% rename from packages/list/src/Item.types.ts rename to packages/list/src/lib/Item.types.ts diff --git a/packages/list/src/Label.svelte b/packages/list/src/lib/Label.svelte similarity index 100% rename from packages/list/src/Label.svelte rename to packages/list/src/lib/Label.svelte diff --git a/packages/list/src/List.svelte b/packages/list/src/lib/List.svelte similarity index 100% rename from packages/list/src/List.svelte rename to packages/list/src/lib/List.svelte diff --git a/packages/list/src/List.types.ts b/packages/list/src/lib/List.types.ts similarity index 100% rename from packages/list/src/List.types.ts rename to packages/list/src/lib/List.types.ts diff --git a/packages/list/src/Meta.ts b/packages/list/src/lib/Meta.ts similarity index 100% rename from packages/list/src/Meta.ts rename to packages/list/src/lib/Meta.ts diff --git a/packages/list/src/PrimaryText.ts b/packages/list/src/lib/PrimaryText.ts similarity index 100% rename from packages/list/src/PrimaryText.ts rename to packages/list/src/lib/PrimaryText.ts diff --git a/packages/list/src/SecondaryText.ts b/packages/list/src/lib/SecondaryText.ts similarity index 100% rename from packages/list/src/SecondaryText.ts rename to packages/list/src/lib/SecondaryText.ts diff --git a/packages/list/src/Separator.svelte b/packages/list/src/lib/Separator.svelte similarity index 100% rename from packages/list/src/Separator.svelte rename to packages/list/src/lib/Separator.svelte diff --git a/packages/list/src/Subheader.ts b/packages/list/src/lib/Subheader.ts similarity index 100% rename from packages/list/src/Subheader.ts rename to packages/list/src/lib/Subheader.ts diff --git a/packages/list/src/Text.ts b/packages/list/src/lib/Text.ts similarity index 100% rename from packages/list/src/Text.ts rename to packages/list/src/lib/Text.ts diff --git a/packages/list/src/ambient.d.ts b/packages/list/src/lib/ambient.d.ts similarity index 100% rename from packages/list/src/ambient.d.ts rename to packages/list/src/lib/ambient.d.ts diff --git a/packages/list/src/index.ts b/packages/list/src/lib/index.ts similarity index 100% rename from packages/list/src/index.ts rename to packages/list/src/lib/index.ts diff --git a/packages/list/svelte.config.js b/packages/list/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/list/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/menu-surface/package.json b/packages/menu-surface/package.json index 9a65c5bd5..668b7d50f 100644 --- a/packages/menu-surface/package.json +++ b/packages/menu-surface/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Menu Surface", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -48,7 +47,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/menu-surface/src/Anchor.ts b/packages/menu-surface/src/lib/Anchor.ts similarity index 100% rename from packages/menu-surface/src/Anchor.ts rename to packages/menu-surface/src/lib/Anchor.ts diff --git a/packages/menu-surface/src/MenuSurface.svelte b/packages/menu-surface/src/lib/MenuSurface.svelte similarity index 100% rename from packages/menu-surface/src/MenuSurface.svelte rename to packages/menu-surface/src/lib/MenuSurface.svelte diff --git a/packages/menu-surface/src/MenuSurface.types.ts b/packages/menu-surface/src/lib/MenuSurface.types.ts similarity index 100% rename from packages/menu-surface/src/MenuSurface.types.ts rename to packages/menu-surface/src/lib/MenuSurface.types.ts diff --git a/packages/menu-surface/src/ambient.d.ts b/packages/menu-surface/src/lib/ambient.d.ts similarity index 100% rename from packages/menu-surface/src/ambient.d.ts rename to packages/menu-surface/src/lib/ambient.d.ts diff --git a/packages/menu-surface/src/index.ts b/packages/menu-surface/src/lib/index.ts similarity index 100% rename from packages/menu-surface/src/index.ts rename to packages/menu-surface/src/lib/index.ts diff --git a/packages/menu-surface/svelte.config.js b/packages/menu-surface/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/menu-surface/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/menu/package.json b/packages/menu/package.json index 97de233ea..e239bd2d4 100644 --- a/packages/menu/package.json +++ b/packages/menu/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Menu", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -50,7 +49,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/menu/src/Menu.svelte b/packages/menu/src/lib/Menu.svelte similarity index 100% rename from packages/menu/src/Menu.svelte rename to packages/menu/src/lib/Menu.svelte diff --git a/packages/menu/src/Menu.types.ts b/packages/menu/src/lib/Menu.types.ts similarity index 100% rename from packages/menu/src/Menu.types.ts rename to packages/menu/src/lib/Menu.types.ts diff --git a/packages/menu/src/SelectionGroup.svelte b/packages/menu/src/lib/SelectionGroup.svelte similarity index 100% rename from packages/menu/src/SelectionGroup.svelte rename to packages/menu/src/lib/SelectionGroup.svelte diff --git a/packages/menu/src/SelectionGroupIcon.ts b/packages/menu/src/lib/SelectionGroupIcon.ts similarity index 100% rename from packages/menu/src/SelectionGroupIcon.ts rename to packages/menu/src/lib/SelectionGroupIcon.ts diff --git a/packages/menu/src/ambient.d.ts b/packages/menu/src/lib/ambient.d.ts similarity index 100% rename from packages/menu/src/ambient.d.ts rename to packages/menu/src/lib/ambient.d.ts diff --git a/packages/menu/src/index.ts b/packages/menu/src/lib/index.ts similarity index 100% rename from packages/menu/src/index.ts rename to packages/menu/src/lib/index.ts diff --git a/packages/menu/svelte.config.js b/packages/menu/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/menu/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/notched-outline/package.json b/packages/notched-outline/package.json index 437e6802e..3d31ac4f2 100644 --- a/packages/notched-outline/package.json +++ b/packages/notched-outline/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Notched Outline", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -48,7 +47,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/notched-outline/src/NotchedOutline.svelte b/packages/notched-outline/src/lib/NotchedOutline.svelte similarity index 100% rename from packages/notched-outline/src/NotchedOutline.svelte rename to packages/notched-outline/src/lib/NotchedOutline.svelte diff --git a/packages/notched-outline/src/ambient.d.ts b/packages/notched-outline/src/lib/ambient.d.ts similarity index 100% rename from packages/notched-outline/src/ambient.d.ts rename to packages/notched-outline/src/lib/ambient.d.ts diff --git a/packages/notched-outline/src/index.ts b/packages/notched-outline/src/lib/index.ts similarity index 100% rename from packages/notched-outline/src/index.ts rename to packages/notched-outline/src/lib/index.ts diff --git a/packages/notched-outline/svelte.config.js b/packages/notched-outline/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/notched-outline/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/paper/package.json b/packages/paper/package.json index 5d80f756a..a255a07c7 100644 --- a/packages/paper/package.json +++ b/packages/paper/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Paper", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -51,7 +50,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/paper/src/Content.ts b/packages/paper/src/lib/Content.ts similarity index 100% rename from packages/paper/src/Content.ts rename to packages/paper/src/lib/Content.ts diff --git a/packages/paper/src/Paper.svelte b/packages/paper/src/lib/Paper.svelte similarity index 100% rename from packages/paper/src/Paper.svelte rename to packages/paper/src/lib/Paper.svelte diff --git a/packages/paper/src/Subtitle.ts b/packages/paper/src/lib/Subtitle.ts similarity index 100% rename from packages/paper/src/Subtitle.ts rename to packages/paper/src/lib/Subtitle.ts diff --git a/packages/paper/src/Title.ts b/packages/paper/src/lib/Title.ts similarity index 100% rename from packages/paper/src/Title.ts rename to packages/paper/src/lib/Title.ts diff --git a/packages/paper/src/ambient.d.ts b/packages/paper/src/lib/ambient.d.ts similarity index 100% rename from packages/paper/src/ambient.d.ts rename to packages/paper/src/lib/ambient.d.ts diff --git a/packages/paper/src/index.ts b/packages/paper/src/lib/index.ts similarity index 100% rename from packages/paper/src/index.ts rename to packages/paper/src/lib/index.ts diff --git a/packages/paper/svelte.config.js b/packages/paper/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/paper/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/radio/package.json b/packages/radio/package.json index bbb947ece..f213f37a9 100644 --- a/packages/radio/package.json +++ b/packages/radio/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Radio", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -48,7 +47,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/radio/src/Radio.svelte b/packages/radio/src/lib/Radio.svelte similarity index 100% rename from packages/radio/src/Radio.svelte rename to packages/radio/src/lib/Radio.svelte diff --git a/packages/radio/src/ambient.d.ts b/packages/radio/src/lib/ambient.d.ts similarity index 100% rename from packages/radio/src/ambient.d.ts rename to packages/radio/src/lib/ambient.d.ts diff --git a/packages/radio/src/index.ts b/packages/radio/src/lib/index.ts similarity index 100% rename from packages/radio/src/index.ts rename to packages/radio/src/lib/index.ts diff --git a/packages/radio/svelte.config.js b/packages/radio/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/radio/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/ripple/package.json b/packages/ripple/package.json index 843f53a59..b1494fe44 100644 --- a/packages/ripple/package.json +++ b/packages/ripple/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Ripple", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -48,7 +47,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/ripple/src/Ripple.ts b/packages/ripple/src/lib/Ripple.ts similarity index 100% rename from packages/ripple/src/Ripple.ts rename to packages/ripple/src/lib/Ripple.ts diff --git a/packages/ripple/src/ambient.d.ts b/packages/ripple/src/lib/ambient.d.ts similarity index 100% rename from packages/ripple/src/ambient.d.ts rename to packages/ripple/src/lib/ambient.d.ts diff --git a/packages/ripple/src/index.ts b/packages/ripple/src/lib/index.ts similarity index 100% rename from packages/ripple/src/index.ts rename to packages/ripple/src/lib/index.ts diff --git a/packages/ripple/svelte.config.js b/packages/ripple/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/ripple/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/segmented-button/package.json b/packages/segmented-button/package.json index 40e18419c..62577f0a9 100644 --- a/packages/segmented-button/package.json +++ b/packages/segmented-button/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Segmented Button", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -48,7 +47,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/segmented-button/src/Segment.svelte b/packages/segmented-button/src/lib/Segment.svelte similarity index 100% rename from packages/segmented-button/src/Segment.svelte rename to packages/segmented-button/src/lib/Segment.svelte diff --git a/packages/segmented-button/src/Segment.types.ts b/packages/segmented-button/src/lib/Segment.types.ts similarity index 100% rename from packages/segmented-button/src/Segment.types.ts rename to packages/segmented-button/src/lib/Segment.types.ts diff --git a/packages/segmented-button/src/SegmentedButton.svelte b/packages/segmented-button/src/lib/SegmentedButton.svelte similarity index 100% rename from packages/segmented-button/src/SegmentedButton.svelte rename to packages/segmented-button/src/lib/SegmentedButton.svelte diff --git a/packages/segmented-button/src/ambient.d.ts b/packages/segmented-button/src/lib/ambient.d.ts similarity index 100% rename from packages/segmented-button/src/ambient.d.ts rename to packages/segmented-button/src/lib/ambient.d.ts diff --git a/packages/segmented-button/src/index.ts b/packages/segmented-button/src/lib/index.ts similarity index 100% rename from packages/segmented-button/src/index.ts rename to packages/segmented-button/src/lib/index.ts diff --git a/packages/segmented-button/svelte.config.js b/packages/segmented-button/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/segmented-button/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/select/helper-text/index.js b/packages/select/helper-text/index.js index fface2e7b..8ecde6c5b 100644 --- a/packages/select/helper-text/index.js +++ b/packages/select/helper-text/index.js @@ -1,3 +1,3 @@ -export * from '../dist/helper-text/index.js'; -import defaultExport from '../dist/helper-text/index.js'; +export * from '../package/helper-text/index.js'; +import defaultExport from '../package/helper-text/index.js'; export default defaultExport; diff --git a/packages/select/icon/index.js b/packages/select/icon/index.js index b088eaef7..de0490047 100644 --- a/packages/select/icon/index.js +++ b/packages/select/icon/index.js @@ -1,3 +1,3 @@ -export * from '../dist/icon/index.js'; -import defaultExport from '../dist/icon/index.js'; +export * from '../package/icon/index.js'; +import defaultExport from '../package/icon/index.js'; export default defaultExport; diff --git a/packages/select/index.js b/packages/select/index.js index a2ea4c8c5..652611ae1 100644 --- a/packages/select/index.js +++ b/packages/select/index.js @@ -1,3 +1,3 @@ -export * from './dist/index.js'; -import defaultExport from './dist/index.js'; +export * from './package/index.js'; +import defaultExport from './package/index.js'; export default defaultExport; diff --git a/packages/select/package.json b/packages/select/package.json index 4f0aed653..86621f80b 100644 --- a/packages/select/package.json +++ b/packages/select/package.json @@ -3,23 +3,23 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Select", "type": "module", - "svelte": "./dist/index.js", + "svelte": "./package/index.js", "exports": { "./package.json": "./package.json", - ".": "./dist/index.js", - "./helper-text": "./dist/helper-text/index.js", - "./icon": "./dist/icon/index.js" + ".": "./package/index.js", + "./helper-text": "./package/helper-text/index.js", + "./icon": "./package/icon/index.js" }, "typesVersions": { "*": { "*": [ - "./src/*" + "./package/*" ], "helper-text": [ - "./src/helper-text/index.ts" + "./package/helper-text/index.d.ts" ], "icon": [ - "./src/icon/index.ts" + "./package/icon/index.d.ts" ] } }, @@ -33,12 +33,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css && sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules helper-text/_style.scss helper-text/bare.css && sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules icon/_style.scss icon/bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -74,7 +73,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/select/src/HelperFragment.svelte b/packages/select/src/lib/HelperFragment.svelte similarity index 100% rename from packages/select/src/HelperFragment.svelte rename to packages/select/src/lib/HelperFragment.svelte diff --git a/packages/select/src/Option.svelte b/packages/select/src/lib/Option.svelte similarity index 100% rename from packages/select/src/Option.svelte rename to packages/select/src/lib/Option.svelte diff --git a/packages/select/src/Option.types.ts b/packages/select/src/lib/Option.types.ts similarity index 100% rename from packages/select/src/Option.types.ts rename to packages/select/src/lib/Option.types.ts diff --git a/packages/select/src/Select.svelte b/packages/select/src/lib/Select.svelte similarity index 100% rename from packages/select/src/Select.svelte rename to packages/select/src/lib/Select.svelte diff --git a/packages/select/src/ambient.d.ts b/packages/select/src/lib/ambient.d.ts similarity index 100% rename from packages/select/src/ambient.d.ts rename to packages/select/src/lib/ambient.d.ts diff --git a/packages/select/src/helper-text/HelperText.svelte b/packages/select/src/lib/helper-text/HelperText.svelte similarity index 100% rename from packages/select/src/helper-text/HelperText.svelte rename to packages/select/src/lib/helper-text/HelperText.svelte diff --git a/packages/select/src/helper-text/index.ts b/packages/select/src/lib/helper-text/index.ts similarity index 100% rename from packages/select/src/helper-text/index.ts rename to packages/select/src/lib/helper-text/index.ts diff --git a/packages/select/src/icon/Icon.svelte b/packages/select/src/lib/icon/Icon.svelte similarity index 100% rename from packages/select/src/icon/Icon.svelte rename to packages/select/src/lib/icon/Icon.svelte diff --git a/packages/select/src/icon/index.ts b/packages/select/src/lib/icon/index.ts similarity index 100% rename from packages/select/src/icon/index.ts rename to packages/select/src/lib/icon/index.ts diff --git a/packages/select/src/index.ts b/packages/select/src/lib/index.ts similarity index 100% rename from packages/select/src/index.ts rename to packages/select/src/lib/index.ts diff --git a/packages/select/svelte.config.js b/packages/select/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/select/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/site/svelte.config.js b/packages/site/svelte.config.js index 54a302172..5febe9121 100644 --- a/packages/site/svelte.config.js +++ b/packages/site/svelte.config.js @@ -31,8 +31,6 @@ const config = { kit: { adapter: staticAdapter(), - - trailingSlash: 'ignore', }, }; diff --git a/packages/site/tsconfig.json b/packages/site/tsconfig.json index 9ed1ea4df..b6786faa5 100644 --- a/packages/site/tsconfig.json +++ b/packages/site/tsconfig.json @@ -24,52 +24,49 @@ "src/**/*.js", "src/**/*.ts", "src/**/*.svelte", - "src/**/*.js", - "src/**/*.ts", - "src/**/*.svelte", "tests/**/*.js", "tests/**/*.ts", "tests/**/*.svelte", - "../accordion/src/ambient.d.ts", - "../autocomplete/src/ambient.d.ts", - "../badge/src/ambient.d.ts", - "../banner/src/ambient.d.ts", - "../button/src/ambient.d.ts", - "../card/src/ambient.d.ts", - "../checkbox/src/ambient.d.ts", - "../chips/src/ambient.d.ts", - "../circular-progress/src/ambient.d.ts", - "../common/src/ambient.d.ts", - "../data-table/src/ambient.d.ts", - "../dialog/src/ambient.d.ts", - "../drawer/src/ambient.d.ts", - "../fab/src/ambient.d.ts", - "../floating-label/src/ambient.d.ts", - "../form-field/src/ambient.d.ts", - "../icon-button/src/ambient.d.ts", - "../image-list/src/ambient.d.ts", - "../layout-grid/src/ambient.d.ts", - "../linear-progress/src/ambient.d.ts", - "../line-ripple/src/ambient.d.ts", - "../list/src/ambient.d.ts", - "../menu/src/ambient.d.ts", - "../menu-surface/src/ambient.d.ts", - "../notched-outline/src/ambient.d.ts", - "../paper/src/ambient.d.ts", - "../radio/src/ambient.d.ts", - "../ripple/src/ambient.d.ts", - "../segmented-button/src/ambient.d.ts", - "../select/src/ambient.d.ts", - "../slider/src/ambient.d.ts", - "../snackbar/src/ambient.d.ts", - "../switch/src/ambient.d.ts", - "../tab/src/ambient.d.ts", - "../tab-bar/src/ambient.d.ts", - "../tab-indicator/src/ambient.d.ts", - "../tab-scroller/src/ambient.d.ts", - "../textfield/src/ambient.d.ts", - "../tooltip/src/ambient.d.ts", - "../top-app-bar/src/ambient.d.ts", - "../touch-target/src/ambient.d.ts" + "../accordion/src/lib/ambient.d.ts", + "../autocomplete/src/lib/ambient.d.ts", + "../badge/src/lib/ambient.d.ts", + "../banner/src/lib/ambient.d.ts", + "../button/src/lib/ambient.d.ts", + "../card/src/lib/ambient.d.ts", + "../checkbox/src/lib/ambient.d.ts", + "../chips/src/lib/ambient.d.ts", + "../circular-progress/src/lib/ambient.d.ts", + "../common/src/lib/ambient.d.ts", + "../data-table/src/lib/ambient.d.ts", + "../dialog/src/lib/ambient.d.ts", + "../drawer/src/lib/ambient.d.ts", + "../fab/src/lib/ambient.d.ts", + "../floating-label/src/lib/ambient.d.ts", + "../form-field/src/lib/ambient.d.ts", + "../icon-button/src/lib/ambient.d.ts", + "../image-list/src/lib/ambient.d.ts", + "../layout-grid/src/lib/ambient.d.ts", + "../linear-progress/src/lib/ambient.d.ts", + "../line-ripple/src/lib/ambient.d.ts", + "../list/src/lib/ambient.d.ts", + "../menu/src/lib/ambient.d.ts", + "../menu-surface/src/lib/ambient.d.ts", + "../notched-outline/src/lib/ambient.d.ts", + "../paper/src/lib/ambient.d.ts", + "../radio/src/lib/ambient.d.ts", + "../ripple/src/lib/ambient.d.ts", + "../segmented-button/src/lib/ambient.d.ts", + "../select/src/lib/ambient.d.ts", + "../slider/src/lib/ambient.d.ts", + "../snackbar/src/lib/ambient.d.ts", + "../switch/src/lib/ambient.d.ts", + "../tab/src/lib/ambient.d.ts", + "../tab-bar/src/lib/ambient.d.ts", + "../tab-indicator/src/lib/ambient.d.ts", + "../tab-scroller/src/lib/ambient.d.ts", + "../textfield/src/lib/ambient.d.ts", + "../tooltip/src/lib/ambient.d.ts", + "../top-app-bar/src/lib/ambient.d.ts", + "../touch-target/src/lib/ambient.d.ts" ] } diff --git a/packages/slider/package.json b/packages/slider/package.json index d84fcde18..3504ecad3 100644 --- a/packages/slider/package.json +++ b/packages/slider/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Slider", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -49,7 +48,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/slider/src/Slider.svelte b/packages/slider/src/lib/Slider.svelte similarity index 100% rename from packages/slider/src/Slider.svelte rename to packages/slider/src/lib/Slider.svelte diff --git a/packages/slider/src/Slider.types.ts b/packages/slider/src/lib/Slider.types.ts similarity index 100% rename from packages/slider/src/Slider.types.ts rename to packages/slider/src/lib/Slider.types.ts diff --git a/packages/slider/src/ambient.d.ts b/packages/slider/src/lib/ambient.d.ts similarity index 100% rename from packages/slider/src/ambient.d.ts rename to packages/slider/src/lib/ambient.d.ts diff --git a/packages/slider/src/index.ts b/packages/slider/src/lib/index.ts similarity index 100% rename from packages/slider/src/index.ts rename to packages/slider/src/lib/index.ts diff --git a/packages/slider/svelte.config.js b/packages/slider/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/slider/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/snackbar/index.js b/packages/snackbar/index.js index a2ea4c8c5..652611ae1 100644 --- a/packages/snackbar/index.js +++ b/packages/snackbar/index.js @@ -1,3 +1,3 @@ -export * from './dist/index.js'; -import defaultExport from './dist/index.js'; +export * from './package/index.js'; +import defaultExport from './package/index.js'; export default defaultExport; diff --git a/packages/snackbar/kitchen/index.js b/packages/snackbar/kitchen/index.js index 2a358a5e6..ae5bd2760 100644 --- a/packages/snackbar/kitchen/index.js +++ b/packages/snackbar/kitchen/index.js @@ -1,3 +1,3 @@ -export * from '../dist/kitchen/index.js'; -import defaultExport from '../dist/kitchen/index.js'; +export * from '../package/kitchen/index.js'; +import defaultExport from '../package/kitchen/index.js'; export default defaultExport; diff --git a/packages/snackbar/package.json b/packages/snackbar/package.json index 317cfa375..273d8026f 100644 --- a/packages/snackbar/package.json +++ b/packages/snackbar/package.json @@ -3,19 +3,19 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Snackbar", "type": "module", - "svelte": "./dist/index.js", + "svelte": "./package/index.js", "exports": { "./package.json": "./package.json", - ".": "./dist/index.js", - "./kitchen": "./dist/kitchen/index.js" + ".": "./package/index.js", + "./kitchen": "./package/kitchen/index.js" }, "typesVersions": { "*": { "*": [ - "./src/*" + "./package/*" ], "kitchen": [ - "./src/kitchen/index.ts" + "./package/kitchen/index.d.ts" ] } }, @@ -29,12 +29,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css && sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules kitchen/_style.scss kitchen/bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -64,7 +63,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/snackbar/src/Actions.ts b/packages/snackbar/src/lib/Actions.ts similarity index 100% rename from packages/snackbar/src/Actions.ts rename to packages/snackbar/src/lib/Actions.ts diff --git a/packages/snackbar/src/Snackbar.svelte b/packages/snackbar/src/lib/Snackbar.svelte similarity index 100% rename from packages/snackbar/src/Snackbar.svelte rename to packages/snackbar/src/lib/Snackbar.svelte diff --git a/packages/snackbar/src/ambient.d.ts b/packages/snackbar/src/lib/ambient.d.ts similarity index 100% rename from packages/snackbar/src/ambient.d.ts rename to packages/snackbar/src/lib/ambient.d.ts diff --git a/packages/snackbar/src/index.ts b/packages/snackbar/src/lib/index.ts similarity index 100% rename from packages/snackbar/src/index.ts rename to packages/snackbar/src/lib/index.ts diff --git a/packages/snackbar/src/kitchen/Kitchen.svelte b/packages/snackbar/src/lib/kitchen/Kitchen.svelte similarity index 100% rename from packages/snackbar/src/kitchen/Kitchen.svelte rename to packages/snackbar/src/lib/kitchen/Kitchen.svelte diff --git a/packages/snackbar/src/kitchen/Kitchen.types.ts b/packages/snackbar/src/lib/kitchen/Kitchen.types.ts similarity index 100% rename from packages/snackbar/src/kitchen/Kitchen.types.ts rename to packages/snackbar/src/lib/kitchen/Kitchen.types.ts diff --git a/packages/snackbar/src/kitchen/index.ts b/packages/snackbar/src/lib/kitchen/index.ts similarity index 100% rename from packages/snackbar/src/kitchen/index.ts rename to packages/snackbar/src/lib/kitchen/index.ts diff --git a/packages/snackbar/svelte.config.js b/packages/snackbar/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/snackbar/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/switch/package.json b/packages/switch/package.json index cbdf98fb2..ffb7d3035 100644 --- a/packages/switch/package.json +++ b/packages/switch/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Switch", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -50,7 +49,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/switch/src/Switch.svelte b/packages/switch/src/lib/Switch.svelte similarity index 100% rename from packages/switch/src/Switch.svelte rename to packages/switch/src/lib/Switch.svelte diff --git a/packages/switch/src/ambient.d.ts b/packages/switch/src/lib/ambient.d.ts similarity index 100% rename from packages/switch/src/ambient.d.ts rename to packages/switch/src/lib/ambient.d.ts diff --git a/packages/switch/src/index.ts b/packages/switch/src/lib/index.ts similarity index 100% rename from packages/switch/src/index.ts rename to packages/switch/src/lib/index.ts diff --git a/packages/switch/svelte.config.js b/packages/switch/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/switch/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/tab-bar/package.json b/packages/tab-bar/package.json index 9a53ff0ee..0e31a5d82 100644 --- a/packages/tab-bar/package.json +++ b/packages/tab-bar/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Tab Bar", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -49,7 +48,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/tab-bar/src/TabBar.svelte b/packages/tab-bar/src/lib/TabBar.svelte similarity index 100% rename from packages/tab-bar/src/TabBar.svelte rename to packages/tab-bar/src/lib/TabBar.svelte diff --git a/packages/tab-bar/src/ambient.d.ts b/packages/tab-bar/src/lib/ambient.d.ts similarity index 100% rename from packages/tab-bar/src/ambient.d.ts rename to packages/tab-bar/src/lib/ambient.d.ts diff --git a/packages/tab-bar/src/index.ts b/packages/tab-bar/src/lib/index.ts similarity index 100% rename from packages/tab-bar/src/index.ts rename to packages/tab-bar/src/lib/index.ts diff --git a/packages/tab-bar/svelte.config.js b/packages/tab-bar/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/tab-bar/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/tab-indicator/package.json b/packages/tab-indicator/package.json index bdb3719cd..44843f12a 100644 --- a/packages/tab-indicator/package.json +++ b/packages/tab-indicator/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Tab Indicator", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -47,7 +46,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/tab-indicator/src/TabIndicator.svelte b/packages/tab-indicator/src/lib/TabIndicator.svelte similarity index 100% rename from packages/tab-indicator/src/TabIndicator.svelte rename to packages/tab-indicator/src/lib/TabIndicator.svelte diff --git a/packages/tab-indicator/src/ambient.d.ts b/packages/tab-indicator/src/lib/ambient.d.ts similarity index 100% rename from packages/tab-indicator/src/ambient.d.ts rename to packages/tab-indicator/src/lib/ambient.d.ts diff --git a/packages/tab-indicator/src/index.ts b/packages/tab-indicator/src/lib/index.ts similarity index 100% rename from packages/tab-indicator/src/index.ts rename to packages/tab-indicator/src/lib/index.ts diff --git a/packages/tab-indicator/svelte.config.js b/packages/tab-indicator/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/tab-indicator/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/tab-scroller/package.json b/packages/tab-scroller/package.json index cd767490c..e6d9431f7 100644 --- a/packages/tab-scroller/package.json +++ b/packages/tab-scroller/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Tab Scroller", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -48,7 +47,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/tab-scroller/src/TabScroller.svelte b/packages/tab-scroller/src/lib/TabScroller.svelte similarity index 100% rename from packages/tab-scroller/src/TabScroller.svelte rename to packages/tab-scroller/src/lib/TabScroller.svelte diff --git a/packages/tab-scroller/src/ambient.d.ts b/packages/tab-scroller/src/lib/ambient.d.ts similarity index 100% rename from packages/tab-scroller/src/ambient.d.ts rename to packages/tab-scroller/src/lib/ambient.d.ts diff --git a/packages/tab-scroller/src/index.ts b/packages/tab-scroller/src/lib/index.ts similarity index 100% rename from packages/tab-scroller/src/index.ts rename to packages/tab-scroller/src/lib/index.ts diff --git a/packages/tab-scroller/svelte.config.js b/packages/tab-scroller/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/tab-scroller/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/tab/package.json b/packages/tab/package.json index f6b836b74..e17e1034d 100644 --- a/packages/tab/package.json +++ b/packages/tab/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Tab", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -49,7 +48,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/tab/src/Tab.svelte b/packages/tab/src/lib/Tab.svelte similarity index 100% rename from packages/tab/src/Tab.svelte rename to packages/tab/src/lib/Tab.svelte diff --git a/packages/tab/src/Tab.types.ts b/packages/tab/src/lib/Tab.types.ts similarity index 100% rename from packages/tab/src/Tab.types.ts rename to packages/tab/src/lib/Tab.types.ts diff --git a/packages/tab/src/ambient.d.ts b/packages/tab/src/lib/ambient.d.ts similarity index 100% rename from packages/tab/src/ambient.d.ts rename to packages/tab/src/lib/ambient.d.ts diff --git a/packages/tab/src/index.ts b/packages/tab/src/lib/index.ts similarity index 100% rename from packages/tab/src/index.ts rename to packages/tab/src/lib/index.ts diff --git a/packages/tab/svelte.config.js b/packages/tab/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/tab/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/textfield/character-counter/index.js b/packages/textfield/character-counter/index.js index 8526a10c6..483d747c8 100644 --- a/packages/textfield/character-counter/index.js +++ b/packages/textfield/character-counter/index.js @@ -1,3 +1,3 @@ -export * from '../dist/character-counter/index.js'; -import defaultExport from '../dist/character-counter/index.js'; +export * from '../package/character-counter/index.js'; +import defaultExport from '../package/character-counter/index.js'; export default defaultExport; diff --git a/packages/textfield/helper-text/index.js b/packages/textfield/helper-text/index.js index fface2e7b..8ecde6c5b 100644 --- a/packages/textfield/helper-text/index.js +++ b/packages/textfield/helper-text/index.js @@ -1,3 +1,3 @@ -export * from '../dist/helper-text/index.js'; -import defaultExport from '../dist/helper-text/index.js'; +export * from '../package/helper-text/index.js'; +import defaultExport from '../package/helper-text/index.js'; export default defaultExport; diff --git a/packages/textfield/icon/index.js b/packages/textfield/icon/index.js index b088eaef7..de0490047 100644 --- a/packages/textfield/icon/index.js +++ b/packages/textfield/icon/index.js @@ -1,3 +1,3 @@ -export * from '../dist/icon/index.js'; -import defaultExport from '../dist/icon/index.js'; +export * from '../package/icon/index.js'; +import defaultExport from '../package/icon/index.js'; export default defaultExport; diff --git a/packages/textfield/index.js b/packages/textfield/index.js index a2ea4c8c5..652611ae1 100644 --- a/packages/textfield/index.js +++ b/packages/textfield/index.js @@ -1,3 +1,3 @@ -export * from './dist/index.js'; -import defaultExport from './dist/index.js'; +export * from './package/index.js'; +import defaultExport from './package/index.js'; export default defaultExport; diff --git a/packages/textfield/package.json b/packages/textfield/package.json index b8025db6e..0c962604d 100644 --- a/packages/textfield/package.json +++ b/packages/textfield/package.json @@ -3,27 +3,27 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Text Field", "type": "module", - "svelte": "./dist/index.js", + "svelte": "./package/index.js", "exports": { "./package.json": "./package.json", - ".": "./dist/index.js", - "./character-counter": "./dist/character-counter/index.js", - "./helper-text": "./dist/helper-text/index.js", - "./icon": "./dist/icon/index.js" + ".": "./package/index.js", + "./character-counter": "./package/character-counter/index.js", + "./helper-text": "./package/helper-text/index.js", + "./icon": "./package/icon/index.js" }, "typesVersions": { "*": { "*": [ - "./src/*" + "./package/*" ], "character-counter": [ - "./src/character-counter/index.ts" + "./package/character-counter/index.d.ts" ], "helper-text": [ - "./src/helper-text/index.ts" + "./package/helper-text/index.d.ts" ], "icon": [ - "./src/icon/index.ts" + "./package/icon/index.d.ts" ] } }, @@ -37,12 +37,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css && sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules character-counter/_style.scss character-counter/bare.css && sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules helper-text/_style.scss helper-text/bare.css && sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules icon/_style.scss icon/bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -75,7 +74,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/textfield/src/HelperLine.ts b/packages/textfield/src/lib/HelperLine.ts similarity index 100% rename from packages/textfield/src/HelperLine.ts rename to packages/textfield/src/lib/HelperLine.ts diff --git a/packages/textfield/src/Input.svelte b/packages/textfield/src/lib/Input.svelte similarity index 100% rename from packages/textfield/src/Input.svelte rename to packages/textfield/src/lib/Input.svelte diff --git a/packages/textfield/src/Prefix.ts b/packages/textfield/src/lib/Prefix.ts similarity index 100% rename from packages/textfield/src/Prefix.ts rename to packages/textfield/src/lib/Prefix.ts diff --git a/packages/textfield/src/Suffix.ts b/packages/textfield/src/lib/Suffix.ts similarity index 100% rename from packages/textfield/src/Suffix.ts rename to packages/textfield/src/lib/Suffix.ts diff --git a/packages/textfield/src/Textarea.svelte b/packages/textfield/src/lib/Textarea.svelte similarity index 100% rename from packages/textfield/src/Textarea.svelte rename to packages/textfield/src/lib/Textarea.svelte diff --git a/packages/textfield/src/Textfield.svelte b/packages/textfield/src/lib/Textfield.svelte similarity index 100% rename from packages/textfield/src/Textfield.svelte rename to packages/textfield/src/lib/Textfield.svelte diff --git a/packages/textfield/src/ambient.d.ts b/packages/textfield/src/lib/ambient.d.ts similarity index 100% rename from packages/textfield/src/ambient.d.ts rename to packages/textfield/src/lib/ambient.d.ts diff --git a/packages/textfield/src/character-counter/CharacterCounter.svelte b/packages/textfield/src/lib/character-counter/CharacterCounter.svelte similarity index 100% rename from packages/textfield/src/character-counter/CharacterCounter.svelte rename to packages/textfield/src/lib/character-counter/CharacterCounter.svelte diff --git a/packages/textfield/src/character-counter/index.ts b/packages/textfield/src/lib/character-counter/index.ts similarity index 100% rename from packages/textfield/src/character-counter/index.ts rename to packages/textfield/src/lib/character-counter/index.ts diff --git a/packages/textfield/src/helper-text/HelperText.svelte b/packages/textfield/src/lib/helper-text/HelperText.svelte similarity index 100% rename from packages/textfield/src/helper-text/HelperText.svelte rename to packages/textfield/src/lib/helper-text/HelperText.svelte diff --git a/packages/textfield/src/helper-text/index.ts b/packages/textfield/src/lib/helper-text/index.ts similarity index 100% rename from packages/textfield/src/helper-text/index.ts rename to packages/textfield/src/lib/helper-text/index.ts diff --git a/packages/textfield/src/icon/Icon.svelte b/packages/textfield/src/lib/icon/Icon.svelte similarity index 100% rename from packages/textfield/src/icon/Icon.svelte rename to packages/textfield/src/lib/icon/Icon.svelte diff --git a/packages/textfield/src/icon/index.ts b/packages/textfield/src/lib/icon/index.ts similarity index 100% rename from packages/textfield/src/icon/index.ts rename to packages/textfield/src/lib/icon/index.ts diff --git a/packages/textfield/src/index.ts b/packages/textfield/src/lib/index.ts similarity index 100% rename from packages/textfield/src/index.ts rename to packages/textfield/src/lib/index.ts diff --git a/packages/textfield/svelte.config.js b/packages/textfield/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/textfield/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/tooltip/package.json b/packages/tooltip/package.json index c30325078..8df7fa35c 100644 --- a/packages/tooltip/package.json +++ b/packages/tooltip/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Tooltip", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -47,7 +46,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/tooltip/src/Content.ts b/packages/tooltip/src/lib/Content.ts similarity index 100% rename from packages/tooltip/src/Content.ts rename to packages/tooltip/src/lib/Content.ts diff --git a/packages/tooltip/src/Link.ts b/packages/tooltip/src/lib/Link.ts similarity index 100% rename from packages/tooltip/src/Link.ts rename to packages/tooltip/src/lib/Link.ts diff --git a/packages/tooltip/src/RichActions.ts b/packages/tooltip/src/lib/RichActions.ts similarity index 100% rename from packages/tooltip/src/RichActions.ts rename to packages/tooltip/src/lib/RichActions.ts diff --git a/packages/tooltip/src/Title.ts b/packages/tooltip/src/lib/Title.ts similarity index 100% rename from packages/tooltip/src/Title.ts rename to packages/tooltip/src/lib/Title.ts diff --git a/packages/tooltip/src/Tooltip.svelte b/packages/tooltip/src/lib/Tooltip.svelte similarity index 100% rename from packages/tooltip/src/Tooltip.svelte rename to packages/tooltip/src/lib/Tooltip.svelte diff --git a/packages/tooltip/src/Wrapper.svelte b/packages/tooltip/src/lib/Wrapper.svelte similarity index 100% rename from packages/tooltip/src/Wrapper.svelte rename to packages/tooltip/src/lib/Wrapper.svelte diff --git a/packages/tooltip/src/ambient.d.ts b/packages/tooltip/src/lib/ambient.d.ts similarity index 100% rename from packages/tooltip/src/ambient.d.ts rename to packages/tooltip/src/lib/ambient.d.ts diff --git a/packages/tooltip/src/index.ts b/packages/tooltip/src/lib/index.ts similarity index 100% rename from packages/tooltip/src/index.ts rename to packages/tooltip/src/lib/index.ts diff --git a/packages/tooltip/svelte.config.js b/packages/tooltip/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/tooltip/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/top-app-bar/package.json b/packages/top-app-bar/package.json index f9d09213f..061fcdd35 100644 --- a/packages/top-app-bar/package.json +++ b/packages/top-app-bar/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Top App Bar", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -48,7 +47,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/top-app-bar/src/AutoAdjust.svelte b/packages/top-app-bar/src/lib/AutoAdjust.svelte similarity index 100% rename from packages/top-app-bar/src/AutoAdjust.svelte rename to packages/top-app-bar/src/lib/AutoAdjust.svelte diff --git a/packages/top-app-bar/src/DenseFixedAdjust.ts b/packages/top-app-bar/src/lib/DenseFixedAdjust.ts similarity index 100% rename from packages/top-app-bar/src/DenseFixedAdjust.ts rename to packages/top-app-bar/src/lib/DenseFixedAdjust.ts diff --git a/packages/top-app-bar/src/DenseProminentFixedAdjust.ts b/packages/top-app-bar/src/lib/DenseProminentFixedAdjust.ts similarity index 100% rename from packages/top-app-bar/src/DenseProminentFixedAdjust.ts rename to packages/top-app-bar/src/lib/DenseProminentFixedAdjust.ts diff --git a/packages/top-app-bar/src/FixedAdjust.ts b/packages/top-app-bar/src/lib/FixedAdjust.ts similarity index 100% rename from packages/top-app-bar/src/FixedAdjust.ts rename to packages/top-app-bar/src/lib/FixedAdjust.ts diff --git a/packages/top-app-bar/src/ProminentFixedAdjust.ts b/packages/top-app-bar/src/lib/ProminentFixedAdjust.ts similarity index 100% rename from packages/top-app-bar/src/ProminentFixedAdjust.ts rename to packages/top-app-bar/src/lib/ProminentFixedAdjust.ts diff --git a/packages/top-app-bar/src/Row.ts b/packages/top-app-bar/src/lib/Row.ts similarity index 100% rename from packages/top-app-bar/src/Row.ts rename to packages/top-app-bar/src/lib/Row.ts diff --git a/packages/top-app-bar/src/Section.svelte b/packages/top-app-bar/src/lib/Section.svelte similarity index 100% rename from packages/top-app-bar/src/Section.svelte rename to packages/top-app-bar/src/lib/Section.svelte diff --git a/packages/top-app-bar/src/ShortFixedAdjust.ts b/packages/top-app-bar/src/lib/ShortFixedAdjust.ts similarity index 100% rename from packages/top-app-bar/src/ShortFixedAdjust.ts rename to packages/top-app-bar/src/lib/ShortFixedAdjust.ts diff --git a/packages/top-app-bar/src/Title.ts b/packages/top-app-bar/src/lib/Title.ts similarity index 100% rename from packages/top-app-bar/src/Title.ts rename to packages/top-app-bar/src/lib/Title.ts diff --git a/packages/top-app-bar/src/TopAppBar.svelte b/packages/top-app-bar/src/lib/TopAppBar.svelte similarity index 100% rename from packages/top-app-bar/src/TopAppBar.svelte rename to packages/top-app-bar/src/lib/TopAppBar.svelte diff --git a/packages/top-app-bar/src/ambient.d.ts b/packages/top-app-bar/src/lib/ambient.d.ts similarity index 100% rename from packages/top-app-bar/src/ambient.d.ts rename to packages/top-app-bar/src/lib/ambient.d.ts diff --git a/packages/top-app-bar/src/index.ts b/packages/top-app-bar/src/lib/index.ts similarity index 100% rename from packages/top-app-bar/src/index.ts rename to packages/top-app-bar/src/lib/index.ts diff --git a/packages/top-app-bar/svelte.config.js b/packages/top-app-bar/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/top-app-bar/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config; diff --git a/packages/touch-target/package.json b/packages/touch-target/package.json index 977e69068..668aa2c89 100644 --- a/packages/touch-target/package.json +++ b/packages/touch-target/package.json @@ -3,10 +3,10 @@ "version": "7.0.0-beta.0", "description": "Svelte Material UI - Touch Target", "type": "module", - "main": "dist/index.js", - "module": "dist/index.js", - "svelte": "dist/index.js", - "types": "src/index.ts", + "main": "package/index.js", + "module": "package/index.js", + "svelte": "package/index.js", + "types": "package/index.d.ts", "keywords": [ "svelte", "svelte3", @@ -17,12 +17,11 @@ "sveltejs" ], "scripts": { - "build": "npm run build:js && npm run build:svelte && npm run build:sass", - "build:js": "tsc -p . --outDir dist/ --rootDir src/", - "build:svelte": "svelte-strip strip src/ dist", + "build": "npm run build:svelte && npm run build:sass", + "build:svelte": "svelte-package", "build:sass": "sass --no-source-map -I node_modules -I ../smui-theme/node_modules -I ../../node_modules _style.scss bare.css", "clean": "git status --ignored -u --porcelain . | grep -v node_modules/ | grep -e '^!! ' | sed 's/^!! packages\\/[a-z-]*\\///g' | tr '\\n' ' ' | xargs rm", - "check": "npx svelte-check --ignore dist", + "check": "npx svelte-check --ignore package", "prepare": "npm run build", "test": "echo \"Error: no test specified\" && exit 1" }, @@ -47,7 +46,6 @@ "@tsconfig/svelte": "^3.0.0", "sass": "^1.54.0", "svelte-check": "^2.8.1", - "svelte-strip": "^1.0.2", "tslib": "^2.4.0", "typescript": "^4.7.4" } diff --git a/packages/touch-target/src/Wrapper.ts b/packages/touch-target/src/lib/Wrapper.ts similarity index 100% rename from packages/touch-target/src/Wrapper.ts rename to packages/touch-target/src/lib/Wrapper.ts diff --git a/packages/touch-target/src/ambient.d.ts b/packages/touch-target/src/lib/ambient.d.ts similarity index 100% rename from packages/touch-target/src/ambient.d.ts rename to packages/touch-target/src/lib/ambient.d.ts diff --git a/packages/touch-target/src/index.ts b/packages/touch-target/src/lib/index.ts similarity index 100% rename from packages/touch-target/src/index.ts rename to packages/touch-target/src/lib/index.ts diff --git a/packages/touch-target/svelte.config.js b/packages/touch-target/svelte.config.js new file mode 100644 index 000000000..6071a099e --- /dev/null +++ b/packages/touch-target/svelte.config.js @@ -0,0 +1,7 @@ +import preprocess from 'svelte-preprocess'; + +const config = { + preprocess: preprocess() +}; + +export default config;