@addsign/moje-agenda-shared-lib 1.0.3 → 1.0.5
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/assets/tailwind.css +3 -10
- package/dist/components/SpinnerIcon.d.ts +1 -1
- package/dist/components/SpinnerIcon.js.map +1 -1
- package/dist/components/datatable/DataTableServer.js +31 -10
- package/dist/components/datatable/DataTableServer.js.map +1 -1
- package/dist/components/form/DateField.d.ts +1 -1
- package/dist/components/form/DateField.js +9 -16
- package/dist/components/form/DateField.js.map +1 -1
- package/dist/main.d.ts +1 -0
- package/dist/main.js +2 -0
- package/dist/main.js.map +1 -1
- package/dist/utils/handleErrors.js +7 -3
- package/dist/utils/handleErrors.js.map +1 -1
- package/package.json +1 -1
package/dist/assets/tailwind.css
CHANGED
|
@@ -940,6 +940,9 @@ video {
|
|
|
940
940
|
.min-w-\[100px\] {
|
|
941
941
|
min-width: 100px;
|
|
942
942
|
}
|
|
943
|
+
.min-w-\[120px\] {
|
|
944
|
+
min-width: 120px;
|
|
945
|
+
}
|
|
943
946
|
.min-w-\[180px\] {
|
|
944
947
|
min-width: 180px;
|
|
945
948
|
}
|
|
@@ -1788,9 +1791,6 @@ video {
|
|
|
1788
1791
|
font-size: 0.75rem;
|
|
1789
1792
|
line-height: 1rem;
|
|
1790
1793
|
}
|
|
1791
|
-
.\!font-normal {
|
|
1792
|
-
font-weight: 400 !important;
|
|
1793
|
-
}
|
|
1794
1794
|
.font-bold {
|
|
1795
1795
|
font-weight: 700;
|
|
1796
1796
|
}
|
|
@@ -2871,13 +2871,6 @@ video {
|
|
|
2871
2871
|
|
|
2872
2872
|
|
|
2873
2873
|
|
|
2874
|
-
.focus\:ring-indigo-200:focus {
|
|
2875
|
-
--tw-ring-opacity: 1;
|
|
2876
|
-
--tw-ring-color: rgb(199 210 254 / var(--tw-ring-opacity));
|
|
2877
|
-
}
|
|
2878
|
-
|
|
2879
|
-
|
|
2880
|
-
|
|
2881
2874
|
.focus\:ring-indigo-500:focus {
|
|
2882
2875
|
--tw-ring-opacity: 1;
|
|
2883
2876
|
--tw-ring-color: rgb(99 102 241 / var(--tw-ring-opacity));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SpinnerIcon.js","sources":["../../lib/components/SpinnerIcon.tsx"],"sourcesContent":["import React from \"react\";\nimport { FaSpinner } from \"react-icons/fa\";\n\ntype SpinnerIconProps = {\n icon
|
|
1
|
+
{"version":3,"file":"SpinnerIcon.js","sources":["../../lib/components/SpinnerIcon.tsx"],"sourcesContent":["import React from \"react\";\nimport { FaSpinner } from \"react-icons/fa\";\n\ntype SpinnerIconProps = {\n icon?: React.ReactNode;\n};\n\nconst SpinnerIcon: React.FC<SpinnerIconProps> = ({ icon = <FaSpinner /> }) => {\n return <div className=\"animate-spin\">{icon}</div>;\n};\n\nexport default SpinnerIcon;\n"],"names":[],"mappings":";;AAOA,MAAM,cAA0C,CAAC,EAAE,OAAQ,oBAAA,WAAA,CAAU,CAAA,QAAS;AAC5E,SAAQ,oBAAA,OAAA,EAAI,WAAU,gBAAgB,UAAK,KAAA,CAAA;AAC7C;"}
|
|
@@ -8,7 +8,7 @@ import InputField from "../form/InputField.js";
|
|
|
8
8
|
import SelectField from "../form/SelectField.js";
|
|
9
9
|
import Spinner from "../Spinner.js";
|
|
10
10
|
import DateRangeField from "../form/DateRangeField.js";
|
|
11
|
-
import "
|
|
11
|
+
import DateField from "../form/DateField.js";
|
|
12
12
|
import "../../contexts/FederationContext.js";
|
|
13
13
|
import { useFederationContext } from "../../contexts/useFederationContext.js";
|
|
14
14
|
import { handleErrors } from "../../utils/handleErrors.js";
|
|
@@ -21724,8 +21724,8 @@ function DataTableServer({
|
|
|
21724
21724
|
};
|
|
21725
21725
|
const [reloadData, setReloadData] = useState(false);
|
|
21726
21726
|
const mergedFilters = useMemo(() => {
|
|
21727
|
-
return { ...columnFilters, ...filters };
|
|
21728
|
-
}, [columnFilters, filters]);
|
|
21727
|
+
return showColFilters ? { ...columnFilters, ...filters } : filters || {};
|
|
21728
|
+
}, [columnFilters, filters, showColFilters]);
|
|
21729
21729
|
useEffect(() => {
|
|
21730
21730
|
setReloadData(true);
|
|
21731
21731
|
}, [
|
|
@@ -22007,7 +22007,7 @@ function DataTableServer({
|
|
|
22007
22007
|
"div",
|
|
22008
22008
|
{
|
|
22009
22009
|
className: "flex items-center text-xl h-full p-3 cursor-pointer text-gray-500 hover:text-black",
|
|
22010
|
-
title: "Filtrovat
|
|
22010
|
+
title: "Filtrovat sloupců",
|
|
22011
22011
|
onClick: handleToggleShowColFilters,
|
|
22012
22012
|
children: [
|
|
22013
22013
|
!showColFilters && /* @__PURE__ */ jsx(MdOutlineFilterAlt, {}),
|
|
@@ -22096,7 +22096,7 @@ function DataTableServer({
|
|
|
22096
22096
|
value: (mergedFilters == null ? void 0 : mergedFilters[String(filterParam)]) || "",
|
|
22097
22097
|
clearable: true,
|
|
22098
22098
|
className: " px-0",
|
|
22099
|
-
placeholder: "
|
|
22099
|
+
placeholder: "Zadejte filtr",
|
|
22100
22100
|
rounded: true,
|
|
22101
22101
|
disabled: Object.keys(
|
|
22102
22102
|
filters || {}
|
|
@@ -22113,21 +22113,42 @@ function DataTableServer({
|
|
|
22113
22113
|
e.target.value
|
|
22114
22114
|
),
|
|
22115
22115
|
type: filterType,
|
|
22116
|
-
options: filterOptions[String(filterParam)] || [],
|
|
22117
22116
|
value: {
|
|
22118
22117
|
startDate: (mergedFilters == null ? void 0 : mergedFilters[String(filterParam)]) || "",
|
|
22119
22118
|
endDate: (mergedFilters == null ? void 0 : mergedFilters[String(filterParam2)]) || ""
|
|
22120
22119
|
},
|
|
22121
22120
|
clearable: true,
|
|
22122
22121
|
className: " px-0 py-0 ",
|
|
22123
|
-
placeholder: "
|
|
22122
|
+
placeholder: "Zadejte filtr",
|
|
22123
|
+
rounded: true,
|
|
22124
|
+
disabled: Object.keys(
|
|
22125
|
+
filters || {}
|
|
22126
|
+
).includes(String(filterParam))
|
|
22127
|
+
},
|
|
22128
|
+
JSON.stringify(mergedFilters)
|
|
22129
|
+
) : filterType === "date" ? /* @__PURE__ */ jsx(
|
|
22130
|
+
DateField,
|
|
22131
|
+
{
|
|
22132
|
+
name: String(filterParam),
|
|
22133
|
+
onInputChange: (e) => filterHandler(
|
|
22134
|
+
e.target.name,
|
|
22135
|
+
e.target.value
|
|
22136
|
+
),
|
|
22137
|
+
type: filterType,
|
|
22138
|
+
value: {
|
|
22139
|
+
startDate: (mergedFilters == null ? void 0 : mergedFilters[String(filterParam)]) || "",
|
|
22140
|
+
endDate: (mergedFilters == null ? void 0 : mergedFilters[String(filterParam)]) || ""
|
|
22141
|
+
},
|
|
22142
|
+
clearable: true,
|
|
22143
|
+
className: " px-0 py-0 ",
|
|
22144
|
+
placeholder: "Zadejte filtr",
|
|
22124
22145
|
rounded: true,
|
|
22125
22146
|
disabled: Object.keys(
|
|
22126
22147
|
filters || {}
|
|
22127
22148
|
).includes(String(filterParam))
|
|
22128
22149
|
},
|
|
22129
22150
|
JSON.stringify(mergedFilters)
|
|
22130
|
-
) : /* @__PURE__ */ jsx(
|
|
22151
|
+
) : filterType === "text" ? /* @__PURE__ */ jsx(
|
|
22131
22152
|
InputField,
|
|
22132
22153
|
{
|
|
22133
22154
|
name: String(key) + "_filter",
|
|
@@ -22143,11 +22164,11 @@ function DataTableServer({
|
|
|
22143
22164
|
clearable: true,
|
|
22144
22165
|
className: " min-w-[100px] px-0 ",
|
|
22145
22166
|
rounded: true,
|
|
22146
|
-
placeholder: "
|
|
22167
|
+
placeholder: "Zadejte filtr",
|
|
22147
22168
|
debounceTimeout: 1e3
|
|
22148
22169
|
},
|
|
22149
22170
|
JSON.stringify(mergedFilters)
|
|
22150
|
-
)
|
|
22171
|
+
) : null
|
|
22151
22172
|
}
|
|
22152
22173
|
)
|
|
22153
22174
|
]
|