nodebb-theme-persona 14.2.41 → 15.0.0-beta.1

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.
Files changed (46) hide show
  1. package/package.json +2 -2
  2. package/public/persona.js +1 -1
  3. package/scss/modules/usercard.scss +3 -55
  4. package/templates/account/blocks.tpl +1 -1
  5. package/templates/account/edit.tpl +0 -9
  6. package/templates/account/info.tpl +7 -7
  7. package/templates/account/profile.tpl +1 -1
  8. package/templates/account/sessions.tpl +1 -18
  9. package/templates/account/settings.tpl +3 -3
  10. package/templates/category.tpl +2 -2
  11. package/templates/groups/details.tpl +3 -3
  12. package/templates/header.tpl +3 -3
  13. package/templates/modules/usercard.tpl +22 -20
  14. package/templates/notifications.tpl +2 -2
  15. package/templates/partials/account/category-item.tpl +2 -2
  16. package/templates/partials/account/header.tpl +6 -12
  17. package/templates/partials/account/menu.tpl +3 -3
  18. package/templates/partials/account/session-list.tpl +1 -1
  19. package/templates/partials/breadcrumbs.tpl +1 -1
  20. package/templates/partials/buttons/newTopic.tpl +1 -1
  21. package/templates/partials/categories/item.tpl +3 -3
  22. package/templates/partials/categories/lastpost.tpl +2 -2
  23. package/templates/partials/categories/link.tpl +5 -11
  24. package/templates/partials/chats-menu.tpl +1 -1
  25. package/templates/partials/groups/admin.tpl +1 -1
  26. package/templates/partials/groups/invited.tpl +1 -1
  27. package/templates/partials/groups/list.tpl +1 -1
  28. package/templates/partials/groups/memberlist.tpl +1 -1
  29. package/templates/partials/groups/pending.tpl +1 -1
  30. package/templates/partials/header/user-menu.tpl +1 -1
  31. package/templates/partials/menu.tpl +5 -5
  32. package/templates/partials/notifications_list.tpl +2 -2
  33. package/templates/partials/posts_list_item.tpl +2 -2
  34. package/templates/partials/quick-category-search-results.tpl +2 -2
  35. package/templates/partials/quick-search-results.tpl +2 -2
  36. package/templates/partials/search-filters.tpl +2 -2
  37. package/templates/partials/search-results.tpl +3 -3
  38. package/templates/partials/topic/event.tpl +1 -1
  39. package/templates/partials/topic/navigation-post.tpl +2 -2
  40. package/templates/partials/topic/necro-post.tpl +1 -1
  41. package/templates/partials/topic/post.tpl +5 -5
  42. package/templates/partials/topic/quickreply.tpl +1 -1
  43. package/templates/partials/topics_list.tpl +6 -6
  44. package/templates/partials/users/item.tpl +1 -1
  45. package/templates/topic.tpl +2 -10
  46. package/templates/world.tpl +4 -4
package/package.json CHANGED
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "name": "nodebb-theme-persona",
3
- "version": "14.2.41",
3
+ "version": "15.0.0-beta.1",
4
4
  "nbbpm": {
5
- "compatibility": "^4.13.0"
5
+ "compatibility": "^4.14.0"
6
6
  },
7
7
  "description": "Persona theme for NodeBB",
8
8
  "main": "library.js",
