Since updating to Tahoe and Xcode 26 I have found that the UISplitViewController.showDetailViewController() is not working in the iPhone version of my app (it is a universal app). I'm just trying to show a detail view after a tap on a UITableView item. The iPad versions are all working correctly. Has anyone else experienced this or have any advice about what may have changed?
Thanks in advance.
UIKit
RSS for tagConstruct and manage graphical, event-driven user interfaces for iOS or tvOS apps using UIKit.
Selecting any option will automatically load the page
Post
Replies
Boosts
Views
Activity
UIViewController's modalInPopover is deprecated and might disappear in the near future. Is there any replacement?
UIViewController's presentViewController:animated:completion is not an equivalent because the modal style cannot be changed while the controller is already presented.
It seems to be that the functionality of the method setViewController:forColumn: in the column-style layout of a UISplitViewController has changed.
iOS 18: setViewController:forColumn: pushes a new view controller onto the UINavigationController if it existed before the call.
iOS 26: setViewController:forColumn: sets or replaces the view controller with a new view controller as a root of a new UINavigationController.
My questions:
what is the intended behavior? I did not find any documentation about a change.
how do I replace in iOS 18 the old view controller with the new view controller passed to setViewController:forColumn:?
I’ve been trying to set up a UIDocument and override writeContents(...). This works correctly in older projects, but I haven’t been able to get it working in my new iOS 26 app using Swift 6.
To troubleshoot, I tested the Particles demo and successfully overrode writeContents there. However, as soon as I switch that project to iOS 26 and Swift 6, calling save; which triggers writeContents, causes the same crash.
override public func writeContents(
_ data: Any,
to url: URL,
for _: UIDocument.SaveOperation,
originalContentsURL _: URL?,
) throws {
...
}
Thread 10 Queue : UIDocument File Access (serial)
Topic:
UI Frameworks
SubTopic:
UIKit
Hello! What UIKit API enables you to add a view below the navigation bar and extend the scroll edge effect below it in iOS 26? safeAreaBar is how you do it in SwiftUI but I need to achieve this design in my UIKit app (which has a collection view in a view controller in a navigation controller).
struct ContentView: View {
let segments = ["First", "Second", "Third"]
@State private var selectedSegment = "First"
var body: some View {
NavigationStack {
List(0..<50, id: \.self) { i in
Text("Row \(i + 1)")
}
.safeAreaBar(edge: .top) {
Picker("Segment", selection: $selectedSegment) {
ForEach(segments, id: \.self) {
Text($0)
}
}
.pickerStyle(.segmented)
.padding(.horizontal)
.padding(.bottom, 8)
}
.navigationTitle("Title")
.navigationBarTitleDisplayMode(.inline)
}
}
}
When a UIVisualEffect with glass effect view is added with opacity 0, it remains hidden as expected. But when changing it back to 1 should make it visible, but currently it stays hidden forever. The bug is only reproducible on iOS 26.1 and iOS 26.2. It does not happen on iOS 26.0. The issue is also not reproducible with UIBlurEffect. Only happens for Glass effect
Here is the repro link
I’m building a photo‑gallery view that mimics the iOS Photos app when it’s zoomed in to the maximum level: all years are displayed at once, with roughly 400 tiny thumbnails per page. The user experience of the system app is that the view is instantly visible, and scrolling keeps thumbnails instantly appearing.
I’ve already tried fetching thumbnails with PHImageManager and PHCachingImageManager, requesting the .fastFormat representation. However, the thumbnails still take several seconds to load, so the scrolling experience is noticeably laggy compared to the system app.
Is there another approach or technique—perhaps a different caching strategy, pre‑fetching, or a lower‑level API—that would allow me to retrieve and display thumbnails as quickly (or faster) than the native Photos app? Any guidance or code snippets would be greatly appreciated.
I was trying to figure out why my bottom sheet looks weird and doesn't have the "proper glass" look. I found that this issue seems to be new to iOS 26.1.
See the images below, they show the same view hierarchy (in this case UIHostingController configured as bottom sheet that has NavigationStack and content.
On iOS 26.1 there seems to be extra two layers of background - even though I am no adding any.
iOS 26:
iOS 26.1
Has anyone experienced something similar? Any workarounds? I am happy to completely disable the glass effect for this bottom sheet if it helps.
The screenshots show one sheet, but the same thing happens for another ones.
Hello!
I'm creating a settings page for my app and I want it to look as native as possible. I want to know if it's possible to add constraints that make the second label go to the bottom when the text size gets really large (see Picture1) instead of having to force it to be on the right (see Picture 2).
I've left my constraint code for this cell down below, too.
I'm still learning constraints and best practices, so if there's any feedback, I'd love to hear it. Thank you!
Picture 1
Picture 2
- (void) setConstraints {
[NSLayoutConstraint activateConstraints:@[
// Cell Title Label
[self.themeColorLabel.leadingAnchor constraintEqualToAnchor:self.contentView.layoutMarginsGuide.leadingAnchor],
[self.themeColorLabel.trailingAnchor constraintEqualToAnchor:self.contentView.layoutMarginsGuide.trailingAnchor],
[self.themeColorLabel.topAnchor constraintEqualToAnchor: self.contentView.layoutMarginsGuide.topAnchor],
[self.themeColorLabel.bottomAnchor constraintEqualToAnchor: self.contentView.layoutMarginsGuide.bottomAnchor],
// Selected Theme Color Label
[self.selectedColorLabel.trailingAnchor constraintEqualToAnchor: self.contentView.layoutMarginsGuide.trailingAnchor],
[self.selectedColorLabel.topAnchor constraintEqualToAnchor: self.contentView.layoutMarginsGuide.topAnchor],
[self.selectedColorLabel.bottomAnchor constraintEqualToAnchor: self.contentView.layoutMarginsGuide.bottomAnchor],
]];
}
I've created a custom keyboard and implemented the:
class KeyboardViewController: UIInputViewController
The imlementation looks like this:
override func viewDidLoad() {
super.viewDidLoad()
var stack = UIStackView()
stack.axis = .vertical
stack.spacing = 8
stack.translatesAutoresizingMaskIntoConstraints = false
stack.distribution = .fill
stack.heightAnchor.constraint(equalToConstant: 200).isActive = true
....
view.addSubview(stack)
NSLayoutConstraint.activate([
stack.leadingAnchor.constraint(equalTo: view.leadingAnchor, constant: 20),
stack.trailingAnchor.constraint(equalTo: view.trailingAnchor, constant: -20),
stack.topAnchor.constraint(equalTo: view.topAnchor, constant: 10),
stack.bottomAnchor.constraint(equalTo: view.bottomAnchor, constant: -10)
])
The problem is that the keyboard seems to start showing in the size (I've printed the parent frame):
Optional(<UIView: 0x101008480; frame = (0 0; 390 844); autoresize = W+H; layer = <CALayer: 0x600000207b80>>)
and than resizes to my given height. But it's not fast enough so that I can see some glitches whenever I switch from another keyboard to my custom keyboard.
Is there a way to prevent this resizing or start the keyboard in a given size? This is just not the best user experience.
Topic:
UI Frameworks
SubTopic:
UIKit
After the iOS 26 update, unwanted animations appear on UIButton.
I'm using the attributedTitle property of UIButton.Configuration to change the button's text, and an animation appears after iOS 26.
(It's unclear whether it's after iOS 26.0 or iOS 26.1, but it likely started with 26.1.)
The peculiar thing is that the animation only starts appearing on buttons that have been pressed once.
I tried using UIView.performWithoutAnimation and CATransaction's begin(), setDisableActions(true), commit(), but it didn't work.
How should I solve this?
Below is the code for changing the button's text.
func updateTitle() {
let keys = type.keys
if keys.count == 1 {
guard let key = keys.first else { return }
if key.count == 1 {
if Character(key).isLowercase {
self.configuration?.attributedTitle = AttributedString(key, attributes: AttributeContainer([.font: UIFont.systemFont(ofSize: 24, weight: .regular), .foregroundColor: UIColor.label]))
} else if Character(key).isUppercase {
self.configuration?.attributedTitle = AttributedString(key, attributes: AttributeContainer([.font: UIFont.systemFont(ofSize: 22, weight: .regular), .foregroundColor: UIColor.label]))
} else {
self.configuration?.attributedTitle = AttributedString(key, attributes: AttributeContainer([.font: UIFont.systemFont(ofSize: 22, weight: .regular), .foregroundColor: UIColor.label]))
}
} else {
self.configuration?.attributedTitle = AttributedString(key, attributes: AttributeContainer([.font: UIFont.systemFont(ofSize: 18, weight: .regular), .foregroundColor: UIColor.label]))
}
} else {
let joined = keys.joined(separator: "")
self.configuration?.attributedTitle = AttributedString(joined, attributes: AttributeContainer([.font: UIFont.systemFont(ofSize: 22, weight: .regular), .foregroundColor: UIColor.label]))
}
}
Hello. I have an 12 year old app that still has some objective-c code in it. I have a place where i have a flip animation between 2 view controllers that looks like this:
[UIView transitionFromView:origView
toView:newViewController.view
duration:0.5
options:UIViewAnimationOptionTransitionFlipFromRight
completion:nil];
It has looked like this since 2012 at least.
In our production release, it works prior to 26.1, but in 26.1 and 26.2, the flip is off-center and looks weird. it's like both edges flip the same way. It's a little bit hard to explain.
If seen at least 2 other app store apps that i have installed behave this way too, from 26.1 and onwards.
Anyone else seen this? Is there anything that can be done about it?
Thankful for thoughts.
Device: iPhone 11
iOS Version: 17.2.1
Frameworks: UIKit, Auto Layout
App Behavior: App supports Arabic (RTL). User can switch language in-app. When language is switched, the app sets UIView.appearance().semanticContentAttribute and fully rebuilds the window’s rootViewController.
Problem Summary
I update the global semantic direction only when the user explicitly switches language inside the app — e.g.:
// Only run when user switches language inside the app
UIView.appearance().semanticContentAttribute = .forceRightToLeft // or .forceLeftToRight
// then rebuild the window's rootViewController
I do not change UIView.appearance().semanticContentAttribute during navigation transitions. Despite that, after switching the language (and rebuilding the root), the app sometimes crashes during a subsequent UINavigationController push/pop animation. The crash appears to be caused by UIKit’s Auto Layout engine removing or updating directional constraints while a navigation transition is running.
Crash Log (most relevant portion)
Crashed: com.apple.main-thread
0 CoreAutoLayout 0x1372c -[NSISEngine positiveErrorVarForBrokenConstraintWithMarker:errorVar:] + 212
1 CoreAutoLayout 0x121d4 -[NSISEngine removeConstraintWithMarker:] + 1028
2 CoreAutoLayout 0x11d78 -[NSLayoutConstraint _removeFromEngine:] + 148
3 UIKitCore 0x124ba9c __58-[UIView _updateDirectionalConstraintsIfNeededWasFlipped:]_block_invoke_2 + 56
4 UIKitCore 0x484d4 ___UIViewEnumerateLayoutConstraintsAndAdjustForSelectedLayoutVariables_block_invoke + 296
5 UIKitCore 0x4801c -[UIView(AdditionalLayoutSupport) _withUnsatisfiableConstraintsLoggingSuspendedIfEngineDelegateExists:] + 112
6 UIKitCore 0x60830 -[UIView _updateDirectionalConstraintsIfNeededWasFlipped:] + 356
7 UIKitCore 0x60494 -[UIView setSemanticContentAttribute:] + 148
8 CoreFoundation 0x31794 __invoking___ + 148
9 CoreFoundation 0xe6360 -[NSInvocation invokeUsingIMP:] + 332
10 UIKitCore 0x1d93ec __workaround10030904InvokeWithTarget_block_invoke + 68
11 UIKitCore 0x250ec +[UIView _performSystemAppearanceModifications:] + 72
12 UIKitCore 0x3f008 applyInvocationsToTarget + 1004
13 UIKitCore 0x3dcd4 +[_UIAppearance _applyInvocationsTo:window:matchingSelector:onlySystemInvocations:] + 1180
14 UIKitCore 0x3d744 __88-[UIView(Internal) _performUpdatesForPossibleChangesOfIdiom:orScreen:traverseHierarchy:]_block_invoke + 68
15 UIKitCore 0x3d6c4 -[UIView _performUpdatesForPossibleChangesOfIdiom:orScreen:traverseHierarchy:] + 216
16 UIKitCore 0x3d5a0 -[UIView _didChangeFromIdiomOnScreen:traverseHierarchy:] + 112
17 UIKitCore 0x11644 -[UIView(Internal) _didMoveFromWindow:toWindow:] + 1220
18 UIKitCore 0x1142c -[UIView(Internal) _didMoveFromWindow:toWindow:] + 684
19 UIKitCore 0x1142c -[UIView(Internal) _didMoveFromWindow:toWindow:] + 684
20 UIKitCore 0x1142c -[UIView(Internal) _didMoveFromWindow:toWindow:] + 684
21 UIKitCore 0x10eb4 __45-[UIView(Hierarchy) _postMovedFromSuperview:]_block_invoke + 124
22 CoreAutoLayout 0xa514 -[NSISEngine withBehaviors:performModifications:] + 84
23 UIKitCore 0x10ddc -[UIView _postMovedFromSuperview:] + 504
24 UIKitCore 0xfa24 -[UIView(Internal) _addSubview:positioned:relativeTo:] + 2200
25 UIKitCore 0x7a63b8 __53-[_UINavigationParallaxTransition animateTransition:]_block_invoke_2 + 1252
26 UIKitCore 0x41a70 +[UIView(Animation) performWithoutAnimation:] + 76
27 UIKitCore 0x7a5e84 __53-[_UINavigationParallaxTransition animateTransition:]_block_invoke + 240
28 UIKitCore 0x12749c +[UIView _performBlockDelayingTriggeringResponderEvents:forScene:] + 176
29 UIKitCore 0x7a5990 -[_UINavigationParallaxTransition animateTransition:] + 952
30 UIKitCore 0x291098 ___UIViewControllerTransitioningRunCustomTransition_block_invoke_3 + 52
31 UIKitCore 0x29100c +[UIKeyboardSceneDelegate _pinInputViewsForKeyboardSceneDelegate:onBehalfOfResponder:duringBlock:] + 96
32 UIKitCore 0x290f70 ___UIViewControllerTransitioningRunCustomTransition_block_invoke_2 + 196
33 UIKitCore 0x1d8c8c +[UIView(Animation) _setAlongsideAnimations:toRunByEndOfBlock:] + 180
34 UIKitCore 0x1d851c _UIViewControllerTransitioningRunCustomTransition + 484
35 UIKitCore 0x6f5a84 -[UINavigationController _startCustomTransition:] + 3292
36 UIKitCore 0x1182a8 -[UINavigationController _startDeferredTransitionIfNeeded:] + 496
37 UIKitCore 0x1179a0 -[UINavigationController __viewWillLayoutSubviews] + 96
38 UIKitCore 0x117904 -[UILayoutContainerView layoutSubviews] + 172
39 UIKitCore 0x3297c -[UIView(CALayerDelegate) layoutSublayersOfLayer:] + 1528
40 QuartzCore 0x66aa8 CA::Layer::layout_if_needed(CA::Transaction*) + 500
41 QuartzCore 0x66630 CA::Layer::layout_and_display_if_needed(CA::Transaction*) + 144
42 QuartzCore 0x6cb60 CA::Context::commit_transaction(CA::Transaction*, double, double*) + 464
43 QuartzCore 0x65e3c CA::Transaction::commit() + 648
44 QuartzCore 0x65ae4 CA::Transaction::flush_as_runloop_observer(bool) + 88
45 CoreFoundation 0x3583c __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 36
46 CoreFoundation 0x34244 __CFRunLoopDoObservers + 548
47 CoreFoundation 0x33960 __CFRunLoopRun + 1028
48 CoreFoundation 0x33478 CFRunLoopRunSpecific + 608
49 GraphicsServices 0x34f8 GSEventRunModal + 164
50 UIKitCore 0x22c62c -[UIApplication _run] + 888
51 UIKitCore 0x22bc68 UIApplicationMain + 340
52 MyApp 0x46a040 main + 44 (AppDelegate.swift:44)
53 ??? 0x1c8d52dcc (缺少)
Questions / Requests
Recommended patterns for in-app language switching (LTR ⇄ RTL) to avoid direction/constraint races during animations? For example:
Should semantic direction be applied to the window/root view controller only?
Should we avoid rebuilding root during an active transition?
Any suggested synchronization (e.g., wait for transitions to finish) or APIs to call after rebuilding?
In third-party keyboard app, the app is crashed when call [[UIInputViewController textDocumentProxy] keyboardAppearance].
Environment)
iOS 26
crash dump call stack
Thread 0 Crashed: 0 libobjc.A.dylib 0x0000000198433008 objc_msgSend + 8
1 UIKitCore 0x00000001a1cea570 -[_UITextDocumentInterface _controllerState] + 68
2 UIKitCore 0x00000001a1ceaef0 -[_UITextDocumentInterface documentIdentifier] + 20
3 ThirtPartyKeyboardApp 0x0000000104aad190 -[NKBKeyboardViewController _updateThemeCenterAppearanceModeIfNeeds] + 56 (NKBKeyboardViewController.m:164)
I have an app where I create UIToolbars and add them to UIViews programatically. I've never used autolayout for anything, I've never assigned any constraints to anything, etc.
This worked fine pre-iOS 26.
Now I'm trying to build for iOS 26 (liquid glass) and my toolbars are spamming my debug pane with hundreds of lines of autolayout warnings. Here are some key phrases from the warnings:
Unable to simultaneously satisfy constraints.
Will attempt to recover by breaking constraint
Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
(Note: If you're seeing NSAutoresizingMaskLayoutConstraints that you don't understand, refer to the documentation for the UIView property translatesAutoresizingMaskIntoConstraints)
Does anybody know what happened and how I can get it to stop? The way things are, I can't use the debug pane for anything because of this spam.
When I run my Mac Catalyst app I'm getting unacceptable performance when resizing the window. Window resizing is very unresponsive/laggy.
Configuration:
The root view controller is a UISplitViewController (three pane split using UISplitViewControllerStyleTripleColumn).
Sidebar is configured. It's using a UICollectionView sidebar style (so it looks like NSOutlineView in AppKit).
On initial launch there is no selection and the second and third view controllers in the split have empty placeholder view controllers.
At this point window resizing is fine.
Now I make a selection in the sidebar. This populates the supplementary view controller with a view controller that uses a UITableView.
Now resizing the window performance is awful. Basically this is unusable. When resizing the window a bunch what looks to be Core Animation related logs flood the console during window resize:
cannot add handler to 3 from 1 - dropping Library: QuartzCore | Subsystem: com.apple.coreanimation
Now if I go to my app's Info.plist and add: UIDesignRequiresCompatibility entry with a value of TRUE and follow the same steps described above window resizing works as expected and I do not experience performance issues. Also with UIDesignRequiresCompatibility there is no "cannot add handlers" error logs flooding the console on window resize.
I want to create GIF file and then use UIImage to it.
UITabBarAppearance *appearance = UITabBarAppearance.alloc.init;
[appearance.stackedLayoutAppearance.normal setTitleTextAttributes:@{NSForegroundColorAttributeName:UIColor.redColor}];
[appearance.stackedLayoutAppearance.selected setTitleTextAttributes:@{NSForegroundColorAttributeName:UIColor.purpleColor}];
appearance.backgroundColor = UIColor.redColor;
self.tabBar.standardAppearance = appearance;
self.tabBar.scrollEdgeAppearance = appearance;
How to resolve?
Topic:
UI Frameworks
SubTopic:
UIKit
We are seeing this crash across several different iPad models, all of them running iPadOS 26.1.
The crash did not occur before, and it started appearing consistently over the past month.
This suggests that the issue may be related to changes introduced in recent iPadOS 26.1 builds.
Crash Log:
0 CoreFoundation 0xc5994 (缺少 UUID b4a0233bf37d3ef6a977e4f36199c5a4)
1 libobjc.A.dylib 0x31814 objc_exception_throw
2 Foundation 0x9465a4 (缺少 UUID 218da4dc727a3341b59e8fdb39a2d7c4)
3 Foundation 0x9469c8 (缺少 UUID 218da4dc727a3341b59e8fdb39a2d7c4)
4 Foundation 0x9468e0 (缺少 UUID 218da4dc727a3341b59e8fdb39a2d7c4)
5 PencilKit 0x100894 -[PKTextEffectsWindowObserver dealloc]
6 UIKitCore 0x22b28 (缺少 UUID a0e1cefbfd0136f9b82351b092e4dbc6)
7 UIKitCore 0x19918b8 (缺少 UUID a0e1cefbfd0136f9b82351b092e4dbc6)
8 PencilKit 0xe8448 -[PKTextInputInteraction willMoveToView:]
9 UIKitCore 0x22b1c (缺少 UUID a0e1cefbfd0136f9b82351b092e4dbc6)
10 UIKitCore 0x19918b8 (缺少 UUID a0e1cefbfd0136f9b82351b092e4dbc6)
11 UIKitCore 0x171e094 (缺少 UUID a0e1cefbfd0136f9b82351b092e4dbc6)
12 UIKitCore 0xc896a8 (缺少 UUID a0e1cefbfd0136f9b82351b092e4dbc6)
13 UIKitCore 0xc89d70 (缺少 UUID a0e1cefbfd0136f9b82351b092e4dbc6)
14 UIKitCore 0xc89c10 (缺少 UUID a0e1cefbfd0136f9b82351b092e4dbc6)
15 CoreFoundation 0x14f78 (缺少 UUID b4a0233bf37d3ef6a977e4f36199c5a4)
16 CoreFoundation 0x17fc2c (缺少 UUID b4a0233bf37d3ef6a977e4f36199c5a4)
17 UIKitCore 0xc89a44 (缺少 UUID a0e1cefbfd0136f9b82351b092e4dbc6)
18 UIKitCore 0xc8a53c (缺少 UUID a0e1cefbfd0136f9b82351b092e4dbc6)
19 UIKitCore 0xc8a638 (缺少 UUID a0e1cefbfd0136f9b82351b092e4dbc6)
20 UIKitCore 0xb9701c (缺少 UUID a0e1cefbfd0136f9b82351b092e4dbc6)
21 UIKitCore 0xb96cd0 (缺少 UUID a0e1cefbfd0136f9b82351b092e4dbc6)
22 UIKitCore 0xba0720 (缺少 UUID a0e1cefbfd0136f9b82351b092e4dbc6)
23 UIKitCore 0xb9a608 (缺少 UUID a0e1cefbfd0136f9b82351b092e4dbc6)
24 UIKitCore 0xca4fec (缺少 UUID a0e1cefbfd0136f9b82351b092e4dbc6)
25 UIKitCore 0x90878 (缺少 UUID a0e1cefbfd0136f9b82351b092e4dbc6)
26 UIKitCore 0x907b0 (缺少 UUID a0e1cefbfd0136f9b82351b092e4dbc6)
27 libdispatch.dylib 0x1adc _dispatch_call_block_and_release
28 libdispatch.dylib 0x1b7ec _dispatch_client_callout
29 libdispatch.dylib 0x38b24 _dispatch_main_queue_drain.cold.5
30 libdispatch.dylib 0x10ec8 _dispatch_main_queue_drain
31 libdispatch.dylib 0x10e04 _dispatch_main_queue_callback_4CF
32 CoreFoundation 0x6a2c8 (缺少 UUID b4a0233bf37d3ef6a977e4f36199c5a4)
33 CoreFoundation 0x1db3c (缺少 UUID b4a0233bf37d3ef6a977e4f36199c5a4)
34 CoreFoundation 0x1ca6c (缺少 UUID b4a0233bf37d3ef6a977e4f36199c5a4)
35 GraphicsServices 0x1498 GSEventRunModal
36 UIKitCore 0x9dba4 (缺少 UUID a0e1cefbfd0136f9b82351b092e4dbc6)
37 UIKitCore 0x46a78 (缺少 UUID a0e1cefbfd0136f9b82351b092e4dbc6)
38 ---------- 0xcd20 main + 35 (main.m:35)
39 ??? 0x18a026e28 (缺少)
crash_stacktrace.txt
Issue Summary:
On iOS 26.0.1 to 26.3, apps using multiple UITextFields for OTP input face a critical issue where the system autofill pastes the entire OTP string into a single text field, usually the focused one, rather than splitting digits across fields. Delegate events like textDidChange: do not trigger consistently on autofill, breaking existing input handling logic.
Expected Behavior:
OTP autofill should distribute each digit correctly across all OTP UITextFields.
Delegate or control events should fire on autofill to enable manual handling.
(BOOL)textField:(UITextField *)textField
shouldChangeCharactersInRange:(NSRange)range
replacementString:(NSString *)string {
if (string.length > 1) {
// Autofill detected - distribute OTP manually
for (int i = 0; i < string.length && i < self.arrayOTPText.count; i++) {
UITextField *field = self.arrayOTPText[i];
field.text = [NSString stringWithFormat:@"%c", [string characterAtIndex:i]];
}
UITextField *lastField = self.arrayOTPText[string.length - 1];
[lastField becomeFirstResponder];
return NO;
}
// Handle normal single character or deletion input here
return YES;
}
//
// Setup UITextFields - set .oneTimeCode on first field only
for (int i = 0; i < self.arrayOTPText.count; i++) {
UITextField *field = self.arrayOTPText[i];
field.delegate = self;
if (@available(iOS 12.0, *)) {
field.textContentType = (i == 0) ? UITextContentTypeOneTimeCode : UITextContentTypeNone;
}
}
What We’ve Tried:
Setting textContentType properly.
Handling OTP distribution in delegate method.
Verifying settings and keyboard use.
Testing on multiple iOS 26.x versions.
Impact:
Major usability degradation during OTP entry.
Forces fragile workarounds.
Inconsistent autofill reduces user confidence.
Request:
Request Apple fix OTP autofill to natively support multi-field UITextField OTP input or provide enhanced delegate callbacks for consistent behavior.
Did any one face this issue in recent time with iOS 26.0.1 to 26.3 beta version