I have created my own component inheriting from TreeGrid. But when creating HTML, I found several errors.
1. The filter button is invisible.
2. The may of the component is not created in <div id="app">, but in the main <body>
3. The height of isc_NoticesTreeGrid_0_filterEditor_body is 100px, not 22px as specified in the styles
4. The height of isc_NoticesTreeGrid_0_filterEditor_actionButton is also equal to 100px
my NoticesTreeGrid.js
	my App.js
	
created HTML

SNAPSHOT_v13.1d_2024-05-19
					1. The filter button is invisible.
2. The may of the component is not created in <div id="app">, but in the main <body>
3. The height of isc_NoticesTreeGrid_0_filterEditor_body is 100px, not 22px as specified in the styles
4. The height of isc_NoticesTreeGrid_0_filterEditor_actionButton is also equal to 100px
my NoticesTreeGrid.js
Code:
	
	import { SC, ReactComponent, TreeGrid } from 'smartclient-pro/react';
let isc = window.isc;
SC.defineClass("NoticesTreeGrid", TreeGrid);
class NoticesTreeGrid extends TreeGrid {
    static ISC_CLASS_NAME = "NoticesTreeGrid";
    static IS_CLASS = true;
    static NUMERIC_PROPERTIES = {};
    static COMPOUND_PROPERTIES = {};
    constructor(props) {
        super(props);
    }
}
isc.NoticesTreeGrid.addProperties({
    autoFetchData: false,
    loadDataOnDemand: false,
    canEdit: false,
    showFilterEditor: true,
    showHover: true,
    cascadeSelection: false,
    defaultFields: [
        { name: "command", title: "Command" },
        { name: "argument 1", title: "Argument 1" },
        { name: "argument 2", title: "Argument 2" }],
    gridComponents: ["header", "filterEditor", "body"]
});
Object.defineProperty(NoticesTreeGrid, "name", { value: "NoticesTreeGrid" });
ReactComponent.registerClass("NoticesTreeGrid", NoticesTreeGrid);
export default NoticesTreeGrid;
Code:
	
	import React, { Component } from 'react';
import NoticesTreeGrid from './NoticesTreeGrid.js';
class App extends Component {
  constructor(param) {
    super(param);
  };
  render() {
    return (
      <NoticesTreeGrid width="500" height="300" />
    );
  }
}
export default App;
created HTML
SNAPSHOT_v13.1d_2024-05-19
Comment