spacedrive icon indicating copy to clipboard operation
spacedrive copied to clipboard

Tags: no explicit way to update a tag color/name

Open zaaakher opened this issue 9 months ago • 5 comments

Describe the bug

When I try to update the tag color/name there's no "save" button to save the changes I just made to the tag,

spacedrive-save-tags-issue

Reproduction

  1. Go to settings
  2. Go to a library's tags
  3. select an existing tag
  4. change the color / name
  5. try to save the changes you just made

Expected behavior

There should be a button in interface/app/$libraryId/settings/library/tags/EditForm.tsx next to the delete button that executes the updateTag.mutate() when onClick is triggered in that button.

Platform and versions

Windows 10 Pro (19045.4291) - Spacedrive for Windows v0.2.13 93844bad

Stack trace

No response

Additional context

No response

zaaakher avatar Apr 29 '24 18:04 zaaakher

The only way I was able to update a tag name/color is by creating a new tag which I think triggers the useDebounceFormWatch hook

zaaakher avatar Apr 29 '24 18:04 zaaakher

They are updated live (unless that's not working?), maybe we should show a toast to indicate that

utkubakir avatar Apr 29 '24 20:04 utkubakir

Unfortunately they're not updated live. If I change a color/name of a tag and then switch to another tag then the first tag I just updated doesn't retain the changes I made to it.

zaaakher avatar Apr 29 '24 20:04 zaaakher

Can confirm. They are being updated in the background but neither the sidebar or the setting page shows the update.

Should be fixed on the next release, thanks for letting us know :)

utkubakir avatar Apr 29 '24 20:04 utkubakir

Oh I didn't notice the sidebar part. I can confirm that the tag updates when I click on the tag in the sidebar. So in general it seems I have to do some action to trigger a UI update (like clicking on the tag from the sidebar or creating a new tag).

It could be an opinionated suggestion but I think an explicit "Save" or "Update" button to save the changes made would actually feel more intuitive and might even be easier to implement.

Nevertheless, here's a goofy little video I just recorded to show the issue discussed in this issue.

zaaakher avatar Apr 29 '24 21:04 zaaakher

I just tested it now and it seems to be working fine, the color changes when I select it and the text changes when I unfocus from the input element or click the enter key.

zaaakher avatar May 03 '24 18:05 zaaakher

For future reference, this is probably related to million.js somehow, code worked before for a long time and magically started working again so...

utkubakir avatar May 03 '24 21:05 utkubakir