Pārlūkot izejas kodu

Fix style rendering in markdown (#1869)

Nikhil Rao 1 gadu atpakaļ
vecāks
revīzija
d1019fb977
1 mainītis faili ar 2 papildinājumiem un 1 dzēšanām
  1. 2 1
      reflex/components/typography/markdown.py

+ 2 - 1
reflex/components/typography/markdown.py

@@ -12,6 +12,7 @@ from reflex.components.navigation import Link
 from reflex.components.tags.tag import Tag
 from reflex.components.tags.tag import Tag
 from reflex.components.typography.heading import Heading
 from reflex.components.typography.heading import Heading
 from reflex.components.typography.text import Text
 from reflex.components.typography.text import Text
+from reflex.style import Style
 from reflex.utils import console, imports, types
 from reflex.utils import console, imports, types
 from reflex.vars import ImportVar, Var
 from reflex.vars import ImportVar, Var
 
 
@@ -173,7 +174,7 @@ class Markdown(Component):
         component = self.component_map[tag](*children, **props).set(
         component = self.component_map[tag](*children, **props).set(
             special_props=special_props
             special_props=special_props
         )
         )
-        component._add_style(self.custom_styles.get(tag, {}))
+        component._add_style(Style(self.custom_styles.get(tag, {})))
         return component
         return component
 
 
     def format_component(self, tag: str, **props) -> str:
     def format_component(self, tag: str, **props) -> str: