@dartech/arsenal-ui 1.4.51 → 1.4.53

Sign up to get free protection for your applications and to get access to all the features.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dartech/arsenal-ui",
3
- "version": "1.4.51",
3
+ "version": "1.4.53",
4
4
  "author": "DAR",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -32,6 +32,18 @@ export interface CreateDefinitionType<T = Record<string, never>> extends Omit<De
32
32
  export interface UpdateDefinitionType<T = Record<string, never>> extends Omit<Definition<T>, 'properties'> {
33
33
  properties: PropertiesArrayType<T>;
34
34
  }
35
+ export interface UiSettings {
36
+ label?: string;
37
+ name?: string;
38
+ paramJson?: {
39
+ size?: number;
40
+ type?: 'email' | 'phone' | 'iin' | 'currency' | 'iban';
41
+ maxLength?: number;
42
+ };
43
+ behaviorJson: {
44
+ displayDependOn?: string;
45
+ };
46
+ }
35
47
  export interface Property {
36
48
  propertyType: keyof typeof PropertyType | {
37
49
  value: keyof typeof PropertyType;
@@ -43,7 +55,7 @@ export interface Property {
43
55
  isMultiple: boolean;
44
56
  sortOrder: number;
45
57
  isEnabled: boolean;
46
- uiSettings: unknown;
58
+ uiSettings: UiSettings | null;
47
59
  validationNode: unknown;
48
60
  key?: string;
49
61
  }
@@ -1,4 +1,5 @@
1
- /// <reference types="react" />
1
+ import React from 'react';
2
+ import { AutocompleteProps } from '@mui/material/Autocomplete';
2
3
  import { ControlAutocompleteProps } from './ControlAutocomplete';
3
4
  import { PaginateData } from '../../../interfaces';
4
5
  type PaginateParams = {
@@ -13,6 +14,7 @@ type ControlQueryAutocompleteProps<T> = Omit<ControlAutocompleteProps, 'options'
13
14
  queryFunction: (params: PaginateParams) => Promise<PaginateData<T>>;
14
15
  itemQueryFunction?: (valueKey: string) => Promise<T>;
15
16
  requiredErrorText?: string;
17
+ renderInput?: AutocompleteProps<unknown, boolean, boolean, boolean, React.ElementType<any>>['renderInput'];
16
18
  };
17
19
  export declare function ControlQueryAutocomplete<T>({ name, label, control, required, searchBy, labelKey, multiple, mongoQueryJson, disabled, valueKey, sortBy, hideErrorMessage, disableCloseOnSelect, textFieldProps, onChange, queryFunction, validate, itemQueryFunction, requiredErrorText, ...autocompleteProps }: ControlQueryAutocompleteProps<T>): JSX.Element;
18
20
  export default ControlQueryAutocomplete;