Skip to content

Commit

Permalink
fix(footer): corner radius
Browse files Browse the repository at this point in the history
  • Loading branch information
git-f0x authored and wash2 committed Nov 19, 2024
1 parent 62b0c8a commit dd79e90
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 14 deletions.
16 changes: 4 additions & 12 deletions src/theme/style/iced.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,15 +6,13 @@
use crate::theme::{CosmicComponent, Theme, TRANSPARENT_COMPONENT};
use cosmic_theme::composite::over;
use iced::{
border, color,
overlay::menu,
widget::{
button as iced_button, checkbox as iced_checkbox, container as iced_container, pane_grid,
pick_list, progress_bar, radio, rule, scrollable,
slider::{self, Rail},
svg, toggler,
},
Gradient,
};
use iced_core::{Background, Border, Color, Shadow, Vector};
use iced_widget::{pane_grid::Highlight, text_editor, text_input};
Expand Down Expand Up @@ -411,7 +409,7 @@ impl<'a> Container<'a> {
text_color: Some(Color::from(theme.background.on)),
background: Some(iced::Background::Color(theme.background.base.into())),
border: Border {
radius: theme.corner_radii.radius_xs.into(),
radius: theme.corner_radii.radius_s.into(),
..Default::default()
},
shadow: Shadow::default(),
Expand All @@ -425,7 +423,7 @@ impl<'a> Container<'a> {
text_color: Some(Color::from(theme.primary.on)),
background: Some(iced::Background::Color(theme.primary.base.into())),
border: Border {
radius: theme.corner_radii.radius_xs.into(),
radius: theme.corner_radii.radius_s.into(),
..Default::default()
},
shadow: Shadow::default(),
Expand All @@ -439,7 +437,7 @@ impl<'a> Container<'a> {
text_color: Some(Color::from(theme.secondary.on)),
background: Some(iced::Background::Color(theme.secondary.base.into())),
border: Border {
radius: theme.corner_radii.radius_xs.into(),
radius: theme.corner_radii.radius_s.into(),
..Default::default()
},
shadow: Shadow::default(),
Expand Down Expand Up @@ -531,13 +529,7 @@ impl iced_container::Catalog for Theme {
}

Container::ContextDrawer => {
let mut appearance = crate::style::Container::primary(cosmic);

appearance.border = Border {
color: cosmic.primary.divider.into(),
width: 0.0,
radius: cosmic.corner_radii.radius_s.into(),
};
let mut appearance = Container::primary(cosmic);

appearance.shadow = Shadow {
color: cosmic.shade.into(),
Expand Down
3 changes: 1 addition & 2 deletions src/widget/context_drawer/widget.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@ impl<'a, Message: Clone + 'static> ContextDrawer<'a, Message> {
{
let cosmic_theme::Spacing {
space_xxs,
space_xs,
space_s,
space_m,
space_l,
Expand Down Expand Up @@ -78,7 +77,7 @@ impl<'a, Message: Clone + 'static> ContextDrawer<'a, Message> {
container(element)
.width(Length::Fixed(480.0))
.align_y(Alignment::Center)
.padding([space_xs, horizontal_padding])
.padding([space_xxs, horizontal_padding])
});
let pane = column::with_capacity(3)
.push(header)
Expand Down

0 comments on commit dd79e90

Please sign in to comment.