Skip to content

bug: toolbars in modal need additional padding #22778

Closed
@liamdebeasi

Description

@liamdebeasi

Bug Report

Ionic version:

[ ] 4.x
[x] 5.x

Current behavior:

Toolbars in modals and non-modal contexts have the same padding.

Expected behavior:

Toolbars in modals on native iOS have additional padding than in non-modal contexts.

Steps to reproduce:

  1. Go to https://ionicframework.com/docs.
  2. Click "Modal" in the example app on the right.
  3. Click "Open Modal".
  4. Compare with the screenshot below. Notice that there is less padding in the Ionic example than in the native example.

Related code:

We will need to modify the --padding-* CSS Variables on the ion-toolbar component: https://github.com/ionic-team/ionic-framework/blob/master/core/src/components/toolbar/toolbar.ios.scss#L11-L14.

However, there are a few restrictions:

  1. This should only apply in iOS mode.
  2. This should only apply when the toolbar is used in a header in a modal.

TODO: need to figure out the exact padding values.

IMG_DC0748849985-1

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions