ods-component-lib 1.18.72 → 1.18.74

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.
@@ -0,0 +1,18 @@
1
+ import React from 'react';
2
+ import { FormProps, ButtonProps } from 'antd';
3
+ export interface IFormItemRuleProps {
4
+ required?: boolean;
5
+ message?: string;
6
+ }
7
+ export interface IFormItemProps {
8
+ label?: string;
9
+ name?: string;
10
+ formItemType: string;
11
+ rules?: IFormItemRuleProps[];
12
+ }
13
+ export interface IFormProps extends FormProps {
14
+ formItems: IFormItemProps[];
15
+ formButtons: ButtonProps[];
16
+ }
17
+ declare function OdsBasicForm(props: IFormProps): React.JSX.Element;
18
+ export default OdsBasicForm;
package/dist/index.js CHANGED
@@ -16682,6 +16682,7 @@ var OdsRemoteDataGrid = function OdsRemoteDataGrid(props) {
16682
16682
  };
16683
16683
  colItem.headerCellRender = headerCellRenderr;
16684
16684
  }
16685
+ if (props.isServerSide) colItem.calculateSortValue = String("dummyFieldForPreventClientSideSorting");
16685
16686
  return colItem;
16686
16687
  });
16687
16688
  columns.current = newColumns;
@@ -16702,6 +16703,32 @@ var OdsRemoteDataGrid = function OdsRemoteDataGrid(props) {
16702
16703
  React.useEffect(function () {
16703
16704
  if (contentReady) checkSortingPropertyForInitilaize();
16704
16705
  }, [contentReady]);
16706
+ React.useEffect(function () {
16707
+ var cssRules = "\n .data-exists .dx-datagrid-borders > .dx-datagrid-filter-panel,\n .data-exists .dx-datagrid-borders > .dx-datagrid-headers {\n border-top: 1px solid rgba(0, 0, 0, 0.06);\n padding-right: 0px !important;\n }\n \n .data-exists .dx-datagrid-headers .dx-datagrid-content {\n margin-bottom: -1px;\n padding-right: 17px !important;\n }\n ";
16708
+ var styleSheet = document.createElement('style');
16709
+ styleSheet.type = 'text/css';
16710
+ styleSheet.innerText = cssRules;
16711
+ document.head.appendChild(styleSheet);
16712
+ var checkData = function checkData() {
16713
+ if (gridRef.current) {
16714
+ var _dataGridInstance = gridRef.current.instance;
16715
+ var dataExists = data.length > 0;
16716
+ var gridElement = _dataGridInstance.element();
16717
+ if (dataExists) {
16718
+ gridElement.classList.add('data-exists');
16719
+ } else {
16720
+ gridElement.classList.remove('data-exists');
16721
+ }
16722
+ }
16723
+ };
16724
+ var dataGridInstance = gridRef.current.instance;
16725
+ dataGridInstance.on('dataChanged', checkData);
16726
+ checkData();
16727
+ return function () {
16728
+ document.head.removeChild(styleSheet);
16729
+ dataGridInstance.off('dataChanged', checkData);
16730
+ };
16731
+ }, [data]);
16705
16732
  var checkSortingPropertyForInitilaize = function checkSortingPropertyForInitilaize() {
16706
16733
  var onOptionChanged = props.onOptionChanged;
16707
16734
  if (onOptionChanged) {