@progress/kendo-react-orgchart 13.3.0-develop.9 → 13.4.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@progress/kendo-react-orgchart",
3
- "version": "13.3.0-develop.9",
3
+ "version": "13.4.0-develop.1",
4
4
  "description": "React OrgChart renders a message to the user with information about the status of an app process. KendoReact OrgChart package",
5
5
  "author": "Progress",
6
6
  "license": "SEE LICENSE IN LICENSE.md",
@@ -27,9 +27,9 @@
27
27
  "peerDependencies": {
28
28
  "@progress/kendo-data-query": "^1.7.2",
29
29
  "@progress/kendo-licensing": "^1.7.2",
30
- "@progress/kendo-react-buttons": "13.3.0-develop.9",
31
- "@progress/kendo-react-common": "13.3.0-develop.9",
32
- "@progress/kendo-react-layout": "13.3.0-develop.9",
30
+ "@progress/kendo-react-buttons": "13.4.0-develop.1",
31
+ "@progress/kendo-react-common": "13.4.0-develop.1",
32
+ "@progress/kendo-react-layout": "13.4.0-develop.1",
33
33
  "@progress/kendo-svg-icons": "^4.0.0",
34
34
  "react": "^16.8.2 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc",
35
35
  "react-dom": "^16.8.2 || ^17.0.0 || ^18.0.0 || ^19.0.0 || ^19.0.0-rc"
@@ -55,7 +55,7 @@
55
55
  "package": {
56
56
  "productName": "KendoReact",
57
57
  "productCode": "KENDOUIREACT",
58
- "publishDate": 1768491558,
58
+ "publishDate": 1770219192,
59
59
  "licensingDocsUrl": "https://www.telerik.com/kendo-react-ui/my-license/?utm_medium=product&utm_source=kendoreact&utm_campaign=kendo-ui-react-purchase-license-keys-warning"
60
60
  }
61
61
  },
@@ -0,0 +1,58 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2026 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ import { OrgChartOperationDescriptors } from './OrgChartOperationDescriptors.js';
9
+ /**
10
+ * A helper function which applies the specified operation descriptors to the data.
11
+ * * [Expanding and collapsing items](https://www.telerik.com/kendo-react-ui/components/treeview/expansion/update-expanded-items#toc-using-a-helper-function)
12
+ * * [Selecting and deselecting items](https://www.telerik.com/kendo-react-ui/components/treeview/selection/update-selected-items#toc-using-a-helper-function)
13
+ * * [Checking and unchecking items](https://www.telerik.com/kendo-react-ui/components/treeview/checkboxes/helper-functions)
14
+ *
15
+ * @param data - The data that will be processed.
16
+ * @param operations - The operation descriptors that will be applied to the data.
17
+ * @returns - The processed copy of the input data.
18
+ *
19
+ * @example
20
+ * ```jsx
21
+ * const App = () => {
22
+ * const [items, setItems] = React.useState(tree);
23
+ * const [expand, setExpand] = React.useState([]);
24
+ * const [select, setSelect] = React.useState([]);
25
+ * const [check, setCheck] = React.useState([]);
26
+ *
27
+ * const onExpandChange = (event) => {
28
+ * let newExpand = expand.slice();
29
+ * const index = newExpand.indexOf(event.itemHierarchicalIndex);
30
+ * index === -1 ? newExpand.push(event.itemHierarchicalIndex) : newExpand.splice(index, 1);
31
+ * setExpand(newExpand);
32
+ * }
33
+ *
34
+ * return (
35
+ * <OrgChart
36
+ * data={processOrgChartItems(items, { expand, select, check })}
37
+ * expandIcons={true} onExpandChange={onExpandChange} checkboxes={true}
38
+ * onCheckChange={event => setCheck([event.itemHierarchicalIndex])}
39
+ * onItemClick={event => setSelect([event.itemHierarchicalIndex])}
40
+ * />
41
+ * );
42
+ * }
43
+ *
44
+ * const tree = [{
45
+ * text: 'Item1',
46
+ * items: [
47
+ * { text: 'Item1.1' },
48
+ * { text: 'Item1.2' },
49
+ * { text: 'Item1.3', items: [{ text: 'Item1.3.1' }] }]
50
+ * }, {
51
+ * text: 'Item2', disabled: true,
52
+ * items: [{ text: 'Item2.1' }, { text: 'Item2.2' }, { text: 'Item2.3' }]
53
+ * }, {
54
+ * text: 'Item3'
55
+ * }];
56
+ * ```
57
+ */
58
+ export declare function processOrgChartItems(data: any[] | null | undefined, operations: OrgChartOperationDescriptors): any[];
@@ -5,7 +5,7 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- import { isArray as I, resolveItemsIds as g, updateItem as C, getNestedValue as E } from "@progress/kendo-react-common";
8
+ import { isArray as I, resolveItemsIds as g, getNestedValue as E, updateItem as C } from "@progress/kendo-react-common";
9
9
  import { EXPAND_FIELD as D, SELECT_FIELD as L, CHECK_FIELD as o, CHILDREN_FIELD as h, CHECK_INDETERMINATE_FIELD as N } from "./utils/consts.mjs";
