Skip to content

Alert with only an icon and title is missing bottom spacing #999

@brentvollebregt

Description

@brentvollebregt

The issue

When creating an alert with only a title and icon, the spacing at the bottom that is usually provided when using buttons or text is not rendered.

For example, doing the following,

swal({
  title: "Example Title",
  icon: "error",
  buttons: false
});

will render,

image

Expectation

I would expect that there is spacing similar to when text is provided:

image

Possible Solution

One solution I see is to apply the bottom spacing like the margin for text is added, something like:

.swal-title:last-child {
  margin-bottom: 45px;
}

This would then give,

image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions