From 82f20186b1c48411611502b2e607eaff2afe3d34 Mon Sep 17 00:00:00 2001 From: Hiroki Terashima Date: Fri, 30 Oct 2020 18:57:37 -0700 Subject: [PATCH 01/15] Removed OnlyShowWork mode and removed from NodeController. Also cleaned up related code. #2777 --- .../wise5/components/componentController.ts | 77 ++++--------------- .../conceptMap/conceptMapController.ts | 13 ---- .../wise5/components/draw/drawController.ts | 4 +- .../wise5/components/graph/graphController.ts | 9 --- .../wise5/components/label/labelController.ts | 6 -- .../wise5/components/match/matchController.ts | 5 -- .../multipleChoiceController.ts | 5 -- .../openResponse/openResponseController.ts | 10 --- .../wise5/components/table/tableController.ts | 6 -- .../webapp/wise5/vle/node/nodeController.ts | 58 +++----------- 10 files changed, 31 insertions(+), 162 deletions(-) diff --git a/src/main/webapp/wise5/components/componentController.ts b/src/main/webapp/wise5/components/componentController.ts index 31a9422c4f..41914bad2a 100644 --- a/src/main/webapp/wise5/components/componentController.ts +++ b/src/main/webapp/wise5/components/componentController.ts @@ -15,23 +15,7 @@ import { Directive } from '@angular/core'; @Directive() class ComponentController { - $filter: any; - $injector: any; - $mdDialog: any; - $q: any; - $rootScope: any; - $scope: any; $translate: any; - AudioRecorderService: AudioRecorderService; - AnnotationService: AnnotationService; - ConfigService: ConfigService; - NodeService: NodeService; - NotebookService: NotebookService; - NotificationService: NotificationService; - ProjectService: ProjectService; - StudentAssetService: StudentAssetService; - UtilService: UtilService; - StudentDataService: StudentDataService; nodeId: string; componentId: string; componentContent: any; @@ -72,40 +56,23 @@ class ComponentController { starterStateRequestSubscription: Subscription; constructor( - $filter, - $injector, - $mdDialog, - $q, - $rootScope, - $scope, - AnnotationService, - AudioRecorderService, - ConfigService, - NodeService, - NotebookService, - NotificationService, - ProjectService, - StudentAssetService, - StudentDataService, - UtilService) { - this.$filter = $filter; - this.$injector = $injector; - this.$mdDialog = $mdDialog; - this.$q = $q; - this.$rootScope = $rootScope; - this.$scope = $scope; - this.AnnotationService = AnnotationService; - this.AudioRecorderService = AudioRecorderService; - this.ConfigService = ConfigService; - this.NodeService = NodeService; - this.NotebookService = NotebookService; - this.NotificationService = NotificationService; - this.ProjectService = ProjectService; - this.StudentAssetService = StudentAssetService; - this.StudentDataService = StudentDataService; - this.UtilService = UtilService; + protected $filter: any, + protected $injector: any, + protected $mdDialog: any, + protected $q: any, + protected $rootScope: any, + protected $scope: any, + protected AnnotationService: AnnotationService, + protected AudioRecorderService: AudioRecorderService, + protected ConfigService: ConfigService, + protected NodeService: NodeService, + protected NotebookService: NotebookService, + protected NotificationService: NotificationService, + protected ProjectService: ProjectService, + protected StudentAssetService: StudentAssetService, + protected StudentDataService: StudentDataService, + protected UtilService: UtilService) { this.$translate = this.$filter('translate'); - this.nodeId = this.$scope.nodeId; this.componentContent = this.$scope.componentContent; this.componentId = this.componentContent.id; @@ -160,18 +127,13 @@ class ComponentController { this.isSaveButtonVisible = false; this.isSubmitButtonVisible = false; this.isDisabled = true; - } else if (this.isOnlyShowWorkMode()) { - this.isPromptVisible = false; - this.isSaveButtonVisible = false; - this.isSubmitButtonVisible = false; - this.isDisabled = true; } if (this.isStudentMode() || this.isGradingMode() || this.isGradingRevisionMode()) { this.latestAnnotations = this.AnnotationService.getLatestComponentAnnotations(this.nodeId, this.componentId, this.workgroupId); } - if (this.isGradingMode() || this.isGradingRevisionMode() || this.isOnlyShowWorkMode()) { + if (this.isGradingMode() || this.isGradingRevisionMode()) { this.showAddToNotebookButton = false; } @@ -209,10 +171,6 @@ class ComponentController { return this.mode === 'gradingRevision'; } - isOnlyShowWorkMode() { - return this.mode === 'onlyShowWork'; - } - isAuthoringComponentPreviewMode() { return this.mode === 'authoringComponentPreview'; } @@ -635,7 +593,6 @@ class ComponentController { return this.ProjectService.isApplicationNode(nodeId); } - /** * Create a new component state populated with the student data * @param action the action that is triggering creating of this component state diff --git a/src/main/webapp/wise5/components/conceptMap/conceptMapController.ts b/src/main/webapp/wise5/components/conceptMap/conceptMapController.ts index f979bd832a..70131ece53 100644 --- a/src/main/webapp/wise5/components/conceptMap/conceptMapController.ts +++ b/src/main/webapp/wise5/components/conceptMap/conceptMapController.ts @@ -169,19 +169,6 @@ class ConceptMapController extends ComponentController { } else { this.setIdsWithNodeIdComponentIdWorkgroupId(); } - } else if (this.isOnlyShowWorkMode()) { - const componentState = this.$scope.componentState; - if (componentState == null) { - this.setSVGId(this.nodeId, this.componentId, this.workgroupId, 'onlyShowWork_'); - } else { - this.setSVGId( - this.nodeId, - this.componentId, - this.workgroupId, - this.componentStateId, - 'onlyShowWork_' - ); - } } else { this.availableNodes = this.componentContent.nodes; this.availableLinks = this.componentContent.links; diff --git a/src/main/webapp/wise5/components/draw/drawController.ts b/src/main/webapp/wise5/components/draw/drawController.ts index 143c3ef0af..59acfa639d 100644 --- a/src/main/webapp/wise5/components/draw/drawController.ts +++ b/src/main/webapp/wise5/components/draw/drawController.ts @@ -111,7 +111,7 @@ class DrawController extends ComponentController { this.isSubmitButtonVisible = this.componentContent.showSubmitButton; this.isResetButtonVisible = true; this.drawingToolId = 'drawingtool_' + this.nodeId + '_' + this.componentId; - } else if (this.isGradingMode() || this.isGradingRevisionMode() || this.isOnlyShowWorkMode()) { + } else if (this.isGradingMode() || this.isGradingRevisionMode()) { const componentState = this.$scope.componentState; if (componentState != null) { if (this.isGradingRevisionMode()) { @@ -289,7 +289,7 @@ class DrawController extends ComponentController { }); } - if (this.isGradingMode() || this.isGradingRevisionMode() || this.isOnlyShowWorkMode()) { + if (this.isGradingMode() || this.isGradingRevisionMode()) { $('#' + this.drawingToolId) .find('.dt-tools') .hide(); diff --git a/src/main/webapp/wise5/components/graph/graphController.ts b/src/main/webapp/wise5/components/graph/graphController.ts index 42c498dee2..45c3b59fd7 100644 --- a/src/main/webapp/wise5/components/graph/graphController.ts +++ b/src/main/webapp/wise5/components/graph/graphController.ts @@ -172,8 +172,6 @@ class GraphController extends ComponentController { this.initializeStudentMode(componentState); } else if (this.mode === 'grading' || this.mode === 'gradingRevision') { this.initializeGradingMode(componentState); - } else if (this.mode === 'onlyShowWork') { - this.initializeOnlyShowWorkMode(); } else { this.isResetSeriesButtonVisible = true; this.isSelectSeriesVisible = true; @@ -291,13 +289,6 @@ class GraphController extends ComponentController { } } - initializeOnlyShowWorkMode() { - this.isResetGraphButtonVisible = false; - this.isResetSeriesButtonVisible = false; - this.isSelectSeriesVisible = false; - this.backgroundImage = this.componentContent.backgroundImage; - } - initializeHandleConnectedComponentStudentDataChanged() { this.$scope.handleConnectedComponentStudentDataChanged = ( connectedComponent, diff --git a/src/main/webapp/wise5/components/label/labelController.ts b/src/main/webapp/wise5/components/label/labelController.ts index d35998eabb..4ec371c648 100644 --- a/src/main/webapp/wise5/components/label/labelController.ts +++ b/src/main/webapp/wise5/components/label/labelController.ts @@ -207,12 +207,6 @@ class LabelController extends ComponentController { this.canvasId = 'labelCanvas_gradingRevision_' + componentState.id; } } - } else if (this.mode === 'onlyShowWork') { - this.isPromptVisible = false; - this.isSaveButtonVisible = false; - this.isSubmitButtonVisible = false; - this.isNewLabelButtonVisible = false; - this.isDisabled = true; } else if (this.mode === 'showPreviousWork') { this.isPromptVisible = true; this.isSaveButtonVisible = false; diff --git a/src/main/webapp/wise5/components/match/matchController.ts b/src/main/webapp/wise5/components/match/matchController.ts index e9058e7483..2e695b876f 100644 --- a/src/main/webapp/wise5/components/match/matchController.ts +++ b/src/main/webapp/wise5/components/match/matchController.ts @@ -133,11 +133,6 @@ class MatchController extends ComponentController { if (this.shouldImportPrivateNotes()) { this.privateNotebookItems = this.NotebookService.getPrivateNotebookItems(this.workgroupId); } - } else if (this.mode === 'onlyShowWork') { - this.isPromptVisible = false; - this.isSaveButtonVisible = false; - this.isSubmitButtonVisible = false; - this.isDisabled = true; } else if (this.mode === 'showPreviousWork') { this.isPromptVisible = true; this.isSaveButtonVisible = false; diff --git a/src/main/webapp/wise5/components/multipleChoice/multipleChoiceController.ts b/src/main/webapp/wise5/components/multipleChoice/multipleChoiceController.ts index 81b28f7110..e19d518066 100644 --- a/src/main/webapp/wise5/components/multipleChoice/multipleChoiceController.ts +++ b/src/main/webapp/wise5/components/multipleChoice/multipleChoiceController.ts @@ -90,11 +90,6 @@ class MultipleChoiceController extends ComponentController { this.isSaveButtonVisible = false; this.isSubmitButtonVisible = false; this.isDisabled = true; - } else if (this.mode === 'onlyShowWork') { - this.isPromptVisible = false; - this.isSaveButtonVisible = false; - this.isSubmitButtonVisible = false; - this.isDisabled = true; } else if (this.mode === 'showPreviousWork') { this.isPromptVisible = true; this.isSaveButtonVisible = false; diff --git a/src/main/webapp/wise5/components/openResponse/openResponseController.ts b/src/main/webapp/wise5/components/openResponse/openResponseController.ts index 0096caac71..4fa7830350 100644 --- a/src/main/webapp/wise5/components/openResponse/openResponseController.ts +++ b/src/main/webapp/wise5/components/openResponse/openResponseController.ts @@ -16,7 +16,6 @@ class OpenResponseController extends ComponentController { OpenResponseService: OpenResponseService; studentResponse: string; isRichTextEnabled: boolean; - onlyShowWork: boolean; messageDialog: any; tinymceOptions: any; isRecordingAudio: boolean = false; @@ -95,9 +94,6 @@ class OpenResponseController extends ComponentController { // whether rich text editing is enabled this.isRichTextEnabled = false; - // whether we're only showing the student work - this.onlyShowWork = false; - // used to hold a message dialog if we need to use one this.messageDialog = null; @@ -145,12 +141,6 @@ class OpenResponseController extends ComponentController { this.isSaveButtonVisible = false; this.isSubmitButtonVisible = false; this.isDisabled = true; - } else if (this.mode === 'onlyShowWork') { - this.onlyShowWork = true; - this.isPromptVisible = false; - this.isSaveButtonVisible = false; - this.isSubmitButtonVisible = false; - this.isDisabled = true; } else if (this.mode === 'showPreviousWork') { this.isPromptVisible = true; this.isSaveButtonVisible = false; diff --git a/src/main/webapp/wise5/components/table/tableController.ts b/src/main/webapp/wise5/components/table/tableController.ts index 102131dec7..6a1fd4f0a4 100644 --- a/src/main/webapp/wise5/components/table/tableController.ts +++ b/src/main/webapp/wise5/components/table/tableController.ts @@ -116,12 +116,6 @@ class TableController extends ComponentController { this.isSubmitButtonVisible = false; this.isResetTableButtonVisible = false; this.isDisabled = true; - } else if (this.mode === 'onlyShowWork') { - this.isPromptVisible = false; - this.isSaveButtonVisible = false; - this.isSubmitButtonVisible = false; - this.isResetTableButtonVisible = false; - this.isDisabled = true; } else if (this.mode === 'showPreviousWork') { this.isPromptVisible = true; this.isSaveButtonVisible = false; diff --git a/src/main/webapp/wise5/vle/node/nodeController.ts b/src/main/webapp/wise5/vle/node/nodeController.ts index b461af3089..93f783bf80 100644 --- a/src/main/webapp/wise5/vle/node/nodeController.ts +++ b/src/main/webapp/wise5/vle/node/nodeController.ts @@ -45,7 +45,6 @@ class NodeController { '$compile', '$filter', '$q', - '$rootScope', '$scope', '$state', '$timeout', @@ -63,7 +62,6 @@ class NodeController { private $compile: any, $filter: any, private $q: any, - private $rootScope: any, private $scope: any, private $state: any, private $timeout: any, @@ -76,18 +74,6 @@ class NodeController { private StudentDataService: StudentDataService, private UtilService: UtilService ) { - this.$compile = $compile; - this.$q = $q; - this.$rootScope = $rootScope; - this.$scope = $scope; - this.$state = $state; - this.$timeout = $timeout; - this.AnnotationService = AnnotationService; - this.ConfigService = ConfigService; - this.NodeService = NodeService; - this.ProjectService = ProjectService; - this.StudentDataService = StudentDataService; - this.UtilService = UtilService; this.$translate = $filter('translate'); this.autoSaveInterval = 60000; // in milliseconds this.nodeId = null; @@ -121,11 +107,8 @@ class NodeController { this.rubric = null; this.mode = this.ConfigService.getMode(); - // perform setup of this node only if the current node is not a group. - if ( - this.StudentDataService.getCurrentNode() && - this.ProjectService.isApplicationNode(this.StudentDataService.getCurrentNodeId()) - ) { + if (this.StudentDataService.getCurrentNode() && + this.ProjectService.isApplicationNode(this.StudentDataService.getCurrentNodeId())) { const currentNode = this.StudentDataService.getCurrentNode(); if (currentNode != null) { this.nodeId = currentNode.id; @@ -199,10 +182,6 @@ class NodeController { } }); - /** - * Listen for the componentSubmitTriggered event which occurs when a - * component is requesting student data to be submitted - */ this.componentSubmitTriggeredSubscription = this.StudentDataService.componentSubmitTriggered$.subscribe(({ nodeId, componentId }) => { if (this.nodeId == nodeId && this.nodeContainsComponent(componentId)) { @@ -230,18 +209,7 @@ class NodeController { this.NodeService.broadcastSiblingComponentStudentDataChanged(componentStudentData); }); - this.$scope.$on('$destroy', () => { - this.componentDirtySubscription.unsubscribe(); - this.componentSaveTriggeredSubscription.unsubscribe(); - this.componentStudentDataSubscription.unsubscribe(); - this.componentSubmitDirtySubscription.unsubscribe(); - this.componentSubmitTriggeredSubscription.unsubscribe(); - }); - - /** - * Listen for the componentDirty observable that will come from child components. - */ - this.componentDirtySubscription = + this.componentDirtySubscription = this.StudentDataService.componentDirty$.subscribe(({ componentId, isDirty }) => { const index = this.dirtyComponentIds.indexOf(componentId); if (isDirty && index === -1) { @@ -251,10 +219,7 @@ class NodeController { } }); - /** - * Listen for the componentSubmitDirty observable that will come from child components. - */ - this.componentSubmitDirtySubscription = + this.componentSubmitDirtySubscription = this.StudentDataService.componentSubmitDirty$.subscribe(({ componentId, isDirty }) => { const index = this.dirtySubmitComponentIds.indexOf(componentId); if (isDirty && index === -1) { @@ -279,17 +244,19 @@ class NodeController { ngOnDestroy() { this.stopAutoSaveInterval(); this.nodeUnloaded(this.nodeId); - if ( - this.NodeService.currentNodeHasTransitionLogic() && - this.NodeService.evaluateTransitionLogicOn('exitNode') - ) { + if (this.NodeService.currentNodeHasTransitionLogic() && + this.NodeService.evaluateTransitionLogicOn('exitNode')) { this.NodeService.evaluateTransitionLogic(); } this.unsubscribeAll(); } unsubscribeAll() { + this.componentDirtySubscription.unsubscribe(); + this.componentSaveTriggeredSubscription.unsubscribe(); this.componentStudentDataSubscription.unsubscribe(); + this.componentSubmitDirtySubscription.unsubscribe(); + this.componentSubmitTriggeredSubscription.unsubscribe(); this.exitSubscription.unsubscribe(); } @@ -994,9 +961,8 @@ class NodeController { getSubmitDirty() { const components = this.getComponents(); if (components != null) { - for (let component of components) { - const componentId = component.id; - const latestState = this.getComponentStateByComponentId(componentId); + for (const component of components) { + const latestState = this.getComponentStateByComponentId(component.id); if (latestState && !latestState.isSubmit) { return true; } From 55fd36a0fb02b0df001abd23dde93e502483b7c7 Mon Sep 17 00:00:00 2001 From: Hiroki Terashima Date: Mon, 2 Nov 2020 11:41:51 -0800 Subject: [PATCH 02/15] Upgraded HelpIcon component to Angular. Needed to tweak tsconfig to compile theme directory. #2773 --- src/main/webapp/site/src/app/hybrid-module.ts | 2 + src/main/webapp/site/src/messages.xlf | 28 ++++++------- src/main/webapp/site/src/tsconfig.app.json | 1 + src/main/webapp/wise5/services/nodeService.ts | 6 +++ .../wise5/themes/default/node/node.html | 18 ++++----- ...{themeComponents.js => themeComponents.ts} | 7 +++- .../helpIcon/help-icon.component.html | 9 +++++ .../helpIcon/help-icon.component.scss | 22 +++++++++++ .../helpIcon/help-icon.component.ts | 39 +++++++++++++++++++ .../themeComponents/helpIcon/helpIcon.js | 34 ---------------- .../webapp/wise5/vle/node/nodeController.ts | 13 ++++--- 11 files changed, 114 insertions(+), 65 deletions(-) rename src/main/webapp/wise5/themes/default/{themeComponents.js => themeComponents.ts} (81%) create mode 100644 src/main/webapp/wise5/themes/default/themeComponents/helpIcon/help-icon.component.html create mode 100644 src/main/webapp/wise5/themes/default/themeComponents/helpIcon/help-icon.component.scss create mode 100644 src/main/webapp/wise5/themes/default/themeComponents/helpIcon/help-icon.component.ts delete mode 100644 src/main/webapp/wise5/themes/default/themeComponents/helpIcon/helpIcon.js diff --git a/src/main/webapp/site/src/app/hybrid-module.ts b/src/main/webapp/site/src/app/hybrid-module.ts index 7c3fbd847a..d3bb684746 100644 --- a/src/main/webapp/site/src/app/hybrid-module.ts +++ b/src/main/webapp/site/src/app/hybrid-module.ts @@ -71,6 +71,7 @@ import { ChooseImportStepComponent } from './authoring-tool/import-step/choose-i import { ChooseImportStepLocationComponent } from './authoring-tool/import-step/choose-import-step-location/choose-import-step-location.component'; import { ComponentNewWorkBadgeComponent } from './classroom-monitor/component-new-work-badge/component-new-work-badge.component'; import { StatusIconComponent } from './classroom-monitor/status-icon/status-icon.component'; +import { HelpIconComponent } from '../../../wise5/themes/default/themeComponents/helpIcon/help-icon.component'; @Component({template: ``}) export class EmptyComponent {} @@ -78,6 +79,7 @@ export class EmptyComponent {} @NgModule({ declarations: [ EmptyComponent, + HelpIconComponent, NodeIconComponent, ], imports: [ diff --git a/src/main/webapp/site/src/messages.xlf b/src/main/webapp/site/src/messages.xlf index 92504ef1d8..68c80bfa4b 100644 --- a/src/main/webapp/site/src/messages.xlf +++ b/src/main/webapp/site/src/messages.xlf @@ -5268,20 +5268,6 @@ 120 - - point - - app/possible-score/possible-score.component.html - 3 - - - - points - - app/possible-score/possible-score.component.html - 4 - - Choose a Branch Path @@ -5296,6 +5282,20 @@ 3 + + point + + app/possible-score/possible-score.component.html + 3 + + + + points + + app/possible-score/possible-score.component.html + 4 + + Back to Unit Plan diff --git a/src/main/webapp/site/src/tsconfig.app.json b/src/main/webapp/site/src/tsconfig.app.json index 6c09e861e9..fe174aa020 100644 --- a/src/main/webapp/site/src/tsconfig.app.json +++ b/src/main/webapp/site/src/tsconfig.app.json @@ -13,6 +13,7 @@ "polyfills.ts" ], "include": [ + "../../wise5/themes/**/*.ts" ], "exclude": ["test.ts", "**/*.spec.ts"] } diff --git a/src/main/webapp/wise5/services/nodeService.ts b/src/main/webapp/wise5/services/nodeService.ts index 51d40403d4..bbaa499f60 100644 --- a/src/main/webapp/wise5/services/nodeService.ts +++ b/src/main/webapp/wise5/services/nodeService.ts @@ -22,6 +22,8 @@ export class NodeService { private componentShowSubmitButtonValueChangedSource: Subject = new Subject(); public componentShowSubmitButtonValueChanged$: Observable = this.componentShowSubmitButtonValueChangedSource.asObservable(); + private showRubricSource: Subject = new Subject(); + public showRubric$: Observable = this.showRubricSource.asObservable(); private siblingComponentStudentDataChangedSource: Subject = new Subject(); public siblingComponentStudentDataChanged$: Observable = this.siblingComponentStudentDataChangedSource.asObservable(); @@ -825,4 +827,8 @@ export class NodeService { respondStarterState(args: any) { this.starterStateResponseSource.next(args); } + + showRubric(id: string) : void { + this.showRubricSource.next(id); + } } diff --git a/src/main/webapp/wise5/themes/default/node/node.html b/src/main/webapp/wise5/themes/default/node/node.html index 673d5492f5..0b7d7b730d 100644 --- a/src/main/webapp/wise5/themes/default/node/node.html +++ b/src/main/webapp/wise5/themes/default/node/node.html @@ -6,22 +6,20 @@
+ rubric-id="{{nodeController.nodeId}}" + [pulse]="!nodeController.rubricTour.steps[0].viewed" + label="{{ 'STEP_INFO' | translate}}" + icon="info">
+ rubric-id="{{component.id}}" + [pulse]="!nodeController.rubricTour.steps[$index].viewed" + label="{{ 'TEACHING_TIPS' | translate }}" + icon="info">
+ +
diff --git a/src/main/webapp/wise5/themes/default/themeComponents/helpIcon/help-icon.component.scss b/src/main/webapp/wise5/themes/default/themeComponents/helpIcon/help-icon.component.scss new file mode 100644 index 0000000000..6bdc33dc7b --- /dev/null +++ b/src/main/webapp/wise5/themes/default/themeComponents/helpIcon/help-icon.component.scss @@ -0,0 +1,22 @@ +mat-icon { + color: #ef6c00!important; + font-size: 36px; + width: 36px; + min-width: 0; +} + +.pulse { + animation: pulse 4s infinite; +} + +@keyframes pulse { + 0% { + box-shadow: 0 0 0 0 rgb(0,0,0,0); + } + 50% { + box-shadow: 0 0 0 10px #ef6c00; + } + 100% { + box-shadow: 0 0 0 0 #ef6c00; + } +} diff --git a/src/main/webapp/wise5/themes/default/themeComponents/helpIcon/help-icon.component.ts b/src/main/webapp/wise5/themes/default/themeComponents/helpIcon/help-icon.component.ts new file mode 100644 index 0000000000..ab76f96dc5 --- /dev/null +++ b/src/main/webapp/wise5/themes/default/themeComponents/helpIcon/help-icon.component.ts @@ -0,0 +1,39 @@ +"use strict"; + +import { Component, Input } from "@angular/core"; +import { NodeService } from "../../../../services/nodeService"; + +@Component({ + selector: 'help-icon', + styleUrls: ['help-icon.component.scss'], + templateUrl: 'help-icon.component.html' +}) +export class HelpIconComponent { + + @Input() + color: string; + + @Input() + customClass: string; + + @Input() + icon: string; + + @Input() + iconClass: string; + + @Input() + label: string; + + @Input() + pulse: boolean; + + @Input() + rubricId: string; + + constructor(private NodeService: NodeService) {} + + showRubric() { + this.NodeService.showRubric(this.rubricId); + } +} diff --git a/src/main/webapp/wise5/themes/default/themeComponents/helpIcon/helpIcon.js b/src/main/webapp/wise5/themes/default/themeComponents/helpIcon/helpIcon.js deleted file mode 100644 index 23fb6229d2..0000000000 --- a/src/main/webapp/wise5/themes/default/themeComponents/helpIcon/helpIcon.js +++ /dev/null @@ -1,34 +0,0 @@ -"use strict"; - -class HelpIconController { - constructor() { - }; - - click() { - this.onClick(); - } -} - -//HelpIconController.$inject = []; - -const HelpIcon = { - bindings: { - color: '<', - customClass: '<', - icon: '<', - iconClass: '<', - pulse: '<', - onClick: '&' - }, - controller: HelpIconController, - template: - `
- - {{ $ctrl.icon }} - -
` -}; - -export default HelpIcon; diff --git a/src/main/webapp/wise5/vle/node/nodeController.ts b/src/main/webapp/wise5/vle/node/nodeController.ts index b461af3089..6b8281f547 100644 --- a/src/main/webapp/wise5/vle/node/nodeController.ts +++ b/src/main/webapp/wise5/vle/node/nodeController.ts @@ -37,6 +37,7 @@ class NodeController { rubric: any; rubricTour: any; saveMessage: any; + showRubricSubscription: Subscription; submit: any; teacherWorkgroupId: number; workgroupId: number; @@ -241,7 +242,7 @@ class NodeController { /** * Listen for the componentDirty observable that will come from child components. */ - this.componentDirtySubscription = + this.componentDirtySubscription = this.StudentDataService.componentDirty$.subscribe(({ componentId, isDirty }) => { const index = this.dirtyComponentIds.indexOf(componentId); if (isDirty && index === -1) { @@ -254,7 +255,7 @@ class NodeController { /** * Listen for the componentSubmitDirty observable that will come from child components. */ - this.componentSubmitDirtySubscription = + this.componentSubmitDirtySubscription = this.StudentDataService.componentSubmitDirty$.subscribe(({ componentId, isDirty }) => { const index = this.dirtySubmitComponentIds.indexOf(componentId); if (isDirty && index === -1) { @@ -264,6 +265,10 @@ class NodeController { } }); + this.showRubricSubscription = this.NodeService.showRubric$.subscribe((id: string) => { + this.showRubric(id); + }); + const script = this.nodeContent.script; if (script != null) { this.ProjectService.retrieveScript(script).then((script: string) => { @@ -291,6 +296,7 @@ class NodeController { unsubscribeAll() { this.componentStudentDataSubscription.unsubscribe(); this.exitSubscription.unsubscribe(); + this.showRubricSubscription.unsubscribe(); } createRubricTour() { @@ -355,8 +361,6 @@ class NodeController { if (this.rubricTour) { let step = -1; let index = 0; - - let thisTarget = '#nodeRubric_' + this.nodeId; if (this.nodeId === id) { step = index; } @@ -369,7 +373,6 @@ class NodeController { const components = this.getComponents(); for (let component of components) { if (component.rubric) { - thisTarget = '#rubric_' + component.id; if (component.id === id) { step = index; break; From 353ef0fbd85b9107413620b0c4b5a66b0c21720f Mon Sep 17 00:00:00 2001 From: Hiroki Terashima Date: Mon, 2 Nov 2020 13:14:05 -0800 Subject: [PATCH 03/15] Upgrade NodeAdvancedJSONAuthoring component to Angular. #2782 --- src/main/webapp/site/src/app/hybrid-module.ts | 2 + src/main/webapp/site/src/messages.xlf | 7 ++++ ...ode-advanced-json-authoring.component.html | 15 +++----- .../node-advanced-json-authoring.component.ts | 38 ++++++++++++------- .../teacher/teacher-angular-js-module.ts | 3 +- 5 files changed, 40 insertions(+), 25 deletions(-) diff --git a/src/main/webapp/site/src/app/hybrid-module.ts b/src/main/webapp/site/src/app/hybrid-module.ts index 7c3fbd847a..e9a300e8ba 100644 --- a/src/main/webapp/site/src/app/hybrid-module.ts +++ b/src/main/webapp/site/src/app/hybrid-module.ts @@ -71,6 +71,7 @@ import { ChooseImportStepComponent } from './authoring-tool/import-step/choose-i import { ChooseImportStepLocationComponent } from './authoring-tool/import-step/choose-import-step-location/choose-import-step-location.component'; import { ComponentNewWorkBadgeComponent } from './classroom-monitor/component-new-work-badge/component-new-work-badge.component'; import { StatusIconComponent } from './classroom-monitor/status-icon/status-icon.component'; +import { NodeAdvancedJsonAuthoringComponent } from '../../../wise5/authoringTool/node/advanced/json/node-advanced-json-authoring.component'; @Component({template: ``}) export class EmptyComponent {} @@ -209,6 +210,7 @@ export class PreviewAngularJSModule { ComponentNewWorkBadgeComponent, ManageStudentsComponent, MilestoneReportDataComponent, + NodeAdvancedJsonAuthoringComponent, StatusIconComponent, WorkgroupNodeScoreComponent, NavItemScoreComponent diff --git a/src/main/webapp/site/src/messages.xlf b/src/main/webapp/site/src/messages.xlf index 92504ef1d8..770af41858 100644 --- a/src/main/webapp/site/src/messages.xlf +++ b/src/main/webapp/site/src/messages.xlf @@ -5487,6 +5487,13 @@ 1
+ + Edit Step JSON + + ../../wise5/authoringTool/node/advanced/json/node-advanced-json-authoring.component.html + 2 + + Teacher Home diff --git a/src/main/webapp/wise5/authoringTool/node/advanced/json/node-advanced-json-authoring.component.html b/src/main/webapp/wise5/authoringTool/node/advanced/json/node-advanced-json-authoring.component.html index 0420077e20..e4b9a746f5 100644 --- a/src/main/webapp/wise5/authoringTool/node/advanced/json/node-advanced-json-authoring.component.html +++ b/src/main/webapp/wise5/authoringTool/node/advanced/json/node-advanced-json-authoring.component.html @@ -1,10 +1,5 @@ -
-
{{ ::'editActivityJSON' | translate }}
-
{{ ::'editStepJSON' | translate }}
- - - -
+ + Edit Step JSON + + diff --git a/src/main/webapp/wise5/authoringTool/node/advanced/json/node-advanced-json-authoring.component.ts b/src/main/webapp/wise5/authoringTool/node/advanced/json/node-advanced-json-authoring.component.ts index 5d7a131886..3c0488e315 100644 --- a/src/main/webapp/wise5/authoringTool/node/advanced/json/node-advanced-json-authoring.component.ts +++ b/src/main/webapp/wise5/authoringTool/node/advanced/json/node-advanced-json-authoring.component.ts @@ -2,25 +2,44 @@ import { TeacherDataService } from "../../../../services/teacherDataService"; import { TeacherProjectService } from "../../../../services/teacherProjectService"; import * as angular from 'angular'; import { NotificationService } from "../../../../services/notificationService"; +import { Component } from "@angular/core"; +import { Subject, Subscription } from "rxjs"; +import { debounceTime, distinctUntilChanged } from "rxjs/operators"; -class NodeAdvancedJsonAuthoringController { +@Component({ + templateUrl: 'node-advanced-json-authoring.component.html' +}) +export class NodeAdvancedJsonAuthoringComponent { - nodeContentJSONString: string; node: any; + nodeContentJSONString: string; + nodeContentChanged: Subject = new Subject(); + nodeContentChangedSubscription: Subscription; nodeId: string; - static $inject = ['NotificationService', 'ProjectService', 'TeacherDataService']; - constructor(private NotificationService: NotificationService, private ProjectService: TeacherProjectService, private TeacherDataService: TeacherDataService) { } - $onInit() { + ngOnInit() { this.nodeId = this.TeacherDataService.getCurrentNodeId(); this.node = this.ProjectService.getNodeById(this.nodeId); this.nodeContentJSONString = angular.toJson(this.node, 4); this.NotificationService.showJSONValidMessage(); + this.nodeContentChangedSubscription = this.nodeContentChanged + .pipe( + debounceTime(1000), + distinctUntilChanged() + ) + .subscribe(newText => { + this.nodeContentJSONString = newText; + this.autoSaveJSON(); + }); + } + + ngOnDestroy() { + this.nodeContentChangedSubscription.unsubscribe(); } autoSaveJSON() { @@ -36,13 +55,4 @@ class NodeAdvancedJsonAuthoringController { this.NotificationService.showJSONInvalidMessage(); } } - - isGroupNode(nodeId) { - return this.ProjectService.isGroupNode(nodeId); - } -} - -export const NodeAdvancedJsonAuthoringComponent = { - templateUrl: `/wise5/authoringTool/node/advanced/json/node-advanced-json-authoring.component.html`, - controller: NodeAdvancedJsonAuthoringController } diff --git a/src/main/webapp/wise5/teacher/teacher-angular-js-module.ts b/src/main/webapp/wise5/teacher/teacher-angular-js-module.ts index fcd2790da1..a1a112ca59 100644 --- a/src/main/webapp/wise5/teacher/teacher-angular-js-module.ts +++ b/src/main/webapp/wise5/teacher/teacher-angular-js-module.ts @@ -104,7 +104,8 @@ export function createTeacherAngularJSModule() { .component('nodeAdvancedBranchAuthoringComponent', NodeAdvancedBranchAuthoringComponent) .component('nodeAdvancedConstraintAuthoringComponent', NodeAdvancedConstraintAuthoringComponent) .component('nodeAdvancedGeneralAuthoringComponent', NodeAdvancedGeneralAuthoringComponent) - .component('nodeAdvancedJsonAuthoringComponent', NodeAdvancedJsonAuthoringComponent) + .directive('nodeAdvancedJsonAuthoringComponent', downgradeComponent( + { component: NodeAdvancedJsonAuthoringComponent }) as angular.IDirectiveFactory) .component('nodeAdvancedPathAuthoringComponent', NodeAdvancedPathAuthoringComponent) .directive('advancedProjectAuthoringComponent', downgradeComponent( { component: AdvancedProjectAuthoringComponent }) as angular.IDirectiveFactory) From b1c4f4c9692356c1e1c80a0794b8b1695bc86de8 Mon Sep 17 00:00:00 2001 From: Hiroki Terashima Date: Tue, 3 Nov 2020 08:27:56 -0800 Subject: [PATCH 04/15] Removed createCommonModule(). --- src/main/webapp/site/src/app/hybrid-module.ts | 13 +++++-------- src/main/webapp/wise5/common-angular-js-module.ts | 4 +--- .../wise5/teacher/teacher-angular-js-module.ts | 7 ++----- .../webapp/wise5/vle/student-angular-js-module.ts | 3 +-- 4 files changed, 9 insertions(+), 18 deletions(-) diff --git a/src/main/webapp/site/src/app/hybrid-module.ts b/src/main/webapp/site/src/app/hybrid-module.ts index 7c3fbd847a..ac6fa0765f 100644 --- a/src/main/webapp/site/src/app/hybrid-module.ts +++ b/src/main/webapp/site/src/app/hybrid-module.ts @@ -2,8 +2,8 @@ import { Component, NgModule } from '@angular/core'; import { RouterModule } from '@angular/router'; import { FlexLayoutModule } from '@angular/flex-layout'; -import { createStudentAngularJSModule } from '../../../wise5/vle/student-angular-js-module'; -import { createTeacherAngularJSModule } from '../../../wise5/teacher/teacher-angular-js-module'; +import { createStudentAngularJSModule} from '../../../wise5/vle/student-angular-js-module'; +import '../../../wise5/teacher/teacher-angular-js-module'; import { UpgradeModule } from '@angular/upgrade/static'; import { setUpLocationSync } from '@angular/router/upgrade'; import { UtilService } from '../../../wise5/services/utilService'; @@ -235,12 +235,9 @@ export class TeacherAngularJSModule { } function bootstrapAngularJSModule(upgrade: UpgradeModule, moduleType: string) { - let module; - if (moduleType === 'teacher') { - module = createTeacherAngularJSModule(); - } else { - module = createStudentAngularJSModule(moduleType); + if (moduleType !== 'teacher') { + createStudentAngularJSModule(moduleType); } - upgrade.bootstrap(document.body, [module.name]); + upgrade.bootstrap(document.body, [moduleType]); setUpLocationSync(upgrade); } diff --git a/src/main/webapp/wise5/common-angular-js-module.ts b/src/main/webapp/wise5/common-angular-js-module.ts index 6991ec385a..80aadeb91f 100644 --- a/src/main/webapp/wise5/common-angular-js-module.ts +++ b/src/main/webapp/wise5/common-angular-js-module.ts @@ -69,8 +69,7 @@ window['Stomp'] = StompJS.Stomp; import './lib/angular-summernote/dist/angular-summernote.min'; import './themes/default/theme'; -export function createCommonModule() { - return angular.module('common', [ + angular.module('common', [ angularDragula(angular), 'angularMoment', 'angular-toArrayFilter', @@ -207,4 +206,3 @@ export function createCommonModule() { } }); }]); -} diff --git a/src/main/webapp/wise5/teacher/teacher-angular-js-module.ts b/src/main/webapp/wise5/teacher/teacher-angular-js-module.ts index fcd2790da1..5e91589de1 100644 --- a/src/main/webapp/wise5/teacher/teacher-angular-js-module.ts +++ b/src/main/webapp/wise5/teacher/teacher-angular-js-module.ts @@ -2,7 +2,7 @@ import '../lib/jquery/jquery-global'; import '../lib/bootstrap/js/bootstrap.min' import * as angular from 'angular'; import { downgradeComponent, downgradeInjectable } from '@angular/upgrade/static'; -import { createCommonModule } from '../common-angular-js-module'; +import '../common-angular-js-module'; import { MilestoneService } from '../services/milestoneService'; import { TeacherProjectService } from '../services/teacherProjectService'; import { ProjectAssetService } from '../../site/src/app/services/projectAssetService'; @@ -62,9 +62,7 @@ import '../lib/summernote/dist/summernote.min'; import '../lib/summernoteExtensions/summernote-ext-addNote.js'; import '../lib/summernoteExtensions/summernote-ext-print.js' -export function createTeacherAngularJSModule() { - createCommonModule(); - return angular.module('teacher', [ + angular.module('teacher', [ 'common', 'angular-inview', 'addComponentModule', @@ -483,4 +481,3 @@ export function createTeacherAngularJSModule() { $mdThemingProvider.setDefaultTheme('at'); } ]); - } diff --git a/src/main/webapp/wise5/vle/student-angular-js-module.ts b/src/main/webapp/wise5/vle/student-angular-js-module.ts index 70d599103e..853f50b30d 100644 --- a/src/main/webapp/wise5/vle/student-angular-js-module.ts +++ b/src/main/webapp/wise5/vle/student-angular-js-module.ts @@ -2,7 +2,7 @@ import '../lib/jquery/jquery-global'; import '../lib/bootstrap/js/bootstrap.min' import * as angular from 'angular'; import { downgradeInjectable } from '@angular/upgrade/static'; -import { createCommonModule } from '../common-angular-js-module'; +import '../common-angular-js-module'; import Filters from '../filters/filters'; import NavigationController from '../vle/navigation/navigationController'; import NodeController from '../vle/node/nodeController'; @@ -14,7 +14,6 @@ import '../lib/summernoteExtensions/summernote-ext-addNote.js'; import '../lib/summernoteExtensions/summernote-ext-print.js' export function createStudentAngularJSModule(type = 'preview') { - createCommonModule(); return angular.module(type, [ 'common', 'ngOnload', From 66bf68342e14ac10681c8764599b14acc3446cc4 Mon Sep 17 00:00:00 2001 From: Hiroki Terashima Date: Tue, 3 Nov 2020 10:02:59 -0800 Subject: [PATCH 05/15] Divided student and teacher hybrid modules into separate files and put common modules in common-hybrid-angular.module file. #2788 --- ...ule.ts => common-hybrid-angular.module.ts} | 113 ----- .../site/src/app/preview/preview.module.ts | 2 +- .../src/app/student-hybrid-angular.module.ts | 68 +++ .../src/app/student/student-routing.module.ts | 2 +- .../src/app/teacher-hybrid-angular.module.ts | 66 +++ .../src/app/teacher/teacher-routing.module.ts | 2 +- src/main/webapp/site/src/messages.xlf | 390 +++++++++--------- .../webapp/wise5/common-angular-js-module.ts | 2 + .../wise5/vle/student-angular-js-module.ts | 2 - 9 files changed, 334 insertions(+), 313 deletions(-) rename src/main/webapp/site/src/app/{hybrid-module.ts => common-hybrid-angular.module.ts} (53%) create mode 100644 src/main/webapp/site/src/app/student-hybrid-angular.module.ts create mode 100644 src/main/webapp/site/src/app/teacher-hybrid-angular.module.ts diff --git a/src/main/webapp/site/src/app/hybrid-module.ts b/src/main/webapp/site/src/app/common-hybrid-angular.module.ts similarity index 53% rename from src/main/webapp/site/src/app/hybrid-module.ts rename to src/main/webapp/site/src/app/common-hybrid-angular.module.ts index ac6fa0765f..ef2b2a00d5 100644 --- a/src/main/webapp/site/src/app/hybrid-module.ts +++ b/src/main/webapp/site/src/app/common-hybrid-angular.module.ts @@ -2,10 +2,7 @@ import { Component, NgModule } from '@angular/core'; import { RouterModule } from '@angular/router'; import { FlexLayoutModule } from '@angular/flex-layout'; -import { createStudentAngularJSModule} from '../../../wise5/vle/student-angular-js-module'; -import '../../../wise5/teacher/teacher-angular-js-module'; import { UpgradeModule } from '@angular/upgrade/static'; -import { setUpLocationSync } from '@angular/router/upgrade'; import { UtilService } from '../../../wise5/services/utilService'; import { ConfigService } from '../../../wise5/services/configService'; import { ProjectService } from '../../../wise5/services/projectService'; @@ -15,20 +12,12 @@ import { SessionService } from '../../../wise5/services/sessionService'; import { StudentAssetService } from '../../../wise5/services/studentAssetService'; import { TagService } from '../../../wise5/services/tagService'; import { AudioRecorderService } from '../../../wise5/services/audioRecorderService'; -import { PossibleScoreComponent } from './possible-score/possible-score.component'; import { AnnotationService } from '../../../wise5/services/annotationService'; import { CommonModule } from '@angular/common'; import { StudentWebSocketService } from '../../../wise5/services/studentWebSocketService'; import { StudentDataService } from '../../../wise5/services/studentDataService'; import { AchievementService } from '../../../wise5/services/achievementService'; -import { MilestoneReportDataComponent } from './teacher/milestone/milestone-report-data/milestone-report-data.component'; -import { TeacherProjectService } from '../../../wise5/services/teacherProjectService'; -import { ProjectAssetService } from './services/projectAssetService'; -import { SpaceService } from '../../../wise5/services/spaceService'; -import { StudentStatusService } from '../../../wise5/services/studentStatusService'; import { SummaryService } from '../../../wise5/components/summary/summaryService'; -import { TeacherDataService } from '../../../wise5/services/teacherDataService'; -import { TeacherWebSocketService } from '../../../wise5/services/teacherWebSocketService'; import { TableService } from '../../../wise5/components/table/tableService'; import { NotebookService } from '../../../wise5/services/notebookService'; import { NotificationService } from '../../../wise5/services/notificationService'; @@ -38,10 +27,8 @@ import { MultipleChoiceService } from '../../../wise5/components/multipleChoice/ import { OpenResponseService } from '../../../wise5/components/openResponse/openResponseService'; import { NodeService } from '../../../wise5/services/nodeService'; import { MatDialogModule } from '@angular/material/dialog'; -import { ChooseBranchPathDialogComponent } from './preview/modules/choose-branch-path-dialog/choose-branch-path-dialog.component'; import { MatButtonModule } from '@angular/material/button'; import { MatListModule } from '@angular/material/list'; -import { DataService } from './services/data.service'; import { DiscussionService } from '../../../wise5/components/discussion/discussionService'; import { DrawService } from '../../../wise5/components/draw/drawService'; import { EmbeddedService } from '../../../wise5/components/embedded/embeddedService'; @@ -50,27 +37,16 @@ import { LabelService } from '../../../wise5/components/label/labelService'; import { AnimationService } from '../../../wise5/components/animation/animationService'; import { AudioOscillatorService } from '../../../wise5/components/audioOscillator/audioOscillatorService'; import { ConceptMapService } from '../../../wise5/components/conceptMap/conceptMapService'; -import { MilestoneService } from '../../../wise5/services/milestoneService'; import { GraphService } from '../../../wise5/components/graph/graphService'; -import { WorkgroupNodeScoreComponent } from '../../../wise5/classroomMonitor/classroomMonitorComponents/shared/workgroupNodeScore/workgroup-node-score.component'; -import { NavItemScoreComponent } from '../../../wise5/classroomMonitor/classroomMonitorComponents/nodeProgress/navItemScore/nav-item-score.component'; import { NodeIconComponent } from '../../../wise5/classroomMonitor/classroomMonitorComponents/shared/nodeIcon/node-icon.component'; import { MatFormFieldModule } from '@angular/material/form-field'; import { MatIconModule } from '@angular/material/icon'; import { MatInputModule } from '@angular/material/input'; import { MatTooltipModule } from '@angular/material/tooltip'; -import { ManageStudentsComponent } from '../../../wise5/classroomMonitor/manageStudents/manage-students-component'; -import { AdvancedProjectAuthoringComponent } from '../../../wise5/authoringTool/advanced/advanced-project-authoring.component'; import { FormsModule, ReactiveFormsModule } from '@angular/forms'; import { MatCardModule } from '@angular/material/card'; import { MatCheckboxModule } from '@angular/material/checkbox'; import { MatSelectModule } from '@angular/material/select'; -import { ChooseNewComponent } from './authoring-tool/add-component/choose-new-component/choose-new-component.component'; -import { ChooseNewComponentLocation } from './authoring-tool/add-component/choose-new-component-location/choose-new-component-location.component'; -import { ChooseImportStepComponent } from './authoring-tool/import-step/choose-import-step/choose-import-step.component'; -import { ChooseImportStepLocationComponent } from './authoring-tool/import-step/choose-import-step-location/choose-import-step-location.component'; -import { ComponentNewWorkBadgeComponent } from './classroom-monitor/component-new-work-badge/component-new-work-badge.component'; -import { StatusIconComponent } from './classroom-monitor/status-icon/status-icon.component'; @Component({template: ``}) export class EmptyComponent {} @@ -152,92 +128,3 @@ export class EmptyComponent {} ] }) export class AngularJSModule {} - -@NgModule({ - declarations: [ - PossibleScoreComponent - ], - imports: [ - AngularJSModule - ], - providers: [ - { provide: DataService, useExisting: StudentDataService }, - { provide: ProjectService, useExisting: VLEProjectService }, - VLEProjectService - ], - exports: [ - CommonModule, - MatButtonModule, - MatDialogModule, - MatListModule - ] -}) -export class StudentAngularJSModule {} - -@NgModule({ - declarations: [ - ChooseBranchPathDialogComponent - ], - imports: [ - StudentAngularJSModule - ] -}) -export class StudentVLEAngularJSModule { - constructor(upgrade: UpgradeModule) { - bootstrapAngularJSModule(upgrade, 'vle'); - } -} - -@NgModule({ - imports: [ - StudentAngularJSModule - ] -}) -export class PreviewAngularJSModule { - constructor(upgrade: UpgradeModule) { - bootstrapAngularJSModule(upgrade, 'preview'); - } -} - -@NgModule({ - declarations: [ - AdvancedProjectAuthoringComponent, - ChooseImportStepComponent, - ChooseImportStepLocationComponent, - ChooseNewComponent, - ChooseNewComponentLocation, - ComponentNewWorkBadgeComponent, - ManageStudentsComponent, - MilestoneReportDataComponent, - StatusIconComponent, - WorkgroupNodeScoreComponent, - NavItemScoreComponent - ], - imports: [ - AngularJSModule - ], - providers: [ - { provide: DataService, useExisting: TeacherDataService }, - MilestoneService, - ProjectAssetService, - SpaceService, - StudentStatusService, - { provide: ProjectService, useExisting: TeacherProjectService }, - TeacherDataService, - TeacherProjectService, - TeacherWebSocketService - ] -}) -export class TeacherAngularJSModule { - constructor(upgrade: UpgradeModule) { - bootstrapAngularJSModule(upgrade, 'teacher'); - } -} - -function bootstrapAngularJSModule(upgrade: UpgradeModule, moduleType: string) { - if (moduleType !== 'teacher') { - createStudentAngularJSModule(moduleType); - } - upgrade.bootstrap(document.body, [moduleType]); - setUpLocationSync(upgrade); -} diff --git a/src/main/webapp/site/src/app/preview/preview.module.ts b/src/main/webapp/site/src/app/preview/preview.module.ts index 931408352a..f6b7953b06 100644 --- a/src/main/webapp/site/src/app/preview/preview.module.ts +++ b/src/main/webapp/site/src/app/preview/preview.module.ts @@ -7,7 +7,7 @@ import { RouterModule } from '@angular/router'; { path: 'preview', children: [ - {path: '', loadChildren: () => import('../hybrid-module').then(m => m.PreviewAngularJSModule)} + {path: '', loadChildren: () => import('../student-hybrid-angular.module').then(m => m.PreviewAngularJSModule)} ] } ]) diff --git a/src/main/webapp/site/src/app/student-hybrid-angular.module.ts b/src/main/webapp/site/src/app/student-hybrid-angular.module.ts new file mode 100644 index 0000000000..8563282f74 --- /dev/null +++ b/src/main/webapp/site/src/app/student-hybrid-angular.module.ts @@ -0,0 +1,68 @@ +import { NgModule } from '@angular/core'; + +import { createStudentAngularJSModule} from '../../../wise5/vle/student-angular-js-module'; +import { UpgradeModule } from '@angular/upgrade/static'; +import { setUpLocationSync } from '@angular/router/upgrade'; +import { ProjectService } from '../../../wise5/services/projectService'; +import { VLEProjectService } from '../../../wise5/vle/vleProjectService'; +import { PossibleScoreComponent } from './possible-score/possible-score.component'; +import { CommonModule } from '@angular/common'; +import { StudentDataService } from '../../../wise5/services/studentDataService'; +import { MatDialogModule } from '@angular/material/dialog'; +import { ChooseBranchPathDialogComponent } from './preview/modules/choose-branch-path-dialog/choose-branch-path-dialog.component'; +import { MatButtonModule } from '@angular/material/button'; +import { MatListModule } from '@angular/material/list'; +import { DataService } from './services/data.service'; +import { AngularJSModule } from './common-hybrid-angular.module'; + +@NgModule({ + declarations: [ + PossibleScoreComponent + ], + imports: [ + AngularJSModule + ], + providers: [ + { provide: DataService, useExisting: StudentDataService }, + { provide: ProjectService, useExisting: VLEProjectService }, + VLEProjectService + ], + exports: [ + CommonModule, + MatButtonModule, + MatDialogModule, + MatListModule + ] +}) +export class StudentAngularJSModule {} + +@NgModule({ + declarations: [ + ChooseBranchPathDialogComponent + ], + imports: [ + StudentAngularJSModule + ] +}) +export class StudentVLEAngularJSModule { + constructor(upgrade: UpgradeModule) { + bootstrapAngularJSModule(upgrade, 'vle'); + } +} + +@NgModule({ + imports: [ + StudentAngularJSModule + ] +}) +export class PreviewAngularJSModule { + constructor(upgrade: UpgradeModule) { + bootstrapAngularJSModule(upgrade, 'preview'); + } +} + +function bootstrapAngularJSModule(upgrade: UpgradeModule, moduleType: string) { + createStudentAngularJSModule(moduleType); + upgrade.bootstrap(document.body, [moduleType]); + setUpLocationSync(upgrade); +} diff --git a/src/main/webapp/site/src/app/student/student-routing.module.ts b/src/main/webapp/site/src/app/student/student-routing.module.ts index c3b31fd8c6..ef19ef67c0 100644 --- a/src/main/webapp/site/src/app/student/student-routing.module.ts +++ b/src/main/webapp/site/src/app/student/student-routing.module.ts @@ -16,7 +16,7 @@ const studentRoutes: Routes = [ { path: 'home', component: StudentHomeComponent, pathMatch: 'full' }, { path: 'profile', redirectTo: '', pathMatch: 'full' }, { path: 'profile/edit', component: EditComponent }, - {path: '', loadChildren: () => import('../hybrid-module').then(m => m.StudentVLEAngularJSModule)} + {path: '', loadChildren: () => import('../student-hybrid-angular.module').then(m => m.StudentVLEAngularJSModule)} ] } ]; diff --git a/src/main/webapp/site/src/app/teacher-hybrid-angular.module.ts b/src/main/webapp/site/src/app/teacher-hybrid-angular.module.ts new file mode 100644 index 0000000000..65d44776d5 --- /dev/null +++ b/src/main/webapp/site/src/app/teacher-hybrid-angular.module.ts @@ -0,0 +1,66 @@ +import { NgModule } from '@angular/core'; + +import '../../../wise5/teacher/teacher-angular-js-module'; +import { UpgradeModule } from '@angular/upgrade/static'; +import { setUpLocationSync } from '@angular/router/upgrade'; +import { ProjectService } from '../../../wise5/services/projectService'; +import { MilestoneReportDataComponent } from './teacher/milestone/milestone-report-data/milestone-report-data.component'; +import { TeacherProjectService } from '../../../wise5/services/teacherProjectService'; +import { ProjectAssetService } from './services/projectAssetService'; +import { SpaceService } from '../../../wise5/services/spaceService'; +import { StudentStatusService } from '../../../wise5/services/studentStatusService'; +import { TeacherDataService } from '../../../wise5/services/teacherDataService'; +import { TeacherWebSocketService } from '../../../wise5/services/teacherWebSocketService'; +import { DataService } from './services/data.service'; +import { MilestoneService } from '../../../wise5/services/milestoneService'; +import { WorkgroupNodeScoreComponent } from '../../../wise5/classroomMonitor/classroomMonitorComponents/shared/workgroupNodeScore/workgroup-node-score.component'; +import { NavItemScoreComponent } from '../../../wise5/classroomMonitor/classroomMonitorComponents/nodeProgress/navItemScore/nav-item-score.component'; +import { ManageStudentsComponent } from '../../../wise5/classroomMonitor/manageStudents/manage-students-component'; +import { AdvancedProjectAuthoringComponent } from '../../../wise5/authoringTool/advanced/advanced-project-authoring.component'; +import { ChooseNewComponent } from './authoring-tool/add-component/choose-new-component/choose-new-component.component'; +import { ChooseNewComponentLocation } from './authoring-tool/add-component/choose-new-component-location/choose-new-component-location.component'; +import { ChooseImportStepComponent } from './authoring-tool/import-step/choose-import-step/choose-import-step.component'; +import { ChooseImportStepLocationComponent } from './authoring-tool/import-step/choose-import-step-location/choose-import-step-location.component'; +import { ComponentNewWorkBadgeComponent } from './classroom-monitor/component-new-work-badge/component-new-work-badge.component'; +import { StatusIconComponent } from './classroom-monitor/status-icon/status-icon.component'; +import { AngularJSModule } from './common-hybrid-angular.module'; + +@NgModule({ + declarations: [ + AdvancedProjectAuthoringComponent, + ChooseImportStepComponent, + ChooseImportStepLocationComponent, + ChooseNewComponent, + ChooseNewComponentLocation, + ComponentNewWorkBadgeComponent, + ManageStudentsComponent, + MilestoneReportDataComponent, + StatusIconComponent, + WorkgroupNodeScoreComponent, + NavItemScoreComponent + ], + imports: [ + AngularJSModule + ], + providers: [ + { provide: DataService, useExisting: TeacherDataService }, + MilestoneService, + ProjectAssetService, + SpaceService, + StudentStatusService, + { provide: ProjectService, useExisting: TeacherProjectService }, + TeacherDataService, + TeacherProjectService, + TeacherWebSocketService + ] +}) +export class TeacherAngularJSModule { + constructor(upgrade: UpgradeModule) { + bootstrapAngularJSModule(upgrade, 'teacher'); + } +} + +function bootstrapAngularJSModule(upgrade: UpgradeModule, moduleType: string) { + upgrade.bootstrap(document.body, [moduleType]); + setUpLocationSync(upgrade); +} diff --git a/src/main/webapp/site/src/app/teacher/teacher-routing.module.ts b/src/main/webapp/site/src/app/teacher/teacher-routing.module.ts index 9c0baa70e6..2fc1c7049c 100644 --- a/src/main/webapp/site/src/app/teacher/teacher-routing.module.ts +++ b/src/main/webapp/site/src/app/teacher/teacher-routing.module.ts @@ -39,7 +39,7 @@ const teacherRoutes: Routes = [ } ] }, - {path: '', loadChildren: () => import('../hybrid-module').then(m => m.TeacherAngularJSModule)} + {path: '', loadChildren: () => import('../teacher-hybrid-angular.module').then(m => m.TeacherAngularJSModule)} ], } ]; diff --git a/src/main/webapp/site/src/messages.xlf b/src/main/webapp/site/src/messages.xlf index 92504ef1d8..8a7380abf4 100644 --- a/src/main/webapp/site/src/messages.xlf +++ b/src/main/webapp/site/src/messages.xlf @@ -1147,6 +1147,10 @@ app/student/team-sign-in-dialog/team-sign-in-dialog.component.html 68
+ + app/teacher/share-run-dialog/share-run-dialog.component.html + 95 + app/authoring-tool/import-step/choose-import-step/choose-import-step.component.html 62 @@ -1163,10 +1167,6 @@ app/authoring-tool/add-component/choose-new-component-location/choose-new-component-location.component.html 41 - - app/teacher/share-run-dialog/share-run-dialog.component.html - 95 -
Add @@ -5296,197 +5296,6 @@ 3 - - Back to Unit Plan - - ../../wise5/authoringTool/advanced/advanced-project-authoring.component.html - 4 - - - - Show JSON - - ../../wise5/authoringTool/advanced/advanced-project-authoring.component.html - 7 - - - - Download Unit - - ../../wise5/authoringTool/advanced/advanced-project-authoring.component.html - 10 - - - - Edit Unit JSON - - ../../wise5/authoringTool/advanced/advanced-project-authoring.component.html - 16 - - - - Script Filename - - ../../wise5/authoringTool/advanced/advanced-project-authoring.component.html - 23 - - - - Choose - - ../../wise5/authoringTool/advanced/advanced-project-authoring.component.html - 28 - - - - Unit URL - - ../../wise5/authoringTool/advanced/advanced-project-authoring.component.html - 33 - - - - Copy Unit URL to Clipboard - - ../../wise5/authoringTool/advanced/advanced-project-authoring.component.html - 38 - - - - Open Unit URL in New Tab - - ../../wise5/authoringTool/advanced/advanced-project-authoring.component.html - 42 - - - - Import Step(s) - - app/authoring-tool/import-step/choose-import-step/choose-import-step.component.html - 1 - - - - Choose a unit to import from: - - app/authoring-tool/import-step/choose-import-step/choose-import-step.component.html - 3 - - - - Run ID - - app/authoring-tool/import-step/choose-import-step/choose-import-step.component.html - 11 - - - - Library Units - - app/authoring-tool/import-step/choose-import-step/choose-import-step.component.html - 17 - - - - Choose the step(s) that you want to import, then click next. - - app/authoring-tool/import-step/choose-import-step/choose-import-step.component.html - 28 - - - - Preview Unit - - app/authoring-tool/import-step/choose-import-step/choose-import-step.component.html - 34 - - - - Preview Step - - app/authoring-tool/import-step/choose-import-step/choose-import-step.component.html - 51 - - - - Next - - app/authoring-tool/import-step/choose-import-step/choose-import-step.component.html - 70 - - - app/authoring-tool/import-step/choose-import-step/choose-import-step.component.html - 66 - - - app/authoring-tool/add-component/choose-new-component/choose-new-component.component.html - 27 - - - - Choose a location for the imported steps - - app/authoring-tool/import-step/choose-import-step-location/choose-import-step-location.component.html - 1 - - - - Insert As First Step - - app/authoring-tool/import-step/choose-import-step-location/choose-import-step-location.component.html - 17 - - - - Insert After - - app/authoring-tool/import-step/choose-import-step-location/choose-import-step-location.component.html - 25 - - - app/authoring-tool/add-component/choose-new-component-location/choose-new-component-location.component.html - 25 - - - - Click the new component type you want to add - - app/authoring-tool/add-component/choose-new-component/choose-new-component.component.html - 3 - - - - Choose New Location - - app/authoring-tool/add-component/choose-new-component-location/choose-new-component-location.component.html - 3 - - - - Insert As First Component - - app/authoring-tool/add-component/choose-new-component-location/choose-new-component-location.component.html - 9 - - - app/authoring-tool/add-component/choose-new-component-location/choose-new-component-location.component.html - 12 - - - - Back - - app/authoring-tool/add-component/choose-new-component-location/choose-new-component-location.component.html - 36 - - - - New - - app/classroom-monitor/component-new-work-badge/component-new-work-badge.component.ts - 1 - - Teacher Home @@ -5805,6 +5614,197 @@ 107 + + Back to Unit Plan + + ../../wise5/authoringTool/advanced/advanced-project-authoring.component.html + 4 + + + + Show JSON + + ../../wise5/authoringTool/advanced/advanced-project-authoring.component.html + 7 + + + + Download Unit + + ../../wise5/authoringTool/advanced/advanced-project-authoring.component.html + 10 + + + + Edit Unit JSON + + ../../wise5/authoringTool/advanced/advanced-project-authoring.component.html + 16 + + + + Script Filename + + ../../wise5/authoringTool/advanced/advanced-project-authoring.component.html + 23 + + + + Choose + + ../../wise5/authoringTool/advanced/advanced-project-authoring.component.html + 28 + + + + Unit URL + + ../../wise5/authoringTool/advanced/advanced-project-authoring.component.html + 33 + + + + Copy Unit URL to Clipboard + + ../../wise5/authoringTool/advanced/advanced-project-authoring.component.html + 38 + + + + Open Unit URL in New Tab + + ../../wise5/authoringTool/advanced/advanced-project-authoring.component.html + 42 + + + + Import Step(s) + + app/authoring-tool/import-step/choose-import-step/choose-import-step.component.html + 1 + + + + Choose a unit to import from: + + app/authoring-tool/import-step/choose-import-step/choose-import-step.component.html + 3 + + + + Run ID + + app/authoring-tool/import-step/choose-import-step/choose-import-step.component.html + 11 + + + + Library Units + + app/authoring-tool/import-step/choose-import-step/choose-import-step.component.html + 17 + + + + Choose the step(s) that you want to import, then click next. + + app/authoring-tool/import-step/choose-import-step/choose-import-step.component.html + 28 + + + + Preview Unit + + app/authoring-tool/import-step/choose-import-step/choose-import-step.component.html + 34 + + + + Preview Step + + app/authoring-tool/import-step/choose-import-step/choose-import-step.component.html + 51 + + + + Next + + app/authoring-tool/import-step/choose-import-step/choose-import-step.component.html + 70 + + + app/authoring-tool/import-step/choose-import-step/choose-import-step.component.html + 66 + + + app/authoring-tool/add-component/choose-new-component/choose-new-component.component.html + 27 + + + + Choose a location for the imported steps + + app/authoring-tool/import-step/choose-import-step-location/choose-import-step-location.component.html + 1 + + + + Insert As First Step + + app/authoring-tool/import-step/choose-import-step-location/choose-import-step-location.component.html + 17 + + + + Insert After + + app/authoring-tool/import-step/choose-import-step-location/choose-import-step-location.component.html + 25 + + + app/authoring-tool/add-component/choose-new-component-location/choose-new-component-location.component.html + 25 + + + + Click the new component type you want to add + + app/authoring-tool/add-component/choose-new-component/choose-new-component.component.html + 3 + + + + Choose New Location + + app/authoring-tool/add-component/choose-new-component-location/choose-new-component-location.component.html + 3 + + + + Insert As First Component + + app/authoring-tool/add-component/choose-new-component-location/choose-new-component-location.component.html + 9 + + + app/authoring-tool/add-component/choose-new-component-location/choose-new-component-location.component.html + 12 + + + + Back + + app/authoring-tool/add-component/choose-new-component-location/choose-new-component-location.component.html + 36 + + + + New + + app/classroom-monitor/component-new-work-badge/component-new-work-badge.component.ts + 1 + + Register or Sign In diff --git a/src/main/webapp/wise5/common-angular-js-module.ts b/src/main/webapp/wise5/common-angular-js-module.ts index 80aadeb91f..82e3ac63a9 100644 --- a/src/main/webapp/wise5/common-angular-js-module.ts +++ b/src/main/webapp/wise5/common-angular-js-module.ts @@ -32,6 +32,7 @@ import './components/draw/drawComponentModule'; import './components/embedded/embeddedComponentModule'; import * as fabric from 'fabric'; window['fabric'] = fabric.fabric +import Filters from './filters/filters'; import './lib/highcharts/highcharts-ng'; import * as Highcharts from './lib/highcharts/highcharts.src'; import './lib/draggable-points/draggable-points'; @@ -115,6 +116,7 @@ import './themes/default/theme'; .factory('TagService', downgradeInjectable(TagService)) .factory('StudentDataService', downgradeInjectable(StudentDataService)) .factory('UtilService', downgradeInjectable(UtilService)) + .filter('Filters', Filters) .config([ '$httpProvider', '$locationProvider', diff --git a/src/main/webapp/wise5/vle/student-angular-js-module.ts b/src/main/webapp/wise5/vle/student-angular-js-module.ts index 853f50b30d..9ed38e53a4 100644 --- a/src/main/webapp/wise5/vle/student-angular-js-module.ts +++ b/src/main/webapp/wise5/vle/student-angular-js-module.ts @@ -3,7 +3,6 @@ import '../lib/bootstrap/js/bootstrap.min' import * as angular from 'angular'; import { downgradeInjectable } from '@angular/upgrade/static'; import '../common-angular-js-module'; -import Filters from '../filters/filters'; import NavigationController from '../vle/navigation/navigationController'; import NodeController from '../vle/node/nodeController'; import { StudentWebSocketService } from '../services/studentWebSocketService'; @@ -27,7 +26,6 @@ export function createStudentAngularJSModule(type = 'preview') { .controller('NavigationController', NavigationController) .controller('NodeController', NodeController) .controller('VLEController', VLEController) - .filter('Filters', Filters) .config([ '$stateProvider', '$translatePartialLoaderProvider', From 30230cf996563beef828026a94a90013ddc6e55f Mon Sep 17 00:00:00 2001 From: Geoffrey Kwan Date: Wed, 4 Nov 2020 11:50:22 -0500 Subject: [PATCH 06/15] Fixed some styling issues with the help-icon component. #2773 --- .../default/themeComponents/helpIcon/help-icon.component.scss | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/webapp/wise5/themes/default/themeComponents/helpIcon/help-icon.component.scss b/src/main/webapp/wise5/themes/default/themeComponents/helpIcon/help-icon.component.scss index 6bdc33dc7b..a1cdc321a5 100644 --- a/src/main/webapp/wise5/themes/default/themeComponents/helpIcon/help-icon.component.scss +++ b/src/main/webapp/wise5/themes/default/themeComponents/helpIcon/help-icon.component.scss @@ -1,5 +1,5 @@ mat-icon { - color: #ef6c00!important; + color: #ef6c00 !important; font-size: 36px; width: 36px; min-width: 0; @@ -11,7 +11,7 @@ mat-icon { @keyframes pulse { 0% { - box-shadow: 0 0 0 0 rgb(0,0,0,0); + box-shadow: 0 0 0 0 rgba(0, 0, 0, 0); } 50% { box-shadow: 0 0 0 10px #ef6c00; From 8216ace9c75d429867d4d33331e5cb0b9076f683 Mon Sep 17 00:00:00 2001 From: breity Date: Wed, 4 Nov 2020 09:10:19 -0800 Subject: [PATCH 07/15] Remove text showing number of 'completed' runs from student and teacher run list. #2786 --- .../student-run-list.component.html | 3 +-- .../student-run-list.component.spec.ts | 4 ++-- .../teacher-run-list.component.html | 3 +-- src/main/webapp/site/src/messages.xlf | 19 ++++--------------- 4 files changed, 8 insertions(+), 21 deletions(-) diff --git a/src/main/webapp/site/src/app/student/student-run-list/student-run-list.component.html b/src/main/webapp/site/src/app/student/student-run-list/student-run-list.component.html index b8a8e0c8a2..0c9b35164d 100644 --- a/src/main/webapp/site/src/app/student/student-run-list/student-run-list.component.html +++ b/src/main/webapp/site/src/app/student/student-run-list/student-run-list.component.html @@ -20,8 +20,7 @@ My WISE units: {{ filteredRuns.length }} ({{ scheduledTotal() }} scheduled, - {{ activeTotal() }} active, - {{ completedTotal() }} completed) + {{ activeTotal() }} active) | Reset diff --git a/src/main/webapp/site/src/app/student/student-run-list/student-run-list.component.spec.ts b/src/main/webapp/site/src/app/student/student-run-list/student-run-list.component.spec.ts index 60871a329a..4350dab9b4 100644 --- a/src/main/webapp/site/src/app/student/student-run-list/student-run-list.component.spec.ts +++ b/src/main/webapp/site/src/app/student/student-run-list/student-run-list.component.spec.ts @@ -37,7 +37,7 @@ export class MockStudentService { new Run({ id:2, name:'Plate Tectonics', - startTime: new Date('2018-08-23T00:00:00.0').getTime() + startTime: new Date('2018-08-25T00:00:00.0').getTime() }), new Run({ id:3, @@ -89,6 +89,6 @@ describe('StudentRunListComponent', () => { it('should show number of runs', () => { const compiled = fixture.debugElement.nativeElement; - expect(compiled.querySelector('#unitCount').textContent).toContain('My WISE units: 3 (2 active, 1 completed)'); + expect(compiled.querySelector('#unitCount').textContent).toContain('My WISE units: 3 (1 scheduled, 1 active)'); }) }); diff --git a/src/main/webapp/site/src/app/teacher/teacher-run-list/teacher-run-list.component.html b/src/main/webapp/site/src/app/teacher/teacher-run-list/teacher-run-list.component.html index 6829e9e838..ac77815e86 100644 --- a/src/main/webapp/site/src/app/teacher/teacher-run-list/teacher-run-list.component.html +++ b/src/main/webapp/site/src/app/teacher/teacher-run-list/teacher-run-list.component.html @@ -30,8 +30,7 @@ Total classroom units: {{ filteredRuns.length }} ({{ scheduledTotal() }} scheduled, - {{ activeTotal() }} active, - {{ completedTotal() }} completed) + {{ activeTotal() }} active) | Reset diff --git a/src/main/webapp/site/src/messages.xlf b/src/main/webapp/site/src/messages.xlf index f858445afa..404d964608 100644 --- a/src/main/webapp/site/src/messages.xlf +++ b/src/main/webapp/site/src/messages.xlf @@ -2258,11 +2258,11 @@ app/student/student-run-list/student-run-list.component.html - 27 + 26 app/teacher/teacher-run-list/teacher-run-list.component.html - 37 + 36 @@ -4947,11 +4947,11 @@ app/student/student-run-list/student-run-list.component.html - 64 + 63 app/teacher/teacher-run-list/teacher-run-list.component.html - 76 + 75 @@ -5400,17 +5400,6 @@ 33 - - completed - - app/student/student-run-list/student-run-list.component.html - 24 - - - app/teacher/teacher-run-list/teacher-run-list.component.html - 34 - - Team Sign In From d03973b52564e080658ae73219d839832e637b71 Mon Sep 17 00:00:00 2001 From: breity Date: Wed, 4 Nov 2020 09:13:50 -0800 Subject: [PATCH 08/15] Change tab label from 'Browse WISE Units' to 'Unit Library' on teacher home. #2786 --- .../app/help/getting-started/getting-started.component.html | 2 +- .../src/app/help/teacher-faq/teacher-faq.component.html | 4 ++-- .../src/app/teacher/teacher-home/teacher-home.component.ts | 2 +- src/main/webapp/site/src/messages-code.xlf | 2 +- src/main/webapp/site/src/messages.xlf | 6 +++--- 5 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/main/webapp/site/src/app/help/getting-started/getting-started.component.html b/src/main/webapp/site/src/app/help/getting-started/getting-started.component.html index 4f850bd19d..8078c6742f 100644 --- a/src/main/webapp/site/src/app/help/getting-started/getting-started.component.html +++ b/src/main/webapp/site/src/app/help/getting-started/getting-started.component.html @@ -22,7 +22,7 @@

Using a WISE Unit

Here are instructions on how to set up a Run.

  1. Sign in to WISE with your teacher account.
  2. -
  3. Click the "Browse WISE Units" tab.
  4. +
  5. Click the "Unit Library" tab.
  6. Find a project that you would like to use with your class.
  7. Click on the project to open the information for the project.
  8. Click the "Use With Class" button.
  9. diff --git a/src/main/webapp/site/src/app/help/teacher-faq/teacher-faq.component.html b/src/main/webapp/site/src/app/help/teacher-faq/teacher-faq.component.html index 18bda7271a..f3d96044c6 100644 --- a/src/main/webapp/site/src/app/help/teacher-faq/teacher-faq.component.html +++ b/src/main/webapp/site/src/app/help/teacher-faq/teacher-faq.component.html @@ -23,7 +23,7 @@

    How do I create an account?

    How do I use a unit with my class?

    1. Sign in to WISE with your teacher account.
    2. -
    3. Click the "Browse WISE Units" tab.
    4. +
    5. Click the "Unit Library" tab.
    6. Find a project that you would like to use with your class.
    7. Click on the project to open the information for the project.
    8. Click the "Use With Class" button.
    9. @@ -107,7 +107,7 @@

      Can I shorten a project run to 1 or 2 days?

      Where do I find out about lesson plans and standards for WISE projects?