nodebb-plugin-composer-default 10.3.28 → 10.3.31

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-plugin-composer-default",
3
- "version": "10.3.28",
3
+ "version": "10.3.31",
4
4
  "description": "Default composer for NodeBB",
5
5
  "main": "library.js",
6
6
  "repository": {
@@ -26,7 +26,7 @@
26
26
  },
27
27
  "readmeFilename": "README.md",
28
28
  "nbbpm": {
29
- "compatibility": "^4.5.0"
29
+ "compatibility": "^4.12.0"
30
30
  },
31
31
  "dependencies": {
32
32
  "screenfull": "^5.0.2",
@@ -95,4 +95,20 @@ $(document).ready(function () {
95
95
  composer.enhance(data.container);
96
96
  });
97
97
  });
98
+
99
+ $(window).on('action:composer.thumbs.updateCount', function (ev, data) {
100
+ require(['composer'], function (composer) {
101
+ const { uuid } = data;
102
+ const postContainer = $(`[component="composer"][data-uuid="${uuid}"]`);
103
+ composer.updateThumbCount(uuid, postContainer);
104
+ });
105
+ });
106
+
107
+ $(window).on('action:composer.updateFormattingBtnBadgeCount', (ev, data) => {
108
+ require(['composer'], (composer) => {
109
+ const { uuid, formatName, count } = data;
110
+ const postContainer = $(`[component="composer"][data-uuid="${uuid}"]`);
111
+ composer.updateFormattingBtnBadgeCount(postContainer, formatName, count);
112
+ });
113
+ });
98
114
  });
@@ -505,7 +505,7 @@ define('composer', [
505
505
  }
506
506
  composerTemplate = $(composerTemplate);
507
507
 
508
- composerTemplate.find('.title').each(function () {
508
+ composerTemplate.find('.title, textarea.write').each(function () {
509
509
  $(this).text(translator.unescape($(this).text()));
510
510
  });
511
511