skin-dt-32 0.0.78 → 0.0.81

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 (2) hide show
  1. package/general.js +9 -3
  2. package/package.json +1 -1
package/general.js CHANGED
@@ -846,9 +846,15 @@ document.addEventListener('DOMContentLoaded', () => {
846
846
  document.addEventListener('forumReady', () => {
847
847
  if (document.querySelector('.forum-forum')) {
848
848
  [].forEach.call(document.querySelectorAll('.forum-forum'), (item) => {
849
- console.log(item.querySelector('.forum-last > strong'));
850
- if (item.querySelector('.forum-last > strong')) {
851
- item.querySelector('.lastpost-name').insertAdjacentHTML('beforeend', item.querySelector('.forum-last > strong').outerHTML);
849
+ if (item.querySelector('.forum-last .is-hidden-desktop > strong')) {
850
+ item.querySelector('.lastpost-name').insertAdjacentHTML('beforeend', item.querySelector('.forum-last .is-hidden-desktop > strong').outerHTML);
851
+ }
852
+
853
+ if (item.querySelector('.forum-last .is-hidden-desktop .lastpost-link')) {
854
+ const postLink = item.querySelector('.forum-last .is-hidden-desktop .lastpost-link').outerHTML;
855
+ const postDate = item.querySelector('.forum-last .is-hidden-desktop').textContent.split('</strong>, ')[1];
856
+
857
+ item.querySelector('.forum-last .is-hidden-desktop .lastpost-link').insertAdjacentHTML('beforeend', `${postLink}, ${postDate}`);
852
858
  }
853
859
  });
854
860
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "skin-dt-32",
3
- "version": "0.0.78",
3
+ "version": "0.0.81",
4
4
  "main": "readme.md",
5
5
  "scripts": {
6
6
  "test": "echo \"Error: no test specified\" && exit 1"