Telerik Forums
KendoReact Forum
1 answer
25 views
Hello, I am using a Kendo React DropDownList in a form, but I have an issue. I receive data in batches of 10 from the server-side due to pagination settings. How can I implement scrolling so that the dropdown can display the next 10 data entries when scrolled
Konstantin Dikov
Telerik team
 answered on 25 Apr 2024
2 answers
29 views

Hi,  I've created a drop-down list for my react application. However, when I set the initial value, the required validator is triggering even though a selection has been made. Is there something else I need to be doing?

<Field
name={'site'}
component={FormDropDownList}
textField="title"
dataItemKey="id"
data={sites}
// label={'Select the site you are attending.'}
defaultItem={sitesReducer.nearestSite ? sitesReducer.nearestSite : {
title: 'Select...',
}}
validator={requiredValidator}
/>
Lee
Top achievements
Rank 1
Iron
 answered on 03 Mar 2024
1 answer
27 views

I have couple of issues related to in-cell editing in react grid. I am using NextJs as well.

1) The problem i am facing is when i exit from the cell, the particular cell is still in edit mode. i have added an example for numeric textbox. Even though i have clicked outside the grid, the border is till highlighted & the field is in edit mode.  I am already using custom cell for different fields like( Dropdown list, checkboxes. textboxes, Numeric-text-boxes)

2) In the above numeric textbox, when i add any integer, it will display the number & the cursor will vanish immediately. I have to again click on the numeric text box to add the next  number in the same cell.

3) I have almost 300 records in the grid. I am experiencing slowness in rendering the cells when i edit different cells .

 

I have referred to this example:

https://stackblitz.com/edit/react-czmt6w-tpf8qh?file=app%2FcustomCells.jsx,app%2Fmain.jsx

 

 

Konstantin Dikov
Telerik team
 answered on 22 Feb 2024
1 answer
50 views

My application was recently tested for 508 compliance. I have a cascading dropdown section on one form. First dropdown is a standard dropdown and the second is a filterable dropdown. When I select an option from the first, open the second and type, I am unable to navigate to the options to select one with the keyboard.

