Merge branch 'feat-vue3' of github.com:vueComponent/ant-design-vue into feat-vue3
commit
9eebd8da23
|
@ -2,6 +2,7 @@
|
|||
// Definitions by: akki-jat <https://github.com/akki-jat>
|
||||
// Definitions: https://github.com/vueComponent/ant-design-vue/types
|
||||
|
||||
import { VNodeChild, CSSProperties } from 'vue';
|
||||
import { AntdComponent } from './component';
|
||||
import { Meta } from './meta';
|
||||
|
||||
|
@ -11,91 +12,93 @@ export declare class Card extends AntdComponent {
|
|||
static Grid: any;
|
||||
static Meta: typeof Meta;
|
||||
|
||||
tabBarExtraContent: any;
|
||||
/**
|
||||
* The action list, shows at the bottom of the Card.
|
||||
* @type any (slots)
|
||||
*/
|
||||
actions: any;
|
||||
$props: {
|
||||
tabBarExtraContent: any;
|
||||
/**
|
||||
* The action list, shows at the bottom of the Card.
|
||||
* @type any (slots)
|
||||
*/
|
||||
actions: VNodeChild | JSX.Element;
|
||||
|
||||
/**
|
||||
* Current TabPane's key
|
||||
* @type string
|
||||
*/
|
||||
activeTabKey: string;
|
||||
/**
|
||||
* Current TabPane's key
|
||||
* @type string
|
||||
*/
|
||||
activeTabKey?: string;
|
||||
|
||||
/**
|
||||
* Inline style to apply to the card head
|
||||
* @type object
|
||||
*/
|
||||
headStyle: object;
|
||||
/**
|
||||
* Inline style to apply to the card head
|
||||
* @type object
|
||||
*/
|
||||
headStyle?: CSSProperties;
|
||||
|
||||
/**
|
||||
* Inline style to apply to the card content
|
||||
* @type object
|
||||
*/
|
||||
bodyStyle: object;
|
||||
/**
|
||||
* Inline style to apply to the card content
|
||||
* @type object
|
||||
*/
|
||||
bodyStyle?: CSSProperties;
|
||||
|
||||
/**
|
||||
* Toggles rendering of the border around the card
|
||||
* @default true
|
||||
* @type boolean
|
||||
*/
|
||||
bordered: boolean;
|
||||
/**
|
||||
* Toggles rendering of the border around the card
|
||||
* @default true
|
||||
* @type boolean
|
||||
*/
|
||||
bordered?: boolean;
|
||||
|
||||
/**
|
||||
* Card cover
|
||||
* @type any (slot)
|
||||
*/
|
||||
cover: any;
|
||||
/**
|
||||
* Card cover
|
||||
* @type any (slot)
|
||||
*/
|
||||
cover?: VNodeChild | JSX.Element;
|
||||
|
||||
/**
|
||||
* Initial active TabPane's key, if activeTabKey is not set.
|
||||
* @type string
|
||||
*/
|
||||
defaultActiveTabKey: string;
|
||||
/**
|
||||
* Initial active TabPane's key, if activeTabKey is not set.
|
||||
* @type string
|
||||
*/
|
||||
defaultActiveTabKey?: string;
|
||||
|
||||
/**
|
||||
* Content to render in the top-right corner of the card
|
||||
* @type any (string | slot)
|
||||
*/
|
||||
extra: any;
|
||||
/**
|
||||
* Content to render in the top-right corner of the card
|
||||
* @type any (string | slot)
|
||||
*/
|
||||
extra?: VNodeChild | JSX.Element;
|
||||
|
||||
/**
|
||||
* Lift up when hovering card
|
||||
* @default false
|
||||
* @type boolean
|
||||
*/
|
||||
hoverable: boolean;
|
||||
/**
|
||||
* Lift up when hovering card
|
||||
* @default false
|
||||
* @type boolean
|
||||
*/
|
||||
hoverable?: boolean;
|
||||
|
||||
/**
|
||||
* Shows a loading indicator while the contents of the card are being fetched
|
||||
* @default false
|
||||
* @type boolean
|
||||
*/
|
||||
loading: boolean;
|
||||
/**
|
||||
* Shows a loading indicator while the contents of the card are being fetched
|
||||
* @default false
|
||||
* @type boolean
|
||||
*/
|
||||
loading?: boolean;
|
||||
|
||||
/**
|
||||
* List of TabPane's head, Custom tabs can be created with the scopedSlots property
|
||||
* @type Array<{key: string, tab: any, scopedSlots: {tab: string}}>
|
||||
*/
|
||||
tabList: Array<{ key: string; tab: any; scopedSlots: { tab: string } }>;
|
||||
/**
|
||||
* List of TabPane's head, Custom tabs can be created with the scopedSlots property
|
||||
* @type Array<{key: string, tab: any, scopedSlots: {tab: string}}>
|
||||
*/
|
||||
tabList?: Array<{ key: string; tab: any; scopedSlots: { tab: string } }>;
|
||||
|
||||
/**
|
||||
* Card title
|
||||
* @type any (string | slot)
|
||||
*/
|
||||
title: any;
|
||||
/**
|
||||
* Card title
|
||||
* @type any (string | slot)
|
||||
*/
|
||||
title?: VNodeChild | JSX.Element;
|
||||
|
||||
/**
|
||||
* Card style type, can be set to inner or not set
|
||||
* @type string
|
||||
*/
|
||||
type: string;
|
||||
/**
|
||||
* Card style type, can be set to inner or not set
|
||||
* @type string
|
||||
*/
|
||||
type?: string;
|
||||
|
||||
/**
|
||||
* Size of card
|
||||
* @type string
|
||||
*/
|
||||
size: CardSize;
|
||||
/**
|
||||
* Size of card
|
||||
* @type string
|
||||
*/
|
||||
size?: CardSize;
|
||||
};
|
||||
}
|
||||
|
|
|
@ -16,12 +16,12 @@ export declare class Meta {
|
|||
* The description of list item
|
||||
* @type any (string | slot)
|
||||
*/
|
||||
description?: string | VNodeChild;
|
||||
description?: VNodeChild | JSX.Element;
|
||||
|
||||
/**
|
||||
* The title of list item
|
||||
* @type any (string | slot)
|
||||
*/
|
||||
title?: string | VNodeChild;
|
||||
title?: VNodeChild | JSX.Element;
|
||||
};
|
||||
}
|
||||
|
|
|
@ -4,7 +4,8 @@
|
|||
|
||||
import { TooltipCommon } from './tootip/common';
|
||||
import { VNodeChild } from 'vue';
|
||||
export declare class Popconfirm extends TooltipCommon {
|
||||
import { AntdComponent } from './component';
|
||||
export declare class Popconfirm extends AntdComponent {
|
||||
$props: {
|
||||
/**
|
||||
* text of the Cancel button
|
||||
|
@ -45,6 +46,6 @@ export declare class Popconfirm extends TooltipCommon {
|
|||
* @type boolean
|
||||
*/
|
||||
disabled?: boolean;
|
||||
}
|
||||
} & TooltipCommon
|
||||
|
||||
}
|
||||
|
|
|
@ -4,7 +4,8 @@
|
|||
|
||||
import { TooltipCommon } from './tootip/common';
|
||||
import { VNodeChild } from 'vue';
|
||||
export declare class Popover extends TooltipCommon {
|
||||
import { AntdComponent } from './component';
|
||||
export declare class Popover extends AntdComponent {
|
||||
$props: {
|
||||
/**
|
||||
* Content of the card
|
||||
|
@ -17,5 +18,5 @@ export declare class Popover extends TooltipCommon {
|
|||
* @type any (string | slot | VNode)
|
||||
*/
|
||||
title?: VNodeChild | JSX.Element;
|
||||
}
|
||||
} & TooltipCommon
|
||||
}
|
||||
|
|
|
@ -3,24 +3,27 @@
|
|||
// Definitions: https://github.com/vueComponent/ant-design-vue/types
|
||||
|
||||
import { AntdComponent } from '../component';
|
||||
import { VNodeChild } from 'vue';
|
||||
|
||||
export declare class TabPane extends AntdComponent {
|
||||
/**
|
||||
* Forced render of content in tabs, not lazy render after clicking on tabs
|
||||
* @default false
|
||||
* @type boolean
|
||||
*/
|
||||
forceRender: boolean;
|
||||
$props: {
|
||||
/**
|
||||
* Forced render of content in tabs, not lazy render after clicking on tabs
|
||||
* @default false
|
||||
* @type boolean
|
||||
*/
|
||||
forceRender?: boolean;
|
||||
|
||||
/**
|
||||
* TabPane's key
|
||||
* @type string
|
||||
*/
|
||||
key: string;
|
||||
/**
|
||||
* TabPane's key
|
||||
* @type string
|
||||
*/
|
||||
key?: string;
|
||||
|
||||
/**
|
||||
* Show text in TabPane's head
|
||||
* @type any (string | slot)
|
||||
*/
|
||||
tab: any;
|
||||
/**
|
||||
* Show text in TabPane's head
|
||||
* @type any (string | slot)
|
||||
*/
|
||||
tab?: VNodeChild | JSX.Element;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -4,72 +4,74 @@
|
|||
|
||||
import { AntdComponent } from '../component';
|
||||
import { TabPane } from './tab-pane';
|
||||
import { CSSProperties, VNodeChild } from 'vue';
|
||||
|
||||
export declare class Tabs extends AntdComponent {
|
||||
static TabPane: typeof TabPane;
|
||||
$props: {
|
||||
/**
|
||||
* Current TabPane's key
|
||||
* @type string
|
||||
*/
|
||||
activeKey?: string;
|
||||
|
||||
/**
|
||||
* Current TabPane's key
|
||||
* @type string
|
||||
*/
|
||||
activeKey: string;
|
||||
/**
|
||||
* Whether to change tabs with animation. Only works while tabPosition="top"\|"bottom"
|
||||
* @default true, false when type="card"
|
||||
* @type boolean | object
|
||||
*/
|
||||
animated?: boolean | { inkBar: boolean; tabPane: boolean };
|
||||
|
||||
/**
|
||||
* Whether to change tabs with animation. Only works while tabPosition="top"\|"bottom"
|
||||
* @default true, false when type="card"
|
||||
* @type boolean | object
|
||||
*/
|
||||
animated: boolean | { inkBar: boolean; tabPane: boolean };
|
||||
/**
|
||||
* Initial active TabPane's key, if activeKey is not set.
|
||||
* @type string
|
||||
*/
|
||||
defaultActiveKey?: string;
|
||||
|
||||
/**
|
||||
* Initial active TabPane's key, if activeKey is not set.
|
||||
* @type string
|
||||
*/
|
||||
defaultActiveKey: string;
|
||||
/**
|
||||
* Hide plus icon or not. Only works while type="editable-card"
|
||||
* @default false
|
||||
* @type boolean
|
||||
*/
|
||||
hideAdd?: boolean;
|
||||
|
||||
/**
|
||||
* Hide plus icon or not. Only works while type="editable-card"
|
||||
* @default false
|
||||
* @type boolean
|
||||
*/
|
||||
hideAdd: boolean;
|
||||
/**
|
||||
* preset tab bar size
|
||||
* @default 'default'
|
||||
* @type string
|
||||
*/
|
||||
size?: 'default' | 'small' | 'large';
|
||||
|
||||
/**
|
||||
* preset tab bar size
|
||||
* @default 'default'
|
||||
* @type string
|
||||
*/
|
||||
size: 'default' | 'small' | 'large';
|
||||
/**
|
||||
* Extra content in tab bar
|
||||
* @type any
|
||||
*/
|
||||
tabBarExtraContent?: VNodeChild | JSX.Element;
|
||||
|
||||
/**
|
||||
* Extra content in tab bar
|
||||
* @type any
|
||||
*/
|
||||
tabBarExtraContent: any;
|
||||
/**
|
||||
* Tab bar style object
|
||||
* @type object
|
||||
*/
|
||||
tabBarStyle?: CSSProperties;
|
||||
|
||||
/**
|
||||
* Tab bar style object
|
||||
* @type object
|
||||
*/
|
||||
tabBarStyle: object;
|
||||
/**
|
||||
* Position of tabs
|
||||
* @default 'top'
|
||||
* @type string
|
||||
*/
|
||||
tabPosition?: 'top' | 'right' | 'bottom' | 'left';
|
||||
|
||||
/**
|
||||
* Position of tabs
|
||||
* @default 'top'
|
||||
* @type string
|
||||
*/
|
||||
tabPosition: 'top' | 'right' | 'bottom' | 'left';
|
||||
/**
|
||||
* Basic style of tabs
|
||||
* @default 'line'
|
||||
* @type string
|
||||
*/
|
||||
type?: 'line' | 'card' | 'editable-card';
|
||||
|
||||
/**
|
||||
* Basic style of tabs
|
||||
* @default 'line'
|
||||
* @type string
|
||||
*/
|
||||
type: 'line' | 'card' | 'editable-card';
|
||||
|
||||
/**
|
||||
* The gap between tabs
|
||||
* @type number
|
||||
*/
|
||||
tabBarGutter: number;
|
||||
/**
|
||||
* The gap between tabs
|
||||
* @type number
|
||||
*/
|
||||
tabBarGutter?: number;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -2,72 +2,72 @@
|
|||
// Definitions by: akki-jat <https://github.com/akki-jat>
|
||||
// Definitions: https://github.com/vueComponent/ant-design-vue/types
|
||||
|
||||
import { AntdComponent } from '../component';
|
||||
|
||||
import { CSSProperties } from 'vue';
|
||||
export declare type triggerType = 'hover' | 'focus' | 'click' | 'contextmenu';
|
||||
|
||||
export declare class TooltipCommon extends AntdComponent {
|
||||
/**
|
||||
* Whether the arrow is pointed at the center of target
|
||||
* @default false
|
||||
* @type boolean
|
||||
*/
|
||||
arrowPointAtCenter: boolean;
|
||||
export declare class TooltipCommon {
|
||||
// $props: {
|
||||
/**
|
||||
* Whether the arrow is pointed at the center of target
|
||||
* @default false
|
||||
* @type boolean
|
||||
*/
|
||||
arrowPointAtCenter?: boolean;
|
||||
|
||||
/**
|
||||
* Whether to adjust popup placement automatically when popup is off screen
|
||||
* @default true
|
||||
* @type boolean
|
||||
*/
|
||||
autoAdjustOverflow: boolean | object;
|
||||
/**
|
||||
* Whether to adjust popup placement automatically when popup is off screen
|
||||
* @default true
|
||||
* @type boolean
|
||||
*/
|
||||
autoAdjustOverflow?: boolean | object;
|
||||
|
||||
/**
|
||||
* Whether the floating tooltip card is visible by default
|
||||
* @default false
|
||||
* @type boolean
|
||||
*/
|
||||
defaultVisible: boolean;
|
||||
/**
|
||||
* Whether the floating tooltip card is visible by default
|
||||
* @default false
|
||||
* @type boolean
|
||||
*/
|
||||
defaultVisible?: boolean;
|
||||
|
||||
/**
|
||||
* The DOM container of the tip, the default behavior is to create a div element in body.
|
||||
* @default () => document.body
|
||||
* @type Function
|
||||
*/
|
||||
getPopupContainer: (triggerNode: any) => any;
|
||||
/**
|
||||
* The DOM container of the tip, the default behavior is to create a div element in body.
|
||||
* @default () => document.body
|
||||
* @type Function
|
||||
*/
|
||||
getPopupContainer?: (triggerNode: HTMLElement) => HTMLElement;
|
||||
|
||||
/**
|
||||
* Delay in seconds, before tooltip is shown on mouse enter
|
||||
* @default 0
|
||||
* @type number
|
||||
*/
|
||||
mouseEnterDelay: number;
|
||||
/**
|
||||
* Delay in seconds, before tooltip is shown on mouse enter
|
||||
* @default 0
|
||||
* @type number
|
||||
*/
|
||||
mouseEnterDelay?: number;
|
||||
|
||||
/**
|
||||
* Delay in seconds, before tooltip is hidden on mouse leave
|
||||
* @default 0.1
|
||||
* @type number
|
||||
*/
|
||||
mouseLeaveDelay: number;
|
||||
/**
|
||||
* Delay in seconds, before tooltip is hidden on mouse leave
|
||||
* @default 0.1
|
||||
* @type number
|
||||
*/
|
||||
mouseLeaveDelay?: number;
|
||||
|
||||
/**
|
||||
* Class name of the tooltip card
|
||||
* @type string
|
||||
*/
|
||||
overlayClassName: string;
|
||||
/**
|
||||
* Class name of the tooltip card
|
||||
* @type string
|
||||
*/
|
||||
overlayClassName?: string;
|
||||
|
||||
/**
|
||||
* Style of the tooltip card
|
||||
* @type undefined
|
||||
*/
|
||||
overlayStyle: object;
|
||||
/**
|
||||
* Style of the tooltip card
|
||||
* @type undefined
|
||||
*/
|
||||
overlayStyle?: CSSProperties;
|
||||
|
||||
/**
|
||||
* The position of the tooltip relative to the target, which can be one of top
|
||||
* left right bottom topLeft topRight bottomLeft bottomRight leftTop leftBottom rightTop rightBottom
|
||||
* @default 'top'
|
||||
* @type string
|
||||
*/
|
||||
placement:
|
||||
/**
|
||||
* The position of the tooltip relative to the target, which can be one of top
|
||||
* left right bottom topLeft topRight bottomLeft bottomRight leftTop leftBottom rightTop rightBottom
|
||||
* @default 'top'
|
||||
* @type string
|
||||
*/
|
||||
placement?:
|
||||
| 'top'
|
||||
| 'left'
|
||||
| 'right'
|
||||
|
@ -81,30 +81,31 @@ export declare class TooltipCommon extends AntdComponent {
|
|||
| 'rightTop'
|
||||
| 'rightBottom';
|
||||
|
||||
/**
|
||||
* Tooltip trigger mode
|
||||
* @default 'hover'
|
||||
* @type triggerType | triggerType[]
|
||||
*/
|
||||
trigger: triggerType | triggerType[];
|
||||
/**
|
||||
* Tooltip trigger mode
|
||||
* @default 'hover'
|
||||
* @type triggerType | triggerType[]
|
||||
*/
|
||||
trigger?: triggerType | triggerType[];
|
||||
|
||||
/**
|
||||
* Whether the floating tooltip card is visible or not
|
||||
* @default false
|
||||
* @type boolean
|
||||
*/
|
||||
visible: boolean;
|
||||
/**
|
||||
* Whether the floating tooltip card is visible or not
|
||||
* @default false
|
||||
* @type boolean
|
||||
*/
|
||||
visible?: boolean;
|
||||
|
||||
/**
|
||||
* Whether to destroy tooltip on hide
|
||||
* @default false
|
||||
* @type boolean
|
||||
*/
|
||||
destroyTooltipOnHide: boolean;
|
||||
/**
|
||||
* Whether to destroy tooltip on hide
|
||||
* @default false
|
||||
* @type boolean
|
||||
*/
|
||||
destroyTooltipOnHide?: boolean;
|
||||
|
||||
/**
|
||||
* this value will be merged into placement's config, please refer to the settings dom-align
|
||||
* @type object
|
||||
*/
|
||||
align: object;
|
||||
/**
|
||||
* this value will be merged into placement's config, please refer to the settings dom-align
|
||||
* @type object
|
||||
*/
|
||||
align?: unknown;
|
||||
// }
|
||||
}
|
||||
|
|
|
@ -2,13 +2,16 @@
|
|||
// Definitions by: akki-jat <https://github.com/akki-jat>
|
||||
// Definitions: https://github.com/vueComponent/ant-design-vue/types
|
||||
|
||||
import Vue from 'vue';
|
||||
import Vue, { VNodeChild } from 'vue';
|
||||
import { AntdComponent } from '../component';
|
||||
import { TooltipCommon } from './common';
|
||||
|
||||
export declare class Tooltip extends TooltipCommon {
|
||||
/**
|
||||
* The text shown in the tooltip
|
||||
* @type any (string | slot)
|
||||
*/
|
||||
title: any;
|
||||
export declare class Tooltip extends AntdComponent {
|
||||
$props: {
|
||||
/**
|
||||
* The text shown in the tooltip
|
||||
* @type any (string | slot)
|
||||
*/
|
||||
title: VNodeChild | JSX.Element
|
||||
} & TooltipCommon
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue