@zykjcommon/questions 0.0.35 → 0.0.37

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -23814,75 +23814,73 @@ var index = {
23814
23814
  const Question_Programming_exports_ = /*#__PURE__*/(0,exportHelper/* default */.Z)(Question_Programmingvue_type_script_lang_js, [['render',Question_Programmingvue_type_template_id_411b6dae_render]])
23815
23815
 
23816
23816
  /* harmony default export */ var Question_Programming = (Question_Programming_exports_);
23817
- ;// CONCATENATED MODULE: ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[4]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/components/questions/Question_Classify.vue?vue&type=template&id=00c7419b
23817
+ ;// CONCATENATED MODULE: ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-40.use[1]!./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[4]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/components/questions/Question_Classify.vue?vue&type=template&id=25cb7a86
23818
23818
 
23819
- var Question_Classifyvue_type_template_id_00c7419b_hoisted_1 = {
23819
+ var Question_Classifyvue_type_template_id_25cb7a86_hoisted_1 = {
23820
23820
  class: "zykjcommon-question",
23821
23821
  style: {
23822
23822
  "width": "100%",
23823
23823
  "height": "100%"
23824
23824
  }
23825
23825
  };
23826
- var Question_Classifyvue_type_template_id_00c7419b_hoisted_2 = {
23826
+ var Question_Classifyvue_type_template_id_25cb7a86_hoisted_2 = {
23827
23827
  class: "box"
23828
23828
  };
23829
- var Question_Classifyvue_type_template_id_00c7419b_hoisted_3 = {
23829
+ var Question_Classifyvue_type_template_id_25cb7a86_hoisted_3 = {
23830
23830
  class: "main-block"
23831
23831
  };
23832
- var Question_Classifyvue_type_template_id_00c7419b_hoisted_4 = ["src"];
23833
- var Question_Classifyvue_type_template_id_00c7419b_hoisted_5 = /*#__PURE__*/(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23832
+ var Question_Classifyvue_type_template_id_25cb7a86_hoisted_4 = ["src"];
23833
+ var Question_Classifyvue_type_template_id_25cb7a86_hoisted_5 = /*#__PURE__*/(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23834
23834
  class: "main-content"
23835
23835
  }, [/*#__PURE__*/(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23836
23836
  class: "main-append"
23837
23837
  })], -1);
23838
- var Question_Classifyvue_type_template_id_00c7419b_hoisted_6 = /*#__PURE__*/(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23838
+ var Question_Classifyvue_type_template_id_25cb7a86_hoisted_6 = /*#__PURE__*/(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23839
23839
  class: "prev"
23840
23840
  }, [/*#__PURE__*/(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23841
23841
  class: "prev-main"
23842
23842
  })], -1);
23843
- var Question_Classifyvue_type_template_id_00c7419b_hoisted_7 = /*#__PURE__*/(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23843
+ var Question_Classifyvue_type_template_id_25cb7a86_hoisted_7 = /*#__PURE__*/(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23844
23844
  class: "next"
23845
23845
  }, [/*#__PURE__*/(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23846
23846
  class: "next-main"
23847
23847
  })], -1);
23848
- var Question_Classifyvue_type_template_id_00c7419b_hoisted_8 = {
23848
+ var Question_Classifyvue_type_template_id_25cb7a86_hoisted_8 = {
23849
23849
  class: "list"
23850
23850
  };
23851
- var Question_Classifyvue_type_template_id_00c7419b_hoisted_9 = ["idx"];
23852
- var Question_Classifyvue_type_template_id_00c7419b_hoisted_10 = {
23851
+ var Question_Classifyvue_type_template_id_25cb7a86_hoisted_9 = ["idx"];
23852
+ var Question_Classifyvue_type_template_id_25cb7a86_hoisted_10 = {
23853
23853
  class: "list-item-text"
23854
23854
  };
23855
- function Question_Classifyvue_type_template_id_00c7419b_render(_ctx, _cache, $props, $setup, $data, $options) {
23856
- return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)("div", Question_Classifyvue_type_template_id_00c7419b_hoisted_1, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23855
+ function Question_Classifyvue_type_template_id_25cb7a86_render(_ctx, _cache, $props, $setup, $data, $options) {
23856
+ return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)("div", Question_Classifyvue_type_template_id_25cb7a86_hoisted_1, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23857
23857
  class: "question-classify",
23858
23858
  style: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeStyle)($data.bigBgCss)
23859
- }, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", Question_Classifyvue_type_template_id_00c7419b_hoisted_2, [((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(true), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)(external_commonjs_vue_commonjs2_vue_root_Vue_.Fragment, null, (0,external_commonjs_vue_commonjs2_vue_root_Vue_.renderList)($data.bigBoxItemList, function (item, index) {
23859
+ }, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", Question_Classifyvue_type_template_id_25cb7a86_hoisted_2, [((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(true), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)(external_commonjs_vue_commonjs2_vue_root_Vue_.Fragment, null, (0,external_commonjs_vue_commonjs2_vue_root_Vue_.renderList)($data.bigBoxItemList, function (item, index) {
23860
23860
  return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)("div", {
23861
23861
  class: "box-item",
23862
23862
  style: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeStyle)(item.bgUrlCss),
23863
23863
  key: index
23864
- }, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", Question_Classifyvue_type_template_id_00c7419b_hoisted_3, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("img", {
23864
+ }, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", Question_Classifyvue_type_template_id_25cb7a86_hoisted_3, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("img", {
23865
23865
  src: item.imgUrl,
23866
23866
  alt: ""
23867
- }, null, 8, Question_Classifyvue_type_template_id_00c7419b_hoisted_4)]), Question_Classifyvue_type_template_id_00c7419b_hoisted_5], 4);
23867
+ }, null, 8, Question_Classifyvue_type_template_id_25cb7a86_hoisted_4)]), Question_Classifyvue_type_template_id_25cb7a86_hoisted_5], 4);
23868
23868
  }), 128))]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23869
23869
  class: "list-outter",
23870
23870
  style: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeStyle)($data.bottomBgCss)
23871
- }, [Question_Classifyvue_type_template_id_00c7419b_hoisted_6, Question_Classifyvue_type_template_id_00c7419b_hoisted_7, (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", Question_Classifyvue_type_template_id_00c7419b_hoisted_8, [((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(true), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)(external_commonjs_vue_commonjs2_vue_root_Vue_.Fragment, null, (0,external_commonjs_vue_commonjs2_vue_root_Vue_.renderList)($data.optionList, function (item, index) {
23871
+ }, [Question_Classifyvue_type_template_id_25cb7a86_hoisted_6, Question_Classifyvue_type_template_id_25cb7a86_hoisted_7, (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", Question_Classifyvue_type_template_id_25cb7a86_hoisted_8, [((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(true), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)(external_commonjs_vue_commonjs2_vue_root_Vue_.Fragment, null, (0,external_commonjs_vue_commonjs2_vue_root_Vue_.renderList)($data.optionList, function (item, index) {
23872
23872
  return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)("div", {
23873
23873
  class: "list-item",
23874
23874
  idx: item.idx,
23875
23875
  style: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeStyle)(item.bgUrlCss),
23876
23876
  key: index
23877
- }, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", Question_Classifyvue_type_template_id_00c7419b_hoisted_10, (0,external_commonjs_vue_commonjs2_vue_root_Vue_.toDisplayString)(item.content), 1)], 12, Question_Classifyvue_type_template_id_00c7419b_hoisted_9);
23877
+ }, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", Question_Classifyvue_type_template_id_25cb7a86_hoisted_10, (0,external_commonjs_vue_commonjs2_vue_root_Vue_.toDisplayString)(item.content), 1)], 12, Question_Classifyvue_type_template_id_25cb7a86_hoisted_9);
23878
23878
  }), 128))])], 4)], 4)]);
23879
23879
  }
23880
- ;// CONCATENATED MODULE: ./src/components/questions/Question_Classify.vue?vue&type=template&id=00c7419b
23880
+ ;// CONCATENATED MODULE: ./src/components/questions/Question_Classify.vue?vue&type=template&id=25cb7a86
23881
23881
 
23882
23882
  // EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.sort.js
23883
23883
  var es_array_sort = __webpack_require__(2707);
23884
- // EXTERNAL MODULE: ./node_modules/core-js/modules/es.promise.js
23885
- var es_promise = __webpack_require__(8674);
23886
23884
  // EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.find-index.js
23887
23885
  var es_array_find_index = __webpack_require__(4553);
23888
23886
  // EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.splice.js
