wekan/client/components/main/header.jade
Lauri Ojansivu 34d8235551 Add the following new Sandstorm features and fixes:
- All Boards page [so it's possible to go back from subtask board](https://github.com/wekan/wekan/issues/2082)
- Board favorites
- New Sandstorm board first user is Admin and [has IFTTT Rules](https://github.com/wekan/wekan/issues/2125)
  and Standalone Wekan Admin Panel. Probably some Admin Panel features do not work yet. Please keep backup of your grains before testig Admin Panel.
- Linked Cards and Linked Boards.
- Some not needed options like Logout etc have been hidden from top bar right menu.
- [Import board now works. "Board not found" is not problem anymore](https://github.com/wekan/wekan/issues/1430), because you can go to All Boards page to change to imported board.

and removes the following features:

- Remove Welcome Board from Standalone Wekan, [to fix Welcome board not translated](https://github.com/wekan/wekan/issues/1601).
  Sandstorm Wekan does not have Welcome Board.

Thanks to xet7 !

Closes #2125,
closes #2082,
closes #1430,
closes #1601,
related #2205,
related #2070,
related #1695,
related #1192.
2019-02-27 16:14:14 +02:00

74 lines
2.3 KiB
Text

template(name="header")
//-
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.
if currentUser
#header-quick-access(class=currentBoard.colorClass)
if isMiniScreen
ul
li
a(href="{{pathFor 'home'}}")
span.fa.fa-home
if currentList
each currentBoard.lists
li(class="{{#if $.Session.equals 'currentList' _id}}current{{/if}}")
a.js-select-list
= title
#header-new-board-icon
else
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")
+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.
If the user is not connected we display "sign in" and "log in" buttons.
#header-main-bar(class="{{#if wrappedHeader}}wrapper{{/if}}")
+Template.dynamic(template=headerBar)
unless hideLogo
//-
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.
unless currentSetting.hideLogo
a.wekan-logo(href="{{pathFor 'home'}}" title="{{_ 'header-logo-title'}}")
img(src="{{pathFor '/wekan-logo-header.png'}}" alt="Wekan")
if appIsOffline
+offlineWarning
if currentUser.isBoardMember
if hasAnnouncement
.announcement
p
i.fa.fa-bullhorn
+viewer
| #{announcement}
i.fa.fa-times-circle.js-close-announcement
template(name="offlineWarning")
.offline-warning
p
i.fa.fa-warning
| {{_ 'app-is-offline'}}