@antscorp/antsomi-ui 1.2.1 → 1.2.2
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/dist/index.js +1 -1
- package/dist/types/components/atoms/Checkbox/Checkbox.d.ts +1 -0
- package/dist/types/components/atoms/Checkbox/index.d.ts +1 -0
- package/dist/types/components/atoms/InputNumber/InputNumber.d.ts +1 -2
- package/dist/types/components/atoms/InputNumber/InputNumber.stories.d.ts +16 -0
- package/dist/types/components/atoms/InputNumber/__tests__/InputNumber.test.d.ts +1 -0
- package/dist/types/components/atoms/index.d.ts +1 -0
- package/dist/types/components/index.d.ts +1 -0
- package/dist/types/components/molecules/DatePicker/components/AdvancedPicker/AdvancedPicker.d.ts +5 -1
- package/dist/types/components/molecules/DatePicker/components/AdvancedPicker/styled.d.ts +1 -0
- package/dist/types/components/molecules/DatePicker/components/AdvancedPicker/types.d.ts +3 -0
- package/dist/types/components/molecules/DatePicker/components/AdvancedRangePicker/AdvancedRangePicker.d.ts +7 -1
- package/dist/types/components/molecules/DatePicker/components/AdvancedRangePicker/AdvancedRangePicker.stories.d.ts +2 -0
- package/dist/types/components/molecules/DatePicker/components/AdvancedRangePicker/types.d.ts +4 -1
- package/dist/types/components/organism/Table/Table.d.ts +1 -0
- package/dist/types/components/organism/Table/index.d.ts +1 -0
- package/dist/types/components/organism/index.d.ts +1 -0
- package/package.json +2 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Checkbox } from 'antd';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Checkbox } from './Checkbox';
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { InputNumberProps as AntdInputNumberProps } from 'antd';
|
|
3
|
-
interface InputNumberProps extends AntdInputNumberProps {
|
|
3
|
+
export interface InputNumberProps extends AntdInputNumberProps {
|
|
4
4
|
showHandler?: boolean;
|
|
5
5
|
}
|
|
6
6
|
export declare const InputNumber: React.FC<InputNumberProps>;
|
|
7
|
-
export {};
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { ComponentStory, ComponentMeta } from '@storybook/react';
|
|
3
|
+
declare const _default: ComponentMeta<React.FC<import("./InputNumber").InputNumberProps>>;
|
|
4
|
+
export default _default;
|
|
5
|
+
export declare const Default: ComponentStory<React.FC<import("./InputNumber").InputNumberProps>>;
|
|
6
|
+
export declare const BasicUsage: ComponentStory<any>;
|
|
7
|
+
export declare const PrePostTab: ComponentStory<any>;
|
|
8
|
+
export declare const HighPrecisionDecimals: ComponentStory<any>;
|
|
9
|
+
export declare const KeyBoard: ComponentStory<any>;
|
|
10
|
+
export declare const OutOfRange: ComponentStory<any>;
|
|
11
|
+
export declare const Status: ComponentStory<any>;
|
|
12
|
+
export declare const Sizes: ComponentStory<any>;
|
|
13
|
+
export declare const Disabled: ComponentStory<any>;
|
|
14
|
+
export declare const Formatter: ComponentStory<any>;
|
|
15
|
+
export declare const Borderless: ComponentStory<any>;
|
|
16
|
+
export declare const Prefix: ComponentStory<any>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
package/dist/types/components/molecules/DatePicker/components/AdvancedPicker/AdvancedPicker.d.ts
CHANGED
|
@@ -1,8 +1,11 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { TAdvancedType, TOperatorKey, TOption } from './types';
|
|
2
|
+
import { TAdvancedType, TCalculationType, TOperatorKey, TOption, TShowCalculationTypeCondition } from './types';
|
|
3
3
|
export interface AdvancedPickerProps {
|
|
4
4
|
label?: string;
|
|
5
|
+
disabled?: boolean;
|
|
5
6
|
dateTypeKeysShow?: string[];
|
|
7
|
+
showCalculationTypeCondition?: TShowCalculationTypeCondition;
|
|
8
|
+
calculationTypeKeysShow?: TCalculationType[];
|
|
6
9
|
defaultDateTypeKey?: string;
|
|
7
10
|
valueType?: string;
|
|
8
11
|
option?: TOption;
|
|
@@ -15,6 +18,7 @@ export interface AdvancedPickerProps {
|
|
|
15
18
|
disableAfterDate?: string;
|
|
16
19
|
disableBeforeDate?: string;
|
|
17
20
|
errorMessage?: string;
|
|
21
|
+
showTime?: boolean;
|
|
18
22
|
onUpdatedNewDate?: (newDate: any) => void;
|
|
19
23
|
onApply?: ({ date, option }: {
|
|
20
24
|
date: string;
|
|
@@ -4,3 +4,4 @@ export declare const DropdownFooter: import("styled-components").StyledComponent
|
|
|
4
4
|
export declare const DatePickerHeader: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
5
5
|
export declare const DatePickerCustomInput: import("styled-components").StyledComponent<"input", any, {}, never>;
|
|
6
6
|
export declare const DatePickerFooter: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
7
|
+
export declare const CalendarIconWrapper: import("styled-components").StyledComponent<"div", any, {}, never>;
|
|
@@ -4,6 +4,9 @@ export type TOption = {
|
|
|
4
4
|
calculationDate: TCalculationDate;
|
|
5
5
|
value: number;
|
|
6
6
|
};
|
|
7
|
+
export type TShowCalculationTypeCondition = {
|
|
8
|
+
dateType: Partial<Record<TDateType, TCalculationType[]>>;
|
|
9
|
+
};
|
|
7
10
|
export type TDateType = 'today' | 'first_day_of_week_mon_sun' | 'first_day_of_week_sun_sat' | 'first_day_of_month' | 'first_day_of_quarter' | 'first_day_of_year' | 'last_day_of_week_mon_sun' | 'last_day_of_week_sun_sat' | 'last_day_of_month' | 'last_day_of_quarter' | 'last_day_of_year' | 'fixed';
|
|
8
11
|
export type TCalculationType = 'minus' | 'plus' | '';
|
|
9
12
|
export type TCalculationDate = 'seconds' | 'minutes' | 'hours' | 'days' | 'weeks' | 'months' | 'quarters' | 'years' | '';
|
|
@@ -1,9 +1,15 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import {
|
|
2
|
+
import { TShowCalculationTypeCondition } from '../AdvancedPicker/types';
|
|
3
|
+
import { TDateConfig, TOnChangePayload, TTimeRange } from './types';
|
|
3
4
|
export interface AdvancedRangePickerProps {
|
|
5
|
+
disabled?: boolean;
|
|
6
|
+
showCalculationTypeCondition?: TShowCalculationTypeCondition;
|
|
7
|
+
startDateConfig?: TDateConfig;
|
|
8
|
+
endDateConfig?: TDateConfig;
|
|
4
9
|
timeRange: TTimeRange;
|
|
5
10
|
errorMessage?: string;
|
|
6
11
|
showLabel?: boolean;
|
|
12
|
+
showTime?: boolean;
|
|
7
13
|
onChange?: ({ timeRange, mode }: TOnChangePayload) => void;
|
|
8
14
|
}
|
|
9
15
|
export declare const AdvancedRangePicker: React.FC<AdvancedRangePickerProps>;
|
|
@@ -5,3 +5,5 @@ declare const _default: ComponentMeta<React.FC<import("./AdvancedRangePicker").A
|
|
|
5
5
|
export default _default;
|
|
6
6
|
export declare const Template: ComponentStory<typeof AdvancedRangePicker>;
|
|
7
7
|
export declare const Basic: ComponentStory<typeof AdvancedRangePicker>;
|
|
8
|
+
export declare const HideTimeLabel: ComponentStory<typeof AdvancedRangePicker>;
|
|
9
|
+
export declare const ShowCalculationTypeCondition: ComponentStory<typeof AdvancedRangePicker>;
|
package/dist/types/components/molecules/DatePicker/components/AdvancedRangePicker/types.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { TOption } from '../AdvancedPicker/types';
|
|
1
|
+
import { TCalculationType, TOption } from '../AdvancedPicker/types';
|
|
2
2
|
export type TOnChangeMode = 'system' | 'user';
|
|
3
3
|
export type TTimeRange = {
|
|
4
4
|
startDate: TOption & {
|
|
@@ -12,3 +12,6 @@ export type TOnChangePayload = {
|
|
|
12
12
|
timeRange: TTimeRange;
|
|
13
13
|
mode: 'system' | 'user';
|
|
14
14
|
};
|
|
15
|
+
export type TDateConfig = {
|
|
16
|
+
calculationTypeKeysShow?: TCalculationType[];
|
|
17
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Table } from 'antd';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Table } from './Table';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { Table } from './Table';
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@antscorp/antsomi-ui",
|
|
3
|
-
"version": "1.2.
|
|
3
|
+
"version": "1.2.2",
|
|
4
4
|
"description": "An enterprise-class UI design language and React UI library.",
|
|
5
5
|
"main": "dist/index.js",
|
|
6
6
|
"files": [
|
|
@@ -19,6 +19,7 @@
|
|
|
19
19
|
"serve-storybook": "serve storybook-static",
|
|
20
20
|
"version": "auto-changelog -p && git add CHANGELOG.md",
|
|
21
21
|
"test": "jest",
|
|
22
|
+
"test:changed": "jest --onlyChanged",
|
|
22
23
|
"test:watch": "jest --watch",
|
|
23
24
|
"test:coverage": "jest --coverage"
|
|
24
25
|
},
|