@progress/kendo-react-scheduler
Version:
React Scheduler brings the functionality of Outlook's Calendar to a single UI component. KendoReact Scheduler package
32 lines (31 loc) • 954 B
JavaScript
/**
* @license
*-------------------------------------------------------------------------------------------
* Copyright © 2025 Progress Software Corporation. All rights reserved.
* Licensed under commercial license. See LICENSE.md in the package root for more information
*-------------------------------------------------------------------------------------------
*/
import { useControlledState as o } from "../../hooks/useControlledState.mjs";
var c = /* @__PURE__ */ ((e) => (e.reset = "SERIES_RESET", e.set = "SERIES_SET", e.toggle = "SERIES_TOGGLE", e))(c || {});
const u = (e, r) => {
switch (r.type) {
case "SERIES_RESET":
return null;
case "SERIES_SET":
return r.payload;
case "SERIES_TOGGLE":
return !e;
default:
return e;
}
}, a = (e, r, S) => {
const [s, t] = o(e, r, S);
return [s, t, (n) => {
const E = u(s, n);
t(E);
}];
};
export {
c as SERIES_ACTION,
a as useSeries
};