@arco-design/mobile-react 2.37.0 → 2.38.0

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.
Files changed (318) hide show
  1. package/CHANGELOG.md +17 -0
  2. package/README.en-US.md +2 -2
  3. package/README.md +2 -2
  4. package/cjs/action-sheet/index.d.ts +2 -2
  5. package/cjs/action-sheet/style/css/index.css +18 -0
  6. package/cjs/avatar/style/css/index.css +18 -0
  7. package/cjs/badge/index.d.ts +2 -1
  8. package/cjs/badge/index.js +1 -1
  9. package/cjs/badge/style/css/index.css +26 -4
  10. package/cjs/badge/style/index.less +4 -2
  11. package/cjs/button/style/css/index.css +18 -0
  12. package/cjs/carousel/style/css/index.css +18 -0
  13. package/cjs/cell/style/css/index.css +18 -0
  14. package/cjs/checkbox/style/css/index.css +18 -0
  15. package/cjs/circle-progress/style/css/index.css +18 -0
  16. package/cjs/collapse/style/css/index.css +18 -0
  17. package/cjs/count-down/style/css/index.css +18 -0
  18. package/cjs/date-picker/style/css/index.css +18 -0
  19. package/cjs/dialog/index.d.ts +7 -6
  20. package/cjs/dialog/index.js +4 -1
  21. package/cjs/dialog/style/css/index.css +26 -4
  22. package/cjs/dialog/style/index.less +4 -2
  23. package/cjs/divider/style/css/index.css +18 -0
  24. package/cjs/dropdown/style/css/index.css +18 -0
  25. package/cjs/dropdown-menu/style/css/index.css +18 -0
  26. package/cjs/ellipsis/style/css/index.css +18 -0
  27. package/cjs/form/style/css/index.css +18 -0
  28. package/cjs/grid/style/css/index.css +18 -0
  29. package/cjs/image/style/css/index.css +18 -0
  30. package/cjs/image-picker/style/css/index.css +18 -0
  31. package/cjs/image-preview/style/css/index.css +18 -0
  32. package/cjs/index-bar/style/css/index.css +18 -0
  33. package/cjs/input/style/css/index.css +18 -0
  34. package/cjs/keyboard/style/css/index.css +18 -0
  35. package/cjs/load-more/style/css/index.css +18 -0
  36. package/cjs/loading/style/css/index.css +18 -0
  37. package/cjs/masking/index.d.ts +11 -5
  38. package/cjs/masking/index.js +2 -0
  39. package/cjs/masking/style/css/index.css +18 -0
  40. package/cjs/nav-bar/style/css/index.css +18 -0
  41. package/cjs/notice-bar/style/css/index.css +18 -0
  42. package/cjs/notify/style/css/index.css +18 -0
  43. package/cjs/pagination/style/css/index.css +18 -0
  44. package/cjs/picker/style/css/index.css +18 -0
  45. package/cjs/picker-view/style/css/index.css +18 -0
  46. package/cjs/popover/style/css/index.css +18 -0
  47. package/cjs/popover/style/css/menu.css +18 -0
  48. package/cjs/popup/index.d.ts +3 -3
  49. package/cjs/popup/index.js +1 -0
  50. package/cjs/popup/style/css/index.css +35 -0
  51. package/cjs/popup/style/index.less +36 -3
  52. package/cjs/popup-swiper/index.d.ts +2 -2
  53. package/cjs/popup-swiper/index.js +20 -3
  54. package/cjs/popup-swiper/style/css/index.css +18 -0
  55. package/cjs/progress/style/css/index.css +18 -0
  56. package/cjs/pull-refresh/style/css/index.css +18 -0
  57. package/cjs/radio/style/css/index.css +18 -0
  58. package/cjs/rate/style/css/index.css +18 -0
  59. package/cjs/search-bar/style/css/index.css +18 -0
  60. package/cjs/skeleton/style/css/index.css +18 -0
  61. package/cjs/slider/style/css/index.css +18 -0
  62. package/cjs/stepper/style/css/index.css +18 -0
  63. package/cjs/steps/style/css/index.css +18 -0
  64. package/cjs/sticky/style/css/index.css +18 -0
  65. package/cjs/swipe-action/style/css/index.css +18 -0
  66. package/cjs/swipe-load/style/css/index.css +18 -0
  67. package/cjs/switch/style/css/index.css +18 -0
  68. package/cjs/tab-bar/style/css/index.css +18 -0
  69. package/cjs/tabs/index.js +7 -3
  70. package/cjs/tabs/style/css/index.css +18 -0
  71. package/cjs/tabs/tab-cell.js +9 -1
  72. package/cjs/tabs/type.d.ts +5 -0
  73. package/cjs/tag/style/css/index.css +18 -0
  74. package/cjs/textarea/style/css/index.css +18 -0
  75. package/cjs/toast/style/css/index.css +18 -0
  76. package/cjs/transition/index.d.ts +9 -3
  77. package/cjs/transition/index.js +36 -6
  78. package/cjs/transition/style/css/index.css +22 -4
  79. package/cjs/transition/style/index.less +2 -2
  80. package/cjs/uploader/style/css/index.css +18 -0
  81. package/dist/index.js +82 -22
  82. package/dist/index.min.js +4 -4
  83. package/dist/style.css +1049 -6
  84. package/dist/style.min.css +1 -1
  85. package/esm/action-sheet/index.d.ts +2 -2
  86. package/esm/action-sheet/style/css/index.css +18 -0
  87. package/esm/avatar/style/css/index.css +18 -0
  88. package/esm/badge/index.d.ts +2 -1
  89. package/esm/badge/index.js +1 -1
  90. package/esm/badge/style/css/index.css +26 -4
  91. package/esm/badge/style/index.less +4 -2
  92. package/esm/button/style/css/index.css +18 -0
  93. package/esm/carousel/style/css/index.css +18 -0
  94. package/esm/cell/style/css/index.css +18 -0
  95. package/esm/checkbox/style/css/index.css +18 -0
  96. package/esm/circle-progress/style/css/index.css +18 -0
  97. package/esm/collapse/style/css/index.css +18 -0
  98. package/esm/count-down/style/css/index.css +18 -0
  99. package/esm/date-picker/style/css/index.css +18 -0
  100. package/esm/dialog/index.d.ts +7 -6
  101. package/esm/dialog/index.js +4 -1
  102. package/esm/dialog/style/css/index.css +26 -4
  103. package/esm/dialog/style/index.less +4 -2
  104. package/esm/divider/style/css/index.css +18 -0
  105. package/esm/dropdown/style/css/index.css +18 -0
  106. package/esm/dropdown-menu/style/css/index.css +18 -0
  107. package/esm/ellipsis/style/css/index.css +18 -0
  108. package/esm/form/style/css/index.css +18 -0
  109. package/esm/grid/style/css/index.css +18 -0
  110. package/esm/image/style/css/index.css +18 -0
  111. package/esm/image-picker/style/css/index.css +18 -0
  112. package/esm/image-preview/style/css/index.css +18 -0
  113. package/esm/index-bar/style/css/index.css +18 -0
  114. package/esm/input/style/css/index.css +18 -0
  115. package/esm/keyboard/style/css/index.css +18 -0
  116. package/esm/load-more/style/css/index.css +18 -0
  117. package/esm/loading/style/css/index.css +18 -0
  118. package/esm/masking/index.d.ts +11 -5
  119. package/esm/masking/index.js +2 -0
  120. package/esm/masking/style/css/index.css +18 -0
  121. package/esm/nav-bar/style/css/index.css +18 -0
  122. package/esm/notice-bar/style/css/index.css +18 -0
  123. package/esm/notify/style/css/index.css +18 -0
  124. package/esm/pagination/style/css/index.css +18 -0
  125. package/esm/picker/style/css/index.css +18 -0
  126. package/esm/picker-view/style/css/index.css +18 -0
  127. package/esm/popover/style/css/index.css +18 -0
  128. package/esm/popover/style/css/menu.css +18 -0
  129. package/esm/popup/index.d.ts +3 -3
  130. package/esm/popup/index.js +1 -0
  131. package/esm/popup/style/css/index.css +35 -0
  132. package/esm/popup/style/index.less +36 -3
  133. package/esm/popup-swiper/index.d.ts +2 -2
  134. package/esm/popup-swiper/index.js +20 -3
  135. package/esm/popup-swiper/style/css/index.css +18 -0
  136. package/esm/progress/style/css/index.css +18 -0
  137. package/esm/pull-refresh/style/css/index.css +18 -0
  138. package/esm/radio/style/css/index.css +18 -0
  139. package/esm/rate/style/css/index.css +18 -0
  140. package/esm/search-bar/style/css/index.css +18 -0
  141. package/esm/skeleton/style/css/index.css +18 -0
  142. package/esm/slider/style/css/index.css +18 -0
  143. package/esm/stepper/style/css/index.css +18 -0
  144. package/esm/steps/style/css/index.css +18 -0
  145. package/esm/sticky/style/css/index.css +18 -0
  146. package/esm/swipe-action/style/css/index.css +18 -0
  147. package/esm/swipe-load/style/css/index.css +18 -0
  148. package/esm/switch/style/css/index.css +18 -0
  149. package/esm/tab-bar/style/css/index.css +18 -0
  150. package/esm/tabs/index.js +7 -3
  151. package/esm/tabs/style/css/index.css +18 -0
  152. package/esm/tabs/tab-cell.js +9 -1
  153. package/esm/tabs/type.d.ts +5 -0
  154. package/esm/tag/style/css/index.css +18 -0
  155. package/esm/textarea/style/css/index.css +18 -0
  156. package/esm/toast/style/css/index.css +18 -0
  157. package/esm/transition/index.d.ts +9 -3
  158. package/esm/transition/index.js +32 -7
  159. package/esm/transition/style/css/index.css +22 -4
  160. package/esm/transition/style/index.less +2 -2
  161. package/esm/uploader/style/css/index.css +18 -0
  162. package/esnext/action-sheet/index.d.ts +2 -2
  163. package/esnext/action-sheet/style/css/index.css +18 -0
  164. package/esnext/avatar/style/css/index.css +18 -0
  165. package/esnext/badge/index.d.ts +2 -1
  166. package/esnext/badge/index.js +1 -1
  167. package/esnext/badge/style/css/index.css +26 -4
  168. package/esnext/badge/style/index.less +4 -2
  169. package/esnext/button/style/css/index.css +18 -0
  170. package/esnext/carousel/style/css/index.css +18 -0
  171. package/esnext/cell/style/css/index.css +18 -0
  172. package/esnext/checkbox/style/css/index.css +18 -0
  173. package/esnext/circle-progress/style/css/index.css +18 -0
  174. package/esnext/collapse/style/css/index.css +18 -0
  175. package/esnext/count-down/style/css/index.css +18 -0
  176. package/esnext/date-picker/style/css/index.css +18 -0
  177. package/esnext/dialog/index.d.ts +7 -6
  178. package/esnext/dialog/index.js +1 -1
  179. package/esnext/dialog/style/css/index.css +26 -4
  180. package/esnext/dialog/style/index.less +4 -2
  181. package/esnext/divider/style/css/index.css +18 -0
  182. package/esnext/dropdown/style/css/index.css +18 -0
  183. package/esnext/dropdown-menu/style/css/index.css +18 -0
  184. package/esnext/ellipsis/style/css/index.css +18 -0
  185. package/esnext/form/style/css/index.css +18 -0
  186. package/esnext/grid/style/css/index.css +18 -0
  187. package/esnext/image/style/css/index.css +18 -0
  188. package/esnext/image-picker/style/css/index.css +18 -0
  189. package/esnext/image-preview/style/css/index.css +18 -0
  190. package/esnext/index-bar/style/css/index.css +18 -0
  191. package/esnext/input/style/css/index.css +18 -0
  192. package/esnext/keyboard/style/css/index.css +18 -0
  193. package/esnext/load-more/style/css/index.css +18 -0
  194. package/esnext/loading/style/css/index.css +18 -0
  195. package/esnext/masking/index.d.ts +11 -5
  196. package/esnext/masking/index.js +3 -3
  197. package/esnext/masking/style/css/index.css +18 -0
  198. package/esnext/nav-bar/style/css/index.css +18 -0
  199. package/esnext/notice-bar/style/css/index.css +18 -0
  200. package/esnext/notify/style/css/index.css +18 -0
  201. package/esnext/pagination/style/css/index.css +18 -0
  202. package/esnext/picker/style/css/index.css +18 -0
  203. package/esnext/picker-view/style/css/index.css +18 -0
  204. package/esnext/popover/style/css/index.css +18 -0
  205. package/esnext/popover/style/css/menu.css +18 -0
  206. package/esnext/popup/index.d.ts +3 -3
  207. package/esnext/popup/index.js +1 -1
  208. package/esnext/popup/style/css/index.css +35 -0
  209. package/esnext/popup/style/index.less +36 -3
  210. package/esnext/popup-swiper/index.d.ts +2 -2
  211. package/esnext/popup-swiper/index.js +7 -2
  212. package/esnext/popup-swiper/style/css/index.css +18 -0
  213. package/esnext/progress/style/css/index.css +18 -0
  214. package/esnext/pull-refresh/style/css/index.css +18 -0
  215. package/esnext/radio/style/css/index.css +18 -0
  216. package/esnext/rate/style/css/index.css +18 -0
  217. package/esnext/search-bar/style/css/index.css +18 -0
  218. package/esnext/skeleton/style/css/index.css +18 -0
  219. package/esnext/slider/style/css/index.css +18 -0
  220. package/esnext/stepper/style/css/index.css +18 -0
  221. package/esnext/steps/style/css/index.css +18 -0
  222. package/esnext/sticky/style/css/index.css +18 -0
  223. package/esnext/swipe-action/style/css/index.css +18 -0
  224. package/esnext/swipe-load/style/css/index.css +18 -0
  225. package/esnext/switch/style/css/index.css +18 -0
  226. package/esnext/tab-bar/style/css/index.css +18 -0
  227. package/esnext/tabs/index.js +3 -2
  228. package/esnext/tabs/style/css/index.css +18 -0
  229. package/esnext/tabs/tab-cell.js +8 -1
  230. package/esnext/tabs/type.d.ts +5 -0
  231. package/esnext/tag/style/css/index.css +18 -0
  232. package/esnext/textarea/style/css/index.css +18 -0
  233. package/esnext/toast/style/css/index.css +18 -0
  234. package/esnext/transition/index.d.ts +9 -3
  235. package/esnext/transition/index.js +28 -3
  236. package/esnext/transition/style/css/index.css +22 -4
  237. package/esnext/transition/style/index.less +2 -2
  238. package/esnext/uploader/style/css/index.css +18 -0
  239. package/package.json +3 -3
  240. package/style/css/public.css +18 -0
  241. package/tokens/mixin/index.less +31 -2
  242. package/umd/action-sheet/index.d.ts +2 -2
  243. package/umd/action-sheet/style/css/index.css +18 -0
  244. package/umd/avatar/style/css/index.css +18 -0
  245. package/umd/badge/index.d.ts +2 -1
  246. package/umd/badge/index.js +1 -1
  247. package/umd/badge/style/css/index.css +26 -4
  248. package/umd/badge/style/index.less +4 -2
  249. package/umd/button/style/css/index.css +18 -0
  250. package/umd/carousel/style/css/index.css +18 -0
  251. package/umd/cell/style/css/index.css +18 -0
  252. package/umd/checkbox/style/css/index.css +18 -0
  253. package/umd/circle-progress/style/css/index.css +18 -0
  254. package/umd/collapse/style/css/index.css +18 -0
  255. package/umd/count-down/style/css/index.css +18 -0
  256. package/umd/date-picker/style/css/index.css +18 -0
  257. package/umd/dialog/index.d.ts +7 -6
  258. package/umd/dialog/index.js +4 -1
  259. package/umd/dialog/style/css/index.css +26 -4
  260. package/umd/dialog/style/index.less +4 -2
  261. package/umd/divider/style/css/index.css +18 -0
  262. package/umd/dropdown/style/css/index.css +18 -0
  263. package/umd/dropdown-menu/style/css/index.css +18 -0
  264. package/umd/ellipsis/style/css/index.css +18 -0
  265. package/umd/form/style/css/index.css +18 -0
  266. package/umd/grid/style/css/index.css +18 -0
  267. package/umd/image/style/css/index.css +18 -0
  268. package/umd/image-picker/style/css/index.css +18 -0
  269. package/umd/image-preview/style/css/index.css +18 -0
  270. package/umd/index-bar/style/css/index.css +18 -0
  271. package/umd/input/style/css/index.css +18 -0
  272. package/umd/keyboard/style/css/index.css +18 -0
  273. package/umd/load-more/style/css/index.css +18 -0
  274. package/umd/loading/style/css/index.css +18 -0
  275. package/umd/masking/index.d.ts +11 -5
  276. package/umd/masking/index.js +2 -0
  277. package/umd/masking/style/css/index.css +18 -0
  278. package/umd/nav-bar/style/css/index.css +18 -0
  279. package/umd/notice-bar/style/css/index.css +18 -0
  280. package/umd/notify/style/css/index.css +18 -0
  281. package/umd/pagination/style/css/index.css +18 -0
  282. package/umd/picker/style/css/index.css +18 -0
  283. package/umd/picker-view/style/css/index.css +18 -0
  284. package/umd/popover/style/css/index.css +18 -0
  285. package/umd/popover/style/css/menu.css +18 -0
  286. package/umd/popup/index.d.ts +3 -3
  287. package/umd/popup/index.js +1 -0
  288. package/umd/popup/style/css/index.css +35 -0
  289. package/umd/popup/style/index.less +36 -3
  290. package/umd/popup-swiper/index.d.ts +2 -2
  291. package/umd/popup-swiper/index.js +20 -3
  292. package/umd/popup-swiper/style/css/index.css +18 -0
  293. package/umd/progress/style/css/index.css +18 -0
  294. package/umd/pull-refresh/style/css/index.css +18 -0
  295. package/umd/radio/style/css/index.css +18 -0
  296. package/umd/rate/style/css/index.css +18 -0
  297. package/umd/search-bar/style/css/index.css +18 -0
  298. package/umd/skeleton/style/css/index.css +18 -0
  299. package/umd/slider/style/css/index.css +18 -0
  300. package/umd/stepper/style/css/index.css +18 -0
  301. package/umd/steps/style/css/index.css +18 -0
  302. package/umd/sticky/style/css/index.css +18 -0
  303. package/umd/swipe-action/style/css/index.css +18 -0
  304. package/umd/swipe-load/style/css/index.css +18 -0
  305. package/umd/switch/style/css/index.css +18 -0
  306. package/umd/tab-bar/style/css/index.css +18 -0
  307. package/umd/tabs/index.js +7 -3
  308. package/umd/tabs/style/css/index.css +18 -0
  309. package/umd/tabs/tab-cell.js +9 -1
  310. package/umd/tabs/type.d.ts +5 -0
  311. package/umd/tag/style/css/index.css +18 -0
  312. package/umd/textarea/style/css/index.css +18 -0
  313. package/umd/toast/style/css/index.css +18 -0
  314. package/umd/transition/index.d.ts +9 -3
  315. package/umd/transition/index.js +36 -6
  316. package/umd/transition/style/css/index.css +22 -4
  317. package/umd/transition/style/index.less +2 -2
  318. package/umd/uploader/style/css/index.css +18 -0
