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: disabled autogenerate field icon when empty system role #2076

Merged
merged 7 commits into from May 4, 2024

Conversation

techcontributor
Copy link
Contributor

@techcontributor techcontributor commented Apr 17, 2024

💻 变更类型 | Change Type

  • ✨ feat
  • 🐛 fix
  • ♻️ refactor
  • 💄 style
  • 🔨 chore
  • ⚡️ perf
  • 📝 docs

🔀 变更说明 | Description of Change

📝 补充信息 | Additional Information

Disabled the auto generate icon when system role is empty

fixes #2052

Copy link

vercel bot commented Apr 17, 2024

Someone is attempting to deploy a commit to the LobeHub Team on Vercel.

A member of the Team first needs to authorize it.

@lobehubbot
Copy link
Member

👍 @techcontributor

Thank you for raising your pull request and contributing to our Community
Please make sure you have followed our contributing guidelines. We will review it as soon as possible.
If you encounter any problems, please feel free to connect with us.
非常感谢您提出拉取请求并为我们的社区做出贡献,请确保您已经遵循了我们的贡献指南,我们会尽快审查它。
如果您遇到任何问题,请随时与我们联系。

@sagar-vaghela
Copy link

@gijigae @lobehubbot @phuang07 @chenhunghan

Could you please review this PR?

Copy link

vercel bot commented Apr 25, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
lobe-chat-community ✅ Ready (Inspect) Visit Preview 💬 Add feedback May 3, 2024 11:05am

Copy link

codecov bot commented Apr 25, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 92.86%. Comparing base (88d0e39) to head (56cbc3b).
Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2076   +/-   ##
=======================================
  Coverage   92.86%   92.86%           
=======================================
  Files         295      295           
  Lines       16791    16791           
  Branches     1939     1939           
=======================================
  Hits        15593    15593           
  Misses       1198     1198           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@arvinxx
Copy link
Contributor

arvinxx commented Apr 25, 2024

@techcontributor vercel build failed, please check the code

image

@techcontributor
Copy link
Contributor Author

@techcontributor vercel build failed, please check the code

image

@arvinxx could you please check now? i updated PR

Thanks

@arvinxx arvinxx changed the title fix: disabled autogenerate field icon when empty system role 🐛 fix: disabled autogenerate field icon when empty system role Apr 26, 2024
Copy link
Contributor

Choose a reason for hiding this comment

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

why remove the systemRole condition?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@arvinxx

it was for extra guard check condition but i hope this is not require any more since it is already been disabled in code using canAutoGenerate. (please find attachment)

but if you think this is required then i will put it back.
Screenshot 2024-04-29 at 12 17 43 PM

Copy link
Contributor

@arvinxx arvinxx May 2, 2024

Choose a reason for hiding this comment

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

I think it's required, because we have another place to call these functions like autocompleteMeta. And maybe in the future we will call it automatically when user just set system role in the chat page. so the guard is necessary

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Okay i made update as per feedback please check PR once.

@arvinxx

Copy link
Contributor

@arvinxx arvinxx May 3, 2024

Choose a reason for hiding this comment

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

why update the const preValue = meta.description; line? I think this file don't need to change.

@techcontributor
Copy link
Contributor Author

@arvinxx could you please review this PR?

if all good then could you please proceed ahead? or let me know if any query

@arvinxx
Copy link
Contributor

arvinxx commented May 2, 2024

@techcontributor I have commented.

image

@techcontributor
Copy link
Contributor Author

@techcontributor I have commented.

image

Screenshot 2024-05-02 at 6 16 29 PM

@arvinxx could you please check my comment? i already reply

@arvinxx
Copy link
Contributor

arvinxx commented May 2, 2024

@techcontributor It's pending , so I didn't see it. you need to send it.

image

like this:
image

@techcontributor
Copy link
Contributor Author

techcontributor commented May 2, 2024

@techcontributor It's pending , so I didn't see it. you need to send it.

image like this: image

submitted @arvinxx

Copy link
Contributor

@arvinxx arvinxx left a comment

Choose a reason for hiding this comment

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

I think the change of AgentMeta is LGTM, please revert the change of the action.ts

@techcontributor
Copy link
Contributor Author

action.ts

@arvinxx reverted the changes as per suggestion.

@arvinxx
Copy link
Contributor

arvinxx commented May 3, 2024

@techcontributor OK, I have triggered the vercel deployment. And I'll check the preview and if it works as expected, I'll merge it~ Thanks for your patience and contribution~ 👏

@arvinxx arvinxx merged commit 27095f5 into lobehub:main May 4, 2024
6 checks passed
@lobehubbot
Copy link
Member

❤️ Great PR @techcontributor ❤️

