@@ -1141,24 +1141,18 @@ gatherAttrRecursive classes node has transform styles attrs children elementAttr
1141 gatherAttrRecursive classes (addNodeName "h6" node) has transform styles attrs children remaining
1141 gatherAttrRecursive classes (addNodeName "h6" node) has transform styles attrs children remaining
1143 Paragraph ->
1143 Paragraph ->
1144− let
1144+ -- previously we rendered a <p> tag, though apparently this invalidates the html if it has <div>s inside.
1145− newNode =
1145+ -- Since we can't guaranteee that there are no divs, we need another strategy.
1146− case node of
1146+ -- While it's not documented in many places, there apparently is a paragraph aria role
1147− Generic ->
1147+ -- maybe it doesn't do anything, but it might help.
1148− NodeName "p"
1148+ -- https://github.com/w3c/aria/blob/11f85f41a5b621fdbe85fc9bcdcd270e653a48ba/common/script/roleInfo.js
1156− gatherAttrRecursive classes
1149+ gatherAttrRecursive
1157− newNode
1150+ classes
1159 transform
1153 transform
1161− attrs
1155+ (VirtualDom.attribute "role" "paragraph" :: attrs)
1162 children
1156 children
1163 remaining
1157 remaining
@@ -2043,34 +2037,44 @@ getHeight attrs =
2040+textElementClasses : String
2041+textElementClasses =
2046+ ++ classes.widthContent
2048+ ++ classes.heightContent
2046textElement : String -> VirtualDom.Node msg
2051textElement : String -> VirtualDom.Node msg
2047textElement str =
2052textElement str =
2048 Html.div
2053 Html.div
2049 [ Html.Attributes.class
2054 [ Html.Attributes.class
2050− (String.join " "
2055+ textElementClasses
2053− , classes.widthContent
2054− , classes.heightContent
2058 [ Html.text str ]
2057 [ Html.text str ]
2060+textElementFillClasses : String
2061+textElementFillClasses =
2066+ ++ classes.widthFill
2068+ ++ classes.heightFill
2061textElementFill : String -> VirtualDom.Node msg
2071textElementFill : String -> VirtualDom.Node msg
2062textElementFill str =
2072textElementFill str =
2063− VirtualDom.node "div"
2073+ Html.div
2064 [ Html.Attributes.class
2074 [ Html.Attributes.class
2065− (String.join " "
2075+ textElementFillClasses
2068− , classes.widthFill
2069− , classes.heightFill
2073− [ VirtualDom.text str ]
2077+ [ Html.text str ]
2076type Children x
2080type Children x