Skip to content

Commit

Permalink
New feature: hyphenation for survey content on small screens (very lo…
Browse files Browse the repository at this point in the history
…ng words will be break with hyphens on recent navigators, or with word-wrap on old ones)
  • Loading branch information
LouisGac committed May 10, 2016
1 parent 6c2db35 commit 1b1b8c5
Show file tree
Hide file tree
Showing 6 changed files with 59 additions and 9 deletions.
15 changes: 15 additions & 0 deletions templates/default/css/template.css
Original file line number Diff line number Diff line change
Expand Up @@ -918,3 +918,18 @@ label, th {
{
margin-top: 50px;
}

/* text overflows, ellipsis and hyphens */
.navbar-brand {
overflow: hidden;
text-overflow: ellipsis;
}

#outerframeContainer {
word-wrap: break-word;
-webkit-hyphens: auto;
-moz-hyphens: auto;
-ms-hyphens: auto;
-o-hyphens: auto;
hyphens: auto;
}
7 changes: 4 additions & 3 deletions templates/default/views/startpage.pstpl
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,17 @@

<nav class="navbar navbar-default navbar-fixed-top" id="topsurveymenubar">
<div class="container">
<div class="navbar-header">
<div class="navbar-header col-xs-12 col-sm-6 col-lg-8">
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<span class="navbar-brand">{SURVEYNAME}</span>
<span class="navbar-brand col-xs-10 col-sm-12" >{SURVEYNAME}</span>
</div>
<div id="navbar" class="navbar-collapse collapse">

<div id="navbar" class="navbar-collapse collapse col-xs-12">
<ul class="nav navbar-nav">
</ul>
<ul class="nav navbar-nav navbar-right">
Expand Down
15 changes: 15 additions & 0 deletions templates/news_paper/css/template.css
Original file line number Diff line number Diff line change
Expand Up @@ -822,3 +822,18 @@ label, th {
{
margin-top: 50px;
}

/* text overflows, ellipsis and hyphens */
.navbar-brand {
overflow: hidden;
text-overflow: ellipsis;
}

#outerframeContainer {
word-wrap: break-word;
-webkit-hyphens: auto;
-moz-hyphens: auto;
-ms-hyphens: auto;
-o-hyphens: auto;
hyphens: auto;
}
7 changes: 4 additions & 3 deletions templates/news_paper/views/startpage.pstpl
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,17 @@

<nav class="navbar navbar-default navbar-fixed-top" id="topsurveymenubar">
<div class="container">
<div class="navbar-header">
<div class="navbar-header col-xs-12 col-sm-6 col-lg-8">
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand col-xs-8" href="#">{SURVEYNAME}</a>
<span class="navbar-brand col-xs-10 col-sm-12" >{SURVEYNAME}</span>
</div>
<div id="navbar" class="navbar-collapse collapse">

<div id="navbar" class="navbar-collapse collapse col-xs-12">
<ul class="nav navbar-nav">
</ul>
<ul class="nav navbar-nav navbar-right">
Expand Down
17 changes: 17 additions & 0 deletions templates/ubuntu_orange/css/template.css
Original file line number Diff line number Diff line change
Expand Up @@ -817,3 +817,20 @@ label, th {
{
margin-top: 50px;
}



/* text overflows, ellipsis and hyphens */
.navbar-brand {
overflow: hidden;
text-overflow: ellipsis;
}

#outerframeContainer {
word-wrap: break-word;
-webkit-hyphens: auto;
-moz-hyphens: auto;
-ms-hyphens: auto;
-o-hyphens: auto;
hyphens: auto;
}
7 changes: 4 additions & 3 deletions templates/ubuntu_orange/views/startpage.pstpl
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,17 @@

<nav class="navbar navbar-default navbar-fixed-top" id="topsurveymenubar">
<div class="container">
<div class="navbar-header">
<div class="navbar-header col-xs-12 col-sm-6 col-lg-8">
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#navbar" aria-expanded="false" aria-controls="navbar">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand col-xs-8" href="#">{SURVEYNAME}</a>
<span class="navbar-brand col-xs-10 col-sm-12" >{SURVEYNAME}</span>
</div>
<div id="navbar" class="navbar-collapse collapse">

<div id="navbar" class="navbar-collapse collapse col-xs-12">
<ul class="nav navbar-nav">
</ul>
<ul class="nav navbar-nav navbar-right">
Expand Down

0 comments on commit 1b1b8c5

Please sign in to comment.