@elice/material-survey 1.240718.0-trasncript.2 → 1.240718.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.
Files changed (67) hide show
  1. package/cjs/components/markdown-editor/index.d.ts +2 -1
  2. package/cjs/components/markdown-editor/index.js +10 -19
  3. package/cjs/components/material-survey/MaterialSurvey.js +57 -82
  4. package/cjs/components/material-survey/MaterialSurveyInfo.js +59 -69
  5. package/cjs/components/material-survey/MaterialSurveySelectMultiple.js +90 -131
  6. package/cjs/components/material-survey/MaterialSurveySelectOne.js +86 -125
  7. package/cjs/components/material-survey/MaterialSurveyShimmer.js +40 -47
  8. package/cjs/components/material-survey/MaterialSurveyText.js +75 -114
  9. package/cjs/components/material-survey/SurveyResultBadge.js +10 -17
  10. package/cjs/components/material-survey/SurveySubmitStatusText.js +16 -21
  11. package/cjs/components/material-survey/context/MaterialSurveyContext.d.ts +1 -1
  12. package/cjs/components/material-survey/context/MaterialSurveyContext.js +74 -115
  13. package/cjs/components/material-survey-edit/MaterialSurveyEdit.js +36 -49
  14. package/cjs/components/material-survey-edit/MaterialSurveyEditContent.js +91 -113
  15. package/cjs/components/material-survey-edit/MaterialSurveyEditOptionSelect.js +87 -100
  16. package/cjs/components/material-survey-edit/context.js +2 -8
  17. package/cjs/components/material-survey-edit/utils/editValue.js +11 -17
  18. package/cjs/components/shared/StyledMarkdown.js +1 -5
  19. package/cjs/components/shared/SurveyContentBox.js +74 -85
  20. package/cjs/components/shared/question-checkbox/QuestionCheckbox.js +7 -13
  21. package/cjs/components/shared/question-checkbox/QuestionCheckboxContext.d.ts +1 -1
  22. package/cjs/components/shared/question-checkbox/QuestionCheckboxContext.js +17 -24
  23. package/cjs/components/shared/question-checkbox/QuestionCheckboxOption.js +89 -66
  24. package/cjs/components/shared/question-radio/QuestionRadio.js +7 -13
  25. package/cjs/components/shared/question-radio/QuestionRadioContext.d.ts +1 -1
  26. package/cjs/components/shared/question-radio/QuestionRadioContext.js +17 -24
  27. package/cjs/components/shared/question-radio/QuestionRadioOption.js +80 -59
  28. package/es/components/markdown-editor/index.d.ts +2 -1
  29. package/es/components/markdown-editor/index.js +10 -15
  30. package/es/components/material-survey/MaterialSurvey.js +57 -77
  31. package/es/components/material-survey/MaterialSurveyInfo.js +59 -65
  32. package/es/components/material-survey/MaterialSurveySelectMultiple.js +90 -127
  33. package/es/components/material-survey/MaterialSurveySelectOne.js +86 -121
  34. package/es/components/material-survey/MaterialSurveyShimmer.js +40 -43
  35. package/es/components/material-survey/MaterialSurveyText.js +75 -109
  36. package/es/components/material-survey/SurveyResultBadge.js +10 -13
  37. package/es/components/material-survey/SurveySubmitStatusText.js +16 -17
  38. package/es/components/material-survey/context/MaterialSurveyContext.d.ts +1 -1
  39. package/es/components/material-survey/context/MaterialSurveyContext.js +75 -112
  40. package/es/components/material-survey-edit/MaterialSurveyEdit.js +36 -45
  41. package/es/components/material-survey-edit/MaterialSurveyEditContent.js +90 -107
  42. package/es/components/material-survey-edit/MaterialSurveyEditOptionSelect.js +87 -96
  43. package/es/components/material-survey-edit/context.js +2 -4
  44. package/es/components/material-survey-edit/utils/editValue.js +11 -17
  45. package/es/components/shared/StyledMarkdown.js +1 -1
  46. package/es/components/shared/SurveyContentBox.js +74 -81
  47. package/es/components/shared/question-checkbox/QuestionCheckbox.js +7 -9
  48. package/es/components/shared/question-checkbox/QuestionCheckboxContext.d.ts +1 -1
  49. package/es/components/shared/question-checkbox/QuestionCheckboxContext.js +17 -20
  50. package/es/components/shared/question-checkbox/QuestionCheckboxOption.js +89 -61
  51. package/es/components/shared/question-radio/QuestionRadio.js +7 -9
  52. package/es/components/shared/question-radio/QuestionRadioContext.d.ts +1 -1
  53. package/es/components/shared/question-radio/QuestionRadioContext.js +17 -20
  54. package/es/components/shared/question-radio/QuestionRadioOption.js +80 -54
  55. package/package.json +12 -9
  56. package/cjs/_virtual/_rollupPluginBabelHelpers.js +0 -399
  57. package/cjs/components/material-survey/index.js +0 -9
  58. package/cjs/components/material-survey/locales/index.js +0 -13
  59. package/cjs/components/material-survey-edit/index.js +0 -7
  60. package/cjs/components/material-survey-edit/locales/index.js +0 -13
  61. package/cjs/components/shared/index.js +0 -13
  62. package/es/_virtual/_rollupPluginBabelHelpers.js +0 -386
  63. package/es/components/material-survey/index.js +0 -2
  64. package/es/components/material-survey/locales/index.js +0 -4
  65. package/es/components/material-survey-edit/index.js +0 -1
  66. package/es/components/material-survey-edit/locales/index.js +0 -4
  67. package/es/components/shared/index.js +0 -4
