Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: optimize user avatar loading or error display #702

Merged
merged 2 commits into from
May 29, 2024

Conversation

orangelckc
Copy link
Contributor

#698
使用 1x1 像素的透明 GIF 图片,消除头像图片加载失败时的边框

@baboon-king baboon-king self-requested a review May 28, 2024 12:06
Copy link
Collaborator

@baboon-king baboon-king left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

非常巧妙的办法!🥳
但是你能试试这个吗
在 apps/client/components/Home/index.vue L5-L12 使用下面的代码

<div
  class="mx-auto h-56 w-56 overflow-hidden rounded-full border-2 border-gray-300 bg-gray-300 dark:border-gray-700 dark:bg-gray-700"
>
  <img
    class="h-full object-cover"
    :src="userStore.userInfo?.picture!"
  />
</div>

这样的话,我们或许可以,不用采用这么魔法的方式,

@orangelckc
Copy link
Contributor Author

非常巧妙的办法!🥳 但是你能试试这个吗 在 apps/client/components/Home/index.vue L5-L12 使用下面的代码

<div
  class="mx-auto h-56 w-56 overflow-hidden rounded-full border-2 border-gray-300 bg-gray-300 dark:border-gray-700 dark:bg-gray-700"
>
  <img
    class="h-full object-cover"
    :src="userStore.userInfo?.picture!"
  />
</div>

这样的话,我们或许可以,不用采用这么魔法的方式,

感谢,这么看是我想麻烦了,有点思维定势了😓

那这个PR我就关掉啦~

@orangelckc orangelckc closed this May 29, 2024
@baboon-king baboon-king reopened this May 29, 2024
@baboon-king
Copy link
Collaborator

非常巧妙的办法!🥳 但是你能试试这个吗 在 apps/client/components/Home/index.vue L5-L12 使用下面的代码

<div
  class="mx-auto h-56 w-56 overflow-hidden rounded-full border-2 border-gray-300 bg-gray-300 dark:border-gray-700 dark:bg-gray-700"
>
  <img
    class="h-full object-cover"
    :src="userStore.userInfo?.picture!"
  />
</div>

这样的话,我们或许可以,不用采用这么魔法的方式,

感谢,这么看是我想麻烦了,有点思维定势了😓

那这个PR我就关掉啦~

你可以更新你现在的代码,然后重新提交。我们依然可以继续合并这个PR🥳

@fengstats fengstats self-requested a review May 29, 2024 21:38
@fengstats
Copy link
Collaborator

fengstats commented May 29, 2024

@baboon-king 不错的思路~ 爱了 😊

@fengstats fengstats merged commit 49460cd into cuixueshe:main May 29, 2024
1 check passed
@fengstats fengstats changed the title fix: user avatar placeholder using transparent GIF fix: optimize user avatar loading or error display May 29, 2024
@orangelckc orangelckc deleted the kc/fix-avatar branch May 29, 2024 22:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants