nickslick03 / messiah-meal-planner

1 stars 0 forks source link

Updated sort and search #37

Closed nickslick03 closed 3 months ago

nickslick03 commented 3 months ago

Here's the rundown:

One thing I noticed is that when I search, the table cells change their width. I'm sure there's a way to make it so they retain their width (display: flex; && flex: 1; perhaps), but I am too tired. Just thought this might be a point to bring up in the UI.

Another UI issue is that I don't think the search bar and checkbox look aesthetically pleasing right now so if you have any styling ideas I'm all ears.

nickslick03 commented 3 months ago

I'm also thinking maybe the search bar only needs to appear on the available meals table?

cdrice26 commented 3 months ago

Alright, I've looked at the code and overall it looks great! I did modify the styling, let me know what you think. Basically I did the following:

I did not directly address the issue of columns changing widths, and while you're right that we could apply flex:1 to them or something like that, I'm not sure we should because that would make them all the same width, which we don't really want as the name needs more space than the other columns. We'd need to apply static widths that best fit the columns and that could get messy, so personally I'm not sure if this is a big enough problem to merit dealing with it or not, let me know what you think.

As to the search bar only being necessary on AvailableMeals, I would agree. I've added a searchable prop to the MealTable and MealContainer that shows or hides the search bar and set it to false on the MealQueue and DayEditor.

nickslick03 commented 3 months ago

Firstly, the new search bar and custom filtering look BOUGIEE. Also, the "implicit" header to sort from is a UI design I've noticed in other sorting tables, I can see why this design would cause confusion. I removed any reminiscence of it.