@awell-health/ui-library 0.1.121 → 0.1.123
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/dist/index.js +23 -3
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -48233,7 +48233,7 @@ var Kr=[{
|
|
|
48233
48233
|
if (value && disabled === true) {
|
|
48234
48234
|
return jsxRuntime.exports.jsxs("div", __assign({ className: "".concat(classes$9.file_input_field_container, " ").concat(className), "data-cy": dataCy }, { children: [label && jsxRuntime.exports.jsx(QuestionLabel, { htmlFor: id, label: label, mandatory: mandatory }), !value.url ? jsxRuntime.exports.jsx("div", { children: "No file uploaded" }) : jsxRuntime.exports.jsxs("div", __assign({ className: classes$9.read_only_file }, { children: [value.filename, " (", value.contentType, ")"] }))] }), id);
|
|
48235
48235
|
}
|
|
48236
|
-
return jsxRuntime.exports.jsxs("div", __assign({ className: "".concat(classes$9.file_input_field_container, " ").concat(className), "data-cy": dataCy }, { children: [label && jsxRuntime.exports.jsx(QuestionLabel, { htmlFor: id, label: label, mandatory: mandatory }), error && jsxRuntime.exports.jsx("div", __assign({ className: classes$9.error_message }, { children: error })), jsxRuntime.exports.jsx("div", __assign({ className: classes$9.file_upload_wrapper }, { children: jsxRuntime.exports.jsx(dg, { onChange: handleFilesChange, onError: onError, isMultiple: false, accept: accept, error: error }) })), selectedFile && jsxRuntime.exports.jsx("div", __assign({ className: "".concat(classes$9.file_list_wrapper, " ").concat(classes$9.custom_file_list_container) }, { children: jsxRuntime.exports.jsx(ug, { files: [selectedFile], onDelete: function () {return handleRemoveFile();}, generalProgress: selectedFile.progress !== undefined && selectedFile.progress < 100 ?
|
|
48236
|
+
return jsxRuntime.exports.jsxs("div", __assign({ className: "".concat(classes$9.file_input_field_container, " ").concat(className), "data-cy": dataCy }, { children: [label && jsxRuntime.exports.jsx(QuestionLabel, { htmlFor: id, label: label, mandatory: mandatory }), error && jsxRuntime.exports.jsx("div", __assign({ className: classes$9.error_message }, { children: error })), jsxRuntime.exports.jsx("div", __assign({ className: classes$9.file_upload_wrapper }, { children: jsxRuntime.exports.jsx(dg, { onChange: handleFilesChange, onError: onError, isMultiple: false, accept: accept, error: error, maxSizeMb: 5 }) })), selectedFile && jsxRuntime.exports.jsx("div", __assign({ className: "".concat(classes$9.file_list_wrapper, " ").concat(classes$9.custom_file_list_container) }, { children: jsxRuntime.exports.jsx(ug, { files: [selectedFile], onDelete: function () {return handleRemoveFile();}, generalProgress: selectedFile.progress !== undefined && selectedFile.progress < 100 ?
|
|
48237
48237
|
selectedFile.progress :
|
|
48238
48238
|
undefined }) }))] }), id);
|
|
48239
48239
|
};
|
|
@@ -48452,7 +48452,18 @@ var Kr=[{
|
|
|
48452
48452
|
var _a, _b, _c;
|
|
48453
48453
|
return isAttachmentValid({
|
|
48454
48454
|
attachmentsValue: value,
|
|
48455
|
-
acceptedFileTypes: (_b = (_a = config === null || config === void 0 ? void 0 : config.file_storage) === null || _a === void 0 ? void 0 : _a.accepted_file_types) !== null && _b !== void 0 ? _b : [
|
|
48455
|
+
acceptedFileTypes: (_b = (_a = config === null || config === void 0 ? void 0 : config.file_storage) === null || _a === void 0 ? void 0 : _a.accepted_file_types) !== null && _b !== void 0 ? _b : [
|
|
48456
|
+
'application/pdf',
|
|
48457
|
+
'application/msword',
|
|
48458
|
+
'application/json',
|
|
48459
|
+
'application/xml',
|
|
48460
|
+
'application/csv',
|
|
48461
|
+
'application/zip',
|
|
48462
|
+
'document/json',
|
|
48463
|
+
'document/xml',
|
|
48464
|
+
'document/csv',
|
|
48465
|
+
'document/zip'],
|
|
48466
|
+
|
|
48456
48467
|
required: (_c = config === null || config === void 0 ? void 0 : config.mandatory) !== null && _c !== void 0 ? _c : false });
|
|
48457
48468
|
|
|
48458
48469
|
} },
|
|
@@ -48463,7 +48474,16 @@ var Kr=[{
|
|
|
48463
48474
|
onControllerChange(JSON.stringify(attachment));
|
|
48464
48475
|
onAnswerChange();
|
|
48465
48476
|
}, onBlur: onBlur, accept: (_c = (_b = config === null || config === void 0 ? void 0 : config.file_storage) === null || _b === void 0 ? void 0 : _b.accepted_file_types) !== null && _c !== void 0 ? _c : [
|
|
48466
|
-
'application/pdf'
|
|
48477
|
+
'application/pdf',
|
|
48478
|
+
'application/msword',
|
|
48479
|
+
'application/json',
|
|
48480
|
+
'application/xml',
|
|
48481
|
+
'application/csv',
|
|
48482
|
+
'application/zip',
|
|
48483
|
+
'document/json',
|
|
48484
|
+
'document/xml',
|
|
48485
|
+
'document/csv',
|
|
48486
|
+
'document/zip'],
|
|
48467
48487
|
configSlug: (_d = config === null || config === void 0 ? void 0 : config.file_storage) === null || _d === void 0 ? void 0 : _d.file_storage_config_slug, onFileUpload: onFileUpload, label: question.title, mandatory: config === null || config === void 0 ? void 0 : config.mandatory });
|
|
48468
48488
|
} });
|
|
48469
48489
|
case exports.UserQuestionType.Image:
|