From ebfd05cdf5e8532a67aa7959f01a59148bdb08eb Mon Sep 17 00:00:00 2001 From: Tyh2001 <1469442737@qq.com> Date: Mon, 22 May 2023 14:39:50 +0800 Subject: [PATCH] =?UTF-8?q?revert:=20=E5=8F=91=E5=B8=83=E6=96=B0=E7=89=88?= =?UTF-8?q?=E6=9C=AC=200.40.3=20(2023-05-22)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- CHANGELOG.en-US.md | 4 ++++ CHANGELOG.md | 4 ++++ docs/docs/changelog.md | 4 ++++ packages/fighting-design/_hooks/use-trigger/index.ts | 10 ++++++---- packages/fighting-design/image/src/image.vue | 2 +- packages/fighting-design/package.json | 2 +- packages/fighting-theme/src/avatar.scss | 2 +- packages/fighting-theme/src/image.scss | 3 +-- 8 files changed, 22 insertions(+), 9 deletions(-) diff --git a/CHANGELOG.en-US.md b/CHANGELOG.en-US.md index 338a3376e6..0a21c6c0fc 100644 --- a/CHANGELOG.en-US.md +++ b/CHANGELOG.en-US.md @@ -4,6 +4,10 @@ English | [Chinese](https://github.com/FightingDesign/fighting-design/blob/master/CHANGELOG.md) +## 0.40.3 (2023-05-22) + +- Fix unexpected margin display issue in the `f-avatar` component + ## 0.40.2 (2023-05-20) **Add** diff --git a/CHANGELOG.md b/CHANGELOG.md index 12420dff00..adf6d81a93 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,10 @@ 中文 | [英文](https://github.com/FightingDesign/fighting-design/blob/master/CHANGELOG.en-US.md) +## 0.40.3 (2023-05-22) + +- 修复 `f-avatar` 组件意外的边距展示问题 + ## 0.40.2 (2023-05-20) **新增** diff --git a/docs/docs/changelog.md b/docs/docs/changelog.md index 12420dff00..adf6d81a93 100644 --- a/docs/docs/changelog.md +++ b/docs/docs/changelog.md @@ -2,6 +2,10 @@ 中文 | [英文](https://github.com/FightingDesign/fighting-design/blob/master/CHANGELOG.en-US.md) +## 0.40.3 (2023-05-22) + +- 修复 `f-avatar` 组件意外的边距展示问题 + ## 0.40.2 (2023-05-20) **新增** diff --git a/packages/fighting-design/_hooks/use-trigger/index.ts b/packages/fighting-design/_hooks/use-trigger/index.ts index 60ac4929dc..4d81cd79a8 100644 --- a/packages/fighting-design/_hooks/use-trigger/index.ts +++ b/packages/fighting-design/_hooks/use-trigger/index.ts @@ -212,8 +212,9 @@ export const useTrigger = ( */ const onBeforeEnter = (el: Element): void => { if (prop.trigger === 'hover') { - ;(el as HTMLElement).addEventListener('mouseenter', contentLave) - ;(el as HTMLElement).addEventListener('mouseleave', close) + const node = el as HTMLElement + node.addEventListener('mouseenter', contentLave) + node.addEventListener('mouseleave', close) } /** @@ -244,8 +245,9 @@ export const useTrigger = ( */ const onAfterLeave = (el: Element): void => { if (prop.trigger === 'hover') { - ;(el as HTMLElement).removeEventListener('mouseenter', contentLave) - ;(el as HTMLElement).removeEventListener('mouseleave', close) + const node = el as HTMLElement + node.removeEventListener('mouseenter', contentLave) + node.removeEventListener('mouseleave', close) } } diff --git a/packages/fighting-design/image/src/image.vue b/packages/fighting-design/image/src/image.vue index 06a79202c3..c88b81c10c 100644 --- a/packages/fighting-design/image/src/image.vue +++ b/packages/fighting-design/image/src/image.vue @@ -37,7 +37,7 @@