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

fix: clean up table styling #1726

Merged
merged 3 commits into from
Feb 15, 2017
Merged

fix: clean up table styling #1726

merged 3 commits into from
Feb 15, 2017

Conversation

patrickhulce
Copy link
Collaborator

R: @paulirish all

Before
image

After
image

@@ -111,6 +111,20 @@ class ReportGenerator {
}
});

Handlebars.registerHelper('kebabCase', function(str) {
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

would love to rebase against #1660 and add tests here

{{/each}}
</tr>
</thead>
<tbody>
{{#each rows}}
<tr>
{{#each cols}}
<td>{{ sanitize this}}</td>
<td class="table-column table-column-{{ kebabCase (lookup ../../headingKeys @index) }}">{{ sanitize this}}</td>
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

don't like this, but not sure it's worth restructuring the format of rows just for class names here

Copy link
Contributor

@ebidel ebidel Feb 15, 2017

Choose a reason for hiding this comment

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

Nice. It's useful to be able to target these. It's hard that we have a generic table, but specific data that might need to look different here/there.

}
.table_list .table-column.table-column-url {
text-align: left;
width: 250px;
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

could add more here, but on smaller screen sizes the optimized images table starts getting pretty squished, min-width doesn't seem to have an impact on fixed table width

@ebidel
Copy link
Contributor

ebidel commented Feb 15, 2017

This LGTM. One thing I notice is the text-align: right makes the code snippets funky:

screen shot 2017-02-15 at 9 46 08 am

vs before:

screen shot 2017-02-15 at 9 46 12 am

@patrickhulce
Copy link
Collaborator Author

oh thanks good catch @ebidel, fixed

@ebidel
Copy link
Contributor

ebidel commented Feb 15, 2017

LGTM

@paulirish paulirish merged commit a026483 into master Feb 15, 2017
@paulirish paulirish deleted the table_css_cleanup branch February 15, 2017 19:38
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.

None yet

3 participants