@progress/kendo-react-grid 10.1.0-develop.8 → 10.1.0
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/GridComponent.js +1 -1
- package/GridComponent.mjs +145 -141
- package/README.md +4 -4
- package/cells/GridFilterCell.js +1 -1
- package/cells/GridFilterCell.mjs +8 -10
- package/dist/cdn/js/kendo-react-grid.js +1 -1
- package/header/client/GridHeaderCellContainer.js +1 -1
- package/header/client/GridHeaderCellContainer.mjs +17 -14
- package/package-metadata.js +1 -1
- package/package-metadata.mjs +2 -2
- package/package.json +13 -13
package/README.md
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
> - This package is а part of [KendoReact](https://www.telerik.com/kendo-react-ui?utm_medium=referral&utm_source=npm&utm_campaign=kendo-ui-react-trial-npm-grid)—an enterprise-grade UI library with 120+ free and premium components.
|
|
8
8
|
> - This is a free React Data Grid (Table) component with premium features. To use the premium features of the KendoReact Data Grid (Table), you will need to [purchase a license](https://www.telerik.com/kendo-react-ui/pricing?utm_medium=referral&utm_source=npm&utm_campaign=kendo-ui-react-trial-npm-grid) or register for a [free trial](https://www.telerik.com/try/kendo-react-ui?utm_medium=referral&utm_source=npm&utm_campaign=kendo-ui-react-trial-npm-grid). You can use the free features even in production, no sign-up or license required.
|
|
9
9
|
> - If you're looking for more free React components, check out [Get Started with KendoReact Free](https://www.telerik.com/kendo-react-ui/components/free).
|
|
10
|
-
> -
|
|
10
|
+
> - If you have an active license, visit the [KendoReact My License page](https://www.telerik.com/kendo-react-ui/components/my-license/?utm_medium=referral&utm_source=npm&utm_campaign=kendo-ui-react-trial-npm-grid) to learn how to configure your KendoReact licensing.
|
|
11
11
|
> - Installing and working with this package indicates that you [accept the KendoReact License Agreement](https://www.telerik.com/purchase/license-agreement/progress-kendoreact?utm_medium=referral&utm_source=npm&utm_campaign=kendo-ui-react-trial-npm-grid).
|
|
12
12
|
> - The [30-day free trial](https://www.telerik.com/try/kendo-react-ui?utm_medium=referral&utm_source=npm&utm_campaign=kendo-ui-react-trial-npm-grid) gives you access to all KendoReact components and their full functionality. Additionally, for the period of your trial, you can use our legendary technical support provided directly by the KendoReact dev team!
|
|
13
13
|
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
How to start:
|
|
17
17
|
|
|
18
18
|
```sh
|
|
19
|
-
npm
|
|
19
|
+
npm i @progress/kendo-react-grid
|
|
20
20
|
```
|
|
21
21
|
|
|
22
22
|
## React Data Grid
|
|
@@ -62,7 +62,7 @@ Among the many features which the KendoReact Data Grid delivers are:
|
|
|
62
62
|
- [Detail templates (premium)](https://www.telerik.com/kendo-react-ui/components/grid/advanced-features/detail/?utm_medium=referral&utm_source=npm&utm_campaign=kendo-ui-react-trial-npm-grid)—The detail rows of the Grid provide additional details about a particular row of table data through expanding or collapsing its content.
|
|
63
63
|
- [Globalization (free)](https://www.telerik.com/kendo-react-ui/components/grid/globalization/?utm_medium=referral&utm_source=npm&utm_campaign=kendo-ui-react-trial-npm-grid)—By using the available globalization options in KendoReact, you can translate the Grid messages by adapting them to specific culture locales.
|
|
64
64
|
- [Theme support (free)](https://www.telerik.com/kendo-react-ui/components/styling/?utm_medium=referral&utm_source=npm&utm_campaign=kendo-ui-react-trial-npm-grid)—The KendoReact Grid, as well as all 120+ components in the KendoReact suite, are styled in three polished themes (Bootstrap, Material, Fluent, and Default) and can be further customized to match your specific design guidelines.
|
|
65
|
-
-
|
|
65
|
+
- [Server and hybrid data operations (premium)](https://www.telerik.com/kendo-react-ui/components/grid/rsc-mode)—The RCS mode of the KendoReact Grid is a modern, high-performance implementation built on top of the React Server Components (or RSC) architecture allowing you to perform server and hybrid data operations.
|
|
66
66
|
|
|
67
67
|
How to use the Data Grid component in your apps:
|
|
68
68
|
|
|
@@ -70,7 +70,7 @@ How to use the Data Grid component in your apps:
|
|
|
70
70
|
import { Grid, GridColumn } from '@progress/kendo-react-grid';
|
|
71
71
|
...
|
|
72
72
|
/**
|
|
73
|
-
* Provide the data to populate the grid.
|
|
73
|
+
* Provide the data to populate the grid.
|
|
74
74
|
*/
|
|
75
75
|
<Grid data={data}>
|
|
76
76
|
<GridColumn field="DataField1" />
|
package/cells/GridFilterCell.js
CHANGED
|
@@ -6,4 +6,4 @@
|
|
|
6
6
|
*-------------------------------------------------------------------------------------------
|
|
7
7
|
*/
|
|
8
8
|
"use client";
|
|
9
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const z=require("react"),D=require("@progress/kendo-react-buttons"),m=require("@progress/kendo-react-dropdowns"),
|
|
9
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const z=require("react"),D=require("@progress/kendo-react-buttons"),m=require("@progress/kendo-react-dropdowns"),h=require("@progress/kendo-react-inputs"),E=require("@progress/kendo-react-dateinputs"),u=require("../messages/index.js"),O=require("@progress/kendo-react-intl"),C=require("@progress/kendo-svg-icons"),g=require("../filterCommon.js"),y=require("@progress/kendo-react-common");function L(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const c in e)if(c!=="default"){const s=Object.getOwnPropertyDescriptor(e,c);Object.defineProperty(t,c,s.get?s:{enumerable:!0,get:()=>e[c]})}}return t.default=e,Object.freeze(t)}const r=L(z),R=e=>{const t=r.useRef(),c=O.useLocalization(),s=()=>{if(e.filterType==="boolean")return;let n;const l=e.operators.find(o=>o.operator===e.operator)||null;return r.createElement(m.DropDownList,{ref:o=>n=o,size:e.size,value:l,onChange:b,className:"k-dropdown-operator",svgIcon:C.filterIcon,data:e.operators,textField:"text",title:c.toLanguageString(u.filterChooseOperator,u.messages[u.filterChooseOperator]),popupSettings:{width:"",onMouseDownOutside:function(o){!o.isAnchorClicked&&o.state&&o.state.props.show&&n&&n.togglePopup()}}})},d=(n,l)=>{g.cellInputChange(n,l,e)},b=n=>{g.cellOperatorChange(n,e.value,e.onChange)},v=n=>{g.cellBoolDropdownChange(n,e.onChange)},k=n=>{n.preventDefault(),e.onChange({value:"",operator:"",syntheticEvent:n}),t.current&&(t.current.element.value="",setTimeout(()=>{t.current.element.focus()},0))},w=(n,l,o)=>{switch(n){case"numeric":return r.createElement(h.NumericTextBox,{ref:t,size:e.size,value:l,onChange:a=>{d(a.value,a.syntheticEvent)},title:e.title,ariaLabel:e.ariaLabel});case"date":return r.createElement(E.DatePicker,{ref:t,size:e.size,value:l,onChange:a=>{d(a.value,a.syntheticEvent)},title:e.title,ariaLabel:e.ariaLabel,popupSettings:{onMouseDownOutside:a=>{!a.isAnchorClicked&&a.state&&a.state.props.show&&t&&t.current.togglePopup()}}});case"boolean":{const a=i=>i==null;return r.createElement(m.DropDownList,{ref:t,size:e.size,onChange:v,value:o.find(i=>i.operator===(a(l)?"":l)),data:o,textField:"text",title:e.title,ariaLabel:e.ariaLabel,popupSettings:{onMouseDownOutside:i=>{!i.isAnchorClicked&&i.state&&i.state.props.show&&t&&t.current.togglePopup()}}})}default:return r.createElement(h.TextBox,{ref:t,size:e.size,value:l||"",onChange:a=>{d(a.target.value,a.syntheticEvent)},title:e.title,"aria-label":e.ariaLabel})}},f=r.createElement("div",{className:"k-filtercell"},r.createElement("div",{className:"k-filtercell-wrapper"},w(e.filterType,e.value,e.booleanValues),r.createElement("div",{className:"k-filtercell-operator"},s()," ",r.createElement(D.Button,{size:e.size,svgIcon:C.filterClearIcon,className:y.classNames({"k-clear-button-visible":!!(!(e.value===null||e.value==="")||e.operator)}),title:c.toLanguageString(u.filterClearButton,u.messages[u.filterClearButton]),type:"button",onClick:k,disabled:!(!(e.value===null||e.value==="")||e.operator)}))));return e.render?e.render.call(void 0,f,e):f};exports.GridFilterCell=R;
|
package/cells/GridFilterCell.mjs
CHANGED
|
@@ -9,12 +9,12 @@
|
|
|
9
9
|
import * as o from "react";
|
|
10
10
|
import { Button as z } from "@progress/kendo-react-buttons";
|
|
11
11
|
import { DropDownList as m } from "@progress/kendo-react-dropdowns";
|
|
12
|
-
import { TextBox as w, NumericTextBox as
|
|
13
|
-
import { DatePicker as
|
|
12
|
+
import { TextBox as w, NumericTextBox as L } from "@progress/kendo-react-inputs";
|
|
13
|
+
import { DatePicker as k } from "@progress/kendo-react-dateinputs";
|
|
14
14
|
import { filterClearButton as f, messages as d, filterChooseOperator as g } from "../messages/index.mjs";
|
|
15
15
|
import { useLocalization as x } from "@progress/kendo-react-intl";
|
|
16
|
-
import { filterClearIcon as D, filterIcon as
|
|
17
|
-
import { cellOperatorChange as
|
|
16
|
+
import { filterClearIcon as D, filterIcon as y } from "@progress/kendo-svg-icons";
|
|
17
|
+
import { cellOperatorChange as N, cellInputChange as B, cellBoolDropdownChange as O } from "../filterCommon.mjs";
|
|
18
18
|
import { classNames as S } from "@progress/kendo-react-common";
|
|
19
19
|
const j = (e) => {
|
|
20
20
|
const n = o.useRef(), u = x(), h = () => {
|
|
@@ -30,8 +30,7 @@ const j = (e) => {
|
|
|
30
30
|
value: r,
|
|
31
31
|
onChange: C,
|
|
32
32
|
className: "k-dropdown-operator",
|
|
33
|
-
|
|
34
|
-
svgIcon: N,
|
|
33
|
+
svgIcon: y,
|
|
35
34
|
data: e.operators,
|
|
36
35
|
textField: "text",
|
|
37
36
|
title: u.toLanguageString(g, d[g]),
|
|
@@ -46,7 +45,7 @@ const j = (e) => {
|
|
|
46
45
|
}, c = (t, r) => {
|
|
47
46
|
B(t, r, e);
|
|
48
47
|
}, C = (t) => {
|
|
49
|
-
|
|
48
|
+
N(t, e.value, e.onChange);
|
|
50
49
|
}, v = (t) => {
|
|
51
50
|
O(t, e.onChange);
|
|
52
51
|
}, b = (t) => {
|
|
@@ -57,7 +56,7 @@ const j = (e) => {
|
|
|
57
56
|
switch (t) {
|
|
58
57
|
case "numeric":
|
|
59
58
|
return /* @__PURE__ */ o.createElement(
|
|
60
|
-
|
|
59
|
+
L,
|
|
61
60
|
{
|
|
62
61
|
ref: n,
|
|
63
62
|
size: e.size,
|
|
@@ -71,7 +70,7 @@ const j = (e) => {
|
|
|
71
70
|
);
|
|
72
71
|
case "date":
|
|
73
72
|
return /* @__PURE__ */ o.createElement(
|
|
74
|
-
|
|
73
|
+
k,
|
|
75
74
|
{
|
|
76
75
|
ref: n,
|
|
77
76
|
size: e.size,
|
|
@@ -128,7 +127,6 @@ const j = (e) => {
|
|
|
128
127
|
z,
|
|
129
128
|
{
|
|
130
129
|
size: e.size,
|
|
131
|
-
icon: "filter-clear",
|
|
132
130
|
svgIcon: D,
|
|
133
131
|
className: S({
|
|
134
132
|
"k-clear-button-visible": !!(!(e.value === null || e.value === "") || e.operator)
|