lkd-web-kit 0.3.5 → 0.3.8
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.cjs.js +118 -0
- package/dist/index.cjs10.js +16 -0
- package/dist/index.cjs11.js +16 -0
- package/dist/index.cjs12.js +16 -0
- package/dist/index.cjs13.js +16 -0
- package/dist/index.cjs14.js +118 -0
- package/dist/index.cjs15.js +16 -0
- package/dist/index.cjs16.js +19 -0
- package/dist/index.cjs17.js +70 -0
- package/dist/index.cjs18.js +14 -0
- package/dist/index.cjs19.js +66 -0
- package/dist/index.cjs2.js +43 -0
- package/dist/index.cjs20.js +21 -0
- package/dist/index.cjs21.js +30 -0
- package/dist/index.cjs22.js +23 -0
- package/dist/index.cjs23.js +15 -0
- package/dist/index.cjs24.js +16 -0
- package/dist/index.cjs25.js +16 -0
- package/dist/index.cjs26.js +18 -0
- package/dist/index.cjs27.js +17 -0
- package/dist/index.cjs28.js +17 -0
- package/dist/index.cjs29.js +17 -0
- package/dist/index.cjs3.js +12 -0
- package/dist/index.cjs30.js +17 -0
- package/dist/index.cjs31.js +17 -0
- package/dist/index.cjs32.js +17 -0
- package/dist/index.cjs33.js +17 -0
- package/dist/index.cjs34.js +17 -0
- package/dist/index.cjs35.js +29 -0
- package/dist/index.cjs36.js +17 -0
- package/dist/index.cjs37.js +17 -0
- package/dist/index.cjs38.js +51 -0
- package/dist/index.cjs39.js +38 -0
- package/dist/index.cjs4.js +40 -0
- package/dist/index.cjs40.js +15 -0
- package/dist/index.cjs41.js +23 -0
- package/dist/index.cjs42.js +39 -0
- package/dist/index.cjs43.js +24 -0
- package/dist/index.cjs44.js +14 -0
- package/dist/index.cjs45.js +19 -0
- package/dist/index.cjs46.js +43 -0
- package/dist/index.cjs47.js +14 -0
- package/dist/index.cjs48.js +20 -0
- package/dist/index.cjs49.js +11 -0
- package/dist/index.cjs5.js +54 -0
- package/dist/index.cjs50.js +45 -0
- package/dist/index.cjs51.js +19 -0
- package/dist/index.cjs52.js +24 -0
- package/dist/index.cjs53.js +7 -0
- package/dist/index.cjs54.js +65 -0
- package/dist/index.cjs6.js +19 -0
- package/dist/index.cjs7.js +19 -0
- package/dist/index.cjs8.js +17 -0
- package/dist/index.cjs9.js +16 -0
- package/dist/{main.d.ts → index.d.ts} +3 -3
- package/dist/index.es.js +52 -0
- package/dist/index.es10.js +12 -0
- package/dist/index.es11.js +12 -0
- package/dist/index.es12.js +12 -0
- package/dist/index.es13.js +12 -0
- package/dist/index.es14.js +114 -0
- package/dist/index.es15.js +12 -0
- package/dist/index.es16.js +15 -0
- package/dist/index.es17.js +66 -0
- package/dist/index.es18.js +10 -0
- package/dist/index.es19.js +60 -0
- package/dist/index.es2.js +39 -0
- package/dist/index.es20.js +16 -0
- package/dist/index.es21.js +26 -0
- package/dist/index.es22.js +19 -0
- package/dist/index.es23.js +11 -0
- package/dist/index.es24.js +12 -0
- package/dist/index.es25.js +12 -0
- package/dist/index.es26.js +14 -0
- package/dist/index.es27.js +13 -0
- package/dist/index.es28.js +13 -0
- package/dist/index.es29.js +13 -0
- package/dist/index.es3.js +8 -0
- package/dist/index.es30.js +13 -0
- package/dist/index.es31.js +13 -0
- package/dist/index.es32.js +13 -0
- package/dist/index.es33.js +13 -0
- package/dist/index.es34.js +13 -0
- package/dist/index.es35.js +23 -0
- package/dist/index.es36.js +13 -0
- package/dist/index.es37.js +13 -0
- package/dist/index.es38.js +47 -0
- package/dist/index.es39.js +34 -0
- package/dist/index.es4.js +36 -0
- package/dist/index.es40.js +11 -0
- package/dist/index.es41.js +19 -0
- package/dist/index.es42.js +35 -0
- package/dist/index.es43.js +20 -0
- package/dist/{src/mantine/breakpoints-with-px.js → index.es44.js} +4 -5
- package/dist/index.es45.js +15 -0
- package/dist/index.es46.js +39 -0
- package/dist/index.es47.js +10 -0
- package/dist/index.es48.js +15 -0
- package/dist/index.es49.js +7 -0
- package/dist/index.es5.js +50 -0
- package/dist/index.es50.js +40 -0
- package/dist/index.es51.js +15 -0
- package/dist/index.es52.js +20 -0
- package/dist/index.es53.js +3 -0
- package/dist/index.es54.js +63 -0
- package/dist/index.es6.js +15 -0
- package/dist/index.es7.js +15 -0
- package/dist/index.es8.js +13 -0
- package/dist/index.es9.js +12 -0
- package/dist/node_modules/@mantine/notifications/styles.css +42 -0
- package/package.json +15 -5
- package/dist/lkd-web-kit.css +0 -1
- package/dist/src/components/EmptyState/index.js +0 -36
- package/dist/src/components/Icon.js +0 -47
- package/dist/src/components/InfinityLoader/index.js +0 -9
- package/dist/src/components/MyDatePickerInput/CalendarIcon.js +0 -61
- package/dist/src/components/MyDatePickerInput/index.js +0 -14
- package/dist/src/components/MyDateTimePicker/index.js +0 -14
- package/dist/src/components/MyMonthPickerInput/index.js +0 -14
- package/dist/src/components/MyMultiSelect/index.js +0 -12
- package/dist/src/components/MyNotifications/index.js +0 -13
- package/dist/src/components/MyNumberInput/index.js +0 -12
- package/dist/src/components/MySelect/index.js +0 -12
- package/dist/src/components/MyTextInput/index.js +0 -12
- package/dist/src/components/MyTextarea/index.js +0 -12
- package/dist/src/components/MyTimeInput/index.js +0 -12
- package/dist/src/components/NavItems.js +0 -36
- package/dist/src/components/SelectInfinity/index.js +0 -106
- package/dist/src/consts/http-status.js +0 -4
- package/dist/src/consts/revalidate.js +0 -4
- package/dist/src/contexts/NavigationHistoryContext/index.js +0 -47
- package/dist/src/contexts/PageDataContext/index.js +0 -15
- package/dist/src/form/Form.js +0 -23
- package/dist/src/form/FormButtonSubmit.js +0 -18
- package/dist/src/form/base/FormCheckbox.js +0 -15
- package/dist/src/form/base/FormDatePickerInput.js +0 -21
- package/dist/src/form/base/FormDateTimePicker.js +0 -21
- package/dist/src/form/base/FormMonthPickerInput.js +0 -21
- package/dist/src/form/base/FormMultiSelect.js +0 -21
- package/dist/src/form/base/FormNumberInput.js +0 -21
- package/dist/src/form/base/FormRadioGroup.js +0 -14
- package/dist/src/form/base/FormSelect.js +0 -21
- package/dist/src/form/base/FormSelectInfinity.js +0 -21
- package/dist/src/form/base/FormTextInput.js +0 -21
- package/dist/src/form/base/FormTextarea.js +0 -21
- package/dist/src/form/base/FormTimeInput.js +0 -29
- package/dist/src/form/utils/nullable-but-required.js +0 -10
- package/dist/src/form/utils/optional-but-required.js +0 -10
- package/dist/src/form/utils/zodValidator.js +0 -9
- package/dist/src/hocs/withForm.js +0 -59
- package/dist/src/hocs/withModalManager.js +0 -29
- package/dist/src/hooks/useBreakpoint.js +0 -8
- package/dist/src/hooks/useFetchNextPageOnScroll.js +0 -19
- package/dist/src/hooks/useOnScrollProgress.js +0 -25
- package/dist/src/hooks/useUpdateSearchParams.js +0 -19
- package/dist/src/main.js +0 -113
- package/dist/src/mantine/my-default-theme.js +0 -39
- package/dist/src/mantine/to-tailwind-colors.js +0 -10
- package/dist/src/utils/array/groupBy.js +0 -36
- package/dist/src/utils/array/shuffleArray.js +0 -13
- package/dist/src/utils/formatBytes.js +0 -8
- package/dist/src/utils/isInfinityEmpty.js +0 -4
- package/dist/src/utils/ky/addBodyJsonHook.js +0 -12
- package/dist/src/utils/ky/parseJson.js +0 -6
- package/dist/src/utils/newHref.js +0 -20
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
"use client";
|
|
2
|
-
import { useSearchParams as c } from "next/navigation";
|
|
3
|
-
const i = () => {
|
|
4
|
-
const a = c();
|
|
5
|
-
return { updateSearchParams: (n) => {
|
|
6
|
-
var t;
|
|
7
|
-
const r = new URLSearchParams(a.toString());
|
|
8
|
-
Object.entries(n).forEach(([e, s]) => {
|
|
9
|
-
if (s === null) {
|
|
10
|
-
r.delete(e);
|
|
11
|
-
return;
|
|
12
|
-
}
|
|
13
|
-
r.set(e, String(s));
|
|
14
|
-
}), (t = window == null ? void 0 : window.history) == null || t.pushState(null, "", `?${r.toString()}`);
|
|
15
|
-
}, searchParams: a };
|
|
16
|
-
};
|
|
17
|
-
export {
|
|
18
|
-
i as useUpdateSearchParams
|
|
19
|
-
};
|
package/dist/src/main.js
DELETED
|
@@ -1,113 +0,0 @@
|
|
|
1
|
-
import { EmptyState as e } from "./components/EmptyState/index.js";
|
|
2
|
-
import { InfinityLoader as m } from "./components/InfinityLoader/index.js";
|
|
3
|
-
import { NavItems as f } from "./components/NavItems.js";
|
|
4
|
-
import { Icon as i } from "./components/Icon.js";
|
|
5
|
-
import { MyDatePickerInput as n } from "./components/MyDatePickerInput/index.js";
|
|
6
|
-
import { MyDateTimePicker as y } from "./components/MyDateTimePicker/index.js";
|
|
7
|
-
import { MyNotifications as s } from "./components/MyNotifications/index.js";
|
|
8
|
-
import { MyNumberInput as I } from "./components/MyNumberInput/index.js";
|
|
9
|
-
import { MySelect as d } from "./components/MySelect/index.js";
|
|
10
|
-
import { MyTextarea as P } from "./components/MyTextarea/index.js";
|
|
11
|
-
import { MyTextInput as T } from "./components/MyTextInput/index.js";
|
|
12
|
-
import { MyTimeInput as k } from "./components/MyTimeInput/index.js";
|
|
13
|
-
import { SelectInfinity as B } from "./components/SelectInfinity/index.js";
|
|
14
|
-
import { MyMultiSelect as g } from "./components/MyMultiSelect/index.js";
|
|
15
|
-
import { MyMonthPickerInput as v } from "./components/MyMonthPickerInput/index.js";
|
|
16
|
-
import { HttpStatus as R } from "./consts/http-status.js";
|
|
17
|
-
import { Revalidate as E } from "./consts/revalidate.js";
|
|
18
|
-
import { NavigationHistoryProvider as C, QP_BACK_URL_NAME as O, useNavigationHistory as _ } from "./contexts/NavigationHistoryContext/index.js";
|
|
19
|
-
import { PageDataProvider as J, usePageData as K } from "./contexts/PageDataContext/index.js";
|
|
20
|
-
import { Form as U } from "./form/Form.js";
|
|
21
|
-
import { FormButtonSubmit as G } from "./form/FormButtonSubmit.js";
|
|
22
|
-
import { zodValidator as V } from "./form/utils/zodValidator.js";
|
|
23
|
-
import { nullableButRequired as j } from "./form/utils/nullable-but-required.js";
|
|
24
|
-
import { optionalButRequired as Y } from "./form/utils/optional-but-required.js";
|
|
25
|
-
import { FormCheckbox as $ } from "./form/base/FormCheckbox.js";
|
|
26
|
-
import { FormDatePickerInput as or } from "./form/base/FormDatePickerInput.js";
|
|
27
|
-
import { FormDateTimePicker as tr } from "./form/base/FormDateTimePicker.js";
|
|
28
|
-
import { FormNumberInput as pr } from "./form/base/FormNumberInput.js";
|
|
29
|
-
import { FormRadioGroup as xr } from "./form/base/FormRadioGroup.js";
|
|
30
|
-
import { FormSelect as ar } from "./form/base/FormSelect.js";
|
|
31
|
-
import { FormSelectInfinity as ur } from "./form/base/FormSelectInfinity.js";
|
|
32
|
-
import { FormTextarea as lr } from "./form/base/FormTextarea.js";
|
|
33
|
-
import { FormTextInput as cr } from "./form/base/FormTextInput.js";
|
|
34
|
-
import { FormTimeInput as Mr, numberToTimeInput as dr, timeInputToNumber as Fr } from "./form/base/FormTimeInput.js";
|
|
35
|
-
import { FormMultiSelect as Sr } from "./form/base/FormMultiSelect.js";
|
|
36
|
-
import { FormMonthPickerInput as hr } from "./form/base/FormMonthPickerInput.js";
|
|
37
|
-
import { withForm as Nr } from "./hocs/withForm.js";
|
|
38
|
-
import { withModalManager as br } from "./hocs/withModalManager.js";
|
|
39
|
-
import { useBreakpoint as Dr } from "./hooks/useBreakpoint.js";
|
|
40
|
-
import { useFetchNextPageOnScroll as Hr } from "./hooks/useFetchNextPageOnScroll.js";
|
|
41
|
-
import { useOnScrollProgress as wr } from "./hooks/useOnScrollProgress.js";
|
|
42
|
-
import { useUpdateSearchParams as Ar } from "./hooks/useUpdateSearchParams.js";
|
|
43
|
-
import { breakpointsWithPx as Or } from "./mantine/breakpoints-with-px.js";
|
|
44
|
-
import { toTailwindColors as qr } from "./mantine/to-tailwind-colors.js";
|
|
45
|
-
import { myDefaultTheme as Kr } from "./mantine/my-default-theme.js";
|
|
46
|
-
import { formatBytes as Ur } from "./utils/formatBytes.js";
|
|
47
|
-
import { KyError as Gr, addBodyJsonHook as Qr } from "./utils/ky/addBodyJsonHook.js";
|
|
48
|
-
import { parseJSON as Wr } from "./utils/ky/parseJson.js";
|
|
49
|
-
import { groupBy as Xr, indexBy as Yr } from "./utils/array/groupBy.js";
|
|
50
|
-
import { shuffleArray as $r } from "./utils/array/shuffleArray.js";
|
|
51
|
-
import { newHref as oo } from "./utils/newHref.js";
|
|
52
|
-
import { isInfinityEmpty as to } from "./utils/isInfinityEmpty.js";
|
|
53
|
-
export {
|
|
54
|
-
e as EmptyState,
|
|
55
|
-
U as Form,
|
|
56
|
-
G as FormButtonSubmit,
|
|
57
|
-
$ as FormCheckbox,
|
|
58
|
-
or as FormDatePickerInput,
|
|
59
|
-
tr as FormDateTimePicker,
|
|
60
|
-
hr as FormMonthPickerInput,
|
|
61
|
-
Sr as FormMultiSelect,
|
|
62
|
-
pr as FormNumberInput,
|
|
63
|
-
xr as FormRadioGroup,
|
|
64
|
-
ar as FormSelect,
|
|
65
|
-
ur as FormSelectInfinity,
|
|
66
|
-
cr as FormTextInput,
|
|
67
|
-
lr as FormTextarea,
|
|
68
|
-
Mr as FormTimeInput,
|
|
69
|
-
R as HttpStatus,
|
|
70
|
-
i as Icon,
|
|
71
|
-
m as InfinityLoader,
|
|
72
|
-
Gr as KyError,
|
|
73
|
-
n as MyDatePickerInput,
|
|
74
|
-
y as MyDateTimePicker,
|
|
75
|
-
v as MyMonthPickerInput,
|
|
76
|
-
g as MyMultiSelect,
|
|
77
|
-
s as MyNotifications,
|
|
78
|
-
I as MyNumberInput,
|
|
79
|
-
d as MySelect,
|
|
80
|
-
T as MyTextInput,
|
|
81
|
-
P as MyTextarea,
|
|
82
|
-
k as MyTimeInput,
|
|
83
|
-
f as NavItems,
|
|
84
|
-
C as NavigationHistoryProvider,
|
|
85
|
-
J as PageDataProvider,
|
|
86
|
-
O as QP_BACK_URL_NAME,
|
|
87
|
-
E as Revalidate,
|
|
88
|
-
B as SelectInfinity,
|
|
89
|
-
Qr as addBodyJsonHook,
|
|
90
|
-
Or as breakpointsWithPx,
|
|
91
|
-
Ur as formatBytes,
|
|
92
|
-
Xr as groupBy,
|
|
93
|
-
Yr as indexBy,
|
|
94
|
-
to as isInfinityEmpty,
|
|
95
|
-
Kr as myDefaultTheme,
|
|
96
|
-
oo as newHref,
|
|
97
|
-
j as nullableButRequired,
|
|
98
|
-
dr as numberToTimeInput,
|
|
99
|
-
Y as optionalButRequired,
|
|
100
|
-
Wr as parseJSON,
|
|
101
|
-
$r as shuffleArray,
|
|
102
|
-
Fr as timeInputToNumber,
|
|
103
|
-
qr as toTailwindColors,
|
|
104
|
-
Dr as useBreakpoint,
|
|
105
|
-
Hr as useFetchNextPageOnScroll,
|
|
106
|
-
_ as useNavigationHistory,
|
|
107
|
-
wr as useOnScrollProgress,
|
|
108
|
-
K as usePageData,
|
|
109
|
-
Ar as useUpdateSearchParams,
|
|
110
|
-
Nr as withForm,
|
|
111
|
-
br as withModalManager,
|
|
112
|
-
V as zodValidator
|
|
113
|
-
};
|
|
@@ -1,39 +0,0 @@
|
|
|
1
|
-
import { Tooltip as e, Menu as t, Select as o, AppShell as l, Notification as i } from "@mantine/core";
|
|
2
|
-
import { breakpointsWithPx as p } from "./breakpoints-with-px.js";
|
|
3
|
-
const a = {
|
|
4
|
-
breakpoints: p,
|
|
5
|
-
cursorType: "pointer",
|
|
6
|
-
components: {
|
|
7
|
-
Notification: i.extend({
|
|
8
|
-
defaultProps: {
|
|
9
|
-
withBorder: !0
|
|
10
|
-
}
|
|
11
|
-
}),
|
|
12
|
-
AppShell: l.extend({
|
|
13
|
-
defaultProps: {
|
|
14
|
-
padding: 0
|
|
15
|
-
}
|
|
16
|
-
}),
|
|
17
|
-
Select: o.extend({
|
|
18
|
-
defaultProps: {
|
|
19
|
-
allowDeselect: !1,
|
|
20
|
-
withCheckIcon: !1,
|
|
21
|
-
clearable: !0
|
|
22
|
-
}
|
|
23
|
-
}),
|
|
24
|
-
Menu: t.extend({
|
|
25
|
-
defaultProps: {
|
|
26
|
-
position: "bottom-end"
|
|
27
|
-
}
|
|
28
|
-
}),
|
|
29
|
-
Tooltip: e.extend({
|
|
30
|
-
defaultProps: {
|
|
31
|
-
multiline: !0,
|
|
32
|
-
w: 300
|
|
33
|
-
}
|
|
34
|
-
})
|
|
35
|
-
}
|
|
36
|
-
};
|
|
37
|
-
export {
|
|
38
|
-
a as myDefaultTheme
|
|
39
|
-
};
|
|
@@ -1,36 +0,0 @@
|
|
|
1
|
-
function i(e, f, u) {
|
|
2
|
-
return u ? e.reduce(
|
|
3
|
-
(n, r) => {
|
|
4
|
-
const o = f(r);
|
|
5
|
-
return o === void 0 || (n[o] = u(r)), n;
|
|
6
|
-
},
|
|
7
|
-
{}
|
|
8
|
-
) : e.reduce(
|
|
9
|
-
(n, r) => {
|
|
10
|
-
const o = f(r);
|
|
11
|
-
return o === void 0 || (n[o] = r), n;
|
|
12
|
-
},
|
|
13
|
-
{}
|
|
14
|
-
);
|
|
15
|
-
}
|
|
16
|
-
const y = (e, f) => {
|
|
17
|
-
const u = {};
|
|
18
|
-
return e == null || e.forEach((n) => {
|
|
19
|
-
var o;
|
|
20
|
-
const r = f(n);
|
|
21
|
-
if (r !== null) {
|
|
22
|
-
if (Array.isArray(r)) {
|
|
23
|
-
r.forEach((t) => {
|
|
24
|
-
var s;
|
|
25
|
-
u[t] || (u[t] = []), (s = u[t]) == null || s.push(n);
|
|
26
|
-
});
|
|
27
|
-
return;
|
|
28
|
-
}
|
|
29
|
-
u[r] || (u[r] = []), (o = u[r]) == null || o.push(n);
|
|
30
|
-
}
|
|
31
|
-
}), u;
|
|
32
|
-
};
|
|
33
|
-
export {
|
|
34
|
-
y as groupBy,
|
|
35
|
-
i as indexBy
|
|
36
|
-
};
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { HTTPError as t } from "ky";
|
|
2
|
-
import { parseJSON as p } from "./parseJson.js";
|
|
3
|
-
class c extends t {
|
|
4
|
-
constructor(s, r, n, e) {
|
|
5
|
-
super(s, r, n), this.response.bodyJson = e;
|
|
6
|
-
}
|
|
7
|
-
}
|
|
8
|
-
const y = async (o) => (o.response.bodyJson = await p(o.response), o);
|
|
9
|
-
export {
|
|
10
|
-
c as KyError,
|
|
11
|
-
y as addBodyJsonHook
|
|
12
|
-
};
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import s from "query-string";
|
|
2
|
-
const m = (t) => (r) => {
|
|
3
|
-
const e = typeof t == "string" ? t : t(
|
|
4
|
-
r ?? {
|
|
5
|
-
params: {},
|
|
6
|
-
searchParams: {}
|
|
7
|
-
}
|
|
8
|
-
);
|
|
9
|
-
if (r != null && r.searchParams) {
|
|
10
|
-
const i = s.stringify(r.searchParams, {
|
|
11
|
-
skipEmptyString: !0,
|
|
12
|
-
skipNull: !0
|
|
13
|
-
});
|
|
14
|
-
return `${e}${i ? `?${i}` : ""}`;
|
|
15
|
-
}
|
|
16
|
-
return e;
|
|
17
|
-
};
|
|
18
|
-
export {
|
|
19
|
-
m as newHref
|
|
20
|
-
};
|