Skip to content

Commit bebf395

Browse files
authored
Create a new dist version 3.2.7 (#480)
Collecting: - [Dependabot] Bump storybook from 8.6.14 to 8.6.15 in the npm_and_yarn group across 1 directory #468 - [FIX] bump @storybook/react to resolve dependabot alert #471 - [Dependabot] Bump react-router from 6.22.3 to 6.30.3 in the npm_and_yarn group across 1 directory #474 - [CHORE ]Handle permission denied error message in the table #473 - [Dependabot] Bump lodash from 4.17.21 to 4.17.23 in the npm_and_yarn group across 1 directory
1 parent 57fe07c commit bebf395

File tree

5 files changed

+80
-75
lines changed

5 files changed

+80
-75
lines changed

commit_message

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,10 @@
11

22

3-
Create a new dist version 3.2.6
3+
Create a new dist version 3.2.7
44

55
Collecting:
6-
- [FIX] Changed date-time format to local (#461)
7-
- [CHORE] Add package-lock file (#466)
6+
- [Dependabot] Bump storybook from 8.6.14 to 8.6.15 in the npm_and_yarn group across 1 directory #468
7+
- [FIX] bump @storybook/react to resolve dependabot alert #471
8+
- [Dependabot] Bump react-router from 6.22.3 to 6.30.3 in the npm_and_yarn group across 1 directory #474
9+
- [CHORE ]Handle permission denied error message in the table #473
10+
- [Dependabot] Bump lodash from 4.17.21 to 4.17.23 in the npm_and_yarn group across 1 directory

dist/utils/common.util.d.ts.map

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/utils/common.util.mjs

Lines changed: 71 additions & 69 deletions
Original file line numberDiff line numberDiff line change
@@ -1,107 +1,109 @@
1-
import { create as f } from "react-modal-promise";
2-
import { isEmpty as c, isNumber as g, differenceWith as w, isEqual as E, omit as a, get as s } from "lodash";
1+
import { create as g } from "react-modal-promise";
2+
import { isEmpty as u, isNumber as E, differenceWith as w, isEqual as T, omit as a, get as s } from "lodash";
33
import d from "../components/ConfirmDialog/ConfirmDialog.mjs";
4-
import { PRIMARY_BUTTON as b, TERTIARY_BUTTON as u, DANGER_BUTTON as T, VIEW_SEARCH_PARAMETER as y } from "../constants.mjs";
5-
import { setFiltersWasHandled as h, showWarning as v } from "../reducers/commonDetailsReducer.mjs";
6-
import { setNotification as C } from "../reducers/notificationReducer.mjs";
4+
import { PRIMARY_BUTTON as b, TERTIARY_BUTTON as m, DANGER_BUTTON as h, FORBIDDEN_ERROR_STATUS_CODE as v, VIEW_SEARCH_PARAMETER as y } from "../constants.mjs";
5+
import { setFiltersWasHandled as C, showWarning as R } from "../reducers/commonDetailsReducer.mjs";
6+
import { setNotification as N } from "../reducers/notificationReducer.mjs";
77
import { showErrorNotification as l } from "./notification.util.mjs";
8-
const m = (t, e) => f(t)(e), M = (t, e) => m(d, {
8+
const p = (e, t) => g(e)(t), S = (e, t) => p(d, {
99
cancelButton: {
1010
label: "Cancel",
11-
variant: u
11+
variant: m
1212
},
1313
confirmButton: {
1414
label: "OK",
1515
variant: b,
16-
handler: e
16+
handler: t
1717
},
1818
header: "Are you sure?",
19-
message: t
20-
}), O = (t, e, r) => m(d, {
19+
message: e
20+
}), _ = (e, t, n) => p(d, {
2121
cancelButton: {
2222
label: "Cancel",
23-
variant: u
23+
variant: m
2424
},
2525
confirmButton: {
2626
label: "Delete",
27-
variant: T,
28-
handler: r
27+
variant: h,
28+
handler: n
2929
},
30-
header: t,
31-
message: e
32-
}), F = (t) => Object.values(t).every(
33-
(e) => !e || (e == null ? void 0 : e.length) === 0 || !g(e) && c(e)
34-
), S = (t, e, r = []) => t.length !== e.length ? !1 : c(
35-
w(t, e, (n, i) => E(a(n, r), a(i, r)))
36-
), N = (t) => {
37-
const e = s(t, "response.data.detail", null);
38-
return typeof e == "string" ? e : s(e, "reason", "");
39-
}, V = (t, e) => {
40-
const n = N(t) || t.message;
41-
return (!n || n === "Not Found" || n.startsWith("Request failed with status code")) && e ? e : n || "";
42-
}, W = () => {
43-
const t = {
30+
header: e,
31+
message: t
32+
}), F = (e) => Object.values(e).every(
33+
(t) => !t || (t == null ? void 0 : t.length) === 0 || !E(t) && u(t)
34+
), V = (e, t, n = []) => e.length !== t.length ? !1 : u(
35+
w(e, t, (r, i) => T(a(r, n), a(i, n)))
36+
), c = {
37+
[v]: "You do not have a permission to view this data"
38+
}, D = (e) => {
39+
const t = s(e, "response.data.detail", null);
40+
return typeof t == "string" ? t : s(t, "reason", "");
41+
}, W = (e, t) => {
42+
const r = D(e) || e.message;
43+
return (!r || r === "Not Found" || r.startsWith("Request failed with status code")) && t ? t : c[e.status] ? c[e.status] : r || "";
44+
}, x = () => {
45+
const e = {
4446
transition: "transitionend",
4547
OTransition: "oTransitionEnd",
4648
MozTransition: "transitionend",
4749
WebkitTransition: "webkitTransitionEnd"
4850
};
49-
let e = document.body.style;
50-
for (let r in t)
51-
if (e[r] !== void 0)
52-
return t[r];
53-
}, _ = (t) => getComputedStyle(document.documentElement).getPropertyValue(t).trim(), x = (t) => {
54-
var e;
55-
return (e = new URLSearchParams(t).get(y)) == null ? void 0 : e.toLowerCase();
56-
}, q = async (t, e, r = !1) => {
57-
let n = Promise.resolve(!0);
58-
return t.counter > 0 && (n = await new Promise((i) => {
59-
const o = (p) => {
60-
window.removeEventListener("discardChanges", o), window.removeEventListener("cancelLeave", o), i(p);
51+
let t = document.body.style;
52+
for (let n in e)
53+
if (t[n] !== void 0)
54+
return e[n];
55+
}, I = (e) => getComputedStyle(document.documentElement).getPropertyValue(e).trim(), q = (e) => {
56+
var t;
57+
return (t = new URLSearchParams(e).get(y)) == null ? void 0 : t.toLowerCase();
58+
}, H = async (e, t, n = !1) => {
59+
let r = Promise.resolve(!0);
60+
return e.counter > 0 && (r = await new Promise((i) => {
61+
const o = (f) => {
62+
window.removeEventListener("discardChanges", o), window.removeEventListener("cancelLeave", o), i(f);
6163
};
62-
window.addEventListener("discardChanges", () => o(!0)), window.addEventListener("cancelLeave", () => o(!1)), e(h(r)), e(v(!0));
63-
})), n;
64-
}, H = (t, e) => {
65-
var r;
66-
if (!((r = navigator.clipboard) != null && r.writeText))
64+
window.addEventListener("discardChanges", () => o(!0)), window.addEventListener("cancelLeave", () => o(!1)), t(C(n)), t(R(!0));
65+
})), r;
66+
}, Y = (e, t) => {
67+
var n;
68+
if (!((n = navigator.clipboard) != null && n.writeText))
6769
return l(
68-
e,
70+
t,
6971
null,
7072
"",
7173
"Copy to clipboard failed due to unsecured connection"
7274
);
73-
navigator.clipboard.writeText(t).then(() => {
74-
e(
75-
C({
75+
navigator.clipboard.writeText(e).then(() => {
76+
t(
77+
N({
7678
status: 200,
7779
id: Math.random(),
7880
message: "Copied to clipboard successfully"
7981
})
8082
);
81-
}).catch((n) => {
82-
l(e, n, "", "Copy to clipboard failed");
83+
}).catch((r) => {
84+
l(t, r, "", "Copy to clipboard failed");
8385
});
84-
}, I = (t, e) => {
85-
if ((typeof t == "string" && t.trim() !== "" || typeof t == "number") && !isNaN(t)) {
86-
const r = parseFloat(t);
87-
return r % 1 === 0 ? r : +r.toFixed(e ?? 2);
86+
}, j = (e, t) => {
87+
if ((typeof e == "string" && e.trim() !== "" || typeof e == "number") && !isNaN(e)) {
88+
const n = parseFloat(e);
89+
return n % 1 === 0 ? n : +n.toFixed(t ?? 2);
8890
}
89-
return t;
90-
}, j = (t) => new URL(t, window.location.origin).toString();
91+
return e;
92+
}, k = (e) => new URL(e, window.location.origin).toString();
9193
export {
92-
S as areArraysEqual,
93-
H as copyToClipboard,
94-
j as generateUrlFromRouterPath,
95-
N as getErrorDetail,
96-
V as getErrorMsg,
97-
_ as getScssVariableValue,
98-
W as getTransitionEndEventName,
99-
x as getViewMode,
94+
V as areArraysEqual,
95+
Y as copyToClipboard,
96+
k as generateUrlFromRouterPath,
97+
D as getErrorDetail,
98+
W as getErrorMsg,
99+
I as getScssVariableValue,
100+
x as getTransitionEndEventName,
101+
q as getViewMode,
100102
F as isEveryObjectValueEmpty,
101-
M as openConfirmPopUp,
102-
O as openDeleteConfirmPopUp,
103-
m as openPopUp,
104-
q as performDetailsActionHelper,
105-
I as roundFloats
103+
S as openConfirmPopUp,
104+
_ as openDeleteConfirmPopUp,
105+
p as openPopUp,
106+
H as performDetailsActionHelper,
107+
j as roundFloats
106108
};
107109
//# sourceMappingURL=common.util.mjs.map

0 commit comments

Comments
 (0)