@instructure/quiz-core 22.3.2-rc.1 → 22.3.2-rc.3
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.
- package/es/building/api/quizzes.js +6 -1
- package/es/common/actions/modifications.js +11 -0
- package/es/common/records/Quiz.js +1 -0
- package/es/index.js +1 -1
- package/lib/building/api/quizzes.js +6 -0
- package/lib/common/actions/modifications.js +12 -0
- package/lib/common/records/Quiz.js +1 -0
- package/lib/index.js +7 -0
- package/package.json +9 -9
|
@@ -3,7 +3,7 @@ import { noop } from 'lodash';
|
|
|
3
3
|
import { DO_NOTHING, NEW_QUIZ_ID, QUIZ_SAVE_CALL, PARENT_TYPE_BANK, PARENT_TYPE_QUIZ, PARENT_TYPE_QUIZ_SESSION } from '@instructure/quiz-common';
|
|
4
4
|
import Fetcher from '../../common/util/Fetcher';
|
|
5
5
|
import { getQTIInfo } from './qtiImports';
|
|
6
|
-
import { changeQuizAllowBacktracking, changeQuizAllowClearMCSelection, changeQuizChoiceElimination, changeQuizHasTimeLimit, changeQuizOneAtATimeType, changeQuizDefaultRceSettings, changeQuizShuffleQuestions, changeQuizShuffleAnswers, changeQuizRequireStudentAccessCode, changeQuizStudentAccessCode, changeSessionTimeLimitInSeconds, changeQuizFilterIpAddress, changeQuizIpFilters, changeQuizCalculatorType, changeResultsFeedback, changeResultsFeedbackEnabled } from '../../common/actions/modifications';
|
|
6
|
+
import { changeQuizAllowBacktracking, changeQuizAllowClearMCSelection, changeQuizChoiceElimination, changeQuizHasTimeLimit, changeQuizOneAtATimeType, changeQuizDefaultRceSettings, changeQuizShuffleQuestions, changeQuizShuffleAnswers, changeQuizRequireStudentAccessCode, changeQuizStudentAccessCode, changeSessionTimeLimitInSeconds, changeQuizFilterIpAddress, changeQuizIpFilters, changeQuizCalculatorType, changeResultsFeedback, changeResultsFeedbackEnabled, changeQuizDisableDocumentAccess } from '../../common/actions/modifications';
|
|
7
7
|
import { handleQuizResponse } from '../../common/api/callHandlers';
|
|
8
8
|
import { getUploadUrl, sendFileToS3 } from '../../common/api/fileUpload';
|
|
9
9
|
import { interactionTypeFetch } from '../../common/api/interactionTypes';
|
|
@@ -190,6 +190,11 @@ export function setQuizShuffleAnswers(quizId, value, completeCb) {
|
|
|
190
190
|
shuffle_answers: Boolean(value)
|
|
191
191
|
}, changeQuizShuffleAnswers(quizId, value), completeCb);
|
|
192
192
|
}
|
|
193
|
+
export function setQuizDisableDocumentAccess(quizId, value, completeCb) {
|
|
194
|
+
return setQuizProperty(quizId, {
|
|
195
|
+
disable_document_access: Boolean(value)
|
|
196
|
+
}, changeQuizDisableDocumentAccess(quizId, value), completeCb);
|
|
197
|
+
}
|
|
193
198
|
export function setRequireStudentAccessCode(quizId, value, completeCb) {
|
|
194
199
|
return setQuizProperty(quizId, {
|
|
195
200
|
require_student_access_code: Boolean(value)
|
|
@@ -99,6 +99,17 @@ export function changeQuizShuffleAnswers(quizId, value) {
|
|
|
99
99
|
}
|
|
100
100
|
};
|
|
101
101
|
}
|
|
102
|
+
export function changeQuizDisableDocumentAccess(quizId, value) {
|
|
103
|
+
return {
|
|
104
|
+
type: QUIZ_MODIFICATION,
|
|
105
|
+
payload: {
|
|
106
|
+
id: quizId,
|
|
107
|
+
modifications: {
|
|
108
|
+
disableDocumentAccess: Boolean(value)
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
};
|
|
112
|
+
}
|
|
102
113
|
export function changeQuizRequireStudentAccessCode(quizId, value) {
|
|
103
114
|
return {
|
|
104
115
|
type: QUIZ_MODIFICATION,
|
|
@@ -165,6 +165,7 @@ export var Quiz = (_dec = withStateCache(function (quiz) {
|
|
|
165
165
|
choiceElimination: false,
|
|
166
166
|
contextId: null,
|
|
167
167
|
defaultRceSettings: null,
|
|
168
|
+
disableDocumentAccess: false,
|
|
168
169
|
hasTimeLimit: false,
|
|
169
170
|
id: '0',
|
|
170
171
|
instructions: t('Add Instructions...'),
|
package/es/index.js
CHANGED
|
@@ -116,7 +116,7 @@ export { getClientIpAddress } from './common/util/getClientIpAddress';
|
|
|
116
116
|
export { createQuizEntryRegrade } from './grading/api/quizEntryRegrades';
|
|
117
117
|
export { getQuizEntry } from './building/api/quizEntries';
|
|
118
118
|
export { getItem } from './building/api/items';
|
|
119
|
-
export { interactionFileUpload, setOneAtATimeType, quizBuildingSession, saveQuizChange, setBacktracking, setCalculatorType, setAllowClearMCSelection, setChoiceElimination, setFilterIpAddress, setIpFiltersApi, setIpFiltersUi, setQuizDefaultRceSettings, setQuizShuffleAnswers, setQuizShuffleQuestions, setRequireStudentAccessCode, setStudentAccessCodeApi, setStudentAccessCodeUi, setQuizHasTimeLimit, setSessionTimeLimitInSecondsUi, setSessionTimeLimitInSecondsApi, setResultsFeedback, setResultsFeedbackEnabled } from './building/api/quizzes';
|
|
119
|
+
export { interactionFileUpload, setOneAtATimeType, quizBuildingSession, saveQuizChange, setBacktracking, setCalculatorType, setAllowClearMCSelection, setChoiceElimination, setFilterIpAddress, setIpFiltersApi, setIpFiltersUi, setQuizDefaultRceSettings, setQuizShuffleAnswers, setQuizDisableDocumentAccess, setQuizShuffleQuestions, setRequireStudentAccessCode, setStudentAccessCodeApi, setStudentAccessCodeUi, setQuizHasTimeLimit, setSessionTimeLimitInSecondsUi, setSessionTimeLimitInSecondsApi, setResultsFeedback, setResultsFeedbackEnabled } from './building/api/quizzes';
|
|
120
120
|
export { getExistingQuiz } from './common/api/quizzes';
|
|
121
121
|
export { confirmSessionStartPage, submitStudentAccessCode, nextQuestion, submitQuiz } from './taking/api/taking';
|
|
122
122
|
export { pinSessionItem } from './common/api/quizSessions';
|
|
@@ -17,6 +17,7 @@ exports.setIpFiltersApi = setIpFiltersApi;
|
|
|
17
17
|
exports.setIpFiltersUi = setIpFiltersUi;
|
|
18
18
|
exports.setOneAtATimeType = setOneAtATimeType;
|
|
19
19
|
exports.setQuizDefaultRceSettings = setQuizDefaultRceSettings;
|
|
20
|
+
exports.setQuizDisableDocumentAccess = setQuizDisableDocumentAccess;
|
|
20
21
|
exports.setQuizHasTimeLimit = setQuizHasTimeLimit;
|
|
21
22
|
exports.setQuizShuffleAnswers = setQuizShuffleAnswers;
|
|
22
23
|
exports.setQuizShuffleQuestions = setQuizShuffleQuestions;
|
|
@@ -220,6 +221,11 @@ function setQuizShuffleAnswers(quizId, value, completeCb) {
|
|
|
220
221
|
shuffle_answers: Boolean(value)
|
|
221
222
|
}, (0, _modifications.changeQuizShuffleAnswers)(quizId, value), completeCb);
|
|
222
223
|
}
|
|
224
|
+
function setQuizDisableDocumentAccess(quizId, value, completeCb) {
|
|
225
|
+
return setQuizProperty(quizId, {
|
|
226
|
+
disable_document_access: Boolean(value)
|
|
227
|
+
}, (0, _modifications.changeQuizDisableDocumentAccess)(quizId, value), completeCb);
|
|
228
|
+
}
|
|
223
229
|
function setRequireStudentAccessCode(quizId, value, completeCb) {
|
|
224
230
|
return setQuizProperty(quizId, {
|
|
225
231
|
require_student_access_code: Boolean(value)
|
|
@@ -15,6 +15,7 @@ exports.changeQuizAllowClearMCSelection = changeQuizAllowClearMCSelection;
|
|
|
15
15
|
exports.changeQuizCalculatorType = changeQuizCalculatorType;
|
|
16
16
|
exports.changeQuizChoiceElimination = changeQuizChoiceElimination;
|
|
17
17
|
exports.changeQuizDefaultRceSettings = changeQuizDefaultRceSettings;
|
|
18
|
+
exports.changeQuizDisableDocumentAccess = changeQuizDisableDocumentAccess;
|
|
18
19
|
exports.changeQuizEntryEntry = changeQuizEntryEntry;
|
|
19
20
|
exports.changeQuizEntryPoints = changeQuizEntryPoints;
|
|
20
21
|
exports.changeQuizEntryProperties = changeQuizEntryProperties;
|
|
@@ -145,6 +146,17 @@ function changeQuizShuffleAnswers(quizId, value) {
|
|
|
145
146
|
}
|
|
146
147
|
};
|
|
147
148
|
}
|
|
149
|
+
function changeQuizDisableDocumentAccess(quizId, value) {
|
|
150
|
+
return {
|
|
151
|
+
type: _quizCommon.QUIZ_MODIFICATION,
|
|
152
|
+
payload: {
|
|
153
|
+
id: quizId,
|
|
154
|
+
modifications: {
|
|
155
|
+
disableDocumentAccess: Boolean(value)
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
};
|
|
159
|
+
}
|
|
148
160
|
function changeQuizRequireStudentAccessCode(quizId, value) {
|
|
149
161
|
return {
|
|
150
162
|
type: _quizCommon.QUIZ_MODIFICATION,
|
|
@@ -172,6 +172,7 @@ var Quiz = exports.Quiz = (_dec = (0, _withStateCache["default"])(function (quiz
|
|
|
172
172
|
choiceElimination: false,
|
|
173
173
|
contextId: null,
|
|
174
174
|
defaultRceSettings: null,
|
|
175
|
+
disableDocumentAccess: false,
|
|
175
176
|
hasTimeLimit: false,
|
|
176
177
|
id: '0',
|
|
177
178
|
instructions: (0, _formatMessage["default"])('Add Instructions...'),
|
package/lib/index.js
CHANGED
|
@@ -134,6 +134,7 @@ var _exportNames = {
|
|
|
134
134
|
setIpFiltersUi: true,
|
|
135
135
|
setQuizDefaultRceSettings: true,
|
|
136
136
|
setQuizShuffleAnswers: true,
|
|
137
|
+
setQuizDisableDocumentAccess: true,
|
|
137
138
|
setQuizShuffleQuestions: true,
|
|
138
139
|
setRequireStudentAccessCode: true,
|
|
139
140
|
setStudentAccessCodeApi: true,
|
|
@@ -1324,6 +1325,12 @@ Object.defineProperty(exports, "setQuizDefaultRceSettings", {
|
|
|
1324
1325
|
return _quizzes.setQuizDefaultRceSettings;
|
|
1325
1326
|
}
|
|
1326
1327
|
});
|
|
1328
|
+
Object.defineProperty(exports, "setQuizDisableDocumentAccess", {
|
|
1329
|
+
enumerable: true,
|
|
1330
|
+
get: function get() {
|
|
1331
|
+
return _quizzes.setQuizDisableDocumentAccess;
|
|
1332
|
+
}
|
|
1333
|
+
});
|
|
1327
1334
|
Object.defineProperty(exports, "setQuizHasTimeLimit", {
|
|
1328
1335
|
enumerable: true,
|
|
1329
1336
|
get: function get() {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@instructure/quiz-core",
|
|
3
|
-
"version": "22.3.2-rc.
|
|
3
|
+
"version": "22.3.2-rc.3+0c12cc851",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "The Quiz React SDK by Instructure Inc.",
|
|
6
6
|
"author": "Instructure, Inc. Engineering and Product Design",
|
|
@@ -46,11 +46,11 @@
|
|
|
46
46
|
"@instructure/emotion": "10.14.0",
|
|
47
47
|
"@instructure/grading-utils": "^1.0.0",
|
|
48
48
|
"@instructure/outcomes-ui": "3.2.3",
|
|
49
|
-
"@instructure/quiz-common": "22.3.2-rc.
|
|
50
|
-
"@instructure/quiz-i18n": "22.3.2-rc.
|
|
51
|
-
"@instructure/quiz-interactions": "22.3.2-rc.
|
|
52
|
-
"@instructure/quiz-number-input": "22.3.2-rc.
|
|
53
|
-
"@instructure/quiz-rce": "22.3.2-rc.
|
|
49
|
+
"@instructure/quiz-common": "22.3.2-rc.3+0c12cc851",
|
|
50
|
+
"@instructure/quiz-i18n": "22.3.2-rc.3+0c12cc851",
|
|
51
|
+
"@instructure/quiz-interactions": "22.3.2-rc.3+0c12cc851",
|
|
52
|
+
"@instructure/quiz-number-input": "22.3.2-rc.3+0c12cc851",
|
|
53
|
+
"@instructure/quiz-rce": "22.3.2-rc.3+0c12cc851",
|
|
54
54
|
"@instructure/ui-a11y-content": "10.14.0",
|
|
55
55
|
"@instructure/ui-alerts": "10.14.0",
|
|
56
56
|
"@instructure/ui-avatar": "10.14.0",
|
|
@@ -109,7 +109,7 @@
|
|
|
109
109
|
"file-saver": "~2.0.5",
|
|
110
110
|
"humps": "^2.0.0",
|
|
111
111
|
"immutable": "^3.8.1",
|
|
112
|
-
"instructure-validations": "22.3.2-rc.
|
|
112
|
+
"instructure-validations": "22.3.2-rc.3+0c12cc851",
|
|
113
113
|
"ipaddr.js": "^1.5.4",
|
|
114
114
|
"isomorphic-fetch": "^2.2.0",
|
|
115
115
|
"isuuid": "^0.1.0",
|
|
@@ -158,7 +158,7 @@
|
|
|
158
158
|
"jquery": "^2.2.3",
|
|
159
159
|
"karma-junit-reporter": "^2.0.1",
|
|
160
160
|
"most-subject": "^5.3.0",
|
|
161
|
-
"quiz-presets": "22.3.2-rc.
|
|
161
|
+
"quiz-presets": "22.3.2-rc.3+0c12cc851",
|
|
162
162
|
"react": "^16.8.6",
|
|
163
163
|
"react-addons-test-utils": "^15.6.2",
|
|
164
164
|
"react-dom": "^16.8.6",
|
|
@@ -174,5 +174,5 @@
|
|
|
174
174
|
"publishConfig": {
|
|
175
175
|
"access": "public"
|
|
176
176
|
},
|
|
177
|
-
"gitHead": "
|
|
177
|
+
"gitHead": "0c12cc8514fceb177245cae1bcb9ec06c57836c4"
|
|
178
178
|
}
|