feat(element,ipub): new element package to take care of XML Marshalling and Unmarshalling

This commit is contained in:
Guz
2025-05-22 11:03:43 -03:00
parent 1466c35e39
commit c05445f702

22
ipub/element/sections.go Normal file
View File

@@ -0,0 +1,22 @@
package element
import "encoding/xml"
type Section struct {
XMLName xml.Name `xml:"html"`
Body Body `xml:"body"`
}
type Body struct {
XMLName xml.Name `xml:"body"`
Test string `xml:"test,attr"`
}
type Paragraph struct {
XMLName xml.Name `xml:"p"`
DataElement ElementKind `xml:"data-ipub-element,attr"`
Test string `xml:"test,attr"`
Text string `xml:",chardata"`
}