summaryrefslogtreecommitdiffstats
path: root/client/components/main/header.jade
diff options
context:
space:
mode:
authorLiming Xie <liming.xie@gmail.com>2015-12-17 14:23:35 +0800
committerLiming Xie <liming.xie@gmail.com>2015-12-17 14:23:35 +0800
commit354eff9f7bf550f83d55ef2e96b10aab1a70162d (patch)
tree34cba5531d56d4ca51ed5346a5f26e480c4a33c7 /client/components/main/header.jade
parent0954cff5b470712210275a9c0699d85d6579ab54 (diff)
downloadwekan-354eff9f7bf550f83d55ef2e96b10aab1a70162d.tar.gz
wekan-354eff9f7bf550f83d55ef2e96b10aab1a70162d.tar.bz2
wekan-354eff9f7bf550f83d55ef2e96b10aab1a70162d.zip
add: support compact mode for mobile web, auto adapt to small screen/window
Diffstat (limited to 'client/components/main/header.jade')
-rw-r--r--client/components/main/header.jade69
1 files changed, 35 insertions, 34 deletions
diff --git a/client/components/main/header.jade b/client/components/main/header.jade
index 0d178250..ff79617e 100644
--- a/client/components/main/header.jade
+++ b/client/components/main/header.jade
@@ -1,32 +1,32 @@
template(name="header")
- #header(class=currentBoard.colorClass)
- //-
- If the user is connected we display a small "quick-access" top bar that
- list all starred boards with a link to go there. This is inspired by the
- Reddit "subreddit" bar.
- The first link goes to the boards page.
- unless isSandstorm
- if currentUser
- #header-quick-access
- ul
- li
- a(href="{{pathFor 'home'}}")
- span.fa.fa-home
- | {{_ 'all-boards'}}
- each currentUser.starredBoards
- li.separator -
- li(class="{{#if $.Session.equals 'currentBoard' _id}}current{{/if}}")
- a(href="{{pathFor 'board' id=_id slug=slug}}")
- = title
- else
- li.current {{_ 'quick-access-description'}}
+ //-
+ If the user is connected we display a small "quick-access" top bar that
+ list all starred boards with a link to go there. This is inspired by the
+ Reddit "subreddit" bar.
+ The first link goes to the boards page.
+ unless isSandstorm
+ if currentUser
+ #header-quick-access(class=currentBoard.colorClass)
+ ul
+ li
+ a(href="{{pathFor 'home'}}")
+ span.fa.fa-home
+ | {{_ 'all-boards'}}
+ each currentUser.starredBoards
+ li.separator -
+ li(class="{{#if $.Session.equals 'currentBoard' _id}}current{{/if}}")
+ a(href="{{pathFor 'board' id=_id slug=slug}}")
+ = title
+ else
+ li.current {{_ 'quick-access-description'}}
- a#header-new-board-icon.js-create-board
- i.fa.fa-plus(title="Create a new board")
+ a#header-new-board-icon.js-create-board
+ i.fa.fa-plus(title="Create a new board")
- +headerUserBar
+ +headerUserBar
+ #header(class=currentBoard.colorClass)
//-
The main bar is a colorful bar that provide all the meta-data for the
current page. This bar is contextual based.
@@ -34,13 +34,14 @@ template(name="header")
#header-main-bar(class="{{#if wrappedHeader}}wrapper{{/if}}")
+Template.dynamic(template=headerBar)
- //-
- On sandstorm, the logo shouldn't be clickable, because we only have one
- page/document on it, and we don't want to see the home page containing
- the list of all boards.
- if isSandstorm
- .wekan-logo
- img(src="{{pathFor '/wekan-logo-header.png'}}" alt="Wekan")
- else
- a.wekan-logo(href="{{pathFor 'home'}}" title="{{_ 'header-logo-title'}}")
- img(src="{{pathFor '/wekan-logo-header.png'}}" alt="Wekan")
+ if wrappedHeader
+ //-
+ On sandstorm, the logo shouldn't be clickable, because we only have one
+ page/document on it, and we don't want to see the home page containing
+ the list of all boards.
+ if isSandstorm
+ .wekan-logo
+ img(src="{{pathFor '/wekan-logo-header.png'}}" alt="Wekan")
+ else
+ a.wekan-logo(href="{{pathFor 'home'}}" title="{{_ 'header-logo-title'}}")
+ img(src="{{pathFor '/wekan-logo-header.png'}}" alt="Wekan")