@@ -1,14 +1,14 @@
1
- import { jsxs, jsx } from 'react/jsx-runtime';
2
1
  import React from 'react';
3
2
  import { base } from '@elice/design-tokens';
4
3
  import styled from 'styled-components';
5
4
  import { useQuestionRadioContext } from './QuestionRadioContext.js';
6
5
 
7
- var StyledQuestionRadioOption = styled.div.withConfig({
6
+ const StyledQuestionRadioOption = styled.div.withConfig({
8
7
  componentId: "sc-zgbv8k-0"
9
- })(["display:flex;align-items:center;padding:1.125rem;border-radius:8px;background-color:", ";&:not(:last-of-type){margin-bottom:1rem;}&:hover,& *:hover{cursor:", ";}", ""], function (_ref) {
10
- var checked = _ref.checked,
11
- status = _ref.status;
8
+ })(["display:flex;align-items:center;padding:1.125rem;border-radius:8px;background-color:", ";&:not(:last-of-type){margin-bottom:1rem;}&:hover,& *:hover{cursor:", ";}", ""], ({
9
+ checked,
10
+ status
11
+ }) => {
12
12
  if (checked) {
13
13
  return base.color.primary1;
14
14
  }
@@ -20,18 +20,17 @@ var StyledQuestionRadioOption = styled.div.withConfig({
20
20
  default:
21
21
  return base.color.navy5;
22
22
  }
23
- }, function (_ref2) {
24
- var disabled = _ref2.disabled;
25
- return disabled ? 'not-allowed' : 'pointer';
26
- }, function (_ref3) {
27
- var isAnswer = _ref3.isAnswer;
28
- return isAnswer ? "border: 3px solid ".concat(base.color.green5) : '';
29
- });
30
- var StyledQuestionRadioInput = styled.input.withConfig({
23
+ }, ({
24
+ disabled
25
+ }) => disabled ? 'not-allowed' : 'pointer', ({
26
+ isAnswer
27
+ }) => isAnswer ? `border: 3px solid ${base.color.green5}` : '');
28
+ const StyledQuestionRadioInput = styled.input.withConfig({
31
29
  componentId: "sc-zgbv8k-1"
32
- })(["flex:none;margin:0;-webkit-appearance:none;-moz-appearance:none;appearance:none;position:relative;border-radius:50%;width:1.25rem;height:1.25rem;margin-right:0.875rem;border:2px solid ", ";", ""], function (_ref4) {
33
- var checked = _ref4.checked,
34
- status = _ref4.status;
30
+ })(["flex:none;margin:0;-webkit-appearance:none;-moz-appearance:none;appearance:none;position:relative;border-radius:50%;width:1.25rem;height:1.25rem;margin-right:0.875rem;border:2px solid ", ";", ""], ({
31
+ checked,
32
+ status
33
+ }) => {
35
34
  if (checked) {
36
35
  return base.color.primary6;
37
36
  }
@@ -43,14 +42,27 @@ var StyledQuestionRadioInput = styled.input.withConfig({
43
42
  default:
44
43
  return base.color.gray3;
45
44
  }
46
- }, function (_ref5) {
47
- var status = _ref5.status,
48
- checked = _ref5.checked;
45
+ }, ({
46
+ status,
47
+ checked
48
+ }) => {
49
49
  if (checked) {
50
- return "\n &:after {\n content: '';\n position: absolute;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n width: 70%;\n height: 70%;\n border-radius: 50%;\n background-color: ".concat(base.color.primary6, ";\n }\n ");
50
+ return `
51
+ &:after {
52
+ content: '';
53
+ position: absolute;
54
+ top: 50%;
55
+ left: 50%;
56
+ transform: translate(-50%, -50%);
57
+ width: 70%;
58
+ height: 70%;
59
+ border-radius: 50%;
60
+ background-color: ${base.color.primary6};
61
+ }
62
+ `;
51
63
  }
52
64
  if (status) {
53
- var bgColor;
65
+ let bgColor;
54
66
  switch (status) {
55
67
  case 'correct':
56
68
  bgColor = base.color.green9;
@@ -62,14 +74,27 @@ var StyledQuestionRadioInput = styled.input.withConfig({
62
74
  bgColor = base.color.gray3;
63
75
  break;
64
76
  }
65
- return "\n &:after {\n content: '';\n position: absolute;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n width: 70%;\n height: 70%;\n border-radius: 50%;\n background-color: ".concat(bgColor, ";\n }\n ");
77
+ return `
78
+ &:after {
79
+ content: '';
80
+ position: absolute;
81
+ top: 50%;
82
+ left: 50%;
83
+ transform: translate(-50%, -50%);
84
+ width: 70%;
85
+ height: 70%;
86
+ border-radius: 50%;
87
+ background-color: ${bgColor};
88
+ }
89
+ `;
66
90
  }
67
91
  });
68
- var StyledLabel = styled.label.withConfig({
92
+ const StyledLabel = styled.label.withConfig({
69
93
  componentId: "sc-zgbv8k-2"
70
- })(["word-break:break-all;margin-right:0.875rem;font-size:", ";color:", ";& p{color:", ";}"], base.size.body3, function (_ref6) {
71
- var checked = _ref6.checked,
72
- status = _ref6.status;
94
+ })(["word-break:break-all;margin-right:0.875rem;font-size:", ";color:", ";& p{color:", ";}"], base.size.body3, ({
95
+ checked,
96
+ status
97
+ }) => {
73
98
  if (checked) {
74
99
  return base.color.primary6;
75
100
  }
@@ -81,9 +106,10 @@ var StyledLabel = styled.label.withConfig({
81
106
  default:
82
107
  return base.color.navy0;
83
108
  }
84
- }, function (_ref7) {
85
- var checked = _ref7.checked,
86
- status = _ref7.status;
109
+ }, ({
110
+ checked,
111
+ status
112
+ }) => {
87
113
  if (checked) {
88
114
  return base.color.primary6;
89
115
  }
@@ -96,40 +122,40 @@ var StyledLabel = styled.label.withConfig({
96
122
  return base.color.navy0;
97
123
  }
98
124
  });
99
- var QuestionRadioOption = React.memo(function (_ref8) {
100
- var value = _ref8.value,
101
- status = _ref8.status,
102
- isAnswer = _ref8.isAnswer,
103
- children = _ref8.children;
104
- var _useQuestionRadioCont = useQuestionRadioContext(),
105
- selectedValue = _useQuestionRadioCont.selectedValue,
106
- disabled = _useQuestionRadioCont.disabled,
107
- onSelect = _useQuestionRadioCont.onSelect;
108
- return jsxs(StyledQuestionRadioOption, {
125
+ const QuestionRadioOption = React.memo(({
126
+ value,
127
+ status,
128
+ isAnswer,
129
+ children
130
+ }) => {
131
+ const {
132
+ selectedValue,
133
+ disabled,
134
+ onSelect
135
+ } = useQuestionRadioContext();
136
+ return React.createElement(StyledQuestionRadioOption, {
109
137
  isAnswer: isAnswer,
110
138
  disabled: disabled,
111
139
  checked: selectedValue === value,
112
- onClick: function onClick(e) {
140
+ onClick: e => {
113
141
  e.preventDefault();
114
142
  if (disabled) {
115
143
  return;
116
144
  }
117
145
  onSelect(value);
118
146
  },
119
- status: status,
120
- children: [jsx(StyledQuestionRadioInput, {
121
- id: value,
122
- type: "radio",
123
- readOnly: true,
124
- checked: selectedValue === value,
125
- status: status
126
- }), jsx(StyledLabel, {
127
- htmlFor: value,
128
- checked: selectedValue === value,
129
- status: status,
130
- children: children
131
- })]
132
- });
147
+ status: status
148
+ }, React.createElement(StyledQuestionRadioInput, {
149
+ id: value,
150
+ type: "radio",
151
+ readOnly: true,
152
+ checked: selectedValue === value,
153
+ status: status
154
+ }), React.createElement(StyledLabel, {
155
+ htmlFor: value,
156
+ checked: selectedValue === value,
157
+ status: status
158
+ }, children));
133
159
  });
134
160
 
135
161
  export { QuestionRadioOption as default };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@elice/material-survey",
3
- "version": "1.240718.0-trasncript.2",
3
+ "version": "1.240718.2",
4
4
  "description": "User view and editing components of Elice material survey",
5
5
  "repository": "https://git.elicer.io/elice/frontend/library/elice-material",
6
6
  "license": "UNLICENSED",
@@ -17,8 +17,10 @@
17
17
  "scripts": {
18
18
  "start": "run-s watch",
19
19
  "prebuild": "run-s clean",
20
- "build": "cross-env NODE_ENV=production rollup -c ../../rollup.config.ts --configPlugin typescript -f es -f cjs",
21
- "watch": "rollup -c ../../rollup.config.ts --configPlugin typescript -f es -f cjs -w",
20
+ "build": "run-p build:es build:cjs",
21
+ "build:es": "rollup -c ../../rollup.config.ts --configPlugin typescript -f es",
22
+ "build:cjs": "rollup -c ../../rollup.config.ts --configPlugin typescript -f cjs",
23
+ "watch": "rollup -c ../../rollup.config.ts --configPlugin typescript -f es -w",
22
24
  "lint": "eslint --ext .ts,.tsx ./src --max-warnings=0",
23
25
  "clean": "del-cli \"es/*\" \"cjs/*\" \"dist/*\""
24
26
  },
@@ -45,15 +47,15 @@
45
47
  },
46
48
  "devDependencies": {
47
49
  "@elice/api-client": "^1.240619.0",
48
- "@elice/blocks": "^1.240529.0",
50
+ "@elice/blocks": "^1.240514.0",
49
51
  "@elice/design-tokens": "^1.220803.0",
50
52
  "@elice/icons": "^1.230814.0",
51
53
  "@elice/icons-legacy": "npm:@elice/icons@0.230814.0",
52
54
  "@elice/intl": "0.240425.0-rc.2",
53
- "@elice/markdown": "^1.240124.0",
54
- "@elice/material-shared-types": "1.240718.0-trasncript.2",
55
- "@elice/material-shared-utils": "1.240718.0-trasncript.2",
56
- "@elice/types": "1.240709.0",
55
+ "@elice/markdown": "^1.220815.0",
56
+ "@elice/material-shared-types": "1.240718.2",
57
+ "@elice/material-shared-utils": "1.240718.2",
58
+ "@elice/types": "^1.240619.0",
57
59
  "@elice/wysiwyg": "1.240716.1",
58
60
  "@types/classnames": "^2.3.1",
59
61
  "@types/react": "~17.0.9",
@@ -62,5 +64,6 @@
62
64
  "react": "^17.0.2",
63
65
  "react-use": "^17.2.4",
64
66
  "styled-components": "^5.3.0"
65
- }
67
+ },
68
+ "gitHead": "cd595d8015f44aa8518f22e37b7d2fb981a2b71d"
66
69
  }
@@ -1,399 +0,0 @@
1
- 'use strict';
2
-
3
- function _iterableToArrayLimit(arr, i) {
4
- var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"];
5
- if (null != _i) {
6
- var _s,
7
- _e,
8
- _x,
9
- _r,
10
- _arr = [],
11
- _n = !0,
12
- _d = !1;
13
- try {
14
- if (_x = (_i = _i.call(arr)).next, 0 === i) ; else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0);
15
- } catch (err) {
16
- _d = !0, _e = err;
17
- } finally {
18
- try {
19
- if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return;
20
- } finally {
21
- if (_d) throw _e;
22
- }
23
- }
24
- return _arr;
25
- }
26
- }
27
- function _regeneratorRuntime() {
28
- _regeneratorRuntime = function () {
29
- return exports;
30
- };
31
- var exports = {},
32
- Op = Object.prototype,
33
- hasOwn = Op.hasOwnProperty,
34
- defineProperty = Object.defineProperty || function (obj, key, desc) {
35
- obj[key] = desc.value;
36
- },
37
- $Symbol = "function" == typeof Symbol ? Symbol : {},
38
- iteratorSymbol = $Symbol.iterator || "@@iterator",
39
- asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator",
40
- toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag";
41
- function define(obj, key, value) {
42
- return Object.defineProperty(obj, key, {
43
- value: value,
44
- enumerable: !0,
45
- configurable: !0,
46
- writable: !0
47
- }), obj[key];
48
- }
49
- try {
50
- define({}, "");
51
- } catch (err) {
52
- define = function (obj, key, value) {
53
- return obj[key] = value;
54
- };
55
- }
56
- function wrap(innerFn, outerFn, self, tryLocsList) {
57
- var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator,
58
- generator = Object.create(protoGenerator.prototype),
59
- context = new Context(tryLocsList || []);
60
- return defineProperty(generator, "_invoke", {
61
- value: makeInvokeMethod(innerFn, self, context)
62
- }), generator;
63
- }
64
- function tryCatch(fn, obj, arg) {
65
- try {
66
- return {
67
- type: "normal",
68
- arg: fn.call(obj, arg)
69
- };
70
- } catch (err) {
71
- return {
72
- type: "throw",
73
- arg: err
74
- };
75
- }
76
- }
77
- exports.wrap = wrap;
78
- var ContinueSentinel = {};
79
- function Generator() {}
80
- function GeneratorFunction() {}
81
- function GeneratorFunctionPrototype() {}
82
- var IteratorPrototype = {};
83
- define(IteratorPrototype, iteratorSymbol, function () {
84
- return this;
85
- });
86
- var getProto = Object.getPrototypeOf,
87
- NativeIteratorPrototype = getProto && getProto(getProto(values([])));
88
- NativeIteratorPrototype && NativeIteratorPrototype !== Op && hasOwn.call(NativeIteratorPrototype, iteratorSymbol) && (IteratorPrototype = NativeIteratorPrototype);
89
- var Gp = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(IteratorPrototype);
90
- function defineIteratorMethods(prototype) {
91
- ["next", "throw", "return"].forEach(function (method) {
92
- define(prototype, method, function (arg) {
93
- return this._invoke(method, arg);
94
- });
95
- });
96
- }
97
- function AsyncIterator(generator, PromiseImpl) {
98
- function invoke(method, arg, resolve, reject) {
99
- var record = tryCatch(generator[method], generator, arg);
100
- if ("throw" !== record.type) {
101
- var result = record.arg,
102
- value = result.value;
103
- return value && "object" == typeof value && hasOwn.call(value, "__await") ? PromiseImpl.resolve(value.__await).then(function (value) {
104
- invoke("next", value, resolve, reject);
105
- }, function (err) {
106
- invoke("throw", err, resolve, reject);
107
- }) : PromiseImpl.resolve(value).then(function (unwrapped) {
108
- result.value = unwrapped, resolve(result);
109
- }, function (error) {
110
- return invoke("throw", error, resolve, reject);
111
- });
112
- }
113
- reject(record.arg);
114
- }
115
- var previousPromise;
116
- defineProperty(this, "_invoke", {
117
- value: function (method, arg) {
118
- function callInvokeWithMethodAndArg() {
119
- return new PromiseImpl(function (resolve, reject) {
120
- invoke(method, arg, resolve, reject);
121
- });
122
- }
123
- return previousPromise = previousPromise ? previousPromise.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg();
124
- }
125
- });
126
- }
127
- function makeInvokeMethod(innerFn, self, context) {
128
- var state = "suspendedStart";
129
- return function (method, arg) {
130
- if ("executing" === state) throw new Error("Generator is already running");
131
- if ("completed" === state) {
132
- if ("throw" === method) throw arg;
133
- return {
134
- value: void 0,
135
- done: !0
136
- };
137
- }
138
- for (context.method = method, context.arg = arg;;) {
139
- var delegate = context.delegate;
140
- if (delegate) {
141
- var delegateResult = maybeInvokeDelegate(delegate, context);
142
- if (delegateResult) {
143
- if (delegateResult === ContinueSentinel) continue;
144
- return delegateResult;
145
- }
146
- }
147
- if ("next" === context.method) context.sent = context._sent = context.arg;else if ("throw" === context.method) {
148
- if ("suspendedStart" === state) throw state = "completed", context.arg;
149
- context.dispatchException(context.arg);
150
- } else "return" === context.method && context.abrupt("return", context.arg);
151
- state = "executing";
152
- var record = tryCatch(innerFn, self, context);
153
- if ("normal" === record.type) {
154
- if (state = context.done ? "completed" : "suspendedYield", record.arg === ContinueSentinel) continue;
155
- return {
156
- value: record.arg,
157
- done: context.done
158
- };
159
- }
160
- "throw" === record.type && (state = "completed", context.method = "throw", context.arg = record.arg);
161
- }
162
- };
163
- }
164
- function maybeInvokeDelegate(delegate, context) {
165
- var methodName = context.method,
166
- method = delegate.iterator[methodName];
167
- if (undefined === method) return context.delegate = null, "throw" === methodName && delegate.iterator.return && (context.method = "return", context.arg = undefined, maybeInvokeDelegate(delegate, context), "throw" === context.method) || "return" !== methodName && (context.method = "throw", context.arg = new TypeError("The iterator does not provide a '" + methodName + "' method")), ContinueSentinel;
168
- var record = tryCatch(method, delegate.iterator, context.arg);
169
- if ("throw" === record.type) return context.method = "throw", context.arg = record.arg, context.delegate = null, ContinueSentinel;
170
- var info = record.arg;
171
- return info ? info.done ? (context[delegate.resultName] = info.value, context.next = delegate.nextLoc, "return" !== context.method && (context.method = "next", context.arg = undefined), context.delegate = null, ContinueSentinel) : info : (context.method = "throw", context.arg = new TypeError("iterator result is not an object"), context.delegate = null, ContinueSentinel);
172
- }
173
- function pushTryEntry(locs) {
174
- var entry = {
175
- tryLoc: locs[0]
176
- };
177
- 1 in locs && (entry.catchLoc = locs[1]), 2 in locs && (entry.finallyLoc = locs[2], entry.afterLoc = locs[3]), this.tryEntries.push(entry);
178
- }
179
- function resetTryEntry(entry) {
180
- var record = entry.completion || {};
181
- record.type = "normal", delete record.arg, entry.completion = record;
182
- }
183
- function Context(tryLocsList) {
184
- this.tryEntries = [{
185
- tryLoc: "root"
186
- }], tryLocsList.forEach(pushTryEntry, this), this.reset(!0);
187
- }
188
- function values(iterable) {
189
- if (iterable || "" === iterable) {
190
- var iteratorMethod = iterable[iteratorSymbol];
191
- if (iteratorMethod) return iteratorMethod.call(iterable);
192
- if ("function" == typeof iterable.next) return iterable;
193
- if (!isNaN(iterable.length)) {
194
- var i = -1,
195
- next = function next() {
196
- for (; ++i < iterable.length;) if (hasOwn.call(iterable, i)) return next.value = iterable[i], next.done = !1, next;
197
- return next.value = undefined, next.done = !0, next;
198
- };
199
- return next.next = next;
200
- }
201
- }
202
- throw new TypeError(typeof iterable + " is not iterable");
203
- }
204
- return GeneratorFunction.prototype = GeneratorFunctionPrototype, defineProperty(Gp, "constructor", {
205
- value: GeneratorFunctionPrototype,
206
- configurable: !0
207
- }), defineProperty(GeneratorFunctionPrototype, "constructor", {
208
- value: GeneratorFunction,
209
- configurable: !0
210
- }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, toStringTagSymbol, "GeneratorFunction"), exports.isGeneratorFunction = function (genFun) {
211
- var ctor = "function" == typeof genFun && genFun.constructor;
212
- return !!ctor && (ctor === GeneratorFunction || "GeneratorFunction" === (ctor.displayName || ctor.name));
213
- }, exports.mark = function (genFun) {
214
- return Object.setPrototypeOf ? Object.setPrototypeOf(genFun, GeneratorFunctionPrototype) : (genFun.__proto__ = GeneratorFunctionPrototype, define(genFun, toStringTagSymbol, "GeneratorFunction")), genFun.prototype = Object.create(Gp), genFun;
215
- }, exports.awrap = function (arg) {
216
- return {
217
- __await: arg
218
- };
219
- }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, asyncIteratorSymbol, function () {
220
- return this;
221
- }), exports.AsyncIterator = AsyncIterator, exports.async = function (innerFn, outerFn, self, tryLocsList, PromiseImpl) {
222
- void 0 === PromiseImpl && (PromiseImpl = Promise);
223
- var iter = new AsyncIterator(wrap(innerFn, outerFn, self, tryLocsList), PromiseImpl);
224
- return exports.isGeneratorFunction(outerFn) ? iter : iter.next().then(function (result) {
225
- return result.done ? result.value : iter.next();
226
- });
227
- }, defineIteratorMethods(Gp), define(Gp, toStringTagSymbol, "Generator"), define(Gp, iteratorSymbol, function () {
228
- return this;
229
- }), define(Gp, "toString", function () {
230
- return "[object Generator]";
231
- }), exports.keys = function (val) {
232
- var object = Object(val),
233
- keys = [];
234
- for (var key in object) keys.push(key);
235
- return keys.reverse(), function next() {
236
- for (; keys.length;) {
237
- var key = keys.pop();
238
- if (key in object) return next.value = key, next.done = !1, next;
239
- }
240
- return next.done = !0, next;
241
- };
242
- }, exports.values = values, Context.prototype = {
243
- constructor: Context,
244
- reset: function (skipTempReset) {
245
- if (this.prev = 0, this.next = 0, this.sent = this._sent = undefined, this.done = !1, this.delegate = null, this.method = "next", this.arg = undefined, this.tryEntries.forEach(resetTryEntry), !skipTempReset) for (var name in this) "t" === name.charAt(0) && hasOwn.call(this, name) && !isNaN(+name.slice(1)) && (this[name] = undefined);
246
- },
247
- stop: function () {
248
- this.done = !0;
249
- var rootRecord = this.tryEntries[0].completion;
250
- if ("throw" === rootRecord.type) throw rootRecord.arg;
251
- return this.rval;
252
- },
253
- dispatchException: function (exception) {
254
- if (this.done) throw exception;
255
- var context = this;
256
- function handle(loc, caught) {
257
- return record.type = "throw", record.arg = exception, context.next = loc, caught && (context.method = "next", context.arg = undefined), !!caught;
258
- }
259
- for (var i = this.tryEntries.length - 1; i >= 0; --i) {
260
- var entry = this.tryEntries[i],
261
- record = entry.completion;
262
- if ("root" === entry.tryLoc) return handle("end");
263
- if (entry.tryLoc <= this.prev) {
264
- var hasCatch = hasOwn.call(entry, "catchLoc"),
265
- hasFinally = hasOwn.call(entry, "finallyLoc");
266
- if (hasCatch && hasFinally) {
267
- if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0);
268
- if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc);
269
- } else if (hasCatch) {
270
- if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0);
271
- } else {
272
- if (!hasFinally) throw new Error("try statement without catch or finally");
273
- if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc);
274
- }
275
- }
276
- }
277
- },
278
- abrupt: function (type, arg) {
279
- for (var i = this.tryEntries.length - 1; i >= 0; --i) {
280
- var entry = this.tryEntries[i];
281
- if (entry.tryLoc <= this.prev && hasOwn.call(entry, "finallyLoc") && this.prev < entry.finallyLoc) {
282
- var finallyEntry = entry;
283
- break;
284
- }
285
- }
286
- finallyEntry && ("break" === type || "continue" === type) && finallyEntry.tryLoc <= arg && arg <= finallyEntry.finallyLoc && (finallyEntry = null);
287
- var record = finallyEntry ? finallyEntry.completion : {};
288
- return record.type = type, record.arg = arg, finallyEntry ? (this.method = "next", this.next = finallyEntry.finallyLoc, ContinueSentinel) : this.complete(record);
289
- },
290
- complete: function (record, afterLoc) {
291
- if ("throw" === record.type) throw record.arg;
292
- return "break" === record.type || "continue" === record.type ? this.next = record.arg : "return" === record.type ? (this.rval = this.arg = record.arg, this.method = "return", this.next = "end") : "normal" === record.type && afterLoc && (this.next = afterLoc), ContinueSentinel;
293
- },
294
- finish: function (finallyLoc) {
295
- for (var i = this.tryEntries.length - 1; i >= 0; --i) {
296
- var entry = this.tryEntries[i];
297
- if (entry.finallyLoc === finallyLoc) return this.complete(entry.completion, entry.afterLoc), resetTryEntry(entry), ContinueSentinel;
298
- }
299
- },
300
- catch: function (tryLoc) {
301
- for (var i = this.tryEntries.length - 1; i >= 0; --i) {
302
- var entry = this.tryEntries[i];
303
- if (entry.tryLoc === tryLoc) {
304
- var record = entry.completion;
305
- if ("throw" === record.type) {
306
- var thrown = record.arg;
307
- resetTryEntry(entry);
308
- }
309
- return thrown;
310
- }
311
- }
312
- throw new Error("illegal catch attempt");
313
- },
314
- delegateYield: function (iterable, resultName, nextLoc) {
315
- return this.delegate = {
316
- iterator: values(iterable),
317
- resultName: resultName,
318
- nextLoc: nextLoc
319
- }, "next" === this.method && (this.arg = undefined), ContinueSentinel;
320
- }
321
- }, exports;
322
- }
323
- function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
324
- try {
325
- var info = gen[key](arg);
326
- var value = info.value;
327
- } catch (error) {
328
- reject(error);
329
- return;
330
- }
331
- if (info.done) {
332
- resolve(value);
333
- } else {
334
- Promise.resolve(value).then(_next, _throw);
335
- }
336
- }
337
- function _asyncToGenerator(fn) {
338
- return function () {
339
- var self = this,
340
- args = arguments;
341
- return new Promise(function (resolve, reject) {
342
- var gen = fn.apply(self, args);
343
- function _next(value) {
344
- asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value);
345
- }
346
- function _throw(err) {
347
- asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err);
348
- }
349
- _next(undefined);
350
- });
351
- };
352
- }
353
- function _slicedToArray(arr, i) {
354
- return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest();
355
- }
356
- function _toConsumableArray(arr) {
357
- return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread();
358
- }
359
- function _arrayWithoutHoles(arr) {
360
- if (Array.isArray(arr)) return _arrayLikeToArray(arr);
361
- }
362
- function _arrayWithHoles(arr) {
363
- if (Array.isArray(arr)) return arr;
364
- }
365
- function _iterableToArray(iter) {
366
- if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
367
- }
368
- function _unsupportedIterableToArray(o, minLen) {
369
- if (!o) return;
370
- if (typeof o === "string") return _arrayLikeToArray(o, minLen);
371
- var n = Object.prototype.toString.call(o).slice(8, -1);
372
- if (n === "Object" && o.constructor) n = o.constructor.name;
373
- if (n === "Map" || n === "Set") return Array.from(o);
374
- if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);
375
- }
376
- function _arrayLikeToArray(arr, len) {
377
- if (len == null || len > arr.length) len = arr.length;
378
- for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];
379
- return arr2;
380
- }
381
- function _nonIterableSpread() {
382
- throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
383
- }
384
- function _nonIterableRest() {
385
- throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
386
- }
387
-
388
- exports.arrayLikeToArray = _arrayLikeToArray;
389
- exports.arrayWithHoles = _arrayWithHoles;
390
- exports.arrayWithoutHoles = _arrayWithoutHoles;
391
- exports.asyncToGenerator = _asyncToGenerator;
392
- exports.iterableToArray = _iterableToArray;
393
- exports.iterableToArrayLimit = _iterableToArrayLimit;
394
- exports.nonIterableRest = _nonIterableRest;
395
- exports.nonIterableSpread = _nonIterableSpread;
396
- exports.regeneratorRuntime = _regeneratorRuntime;
397
- exports.slicedToArray = _slicedToArray;
398
- exports.toConsumableArray = _toConsumableArray;
399
- exports.unsupportedIterableToArray = _unsupportedIterableToArray;
@@ -1,9 +0,0 @@
1
- 'use strict';
2
-
3
- var MaterialSurvey = require('./MaterialSurvey.js');
4
- var MaterialSurveyInfo = require('./MaterialSurveyInfo.js');
5
-
6
-
7
-
8
- exports.MaterialSurvey = MaterialSurvey.default;
9
- exports.MaterialSurveyInfo = MaterialSurveyInfo.default;
@@ -1,13 +0,0 @@
1
- 'use strict';
2
-
3
- var en = require('./en.json.js');
4
- var ko = require('./ko.json.js');
5
- var th = require('./th.json.js');
6
- var ja = require('./ja.json.js');
7
-
8
-
9
-
10
- exports.messageEn = en.default;
11
- exports.messageKo = ko.default;
12
- exports.messageTh = th.default;
13
- exports.messageJa = ja.default;
@@ -1,7 +0,0 @@
1
- 'use strict';
2
-
3
- var MaterialSurveyEdit = require('./MaterialSurveyEdit.js');
4
-
5
-
6
-
7
- exports.MaterialSurveyEdit = MaterialSurveyEdit.default;