Questions tagged [actionsheet]
45 questions
13
votes
2 answers
SwiftUI - Action sheet with no title, Alert.Button using View instead of Text
Is there any way to have no title section in an Action Sheet? The Action Sheet definition in the SwiftUI code is as follows:
public struct ActionSheet {
/// Creates an action sheet with the provided buttons.
public init(title: Text, message:…

Warrior
- 39,156
- 44
- 139
- 214
10
votes
2 answers
How to use react-native-action-sheet with hooks
I'm trying to use https://github.com/expo/react-native-action-sheet in a functional component using the provided hook useActionSheet(). I'm already using the class components version without any problem but I'd like to switch to functional.
React…

zeights
- 103
- 1
- 6
7
votes
0 answers
SwiftUI ActionSheet position on iPad
When using SwiftUI's ActionSheet inside a List on iPad, it appears in a wrong position, especially if the style of the list is set to GroupedListStyle.
With this code:
struct ContentView: View {
@State var presentAction: Bool = false
var…

alessionossa
- 923
- 2
- 15
- 41
5
votes
1 answer
SwiftUI ActionSheet different color for each action
I have a question regarding Actionsheet in SwiftUI. I want to create an ActionSheet with 2 options: delete and cancel. "Delete" button colored in red and "cancel" in green.
Here is an example of code:
Button(action: {
…

Theodor Ungureanu
- 233
- 1
- 7
5
votes
1 answer
iOS SwiftUI: ActionSheet custom style
I'm trying to change the text color and the background color of the ActionSheet in SwiftUI.
This is the code of my actionSheet:
.actionSheet(isPresented: $viewModel.isCustomItemSelected) {
ActionSheet(
title: Text("Add Item"),
…

Andrea Miotto
- 7,084
- 8
- 45
- 70
4
votes
0 answers
Custom ActionSheet doesn't work when getting in SplitView
I want to implement a custom ActionSheet, everything works fine except one thing, when getting in split view with the action sheet opened the touch area of the button from my custom action sheet is wrongly positioned. As you can see in the demo(at…

Claudiu
- 485
- 1
- 4
- 17
3
votes
1 answer
SwiftUI open ShareLink from ActionSheet (confirmationDialog) Not Working
I have a ShareLink inside an ActionSheet (confirmationDialog) but it's not opening. Can anyone confirm if this is possible or not? I imagine it's something to do with the action sheet being dismissed at the same time.
.confirmationDialog("",…

Dan
- 543
- 2
- 13
3
votes
2 answers
SwiftUI .actionSheet() doesn't always present
I'm running into an issue that stems from having a button in one action sheet that opens another action sheet attached to a different subview of a ZStack. I'm not sure why, but sometimes the second action sheet appears, and sometimes it doesn't. I…

nickcoding2
- 142
- 1
- 8
- 34
2
votes
0 answers
Flutter : How can I change background color of CupertinoActionSheet?
How can I change CupertinoActionSheet background color in flutter? I tried many possible ways. But its default color didn't change. how can I ?
Sample Code:
import 'package:flutter/cupertino.dart';
import…

Abir Ahsan
- 2,649
- 29
- 51
2
votes
1 answer
Action sheet not displaying (Ionic Framework)
In Ionic 6, I'm displaying an action sheet when a list item is clicked. It works fine in the browser, but when testing on my iPhone the action sheet never appears.
To test on my iPhone I'm using these commands:
ionic capacitor copy ios
ionic…

Luc
- 3,581
- 3
- 22
- 24
2
votes
1 answer
ActionSheet crashes on iPad, not on iPhone
The below code is found on examples in several places and used to work for me, but now it crashes. The problem seems to be on iPadOS since it seems to work on iPhones, both simulators and physical devices.
The error…

Russ
- 467
- 3
- 10
2
votes
1 answer
using Navigationlink in actionsheet swiftui
Does anyone know how I can go to another view from an actionsheet in Swiftui?
Currently I use this as a button in actionsheet:
.actionSheet(isPresented: $actionsheet) {
ActionSheet(title: Text("Actions"), message: Text("Choose action"), buttons:…

chrispsv
- 503
- 1
- 3
- 21
2
votes
1 answer
How to manipulate the ion-list item using an ActionSheet in SwiftUI?
I am trying to use an ActionSheet to manipulate items of a List. How can I call a function (in this example deleteItem) that is part of the data model, using an ActionSheet and manipulte the selected item, similar to what .onDelete does?
My view…

jiko
- 146
- 1
- 9
1
vote
0 answers
Not responding Custom Actions from Gifted chat
I am not to familiar with react-native and I have tried to get help from my mentor, anyhow he is not familiar with the topic (react-native, Gifted chat).
So I have this two components: ChatScreen and Custom Actions. Custom Actions should render…

GustavoA17
- 11
- 3
1
vote
1 answer
How to remove ActionSheet borderRadius NativeBase
I am working on react native and using native-base (v3.0.*) for the design part. I need to remove the top border-radius from the Actionsheet and need something like this.

sakshya73
- 5,570
- 5
- 22
- 41