Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

@uppy/svelte: update peer dependencies #4065

Merged
merged 1 commit into from Aug 30, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
20 changes: 15 additions & 5 deletions packages/@uppy/svelte/package.json
@@ -1,5 +1,6 @@
{
"name": "@uppy/svelte",
"description": "Uppy plugin that helps integrate Uppy into your Svelte project.",
"svelte": "src/index.js",
"module": "dist/index.mjs",
"main": "dist/index.js",
Expand All @@ -9,11 +10,13 @@
"prepublishOnly": "yarn run build",
"validate": "svelte-check"
},
"dependencies": {
"@uppy/dashboard": "workspace:^",
"@uppy/drag-drop": "workspace:^",
"@uppy/progress-bar": "workspace:^",
"@uppy/status-bar": "workspace:^"
"homepage": "https://uppy.io",
"bugs": {
"url": "https://github.com/transloadit/uppy/issues"
},
"repository": {
"type": "git",
"url": "git+https://github.com/transloadit/uppy.git"
},
"devDependencies": {
"@rollup/plugin-node-resolve": "^13.0.0",
Expand All @@ -26,12 +29,19 @@
},
"peerDependencies": {
"@uppy/core": "workspace:^",
"@uppy/dashboard": "workspace:^",
"@uppy/drag-drop": "workspace:^",
"@uppy/progress-bar": "workspace:^",
"@uppy/status-bar": "workspace:^",
"svelte": "^3.0.0"
},
"publishConfig": {
"access": "public"
},
"keywords": [
"file uploader",
"uppy",
"uppy-plugin",
"svelte"
],
"files": [
Expand Down
6 changes: 6 additions & 0 deletions website/src/docs/migration-guides.md
Expand Up @@ -168,6 +168,12 @@ It’s internal usage only.

To migrate: use exposed options only.

#### `@uppy/svelte`

`@uppy/dashboard`, `@uppy/drag-drop`, `@uppy/progress-bar`, and `@uppy/status-bar` are now peer dependencies. This means you don’t install all these packages if you only need one.

To migrate: install only the packages you need. If you use the Dashboard component, you need `@uppy/dashboard`, and so onwards.

#### `@uppy/vue`

`@uppy/dashboard`, `@uppy/drag-drop`, `@uppy/file-input`, `@uppy/progress-bar`, and `@uppy/status-bar` are now peer dependencies. This means you don’t install all these packages if you only need one.
Expand Down
21 changes: 15 additions & 6 deletions website/src/docs/svelte.md
Expand Up @@ -82,13 +82,14 @@ const uppy = new Uppy().use(Webcam);
</script>
```

The following plugins are available as Svelte component wrappers:
The following plugins are available as Svelte component wrappers (you need to
install each package separately):

* `<Dashboard />` - renders an inline `@uppy/dashboard`
* `<DashboardModal />` - renders a `@uppy/dashboard` modal
* `<DragDrop />` - renders a `@uppy/drag-drop` area
* `<ProgressBar />` - renders a `@uppy/progress-bar`
* `<StatusBar />` - renders a `@uppy/status-bar`
* `<Dashboard />` - renders an inline [`@uppy/dashboard`][].
* `<DashboardModal />` - renders a [`@uppy/dashboard`][] modal.
* `<DragDrop />` - renders a [`@uppy/drag-drop`][] area.
* `<ProgressBar />` - renders a [`@uppy/progress-bar`][].
* `<StatusBar />` - renders a [`@uppy/status-bar`][].

Each component takes a `props` prop that will be passed to the UI Plugin. Both `@uppy/dashboard` based plugins also take a `plugins` array as a props, make it easier to add your plugins.

Expand Down Expand Up @@ -222,6 +223,14 @@ Import general Core styles from `@uppy/core/dist/style.css` first, then add the

The `<StatusBar />` component supports all `@uppy/status-bar` options to be passed as an object on the `props` prop. An Uppy instance must be provided in the `uppy={}` prop.

[`@uppy/dashboard`]: /docs/dashboard

[`@uppy/drag-drop`]: /docs/drag-drop

[`@uppy/progress-bar`]: /docs/progress-bar

[`@uppy/status-bar`]: /docs/status-bar

[`@uppy/webcam`]: /docs/webcam/

[Svelte]: https://svelte.dev
Expand Down
8 changes: 4 additions & 4 deletions yarn.lock
Expand Up @@ -8813,17 +8813,17 @@ __metadata:
dependencies:
"@rollup/plugin-node-resolve": ^13.0.0
"@tsconfig/svelte": ^3.0.0
"@uppy/dashboard": "workspace:^"
"@uppy/drag-drop": "workspace:^"
"@uppy/progress-bar": "workspace:^"
"@uppy/status-bar": "workspace:^"
rollup: ^2.60.2
rollup-plugin-svelte: ^7.0.0
svelte: ^3.31.0
svelte-check: ^2.0.0
svelte-preprocess: ^4.6.1
peerDependencies:
"@uppy/core": "workspace:^"
"@uppy/dashboard": "workspace:^"
"@uppy/drag-drop": "workspace:^"
"@uppy/progress-bar": "workspace:^"
"@uppy/status-bar": "workspace:^"
svelte: ^3.0.0
languageName: unknown
linkType: soft
Expand Down