@monolith-forensics/monolith-ui 1.2.85 → 1.2.86
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.
|
@@ -5,7 +5,19 @@ import "react-pdf/dist/esm/Page/AnnotationLayer.css";
|
|
|
5
5
|
import "react-pdf/dist/esm/Page/TextLayer.css";
|
|
6
6
|
import styled from "styled-components";
|
|
7
7
|
import Loader from "../../Loader";
|
|
8
|
-
|
|
8
|
+
if (typeof Promise.withResolvers === "undefined") {
|
|
9
|
+
if (window)
|
|
10
|
+
// @ts-expect-error This does not exist outside of polyfill which this is doing
|
|
11
|
+
window.Promise.withResolvers = function () {
|
|
12
|
+
let resolve, reject;
|
|
13
|
+
const promise = new Promise((res, rej) => {
|
|
14
|
+
resolve = res;
|
|
15
|
+
reject = rej;
|
|
16
|
+
});
|
|
17
|
+
return { promise, resolve, reject };
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
pdfjs.GlobalWorkerOptions.workerSrc = new URL("pdfjs-dist/legacy/build/pdf.worker.min.mjs", import.meta.url).toString();
|
|
9
21
|
const StyledContainer = styled.div.attrs({
|
|
10
22
|
className: "PdfViewer-container",
|
|
11
23
|
}) `
|
package/dist/TagBox/TagBox.js
CHANGED
|
@@ -519,7 +519,7 @@ const TagBox = styled(({ className, data = [], placeholder = "Select tags", arro
|
|
|
519
519
|
customItems,
|
|
520
520
|
]);
|
|
521
521
|
const handleKeyDown = (e) => {
|
|
522
|
-
var _a, _b
|
|
522
|
+
var _a, _b;
|
|
523
523
|
const currentInputValue = (_a = inputRef === null || inputRef === void 0 ? void 0 : inputRef.current) === null || _a === void 0 ? void 0 : _a.value;
|
|
524
524
|
// Escape key
|
|
525
525
|
if (e.key === "Escape") {
|
|
@@ -542,7 +542,8 @@ const TagBox = styled(({ className, data = [], placeholder = "Select tags", arro
|
|
|
542
542
|
currentInputValue !== "" &&
|
|
543
543
|
allowCustomValue) {
|
|
544
544
|
handleAddItem(currentInputValue);
|
|
545
|
-
|
|
545
|
+
if (inputRef === null || inputRef === void 0 ? void 0 : inputRef.current)
|
|
546
|
+
inputRef.current.value = "";
|
|
546
547
|
setSearchValue("");
|
|
547
548
|
update();
|
|
548
549
|
}
|