prototyped svg reports
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
package svg
|
||||
|
||||
type (
|
||||
Width struct {
|
||||
*LengthAttr[WidthTag]
|
||||
}
|
||||
WidthP struct {
|
||||
PercentageAttr[WidthTag]
|
||||
}
|
||||
|
||||
WidthTag struct{}
|
||||
)
|
||||
|
||||
func (l *Length) AsWidth() Width {
|
||||
return Width{LengthAttr: (*LengthAttr[WidthTag])(l)}
|
||||
}
|
||||
|
||||
func (p Percentage) AsWidth() WidthP {
|
||||
return WidthP{PercentageAttr: (PercentageAttr[WidthTag])(p)}
|
||||
}
|
||||
|
||||
func (WidthTag) PrintTag() string {
|
||||
return "width"
|
||||
}
|
||||
Reference in New Issue
Block a user