mail based rss feed aggregator
2
fork

Configure Feed

Select the types of activity you want to include in your feed.

remove id from `toaster.Toast`

ollie bd029b75 06c3ffc5

+15 -7
+15 -7
src/eater/ui/toaster.gleam
··· 25 25 pub const max: Int = 5 26 26 27 27 pub type Toast { 28 - Toast( 29 - id: Int, 30 - title: option.Option(String), 31 - message: String, 32 - options: toast.Options, 33 - ) 28 + Toast(title: option.Option(String), message: String, options: toast.Options) 34 29 } 35 30 36 31 /// render all `toast-container`s ··· 76 71 /// renders a toast without its surrounding `toast-container` 77 72 /// 78 73 fn view_toast(toast: Toast) -> element.Element(a) { 79 - let Toast(title:, message:, options:, ..) = toast 74 + let Toast(title:, message:, options:) = toast 80 75 81 76 element.element( 82 77 "output", 83 78 [ 84 79 attribute.attribute("data-variant", options.variant |> variant_to_string), 85 80 attribute.class("toast"), 81 + // attribute.attribute("data-entering", ""), 86 82 ], 87 83 [ 84 + // html.script( 85 + // [], 86 + // " 87 + // var self = document.currentScript; 88 + // // Double RAF to compute styles before transition starts. 89 + // requestAnimationFrame(() => { 90 + // requestAnimationFrame(() => { 91 + // self.parentElement.removeAttribute('data-entering'); 92 + // }); 93 + // }); 94 + // ", 95 + // ), 88 96 case title { 89 97 option.Some(title) -> 90 98 html.h6([attribute.class("toast-title")], [element.text(title)])