MCPcopy Index your code
hub / github.com/iChochy/NCE / renderUnitSelect

Method renderUnitSelect

js/ReadingSystem.js:266–274  ·  view source on GitHub ↗

* 渲染单元下拉选择器

()

Source from the content-addressed store, hash-verified

264 * 渲染单元下拉选择器
265 */
266 renderUnitSelect() {
267 if (!this.dom.unitSelect) return;
268
269 const options = this.state.units
270 .map((unit, index) => `<option value="${index}">${unit.title}</option>`)
271 .join('');
272
273 setHTML(this.dom.unitSelect, options);
274 }
275
276 /**
277 * 从 localStorage 恢复上次学习的单元

Callers 1

applyBookChangeMethod · 0.95

Calls 1

setHTMLFunction · 0.90

Tested by

no test coverage detected