package/public/persona.js CHANGED
@@ -186,7 +186,7 @@ $(document).ready(function () {
186
186
  avatar.parents('a').after(card.hide());
187
187
 
188
188
  if (String(app.user.uid) === String(user.uid) || !app.user.uid) {
189
- card.find('.btn-morph').hide();
189
+ card.find('.btn-morph').addClass('invisible');
190
190
  } else {
191
191
  const uid = isFinite(user.uid) ? user.uid : encodeURIComponent(user.userslug);
192
192
  setupFavouriteMorph(card, uid, user.username);
@@ -1,65 +1,13 @@
1
1
  .persona-usercard {
2
2
  position: absolute;
3
- background: #333;
4
3
  top: -50%;
5
4
  left: 0px;
6
5
  box-shadow: 0px 2px 5px 0px rgba(0, 0, 0, 0.25), 0px 2px 10px 0px rgba(0, 0, 0, 0.25);
7
6
  height: 150px;
8
7
  width: 450px;
9
- z-index: 1;
10
- display: block;
8
+ z-index: $zindex-dropdown;
11
9
 
12
- a, a:hover, a:visited, a:active {
13
- text-decoration: none;
14
- color: white;
15
- }
16
-
17
- .usercard-picture {
18
- width: 150px;
19
- height: 150px;
20
- float: left;
21
- background-size: cover;
22
- background-repeat: no-repeat;
23
- font-size: 75px;
24
- line-height: 140px;
25
- text-align: center;
26
- }
27
-
28
- .usercard-body {
29
- padding: 5px 15px;
30
- float: left;
31
-
32
- height: 150px;
33
- width: 300px;
34
- color: white;
35
- }
36
-
37
- .usercard-name {
38
- font-size: 28px;
39
- }
40
-
41
- .usercard-username {
42
- text-transform: uppercase;
43
- font-size: 13px;
44
- }
45
-
46
- .usercard-info {
47
- text-align: center;
48
- font-size: 30px;
49
- font-weight: 300;
50
-
51
- small {
52
- text-transform: uppercase;
53
- font-size: 10px;
54
- display: block;
55
- margin-top: 15px;
56
- font-weight: 400;
57
- }
58
- }
59
-
60
- .persona-fab.btn-morph {
61
- top: 75px;
62
- right: 15px;
63
- position: absolute;
10
+ .avatar {
11
+ margin: 0!important;
64
12
  }
65
13
  }
@@ -16,7 +16,7 @@
16
16
  <li component="blocks/search/match">
17
17
  <div class="dropdown-item rounded-1 d-flex flex-nowrap gap-2 justify-content-between align-items-center" role="menuitem">
18
18
  <div class="text-truncate">
19
- <a href="{config.relative_path}/uid/{../uid}">{buildAvatar(edit, "24px", true)} {../username}</a>
19
+ <a href="{config.relative_path}/uid/{../uid}">{{buildAvatar(edit, "24px", true)}} {../username}</a>
20
20
  </div>
21
21
 
22
22
  <button class="btn btn-sm btn-outline-danger text-nowrap {{{ if ./isBlocked }}}hidden{{{ end }}}" data-uid="{./uid}" data-action="block">[[user:block-user]]</button>
@@ -3,15 +3,6 @@
3
3
  <div class="row">
4
4
  <div class="col-md-3 col-sm-4">
5
5
  <div class="account-picture-block text-center">
6
- <div class="row mb-3">
7
- <div class="col-12 hidden-xs">
8
- <!-- IF picture -->
9
- <img id="user-current-picture" class="avatar avatar-rounded" style="--avatar-size: 128px;" src="{picture}" />
10
- <!-- ELSE -->
11
- <div class="avatar avatar-rounded" style="background-color: {icon:bgColor}; --avatar-size: 128px;">{icon:text}</div>
12
- <!-- ENDIF picture -->
13
- </div>
14
- </div>
15
6
  <ul class="list-group mb-3">
16
7
  {{{ if allowProfilePicture }}}
17
8
  <li class="list-group-item"><a component="profile/change/picture" href="#" class="text-decoration-none text-reset">[[user:change-picture]]</a></li>
@@ -15,7 +15,7 @@
15
15
  <div class="mb-4 pb-3 border-bottom">
16
16
  <h6>[[user:info.invited-by]]</h6>
17
17
  <div class="d-flex align-items-center gap-2">
18
- <a href="">{buildAvatar(invitedBy, "24px", true)}</a>
18
+ <a href="">{{buildAvatar(invitedBy, "24px", true)}}</a>
19
19
  <a href="">{invitedBy.username}</a>
20
20
  </div>
21
21
  </div>
@@ -43,7 +43,7 @@
43
43
  <div>
44
44
  {{{ if ./byUid }}}
45
45
  <a class="lh-1" href="{{{ if ./byUser.userslug }}}{config.relative_path}/user/{./byUser.userslug}{{{ else }}}#{{{ end }}}">
46
- {buildAvatar(./byUser, "18px", true)}</a>
46
+ {{buildAvatar(./byUser, "18px", true)}}</a>
47
47
  {{{ end }}}
48
48
  <span class="timeago text-sm text-secondary lh-1 align-middle" title="{./timestampISO}"></span>
49
49
  </div>
@@ -63,7 +63,7 @@
63
63
  <div>
64
64
  {{{ if ./byUid }}}
65
65
  <a class="lh-1" href="{{{ if ./byUser.userslug }}}{config.relative_path}/user/{./byUser.userslug}{{{ else }}}#{{{ end }}}">
66
- {buildAvatar(./byUser, "18px", true)}</a>
66
+ {{buildAvatar(./byUser, "18px", true)}}</a>
67
67
  {{{ end }}}
68
68
  <span class="timeago text-sm text-secondary lh-1 align-middle" title="{./timestampISO}"></span>
69
69
  </div>
@@ -107,7 +107,7 @@
107
107
  <span class="text-sm">[[user:info.reported-by]]</span>
108
108
  <div class="d-flex text-nowrap">
109
109
  {{{ each ./reports }}}
110
- <a style="width: 18px; z-index: 3;" class="text-decoration-none" href="{config.relative_path}/user/{./reporter.userslug}">{buildAvatar(./reporter, "24px", true)}</a>
110
+ <a style="width: 18px; z-index: 3;" class="text-decoration-none" href="{config.relative_path}/user/{./reporter.userslug}">{{buildAvatar(./reporter, "24px", true)}}</a>
111
111
  {{{ end }}}
112
112
  </div>
113
113
  </div>
@@ -138,7 +138,7 @@
138
138
  <li class="mb-4 border-bottom">
139
139
  <div class="mb-1 d-flex align-items-center justify-content-between">
140
140
  <div>
141
- <a href="{config.relative_path}/user/{./user.userslug}">{buildAvatar(./user, "24px", true)}</a>
141
+ <a href="{config.relative_path}/user/{./user.userslug}">{{buildAvatar(./user, "24px", true)}}</a>
142
142
  <strong>
143
143
  <a href="{{{ if ./user.userslug }}}{config.relative_path}/user/{./user.userslug}{{{ else }}}#{{{ end }}}" itemprop="author" data-username="{./user.username}" data-uid="{./user.uid}">{./user.username}</a>
144
144
  </strong>
@@ -192,7 +192,7 @@
192
192
  <li class="mb-4 border-bottom">
193
193
  <div class="mb-1 d-flex align-items-center justify-content-between">
194
194
  <div>
195
- <a href="{config.relative_path}/user/{./user.userslug}">{buildAvatar(./user, "24px", true)}</a>
195
+ <a href="{config.relative_path}/user/{./user.userslug}">{{buildAvatar(./user, "24px", true)}}</a>
196
196
  <strong>
197
197
  <a href="{{{ if ./user.userslug }}}{config.relative_path}/user/{./user.userslug}{{{ else }}}#{{{ end }}}" itemprop="author" data-username="{./user.username}" data-uid="{./user.uid}">{./user.username}</a>
198
198
  </strong>
@@ -240,7 +240,7 @@
240
240
 
241
241
  <div data-id="{./id}">
242
242
  <div class="d-flex align-items-baseline gap-1 mb-1">
243
- <a href="{{{ if ./user.userslug }}}{config.relative_path}/user/{./user.userslug}{{{ else }}}#{{{ end }}}">{buildAvatar(./user, "24px", true)}</a>
243
+ <a href="{{{ if ./user.userslug }}}{config.relative_path}/user/{./user.userslug}{{{ else }}}#{{{ end }}}">{{buildAvatar(./user, "24px", true)}}</a>
244
244
 
245
245
  <a href="{{{ if ./user.userslug }}}{config.relative_path}/user/{./user.userslug}{{{ else }}}#{{{ end }}}" class="fw-bold" itemprop="author" data-username="{./user.username}" data-uid="{./user.uid}">{./user.username}</a>
246
246
 
@@ -36,7 +36,7 @@
36
36
  {{{ end }}}
37
37
 
38
38
  <!-- IF aboutme -->
39
- <div component="aboutme" class="text-center aboutme text-secondary w-75 mx-auto text-center">{aboutmeParsed}</div>
39
+ <div component="aboutme" class="text-center aboutme text-secondary w-75 mx-auto text-center">{{aboutmeParsed}}</div>
40
40
  <!-- ENDIF aboutme -->
41
41
 
42
42
  <div class="account-stats fs-1 text-center mb-3">
@@ -6,24 +6,7 @@
6
6
  <p class="lead">[[user:sessions.description]]</p>
7
7
  <hr />
8
8
  <ul class="list-group" component="user/sessions">
9
- {{{each sessions}}}
10
- <li class="list-group-item" data-uuid="{../uuid}">
11
- <div class="float-end">
12
- <!-- IF isSelfOrAdminOrGlobalModerator -->
13
- <!-- IF !../current -->
14
- <button class="btn btn-sm btn-outline-secondary" type="button" data-action="revokeSession">Revoke Session</button>
15
- <!-- ENDIF !../current -->
16
- <!-- ENDIF isSelfOrAdminOrGlobalModerator -->
17
- {function.userAgentIcons}
18
- <i class="fa fa-circle text-<!-- IF ../current -->success<!-- ELSE -->muted<!-- ENDIF ../current -->"></i>
19
- </div>
20
- {../browser} {../version} on {../platform}<br />
21
- <small class="timeago text-muted" title="{../datetimeISO}"></small>
22
- <ul>
23
- <li><strong>[[global:ip-address]]</strong>: {../ip}</li>
24
- </ul>
25
- </li>
26
- {{{end}}}
9
+ <!-- IMPORT partials/account/session-list.tpl -->
27
10
  </ul>
28
11
  </div>
29
12
  </div>
@@ -61,7 +61,7 @@
61
61
  <div component="chat/allow/list" class="d-flex flex-wrap gap-2 mb-2">
62
62
  {{{ each settings.chatAllowListUsers }}}
63
63
  <div component="chat/allow/list/user" data-uid="{./uid}" class="d-flex px-2 py-1 rounded-1 text-bg-light gap-2 align-items-center text-sm">
64
- {buildAvatar(@value, "16px", true)} {./username}
64
+ {{buildAvatar(@value, "16px", true)}} {./username}
65
65
  <button component="chat/allow/delete" data-uid="{./uid}" class="btn btn-light btn-sm py-0"><i class="fa fa-times fa-xs text-danger"></i></button>
66
66
  </div>
67
67
  {{{ end }}}
@@ -76,7 +76,7 @@
76
76
  <div component="chat/deny/list" class="d-flex flex-wrap gap-2 mb-2">
77
77
  {{{ each settings.chatDenyListUsers }}}
78
78
  <div component="chat/deny/list/user" data-uid="{./uid}" class="d-flex px-2 py-1 rounded-1 text-bg-light gap-2 align-items-center text-sm">
79
- {buildAvatar(@value, "16px", true)} {./username}
79
+ {{buildAvatar(@value, "16px", true)}} {./username}
80
80
  <button component="chat/deny/delete" data-uid="{./uid}" class="btn btn-light btn-sm py-0"><i class="fa fa-times fa-xs text-danger"></i></button>
81
81
  </div>
82
82
  {{{ end }}}
@@ -176,7 +176,7 @@
176
176
  {{{each customSettings}}}
177
177
  <h4>{customSettings.title}</h4>
178
178
  <div class="card card-body mb-3">
179
- {customSettings.content}
179
+ {{customSettings.content}}
180
180
  </div>
181
181
  {{{end}}}
182
182
 
@@ -19,13 +19,13 @@
19
19
  {{{ end }}}
20
20
  {{{ end }}}
21
21
 
22
- <a href="{escape(url)}" class="d-inline-block">
22
+ <a href="{url}" class="d-inline-block">
23
23
  <div class="alert alert-warning h-100 m-0 px-2 py-1 d-flex gap-1 align-items-center hide" id="new-topics-alert"><i class="fa fa-fw fa-rotate-right"></i>[[recent:load-new-posts]]</div>
24
24
  </a>
25
25
  </div>
26
26
  <div component="category/controls" class="d-flex gap-1">
27
27
  {{{ if !isNumber(cid) }}}
28
- <a href="{escape(./url)}" class="btn btn-sm d-flex gap-2 align-items-center" data-ajaxify="false">
28
+ <a href="{./url}" class="btn btn-sm d-flex gap-2 align-items-center" data-ajaxify="false">
29
29
  <i class="fa fa-external-link text-primary"></i>
30
30
  <span class="fw-semibold">View Original</span>
31
31
  </a>
@@ -1,6 +1,6 @@
1
1
  <div component="groups/container" class="groups details">
2
2
 
3
- <div component="groups/cover" style="background-image: url({group.cover:url}??{config.cache-buster}); background-position: {group.cover:position};">
3
+ <div component="groups/cover" style="background-image: url({group.cover:url}?{config.cache-buster}); background-position: {group.cover:position};">
4
4
  {{{ if group.isOwner }}}
5
5
  <div class="controls">
6
6
  <span class="upload"><i class="fa fa-fw fa-4x fa-upload"></i></span>
@@ -26,12 +26,12 @@
26
26
  </div>
27
27
  </div>
28
28
  <div>
29
- {group.descriptionParsed}
29
+ {{group.descriptionParsed}}
30
30
  </div>
31
31
  </div>
32
32
  <div class="d-flex gap-2 align-items-start">
33
33
  {{{ if loggedIn }}}
34
- {function.membershipBtn, group}
34
+ {{membershipBtn(group)}}
35
35
  {{{ end }}}
36
36
  {{{ if isAdmin }}}
37
37
  <a href="{config.relative_path}/admin/manage/groups/{group.slug}" target="_blank" class="btn btn-light text-nowrap"><i class="fa fa-gear"></i> [[user:edit]]</a>
@@ -1,10 +1,10 @@
1
1
  <!DOCTYPE html>
2
- <html lang="{function.localeToHTML, userLang, defaultLang}" {{{if languageDirection}}}data-dir="{languageDirection}" style="direction: {languageDirection};"{{{end}}}>
2
+ <html lang="{localeToHTML(userLang, defaultLang)}" {{{if languageDirection}}}data-dir="{languageDirection}" style="direction: {languageDirection};"{{{end}}}>
3
3
  <head>
4
4
  <title>{browserTitle}</title>
5
- {{{each metaTags}}}{function.buildMetaTag}{{{end}}}
5
+ {{{each metaTags}}}{{buildMetaTag(@value)}}{{{end}}}
6
6
  <link rel="stylesheet" type="text/css" href="{relative_path}/assets/client{{{if bootswatchSkin}}}-{bootswatchSkin}{{{end}}}{{{ if (languageDirection=="rtl") }}}-rtl{{{ end }}}.css?{config.cache-buster}" />
7
- {{{each linkTags}}}{function.buildLinkTag}{{{end}}}
7
+ {{{each linkTags}}}{{buildLinkTag(@value)}}{{{end}}}
8
8
 
9
9
  <script>
10
10
  var config = JSON.parse('{{configJSON}}');
@@ -1,31 +1,32 @@
1
- <div class="persona-usercard">
1
+ <div class="persona-usercard d-flex text-bg-dark">
2
2
  <a href="{config.relative_path}/user/{userslug}">
3
- <!-- IF picture -->
4
- <div class="usercard-picture" style="background-image:url({picture})"></div>
5
- <!-- ELSE -->
6
- <div class="usercard-picture" style="background-color: {icon:bgColor};">{icon:text}</div>
7
- <!-- ENDIF picture -->
3
+ {{buildAvatar(@value, "150px", false, "shadow-none")}}
8
4
  </a>
9
- <div class="usercard-body">
10
- <a href="{config.relative_path}/user/{userslug}">
11
- <span class="usercard-name"><!-- IF fullname -->{fullname}<!-- ELSE -->{username}<!-- ENDIF fullname --></span><br />
12
- <span class="usercard-username"><!-- IF !banned -->@{username}<!-- ELSE -->[[user:banned]]<!-- ENDIF !banned --></span>
13
- <!-- IF !banned -->
14
- <i component="user/status" class="fa fa-circle status {status}" title="[[global:{status}]]"></i>
15
- <!-- ENDIF !banned -->
5
+ <div class="usercard-body w-100 d-flex flex-column justify-content-between gap-2 py-2 px-3 overflow-hidden position-relative">
6
+
7
+ <a href="{config.relative_path}/user/{userslug}" class="text-reset text-truncate d-block">
8
+ <span class="usercard-name fs-5">{{{ if fullname }}}{fullname}{{{ else }}}{username}{{{ end }}}</span>
16
9
  </a>
17
10
 
18
- <div class="row usercard-info">
19
- <div class="col-4">
11
+ <div class="d-flex gap-2 align-items-center">
12
+ <a href="{config.relative_path}/user/{userslug}" class="text-reset text-truncate d-block">
13
+ <span class="usercard-username text-uppercase text-sm text-truncate">{{{ if !banned }}}@{username}{{{ else }}}[[user:banned]]{{{ end }}}</span>
14
+ </a>
15
+ {{{ if !banned }}}
16
+ <span component="user/status" class="border border-white border-2 m-0 rounded-circle status {status}" title="[[global:{status}]]" style="transform: none;"><span class="visually-hidden">[[global:{posts.user.status}]]</span></span>
17
+ {{{ end }}}
18
+ </div>
19
+
20
+ <div class="d-flex justify-content-between usercard-info">
21
+ <div class="d-flex flex-column text-center">
20
22
  <small>[[global:posts]]</small>
21
- <span>{humanReadableNumber(postcount)}</span>
23
+ <span class="fs-5">{humanReadableNumber(postcount)}</span>
22
24
  </div>
23
- <div class="col-4">
25
+ <div class="d-flex flex-column text-center">
24
26
  <small>[[global:reputation]]</small>
25
- <span>{humanReadableNumber(reputation)}</span>
27
+ <span class="fs-5">{humanReadableNumber(reputation)}</span>
26
28
  </div>
27
-
28
- <button class="btn-morph persona-fab <!-- IF banned --> hide<!-- ENDIF banned -->">
29
+ <button class="btn-morph persona-fab fs-3 {{{ if banned }}} invisible{{{ end }}}">
29
30
  <span>
30
31
  <span class="s1"></span>
31
32
  <span class="s2"></span>
@@ -34,4 +35,5 @@
34
35
  </button>
35
36
  </div>
36
37
  </div>
38
+
37
39
  </div>
@@ -14,7 +14,7 @@
14
14
  {{{ else }}}
15
15
  <li role="presentation" class="category">
16
16
  <a class="dropdown-item rounded-1 d-flex gap-3 align-items-center justify-content-between" role="menuitem" href="{config.relative_path}/notifications?filter={filters.filter}">
17
- <span><i class="fa fa-fw {{{ if filters.selected }}}fa-check{{{ end }}}"></i> {filters.name}</span>
17
+ <span><i class="fa fa-fw {{{ if filters.selected }}}fa-check{{{ end }}}"></i> {tx(filters.name)}</span>
18
18
  <span class="">{./count}</span>
19
19
  </a>
20
20
  </li>
@@ -40,7 +40,7 @@
40
40
  <li data-nid="{notifications.nid}" class="{notifications.readClass} {{{ if !./read}}}unread{{{ end }}} d-flex pointer border p-3 mb-2 d-flex gap-2" component="notifications/item">
41
41
  <div>
42
42
  {{{ if notifications.from }}}
43
- {buildAvatar(notifications.user, "24px", true)}
43
+ {{buildAvatar(notifications.user, "24px", true)}}
44
44
  {{{ else }}}
45
45
  {{{ if notifications.image }}}
46
46
  <img width="24" height="24" src="{notifications.image}" />
@@ -3,14 +3,14 @@
3
3
  <div class="content depth-{./depth} d-flex gap-2">
4
4
  <div class="flex-grow-1 align-items-start d-flex gap-2">
5
5
  <div>
6
- {buildCategoryIcon(@value, "24px", "rounded-circle")}
6
+ {{buildCategoryIcon(@value, "24px", "rounded-circle")}}
7
7
  </div>
8
8
  <div class="d-grid gap-0">
9
9
  <div class="title fw-semibold">
10
10
  <!-- IMPORT partials/categories/link.tpl -->
11
11
  </div>
12
12
  {{{ if ./descriptionParsed }}}
13
- <div class="description text-muted text-xs w-100 line-clamp-5">{./descriptionParsed}</div>
13
+ <div class="description text-muted text-xs w-100 line-clamp-5">{{./descriptionParsed}}</div>
14
14
  {{{ end }}}
15
15
  </div>
16
16
  </div>
@@ -9,27 +9,22 @@
9
9
 
10
10
  <div class="cover" component="account/cover" style="background-image: url({cover:url}); background-position: {cover:position};">
11
11
  <div class="avatar-wrapper" data-uid="{uid}">
12
- <!-- IF picture -->
13
- <img src="{picture}" class="avatar avatar-rounded" style="--avatar-size: 128px;" />
14
- <!-- ELSE -->
15
- <div class="avatar avatar-rounded" style="background-color: {icon:bgColor}; --avatar-size: 128px;" title="{username}">{icon:text}</div>
16
- <!-- ENDIF picture -->
12
+ {{buildAvatar(@value, "128px", true)}}
17
13
  <span component="user/status" class="position-absolute border border-white border-2 rounded-circle status {status}"><span class="visually-hidden">[[global:{status}]]</span></span>
18
14
 
19
- <!-- IF !isSelf -->
20
- <button class="btn-morph persona-fab <!-- IF isFollowing -->heart<!-- ELSE -->plus<!-- ENDIF isFollowing -->" title="<!-- IF isFollowing -->[[global:unfollow]]<!-- ELSE -->[[global:follow]]<!-- ENDIF isFollowing -->">
15
+ {{{ if !isSelf }}}
16
+ <button class="btn-morph persona-fab {{{ if isFollowing }}}heart{{{ else }}}plus{{{ end }}}" title="{{{ if isFollowing }}}[[global:unfollow]]{{{ else }}}[[global:follow]]{{{ end }}}">
21
17
  <span>
22
18
  <span class="s1"></span>
23
19
  <span class="s2"></span>
24
20
  <span class="s3"></span>
25
21
  </span>
26
22
  </button>
27
- <!-- ENDIF !isSelf -->
23
+ {{{ end }}}
28
24
  </div>
29
25
 
30
26
  <div class="container">
31
- <!-- IF allowCoverPicture -->
32
- <!-- IF canEdit -->
27
+ {{{ if (allowCoverPicture && canEdit) }}}
33
28
  <div class="controls">
34
29
  <a href="#" class="upload"><i class="fa fa-fw fa-4x fa-upload"></i></a>
35
30
  <a href="#" class="resize"><i class="fa fa-fw fa-4x fa-arrows"></i></a>
@@ -37,8 +32,7 @@
37
32
  </div>
38
33
  <a href="#" class="save">[[groups:cover-save]] <i class="fa fa-fw fa-floppy-o"></i></a>
39
34
  <div class="indicator">[[groups:cover-saving]] <i class="fa fa-fw fa-refresh fa-spin"></i></div>
40
- <!-- ENDIF canEdit -->
41
- <!-- ENDIF allowCoverPicture -->
35
+ {{{ end }}}
42
36
 
43
37
  <!-- IMPORT partials/account/menu.tpl -->
44
38
  </div>
@@ -90,11 +90,11 @@
90
90
  <li><a class="dropdown-item d-flex justify-content-between align-items-center" href="{config.relative_path}/user/{userslug}/uploads" role="menuitem">[[global:uploads]] <span class="badge bg-secondary rounded-pill ms-2" title="{counts.uploaded}">{formattedNumber(counts.uploaded)}</span></a></li>
91
91
  <!-- ENDIF canEdit -->
92
92
 
93
- {{{each profile_links}}}
93
+ {{{ each profile_links }}}
94
94
  <!-- IF @first -->
95
95
  <li role="separator" class="dropdown-divider"></li>
96
96
  <!-- ENDIF @first -->
97
- <li id="{profile_links.id}" class="plugin-link <!-- IF profile_links.public -->public<!-- ELSE -->private<!-- ENDIF profile_links.public -->"><a class="dropdown-item" href="{config.relative_path}/user/{userslug}/{profile_links.route}"><!-- IF ../icon --><i class="fa fa-fw {profile_links.icon}"></i> <!-- END -->{profile_links.name}</a></li>
98
- {{{end}}}
97
+ <li id="{./id}" class="plugin-link {{{ if ./public }}}public{{{ else }}}private{{{ end }}}"><a class="dropdown-item" href="{config.relative_path}/user/{userslug}/{profile_links.route}">{{{ if icon }}}<i class="fa fa-fw {./icon}"></i> {{{ end }}}{tx(./name)}</a></li>
98
+ {{{ end }}}
99
99
  </ul>
100
100
  </div>
@@ -6,7 +6,7 @@
6
6
  <button class="btn btn-sm btn-outline-secondary" type="button" data-action="revokeSession">[[user:revoke-session]]</button>
7
7
  {{{ end }}}
8
8
  {{{ end }}}
9
- {function.userAgentIcons}
9
+ {{userAgentIcons(@value)}}
10
10
  <i class="fa fa-circle text-{{{ if ./current }}}success{{{ else }}}muted{{{ end }}}"></i>
11
11
  </div>
12
12
  [[user:browser-version-on-platform, {./browser}, {./version}, {./platform}]]<br />
@@ -5,7 +5,7 @@
5
5
  <meta itemprop="position" content="{@index}" />
6
6
  {{{ if ./url }}}<a href="{breadcrumbs.url}" itemprop="item">{{{ end }}}
7
7
  <span itemprop="name">
8
- {breadcrumbs.text}
8
+ {tx(./text)}
9
9
  <!-- IF @last -->
10
10
  <!-- IF !feeds:disableRSS -->
11
11
  <!-- IF rssFeedUrl --><a class="ms-2 link-secondary" target="_blank" href="{rssFeedUrl}" itemprop="item"><i class="fa fa-rss-square"></i></a><!-- ENDIF rssFeedUrl --><!-- ENDIF !feeds:disableRSS -->
@@ -10,7 +10,7 @@
10
10
  <a role="menu-item" href="{config.relative_path}/compose?cid={categories.cid}">{categories.level}
11
11
  <span component="category-markup">
12
12
  <div class="category-item d-inline-block">
13
- {buildCategoryIcon(@value, "24px", "rounded-circle")}
13
+ {{buildCategoryIcon(@value, "24px", "rounded-circle")}}
14
14
  {categories.name}
15
15
  </div>
16
16
  </span>
@@ -3,7 +3,7 @@
3
3
 
4
4
  <div class="d-flex col-md-7 gap-2 gap-lg-3">
5
5
  <div class="flex-shrink-0">
6
- {buildCategoryIcon(@value, "48px", "rounded-circle")}
6
+ {{buildCategoryIcon(@value, "48px", "rounded-circle")}}
7
7
  </div>
8
8
  <div class="flex-grow-1 d-flex flex-wrap gap-1">
9
9
  <h2 class="title text-break fs-4 fw-semibold m-0 tracking-tight w-100">
@@ -11,7 +11,7 @@
11
11
  </h2>
12
12
  {{{ if ./descriptionParsed }}}
13
13
  <div class="description text-muted text-sm w-100 line-clamp-sm-5">
14
- {./descriptionParsed}
14
+ {{./descriptionParsed}}
15
15
  </div>
16
16
  {{{ end }}}
17
17
  {{{ if ./teaser.timestampISO }}}
@@ -26,7 +26,7 @@
26
26
  {{{ each ./children }}}
27
27
  {{{ if !./isSection }}}
28
28
  <li class="category-children-item small d-flex gap-1 align-items-center">
29
- {buildCategoryIcon(@value, "24px", "rounded-circle")}
29
+ {{buildCategoryIcon(@value, "24px", "rounded-circle")}}
30
30
  <a href="{{{ if ./link }}}{./link}{{{ else }}}{config.relative_path}/category/{./slug}{{{ end }}}" class="text-reset">{./name}</a>
31
31
  </li>
32
32
  {{{ end }}}
@@ -3,12 +3,12 @@
3
3
  {{{ if @first }}}
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
- <a class="text-decoration-none avatar-tooltip" title="{./user.displayname}" href="{config.relative_path}/user/{./user.userslug}">{buildAvatar(posts.user, "18px", true)}</a>
6
+ <a class="text-decoration-none avatar-tooltip" title="{./user.displayname}" href="{config.relative_path}/user/{./user.userslug}">{{buildAvatar(posts.user, "18px", true)}}</a>
7
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>
8
8
  </div>
9
9
  <div class="post-content text-xs text-break line-clamp-sm-2 lh-sm position-relative flex-fill">
10
10
  <a class="stretched-link" tabindex="-1" href="{config.relative_path}/topic/{./topic.slug}{{{ if ./index }}}/{./index}{{{ end }}}" aria-label="[[global:lastpost]]"></a>
11
- {./content}
11
+ {{./content}}
12
12
  </div>
13
13
  </div>
14
14
  {{{ end }}}
@@ -1,11 +1,5 @@
1
- <!-- IF ../isSection -->
2
- {../name}
3
- <!-- ELSE -->
4
- <!-- IF ../link -->
5
- <a href="{../link}" itemprop="url">
6
- <!-- ELSE -->
7
- <a href="{config.relative_path}/category/{../slug}" itemprop="url">
8
- <!-- ENDIF ../link -->
9
- {../name}
10
- </a>
11
- <!-- ENDIF ../isSection -->
1
+ {{{ if ./isSection }}}
2
+ {./name}
3
+ {{{ else }}}
4
+ <a class="text-reset" href="{{{ if ./link }}}{./link}{{{ else }}}{config.relative_path}/category/{./slug}{{{ end }}}" itemprop="url">{./name}</a>
5
+ {{{ end }}}
@@ -10,7 +10,7 @@
10
10
  {{{ end }}}
11
11
  <li class="nav-item">
12
12
  <a class="nav-link active text-decoration-none" href="#" data-bs-target="#profile" data-bs-toggle="tab">
13
- {buildAvatar(user, "24px", true, "user-icon")}
13
+ {{buildAvatar(user, "24px", true, "user-icon")}}
14
14
  </a>
15
15
  </li>
16
16
  </ul>
@@ -26,7 +26,7 @@
26
26
  <div class="mb-3 user-title-option">
27
27
  <label class="form-label" for="userTitle">[[groups:details.badge-text]]</label>
28
28
  <div class="d-flex gap-2">
29
- <input component="groups/userTitleOption" class="form-control" name="userTitle" id="userTitle" type="text" maxlength="40" value="{group.userTitleEscaped}"<!-- IF !group.userTitleEnabled --> disabled<!-- ENDIF !group.userTitleEnabled --> />
29
+ <input component="groups/userTitleOption" class="form-control" name="userTitle" id="userTitle" type="text" maxlength="40" value="{group.userTitle}"<!-- IF !group.userTitleEnabled --> disabled<!-- ENDIF !group.userTitleEnabled --> />
30
30
  <button component="groups/userTitleOption" type="button" class="btn btn-outline-secondary btn-sm text-nowrap" data-action="icon-select"<!-- IF !group.userTitleEnabled --> disabled<!-- ENDIF !group.userTitleEnabled -->>[[groups:details.change-icon]]</button>
31
31
  </div>
32
32
  </div>
@@ -21,7 +21,7 @@
21
21
  <tr data-uid="{group.invited.uid}" class="align-middle">
22
22
  <td class="member-name p-2 d-flex align-items-center justify-content-between">
23
23
  <div class="d-flex align-items-center gap-2">
24
- <a class="text-decoration-none" href="{config.relative_path}/user/{group.invited.userslug}">{buildAvatar(group.invited, "24px", true)}</a>
24
+ <a class="text-decoration-none" href="{config.relative_path}/user/{group.invited.userslug}">{{buildAvatar(group.invited, "24px", true)}}</a>
25
25
  <a href="{config.relative_path}/user/{group.invited.userslug}">{group.invited.username}</a>
26
26
  </div>
27
27
  <button class="btn btn-outline-secondary btn-sm text-nowrap" data-action="rescindInvite">[[groups:invited.uninvite]]</button>
@@ -11,7 +11,7 @@
11
11
  <ul class="members list-unstyled d-flex align-items-center gap-2 flex-wrap">
12
12
  {{{each groups.members}}}
13
13
  <li>
14
- <a href="{config.relative_path}/user/{groups.members.userslug}">{buildAvatar(groups.members, "24px", true)}</a>
14
+ <a href="{config.relative_path}/user/{groups.members.userslug}">{{buildAvatar(groups.members, "24px", true)}}</a>
15
15
  </li>
16
16
  {{{end}}}
17
17
  </ul>
@@ -20,7 +20,7 @@
20
20
  <td class="member-name p-2 w-100 ">
21
21
  <div class="d-flex align-items-center justify-content-between">
22
22
  <div class="d-flex align-items-center gap-2">
23
- <a class="text-decoration-none" href="{config.relative_path}/user/{group.members.userslug}">{buildAvatar(group.members, "24px", true)}</a>
23
+ <a class="text-decoration-none" href="{config.relative_path}/user/{group.members.userslug}">{{buildAvatar(group.members, "24px", true)}}</a>
24
24
  <a class="align-text-top" href="{config.relative_path}/user/{group.members.userslug}">{group.members.username}</a>
25
25
  <i component="groups/owner/icon" title="[[groups:owner]]" class="user-owner-icon fa fa-star align-text-top text-warning {{{ if !group.members.isOwner }}}invisible{{{ end }}}"></i>
26
26
  </div>
@@ -13,7 +13,7 @@
13
13
  <tr data-uid="{group.pending.uid}" class="align-middle">
14
14
  <td class="member-name p-2 d-flex align-items-center justify-content-between">
15
15
  <div class="d-flex gap-2">
16
- <a class="text-decoration-none" href="{config.relative_path}/user/{group.pending.userslug}">{buildAvatar(group.pending, "24px", true)}</a>
16
+ <a class="text-decoration-none" href="{config.relative_path}/user/{group.pending.userslug}">{{buildAvatar(group.pending, "24px", true)}}</a>
17
17
  <a href="{config.relative_path}/user/{group.pending.userslug}">{group.pending.username}</a>
18
18
  </div>
19
19
  <div class="d-flex gap-2">
@@ -1,6 +1,6 @@
1
1
  <li id="user_label" class="nav-item dropdown px-3" title="[[global:header.profile]]">
2
2
  <a href="#" for="user-control-list-check" data-bs-toggle="dropdown" id="user_dropdown" role="button" component="header/avatar" aria-haspopup="true" aria-expanded="false">
3
- {buildAvatar(user, "32px", true)}
3
+ {{buildAvatar(user, "32px", true)}}
4
4
  <span id="user-header-name" class="d-block d-sm-none">{user.username}</span>
5
5
  </a>
6
6
  <input type="checkbox" class="hidden" id="user-control-list-check" aria-hidden="true">
@@ -35,7 +35,7 @@
35
35
  <button type="button" class="navbar-toggler border-0" id="mobile-chats">
36
36
  <span component="notifications/icon" class="notification-icon fa fa-fw fa-bell-o unread-count" data-content="{unreadCount.notification}"></span>
37
37
  <span component="chat/icon" class="notification-icon fa fa-fw fa-comments unread-count" data-content="{unreadCount.chat}"></span>
38
- {buildAvatar(user, "32px", true)}
38
+ {{buildAvatar(user, "32px", true)}}
39
39
  </button>
40
40
  {{{ end }}}
41
41
 
@@ -46,7 +46,7 @@
46
46
  <div id="nav-dropdown" class="collapse navbar-collapse d-none d-lg-block">
47
47
  <ul id="main-nav" class="navbar-nav me-auto mb-2 mb-lg-0">
48
48
  {{{each navigation}}}
49
- <!-- IF function.displayMenuItem, @index -->
49
+ {{{ if displayMenuItem(@root, @index) }}}
50
50
  <li class="nav-item {navigation.class}{{{ if navigation.dropdown }}} dropdown{{{ end }}}" title="{navigation.title}">
51
51
  <a class="nav-link navigation-link {{{ if navigation.dropdown }}}dropdown-toggle{{{ end }}}"
52
52
  {{{ if navigation.dropdown }}} href="#" role="button" data-bs-toggle="dropdown" aria-haspopup="true" aria-expanded="false" {{{ else }}} href="{navigation.route}"{{{ end }}} {{{ if navigation.id }}}id="{navigation.id}"{{{ end }}}{{{ if navigation.targetBlank }}} target="_blank"{{{ end }}}>
@@ -62,12 +62,12 @@
62
62
  </a>
63
63
  {{{ if navigation.dropdown }}}
64
64
  <ul class="dropdown-menu p-1" role="menu">
65
- {navigation.dropdownContent}
65
+ {{navigation.dropdownContent}}
66
66
  </ul>
67
67
  {{{ end }}}
68
68
  </li>
69
- <!-- ENDIF function.displayMenuItem -->
70
- {{{end}}}
69
+ {{{ end }}}
70
+ {{{ end }}}
71
71
  </ul>
72
72
  <ul class="navbar-nav mb-2 mb-lg-0 hidden-xs">
73
73
  <li class="nav-item">
@@ -11,7 +11,7 @@
11
11
  <div class="btn btn-ghost btn-sm d-flex gap-2 flex-grow-1 align-items-start text-start">
12
12
  <a class="flex-grow-0 flex-shrink-0" href="{{{ if ./user.userslug}}}{config.relative_path}/user/{./user.userslug}{{{ else }}}#{{{ end }}}">
13
13
  {{{ if ./user }}}
14
- {buildAvatar(./user, "32px", true)}
14
+ {{buildAvatar(./user, "32px", true)}}
15
15
  {{{ else }}}
16
16
  {{{ if ./icon }}}
17
17
  <div class="avatar avatar-rounded" style="--avatar-size: 32px;"><i class="text-secondary fa {./icon}"></i></div>
@@ -29,7 +29,7 @@
29
29
  </a>
30
30
  {{{ if ./bodyLong}}}
31
31
  <div class="text-secondary text-sm line-clamp-2 text-contain hidden-blockquote hidden-pre hidden-first-child-br">
32
- {./bodyLong}
32
+ {{./bodyLong}}
33
33
  </div>
34
34
  {{{ end }}}
35
35
  <div class="text-xs text-muted">{{{ if ./timeagoLong }}}{./timeagoLong}{{{ else }}}<span class="timeago" title="{./datetimeISO}"></span>{{{ end }}}</div>
@@ -5,7 +5,7 @@
5
5
  </a>
6
6
 
7
7
  <div component="post/content" class="content mb-3">
8
- {../content}
8
+ {{../content}}
9
9
  </div>
10
10
 
11
11
  <div class="mb-3">
@@ -23,7 +23,7 @@
23
23
  </div>
24
24
 
25
25
  <div class="post-info">
26
- <a href="{config.relative_path}/user/{./user.userslug}">{buildAvatar(./user, "28px", true, "user-img not-responsive")}</a>
26
+ <a href="{config.relative_path}/user/{./user.userslug}">{{buildAvatar(./user, "28px", true, "user-img not-responsive")}}</a>
27
27
 
28
28
  <div class="post-author text-secondary text-uppercase">
29
29
  <a class="text-reset" href="{config.relative_path}/user/{./user.userslug}">{./user.displayname}</a><br />
@@ -11,7 +11,7 @@
11
11
  {{{ each categories }}}
12
12
  <li data-cid="{./cid}" class="d-flex flex-column gap-1">
13
13
  <div class="btn btn-ghost btn-sm ff-secondary d-flex gap-2 align-items-center rounded-1 text-start text-reset d-block text-truncate px-2 py-1 position-relative">
14
- <div class="flex-shrink-0">{buildCategoryIcon(@value, "40px", "rounded-circle")}</div>
14
+ <div class="flex-shrink-0">{{buildCategoryIcon(@value, "40px", "rounded-circle")}}</div>
15
15
  <div class="flex-grow-1" style="min-width:0;">
16
16
  <a class="stretched-link" href="{config.relative_path}/category/{./slug}"></a>
17
17
  <span class="quick-search-title fw-semibold text-sm">
@@ -22,7 +22,7 @@
22
22
  </span>
23
23
  <br/>
24
24
  <div class="snippet text-xs text-break text-wrap mb-0 text-sm text-secondary line-clamp-1">
25
- {./descriptionParsed}
25
+ {{./descriptionParsed}}
26
26
  </div>
27
27
  </div>
28
28
  </div>
@@ -3,7 +3,7 @@
3
3
  <li data-tid="{posts.topic.tid}" data-pid="{posts.pid}">
4
4
  <a href="{config.relative_path}/post/{encodeURIComponent(posts.pid)}"
5
5
  class="text-decoration-none text-reset clearfix d-block text-truncate px-3 py-1">
6
- {buildAvatar(posts.user, "24px", true)}
6
+ {{buildAvatar(posts.user, "24px", true)}}
7
7
  <span class="quick-search-title fw-bold">{posts.topic.title}</span>
8
8
  <br/>
9
9
  <p class="snippet text-break text-wrap">
@@ -11,7 +11,7 @@
11
11
  </p>
12
12
  <small class="post-info float-end">
13
13
  <div class="category-item d-inline-block">
14
- {buildCategoryIcon(./category, "24px", "rounded-circle")} {posts.category.name}
14
+ {{buildCategoryIcon(./category, "24px", "rounded-circle")}} {posts.category.name}
15
15
  &bull; <span class="timeago" title="{posts.timestampISO}"></span>
16
16
  </div>
17
17
  </small>
@@ -69,7 +69,7 @@
69
69
  <div component="user/filter/selected" class="d-flex flex-wrap gap-2">
70
70
  {{{ each userFilterSelected }}}
71
71
  <div class="d-flex px-2 py-1 rounded-1 text-bg-primary gap-2 align-items-center text-sm">
72
- {buildAvatar(@value, "16px", true)} {./username}
72
+ {{buildAvatar(@value, "16px", true)}} {./username}
73
73
  <button component="user/filter/delete" data-uid="{./uid}" class="btn btn-primary btn-sm py-0"><i class="fa fa-times fa-xs"></i></button>
74
74
  </div>
75
75
  {{{ end }}}
@@ -77,7 +77,7 @@
77
77
  <hr class="my-2"/>
78
78
  <div component="user/filter/results" class="d-flex flex-wrap gap-2">
79
79
  {{{ each userFilterResults }}}
80
- <button class="btn btn-light btn-sm border" data-uid="{./uid}" data-username="{./username}">{buildAvatar(@value, "16px", true)} {./username}</button>
80
+ <button class="btn btn-light btn-sm border" data-uid="{./uid}" data-username="{./username}">{{buildAvatar(@value, "16px", true)}} {./username}</button>
81
81
  {{{ end }}}
82
82
  </div>
83
83
  </li>
@@ -11,20 +11,20 @@
11
11
  <div class="topic-row card clearfix mb-3">
12
12
  <div class="card-body">
13
13
  <div class="mb-2">
14
- <a href="{config.relative_path}/user/{./user.userslug}">{buildAvatar(./user, "24px", true)}</a>
14
+ <a href="{config.relative_path}/user/{./user.userslug}">{{buildAvatar(./user, "24px", true)}}</a>
15
15
  <a class="topic-title fw-semibold fs-5" href="{config.relative_path}/post/{encodeURIComponent(posts.pid)}">{./topic.title}</a>
16
16
  </div>
17
17
 
18
18
  {{{ if showAsPosts }}}
19
19
  <div component="post/content" class="content">
20
- {./content}
20
+ {{./content}}
21
21
  </div>
22
22
  {{{ end }}}
23
23
 
24
24
  <small class="post-info">
25
25
  <a href="{config.relative_path}/category/{./category.slug}">
26
26
  <div class="category-item d-inline-block">
27
- {buildCategoryIcon(./category, "24px", "rounded-circle")}
27
+ {{buildCategoryIcon(./category, "24px", "rounded-circle")}}
28
28
  {./category.name}
29
29
  </div>
30
30
  </a> &bull;
@@ -3,7 +3,7 @@
3
3
  <i class="fa {{{ if ./icon }}}{./icon}{{{ else }}}fa-circle{{{ end }}}"></i>
4
4
  </div>
5
5
  <span class="timeline-text">
6
- {./text}
6
+ {{./text}}
7
7
  </span>
8
8
  {{{ if (privileges.isAdminOrMod && ./id) }}}
9
9
  &nbsp;<span component="topic/event/delete" data-topic-event-id="{./id}" data-topic-event-type="{./type}" class="timeline-text pointer" title="[[topic:delete-event]]"><i class="fa fa-trash"></i></span>
@@ -1,7 +1,7 @@
1
1
  <div class="clearfix">
2
2
  <div class="icon float-start">
3
3
  <a href="<!-- IF post.user.userslug -->{config.relative_path}/user/{post.user.userslug}<!-- ELSE -->#<!-- ENDIF post.user.userslug -->">
4
- {buildAvatar(post.user, "24px", true, "", "user/picture")} {post.user.username}
4
+ {{buildAvatar(post.user, "24px", true, "", "user/picture")}} {post.user.username}
5
5
  </a>
6
6
  </div>
7
7
  <small class="float-end">
@@ -9,4 +9,4 @@
9
9
  </small>
10
10
  </div>
11
11
 
12
- <div>{post.content}</div>
12
+ <div>{{post.content}}</div>
@@ -1,3 +1,3 @@
1
1
  <li component="topic/necro-post" class="necro-post text-muted timeline-event">
2
- <span class="timeline-text">{text}</span>
2
+ <span class="timeline-text">{tx(text)}</span>
3
3
  </li>
@@ -9,7 +9,7 @@
9
9
  <div class="clearfix post-header">
10
10
  <div class="icon float-start">
11
11
  <a href="<!-- IF posts.user.userslug -->{config.relative_path}/user/{posts.user.userslug}<!-- ELSE -->#<!-- ENDIF posts.user.userslug -->">
12
- {buildAvatar(posts.user, "48px", true, "", "user/picture")}
12
+ {{buildAvatar(posts.user, "48px", true, "", "user/picture")}}
13
13
  {{{ if ./user.isLocal }}}
14
14
  <span component="user/status" class="position-absolute top-100 start-100 border border-white border-2 rounded-circle status {posts.user.status}"><span class="visually-hidden">[[global:{posts.user.status}]]</span></span>
15
15
  {{{ else }}}
@@ -48,7 +48,7 @@
48
48
  <!-- IF posts.user.custom_profile_info.length -->
49
49
  &#124;
50
50
  {{{each posts.user.custom_profile_info}}}
51
- {posts.user.custom_profile_info.content}
51
+ {{posts.user.custom_profile_info.content}}
52
52
  {{{end}}}
53
53
  <!-- ENDIF posts.user.custom_profile_info.length -->
54
54
  </span>
@@ -72,12 +72,12 @@
72
72
  <br />
73
73
 
74
74
  <div class="content" component="post/content" itemprop="text">
75
- {posts.content}
75
+ {{posts.content}}
76
76
  </div>
77
77
 
78
78
  <div class="post-footer">
79
79
  {{{ if posts.user.signature }}}
80
- <div component="post/signature" data-uid="{posts.user.uid}" class="post-signature">{posts.user.signature}</div>
80
+ <div component="post/signature" data-uid="{posts.user.uid}" class="post-signature">{{posts.user.signature}}</div>
81
81
  {{{ end }}}
82
82
 
83
83
  <div class="clearfix">
@@ -85,7 +85,7 @@
85
85
  <a component="post/reply-count" data-target-component="post/replies/container" href="#" class="threaded-replies user-select-none float-start text-muted {{{ if (!./replies || shouldHideReplyContainer(@value)) }}}hidden{{{ end }}}">
86
86
  <span component="post/reply-count/avatars" class="avatars d-inline-flex gap-1 align-items-top hidden-xs {{{ if posts.replies.hasMore }}}hasMore{{{ end }}}">
87
87
  {{{each posts.replies.users}}}
88
- <span>{buildAvatar(posts.replies.users, "16px", true, "")}</span>
88
+ <span>{{buildAvatar(posts.replies.users, "16px", true, "")}}</span>
89
89
  {{{end}}}
90
90
  {{{ if posts.replies.hasMore}}}
91
91
  <span><i class="fa fa-ellipsis"></i></span>
@@ -2,7 +2,7 @@
2
2
  <div component="topic/quickreply/container" class="quick-reply d-flex gap-3 mb-4">
3
3
  <div class="icon hidden-xs">
4
4
  <a class="d-inline-block position-relative" href="{{{ if loggedInUser.userslug }}}{config.relative_path}/user/{loggedInUser.userslug}{{{ else }}}#{{{ end }}}">
5
- {buildAvatar(loggedInUser, "48px", true, "", "user/picture")}
5
+ {{buildAvatar(loggedInUser, "48px", true, "", "user/picture")}}
6
6
  </a>
7
7
  </div>
8
8
  <form class="flex-grow-1 d-flex flex-column gap-2" method="post" action="{config.relative_path}/compose">
@@ -1,9 +1,9 @@
1
1
  <ul component="category" class="topics-list list-unstyled" itemscope itemtype="http://www.schema.org/ItemList" data-nextstart="{nextStart}" data-set="{set}">
2
2
 
3
3
  {{{ each topics }}}
4
- <li component="category/topic" class="category-item hover-parent py-2 mb-2 d-flex flex-column flex-lg-row align-items-start {function.generateTopicClass}" <!-- IMPORT partials/data/category.tpl -->>
4
+ <li component="category/topic" class="category-item hover-parent py-2 mb-2 d-flex flex-column flex-lg-row align-items-start {generateTopicClass(@value)}" <!-- IMPORT partials/data/category.tpl -->>
5
5
  <link itemprop="url" content="{config.relative_path}/topic/{./slug}" />
6
- <meta itemprop="name" content="{function.stripTags, ./title}" />
6
+ <meta itemprop="name" content="{./title}" />
7
7
  <meta itemprop="itemListOrder" content="descending" />
8
8
  <meta itemprop="position" content="{increment(./index, "1")}" />
9
9
  <a id="{./index}" data-index="{./index}" component="topic/anchor"></a>
@@ -11,7 +11,7 @@
11
11
  <div class="d-flex p-0 col-12 col-lg-7 gap-2 gap-lg-3 pe-1 align-items-start {{{ if config.theme.mobileTopicTeasers }}}mb-2 mb-lg-0{{{ end }}}">
12
12
  <div class="flex-shrink-0 position-relative">
13
13
  <a class="d-inline-block text-decoration-none avatar-tooltip" title="{./user.displayname}" href="{{{ if ./user.userslug }}}{config.relative_path}/user/{./user.userslug}{{{ else }}}#{{{ end }}}">
14
- {buildAvatar(./user, "40px", true)}
14
+ {{buildAvatar(./user, "40px", true)}}
15
15
  </a>
16
16
  {{{ if showSelect }}}
17
17
  <div class="checkbox position-absolute top-100 start-50 translate-middle-x m-0 d-none d-lg-flex" style="max-width:max-content">
@@ -51,7 +51,7 @@
51
51
  {{{each ./icons}}}<span class="lh-1">{@value}</span>{{{end}}}
52
52
 
53
53
  {{{ if (!template.category || (cid != ./cid)) }}}
54
- {function.buildCategoryLabel, ./category, "a", "border"}
54
+ {{buildCategoryLabel(./category, "a", "border")}}
55
55
  {{{ end }}}
56
56
 
57
57
  <span data-tid="{./tid}" component="topic/tags" class="lh-1 tag-list d-flex flex-wrap gap-1 {{{ if !./tags.length }}}hidden{{{ end }}}">
@@ -114,12 +114,12 @@
114
114
  {{{ else }}}
115
115
  {{{ if ./teaser.pid }}}
116
116
  <div class="ps-2">
117
- <a href="{{{ if ./teaser.user.userslug }}}{config.relative_path}/user/{./teaser.user.userslug}{{{ else }}}#{{{ end }}}" class="text-decoration-none avatar-tooltip" title="{./teaser.user.displayname}">{buildAvatar(./teaser.user, "18px", true)}</a>
117
+ <a href="{{{ if ./teaser.user.userslug }}}{config.relative_path}/user/{./teaser.user.userslug}{{{ else }}}#{{{ end }}}" class="text-decoration-none avatar-tooltip" title="{./teaser.user.displayname}">{{buildAvatar(./teaser.user, "18px", true)}}</a>
118
118
  <a class="permalink text-muted timeago text-xs" href="{config.relative_path}/topic/{./slug}/{./teaser.index}" title="{./teaser.timestampISO}" aria-label="[[global:lastpost]]"></a>
119
119
  </div>
120
120
  <div class="post-content text-xs ps-2 line-clamp-sm-2 lh-sm text-break position-relative flex-fill">
121
121
  <a class="stretched-link" tabindex="-1" href="{config.relative_path}/topic/{./slug}/{./teaser.index}" aria-label="[[global:lastpost]]"></a>
122
- {./teaser.content}
122
+ {{./teaser.content}}
123
123
  </div>
124
124
  {{{ end }}}
125
125
  {{{ end }}}
@@ -1,5 +1,5 @@
1
1
  <li class="users-box registered-user text-center pb-3" data-uid="{users.uid}" style="width: 102px;">
2
- <a href="{config.relative_path}/user/{users.userslug}">{buildAvatar(users, "64px", true)}</a>
2
+ <a href="{config.relative_path}/user/{users.userslug}">{{buildAvatar(users, "64px", true)}}</a>
3
3
 
4
4
  <div class="user-info">
5
5
  <div class="text-nowrap text-truncate">
@@ -5,15 +5,7 @@
5
5
  </div>
6
6
  <div class="row mb-5">
7
7
  <div class="topic {{{ if widgets.sidebar.length }}}col-lg-9 col-sm-12{{{ else }}}col-lg-12{{{ end }}}" itemid="{url}" itemscope itemtype="https://schema.org/DiscussionForumPosting">
8
- <meta itemprop="headline" content="{escape(titleRaw)}">
9
- <meta itemprop="text" content="{escape(titleRaw)}">
10
- <meta itemprop="url" content="{url}">
11
- <meta itemprop="datePublished" content="{timestampISO}">
12
- <meta itemprop="dateModified" content="{lastposttimeISO}">
13
- <div itemprop="author" itemscope itemtype="https://schema.org/Person">
14
- <meta itemprop="name" content="{author.username}">
15
- {{{ if author.userslug }}}<meta itemprop="url" content="{config.relative_path}/user/{author.userslug}">{{{ end }}}
16
- </div>
8
+ <!-- IMPORT partials/topic/meta-tags.tpl -->
17
9
 
18
10
  <div class="topic-header sticky-top mb-3 bg-body">
19
11
  <div class="d-flex flex-wrap gap-3 border-bottom p-2">
@@ -40,7 +32,7 @@
40
32
  </a>
41
33
  {{{each icons}}}<span class="lh-1">{@value}</span>{{{end}}}
42
34
  </span>
43
- {function.buildCategoryLabel, category, "a", "border"}
35
+ {{buildCategoryLabel(category, "a", "border")}}
44
36
  <div data-tid="{./tid}" component="topic/tags" class="lh-1 tags tag-list d-flex flex-wrap hidden-xs hidden-empty gap-2"><!-- IMPORT partials/topic/tags.tpl --></div>
45
37
  <div class="d-flex gap-2" component="topic/stats"><!-- IMPORT partials/topic/stats.tpl --></div>
46
38
  {{{ if !feeds:disableRSS }}}
@@ -13,12 +13,12 @@
13
13
 
14
14
  <div class="category-header d-flex flex-column gap-2">
15
15
  <div class="d-flex gap-2 align-items-center mb-1 {{{ if config.theme.centerHeaderElements }}}justify-content-center{{{ end }}}">
16
- {buildCategoryIcon(@value, "40px", "rounded-1 flex-shrink-0")}
16
+ {{buildCategoryIcon(@value, "40px", "rounded-1 flex-shrink-0")}}
17
17
  <h1 class="tracking-tight fs-2 fw-semibold mb-0 text-center">[[world:name]]</h1>
18
18
  </div>
19
19
  {{{ if ./descriptionParsed }}}
20
20
  <p class="description text-secondary text-sm w-100 {{{ if config.theme.centerHeaderElements }}}text-center{{{ end }}}">
21
- {./descriptionParsed}
21
+ {{./descriptionParsed}}
22
22
  </p>
23
23
  {{{ end }}}
24
24
  </div>
@@ -39,14 +39,14 @@
39
39
  {{{ each categories }}}
40
40
  <li class="flex-grow-1 align-items-start d-flex gap-2 p-1 mb-2 position-relative">
41
41
  <div>
42
- {buildCategoryIcon(@value, "24px", "rounded-1")}
42
+ {{buildCategoryIcon(@value, "24px", "rounded-1")}}
43
43
  </div>
44
44
  <div class="d-grid gap-0">
45
45
  <div class="title fw-semibold">
46
46
  <a class="text-reset stretched-link" href="{{{ if ./link }}}{./link}{{{ else }}}{config.relative_path}/category/{./slug}{{{ end }}}" itemprop="url">{../name}</a>
47
47
  </div>
48
48
  {{{ if ./descriptionParsed }}}
49
- <div class="description text-muted text-xs w-100 line-clamp-sm-5">{./descriptionParsed}</div>
49
+ <div class="description text-muted text-xs w-100 line-clamp-sm-5">{{./descriptionParsed}}</div>
50
50
  {{{ end }}}
51
51
  </div>
52
52
  </li>