I was able to replicate this in the example code by making the second dropdown filterable (NOTE: I'm returning all the data when filtering for simplicity). See below:

import * as React from "react";
import * as ReactDOM from "react-dom";
import { DropDownList, DropDownListChangeEvent, DropDownListFilterChangeEvent } from "@progress/kendo-react-dropdowns";
import { dataCategories, dataProducts, dataOrders } from "./data";
import { filterBy } from '@progress/kendo-data-query';

const defaultItemCategory = { categoryName: "Select Category ..." };
const defaultItemProduct = { productName: "Select Product ..." };
const defaultItemOrder = { orderName: "Select Order ..." };

const App = () => {
  const [state, setState] = React.useState({
    category: null,
    product: null,
    order: null,
    orders: dataOrders,
    products: dataProducts
  });

  const categoryChange = (event: DropDownListChangeEvent) => {
    const category = event.target.value;
    const products = dataProducts.filter(
      product => product.categoryId === category.categoryId
    );

    setState({
      ...state,
      category: category,
      products: products,
      product: null,
      order: null
    });
  };

  const productChange = (event: DropDownListChangeEvent) => {
    const product = event.target.value;
    const orders = dataOrders.filter(
      order => order.productId === product.productId
    );

    setState({
      ...state,
      product: product,
      orders: orders,
      order: null
    });
  };

  const orderChange = (event: DropDownListChangeEvent) => {
    setState({ ...state, order: event.target.value });
  };

  const ddlProducts_onFilterChange = (event: DropDownListFilterChangeEvent) => {
    setState({ products: state.products });
  }



  const category = state.category;
  const product = state.product;
  const order = state.order;

  const hasCategory = category && category !== defaultItemCategory;
  const hasProduct = product && product !== defaultItemProduct;

  return (
    <div style={{ display: 'flex', gap: '30px', flexWrap: 'wrap' }}>
      <div>
        Categories
        <br />
        <DropDownList
          style={{ width: '300px' }}
          data={dataCategories}
          textField="categoryName"
          onChange={categoryChange}
          defaultItem={defaultItemCategory}
          value={category}
        />
      </div>
      <div>
        Products
        <br />
        <DropDownList
          style={{ width: '300px' }}
          disabled={!hasCategory}
          data={state.products}
          textField="productName"
          onChange={productChange}
          defaultItem={defaultItemProduct}
          value={product}
          filterable={ true }
          onFilterChange={ ddlProducts_onFilterChange }
        />
      </div>
      <div>
        Orders
        <br />
        <DropDownList
          style={{ width: '300px' }}
          disabled={!hasProduct}
          data={state.orders}
          textField="orderName"
          onChange={orderChange}
          defaultItem={defaultItemOrder}
          value={order}
        />
      </div>
    </div>
  );
};

ReactDOM.render(<App />, document.querySelector("my-app"));

Is this a known issue? Please advise.

Thanks in advance

Filip
Telerik team
 answered on 18 Jan 2024
1 answer
49 views

Greetings,

I found out that the External filter allows the user to type in the first DropDownList to search for the column name before selecting it.
Is it possible to change the first DropDownList onChange function to delay an action until the user stops typing before triggering the search?

Please help, thanks!

 

Jason

Vessy
Telerik team
 answered on 16 Jan 2024
1 answer
29 views

Problems with the "Field > Combobox" component when passing all the data, label and component properties to it, no problem, but when I add "textField" the combobox gives me a list of [object Object]. Maybe I'm passing the properties wrong, could you give me some clue? 

I have the list of "moneda" that is passed in data through the API.

In the attached image you can see that it loads the list with the value of 'CLP' which is correct and you see the [Object object] list. Greetings

   const [currency, setCurrency] = useState([]);

   useEffect(() => {
     (async() => {
       const currency = await getDefiCurrencies();

       setCurrency(currency);
     })();
   }, []);

---------------Edit Form --------------------------
                   <Field
                     id={'CodiMone'}
                     name={'CodiMone'}
                     label={'Currency'}
                     component={FormComboBox}
                     // textField={'CodiMone'}
                     data={currency}
                   />

      
Konstantin Dikov
Telerik team
 answered on 28 Dec 2023
1 answer
66 views

I am trying to implement scrolling within a DropDownTree KendoReact component. So far, I am not seeing that this is possible, but am hoping there is a solution or workaround. Does anyone have suggestions?

We are basically implementing a large list of selectable items to a user (may also change to a MultiSelectTree to make this work), but due to the number of items we have, the vertical height goes off the page.

 

I did find a forum post from a while back here that makes it seem like maybe this feature is to be implemented come January 2024, but am not positive.

Wissam
Telerik team
 answered on 08 Dec 2023
0 answers
32 views

Hello KendoReact Team,

is there an example that shows how to fully customise a numeric filter cell? I have the case that I need a filter cell for integers and one for decimals. The creation of the component is done, but I can't find an example that also implies the filter operator. The following questions arise from the problem.

1. Where can I view all the CSS classes of KendoReact that I can use for component styling? E.g. `k-icon k-i-filter-clear k-buttonicon` With this class I can style a clear button, including automatic assignment of the icon.

2. Which element is necessary to display the selection list of the filter operator?

3. Is it possible to implement the filter element in the standard display?

 

Thank you for the help

Screen capture

 

Code

import { NumericTextBox, NumericTextBoxChangeEvent } from "@progress/kendo-react-inputs";
import { GridFilterCellProps } from "@progress/kendo-react-grid";
import { Button } from "@progress/kendo-react-buttons";
import React, { useState } from "react";
import { DropDownList } from "@progress/kendo-react-dropdowns/dist/npm/DropDownList/DropDownList";
import { DropDownListChangeEvent } from "@progress/kendo-react-dropdowns";

type CustomNumericFilterCellProps = {
  gridFilterCellProps: GridFilterCellProps;
  format: string;
};

type NumericFilterOperatorType = {
  text: string;
  operator: string;
};

const numericFilterOperators: NumericFilterOperatorType[] = [
  { text: "Is equal to", operator: "eq" },
  { text: "Is not equal to", operator: "neq" },
  { text: "Is greater than or equal", operator: "gte" },
  { text: "Is greater than", operator: "gt" },
  { text: "Is less than or equal", operator: "lte" },
  { text: "Is less than", operator: "lt" },
  { text: "Is null", operator: "isnull" },
  { text: "Is not null", operator: "isnotnull" },
];

export const CustomNumericFilterCell = ({
  gridFilterCellProps,
  format,
}: CustomNumericFilterCellProps) => {
  const { onChange: filterCellPropsOnChange } = gridFilterCellProps;

  const [filterCellValue, setFilterCellValue] = useState<number | null>(null);
  const [isFilterActive, setIsFilterActive] = useState<boolean>(false);
  const [selectedOperator, setSelectedOperator] = useState<NumericFilterOperatorType>(
    numericFilterOperators[0]
  );

  const numericTextBoxOnChange = (event: NumericTextBoxChangeEvent) => {
    const { value: filterValue } = event.target;
    setFilterCellValue(filterValue);
    setIsFilterActive(true);

    filterCellPropsOnChange({
      value: filterValue,
      operator: filterValue ? selectedOperator.operator : "",
      syntheticEvent: event.syntheticEvent,
    });
  };

  const onButtonClearClick = (event: React.MouseEvent<HTMLButtonElement, MouseEvent>) => {
    event.preventDefault();
    setFilterCellValue(null);
    setIsFilterActive(false);
    setSelectedOperator(numericFilterOperators[0]);

    filterCellPropsOnChange({
      value: "",
      operator: "",
      syntheticEvent: event,
    });
  };

  const dropdownlistOnChange = (event: DropDownListChangeEvent) => {
    const operator = event.value as NumericFilterOperatorType;
    setSelectedOperator(operator);
  };

  return (
    <div className="k-filtercell">
      <NumericTextBox onChange={numericTextBoxOnChange} format={format} value={filterCellValue} />

      <DropDownList
        data={numericFilterOperators}
        textField="text"
        dataItemKey="operator"
        onChange={dropdownlistOnChange}
        value={numericFilterOperators.find((item) => item.operator === selectedOperator.operator)}
        className="k-button k-filtercell-clear"
        popupSettings={{ width: "180px" }}
      />

      <Button title="Clear" onClick={onButtonClearClick}>
        <span
          className={`k-icon k-i-filter-clear k-button-icon ${
            !isFilterActive ? "k-disabled" : "k-clear-button-visible"
          }`}
        />
      </Button>
    </div>
  );
};

 

Christian
Top achievements
Rank 1
Iron
Iron
Iron
 updated question on 27 Nov 2023
1 answer
25 views

Hcbc

Konstantin Dikov
Telerik team
 answered on 01 Nov 2023
1 answer
1.0K+ views

Components are onrganized in simple hierarchical structure like this below


<Window>

<Grid>

<GridColumn

cell= {props => <MultiColumnComboBox />}

></GridColumn>

</Grid>

<Window>


 

When one row which means one multicolumncombobox exists inside <Grid>, No problem,

But, When two rows which mean two multicolumncombbox exist, An Error has happend.

"ResizeObserver loop completed with undelivered notifications."

 

 

my package.json  is

"@babel/plugin-proposal-private-property-in-object": "^7.21.11",
"@emotion/react": "^11.9.0",
"@emotion/styled": "^11.8.1",
"@microsoft/signalr": "^6.0.3",
"@mui/icons-material": "^5.11.9",
"@mui/material": "^5.6.4",
"@progress/kendo-data-query": "^1.5.5",
"@progress/kendo-drawing": "^1.17.2",
"@progress/kendo-file-saver": "^1.1.1",
"@progress/kendo-licensing": "^1.2.1",
"@progress/kendo-react-animation": "^5.9.0",
"@progress/kendo-react-buttons": "^5.18.0",
"@progress/kendo-react-charts": "^5.18.0",
"@progress/kendo-react-common": "5.18.0",
"@progress/kendo-react-data-tools": "^5.18.0",
"@progress/kendo-react-dateinputs": "^5.18.0",
"@progress/kendo-react-dialogs": "^5.18.0",
"@progress/kendo-react-dropdowns": "^5.18.0",
"@progress/kendo-react-form": "^5.18.0",
"@progress/kendo-react-grid": "^5.18.0",
"@progress/kendo-react-indicators": "^5.18.0",
"@progress/kendo-react-inputs": "^5.18.0",
"@progress/kendo-react-intl": "^5.18.0",
"@progress/kendo-react-labels": "^5.18.0",
"@progress/kendo-react-layout": "^5.18.0",
"@progress/kendo-react-listbox": "^5.18.0",
"@progress/kendo-react-listview": "^5.18.0",
"@progress/kendo-react-notification": "^5.18.0",
"@progress/kendo-react-pdf": "^5.18.0",
"@progress/kendo-react-popup": "^5.18.0",
"@progress/kendo-react-progressbars": "^5.18.0",
"@progress/kendo-react-scrollview": "^5.18.0",
"@progress/kendo-react-spreadsheet": "^5.18.0",
"@progress/kendo-react-tooltip": "^5.18.0",
"@progress/kendo-react-treeview": "^5.18.0",
"@progress/kendo-react-upload": "^5.18.0",
"@progress/kendo-svg-icons": "^1.9.0",
"@progress/kendo-theme-default": "^6.7.0",
"@testing-library/jest-dom": "^6.1.3",
"@testing-library/react": "^14.0.0",
"@testing-library/user-event": "^14.5.0",
"calculate-size": "^1.1.1",
"cldr": "^7.2.0",
"cldr-core": "^41.0.0",
"cldr-dates-full": "^41.0.0",
"cldr-numbers-full": "^41.0.0",
"dotenv": "^16.0.0",
"dragselect": "^2.3.0",
"hammerjs": "^2.0.8",
"mobx": "^6.6.1",
"mobx-react": "^7.5.2",
"monaco-editor": "^0.32.1",
"react": "^18.1.0",
"react-dom": "^18.1.0",
"react-error-boundary": "^3.1.4",
"react-intersection-observer": "^9.4.3",
"react-router": "^5.3.4",
"react-router-dom": "^5.3.4",
"react-scripts": "^5.0.1",
"react-simple-image-viewer": "^1.2.2",
"react-to-print": "^2.14.7",
"typescript": "^4.5.5",
"web-vitals": "^2.1.3"

 

 

And error image is.

 

Please. help me.

Konstantin Dikov
Telerik team
 answered on 25 Oct 2023
Narrow your results
Selected tags
Tags
+? more
Top users last month
Mark
Top achievements
Rank 1
Yurii
Top achievements
Rank 1
Leland
Top achievements
Rank 2
Iron
Iron
Iron
Hon
Top achievements
Rank 1
Iron
Deltaohm
Top achievements
Rank 3
Bronze
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Mark
Top achievements
Rank 1
Yurii
Top achievements
Rank 1
Leland
Top achievements
Rank 2
Iron
Iron
Iron
Hon
Top achievements
Rank 1
Iron
Deltaohm
Top achievements
Rank 3
Bronze
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?