Skip to content

[WebProfilerBundle] Filter links in search results #16344

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

Merged
merged 1 commit into from
Oct 28, 2015

Conversation

rvanlaak
Copy link
Contributor

Q A
Bug fix? no
New feature? yes
BC breaks? no
Deprecations? no
Tests pass? yes
Fixed tickets #14110
License MIT
Doc PR

Quite often I find myself copy/pasting the results from the search results in the profiler search form. Adding links for this allows developers to narrow down to the proper profiler result fast.

<td>
<span class="nowrap">{{ result.ip }}</span>
{% if request.session is not null %}
<a href="{{ path('_profiler_search_results', request.query.all|merge({'ip': result.ip, 'token': result.token})) }}" title="Search">
Copy link
Member

Choose a reason for hiding this comment

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

The title attributes of the new links could be customized. Instead of Search we could use any of these alternatives:

Search by IP
Filter profiles by IP
View other profiles with this IP
Show only profiles for this IP
...

Same comment for the other links.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

👍 which one do you propose? Currently we don't use "filter" anywhere, so I sticked with "search".

@javiereguiluz
Copy link
Member

My only concern is how we display the "search icon":

profiler_results_before

A quick test removing the float: right and just adding a margin-left: 2px would look like this:

profiler_results_after

@rvanlaak
Copy link
Contributor Author

@javiereguiluz like you also mentioned in #14110 (comment) ? Think someone just has to make a choice about this, the current implementation seemed to fit your concern quite well back then.

@javiereguiluz
Copy link
Member

@rvanlaak the most recent comment is only about the location of the icons.

@fabpot
Copy link
Member

fabpot commented Oct 28, 2015

I find the @rvanlaak better. With your proposal @javiereguiluz, you might not see the icon as it is near the text.

@rvanlaak
Copy link
Contributor Author

Let me know if I still need to change anything.

@wouterj
Copy link
Member

wouterj commented Oct 28, 2015

Hmm, I agree with @javiereguiluz on the location of the search icon.

As we use a borderless table, you would expect everything that belongs to one cell to be somewhat close to eachother. With the float:right;, it's unclear whether the search icon belongs to the information on the left or the right of the icon. As it's closer to the right, I would expect it belongs to the information on the right, but it appears to belong to the info on the left.

@rvanlaak
Copy link
Contributor Author

I would agree with @wouterj in the case "As we use a borderless table". But the profiler doesn't, right?

@wouterj
Copy link
Member

wouterj commented Oct 28, 2015

I didn't check this PR out locally, so I gave feedback based on @javiereguiluz's screenshot and it appears to be borderless in those screenshots. If it isn't, I agree that floating right is nicer.

@javiereguiluz
Copy link
Member

@wouterj this is how both proposals look on my computer (I've forced all icons to be displayed to get the whole picture):

@rvanlaak's proposal:

proposal1

My proposal:

proposal2

@rvanlaak
Copy link
Contributor Author

Oh, I did remember to have vertical lines while developing it as well but that probably still was the 2.7 branch. Removing the float in this case seems like the best solution. Your latest comment doesn't include the hover @javiereguiluz , you mean your proposal as in #16344 (comment) ?

So two options:

  1. Remove the float from the icon
  2. Let the vertical table borders return, and keep the right float so it is a bit more clear if near text (as @fabpot mentions)

@javiereguiluz
Copy link
Member

@rvanlaak in the new profiler design, columns don't have vertical borders (only rows have horizontal borders). I'd prefer not to change this design feature (it would take us a lot of time to tweak everything and other projects are already using this design. Example: opensoftwareconsulting/deprecation-detector#58 (comment)).

@rvanlaak
Copy link
Contributor Author

I'm fine with any of the options, but I don't think I should make the decision about it. 👍 So shall we get rid of the float?

@fabpot
Copy link
Member

fabpot commented Oct 28, 2015

I now agree with @javiereguiluz reasoning, let's do that.

@rvanlaak
Copy link
Contributor Author

Fixed 👍

@fabpot
Copy link
Member

fabpot commented Oct 28, 2015

Thank you @rvanlaak.

@fabpot fabpot merged commit 4bffacc into symfony:2.8 Oct 28, 2015
fabpot added a commit that referenced this pull request Oct 28, 2015
…anlaak)

This PR was merged into the 2.8 branch.

Discussion
----------

[WebProfilerBundle] Filter links in search results

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | #14110
| License       | MIT
| Doc PR        |

Quite often I find myself copy/pasting the results from the search results in the profiler search form. Adding links for this allows developers to narrow down to the proper profiler result fast.

Commits
-------

4bffacc [WebProfilerBundle] Filter links in search results
@rvanlaak rvanlaak deleted the 2.8-profiler branch October 28, 2015 17:14
@fabpot fabpot mentioned this pull request Nov 16, 2015
ostrolucky pushed a commit to ostrolucky/symfony that referenced this pull request Mar 25, 2018
…lts (Rvanlaak)

This PR was merged into the 2.8 branch.

Discussion
----------

[WebProfilerBundle] Filter links in search results

| Q             | A
| ------------- | ---
| Bug fix?      | no
| New feature?  | yes
| BC breaks?    | no
| Deprecations? | no
| Tests pass?   | yes
| Fixed tickets | symfony#14110
| License       | MIT
| Doc PR        |

Quite often I find myself copy/pasting the results from the search results in the profiler search form. Adding links for this allows developers to narrow down to the proper profiler result fast.

Commits
-------

4bffacc [WebProfilerBundle] Filter links in search results
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants