@xelto.npm/xc2-lib 0.0.39 → 0.0.40

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.
@@ -1,19 +1,4 @@
1
- /// <reference types="react" />
2
- import PropTypes from "prop-types";
3
- declare const DatePicker: {
4
- ({ value, onChange, label, fluid, disabled, forwardedRef, ...props }: {
5
- [x: string]: any;
6
- value: any;
7
- onChange: any;
8
- label?: string | undefined;
9
- fluid?: boolean | undefined;
10
- disabled?: boolean | undefined;
11
- forwardedRef?: null | undefined;
12
- }): JSX.Element;
13
- propTypes: {
14
- disabled: PropTypes.Requireable<boolean>;
15
- label: PropTypes.Requireable<string>;
16
- fluid: PropTypes.Requireable<boolean>;
17
- };
18
- };
1
+ import * as React from 'react';
2
+ import { DatePickerProps } from "./DatePickerProps";
3
+ declare const DatePicker: React.FunctionComponent<DatePickerProps>;
19
4
  export default DatePicker;
@@ -0,0 +1,10 @@
1
+ import { Ref } from "react";
2
+ export interface DatePickerProps {
3
+ value: string;
4
+ disabled?: boolean;
5
+ label?: string;
6
+ fluid?: boolean;
7
+ onChange: (value: unknown, keyboardInputValue?: string) => void;
8
+ forwardedRef?: Ref<HTMLInputElement>;
9
+ endAdornment?: string;
10
+ }
@@ -1,5 +1,5 @@
1
- import { FunctionComponent } from "react";
1
+ import * as React from 'react';
2
2
  import { TextFieldProps } from "./TextFieldProps";
3
3
  export declare const StyledTextField: import("@emotion/styled").StyledComponent<import("@mui/material/TextField").TextFieldProps & import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme>, {}, {}>;
4
- declare const TextField: FunctionComponent<TextFieldProps>;
4
+ declare const TextField: React.FunctionComponent<TextFieldProps>;
5
5
  export default TextField;
@@ -1,18 +1,18 @@
1
- import * as React from "react";
1
+ import { ChangeEventHandler, ReactNode } from "react";
2
2
  export interface TextFieldProps {
3
- label: string;
4
- error: boolean;
5
- icon: string;
6
- disabled: boolean;
7
- fluid: boolean;
8
- type: string;
9
- min: string;
10
- max: string;
11
- small: boolean;
3
+ label?: string;
4
+ error?: boolean;
5
+ icon?: string;
6
+ disabled?: boolean;
7
+ fluid?: boolean;
8
+ type?: string;
9
+ min?: string;
10
+ max?: string;
11
+ small?: boolean;
12
12
  helperText?: string;
13
- value: string;
14
- onChange?: React.ChangeEventHandler<HTMLTextAreaElement | HTMLInputElement>;
15
- onBlur?: React.ChangeEventHandler<HTMLTextAreaElement | HTMLInputElement>;
16
- forwardedRef?: null;
13
+ value?: string;
14
+ onChange?: ChangeEventHandler<HTMLTextAreaElement | HTMLInputElement>;
15
+ onBlur?: ChangeEventHandler<HTMLTextAreaElement | HTMLInputElement>;
16
+ forwardedRef?: ReactNode;
17
17
  endAdornment?: string;
18
18
  }
package/dist/index.d.ts CHANGED
@@ -1,7 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  import propTypes from 'prop-types';
3
3
  import * as React from 'react';
4
- import { FunctionComponent } from 'react';
4
+ import { Ref, ChangeEventHandler, ReactNode } from 'react';
5
5
 
6
6
  declare const AppTileComponent: ({ header, description, illustrationName, forwardedRef, isBigType, size, color }: {
7
7
  header: any;
@@ -96,41 +96,36 @@ declare const CheckboxComponent: ({ disabled, label, checked, onChange, indeterm
96
96
  forwardedRef?: null | undefined;
97
97
  }) => JSX.Element;
98
98
 
99
- declare const DatePicker: {
100
- ({ value, onChange, label, fluid, disabled, forwardedRef, ...props }: {
101
- [x: string]: any;
102
- value: any;
103
- onChange: any;
104
- label?: string | undefined;
105
- fluid?: boolean | undefined;
106
- disabled?: boolean | undefined;
107
- forwardedRef?: null | undefined;
108
- }): JSX.Element;
109
- propTypes: {
110
- disabled: propTypes.Requireable<boolean>;
111
- label: propTypes.Requireable<string>;
112
- fluid: propTypes.Requireable<boolean>;
113
- };
114
- };
99
+ interface DatePickerProps {
100
+ value: string;
101
+ disabled?: boolean;
102
+ label?: string;
103
+ fluid?: boolean;
104
+ onChange: (value: unknown, keyboardInputValue?: string) => void;
105
+ forwardedRef?: Ref<HTMLInputElement>;
106
+ endAdornment?: string;
107
+ }
108
+
109
+ declare const DatePicker: React.FunctionComponent<DatePickerProps>;
115
110
 
116
111
  interface TextFieldProps {
117
- label: string;
118
- error: boolean;
119
- icon: string;
120
- disabled: boolean;
121
- fluid: boolean;
122
- type: string;
123
- min: string;
124
- max: string;
125
- small: boolean;
112
+ label?: string;
113
+ error?: boolean;
114
+ icon?: string;
115
+ disabled?: boolean;
116
+ fluid?: boolean;
117
+ type?: string;
118
+ min?: string;
119
+ max?: string;
120
+ small?: boolean;
126
121
  helperText?: string;
127
- value: string;
128
- onChange?: React.ChangeEventHandler<HTMLTextAreaElement | HTMLInputElement>;
129
- onBlur?: React.ChangeEventHandler<HTMLTextAreaElement | HTMLInputElement>;
130
- forwardedRef?: null;
122
+ value?: string;
123
+ onChange?: ChangeEventHandler<HTMLTextAreaElement | HTMLInputElement>;
124
+ onBlur?: ChangeEventHandler<HTMLTextAreaElement | HTMLInputElement>;
125
+ forwardedRef?: ReactNode;
131
126
  endAdornment?: string;
132
127
  }
133
128
 
134
- declare const TextField: FunctionComponent<TextFieldProps>;
129
+ declare const TextField: React.FunctionComponent<TextFieldProps>;
135
130
 
136
131
  export { AppTileComponent as AppTile, BottomBarComponent as BottomBar, BottomInfoBar, CustomButtonComponent as Button, CheckboxComponent as Checkbox, DatePicker, Icon, IconButtonComponent as IconButton, Illustration, Logo, TextField, TypographyComponent as Typography };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xelto.npm/xc2-lib",
3
- "version": "0.0.39",
3
+ "version": "0.0.40",
4
4
  "author": "XELTO",
5
5
  "description": "React component library based on MUI",
6
6
  "license": "ISC",