antdv-next 1.0.0-alpha.3 → 1.0.0-alpha.5
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/_util/ActionButton.js +22 -10
- package/dist/_util/ContextIsolator.js +4 -2
- package/dist/_util/tools.js +2 -1
- package/dist/_util/wave/WaveEffect.js +6 -1
- package/dist/_util/wave/index.js +6 -3
- package/dist/_util/wave/style.js +4 -3
- package/dist/affix/index.d.ts +3 -3
- package/dist/affix/index.js +14 -6
- package/dist/alert/Alert.d.ts +4 -3
- package/dist/alert/Alert.js +52 -26
- package/dist/anchor/Anchor.d.ts +5 -5
- package/dist/anchor/Anchor.js +28 -14
- package/dist/anchor/AnchorLink.js +14 -8
- package/dist/anchor/index.d.ts +1 -1
- package/dist/antd.js +86 -86
- package/dist/app/App.d.ts +2 -2
- package/dist/app/App.js +12 -5
- package/dist/auto-complete/index.d.ts +77 -0
- package/dist/auto-complete/index.js +627 -0
- package/dist/avatar/Avatar.d.ts +3 -3
- package/dist/avatar/Avatar.js +24 -12
- package/dist/avatar/AvatarGroup.d.ts +2 -2
- package/dist/avatar/AvatarGroup.js +10 -5
- package/dist/badge/Ribbon.d.ts +3 -3
- package/dist/badge/Ribbon.js +14 -6
- package/dist/badge/ScrollNumber.js +10 -5
- package/dist/badge/SingleNumber.js +6 -3
- package/dist/badge/index.d.ts +3 -3
- package/dist/badge/index.js +32 -15
- package/dist/breadcrumb/Breadcrumb.d.ts +5 -5
- package/dist/breadcrumb/Breadcrumb.js +24 -19
- package/dist/breadcrumb/BreadcrumbItem.d.ts +1 -1
- package/dist/breadcrumb/BreadcrumbItem.js +33 -33
- package/dist/breadcrumb/index.d.ts +1 -1
- package/dist/button/Button.d.ts +3 -3
- package/dist/button/Button.js +46 -22
- package/dist/button/DefaultLoadingIcon.js +12 -6
- package/dist/button/IconWrapper.js +2 -1
- package/dist/button/style/variant.js +116 -104
- package/dist/calendar/Header.js +81 -37
- package/dist/calendar/generateCalendar.js +44 -19
- package/dist/calendar/index.d.ts +3 -3
- package/dist/card/Card.d.ts +3 -3
- package/dist/card/Card.js +50 -25
- package/dist/card/CardGrid.d.ts +2 -2
- package/dist/card/CardGrid.js +4 -2
- package/dist/card/CardMeta.d.ts +3 -3
- package/dist/card/CardMeta.js +12 -6
- package/dist/carousel/index.d.ts +3 -3
- package/dist/carousel/index.js +112 -56
- package/dist/cascader/Panel.d.ts +3 -3
- package/dist/cascader/Panel.js +44 -17
- package/dist/cascader/index.d.ts +3 -3
- package/dist/cascader/index.js +175 -82
- package/dist/checkbox/Checkbox.d.ts +3 -3
- package/dist/checkbox/Checkbox.js +36 -17
- package/dist/checkbox/Group.d.ts +3 -3
- package/dist/checkbox/Group.js +16 -8
- package/dist/collapse/Collapse.d.ts +3 -3
- package/dist/collapse/Collapse.js +34 -17
- package/dist/color-picker/ColorPicker.d.ts +4 -4
- package/dist/color-picker/ColorPicker.js +58 -28
- package/dist/color-picker/ColorPickerPanel.js +74 -35
- package/dist/color-picker/components/ColorAlphaInput.js +6 -3
- package/dist/color-picker/components/ColorClear.js +8 -4
- package/dist/color-picker/components/ColorHexInput.js +6 -3
- package/dist/color-picker/components/ColorHsbInput.js +6 -3
- package/dist/color-picker/components/ColorInput.js +16 -7
- package/dist/color-picker/components/ColorPresets.js +8 -4
- package/dist/color-picker/components/ColorRgbInput.js +6 -3
- package/dist/color-picker/components/ColorSlider.js +58 -27
- package/dist/color-picker/components/ColorSteppers.js +14 -7
- package/dist/color-picker/components/ColorTrigger.js +20 -9
- package/dist/color-picker/components/PanelPicker/GradientColorBar.js +40 -19
- package/dist/components.d.ts +3 -2
- package/dist/components.js +7 -4
- package/dist/config-provider/SizeContext.js +2 -1
- package/dist/config-provider/context.js +2 -2
- package/dist/config-provider/defaultRenderEmpty.js +2 -1
- package/dist/config-provider/index.d.ts +3 -3
- package/dist/config-provider/index.js +304 -152
- package/dist/date-picker/PickerButton.js +46 -22
- package/dist/date-picker/generatePicker/SuffixIcon.js +8 -4
- package/dist/date-picker/generatePicker/generateRangePicker.js +555 -257
- package/dist/date-picker/generatePicker/generateSinglePicker.js +559 -257
- package/dist/date-picker/generatePicker/index.d.ts +15 -15
- package/dist/date-picker/index.d.ts +25 -25
- package/dist/descriptions/Cell.js +20 -10
- package/dist/descriptions/Row.js +16 -8
- package/dist/descriptions/index.d.ts +3 -3
- package/dist/descriptions/index.js +30 -15
- package/dist/divider/index.d.ts +2 -2
- package/dist/divider/index.js +26 -13
- package/dist/drawer/DrawerPanel.js +38 -18
- package/dist/drawer/index.d.ts +3 -3
- package/dist/drawer/index.js +130 -62
- package/dist/dropdown/dropdown.d.ts +4 -4
- package/dist/dropdown/dropdown.js +47 -24
- package/dist/empty/index.d.ts +3 -3
- package/dist/empty/index.js +12 -6
- package/dist/flex/index.d.ts +3 -3
- package/dist/flex/index.js +28 -9
- package/dist/float-button/BackTop.d.ts +3 -3
- package/dist/float-button/BackTop.js +36 -18
- package/dist/float-button/FloatButton.d.ts +3 -3
- package/dist/float-button/FloatButton.js +32 -16
- package/dist/float-button/FloatButtonGroup.d.ts +3 -3
- package/dist/float-button/FloatButtonGroup.js +42 -21
- package/dist/float-button/PurePanel.js +78 -39
- package/dist/float-button/style/button.js +4 -4
- package/dist/float-button/style/group.js +12 -12
- package/dist/form/ErrorList.js +12 -6
- package/dist/form/Form.d.ts +3 -3
- package/dist/form/Form.js +48 -24
- package/dist/form/FormItem/ItemHolder.js +66 -33
- package/dist/form/FormItem/StatusProvider.js +18 -8
- package/dist/form/FormItem/index.d.ts +3 -3
- package/dist/form/FormItem/index.js +56 -28
- package/dist/form/FormItemInput.js +24 -12
- package/dist/form/FormItemLabel.js +20 -10
- package/dist/form/context.js +10 -5
- package/dist/form/style/index.js +3 -2
- package/dist/grid/col.js +26 -13
- package/dist/grid/row.js +10 -5
- package/dist/grid/style/index.js +5 -4
- package/dist/image/PreviewGroup.d.ts +2 -2
- package/dist/image/PreviewGroup.js +20 -9
- package/dist/image/index.d.ts +4 -4
- package/dist/image/index.js +24 -12
- package/dist/index.d.ts +5 -4
- package/dist/index.js +5 -4
- package/dist/input/Group.js +6 -3
- package/dist/input/Input.js +71 -30
- package/dist/input/OTP/OTPInput.js +76 -33
- package/dist/input/OTP/index.js +37 -18
- package/dist/input/Password.js +76 -33
- package/dist/input/Search.js +80 -33
- package/dist/input/TextArea.d.ts +3 -3
- package/dist/input/TextArea.js +59 -26
- package/dist/input/index.d.ts +11 -11
- package/dist/input-number/index.d.ts +3 -3
- package/dist/input-number/index.js +89 -38
- package/dist/input-number/style/index.js +18 -17
- package/dist/layout/Sider.js +20 -10
- package/dist/layout/index.d.ts +6 -6
- package/dist/layout/layout.d.ts +2 -2
- package/dist/layout/layout.js +28 -14
- package/dist/locale/index.js +4 -2
- package/dist/masonry/Masonry.d.ts +3 -3
- package/dist/masonry/Masonry.js +28 -15
- package/dist/masonry/MasonryItem.js +18 -8
- package/dist/mentions/index.d.ts +3 -3
- package/dist/mentions/index.js +63 -29
- package/dist/mentions/style/index.js +18 -17
- package/dist/menu/MenuContext.js +2 -1
- package/dist/menu/MenuDivider.d.ts +2 -2
- package/dist/menu/MenuDivider.js +4 -2
- package/dist/menu/MenuItem.d.ts +3 -3
- package/dist/menu/MenuItem.js +38 -19
- package/dist/menu/OverrideContext.js +2 -1
- package/dist/menu/SubMenu.d.ts +3 -3
- package/dist/menu/SubMenu.js +40 -19
- package/dist/menu/index.d.ts +5 -5
- package/dist/menu/index.js +84 -37
- package/dist/menu/menu.js +88 -39
- package/dist/message/PurePanel.d.ts +2 -2
- package/dist/message/PurePanel.js +42 -20
- package/dist/message/index.js +6 -3
- package/dist/message/useMessage.js +26 -12
- package/dist/modal/ConfirmDialog.js +392 -184
- package/dist/modal/Modal.d.ts +3 -3
- package/dist/modal/Modal.js +102 -47
- package/dist/modal/confirm.js +116 -54
- package/dist/modal/shared.js +18 -9
- package/dist/modal/useModal/HookModal.js +8 -4
- package/dist/notification/PurePanel.d.ts +2 -2
- package/dist/notification/PurePanel.js +56 -27
- package/dist/notification/index.js +6 -3
- package/dist/notification/useNotification.js +34 -16
- package/dist/package.d.ts +109 -3
- package/dist/package.js +1 -1
- package/dist/pagination/Pagination.d.ts +3 -3
- package/dist/pagination/Pagination.js +69 -34
- package/dist/pagination/style/index.js +61 -50
- package/dist/popconfirm/PurePanel.d.ts +2 -2
- package/dist/popconfirm/PurePanel.js +68 -34
- package/dist/popconfirm/index.d.ts +3 -3
- package/dist/popconfirm/index.js +76 -35
- package/dist/popover/PurePanel.js +132 -60
- package/dist/popover/index.d.ts +3 -3
- package/dist/popover/index.js +60 -27
- package/dist/popover/style/index.js +11 -8
- package/dist/progress/Circle.js +52 -26
- package/dist/progress/Line.js +52 -26
- package/dist/progress/Steps.js +50 -25
- package/dist/progress/progress.d.ts +3 -3
- package/dist/progress/progress.js +50 -25
- package/dist/qrcode/QrcodeStatus.js +12 -5
- package/dist/qrcode/index.d.ts +3 -3
- package/dist/qrcode/index.js +48 -23
- package/dist/radio/group.js +34 -15
- package/dist/radio/index.d.ts +5 -5
- package/dist/radio/radio.d.ts +3 -3
- package/dist/radio/radio.js +36 -17
- package/dist/radio/radioButton.js +30 -14
- package/dist/rate/index.d.ts +3 -3
- package/dist/rate/index.js +34 -17
- package/dist/result/index.d.ts +3 -3
- package/dist/result/index.js +28 -12
- package/dist/result/noFound.d.ts +2 -2
- package/dist/result/serverError.d.ts +2 -2
- package/dist/result/unauthorized.d.ts +2 -2
- package/dist/segmented/index.d.ts +3 -3
- package/dist/segmented/index.js +36 -18
- package/dist/select/index.d.ts +6 -6
- package/dist/select/index.js +150 -74
- package/dist/select/style/select-input-multiple.js +31 -29
- package/dist/select/style/select-input.js +50 -44
- package/dist/skeleton/Avatar.d.ts +2 -2
- package/dist/skeleton/Avatar.js +10 -5
- package/dist/skeleton/Button.d.ts +2 -2
- package/dist/skeleton/Button.js +12 -6
- package/dist/skeleton/Element.js +10 -5
- package/dist/skeleton/Image.d.ts +2 -2
- package/dist/skeleton/Image.js +6 -3
- package/dist/skeleton/Input.d.ts +2 -2
- package/dist/skeleton/Input.js +10 -5
- package/dist/skeleton/Node.d.ts +3 -3
- package/dist/skeleton/Node.js +8 -4
- package/dist/skeleton/Paragraph.js +8 -4
- package/dist/skeleton/Skeleton.d.ts +3 -3
- package/dist/skeleton/Skeleton.js +20 -10
- package/dist/skeleton/Title.js +8 -4
- package/dist/slider/SliderTooltip.js +62 -28
- package/dist/slider/index.d.ts +3 -3
- package/dist/slider/index.js +60 -29
- package/dist/space/Addon.js +8 -4
- package/dist/space/Compact.d.ts +2 -0
- package/dist/space/Compact.js +37 -15
- package/dist/space/Item.js +8 -4
- package/dist/space/index.d.ts +5 -5
- package/dist/space/index.js +23 -12
- package/dist/space/style/addon.js +20 -19
- package/dist/space/style/compact.js +20 -0
- package/dist/spin/Indicator/Looper.js +4 -2
- package/dist/spin/Indicator/Progress.js +8 -4
- package/dist/spin/Indicator/index.js +6 -3
- package/dist/spin/index.d.ts +3 -3
- package/dist/spin/index.js +24 -12
- package/dist/splitter/Panel.js +18 -9
- package/dist/splitter/SplitBar.js +53 -24
- package/dist/splitter/Splitter.d.ts +3 -3
- package/dist/splitter/Splitter.js +22 -11
- package/dist/splitter/index.d.ts +2 -2
- package/dist/splitter/style/index.js +6 -6
- package/dist/statistic/Number.js +12 -6
- package/dist/statistic/Statistic.d.ts +3 -3
- package/dist/statistic/Statistic.js +30 -15
- package/dist/statistic/Timer.d.ts +5 -5
- package/dist/statistic/Timer.js +34 -17
- package/dist/statistic/index.d.ts +5 -5
- package/dist/steps/PanelArrow.js +2 -1
- package/dist/steps/ProgressIcon.js +13 -4
- package/dist/steps/index.d.ts +3 -3
- package/dist/steps/index.js +51 -26
- package/dist/steps/style/horizontal.js +13 -10
- package/dist/steps/style/icon.js +11 -8
- package/dist/steps/style/index.js +19 -18
- package/dist/steps/style/inline.js +19 -16
- package/dist/steps/style/label-placement.js +22 -20
- package/dist/steps/style/nav.js +7 -5
- package/dist/steps/style/panel.js +34 -32
- package/dist/steps/style/progress-dot.js +10 -8
- package/dist/steps/style/progress.js +29 -58
- package/dist/steps/style/rtl.js +6 -4
- package/dist/steps/style/small.js +10 -8
- package/dist/steps/style/status.js +124 -121
- package/dist/steps/style/util.js +7 -4
- package/dist/steps/style/vertical.js +17 -14
- package/dist/style/placementArrow.js +7 -5
- package/dist/switch/index.d.ts +3 -3
- package/dist/switch/index.js +34 -17
- package/dist/table/Column.d.ts +3 -3
- package/dist/table/Column.js +86 -41
- package/dist/table/ColumnGroup.d.ts +3 -3
- package/dist/table/ColumnGroup.js +84 -41
- package/dist/table/InternalTable.js +107 -53
- package/dist/table/Table.d.ts +3 -3
- package/dist/table/Table.js +104 -51
- package/dist/table/hooks/useFilter/FilterDropdown.js +39 -19
- package/dist/table/hooks/useFilter/FilterWrapper.js +4 -2
- package/dist/tabs/TabPane.d.ts +3 -3
- package/dist/tabs/index.d.ts +3 -3
- package/dist/tabs/index.js +62 -31
- package/dist/tag/CheckableTag.d.ts +3 -3
- package/dist/tag/CheckableTag.js +10 -5
- package/dist/tag/CheckableTagGroup.d.ts +3 -3
- package/dist/tag/CheckableTagGroup.js +28 -12
- package/dist/tag/index.d.ts +3 -3
- package/dist/tag/index.js +30 -14
- package/dist/theme/index.d.ts +4 -4
- package/dist/theme/util/genStyleUtils.js +8 -5
- package/dist/time-picker/index.d.ts +7 -7
- package/dist/time-picker/index.js +1106 -509
- package/dist/timeline/Timeline.d.ts +3 -3
- package/dist/timeline/Timeline.js +20 -10
- package/dist/timeline/TimelineItem.js +22 -10
- package/dist/timeline/TimelineItemList.js +24 -12
- package/dist/tooltip/PurePanel.d.ts +2 -2
- package/dist/tooltip/PurePanel.js +61 -29
- package/dist/tooltip/UniqueProvider/index.d.ts +2 -2
- package/dist/tooltip/index.d.ts +3 -3
- package/dist/tooltip/index.js +62 -30
- package/dist/tooltip/style/index.js +10 -8
- package/dist/tooltip/util.js +5 -3
- package/dist/tour/index.d.ts +3 -3
- package/dist/tour/index.js +52 -25
- package/dist/tour/panelRender.js +18 -9
- package/dist/tour/style/index.js +5 -4
- package/dist/transfer/Actions.d.ts +2 -2
- package/dist/transfer/Actions.js +36 -18
- package/dist/transfer/ListBody.js +76 -38
- package/dist/transfer/ListItem.js +22 -11
- package/dist/transfer/Section.d.ts +2 -2
- package/dist/transfer/Section.js +76 -38
- package/dist/transfer/Transfer.d.ts +3 -3
- package/dist/transfer/Transfer.js +53 -27
- package/dist/transfer/search.js +8 -4
- package/dist/tree/DirectoryTree.d.ts +3 -3
- package/dist/tree/DirectoryTree.js +90 -45
- package/dist/tree/Tree.d.ts +3 -3
- package/dist/tree/Tree.js +90 -45
- package/dist/tree/utils/iconUtil.js +10 -5
- package/dist/tree-select/index.d.ts +4 -4
- package/dist/tree-select/index.js +195 -95
- package/dist/typography/Base/CopyBtn.js +24 -12
- package/dist/typography/Base/Ellipsis.js +16 -8
- package/dist/typography/Base/EllipsisTooltip.js +6 -3
- package/dist/typography/Base/index.js +42 -20
- package/dist/typography/Editable.js +28 -13
- package/dist/typography/Link.d.ts +3 -3
- package/dist/typography/Link.js +48 -23
- package/dist/typography/Paragraph.d.ts +3 -3
- package/dist/typography/Paragraph.js +42 -20
- package/dist/typography/Text.js +42 -20
- package/dist/typography/Title.d.ts +3 -3
- package/dist/typography/Title.js +42 -20
- package/dist/typography/Typography.d.ts +3 -3
- package/dist/typography/Typography.js +16 -7
- package/dist/typography/index.d.ts +9 -9
- package/dist/upload/Dragger.d.ts +6 -3
- package/dist/upload/Dragger.js +76 -38
- package/dist/upload/Upload.d.ts +3 -3
- package/dist/upload/Upload.js +74 -37
- package/dist/upload/UploadList/ListItem.js +44 -22
- package/dist/upload/UploadList/index.js +50 -24
- package/dist/upload/index.d.ts +6 -3
- package/dist/watermark/index.d.ts +2 -2
- package/dist/watermark/index.js +22 -11
- package/global.d.ts +2 -0
- package/package.json +22 -4
- package/web-tags.json +4524 -0
- package/web-types.json +12779 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import genPresetColor from "../../theme/util/genPresetColor.js";
|
|
2
2
|
import { resetComponent } from "../../style/index.js";
|
|
3
|
-
import { genStyleHooks } from "../../theme/util/genStyleUtils.js";
|
|
3
|
+
import { genCssVar, genStyleHooks } from "../../theme/util/genStyleUtils.js";
|
|
4
4
|
import { mergeToken } from "../../theme/internal.js";
|
|
5
5
|
import { getArrowToken } from "../../style/roundedArrow.js";
|
|
6
6
|
import getArrowStyle, { MAX_VERTICAL_CONTENT_RADIUS, getArrowOffsetToken } from "../../style/placementArrow.js";
|
|
@@ -10,14 +10,16 @@ import "../../style/motion/index.js";
|
|
|
10
10
|
import { unit } from "@antdv-next/cssinjs";
|
|
11
11
|
|
|
12
12
|
//#region src/tooltip/style/index.ts
|
|
13
|
+
const FALL_BACK_ORIGIN = "50%";
|
|
13
14
|
const genTooltipStyle = (token) => {
|
|
14
|
-
const { calc, componentCls, tooltipMaxWidth, tooltipColor, tooltipBg, tooltipBorderRadius, zIndexPopup, controlHeight, boxShadowSecondary, paddingSM, paddingXS, arrowOffsetHorizontal, sizePopupArrow } = token;
|
|
15
|
+
const { calc, componentCls, tooltipMaxWidth, tooltipColor, tooltipBg, tooltipBorderRadius, zIndexPopup, controlHeight, boxShadowSecondary, paddingSM, paddingXS, arrowOffsetHorizontal, sizePopupArrow, antCls } = token;
|
|
16
|
+
const [varName, varRef] = genCssVar(antCls, "tooltip");
|
|
15
17
|
const edgeAlignMinWidth = calc(tooltipBorderRadius).add(sizePopupArrow).add(arrowOffsetHorizontal).equal();
|
|
16
18
|
const sharedBodyStyle = {
|
|
17
19
|
minWidth: calc(tooltipBorderRadius).mul(2).add(sizePopupArrow).equal(),
|
|
18
20
|
minHeight: controlHeight,
|
|
19
21
|
padding: `${unit(token.calc(paddingSM).div(2).equal())} ${unit(paddingXS)}`,
|
|
20
|
-
color:
|
|
22
|
+
color: varRef("overlay-color", tooltipColor),
|
|
21
23
|
textAlign: "start",
|
|
22
24
|
textDecoration: "none",
|
|
23
25
|
wordWrap: "break-word",
|
|
@@ -27,8 +29,8 @@ const genTooltipStyle = (token) => {
|
|
|
27
29
|
boxSizing: "border-box"
|
|
28
30
|
};
|
|
29
31
|
const sharedTransformOrigin = {
|
|
30
|
-
"
|
|
31
|
-
|
|
32
|
+
[varName("valid-offset-x")]: varRef("arrow-offset-horizontal", "var(--arrow-x)"),
|
|
33
|
+
transformOrigin: [varRef("valid-offset-x", FALL_BACK_ORIGIN), `var(--arrow-y, ${FALL_BACK_ORIGIN})`].join(" ")
|
|
32
34
|
};
|
|
33
35
|
return [
|
|
34
36
|
{ [componentCls]: {
|
|
@@ -41,7 +43,7 @@ const genTooltipStyle = (token) => {
|
|
|
41
43
|
"visibility": "visible",
|
|
42
44
|
...sharedTransformOrigin,
|
|
43
45
|
"&-hidden": { display: "none" },
|
|
44
|
-
"
|
|
46
|
+
[varName("arrow-background-color")]: tooltipBg,
|
|
45
47
|
[`${componentCls}-container`]: [sharedBodyStyle, initFadeMotion(token, true)],
|
|
46
48
|
[`&:has(~ ${componentCls}-unique-container)`]: { [`${componentCls}-container`]: {
|
|
47
49
|
border: "none",
|
|
@@ -65,11 +67,11 @@ const genTooltipStyle = (token) => {
|
|
|
65
67
|
[`${componentCls}-content`]: { position: "relative" },
|
|
66
68
|
...genPresetColor(token, (colorKey, { darkColor }) => ({ [`&${componentCls}-${colorKey}`]: {
|
|
67
69
|
[`${componentCls}-container`]: { backgroundColor: darkColor },
|
|
68
|
-
[`${componentCls}-arrow`]: { "
|
|
70
|
+
[`${componentCls}-arrow`]: { [varName("arrow-background-color")]: darkColor }
|
|
69
71
|
} })),
|
|
70
72
|
"&-rtl": { direction: "rtl" }
|
|
71
73
|
} },
|
|
72
|
-
getArrowStyle(token, "
|
|
74
|
+
getArrowStyle(token, varRef("arrow-background-color")),
|
|
73
75
|
{ [`${componentCls}-pure`]: {
|
|
74
76
|
position: "relative",
|
|
75
77
|
maxWidth: "none",
|
package/dist/tooltip/util.js
CHANGED
|
@@ -1,10 +1,12 @@
|
|
|
1
|
+
import { genCssVar } from "../theme/util/genStyleUtils.js";
|
|
1
2
|
import { isPresetColor } from "../_util/colors.js";
|
|
2
3
|
import { generateColor } from "../color-picker/util.js";
|
|
3
4
|
import { classNames } from "@v-c/util";
|
|
4
5
|
|
|
5
6
|
//#region src/tooltip/util.ts
|
|
6
|
-
function parseColor(prefixCls, color) {
|
|
7
|
+
function parseColor(rootPrefixCls, prefixCls, color) {
|
|
7
8
|
const isInternalColor = isPresetColor(color);
|
|
9
|
+
const [varName] = genCssVar(rootPrefixCls, "tooltip");
|
|
8
10
|
const className = classNames({ [`${prefixCls}-${color}`]: color && isInternalColor });
|
|
9
11
|
const overlayStyle = {};
|
|
10
12
|
const arrowStyle = {};
|
|
@@ -12,8 +14,8 @@ function parseColor(prefixCls, color) {
|
|
|
12
14
|
const textColor = (.299 * rgb.r + .587 * rgb.g + .114 * rgb.b) / 255 < .5 ? "#FFF" : "#000";
|
|
13
15
|
if (color && !isInternalColor) {
|
|
14
16
|
overlayStyle.background = color;
|
|
15
|
-
overlayStyle["
|
|
16
|
-
arrowStyle["
|
|
17
|
+
overlayStyle[varName("overlay-color")] = textColor;
|
|
18
|
+
arrowStyle[varName("arrow-background-color")] = color;
|
|
17
19
|
}
|
|
18
20
|
return {
|
|
19
21
|
className,
|
package/dist/tour/index.d.ts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { TourEmits, TourLocale, TourProps, TourSemanticName, TourSlots, TourStepProps, TourStylesType } from "./interface.js";
|
|
2
|
-
import * as
|
|
2
|
+
import * as vue59 from "vue";
|
|
3
3
|
import { SlotsType } from "vue";
|
|
4
4
|
|
|
5
5
|
//#region src/tour/index.d.ts
|
|
6
|
-
declare const Tour:
|
|
6
|
+
declare const Tour: vue59.DefineSetupFnComponent<TourProps, TourEmits, SlotsType<TourSlots>, TourProps & {
|
|
7
7
|
[x: `on${Capitalize<string>}`]: ((...args: any[]) => any) | undefined;
|
|
8
|
-
},
|
|
8
|
+
}, vue59.PublicProps>;
|
|
9
9
|
type TourStepItem = TourStepProps;
|
|
10
10
|
//#endregion
|
|
11
11
|
export { Tour, TourStepItem };
|
package/dist/tour/index.js
CHANGED
|
@@ -148,55 +148,68 @@ const Tour = /* @__PURE__ */ defineComponent((props, { slots, emit, attrs }) =>
|
|
|
148
148
|
props: {
|
|
149
149
|
steps: {
|
|
150
150
|
type: Array,
|
|
151
|
-
required: false
|
|
151
|
+
required: false,
|
|
152
|
+
default: void 0
|
|
152
153
|
},
|
|
153
154
|
prefixCls: {
|
|
154
155
|
type: String,
|
|
155
|
-
required: false
|
|
156
|
+
required: false,
|
|
157
|
+
default: void 0
|
|
156
158
|
},
|
|
157
159
|
current: {
|
|
158
160
|
type: Number,
|
|
159
|
-
required: false
|
|
161
|
+
required: false,
|
|
162
|
+
default: void 0
|
|
160
163
|
},
|
|
161
164
|
indicatorsRender: {
|
|
162
165
|
type: Function,
|
|
163
|
-
required: false
|
|
166
|
+
required: false,
|
|
167
|
+
default: void 0
|
|
164
168
|
},
|
|
165
169
|
actionsRender: {
|
|
166
170
|
type: Function,
|
|
167
|
-
required: false
|
|
171
|
+
required: false,
|
|
172
|
+
default: void 0
|
|
168
173
|
},
|
|
169
174
|
type: {
|
|
170
175
|
type: String,
|
|
171
|
-
required: false
|
|
176
|
+
required: false,
|
|
177
|
+
default: void 0
|
|
172
178
|
},
|
|
173
179
|
classes: {
|
|
174
180
|
type: [Object, Function],
|
|
175
|
-
required: false
|
|
181
|
+
required: false,
|
|
182
|
+
default: void 0
|
|
176
183
|
},
|
|
177
184
|
styles: {
|
|
178
185
|
type: [Object, Function],
|
|
179
|
-
required: false
|
|
186
|
+
required: false,
|
|
187
|
+
default: void 0
|
|
180
188
|
},
|
|
181
189
|
rootClass: {
|
|
182
190
|
type: String,
|
|
183
|
-
required: false
|
|
191
|
+
required: false,
|
|
192
|
+
default: void 0
|
|
184
193
|
},
|
|
185
194
|
style: {
|
|
186
195
|
type: Object,
|
|
187
|
-
required: false
|
|
196
|
+
required: false,
|
|
197
|
+
default: void 0
|
|
188
198
|
},
|
|
189
199
|
open: {
|
|
190
200
|
type: Boolean,
|
|
191
|
-
required: false
|
|
201
|
+
required: false,
|
|
202
|
+
default: void 0
|
|
192
203
|
},
|
|
193
204
|
defaultOpen: {
|
|
194
205
|
type: Boolean,
|
|
195
|
-
required: false
|
|
206
|
+
required: false,
|
|
207
|
+
default: void 0
|
|
196
208
|
},
|
|
197
209
|
defaultCurrent: {
|
|
198
210
|
type: Number,
|
|
199
|
-
required: false
|
|
211
|
+
required: false,
|
|
212
|
+
default: void 0
|
|
200
213
|
},
|
|
201
214
|
closeIcon: {
|
|
202
215
|
type: [
|
|
@@ -208,50 +221,64 @@ const Tour = /* @__PURE__ */ defineComponent((props, { slots, emit, attrs }) =>
|
|
|
208
221
|
Boolean,
|
|
209
222
|
Array
|
|
210
223
|
],
|
|
211
|
-
required: false
|
|
224
|
+
required: false,
|
|
225
|
+
default: void 0
|
|
212
226
|
},
|
|
213
227
|
closable: {
|
|
214
228
|
type: [Boolean, Object],
|
|
215
|
-
required: false
|
|
229
|
+
required: false,
|
|
230
|
+
default: void 0
|
|
216
231
|
},
|
|
217
232
|
mask: {
|
|
218
233
|
type: [Boolean, Object],
|
|
219
|
-
required: false
|
|
234
|
+
required: false,
|
|
235
|
+
default: void 0
|
|
220
236
|
},
|
|
221
237
|
arrow: {
|
|
222
238
|
type: [Boolean, Object],
|
|
223
|
-
required: false
|
|
239
|
+
required: false,
|
|
240
|
+
default: void 0
|
|
224
241
|
},
|
|
225
242
|
placement: {
|
|
226
243
|
type: String,
|
|
227
|
-
required: false
|
|
244
|
+
required: false,
|
|
245
|
+
default: void 0
|
|
246
|
+
},
|
|
247
|
+
gap: {
|
|
248
|
+
required: false,
|
|
249
|
+
default: void 0
|
|
228
250
|
},
|
|
229
|
-
gap: { required: false },
|
|
230
251
|
animated: {
|
|
231
252
|
type: [Boolean, Object],
|
|
232
|
-
required: false
|
|
253
|
+
required: false,
|
|
254
|
+
default: void 0
|
|
233
255
|
},
|
|
234
256
|
scrollIntoViewOptions: {
|
|
235
257
|
type: Boolean,
|
|
236
258
|
required: false,
|
|
237
|
-
skipCheck: true
|
|
259
|
+
skipCheck: true,
|
|
260
|
+
default: void 0
|
|
238
261
|
},
|
|
239
262
|
zIndex: {
|
|
240
263
|
type: Number,
|
|
241
|
-
required: false
|
|
264
|
+
required: false,
|
|
265
|
+
default: void 0
|
|
242
266
|
},
|
|
243
267
|
getPopupContainer: {
|
|
244
268
|
type: [Function, Boolean],
|
|
245
|
-
required: false
|
|
269
|
+
required: false,
|
|
270
|
+
default: void 0
|
|
246
271
|
},
|
|
247
272
|
builtinPlacements: {
|
|
248
273
|
type: Function,
|
|
249
274
|
required: false,
|
|
250
|
-
skipCheck: true
|
|
275
|
+
skipCheck: true,
|
|
276
|
+
default: void 0
|
|
251
277
|
},
|
|
252
278
|
disabledInteraction: {
|
|
253
279
|
type: Boolean,
|
|
254
|
-
required: false
|
|
280
|
+
required: false,
|
|
281
|
+
default: void 0
|
|
255
282
|
}
|
|
256
283
|
},
|
|
257
284
|
name: "ATour",
|
package/dist/tour/panelRender.js
CHANGED
|
@@ -119,39 +119,48 @@ const TourPanel = /* @__PURE__ */ defineComponent((props) => {
|
|
|
119
119
|
props: {
|
|
120
120
|
stepProps: {
|
|
121
121
|
type: Object,
|
|
122
|
-
required: true
|
|
122
|
+
required: true,
|
|
123
|
+
default: void 0
|
|
123
124
|
},
|
|
124
125
|
current: {
|
|
125
126
|
type: Number,
|
|
126
|
-
required: true
|
|
127
|
+
required: true,
|
|
128
|
+
default: void 0
|
|
127
129
|
},
|
|
128
130
|
type: {
|
|
129
131
|
type: String,
|
|
130
|
-
required: false
|
|
132
|
+
required: false,
|
|
133
|
+
default: void 0
|
|
131
134
|
},
|
|
132
135
|
indicatorsRender: {
|
|
133
136
|
type: Function,
|
|
134
|
-
required: false
|
|
137
|
+
required: false,
|
|
138
|
+
default: void 0
|
|
135
139
|
},
|
|
136
140
|
classes: {
|
|
137
141
|
type: [Object, Function],
|
|
138
|
-
required: false
|
|
142
|
+
required: false,
|
|
143
|
+
default: void 0
|
|
139
144
|
},
|
|
140
145
|
styles: {
|
|
141
146
|
type: [Object, Function],
|
|
142
|
-
required: false
|
|
147
|
+
required: false,
|
|
148
|
+
default: void 0
|
|
143
149
|
},
|
|
144
150
|
actionsRender: {
|
|
145
151
|
type: Function,
|
|
146
|
-
required: false
|
|
152
|
+
required: false,
|
|
153
|
+
default: void 0
|
|
147
154
|
},
|
|
148
155
|
prevButtonProps: {
|
|
149
156
|
type: Function,
|
|
150
|
-
required: false
|
|
157
|
+
required: false,
|
|
158
|
+
default: void 0
|
|
151
159
|
},
|
|
152
160
|
nextButtonProps: {
|
|
153
161
|
type: Function,
|
|
154
|
-
required: false
|
|
162
|
+
required: false,
|
|
163
|
+
default: void 0
|
|
155
164
|
}
|
|
156
165
|
},
|
|
157
166
|
name: "TourPanel",
|
package/dist/tour/style/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { genFocusStyle, resetComponent } from "../../style/index.js";
|
|
2
|
-
import { genStyleHooks } from "../../theme/util/genStyleUtils.js";
|
|
2
|
+
import { genCssVar, genStyleHooks } from "../../theme/util/genStyleUtils.js";
|
|
3
3
|
import { mergeToken } from "../../theme/internal.js";
|
|
4
4
|
import { getArrowToken } from "../../style/roundedArrow.js";
|
|
5
5
|
import getArrowStyle, { MAX_VERTICAL_CONTENT_RADIUS, getArrowOffsetToken } from "../../style/placementArrow.js";
|
|
@@ -9,6 +9,7 @@ import { FastColor } from "@ant-design/fast-color";
|
|
|
9
9
|
//#region src/tour/style/index.ts
|
|
10
10
|
const genBaseStyle = (token) => {
|
|
11
11
|
const { componentCls, padding, paddingXS, borderRadius, borderRadiusXS, colorPrimary, colorFill, indicatorHeight, indicatorWidth, boxShadowTertiary, zIndexPopup, colorBgElevated, fontWeightStrong, marginXS, colorTextLightSolid, tourBorderRadius, colorWhite, primaryNextBtnHoverBg, closeBtnSize, motionDurationSlow, antCls, primaryPrevBtnBg } = token;
|
|
12
|
+
const [varName, varRef] = genCssVar(antCls, "tooltip");
|
|
12
13
|
return [{
|
|
13
14
|
[componentCls]: {
|
|
14
15
|
...resetComponent(token),
|
|
@@ -17,7 +18,7 @@ const genBaseStyle = (token) => {
|
|
|
17
18
|
"maxWidth": "fit-content",
|
|
18
19
|
"visibility": "visible",
|
|
19
20
|
"width": 520,
|
|
20
|
-
"
|
|
21
|
+
[varName("arrow-background-color")]: colorBgElevated,
|
|
21
22
|
"&-pure": {
|
|
22
23
|
maxWidth: "100%",
|
|
23
24
|
position: "relative"
|
|
@@ -94,7 +95,7 @@ const genBaseStyle = (token) => {
|
|
|
94
95
|
}
|
|
95
96
|
},
|
|
96
97
|
[`${componentCls}-primary, &${componentCls}-primary`]: {
|
|
97
|
-
"
|
|
98
|
+
[varName("arrow-background-color")]: colorPrimary,
|
|
98
99
|
[`${componentCls}-section`]: {
|
|
99
100
|
color: colorTextLightSolid,
|
|
100
101
|
textAlign: "start",
|
|
@@ -134,7 +135,7 @@ const genBaseStyle = (token) => {
|
|
|
134
135
|
"&-placement-rightTop",
|
|
135
136
|
"&-placement-rightBottom"
|
|
136
137
|
].join(",")]: { [`${componentCls}-section`]: { borderRadius: token.min(tourBorderRadius, MAX_VERTICAL_CONTENT_RADIUS) } }
|
|
137
|
-
}, getArrowStyle(token, "
|
|
138
|
+
}, getArrowStyle(token, varRef("arrow-background-color"))];
|
|
138
139
|
};
|
|
139
140
|
const prepareComponentToken = (token) => ({
|
|
140
141
|
zIndexPopup: token.zIndexPopupBase + 70,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { VueNode } from "../_util/type.js";
|
|
2
2
|
import { DirectionType } from "../config-provider/context.js";
|
|
3
|
-
import * as
|
|
3
|
+
import * as vue213 from "vue";
|
|
4
4
|
import { CSSProperties } from "vue";
|
|
5
5
|
|
|
6
6
|
//#region src/transfer/Actions.d.ts
|
|
@@ -16,6 +16,6 @@ interface TransferOperationProps {
|
|
|
16
16
|
direction?: DirectionType;
|
|
17
17
|
oneWay?: boolean;
|
|
18
18
|
}
|
|
19
|
-
declare const Actions:
|
|
19
|
+
declare const Actions: vue213.DefineSetupFnComponent<TransferOperationProps, {}, {}, TransferOperationProps & {}, vue213.PublicProps>;
|
|
20
20
|
//#endregion
|
|
21
21
|
export { Actions, TransferOperationProps };
|
package/dist/transfer/Actions.js
CHANGED
|
@@ -40,35 +40,43 @@ const Action = /* @__PURE__ */ defineComponent((props) => {
|
|
|
40
40
|
props: {
|
|
41
41
|
type: {
|
|
42
42
|
type: String,
|
|
43
|
-
required: true
|
|
43
|
+
required: true,
|
|
44
|
+
default: void 0
|
|
44
45
|
},
|
|
45
46
|
actions: {
|
|
46
47
|
type: Array,
|
|
47
|
-
required: true
|
|
48
|
+
required: true,
|
|
49
|
+
default: void 0
|
|
48
50
|
},
|
|
49
51
|
moveToLeft: {
|
|
50
52
|
type: Function,
|
|
51
|
-
required: false
|
|
53
|
+
required: false,
|
|
54
|
+
default: void 0
|
|
52
55
|
},
|
|
53
56
|
moveToRight: {
|
|
54
57
|
type: Function,
|
|
55
|
-
required: false
|
|
58
|
+
required: false,
|
|
59
|
+
default: void 0
|
|
56
60
|
},
|
|
57
61
|
leftActive: {
|
|
58
62
|
type: Boolean,
|
|
59
|
-
required: false
|
|
63
|
+
required: false,
|
|
64
|
+
default: void 0
|
|
60
65
|
},
|
|
61
66
|
rightActive: {
|
|
62
67
|
type: Boolean,
|
|
63
|
-
required: false
|
|
68
|
+
required: false,
|
|
69
|
+
default: void 0
|
|
64
70
|
},
|
|
65
71
|
direction: {
|
|
66
72
|
type: [String, null],
|
|
67
|
-
required: false
|
|
73
|
+
required: false,
|
|
74
|
+
default: void 0
|
|
68
75
|
},
|
|
69
76
|
disabled: {
|
|
70
77
|
type: Boolean,
|
|
71
|
-
required: false
|
|
78
|
+
required: false,
|
|
79
|
+
default: void 0
|
|
72
80
|
}
|
|
73
81
|
},
|
|
74
82
|
name: "ATransferAction",
|
|
@@ -96,43 +104,53 @@ const Actions = /* @__PURE__ */ defineComponent((props) => {
|
|
|
96
104
|
props: {
|
|
97
105
|
class: {
|
|
98
106
|
type: String,
|
|
99
|
-
required: false
|
|
107
|
+
required: false,
|
|
108
|
+
default: void 0
|
|
100
109
|
},
|
|
101
110
|
actions: {
|
|
102
111
|
type: Array,
|
|
103
|
-
required: true
|
|
112
|
+
required: true,
|
|
113
|
+
default: void 0
|
|
104
114
|
},
|
|
105
115
|
moveToLeft: {
|
|
106
116
|
type: Function,
|
|
107
|
-
required: false
|
|
117
|
+
required: false,
|
|
118
|
+
default: void 0
|
|
108
119
|
},
|
|
109
120
|
moveToRight: {
|
|
110
121
|
type: Function,
|
|
111
|
-
required: false
|
|
122
|
+
required: false,
|
|
123
|
+
default: void 0
|
|
112
124
|
},
|
|
113
125
|
leftActive: {
|
|
114
126
|
type: Boolean,
|
|
115
|
-
required: false
|
|
127
|
+
required: false,
|
|
128
|
+
default: void 0
|
|
116
129
|
},
|
|
117
130
|
rightActive: {
|
|
118
131
|
type: Boolean,
|
|
119
|
-
required: false
|
|
132
|
+
required: false,
|
|
133
|
+
default: void 0
|
|
120
134
|
},
|
|
121
135
|
style: {
|
|
122
136
|
type: Object,
|
|
123
|
-
required: false
|
|
137
|
+
required: false,
|
|
138
|
+
default: void 0
|
|
124
139
|
},
|
|
125
140
|
disabled: {
|
|
126
141
|
type: Boolean,
|
|
127
|
-
required: false
|
|
142
|
+
required: false,
|
|
143
|
+
default: void 0
|
|
128
144
|
},
|
|
129
145
|
direction: {
|
|
130
146
|
type: [String, null],
|
|
131
|
-
required: false
|
|
147
|
+
required: false,
|
|
148
|
+
default: void 0
|
|
132
149
|
},
|
|
133
150
|
oneWay: {
|
|
134
151
|
type: Boolean,
|
|
135
|
-
required: false
|
|
152
|
+
required: false,
|
|
153
|
+
default: void 0
|
|
136
154
|
}
|
|
137
155
|
},
|
|
138
156
|
name: "ATransferOperation",
|