xmoj-script 1.2.42 → 1.2.44

Sign up to get free protection for your applications and to get access to all the features.
package/Update.json CHANGED
@@ -2252,6 +2252,28 @@
2252
2252
  }
2253
2253
  ],
2254
2254
  "Notes": "No release notes were provided for this release."
2255
+ },
2256
+ "1.2.43": {
2257
+ "UpdateDate": 1723097609941,
2258
+ "Prerelease": true,
2259
+ "UpdateContents": [
2260
+ {
2261
+ "PR": 664,
2262
+ "Description": "fix reply infinite looping"
2263
+ }
2264
+ ],
2265
+ "Notes": "No release notes were provided for this release."
2266
+ },
2267
+ "1.2.44": {
2268
+ "UpdateDate": 1723098260973,
2269
+ "Prerelease": true,
2270
+ "UpdateContents": [
2271
+ {
2272
+ "PR": 665,
2273
+ "Description": "fix replying"
2274
+ }
2275
+ ],
2276
+ "Notes": "No release notes were provided for this release."
2255
2277
  }
2256
2278
  }
2257
2279
  }
package/XMOJ.user.js CHANGED
@@ -1,6 +1,6 @@
1
1
  // ==UserScript==
2
2
  // @name XMOJ
3
- // @version 1.2.42
3
+ // @version 1.2.44
4
4
  // @description XMOJ增强脚本
5
5
  // @author @XMOJ-Script-dev, @langningchen and the community
6
6
  // @namespace https://github/langningchen
@@ -4756,11 +4756,9 @@ int main()
4756
4756
  ReplyButton.innerText = "回复";
4757
4757
  ReplyButton.addEventListener("click", () => {
4758
4758
  let Content = Replies[i].Content;
4759
- while (Content.startsWith(">")) {
4760
- Content = Content.substring(Content.indexOf("\n") + 1);
4761
- }
4762
- Content = Content.trim();
4763
4759
  Content = Content.split("\n").map((Line) => {
4760
+ return Line.startsWith(">>") ? Line.substring(1).trim() : Line.trim();
4761
+ }).join("\n").split("\n").map((Line) => {
4764
4762
  return "> " + Line;
4765
4763
  }).join("\n");
4766
4764
  ContentElement.value += Content + `\n\n@${Replies[i].UserID} `;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "xmoj-script",
3
- "version": "1.2.42",
3
+ "version": "1.2.44",
4
4
  "description": "an improvement script for xmoj.tech",
5
5
  "main": "AddonScript.js",
6
6
  "scripts": {