@elice/material-quiz 1.240715.0-touch.1 → 1.240715.0-touch.2

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.
@@ -66,6 +66,19 @@ const MaterialQuizGroupDesktop = () => {
66
66
  tolerance: 5
67
67
  }
68
68
  }));
69
+ /**
70
+ *
71
+ */
72
+ const handleDragEnd = e => {
73
+ var _a, _b, _c;
74
+ if (!e.over) {
75
+ return;
76
+ }
77
+ const targetId = Number(e.active.id);
78
+ const isOverOptionZone = ((_a = e.over) === null || _a === void 0 ? void 0 : _a.id) === 'quiz-options-dropzone';
79
+ const dropzoneIndex = Number((_c = (_b = e.over) === null || _b === void 0 ? void 0 : _b.id) === null || _c === void 0 ? void 0 : _c.split('-').pop());
80
+ isOverOptionZone ? updateCurrentOption(targetId) : updateCurrentAnswer(targetId, dropzoneIndex);
81
+ };
69
82
  /**
70
83
  *
71
84
  */
@@ -163,13 +176,7 @@ const MaterialQuizGroupDesktop = () => {
163
176
  height: "100%"
164
177
  }, React.createElement(core.DndContext, {
165
178
  sensors: sensors,
166
- onDragEnd: e => {
167
- var _a, _b, _c;
168
- const targetId = Number(e.active.id);
169
- const isOverOptionZone = ((_a = e.over) === null || _a === void 0 ? void 0 : _a.id) === 'quiz-options-dropzone';
170
- const dropzoneIndex = Number((_c = (_b = e.over) === null || _b === void 0 ? void 0 : _b.id) === null || _c === void 0 ? void 0 : _c.split('-').pop());
171
- isOverOptionZone ? updateCurrentOption(targetId) : updateCurrentAnswer(targetId, dropzoneIndex);
172
- }
179
+ onDragEnd: handleDragEnd
173
180
  }, renderQuizContentLeft(), renderQuizContentOption(), renderQuizContentRight()));
174
181
  };
175
182
 
@@ -62,6 +62,19 @@ const MaterialQuizGroupDesktop = () => {
62
62
  tolerance: 5
63
63
  }
64
64
  }));
65
+ /**
66
+ *
67
+ */
68
+ const handleDragEnd = e => {
69
+ var _a, _b, _c;
70
+ if (!e.over) {
71
+ return;
72
+ }
73
+ const targetId = Number(e.active.id);
74
+ const isOverOptionZone = ((_a = e.over) === null || _a === void 0 ? void 0 : _a.id) === 'quiz-options-dropzone';
75
+ const dropzoneIndex = Number((_c = (_b = e.over) === null || _b === void 0 ? void 0 : _b.id) === null || _c === void 0 ? void 0 : _c.split('-').pop());
76
+ isOverOptionZone ? updateCurrentOption(targetId) : updateCurrentAnswer(targetId, dropzoneIndex);
77
+ };
65
78
  /**
66
79
  *
67
80
  */
@@ -159,13 +172,7 @@ const MaterialQuizGroupDesktop = () => {
159
172
  height: "100%"
160
173
  }, React.createElement(DndContext, {
161
174
  sensors: sensors,
162
- onDragEnd: e => {
163
- var _a, _b, _c;
164
- const targetId = Number(e.active.id);
165
- const isOverOptionZone = ((_a = e.over) === null || _a === void 0 ? void 0 : _a.id) === 'quiz-options-dropzone';
166
- const dropzoneIndex = Number((_c = (_b = e.over) === null || _b === void 0 ? void 0 : _b.id) === null || _c === void 0 ? void 0 : _c.split('-').pop());
167
- isOverOptionZone ? updateCurrentOption(targetId) : updateCurrentAnswer(targetId, dropzoneIndex);
168
- }
175
+ onDragEnd: handleDragEnd
169
176
  }, renderQuizContentLeft(), renderQuizContentOption(), renderQuizContentRight()));
170
177
  };
171
178
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@elice/material-quiz",
3
- "version": "1.240715.0-touch.1",
3
+ "version": "1.240715.0-touch.2",
4
4
  "description": "User view and editing components of Elice material quiz",
5
5
  "repository": "https://git.elicer.io/elice/frontend/library/elice-material",
6
6
  "license": "UNLICENSED",
@@ -67,8 +67,8 @@
67
67
  "@elice/icons-legacy": "npm:@elice/icons@0.230814.0",
68
68
  "@elice/intl": "0.240425.0-rc.2",
69
69
  "@elice/markdown": "^1.240124.0",
70
- "@elice/material-shared-types": "1.240715.0-touch.1",
71
- "@elice/material-shared-utils": "1.240715.0-touch.1",
70
+ "@elice/material-shared-types": "1.240715.0-touch.2",
71
+ "@elice/material-shared-utils": "1.240715.0-touch.2",
72
72
  "@elice/mui-system": "^5.240108.1",
73
73
  "@elice/types": "^1.240619.0",
74
74
  "@emotion/react": "^11.10.0",
@@ -90,5 +90,5 @@
90
90
  "react-use": "^17.2.4",
91
91
  "styled-components": "^5.3.0"
92
92
  },
93
- "gitHead": "87c590dcefdcad8147a8ee638fc6aa52dc928f9b"
93
+ "gitHead": "50a22bd481d8687c939ed3180f9fa88d842c4102"
94
94
  }