Rename container::box_ to rounded_box

This commit is contained in:
Héctor Ramón Jiménez 2024-03-08 18:57:44 +01:00
parent 0a65fd0d74
commit 34faedd32b
No known key found for this signature in database
GPG key ID: 7CC46565708259A7
8 changed files with 9 additions and 9 deletions

View file

@ -286,7 +286,7 @@ fn action<'a, Message: Clone + 'a>(
label,
tooltip::Position::FollowCursor,
)
.style(container::box_)
.style(container::rounded_box)
.into()
} else {
action.style(button::secondary).into()

View file

@ -275,7 +275,7 @@ fn application<'a>() -> Element<'a, Message> {
.width(200)
.align_items(Alignment::Center),
)
.style(container::box_)
.style(container::rounded_box)
.height(Length::Fill)
.center_y();

View file

@ -174,7 +174,7 @@ impl Application for App {
)
.width(300)
.padding(10)
.style(container::box_);
.style(container::rounded_box);
Modal::new(content, modal)
.on_blur(Message::HideModal)

View file

@ -148,7 +148,7 @@ impl Application for Example {
let image = container(image)
.padding(10)
.style(container::box_)
.style(container::rounded_box)
.width(Length::FillPortion(2))
.height(Length::Fill)
.center_x()

View file

@ -271,7 +271,7 @@ mod toast {
container(text(toast.body.as_str()))
.width(Length::Fill)
.padding(5)
.style(container::box_),
.style(container::rounded_box),
])
.max_width(200)
.into()

View file

@ -52,7 +52,7 @@ impl Sandbox for Example {
self.position,
)
.gap(10)
.style(container::box_);
.style(container::rounded_box);
container(tooltip)
.width(Length::Fill)

View file

@ -132,7 +132,7 @@ impl Application for Example {
container(text("I am the outer container!"))
.id(OUTER_CONTAINER.clone())
.padding(40)
.style(container::box_),
.style(container::rounded_box),
vertical_space().height(400),
scrollable(
column![
@ -141,7 +141,7 @@ impl Application for Example {
container(text("I am the inner container!"))
.id(INNER_CONTAINER.clone())
.padding(40)
.style(container::box_),
.style(container::rounded_box),
vertical_space().height(400),
]
.padding(20)

View file

@ -590,7 +590,7 @@ pub fn transparent<Theme>(_theme: &Theme, _status: Status) -> Appearance {
}
/// A rounded [`Container`] with a background.
pub fn box_(theme: &Theme, _status: Status) -> Appearance {
pub fn rounded_box(theme: &Theme, _status: Status) -> Appearance {
let palette = theme.extended_palette();
Appearance {