@adatechnology/scheduling-ui 0.1.0-rc.2 → 0.1.0-rc.3
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.js +5 -4
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1008,8 +1008,9 @@ function AvailabilityExceptionsEditor({ resourceId, timezone }) {
|
|
|
1008
1008
|
const { data, isLoading, isError: isLoadError } = useAvailabilityExceptions(resourceId);
|
|
1009
1009
|
const addException = useAddAvailabilityException();
|
|
1010
1010
|
const removeException = useRemoveAvailabilityException();
|
|
1011
|
-
const
|
|
1012
|
-
const [
|
|
1011
|
+
const emptyValue = () => formatDateTimeLocalInTimeZone(/* @__PURE__ */ new Date(), timezone);
|
|
1012
|
+
const [from, setFrom] = useState3(emptyValue);
|
|
1013
|
+
const [until, setUntil] = useState3(emptyValue);
|
|
1013
1014
|
const [kind, setKind] = useState3(AVAILABILITY_EXCEPTION_KIND.BLOCK);
|
|
1014
1015
|
const [reason, setReason] = useState3("");
|
|
1015
1016
|
async function handleAdd() {
|
|
@@ -1024,8 +1025,8 @@ function AvailabilityExceptionsEditor({ resourceId, timezone }) {
|
|
|
1024
1025
|
kind,
|
|
1025
1026
|
...reason ? { reason } : {}
|
|
1026
1027
|
});
|
|
1027
|
-
setFrom(
|
|
1028
|
-
setUntil(
|
|
1028
|
+
setFrom(emptyValue());
|
|
1029
|
+
setUntil(emptyValue());
|
|
1029
1030
|
setReason("");
|
|
1030
1031
|
} catch {
|
|
1031
1032
|
}
|
package/package.json
CHANGED