1- // import 'handsontable/dist/handsontable.full.css';
21import RunestoneBase from "../../common/js/runestonebase.js" ;
32import "../css/hparsons.css" ;
43import "../css/hljs-xcode.css" ;
54import BlockFeedback from "./BlockFeedback.js" ;
65import SQLFeedback from "./SQLFeedback.js" ;
7- // import "micro-parsons.j" from 'micro-parsons';
86import { InitMicroParsons } from 'micro-parsons/micro-parsons/micro-parsons.js' ;
97import 'micro-parsons/micro-parsons/micro-parsons.css' ;
108
@@ -13,7 +11,7 @@ export var hpList;
1311if ( hpList === undefined ) hpList = { } ;
1412
1513
16- export default class SQLHParsons extends RunestoneBase {
14+ export default class HParsons extends RunestoneBase {
1715 constructor ( opts ) {
1816 super ( opts ) ;
1917 // copied from activecode
@@ -66,7 +64,7 @@ export default class SQLHParsons extends RunestoneBase {
6664 if ( $ ( orig ) . data ( "caption" ) ) {
6765 this . caption = $ ( orig ) . data ( "caption" ) ;
6866 } else {
69- this . caption = "HorizontalParsons " ;
67+ this . caption = "MicroParsons " ;
7068 }
7169 this . addCaption ( "runestone" ) ;
7270 this . indicate_component_ready ( ) ;
@@ -146,8 +144,6 @@ export default class SQLHParsons extends RunestoneBase {
146144 }
147145
148146 logHorizontalParsonsEvent ( hparsonsEvent ) {
149- // TODO: might need to find another way to change "act".
150- // The event string is probably too long.
151147 let ev = {
152148 event : "hparsons" ,
153149 div_id : this . divid ,
@@ -167,7 +163,7 @@ $(document).on("runestone:login-complete", function () {
167163 if ( $ ( this ) . closest ( "[data-component=timedAssessment]" ) . length == 0 ) {
168164 // If this element exists within a timed component, don't render it here
169165 // try {
170- hpList [ this . id ] = new SQLHParsons ( {
166+ hpList [ this . id ] = new HParsons ( {
171167 orig : this ,
172168 useRunestoneServices : eBookConfig . useRunestoneServices ,
173169 } ) ;
@@ -183,5 +179,5 @@ if (typeof window.component_factory === "undefined") {
183179 window . component_factory = { } ;
184180}
185181window . component_factory [ "hparsons" ] = function ( opts ) {
186- return new SQLHParsons ( opts ) ;
182+ return new HParsons ( opts ) ;
187183} ;
0 commit comments