-
Notifications
You must be signed in to change notification settings - Fork 13.5k
bug: Defining an icon in Action Sheet button properties does not render icon #29600
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
You can fix it by doing this where you are using the action sheet: import { addIcons } from 'ionicons';
import { addCircleOutline } from 'ionicons/icons';
class YourComponent {
constructor() {
addIcons({
addCircleOutline: addCircleOutline,
});
}
} But as you should only need to do this when you are using angular/standalone, this is probably a bug ^^ |
Thanks @Julien-Marcou , I've tested |
Thank you for submitting the issue! I'm closing this as a duplicate since we are tracking this bug through ionic-team/ionic-docs#2892. It's related to StackBlitz. The bug doesn't occur outside of StackBlitz. |
Got it thank you. |
Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Ionic, please create a new issue and ensure the template is fully filled out. |
Prerequisites
Ionic Framework Version
v7.x, v8.x
Current Behavior
The
ion-action-sheet
component does not seem to render the icon provided in theActionSheetButton
properties. It happens both when the action buttons are passed as[buttons]
property or via theActionSheetController
.The
icon
value passed into theActionSheetButton
properties is an Ionicon name.The
<ion-icon>
element will be rendered, but no icon is displayed.Expected Behavior
The icon should be displayed within the
ion-icon
element that is rendered in the Action Sheet.Steps to Reproduce
icon
defined.icon
value, use any of the Ionicons values. Example:icon: 'add-circle-outline'
Code Reproduction URL
https://stackblitz.com/edit/angular-mnydcf?file=src%2Fapp%2Fexample.component.html
Ionic Info
I am using a stackblitz example taken from https://ionicframework.com/docs/api/action-sheet#theming
Additional Information
No response
The text was updated successfully, but these errors were encountered: