diff --git a/file-service/src/html.rs b/file-service/src/html.rs
index d38fb21..5f5e2cd 100644
--- a/file-service/src/html.rs
+++ b/file-service/src/html.rs
@@ -236,41 +236,3 @@ impl Html for Button {
)
}
}
-
-#[derive(Clone, Debug)]
-pub struct Image {
- path: String,
- attributes: Attributes,
-}
-
-impl Image {
- pub fn new(path: &str) -> Self {
- Self {
- path: path.to_owned(),
- attributes: Attributes::default(),
- }
- }
-
- pub fn with_attributes<'a>(
- mut self,
- values: impl IntoIterator- ,
- ) -> Self {
- self.attributes = Attributes(
- values
- .into_iter()
- .map(|(a, b)| (a.to_owned(), b.to_owned()))
- .collect::>(),
- );
- self
- }
-}
-
-impl Html for Image {
- fn to_html_string(&self) -> String {
- format!(
- "",
- path = self.path,
- attrs = self.attributes.to_string()
- )
- }
-}
diff --git a/file-service/src/pages.rs b/file-service/src/pages.rs
index 55ce528..e12feec 100644
--- a/file-service/src/pages.rs
+++ b/file-service/src/pages.rs
@@ -87,8 +87,9 @@ pub fn thumbnail(info: &FileInfo) -> Container {
.with_html(
Container::new(ContainerType::Div).with_link(
format!("/{}", *info.id),
- Image::new(&format!("{}/tn", *info.id))
- .with_attributes([("class", "thumbnail__image")])
+ Container::default()
+ .with_attributes([("class", "thumbnail")])
+ .with_image(&format!("{}/tn", *info.id), "test data")
.to_html_string(),
),
)