@progress/kendo-react-scheduler
Version:
React Scheduler brings the functionality of Outlook's Calendar to a single UI component. KendoReact Scheduler package
9 lines (8 loc) • 3.63 kB
JavaScript
/**
* @license
*-------------------------------------------------------------------------------------------
* Copyright © 2025 Progress Software Corporation. All rights reserved.
* Licensed under commercial license. See LICENSE.md in the package root for more information
*-------------------------------------------------------------------------------------------
*/
;Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const O=require("react"),c=require("../utils/index.js"),V=require("../constants/index.js"),p=require("@progress/kendo-date-math");function b(t){const o=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const n in t)if(n!=="default"){const r=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(o,n,r.get?r:{enumerable:!0,get:()=>t[n]})}}return o.default=t,Object.freeze(o)}const e=b(O),a=e.createContext({current:null}),R=()=>e.useContext(a);a.displayName="SchedulerElementContext";const u=e.createContext({}),A=()=>e.useContext(u);u.displayName="SchedulerPropsContext";const l=e.createContext([]),G=()=>e.useContext(l);l.displayName="SchedulerViewsContext";const d=e.createContext(c.defaultModelFields),j=()=>e.useContext(d);d.displayName="SchedulerFieldsContext";const s=e.createContext({dateFormat:"{0:D}",shortDateFormat:"{0:d}"}),q=()=>e.useContext(s);s.displayName="SchedulerDateFormatContext";const x=e.createContext([V.DEFAULT_GROUP]),M=()=>e.useContext(x);x.displayName="SchedulerGroupsContext";const C=e.createContext({start:new Date,end:new Date,zonedStart:p.ZonedDate.fromLocalDate(new Date),zonedEnd:p.ZonedDate.fromLocalDate(new Date)}),_=()=>e.useContext(C);C.displayName="SchedulerDateRangeContext";const i=e.createContext(null),z=()=>e.useContext(i);i.displayName="SchedulerOrientationContext";const S=e.createContext([new Date,c.noop]),I=()=>e.useContext(S);S.displayName="SchedulerDateContext";const h=e.createContext([[],c.noop]),L=()=>e.useContext(h);h.displayName="SchedulerDataContext";const m=e.createContext(["day",c.noop]),T=()=>e.useContext(m);m.displayName="SchedulerActiveViewContext";const D=e.createContext([null,()=>{}]);D.displayName="SchedulerItemSelectionContext";const k=({children:t,element:o,props:n,views:r,fields:v,groups:P,dateRange:E,dateFormat:y,orientation:w,date:F,data:f,activeView:N,selection:g})=>e.createElement(a.Provider,{value:o},e.createElement(u.Provider,{value:n},e.createElement(l.Provider,{value:r},e.createElement(d.Provider,{value:v},e.createElement(s.Provider,{value:y},e.createElement(x.Provider,{value:P},e.createElement(C.Provider,{value:E},e.createElement(i.Provider,{value:w},e.createElement(S.Provider,{value:F},e.createElement(h.Provider,{value:f},e.createElement(m.Provider,{value:N},e.createElement(D.Provider,{value:g},t))))))))))));exports.SchedulerActiveViewContext=m;exports.SchedulerContext=k;exports.SchedulerDataContext=h;exports.SchedulerDateContext=S;exports.SchedulerDateFormatContext=s;exports.SchedulerDateRangeContext=C;exports.SchedulerElementContext=a;exports.SchedulerFieldsContext=d;exports.SchedulerGroupsContext=x;exports.SchedulerItemSelectionContext=D;exports.SchedulerOrientationContext=i;exports.SchedulerPropsContext=u;exports.SchedulerViewsContext=l;exports.useSchedulerActiveViewContext=T;exports.useSchedulerDataContext=L;exports.useSchedulerDateContext=I;exports.useSchedulerDateFormatContext=q;exports.useSchedulerDateRangeContext=_;exports.useSchedulerElementContext=R;exports.useSchedulerFieldsContext=j;exports.useSchedulerGroupsContext=M;exports.useSchedulerOrientationContext=z;exports.useSchedulerPropsContext=A;exports.useSchedulerViewsContext=G;