From 0cb6aa5d129192bbcbf4575b1070065de990a2c9 Mon Sep 17 00:00:00 2001 From: Cory LaViska Date: Wed, 23 Aug 2023 15:36:19 -0400 Subject: [PATCH 1/5] reformat by CEM plugin --- package.json | 16 +++------------- 1 file changed, 3 insertions(+), 13 deletions(-) diff --git a/package.json b/package.json index 11181f445..3e698b0a7 100644 --- a/package.json +++ b/package.json @@ -25,15 +25,8 @@ "./dist/react/*": "./dist/react/*", "./dist/translations/*": "./dist/translations/*" }, - "files": [ - "dist", - "cdn" - ], - "keywords": [ - "web components", - "custom elements", - "components" - ], + "files": ["dist", "cdn"], + "keywords": ["web components", "custom elements", "components"], "repository": { "type": "git", "url": "git+https://github.com/shoelace-style/shoelace.git" @@ -140,9 +133,6 @@ "user-agent-data-types": "^0.3.0" }, "lint-staged": { - "*.{ts,js}": [ - "eslint --max-warnings 0 --cache --fix", - "prettier --write" - ] + "*.{ts,js}": ["eslint --max-warnings 0 --cache --fix", "prettier --write"] } } From cf195da424b8d3278b2625ffcf42a8cd576f0406 Mon Sep 17 00:00:00 2001 From: Cory LaViska Date: Fri, 25 Aug 2023 09:35:05 -0400 Subject: [PATCH 2/5] fix stuck search --- docs/assets/scripts/search.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/docs/assets/scripts/search.js b/docs/assets/scripts/search.js index 049ab30a4..ead4efa0d 100644 --- a/docs/assets/scripts/search.js +++ b/docs/assets/scripts/search.js @@ -373,4 +373,12 @@ hide(); } }); + + // We're using Turbo, so when a user searches for something, visits a result, and presses the back button, the search + // UI will still be visible but not interactive. This removes the search UI when Turbo renders a page so they don't + // get trapped. + window.addEventListener('turbo:render', () => { + document.body.classList.remove('search-visible'); + document.querySelectorAll('.search__overlay, .search__dialog').forEach(el => el.remove()); + }); })(); From 1867603225b39c9ab85f547c4b1b6bd139b8f26c Mon Sep 17 00:00:00 2001 From: Konnor Rogers Date: Fri, 25 Aug 2023 16:20:19 -0400 Subject: [PATCH 3/5] log stderr in builds (#1543) --- scripts/build.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/scripts/build.js b/scripts/build.js index d27793b59..e46f4ef9b 100644 --- a/scripts/build.js +++ b/scripts/build.js @@ -53,6 +53,10 @@ async function buildTheDocs(watch = false) { output.push(data.toString()); }); + child.stderr.on('data', data => { + output.push(data.toString()); + }); + if (watch) { // The process doesn't terminate in watch mode so, before resolving, we listen for a known signal in stdout that // tells us when the first build completes. From ab770c566e9ccd5a8bd1a65fe9a13c51278c3ccc Mon Sep 17 00:00:00 2001 From: Cory LaViska Date: Mon, 28 Aug 2023 09:27:57 -0400 Subject: [PATCH 4/5] fix spacing; #1540 (#1544) --- docs/pages/resources/changelog.md | 4 ++++ src/components/switch/switch.component.ts | 4 +++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/docs/pages/resources/changelog.md b/docs/pages/resources/changelog.md index d50d8cda6..74da10f29 100644 --- a/docs/pages/resources/changelog.md +++ b/docs/pages/resources/changelog.md @@ -12,6 +12,10 @@ Components with the Experimental bad New versions of Shoelace are released as-needed and generally occur when a critical mass of changes have accumulated. At any time, you can see what's coming in the next release by visiting [next.shoelace.style](https://next.shoelace.style). +## Next + +- Fixed a bug in `` that resulted in improper spacing between the label and the required asterisk [#1540] + ## 2.8.0 - Added `--isolatedModules` and `--verbatimModuleSyntax` to `tsconfig.json`. For anyone directly importing event types, they no longer provide a default export due to these options being enabled. For people using the `events/event.js` file directly, there is no change. diff --git a/src/components/switch/switch.component.ts b/src/components/switch/switch.component.ts index 232d03332..2ec28063c 100644 --- a/src/components/switch/switch.component.ts +++ b/src/components/switch/switch.component.ts @@ -215,7 +215,9 @@ export default class SlSwitch extends ShoelaceElement implements ShoelaceFormCon - +
+ +
`; } From a2fbe121c37adb8683d89f123e1c4d3b3203ae07 Mon Sep 17 00:00:00 2001 From: Cory LaViska Date: Mon, 28 Aug 2023 09:39:16 -0400 Subject: [PATCH 5/5] update ctrl/tinycolor; fixes #1542 (#1545) --- docs/pages/resources/changelog.md | 3 ++- package-lock.json | 16 ++++++++-------- package.json | 2 +- 3 files changed, 11 insertions(+), 10 deletions(-) diff --git a/docs/pages/resources/changelog.md b/docs/pages/resources/changelog.md index 74da10f29..c6f73cecc 100644 --- a/docs/pages/resources/changelog.md +++ b/docs/pages/resources/changelog.md @@ -15,6 +15,7 @@ New versions of Shoelace are released as-needed and generally occur when a criti ## Next - Fixed a bug in `` that resulted in improper spacing between the label and the required asterisk [#1540] +- Updated `@ctrl/tinycolor` to 4.0.1 [#1542] ## 2.8.0 @@ -27,7 +28,7 @@ New versions of Shoelace are released as-needed and generally occur when a criti - Improved expand/collapse behavior of `` to work more like users expect [#1521] - Improved `` so labels truncate properly instead of getting chopped and overflowing - Removed the extra `React.Component` around `@lit-labs/react` wrapper. [#1531] -- Upgrade `@lit-labs/react` to v2.0.1. [#1531] +- Updated `@lit-labs/react` to v2.0.1. [#1531] ## 2.7.0 diff --git a/package-lock.json b/package-lock.json index 566d8b4bf..9379318a3 100644 --- a/package-lock.json +++ b/package-lock.json @@ -9,7 +9,7 @@ "version": "2.8.0", "license": "MIT", "dependencies": { - "@ctrl/tinycolor": "^3.5.0", + "@ctrl/tinycolor": "^4.0.1", "@floating-ui/dom": "^1.2.1", "@lit-labs/react": "^2.0.1", "@shoelace-style/animations": "^1.1.0", @@ -833,11 +833,11 @@ } }, "node_modules/@ctrl/tinycolor": { - "version": "3.5.0", - "resolved": "https://registry.npmjs.org/@ctrl/tinycolor/-/tinycolor-3.5.0.tgz", - "integrity": "sha512-tlJpwF40DEQcfR/QF+wNMVyGMaO9FQp6Z1Wahj4Gk3CJQYHwA2xVG7iKDFdW6zuxZY9XWOpGcfNCTsX4McOsOg==", + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/@ctrl/tinycolor/-/tinycolor-4.0.1.tgz", + "integrity": "sha512-dfimuE1mfaqL8P8jyQzdk9yFeFUWCyhjK5VyydXgDtQO0fezr6aWaGauHnlI07BZBIF45gahb0oxJjkUcylDwQ==", "engines": { - "node": ">=10" + "node": ">=14" } }, "node_modules/@custom-elements-manifest/analyzer": { @@ -17913,9 +17913,9 @@ "dev": true }, "@ctrl/tinycolor": { - "version": "3.5.0", - "resolved": "https://registry.npmjs.org/@ctrl/tinycolor/-/tinycolor-3.5.0.tgz", - "integrity": "sha512-tlJpwF40DEQcfR/QF+wNMVyGMaO9FQp6Z1Wahj4Gk3CJQYHwA2xVG7iKDFdW6zuxZY9XWOpGcfNCTsX4McOsOg==" + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/@ctrl/tinycolor/-/tinycolor-4.0.1.tgz", + "integrity": "sha512-dfimuE1mfaqL8P8jyQzdk9yFeFUWCyhjK5VyydXgDtQO0fezr6aWaGauHnlI07BZBIF45gahb0oxJjkUcylDwQ==" }, "@custom-elements-manifest/analyzer": { "version": "0.8.3", diff --git a/package.json b/package.json index 3e698b0a7..5cca9356a 100644 --- a/package.json +++ b/package.json @@ -60,7 +60,7 @@ "node": ">=14.17.0" }, "dependencies": { - "@ctrl/tinycolor": "^3.5.0", + "@ctrl/tinycolor": "^4.0.1", "@floating-ui/dom": "^1.2.1", "@lit-labs/react": "^2.0.1", "@shoelace-style/animations": "^1.1.0",