nodebb-theme-harmony 1.2.12 → 1.2.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/library.js +5 -0
- package/package.json +1 -1
- package/plugin.json +2 -1
- package/scss/common.scss +7 -0
- package/scss/overrides.scss +2 -1
- package/templates/partials/categories/lastpost.tpl +1 -3
- package/templates/partials/header/brand.tpl +2 -2
- package/templates/partials/sidebar/chats.tpl +1 -1
- package/templates/partials/sidebar/drafts.tpl +1 -1
- package/templates/partials/sidebar/notifications.tpl +1 -1
- package/templates/partials/sidebar/search.tpl +1 -1
- package/templates/partials/sidebar/user-menu.tpl +11 -11
- package/templates/partials/topics_list.tpl +2 -3
package/library.js
CHANGED
|
@@ -186,3 +186,8 @@ library.filterMiddlewareRenderHeader = async function (hookData) {
|
|
|
186
186
|
return hookData;
|
|
187
187
|
};
|
|
188
188
|
|
|
189
|
+
library.filterTeasersConfigureStripTags = function (hookData) {
|
|
190
|
+
// teasers have a stretched-link to go to last post, the anchors in them are not clickable
|
|
191
|
+
hookData.tags.push('a');
|
|
192
|
+
return hookData;
|
|
193
|
+
};
|
package/package.json
CHANGED
package/plugin.json
CHANGED
|
@@ -8,7 +8,8 @@
|
|
|
8
8
|
{ "hook": "filter:settings.get", "method": "getAdminSettings"},
|
|
9
9
|
{ "hook": "filter:user.saveSettings", "method": "saveUserSettings" },
|
|
10
10
|
{ "hook": "filter:user.profileMenu", "method": "addProfileItem" },
|
|
11
|
-
{ "hook": "filter:middleware.renderHeader", "method": "filterMiddlewareRenderHeader" }
|
|
11
|
+
{ "hook": "filter:middleware.renderHeader", "method": "filterMiddlewareRenderHeader" },
|
|
12
|
+
{ "hook": "filter:teasers.configureStripTags", "method": "filterTeasersConfigureStripTags"}
|
|
12
13
|
],
|
|
13
14
|
"scripts": [
|
|
14
15
|
"public/harmony.js"
|
package/scss/common.scss
CHANGED
|
@@ -119,4 +119,11 @@ body:not(.page-user) {
|
|
|
119
119
|
max-height: 500px;
|
|
120
120
|
width: auto;
|
|
121
121
|
}
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
[component="chat/message/body"],
|
|
125
|
+
[component="post/content"],
|
|
126
|
+
[component="topic/teaser"] .post-content,
|
|
127
|
+
[component="category/posts"] .post-content {
|
|
128
|
+
a { text-decoration: underline;}
|
|
122
129
|
}
|
package/scss/overrides.scss
CHANGED
|
@@ -33,7 +33,8 @@ $body-bg: $white !default;
|
|
|
33
33
|
$body-tertiary-bg: $gray-200 !default;
|
|
34
34
|
$text-muted: $gray-600 !default;
|
|
35
35
|
$border-color: $gray-200 !default;
|
|
36
|
-
$link-color: shade-color($blue, 20%) !default;
|
|
36
|
+
// $link-color: shade-color($blue, 20%) !default;
|
|
37
|
+
$link-color: #0951be !default;
|
|
37
38
|
|
|
38
39
|
// no caret on dropdown-toggle
|
|
39
40
|
$enable-caret: false;
|
|
@@ -4,9 +4,7 @@
|
|
|
4
4
|
<div component="category/posts" class="ps-2 text-xs d-flex flex-column h-100 gap-1">
|
|
5
5
|
<div class="text-nowrap text-truncate">
|
|
6
6
|
<a class="text-decoration-none" href="{config.relative_path}/user/{./user.userslug}">{buildAvatar(posts.user, "18px", true, "avatar-tooltip")}</a>
|
|
7
|
-
<a class="permalink text-muted" href="{config.relative_path}/topic/{./topic.slug}{{{ if ./index }}}/{./index}{{{ end }}}">
|
|
8
|
-
<span class="timeago text-xs" title="{../timestampISO}"></span>
|
|
9
|
-
</a>
|
|
7
|
+
<a class="permalink text-muted timeago text-xs" href="{config.relative_path}/topic/{./topic.slug}{{{ if ./index }}}/{./index}{{{ end }}}" title="{./timestampISO}" aria-label="[[global:lastpost]]"></a>
|
|
10
8
|
</div>
|
|
11
9
|
<div class="post-content text-xs text-break line-clamp-sm-2 lh-sm position-relative flex-fill">
|
|
12
10
|
<a class="stretched-link" href="{config.relative_path}/topic/{./topic.slug}{{{ if ./index }}}/{./index}{{{ end }}}" aria-label="[[global:lastpost]]"></a>
|
|
@@ -3,8 +3,8 @@
|
|
|
3
3
|
<div class="col-12 d-flex border-bottom pb-3 {{{ if config.theme.centerHeaderElements }}}justify-content-center{{{ end }}}">
|
|
4
4
|
<div component="brand/wrapper" class="d-flex align-items-center gap-3 p-2 rounded-1 align-content-stretch ">
|
|
5
5
|
{{{ if brand:logo }}}
|
|
6
|
-
<a component="brand/anchor" href="{{{ if brand:logo:url }}}{brand:logo:url}{{{ else }}}{relative_path}/{{{ end }}}">
|
|
7
|
-
<img component="brand/logo" alt="{brand:logo:alt}" class="{brand:logo:display}" src="{brand:logo}?{config.cache-buster}" />
|
|
6
|
+
<a component="brand/anchor" href="{{{ if brand:logo:url }}}{brand:logo:url}{{{ else }}}{relative_path}/{{{ end }}}" title="[[global:header.brand-logo]]">
|
|
7
|
+
<img component="brand/logo" alt="{{{ if brand:logo:alt }}}{brand:logo:alt}{{{ else }}}[[global:header.brand-logo]]{{{ end }}}" class="{brand:logo:display}" src="{brand:logo}?{config.cache-buster}" />
|
|
8
8
|
</a>
|
|
9
9
|
{{{ end }}}
|
|
10
10
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<a data-bs-toggle="dropdown" href="#" role="button" class="nav-link d-flex gap-2 justify-content-between align-items-center position-relative" component="chat/dropdown" aria-haspopup="true" aria-expanded="false">
|
|
1
|
+
<a data-bs-toggle="dropdown" href="#" role="button" class="nav-link d-flex gap-2 justify-content-between align-items-center position-relative" component="chat/dropdown" aria-haspopup="true" aria-expanded="false" aria-label="[[global:header.chats]]">
|
|
2
2
|
<span class="d-flex gap-2 align-items-center text-nowrap truncate-open">
|
|
3
3
|
<span class="position-relative">
|
|
4
4
|
<i component="chat/icon" class="fa fa-fw {{{ if unreadCount.chat}}}fa-comment{{{ else }}}fa-comment-o{{{ end }}} unread-count" data-content="{unreadCount.chat}"></i>
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<a data-bs-toggle="dropdown" href="#" role="button" class="nav-link d-flex gap-2 justify-content-between align-items-center position-relative" aria-haspopup="true" aria-expanded="false">
|
|
1
|
+
<a data-bs-toggle="dropdown" href="#" role="button" class="nav-link d-flex gap-2 justify-content-between align-items-center position-relative" aria-haspopup="true" aria-expanded="false" aria-label="[[global:header.drafts]]">
|
|
2
2
|
<span class="d-flex gap-2 align-items-center text-nowrap truncate-open">
|
|
3
3
|
<span class="position-relative">
|
|
4
4
|
<i component="drafts/icon" class="fa fa-fw fa-pen-to-square unread-count"></i>
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<a data-bs-toggle="dropdown" href="#" role="button" class="nav-link d-flex gap-2 justify-content-between align-items-center position-relative" aria-haspopup="true" aria-expanded="false">
|
|
1
|
+
<a data-bs-toggle="dropdown" href="#" role="button" class="nav-link d-flex gap-2 justify-content-between align-items-center position-relative" aria-haspopup="true" aria-expanded="false" aria-label="[[global:header.notifications]]">
|
|
2
2
|
<span class="d-flex gap-2 align-items-center text-nowrap truncate-open">
|
|
3
3
|
<span class="position-relative">
|
|
4
4
|
<i component="notifications/icon" class="fa fa-fw {{{ if unreadCount.notification}}}fa-bell{{{ else }}}fa-bell-o{{{ end }}} unread-count" data-content="{unreadCount.notification}"></i>
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
<a component="search/button" id="search-button" href="#" role="button" class="nav-link d-flex gap-2 align-items-center text-truncate" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
|
1
|
+
<a component="search/button" id="search-button" href="#" role="button" class="nav-link d-flex gap-2 align-items-center text-truncate" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false" aria-label="[[global:search]]">
|
|
2
2
|
<span>
|
|
3
3
|
<i class="fa fa-search fa-fw"></i>
|
|
4
4
|
</span>
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
<a component="header/avatar" id="user_dropdown" href="#" role="button" class="nav-link d-flex gap-2 align-items-center text-truncate" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
|
|
1
|
+
<a component="header/avatar" id="user_dropdown" href="#" role="button" class="nav-link d-flex gap-2 align-items-center text-truncate" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false" aria-label="[[user:user-menu]]">
|
|
2
2
|
{buildAvatar(user, "20px", true)}
|
|
3
3
|
<span id="user-header-name" class="nav-text small visible-open fw-semibold">{user.username}</span>
|
|
4
4
|
</a>
|
|
5
|
-
<ul id="user-control-list" component="header/usercontrol" class="overscroll-behavior-contain user-dropdown dropdown-menu shadow p-1 text-sm ff-base"
|
|
5
|
+
<ul id="user-control-list" component="header/usercontrol" class="overscroll-behavior-contain user-dropdown dropdown-menu shadow p-1 text-sm ff-base" role="menu">
|
|
6
6
|
<li>
|
|
7
|
-
<a class="dropdown-item rounded-1 d-flex align-items-center gap-2" component="header/profilelink" href="{relative_path}/user/{user.userslug}" role="menuitem">
|
|
7
|
+
<a class="dropdown-item rounded-1 d-flex align-items-center gap-2" component="header/profilelink" href="{relative_path}/user/{user.userslug}" role="menuitem" aria-label="[[user:profile]]">
|
|
8
8
|
<span component="user/status" class="flex-shrink-0 border border-white border-2 rounded-circle status {user.status}"><span class="visually-hidden">[[global:{user.status}]]</span></span>
|
|
9
9
|
<span class="fw-semibold" component="header/username">{user.username}</span>
|
|
10
10
|
</a>
|
|
@@ -13,28 +13,28 @@
|
|
|
13
13
|
<li><h6 class="dropdown-header text-xs">[[global:status]]</h6></li>
|
|
14
14
|
<li>
|
|
15
15
|
<a href="#" class="dropdown-item rounded-1 user-status d-flex align-items-center gap-2 {{{ if user.online }}}selected{{{ end }}}" data-status="online" role="menuitem">
|
|
16
|
-
<span component="user/status" class="flex-shrink-0 border border-white border-2 rounded-circle status online"
|
|
16
|
+
<span component="user/status" class="flex-shrink-0 border border-white border-2 rounded-circle status online"></span>
|
|
17
17
|
<span class="flex-grow-1">[[global:online]]</span>
|
|
18
|
-
<i class="fa-solid fa-check text-muted flex-shrink-0"></i>
|
|
18
|
+
<i class="fa-solid fa-check text-muted flex-shrink-0" aria-label="[[global:selected]]"></i>
|
|
19
19
|
</a>
|
|
20
20
|
</li>
|
|
21
21
|
<li>
|
|
22
22
|
<a href="#" class="dropdown-item rounded-1 user-status d-flex align-items-center gap-2 {{{ if user.away }}}selected{{{ end }}}" data-status="away" role="menuitem">
|
|
23
|
-
<span component="user/status" class="flex-shrink-0 border border-white border-2 rounded-circle status away"
|
|
23
|
+
<span component="user/status" class="flex-shrink-0 border border-white border-2 rounded-circle status away"></span>
|
|
24
24
|
<span class="flex-grow-1">[[global:away]]</span>
|
|
25
|
-
<i class="fa-solid fa-check text-muted flex-shrink-0"></i>
|
|
25
|
+
<i class="fa-solid fa-check text-muted flex-shrink-0"><span class="visually-hidden"></span>[[global:selected]]</span></i>
|
|
26
26
|
</a>
|
|
27
27
|
</li>
|
|
28
28
|
<li>
|
|
29
29
|
<a href="#" class="dropdown-item rounded-1 user-status d-flex align-items-center gap-2 {{{ if user.dnd }}}selected{{{ end }}}" data-status="dnd" role="menuitem">
|
|
30
|
-
<span component="user/status" class="flex-shrink-0 border border-white border-2 rounded-circle status dnd"
|
|
30
|
+
<span component="user/status" class="flex-shrink-0 border border-white border-2 rounded-circle status dnd"></span>
|
|
31
31
|
<span class="flex-grow-1">[[global:dnd]]</span>
|
|
32
32
|
<i class="fa-solid fa-check text-muted flex-shrink-0"></i>
|
|
33
33
|
</a>
|
|
34
34
|
</li>
|
|
35
35
|
<li>
|
|
36
36
|
<a href="#" class="dropdown-item rounded-1 user-status d-flex align-items-center gap-2 {{{ if user.offline }}}selected{{{ end }}}" data-status="offline" role="menuitem">
|
|
37
|
-
<span component="user/status" class="flex-shrink-0 border border-white border-2 rounded-circle status offline"
|
|
37
|
+
<span component="user/status" class="flex-shrink-0 border border-white border-2 rounded-circle status offline"></span>
|
|
38
38
|
<span class="flex-grow-1">[[global:invisible]]</span>
|
|
39
39
|
<i class="fa-solid fa-check text-muted flex-shrink-0"></i>
|
|
40
40
|
</a>
|
|
@@ -92,10 +92,10 @@
|
|
|
92
92
|
|
|
93
93
|
<li role="presentation" class="dropdown-divider"></li>
|
|
94
94
|
<li component="user/logout">
|
|
95
|
-
<form method="post" action="{relative_path}/logout">
|
|
95
|
+
<form method="post" action="{relative_path}/logout" role="menuitem">
|
|
96
96
|
<input type="hidden" name="_csrf" value="{config.csrf_token}">
|
|
97
97
|
<input type="hidden" name="noscript" value="true">
|
|
98
|
-
<button type="submit" class="dropdown-item rounded-1 d-flex align-items-center gap-2"
|
|
98
|
+
<button type="submit" class="dropdown-item rounded-1 d-flex align-items-center gap-2">
|
|
99
99
|
<i class="fa fa-fw fa-sign-out text-muted"></i><span>[[global:logout]]</span>
|
|
100
100
|
</button>
|
|
101
101
|
</form>
|
|
@@ -111,11 +111,10 @@
|
|
|
111
111
|
{{{ if ./teaser.pid }}}
|
|
112
112
|
<div class="ps-2">
|
|
113
113
|
<a href="{config.relative_path}/user/{./teaser.user.userslug}" class="text-decoration-none">{buildAvatar(./teaser.user, "18px", true, "avatar-tooltip not-responsive")}</a>
|
|
114
|
-
<a class="permalink text-muted timeago text-xs" href="{config.relative_path}/topic/{./slug}/{./teaser.index}" title="{./teaser.timestampISO}">
|
|
115
|
-
</a>
|
|
114
|
+
<a class="permalink text-muted timeago text-xs" href="{config.relative_path}/topic/{./slug}/{./teaser.index}" title="{./teaser.timestampISO}" aria-label="[[global:lastpost]]"></a>
|
|
116
115
|
</div>
|
|
117
116
|
<div class="post-content text-xs ps-2 line-clamp-sm-2 lh-sm text-break position-relative flex-fill">
|
|
118
|
-
<a class="stretched-link" href="{config.relative_path}/topic/{./slug}/{./teaser.index}"></a>
|
|
117
|
+
<a class="stretched-link" href="{config.relative_path}/topic/{./slug}/{./teaser.index}" aria-label="[[global:lastpost]]"></a>
|
|
119
118
|
{./teaser.content}
|
|
120
119
|
</div>
|
|
121
120
|
{{{ end }}}
|