@@ -530,25 +530,22 @@ finalizeNode has node attributes children embedMode parentContext =
532embedWith static opts styles children =
532embedWith static opts styles children =
536+ |> List.foldl reduceStyles ( Set.empty, renderFocusStyle opts.focus )
538+ -- |> reduceStylesRecursive Set.empty [ ]) --renderFocusStyle opts.focus ]
540+ |> toStyleSheet opts
533 if static then
542 if static then
534 staticRoot opts
543 staticRoot opts
535− :: (styles
544+ :: dynamicStyleSheet
536− |> List.foldl reduceStyles ( Set.empty, renderFocusStyle opts.focus )
538− -- |> reduceStylesRecursive Set.empty [ ]) --renderFocusStyle opts.focus ]
540− |> toStyleSheet opts
542 :: children
545 :: children
545− (styles
548+ dynamicStyleSheet
546− |> List.foldl reduceStyles ( Set.empty, renderFocusStyle opts.focus )
548− -- |> reduceStylesRecursive Set.empty [ ]) --renderFocusStyle opts.focus ]
550− |> toStyleSheet opts
552 :: children
549 :: children
@@ -2568,28 +2565,16 @@ renderProps force (Property key val) existing =
2570encodeStyles options stylesheet =
2567encodeStyles options stylesheet =
2571− let
2568+ stylesheet
2572− combine style rendered =
2575− renderStyleRule options style Nothing
2577− { rules = renderedStyle ++ rendered.rules
2579− case topLevelValue style of
2584− topLevel :: rendered.topLevel
2587− case List.foldl combine { topLevel = [], rules = [] } stylesheet of
2588− { topLevel, rules } ->
2589− -- TODO: top level values are still required
2591− |> List.map (\r -> ( r, Encode.string r ))
2569+ |> List.map
2573+ renderStyleRule options style Nothing
2575+ ( getStyleName style, Encode.list Encode.string styled )
2592− |> Encode.object
2577+ |> Encode.object
2595toStyleSheetString : OptionRecord -> List Style -> String
2580toStyleSheetString : OptionRecord -> List Style -> String