Files
docx-js/src/file/paragraph/math/n-ary/math-accent-character.ts

13 lines
453 B
TypeScript
Raw Normal View History

2019-08-20 20:40:40 +01:00
// http://www.datypic.com/sc/ooxml/e-m_chr-1.html
import { BuilderElement, XmlComponent } from "@file/xml-components";
2019-08-20 20:40:40 +01:00
type MathAccentCharacterOptions = { readonly accent: string };
2019-08-20 20:40:40 +01:00
export const createMathAccentCharacter = ({ accent }: MathAccentCharacterOptions): XmlComponent =>
new BuilderElement<MathAccentCharacterOptions>({
name: "m:chr",
attributes: {
accent: { key: "m:val", value: accent },
},
});