src/element.ts: update