From 4216447215f819fea638522c1c0140818519e6c5 Mon Sep 17 00:00:00 2001 From: Ferdinand Thiessen Date: Sat, 5 Aug 2023 04:07:42 +0200 Subject: [PATCH] fixup! Make change non breaking Signed-off-by: Ferdinand Thiessen --- docs/index.md | 2 +- package.json | 24 ++++++++++++------------ styleguide.config.js | 2 +- vite.config.mts | 8 ++++---- 4 files changed, 18 insertions(+), 18 deletions(-) diff --git a/docs/index.md b/docs/index.md index df4cdd94a5..8e6504c556 100644 --- a/docs/index.md +++ b/docs/index.md @@ -28,7 +28,7 @@ You can also import individual module without bundling the full library. ```js static -import NcAvatar from '@nextcloud/vue/components/NcAvatar' +import NcAvatar from '@nextcloud/vue/dist/Components/NcAvatar' ``` ## Recommendations diff --git a/package.json b/package.json index 4cc29a4cad..a6fac16b2b 100644 --- a/package.json +++ b/package.json @@ -35,21 +35,21 @@ "import": "./dist/index.mjs", "require": "./dist/index.cjs" }, - "./components/*": { - "import": "./dist/components/*.mjs", - "require": "./dist/components/*.cjs" + "./dist/Components/*.js": { + "import": "./dist/Components/*.mjs", + "require": "./dist/Components/*.cjs" }, - "./directives/*": { - "import": "./dist/directives/*.mjs", - "require": "./dist/directives/*.cjs" + "./dist/Directives/*.js": { + "import": "./dist/Directives/*.mjs", + "require": "./dist/Directives/*.cjs" }, - "./functions/*": { - "import": "./dist/functions/*.mjs", - "require": "./dist/functions/*.cjs" + "./dist/Functions/*.js": { + "import": "./dist/Functions/*.mjs", + "require": "./dist/Functions/*.cjs" }, - "./mixins/*": { - "import": "./dist/mixins/*.mjs", - "require": "./dist/mixins/*.cjs" + "./dist/Mixins/*.js": { + "import": "./dist/Mixins/*.mjs", + "require": "./dist/Mixins/*.cjs" } }, "files": [ diff --git a/styleguide.config.js b/styleguide.config.js index 537e827f2a..768dd48523 100644 --- a/styleguide.config.js +++ b/styleguide.config.js @@ -56,7 +56,7 @@ module.exports = async () => { components: 'src/components/*/*.vue', getComponentPathLine(componentPath) { const name = path.basename(componentPath, '.vue') - return `import ${name} from '@nextcloud/vue/components/${name}.js'` + return `import ${name} from '@nextcloud/vue/dist/Components/${name}.js'` }, sections: [ diff --git a/vite.config.mts b/vite.config.mts index 0e8cc5cadb..72edc252b8 100644 --- a/vite.config.mts +++ b/vite.config.mts @@ -21,7 +21,7 @@ const entryPoints = { ...globSync('src/components/*/index.js').reduce((acc, item) => { const name = item .replace('/index.js', '') - .replace('src/components/', 'components/') + .replace('src/components/', 'Components/') acc[name] = join(__dirname, item) return acc }, {}), @@ -29,7 +29,7 @@ const entryPoints = { ...globSync('src/directives/*/index.js').reduce((acc, item) => { const name = item .replace('/index.js', '') - .replace('src/directives/', 'directives/') + .replace('src/directives/', 'Directives/') acc[name] = join(__dirname, item) return acc }, {}), @@ -37,7 +37,7 @@ const entryPoints = { ...globSync('src/functions/*/index.js').reduce((acc, item) => { const name = item .replace('/index.js', '') - .replace('src/functions/', 'functions/') + .replace('src/functions/', 'Functions/') acc[name] = join(__dirname, item) return acc }, {}), @@ -45,7 +45,7 @@ const entryPoints = { ...globSync('src/mixins/*/index.js').reduce((acc, item) => { const name = item .replace('/index.js', '') - .replace('src/mixins/', 'mixins/') + .replace('src/mixins/', 'Mixins/') acc[name] = join(__dirname, item) return acc }, {}),