nodebb-theme-harmony 2.0.0-pre.36 → 2.0.0-pre.38

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "nodebb-theme-harmony",
3
- "version": "2.0.0-pre.36",
3
+ "version": "2.0.0-pre.38",
4
4
  "nbbpm": {
5
5
  "compatibility": "^3.7.0"
6
6
  },
package/public/harmony.js CHANGED
@@ -72,7 +72,7 @@ $(document).ready(function () {
72
72
  return !!$('[component="bottombar"] [component="sidebar/search"] .search-dropdown.show').length;
73
73
  }
74
74
 
75
- let lastScrollTop = 0;
75
+ let lastScrollTop = $window.scrollTop();
76
76
  let newPostsLoaded = false;
77
77
 
78
78
  function onWindowScroll() {
@@ -86,7 +86,7 @@ $(document).ready(function () {
86
86
  const diff = Math.abs(st - lastScrollTop);
87
87
  const scrolledDown = st > lastScrollTop;
88
88
  const scrolledUp = st < lastScrollTop;
89
- if (diff > 5) {
89
+ if (diff > 10) {
90
90
  bottomBar.css({
91
91
  bottom: !scrolledUp && scrolledDown ?
92
92
  -bottomBar.find('.bottombar-nav').outerHeight(true) :
@@ -115,8 +115,10 @@ $(document).ready(function () {
115
115
  });
116
116
  hooks.on('action:ajaxify.end', function () {
117
117
  $window.off('scroll', delayedScroll);
118
- bottomBar.css({ bottom: 0 });
119
- setTimeout(enableAutohide, 250);
118
+ if (config.theme.autohideBottombar) {
119
+ bottomBar.css({ bottom: 0 });
120
+ setTimeout(enableAutohide, 250);
121
+ }
120
122
  });
121
123
  });
122
124
  }
@@ -7,22 +7,22 @@
7
7
  <!-- disables autocomplete on FF --><input type="password" style="display:none">
8
8
 
9
9
  {{{ if isSelf }}}
10
- <div class="mb-2">
11
- <label class="form-label fw-semibold text-xm" for="inputCurrentPassword">[[user:current-password]]</label>
10
+ <div class="mb-3">
11
+ <label class="form-label fw-semibold text-sm" for="inputCurrentPassword">[[user:current-password]]</label>
12
12
  <input autocomplete="off" class="form-control" type="password" id="inputCurrentPassword" placeholder="[[user:current-password]]" value="" {{{ if !hasPassword }}} disabled{{{ end }}}>
13
13
  </div>
14
14
  {{{ end }}}
15
15
 
16
- <div class="mb-2">
17
- <label class="form-label fw-semibold text-xm" for="inputNewPassword">[[user:new-password]]</label>
16
+ <div class="mb-3">
17
+ <label class="form-label fw-semibold text-sm" for="inputNewPassword">[[user:new-password]]</label>
18
18
  <input class="form-control" type="password" id="inputNewPassword" placeholder="[[user:password]]" value="">
19
- <span class="form-feedback" id="password-notify"></span>
19
+ <span class="form-text" id="password-notify"></span>
20
20
  </div>
21
21
 
22
- <div class="mb-2">
23
- <label class="form-label fw-semibold text-xm" for="inputNewPasswordAgain">[[user:confirm-password]]</label>
22
+ <div class="mb-3">
23
+ <label class="form-label fw-semibold text-sm" for="inputNewPasswordAgain">[[user:confirm-password]]</label>
24
24
  <input class="form-control" type="password" id="inputNewPasswordAgain" placeholder="[[user:confirm-password]]" value="">
25
- <span class="form-feedback" id="password-confirm-notify"></span>
25
+ <span class="form-text" id="password-confirm-notify"></span>
26
26
  </div>
27
27
 
28
28
  <div class="form-actions">
@@ -4,7 +4,7 @@
4
4
  <div class="row">
5
5
  <div class="col-12 col-lg-4">
6
6
  <form class="edit-form">
7
- <div class="mb-2">
7
+ <div class="mb-3">
8
8
  <label class="form-label fw-semibold text-sm" for="inputNewUsername">[[user:username]]</label>
9
9
  <input class="form-control" type="text" id="inputNewUsername" placeholder="[[user:username]]" value="{username}">
10
10
  </div>
@@ -12,7 +12,7 @@
12
12
  <!-- disables autocomplete on FF --><input type="password" style="display:none">
13
13
 
14
14
  {{{ if isSelf }}}
15
- <div class="mb-2">
15
+ <div class="mb-3">
16
16
  <label class="form-label fw-semibold text-sm" for="inputCurrentPassword">[[user:current-password]]</label>
17
17
  <input autocomplete="off" class="form-control" type="password" id="inputCurrentPassword" placeholder="[[user:current-password]]" value=""{{{ if !hasPassword }}} disabled{{{ end }}}>
18
18
  </div>
@@ -20,7 +20,6 @@
20
20
 
21
21
  <input type="hidden" name="uid" id="inputUID" value="{uid}" />
22
22
 
23
- <br/>
24
23
  <div class="form-actions">
25
24
  <button id="submitBtn" class="btn btn-primary btn-block"><i class="hide fa fa-spinner fa-spin"></i> [[user:change-username]]</button>
26
25
  </div>
@@ -0,0 +1 @@
1
+ <!-- IMPORT account/topics.tpl -->
@@ -25,6 +25,7 @@
25
25
  <a href="{config.relative_path}/user/{userslug}/topics" class="btn btn-ghost btn-sm ff-secondary fw-semibold {{{ if template.account/topics }}}active{{{ end }}}">[[global:header.recent]]</a>
26
26
  <a href="{config.relative_path}/user/{userslug}/watched"class="btn btn-ghost btn-sm ff-secondary fw-semibold {{{ if template.account/watched }}}active{{{ end }}}">[[user:watched]]</a>
27
27
  <a href="{config.relative_path}/user/{userslug}/ignored" class="btn btn-ghost btn-sm ff-secondary fw-semibold {{{ if template.account/ignored }}}active{{{ end }}}">[[user:ignored]]</a>
28
+ <a href="{config.relative_path}/user/{userslug}/read" class="btn btn-ghost btn-sm ff-secondary fw-semibold {{{ if template.account/read }}}active{{{ end }}}">[[user:read]]</a>
28
29
  {{{ end }}}
29
30
  </div>
30
31
  </div>
@@ -16,12 +16,12 @@
16
16
  {{{ end }}}
17
17
  {{{ if !config.hideSubCategories }}}
18
18
  {{{ if ./children.length }}}
19
- <div class="category-children row row-cols-2 g-2 my-1 w-100">
19
+ <div class="category-children row row-cols-1 row-cols-md-2 g-2 my-1 w-100">
20
20
  {{{ each ./children }}}
21
21
  {{{ if !./isSection }}}
22
22
  <span class="category-children-item small">
23
23
  <div class="d-flex align-items-center gap-1">
24
- <i class="fa fa-fw fa-caret-right text-primary"></i>
24
+ <i class="fa fa-fw fa-caret-right text-primary align-self-start" style="line-height: var(--bs-body-line-height);"></i>
25
25
  <a href="{{{ if ./link }}}{./link}{{{ else }}}{config.relative_path}/category/{./slug}{{{ end }}}" class="text-reset fw-semibold">{./name}</a>
26
26
  </div>
27
27
  </span>
@@ -1,6 +1,6 @@
1
1
  {{{each tags}}}
2
2
  <a href="{config.relative_path}/tags/{./valueEncoded}" data-tag="{./valueEscaped}" class="btn btn-ghost ff-base d-flex flex-column gap-1 align-items-start justify-content-start text-truncate p-2">
3
3
  <div class="fw-semibold text-nowrap tag-item w-100 text-start text-truncate">{./valueEscaped}</div>
4
- <div class="text-xs text-muted text-nowrap tag-topic-count">[[global:x-topics, {formattedNumber(./score)}]]</div>
4
+ <div class="text-xs text-muted text-nowrap tag-topic-count">[[global:x-topics, {txEscape(formattedNumber(./score))}]]</div>
5
5
  </a>
6
6
  {{{end}}}
@@ -86,13 +86,13 @@
86
86
 
87
87
  <div class="d-flex">
88
88
  {{{ if !hideReplies }}}
89
- <a component="post/reply-count" data-target-component="post/replies/container" href="#" class="d-flex gap-2 align-items-center mt-2 btn-ghost ff-secondary border rounded-1 p-1 text-muted text-decoration-none text-xs {{{ if (!./replies || shouldHideReplyContainer(@value)) }}}hidden{{{ end }}}">
89
+ <a component="post/reply-count" data-target-component="post/replies/container" href="#" class="d-flex gap-2 align-items-center mt-2 btn btn-ghost ff-secondary border rounded-1 p-1 text-muted text-decoration-none text-xs {{{ if (!./replies || shouldHideReplyContainer(@value)) }}}hidden{{{ end }}}">
90
90
  <span component="post/reply-count/avatars" class="d-flex gap-1 {{{ if posts.replies.hasMore }}}hasMore{{{ end }}}">
91
91
  {{{each posts.replies.users}}}
92
92
  <span>{buildAvatar(posts.replies.users, "20px", true, "avatar-tooltip")}</span>
93
93
  {{{end}}}
94
94
  {{{ if posts.replies.hasMore}}}
95
- <span><i class="fa fa-ellipsis"></i></span>
95
+ <span style="height: 20px; line-height: 20px;"><i class="fa fa-ellipsis"></i></span>
96
96
  {{{ end }}}
97
97
  </span>
98
98
 
@@ -112,7 +112,7 @@
112
112
  <a component="post/quote" href="#" class="btn btn-ghost btn-sm {{{ if !privileges.topics:reply }}}hidden{{{ end }}}" title="[[topic:quote]]"><i class="fa fa-fw fa-quote-right text-primary"></i></a>
113
113
 
114
114
  {{{ if ./announces }}}
115
- <a component="post/announce-count" href="#" class="btn btn-ghost btn-sm" title="[[activitypub:announcers]]"><i class="fa fa-share-alt text-primary"></i> {./announces}</a>
115
+ <a component="post/announce-count" href="#" class="btn btn-ghost btn-sm d-flex gap-2 align-items-center" title="[[activitypub:announcers]]"><i class="fa fa-share-alt text-primary"></i> {./announces}</a>
116
116
  {{{ end }}}
117
117
 
118
118
  {{{ if !reputation:disabled }}}