学习通/MOOC等 隐藏答案 Hide Answer

添加一个切换答案按钮,点击可显示/隐藏答案

安装此脚本?
作者推荐脚本

您可能也喜欢中国大学MOOC隐藏答案

安装此脚本
  1. // ==UserScript==
  2. // @name 学习通/MOOC等 隐藏答案 Hide Answer
  3. // @namespace https://github.com/lcandy2/user.js/tree/main/generics/hide-answer
  4. // @version 2.3.2
  5. // @author 甜檸Cirtron (lcandy2)
  6. // @description 添加一个切换答案按钮,点击可显示/隐藏答案
  7. // @license AGPL-3.0-or-later
  8. // @copyright lcandy2 All Rights Reserved
  9. // @homepage https://gf.qytechs.cn/scripts/469779
  10. // @homepageURL https://gf.qytechs.cn/scripts/469779
  11. // @match *://mooc1.chaoxing.com/mooc*
  12. // @match *://mooc1.chaoxing.com/exam*
  13. // @require https://registry.npmmirror.com/vue/3.4.27/files/dist/vue.global.prod.js
  14. // @require data:application/javascript,%3Bwindow.Vue%3DVue%3B
  15. // ==/UserScript==
  16.  
  17. (function (vue) {
  18. 'use strict';
  19.  
  20. const chaoxingMooc = "mooc1.chaoxing.com/mooc";
  21. const chaoxingExam = "mooc1.chaoxing.com/exam";
  22. const UrlDetection = () => {
  23. const url = window.location.href;
  24. if (url.includes(chaoxingMooc) || url.includes(chaoxingExam)) {
  25. if (url.includes("work/view") || url.includes("test/reVersionPaperMarkContentNew")) {
  26. return "chaoxing-mooc";
  27. }
  28. }
  29. };
  30. var oe = "M8.27,3L3,8.27V15.73L8.27,21H15.73C17.5,19.24 21,15.73 21,15.73V8.27L15.73,3M9.1,5H14.9L19,9.1V14.9L14.9,19H9.1L5,14.9V9.1M11,15H13V17H11V15M11,7H13V13H11V7", ae = "M12,2L1,21H23M12,6L19.53,19H4.47M11,10V14H13V10M11,16V18H13V16", re = "M12 2C6.5 2 2 6.5 2 12S6.5 22 12 22 22 17.5 22 12 17.5 2 12 2M10 17L5 12L6.41 10.59L10 14.17L17.59 6.58L19 8L10 17Z", ne = "M19,6.41L17.59,5L12,10.59L6.41,5L5,6.41L10.59,12L5,17.59L6.41,19L12,13.41L17.59,19L19,17.59L13.41,12L19,6.41Z", ie = "M11,9H13V7H11M12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4C16.41,4 20,7.59 20,12C20,16.41 16.41,20 12,20M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M11,17H13V11H11V17Z";
  31. const le = {
  32. transform: "rotate(var(--r, 0deg)) scale(var(--sx, 1), var(--sy, 1))"
  33. }, E = {
  34. fill: "currentColor"
  35. }, z = {
  36. mdi: {
  37. size: 24,
  38. viewbox: "0 0 24 24"
  39. },
  40. "simple-icons": {
  41. size: 24,
  42. viewbox: "0 0 24 24"
  43. },
  44. default: {
  45. size: 0,
  46. viewbox: "0 0 0 0"
  47. }
  48. }, N = {
  49. name: "icon",
  50. props: {
  51. type: {
  52. type: String,
  53. default: "mdi"
  54. },
  55. faIcon: {
  56. type: Object,
  57. default: null
  58. },
  59. path: {
  60. type: [String, Object, Array]
  61. },
  62. size: {
  63. type: [Number, String],
  64. default: 24
  65. },
  66. viewbox: String,
  67. flip: {
  68. type: String,
  69. validator: (t) => ["horizontal", "vertical", "both"].includes(t)
  70. },
  71. rotate: {
  72. type: [Number, String],
  73. default: 0
  74. }
  75. },
  76. setup(t) {
  77. if (!t.path && !t.faIcon)
  78. return console.warn("vue3-icon requires either a 'path' or an 'fa-icon' property"), () => vue.h("div");
  79. const s = vue.computed(() => {
  80. var d;
  81. return ((d = t.faIcon) == null ? void 0 : d.prefix) || t.type;
  82. }), o = vue.computed(() => parseInt(t.rotate, 10)), e = vue.computed(() => z[s.value] || z.default), r = vue.computed(() => parseInt(t.size, 10) || e.value.size), i = vue.computed(() => t.faIcon ? `0 0 ${t.faIcon.icon[0]} ${t.faIcon.icon[1]}` : false), l = vue.computed(() => i.value || t.viewbox || e.value.viewbox), f = vue.computed(() => ({
  83. ...le,
  84. "--sx": ["both", "horizontal"].includes(t.flip) ? "-1" : "1",
  85. "--sy": ["both", "vertical"].includes(t.flip) ? "-1" : "1",
  86. "--r": isNaN(o.value) ? o.value : o.value + "deg"
  87. })), m = vue.computed(() => {
  88. var d;
  89. return t.faIcon ? (d = t.faIcon) == null ? void 0 : d.icon[4] : t.type === "simple-icons" && typeof t.path == "object" ? t.path.path : t.path;
  90. }), p = vue.computed(() => s.value === "fad" ? (console.warn("vue3-icon does not currently support Duotone FontAwesome icons"), vue.h("path")) : Array.isArray(t.path) ? vue.h(
  91. "g",
  92. { style: { ...E } },
  93. t.path.map((d) => typeof d == "string" ? vue.h("path", { d }) : vue.h("path", { ...d }))
  94. ) : vue.h("path", { d: m.value, style: { ...E } }));
  95. return () => vue.h(
  96. "svg",
  97. {
  98. style: f.value,
  99. class: ["vue3-icon"],
  100. width: r.value,
  101. height: r.value,
  102. viewBox: l.value
  103. },
  104. [p.value]
  105. );
  106. }
  107. }, ue = { class: "vue3-snackbar-message-wrapper" }, ce = {
  108. key: 0,
  109. class: "vue3-snackbar-message-icon"
  110. }, de = { class: "vue3-snackbar-message-content" }, fe = {
  111. key: 0,
  112. class: "vue3-snackbar-message-badge"
  113. }, me = { class: "vue3-snackbar-message-title" }, pe = {
  114. key: 0,
  115. class: "vue3-snackbar-message-additional"
  116. }, ge = /* @__PURE__ */ vue.createElementVNode("div", { class: "spacer" }, null, -1), ve = { class: "vue3-snackbar-message-close" }, be = {
  117. __name: "Vue3SnackbarMessage",
  118. props: {
  119. borderClass: {
  120. type: String,
  121. default: ""
  122. },
  123. message: {
  124. type: Object,
  125. default: () => ({})
  126. },
  127. messageClass: {
  128. type: String,
  129. default: ""
  130. },
  131. dense: {
  132. type: Boolean,
  133. default: false
  134. }
  135. },
  136. emits: ["dismiss"],
  137. setup(t, { emit: s }) {
  138. const o = s, e = t;
  139. let r = null, i = null, l = vue.ref(false);
  140. const f = () => {
  141. const a = !e.message.duration && !e.message.dismissible ? 4e3 : e.message.duration;
  142. r = setTimeout(p, a);
  143. };
  144. vue.onMounted(() => {
  145. f();
  146. }), vue.watch(
  147. () => e.message.count,
  148. (a) => {
  149. if (a === 1)
  150. return false;
  151. clearTimeout(r), clearTimeout(i), i = setTimeout(() => {
  152. l.value = false;
  153. }, 1e3), l.value = true, f();
  154. }
  155. );
  156. const m = () => {
  157. r && clearTimeout(r), p();
  158. }, p = () => {
  159. o("dismiss", e.message);
  160. }, d = {
  161. success: {
  162. path: re
  163. },
  164. info: {
  165. path: ie
  166. },
  167. warning: {
  168. path: ae
  169. },
  170. error: {
  171. path: oe
  172. }
  173. }, n = vue.computed(() => {
  174. const a = d[e.message.type];
  175. return a ? (a.type = "mdi", a) : e.message.icon && typeof e.message.icon == "object" ? e.message.icon : {
  176. path: "",
  177. type: "default"
  178. };
  179. });
  180. return (a, u) => (vue.openBlock(), vue.createElementBlock("article", {
  181. class: vue.normalizeClass(["vue3-snackbar-message", [
  182. e.message.type || "custom",
  183. e.messageClass,
  184. e.borderClass,
  185. {
  186. "has-background": e.message.background,
  187. "has-border": e.borderClass,
  188. "is-dense": e.dense,
  189. "shake-baby-shake": vue.unref(l)
  190. }
  191. ]]),
  192. style: vue.normalizeStyle({
  193. "--message-background": e.message.background,
  194. "--message-text-color": e.message.textColor,
  195. "--message-icon-color": e.message.iconColor
  196. })
  197. }, [
  198. vue.renderSlot(a.$slots, "message-inner", {
  199. message: e.message
  200. }, () => [
  201. vue.createElementVNode("div", ue, [
  202. n.value ? (vue.openBlock(), vue.createElementBlock("div", ce, [
  203. vue.renderSlot(a.$slots, "message-icon", {
  204. message: e.message,
  205. icon: n.value
  206. }, () => [
  207. vue.createVNode(vue.unref(N), vue.mergeProps(n.value, { role: "img" }), null, 16)
  208. ])
  209. ])) : vue.createCommentVNode("", true),
  210. vue.createElementVNode("div", de, [
  211. vue.renderSlot(a.$slots, "message-badge", {
  212. message: e.message,
  213. count: e.message.count
  214. }, () => [
  215. e.message.count > 1 ? (vue.openBlock(), vue.createElementBlock("div", fe, vue.toDisplayString(e.message.count), 1)) : vue.createCommentVNode("", true)
  216. ]),
  217. vue.renderSlot(a.$slots, "message-content", {
  218. message: e.message,
  219. title: e.message.title,
  220. text: e.message.text
  221. }, () => [
  222. vue.createElementVNode("div", me, vue.toDisplayString(e.message.title || e.message.text), 1),
  223. e.message.title && e.message.text ? (vue.openBlock(), vue.createElementBlock("div", pe, vue.toDisplayString(e.message.text), 1)) : vue.createCommentVNode("", true)
  224. ])
  225. ]),
  226. ge,
  227. vue.createElementVNode("div", ve, [
  228. vue.renderSlot(a.$slots, "message-close-icon", {
  229. message: e.message,
  230. isDimissible: e.message.dismissible,
  231. isDismissible: e.message.dismissible,
  232. dismiss: m
  233. }, () => [
  234. e.message.dismissible !== false ? (vue.openBlock(), vue.createElementBlock("button", {
  235. key: 0,
  236. onClick: m
  237. }, [
  238. vue.createVNode(vue.unref(N), {
  239. type: "mdi",
  240. path: vue.unref(ne)
  241. }, null, 8, ["path"])
  242. ])) : vue.createCommentVNode("", true)
  243. ])
  244. ])
  245. ])
  246. ])
  247. ], 6));
  248. }
  249. }, ye = typeof window < "u" ? HTMLElement : Object, he = {
  250. /* ******************************************
  251. * LOCATION PROPS
  252. ****************************************** */
  253. top: {
  254. type: Boolean,
  255. default: false
  256. },
  257. bottom: {
  258. type: Boolean,
  259. default: false
  260. },
  261. left: {
  262. type: Boolean,
  263. default: false
  264. },
  265. right: {
  266. type: Boolean,
  267. default: false
  268. },
  269. /* ******************************************
  270. * COLOUR PROPS
  271. ****************************************** */
  272. success: {
  273. type: String,
  274. default: "#4caf50"
  275. },
  276. error: {
  277. type: String,
  278. default: "#ff5252"
  279. },
  280. warning: {
  281. type: String,
  282. default: "#fb8c00"
  283. },
  284. info: {
  285. type: String,
  286. default: "#2196f3"
  287. },
  288. messageTextColor: {
  289. type: String,
  290. default: "#fff"
  291. },
  292. messageIconColor: {
  293. type: String,
  294. default: "currentColor"
  295. },
  296. /* ******************************************
  297. * OTHER PROPS
  298. ****************************************** */
  299. attach: {
  300. type: [String, ye],
  301. default: "body"
  302. },
  303. border: {
  304. type: String,
  305. default: "",
  306. validator: (t) => ["top", "bottom", "left", "right", ""].includes(t)
  307. },
  308. backgroundOpacity: {
  309. type: [String, Number],
  310. default: 0.12,
  311. validator: (t) => !isNaN(parseFloat(t)) && isFinite(t)
  312. },
  313. backgroundColor: {
  314. type: String,
  315. default: "currentColor"
  316. },
  317. baseBackgroundColor: {
  318. type: String,
  319. default: "#fff"
  320. },
  321. duration: {
  322. type: [Number, String],
  323. default: null
  324. },
  325. messageClass: {
  326. type: String
  327. },
  328. zIndex: {
  329. type: Number,
  330. default: 1e4
  331. },
  332. dense: {
  333. type: Boolean,
  334. default: false
  335. },
  336. reverse: {
  337. type: Boolean,
  338. default: false
  339. },
  340. groups: {
  341. type: Boolean,
  342. default: false
  343. },
  344. shadow: {
  345. type: Boolean,
  346. default: false
  347. }
  348. };
  349. function Se(t) {
  350. return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t;
  351. }
  352. var V = { exports: {} };
  353. function B() {
  354. }
  355. B.prototype = {
  356. on: function(t, s, o) {
  357. var e = this.e || (this.e = {});
  358. return (e[t] || (e[t] = [])).push({
  359. fn: s,
  360. ctx: o
  361. }), this;
  362. },
  363. once: function(t, s, o) {
  364. var e = this;
  365. function r() {
  366. e.off(t, r), s.apply(o, arguments);
  367. }
  368. return r._ = s, this.on(t, r, o);
  369. },
  370. emit: function(t) {
  371. var s = [].slice.call(arguments, 1), o = ((this.e || (this.e = {}))[t] || []).slice(), e = 0, r = o.length;
  372. for (e; e < r; e++)
  373. o[e].fn.apply(o[e].ctx, s);
  374. return this;
  375. },
  376. off: function(t, s) {
  377. var o = this.e || (this.e = {}), e = o[t], r = [];
  378. if (e && s)
  379. for (var i = 0, l = e.length; i < l; i++)
  380. e[i].fn !== s && e[i].fn._ !== s && r.push(e[i]);
  381. return r.length ? o[t] = r : delete o[t], this;
  382. }
  383. };
  384. V.exports = B;
  385. V.exports.TinyEmitter = B;
  386. var ke = V.exports, Ce = ke, we = new Ce();
  387. const _ = /* @__PURE__ */ Se(we), C = {
  388. $on: (...t) => _.on(...t),
  389. $once: (...t) => _.once(...t),
  390. $off: (...t) => _.off(...t),
  391. $emit: (...t) => _.emit(...t)
  392. }, b = vue.ref([]), W = Symbol();
  393. function Ee() {
  394. const t = vue.inject(W);
  395. if (!t)
  396. throw new Error("No Snackbar provided!");
  397. return t;
  398. }
  399. const ze = {
  400. install: (t, s = {}) => {
  401. const { disableGlobals: o = false } = s, e = {
  402. add: (r) => {
  403. C.$emit("add", r);
  404. },
  405. clear: () => {
  406. C.$emit("clear");
  407. }
  408. };
  409. o !== true && (t.config.globalProperties.$snackbar = e, typeof window < "u" && (window.$snackbar = e)), t.provide(W, e);
  410. }
  411. };
  412. function _e(t) {
  413. return vue.getCurrentScope() ? (vue.onScopeDispose(t), true) : false;
  414. }
  415. function P(t) {
  416. return typeof t == "function" ? t() : vue.unref(t);
  417. }
  418. const Z = typeof window < "u" && typeof document < "u";
  419. typeof WorkerGlobalScope < "u" && globalThis instanceof WorkerGlobalScope;
  420. const Me = (t) => t != null;
  421. function Le(t) {
  422. return vue.getCurrentInstance();
  423. }
  424. function $e(t, s = true, o) {
  425. Le() ? vue.onMounted(t, o) : s ? t() : vue.nextTick(t);
  426. }
  427. function xe(t) {
  428. var s;
  429. const o = P(t);
  430. return (s = o == null ? void 0 : o.$el) != null ? s : o;
  431. }
  432. const Ve = Z ? window : void 0, Be = Z ? window.document : void 0;
  433. function Oe() {
  434. const t = vue.ref(false), s = vue.getCurrentInstance();
  435. return s && vue.onMounted(() => {
  436. t.value = true;
  437. }, s), t;
  438. }
  439. function Te(t) {
  440. const s = Oe();
  441. return vue.computed(() => (s.value, !!t()));
  442. }
  443. function Ae(t, s, o = {}) {
  444. const { window: e = Ve, ...r } = o;
  445. let i;
  446. const l = Te(() => e && "MutationObserver" in e), f = () => {
  447. i && (i.disconnect(), i = void 0);
  448. }, m = vue.computed(() => {
  449. const a = P(t), u = (Array.isArray(a) ? a : [a]).map(xe).filter(Me);
  450. return new Set(u);
  451. }), p = vue.watch(
  452. () => m.value,
  453. (a) => {
  454. f(), l.value && a.size && (i = new MutationObserver(s), a.forEach((u) => i.observe(u, r)));
  455. },
  456. { immediate: true, flush: "post" }
  457. ), d = () => i == null ? void 0 : i.takeRecords(), n = () => {
  458. f(), p();
  459. };
  460. return _e(n), {
  461. isSupported: l,
  462. stop: n,
  463. takeRecords: d
  464. };
  465. }
  466. function He(t = {}) {
  467. const {
  468. document: s = Be,
  469. selector: o = "html",
  470. observe: e = false,
  471. initialValue: r = "ltr"
  472. } = t;
  473. function i() {
  474. var f, m;
  475. return (m = (f = s == null ? void 0 : s.querySelector(o)) == null ? void 0 : f.getAttribute("dir")) != null ? m : r;
  476. }
  477. const l = vue.ref(i());
  478. return $e(() => l.value = i()), e && s && Ae(
  479. s.querySelector(o),
  480. () => l.value = i(),
  481. { attributes: true }
  482. ), vue.computed({
  483. get() {
  484. return l.value;
  485. },
  486. set(f) {
  487. var m, p;
  488. l.value = f, s && (l.value ? (m = s.querySelector(o)) == null || m.setAttribute("dir", l.value) : (p = s.querySelector(o)) == null || p.removeAttribute("dir"));
  489. }
  490. });
  491. }
  492. const Ne = {
  493. __name: "Vue3Snackbar",
  494. props: { ...he },
  495. emits: ["added", "dismissed", "removed", "cleared"],
  496. setup(t, { emit: s }) {
  497. const o = He(), e = t, r = s, i = vue.computed(() => ({
  498. "is-top": e.top,
  499. "is-bottom": e.top === false && e.bottom,
  500. "is-left": e.left,
  501. "is-right": e.left === false && e.right,
  502. "is-middle": e.top === false && e.bottom === false,
  503. "is-centre": e.left === false && e.right === false,
  504. "has-shadow": e.shadow,
  505. "is-rtl": o.value === "rtl"
  506. })), l = vue.computed(() => ({
  507. "--success-colour": e.success,
  508. "--error-colour": e.error,
  509. "--warning-colour": e.warning,
  510. "--info-colour": e.info,
  511. "--snackbar-zindex": e.zIndex,
  512. "--background-opacity": e.backgroundOpacity,
  513. "--background-color": e.backgroundColor,
  514. "--base-background-color": e.baseBackgroundColor,
  515. "--message-text-color": e.messageTextColor,
  516. "--message-icon-color": e.messageIconColor
  517. })), f = vue.computed(() => e.border ? `border-${e.border}` : ""), m = (n) => Math.abs(n.split("").reduce((a, u) => (a << 5) - a + u.charCodeAt(0) | 0, 0));
  518. let p = 1;
  519. C.$on("add", (n) => {
  520. r("added", n), n.group || (n.group = m(`${n.type}${n.title}${n.text}`).toString(16)), e.duration && !n.duration && n.duration !== 0 && (n.duration = +e.duration);
  521. const a = n.group && b.value.find((u) => u.group === n.group);
  522. if (e.groups === false || !a) {
  523. const u = {
  524. ...n,
  525. id: p,
  526. count: 1
  527. };
  528. e.reverse ? b.value.unshift(u) : b.value.push(u), p++;
  529. } else
  530. a.count++;
  531. }), C.$on("clear", () => {
  532. r("cleared"), b.value = [];
  533. }), vue.onUnmounted(() => {
  534. C.$off("add"), C.$off("clear");
  535. });
  536. const d = (n, a = false) => {
  537. r(a ? "dismissed" : "removed", n), b.value = b.value.filter((u) => u.id !== n.id);
  538. };
  539. return (n, a) => (vue.openBlock(), vue.createBlock(vue.Teleport, {
  540. to: e.attach
  541. }, [
  542. vue.createElementVNode("section", {
  543. id: "vue3-snackbar--container",
  544. class: vue.normalizeClass([[i.value], "vue3-snackbar"]),
  545. style: vue.normalizeStyle(l.value)
  546. }, [
  547. vue.createVNode(vue.TransitionGroup, {
  548. name: "vue3-snackbar-message",
  549. tag: "div"
  550. }, {
  551. default: vue.withCtx(() => [
  552. (vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(vue.unref(b), (u) => (vue.openBlock(), vue.createBlock(be, {
  553. key: u.id,
  554. message: u,
  555. "message-class": e.messageClass,
  556. dense: e.dense,
  557. "border-class": f.value,
  558. onDismiss: a[0] || (a[0] = (O) => d(O, true))
  559. }, vue.createSlots({ _: 2 }, [
  560. vue.renderList(n.$slots, (O, T) => ({
  561. name: T,
  562. fn: vue.withCtx((R) => [
  563. vue.renderSlot(n.$slots, T, vue.mergeProps({ ref_for: true }, R))
  564. ])
  565. }))
  566. ]), 1032, ["message", "message-class", "dense", "border-class"]))), 128))
  567. ]),
  568. _: 3
  569. })
  570. ], 6)
  571. ], 8, ["to"]));
  572. }
  573. };
  574. const _sfc_main = /* @__PURE__ */ vue.defineComponent({
  575. __name: "chaoxing-mooc",
  576. setup(__props) {
  577. const snackbar = Ee();
  578. const elements = Array.from(
  579. document.getElementsByClassName("mark_answer")
  580. );
  581. const isHide = vue.ref(false);
  582. const toggleHide = () => {
  583. const value = isHide.value;
  584. snackbar.clear();
  585. snackbar.add({
  586. type: value ? "info" : "success",
  587. title: value ? "答案已显示" : "答案已隐藏",
  588. text: '你还可以按下 "H" 键来切换答案的显示状态。'
  589. });
  590. elements.forEach((element) => {
  591. element.style.visibility = isHide.value ? "visible" : "hidden";
  592. });
  593. isHide.value = !isHide.value;
  594. };
  595. const keydownHandler = (event) => {
  596. if (event.key === "h" || event.key === "H") {
  597. toggleHide();
  598. }
  599. };
  600. vue.onMounted(() => {
  601. window.addEventListener("keydown", keydownHandler);
  602. });
  603. vue.onUnmounted(() => {
  604. window.removeEventListener("keydown", keydownHandler);
  605. });
  606. return (_ctx, _cache) => {
  607. return vue.openBlock(), vue.createElementBlock(vue.Fragment, null, [
  608. vue.createElementVNode("a", {
  609. href: "javascript:;",
  610. onClick: toggleHide,
  611. class: "fl",
  612. tabindex: "0",
  613. role: "button"
  614. }, vue.toDisplayString(isHide.value ? "显示答案 (H)" : "隐藏答案 (H)"), 1),
  615. vue.createVNode(vue.unref(Ne), {
  616. top: "",
  617. duration: 0,
  618. border: "left",
  619. shadow: "",
  620. dense: "",
  621. reverse: ""
  622. })
  623. ], 64);
  624. };
  625. }
  626. });
  627. const appendChaoxingMoocButton = () => {
  628. const app = vue.createApp(_sfc_main);
  629. app.use(ze);
  630. const targetElement = document.querySelector(".subNav");
  631. if (targetElement) {
  632. const css = document.createElement("link");
  633. css.rel = "stylesheet";
  634. css.href = "https://unpkg.zhimg.com/vue3-snackbar@2.2.2/dist/style.css";
  635. document.head.appendChild(css);
  636. const toggleButton = document.createElement("div");
  637. toggleButton.className = "sub-button fr";
  638. toggleButton.id = "submitFocus";
  639. toggleButton.setAttribute("tabIndex", "-1");
  640. targetElement.appendChild(toggleButton);
  641. app.mount(toggleButton);
  642. }
  643. };
  644. const urlDetection = UrlDetection();
  645. if (urlDetection === "chaoxing-mooc") {
  646. appendChaoxingMoocButton();
  647. }
  648.  
  649. })(Vue);

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址