kui-crm 0.0.186 → 0.0.188
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/cjs/index.js +18 -6
- package/cjs/index.js.map +1 -1
- package/index.d.ts +9 -7
- package/index.js +18 -7
- package/index.js.map +1 -1
- package/package.json +1 -1
- package/utils/cjs/index.js +16 -4
- package/utils/cjs/index.js.map +1 -1
- package/utils/index.d.ts +2 -1
- package/utils/index.js +16 -5
- package/utils/index.js.map +1 -1
package/cjs/index.js
CHANGED
|
@@ -777,16 +777,27 @@ var uploadNewFile = function (loader, document) { return __awaiter(void 0, void
|
|
|
777
777
|
}
|
|
778
778
|
});
|
|
779
779
|
}); };
|
|
780
|
-
var
|
|
780
|
+
var uploadFilesWithoutFilter = function (loader, files) { return __awaiter(void 0, void 0, void 0, function () {
|
|
781
781
|
var res;
|
|
782
782
|
return __generator(this, function (_a) {
|
|
783
783
|
switch (_a.label) {
|
|
784
784
|
case 0: return [4 /*yield*/, Promise.allSettled(files.map(function (file) { return uploadNewFile(loader, file); }))];
|
|
785
785
|
case 1:
|
|
786
786
|
res = _a.sent();
|
|
787
|
-
return [2 /*return*/, res
|
|
788
|
-
|
|
789
|
-
|
|
787
|
+
return [2 /*return*/, res.map(function (result) {
|
|
788
|
+
return result.status === "fulfilled" ? result.value : null;
|
|
789
|
+
})];
|
|
790
|
+
}
|
|
791
|
+
});
|
|
792
|
+
}); };
|
|
793
|
+
var uploadFiles = function (loader, files) { return __awaiter(void 0, void 0, void 0, function () {
|
|
794
|
+
var res;
|
|
795
|
+
return __generator(this, function (_a) {
|
|
796
|
+
switch (_a.label) {
|
|
797
|
+
case 0: return [4 /*yield*/, uploadFilesWithoutFilter(loader, files)];
|
|
798
|
+
case 1:
|
|
799
|
+
res = _a.sent();
|
|
800
|
+
return [2 /*return*/, res.filter(function (result) { return result; })];
|
|
790
801
|
}
|
|
791
802
|
});
|
|
792
803
|
}); };
|
|
@@ -3667,8 +3678,8 @@ var StyledLink$1 = styled__default["default"].a(templateObject_1$e || (templateO
|
|
|
3667
3678
|
var templateObject_1$e;
|
|
3668
3679
|
|
|
3669
3680
|
function PreviewContent(_a) {
|
|
3670
|
-
var imageSrc = _a.imageSrc, description = _a.description, content = _a.content, label = _a.label, other = __rest(_a, ["imageSrc", "description", "content", "label"]);
|
|
3671
|
-
return (jsxRuntime.jsxs(kuiBasic.Grid, __assign({ container: true, alignItems: "center", wrap: "nowrap" }, other, { children: [jsxRuntime.jsx(StyledImage$2, { size: "sm", imageSrc: imageSrc, name: description }), jsxRuntime.jsxs(StyledContent, { children: [content || (jsxRuntime.jsx(StyledCaption$2, __assign({ size: "s", weight: 500 }, { children: description }))), label] })] })));
|
|
3681
|
+
var imageSrc = _a.imageSrc, description = _a.description, content = _a.content, label = _a.label, withoutImage = _a.withoutImage, other = __rest(_a, ["imageSrc", "description", "content", "label", "withoutImage"]);
|
|
3682
|
+
return (jsxRuntime.jsxs(kuiBasic.Grid, __assign({ container: true, alignItems: "center", wrap: "nowrap" }, other, { children: [!withoutImage && (jsxRuntime.jsx(StyledImage$2, { size: "sm", imageSrc: imageSrc, name: description })), jsxRuntime.jsxs(StyledContent, { children: [content || (jsxRuntime.jsx(StyledCaption$2, __assign({ size: "s", weight: 500 }, { children: description }))), label] })] })));
|
|
3672
3683
|
}
|
|
3673
3684
|
var StyledImage$2 = styled__default["default"](SquarePreviewImage)(templateObject_1$d || (templateObject_1$d = __makeTemplateObject(["\n margin-right: 10px;\n"], ["\n margin-right: 10px;\n"])));
|
|
3674
3685
|
var StyledCaption$2 = styled__default["default"](kuiBasic.Caption)(templateObject_2$8 || (templateObject_2$8 = __makeTemplateObject(["\n max-width: 100%;\n"], ["\n max-width: 100%;\n"])));
|
|
@@ -4231,6 +4242,7 @@ exports.uploadDocument = uploadDocument;
|
|
|
4231
4242
|
exports.uploadDocuments = uploadDocuments;
|
|
4232
4243
|
exports.uploadFile = uploadFile;
|
|
4233
4244
|
exports.uploadFiles = uploadFiles;
|
|
4245
|
+
exports.uploadFilesWithoutFilter = uploadFilesWithoutFilter;
|
|
4234
4246
|
exports.uploadImage = uploadImage;
|
|
4235
4247
|
exports.uploadImages = uploadImages;
|
|
4236
4248
|
exports.uploadNewFile = uploadNewFile;
|