Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add an filter/search box for the app list page #90

Merged
merged 4 commits into from Jul 14, 2015

Conversation

dfuentes
Copy link
Contributor

This PR fixes mesosphere/marathon#1204 by adding an app search/filter box. I tried to stick to the design mockup that is on that issue's discussion.

Can see a small demo of the functionality here

dfuentes and others added 2 commits July 12, 2015 15:20
Fixes mesosphere/marathon#1204.  I tried to stick to
the design mockups on that page.
@philipnrmn philipnrmn self-assigned this Jul 13, 2015
@philipnrmn
Copy link
Contributor

Hi @dfuentes, thanks for this PR! I've tested it thoroughly and it's working nicely.

I noticed you included the Ionicons set. So far we've got by without using any icons at all, so this is quite a big code change. I thought Glyphicons might be preferable, as the styles are already in courtesy of bootstrap, or maybe we should simply include the two icons as image assets. @aatumanova, may we ask your opinion here?

</Link>
<AppListComponent />
className="btn btn-success"
style={{float: "right"}}>
Copy link
Contributor

Choose a reason for hiding this comment

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

Let's use the bootstrap pull-right class here instead of a style attribute.

@dfuentes
Copy link
Contributor Author

I mainly used those icons based on the comment from @aatumanova here, but would be happy to change them.

<TabPaneComponent id={tabs[0].id}>
<Link
<div className="row">
Copy link
Contributor

Choose a reason for hiding this comment

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

These columns don't collapse nicely on narrow screens - let's remove them. The button is already floated right, and the filter component can be prevented from filling the screen with max-width: 330px or similar.

@philipnrmn
Copy link
Contributor

@dfuentes re the icon set - thanks, I hadn't seen that comment. Ionicons it is.

@mlunoe
Copy link
Contributor

mlunoe commented Jul 13, 2015

@philipnrmn There have actually been a discussion around which icon set to use, and we landed on Ionicons. I think the plan is to add a custom icon set when canvas is introduced to the project, but I think this is a good start.

@mlunoe
Copy link
Contributor

mlunoe commented Jul 13, 2015

Oh, didn't see your comment @philipnrmn

@dfuentes
Copy link
Contributor Author

Updated based on feedback:

  • Using float instead of bootstrap columns
  • Restored 8px padding around the app list controls

"input-group": true,
"filter-box": true,
"filter-box-activated": !!state.activated,
"pull-left": true
Copy link
Contributor

Choose a reason for hiding this comment

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

I don't think the filter input needs to float left - floating the button right ought to be enough.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

That's what I thought as well, however with only the button floated right, they no longer align vertically. This is because bootstrap uses display: table for input groups. Not using input groups would be a larger change (since thats how I implemented the icons inside the input).

I'm not great at css, so other suggestions are definitely welcome.

Copy link
Contributor

Choose a reason for hiding this comment

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

Ah, good point - I made an omission in my feedback. The button should precede the filter input in the markup to prevent it wrapping under.

- remove float: left from filter box
- reorder filter box and nav button so they align correctly
- use max-width instead of width for filter box
@dfuentes
Copy link
Contributor Author

Thanks, reordering did let me just float the button. Made that change as well as the max-width one.

@philipnrmn
Copy link
Contributor

Looks fantastic. I'm happy to merge, assigning to @pierlo-upitup for a final review.

@pierluigi
Copy link
Contributor

Excellent job, @dfuentes – thanks!

pierluigi pushed a commit that referenced this pull request Jul 14, 2015
Add an filter/search box for the app list page
@pierluigi pierluigi merged commit e57cec7 into mesosphere:master Jul 14, 2015
@aatumanova
Copy link

Lovely work @dfuentes!

@aldipower
Copy link
Contributor

Cool!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
6 participants