@@ -23946,7 +23944,6 @@ var setRemFixedHeight = function setRemFixedHeight() {
23946
23944
 
23947
23945
 
23948
23946
 
23949
-
23950
23947
  var env = js_fun.getDeviceEnv();
23951
23948
  /* harmony default export */ var Question_Classifyvue_type_script_lang_js = ({
23952
23949
  name: 'Question_Classify',
@@ -24083,23 +24080,6 @@ var env = js_fun.getDeviceEnv();
24083
24080
  var correct = this.questionInfo.answerMap.is_correct === '1' ? true : false;
24084
24081
  return correct;
24085
24082
  },
24086
- intervalFindEl: function intervalFindEl() {
24087
- var _this2 = this;
24088
- return new Promise(function (resolve, reject) {
24089
- console.log(_this2.$el, 345);
24090
- debugger;
24091
- if (_this2.$el) {
24092
- resolve();
24093
- } else {
24094
- var interval = setInterval(function () {
24095
- if (_this2.$el) {
24096
- clearInterval(interval);
24097
- resolve();
24098
- }
24099
- }, 50);
24100
- }
24101
- });
24102
- },
24103
24083
  parseLists: function parseLists(nv) {
24104
24084
  this.classify_question_info = nv.classify_question_info;
24105
24085
  var exam_options_data = nv.exam_options_data;
@@ -24343,7 +24323,7 @@ var env = js_fun.getDeviceEnv();
24343
24323
  },
24344
24324
  //回显答案
24345
24325
  setAnswerDo: function setAnswerDo() {
24346
- var _this3 = this;
24326
+ var _this2 = this;
24347
24327
  var self = this;
24348
24328
  var listItemIds = [];
24349
24329
  $(this.$el).find('.question-classify .list-item').each(function (index, item) {
@@ -24357,11 +24337,11 @@ var env = js_fun.getDeviceEnv();
24357
24337
  if (idx > -1) {
24358
24338
  //找到一个删掉一个,要不会有问题
24359
24339
  listItemIds.splice(idx, 1);
24360
- var listItemDom = $(_this3.$el).find('.question-classify .list-item').eq(idx);
24340
+ var listItemDom = $(_this2.$el).find('.question-classify .list-item').eq(idx);
24361
24341
  var attrIdx = listItemDom.attr('idx');
24362
24342
  var appendItem = $("<div class=\"append-item\" idx=\"".concat(attrIdx, "\" style=\"").concat(self.listItemBgCss, "\"><div class=\"list-item-text\">").concat(listItemDom.find('.list-item-text').text(), "</div></div>"));
24363
24343
  self.bindDragDomEvent(appendItem, 'back');
24364
- $(_this3.$el).find('.main-append').eq(index).append(appendItem);
24344
+ $(_this2.$el).find('.main-append').eq(index).append(appendItem);
24365
24345
  listItemDom.remove();
24366
24346
  }
24367
24347
  });
@@ -24379,7 +24359,7 @@ var env = js_fun.getDeviceEnv();
24379
24359
 
24380
24360
 
24381
24361
  ;
24382
- const Question_Classify_exports_ = /*#__PURE__*/(0,exportHelper/* default */.Z)(Question_Classifyvue_type_script_lang_js, [['render',Question_Classifyvue_type_template_id_00c7419b_render]])
24362
+ const Question_Classify_exports_ = /*#__PURE__*/(0,exportHelper/* default */.Z)(Question_Classifyvue_type_script_lang_js, [['render',Question_Classifyvue_type_template_id_25cb7a86_render]])
24383
24363
 
24384
24364
  /* harmony default export */ var Question_Classify = (Question_Classify_exports_);
24385
24365
  ;// CONCATENATED MODULE: ./src/components/questions/const.js
@@ -24404,6 +24384,8 @@ var questionMapper = {
24404
24384
  //填空
24405
24385
  '17': 'Question_Classify' //分类
24406
24386
  };
24387
+ // EXTERNAL MODULE: ./node_modules/core-js/modules/es.promise.js
24388
+ var es_promise = __webpack_require__(8674);
24407
24389
  // EXTERNAL MODULE: ./node_modules/crypto-js/index.js
24408
24390
  var crypto_js = __webpack_require__(1354);
24409
24391
  // EXTERNAL MODULE: ./node_modules/axios/index.js
@@ -23824,75 +23824,73 @@ var index = {
23824
23824
  const Question_Programming_exports_ = /*#__PURE__*/(0,exportHelper/* default */.Z)(Question_Programmingvue_type_script_lang_js, [['render',Question_Programmingvue_type_template_id_411b6dae_render]])
23825
23825
 
23826
23826
  /* harmony default export */ var Question_Programming = (Question_Programming_exports_);
23827
- ;// CONCATENATED MODULE: ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-86.use[1]!./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[4]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/components/questions/Question_Classify.vue?vue&type=template&id=00c7419b
23827
+ ;// CONCATENATED MODULE: ./node_modules/thread-loader/dist/cjs.js!./node_modules/babel-loader/lib/index.js??clonedRuleSet-86.use[1]!./node_modules/vue-loader/dist/templateLoader.js??ruleSet[1].rules[4]!./node_modules/vue-loader/dist/index.js??ruleSet[0].use[0]!./src/components/questions/Question_Classify.vue?vue&type=template&id=25cb7a86
23828
23828
 
23829
- var Question_Classifyvue_type_template_id_00c7419b_hoisted_1 = {
23829
+ var Question_Classifyvue_type_template_id_25cb7a86_hoisted_1 = {
23830
23830
  class: "zykjcommon-question",
23831
23831
  style: {
23832
23832
  "width": "100%",
23833
23833
  "height": "100%"
23834
23834
  }
23835
23835
  };
23836
- var Question_Classifyvue_type_template_id_00c7419b_hoisted_2 = {
23836
+ var Question_Classifyvue_type_template_id_25cb7a86_hoisted_2 = {
23837
23837
  class: "box"
23838
23838
  };
23839
- var Question_Classifyvue_type_template_id_00c7419b_hoisted_3 = {
23839
+ var Question_Classifyvue_type_template_id_25cb7a86_hoisted_3 = {
23840
23840
  class: "main-block"
23841
23841
  };
23842
- var Question_Classifyvue_type_template_id_00c7419b_hoisted_4 = ["src"];
23843
- var Question_Classifyvue_type_template_id_00c7419b_hoisted_5 = /*#__PURE__*/(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23842
+ var Question_Classifyvue_type_template_id_25cb7a86_hoisted_4 = ["src"];
23843
+ var Question_Classifyvue_type_template_id_25cb7a86_hoisted_5 = /*#__PURE__*/(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23844
23844
  class: "main-content"
23845
23845
  }, [/*#__PURE__*/(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23846
23846
  class: "main-append"
23847
23847
  })], -1);
23848
- var Question_Classifyvue_type_template_id_00c7419b_hoisted_6 = /*#__PURE__*/(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23848
+ var Question_Classifyvue_type_template_id_25cb7a86_hoisted_6 = /*#__PURE__*/(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23849
23849
  class: "prev"
23850
23850
  }, [/*#__PURE__*/(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23851
23851
  class: "prev-main"
23852
23852
  })], -1);
23853
- var Question_Classifyvue_type_template_id_00c7419b_hoisted_7 = /*#__PURE__*/(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23853
+ var Question_Classifyvue_type_template_id_25cb7a86_hoisted_7 = /*#__PURE__*/(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23854
23854
  class: "next"
23855
23855
  }, [/*#__PURE__*/(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23856
23856
  class: "next-main"
23857
23857
  })], -1);
23858
- var Question_Classifyvue_type_template_id_00c7419b_hoisted_8 = {
23858
+ var Question_Classifyvue_type_template_id_25cb7a86_hoisted_8 = {
23859
23859
  class: "list"
23860
23860
  };
23861
- var Question_Classifyvue_type_template_id_00c7419b_hoisted_9 = ["idx"];
23862
- var Question_Classifyvue_type_template_id_00c7419b_hoisted_10 = {
23861
+ var Question_Classifyvue_type_template_id_25cb7a86_hoisted_9 = ["idx"];
23862
+ var Question_Classifyvue_type_template_id_25cb7a86_hoisted_10 = {
23863
23863
  class: "list-item-text"
23864
23864
  };
23865
- function Question_Classifyvue_type_template_id_00c7419b_render(_ctx, _cache, $props, $setup, $data, $options) {
23866
- return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)("div", Question_Classifyvue_type_template_id_00c7419b_hoisted_1, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23865
+ function Question_Classifyvue_type_template_id_25cb7a86_render(_ctx, _cache, $props, $setup, $data, $options) {
23866
+ return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)("div", Question_Classifyvue_type_template_id_25cb7a86_hoisted_1, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23867
23867
  class: "question-classify",
23868
23868
  style: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeStyle)($data.bigBgCss)
23869
- }, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", Question_Classifyvue_type_template_id_00c7419b_hoisted_2, [((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(true), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)(external_commonjs_vue_commonjs2_vue_root_Vue_.Fragment, null, (0,external_commonjs_vue_commonjs2_vue_root_Vue_.renderList)($data.bigBoxItemList, function (item, index) {
23869
+ }, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", Question_Classifyvue_type_template_id_25cb7a86_hoisted_2, [((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(true), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)(external_commonjs_vue_commonjs2_vue_root_Vue_.Fragment, null, (0,external_commonjs_vue_commonjs2_vue_root_Vue_.renderList)($data.bigBoxItemList, function (item, index) {
23870
23870
  return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)("div", {
23871
23871
  class: "box-item",
23872
23872
  style: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeStyle)(item.bgUrlCss),
23873
23873
  key: index
23874
- }, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", Question_Classifyvue_type_template_id_00c7419b_hoisted_3, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("img", {
23874
+ }, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", Question_Classifyvue_type_template_id_25cb7a86_hoisted_3, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("img", {
23875
23875
  src: item.imgUrl,
23876
23876
  alt: ""
23877
- }, null, 8, Question_Classifyvue_type_template_id_00c7419b_hoisted_4)]), Question_Classifyvue_type_template_id_00c7419b_hoisted_5], 4);
23877
+ }, null, 8, Question_Classifyvue_type_template_id_25cb7a86_hoisted_4)]), Question_Classifyvue_type_template_id_25cb7a86_hoisted_5], 4);
23878
23878
  }), 128))]), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", {
23879
23879
  class: "list-outter",
23880
23880
  style: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeStyle)($data.bottomBgCss)
23881
- }, [Question_Classifyvue_type_template_id_00c7419b_hoisted_6, Question_Classifyvue_type_template_id_00c7419b_hoisted_7, (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", Question_Classifyvue_type_template_id_00c7419b_hoisted_8, [((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(true), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)(external_commonjs_vue_commonjs2_vue_root_Vue_.Fragment, null, (0,external_commonjs_vue_commonjs2_vue_root_Vue_.renderList)($data.optionList, function (item, index) {
23881
+ }, [Question_Classifyvue_type_template_id_25cb7a86_hoisted_6, Question_Classifyvue_type_template_id_25cb7a86_hoisted_7, (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", Question_Classifyvue_type_template_id_25cb7a86_hoisted_8, [((0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(true), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)(external_commonjs_vue_commonjs2_vue_root_Vue_.Fragment, null, (0,external_commonjs_vue_commonjs2_vue_root_Vue_.renderList)($data.optionList, function (item, index) {
23882
23882
  return (0,external_commonjs_vue_commonjs2_vue_root_Vue_.openBlock)(), (0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementBlock)("div", {
23883
23883
  class: "list-item",
23884
23884
  idx: item.idx,
23885
23885
  style: (0,external_commonjs_vue_commonjs2_vue_root_Vue_.normalizeStyle)(item.bgUrlCss),
23886
23886
  key: index
23887
- }, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", Question_Classifyvue_type_template_id_00c7419b_hoisted_10, (0,external_commonjs_vue_commonjs2_vue_root_Vue_.toDisplayString)(item.content), 1)], 12, Question_Classifyvue_type_template_id_00c7419b_hoisted_9);
23887
+ }, [(0,external_commonjs_vue_commonjs2_vue_root_Vue_.createElementVNode)("div", Question_Classifyvue_type_template_id_25cb7a86_hoisted_10, (0,external_commonjs_vue_commonjs2_vue_root_Vue_.toDisplayString)(item.content), 1)], 12, Question_Classifyvue_type_template_id_25cb7a86_hoisted_9);
23888
23888
  }), 128))])], 4)], 4)]);
23889
23889
  }
23890
- ;// CONCATENATED MODULE: ./src/components/questions/Question_Classify.vue?vue&type=template&id=00c7419b
23890
+ ;// CONCATENATED MODULE: ./src/components/questions/Question_Classify.vue?vue&type=template&id=25cb7a86
23891
23891
 
23892
23892
  // EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.sort.js
23893
23893
  var es_array_sort = __webpack_require__(2707);
23894
- // EXTERNAL MODULE: ./node_modules/core-js/modules/es.promise.js
23895
- var es_promise = __webpack_require__(8674);
23896
23894
  // EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.find-index.js
23897
23895
  var es_array_find_index = __webpack_require__(4553);
23898
23896
  // EXTERNAL MODULE: ./node_modules/core-js/modules/es.array.splice.js
