Skip to content

Commit 23c2912

Browse files
committed
refactor: remove deprecated SideContent UI components
1 parent 59b1749 commit 23c2912

File tree

5 files changed

+0
-336
lines changed

5 files changed

+0
-336
lines changed

src/commons/editingWorkspace/EditingWorkspace.tsx

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@ import { convertEditorTabStateToProps } from '../editor/EditorContainer';
4545
import { Position } from '../editor/EditorTypes';
4646
import Markdown from '../Markdown';
4747
import { SideContentProps } from '../sideContent/SideContent';
48-
import SideContentToneMatrix from '../sideContent/SideContentToneMatrix';
4948
import { SideContentTab, SideContentType } from '../sideContent/SideContentTypes';
5049
import { history } from '../utils/HistoryHelper';
5150
import Workspace, { WorkspaceProps } from '../workspace/Workspace';
@@ -432,15 +431,6 @@ const EditingWorkspace: React.FC<EditingWorkspaceProps> = props => {
432431
id: SideContentType.editorAutograder
433432
});
434433
}
435-
const functionsAttached = currentAssessment!.globalDeployment!.external.symbols;
436-
if (functionsAttached.includes('get_matrix')) {
437-
tabs.push({
438-
label: `Tone Matrix`,
439-
iconName: IconNames.GRID_VIEW,
440-
body: <SideContentToneMatrix />,
441-
id: SideContentType.toneMatrix
442-
});
443-
}
444434
} else {
445435
tabs = [
446436
{

src/commons/sideContent/SideContentToneMatrix.tsx

Lines changed: 0 additions & 47 deletions
This file was deleted.

src/commons/sideContent/SideContentTypes.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,6 @@ export enum SideContentType {
3333
sourcereel = 'sourcereel',
3434
substVisualizer = 'subst_visualiser',
3535
testcases = 'testcases',
36-
toneMatrix = 'tone_matrix',
37-
videoDisplay = 'video_display',
3836
htmlDisplay = 'html_display'
3937
}
4038

src/commons/sideContent/SideContentVideoDisplay.tsx

Lines changed: 0 additions & 251 deletions
This file was deleted.

src/pages/academy/grading/subcomponents/GradingWorkspace.tsx

Lines changed: 0 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,6 @@ import { IconNames } from '@blueprintjs/icons';
33
import classNames from 'classnames';
44
import { Chapter, Variant } from 'js-slang/dist/types';
55
import * as React from 'react';
6-
import { ExternalLibraryName } from 'src/commons/application/types/ExternalTypes';
7-
import SideContentVideoDisplay from 'src/commons/sideContent/SideContentVideoDisplay';
86

97
import {
108
defaultWorkspaceManager,
@@ -30,7 +28,6 @@ import { Position } from '../../../../commons/editor/EditorTypes';
3028
import Markdown from '../../../../commons/Markdown';
3129
import { SideContentProps } from '../../../../commons/sideContent/SideContent';
3230
import SideContentAutograder from '../../../../commons/sideContent/SideContentAutograder';
33-
import SideContentToneMatrix from '../../../../commons/sideContent/SideContentToneMatrix';
3431
import { SideContentTab, SideContentType } from '../../../../commons/sideContent/SideContentTypes';
3532
import { history } from '../../../../commons/utils/HistoryHelper';
3633
import Workspace, { WorkspaceProps } from '../../../../commons/workspace/Workspace';
@@ -344,29 +341,6 @@ class GradingWorkspace extends React.Component<GradingWorkspaceProps, State> {
344341
}
345342
];
346343

347-
const externalLibrary = props.grading![questionId].question.library.external;
348-
const functionsAttached = externalLibrary.symbols;
349-
if (functionsAttached.includes('get_matrix')) {
350-
tabs.push({
351-
label: `Tone Matrix`,
352-
iconName: IconNames.GRID_VIEW,
353-
body: <SideContentToneMatrix />,
354-
id: SideContentType.toneMatrix
355-
});
356-
}
357-
358-
if (
359-
externalLibrary.name === ExternalLibraryName.PIXNFLIX ||
360-
externalLibrary.name === ExternalLibraryName.ALL
361-
) {
362-
tabs.push({
363-
label: 'Video Display',
364-
iconName: IconNames.MOBILE_VIDEO,
365-
body: <SideContentVideoDisplay replChange={props.handleSendReplInputToOutput} />,
366-
id: SideContentType.videoDisplay
367-
});
368-
}
369-
370344
const sideContentProps: SideContentProps = {
371345
onChange: (
372346
newTabId: SideContentType,

0 commit comments

Comments
 (0)