Version bumps made css_inline uncompilable for wasm
This commit is contained in:
@@ -194,13 +194,15 @@ fn view_part(part: &Part) -> Node<Msg> {
|
||||
"text/plain" => view_text_plain(&part.content),
|
||||
"text/html" => {
|
||||
if let Some(Content::String(html)) = &part.content {
|
||||
/* Build problems w/ css_inline. TODO(wathiede): move to server
|
||||
let inliner = css_inline::CSSInliner::options()
|
||||
.load_remote_stylesheets(false)
|
||||
.remove_style_tags(true)
|
||||
.build();
|
||||
let inlined = inliner.inline(html).expect("failed to inline CSS");
|
||||
*/
|
||||
|
||||
return div![C!["view-part-text-html"], raw![&inlined]];
|
||||
return div![C!["view-part-text-html"], raw![&html]];
|
||||
} else {
|
||||
div![
|
||||
C!["error"],
|
||||
@@ -218,12 +220,14 @@ fn view_part(part: &Part) -> Node<Msg> {
|
||||
for part in parts.iter().rev() {
|
||||
if part.content_type == "text/html" {
|
||||
if let Some(Content::String(html)) = &part.content {
|
||||
/*
|
||||
let inliner = css_inline::CSSInliner::options()
|
||||
.load_remote_stylesheets(false)
|
||||
.remove_style_tags(true)
|
||||
.build();
|
||||
let inlined = inliner.inline(html).expect("failed to inline CSS");
|
||||
return div![Node::from_html(None, &inlined)];
|
||||
*/
|
||||
return div![Node::from_html(None, &html)];
|
||||
}
|
||||
}
|
||||
if part.content_type == "text/plain" {
|
||||
|
||||
Reference in New Issue
Block a user