lobe-chat
lobe-chat copied to clipboard
đ fix: Bind the selected group name in the rename modal.
đť ĺć´çąťĺ | Change Type
- [ ] ⨠feat
- [x] đ fix
- [ ] âťď¸ refactor
- [ ] đ style
- [ ] đˇ build
- [ ] âĄď¸ perf
- [ ] đ docs
- [ ] đ¨ chore
đ ĺć´čŻ´ć | Description of Change
Bind the selected group name in the rename group modal. The issue was that when there is multiple groups with sessions and you choose to rename a group, previously selected group name appears. Attached video.
đ 襼ĺ äżĄćŻ | Additional Information
- Added useEffect dependent on group and then updated the setInput so that group.name fetched from the store is set in input.
useEffect(() => {
setInput(group?.name);
}, [group]);
Before fix:
https://github.com/user-attachments/assets/402b3d08-62f6-485b-b2b7-e65b2dedfa67
After fix:
https://github.com/user-attachments/assets/a6ee0de4-d91f-4510-9395-2b7a8f88de48