From db9b9f42614692176926c6b6e6f5eda3dbb87da8 Mon Sep 17 00:00:00 2001 From: GHOST Date: Thu, 14 Mar 2024 00:34:45 +0000 Subject: [PATCH] build: fix lint --- packages/docs/.prettierrc | 10 ++++++++-- packages/docs/package.json | 4 ++-- packages/docs/src/app.html | 2 +- .../components/clduploadbutton/examples.md | 18 +++++++++--------- .../docs/components/clduploadwidget/usage.md | 12 ++++++------ packages/docs/src/lib/components/Search.svelte | 4 +++- packages/playground/.prettierrc | 10 ++++++++-- packages/playground/package.json | 4 ++-- packages/playground/src/app.html | 2 +- 9 files changed, 40 insertions(+), 26 deletions(-) diff --git a/packages/docs/.prettierrc b/packages/docs/.prettierrc index a77fddea..3f7802c3 100644 --- a/packages/docs/.prettierrc +++ b/packages/docs/.prettierrc @@ -4,6 +4,12 @@ "trailingComma": "none", "printWidth": 100, "plugins": ["prettier-plugin-svelte"], - "pluginSearchDirs": ["."], - "overrides": [{ "files": "*.svelte", "options": { "parser": "svelte" } }] + "overrides": [ + { + "files": "*.svelte", + "options": { + "parser": "svelte" + } + } + ] } diff --git a/packages/docs/package.json b/packages/docs/package.json index a63b38c4..05ea75eb 100644 --- a/packages/docs/package.json +++ b/packages/docs/package.json @@ -8,8 +8,8 @@ "preview": "vite preview", "check": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json", "check:watch": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json --watch", - "lint": "prettier --plugin-search-dir . --check .", - "format": "prettier --plugin-search-dir . --write ." + "lint": "prettier --check .", + "format": "prettier --write ." }, "devDependencies": { "@sveltejs/adapter-vercel": "^5.1.1", diff --git a/packages/docs/src/app.html b/packages/docs/src/app.html index a2c6669c..e8b0af9c 100644 --- a/packages/docs/src/app.html +++ b/packages/docs/src/app.html @@ -1,4 +1,4 @@ - + diff --git a/packages/docs/src/docs/components/clduploadbutton/examples.md b/packages/docs/src/docs/components/clduploadbutton/examples.md index 64d09ac4..c0072e03 100644 --- a/packages/docs/src/docs/components/clduploadbutton/examples.md +++ b/packages/docs/src/docs/components/clduploadbutton/examples.md @@ -23,9 +23,9 @@ order: 3 ### Unsigned { info = result?.info; widget.close(); }} - uploadPreset={PUBLIC_CLOUDINARY_UNSIGNED_UPLOAD_PRESET} +class="cldbutton" +onUpload={(result, widget) => { info = result?.info; widget.close(); }} +uploadPreset={PUBLIC_CLOUDINARY_UNSIGNED_UPLOAD_PRESET} />

URL: { info?.secure_url || 'Upload to see example result.' }

@@ -41,17 +41,17 @@ order: 3 ### Signed { infoSecure = result?.info; widget.close(); }} - uploadPreset={PUBLIC_CLOUDINARY_SIGNED_UPLOAD_PRESET} +class="cldbutton" +signatureEndpoint="/api/sign-cloudinary-params" +onUpload={(result, widget) => { infoSecure = result?.info; widget.close(); }} +uploadPreset={PUBLIC_CLOUDINARY_SIGNED_UPLOAD_PRESET} />

URL: { infoSecure?.secure_url || 'Upload to see example result.' }

```html ``` diff --git a/packages/docs/src/docs/components/clduploadwidget/usage.md b/packages/docs/src/docs/components/clduploadwidget/usage.md index 814f9dd9..26700306 100644 --- a/packages/docs/src/docs/components/clduploadwidget/usage.md +++ b/packages/docs/src/docs/components/clduploadwidget/usage.md @@ -49,12 +49,12 @@ Use the following to generate an unsigned upload widget: ``` { infoUpload = result?.info; widget.close(); }} - uploadPreset={PUBLIC_CLOUDINARY_UNSIGNED_UPLOAD_PRESET}> - +let:open let:isLoading +onUpload={(result, widget) => { infoUpload = result?.info; widget.close(); }} +uploadPreset={PUBLIC_CLOUDINARY_UNSIGNED_UPLOAD_PRESET}> +

URL: { infoUpload?.secure_url || 'Upload to see example result.' }

diff --git a/packages/docs/src/lib/components/Search.svelte b/packages/docs/src/lib/components/Search.svelte index 582290f9..6aff56e0 100644 --- a/packages/docs/src/lib/components/Search.svelte +++ b/packages/docs/src/lib/components/Search.svelte @@ -166,7 +166,9 @@ padding: 0.5rem; backdrop-filter: blur(1rem); margin-top: 0.5rem; - box-shadow: rgba(50, 50, 93, 0.25) 0px 13px 27px -5px, rgba(0, 0, 0, 0.3) 0px 8px 16px -8px; + box-shadow: + rgba(50, 50, 93, 0.25) 0px 13px 27px -5px, + rgba(0, 0, 0, 0.3) 0px 8px 16px -8px; } [data-svelte-typeahead][data-svelte-typeahead] .svelte-typeahead-list .selected, [data-svelte-typeahead][data-svelte-typeahead] .svelte-typeahead-list .selected:hover { diff --git a/packages/playground/.prettierrc b/packages/playground/.prettierrc index a77fddea..3f7802c3 100644 --- a/packages/playground/.prettierrc +++ b/packages/playground/.prettierrc @@ -4,6 +4,12 @@ "trailingComma": "none", "printWidth": 100, "plugins": ["prettier-plugin-svelte"], - "pluginSearchDirs": ["."], - "overrides": [{ "files": "*.svelte", "options": { "parser": "svelte" } }] + "overrides": [ + { + "files": "*.svelte", + "options": { + "parser": "svelte" + } + } + ] } diff --git a/packages/playground/package.json b/packages/playground/package.json index dbe92f3a..c5f5a7d1 100644 --- a/packages/playground/package.json +++ b/packages/playground/package.json @@ -8,8 +8,8 @@ "preview": "vite preview", "check": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json", "check:watch": "svelte-kit sync && svelte-check --tsconfig ./tsconfig.json --watch", - "lint": "prettier --plugin-search-dir . --check .", - "format": "prettier --plugin-search-dir . --write ." + "lint": "prettier --check .", + "format": "prettier --write ." }, "devDependencies": { "@sveltejs/adapter-auto": "^3.1.1", diff --git a/packages/playground/src/app.html b/packages/playground/src/app.html index 6bf6592e..a7659dee 100644 --- a/packages/playground/src/app.html +++ b/packages/playground/src/app.html @@ -1,4 +1,4 @@ - +