Skip to content

Fix collapsed group order & explicit search returns#187

Open
Rsslone wants to merge 4 commits intoCleanroomMC:cleanroomfrom
Rsslone:CollapsedGroupSort-rebased
Open

Fix collapsed group order & explicit search returns#187
Rsslone wants to merge 4 commits intoCleanroomMC:cleanroomfrom
Rsslone:CollapsedGroupSort-rebased

Conversation

@Rsslone
Copy link
Copy Markdown
Contributor

@Rsslone Rsslone commented Apr 12, 2026

During the cleanup commit some functionality was dropped / broken, this fixes the following.

Fix collapsed groups to have consistent order and previews.
Fix searches to apply to collapsed groups, filtering ingredients within it.
Fix searches that result in a single ingredient, actions apply to that ingredient (view recipe / spawn / ect).
Changes collapsed groups to not be able to be bookmarked, functionality is currently not there to allow this.

If anything here added something back that breaks something I'm not aware of, let me know and I'll try and sort it out. If any of this falls in the "I didn't think that was intended behavior", and maybe an option is warranted, I will implement settings to it, I personally believe this is how it should be.

Rsslone added 2 commits April 11, 2026 22:41
Fixes collapsed groups having out of order entries and inconsistent stack previews.
Fixes collapsed stacks not being filtered in a search.
Fixes single item stacks to act on item instead of expanding.
Removes ability to bookmark collapsed stacks.
Copy link
Copy Markdown
Contributor

@WaitingIdly WaitingIdly left a comment

Choose a reason for hiding this comment

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

this issue wasnt introduced in this PR, but:
make two groups, ie stone + cobblestone and stone + cobblestone + sandstone. expand both groups, observe that stone and cobblestone appear twice. if two groups are expanded, it shouldnt display the ingredient twice.
additionally, the ui of an ingredient being in two different groups is poor - perhaps a tooltip on items in an expanded group saying ie "Part of {x,y,z} group(s)"

Comment on lines +104 to +105
// If the search has filtered this group down to a single item, don't expand —
// let the click fall through so InputHandler treats it as clicking the item directly.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

if theres only one item in the "collapsed" group, i think it should have the visibility of an expanded group

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

I don't think there is any current utility in rendering the group borders on 1 size stacks, so I just went further and dropped the borders entirely.

@Rsslone
Copy link
Copy Markdown
Contributor Author

Rsslone commented Apr 12, 2026

this issue wasnt introduced in this PR, but: make two groups, ie stone + cobblestone and stone + cobblestone + sandstone. expand both groups, observe that stone and cobblestone appear twice. if two groups are expanded, it shouldnt display the ingredient twice. additionally, the ui of an ingredient being in two different groups is poor - perhaps a tooltip on items in an expanded group saying ie "Part of {x,y,z} group(s)"

I think its currently dumb to do, but there is nothing stopping a user from placing the same item in multiple groups. If I was to filter them out if two of the groups that are expanded and only have the item in one of the two groups, it would create confusion because an item would not be displayed were a user might be expecting it to be.

I wanted to think about ways to set group "keys" which would decide the groups placement location, but ultimately didn't do it, I wasn't happy with the idea. I'm open to ideas around multi-memberships.

I do think that on an explicit search where cobblestone exists in two groups, when group size == 1 it should return only one stack, so I will test and fix that if its the case.

Rsslone added 2 commits April 12, 2026 21:03
When a search results in multiple singles size groups, filter out all repeats.
When a collapsed stack resolves to a single item, render it as a single item instead of a group.
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.

2 participants