armtek-uikit-react 1.0.166 → 1.0.168
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.
package/package.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"name":"armtek-uikit-react","version":"1.0.
|
|
1
|
+
{"name":"armtek-uikit-react","version":"1.0.168","description":"Armtek UIKit for React","main":"cjs/index.js","module":"esm/index.js","types":"esm/index.d.ts","repository":{"type":"git","url":"ssh://git@gl.corp:10022/int/uikit/uikit_react.git"},"author":"","license":"ISC","dependencies":{"build":"^0.1.4","clsx":"^2.0.0","rc-slider":"^10.2.1","react":"*","react-datepicker":"^4.16.0","react-dom":"*","react-transition-group":"^4.4.5"},"peerDependencies":{"react":"*","react-dom":"*"},"scripts":{"pub":"npm version patch && npm publish"}}
|
package/types/theme.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { TextFieldProps } from '../TextField/TextField';
|
|
2
2
|
import { ChangeEvent, MouseEvent } from 'react';
|
|
3
3
|
import { DatePickerProps } from '../DatePicker/DatePicker';
|
|
4
|
+
import { DataAttributes } from '../../../types/theme';
|
|
4
5
|
type BaseInputProps = Pick<TextFieldProps, 'label' | 'className' | 'placeholder' | 'error' | 'helperText'>;
|
|
5
6
|
export type DateFieldChangeEvent = Omit<ChangeEvent<HTMLInputElement>, 'target'> & {
|
|
6
7
|
target: {
|
|
@@ -15,7 +16,7 @@ type OwnProps = {
|
|
|
15
16
|
value?: Date | string | null;
|
|
16
17
|
showTime?: boolean;
|
|
17
18
|
showTimeOnly?: boolean;
|
|
18
|
-
inputProps?: Omit<TextFieldProps, 'onChange' | 'value'
|
|
19
|
+
inputProps?: Omit<TextFieldProps, 'onChange' | 'value'> & DataAttributes;
|
|
19
20
|
};
|
|
20
21
|
export type DateFieldProps = OwnProps & BaseInputProps & Omit<DatePickerProps, keyof OwnProps>;
|
|
21
22
|
export declare const getDateFormat: (format?: string) => Record<string, any>;
|
|
@@ -123,40 +123,6 @@ const DateField = exports.DateField = /*#__PURE__*/(0, _react.forwardRef)((props
|
|
|
123
123
|
})]
|
|
124
124
|
});
|
|
125
125
|
});
|
|
126
|
-
// const DateField = forwardRef((props: DateFieldProps, ref: any) => {
|
|
127
|
-
//
|
|
128
|
-
// let {onChange, format = 'dd.MM.yyyy', onInput, showTime, showTimeOnly, disabled, value, ...restProps} = props
|
|
129
|
-
// let [date, setDate] = useState<Date | null>(null)
|
|
130
|
-
//
|
|
131
|
-
// if( showTime && !showTimeOnly ) format = 'dd.MM.yyyy HH:mm'
|
|
132
|
-
// else if( showTimeOnly ) format = 'HH:mm'
|
|
133
|
-
//
|
|
134
|
-
// const handleChange = (d: Date | null) => {
|
|
135
|
-
// setDate(d)
|
|
136
|
-
// if( onChange )
|
|
137
|
-
// onChange(d)
|
|
138
|
-
// }
|
|
139
|
-
//
|
|
140
|
-
// let realValue = value !== undefined ? value : date
|
|
141
|
-
//
|
|
142
|
-
// return <>
|
|
143
|
-
// <DatePicker
|
|
144
|
-
// onChange={handleChange}
|
|
145
|
-
// selected={realValue}
|
|
146
|
-
// showTimeSelect={!!showTime}
|
|
147
|
-
// timeIntervals={15}
|
|
148
|
-
// showTimeSelectOnly={!!showTimeOnly && !!showTime}
|
|
149
|
-
// customInput={<DateInput showTime={showTime} showTimeOnly={showTimeOnly} ref={ref} {...restProps} />}
|
|
150
|
-
// inline={false}
|
|
151
|
-
// disabled={disabled}
|
|
152
|
-
// calendarContainer={PickerCard}
|
|
153
|
-
// popperPlacement="top-end"
|
|
154
|
-
// dateFormat={format}
|
|
155
|
-
// />
|
|
156
|
-
// </>
|
|
157
|
-
//
|
|
158
|
-
// })
|
|
159
|
-
|
|
160
126
|
const PickerCard = props => {
|
|
161
127
|
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_Card.default, {
|
|
162
128
|
className: props.className,
|
|
@@ -6,7 +6,7 @@ declare const TimeField: import("react").ForwardRefExoticComponent<{
|
|
|
6
6
|
value?: string | Date | null | undefined;
|
|
7
7
|
showTime?: boolean | undefined;
|
|
8
8
|
showTimeOnly?: boolean | undefined;
|
|
9
|
-
inputProps?: Omit<import("../TextField").TextFieldProps, "value" | "onChange"> | undefined;
|
|
9
|
+
inputProps?: (Omit<import("../TextField").TextFieldProps, "value" | "onChange"> & import("../../../types/theme").DataAttributes) | undefined;
|
|
10
10
|
} & {
|
|
11
11
|
label?: string | undefined;
|
|
12
12
|
placeholder?: string | undefined;
|
|
@@ -21,6 +21,6 @@ declare const TimeField: import("react").ForwardRefExoticComponent<{
|
|
|
21
21
|
value?: string | Date | null | undefined;
|
|
22
22
|
showTime?: boolean | undefined;
|
|
23
23
|
showTimeOnly?: boolean | undefined;
|
|
24
|
-
inputProps?: Omit<import("../TextField").TextFieldProps, "value" | "onChange"> | undefined;
|
|
24
|
+
inputProps?: (Omit<import("../TextField").TextFieldProps, "value" | "onChange"> & import("../../../types/theme").DataAttributes) | undefined;
|
|
25
25
|
}> & import("react").RefAttributes<HTMLInputElement>>;
|
|
26
26
|
export default TimeField;
|
package/ui/Tooltip/Tooltip.d.ts
CHANGED
|
@@ -3,10 +3,11 @@ type Classes = {
|
|
|
3
3
|
tooltip: string;
|
|
4
4
|
popper: string;
|
|
5
5
|
};
|
|
6
|
-
|
|
6
|
+
type OwnProps = {
|
|
7
7
|
text: string | ReactNode;
|
|
8
8
|
classNames?: Partial<Classes>;
|
|
9
9
|
placement?: 'bottom-end' | 'bottom-start' | 'bottom' | 'left-end' | 'left-start' | 'left' | 'right-end' | 'right-start' | 'right' | 'top-end' | 'top-start' | 'top';
|
|
10
10
|
};
|
|
11
|
-
|
|
11
|
+
export type TooltipProps = OwnProps & Omit<ComponentPropsWithoutRef<'span'>, keyof OwnProps>;
|
|
12
|
+
declare function Tooltip(props: TooltipProps): import("react/jsx-runtime").JSX.Element;
|
|
12
13
|
export default Tooltip;
|