Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Binary file modified db/TDesign.db
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ clearable | Boolean | false | \- | N
defaultTime | String | '00:00:00' | Time selector default value | N
disableDate | Object / Array / Function | - | Typescript: `DisableDate` `type DisableDate = Array<DateValue> \| DisableDateObj \| ((date: DateValue) => boolean)` `interface DisableDateObj { from?: string; to?: string; before?: string; after?: string }`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/date-picker/type.ts) | N
disableTime | Function | - | disable time config function。Typescript: `(time: Date) => Partial<{ hour: Array<number>, minute: Array<number>, second: Array<number>, millisecond: Array<number> }>` | N
disabled | Boolean | undefined | make DatePicker to be disabled | N
disabled | Boolean / Array | undefined | make DatePicker to be disabled。Typescript: `boolean \| Array<boolean>` | N
enableTimePicker | Boolean | false | \- | N
firstDayOfWeek | Number | 7 | options: 1/2/3/4/5/6/7 | N
format | String | 'YYYY-MM-DD' | \- | N
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ clearable | Boolean | false | 是否显示清除按钮 | N
defaultTime | String | '00:00:00' | 时间选择器默认值,当 value/defaultValue 未设置值时有效 | N
disableDate | Object / Array / Function | - | 禁用日期,示例:['A', 'B'] 表示日期 A 和日期 B 会被禁用。`{ from: 'A', to: 'B' }` 表示在 A 到 B 之间的日期会被禁用。`{ before: 'A', after: 'B' }` 表示在 A 之前和在 B 之后的日期都会被禁用。其中 A = '2021-01-01',B = '2021-02-01'。值类型为 Function 则表示返回值为 true 的日期会被禁用。TS 类型:`DisableDate` `type DisableDate = Array<DateValue> \| DisableDateObj \| ((date: DateValue) => boolean)` `interface DisableDateObj { from?: string; to?: string; before?: string; after?: string }`。[详细类型定义](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/date-picker/type.ts) | N
disableTime | Function | - | 禁用时间项的配置函数,仅在日期时间选择器中可用。TS 类型:`(time: Date) => Partial<{ hour: Array<number>, minute: Array<number>, second: Array<number>, millisecond: Array<number> }>` | N
disabled | Boolean | undefined | 是否禁用组件 | N
disabled | Boolean / Array | undefined | 是否禁用组件。TS 类型:`boolean \| Array<boolean>` | N
enableTimePicker | Boolean | false | 是否显示时间选择 | N
firstDayOfWeek | Number | 7 | 第一天从星期几开始。可选项:1/2/3/4/5/6/7 | N
format | String | 'YYYY-MM-DD' | 仅用于格式化日期显示的格式,不影响日期值。注意和 `valueType` 的区别,`valueType`会直接决定日期值 `value` 的格式。全局配置默认为:'YYYY-MM-DD',[详细文档](https://day.js.org/docs/en/display/format) | N
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ export interface TdDatePickerProps {
/**
* 是否禁用组件
*/
disabled?: boolean;
disabled?: boolean | Array<boolean>;
/**
* 是否显示时间选择
* @default false
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,41 +7,41 @@
name | type | default | description | required
-- | -- | -- | -- | --
className | String | - | className of component | N
style | Object | - | CSS(Cascading Style Sheets),Typescript`React.CSSProperties` | N
style | Object | - | CSS(Cascading Style Sheets),Typescript: `React.CSSProperties` | N
activeIndex | Number | - | \- | N
borderless | Boolean | false | \- | N
clearable | Boolean | false | \- | N
disabled | Boolean | undefined | \- | N
format | Array / Function | - | Typescript`InputFormatType \| Array<InputFormatType>` | N
inputProps | Object / Array | - | Typescript`InputProps \| Array<InputProps>`,[Input API Documents](./input?tab=api)。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/range-input/type.ts) | N
label | TNode | - | Typescript`string \| TNode`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/common.ts) | N
placeholder | String / Array | - | Typescript`string \| Array<string>` | N
prefixIcon | TElement | - | Typescript`TNode`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/common.ts) | N
disabled | Boolean / Array | undefined | Typescript: `boolean \| Array<boolean>` | N
format | Array / Function | - | Typescript: `InputFormatType \| Array<InputFormatType>` | N
inputProps | Object / Array | - | Typescript: `InputProps \| Array<InputProps>`,[Input API Documents](./input?tab=api)。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/range-input/type.ts) | N
label | TNode | - | Typescript: `string \| TNode`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/common.ts) | N
placeholder | String / Array | - | Typescript: `string \| Array<string>` | N
prefixIcon | TElement | - | Typescript: `TNode`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/common.ts) | N
readonly | Boolean | undefined | \- | N
separator | TNode | '-' | Typescript`string \| TNode`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/common.ts) | N
separator | TNode | '-' | Typescript: `string \| TNode`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/common.ts) | N
showClearIconOnEmpty | Boolean | false | \- | N
size | String | medium | options: small/medium/large | N
status | String | default | options: default/success/warning/error | N
suffix | TNode | - | Typescript`string \| TNode`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/common.ts) | N
suffixIcon | TElement | - | Typescript`TNode`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/common.ts) | N
tips | TNode | - | Typescript`string \| TNode`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/common.ts) | N
value | Array | [] | Typescript`RangeInputValue` `type RangeInputValue = Array<InputValue>`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/range-input/type.ts) | N
defaultValue | Array | [] | uncontrolled property。Typescript`RangeInputValue` `type RangeInputValue = Array<InputValue>`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/range-input/type.ts) | N
onBlur | Function | | Typescript`(value: RangeInputValue, context?: { e?: FocusEvent; position?: RangeInputPosition }) => void`<br/> | N
onChange | Function | | Typescript`(value: RangeInputValue, context?: { e?: InputEvent \| MouseEvent \| CompositionEvent; position?: RangeInputPosition; trigger?: 'input' \| 'initial' \| 'clear' }) => void`<br/>[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/range-input/type.ts)。<br/>`type RangeInputPosition = 'first' \| 'second' \| 'all'`<br/> | N
onClear | Function | | Typescript`(context: { e: MouseEvent }) => void`<br/> | N
onClick | Function | | Typescript`(context?: { e?: MouseEvent; position?: RangeInputPosition }) => void`<br/> | N
onEnter | Function | | Typescript`(value: RangeInputValue, context?: { e?: InputEvent \| MouseEvent; position?: RangeInputPosition }) => void`<br/> | N
onFocus | Function | | Typescript`(value: RangeInputValue, context?: { e?: FocusEvent; position?: RangeInputPosition }) => void`<br/> | N
onMouseenter | Function | | Typescript`(context: { e: MouseEvent }) => void`<br/>trigger on mouseenter | N
onMouseleave | Function | | Typescript`(context: { e: MouseEvent }) => void`<br/> | N
suffix | TNode | - | Typescript: `string \| TNode`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/common.ts) | N
suffixIcon | TElement | - | Typescript: `TNode`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/common.ts) | N
tips | TNode | - | Typescript: `string \| TNode`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/common.ts) | N
value | Array | [] | Typescript: `RangeInputValue` `type RangeInputValue = Array<InputValue>`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/range-input/type.ts) | N
defaultValue | Array | [] | uncontrolled property。Typescript: `RangeInputValue` `type RangeInputValue = Array<InputValue>`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/range-input/type.ts) | N
onBlur | Function | | Typescript: `(value: RangeInputValue, context?: { e?: FocusEvent; position?: RangeInputPosition }) => void`<br/> | N
onChange | Function | | Typescript: `(value: RangeInputValue, context?: { e?: InputEvent \| MouseEvent \| CompositionEvent; position?: RangeInputPosition; trigger?: 'input' \| 'initial' \| 'clear' }) => void`<br/>[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/range-input/type.ts)。<br/>`type RangeInputPosition = 'first' \| 'second' \| 'all'`<br/> | N
onClear | Function | | Typescript: `(context: { e: MouseEvent }) => void`<br/> | N
onClick | Function | | Typescript: `(context?: { e?: MouseEvent; position?: RangeInputPosition }) => void`<br/> | N
onEnter | Function | | Typescript: `(value: RangeInputValue, context?: { e?: InputEvent \| MouseEvent; position?: RangeInputPosition }) => void`<br/> | N
onFocus | Function | | Typescript: `(value: RangeInputValue, context?: { e?: FocusEvent; position?: RangeInputPosition }) => void`<br/> | N
onMouseenter | Function | | Typescript: `(context: { e: MouseEvent }) => void`<br/>trigger on mouseenter | N
onMouseleave | Function | | Typescript: `(context: { e: MouseEvent }) => void`<br/> | N

### RangeInputInstanceFunctions 组件实例方法

name | params | return | description
-- | -- | -- | --
className | String | - | className of component | N
style | Object | - | CSS(Cascading Style Sheets),Typescript`React.CSSProperties` | N
style | Object | - | CSS(Cascading Style Sheets),Typescript: `React.CSSProperties` | N
blur | `(options?: {position?: RangeInputPosition})` | \- | \-
focus | `(options?: {position?: RangeInputPosition})` | \- | \-
select | `(options?: {position?: RangeInputPosition})` | \- | \-
Expand All @@ -52,19 +52,19 @@ select | `(options?: {position?: RangeInputPosition})` | \- | \-
name | type | default | description | required
-- | -- | -- | -- | --
className | String | - | className of component | N
style | Object | - | CSS(Cascading Style Sheets),Typescript`React.CSSProperties` | N
style | Object | - | CSS(Cascading Style Sheets),Typescript: `React.CSSProperties` | N
autoWidth | Boolean | false | \- | N
disabled | Boolean | - | \- | N
inputValue | Array | - | Typescript`RangeInputValue` | N
defaultInputValue | Array | - | uncontrolled property。Typescript`RangeInputValue` | N
label | TNode | - | Typescript`string \| TNode`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/common.ts) | N
panel | TNode | - | Typescript`string \| TNode`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/common.ts) | N
popupProps | Object | - | Typescript`PopupProps`,[Popup API Documents](./popup?tab=api)。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/range-input/type.ts) | N
inputValue | Array | - | Typescript: `RangeInputValue` | N
defaultInputValue | Array | - | uncontrolled property。Typescript: `RangeInputValue` | N
label | TNode | - | Typescript: `string \| TNode`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/common.ts) | N
panel | TNode | - | Typescript: `string \| TNode`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/common.ts) | N
popupProps | Object | - | Typescript: `PopupProps`,[Popup API Documents](./popup?tab=api)。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/range-input/type.ts) | N
popupVisible | Boolean | - | \- | N
defaultPopupVisible | Boolean | - | uncontrolled property | N
rangeInputProps | Object | - | Typescript`RangeInputProps`,[RangeInput API Documents](./range-input?tab=api)。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/range-input/type.ts) | N
rangeInputProps | Object | - | Typescript: `RangeInputProps`,[RangeInput API Documents](./range-input?tab=api)。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/range-input/type.ts) | N
readonly | Boolean | undefined | \- | N
status | String | default | options: default/success/warning/error | N
tips | TNode | - | Typescript`string \| TNode`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/common.ts) | N
onInputChange | Function | | Typescript`(value: RangeInputValue, context?: RangeInputValueChangeContext) => void`<br/>[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/range-input/type.ts)。<br/>`type RangeInputValueChangeContext = { e?: InputEvent \| MouseEvent; trigger?: 'input' \| 'clear', position?: RangeInputPosition }`<br/> | N
onPopupVisibleChange | Function | | Typescript`(visible: boolean, context: PopupVisibleChangeContext) => void`<br/>[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/range-input/type.ts)。<br/>`import { PopupVisibleChangeContext } from '@Popup'`<br/> | N
tips | TNode | - | Typescript: `string \| TNode`。[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/common.ts) | N
onInputChange | Function | | Typescript: `(value: RangeInputValue, context?: RangeInputValueChangeContext) => void`<br/>[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/range-input/type.ts)。<br/>`type RangeInputValueChangeContext = { e?: InputEvent \| MouseEvent; trigger?: 'input' \| 'clear', position?: RangeInputPosition }`<br/> | N
onPopupVisibleChange | Function | | Typescript: `(visible: boolean, context: PopupVisibleChangeContext) => void`<br/>[see more ts definition](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/range-input/type.ts)。<br/>`import { PopupVisibleChangeContext } from '@Popup'`<br/> | N
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ style | Object | - | 样式,TS 类型:`React.CSSProperties` | N
activeIndex | Number | - | 输入框高亮状态序号 | N
borderless | Boolean | false | 无边框模式 | N
clearable | Boolean | false | 是否可清空 | N
disabled | Boolean | undefined | 是否禁用范围输入框 | N
disabled | Boolean / Array | undefined | 是否禁用范围输入框。TS 类型:`boolean \| Array<boolean>` | N
format | Array / Function | - | 指定输入框展示值的格式。TS 类型:`InputFormatType \| Array<InputFormatType>` | N
inputProps | Object / Array | - | 透传 Input 输入框组件全部属性,数组第一项表示第一个输入框属性,第二项表示第二个输入框属性。示例:`[{ label: 'A', name: 'A-name' }, { label: 'B', name: 'B-name' }]`。TS 类型:`InputProps \| Array<InputProps>`,[Input API Documents](./input?tab=api)。[详细类型定义](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/range-input/type.ts) | N
label | TNode | - | 左侧内容。TS 类型:`string \| TNode`。[通用类型定义](https://github.com/Tencent/tdesign-react/blob/develop/packages/components/common.ts) | N
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ export interface TdRangeInputProps {
/**
* 是否禁用范围输入框
*/
disabled?: boolean;
disabled?: boolean | Array<boolean>;
/**
* 指定输入框展示值的格式
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ clearable | Boolean | false | \- | N
defaultTime | String | '00:00:00' | Time selector default value | N
disableDate | Object / Array / Function | - | Typescript: `DisableDate` `type DisableDate = Array<DateValue> \| DisableDateObj \| ((date: DateValue) => boolean)` `interface DisableDateObj { from?: string; to?: string; before?: string; after?: string }`。[see more ts definition](https://github.com/Tencent/tdesign-vue-next/blob/develop/packages/components/date-picker/type.ts) | N
disableTime | Function | - | disable time config function。Typescript: `(time: Date) => Partial<{ hour: Array<number>, minute: Array<number>, second: Array<number>, millisecond: Array<number> }>` | N
disabled | Boolean | undefined | make DatePicker to be disabled | N
disabled | Boolean / Array | undefined | make DatePicker to be disabled。Typescript: `boolean \| Array<boolean>` | N
enableTimePicker | Boolean | false | \- | N
firstDayOfWeek | Number | 7 | options: 1/2/3/4/5/6/7 | N
format | String | 'YYYY-MM-DD' | \- | N
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ clearable | Boolean | false | 是否显示清除按钮 | N
defaultTime | String | '00:00:00' | 时间选择器默认值,当 value/defaultValue 未设置值时有效 | N
disableDate | Object / Array / Function | - | 禁用日期,示例:['A', 'B'] 表示日期 A 和日期 B 会被禁用。`{ from: 'A', to: 'B' }` 表示在 A 到 B 之间的日期会被禁用。`{ before: 'A', after: 'B' }` 表示在 A 之前和在 B 之后的日期都会被禁用。其中 A = '2021-01-01',B = '2021-02-01'。值类型为 Function 则表示返回值为 true 的日期会被禁用。TS 类型:`DisableDate` `type DisableDate = Array<DateValue> \| DisableDateObj \| ((date: DateValue) => boolean)` `interface DisableDateObj { from?: string; to?: string; before?: string; after?: string }`。[详细类型定义](https://github.com/Tencent/tdesign-vue-next/blob/develop/packages/components/date-picker/type.ts) | N
disableTime | Function | - | 禁用时间项的配置函数,仅在日期时间选择器中可用。TS 类型:`(time: Date) => Partial<{ hour: Array<number>, minute: Array<number>, second: Array<number>, millisecond: Array<number> }>` | N
disabled | Boolean | undefined | 是否禁用组件 | N
disabled | Boolean / Array | undefined | 是否禁用组件。TS 类型:`boolean \| Array<boolean>` | N
enableTimePicker | Boolean | false | 是否显示时间选择 | N
firstDayOfWeek | Number | 7 | 第一天从星期几开始。可选项:1/2/3/4/5/6/7 | N
format | String | 'YYYY-MM-DD' | 仅用于格式化日期显示的格式,不影响日期值。注意和 `valueType` 的区别,`valueType`会直接决定日期值 `value` 的格式。全局配置默认为:'YYYY-MM-DD',[详细文档](https://day.js.org/docs/en/display/format) | N
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ export default {
},
/** 是否禁用组件 */
disabled: {
type: Boolean,
default: undefined,
type: [Boolean, Array] as PropType<TdDatePickerProps['disabled']>,
default: undefined as TdDatePickerProps['disabled'],
},
/** 是否显示时间选择 */
enableTimePicker: Boolean,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ export interface TdDatePickerProps {
/**
* 是否禁用组件
*/
disabled?: boolean;
disabled?: boolean | Array<boolean>;
/**
* 是否显示时间选择
* @default false
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ export default {
clearable: Boolean,
/** 是否禁用范围输入框 */
disabled: {
type: Boolean,
default: undefined,
type: [Boolean, Array] as PropType<TdRangeInputProps['disabled']>,
default: undefined as TdRangeInputProps['disabled'],
},
/** 指定输入框展示值的格式 */
format: {
Expand Down
Loading