summaryrefslogtreecommitdiffstats
path: root/web/src/widget/button.rs
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón <hector0193@gmail.com>2019-12-18 23:20:19 +0100
committerLibravatar GitHub <noreply@github.com>2019-12-18 23:20:19 +0100
commit6f9de4130f6b3fe4ed0d4aa14b2cbc8d0d8e10e3 (patch)
treead267b855f2c5e3d9d2aced5ebb672c72ef52b2a /web/src/widget/button.rs
parent0f2e20f5e5b1f0658ab4e6cbe6fdda9ca97f2b36 (diff)
parent95988e8e251d5e416698d3883f85a469daed6365 (diff)
downloadiced-6f9de4130f6b3fe4ed0d4aa14b2cbc8d0d8e10e3.tar.gz
iced-6f9de4130f6b3fe4ed0d4aa14b2cbc8d0d8e10e3.tar.bz2
iced-6f9de4130f6b3fe4ed0d4aa14b2cbc8d0d8e10e3.zip
Merge pull request #127 from Gohla/web_styling
Add several missing style attributes in iced_web
Diffstat (limited to 'web/src/widget/button.rs')
-rw-r--r--web/src/widget/button.rs4
1 files changed, 3 insertions, 1 deletions
diff --git a/web/src/widget/button.rs b/web/src/widget/button.rs
index 4cc8b3de..e628bd18 100644
--- a/web/src/widget/button.rs
+++ b/web/src/widget/button.rs
@@ -130,6 +130,7 @@ where
) -> dodrio::Node<'b> {
use dodrio::builder::*;
+ let width = style::length(self.width);
let padding_class =
style_sheet.insert(bump, Style::Padding(self.padding));
@@ -149,9 +150,10 @@ where
"style",
bumpalo::format!(
in bump,
- "background: {}; border-radius: {}px; min-width: {}px",
+ "background: {}; border-radius: {}px; width:{}; min-width: {}px",
background,
self.border_radius,
+ width,
self.min_width
)
.into_bump_str(),