antdv-next 1.4.2 → 1.4.3

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.
@@ -1,5 +1,5 @@
1
1
  import { genCssVar, genStyleHooks } from "../../theme/util/genStyleUtils.js";
2
- import { genNoMotionStyle } from "../../style/motion/util.js";
2
+ import { genNoMotionRawStyle } from "../../style/motion/util.js";
3
3
  import "../util.js";
4
4
  import { Keyframes } from "@antdv-next/cssinjs";
5
5
  //#region src/border-beam/style/index.ts
@@ -28,7 +28,7 @@ const genBorderBeamStyle = (token) => {
28
28
  "@supports (offset-path: rect(0 auto auto 0 round 1px))": {
29
29
  display: "block",
30
30
  "&::before": {
31
- ...genNoMotionStyle(),
31
+ ...genNoMotionRawStyle(),
32
32
  content: "\"\"",
33
33
  position: "absolute",
34
34
  top: 0,
@@ -2,7 +2,7 @@ import { CSSProperties, VNodeChild } from "vue";
2
2
 
3
3
  //#region src/button/buttonHelper.d.ts
4
4
  declare const isTwoCNChar: (string: string) => boolean;
5
- declare function isUnBorderedButtonVariant(type?: ButtonVariantType): type is "link" | "text";
5
+ declare function isUnBorderedButtonVariant(type?: ButtonVariantType): type is "text" | "link";
6
6
  declare function spaceChildren(children: VNodeChild[], needInserted: boolean, style?: CSSProperties, className?: string): VNodeChild[];
7
7
  declare const _ButtonTypes: readonly ["default", "primary", "dashed", "link", "text"];
8
8
  type ButtonType = (typeof _ButtonTypes)[number];
@@ -1,7 +1,7 @@
1
1
  import { genFocusOutline, resetComponent } from "../../style/index.js";
2
2
  import { genStyleHooks } from "../../theme/util/genStyleUtils.js";
3
3
  import { mergeToken } from "../../theme/internal.js";
4
- import { genNoMotionStyle } from "../../style/motion/util.js";
4
+ import { genNoMotionRawStyle, genNoMotionStyle } from "../../style/motion/util.js";
5
5
  import { unit } from "@antdv-next/cssinjs";
6
6
  //#region src/checkbox/style/index.ts
7
7
  const genCheckboxStyle = (token) => {
@@ -68,7 +68,7 @@ const genCheckboxStyle = (token) => {
68
68
  opacity: 0,
69
69
  content: "\"\"",
70
70
  transition: `all ${token.motionDurationFast} ${token.motionEaseInBack}, opacity ${token.motionDurationFast}`,
71
- ...genNoMotionStyle()
71
+ ...genNoMotionRawStyle()
72
72
  },
73
73
  [`${checkboxCls}-input`]: {
74
74
  position: "absolute",
@@ -102,7 +102,7 @@ const genCheckboxStyle = (token) => {
102
102
  opacity: 1,
103
103
  transform: "rotate(45deg) scale(1) translate(-50%,-50%)",
104
104
  transition: `all ${token.motionDurationMid} ${token.motionEaseOutBack} ${token.motionDurationFast}`,
105
- ...genNoMotionStyle()
105
+ ...genNoMotionRawStyle()
106
106
  },
107
107
  [hoverMediaQuery]: { [`&:not(${checkboxCls}-disabled):hover`]: {
108
108
  backgroundColor: token.colorPrimaryHover,
@@ -4,11 +4,11 @@ import { Components } from "@v-c/picker";
4
4
  //#region src/date-picker/generatePicker/useComponents.d.ts
5
5
  declare function useComponents(components?: Components): {
6
6
  time?: import("vue").DefineComponent<import("@v-c/picker/dist/interface").SharedPanelProps<any>> | undefined;
7
- year?: import("vue").DefineComponent<import("@v-c/picker/dist/interface").SharedPanelProps<any>> | undefined;
8
- month?: import("vue").DefineComponent<import("@v-c/picker/dist/interface").SharedPanelProps<any>> | undefined;
9
7
  date?: import("vue").DefineComponent<import("@v-c/picker/dist/interface").SharedPanelProps<any>> | undefined;
10
8
  week?: import("vue").DefineComponent<import("@v-c/picker/dist/interface").SharedPanelProps<any>> | undefined;
9
+ month?: import("vue").DefineComponent<import("@v-c/picker/dist/interface").SharedPanelProps<any>> | undefined;
11
10
  quarter?: import("vue").DefineComponent<import("@v-c/picker/dist/interface").SharedPanelProps<any>> | undefined;
11
+ year?: import("vue").DefineComponent<import("@v-c/picker/dist/interface").SharedPanelProps<any>> | undefined;
12
12
  decade?: import("vue").DefineComponent<import("@v-c/picker/dist/interface").SharedPanelProps<any>> | undefined;
13
13
  datetime?: import("vue").DefineComponent<import("@v-c/picker/dist/interface").SharedPanelProps<any>> | undefined;
14
14
  button: string | import("vue").DefineSetupFnComponent<ButtonProps, {}, {}, ButtonProps & {}, import("vue").PublicProps> | import("vue").DefineComponent;
@@ -9,23 +9,23 @@ declare function useItems(screens: Ref<ScreenMap>, items: Ref<DescriptionsItemTy
9
9
  filled: boolean;
10
10
  _$index: number;
11
11
  key?: import("@v-c/util/dist/type").Key;
12
- classes?: CellSemanticClassNames | undefined;
13
12
  styles?: CellSemanticStyles | undefined;
14
13
  style?: import("vue").CSSProperties | undefined;
14
+ content?: VueNode;
15
+ classes?: CellSemanticClassNames | undefined;
15
16
  rootClass?: string | undefined;
16
17
  label?: VueNode;
17
18
  class?: string | undefined;
18
- content?: VueNode;
19
19
  } | {
20
20
  span: number | undefined;
21
21
  key?: import("@v-c/util/dist/type").Key;
22
- classes?: CellSemanticClassNames | undefined;
23
22
  styles?: CellSemanticStyles | undefined;
24
23
  style?: import("vue").CSSProperties | undefined;
24
+ content?: VueNode;
25
+ classes?: CellSemanticClassNames | undefined;
25
26
  rootClass?: string | undefined;
26
27
  label?: VueNode;
27
28
  class?: string | undefined;
28
- content?: VueNode;
29
29
  _$index: number;
30
30
  })[]>;
31
31
  //#endregion
@@ -69,7 +69,7 @@ declare function useFormItemPrefixContext(): Ref<{
69
69
  prefixCls: string;
70
70
  }>;
71
71
  declare function useVariantContextProvider(variant: Ref<Variant | undefined>): void;
72
- declare function useVariantContext(): Ref<"outlined" | "filled" | "borderless" | "underlined" | undefined, "outlined" | "filled" | "borderless" | "underlined" | undefined>;
72
+ declare function useVariantContext(): Ref<"outlined" | "borderless" | "filled" | "underlined" | undefined, "outlined" | "borderless" | "filled" | "underlined" | undefined>;
73
73
  interface FormItemStatusContextProps {
74
74
  isFormItemInput?: boolean;
75
75
  status?: ValidateStatus;
@@ -4,7 +4,7 @@ import { Ref } from "vue";
4
4
 
5
5
  //#region src/form/hooks/useVariant.d.ts
6
6
  type VariantComponents = keyof Pick<ConfigProviderProps, 'input' | 'inputNumber' | 'textArea' | 'mentions' | 'select' | 'cascader' | 'treeSelect' | 'datePicker' | 'timePicker' | 'rangePicker' | 'card'>;
7
- declare function useVariant(component: VariantComponents, variant?: Ref<Variant | undefined>, legacyBordered?: Ref<boolean | undefined> | boolean): readonly [import("vue").ComputedRef<"outlined" | "filled" | "borderless" | "underlined">, import("vue").ComputedRef<boolean>];
7
+ declare function useVariant(component: VariantComponents, variant?: Ref<Variant | undefined>, legacyBordered?: Ref<boolean | undefined> | boolean): readonly [import("vue").ComputedRef<"outlined" | "borderless" | "filled" | "underlined">, import("vue").ComputedRef<boolean>];
8
8
  declare const useVariants: typeof useVariant;
9
9
  //#endregion
10
10
  export { useVariant as default, useVariants };
package/dist/package.js CHANGED
@@ -1,4 +1,4 @@
1
1
  //#region package.json
2
- var version = "1.4.2";
2
+ var version = "1.4.3";
3
3
  //#endregion
4
4
  export { version };
@@ -1,7 +1,7 @@
1
1
  import { genFocusOutline, resetComponent } from "../../style/index.js";
2
2
  import { genStyleHooks } from "../../theme/util/genStyleUtils.js";
3
3
  import { mergeToken } from "../../theme/internal.js";
4
- import { genNoMotionStyle } from "../../style/motion/util.js";
4
+ import { genNoMotionRawStyle, genNoMotionStyle } from "../../style/motion/util.js";
5
5
  import { unit } from "@antdv-next/cssinjs";
6
6
  //#region src/radio/style/index.ts
7
7
  const getGroupRadioStyle = (token) => {
@@ -104,7 +104,7 @@ const getRadioBasicStyle = (token) => {
104
104
  transformOrigin: "50% 50%",
105
105
  opacity: 0,
106
106
  transition: `all ${motionDurationSlow} ${motionEaseInOutCirc}`,
107
- ...genNoMotionStyle()
107
+ ...genNoMotionRawStyle()
108
108
  },
109
109
  [`${componentCls}-input`]: {
110
110
  position: "absolute",
@@ -1,7 +1,7 @@
1
1
  import { genFocusOutline, genFocusStyle, resetComponent, textEllipsis } from "../../style/index.js";
2
2
  import { genStyleHooks } from "../../theme/util/genStyleUtils.js";
3
3
  import { mergeToken } from "../../theme/internal.js";
4
- import { genNoMotionStyle } from "../../style/motion/util.js";
4
+ import { genNoMotionRawStyle, genNoMotionStyle } from "../../style/motion/util.js";
5
5
  import { unit } from "@antdv-next/cssinjs";
6
6
  //#region src/segmented/style/index.ts
7
7
  function getItemDisabledStyle(cls, token) {
@@ -82,7 +82,7 @@ const genSegmentedStyle = (token) => {
82
82
  opacity: 0,
83
83
  pointerEvents: "none",
84
84
  transition: ["opacity", "background-color"].map((prop) => `${prop} ${motionDurationMid}`).join(", "),
85
- ...genNoMotionStyle()
85
+ ...genNoMotionRawStyle()
86
86
  },
87
87
  [`&:not(${componentCls}-item-selected):not(${componentCls}-item-disabled)`]: {
88
88
  "&:hover, &:active": { color: token.itemHoverColor },
@@ -215,18 +215,7 @@ const SplitBar = /* @__PURE__ */ defineComponent((props, { slots, attrs }) => {
215
215
  type: Boolean,
216
216
  required: true
217
217
  },
218
- draggerIcon: {
219
- type: [
220
- Function,
221
- String,
222
- Number,
223
- null,
224
- Object,
225
- Boolean
226
- ],
227
- required: false,
228
- default: void 0
229
- },
218
+ draggerIcon: { required: false },
230
219
  collapsibleIcon: {
231
220
  type: Object,
232
221
  required: false
@@ -2,6 +2,6 @@ import genCollapseMotion from "./collapse.js";
2
2
  import { fadeIn, fadeOut, initFadeMotion } from "./fade.js";
3
3
  import { initMoveMotion, moveDownIn, moveDownOut, moveLeftIn, moveLeftOut, moveRightIn, moveRightOut, moveUpIn, moveUpOut } from "./move.js";
4
4
  import { initSlideMotion, slideDownIn, slideDownOut, slideLeftIn, slideLeftOut, slideRightIn, slideRightOut, slideUpIn, slideUpOut } from "./slide.js";
5
- import { genNoMotionStyle } from "./util.js";
5
+ import { genNoMotionRawStyle, genNoMotionStyle } from "./util.js";
6
6
  import { initZoomMotion, zoomBigIn, zoomBigOut, zoomDownIn, zoomDownOut, zoomIn, zoomLeftIn, zoomLeftOut, zoomOut, zoomRightIn, zoomRightOut, zoomUpIn, zoomUpOut } from "./zoom.js";
7
- export { fadeIn, fadeOut, genCollapseMotion, genNoMotionStyle, initFadeMotion, initMoveMotion, initSlideMotion, initZoomMotion, moveDownIn, moveDownOut, moveLeftIn, moveLeftOut, moveRightIn, moveRightOut, moveUpIn, moveUpOut, slideDownIn, slideDownOut, slideLeftIn, slideLeftOut, slideRightIn, slideRightOut, slideUpIn, slideUpOut, zoomBigIn, zoomBigOut, zoomDownIn, zoomDownOut, zoomIn, zoomLeftIn, zoomLeftOut, zoomOut, zoomRightIn, zoomRightOut, zoomUpIn, zoomUpOut };
7
+ export { fadeIn, fadeOut, genCollapseMotion, genNoMotionRawStyle, genNoMotionStyle, initFadeMotion, initMoveMotion, initSlideMotion, initZoomMotion, moveDownIn, moveDownOut, moveLeftIn, moveLeftOut, moveRightIn, moveRightOut, moveUpIn, moveUpOut, slideDownIn, slideDownOut, slideLeftIn, slideLeftOut, slideRightIn, slideRightOut, slideUpIn, slideUpOut, zoomBigIn, zoomBigOut, zoomDownIn, zoomDownOut, zoomIn, zoomLeftIn, zoomLeftOut, zoomOut, zoomRightIn, zoomRightOut, zoomUpIn, zoomUpOut };
@@ -2,6 +2,6 @@ import genCollapseMotion from "./collapse.js";
2
2
  import { fadeIn, fadeOut, initFadeMotion } from "./fade.js";
3
3
  import { initMoveMotion, moveDownIn, moveDownOut, moveLeftIn, moveLeftOut, moveRightIn, moveRightOut, moveUpIn, moveUpOut } from "./move.js";
4
4
  import { initSlideMotion, slideDownIn, slideDownOut, slideLeftIn, slideLeftOut, slideRightIn, slideRightOut, slideUpIn, slideUpOut } from "./slide.js";
5
- import { genNoMotionStyle } from "./util.js";
5
+ import { genNoMotionRawStyle, genNoMotionStyle } from "./util.js";
6
6
  import { initZoomMotion, zoomBigIn, zoomBigOut, zoomDownIn, zoomDownOut, zoomIn, zoomLeftIn, zoomLeftOut, zoomOut, zoomRightIn, zoomRightOut, zoomUpIn, zoomUpOut } from "./zoom.js";
7
- export { fadeIn, fadeOut, genCollapseMotion, genNoMotionStyle, initFadeMotion, initMoveMotion, initSlideMotion, initZoomMotion, moveDownIn, moveDownOut, moveLeftIn, moveLeftOut, moveRightIn, moveRightOut, moveUpIn, moveUpOut, slideDownIn, slideDownOut, slideLeftIn, slideLeftOut, slideRightIn, slideRightOut, slideUpIn, slideUpOut, zoomBigIn, zoomBigOut, zoomDownIn, zoomDownOut, zoomIn, zoomLeftIn, zoomLeftOut, zoomOut, zoomRightIn, zoomRightOut, zoomUpIn, zoomUpOut };
7
+ export { fadeIn, fadeOut, genCollapseMotion, genNoMotionRawStyle, genNoMotionStyle, initFadeMotion, initMoveMotion, initSlideMotion, initZoomMotion, moveDownIn, moveDownOut, moveLeftIn, moveLeftOut, moveRightIn, moveRightOut, moveUpIn, moveUpOut, slideDownIn, slideDownOut, slideLeftIn, slideLeftOut, slideRightIn, slideRightOut, slideUpIn, slideUpOut, zoomBigIn, zoomBigOut, zoomDownIn, zoomDownOut, zoomIn, zoomLeftIn, zoomLeftOut, zoomOut, zoomRightIn, zoomRightOut, zoomUpIn, zoomUpOut };
@@ -2,5 +2,12 @@ import { CSSObject } from "@antdv-next/cssinjs";
2
2
 
3
3
  //#region src/style/motion/util.d.ts
4
4
  declare function genNoMotionStyle(): CSSObject;
5
+ /**
6
+ * Flat variant for call sites already nested inside a pseudo-element
7
+ * selector, where the `&::before` expansion of `genNoMotionStyle` would
8
+ * emit invalid selectors like `.foo::before::before` (rejected by
9
+ * lightningcss during the docs build).
10
+ */
11
+ declare function genNoMotionRawStyle(): CSSObject;
5
12
  //#endregion
6
- export { genNoMotionStyle };
13
+ export { genNoMotionRawStyle, genNoMotionStyle };
@@ -5,5 +5,17 @@ function genNoMotionStyle() {
5
5
  animation: "none"
6
6
  } } };
7
7
  }
8
+ /**
9
+ * Flat variant for call sites already nested inside a pseudo-element
10
+ * selector, where the `&::before` expansion of `genNoMotionStyle` would
11
+ * emit invalid selectors like `.foo::before::before` (rejected by
12
+ * lightningcss during the docs build).
13
+ */
14
+ function genNoMotionRawStyle() {
15
+ return { "@media (prefers-reduced-motion: reduce)": {
16
+ transition: "none",
17
+ animation: "none"
18
+ } };
19
+ }
8
20
  //#endregion
9
- export { genNoMotionStyle };
21
+ export { genNoMotionRawStyle, genNoMotionStyle };
@@ -1,7 +1,7 @@
1
1
  import { genFocusStyle, resetComponent } from "../../style/index.js";
2
2
  import { genStyleHooks } from "../../theme/util/genStyleUtils.js";
3
3
  import { mergeToken } from "../../theme/internal.js";
4
- import { genNoMotionStyle } from "../../style/motion/util.js";
4
+ import { genNoMotionRawStyle, genNoMotionStyle } from "../../style/motion/util.js";
5
5
  import { unit } from "@antdv-next/cssinjs";
6
6
  import { FastColor } from "@ant-design/fast-color";
7
7
  //#region src/switch/style/index.ts
@@ -98,7 +98,7 @@ const genSwitchHandleStyle = (token) => {
98
98
  boxShadow: handleShadow,
99
99
  transition: `all ${token.switchDuration} ease-in-out`,
100
100
  content: "\"\"",
101
- ...genNoMotionStyle()
101
+ ...genNoMotionRawStyle()
102
102
  }
103
103
  },
104
104
  [`&${componentCls}-checked ${switchHandleCls}`]: { insetInlineStart: `calc(100% - ${unit(calc(handleSize).add(trackPadding).equal())})` },
@@ -10,6 +10,6 @@ declare function useColor(props: {
10
10
  color: Ref<TagProps['color']>;
11
11
  variant: Ref<TagProps['variant']>;
12
12
  bordered: Ref<TagProps['bordered']>;
13
- }, contextVariant?: Ref<TagProps['variant']>): readonly [import("vue").ComputedRef<"outlined" | "solid" | "filled">, import("vue").ComputedRef<string | undefined>, import("vue").ComputedRef<boolean>, import("vue").ComputedRef<boolean>, import("vue").ComputedRef<CSSProperties>];
13
+ }, contextVariant?: Ref<TagProps['variant']>): readonly [import("vue").ComputedRef<"outlined" | "filled" | "solid">, import("vue").ComputedRef<string | undefined>, import("vue").ComputedRef<boolean>, import("vue").ComputedRef<boolean>, import("vue").ComputedRef<CSSProperties>];
14
14
  //#endregion
15
15
  export { useColor as default };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "antdv-next",
3
3
  "type": "module",
4
- "version": "1.4.2",
4
+ "version": "1.4.3",
5
5
  "description": "Ant Design Vue3 Component Library",
6
6
  "author": {
7
7
  "email": "aibayanyu@gamil.com",