10
10
  function a(n, t) {
11
11
  if (!n || !n.length)
@@ -0,0 +1,16 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2026 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ import { OrgChartProps } from '../client/ClientOrgChart.js';
9
+ import * as React from 'react';
10
+ /**
11
+ * @hidden
12
+ */
13
+ export declare const ServerGroupedOrgChart: {
14
+ (props: OrgChartProps): React.JSX.Element;
15
+ displayName: string;
16
+ };
@@ -5,4 +5,4 @@
5
5
  * Licensed under commercial license. See LICENSE.md in the package root for more information
6
6
  *-------------------------------------------------------------------------------------------
7
7
  */
8
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const B=require("react"),S=require("@progress/kendo-react-common"),$=require("./ServerOrgChartNode.js"),F=require("./ServerOrgChartGroup.js"),K=require("@progress/kendo-data-query"),n=require("../utils/consts.js");function Q(o){const I=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(o){for(const a in o)if(a!=="default"){const e=Object.getOwnPropertyDescriptor(o,a);Object.defineProperty(I,a,e.get?e:{enumerable:!0,get:()=>o[a]})}}return I.default=o,Object.freeze(I)}const b=Q(B),W=({dataByGroups:o,data:I=[],cardWidth:a,childrenField:e,idField:t,expandField:r,hasChildrenField:i,groupField:h,level:d=1,parentId:l=0})=>{I.forEach(s=>{const c=s[e];if(s[r]&&c&&c.length){const O=c.some(T=>T[e]&&T[e].length||i&&T[i]),f=O?"horizontal":"vertical",v=O?null:a+2*n.HORIZONTAL_GAP,E=o.find(T=>T.parentId===l),R=o.find(T=>T.ids.includes(l));let _=!1;if(E){const T=E.ids[0],x=R.items.find(G=>G[t]===T),N=R.items.find(G=>G[t]===s[t]);_=x[h]===N[h]}E&&_?(E.ids.push(s[t]),E.items=E.items.concat(c)):o.push({ids:[s[t]],items:c,level:d,parentId:l,hasChildren:O,orientation:f,width:v}),W({dataByGroups:o,data:s[e],childrenField:e,cardWidth:a,idField:t,expandField:r,hasChildrenField:i,groupField:h,level:d+1,parentId:s[t]})}})},J=(o,I)=>{const a=I||n.NODE_WIDTH,e=o.sort((t,r)=>r.level-t.level);e.forEach(t=>{if(!t.width){const r=e.filter(i=>t.ids.includes(i.parentId));if(r.length){const i=Math.max(...r.map(s=>s.width||0)),h=Math.max(...r.map(s=>s.groupedItems.length||0)),d=Math.max(...t.groupedItems.map(s=>{const c=t.orientation==="horizontal"?s.items.length:1;return c*(a+2*n.HORIZONTAL_GAP)+n.HORIZONTAL_GAP*(c-1)})),l=i*h+n.HORIZONTAL_GAP*(h-1);t.width=Math.max(l,d)}else{const i=Math.max(...t.groupedItems.map(h=>{const d=t.orientation==="horizontal"?h.items.length:1;return d*(a+2*n.HORIZONTAL_GAP)+n.HORIZONTAL_GAP*(d-1)}));t.width=i}}})},X=(o,I)=>{const a=o.sort((e,t)=>e.level-t.level);a.forEach(e=>{var c;if(e.level===0)return;const t=a.find(m=>m.ids.includes(e.parentId)),r=(t==null?void 0:t.groupedItems.findIndex(m=>m.items.some(O=>e.ids.includes(O[I]))))||0,i=(t==null?void 0:t.groupedItems)||[],h=t.width?(t.width-(i.length-1)*n.HORIZONTAL_GAP)/i.length:0;if(!e.left){let m=(t==null?void 0:t.left)||0;i.forEach((O,f)=>{f<r&&(m+=h+n.HORIZONTAL_GAP)}),e.left=m}const d=(t==null?void 0:t.width)||0,l=(t==null?void 0:t.groupedItems.length)||1,s=(d-(l-1)*n.HORIZONTAL_GAP)/l;if(e.width=s,t){const m=e.width-(e.width-(e.groupedItems.length-1)*n.HORIZONTAL_GAP)/e.groupedItems.length;t.childLineWidths?(c=t.childLineWidths)==null||c.push(m):t.childLineWidths=[m]}})},Y=(o,I,a,e,t)=>{const r=I||n.NODE_HEIGHT,i=t||n.VERTICAL_LINE,h=a+e+n.GROUP_PADDINGS;o.forEach(d=>{const l=d.level,s=(r+i+h)*l+n.VERTICAL_LINE*(l?l-1:0)-(i-n.VERTICAL_LINE)*(l?1:0);d.top=s})},tt=(o,I,a,e,t)=>{const r=I||n.NODE_HEIGHT,i=a||n.VERTICAL_LINE,d=(e||n.GROUP_TITLE_HEIGHT)+n.GROUP_SUBTITLE_HEIGHT+n.GROUP_PADDINGS;return Math.max(...o.map(s=>{const c=s.top||0,m=Math.max(...s.groupedItems.map(v=>v.items.length)),O=s.hasChildren?n.VERTICAL_LINE:0,f=s.orientation==="horizontal"?r+i+d+i+O:m*(r+i)+d+i;return c+f}))},y=o=>{const I={width:"100%",data:[],ariaLabel:"Org Chart",idField:"id",childrenField:"items",avatarField:"avatar",titleField:"title",subtitleField:"subtitle",expandField:"expanded",orientation:"horizontal",showAvatar:!0},{id:a,width:e,data:t,groupField:r,cardWidth:i,cardHeight:h,groupTitleHeight:d,groupSubtitleHeight:l,verticalLine:s,idField:c,childrenField:m,expandField:O,hasChildrenField:f,avatarField:v,titleField:E,subtitleField:R,cardsColors:_,ariaLabel:T,itemRender:x,groupTitleRender:N,groupSubtitleRender:G,height:D,avatarType:k,showAvatar:M}={...I,...o},p=[{items:t,level:0,hasChildren:!0,orientation:"horizontal",ids:[0],parentId:null,width:null}];W({dataByGroups:p,data:t,cardWidth:i,expandField:O,hasChildrenField:f,childrenField:m,idField:c,groupField:r}),p.map(u=>{u.groupedItems=K.groupBy(u.items,[{field:r}])}),J(p,i),X(p,c),Y(p,h||n.NODE_HEIGHT,d||n.GROUP_TITLE_HEIGHT,l||n.GROUP_SUBTITLE_HEIGHT,s);const U=tt(p,h||n.NODE_HEIGHT,d||n.GROUP_TITLE_HEIGHT,l||n.GROUP_SUBTITLE_HEIGHT);return b.createElement("div",{className:"k-orgchart-container",style:{width:e,height:D||U}},p.map(u=>{const H=u.level,w=u.groupedItems.map(L=>{const C=L.items.some(A=>A[O]);return{...L,expanded:C}}),Z=w.filter(L=>L.expanded),P="horizontal",z=_&&_[H]||"green";return b.createElement("div",{role:H===0?"tree":"group",id:a+"-"+H+"-"+u.ids[0],"aria-label":H===0?T:void 0,"aria-orientation":H===0?P:void 0,key:u.ids[0]+"_"+H,className:S.classNames("k-orgchart-group",`k-orgchart-level-${H}`,"k-pos-absolute",{[`k-${S.kendoThemeMaps.orientationMap[P]}`]:P}),style:{width:u.width||"100%",left:u.left,top:u.top}},t.length>0&&w.map((L,C)=>{const A=L.items.some(g=>g[m]&&g[m].length||f&&g[f]),q=u.width?(u.width-(w.length-1)*n.HORIZONTAL_GAP)/w.length:void 0,V=Z.findIndex(g=>g===L);return b.createElement(F.ServerOrgChartGroup,{id:a+"-"+(H+1)+"-"+L.items[0][c],style:{width:q},groupTitleHeight:d,groupSubtitleHeight:l,groupTitleRender:N,groupSubtitleRender:G,key:C,level:H,verticalLine:s||n.VERTICAL_LINE,title:L.items[0][r||E],subtitle:r,orientation:u.orientation,childLineWidth:A&&L.expanded&&u.orientation==="horizontal"?u.childLineWidths[V]:0,line:A,nodes:L.items,expanded:L.expanded,plus:A},L.items.map((g,j)=>b.createElement($.ServerOrgChartNode,{cardHeight:h,cardWidth:i,itemRender:x,color:z,key:j,level:H,avatar:g[v],avatarType:k,showAvatar:M,title:g[E],subtitle:g[R],verticalLine:0,line:!1,node:g,childLineWidth:0,plus:!1},g.text)))}))}))};y.displayName="KendoServerGroupedOrgChart";exports.ServerGroupedOrgChart=y;
8
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const B=require("react"),C=require("@progress/kendo-react-common"),$=require("./ServerOrgChartNode.js"),F=require("./ServerOrgChartGroup.js"),K=require("@progress/kendo-data-query"),n=require("../utils/consts.js");function Q(o){const I=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(o){for(const a in o)if(a!=="default"){const e=Object.getOwnPropertyDescriptor(o,a);Object.defineProperty(I,a,e.get?e:{enumerable:!0,get:()=>o[a]})}}return I.default=o,Object.freeze(I)}const b=Q(B),W=({dataByGroups:o,data:I=[],cardWidth:a,childrenField:e,idField:t,expandField:r,hasChildrenField:i,groupField:h,level:d=1,parentId:l=0})=>{I.forEach(s=>{const c=s[e];if(s[r]&&c&&c.length){const g=c.some(O=>O[e]&&O[e].length||i&&O[i]),H=g?"horizontal":"vertical",_=g?null:a+2*n.HORIZONTAL_GAP,p=o.find(O=>O.parentId===l),R=o.find(O=>O.ids.includes(l));let E=!1;if(p){const O=p.ids[0],x=R.items.find(G=>G[t]===O),P=R.items.find(G=>G[t]===s[t]);E=x[h]===P[h]}p&&E?(p.ids.push(s[t]),p.items=p.items.concat(c)):o.push({ids:[s[t]],items:c,level:d,parentId:l,hasChildren:g,orientation:H,width:_}),W({dataByGroups:o,data:s[e],childrenField:e,cardWidth:a,idField:t,expandField:r,hasChildrenField:i,groupField:h,level:d+1,parentId:s[t]})}})},J=(o,I)=>{const a=I||n.NODE_WIDTH,e=o.sort((t,r)=>r.level-t.level);e.forEach(t=>{if(!t.width){const r=e.filter(i=>t.ids.includes(i.parentId));if(r.length){const i=Math.max(...r.map(s=>s.width||0)),h=Math.max(...r.map(s=>s.groupedItems.length||0)),d=Math.max(...t.groupedItems.map(s=>{const c=t.orientation==="horizontal"?s.items.length:1;return c*(a+2*n.HORIZONTAL_GAP)+n.HORIZONTAL_GAP*(c-1)})),l=i*h+n.HORIZONTAL_GAP*(h-1);t.width=Math.max(l,d)}else{const i=Math.max(...t.groupedItems.map(h=>{const d=t.orientation==="horizontal"?h.items.length:1;return d*(a+2*n.HORIZONTAL_GAP)+n.HORIZONTAL_GAP*(d-1)}));t.width=i}}})},X=(o,I)=>{const a=o.sort((e,t)=>e.level-t.level);a.forEach(e=>{var c;if(e.level===0)return;const t=a.find(m=>m.ids.includes(e.parentId)),r=(t==null?void 0:t.groupedItems.findIndex(m=>m.items.some(g=>e.ids.includes(g[I]))))||0,i=(t==null?void 0:t.groupedItems)||[],h=t.width?(t.width-(i.length-1)*n.HORIZONTAL_GAP)/i.length:0;if(!e.left){let m=(t==null?void 0:t.left)||0;i.forEach((g,H)=>{H<r&&(m+=h+n.HORIZONTAL_GAP)}),e.left=m}const d=(t==null?void 0:t.width)||0,l=(t==null?void 0:t.groupedItems.length)||1,s=(d-(l-1)*n.HORIZONTAL_GAP)/l;if(e.width=s,t){const m=e.width-(e.width-(e.groupedItems.length-1)*n.HORIZONTAL_GAP)/e.groupedItems.length;t.childLineWidths?(c=t.childLineWidths)==null||c.push(m):t.childLineWidths=[m]}})},Y=(o,I,a,e,t)=>{const r=I,i=t||n.VERTICAL_LINE,h=a+e+n.GROUP_PADDINGS;o.forEach(d=>{const l=d.level,s=(r+i+h)*l+n.VERTICAL_LINE*(l?l-1:0)-(i-n.VERTICAL_LINE)*(l?1:0);d.top=s})},tt=(o,I,a,e,t)=>{const r=I,i=a,d=e+n.GROUP_SUBTITLE_HEIGHT+n.GROUP_PADDINGS;return Math.max(...o.map(s=>{const c=s.top||0,m=Math.max(...s.groupedItems.map(_=>_.items.length)),g=s.hasChildren?n.VERTICAL_LINE:0,H=s.orientation==="horizontal"?r+i+d+i+g:m*(r+i)+d+i;return c+H}))},y=o=>{const I={width:"100%",data:[],ariaLabel:"Org Chart",idField:"id",childrenField:"items",avatarField:"avatar",titleField:"title",subtitleField:"subtitle",expandField:"expanded",orientation:"horizontal",showAvatar:!0},{id:a,width:e,data:t,groupField:r,cardWidth:i,cardHeight:h,groupTitleHeight:d,groupSubtitleHeight:l,verticalLine:s,idField:c,childrenField:m,expandField:g,hasChildrenField:H,avatarField:_,titleField:p,subtitleField:R,cardsColors:E,ariaLabel:O,itemRender:x,groupTitleRender:P,groupSubtitleRender:G,height:k,avatarType:D,showAvatar:M}={...I,...o},v=[{items:t,level:0,hasChildren:!0,orientation:"horizontal",ids:[0],parentId:null,width:null}];W({dataByGroups:v,data:t,cardWidth:i,expandField:g,hasChildrenField:H,childrenField:m,idField:c,groupField:r}),v.map(u=>{u.groupedItems=K.groupBy(u.items,[{field:r}])}),J(v,i),X(v,c),Y(v,h||n.NODE_HEIGHT,d||n.GROUP_TITLE_HEIGHT,l||n.GROUP_SUBTITLE_HEIGHT,s);const Z=tt(v,h||n.NODE_HEIGHT,d||n.GROUP_TITLE_HEIGHT,l||n.GROUP_SUBTITLE_HEIGHT);return b.createElement("div",{className:"k-orgchart-container",style:{width:e,height:k||Z}},v.map(u=>{const T=u.level,w=u.groupedItems.map(L=>{const S=L.items.some(A=>A[g]);return{...L,expanded:S}}),U=w.filter(L=>L.expanded),N="horizontal",z=E&&E[T]||"green";return b.createElement("div",{role:T===0?"tree":"group",id:a+"-"+T+"-"+u.ids[0],"aria-label":T===0?O:void 0,"aria-orientation":T===0?N:void 0,key:u.ids[0]+"_"+T,className:C.classNames("k-orgchart-group",`k-orgchart-level-${T}`,"k-pos-absolute",{[`k-${C.kendoThemeMaps.orientationMap[N]}`]:N}),style:{width:u.width||"100%",left:u.left,top:u.top}},t.length>0&&w.map((L,S)=>{const A=L.items.some(f=>f[m]&&f[m].length||H&&f[H]),q=u.width?(u.width-(w.length-1)*n.HORIZONTAL_GAP)/w.length:void 0,j=U.findIndex(f=>f===L);return b.createElement(F.ServerOrgChartGroup,{id:a+"-"+(T+1)+"-"+L.items[0][c],style:{width:q},groupTitleHeight:d,groupSubtitleHeight:l,groupTitleRender:P,groupSubtitleRender:G,key:S,level:T,verticalLine:s||n.VERTICAL_LINE,title:L.items[0][r||p],subtitle:r,orientation:u.orientation,childLineWidth:A&&L.expanded&&u.orientation==="horizontal"?u.childLineWidths[j]:0,line:A,nodes:L.items,expanded:L.expanded,plus:A},L.items.map((f,V)=>b.createElement($.ServerOrgChartNode,{cardHeight:h,cardWidth:i,itemRender:x,color:z,key:V,level:T,avatar:f[_],avatarType:D,showAvatar:M,title:f[p],subtitle:f[R],verticalLine:0,line:!1,node:f,childLineWidth:0,plus:!1},f.text)))}))}))};y.displayName="KendoServerGroupedOrgChart";exports.ServerGroupedOrgChart=y;
@@ -10,7 +10,7 @@ import { classNames as q, kendoThemeMaps as J } from "@progress/kendo-react-comm
10
10
  import { ServerOrgChartNode as Q } from "./ServerOrgChartNode.mjs";
11
11
  import { ServerOrgChartGroup as X } from "./ServerOrgChartGroup.mjs";
12
12
  import { groupBy as Y } from "@progress/kendo-data-query";
13
- import { HORIZONTAL_GAP as v, VERTICAL_LINE as b, NODE_WIDTH as tt, NODE_HEIGHT as S, GROUP_PADDINGS as D, GROUP_TITLE_HEIGHT as z, GROUP_SUBTITLE_HEIGHT as A } from "../utils/consts.mjs";
13
+ import { HORIZONTAL_GAP as v, VERTICAL_LINE as G, NODE_WIDTH as tt, GROUP_PADDINGS as D, GROUP_SUBTITLE_HEIGHT as M, GROUP_TITLE_HEIGHT as z, NODE_HEIGHT as A } from "../utils/consts.mjs";
14
14
  const P = ({
15
15
  dataByGroups: m,
16
16
  data: u = [],
@@ -28,20 +28,20 @@ const P = ({
28
28
  if (n[s] && h && h.length) {
29
29
  const I = h.some(
30
30
  (g) => g[e] && g[e].length || i && g[i]
31
- ), x = I ? "horizontal" : "vertical", E = I ? null : r + 2 * v, L = m.find((g) => g.parentId === a), C = m.find((g) => g.ids.includes(a));
32
- let T = !1;
31
+ ), x = I ? "horizontal" : "vertical", b = I ? null : r + 2 * v, L = m.find((g) => g.parentId === a), C = m.find((g) => g.ids.includes(a));
32
+ let E = !1;
33
33
  if (L) {
34
- const g = L.ids[0], k = C.items.find((W) => W[t] === g), _ = C.items.find((W) => W[t] === n[t]);
35
- T = k[d] === _[d];
34
+ const g = L.ids[0], S = C.items.find((T) => T[t] === g), k = C.items.find((T) => T[t] === n[t]);
35
+ E = S[d] === k[d];
36
36
  }
37
- L && T ? (L.ids.push(n[t]), L.items = L.items.concat(h)) : m.push({
37
+ L && E ? (L.ids.push(n[t]), L.items = L.items.concat(h)) : m.push({
38
38
  ids: [n[t]],
39
39
  items: h,
40
40
  level: o,
41
41
  parentId: a,
42
42
  hasChildren: I,
43
43
  orientation: x,
44
- width: E
44
+ width: b
45
45
  }), P({
46
46
  dataByGroups: m,
47
47
  data: n[e],
@@ -108,16 +108,16 @@ const P = ({
108
108
  }
109
109
  });
110
110
  }, nt = (m, u, r, e, t) => {
111
- const s = u || S, i = t || b, d = r + e + D;
111
+ const s = u, i = t || G, d = r + e + D;
112
112
  m.forEach((o) => {
113
- const a = o.level, n = (s + i + d) * a + b * (a ? a - 1 : 0) - (i - b) * (a ? 1 : 0);
113
+ const a = o.level, n = (s + i + d) * a + G * (a ? a - 1 : 0) - (i - G) * (a ? 1 : 0);
114
114
  o.top = n;
115
115
  });
116
116
  }, st = (m, u, r, e, t) => {
117
- const s = u || S, i = r || b, o = (e || z) + A + D;
117
+ const s = u, i = r, o = e + M + D;
118
118
  return Math.max(
119
119
  ...m.map((n) => {
120
- const h = n.top || 0, l = Math.max(...n.groupedItems.map((E) => E.items.length)), I = n.hasChildren ? b : 0, x = n.orientation === "horizontal" ? s + i + o + i + I : l * (s + i) + o + i;
120
+ const h = n.top || 0, l = Math.max(...n.groupedItems.map((b) => b.items.length)), I = n.hasChildren ? G : 0, x = n.orientation === "horizontal" ? s + i + o + i + I : l * (s + i) + o + i;
121
121
  return h + x;
122
122
  })
123
123
  );
@@ -148,14 +148,14 @@ const P = ({
148
148
  childrenField: l,
149
149
  expandField: I,
150
150
  hasChildrenField: x,
151
- avatarField: E,
151
+ avatarField: b,
152
152
  titleField: L,
153
153
  subtitleField: C,
154
- cardsColors: T,
154
+ cardsColors: E,
155
155
  ariaLabel: g,
156
- itemRender: k,
157
- groupTitleRender: _,
158
- groupSubtitleRender: W,
156
+ itemRender: S,
157
+ groupTitleRender: k,
158
+ groupSubtitleRender: T,
159
159
  height: N,
160
160
  avatarType: U,
161
161
  showAvatar: B
@@ -183,35 +183,35 @@ const P = ({
183
183
  c.groupedItems = Y(c.items, [{ field: s }]);
184
184
  }), et(H, i), it(H, h), nt(
185
185
  H,
186
- d || S,
186
+ d || A,
187
187
  o || z,
188
- a || A,
188
+ a || M,
189
189
  n
190
190
  );
191
191
  const $ = st(
192
192
  H,
193
- d || S,
193
+ d || A,
194
194
  o || z,
195
- a || A
195
+ a || M
196
196
  );
197
197
  return /* @__PURE__ */ R.createElement("div", { className: "k-orgchart-container", style: { width: e, height: N || $ } }, H.map((c) => {
198
198
  const w = c.level, O = c.groupedItems.map((f) => {
199
- const M = f.items.some((G) => G[I]);
199
+ const y = f.items.some((W) => W[I]);
200
200
  return {
201
201
  ...f,
202
- expanded: M
202
+ expanded: y
203
203
  };
204
- }), F = O.filter((f) => f.expanded), y = "horizontal", K = T && T[w] || "green";
204
+ }), F = O.filter((f) => f.expanded), _ = "horizontal", K = E && E[w] || "green";
205
205
  return /* @__PURE__ */ R.createElement(
206
206
  "div",
207
207
  {
208
208
  role: w === 0 ? "tree" : "group",
209
209
  id: r + "-" + w + "-" + c.ids[0],
210
210
  "aria-label": w === 0 ? g : void 0,
211
- "aria-orientation": w === 0 ? y : void 0,
211
+ "aria-orientation": w === 0 ? _ : void 0,
212
212
  key: c.ids[0] + "_" + w,
213
213
  className: q("k-orgchart-group", `k-orgchart-level-${w}`, "k-pos-absolute", {
214
- [`k-${J.orientationMap[y]}`]: y
214
+ [`k-${J.orientationMap[_]}`]: _
215
215
  }),
216
216
  style: {
217
217
  width: c.width || "100%",
@@ -219,8 +219,8 @@ const P = ({
219
219
  top: c.top
220
220
  }
221
221
  },
222
- t.length > 0 && O.map((f, M) => {
223
- const G = f.items.some(
222
+ t.length > 0 && O.map((f, y) => {
223
+ const W = f.items.some(
224
224
  (p) => p[l] && p[l].length || x && p[x]
225
225
  ), V = c.width ? (c.width - (O.length - 1) * v) / O.length : void 0, Z = F.findIndex((p) => p === f);
226
226
  return /* @__PURE__ */ R.createElement(
@@ -230,30 +230,30 @@ const P = ({
230
230
  style: { width: V },
231
231
  groupTitleHeight: o,
232
232
  groupSubtitleHeight: a,
233
- groupTitleRender: _,
234
- groupSubtitleRender: W,
235
- key: M,
233
+ groupTitleRender: k,
234
+ groupSubtitleRender: T,
235
+ key: y,
236
236
  level: w,
237
- verticalLine: n || b,
237
+ verticalLine: n || G,
238
238
  title: f.items[0][s || L],
239
239
  subtitle: s,
240
240
  orientation: c.orientation,
241
- childLineWidth: G && f.expanded && c.orientation === "horizontal" ? c.childLineWidths[Z] : 0,
242
- line: G,
241
+ childLineWidth: W && f.expanded && c.orientation === "horizontal" ? c.childLineWidths[Z] : 0,
242
+ line: W,
243
243
  nodes: f.items,
244
244
  expanded: f.expanded,
245
- plus: G
245
+ plus: W
246
246
  },
247
247
  f.items.map((p, j) => /* @__PURE__ */ R.createElement(
248
248
  Q,
249
249
  {
250
250
  cardHeight: d,
251
251
  cardWidth: i,
252
- itemRender: k,
252
+ itemRender: S,
253
253
  color: K,
254
254
  key: j,
255
255
  level: w,
256
- avatar: p[E],
256
+ avatar: p[b],
257
257
  avatarType: U,
258
258
  showAvatar: B,
259
259
  title: p[L],
@@ -0,0 +1,16 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2026 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ import { OrgChartProps } from '../client/ClientOrgChart.js';
9
+ import * as React from 'react';
10
+ /**
11
+ * @hidden
12
+ */
13
+ export declare const ServerOrgChart: {
14
+ (props: OrgChartProps): React.JSX.Element;
15
+ displayName: string;
16
+ };
@@ -0,0 +1,103 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2026 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ import * as React from 'react';
9
+ /**
10
+ * @hidden
11
+ */
12
+ export interface OrgChartGroupTitleProps {
13
+ /**
14
+ * The styles that are applied to the OrgChart group title.
15
+ */
16
+ style?: React.CSSProperties;
17
+ /**
18
+ * The default class that is applied to the OrgChart group title.
19
+ */
20
+ className?: string;
21
+ /**
22
+ * The default title that are passed to the OrgChart group.
23
+ */
24
+ title?: string;
25
+ /**
26
+ * The collection of inner items of the group.
27
+ */
28
+ items?: any[];
29
+ /**
30
+ * The level of the group.
31
+ */
32
+ level?: number;
33
+ /**
34
+ * The expanded state of the group.
35
+ */
36
+ expanded?: boolean;
37
+ }
38
+ /**
39
+ * @hidden
40
+ */
41
+ export interface OrgChartGroupSubtitleProps {
42
+ /**
43
+ * The styles that are applied to the OrgChart.
44
+ */
45
+ style?: React.CSSProperties;
46
+ /**
47
+ * The default class that is applied to the OrgChart group title.
48
+ */
49
+ className?: string;
50
+ /**
51
+ * The default subtitle that are passed to the OrgChart group.
52
+ */
53
+ subtitle?: string;
54
+ /**
55
+ * The collection of inner items of the group.
56
+ */
57
+ items?: any[];
58
+ /**
59
+ * The level of the group.
60
+ */
61
+ level?: number;
62
+ /**
63
+ * The expanded state of the group.
64
+ */
65
+ expanded?: boolean;
66
+ }
67
+ /**
68
+ * @hidden
69
+ */
70
+ export interface ServerOrgChartGroupProps {
71
+ /**
72
+ * @hidden
73
+ */
74
+ children?: React.ReactNode;
75
+ /**
76
+ * Sets additional classes to the OrgChart.
77
+ */
78
+ className?: string;
79
+ id?: string;
80
+ /**
81
+ * The styles that are applied to the OrgChart.
82
+ */
83
+ style?: React.CSSProperties;
84
+ title?: string;
85
+ subtitle?: string;
86
+ line?: boolean;
87
+ plus?: boolean;
88
+ focus?: boolean;
89
+ expanded?: boolean;
90
+ nodes?: any[];
91
+ level: number;
92
+ groupTitleHeight?: number;
93
+ groupSubtitleHeight?: number;
94
+ childLineWidth?: number;
95
+ verticalLine?: number;
96
+ orientation?: 'horizontal' | 'vertical';
97
+ groupTitleRender?: React.ComponentType<OrgChartGroupTitleProps>;
98
+ groupSubtitleRender?: React.ComponentType<OrgChartGroupSubtitleProps>;
99
+ }
100
+ /**
101
+ * @hidden
102
+ */
103
+ export declare const ServerOrgChartGroup: React.FunctionComponent<ServerOrgChartGroupProps>;
@@ -0,0 +1,83 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2026 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ import { OrgChartActionEvent, OrgChartExpandChangeEvent } from '../index.js';
9
+ import * as React from 'react';
10
+ /**
11
+ * The props that are passed to the itemRender component.
12
+ */
13
+ export interface OrgChartItemRenderProps {
14
+ /**
15
+ * The item passed to the ItemRender.
16
+ */
17
+ item?: any;
18
+ /**
19
+ * The title of the item.
20
+ */
21
+ title?: string;
22
+ /**
23
+ * The subtitle of the item.
24
+ */
25
+ subtitle?: string;
26
+ /**
27
+ * The level of the item.
28
+ */
29
+ level?: number;
30
+ /**
31
+ * The expanded state of the item.
32
+ */
33
+ expanded?: boolean;
34
+ /**
35
+ * The color of the item.
36
+ */
37
+ color?: string;
38
+ }
39
+ /**
40
+ * @hidden
41
+ */
42
+ export interface ServerOrgChartNodeProps {
43
+ /**
44
+ * @hidden
45
+ */
46
+ children?: React.ReactNode;
47
+ /**
48
+ * Sets additional classes to the OrgChart.
49
+ */
50
+ className?: string;
51
+ /**
52
+ * Passes the OrgChart id to the node.
53
+ */
54
+ id?: string;
55
+ /**
56
+ * The styles that are applied to the OrgChart.
57
+ */
58
+ style?: React.CSSProperties;
59
+ level: number;
60
+ childLineWidth?: number;
61
+ title?: string;
62
+ subtitle?: string;
63
+ details?: boolean;
64
+ color?: string;
65
+ line?: boolean;
66
+ plus?: boolean;
67
+ expanded?: boolean;
68
+ avatar?: string;
69
+ avatarType?: string;
70
+ showAvatar?: boolean;
71
+ cardHeight?: number;
72
+ cardWidth?: number;
73
+ verticalLine?: number;
74
+ itemRender?: React.ComponentType<OrgChartItemRenderProps>;
75
+ onExpandChange?: (ev: OrgChartExpandChangeEvent) => void;
76
+ onItemAction?: (ev: OrgChartActionEvent) => void;
77
+ onItemKeyDown?: (ev: OrgChartActionEvent) => void;
78
+ node?: any;
79
+ }
80
+ /**
81
+ * @hidden
82
+ */
83
+ export declare const ServerOrgChartNode: React.FunctionComponent<ServerOrgChartNodeProps>;
@@ -0,0 +1,12 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2026 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ /**
9
+ * @hidden
10
+ */
11
+ declare const loadTheme: (done: any, doc: Document) => void;
12
+ export { loadTheme };
@@ -0,0 +1,79 @@
1
+ /**
2
+ * @license
3
+ *-------------------------------------------------------------------------------------------
4
+ * Copyright © 2026 Progress Software Corporation. All rights reserved.
5
+ * Licensed under commercial license. See LICENSE.md in the package root for more information
6
+ *-------------------------------------------------------------------------------------------
7
+ */
8
+ /**
9
+ * @hidden
10
+ */
11
+ export declare const EXPAND_FIELD = "expanded";
12
+ /**
13
+ * @hidden
14
+ */
15
+ export declare const TEXT_FIELD = "text";
16
+ /**
17
+ * @hidden
18
+ */
19
+ export declare const DISABLED_FIELD = "disabled";
20
+ /**
21
+ * @hidden
22
+ */
23
+ export declare const CHILDREN_FIELD = "items";
24
+ /**
25
+ * @hidden
26
+ */
27
+ export declare const HAS_CHILDREN_FIELD = "hasChildren";
28
+ /**
29
+ * @hidden
30
+ */
31
+ export declare const SELECT_FIELD = "selected";
32
+ /**
33
+ * @hidden
34
+ */
35
+ export declare const CHECK_FIELD = "checked";
36
+ /**
37
+ * @hidden
38
+ */
39
+ export declare const CHECK_INDETERMINATE_FIELD = "checkIndeterminate";
40
+ /**
41
+ * @hidden
42
+ */
43
+ export declare const DOM_KENDO_ITEM_ID_FIELD = "_kendoItemId";
44
+ /**
45
+ * @hidden
46
+ */
47
+ export declare const DOM_KENDO_TREEVIEW_GUID_FIELD = "_kendoOrgChartGuid";
48
+ /**
49
+ * @hidden
50
+ */
51
+ export declare const ORGCHART_CLASSNAME = "k-orgchart";
52
+ /**
53
+ * @hidden
54
+ */
55
+ export declare const NODE_HEIGHT = 80;
56
+ /**
57
+ * @hidden
58
+ */
59
+ export declare const NODE_WIDTH = 300;
60
+ /**
61
+ * @hidden
62
+ */
63
+ export declare const HORIZONTAL_GAP = 25;
64
+ /**
65
+ * @hidden
66
+ */
67
+ export declare const VERTICAL_LINE = 40;
68
+ /**
69
+ * @hidden
70
+ */
71
+ export declare const GROUP_TITLE_HEIGHT = 20;
72
+ /**
73
+ * @hidden
74
+ */
75
+ export declare const GROUP_SUBTITLE_HEIGHT = 20;
76
+ /**
77
+ * @hidden
78
+ */
79
+ export declare const GROUP_PADDINGS = 82;