Skip to content

Commit

Permalink
fix(ui/card): fix the problem of ripple accidental failure
Browse files Browse the repository at this point in the history
  • Loading branch information
haoziqaq authored and BeADre committed Sep 18, 2022
1 parent 64260c9 commit facd510
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 25 deletions.
22 changes: 11 additions & 11 deletions packages/varlet-ui/docs/home.en-US.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,17 @@ Varlet is a Material design mobile component library developed based on `Vue3`,

### Features

- 🚀 Provide 50 high quality general purpose components
- 🚀 Components are very lightweight
- 💪 Developed by Chinese, complete Chinese and English documentation and logistics support
- 🛠️ Support on-demand introduction
- 🛠️ Support theme customization
- 🌍 Support internationalization
- 💡 Support WebStorm, VS Code component syntax highlighting
- 💪 Support the SSR
- 💡 Support the Typescript
- 💪 Make sure more than 90 percent unit test coverage, providing stability assurance
- 🛠️ Support dark mode
- 🚀   Provide 50 high quality general purpose components
- 🚀   Components are very lightweight
- 💪   Developed by Chinese, complete Chinese and English documentation and logistics support
- 🛠️   Support on-demand introduction
- 🛠️   Support theme customization
- 🌍   Support internationalization
- 💡   Support WebStorm, VS Code component syntax highlighting
- 💪   Support the SSR
- 💡   Support the Typescript
- 💪   Make sure more than 90 percent unit test coverage, providing stability assurance
- 🛠️   Support dark mode

### PR & Issue
If you have any problems during use, you can [issue](https://github.com/varletjs/varlet/issues) them to us on [github](https://github.com/varletjs/varlet),
Expand Down
22 changes: 11 additions & 11 deletions packages/varlet-ui/docs/home.zh-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,17 @@ Varlet 是一个基于 `Vue3` 开发的 Material 风格移动端组件库,全

### 特性

- 🚀 提供50个高质量通用组件
- 🚀 组件十分轻量
- 💪 由国人开发,完善的中英文文档和后勤保障
- 🛠️ 支持按需引入
- 🛠️ 支持主题定制
- 🌍 支持国际化
- 💡 支持 webstorm,vscode 组件属性高亮
- 💪 支持 SSR
- 💡 支持 Typescript
- 💪 确保90%以上单元测试覆盖率,提供稳定性保证
- 🛠️ 支持暗黑模式
- 🚀   提供 50 个高质量通用组件
- 🚀   组件十分轻量
- 💪   由国人开发,完善的中英文文档和后勤保障
- 🛠️   支持按需引入
- 🛠️   支持主题定制
- 🌍   支持国际化
- 💡   支持 webstorm,vscode 组件属性高亮
- 💪   支持 SSR
- 💡   支持 Typescript
- 💪   确保 90% 以上单元测试覆盖率,提供稳定性保证
- 🛠️   支持暗黑模式

### PR & Issue
使用过程中出现的问题可以到 [github](https://github.com/varletjs/varlet) 来给我们提 [issue](https://github.com/varletjs/varlet/issues)
Expand Down
2 changes: 1 addition & 1 deletion packages/varlet-ui/src/card/Card.vue
Original file line number Diff line number Diff line change
Expand Up @@ -127,10 +127,10 @@ export default defineComponent({
const floaterOverflow: Ref<string> = ref('hidden')
const contentHeight: Ref<string> = ref('0px')
const opacity: Ref<string> = ref('0')
const { zIndex } = useZIndex(() => props.floating, 1)
const isRow = computed(() => props.layout === 'row')
const showFloatingButtons: Ref<boolean> = ref(false)
const floated: Ref<boolean> = ref(false)
const { zIndex } = useZIndex(() => props.floating, 1)
useLock(
() => props.floating,
Expand Down
3 changes: 1 addition & 2 deletions packages/varlet-ui/src/ripple/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,6 @@ function computeRippleStyles(element: RippleHTMLElement, event: TouchEvent): Rip

function createRipple(this: RippleHTMLElement, event: TouchEvent) {
const _ripple = this._ripple as RippleOptions
_ripple.removeRipple()

if (_ripple.disabled || _ripple.tasker) {
return
Expand Down Expand Up @@ -167,7 +166,7 @@ function updated(el: RippleHTMLElement, binding: DirectiveBinding<RippleOptions>

if (diff) {
el._ripple = {
tasker: el._ripple?.tasker,
tasker: newBinding.disabled ? null : el._ripple?.tasker,
removeRipple: el._ripple?.removeRipple,
...newBinding,
}
Expand Down

0 comments on commit facd510

Please sign in to comment.