Что я пробовал до сих пор:
- Я смотрел сеанс WWDC 2025 «Создание приложения UIKit с новым дизайном»: https://developer.apple.com/videos/play/wwdc2025/284/.
В видео они установили sourceItem с помощью элемента кнопки панели, который правильно показывает отсутствие стрелки. Я пробовал использовать тот же подход с обычным UIButton, но стрелка по-прежнему отображается. - Проверил документацию Apple: https://developer.apple.com/documentati ... ion-sheets
- Отключение стрелки с помощью:
или:Код: Выделить всё
alertController.popoverPresentationController?.permittedArrowDirections = []
скрывает стрелку, но нарушает анимацию листа действий — лист появляется мгновенно, а не плавно скользит вверх.Код: Выделить всё
alertController.popoverPresentationController?.permittedArrowDirections = UIPopoverArrowDirection(rawValue: 0) - Вот код, который я использую:
Код: Выделить всё
@IBAction func buttonTapped(_ sender: UIButton) { let action = UIAlertAction(title: "Action", style: .destructive) let alertController = UIAlertController(title: nil, message: "Message", preferredStyle: .actionSheet) alertController.addAction(action) alertController.popoverPresentationController?.sourceItem = sender alertController.popoverPresentationController?.permittedArrowDirections = UIPopoverArrowDirection(rawValue: 0) present(alertController, animated: true) } - Ожидаемый результат: https://drive.google.com/file/d/1ItU2lt ... sp=sharing
- Фактический результат:
https://drive.google.com/file/d/1ItT8Ab ... sp=sharing
Подробнее здесь: https://stackoverflow.com/questions/798 ... -in-ios-26