The growth of project is inseparable from user feedback and contribution, thanks for your contribution! If you are interesting with the lobehub developer community, please join our discord and then dm @arvinxx or @canisminor1990. They will invite you to our private developer channel. We are talking about the lobe-chat development or sharing ai newsletter around the world.
项目的成长离不开用户反馈和贡献,感谢您的贡献! 如果您对 LobeHub 开发者社区感兴趣,请加入我们的 discord,然后私信 @arvinxx@canisminor1990。他们会邀请您加入我们的私密开发者频道。我们将会讨论关于 Lobe Chat 的开发,分享和讨论全球范围内的 AI 消息。

github-actions bot pushed a commit that referenced this pull request May 4, 2024
### [Version 0.152.12](v0.152.11...v0.152.12)
<sup>Released on **2024-05-04**</sup>

#### 🐛 Bug Fixes

- **misc**: Disabled autogenerate field icon when empty system role.

<br/>

<details>
<summary><kbd>Improvements and Fixes</kbd></summary>

#### What's fixed

* **misc**: Disabled autogenerate field icon when empty system role, closes [#2076](#2076) ([27095f5](27095f5))

</details>

<div align="right">

[![](https://img.shields.io/badge/-BACK_TO_TOP-151515?style=flat-square)](#readme-top)

</div>
@lobehubbot
Copy link
Member

🎉 This PR is included in version 0.152.12 🎉

The release is available on:

Your semantic-release bot 📦🚀

github-actions bot pushed a commit to bentwnghk/lobe-chat that referenced this pull request May 4, 2024
### [Version&nbsp;1.32.2](v1.32.1...v1.32.2)
<sup>Released on **2024-05-04**</sup>

#### ♻ Code Refactoring

- **misc**: Refactor Setting Layout, user store add an auth slice.

#### 🐛 Bug Fixes

- **misc**: Disabled autogenerate field icon when empty system role, Fix intercepting-routes on mobile, Fix router path in UserPanel, Fix Setings Layout, Fix undefined 'DISCORD', Test CI and Release CI, Test CI and Release CI, Test CI and Release CI, Test CI and Release CI, Test CI and Release CI.

#### 💄 Styles

- **misc**: Add user panel and refactor the next-auth, autoScroll to the fully end, improve market layout styles and mobile style, refactor setting layout and improve setting design.

<br/>

<details>
<summary><kbd>Improvements and Fixes</kbd></summary>

#### Code refactoring

* **misc**: Refactor Setting Layout, closes [lobehub#2336](https://github.com/bentwnghk/lobe-chat/issues/2336) ([282082e](282082e))
* **misc**: User store add an auth slice, closes [lobehub#2214](https://github.com/bentwnghk/lobe-chat/issues/2214) ([948b257](948b257))

#### What's fixed

* **misc**: Disabled autogenerate field icon when empty system role, closes [lobehub#2076](https://github.com/bentwnghk/lobe-chat/issues/2076) ([27095f5](27095f5))
* **misc**: Fix intercepting-routes on mobile ([abe228c](abe228c))
* **misc**: Fix router path in UserPanel ([c779e02](c779e02))
* **misc**: Fix Setings Layout, closes [lobehub#2340](https://github.com/bentwnghk/lobe-chat/issues/2340) ([6a2e9a9](6a2e9a9))
* **misc**: Fix undefined 'DISCORD' ([41c70be](41c70be))
* **misc**: Test CI and Release CI ([a909afe](a909afe))
* **misc**: Test CI and Release CI ([aff22b5](aff22b5))
* **misc**: Test CI and Release CI ([1db3b59](1db3b59))
* **misc**: Test CI and Release CI ([e0c82c8](e0c82c8))
* **misc**: Test CI and Release CI ([97634ca](97634ca))

#### Styles

* **misc**: Add user panel and refactor the next-auth, closes [lobehub#2349](https://github.com/bentwnghk/lobe-chat/issues/2349) ([5cecee0](5cecee0))
* **misc**: AutoScroll to the fully end, closes [lobehub#2345](https://github.com/bentwnghk/lobe-chat/issues/2345) ([5458e98](5458e98))
* **misc**: Improve market layout styles and mobile style, closes [lobehub#2347](https://github.com/bentwnghk/lobe-chat/issues/2347) ([79b8115](79b8115))
* **misc**: Refactor setting layout and improve setting design, closes [lobehub#2344](https://github.com/bentwnghk/lobe-chat/issues/2344) ([fa16721](fa16721))

</details>

<div align="right">

[![](https://img.shields.io/badge/-BACK_TO_TOP-151515?style=flat-square)](#readme-top)

</div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Bug] Input fields are not being auto generated on button click
4 participants