Skip to content

Commit 66024de

Browse files
CopilotRichDom2185
andauthored
Migrate to BlueprintJS v6 (#3289)
* Initial plan * Initial setup: Remove external dependencies for Blueprint v6 migration Co-authored-by: RichDom2185 <34370238+RichDom2185@users.noreply.github.com> * Migrate to Blueprint v6: Update dependencies and fix core breaking changes Co-authored-by: RichDom2185 <34370238+RichDom2185@users.noreply.github.com> * Complete Blueprint v6 migration: Fix xlsx dependencies and verify UI functionality Co-authored-by: RichDom2185 <34370238+RichDom2185@users.noreply.github.com> * Revert some dependency changes * Reformat * Simplify some changes * Revert XLSX changes * Revert conductor changes * Revert more conductor changes * Revert more XLSX changes * Organize imports * Reapply some dependency updates as they are non-breaking * Migrate some snapshots to bp6 * Migrate remaining snapshots to bp6 * Revert sharedb update * Pin sharedb to 2.1.1 * Update missed snapshots * Fix format script on Windows * Fix format * Update markdown dependencies * Update Vite for tests * Remove hardcoded classes --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: RichDom2185 <34370238+RichDom2185@users.noreply.github.com>
1 parent 35209d7 commit 66024de

File tree

36 files changed

+2138
-1982
lines changed

36 files changed

+2138
-1982
lines changed

.prettierrc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,6 @@
33
"singleQuote": true,
44
"printWidth": 100,
55
"arrowParens": "avoid",
6-
"trailingComma": "none"
6+
"trailingComma": "none",
7+
"endOfLine": "auto"
78
}

eslint.config.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
// @ts-check
22

33
// import eslint from '@eslint/js';
4-
import { config, configs } from 'typescript-eslint';
54
import reactPlugin from 'eslint-plugin-react';
65
import reactHooksPlugin from 'eslint-plugin-react-hooks';
76
import simpleImportSort from 'eslint-plugin-simple-import-sort';
7+
import { config, configs } from 'typescript-eslint';
88
// import reactRefresh from 'eslint-plugin-react-refresh';
99

1010
export default config(

package.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -31,17 +31,17 @@
3131
"preview": "rsbuild preview"
3232
},
3333
"dependencies": {
34-
"@blueprintjs/core": "^5.10.1",
35-
"@blueprintjs/datetime2": "^2.3.3",
34+
"@blueprintjs/core": "^6.0.0",
35+
"@blueprintjs/datetime": "^6.0.0",
3636
"@blueprintjs/icons": "^6.0.0",
37-
"@blueprintjs/select": "^5.1.3",
37+
"@blueprintjs/select": "^6.0.0",
3838
"@convergencelabs/ace-collab-ext": "^0.6.0",
3939
"@mantine/hooks": "^7.11.2",
4040
"@octokit/rest": "^22.0.0",
4141
"@reduxjs/toolkit": "^1.9.7",
4242
"@sentry/browser": "^8.33.0",
4343
"@sourceacademy/c-slang": "^1.0.21",
44-
"@sourceacademy/sharedb-ace": "^2.1.1",
44+
"@sourceacademy/sharedb-ace": "2.1.1",
4545
"@sourceacademy/sling-client": "^0.1.0",
4646
"@szhsin/react-menu": "^4.0.0",
4747
"@tanstack/react-table": "^8.9.3",

src/commons/__tests__/__snapshots__/ContentDisplay.test.tsx.snap

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ exports[`ContentDisplay page renders correctly 1`] = `
88
className="col-md-10 col-xs-11 contentdisplay-content-parent"
99
>
1010
<div
11-
className="contentdisplay-content bp5-card bp5-elevation-3"
11+
className="contentdisplay-content bp6-card bp6-elevation-3"
1212
>
1313
<div>
1414
Test Content

src/commons/__tests__/__snapshots__/Markdown.test.tsx.snap

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
exports[`Markdown page renders correctly 1`] = `
44
<div
5-
className="md bp5-running-text"
5+
className="md bp6-running-text"
66
dangerouslySetInnerHTML={
77
{
88
"__html": "<p>Welcome to the Source Academy playground!</p>

src/commons/achievement/AchievementFilter.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ const AchievementFilter: React.FC<Props> = ({ filterState, icon, ownStatus }) =>
1919
onClick={() => setGlobalStatus(ownStatus)}
2020
style={{ color: getFilterColor(globalStatus, ownStatus) }}
2121
>
22-
<Icon icon={icon} iconSize={30} />
22+
<Icon icon={icon} size={30} />
2323
<p>{ownStatus}</p>
2424
</div>
2525
);

src/commons/achievement/AchievementView.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ const AchievementView: React.FC<Props> = ({ focusUuid, userState }) => {
5959
if (focusUuid === '') {
6060
return (
6161
<div className="no-view">
62-
<Icon icon={IconNames.MOUNTAIN} iconSize={60} />
62+
<Icon icon={IconNames.MOUNTAIN} size={60} />
6363
<h2>Select an achievement</h2>
6464
</div>
6565
);

src/commons/achievement/control/achievementEditor/EditableDate.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ const EditableDate: React.FC<Props> = ({ type, date, changeDate }) => {
3333
title={`${type}`}
3434
>
3535
<DatePicker
36-
onChange={changeDate}
36+
onChange={selectedDate => changeDate(selectedDate || undefined)}
3737
timePickerProps={{ showArrowButtons: true }}
3838
value={date}
3939
/>

src/commons/achievement/control/goalEditor/EditableDate.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ const EditableDate: React.FC<Props> = ({ type, date, changeDate }) => {
3333
title={`${type}`}
3434
>
3535
<DatePicker
36-
onChange={changeDate}
36+
onChange={selectedDate => changeDate(selectedDate || undefined)}
3737
timePickerProps={{ showArrowButtons: true }}
3838
value={date}
3939
/>

src/commons/assessment/Assessment.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -226,14 +226,14 @@ const Assessment: React.FC = () => {
226226
<div className="listing-footer">
227227
<div>
228228
<Text className="listing-due-date">
229-
<Icon className="listing-due-icon" iconSize={12} icon={IconNames.CALENDAR} />
229+
<Icon className="listing-due-icon" size={12} icon={IconNames.CALENDAR} />
230230
{`${beforeNow(overview.openAt) ? 'Opened' : 'Opens'}: ${getPrettyDate(
231231
overview.openAt
232232
)}`}
233233
</Text>
234234
{beforeNow(overview.openAt) && (
235235
<Text className="listing-due-date">
236-
<Icon className="listing-due-icon" iconSize={12} icon={IconNames.TIME} />
236+
<Icon className="listing-due-icon" size={12} icon={IconNames.TIME} />
237237
{`Due: ${getPrettyDate(overview.closeAt)}`}
238238
</Text>
239239
)}

0 commit comments

Comments
 (0)