Closed ProtocolPav closed 3 weeks ago
As per https://github.com/ProtocolPav/everthorn.net/commit/ec6bbfe52aa97f450dfcff22bf2f8881f5607cd7, performance is mostly good. Known bug for search stopped working.
The way search on Combobox works is that the CommandItem component renders itself when the condition in find is met. Why is this an issue? We have 1200+ items rendered out running the same check at the same time. That is of time complexity O^2 if every item searches linearly.
Rewrite to render CommandItem components as the field.value fuzzily matches the item. Not render them all at first. This must be an outside check/function that will return the items to render out
Something I saw that others have done and I will link this here is called virtualization. Essentially loads items as they are needed (in the scroll area)
The issue with this is it breaks searching. But the thing I linked here I haven't actually checked so maybe it works. Idk lmk
And that's exactly what I did on that pushed commit
Hence why I'm suggesting a fix for the whole new issue created by the fix for the previous issue
I've looked through the code and I believe this component has virtualization and searching built in. Just gotta test it
Yeah, looks like it. I'll be signing off for the night though. Will resume work soon.
Same here. Tomorrow I will continue work on the form and the latest API changes to be made
I started working on this today, but my time got cut short by some distractions and then I completely forgot 😂
The component here supports virtualisation and search. Will implement tonight.
Search is improved and working as intended, only caveat is the scrollbar but ScrollArea brings back all the performance issues. Will close this.
Improve the search of the
comboboxes
in the Quest Creator. Either via binary search or something else. Most likely some sort of library :))