@@ -10,7 +10,7 @@ const Popup = forwardRef((props, ref) => {
10
10
  useImperativeHandle(ref, () => maskingRef.current);
11
11
  function renderPopup({ prefixCls }) {
12
12
  const prefix = `${prefixCls}-popup`;
13
- return (React.createElement(Masking, Object.assign({ className: cls(prefix, className), ref: maskingRef, maskClass: cls(`${prefix}-mask`, { translateZ }, maskClass), contentTransitionType: contentTransitionType || `slide-from-${direction}`, contentClass: cls(`${prefix}-content`, direction, {
13
+ return (React.createElement(Masking, Object.assign({ className: cls(prefix, className), ref: maskingRef, maskClass: cls(`${prefix}-mask`, { translateZ }, maskClass), contentTransitionType: contentTransitionType || `slide-from-${direction}`, contentTransitionVarType: "popup-slide", contentClass: cls(`${prefix}-content`, direction, {
14
14
  'need-bottom-offset': needBottomOffset,
15
15
  }, { translateZ }, contentClass), maskTransitionTimeout: maskTransitionTimeout, contentTransitionTimeout: contentTransitionTimeout }, restProps), children));
16
16
  }
@@ -75,6 +75,24 @@
75
75
  * }
76
76
  * ```
77
77
  */
78
+ /**
79
+ * 为属性设置 transition 变量
80
+ * @desc {en} set the transition variable for the attribute
81
+ * @param @transitionVariable transition 变量名
82
+ * @param @transitionVariable {en} transition variable name
83
+ * @param @backupVariable 备份变量名
84
+ * @param @backupVariable {en} backup variable name
85
+ * @param @property css属性名
86
+ * @param @property {en} css property
87
+ * @example
88
+ * ```
89
+ * @import '@arco-design/mobile-react/style/mixin.less';
90
+ *
91
+ * .demo {
92
+ * .use-transition-var(builtin-transition-fade-enter-duration, transition-fade-duration);
93
+ * }
94
+ * ```
95
+ */
78
96
  /**
79
97
  * 在常规模式和 rtl 模式下为属性设置 arco 提供的 token 变量
80
98
  * @desc {en} set the token variable provided by Arco for the attribute in regular mode and RTL mode
@@ -579,7 +597,16 @@
579
597
  position: fixed;
580
598
  z-index: 1001;
581
599
  }
600
+ .arco-popup-content[class*="-enter-active"] {
601
+ -webkit-transition-duration: var(--builtin-transition-popup-slide-enter-duration, 450ms);
602
+ transition-duration: var(--builtin-transition-popup-slide-enter-duration, 450ms);
603
+ }
604
+ .arco-popup-content[class*="-exit-active"] {
605
+ -webkit-transition-duration: var(--builtin-transition-popup-slide-exit-duration, 240ms);
606
+ transition-duration: var(--builtin-transition-popup-slide-exit-duration, 240ms);
607
+ }
582
608
  .arco-popup-content.need-bottom-offset {
609
+ padding-bottom: constant(safe-area-inset-bottom);
583
610
  padding-bottom: env(safe-area-inset-bottom);
584
611
  }
585
612
  .arco-popup-content.left {
@@ -615,6 +642,14 @@
615
642
  z-index: 1000;
616
643
  background: rgba(0, 0, 0, 0.6) ;
617
644
  }
645
+ .arco-popup-mask[class*="-enter-active"] {
646
+ -webkit-transition-duration: var(--builtin-transition-fade-enter-duration, 450ms);
647
+ transition-duration: var(--builtin-transition-fade-enter-duration, 450ms);
648
+ }
649
+ .arco-popup-mask[class*="-exit-active"] {
650
+ -webkit-transition-duration: var(--builtin-transition-fade-exit-duration, 240ms);
651
+ transition-duration: var(--builtin-transition-fade-exit-duration, 240ms);
652
+ }
618
653
  .arco-popup-mask.translateZ {
619
654
  -webkit-transform: translateZ(1PX);
620
655
  transform: translateZ(1PX);
@@ -1,8 +1,12 @@
1
1
  @import '../../../style/mixin.less';
2
2
 
3
3
  .set-popup-transform(@transform) {
4
- &-enter, &-exit-active, &-exit-done {
4
+
5
+ &-enter,
6
+ &-exit-active,
7
+ &-exit-done {
5
8
  transform: @transform;
9
+
6
10
  &.translateZ {
7
11
  transform: @transform translateZ(2PX);
8
12
  }
@@ -14,63 +18,92 @@
14
18
  &-left {
15
19
  .set-popup-transform(translate(-100%, 0));
16
20
  }
21
+
17
22
  &-right {
18
23
  .set-popup-transform(translate(100%, 0));
19
24
  }
25
+
20
26
  &-top {
21
27
  .set-popup-transform(translate(0, -100%));
22
28
  }
29
+
23
30
  &-bottom {
24
31
  .set-popup-transform(translate(0, 100%));
25
32
  }
26
33
  }
27
- &-content, &-mask {
34
+
35
+ &-content,
36
+ &-mask {
28
37
  &[class*="-enter-active"] {
29
38
  &.translateZ {
30
39
  transform: translateZ(2PX);
31
40
  }
41
+
32
42
  transform: translate(0, 0);
33
43
  .use-var(transition, popup-enter-transition);
34
44
  }
35
45
  }
46
+
36
47
  [class*="-exit-active"] {
37
48
  .use-var(transition, popup-exit-transition);
38
49
  }
50
+
39
51
  &-content {
52
+ &[class*="-enter-active"] {
53
+ transition-duration: var(--builtin-transition-popup-slide-enter-duration, 450ms);
54
+ }
55
+ &[class*="-exit-active"] {
56
+ transition-duration: var(--builtin-transition-popup-slide-exit-duration, 240ms);
57
+ }
40
58
  &.need-bottom-offset {
59
+ padding-bottom: constant(safe-area-inset-bottom);
41
60
  padding-bottom: env(safe-area-inset-bottom);
42
61
  }
62
+
43
63
  &.left {
44
64
  left: 0;
45
65
  top: 0;
46
66
  height: 100%;
47
67
  }
68
+
48
69
  &.top {
49
70
  left: 0;
50
71
  top: 0;
51
72
  width: 100%;
52
73
  }
74
+
53
75
  &.right {
54
76
  right: 0;
55
77
  top: 0;
56
78
  height: 100%;
57
79
  }
80
+
58
81
  &.bottom {
59
82
  left: 0;
60
83
  bottom: 0;
61
84
  width: 100%;
62
85
  }
86
+
63
87
  &.translateZ {
64
88
  transform: translateZ(2PX);
65
89
  }
90
+
66
91
  .use-var(background, popup-content-background);
67
92
  position: fixed;
68
- z-index: @full-screen-z-index + 1;
93
+ z-index: @full-screen-z-index+1;
69
94
  }
95
+
70
96
  &-mask {
97
+ &[class*="-enter-active"] {
98
+ transition-duration: var(--builtin-transition-fade-enter-duration, 450ms);
99
+ }
100
+ &[class*="-exit-active"] {
101
+ transition-duration: var(--builtin-transition-fade-exit-duration, 240ms);
102
+ }
71
103
  &.translateZ {
72
104
  transform: translateZ(1PX);
73
105
  }
106
+
74
107
  position: fixed;
75
108
  width: 100%;
76
109
  height: 100%;
@@ -73,11 +73,11 @@ declare const _default: React.ForwardRefExoticComponent<PopupSwiperProps & React
73
73
  * @param {string | PopupSwiperProps} config Configuration
74
74
  * @returns {{ close: () => void; update: (newConfig: PopupSwiperProps) => void; }}
75
75
  */
76
- open: (config: Pick<import("../context-provider").WithGlobalContext<PopupSwiperProps & React.RefAttributes<PopupSwiperRef>>, "direction" | "children" | "ref" | "key" | "className" | "context" | "translateZ" | "getScrollContainer" | "onTouchStart" | "onTouchMove" | "onTouchEnd" | "getContainer" | "mountOnEnter" | "unmountOnExit" | "onClose" | "maskClass" | "maskStyle" | "contentClass" | "contentStyle" | "maskTransitionType" | "contentTransitionType" | "maskTransitionTimeout" | "contentTransitionTimeout" | "maskClosable" | "animatingClosable" | "orientationDirection" | "preventBodyScroll" | "initialBodyOverflow" | "gestureOutOfControl" | "onOpen" | "onMaskClick" | "onPreventTouchMove" | "needBottomOffset" | "percentToClose" | "distanceToClose" | "speedToClose" | "allowSwipeDirections" | "exitDirection"> & {
76
+ open: (config: Pick<import("../context-provider").WithGlobalContext<PopupSwiperProps & React.RefAttributes<PopupSwiperRef>>, "direction" | "children" | "ref" | "key" | "className" | "context" | "translateZ" | "getScrollContainer" | "onTouchStart" | "onTouchMove" | "onTouchEnd" | "getContainer" | "mountOnEnter" | "unmountOnExit" | "onClose" | "maskClass" | "maskStyle" | "contentClass" | "contentStyle" | "maskTransitionType" | "contentTransitionType" | "contentTransitionVarType" | "maskTransitionTimeout" | "contentTransitionTimeout" | "maskClosable" | "animatingClosable" | "orientationDirection" | "preventBodyScroll" | "initialBodyOverflow" | "gestureOutOfControl" | "onOpen" | "onMaskClick" | "onPreventTouchMove" | "needBottomOffset" | "percentToClose" | "distanceToClose" | "speedToClose" | "allowSwipeDirections" | "exitDirection"> & {
77
77
  key?: string | undefined;
78
78
  }, context?: import("../context-provider").GlobalContextParams | undefined) => {
79
79
  close: () => void;
80
- update: (newConfig: Pick<import("../context-provider").WithGlobalContext<PopupSwiperProps & React.RefAttributes<PopupSwiperRef>>, "direction" | "children" | "ref" | "key" | "className" | "context" | "translateZ" | "getScrollContainer" | "onTouchStart" | "onTouchMove" | "onTouchEnd" | "getContainer" | "mountOnEnter" | "unmountOnExit" | "onClose" | "maskClass" | "maskStyle" | "contentClass" | "contentStyle" | "maskTransitionType" | "contentTransitionType" | "maskTransitionTimeout" | "contentTransitionTimeout" | "maskClosable" | "animatingClosable" | "orientationDirection" | "preventBodyScroll" | "initialBodyOverflow" | "gestureOutOfControl" | "onOpen" | "onMaskClick" | "onPreventTouchMove" | "needBottomOffset" | "percentToClose" | "distanceToClose" | "speedToClose" | "allowSwipeDirections" | "exitDirection"> & {
80
+ update: (newConfig: Pick<import("../context-provider").WithGlobalContext<PopupSwiperProps & React.RefAttributes<PopupSwiperRef>>, "direction" | "children" | "ref" | "key" | "className" | "context" | "translateZ" | "getScrollContainer" | "onTouchStart" | "onTouchMove" | "onTouchEnd" | "getContainer" | "mountOnEnter" | "unmountOnExit" | "onClose" | "maskClass" | "maskStyle" | "contentClass" | "contentStyle" | "maskTransitionType" | "contentTransitionType" | "contentTransitionVarType" | "maskTransitionTimeout" | "contentTransitionTimeout" | "maskClosable" | "animatingClosable" | "orientationDirection" | "preventBodyScroll" | "initialBodyOverflow" | "gestureOutOfControl" | "onOpen" | "onMaskClick" | "onPreventTouchMove" | "needBottomOffset" | "percentToClose" | "distanceToClose" | "speedToClose" | "allowSwipeDirections" | "exitDirection"> & {
81
81
  key?: string | undefined;
82
82
  }) => void;
83
83
  };
@@ -5,7 +5,7 @@ import Popup from '../popup';
5
5
  import { open } from './methods';
6
6
  import { getStyleWithVendor, useRefState } from '../_helpers';
7
7
  const PopupSwiper = forwardRef((props, ref) => {
8
- const { className = '', visible, children, maskStyle, contentStyle, direction = 'bottom', percentToClose = 0.3, distanceToClose = 10, speedToClose = 200, allowSwipeDirections, exitDirection, onTouchMove, onTouchStart, onTouchEnd, onOpen, onClose, close, ...otherProps } = props;
8
+ const { className = '', visible, children, maskStyle, contentStyle, direction = 'bottom', percentToClose = 0.3, distanceToClose = 10, speedToClose = 200, allowSwipeDirections, exitDirection, onTouchMove, onTouchStart, onTouchEnd, onOpen, onClose, close, maskTransitionTimeout = { enter: 450, exit: 240 }, contentTransitionTimeout = { enter: 450, exit: 240 }, ...otherProps } = props;
9
9
  const [opened, setOpened] = useState(visible);
10
10
  const [distance, distanceRef, setDistance] = useRefState({
11
11
  direction: 'X',
@@ -121,6 +121,11 @@ const PopupSwiper = forwardRef((props, ref) => {
121
121
  direction: 'X',
122
122
  value: 0,
123
123
  });
124
+ // 动画完成后需重置
125
+ // @en Reset after animation is complete
126
+ setTimeout(() => {
127
+ setHasTrans(false);
128
+ }, Math.max(typeof maskTransitionTimeout === 'number' ? maskTransitionTimeout : maskTransitionTimeout?.exit || 0, typeof contentTransitionTimeout === 'number' ? contentTransitionTimeout : contentTransitionTimeout?.exit || 0, 240));
124
129
  }
125
130
  touchStartTimeRef.current = 0;
126
131
  }, [onTouchEnd, percentToClose, distanceToClose, speedToClose, close]);
@@ -167,7 +172,7 @@ const PopupSwiper = forwardRef((props, ref) => {
167
172
  }, maskStyle: {
168
173
  ...(maskStyle || {}),
169
174
  opacity: percent ? 1 - percent : void 0,
170
- }, contentStyle: getContentStyle() }, otherProps), children))));
175
+ }, contentStyle: getContentStyle(), maskTransitionTimeout: maskTransitionTimeout, contentTransitionTimeout: contentTransitionTimeout }, otherProps), children))));
171
176
  });
172
177
  export function methodsGenerator(Comp) {
173
178
  return {
@@ -75,6 +75,24 @@
75
75
  * }
76
76
  * ```
77
77
  */
78
+ /**
79
+ * 为属性设置 transition 变量
80
+ * @desc {en} set the transition variable for the attribute
81
+ * @param @transitionVariable transition 变量名
82
+ * @param @transitionVariable {en} transition variable name
83
+ * @param @backupVariable 备份变量名
84
+ * @param @backupVariable {en} backup variable name
85
+ * @param @property css属性名
86
+ * @param @property {en} css property
87
+ * @example
88
+ * ```
89
+ * @import '@arco-design/mobile-react/style/mixin.less';
90
+ *
91
+ * .demo {
92
+ * .use-transition-var(builtin-transition-fade-enter-duration, transition-fade-duration);
93
+ * }
94
+ * ```
95
+ */
78
96
  /**
79
97
  * 在常规模式和 rtl 模式下为属性设置 arco 提供的 token 变量
80
98
  * @desc {en} set the token variable provided by Arco for the attribute in regular mode and RTL mode
@@ -75,6 +75,24 @@
75
75
  * }
76
76
  * ```
77
77
  */
78
+ /**
79
+ * 为属性设置 transition 变量
80
+ * @desc {en} set the transition variable for the attribute
81
+ * @param @transitionVariable transition 变量名
82
+ * @param @transitionVariable {en} transition variable name
83
+ * @param @backupVariable 备份变量名
84
+ * @param @backupVariable {en} backup variable name
85
+ * @param @property css属性名
86
+ * @param @property {en} css property
87
+ * @example
88
+ * ```
89
+ * @import '@arco-design/mobile-react/style/mixin.less';
90
+ *
91
+ * .demo {
92
+ * .use-transition-var(builtin-transition-fade-enter-duration, transition-fade-duration);
93
+ * }
94
+ * ```
95
+ */
78
96
  /**
79
97
  * 在常规模式和 rtl 模式下为属性设置 arco 提供的 token 变量
80
98
  * @desc {en} set the token variable provided by Arco for the attribute in regular mode and RTL mode
@@ -75,6 +75,24 @@
75
75
  * }
76
76
  * ```
77
77
  */
78
+ /**
79
+ * 为属性设置 transition 变量
80
+ * @desc {en} set the transition variable for the attribute
81
+ * @param @transitionVariable transition 变量名
82
+ * @param @transitionVariable {en} transition variable name
83
+ * @param @backupVariable 备份变量名
84
+ * @param @backupVariable {en} backup variable name
85
+ * @param @property css属性名
86
+ * @param @property {en} css property
87
+ * @example
88
+ * ```
89
+ * @import '@arco-design/mobile-react/style/mixin.less';
90
+ *
91
+ * .demo {
92
+ * .use-transition-var(builtin-transition-fade-enter-duration, transition-fade-duration);
93
+ * }
94
+ * ```
95
+ */
78
96
  /**
79
97
  * 在常规模式和 rtl 模式下为属性设置 arco 提供的 token 变量
80
98
  * @desc {en} set the token variable provided by Arco for the attribute in regular mode and RTL mode
@@ -75,6 +75,24 @@
75
75
  * }
76
76
  * ```
77
77
  */
78
+ /**
79
+ * 为属性设置 transition 变量
80
+ * @desc {en} set the transition variable for the attribute
81
+ * @param @transitionVariable transition 变量名
82
+ * @param @transitionVariable {en} transition variable name
83
+ * @param @backupVariable 备份变量名
84
+ * @param @backupVariable {en} backup variable name
85
+ * @param @property css属性名
86
+ * @param @property {en} css property
87
+ * @example
88
+ * ```
89
+ * @import '@arco-design/mobile-react/style/mixin.less';
90
+ *
91
+ * .demo {
92
+ * .use-transition-var(builtin-transition-fade-enter-duration, transition-fade-duration);
93
+ * }
94
+ * ```
95
+ */
78
96
  /**
79
97
  * 在常规模式和 rtl 模式下为属性设置 arco 提供的 token 变量
80
98
  * @desc {en} set the token variable provided by Arco for the attribute in regular mode and RTL mode
@@ -75,6 +75,24 @@
75
75
  * }
76
76
  * ```
77
77
  */
78
+ /**
79
+ * 为属性设置 transition 变量
80
+ * @desc {en} set the transition variable for the attribute
81
+ * @param @transitionVariable transition 变量名
82
+ * @param @transitionVariable {en} transition variable name
83
+ * @param @backupVariable 备份变量名
84
+ * @param @backupVariable {en} backup variable name
85
+ * @param @property css属性名
86
+ * @param @property {en} css property
87
+ * @example
88
+ * ```
89
+ * @import '@arco-design/mobile-react/style/mixin.less';
90
+ *
91
+ * .demo {
92
+ * .use-transition-var(builtin-transition-fade-enter-duration, transition-fade-duration);
93
+ * }
94
+ * ```
95
+ */
78
96
  /**
79
97
  * 在常规模式和 rtl 模式下为属性设置 arco 提供的 token 变量
80
98
  * @desc {en} set the token variable provided by Arco for the attribute in regular mode and RTL mode
@@ -75,6 +75,24 @@
75
75
  * }
76
76
  * ```
77
77
  */
78
+ /**
79
+ * 为属性设置 transition 变量
80
+ * @desc {en} set the transition variable for the attribute
81
+ * @param @transitionVariable transition 变量名
82
+ * @param @transitionVariable {en} transition variable name
83
+ * @param @backupVariable 备份变量名
84
+ * @param @backupVariable {en} backup variable name
85
+ * @param @property css属性名
86
+ * @param @property {en} css property
87
+ * @example
88
+ * ```
89
+ * @import '@arco-design/mobile-react/style/mixin.less';
90
+ *
91
+ * .demo {
92
+ * .use-transition-var(builtin-transition-fade-enter-duration, transition-fade-duration);
93
+ * }
94
+ * ```
95
+ */
78
96
  /**
79
97
  * 在常规模式和 rtl 模式下为属性设置 arco 提供的 token 变量
80
98
  * @desc {en} set the token variable provided by Arco for the attribute in regular mode and RTL mode
@@ -75,6 +75,24 @@
75
75
  * }
76
76
  * ```
77
77
  */
78
+ /**
79
+ * 为属性设置 transition 变量
80
+ * @desc {en} set the transition variable for the attribute
81
+ * @param @transitionVariable transition 变量名
82
+ * @param @transitionVariable {en} transition variable name
83
+ * @param @backupVariable 备份变量名
84
+ * @param @backupVariable {en} backup variable name
85
+ * @param @property css属性名
86
+ * @param @property {en} css property
87
+ * @example
88
+ * ```
89
+ * @import '@arco-design/mobile-react/style/mixin.less';
90
+ *
91
+ * .demo {
92
+ * .use-transition-var(builtin-transition-fade-enter-duration, transition-fade-duration);
93
+ * }
94
+ * ```
95
+ */
78
96
  /**
79
97
  * 在常规模式和 rtl 模式下为属性设置 arco 提供的 token 变量
80
98
  * @desc {en} set the token variable provided by Arco for the attribute in regular mode and RTL mode
@@ -75,6 +75,24 @@
75
75
  * }
76
76
  * ```
77
77
  */
78
+ /**
79
+ * 为属性设置 transition 变量
80
+ * @desc {en} set the transition variable for the attribute
81
+ * @param @transitionVariable transition 变量名
82
+ * @param @transitionVariable {en} transition variable name
83
+ * @param @backupVariable 备份变量名
84
+ * @param @backupVariable {en} backup variable name
85
+ * @param @property css属性名
86
+ * @param @property {en} css property
87
+ * @example
88
+ * ```
89
+ * @import '@arco-design/mobile-react/style/mixin.less';
90
+ *
91
+ * .demo {
92
+ * .use-transition-var(builtin-transition-fade-enter-duration, transition-fade-duration);
93
+ * }
94
+ * ```
95
+ */
78
96
  /**
79
97
  * 在常规模式和 rtl 模式下为属性设置 arco 提供的 token 变量
80
98
  * @desc {en} set the token variable provided by Arco for the attribute in regular mode and RTL mode
@@ -75,6 +75,24 @@
75
75
  * }
76
76
  * ```
77
77
  */
78
+ /**
79
+ * 为属性设置 transition 变量
80
+ * @desc {en} set the transition variable for the attribute
81
+ * @param @transitionVariable transition 变量名
82
+ * @param @transitionVariable {en} transition variable name
83
+ * @param @backupVariable 备份变量名
84
+ * @param @backupVariable {en} backup variable name
85
+ * @param @property css属性名
86
+ * @param @property {en} css property
87
+ * @example
88
+ * ```
89
+ * @import '@arco-design/mobile-react/style/mixin.less';
90
+ *
91
+ * .demo {
92
+ * .use-transition-var(builtin-transition-fade-enter-duration, transition-fade-duration);
93
+ * }
94
+ * ```
95
+ */
78
96
  /**
79
97
  * 在常规模式和 rtl 模式下为属性设置 arco 提供的 token 变量
80
98
  * @desc {en} set the token variable provided by Arco for the attribute in regular mode and RTL mode
@@ -75,6 +75,24 @@
75
75
  * }
76
76
  * ```
77
77
  */
78
+ /**
79
+ * 为属性设置 transition 变量
80
+ * @desc {en} set the transition variable for the attribute
81
+ * @param @transitionVariable transition 变量名
82
+ * @param @transitionVariable {en} transition variable name
83
+ * @param @backupVariable 备份变量名
84
+ * @param @backupVariable {en} backup variable name
85
+ * @param @property css属性名
86
+ * @param @property {en} css property
87
+ * @example
88
+ * ```
89
+ * @import '@arco-design/mobile-react/style/mixin.less';
90
+ *
91
+ * .demo {
92
+ * .use-transition-var(builtin-transition-fade-enter-duration, transition-fade-duration);
93
+ * }
94
+ * ```
95
+ */
78
96
  /**
79
97
  * 在常规模式和 rtl 模式下为属性设置 arco 提供的 token 变量
80
98
  * @desc {en} set the token variable provided by Arco for the attribute in regular mode and RTL mode
@@ -75,6 +75,24 @@
75
75
  * }
76
76
  * ```
77
77
  */
78
+ /**
79
+ * 为属性设置 transition 变量
80
+ * @desc {en} set the transition variable for the attribute
81
+ * @param @transitionVariable transition 变量名
82
+ * @param @transitionVariable {en} transition variable name
83
+ * @param @backupVariable 备份变量名
84
+ * @param @backupVariable {en} backup variable name
85
+ * @param @property css属性名
86
+ * @param @property {en} css property
87
+ * @example
88
+ * ```
89
+ * @import '@arco-design/mobile-react/style/mixin.less';
90
+ *
91
+ * .demo {
92
+ * .use-transition-var(builtin-transition-fade-enter-duration, transition-fade-duration);
93
+ * }
94
+ * ```
95
+ */
78
96
  /**
79
97
  * 在常规模式和 rtl 模式下为属性设置 arco 提供的 token 变量
80
98
  * @desc {en} set the token variable provided by Arco for the attribute in regular mode and RTL mode
@@ -75,6 +75,24 @@
75
75
  * }
76
76
  * ```
77
77
  */
78
+ /**
79
+ * 为属性设置 transition 变量
80
+ * @desc {en} set the transition variable for the attribute
81
+ * @param @transitionVariable transition 变量名
82
+ * @param @transitionVariable {en} transition variable name
83
+ * @param @backupVariable 备份变量名
84
+ * @param @backupVariable {en} backup variable name
85
+ * @param @property css属性名
86
+ * @param @property {en} css property
87
+ * @example
88
+ * ```
89
+ * @import '@arco-design/mobile-react/style/mixin.less';
90
+ *
91
+ * .demo {
92
+ * .use-transition-var(builtin-transition-fade-enter-duration, transition-fade-duration);
93
+ * }
94
+ * ```
95
+ */
78
96
  /**
79
97
  * 在常规模式和 rtl 模式下为属性设置 arco 提供的 token 变量
80
98
  * @desc {en} set the token variable provided by Arco for the attribute in regular mode and RTL mode
@@ -75,6 +75,24 @@
75
75
  * }
76
76
  * ```
77
77
  */
78
+ /**
79
+ * 为属性设置 transition 变量
80
+ * @desc {en} set the transition variable for the attribute
81
+ * @param @transitionVariable transition 变量名
82
+ * @param @transitionVariable {en} transition variable name
83
+ * @param @backupVariable 备份变量名
84
+ * @param @backupVariable {en} backup variable name
85
+ * @param @property css属性名
86
+ * @param @property {en} css property
87
+ * @example
88
+ * ```
89
+ * @import '@arco-design/mobile-react/style/mixin.less';
90
+ *
91
+ * .demo {
92
+ * .use-transition-var(builtin-transition-fade-enter-duration, transition-fade-duration);
93
+ * }
94
+ * ```
95
+ */
78
96
  /**
79
97
  * 在常规模式和 rtl 模式下为属性设置 arco 提供的 token 变量
80
98
  * @desc {en} set the token variable provided by Arco for the attribute in regular mode and RTL mode
@@ -75,6 +75,24 @@
75
75
  * }
76
76
  * ```
77
77
  */
78
+ /**
79
+ * 为属性设置 transition 变量
80
+ * @desc {en} set the transition variable for the attribute
81
+ * @param @transitionVariable transition 变量名
82
+ * @param @transitionVariable {en} transition variable name
83
+ * @param @backupVariable 备份变量名
84
+ * @param @backupVariable {en} backup variable name
85
+ * @param @property css属性名
86
+ * @param @property {en} css property
87
+ * @example
88
+ * ```
89
+ * @import '@arco-design/mobile-react/style/mixin.less';
90
+ *
91
+ * .demo {
92
+ * .use-transition-var(builtin-transition-fade-enter-duration, transition-fade-duration);
93
+ * }
94
+ * ```
95
+ */
78
96
  /**
79
97
  * 在常规模式和 rtl 模式下为属性设置 arco 提供的 token 变量
80
98
  * @desc {en} set the token variable provided by Arco for the attribute in regular mode and RTL mode
@@ -75,6 +75,24 @@
75
75
  * }
76
76
  * ```
77
77
  */
78
+ /**
79
+ * 为属性设置 transition 变量
80
+ * @desc {en} set the transition variable for the attribute
81
+ * @param @transitionVariable transition 变量名
82
+ * @param @transitionVariable {en} transition variable name
83
+ * @param @backupVariable 备份变量名
84
+ * @param @backupVariable {en} backup variable name
85
+ * @param @property css属性名
86
+ * @param @property {en} css property
87
+ * @example
88
+ * ```
89
+ * @import '@arco-design/mobile-react/style/mixin.less';
90
+ *
91
+ * .demo {
92
+ * .use-transition-var(builtin-transition-fade-enter-duration, transition-fade-duration);
93
+ * }
94
+ * ```
95
+ */
78
96
  /**
79
97
  * 在常规模式和 rtl 模式下为属性设置 arco 提供的 token 变量
80
98
  * @desc {en} set the token variable provided by Arco for the attribute in regular mode and RTL mode
@@ -205,6 +205,8 @@ const Tabs = forwardRef((props, ref) => {
205
205
  if (scrollingRef.current && tabBarResetWhenScroll === 'touchend') {
206
206
  cellRef.current && cellRef.current.scrollToCenter();
207
207
  }
208
+ setCellTrans(true);
209
+ setPaneTrans(true);
208
210
  if (!touchStartedRef.current ||
209
211
  posAdjustingRef.current ||
210
212
  scrollingRef.current ||
@@ -212,8 +214,6 @@ const Tabs = forwardRef((props, ref) => {
212
214
  return;
213
215
  }
214
216
  touchStartedRef.current = false;
215
- setCellTrans(true);
216
- setPaneTrans(true);
217
217
  const touchEndTime = new Date().getTime();
218
218
  const dis = distanceRef.current;
219
219
  const speed = (dis / (touchEndTime - touchStartTimeRef.current)) * 1000;
@@ -329,6 +329,7 @@ const Tabs = forwardRef((props, ref) => {
329
329
  tabBarStyle,
330
330
  tabBarClass,
331
331
  tabBarStopPropagation,
332
+ onUnderlineFirstShow: () => setCellTrans(true),
332
333
  ...commonProps,
333
334
  };
334
335
  const CellComp = React.createElement(TabCell, Object.assign({}, cellProps));
@@ -75,6 +75,24 @@
75
75
  * }
76
76
  * ```
77
77
  */
78
+ /**
79
+ * 为属性设置 transition 变量
80
+ * @desc {en} set the transition variable for the attribute
81
+ * @param @transitionVariable transition 变量名
82
+ * @param @transitionVariable {en} transition variable name
83
+ * @param @backupVariable 备份变量名
84
+ * @param @backupVariable {en} backup variable name
85
+ * @param @property css属性名
86
+ * @param @property {en} css property
87
+ * @example
88
+ * ```
89
+ * @import '@arco-design/mobile-react/style/mixin.less';
90
+ *
91
+ * .demo {
92
+ * .use-transition-var(builtin-transition-fade-enter-duration, transition-fade-duration);
93
+ * }
94
+ * ```
95
+ */
78
96
  /**
79
97
  * 在常规模式和 rtl 模式下为属性设置 arco 提供的 token 变量
80
98
  * @desc {en} set the token variable provided by Arco for the attribute in regular mode and RTL mode