MCPcopy Index your code
hub / github.com/simstudioai/sim / parseFontInfo

Function parseFontInfo

apps/sim/lib/pptx-renderer/model/theme.ts:52–58  ·  view source on GitHub ↗

* Parse font info from a majorFont or minorFont node. * Extracts typeface attributes from latin, ea, and cs child elements.

(fontNode: SafeXmlNode)

Source from the content-addressed store, hash-verified

50 * Extracts typeface attributes from latin, ea, and cs child elements.
51 */
52function parseFontInfo(fontNode: SafeXmlNode): { latin: string; ea: string; cs: string } {
53 return {
54 latin: fontNode.child('latin').attr('typeface') ?? '',
55 ea: fontNode.child('ea').attr('typeface') ?? '',
56 cs: fontNode.child('cs').attr('typeface') ?? '',
57 }
58}
59
60/**
61 * Parse a theme XML root (`a:theme`) into ThemeData.

Callers 1

parseThemeFunction · 0.85

Calls 2

attrMethod · 0.80
childMethod · 0.80

Tested by

no test coverage detected