From a264cd6d9ce4a77310be5c8659e5d8612831696e Mon Sep 17 00:00:00 2001 From: Jeremy Wiebe Date: Thu, 14 Nov 2024 14:28:13 -0800 Subject: [PATCH 1/6] Enable dependabot updates for WB/WS (and group them) --- .github/dependabot.yml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 2be174af9d..81dc6da17e 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -10,3 +10,21 @@ updates: allow: - dependency-name: "@khanacademy/eslint-config" - dependency-name: "@khanacademy/eslint-plugin" + assignees: + - "@Khan/perseus" + + # Grouped updates for Wonder Blocks and Wonder Stuff releases. + # This helps us to stay in sync with the latest releases of these packages. + - package-ecosystem: "npm" + directory: "/" + schedule: + interval: "daily" + assignees: + - "@Khan/perseus" + groups: + wonder-stuff: + patterns: + - "@khanacademy/wonder-stuff-*" + wonder-blocks: + patterns: + - "@khanacademy/wonder-blocks-*" From a07ac92c49efabb38aafbc50920044e8bfb329c1 Mon Sep 17 00:00:00 2001 From: Jeremy Wiebe Date: Thu, 14 Nov 2024 14:44:49 -0800 Subject: [PATCH 2/6] Prettier --- .github/dependabot.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 81dc6da17e..bbd5a33664 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -11,7 +11,7 @@ updates: - dependency-name: "@khanacademy/eslint-config" - dependency-name: "@khanacademy/eslint-plugin" assignees: - - "@Khan/perseus" + - "@Khan/perseus" # Grouped updates for Wonder Blocks and Wonder Stuff releases. # This helps us to stay in sync with the latest releases of these packages. From a478aa2feff7ebb298793cf02cec26f8794986ea Mon Sep 17 00:00:00 2001 From: Jeremy Wiebe Date: Thu, 14 Nov 2024 16:28:31 -0800 Subject: [PATCH 3/6] Fix dependabot.yml format --- .github/dependabot.yml | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/.github/dependabot.yml b/.github/dependabot.yml index bbd5a33664..126d6a8650 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -13,14 +13,8 @@ updates: assignees: - "@Khan/perseus" - # Grouped updates for Wonder Blocks and Wonder Stuff releases. - # This helps us to stay in sync with the latest releases of these packages. - - package-ecosystem: "npm" - directory: "/" - schedule: - interval: "daily" - assignees: - - "@Khan/perseus" + # Grouped updates for Wonder Blocks and Wonder Stuff releases. + # This helps us to stay in sync with the latest releases of these packages. groups: wonder-stuff: patterns: From 01c16dbae5642d2b67db1db51882d36f8aa46cd0 Mon Sep 17 00:00:00 2001 From: Jeremy Wiebe Date: Fri, 15 Nov 2024 15:25:21 -0800 Subject: [PATCH 4/6] Add WB color and spacing to restricted import list so we don't accidentally add them back as a dependency at some point (they're deprecated) --- .eslintrc.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.eslintrc.js b/.eslintrc.js index aee5d9fe7d..c7cadf436c 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -172,6 +172,11 @@ module.exports = { "no-invalid-this": "off", "@typescript-eslint/no-this-alias": "off", "no-unused-expressions": "off", + "no-restricted-imports": [ + "error", + "@khanacademy/wonder-blocks-color", + "@khanacademy/wonder-blocks-spacing", + ], "object-curly-spacing": "off", semi: "off", From 416b11a188d767b97dc5c25ba09dca672cc3bc7a Mon Sep 17 00:00:00 2001 From: Jeremy Wiebe Date: Mon, 18 Nov 2024 13:10:22 -0800 Subject: [PATCH 5/6] Remove two usages of deprecated @khanacademy/wonder-blocks-spacing --- .../src/components/__stories__/device-framer.stories.tsx | 5 ++--- packages/perseus-editor/src/components/widget-editor.tsx | 4 ++-- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/packages/perseus-editor/src/components/__stories__/device-framer.stories.tsx b/packages/perseus-editor/src/components/__stories__/device-framer.stories.tsx index 79ae5e8f18..a6f9f06cfc 100644 --- a/packages/perseus-editor/src/components/__stories__/device-framer.stories.tsx +++ b/packages/perseus-editor/src/components/__stories__/device-framer.stories.tsx @@ -1,5 +1,4 @@ -import Spacing from "@khanacademy/wonder-blocks-spacing"; -import {color} from "@khanacademy/wonder-blocks-tokens"; +import {color, spacing} from "@khanacademy/wonder-blocks-tokens"; import DeviceFramer from "../device-framer"; @@ -21,7 +20,7 @@ const SampleContent = () => { color: color.offWhite, width: "90%", height: "300px", - padding: Spacing.medium_16, + padding: spacing.medium_16, }} > The DeviceFramer controls the size of the content inside the frame. diff --git a/packages/perseus-editor/src/components/widget-editor.tsx b/packages/perseus-editor/src/components/widget-editor.tsx index 5b21deadd2..7c406660a0 100644 --- a/packages/perseus-editor/src/components/widget-editor.tsx +++ b/packages/perseus-editor/src/components/widget-editor.tsx @@ -8,8 +8,8 @@ import { } from "@khanacademy/perseus"; import {useUniqueIdWithMock} from "@khanacademy/wonder-blocks-core"; import {Strut} from "@khanacademy/wonder-blocks-layout"; -import Spacing from "@khanacademy/wonder-blocks-spacing"; import Switch from "@khanacademy/wonder-blocks-switch"; +import {spacing} from "@khanacademy/wonder-blocks-tokens"; import * as React from "react"; import _ from "underscore"; @@ -241,7 +241,7 @@ function LabeledSwitch(props: { return ( <> - + ); From 706d132a2262371b67317ac3956b66695fbaa95f Mon Sep 17 00:00:00 2001 From: Jeremy Wiebe Date: Mon, 18 Nov 2024 13:14:06 -0800 Subject: [PATCH 6/6] Changeset --- .changeset/mighty-rules-talk.md | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 .changeset/mighty-rules-talk.md diff --git a/.changeset/mighty-rules-talk.md b/.changeset/mighty-rules-talk.md new file mode 100644 index 0000000000..7946251c38 --- /dev/null +++ b/.changeset/mighty-rules-talk.md @@ -0,0 +1,5 @@ +--- +"@khanacademy/perseus-editor": patch +--- + +Switch two corner usages of deprecated @khanacademy/wonder-blocks-spacing to @khanacademy/wonder-blocks-tokens