@elice/material-quiz 1.241021.0 → 1.241022.0

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.
@@ -508,7 +508,8 @@ var MaterialQuizSelectMultipleOrder = function MaterialQuizSelectMultipleOrder(_
508
508
  children: answerList.map(function (option, index$1) {
509
509
  var getRole = function getRole() {
510
510
  var _a;
511
- if (isActive || isTestLecture) {
511
+ var isHideStatus = !userId && (isActive || isTestLecture);
512
+ if (isHideStatus) {
512
513
  return 'default';
513
514
  }
514
515
  var status = (_a = index.getQuizSelectMultipleOrderOptionResultStatus(option, materialQuizResponse)) !== null && _a !== void 0 ? _a : index.getQuizResultStatus(materialQuizResponse);
@@ -125,7 +125,8 @@ var MaterialQuizGroupDesktop = function MaterialQuizGroupDesktop(_ref3) {
125
125
  disabled: !!userId,
126
126
  isGroupAnswer: isGroupAnswer,
127
127
  children: isGroupAnswer ? (_b = currentAnswerList[dropzoneIndex]) === null || _b === void 0 ? void 0 : _b.map(function (answer, index$1) {
128
- var status = isActive || isTestLecture ? undefined : index.getQuizGroupOptionResultStatus(dropzoneIndex, index$1, materialQuizResponse);
128
+ var isHideStatus = !userId && (isActive || isTestLecture);
129
+ var status = isHideStatus ? undefined : index.getQuizGroupOptionResultStatus(dropzoneIndex, index$1, materialQuizResponse);
129
130
  return jsxRuntime.jsx(MaterialQuizGroupOptionItem.default, {
130
131
  status: status,
131
132
  option: answer
@@ -104,7 +104,8 @@ var MaterialQuizGroupMobile = function MaterialQuizGroupMobile(_ref3) {
104
104
  }), jsxRuntime.jsx(StyledQuizOptionList, {
105
105
  isCurrentOptionList: isCurrentOptionList,
106
106
  children: isCurrentOptionList ? currentAnswerList[index$1].map(function (answer, answerIndex) {
107
- var status = isActive || isTestLecture ? undefined : index.getQuizGroupOptionResultStatus(index$1, answerIndex, materialQuizResponse);
107
+ var isHideStatus = !userId && (isActive || isTestLecture);
108
+ var status = isHideStatus ? undefined : index.getQuizGroupOptionResultStatus(index$1, answerIndex, materialQuizResponse);
108
109
  return jsxRuntime.jsx(MaterialQuizGroupOptionItem.default, {
109
110
  option: answer,
110
111
  status: status,
@@ -139,7 +139,9 @@ var MaterialQuizGroupOptionItem = function MaterialQuizGroupOptionItem(_ref10) {
139
139
  variant: vertical ? 'body2' : 'body1',
140
140
  textAlign: "center",
141
141
  fontWeight: "bold",
142
- color: status === 'correct' ? 'success.main' : status === 'wrong' ? 'error.main' : 'unset',
142
+ color: function color(theme) {
143
+ return status === 'correct' ? 'success.main' : status === 'wrong' ? 'error.main' : theme.palette.common.black;
144
+ },
143
145
  sx: {
144
146
  wordBreak: 'break-all'
145
147
  },
@@ -11,6 +11,6 @@ var styled__default = /*#__PURE__*/_interopDefaultCompat(styled);
11
11
 
12
12
  var StyledMarkdown = styled__default.default(markdown.Markdown).withConfig({
13
13
  componentId: "sc-l6r531-0"
14
- })(["& > .elicemd{overflow:hidden;}p{margin:0 !important;display:flex;align-items:center;}code{white-space:pre-wrap;word-break:break-all;}"]);
14
+ })(["& > .elicemd{overflow:hidden;}p{margin:0 !important;img{vertical-align:middle;}}code{white-space:pre-wrap;word-break:break-all;}"]);
15
15
 
16
16
  exports.default = StyledMarkdown;
@@ -499,7 +499,8 @@ var MaterialQuizSelectMultipleOrder = function MaterialQuizSelectMultipleOrder(_
499
499
  children: answerList.map(function (option, index) {
500
500
  var getRole = function getRole() {
501
501
  var _a;
502
- if (isActive || isTestLecture) {
502
+ var isHideStatus = !userId && (isActive || isTestLecture);
503
+ if (isHideStatus) {
503
504
  return 'default';
504
505
  }
505
506
  var status = (_a = getQuizSelectMultipleOrderOptionResultStatus(option, materialQuizResponse)) !== null && _a !== void 0 ? _a : getQuizResultStatus(materialQuizResponse);
@@ -116,7 +116,8 @@ var MaterialQuizGroupDesktop = function MaterialQuizGroupDesktop(_ref3) {
116
116
  disabled: !!userId,
117
117
  isGroupAnswer: isGroupAnswer,
118
118
  children: isGroupAnswer ? (_b = currentAnswerList[dropzoneIndex]) === null || _b === void 0 ? void 0 : _b.map(function (answer, index) {
119
- var status = isActive || isTestLecture ? undefined : getQuizGroupOptionResultStatus(dropzoneIndex, index, materialQuizResponse);
119
+ var isHideStatus = !userId && (isActive || isTestLecture);
120
+ var status = isHideStatus ? undefined : getQuizGroupOptionResultStatus(dropzoneIndex, index, materialQuizResponse);
120
121
  return jsx(MaterialQuizGroupOptionItem, {
121
122
  status: status,
122
123
  option: answer
@@ -95,7 +95,8 @@ var MaterialQuizGroupMobile = function MaterialQuizGroupMobile(_ref3) {
95
95
  }), jsx(StyledQuizOptionList, {
96
96
  isCurrentOptionList: isCurrentOptionList,
97
97
  children: isCurrentOptionList ? currentAnswerList[index].map(function (answer, answerIndex) {
98
- var status = isActive || isTestLecture ? undefined : getQuizGroupOptionResultStatus(index, answerIndex, materialQuizResponse);
98
+ var isHideStatus = !userId && (isActive || isTestLecture);
99
+ var status = isHideStatus ? undefined : getQuizGroupOptionResultStatus(index, answerIndex, materialQuizResponse);
99
100
  return jsx(MaterialQuizGroupOptionItem, {
100
101
  option: answer,
101
102
  status: status,
@@ -131,7 +131,9 @@ var MaterialQuizGroupOptionItem = function MaterialQuizGroupOptionItem(_ref10) {
131
131
  variant: vertical ? 'body2' : 'body1',
132
132
  textAlign: "center",
133
133
  fontWeight: "bold",
134
- color: status === 'correct' ? 'success.main' : status === 'wrong' ? 'error.main' : 'unset',
134
+ color: function color(theme) {
135
+ return status === 'correct' ? 'success.main' : status === 'wrong' ? 'error.main' : theme.palette.common.black;
136
+ },
135
137
  sx: {
136
138
  wordBreak: 'break-all'
137
139
  },
@@ -3,6 +3,6 @@ import styled from 'styled-components';
3
3
 
4
4
  var StyledMarkdown = styled(Markdown).withConfig({
5
5
  componentId: "sc-l6r531-0"
6
- })(["& > .elicemd{overflow:hidden;}p{margin:0 !important;display:flex;align-items:center;}code{white-space:pre-wrap;word-break:break-all;}"]);
6
+ })(["& > .elicemd{overflow:hidden;}p{margin:0 !important;img{vertical-align:middle;}}code{white-space:pre-wrap;word-break:break-all;}"]);
7
7
 
8
8
  export { StyledMarkdown as default };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@elice/material-quiz",
3
- "version": "1.241021.0",
3
+ "version": "1.241022.0",
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",
@@ -70,8 +70,8 @@
70
70
  "@elice/icons-legacy": "npm:@elice/icons@0.230814.0",
71
71
  "@elice/intl": "0.240710.0",
72
72
  "@elice/markdown": "1.241015.0",
73
- "@elice/material-shared-types": "1.241021.0",
74
- "@elice/material-shared-utils": "1.241021.0",
73
+ "@elice/material-shared-types": "1.241022.0",
74
+ "@elice/material-shared-utils": "1.241022.0",
75
75
  "@elice/mui-elements": "^5.240820.0",
76
76
  "@elice/mui-system": "^5.240820.0",
77
77
  "@elice/openapi-client-course": "^1.230814.0",