@progress/kendo-react-gantt 7.2.4-develop.3 → 7.3.0-develop.1
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/Gantt.js +8 -0
- package/Gantt.mjs +411 -0
- package/cells/FilterCells/GanttBooleanFilter.js +8 -0
- package/cells/FilterCells/GanttBooleanFilter.mjs +27 -0
- package/cells/FilterCells/GanttDateFilter.js +8 -0
- package/cells/FilterCells/GanttDateFilter.mjs +27 -0
- package/cells/FilterCells/GanttNumericFilter.js +8 -0
- package/cells/FilterCells/GanttNumericFilter.mjs +27 -0
- package/cells/FilterCells/GanttTextFilter.js +8 -0
- package/cells/FilterCells/GanttTextFilter.mjs +27 -0
- package/cells/FilterCells/utils.js +8 -0
- package/cells/FilterCells/utils.mjs +59 -0
- package/components/BaseView.js +8 -0
- package/components/BaseView.mjs +239 -0
- package/components/GanttDependency.js +8 -0
- package/components/GanttDependency.mjs +58 -0
- package/components/GanttTask.js +8 -0
- package/components/GanttTask.mjs +169 -0
- package/components/GanttTreelist.js +8 -0
- package/components/GanttTreelist.mjs +571 -0
- package/components/toolbar/AddButton.js +8 -0
- package/components/toolbar/AddButton.mjs +56 -0
- package/components/toolbar/Toolbar.js +8 -0
- package/components/toolbar/Toolbar.mjs +34 -0
- package/components/toolbar/view-selector/ViewSelector.js +8 -0
- package/components/toolbar/view-selector/ViewSelector.mjs +32 -0
- package/components/toolbar/view-selector/ViewSelectorItem.js +8 -0
- package/components/toolbar/view-selector/ViewSelectorItem.mjs +39 -0
- package/components/toolbar/view-selector/ViewSelectorList.js +8 -0
- package/components/toolbar/view-selector/ViewSelectorList.mjs +36 -0
- package/constants/index.js +8 -0
- package/constants/index.mjs +52 -0
- package/context/GanttContext.js +8 -0
- package/context/GanttContext.mjs +103 -0
- package/context/GanttViewContext.js +8 -0
- package/context/GanttViewContext.mjs +38 -0
- package/dist/cdn/js/kendo-react-gantt.js +8 -5
- package/editors/FormDateTimePicker.js +8 -0
- package/editors/FormDateTimePicker.mjs +29 -0
- package/editors/FormDropDownList.js +8 -0
- package/editors/FormDropDownList.mjs +62 -0
- package/editors/FormInput.js +8 -0
- package/editors/FormInput.mjs +29 -0
- package/editors/FormNumericTextBox.js +8 -0
- package/editors/FormNumericTextBox.mjs +30 -0
- package/editors/GanttEditor.js +8 -0
- package/editors/GanttEditor.mjs +260 -0
- package/editors/GanttEditorPredecessors.js +8 -0
- package/editors/GanttEditorPredecessors.mjs +121 -0
- package/editors/GanttEditorSuccessors.js +8 -0
- package/editors/GanttEditorSuccessors.mjs +121 -0
- package/editors/GanttForm.js +8 -0
- package/editors/GanttForm.mjs +113 -0
- package/editors/GanttRemoveDialog.js +8 -0
- package/editors/GanttRemoveDialog.mjs +49 -0
- package/hooks/useControlledState.js +8 -0
- package/hooks/useControlledState.mjs +21 -0
- package/hooks/useDictionaryStore.js +8 -0
- package/hooks/useDictionaryStore.mjs +30 -0
- package/hooks/useGanttTask.js +8 -0
- package/hooks/useGanttTask.mjs +35 -0
- package/index.d.mts +1394 -5
- package/index.d.ts +1394 -32
- package/index.js +8 -5
- package/index.mjs +50 -3087
- package/interfaces/DependencyType.js +8 -0
- package/interfaces/DependencyType.mjs +12 -0
- package/messages/index.js +8 -0
- package/messages/index.mjs +137 -0
- package/package-metadata.js +8 -0
- package/package-metadata.mjs +19 -0
- package/package.json +12 -12
- package/rows/GanttRow.js +8 -0
- package/rows/GanttRow.mjs +13 -0
- package/utils/data-operations.js +8 -0
- package/utils/data-operations.mjs +183 -0
- package/utils/index.js +8 -0
- package/utils/index.mjs +263 -0
- package/views/GanttDayView.js +8 -0
- package/views/GanttDayView.mjs +94 -0
- package/views/GanttMonthView.js +8 -0
- package/views/GanttMonthView.mjs +82 -0
- package/views/GanttWeekView.js +8 -0
- package/views/GanttWeekView.mjs +81 -0
- package/views/GanttYearView.js +8 -0
- package/views/GanttYearView.mjs +73 -0
- package/Gantt.d.ts +0 -29
- package/cells/FilterCells/GanttBooleanFilter.d.ts +0 -14
- package/cells/FilterCells/GanttDateFilter.d.ts +0 -14
- package/cells/FilterCells/GanttNumericFilter.d.ts +0 -14
- package/cells/FilterCells/GanttTextFilter.d.ts +0 -14
- package/cells/FilterCells/utils.d.ts +0 -42
- package/components/BaseView.d.ts +0 -24
- package/components/GanttDependency.d.ts +0 -13
- package/components/GanttTask.d.ts +0 -16
- package/components/GanttTreelist.d.ts +0 -143
- package/components/toolbar/AddButton.d.ts +0 -16
- package/components/toolbar/Toolbar.d.ts +0 -25
- package/components/toolbar/view-selector/ViewSelector.d.ts +0 -28
- package/components/toolbar/view-selector/ViewSelectorItem.d.ts +0 -15
- package/components/toolbar/view-selector/ViewSelectorList.d.ts +0 -7
- package/constants/index.d.ts +0 -57
- package/context/GanttContext.d.ts +0 -125
- package/context/GanttViewContext.d.ts +0 -44
- package/editors/FormDateTimePicker.d.ts +0 -9
- package/editors/FormDropDownList.d.ts +0 -9
- package/editors/FormInput.d.ts +0 -9
- package/editors/FormNumericTextBox.d.ts +0 -9
- package/editors/GanttEditor.d.ts +0 -21
- package/editors/GanttEditorPredecessors.d.ts +0 -25
- package/editors/GanttEditorSuccessors.d.ts +0 -25
- package/editors/GanttForm.d.ts +0 -70
- package/editors/GanttRemoveDialog.d.ts +0 -48
- package/hooks/useControlledState.d.ts +0 -8
- package/hooks/useDictionaryStore.d.ts +0 -22
- package/hooks/useGanttTask.d.ts +0 -8
- package/interfaces/AddDirection.d.ts +0 -10
- package/interfaces/DataItem.d.ts +0 -10
- package/interfaces/DateRange.d.ts +0 -12
- package/interfaces/DependencyModelFields.d.ts +0 -29
- package/interfaces/DependencyType.d.ts +0 -19
- package/interfaces/GanttBaseProps.d.ts +0 -66
- package/interfaces/GanttCellProps.d.ts +0 -45
- package/interfaces/GanttColumnProps.d.ts +0 -40
- package/interfaces/GanttDependency.d.ts +0 -30
- package/interfaces/GanttDependencyModelFields.d.ts +0 -29
- package/interfaces/GanttFilterCellProps.d.ts +0 -10
- package/interfaces/GanttFilterOperator.d.ts +0 -10
- package/interfaces/GanttHeaderCellProps.d.ts +0 -10
- package/interfaces/GanttNoRecordsProps.d.ts +0 -13
- package/interfaces/GanttProps.d.ts +0 -151
- package/interfaces/GanttRowProps.d.ts +0 -95
- package/interfaces/GanttSelectableSettings.d.ts +0 -22
- package/interfaces/GanttSlotType.d.ts +0 -8
- package/interfaces/GanttSortSettings.d.ts +0 -17
- package/interfaces/GanttTaskModelFields.d.ts +0 -64
- package/interfaces/GanttView.d.ts +0 -80
- package/interfaces/GanttViewTimelineHeaderCellProps.d.ts +0 -23
- package/interfaces/Rectangle.d.ts +0 -10
- package/interfaces/Slot.d.ts +0 -16
- package/interfaces/TaskModelFields.d.ts +0 -20
- package/interfaces/events.d.ts +0 -298
- package/messages/index.d.ts +0 -194
- package/package-metadata.d.ts +0 -9
- package/rows/GanttRow.d.ts +0 -8
- package/utils/data-operations.d.ts +0 -47
- package/utils/index.d.ts +0 -182
- package/views/GanttDayView.d.ts +0 -21
- package/views/GanttMonthView.d.ts +0 -17
- package/views/GanttWeekView.d.ts +0 -17
- package/views/GanttYearView.d.ts +0 -17
package/Gantt.js
ADDED
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*-------------------------------------------------------------------------------------------
|
|
4
|
+
* Copyright © 2024 Progress Software Corporation. All rights reserved.
|
|
5
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
|
+
*-------------------------------------------------------------------------------------------
|
|
7
|
+
*/
|
|
8
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const Se=require("react"),n=require("prop-types"),M=require("./utils/index.js"),Te=require("@progress/kendo-react-intl"),Me=require("./context/GanttContext.js"),Ee=require("./views/GanttWeekView.js"),xe=require("@progress/kendo-react-treelist"),c=require("@progress/kendo-react-common"),Fe=require("./hooks/useControlledState.js"),Ie=require("./components/toolbar/view-selector/ViewSelectorList.js"),Ve=require("./components/toolbar/view-selector/ViewSelector.js"),qe=require("./components/toolbar/Toolbar.js"),He=require("@progress/kendo-react-buttons"),H=require("./constants/index.js"),z=require("./package-metadata.js"),ze=require("./components/toolbar/AddButton.js");function Ae(e){const k=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const d in e)if(d!=="default"){const h=Object.getOwnPropertyDescriptor(e,d);Object.defineProperty(k,d,h.get?h:{enumerable:!0,get:()=>e[d]})}}return k.default=e,Object.freeze(k)}const a=Ae(Se),y=a.forwardRef((e,k)=>{c.validatePackage(z.packageMetadata);const d=c.shouldShowValidationUI(z.packageMetadata),{columns:h=f.columns,taskData:E=f.taskData,dependencyData:A=f.dependencyData,style:N,className:G,noRecords:O,timezone:x,rowHeight:P=f.rowHeight,resizable:j,reorderable:K,sortable:L,sort:W,filter:_,columnMenuFilter:B,columnMenu:U,navigatable:$,toolbar:F,row:J,selectable:Q}=e,X=Te.useInternationalization(),{fields:o}=a.useMemo(()=>M.getTaskModelFields(e.taskModelFields),[e.taskModelFields]),{fields:Y}=a.useMemo(()=>M.getDependencyModelFields(e.dependencyModelFields),[e.dependencyModelFields]),I=a.useCallback(M.expandedChildren(o.isExpanded,o.children),[o.isExpanded,o.children]),D=a.useRef(null),r=a.useRef(null),i=a.useRef(null),m=a.useRef(null),s=a.useRef(null),Z=a.useCallback(t=>{const C=c.getter(o.start)(t),g=c.getter(o.end)(t),S=c.getter(o.isSelected)(t);(!r.current||C<r.current)&&(r.current=C),(!i.current||g>i.current)&&(i.current=g),S&&(m.current=t)},[o.start,o.end]),b=a.useMemo(()=>(r.current=null,i.current=null,m.current=null,xe.flatData(E,I,Z)),[E,I]);(!r.current||!i.current)&&(r.current=new Date(H.DEFAULT_DATE),i.current=new Date(H.DEFAULT_DATE));const R=a.Children.toArray(e.children||[a.createElement(Ee.GanttWeekView,{key:"week",firstSlotRangeRef:s})]),[V,p]=Fe.useControlledState(e.defaultView||R[0].props.name,e.view,e.onViewChange),u=R.find(t=>t.props.name===V)||R[0],ee=typeof u.props.dateRange=="function"?u.props.dateRange.call(void 0,{intl:X,tasksStart:r.current,tasksEnd:i.current,timezone:x}):u.props.dateRange,v=a.useRef(null),[ne,te]=a.useState(0);c.useIsomorphicLayoutEffect(()=>{v.current&&te(v.current.element.offsetHeight)},[]);const ae=a.useCallback(t=>{D.current&&D.current.scrollIntoView(t)},[]),q=a.useRef(null),l=a.useRef(null);a.useImperativeHandle(l,()=>({props:e,element:q.current,scrollIntoView:ae})),a.useImperativeHandle(k,()=>l.current);const le=a.useCallback(t=>{e.onDataStateChange&&e.onDataStateChange.call(void 0,{...t,target:l.current})},[e.onDataStateChange]),oe=a.useCallback(t=>{e.onSortChange&&e.onSortChange.call(void 0,{...t,target:l.current})},[e.onSortChange]),ce=a.useCallback(t=>{e.onKeyDown&&e.onKeyDown.call(void 0,{...t,target:l.current})},[e.onKeyDown]),re=a.useCallback(t=>{e.onSelectionChange&&e.onSelectionChange.call(void 0,{...t,target:l.current})},[e.onSelectionChange]),ie=a.useCallback(t=>{e.onHeaderSelectionChange&&e.onHeaderSelectionChange.call(void 0,{...t,target:l.current})},[e.onHeaderSelectionChange]),ue=a.useCallback(t=>{e.onFilterChange&&e.onFilterChange.call(void 0,{...t,target:l.current})},[e.onFilterChange]),de=a.useCallback(t=>{e.onColumnMenuFilterChange&&e.onColumnMenuFilterChange.call(void 0,{...t,target:l.current})},[e.onColumnMenuFilterChange]),se=a.useCallback(t=>{e.onExpandChange&&e.onExpandChange.call(void 0,{...t,target:l.current})},[e.onExpandChange]),Ce=a.useCallback(t=>{e.onAddClick&&e.onAddClick.call(void 0,{...t,target:l.current,selectedDataItem:m.current,slotStart:s.current&&new Date(s.current.start.getTime()),slotEnd:s.current&&new Date(s.current.end.getTime())})},[e.onAddClick]),ge=a.useCallback(t=>{e.onColumnResize&&e.onColumnResize.call(void 0,{...t,target:l.current})},[e.onColumnResize]),ke=a.useCallback(t=>{e.onColumnReorder&&e.onColumnReorder.call(void 0,{...t,target:l.current})},[e.onColumnReorder]),fe=a.useCallback(t=>{e.onRowClick&&e.onRowClick.call(void 0,{...t,target:l.current})},[e.onRowClick]),he=a.useCallback(t=>{e.onRowDoubleClick&&e.onRowDoubleClick.call(void 0,{...t,target:l.current})},[e.onRowClick]),me=a.useCallback(t=>{e.onRowContextMenu&&e.onRowContextMenu.call(void 0,{...t,target:l.current})},[e.onRowClick]),be=a.useCallback(t=>{e.onTaskClick&&e.onTaskClick.call(void 0,{...t,target:l.current})},[e.onTaskClick]),Re=a.useCallback(t=>{e.onTaskDoubleClick&&e.onTaskDoubleClick.call(void 0,{...t,target:l.current})},[e.onTaskDoubleClick]),we=a.useCallback(t=>{e.onTaskContextMenu&&e.onTaskContextMenu.call(void 0,{...t,target:l.current})},[e.onTaskContextMenu]),ye=a.useCallback(t=>{e.onTaskRemoveClick&&e.onTaskRemoveClick.call(void 0,{...t,target:l.current})},[e.onTaskRemoveClick]),De=a.useCallback(t=>{if(e.onDependencyCreate){let C,g;const S=c.getter(o.id);for(let T=0;T<b.length;T++){const ve=b[T],w=S(ve.dataItem);if(String(w)===t.fromId&&(C=w),String(w)===t.toId&&(g=w),C&&g)break}e.onDependencyCreate.call(void 0,{fromId:C,toId:g,target:l.current,type:t.type})}},[e.onDependencyCreate,o,b]);return a.createElement(Me.GanttContext,{dateRange:ee,taskData:b,dependencyData:A,taskModelFields:o,dependencyModelFields:Y,views:R,activeView:[V,p],rowHeight:P,toolbarHeight:ne,props:{columns:h,noRecords:O,timezone:x,resizable:j,reorderable:K,sortable:L,sort:W,filter:_,columnMenuFilter:B,columnMenu:U,navigatable:$,row:J,selectable:Q},events:{onDataStateChange:le,onSortChange:oe,onFilterChange:ue,onColumnMenuFilterChange:de,onExpandChange:se,onRowClick:fe,onRowDoubleClick:he,onRowContextMenu:me,onColumnResize:ge,onColumnReorder:ke,onDependencyCreate:e.onDependencyCreate&&De,onKeyDown:ce,onSelectionChange:re,onHeaderSelectionChange:ie},taskEvents:{onTaskClick:be,onTaskDoubleClick:Re,onTaskContextMenu:we,onTaskRemoveClick:e.onTaskRemoveClick&&ye}},a.createElement("div",{ref:q,role:"application",style:N,className:c.classNames("k-gantt",G)},a.createElement(qe.Toolbar,{ref:v},F&&F.addTaskButton?a.createElement(ze.AddButton,{selectedTask:m.current,onClick:Ce}):null,a.createElement(He.ToolbarSpacer,null),a.createElement(Ve.ViewSelector,null,a.createElement(Ie.ViewSelectorList,null))),u&&a.createElement(u.type,{key:u.props.name,ref:D,...u.props,firstSlotRangeRef:s}),d&&a.createElement(c.WatermarkOverlay,null)))}),f={taskData:[],dependencyData:[],columns:[],rowHeight:40};y.propTypes={taskData:n.array,taskModelFields:n.shape({id:n.string,start:n.string,end:n.string,title:n.string,percentComplete:n.string,parentId:n.string,isRollup:n.string,isExpanded:n.string,children:n.string,isInEdit:n.string}),dependencyData:n.array,dependencyModelFields:n.shape({id:n.string,fromId:n.string,toId:n.string,type:n.string}),columns:n.arrayOf(n.shape({width:n.number,cell:n.any,editCell:n.any,headerCell:n.any,filter:n.any,children:n.any,field:n.string,title:n.string,sortable:n.any,expandable:n.bool,headerSelectionValue:n.bool,format:n.string,headerClassName:n.string,className:n.string,resizable:n.bool,reorderable:n.bool,minResizableWidth:n.number,orderIndex:n.number,columnMenu:n.any})),sort:n.array,filter:n.array,columnMenuFilter:n.array,columnMenu:n.any,style:n.object,className:n.string,children:n.any,timezone:n.string,defaultView:n.string,view:n.string,rowHeight:n.number,navigatable:n.bool,onViewChange:n.func,onDataStateChange:n.func,onSortChange:n.func,onFilterChange:n.func,onExpandChange:n.func,onRowClick:n.func,onColumnResize:n.func,onColumnReorder:n.func};y.defaultProps=f;y.displayName="KendoReactGantt";exports.Gantt=y;
|
package/Gantt.mjs
ADDED
|
@@ -0,0 +1,411 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*-------------------------------------------------------------------------------------------
|
|
4
|
+
* Copyright © 2024 Progress Software Corporation. All rights reserved.
|
|
5
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
|
+
*-------------------------------------------------------------------------------------------
|
|
7
|
+
*/
|
|
8
|
+
"use client";
|
|
9
|
+
import * as a from "react";
|
|
10
|
+
import n from "prop-types";
|
|
11
|
+
import { getTaskModelFields as ve, getDependencyModelFields as Se, expandedChildren as Te } from "./utils/index.mjs";
|
|
12
|
+
import { useInternationalization as Me } from "@progress/kendo-react-intl";
|
|
13
|
+
import { GanttContext as Ee } from "./context/GanttContext.mjs";
|
|
14
|
+
import { GanttWeekView as xe } from "./views/GanttWeekView.mjs";
|
|
15
|
+
import { flatData as Fe } from "@progress/kendo-react-treelist";
|
|
16
|
+
import { validatePackage as Ie, shouldShowValidationUI as He, getter as h, useIsomorphicLayoutEffect as Ve, classNames as ze, WatermarkOverlay as Ae } from "@progress/kendo-react-common";
|
|
17
|
+
import { useControlledState as Ne } from "./hooks/useControlledState.mjs";
|
|
18
|
+
import { ViewSelectorList as Ke } from "./components/toolbar/view-selector/ViewSelectorList.mjs";
|
|
19
|
+
import { ViewSelector as Ge } from "./components/toolbar/view-selector/ViewSelector.mjs";
|
|
20
|
+
import { Toolbar as Le } from "./components/toolbar/Toolbar.mjs";
|
|
21
|
+
import { ToolbarSpacer as Pe } from "@progress/kendo-react-buttons";
|
|
22
|
+
import { DEFAULT_DATE as F } from "./constants/index.mjs";
|
|
23
|
+
import { packageMetadata as I } from "./package-metadata.mjs";
|
|
24
|
+
import { AddButton as We } from "./components/toolbar/AddButton.mjs";
|
|
25
|
+
const y = a.forwardRef((e, H) => {
|
|
26
|
+
Ie(I);
|
|
27
|
+
const V = He(I), {
|
|
28
|
+
columns: z = C.columns,
|
|
29
|
+
taskData: v = C.taskData,
|
|
30
|
+
dependencyData: A = C.dependencyData,
|
|
31
|
+
style: N,
|
|
32
|
+
className: K,
|
|
33
|
+
noRecords: G,
|
|
34
|
+
timezone: S,
|
|
35
|
+
rowHeight: L = C.rowHeight,
|
|
36
|
+
resizable: P,
|
|
37
|
+
reorderable: W,
|
|
38
|
+
sortable: B,
|
|
39
|
+
sort: O,
|
|
40
|
+
filter: U,
|
|
41
|
+
columnMenuFilter: j,
|
|
42
|
+
columnMenu: _,
|
|
43
|
+
navigatable: q,
|
|
44
|
+
toolbar: T,
|
|
45
|
+
row: J,
|
|
46
|
+
selectable: Q
|
|
47
|
+
} = e, X = Me(), { fields: o } = a.useMemo(() => ve(e.taskModelFields), [e.taskModelFields]), { fields: Y } = a.useMemo(() => Se(e.dependencyModelFields), [e.dependencyModelFields]), M = a.useCallback(
|
|
48
|
+
Te(o.isExpanded, o.children),
|
|
49
|
+
[o.isExpanded, o.children]
|
|
50
|
+
), R = a.useRef(null), r = a.useRef(null), c = a.useRef(null), g = a.useRef(null), d = a.useRef(null), Z = a.useCallback(
|
|
51
|
+
(t) => {
|
|
52
|
+
const u = h(o.start)(t), s = h(o.end)(t), w = h(o.isSelected)(t);
|
|
53
|
+
(!r.current || u < r.current) && (r.current = u), (!c.current || s > c.current) && (c.current = s), w && (g.current = t);
|
|
54
|
+
},
|
|
55
|
+
[o.start, o.end]
|
|
56
|
+
), m = a.useMemo(
|
|
57
|
+
() => (r.current = null, c.current = null, g.current = null, Fe(v, M, Z)),
|
|
58
|
+
[v, M]
|
|
59
|
+
);
|
|
60
|
+
(!r.current || !c.current) && (r.current = new Date(F), c.current = new Date(F));
|
|
61
|
+
const k = a.Children.toArray(
|
|
62
|
+
e.children || [/* @__PURE__ */ a.createElement(xe, { key: "week", firstSlotRangeRef: d })]
|
|
63
|
+
), [
|
|
64
|
+
E,
|
|
65
|
+
$
|
|
66
|
+
] = Ne(
|
|
67
|
+
e.defaultView || k[0].props.name,
|
|
68
|
+
e.view,
|
|
69
|
+
e.onViewChange
|
|
70
|
+
), i = k.find((t) => t.props.name === E) || k[0], p = typeof i.props.dateRange == "function" ? i.props.dateRange.call(void 0, {
|
|
71
|
+
intl: X,
|
|
72
|
+
tasksStart: r.current,
|
|
73
|
+
tasksEnd: c.current,
|
|
74
|
+
timezone: S
|
|
75
|
+
}) : i.props.dateRange, b = a.useRef(null), [ee, ne] = a.useState(0);
|
|
76
|
+
Ve(
|
|
77
|
+
() => {
|
|
78
|
+
b.current && ne(b.current.element.offsetHeight);
|
|
79
|
+
},
|
|
80
|
+
[]
|
|
81
|
+
);
|
|
82
|
+
const te = a.useCallback(
|
|
83
|
+
(t) => {
|
|
84
|
+
R.current && R.current.scrollIntoView(t);
|
|
85
|
+
},
|
|
86
|
+
[]
|
|
87
|
+
), x = a.useRef(null), l = a.useRef(null);
|
|
88
|
+
a.useImperativeHandle(l, () => ({ props: e, element: x.current, scrollIntoView: te })), a.useImperativeHandle(H, () => l.current);
|
|
89
|
+
const ae = a.useCallback(
|
|
90
|
+
(t) => {
|
|
91
|
+
e.onDataStateChange && e.onDataStateChange.call(
|
|
92
|
+
void 0,
|
|
93
|
+
{ ...t, target: l.current }
|
|
94
|
+
);
|
|
95
|
+
},
|
|
96
|
+
[e.onDataStateChange]
|
|
97
|
+
), le = a.useCallback(
|
|
98
|
+
(t) => {
|
|
99
|
+
e.onSortChange && e.onSortChange.call(
|
|
100
|
+
void 0,
|
|
101
|
+
{ ...t, target: l.current }
|
|
102
|
+
);
|
|
103
|
+
},
|
|
104
|
+
[e.onSortChange]
|
|
105
|
+
), oe = a.useCallback(
|
|
106
|
+
(t) => {
|
|
107
|
+
e.onKeyDown && e.onKeyDown.call(
|
|
108
|
+
void 0,
|
|
109
|
+
{ ...t, target: l.current }
|
|
110
|
+
);
|
|
111
|
+
},
|
|
112
|
+
[e.onKeyDown]
|
|
113
|
+
), re = a.useCallback(
|
|
114
|
+
(t) => {
|
|
115
|
+
e.onSelectionChange && e.onSelectionChange.call(
|
|
116
|
+
void 0,
|
|
117
|
+
{ ...t, target: l.current }
|
|
118
|
+
);
|
|
119
|
+
},
|
|
120
|
+
[e.onSelectionChange]
|
|
121
|
+
), ce = a.useCallback(
|
|
122
|
+
(t) => {
|
|
123
|
+
e.onHeaderSelectionChange && e.onHeaderSelectionChange.call(
|
|
124
|
+
void 0,
|
|
125
|
+
{ ...t, target: l.current }
|
|
126
|
+
);
|
|
127
|
+
},
|
|
128
|
+
[e.onHeaderSelectionChange]
|
|
129
|
+
), ie = a.useCallback(
|
|
130
|
+
(t) => {
|
|
131
|
+
e.onFilterChange && e.onFilterChange.call(
|
|
132
|
+
void 0,
|
|
133
|
+
{ ...t, target: l.current }
|
|
134
|
+
);
|
|
135
|
+
},
|
|
136
|
+
[e.onFilterChange]
|
|
137
|
+
), de = a.useCallback(
|
|
138
|
+
(t) => {
|
|
139
|
+
e.onColumnMenuFilterChange && e.onColumnMenuFilterChange.call(
|
|
140
|
+
void 0,
|
|
141
|
+
{ ...t, target: l.current }
|
|
142
|
+
);
|
|
143
|
+
},
|
|
144
|
+
[e.onColumnMenuFilterChange]
|
|
145
|
+
), ue = a.useCallback(
|
|
146
|
+
(t) => {
|
|
147
|
+
e.onExpandChange && e.onExpandChange.call(
|
|
148
|
+
void 0,
|
|
149
|
+
{ ...t, target: l.current }
|
|
150
|
+
);
|
|
151
|
+
},
|
|
152
|
+
[e.onExpandChange]
|
|
153
|
+
), se = a.useCallback(
|
|
154
|
+
(t) => {
|
|
155
|
+
e.onAddClick && e.onAddClick.call(
|
|
156
|
+
void 0,
|
|
157
|
+
{
|
|
158
|
+
...t,
|
|
159
|
+
target: l.current,
|
|
160
|
+
selectedDataItem: g.current,
|
|
161
|
+
slotStart: d.current && new Date(d.current.start.getTime()),
|
|
162
|
+
slotEnd: d.current && new Date(d.current.end.getTime())
|
|
163
|
+
}
|
|
164
|
+
);
|
|
165
|
+
},
|
|
166
|
+
[e.onAddClick]
|
|
167
|
+
), Ce = a.useCallback(
|
|
168
|
+
(t) => {
|
|
169
|
+
e.onColumnResize && e.onColumnResize.call(
|
|
170
|
+
void 0,
|
|
171
|
+
{
|
|
172
|
+
...t,
|
|
173
|
+
target: l.current
|
|
174
|
+
}
|
|
175
|
+
);
|
|
176
|
+
},
|
|
177
|
+
[e.onColumnResize]
|
|
178
|
+
), ge = a.useCallback(
|
|
179
|
+
(t) => {
|
|
180
|
+
e.onColumnReorder && e.onColumnReorder.call(
|
|
181
|
+
void 0,
|
|
182
|
+
{ ...t, target: l.current }
|
|
183
|
+
);
|
|
184
|
+
},
|
|
185
|
+
[e.onColumnReorder]
|
|
186
|
+
), me = a.useCallback(
|
|
187
|
+
(t) => {
|
|
188
|
+
e.onRowClick && e.onRowClick.call(
|
|
189
|
+
void 0,
|
|
190
|
+
{ ...t, target: l.current }
|
|
191
|
+
);
|
|
192
|
+
},
|
|
193
|
+
[e.onRowClick]
|
|
194
|
+
), ke = a.useCallback(
|
|
195
|
+
(t) => {
|
|
196
|
+
e.onRowDoubleClick && e.onRowDoubleClick.call(
|
|
197
|
+
void 0,
|
|
198
|
+
{ ...t, target: l.current }
|
|
199
|
+
);
|
|
200
|
+
},
|
|
201
|
+
[e.onRowClick]
|
|
202
|
+
), fe = a.useCallback(
|
|
203
|
+
(t) => {
|
|
204
|
+
e.onRowContextMenu && e.onRowContextMenu.call(
|
|
205
|
+
void 0,
|
|
206
|
+
{ ...t, target: l.current }
|
|
207
|
+
);
|
|
208
|
+
},
|
|
209
|
+
[e.onRowClick]
|
|
210
|
+
), he = a.useCallback(
|
|
211
|
+
(t) => {
|
|
212
|
+
e.onTaskClick && e.onTaskClick.call(
|
|
213
|
+
void 0,
|
|
214
|
+
{ ...t, target: l.current }
|
|
215
|
+
);
|
|
216
|
+
},
|
|
217
|
+
[e.onTaskClick]
|
|
218
|
+
), Re = a.useCallback(
|
|
219
|
+
(t) => {
|
|
220
|
+
e.onTaskDoubleClick && e.onTaskDoubleClick.call(
|
|
221
|
+
void 0,
|
|
222
|
+
{ ...t, target: l.current }
|
|
223
|
+
);
|
|
224
|
+
},
|
|
225
|
+
[e.onTaskDoubleClick]
|
|
226
|
+
), be = a.useCallback(
|
|
227
|
+
(t) => {
|
|
228
|
+
e.onTaskContextMenu && e.onTaskContextMenu.call(
|
|
229
|
+
void 0,
|
|
230
|
+
{ ...t, target: l.current }
|
|
231
|
+
);
|
|
232
|
+
},
|
|
233
|
+
[e.onTaskContextMenu]
|
|
234
|
+
), we = a.useCallback(
|
|
235
|
+
(t) => {
|
|
236
|
+
e.onTaskRemoveClick && e.onTaskRemoveClick.call(
|
|
237
|
+
void 0,
|
|
238
|
+
{ ...t, target: l.current }
|
|
239
|
+
);
|
|
240
|
+
},
|
|
241
|
+
[e.onTaskRemoveClick]
|
|
242
|
+
), De = a.useCallback(
|
|
243
|
+
(t) => {
|
|
244
|
+
if (e.onDependencyCreate) {
|
|
245
|
+
let u, s;
|
|
246
|
+
const w = h(o.id);
|
|
247
|
+
for (let D = 0; D < m.length; D++) {
|
|
248
|
+
const ye = m[D], f = w(ye.dataItem);
|
|
249
|
+
if (String(f) === t.fromId && (u = f), String(f) === t.toId && (s = f), u && s)
|
|
250
|
+
break;
|
|
251
|
+
}
|
|
252
|
+
e.onDependencyCreate.call(
|
|
253
|
+
void 0,
|
|
254
|
+
{
|
|
255
|
+
fromId: u,
|
|
256
|
+
toId: s,
|
|
257
|
+
target: l.current,
|
|
258
|
+
type: t.type
|
|
259
|
+
}
|
|
260
|
+
);
|
|
261
|
+
}
|
|
262
|
+
},
|
|
263
|
+
[e.onDependencyCreate, o, m]
|
|
264
|
+
);
|
|
265
|
+
return /* @__PURE__ */ a.createElement(
|
|
266
|
+
Ee,
|
|
267
|
+
{
|
|
268
|
+
dateRange: p,
|
|
269
|
+
taskData: m,
|
|
270
|
+
dependencyData: A,
|
|
271
|
+
taskModelFields: o,
|
|
272
|
+
dependencyModelFields: Y,
|
|
273
|
+
views: k,
|
|
274
|
+
activeView: [E, $],
|
|
275
|
+
rowHeight: L,
|
|
276
|
+
toolbarHeight: ee,
|
|
277
|
+
props: {
|
|
278
|
+
columns: z,
|
|
279
|
+
noRecords: G,
|
|
280
|
+
timezone: S,
|
|
281
|
+
resizable: P,
|
|
282
|
+
reorderable: W,
|
|
283
|
+
sortable: B,
|
|
284
|
+
sort: O,
|
|
285
|
+
filter: U,
|
|
286
|
+
columnMenuFilter: j,
|
|
287
|
+
columnMenu: _,
|
|
288
|
+
navigatable: q,
|
|
289
|
+
row: J,
|
|
290
|
+
selectable: Q
|
|
291
|
+
},
|
|
292
|
+
events: {
|
|
293
|
+
onDataStateChange: ae,
|
|
294
|
+
onSortChange: le,
|
|
295
|
+
onFilterChange: ie,
|
|
296
|
+
onColumnMenuFilterChange: de,
|
|
297
|
+
onExpandChange: ue,
|
|
298
|
+
onRowClick: me,
|
|
299
|
+
onRowDoubleClick: ke,
|
|
300
|
+
onRowContextMenu: fe,
|
|
301
|
+
onColumnResize: Ce,
|
|
302
|
+
onColumnReorder: ge,
|
|
303
|
+
onDependencyCreate: e.onDependencyCreate && De,
|
|
304
|
+
onKeyDown: oe,
|
|
305
|
+
onSelectionChange: re,
|
|
306
|
+
onHeaderSelectionChange: ce
|
|
307
|
+
},
|
|
308
|
+
taskEvents: {
|
|
309
|
+
onTaskClick: he,
|
|
310
|
+
onTaskDoubleClick: Re,
|
|
311
|
+
onTaskContextMenu: be,
|
|
312
|
+
onTaskRemoveClick: e.onTaskRemoveClick && we
|
|
313
|
+
}
|
|
314
|
+
},
|
|
315
|
+
/* @__PURE__ */ a.createElement(
|
|
316
|
+
"div",
|
|
317
|
+
{
|
|
318
|
+
ref: x,
|
|
319
|
+
role: "application",
|
|
320
|
+
style: N,
|
|
321
|
+
className: ze("k-gantt", K)
|
|
322
|
+
},
|
|
323
|
+
/* @__PURE__ */ a.createElement(Le, { ref: b }, T && T.addTaskButton ? /* @__PURE__ */ a.createElement(We, { selectedTask: g.current, onClick: se }) : null, /* @__PURE__ */ a.createElement(Pe, null), /* @__PURE__ */ a.createElement(Ge, null, /* @__PURE__ */ a.createElement(Ke, null))),
|
|
324
|
+
i && /* @__PURE__ */ a.createElement(
|
|
325
|
+
i.type,
|
|
326
|
+
{
|
|
327
|
+
key: i.props.name,
|
|
328
|
+
ref: R,
|
|
329
|
+
...i.props,
|
|
330
|
+
firstSlotRangeRef: d
|
|
331
|
+
}
|
|
332
|
+
),
|
|
333
|
+
V && /* @__PURE__ */ a.createElement(Ae, null)
|
|
334
|
+
)
|
|
335
|
+
);
|
|
336
|
+
}), C = {
|
|
337
|
+
taskData: [],
|
|
338
|
+
dependencyData: [],
|
|
339
|
+
columns: [],
|
|
340
|
+
rowHeight: 40
|
|
341
|
+
};
|
|
342
|
+
y.propTypes = {
|
|
343
|
+
taskData: n.array,
|
|
344
|
+
taskModelFields: n.shape({
|
|
345
|
+
id: n.string,
|
|
346
|
+
start: n.string,
|
|
347
|
+
end: n.string,
|
|
348
|
+
title: n.string,
|
|
349
|
+
percentComplete: n.string,
|
|
350
|
+
parentId: n.string,
|
|
351
|
+
isRollup: n.string,
|
|
352
|
+
isExpanded: n.string,
|
|
353
|
+
children: n.string,
|
|
354
|
+
isInEdit: n.string
|
|
355
|
+
}),
|
|
356
|
+
dependencyData: n.array,
|
|
357
|
+
dependencyModelFields: n.shape({
|
|
358
|
+
id: n.string,
|
|
359
|
+
fromId: n.string,
|
|
360
|
+
toId: n.string,
|
|
361
|
+
type: n.string
|
|
362
|
+
}),
|
|
363
|
+
columns: n.arrayOf(
|
|
364
|
+
n.shape({
|
|
365
|
+
width: n.number,
|
|
366
|
+
cell: n.any,
|
|
367
|
+
editCell: n.any,
|
|
368
|
+
headerCell: n.any,
|
|
369
|
+
filter: n.any,
|
|
370
|
+
children: n.any,
|
|
371
|
+
field: n.string,
|
|
372
|
+
title: n.string,
|
|
373
|
+
sortable: n.any,
|
|
374
|
+
expandable: n.bool,
|
|
375
|
+
headerSelectionValue: n.bool,
|
|
376
|
+
format: n.string,
|
|
377
|
+
headerClassName: n.string,
|
|
378
|
+
className: n.string,
|
|
379
|
+
resizable: n.bool,
|
|
380
|
+
reorderable: n.bool,
|
|
381
|
+
minResizableWidth: n.number,
|
|
382
|
+
orderIndex: n.number,
|
|
383
|
+
columnMenu: n.any
|
|
384
|
+
})
|
|
385
|
+
),
|
|
386
|
+
sort: n.array,
|
|
387
|
+
filter: n.array,
|
|
388
|
+
columnMenuFilter: n.array,
|
|
389
|
+
columnMenu: n.any,
|
|
390
|
+
style: n.object,
|
|
391
|
+
className: n.string,
|
|
392
|
+
children: n.any,
|
|
393
|
+
timezone: n.string,
|
|
394
|
+
defaultView: n.string,
|
|
395
|
+
view: n.string,
|
|
396
|
+
rowHeight: n.number,
|
|
397
|
+
navigatable: n.bool,
|
|
398
|
+
onViewChange: n.func,
|
|
399
|
+
onDataStateChange: n.func,
|
|
400
|
+
onSortChange: n.func,
|
|
401
|
+
onFilterChange: n.func,
|
|
402
|
+
onExpandChange: n.func,
|
|
403
|
+
onRowClick: n.func,
|
|
404
|
+
onColumnResize: n.func,
|
|
405
|
+
onColumnReorder: n.func
|
|
406
|
+
};
|
|
407
|
+
y.defaultProps = C;
|
|
408
|
+
y.displayName = "KendoReactGantt";
|
|
409
|
+
export {
|
|
410
|
+
y as Gantt
|
|
411
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*-------------------------------------------------------------------------------------------
|
|
4
|
+
* Copyright © 2024 Progress Software Corporation. All rights reserved.
|
|
5
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
|
+
*-------------------------------------------------------------------------------------------
|
|
7
|
+
*/
|
|
8
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("react"),c=require("@progress/kendo-react-data-tools"),n=require("./utils.js"),i=require("@progress/kendo-react-intl");function s(e){const o=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const r=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(o,t,r.get?r:{enumerable:!0,get:()=>e[t]})}}return o.default=e,Object.freeze(o)}const u=s(l),a=e=>{const{operators:o,...t}=e;return u.createElement(c.BooleanFilterCell,{ariaLabel:"boolean filter",...n.localizeFilter(i.useLocalization(),o||n.booleanFilterValues),...t})};a.displayName="KendoReactGanttBooleanFilter";exports.GanttBooleanFilter=a;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*-------------------------------------------------------------------------------------------
|
|
4
|
+
* Copyright © 2024 Progress Software Corporation. All rights reserved.
|
|
5
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
|
+
*-------------------------------------------------------------------------------------------
|
|
7
|
+
*/
|
|
8
|
+
"use client";
|
|
9
|
+
import * as r from "react";
|
|
10
|
+
import { BooleanFilterCell as a } from "@progress/kendo-react-data-tools";
|
|
11
|
+
import { localizeFilter as l, booleanFilterValues as i } from "./utils.mjs";
|
|
12
|
+
import { useLocalization as n } from "@progress/kendo-react-intl";
|
|
13
|
+
const m = (e) => {
|
|
14
|
+
const { operators: o, ...t } = e;
|
|
15
|
+
return /* @__PURE__ */ r.createElement(
|
|
16
|
+
a,
|
|
17
|
+
{
|
|
18
|
+
ariaLabel: "boolean filter",
|
|
19
|
+
...l(n(), o || i),
|
|
20
|
+
...t
|
|
21
|
+
}
|
|
22
|
+
);
|
|
23
|
+
};
|
|
24
|
+
m.displayName = "KendoReactGanttBooleanFilter";
|
|
25
|
+
export {
|
|
26
|
+
m as GanttBooleanFilter
|
|
27
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*-------------------------------------------------------------------------------------------
|
|
4
|
+
* Copyright © 2024 Progress Software Corporation. All rights reserved.
|
|
5
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
|
+
*-------------------------------------------------------------------------------------------
|
|
7
|
+
*/
|
|
8
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("react"),c=require("@progress/kendo-react-data-tools"),n=require("./utils.js"),i=require("@progress/kendo-react-intl");function s(e){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const a=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(r,t,a.get?a:{enumerable:!0,get:()=>e[t]})}}return r.default=e,Object.freeze(r)}const u=s(l),o=e=>{const{operators:r,...t}=e;return u.createElement(c.DateFilterCell,{ariaLabel:"date filter",...n.localizeFilter(i.useLocalization(),r||n.dateFilterOperators),...t})};o.displayName="KendoReactGanttDateFilter";exports.GanttDateFilter=o;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*-------------------------------------------------------------------------------------------
|
|
4
|
+
* Copyright © 2024 Progress Software Corporation. All rights reserved.
|
|
5
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
|
+
*-------------------------------------------------------------------------------------------
|
|
7
|
+
*/
|
|
8
|
+
"use client";
|
|
9
|
+
import * as a from "react";
|
|
10
|
+
import { DateFilterCell as o } from "@progress/kendo-react-data-tools";
|
|
11
|
+
import { localizeFilter as i, dateFilterOperators as l } from "./utils.mjs";
|
|
12
|
+
import { useLocalization as m } from "@progress/kendo-react-intl";
|
|
13
|
+
const s = (t) => {
|
|
14
|
+
const { operators: e, ...r } = t;
|
|
15
|
+
return /* @__PURE__ */ a.createElement(
|
|
16
|
+
o,
|
|
17
|
+
{
|
|
18
|
+
ariaLabel: "date filter",
|
|
19
|
+
...i(m(), e || l),
|
|
20
|
+
...r
|
|
21
|
+
}
|
|
22
|
+
);
|
|
23
|
+
};
|
|
24
|
+
s.displayName = "KendoReactGanttDateFilter";
|
|
25
|
+
export {
|
|
26
|
+
s as GanttDateFilter
|
|
27
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*-------------------------------------------------------------------------------------------
|
|
4
|
+
* Copyright © 2024 Progress Software Corporation. All rights reserved.
|
|
5
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
|
+
*-------------------------------------------------------------------------------------------
|
|
7
|
+
*/
|
|
8
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("react"),a=require("@progress/kendo-react-data-tools"),c=require("./utils.js"),l=require("@progress/kendo-react-intl");function u(e){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const n=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(r,t,n.get?n:{enumerable:!0,get:()=>e[t]})}}return r.default=e,Object.freeze(r)}const s=u(o),i=e=>{const{operators:r,...t}=e;return s.createElement(a.NumericFilterCell,{ariaLabel:"numeric filter",...c.localizeFilter(l.useLocalization(),r||c.numericFilterOperators),...t})};i.displayName="KendoReactGanttNumericFilter";exports.GanttNumericFilter=i;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*-------------------------------------------------------------------------------------------
|
|
4
|
+
* Copyright © 2024 Progress Software Corporation. All rights reserved.
|
|
5
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
|
+
*-------------------------------------------------------------------------------------------
|
|
7
|
+
*/
|
|
8
|
+
"use client";
|
|
9
|
+
import * as i from "react";
|
|
10
|
+
import { NumericFilterCell as o } from "@progress/kendo-react-data-tools";
|
|
11
|
+
import { localizeFilter as a, numericFilterOperators as l } from "./utils.mjs";
|
|
12
|
+
import { useLocalization as m } from "@progress/kendo-react-intl";
|
|
13
|
+
const c = (e) => {
|
|
14
|
+
const { operators: r, ...t } = e;
|
|
15
|
+
return /* @__PURE__ */ i.createElement(
|
|
16
|
+
o,
|
|
17
|
+
{
|
|
18
|
+
ariaLabel: "numeric filter",
|
|
19
|
+
...a(m(), r || l),
|
|
20
|
+
...t
|
|
21
|
+
}
|
|
22
|
+
);
|
|
23
|
+
};
|
|
24
|
+
c.displayName = "KendoReactGanttNumericFilter";
|
|
25
|
+
export {
|
|
26
|
+
c as GanttNumericFilter
|
|
27
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*-------------------------------------------------------------------------------------------
|
|
4
|
+
* Copyright © 2024 Progress Software Corporation. All rights reserved.
|
|
5
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
|
+
*-------------------------------------------------------------------------------------------
|
|
7
|
+
*/
|
|
8
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const l=require("react"),c=require("@progress/kendo-react-data-tools"),o=require("./utils.js"),i=require("@progress/kendo-react-intl");function s(e){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const t in e)if(t!=="default"){const n=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(r,t,n.get?n:{enumerable:!0,get:()=>e[t]})}}return r.default=e,Object.freeze(r)}const u=s(l),a=e=>{const{operators:r,...t}=e;return u.createElement(c.TextFilterCell,{ariaLabel:"text filter",...o.localizeFilter(i.useLocalization(),r||o.textFilterOperators),...t})};a.displayName="KendoReactGanttTextFilter";exports.GanttTextFilter=a;
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*-------------------------------------------------------------------------------------------
|
|
4
|
+
* Copyright © 2024 Progress Software Corporation. All rights reserved.
|
|
5
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
|
+
*-------------------------------------------------------------------------------------------
|
|
7
|
+
*/
|
|
8
|
+
"use client";
|
|
9
|
+
import * as o from "react";
|
|
10
|
+
import { TextFilterCell as a } from "@progress/kendo-react-data-tools";
|
|
11
|
+
import { localizeFilter as i, textFilterOperators as l } from "./utils.mjs";
|
|
12
|
+
import { useLocalization as m } from "@progress/kendo-react-intl";
|
|
13
|
+
const s = (t) => {
|
|
14
|
+
const { operators: e, ...r } = t;
|
|
15
|
+
return /* @__PURE__ */ o.createElement(
|
|
16
|
+
a,
|
|
17
|
+
{
|
|
18
|
+
ariaLabel: "text filter",
|
|
19
|
+
...i(m(), e || l),
|
|
20
|
+
...r
|
|
21
|
+
}
|
|
22
|
+
);
|
|
23
|
+
};
|
|
24
|
+
s.displayName = "KendoReactGanttTextFilter";
|
|
25
|
+
export {
|
|
26
|
+
s as GanttTextFilter
|
|
27
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*-------------------------------------------------------------------------------------------
|
|
4
|
+
* Copyright © 2024 Progress Software Corporation. All rights reserved.
|
|
5
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
|
+
*-------------------------------------------------------------------------------------------
|
|
7
|
+
*/
|
|
8
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("../../messages/index.js"),a=[{text:t.filterContainsOperator,operator:"contains"},{text:t.filterNotContainsOperator,operator:"doesnotcontain"},{text:t.filterEqOperator,operator:"eq"},{text:t.filterNotEqOperator,operator:"neq"},{text:t.filterStartsWithOperator,operator:"startswith"},{text:t.filterEndsWithOperator,operator:"endswith"},{text:t.filterIsNullOperator,operator:"isnull"},{text:t.filterIsNotNullOperator,operator:"isnotnull"},{text:t.filterIsEmptyOperator,operator:"isempty"},{text:t.filterIsNotEmptyOperator,operator:"isnotempty"}],l=[{text:t.filterEqOperator,operator:"eq"},{text:t.filterNotEqOperator,operator:"neq"},{text:t.filterGteOperator,operator:"gte"},{text:t.filterGtOperator,operator:"gt"},{text:t.filterLteOperator,operator:"lte"},{text:t.filterLtOperator,operator:"lt"},{text:t.filterIsNullOperator,operator:"isnull"},{text:t.filterIsNotNullOperator,operator:"isnotnull"}],i=[{text:t.filterEqOperator,operator:"eq"},{text:t.filterNotEqOperator,operator:"neq"},{text:t.filterAfterOrEqualOperator,operator:"gte"},{text:t.filterAfterOperator,operator:"gt"},{text:t.filterBeforeOperator,operator:"lt"},{text:t.filterBeforeOrEqualOperator,operator:"lte"},{text:t.filterIsNullOperator,operator:"isnull"},{text:t.filterIsNotNullOperator,operator:"isnotnull"}],p=[{text:t.filterBooleanAll,operator:""},{text:t.filterIsTrue,operator:!0},{text:t.filterIsFalse,operator:!1}];function s(r,o){return{clearButtonTitle:r.toLanguageString(t.filterClearButton,t.messages[t.filterClearButton]),operators:o.map(e=>({text:r.toLanguageString(e.text,t.messages[e.text]),operator:e.operator}))}}exports.booleanFilterValues=p;exports.dateFilterOperators=i;exports.localizeFilter=s;exports.numericFilterOperators=l;exports.textFilterOperators=a;
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license
|
|
3
|
+
*-------------------------------------------------------------------------------------------
|
|
4
|
+
* Copyright © 2024 Progress Software Corporation. All rights reserved.
|
|
5
|
+
* Licensed under commercial license. See LICENSE.md in the package root for more information
|
|
6
|
+
*-------------------------------------------------------------------------------------------
|
|
7
|
+
*/
|
|
8
|
+
"use client";
|
|
9
|
+
import { filterClearButton as p, messages as i, filterContainsOperator as s, filterNotContainsOperator as x, filterEqOperator as e, filterNotEqOperator as r, filterStartsWithOperator as f, filterEndsWithOperator as O, filterIsNullOperator as o, filterIsNotNullOperator as a, filterIsEmptyOperator as u, filterIsNotEmptyOperator as g, filterGteOperator as c, filterGtOperator as q, filterLteOperator as m, filterLtOperator as E, filterAfterOrEqualOperator as F, filterAfterOperator as I, filterBeforeOperator as N, filterBeforeOrEqualOperator as B, filterBooleanAll as d, filterIsTrue as h, filterIsFalse as y } from "../../messages/index.mjs";
|
|
10
|
+
const A = [
|
|
11
|
+
{ text: s, operator: "contains" },
|
|
12
|
+
{ text: x, operator: "doesnotcontain" },
|
|
13
|
+
{ text: e, operator: "eq" },
|
|
14
|
+
{ text: r, operator: "neq" },
|
|
15
|
+
{ text: f, operator: "startswith" },
|
|
16
|
+
{ text: O, operator: "endswith" },
|
|
17
|
+
{ text: o, operator: "isnull" },
|
|
18
|
+
{ text: a, operator: "isnotnull" },
|
|
19
|
+
{ text: u, operator: "isempty" },
|
|
20
|
+
{ text: g, operator: "isnotempty" }
|
|
21
|
+
], C = [
|
|
22
|
+
{ text: e, operator: "eq" },
|
|
23
|
+
{ text: r, operator: "neq" },
|
|
24
|
+
{ text: c, operator: "gte" },
|
|
25
|
+
{ text: q, operator: "gt" },
|
|
26
|
+
{ text: m, operator: "lte" },
|
|
27
|
+
{ text: E, operator: "lt" },
|
|
28
|
+
{ text: o, operator: "isnull" },
|
|
29
|
+
{ text: a, operator: "isnotnull" }
|
|
30
|
+
], S = [
|
|
31
|
+
{ text: e, operator: "eq" },
|
|
32
|
+
{ text: r, operator: "neq" },
|
|
33
|
+
{ text: F, operator: "gte" },
|
|
34
|
+
{ text: I, operator: "gt" },
|
|
35
|
+
{ text: N, operator: "lt" },
|
|
36
|
+
{ text: B, operator: "lte" },
|
|
37
|
+
{ text: o, operator: "isnull" },
|
|
38
|
+
{ text: a, operator: "isnotnull" }
|
|
39
|
+
], w = [
|
|
40
|
+
{ text: d, operator: "" },
|
|
41
|
+
{ text: h, operator: !0 },
|
|
42
|
+
{ text: y, operator: !1 }
|
|
43
|
+
];
|
|
44
|
+
function G(l, n) {
|
|
45
|
+
return {
|
|
46
|
+
clearButtonTitle: l.toLanguageString(p, i[p]),
|
|
47
|
+
operators: n.map((t) => ({
|
|
48
|
+
text: l.toLanguageString(t.text, i[t.text]),
|
|
49
|
+
operator: t.operator
|
|
50
|
+
}))
|
|
51
|
+
};
|
|
52
|
+
}
|
|
53
|
+
export {
|
|
54
|
+
w as booleanFilterValues,
|
|
55
|
+
S as dateFilterOperators,
|
|
56
|
+
G as localizeFilter,
|
|
57
|
+
C as numericFilterOperators,
|
|
58
|
+
A as textFilterOperators
|
|
59
|
+
};
|