cyp/app/js/lib/search.js

21 lines
432 B
JavaScript
Raw Normal View History

2019-03-31 06:15:32 +08:00
import * as html from "./html.js";
export function normalize(str) {
// FIXME diac/translit
return str.toLowerCase();
}
export default class Search extends EventTarget {
constructor(parent) {
super();
this._node = html.node("div", {className:"search"});
let icon = html.icon("magnify", this._node);
}
getNode() { return this._node; }
getValue() { return this._input.value; }
reset() { this._input.value = ""; }
}