ion-back-button and ion-menu-toggle not visible on iOS
See original GitHub issueBug Report
Ionic Info
Ionic:
ionic (Ionic CLI) : 4.1.2
System:
NodeJS : v8.11.4
npm : 6.4.1
OS : macOS High Sierra
Packaged Versions
{
"@ionic/core": "4.0.0-beta.8",
"@stencil/core": "0.12.4"
}
Describe the Bug
The ion-back-button
doesn’t show the icon on iOS.
Steps to Reproduce
- Create and run an Ionic PWA Stencil project:
npx create-stencil ionic-pwa
npm i -D -E @capacitor/cli @capacitor/core
npx cap init <name> <app-id>
npx cap add ios
npx cap add android
npm start
- Change the emulated device in Chrome dev tools to an iOS device and reload.
- Switch to the profile route.
- The button exists (can be clicked and inspected) but the icon is invisible.
Related Code
<ion-header>
<ion-toolbar color="primary">
<ion-buttons slot="start">
<ion-back-button defaultHref="/" />
</ion-buttons>
<ion-title>Profile: {this.name}</ion-title>
</ion-toolbar>
</ion-header>
Expected Behavior
The icon should be visible.
Additional Context
Adding mode="md"
to the ion-back-button
component kind of fixes it: on iOS it actually shows the proper iOS back icon (chevron), not the Android back icon (arrow). However as I understand setting mode
to md
should also change the icon to the Android icon? The only way of forcing it to use the Android Icon is to run setupConfig({ mode: 'md' })
.
Issue Analytics
- State:
- Created 5 years ago
- Reactions:3
- Comments:7 (2 by maintainers)
Top Results From Across the Web
ion-back-button and ion-menu-toggle not visible on iOS #15545
The ion-back-button doesn't show the icon on iOS. Steps to Reproduce. Create and run an Ionic PWA Stencil project: npx create-stencil ionic-pwa ...
Read more >ion-back-button: Custom Menu Icon for Applications
The ion-back-button is a custom menu icon for Android, iOS, and Progressive Web Apps. Use Ionic Framework components to easily build applications.
Read more >Ionic 5 menu doesn't show up - Stack Overflow
In order to keep the ion-back-button or ion-menu-button there even if the context is lost. Use auto-hide attribute in Ionic 4 onwards.
Read more >[Solved]-Ionic 5 menu doesn't show up-angular.js
In order to keep the ion-back-button or ion-menu-button there even if the context is lost. Use auto-hide attribute in Ionic 4 onwards.
Read more >Build a Cross Platform Mobile App with Ionic 4 and Angular
In this tutorial, we'll learn how to use Ionic 4 and Angular to build a cross platform hybrid mobile application from scratch.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Can confirm I’m seeing this issue as well.
I think this is related to there being a
Somewhere, which is making the color match the background?
I tossed a
in my global.scss and it seems to be back?
I have added a PR -> #15847
They have fixed the back-button few weeks ago, but not the menu-button. I just fixed the problem with the color, but they have to add a lot of more css variables like they did at the back-button. So I don’t know if they merge it or if they fix the whole menu-button soon