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

Combined: Fix column widths in grid-layout #3232

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion themes/bootprint3/css/compiled.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion themes/bootstrap3/css/compiled.css

Large diffs are not rendered by default.

4 changes: 4 additions & 0 deletions themes/bootstrap3/less/components/search.less
Original file line number Diff line number Diff line change
Expand Up @@ -427,6 +427,10 @@ body.rtl {
.combined-search-container.grid {
margin-left: 1rem;
margin-right: 1rem;

.combined-list {
overflow-wrap: anywhere;
Copy link
Member Author

Choose a reason for hiding this comment

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

I also agree that the overflow scrollbar is not good. I'd prefer hidden but there's more we can do, I think. Since this happens when long words come into play, we can allow for more breaks in words:

.combined-list {
    word-break: break-word;
    hyphens: auto;
}

We can also do what we do locally at Villanova and make the container on the combined screen full width.

@crhallberg Yes this is so much better than a scrollbar, thanks for the idea. MDN said word-break: break-word is deprecated so I used its suggested replacement. Overflow-wrap: break-word didn't work either but :anywhere did. The hyphens rule didn't affect it, but actually given that what is wrapping (mostly) are URLs, I'm happier not hyphenating them as I think that confuses things further.

Copy link
Contributor

Choose a reason for hiding this comment

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

Oh! I hadn't realized that! Thank you for the heads up!

}
}

.combined-jump-links {
Expand Down
4 changes: 4 additions & 0 deletions themes/bootstrap3/scss/components/search.scss
Original file line number Diff line number Diff line change
Expand Up @@ -427,6 +427,10 @@ body.rtl {
.combined-search-container.grid {
margin-left: 1rem;
margin-right: 1rem;

.combined-list {
overflow-wrap: anywhere;
}
}

.combined-jump-links {
Expand Down
2 changes: 1 addition & 1 deletion themes/bootstrap3/templates/combined/stack-grid.phtml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<div class="combined-search-container grid"
style="grid-template-columns: repeat(<?=$this->escapeHtmlAttr($columns)?>, 1fr)"
style="grid-template-columns: repeat(<?=$this->escapeHtmlAttr($columns)?>, minmax(0, 1fr))"
>
<?php $columnIndex = 0; ?>
<?php foreach ($this->combinedResults as $searchClassId => $currentSearch): ?>
Expand Down
2 changes: 1 addition & 1 deletion themes/local_theme_example/css/compiled.css

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion themes/sandal/css/compiled.css

Large diffs are not rendered by default.