MCPcopy Create free account
hub / github.com/Xu22Web/tech-study-js / handleBlankInputRand

Function handleBlankInputRand

tech-study.js:3038–3053  ·  view source on GitHub ↗

* @description 处理填空随机

()

Source from the content-addressed store, hash-verified

3036 * @description 处理填空随机
3037 */
3038async function handleBlankInputRand() {
3039 // 所有填空
3040 const blanks = $$('.blank');
3041 if (blanks.length) {
3042 // 输入事件
3043 const inputEvent = new Event('input', {
3044 bubbles: true,
3045 });
3046 blanks.forEach((blank) => {
3047 // 设置答案
3048 blank.setAttribute('value', '答案');
3049 // 触发输入input
3050 blank.dispatchEvent(inputEvent);
3051 });
3052 }
3053}
3054/**
3055 * @description 暂停锁
3056 */

Callers 1

doingExamFunction · 0.70

Calls 1

$$Function · 0.70

Tested by

no test coverage detected