summaryrefslogtreecommitdiff
path: root/htmtl/parsers/inner_text.py
diff options
context:
space:
mode:
authorAsko Nõmm <asko@nmm.ee>2025-01-09 21:43:58 +0200
committerAsko Nõmm <asko@nmm.ee>2025-01-09 21:43:58 +0200
commit4a3208b8c16bf9b3857163f588e68b3ae505cd4b (patch)
tree785c5eb94b1823f4f2cd282ff870cce8be8981cb /htmtl/parsers/inner_text.py
parent0544f795700240e19219521b8b435424fa689a1c (diff)
Getting there
Diffstat (limited to 'htmtl/parsers/inner_text.py')
-rw-r--r--htmtl/parsers/inner_text.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/htmtl/parsers/inner_text.py b/htmtl/parsers/inner_text.py
index 52fc0b4..c147b12 100644
--- a/htmtl/parsers/inner_text.py
+++ b/htmtl/parsers/inner_text.py
@@ -7,7 +7,8 @@ from ..parser import Parser
class InnerText(Parser):
def traverse(self, node: Node) -> Optional[Node]:
if "inner-text" in node.attributes:
- node.children = [TextNode(value=self.expression(node.attributes["inner-text"]))]
+ exp = self.parse_expression(node.attributes["inner-text"])
+ node.children = [TextNode(value=exp)]
node.attributes.pop("inner-text")
- return node \ No newline at end of file
+ return node