@@ -23956,7 +23954,6 @@ var setRemFixedHeight = function setRemFixedHeight() {
23956
23954
 
23957
23955
 
23958
23956
 
23959
-
23960
23957
  var env = js_fun.getDeviceEnv();
23961
23958
  /* harmony default export */ var Question_Classifyvue_type_script_lang_js = ({
23962
23959
  name: 'Question_Classify',
@@ -24093,23 +24090,6 @@ var env = js_fun.getDeviceEnv();
24093
24090
  var correct = this.questionInfo.answerMap.is_correct === '1' ? true : false;
24094
24091
  return correct;
24095
24092
  },
24096
- intervalFindEl: function intervalFindEl() {
24097
- var _this2 = this;
24098
- return new Promise(function (resolve, reject) {
24099
- console.log(_this2.$el, 345);
24100
- debugger;
24101
- if (_this2.$el) {
24102
- resolve();
24103
- } else {
24104
- var interval = setInterval(function () {
24105
- if (_this2.$el) {
24106
- clearInterval(interval);
24107
- resolve();
24108
- }
24109
- }, 50);
24110
- }
24111
- });
24112
- },
24113
24093
  parseLists: function parseLists(nv) {
24114
24094
  this.classify_question_info = nv.classify_question_info;
24115
24095
  var exam_options_data = nv.exam_options_data;
@@ -24353,7 +24333,7 @@ var env = js_fun.getDeviceEnv();
24353
24333
  },
24354
24334
  //回显答案
24355
24335
  setAnswerDo: function setAnswerDo() {
24356
- var _this3 = this;
24336
+ var _this2 = this;
24357
24337
  var self = this;
24358
24338
  var listItemIds = [];
24359
24339
  $(this.$el).find('.question-classify .list-item').each(function (index, item) {
@@ -24367,11 +24347,11 @@ var env = js_fun.getDeviceEnv();
24367
24347
  if (idx > -1) {
24368
24348
  //找到一个删掉一个,要不会有问题
24369
24349
  listItemIds.splice(idx, 1);
24370
- var listItemDom = $(_this3.$el).find('.question-classify .list-item').eq(idx);
24350
+ var listItemDom = $(_this2.$el).find('.question-classify .list-item').eq(idx);
24371
24351
  var attrIdx = listItemDom.attr('idx');
24372
24352
  var appendItem = $("<div class=\"append-item\" idx=\"".concat(attrIdx, "\" style=\"").concat(self.listItemBgCss, "\"><div class=\"list-item-text\">").concat(listItemDom.find('.list-item-text').text(), "</div></div>"));
24373
24353
  self.bindDragDomEvent(appendItem, 'back');
24374
- $(_this3.$el).find('.main-append').eq(index).append(appendItem);
24354
+ $(_this2.$el).find('.main-append').eq(index).append(appendItem);
24375
24355
  listItemDom.remove();
24376
24356
  }
24377
24357
  });
@@ -24389,7 +24369,7 @@ var env = js_fun.getDeviceEnv();
24389
24369
 
24390
24370
 
24391
24371
  ;
24392
- const Question_Classify_exports_ = /*#__PURE__*/(0,exportHelper/* default */.Z)(Question_Classifyvue_type_script_lang_js, [['render',Question_Classifyvue_type_template_id_00c7419b_render]])
24372
+ const Question_Classify_exports_ = /*#__PURE__*/(0,exportHelper/* default */.Z)(Question_Classifyvue_type_script_lang_js, [['render',Question_Classifyvue_type_template_id_25cb7a86_render]])
24393
24373
 
24394
24374
  /* harmony default export */ var Question_Classify = (Question_Classify_exports_);
24395
24375
  ;// CONCATENATED MODULE: ./src/components/questions/const.js
@@ -24414,6 +24394,8 @@ var questionMapper = {
24414
24394
  //填空
24415
24395
  '17': 'Question_Classify' //分类
24416
24396
  };
24397
+ // EXTERNAL MODULE: ./node_modules/core-js/modules/es.promise.js
24398
+ var es_promise = __webpack_require__(8674);
24417
24399
  // EXTERNAL MODULE: ./node_modules/crypto-js/index.js
24418
24400
  var crypto_js = __webpack_require__(1354);
24419
24401
  // EXTERNAL MODULE: ./node_modules/axios/index.js
@@ -24,4 +24,4 @@ return function(t){var n=e,r=n.lib,o=r.WordArray,i=r.Hasher,a=n.algo,s=o.create(
24
24
  * (c) 2022 Evan You
25
25
  * @license MIT
26
26
  */
27
- var Vr="store";function Rr(e,t){Object.keys(e).forEach((function(n){return t(e[n],n)}))}function _r(e){return null!==e&&"object"===typeof e}function jr(e){return e&&"function"===typeof e.then}function Fr(e,t){return function(){return e(t)}}function qr(e,t,n){return t.indexOf(e)<0&&(n&&n.prepend?t.unshift(e):t.push(e)),function(){var n=t.indexOf(e);n>-1&&t.splice(n,1)}}function Ur(e,t){e._actions=Object.create(null),e._mutations=Object.create(null),e._wrappedGetters=Object.create(null),e._modulesNamespaceMap=Object.create(null);var n=e.state;Wr(e,n,[],e._modules.root,!0),Qr(e,n,t)}function Qr(e,t,n){var r=e._state,o=e._scope;e.getters={},e._makeLocalGettersCache=Object.create(null);var a=e._wrappedGetters,s={},c={},u=(0,i.effectScope)(!0);u.run((function(){Rr(a,(function(t,n){s[n]=Fr(t,e),c[n]=(0,i.computed)((function(){return s[n]()})),Object.defineProperty(e.getters,n,{get:function(){return c[n].value},enumerable:!0})}))})),e._state=(0,i.reactive)({data:t}),e._scope=u,e.strict&&Zr(e),r&&n&&e._withCommit((function(){r.data=null})),o&&o.stop()}function Wr(e,t,n,r,o){var i=!n.length,a=e._modules.getNamespace(n);if(r.namespaced&&(e._modulesNamespaceMap[a],e._modulesNamespaceMap[a]=r),!i&&!o){var s=$r(t,n.slice(0,-1)),c=n[n.length-1];e._withCommit((function(){s[c]=r.state}))}var u=r.context=Xr(e,a,n);r.forEachMutation((function(t,n){var r=a+n;zr(e,r,t,u)})),r.forEachAction((function(t,n){var r=t.root?n:a+n,o=t.handler||t;Yr(e,r,o,u)})),r.forEachGetter((function(t,n){var r=a+n;Jr(e,r,t,u)})),r.forEachChild((function(r,i){Wr(e,t,n.concat(i),r,o)}))}function Xr(e,t,n){var r=""===t,o={dispatch:r?e.dispatch:function(n,r,o){var i=eo(n,r,o),a=i.payload,s=i.options,c=i.type;return s&&s.root||(c=t+c),e.dispatch(c,a)},commit:r?e.commit:function(n,r,o){var i=eo(n,r,o),a=i.payload,s=i.options,c=i.type;s&&s.root||(c=t+c),e.commit(c,a,s)}};return Object.defineProperties(o,{getters:{get:r?function(){return e.getters}:function(){return Kr(e,t)}},state:{get:function(){return $r(e.state,n)}}}),o}function Kr(e,t){if(!e._makeLocalGettersCache[t]){var n={},r=t.length;Object.keys(e.getters).forEach((function(o){if(o.slice(0,r)===t){var i=o.slice(r);Object.defineProperty(n,i,{get:function(){return e.getters[o]},enumerable:!0})}})),e._makeLocalGettersCache[t]=n}return e._makeLocalGettersCache[t]}function zr(e,t,n,r){var o=e._mutations[t]||(e._mutations[t]=[]);o.push((function(t){n.call(e,r.state,t)}))}function Yr(e,t,n,r){var o=e._actions[t]||(e._actions[t]=[]);o.push((function(t){var o=n.call(e,{dispatch:r.dispatch,commit:r.commit,getters:r.getters,state:r.state,rootGetters:e.getters,rootState:e.state},t);return jr(o)||(o=Promise.resolve(o)),e._devtoolHook?o.catch((function(t){throw e._devtoolHook.emit("vuex:error",t),t})):o}))}function Jr(e,t,n,r){e._wrappedGetters[t]||(e._wrappedGetters[t]=function(e){return n(r.state,r.getters,e.state,e.getters)})}function Zr(e){(0,i.watch)((function(){return e._state.data}),(function(){0}),{deep:!0,flush:"sync"})}function $r(e,t){return t.reduce((function(e,t){return e[t]}),e)}function eo(e,t,n){return _r(e)&&e.type&&(n=t,t=e,e=e.type),{type:e,payload:t,options:n}}var to="vuex bindings",no="vuex:mutations",ro="vuex:actions",oo="vuex",io=0;function ao(e,t){Lr({id:"org.vuejs.vuex",app:e,label:"Vuex",homepage:"https://next.vuex.vuejs.org/",logo:"https://vuejs.org/images/icons/favicon-96x96.png",packageName:"vuex",componentStateTypes:[to]},(function(n){n.addTimelineLayer({id:no,label:"Vuex Mutations",color:so}),n.addTimelineLayer({id:ro,label:"Vuex Actions",color:so}),n.addInspector({id:oo,label:"Vuex",icon:"storage",treeFilterPlaceholder:"Filter stores..."}),n.on.getInspectorTree((function(n){if(n.app===e&&n.inspectorId===oo)if(n.filter){var r=[];po(r,t._modules.root,n.filter,""),n.rootNodes=r}else n.rootNodes=[ho(t._modules.root,"")]})),n.on.getInspectorState((function(n){if(n.app===e&&n.inspectorId===oo){var r=n.nodeId;Kr(t,r),n.state=mo(vo(t._modules,r),"root"===r?t.getters:t._makeLocalGettersCache,r)}})),n.on.editInspectorState((function(n){if(n.app===e&&n.inspectorId===oo){var r=n.nodeId,o=n.path;"root"!==r&&(o=r.split("/").filter(Boolean).concat(o)),t._withCommit((function(){n.set(t._state.data,o,n.state.value)}))}})),t.subscribe((function(e,t){var r={};e.payload&&(r.payload=e.payload),r.state=t,n.notifyComponentUpdate(),n.sendInspectorTree(oo),n.sendInspectorState(oo),n.addTimelineEvent({layerId:no,event:{time:Date.now(),title:e.type,data:r}})})),t.subscribeAction({before:function(e,t){var r={};e.payload&&(r.payload=e.payload),e._id=io++,e._time=Date.now(),r.state=t,n.addTimelineEvent({layerId:ro,event:{time:e._time,title:e.type,groupId:e._id,subtitle:"start",data:r}})},after:function(e,t){var r={},o=Date.now()-e._time;r.duration={_custom:{type:"duration",display:o+"ms",tooltip:"Action duration",value:o}},e.payload&&(r.payload=e.payload),r.state=t,n.addTimelineEvent({layerId:ro,event:{time:Date.now(),title:e.type,groupId:e._id,subtitle:"end",data:r}})}})}))}var so=8702998,co=6710886,uo=16777215,lo={label:"namespaced",textColor:uo,backgroundColor:co};function fo(e){return e&&"root"!==e?e.split("/").slice(-2,-1)[0]:"Root"}function ho(e,t){return{id:t||"root",label:fo(t),tags:e.namespaced?[lo]:[],children:Object.keys(e._children).map((function(n){return ho(e._children[n],t+n+"/")}))}}function po(e,t,n,r){r.includes(n)&&e.push({id:r||"root",label:r.endsWith("/")?r.slice(0,r.length-1):r||"Root",tags:t.namespaced?[lo]:[]}),Object.keys(t._children).forEach((function(o){po(e,t._children[o],n,r+o+"/")}))}function mo(e,t,n){t="root"===n?t:t[n];var r=Object.keys(t),o={state:Object.keys(e.state).map((function(t){return{key:t,editable:!0,value:e.state[t]}}))};if(r.length){var i=Ao(t);o.getters=Object.keys(i).map((function(e){return{key:e.endsWith("/")?fo(e):e,editable:!1,value:go((function(){return i[e]}))}}))}return o}function Ao(e){var t={};return Object.keys(e).forEach((function(n){var r=n.split("/");if(r.length>1){var o=t,i=r.pop();r.forEach((function(e){o[e]||(o[e]={_custom:{value:{},display:e,tooltip:"Module",abstract:!0}}),o=o[e]._custom.value})),o[i]=go((function(){return e[n]}))}else t[n]=go((function(){return e[n]}))})),t}function vo(e,t){var n=t.split("/").filter((function(e){return e}));return n.reduce((function(e,r,o){var i=e[r];if(!i)throw new Error('Missing module "'+r+'" for path "'+t+'".');return o===n.length-1?i:i._children}),"root"===t?e:e.root._children)}function go(e){try{return e()}catch(t){return t}}var bo=function(e,t){this.runtime=t,this._children=Object.create(null),this._rawModule=e;var n=e.state;this.state=("function"===typeof n?n():n)||{}},So={namespaced:{configurable:!0}};So.namespaced.get=function(){return!!this._rawModule.namespaced},bo.prototype.addChild=function(e,t){this._children[e]=t},bo.prototype.removeChild=function(e){delete this._children[e]},bo.prototype.getChild=function(e){return this._children[e]},bo.prototype.hasChild=function(e){return e in this._children},bo.prototype.update=function(e){this._rawModule.namespaced=e.namespaced,e.actions&&(this._rawModule.actions=e.actions),e.mutations&&(this._rawModule.mutations=e.mutations),e.getters&&(this._rawModule.getters=e.getters)},bo.prototype.forEachChild=function(e){Rr(this._children,e)},bo.prototype.forEachGetter=function(e){this._rawModule.getters&&Rr(this._rawModule.getters,e)},bo.prototype.forEachAction=function(e){this._rawModule.actions&&Rr(this._rawModule.actions,e)},bo.prototype.forEachMutation=function(e){this._rawModule.mutations&&Rr(this._rawModule.mutations,e)},Object.defineProperties(bo.prototype,So);var To=function(e){this.register([],e,!1)};function yo(e,t,n){if(t.update(n),n.modules)for(var r in n.modules){if(!t.getChild(r))return void 0;yo(e.concat(r),t.getChild(r),n.modules[r])}}To.prototype.get=function(e){return e.reduce((function(e,t){return e.getChild(t)}),this.root)},To.prototype.getNamespace=function(e){var t=this.root;return e.reduce((function(e,n){return t=t.getChild(n),e+(t.namespaced?n+"/":"")}),"")},To.prototype.update=function(e){yo([],this.root,e)},To.prototype.register=function(e,t,n){var r=this;void 0===n&&(n=!0);var o=new bo(t,n);if(0===e.length)this.root=o;else{var i=this.get(e.slice(0,-1));i.addChild(e[e.length-1],o)}t.modules&&Rr(t.modules,(function(t,o){r.register(e.concat(o),t,n)}))},To.prototype.unregister=function(e){var t=this.get(e.slice(0,-1)),n=e[e.length-1],r=t.getChild(n);r&&r.runtime&&t.removeChild(n)},To.prototype.isRegistered=function(e){var t=this.get(e.slice(0,-1)),n=e[e.length-1];return!!t&&t.hasChild(n)};var Mo=function(e){var t=this;void 0===e&&(e={});var n=e.plugins;void 0===n&&(n=[]);var r=e.strict;void 0===r&&(r=!1);var o=e.devtools;this._committing=!1,this._actions=Object.create(null),this._actionSubscribers=[],this._mutations=Object.create(null),this._wrappedGetters=Object.create(null),this._modules=new To(e),this._modulesNamespaceMap=Object.create(null),this._subscribers=[],this._makeLocalGettersCache=Object.create(null),this._scope=null,this._devtools=o;var i=this,a=this,s=a.dispatch,c=a.commit;this.dispatch=function(e,t){return s.call(i,e,t)},this.commit=function(e,t,n){return c.call(i,e,t,n)},this.strict=r;var u=this._modules.root.state;Wr(this,u,[],this._modules.root),Qr(this,u),n.forEach((function(e){return e(t)}))},wo={state:{configurable:!0}};Mo.prototype.install=function(e,t){e.provide(t||Vr,this),e.config.globalProperties.$store=this;var n=void 0!==this._devtools&&this._devtools;n&&ao(e,this)},wo.state.get=function(){return this._state.data},wo.state.set=function(e){0},Mo.prototype.commit=function(e,t,n){var r=this,o=eo(e,t,n),i=o.type,a=o.payload,s=(o.options,{type:i,payload:a}),c=this._mutations[i];c&&(this._withCommit((function(){c.forEach((function(e){e(a)}))})),this._subscribers.slice().forEach((function(e){return e(s,r.state)})))},Mo.prototype.dispatch=function(e,t){var n=this,r=eo(e,t),o=r.type,i=r.payload,a={type:o,payload:i},s=this._actions[o];if(s){try{this._actionSubscribers.slice().filter((function(e){return e.before})).forEach((function(e){return e.before(a,n.state)}))}catch(u){0}var c=s.length>1?Promise.all(s.map((function(e){return e(i)}))):s[0](i);return new Promise((function(e,t){c.then((function(t){try{n._actionSubscribers.filter((function(e){return e.after})).forEach((function(e){return e.after(a,n.state)}))}catch(u){0}e(t)}),(function(e){try{n._actionSubscribers.filter((function(e){return e.error})).forEach((function(t){return t.error(a,n.state,e)}))}catch(u){0}t(e)}))}))}},Mo.prototype.subscribe=function(e,t){return qr(e,this._subscribers,t)},Mo.prototype.subscribeAction=function(e,t){var n="function"===typeof e?{before:e}:e;return qr(n,this._actionSubscribers,t)},Mo.prototype.watch=function(e,t,n){var r=this;return(0,i.watch)((function(){return e(r.state,r.getters)}),t,Object.assign({},n))},Mo.prototype.replaceState=function(e){var t=this;this._withCommit((function(){t._state.data=e}))},Mo.prototype.registerModule=function(e,t,n){void 0===n&&(n={}),"string"===typeof e&&(e=[e]),this._modules.register(e,t),Wr(this,this.state,e,this._modules.get(e),n.preserveState),Qr(this,this.state)},Mo.prototype.unregisterModule=function(e){var t=this;"string"===typeof e&&(e=[e]),this._modules.unregister(e),this._withCommit((function(){var n=$r(t.state,e.slice(0,-1));delete n[e[e.length-1]]})),Ur(this)},Mo.prototype.hasModule=function(e){return"string"===typeof e&&(e=[e]),this._modules.isRegistered(e)},Mo.prototype.hotUpdate=function(e){this._modules.update(e),Ur(this,!0)},Mo.prototype._withCommit=function(e){var t=this._committing;this._committing=!0,e(),this._committing=t},Object.defineProperties(Mo.prototype,wo);var Co=xo((function(e,t){var n={};return Po(t).forEach((function(t){var r=t.key,o=t.val;n[r]=function(){var t=this.$store.state,n=this.$store.getters;if(e){var r=Io(this.$store,"mapState",e);if(!r)return;t=r.context.state,n=r.context.getters}return"function"===typeof o?o.call(this,t,n):t[o]},n[r].vuex=!0})),n})),Bo=(xo((function(e,t){var n={};return Po(t).forEach((function(t){var r=t.key,o=t.val;n[r]=function(){var t=[],n=arguments.length;while(n--)t[n]=arguments[n];var r=this.$store.commit;if(e){var i=Io(this.$store,"mapMutations",e);if(!i)return;r=i.context.commit}return"function"===typeof o?o.apply(this,[r].concat(t)):r.apply(this.$store,[o].concat(t))}})),n})),xo((function(e,t){var n={};return Po(t).forEach((function(t){var r=t.key,o=t.val;o=e+o,n[r]=function(){if(!e||Io(this.$store,"mapGetters",e))return this.$store.getters[o]},n[r].vuex=!0})),n})),xo((function(e,t){var n={};return Po(t).forEach((function(t){var r=t.key,o=t.val;n[r]=function(){var t=[],n=arguments.length;while(n--)t[n]=arguments[n];var r=this.$store.dispatch;if(e){var i=Io(this.$store,"mapActions",e);if(!i)return;r=i.context.dispatch}return"function"===typeof o?o.apply(this,[r].concat(t)):r.apply(this.$store,[o].concat(t))}})),n})));function Po(e){return Eo(e)?Array.isArray(e)?e.map((function(e){return{key:e,val:e}})):Object.keys(e).map((function(t){return{key:t,val:e[t]}})):[]}function Eo(e){return Array.isArray(e)||_r(e)}function xo(e){return function(t,n){return"string"!==typeof t?(n=t,t=""):"/"!==t.charAt(t.length-1)&&(t+="/"),e(t,n)}}function Io(e,t,n){var r=e._modulesNamespaceMap[n];return r}var Go={name:"Question_Programming",props:{isEnterCodeByInit:{type:Boolean,default:!1},urlQuery:{type:String,default:""},isSub:{type:Boolean,default:!1},questionInfo:{type:Object,default:{}},bus:{type:Object,default:{}},mode:{type:String,default:"exam"},showScore:{type:Boolean,default:!1}},mounted:function(){var e=this;X(this),this.$watch("oss_temp_url",(function(t){if(t){var n=e.isAnswered();e.$emit("getIsAnswered",n),"exam"===e.mode&&e.bus.$emit("questionCardChange",{questionIndex:e.questionInfo.questionIndex-1,answered:n})}}),{immediate:!0})},created:function(){this.isEnterCodeByInit&&(this.oss_temp_url?this.startCode("2"):this.startCode("1"))},data:function(){return Q({iframe:null,showFrame:!1,analyCorrectAnswer:"",iframeUrl:"",code_file_oss_temp_path:"",oss_temp_url:"",scratch_answer_json:"",loading:!1,enterCode:!1,codeTypeMap:{1:"Scratch",2:"Python",3:"PyGame",4:"C++"},codeTypeImgMap:{1:r(3031),2:r(3843),3:r(6543),4:r(2657)},answerMap:{}},JSON.parse(W))},watch:{questionInfo:{handler:function(e,t){if(e){this.answerMap=e.answerMap;var n=e.answerMap;n&&(this.code_file_oss_temp_path=n.code_file_oss_temp_path,this.oss_temp_url=n.oss_temp_url)}},immediate:!0}},computed:Q({},Co("zykjcommonQuestions",["pythonCodeWebPath","scratchCodeWebPath","cplusCodeWebPath"])),methods:Q(Q({},Bo("zykjcommonQuestions",["getEditorUrlActions"])),{},{getAnswer:function(){return{code_file_oss_temp_path:this.code_file_oss_temp_path,oss_temp_url:this.oss_temp_url,scratch_answer_json:this.scratch_answer_json}},isAnswered:function(){var e=""!==this.oss_temp_url;return e},isCorrect:function(){var e="1"===this.questionInfo.answerMap.is_correct;return e},getCodeWebPath:function(e){var t=this;this.pythonCodeWebPath||this.scratchCodeWebPath||this.cplusCodeWebPath?e&&e():(this.loading=!0,this.getEditorUrlActions().then((function(){t.loading=!1,e&&e()}),(function(){t.loading=!1})))},startCode:function(e){var t=this;this.loading||(this.getCodeWebPath((function(){var n={1:t.questionInfo.template_file_full_url,2:t.oss_temp_url,3:t.oss_temp_url,4:t.questionInfo.reference_file_full_url},r="",o=t.questionInfo.code_type,i=n[e],a=t.urlQuery+"&codeUrl=".concat(i);switch(o){case 1:r="".concat(t.scratchCodeWebPath,"/?").concat(a);break;case 2:r="".concat(t.pythonCodeWebPath,"/?").concat(a);break;case 3:r="".concat(t.pythonCodeWebPath,"/?").concat(a,"&pygame=true");break;case 4:r="".concat(t.cplusCodeWebPath,"/?").concat(a);break}t.iframeUrl=r})),this.showFrame=!0)},getQuestionInfo:function(){var e=this,t={type:"getQuestionInfo",data:e.questionInfo.htmlContent};this.iframe&&this.iframe.contentWindow.postMessage(JSON.stringify(t),"*")},submitCodeQuestionByTimeover:function(){var e={type:"submitCodeQuestionByTimeover"};this.iframe&&this.iframe.contentWindow.postMessage(JSON.stringify(e),"*")},iframeLoaded:function(e){this.iframe=e,this.enterCode=!0,this.bus.$emit("enterCode",!0)},closeIframe:function(){this.enterCode=!1,this.bus.$emit("enterCode",!1),this.showFrame=!1},closeAndSave:function(e){this.saveCodeOnly(e),this.isEnterCodeByInit||this.closeIframe(),this.$emit("closeAndSave",e)},saveCodeOnly:function(e){var t=this;this.code_file_oss_temp_path=e.codeFileOssTempPath,this.oss_temp_url=e.ossTempUrl,this.scratch_answer_json=e.scratch_answer_json,this.bus.$emit("submitQuestion",{saveType:1,submitRequestAutoQuit:!1,needSubmitRequest:!1});var n=this.isAnswered();"exam"===this.mode&&this.bus.$emit("questionCardChange",{questionIndex:t.questionInfo.questionIndex-1,answered:n}),this.$emit("saveCodeOnly",e)},uploadCodingFileSuccess:function(e){this.code_file_oss_temp_path=e.codeFileOssTempPath,this.oss_temp_url=e.ossTempUrl,this.scratch_answer_json=e.scratch_answer_json,this.bus.$emit("uploadCodingFileSuccess")}}),components:{IframeComponent:Br,MediaLooker:Je,Loading:Mr}};const ko=(0,ze.Z)(Go,[["render",hr]]);var Do=ko,Ho={class:"zykjcommon-question",style:{width:"100%",height:"100%"}},Oo={class:"box"},No={class:"main-block"},Lo=["src"],Vo=(0,i.createElementVNode)("div",{class:"main-content"},[(0,i.createElementVNode)("div",{class:"main-append"})],-1),Ro=(0,i.createElementVNode)("div",{class:"prev"},[(0,i.createElementVNode)("div",{class:"prev-main"})],-1),_o=(0,i.createElementVNode)("div",{class:"next"},[(0,i.createElementVNode)("div",{class:"next-main"})],-1),jo={class:"list"},Fo=["idx"],qo={class:"list-item-text"};function Uo(e,t,n,r,o,a){return(0,i.openBlock)(),(0,i.createElementBlock)("div",Ho,[(0,i.createElementVNode)("div",{class:"question-classify",style:(0,i.normalizeStyle)(o.bigBgCss)},[(0,i.createElementVNode)("div",Oo,[((0,i.openBlock)(!0),(0,i.createElementBlock)(i.Fragment,null,(0,i.renderList)(o.bigBoxItemList,(function(e,t){return(0,i.openBlock)(),(0,i.createElementBlock)("div",{class:"box-item",style:(0,i.normalizeStyle)(e.bgUrlCss),key:t},[(0,i.createElementVNode)("div",No,[(0,i.createElementVNode)("img",{src:e.imgUrl,alt:""},null,8,Lo)]),Vo],4)})),128))]),(0,i.createElementVNode)("div",{class:"list-outter",style:(0,i.normalizeStyle)(o.bottomBgCss)},[Ro,_o,(0,i.createElementVNode)("div",jo,[((0,i.openBlock)(!0),(0,i.createElementBlock)(i.Fragment,null,(0,i.renderList)(o.optionList,(function(e,t){return(0,i.openBlock)(),(0,i.createElementBlock)("div",{class:"list-item",idx:e.idx,style:(0,i.normalizeStyle)(e.bgUrlCss),key:t},[(0,i.createElementVNode)("div",qo,(0,i.toDisplayString)(e.content),1)],12,Fo)})),128))])],4)],4)])}r(2707),r(8674),r(4553),r(561);var Qo=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1440,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,r=arguments.length>3?arguments[3]:void 0,o=100,i=document.documentElement.clientWidth||document.body.clientWidth,a=document.documentElement.clientHeight||document.body.clientHeight;a-=t;var s=4.3/3,c=s/(i/a),u=parseInt(i*c);r.style.fontSize=u/e*o*n+"px"},Wo=Xe.getDeviceEnv(),Xo={name:"Question_Classify",props:{questionInfo:{type:Object,default:{}},bus:{type:Object,default:function(){return{}}},mode:{type:String,default:"exam"},screenRepairH:{type:Number,default:0},screenScale:{type:Number,default:1}},created:function(){},unmounted:function(){this.unmountedDo()},destroyed:function(){this.unmountedDo()},mounted:function(){var e=this;this.setRootFontSize(),window.addEventListener("resize",this.setRootFontSize),this.init(),this.$watch("optionList",(function(t){t&&t.length&&e.$nextTick((function(){e.dothings()}))}),{immediate:!0,deep:!0})},data:function(){return{animationing:!1,analyCorrectAnswer:"",classify_question_info:{},answerMap:{},optionList:[],bigBoxItemList:[],bigBgCss:"",bottomBgCss:"",listItemBgCss:"",env:Wo,p1:{},p2:{},listItem:null,moveDiv:null,timer:null,mousedown:"mobile"===Wo?"touchstart":"mousedown",mousemove:"mobile"===Wo?"touchmove":"mousemove",mouseup:"mobile"===Wo?"touchend":"mouseup",dragWay:"",flag:!1,scrollDistance:3e3}},watch:{questionInfo:{handler:function(e,t){e&&(console.log(e,33),this.parseLists(e),this.answerMap=e.answerMap,e.answerMap&&this.mode)},immediate:!0}},computed:{},methods:{getAnswer:function(){var e=[];return $(this.$el).find(".box-item").each((function(t,n){var r=$(this),o=[];r.find(".append-item").each((function(e,t){o.push(Number($(t).attr("idx")))})),o=o.sort((function(e,t){return e-t})),console.log(o,345),e.push({big_type_index:t+1,small_type_index_list:o})})),{classify_mapping_list:e}},isAnswered:function(){var e=$(this.$el).find(".list .list-item").length,t=0===e;return t},isCorrect:function(){var e="1"===this.questionInfo.answerMap.is_correct;return e},intervalFindEl:function(){var e=this;return new Promise((function(t,n){if(console.log(e.$el,345),e.$el)t();else var r=setInterval((function(){e.$el&&(clearInterval(r),t())}),50)}))},parseLists:function(e){this.classify_question_info=e.classify_question_info;var t=e.exam_options_data;if(this.classify_question_info){this.classify_question_info.background_file&&(this.bigBgCss="background: url(".concat(this.classify_question_info.background_file.file_url,") no-repeat center;background-size: 100% 100%")),this.classify_question_info.bottom_img_file&&(this.bottomBgCss="background: url(".concat(this.classify_question_info.bottom_img_file.file_url,") no-repeat center;background-size: 100% 100%"));var n=[];t.forEach((function(e){n.push({content:e.data.option_content,bgUrlCss:"background: url(".concat(e.data.file_url,") no-repeat center;background-size: 100% 100%"),idx:e.index})})),this.optionList=n,this.listItemBgCss=n[0]?n[0].bgUrlCss:"";var r=[],o=this.classify_question_info.big_type_box_image_list,i=this.classify_question_info.big_type_option_list;o.forEach((function(e,t){r.push({imgUrl:i[t].file_url,bgUrl:e.file_url,bgUrlCss:"background: url(".concat(e.file_url,") no-repeat center;background-size: 100% 100%")})})),this.bigBoxItemList=r}},setRootFontSize:function(){Qo(1e3,this.screenRepairH,this.screenScale,this.$el)},unmountedDo:function(){window.removeEventListener("resize",this.setRootFontSize),document.removeEventListener("gesturestart",this.gesturestartListener),$(this.$el).find(".question-classify .append-item").off(this.mousedown),$(this.$el).find(".question-classify .list-item").off(this.mousedown),$(document).off(this.mouseup);var e=document.getElementsByTagName("html")[0];e.style.fontSize=""},answeredNotify:function(){var e=this,t=e.isAnswered();e.$emit("getIsAnswered",t),"exam"===e.mode&&e.bus.$emit("questionCardChange",{questionIndex:e.questionInfo.questionIndex-1,answered:t})},gesturestartListener:function(e){e.preventDefault()},init:function(){"mobile"===Wo&&document.addEventListener("gesturestart",this.gesturestartListener)},getSpecArr:function(){var e=this,t=[],n=e.moveDiv.offset().left,r=n+e.moveDiv.width(),o=e.moveDiv.offset().top,i=o+e.moveDiv.height();return $(this.$el).find(".box-item").each((function(e,a){var s=$(a),c=s.offset().left,u=c+s.width(),l=s.offset().top,f=l+s.height();n>c&&r<u&&o>l&&i<f&&t.push({dom:s})})),t},bindDragDomEvent:function(e,t){var n=this;e.on(this.mousedown,(function(e){if(!n.moveDiv){n.flag=!1,n.dragWay=t,console.log(e),e.stopPropagation(),e.preventDefault(),n.listItem=$(this),n.listItem.addClass("drag"),n.p1.moveX=n.listItem.offset().left,n.p1.moveY=n.listItem.offset().top-30;var r=n.listItem.attr("idx");n.moveDiv=$('<div class="question-classify-moveDiv" idx="'.concat(r,'" style="').concat(n.listItemBgCss,'"><div class="list-item-text">').concat(n.listItem.find(".list-item-text").text(),"</div></div>")),n.moveDiv.css({left:"".concat(n.p1.moveX,"px"),top:"".concat(n.p1.moveY,"px")}),$(n.$el).append(n.moveDiv),$(document).on(n.mousemove,(function(e){e.stopPropagation(),n.p2.moveX=e.clientX||e.originalEvent.touches&&e.originalEvent.touches[0].clientX,n.p2.moveY=e.clientY||e.originalEvent.touches&&e.originalEvent.touches[0].clientY;var t=n.p2.moveX-n.moveDiv.width()/2,r=n.p2.moveY-n.moveDiv.height()/2;n.moveDiv.css({left:t+"px",top:r+"px"})}))}}))},appendMoveDiv:function(e){var t=this;t.listItem.remove();var n=t.moveDiv.attr("idx"),r=$('<div class="'.concat(e.appendItemClassName,'" idx="').concat(n,'" style="').concat(t.listItemBgCss,'"><div class="list-item-text">').concat(t.moveDiv.find(".list-item-text").text(),"</div></div>"));r.css({opacity:0}),e.targetList.append(r),e.targetList[e.scrollDirection](t.scrollDistance);var o=r.offset().left,i=r.offset().top;t.animationing=!0,t.moveDiv.css({transition:"all 0.5s",left:o,top:i}).on("transitionend",(function(){t.flag||(t.moveDiv.remove(),t.moveDiv.off("transitionend"),t.moveDiv=null,r.css({opacity:1}),t.answeredNotify(),t.bindDragDomEvent(r,e.op),t.animationing=!1),t.flag=!0}))},bindNextPrevEvent:function(e){var t=this;$(this.$el).find(".question-classify .".concat(e)).on("click",(function(n){n.stopPropagation(),n.preventDefault();var r=$(t.$el).find(".question-classify .list-item"),o=$(t.$el).find(".question-classify .list"),i=r.outerWidth()*("next"===e?1:-1),a=o.scrollLeft();console.log(a),$(t.$el).find(".question-classify .list").stop(!0).animate({scrollLeft:a+i},500)}))},dothings:function(){var e=this;this.answerMap&&this.answerMap.classify_mapping_list&&this.answerMap.classify_mapping_list.length&&this.setAnswerDo(),e.bindDragDomEvent($(this.$el).find(".question-classify .list-item"),"go"),$(document).on(e.mouseup,(function(t){if(!e.animationing)if("go"===e.dragWay){if($(document).off(e.mousemove),e.listItem&&e.listItem.removeClass("drag"),e.moveDiv){var n=e.getSpecArr();if(0===n.length)e.moveDiv&&(e.moveDiv.remove(),e.moveDiv=null);else{var r=n[0].dom;e.appendMoveDiv({targetList:r.find(".main-append"),appendItemClassName:"append-item",op:"back",scrollDirection:"scrollTop"})}}}else if("back"===e.dragWay&&($(document).off(e.mousemove),e.listItem&&e.listItem.removeClass("drag"),e.moveDiv)){var o=e.getSpecArr();if(0===o.length)e.appendMoveDiv({targetList:$(e.$el).find(".question-classify .list"),appendItemClassName:"list-item",op:"go",scrollDirection:"scrollLeft"});else{var i=o[0].dom,a=e.listItem.parents(".question-classify .box-item");i.get(0)===a.get(0)?(console.log("自己"),e.moveDiv.remove(),e.moveDiv=null,e.listItem&&e.listItem.removeClass("drag")):(console.log("不是自己"),e.appendMoveDiv({targetList:i.find(".main-append"),appendItemClassName:"append-item",op:"back",scrollDirection:"scrollTop"}),console.log("不是自己"))}console.log(o.length)}})),e.bindNextPrevEvent("next"),e.bindNextPrevEvent("prev")},setAnswerDo:function(){var e=this,t=this,n=[];$(this.$el).find(".question-classify .list-item").each((function(e,t){n.push(Number($(t).attr("idx")))})),this.answerMap.classify_mapping_list.forEach((function(r,o){r.small_type_index_list.forEach((function(r){var i=n.findIndex((function(e){return e==r}));if(i>-1){n.splice(i,1);var a=$(e.$el).find(".question-classify .list-item").eq(i),s=a.attr("idx"),c=$('<div class="append-item" idx="'.concat(s,'" style="').concat(t.listItemBgCss,'"><div class="list-item-text">').concat(a.find(".list-item-text").text(),"</div></div>"));t.bindDragDomEvent(c,"back"),$(e.$el).find(".main-append").eq(o).append(c),a.remove()}}))})),this.answeredNotify()}},components:{}};const Ko=(0,ze.Z)(Xo,[["render",Uo]]);var zo=Ko,Yo={1:"Question_SingleChoice",2:"Question_MultipleChoice",3:"Question_SingleChoice",7:"Question_BriefAnswer",16:"Question_Programming",11:"Question_Reading",4:"Question_FillBlank",17:"Question_Classify"},Jo=r(1354),Zo=r(9669),$o=r.n(Zo),ei=r(7631),ti=r.n(ei),ni="piw38kulfozrea7ydmjnvbc965q1gt2x",ri=function(e,t,n,r){void 0!=n&&"undefined"!==typeof n["password"]&&(n["password"]=ti().hex_md5(ti().hex_md5(n["password"]+"FE605C9343A3A47764598FDC184EC66F").toUpperCase()+"FE605C9343A3A47764598FDC184EC66F").toUpperCase());var o=e+"\n/student-web"+t+"\n"+r+"\n"+(n?JSON.stringify(n):""),i=Jo.enc.Base64.stringify((0,Jo.HmacSHA256)(o,ni)),a=function(e){var t=e.replace(/\+/g,"-");t=t.replace(/\//g,"_");var n=t.length%4,r="====";return t+=r.substring(0,n),t};return a(i)};$o().defaults.baseURL="https://jsl-api.thedeer.cn/student-web/",$o().defaults.timeout=6e4,$o().defaults.withCredentials=!0;var oi=function(e,t){if(t&&-1!=t["Content-Type"].indexOf("multipart/form-data")){var n=new FormData;for(var r in e)n.append(r,e[r]);return n}return JSON.stringify(e)},ii=function(e){e=JSON.parse(e),e.hasOwnProperty("errorCode")&&(e.error_code=e.errorCode);var t=e,n=t.error_code,r=t.message;if(n){var o=[39002,39003];if(o.indexOf(n)<=-1){var i=r||"系统异常";Xe.messageTip("warning",i)}}return e};function ai(e,t,n,r,o){var i=void 0,a=void 0;e=e.toUpperCase(),t+=0===n.indexOf("/")?n.substr(1):n;var s=window.isMock;"undefined"!==typeof o&&"undefined"!==typeof o.isMock&&(s=o.isMock,delete o.isMock),s&&o&&o.onUploadProgress&&delete o.onUploadProgress;var c=n;"/"!==n[0]&&(c="/"+n);var u=(new Date).getTime(),l={ts:u,sign:ri(e,c,r,u),token:Xe.getToken()};switch(e){case"Get":a=r||{};break;default:case"POST":i=r||{},l["Content-Type"]=o&&o.contentType?o.contentType:"application/json";break}return t instanceof Array?$o().all([]).then($o().spread((function(){}))):$o()(Object.assign({headers:l,method:e,url:t,data:i,params:a,transformRequest:oi,transformResponse:ii},o)).then((function(e){return e.data})).catch((function(e){return console.log("服务端请求/响应错误:",e,e.config),Promise.reject(e)}))}var si=function(e,t,n){return ai("GET","",e,t,n)},ci={editorUrl:"/open/editor-url"},ui={pythonCodeWebPath:"",scratchCodeWebPath:"",cplusCodeWebPath:""},li={namespaced:!0,state:ui,getters:{},mutations:{setCodeWebPath:function(e,t){e.pythonCodeWebPath=t.pythonCodeWebPath,e.scratchCodeWebPath=t.scratchCodeWebPath,e.cplusCodeWebPath=t.cplusCodeWebPath}},actions:{getEditorUrlActions:function(e){var t=e.commit;e.dispatch;return new Promise((function(e,n){si("".concat(ci.editorUrl)).then((function(n){var r=n.error_code,o=n.data;if(!r){var i=o.pythonCodeWebPath,a=o.scratchCodeWebPath,s=o.cplusCodeWebPath;t("setCodeWebPath",{pythonCodeWebPath:i,scratchCodeWebPath:a,cplusCodeWebPath:s})}e(n)}),(function(e){n(e)}))}))}}},fi=function(e,t,n){var r=this,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:void 0;function i(e,t){e.forEach((function(e){if("img"===e["<>"]&&e.hasOwnProperty("width")){var n=Number(e.width);n>t&&(e.width=Math.floor(t),e.height&&delete e.height)}e.html&&e.html.length&&i(e.html,t)}))}t.forEach((function(t,a){if(t.questionComponent=Yo[t.question_type],void 0===o?t.questionIndex=a+1:(t.questionIndex=o+1+"-"+(a+1),t.questionIndex2=a+1),n&&n.hasOwnProperty(t.question_id)){if(t.answerMap=n[t.question_id],"analysis"===e){t.answerMap.user_coding_file&&(t.answerMap.oss_temp_url=t.answerMap.user_coding_file),t.score=t.answerMap.question_max_score;var s=Object.keys(t.answerMap),c=/^user_/gi;s.forEach((function(e){if(c.test(e)){var n=e.replace(c,"");t.answerMap[n]=t.answerMap[e]}}))}}else t.answerMap=null;var u=t.question_type;3==u?t.exam_options_data=[{index:1,data:{name:"正确"}},{index:2,data:{name:"错误"}}]:t.exam_options_data&&t.exam_options_data.length&&t.exam_options_data.forEach((function(e,t){e.enIndex=Xe.indexToEnIndex(t+1)}));try{var l=JSON.parse(t.content),f=jQuery(".question-list").width()-30;i(l,f),t.htmlContent=$.json2html({},l)}catch(d){t.htmlContent=t.content}try{t.analysis?t.analysisHtmlContent=$.json2html({},JSON.parse(t.analysis)):t.analysisHtmlContent=""}catch(d){t.analysisHtmlContent=t.analysis}t.sub_questions&&t.sub_questions.length&&r.parseQuestionListItem(e,t.sub_questions,n,a)}))};function di(e){return e.registerModule("zykjcommonQuestions",li),{install:function(e){Xe.getVueVersion();e.mixin({methods:{parseQuestionListItem:fi}}),e.component("Question_SingleChoice",et),e.component("Question_MultipleChoice",Nt),e.component("Question_Reading",Jt),e.component("Question_BriefAnswer",xn),e.component("Question_FillBlank",jn),e.component("Question_Programming",Do),e.component("Question_Classify",zo)},parseQuestionListItem:fi,questionMapper:Yo,Question_SingleChoice:et,Question_MultipleChoice:Nt,Question_Reading:Jt,Question_BriefAnswer:xn,Question_FillBlank:jn,Question_Programming:Do,Question_Classify:zo}}var hi=di}(),o}()}));
27
+ var Vr="store";function Rr(e,t){Object.keys(e).forEach((function(n){return t(e[n],n)}))}function _r(e){return null!==e&&"object"===typeof e}function jr(e){return e&&"function"===typeof e.then}function Fr(e,t){return function(){return e(t)}}function qr(e,t,n){return t.indexOf(e)<0&&(n&&n.prepend?t.unshift(e):t.push(e)),function(){var n=t.indexOf(e);n>-1&&t.splice(n,1)}}function Ur(e,t){e._actions=Object.create(null),e._mutations=Object.create(null),e._wrappedGetters=Object.create(null),e._modulesNamespaceMap=Object.create(null);var n=e.state;Wr(e,n,[],e._modules.root,!0),Qr(e,n,t)}function Qr(e,t,n){var r=e._state,o=e._scope;e.getters={},e._makeLocalGettersCache=Object.create(null);var a=e._wrappedGetters,s={},c={},u=(0,i.effectScope)(!0);u.run((function(){Rr(a,(function(t,n){s[n]=Fr(t,e),c[n]=(0,i.computed)((function(){return s[n]()})),Object.defineProperty(e.getters,n,{get:function(){return c[n].value},enumerable:!0})}))})),e._state=(0,i.reactive)({data:t}),e._scope=u,e.strict&&Zr(e),r&&n&&e._withCommit((function(){r.data=null})),o&&o.stop()}function Wr(e,t,n,r,o){var i=!n.length,a=e._modules.getNamespace(n);if(r.namespaced&&(e._modulesNamespaceMap[a],e._modulesNamespaceMap[a]=r),!i&&!o){var s=$r(t,n.slice(0,-1)),c=n[n.length-1];e._withCommit((function(){s[c]=r.state}))}var u=r.context=Xr(e,a,n);r.forEachMutation((function(t,n){var r=a+n;zr(e,r,t,u)})),r.forEachAction((function(t,n){var r=t.root?n:a+n,o=t.handler||t;Yr(e,r,o,u)})),r.forEachGetter((function(t,n){var r=a+n;Jr(e,r,t,u)})),r.forEachChild((function(r,i){Wr(e,t,n.concat(i),r,o)}))}function Xr(e,t,n){var r=""===t,o={dispatch:r?e.dispatch:function(n,r,o){var i=eo(n,r,o),a=i.payload,s=i.options,c=i.type;return s&&s.root||(c=t+c),e.dispatch(c,a)},commit:r?e.commit:function(n,r,o){var i=eo(n,r,o),a=i.payload,s=i.options,c=i.type;s&&s.root||(c=t+c),e.commit(c,a,s)}};return Object.defineProperties(o,{getters:{get:r?function(){return e.getters}:function(){return Kr(e,t)}},state:{get:function(){return $r(e.state,n)}}}),o}function Kr(e,t){if(!e._makeLocalGettersCache[t]){var n={},r=t.length;Object.keys(e.getters).forEach((function(o){if(o.slice(0,r)===t){var i=o.slice(r);Object.defineProperty(n,i,{get:function(){return e.getters[o]},enumerable:!0})}})),e._makeLocalGettersCache[t]=n}return e._makeLocalGettersCache[t]}function zr(e,t,n,r){var o=e._mutations[t]||(e._mutations[t]=[]);o.push((function(t){n.call(e,r.state,t)}))}function Yr(e,t,n,r){var o=e._actions[t]||(e._actions[t]=[]);o.push((function(t){var o=n.call(e,{dispatch:r.dispatch,commit:r.commit,getters:r.getters,state:r.state,rootGetters:e.getters,rootState:e.state},t);return jr(o)||(o=Promise.resolve(o)),e._devtoolHook?o.catch((function(t){throw e._devtoolHook.emit("vuex:error",t),t})):o}))}function Jr(e,t,n,r){e._wrappedGetters[t]||(e._wrappedGetters[t]=function(e){return n(r.state,r.getters,e.state,e.getters)})}function Zr(e){(0,i.watch)((function(){return e._state.data}),(function(){0}),{deep:!0,flush:"sync"})}function $r(e,t){return t.reduce((function(e,t){return e[t]}),e)}function eo(e,t,n){return _r(e)&&e.type&&(n=t,t=e,e=e.type),{type:e,payload:t,options:n}}var to="vuex bindings",no="vuex:mutations",ro="vuex:actions",oo="vuex",io=0;function ao(e,t){Lr({id:"org.vuejs.vuex",app:e,label:"Vuex",homepage:"https://next.vuex.vuejs.org/",logo:"https://vuejs.org/images/icons/favicon-96x96.png",packageName:"vuex",componentStateTypes:[to]},(function(n){n.addTimelineLayer({id:no,label:"Vuex Mutations",color:so}),n.addTimelineLayer({id:ro,label:"Vuex Actions",color:so}),n.addInspector({id:oo,label:"Vuex",icon:"storage",treeFilterPlaceholder:"Filter stores..."}),n.on.getInspectorTree((function(n){if(n.app===e&&n.inspectorId===oo)if(n.filter){var r=[];po(r,t._modules.root,n.filter,""),n.rootNodes=r}else n.rootNodes=[ho(t._modules.root,"")]})),n.on.getInspectorState((function(n){if(n.app===e&&n.inspectorId===oo){var r=n.nodeId;Kr(t,r),n.state=mo(vo(t._modules,r),"root"===r?t.getters:t._makeLocalGettersCache,r)}})),n.on.editInspectorState((function(n){if(n.app===e&&n.inspectorId===oo){var r=n.nodeId,o=n.path;"root"!==r&&(o=r.split("/").filter(Boolean).concat(o)),t._withCommit((function(){n.set(t._state.data,o,n.state.value)}))}})),t.subscribe((function(e,t){var r={};e.payload&&(r.payload=e.payload),r.state=t,n.notifyComponentUpdate(),n.sendInspectorTree(oo),n.sendInspectorState(oo),n.addTimelineEvent({layerId:no,event:{time:Date.now(),title:e.type,data:r}})})),t.subscribeAction({before:function(e,t){var r={};e.payload&&(r.payload=e.payload),e._id=io++,e._time=Date.now(),r.state=t,n.addTimelineEvent({layerId:ro,event:{time:e._time,title:e.type,groupId:e._id,subtitle:"start",data:r}})},after:function(e,t){var r={},o=Date.now()-e._time;r.duration={_custom:{type:"duration",display:o+"ms",tooltip:"Action duration",value:o}},e.payload&&(r.payload=e.payload),r.state=t,n.addTimelineEvent({layerId:ro,event:{time:Date.now(),title:e.type,groupId:e._id,subtitle:"end",data:r}})}})}))}var so=8702998,co=6710886,uo=16777215,lo={label:"namespaced",textColor:uo,backgroundColor:co};function fo(e){return e&&"root"!==e?e.split("/").slice(-2,-1)[0]:"Root"}function ho(e,t){return{id:t||"root",label:fo(t),tags:e.namespaced?[lo]:[],children:Object.keys(e._children).map((function(n){return ho(e._children[n],t+n+"/")}))}}function po(e,t,n,r){r.includes(n)&&e.push({id:r||"root",label:r.endsWith("/")?r.slice(0,r.length-1):r||"Root",tags:t.namespaced?[lo]:[]}),Object.keys(t._children).forEach((function(o){po(e,t._children[o],n,r+o+"/")}))}function mo(e,t,n){t="root"===n?t:t[n];var r=Object.keys(t),o={state:Object.keys(e.state).map((function(t){return{key:t,editable:!0,value:e.state[t]}}))};if(r.length){var i=Ao(t);o.getters=Object.keys(i).map((function(e){return{key:e.endsWith("/")?fo(e):e,editable:!1,value:go((function(){return i[e]}))}}))}return o}function Ao(e){var t={};return Object.keys(e).forEach((function(n){var r=n.split("/");if(r.length>1){var o=t,i=r.pop();r.forEach((function(e){o[e]||(o[e]={_custom:{value:{},display:e,tooltip:"Module",abstract:!0}}),o=o[e]._custom.value})),o[i]=go((function(){return e[n]}))}else t[n]=go((function(){return e[n]}))})),t}function vo(e,t){var n=t.split("/").filter((function(e){return e}));return n.reduce((function(e,r,o){var i=e[r];if(!i)throw new Error('Missing module "'+r+'" for path "'+t+'".');return o===n.length-1?i:i._children}),"root"===t?e:e.root._children)}function go(e){try{return e()}catch(t){return t}}var bo=function(e,t){this.runtime=t,this._children=Object.create(null),this._rawModule=e;var n=e.state;this.state=("function"===typeof n?n():n)||{}},So={namespaced:{configurable:!0}};So.namespaced.get=function(){return!!this._rawModule.namespaced},bo.prototype.addChild=function(e,t){this._children[e]=t},bo.prototype.removeChild=function(e){delete this._children[e]},bo.prototype.getChild=function(e){return this._children[e]},bo.prototype.hasChild=function(e){return e in this._children},bo.prototype.update=function(e){this._rawModule.namespaced=e.namespaced,e.actions&&(this._rawModule.actions=e.actions),e.mutations&&(this._rawModule.mutations=e.mutations),e.getters&&(this._rawModule.getters=e.getters)},bo.prototype.forEachChild=function(e){Rr(this._children,e)},bo.prototype.forEachGetter=function(e){this._rawModule.getters&&Rr(this._rawModule.getters,e)},bo.prototype.forEachAction=function(e){this._rawModule.actions&&Rr(this._rawModule.actions,e)},bo.prototype.forEachMutation=function(e){this._rawModule.mutations&&Rr(this._rawModule.mutations,e)},Object.defineProperties(bo.prototype,So);var To=function(e){this.register([],e,!1)};function yo(e,t,n){if(t.update(n),n.modules)for(var r in n.modules){if(!t.getChild(r))return void 0;yo(e.concat(r),t.getChild(r),n.modules[r])}}To.prototype.get=function(e){return e.reduce((function(e,t){return e.getChild(t)}),this.root)},To.prototype.getNamespace=function(e){var t=this.root;return e.reduce((function(e,n){return t=t.getChild(n),e+(t.namespaced?n+"/":"")}),"")},To.prototype.update=function(e){yo([],this.root,e)},To.prototype.register=function(e,t,n){var r=this;void 0===n&&(n=!0);var o=new bo(t,n);if(0===e.length)this.root=o;else{var i=this.get(e.slice(0,-1));i.addChild(e[e.length-1],o)}t.modules&&Rr(t.modules,(function(t,o){r.register(e.concat(o),t,n)}))},To.prototype.unregister=function(e){var t=this.get(e.slice(0,-1)),n=e[e.length-1],r=t.getChild(n);r&&r.runtime&&t.removeChild(n)},To.prototype.isRegistered=function(e){var t=this.get(e.slice(0,-1)),n=e[e.length-1];return!!t&&t.hasChild(n)};var Mo=function(e){var t=this;void 0===e&&(e={});var n=e.plugins;void 0===n&&(n=[]);var r=e.strict;void 0===r&&(r=!1);var o=e.devtools;this._committing=!1,this._actions=Object.create(null),this._actionSubscribers=[],this._mutations=Object.create(null),this._wrappedGetters=Object.create(null),this._modules=new To(e),this._modulesNamespaceMap=Object.create(null),this._subscribers=[],this._makeLocalGettersCache=Object.create(null),this._scope=null,this._devtools=o;var i=this,a=this,s=a.dispatch,c=a.commit;this.dispatch=function(e,t){return s.call(i,e,t)},this.commit=function(e,t,n){return c.call(i,e,t,n)},this.strict=r;var u=this._modules.root.state;Wr(this,u,[],this._modules.root),Qr(this,u),n.forEach((function(e){return e(t)}))},wo={state:{configurable:!0}};Mo.prototype.install=function(e,t){e.provide(t||Vr,this),e.config.globalProperties.$store=this;var n=void 0!==this._devtools&&this._devtools;n&&ao(e,this)},wo.state.get=function(){return this._state.data},wo.state.set=function(e){0},Mo.prototype.commit=function(e,t,n){var r=this,o=eo(e,t,n),i=o.type,a=o.payload,s=(o.options,{type:i,payload:a}),c=this._mutations[i];c&&(this._withCommit((function(){c.forEach((function(e){e(a)}))})),this._subscribers.slice().forEach((function(e){return e(s,r.state)})))},Mo.prototype.dispatch=function(e,t){var n=this,r=eo(e,t),o=r.type,i=r.payload,a={type:o,payload:i},s=this._actions[o];if(s){try{this._actionSubscribers.slice().filter((function(e){return e.before})).forEach((function(e){return e.before(a,n.state)}))}catch(u){0}var c=s.length>1?Promise.all(s.map((function(e){return e(i)}))):s[0](i);return new Promise((function(e,t){c.then((function(t){try{n._actionSubscribers.filter((function(e){return e.after})).forEach((function(e){return e.after(a,n.state)}))}catch(u){0}e(t)}),(function(e){try{n._actionSubscribers.filter((function(e){return e.error})).forEach((function(t){return t.error(a,n.state,e)}))}catch(u){0}t(e)}))}))}},Mo.prototype.subscribe=function(e,t){return qr(e,this._subscribers,t)},Mo.prototype.subscribeAction=function(e,t){var n="function"===typeof e?{before:e}:e;return qr(n,this._actionSubscribers,t)},Mo.prototype.watch=function(e,t,n){var r=this;return(0,i.watch)((function(){return e(r.state,r.getters)}),t,Object.assign({},n))},Mo.prototype.replaceState=function(e){var t=this;this._withCommit((function(){t._state.data=e}))},Mo.prototype.registerModule=function(e,t,n){void 0===n&&(n={}),"string"===typeof e&&(e=[e]),this._modules.register(e,t),Wr(this,this.state,e,this._modules.get(e),n.preserveState),Qr(this,this.state)},Mo.prototype.unregisterModule=function(e){var t=this;"string"===typeof e&&(e=[e]),this._modules.unregister(e),this._withCommit((function(){var n=$r(t.state,e.slice(0,-1));delete n[e[e.length-1]]})),Ur(this)},Mo.prototype.hasModule=function(e){return"string"===typeof e&&(e=[e]),this._modules.isRegistered(e)},Mo.prototype.hotUpdate=function(e){this._modules.update(e),Ur(this,!0)},Mo.prototype._withCommit=function(e){var t=this._committing;this._committing=!0,e(),this._committing=t},Object.defineProperties(Mo.prototype,wo);var Co=xo((function(e,t){var n={};return Po(t).forEach((function(t){var r=t.key,o=t.val;n[r]=function(){var t=this.$store.state,n=this.$store.getters;if(e){var r=Io(this.$store,"mapState",e);if(!r)return;t=r.context.state,n=r.context.getters}return"function"===typeof o?o.call(this,t,n):t[o]},n[r].vuex=!0})),n})),Bo=(xo((function(e,t){var n={};return Po(t).forEach((function(t){var r=t.key,o=t.val;n[r]=function(){var t=[],n=arguments.length;while(n--)t[n]=arguments[n];var r=this.$store.commit;if(e){var i=Io(this.$store,"mapMutations",e);if(!i)return;r=i.context.commit}return"function"===typeof o?o.apply(this,[r].concat(t)):r.apply(this.$store,[o].concat(t))}})),n})),xo((function(e,t){var n={};return Po(t).forEach((function(t){var r=t.key,o=t.val;o=e+o,n[r]=function(){if(!e||Io(this.$store,"mapGetters",e))return this.$store.getters[o]},n[r].vuex=!0})),n})),xo((function(e,t){var n={};return Po(t).forEach((function(t){var r=t.key,o=t.val;n[r]=function(){var t=[],n=arguments.length;while(n--)t[n]=arguments[n];var r=this.$store.dispatch;if(e){var i=Io(this.$store,"mapActions",e);if(!i)return;r=i.context.dispatch}return"function"===typeof o?o.apply(this,[r].concat(t)):r.apply(this.$store,[o].concat(t))}})),n})));function Po(e){return Eo(e)?Array.isArray(e)?e.map((function(e){return{key:e,val:e}})):Object.keys(e).map((function(t){return{key:t,val:e[t]}})):[]}function Eo(e){return Array.isArray(e)||_r(e)}function xo(e){return function(t,n){return"string"!==typeof t?(n=t,t=""):"/"!==t.charAt(t.length-1)&&(t+="/"),e(t,n)}}function Io(e,t,n){var r=e._modulesNamespaceMap[n];return r}var Go={name:"Question_Programming",props:{isEnterCodeByInit:{type:Boolean,default:!1},urlQuery:{type:String,default:""},isSub:{type:Boolean,default:!1},questionInfo:{type:Object,default:{}},bus:{type:Object,default:{}},mode:{type:String,default:"exam"},showScore:{type:Boolean,default:!1}},mounted:function(){var e=this;X(this),this.$watch("oss_temp_url",(function(t){if(t){var n=e.isAnswered();e.$emit("getIsAnswered",n),"exam"===e.mode&&e.bus.$emit("questionCardChange",{questionIndex:e.questionInfo.questionIndex-1,answered:n})}}),{immediate:!0})},created:function(){this.isEnterCodeByInit&&(this.oss_temp_url?this.startCode("2"):this.startCode("1"))},data:function(){return Q({iframe:null,showFrame:!1,analyCorrectAnswer:"",iframeUrl:"",code_file_oss_temp_path:"",oss_temp_url:"",scratch_answer_json:"",loading:!1,enterCode:!1,codeTypeMap:{1:"Scratch",2:"Python",3:"PyGame",4:"C++"},codeTypeImgMap:{1:r(3031),2:r(3843),3:r(6543),4:r(2657)},answerMap:{}},JSON.parse(W))},watch:{questionInfo:{handler:function(e,t){if(e){this.answerMap=e.answerMap;var n=e.answerMap;n&&(this.code_file_oss_temp_path=n.code_file_oss_temp_path,this.oss_temp_url=n.oss_temp_url)}},immediate:!0}},computed:Q({},Co("zykjcommonQuestions",["pythonCodeWebPath","scratchCodeWebPath","cplusCodeWebPath"])),methods:Q(Q({},Bo("zykjcommonQuestions",["getEditorUrlActions"])),{},{getAnswer:function(){return{code_file_oss_temp_path:this.code_file_oss_temp_path,oss_temp_url:this.oss_temp_url,scratch_answer_json:this.scratch_answer_json}},isAnswered:function(){var e=""!==this.oss_temp_url;return e},isCorrect:function(){var e="1"===this.questionInfo.answerMap.is_correct;return e},getCodeWebPath:function(e){var t=this;this.pythonCodeWebPath||this.scratchCodeWebPath||this.cplusCodeWebPath?e&&e():(this.loading=!0,this.getEditorUrlActions().then((function(){t.loading=!1,e&&e()}),(function(){t.loading=!1})))},startCode:function(e){var t=this;this.loading||(this.getCodeWebPath((function(){var n={1:t.questionInfo.template_file_full_url,2:t.oss_temp_url,3:t.oss_temp_url,4:t.questionInfo.reference_file_full_url},r="",o=t.questionInfo.code_type,i=n[e],a=t.urlQuery+"&codeUrl=".concat(i);switch(o){case 1:r="".concat(t.scratchCodeWebPath,"/?").concat(a);break;case 2:r="".concat(t.pythonCodeWebPath,"/?").concat(a);break;case 3:r="".concat(t.pythonCodeWebPath,"/?").concat(a,"&pygame=true");break;case 4:r="".concat(t.cplusCodeWebPath,"/?").concat(a);break}t.iframeUrl=r})),this.showFrame=!0)},getQuestionInfo:function(){var e=this,t={type:"getQuestionInfo",data:e.questionInfo.htmlContent};this.iframe&&this.iframe.contentWindow.postMessage(JSON.stringify(t),"*")},submitCodeQuestionByTimeover:function(){var e={type:"submitCodeQuestionByTimeover"};this.iframe&&this.iframe.contentWindow.postMessage(JSON.stringify(e),"*")},iframeLoaded:function(e){this.iframe=e,this.enterCode=!0,this.bus.$emit("enterCode",!0)},closeIframe:function(){this.enterCode=!1,this.bus.$emit("enterCode",!1),this.showFrame=!1},closeAndSave:function(e){this.saveCodeOnly(e),this.isEnterCodeByInit||this.closeIframe(),this.$emit("closeAndSave",e)},saveCodeOnly:function(e){var t=this;this.code_file_oss_temp_path=e.codeFileOssTempPath,this.oss_temp_url=e.ossTempUrl,this.scratch_answer_json=e.scratch_answer_json,this.bus.$emit("submitQuestion",{saveType:1,submitRequestAutoQuit:!1,needSubmitRequest:!1});var n=this.isAnswered();"exam"===this.mode&&this.bus.$emit("questionCardChange",{questionIndex:t.questionInfo.questionIndex-1,answered:n}),this.$emit("saveCodeOnly",e)},uploadCodingFileSuccess:function(e){this.code_file_oss_temp_path=e.codeFileOssTempPath,this.oss_temp_url=e.ossTempUrl,this.scratch_answer_json=e.scratch_answer_json,this.bus.$emit("uploadCodingFileSuccess")}}),components:{IframeComponent:Br,MediaLooker:Je,Loading:Mr}};const ko=(0,ze.Z)(Go,[["render",hr]]);var Do=ko,Ho={class:"zykjcommon-question",style:{width:"100%",height:"100%"}},Oo={class:"box"},No={class:"main-block"},Lo=["src"],Vo=(0,i.createElementVNode)("div",{class:"main-content"},[(0,i.createElementVNode)("div",{class:"main-append"})],-1),Ro=(0,i.createElementVNode)("div",{class:"prev"},[(0,i.createElementVNode)("div",{class:"prev-main"})],-1),_o=(0,i.createElementVNode)("div",{class:"next"},[(0,i.createElementVNode)("div",{class:"next-main"})],-1),jo={class:"list"},Fo=["idx"],qo={class:"list-item-text"};function Uo(e,t,n,r,o,a){return(0,i.openBlock)(),(0,i.createElementBlock)("div",Ho,[(0,i.createElementVNode)("div",{class:"question-classify",style:(0,i.normalizeStyle)(o.bigBgCss)},[(0,i.createElementVNode)("div",Oo,[((0,i.openBlock)(!0),(0,i.createElementBlock)(i.Fragment,null,(0,i.renderList)(o.bigBoxItemList,(function(e,t){return(0,i.openBlock)(),(0,i.createElementBlock)("div",{class:"box-item",style:(0,i.normalizeStyle)(e.bgUrlCss),key:t},[(0,i.createElementVNode)("div",No,[(0,i.createElementVNode)("img",{src:e.imgUrl,alt:""},null,8,Lo)]),Vo],4)})),128))]),(0,i.createElementVNode)("div",{class:"list-outter",style:(0,i.normalizeStyle)(o.bottomBgCss)},[Ro,_o,(0,i.createElementVNode)("div",jo,[((0,i.openBlock)(!0),(0,i.createElementBlock)(i.Fragment,null,(0,i.renderList)(o.optionList,(function(e,t){return(0,i.openBlock)(),(0,i.createElementBlock)("div",{class:"list-item",idx:e.idx,style:(0,i.normalizeStyle)(e.bgUrlCss),key:t},[(0,i.createElementVNode)("div",qo,(0,i.toDisplayString)(e.content),1)],12,Fo)})),128))])],4)],4)])}r(2707),r(4553),r(561);var Qo=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:1440,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,r=arguments.length>3?arguments[3]:void 0,o=100,i=document.documentElement.clientWidth||document.body.clientWidth,a=document.documentElement.clientHeight||document.body.clientHeight;a-=t;var s=4.3/3,c=s/(i/a),u=parseInt(i*c);r.style.fontSize=u/e*o*n+"px"},Wo=Xe.getDeviceEnv(),Xo={name:"Question_Classify",props:{questionInfo:{type:Object,default:{}},bus:{type:Object,default:function(){return{}}},mode:{type:String,default:"exam"},screenRepairH:{type:Number,default:0},screenScale:{type:Number,default:1}},created:function(){},unmounted:function(){this.unmountedDo()},destroyed:function(){this.unmountedDo()},mounted:function(){var e=this;this.setRootFontSize(),window.addEventListener("resize",this.setRootFontSize),this.init(),this.$watch("optionList",(function(t){t&&t.length&&e.$nextTick((function(){e.dothings()}))}),{immediate:!0,deep:!0})},data:function(){return{animationing:!1,analyCorrectAnswer:"",classify_question_info:{},answerMap:{},optionList:[],bigBoxItemList:[],bigBgCss:"",bottomBgCss:"",listItemBgCss:"",env:Wo,p1:{},p2:{},listItem:null,moveDiv:null,timer:null,mousedown:"mobile"===Wo?"touchstart":"mousedown",mousemove:"mobile"===Wo?"touchmove":"mousemove",mouseup:"mobile"===Wo?"touchend":"mouseup",dragWay:"",flag:!1,scrollDistance:3e3}},watch:{questionInfo:{handler:function(e,t){e&&(console.log(e,33),this.parseLists(e),this.answerMap=e.answerMap,e.answerMap&&this.mode)},immediate:!0}},computed:{},methods:{getAnswer:function(){var e=[];return $(this.$el).find(".box-item").each((function(t,n){var r=$(this),o=[];r.find(".append-item").each((function(e,t){o.push(Number($(t).attr("idx")))})),o=o.sort((function(e,t){return e-t})),console.log(o,345),e.push({big_type_index:t+1,small_type_index_list:o})})),{classify_mapping_list:e}},isAnswered:function(){var e=$(this.$el).find(".list .list-item").length,t=0===e;return t},isCorrect:function(){var e="1"===this.questionInfo.answerMap.is_correct;return e},parseLists:function(e){this.classify_question_info=e.classify_question_info;var t=e.exam_options_data;if(this.classify_question_info){this.classify_question_info.background_file&&(this.bigBgCss="background: url(".concat(this.classify_question_info.background_file.file_url,") no-repeat center;background-size: 100% 100%")),this.classify_question_info.bottom_img_file&&(this.bottomBgCss="background: url(".concat(this.classify_question_info.bottom_img_file.file_url,") no-repeat center;background-size: 100% 100%"));var n=[];t.forEach((function(e){n.push({content:e.data.option_content,bgUrlCss:"background: url(".concat(e.data.file_url,") no-repeat center;background-size: 100% 100%"),idx:e.index})})),this.optionList=n,this.listItemBgCss=n[0]?n[0].bgUrlCss:"";var r=[],o=this.classify_question_info.big_type_box_image_list,i=this.classify_question_info.big_type_option_list;o.forEach((function(e,t){r.push({imgUrl:i[t].file_url,bgUrl:e.file_url,bgUrlCss:"background: url(".concat(e.file_url,") no-repeat center;background-size: 100% 100%")})})),this.bigBoxItemList=r}},setRootFontSize:function(){Qo(1e3,this.screenRepairH,this.screenScale,this.$el)},unmountedDo:function(){window.removeEventListener("resize",this.setRootFontSize),document.removeEventListener("gesturestart",this.gesturestartListener),$(this.$el).find(".question-classify .append-item").off(this.mousedown),$(this.$el).find(".question-classify .list-item").off(this.mousedown),$(document).off(this.mouseup);var e=document.getElementsByTagName("html")[0];e.style.fontSize=""},answeredNotify:function(){var e=this,t=e.isAnswered();e.$emit("getIsAnswered",t),"exam"===e.mode&&e.bus.$emit("questionCardChange",{questionIndex:e.questionInfo.questionIndex-1,answered:t})},gesturestartListener:function(e){e.preventDefault()},init:function(){"mobile"===Wo&&document.addEventListener("gesturestart",this.gesturestartListener)},getSpecArr:function(){var e=this,t=[],n=e.moveDiv.offset().left,r=n+e.moveDiv.width(),o=e.moveDiv.offset().top,i=o+e.moveDiv.height();return $(this.$el).find(".box-item").each((function(e,a){var s=$(a),c=s.offset().left,u=c+s.width(),l=s.offset().top,f=l+s.height();n>c&&r<u&&o>l&&i<f&&t.push({dom:s})})),t},bindDragDomEvent:function(e,t){var n=this;e.on(this.mousedown,(function(e){if(!n.moveDiv){n.flag=!1,n.dragWay=t,console.log(e),e.stopPropagation(),e.preventDefault(),n.listItem=$(this),n.listItem.addClass("drag"),n.p1.moveX=n.listItem.offset().left,n.p1.moveY=n.listItem.offset().top-30;var r=n.listItem.attr("idx");n.moveDiv=$('<div class="question-classify-moveDiv" idx="'.concat(r,'" style="').concat(n.listItemBgCss,'"><div class="list-item-text">').concat(n.listItem.find(".list-item-text").text(),"</div></div>")),n.moveDiv.css({left:"".concat(n.p1.moveX,"px"),top:"".concat(n.p1.moveY,"px")}),$(n.$el).append(n.moveDiv),$(document).on(n.mousemove,(function(e){e.stopPropagation(),n.p2.moveX=e.clientX||e.originalEvent.touches&&e.originalEvent.touches[0].clientX,n.p2.moveY=e.clientY||e.originalEvent.touches&&e.originalEvent.touches[0].clientY;var t=n.p2.moveX-n.moveDiv.width()/2,r=n.p2.moveY-n.moveDiv.height()/2;n.moveDiv.css({left:t+"px",top:r+"px"})}))}}))},appendMoveDiv:function(e){var t=this;t.listItem.remove();var n=t.moveDiv.attr("idx"),r=$('<div class="'.concat(e.appendItemClassName,'" idx="').concat(n,'" style="').concat(t.listItemBgCss,'"><div class="list-item-text">').concat(t.moveDiv.find(".list-item-text").text(),"</div></div>"));r.css({opacity:0}),e.targetList.append(r),e.targetList[e.scrollDirection](t.scrollDistance);var o=r.offset().left,i=r.offset().top;t.animationing=!0,t.moveDiv.css({transition:"all 0.5s",left:o,top:i}).on("transitionend",(function(){t.flag||(t.moveDiv.remove(),t.moveDiv.off("transitionend"),t.moveDiv=null,r.css({opacity:1}),t.answeredNotify(),t.bindDragDomEvent(r,e.op),t.animationing=!1),t.flag=!0}))},bindNextPrevEvent:function(e){var t=this;$(this.$el).find(".question-classify .".concat(e)).on("click",(function(n){n.stopPropagation(),n.preventDefault();var r=$(t.$el).find(".question-classify .list-item"),o=$(t.$el).find(".question-classify .list"),i=r.outerWidth()*("next"===e?1:-1),a=o.scrollLeft();console.log(a),$(t.$el).find(".question-classify .list").stop(!0).animate({scrollLeft:a+i},500)}))},dothings:function(){var e=this;this.answerMap&&this.answerMap.classify_mapping_list&&this.answerMap.classify_mapping_list.length&&this.setAnswerDo(),e.bindDragDomEvent($(this.$el).find(".question-classify .list-item"),"go"),$(document).on(e.mouseup,(function(t){if(!e.animationing)if("go"===e.dragWay){if($(document).off(e.mousemove),e.listItem&&e.listItem.removeClass("drag"),e.moveDiv){var n=e.getSpecArr();if(0===n.length)e.moveDiv&&(e.moveDiv.remove(),e.moveDiv=null);else{var r=n[0].dom;e.appendMoveDiv({targetList:r.find(".main-append"),appendItemClassName:"append-item",op:"back",scrollDirection:"scrollTop"})}}}else if("back"===e.dragWay&&($(document).off(e.mousemove),e.listItem&&e.listItem.removeClass("drag"),e.moveDiv)){var o=e.getSpecArr();if(0===o.length)e.appendMoveDiv({targetList:$(e.$el).find(".question-classify .list"),appendItemClassName:"list-item",op:"go",scrollDirection:"scrollLeft"});else{var i=o[0].dom,a=e.listItem.parents(".question-classify .box-item");i.get(0)===a.get(0)?(console.log("自己"),e.moveDiv.remove(),e.moveDiv=null,e.listItem&&e.listItem.removeClass("drag")):(console.log("不是自己"),e.appendMoveDiv({targetList:i.find(".main-append"),appendItemClassName:"append-item",op:"back",scrollDirection:"scrollTop"}),console.log("不是自己"))}console.log(o.length)}})),e.bindNextPrevEvent("next"),e.bindNextPrevEvent("prev")},setAnswerDo:function(){var e=this,t=this,n=[];$(this.$el).find(".question-classify .list-item").each((function(e,t){n.push(Number($(t).attr("idx")))})),this.answerMap.classify_mapping_list.forEach((function(r,o){r.small_type_index_list.forEach((function(r){var i=n.findIndex((function(e){return e==r}));if(i>-1){n.splice(i,1);var a=$(e.$el).find(".question-classify .list-item").eq(i),s=a.attr("idx"),c=$('<div class="append-item" idx="'.concat(s,'" style="').concat(t.listItemBgCss,'"><div class="list-item-text">').concat(a.find(".list-item-text").text(),"</div></div>"));t.bindDragDomEvent(c,"back"),$(e.$el).find(".main-append").eq(o).append(c),a.remove()}}))})),this.answeredNotify()}},components:{}};const Ko=(0,ze.Z)(Xo,[["render",Uo]]);var zo=Ko,Yo={1:"Question_SingleChoice",2:"Question_MultipleChoice",3:"Question_SingleChoice",7:"Question_BriefAnswer",16:"Question_Programming",11:"Question_Reading",4:"Question_FillBlank",17:"Question_Classify"},Jo=(r(8674),r(1354)),Zo=r(9669),$o=r.n(Zo),ei=r(7631),ti=r.n(ei),ni="piw38kulfozrea7ydmjnvbc965q1gt2x",ri=function(e,t,n,r){void 0!=n&&"undefined"!==typeof n["password"]&&(n["password"]=ti().hex_md5(ti().hex_md5(n["password"]+"FE605C9343A3A47764598FDC184EC66F").toUpperCase()+"FE605C9343A3A47764598FDC184EC66F").toUpperCase());var o=e+"\n/student-web"+t+"\n"+r+"\n"+(n?JSON.stringify(n):""),i=Jo.enc.Base64.stringify((0,Jo.HmacSHA256)(o,ni)),a=function(e){var t=e.replace(/\+/g,"-");t=t.replace(/\//g,"_");var n=t.length%4,r="====";return t+=r.substring(0,n),t};return a(i)};$o().defaults.baseURL="https://jsl-api.thedeer.cn/student-web/",$o().defaults.timeout=6e4,$o().defaults.withCredentials=!0;var oi=function(e,t){if(t&&-1!=t["Content-Type"].indexOf("multipart/form-data")){var n=new FormData;for(var r in e)n.append(r,e[r]);return n}return JSON.stringify(e)},ii=function(e){e=JSON.parse(e),e.hasOwnProperty("errorCode")&&(e.error_code=e.errorCode);var t=e,n=t.error_code,r=t.message;if(n){var o=[39002,39003];if(o.indexOf(n)<=-1){var i=r||"系统异常";Xe.messageTip("warning",i)}}return e};function ai(e,t,n,r,o){var i=void 0,a=void 0;e=e.toUpperCase(),t+=0===n.indexOf("/")?n.substr(1):n;var s=window.isMock;"undefined"!==typeof o&&"undefined"!==typeof o.isMock&&(s=o.isMock,delete o.isMock),s&&o&&o.onUploadProgress&&delete o.onUploadProgress;var c=n;"/"!==n[0]&&(c="/"+n);var u=(new Date).getTime(),l={ts:u,sign:ri(e,c,r,u),token:Xe.getToken()};switch(e){case"Get":a=r||{};break;default:case"POST":i=r||{},l["Content-Type"]=o&&o.contentType?o.contentType:"application/json";break}return t instanceof Array?$o().all([]).then($o().spread((function(){}))):$o()(Object.assign({headers:l,method:e,url:t,data:i,params:a,transformRequest:oi,transformResponse:ii},o)).then((function(e){return e.data})).catch((function(e){return console.log("服务端请求/响应错误:",e,e.config),Promise.reject(e)}))}var si=function(e,t,n){return ai("GET","",e,t,n)},ci={editorUrl:"/open/editor-url"},ui={pythonCodeWebPath:"",scratchCodeWebPath:"",cplusCodeWebPath:""},li={namespaced:!0,state:ui,getters:{},mutations:{setCodeWebPath:function(e,t){e.pythonCodeWebPath=t.pythonCodeWebPath,e.scratchCodeWebPath=t.scratchCodeWebPath,e.cplusCodeWebPath=t.cplusCodeWebPath}},actions:{getEditorUrlActions:function(e){var t=e.commit;e.dispatch;return new Promise((function(e,n){si("".concat(ci.editorUrl)).then((function(n){var r=n.error_code,o=n.data;if(!r){var i=o.pythonCodeWebPath,a=o.scratchCodeWebPath,s=o.cplusCodeWebPath;t("setCodeWebPath",{pythonCodeWebPath:i,scratchCodeWebPath:a,cplusCodeWebPath:s})}e(n)}),(function(e){n(e)}))}))}}},fi=function(e,t,n){var r=this,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:void 0;function i(e,t){e.forEach((function(e){if("img"===e["<>"]&&e.hasOwnProperty("width")){var n=Number(e.width);n>t&&(e.width=Math.floor(t),e.height&&delete e.height)}e.html&&e.html.length&&i(e.html,t)}))}t.forEach((function(t,a){if(t.questionComponent=Yo[t.question_type],void 0===o?t.questionIndex=a+1:(t.questionIndex=o+1+"-"+(a+1),t.questionIndex2=a+1),n&&n.hasOwnProperty(t.question_id)){if(t.answerMap=n[t.question_id],"analysis"===e){t.answerMap.user_coding_file&&(t.answerMap.oss_temp_url=t.answerMap.user_coding_file),t.score=t.answerMap.question_max_score;var s=Object.keys(t.answerMap),c=/^user_/gi;s.forEach((function(e){if(c.test(e)){var n=e.replace(c,"");t.answerMap[n]=t.answerMap[e]}}))}}else t.answerMap=null;var u=t.question_type;3==u?t.exam_options_data=[{index:1,data:{name:"正确"}},{index:2,data:{name:"错误"}}]:t.exam_options_data&&t.exam_options_data.length&&t.exam_options_data.forEach((function(e,t){e.enIndex=Xe.indexToEnIndex(t+1)}));try{var l=JSON.parse(t.content),f=jQuery(".question-list").width()-30;i(l,f),t.htmlContent=$.json2html({},l)}catch(d){t.htmlContent=t.content}try{t.analysis?t.analysisHtmlContent=$.json2html({},JSON.parse(t.analysis)):t.analysisHtmlContent=""}catch(d){t.analysisHtmlContent=t.analysis}t.sub_questions&&t.sub_questions.length&&r.parseQuestionListItem(e,t.sub_questions,n,a)}))};function di(e){return e.registerModule("zykjcommonQuestions",li),{install:function(e){Xe.getVueVersion();e.mixin({methods:{parseQuestionListItem:fi}}),e.component("Question_SingleChoice",et),e.component("Question_MultipleChoice",Nt),e.component("Question_Reading",Jt),e.component("Question_BriefAnswer",xn),e.component("Question_FillBlank",jn),e.component("Question_Programming",Do),e.component("Question_Classify",zo)},parseQuestionListItem:fi,questionMapper:Yo,Question_SingleChoice:et,Question_MultipleChoice:Nt,Question_Reading:Jt,Question_BriefAnswer:xn,Question_FillBlank:jn,Question_Programming:Do,Question_Classify:zo}}var hi=di}(),o}()}));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zykjcommon/questions",
3
- "version": "0.0.35",
3
+ "version": "0.0.37",
4
4
  "main": "src/components/questions/entry.js",
5
5
  "scripts": {
6
6
  "serve": "vue-cli-service serve",
@@ -169,22 +169,6 @@ export default {
169
169
  let correct = this.questionInfo.answerMap.is_correct === '1' ? true : false
170
170
  return correct
171
171
  },
172
- intervalFindEl(){
173
- return new Promise((resolve,reject)=>{
174
- console.log(this.$el,345);
175
- debugger
176
- if(this.$el){
177
- resolve()
178
- }else{
179
- let interval = setInterval(()=>{
180
- if(this.$el){
181
- clearInterval(interval)
182
- resolve()
183
- }
184
- },50)
185
- }
186
- })
187
- },
188
172
  parseLists(nv){
189
173
  this.classify_question_info = nv.classify_question_info
190
174
  let exam_options_data = nv.exam_options_data