mirror of
https://gitee.com/vant-contrib/vant.git
synced 2026-07-09 07:51:07 +08:00
Compare commits
3 Commits
8a1f7872c5
...
ef8331bd23
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
ef8331bd23 | ||
|
|
dfe0769b97 | ||
|
|
97391aaa30 |
@ -16,6 +16,15 @@ Vant follows [Semantic Versioning 2.0.0](https://semver.org/lang/zh-CN/).
|
||||
|
||||
## Details
|
||||
|
||||
### [v2.12.54](https://github.com/vant-ui/vant/compare/v2.12.53...v2.12.54)
|
||||
|
||||
`2023-02-11`
|
||||
|
||||
**Bug Fixes**
|
||||
|
||||
- Popover: location update after transition [#11558](https://github.com/vant-ui/vant/issues/11558)
|
||||
- Search: @search-left-icon-color var not work [#11299](https://github.com/vant-ui/vant/issues/11299)
|
||||
|
||||
### [v2.12.53](https://github.com/vant-ui/vant/compare/v2.12.52...v2.12.53)
|
||||
|
||||
`2022-11-17`
|
||||
|
||||
@ -25,6 +25,15 @@ Vant 遵循 [Semver](https://semver.org/lang/zh-CN/) 语义化版本规范。
|
||||
|
||||
## 更新内容
|
||||
|
||||
### [v2.12.54](https://github.com/vant-ui/vant/compare/v2.12.53...v2.12.54)
|
||||
|
||||
`2023-02-11`
|
||||
|
||||
**Bug Fixes**
|
||||
|
||||
- Popover: 修复过渡动画后位置错误的问题 [#11558](https://github.com/vant-ui/vant/issues/11558)
|
||||
- Search: 修复 @search-left-icon-color 样式变量不生效的问题 [#11299](https://github.com/vant-ui/vant/issues/11299)
|
||||
|
||||
### [v2.12.53](https://github.com/vant-ui/vant/compare/v2.12.52...v2.12.53)
|
||||
|
||||
`2022-11-17`
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "vant",
|
||||
"version": "2.12.53",
|
||||
"version": "2.12.54",
|
||||
"description": "Mobile UI Components built on Vue",
|
||||
"main": "lib/index.js",
|
||||
"module": "es/index.js",
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
import { createPopper, offsetModifier } from '@vant/popperjs';
|
||||
import { createNamespace } from '../utils';
|
||||
import { createNamespace, isServer } from '../utils';
|
||||
import { BORDER_BOTTOM } from '../utils/constant';
|
||||
|
||||
// Mixins
|
||||
@ -60,6 +60,10 @@ export default createComponent({
|
||||
|
||||
beforeDestroy() {
|
||||
if (this.popper) {
|
||||
if (!isServer) {
|
||||
window.removeEventListener('animationend', this.updateLocation);
|
||||
window.removeEventListener('transitionend', this.updateLocation);
|
||||
}
|
||||
this.popper.destroy();
|
||||
this.popper = null;
|
||||
}
|
||||
@ -67,7 +71,7 @@ export default createComponent({
|
||||
|
||||
methods: {
|
||||
createPopper() {
|
||||
return createPopper(this.$refs.wrapper, this.$refs.popover.$el, {
|
||||
const popper = createPopper(this.$refs.wrapper, this.$refs.popover.$el, {
|
||||
placement: this.placement,
|
||||
modifiers: [
|
||||
{
|
||||
@ -85,6 +89,11 @@ export default createComponent({
|
||||
},
|
||||
],
|
||||
});
|
||||
if (!isServer) {
|
||||
window.addEventListener('animationend', this.updateLocation);
|
||||
window.addEventListener('transitionend', this.updateLocation);
|
||||
}
|
||||
return popper;
|
||||
},
|
||||
|
||||
updateLocation() {
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user