Commit Graph
147 Commits
Author SHA1 Message Date
Brent Simmons 84e653a238 Rename the Find in Article notification handler to handleFindInArticle. Disable Find menu items when no web view. 2026-11-22 20:31:38 -08:00
Dave Marquard abb71358b6 Use the system find bar for Find in Article on iOS
Find in Article was a custom search bar plus JavaScript that walked the
page text and drew its own highlights. It predates WKWebView's
UIFindInteraction (iOS 16), and its state lived in the page, so on iPad,
where the article view stays on screen and reuses its web view for the
next article, the bar kept the previous article's text and result count
and Next / Previous did nothing.

Turn on isFindInteractionEnabled and drive the web view's find
interaction instead. ArticleViewController handles find:, findNext: and
findPrevious:, so the system Find menu (Find, Find Next, Find Previous)
works with a hardware keyboard, and the old ⌘F key command goes away.
It also passes Use Selection for Find to the web view, which otherwise
only gets it while it's first responder, so the menu item works when the
view controller has focus. The find bar is dismissed when the article
changes or the article view goes away. The share sheet's Find in Article item still works.

Verified on iPad Pro 11-inch (iOS 27.0) and iPhone 18 Pro (iOS 27.2)
simulators: ⌘F, ⌘G, switching articles from the timeline and with the
next-article button, and the share sheet item.
2026-11-22 07:06:12 -08:00
Brent Simmons 38122dd028 Move next-unread button to right below next/prev buttons on Duo when buttons are in vertical mode. Easier to hit with the thumb. 2026-11-19 09:30:10 -08:00
Brent Simmons 11251847b5 Show Reader View button in vertical row (instead of side row) on Duo. 2026-11-19 09:20:13 -08:00
Brent Simmons e85d49b352 Fixed bug with fullscreen articles on iOS where going back to timeline would make the app would forget that you were in fullscreen mode. 2026-11-15 20:43:05 -08:00
Brent Simmons 90aaf2e632 Merge branch 'main' of https://github.com/Ranchero-Software/NetNewsWire 2026-11-12 13:48:46 -08:00
Brent Simmons 859bbe5476 Add iOS setting for enabling swipe to next/previous articles. Off for new users, but true by default for existing users. 2026-11-12 13:48:34 -08:00
Brent Simmons 24a5bd9642 Make arrow key navigation work from timeline to article view and back. Make up and down arrow keys scroll in article view. Fixes #5538. 2026-11-12 10:37:19 -08:00
Brent Simmons 6943a6f403 Move function to private extension. Simplify comment. 2026-11-05 12:14:40 -08:00
Brent Simmons f73735e7fc Clarify comments on iOS 27 compiler checks. 2026-11-04 11:49:08 -08:00
Brent Simmons f707ab64e0 Update search bar position in one place. 2026-11-04 11:42:53 -08:00
Brent Simmons ec90003718 Merge pull request #5533 from dave-atx/fix-iphone-duo-layout
Drop the empty navigation bar over articles when the bars move to a side
2026-11-04 09:54:44 -08:00
Brent Simmons ac1e1a8571 Merge pull request #5510 from stuartbreckenridge/fix/modernise-find-in-article
🔎 Refresh article search controls
2026-11-04 09:41:57 -08:00
Dave Marquard 4a035abd92 Drop the empty navigation bar over articles when the bars move to a side
The article puts an empty view in the navigation bar's title so a tap on
the bar can enter full screen. With the iOS 27.1 vertical bar (the iPhone
Duo's outer screen, and the inner one in landscape) the bar buttons move
to a side edge, and that title view is all that's left in the top bar. It
keeps an empty bar across the top of the article.

Leave the title view out while verticalBarEdge is set, and update it when
the trait changes. Tapping the bar to enter full screen isn't available
in that layout, which only matters with the full-screen setting on.

The new API is behind #if compiler(>=6.4.2), the Swift in Xcode 27.2, so
Xcodes whose SDKs don't have it still build.

Verified in the iOS 27.2 iPhone Duo simulator: the outer screen in both
orientations and the inner one in landscape. Inner portrait keeps its
horizontal bar and the tap zone.

Fixes #5530.

Written with help from Claude Code.
2026-11-03 14:02:00 -08:00
Dave Marquard 84d894d4d6 Let a left-edge swipe reveal the timeline over an article
The article is a UIPageViewController, and a no-op pan recognizer on its
internal scroll view refuses simultaneous recognition within 40pt of the
left edge, so swiping from there doesn't page back and navigate back at
the same time. It refused every other recognizer there too, including the
split view's reveal gesture. The swipe did nothing over the article while
it still worked alongside the toolbars, where the page view controller
isn't under the touch.

Narrow the refusal to the page view controller's own pan. Paging is still
held back near the edge, and everything else gets the touch.

Found on an unfolded iPhone Duo, where the article fills a 669pt-wide
expanded split view and the timeline is otherwise only reachable from the
sidebar button.

Written with help from Claude Code.
2026-11-03 14:02:00 -08:00
Stuart Breckenridge 2cbf2beda7 Update compiler checks 2026-10-25 13:35:13 +08:00
Stuart Breckenridge f0a59bb194 Fix for CI only 2026-10-25 13:28:33 +08:00
Stuart Breckenridge 3cfee08acf 🔎 Refresh article search controls
Add translucent search controls, reserved-region margins and keyboard-aware spacing.
2026-10-25 10:38:15 +08:00
Brent Simmons 2ce850441b Make AppDefaults an enum instead of singleton class. 2026-10-22 13:46:32 -07:00
Brent Simmons 26de11a799 Fix bug where a custom gesture recognizer delegate could prevent timeline rows from being tapped on iOS 27 beta. 2026-08-14 10:29:24 -07:00
Brent Simmons 3da877e99d Fix the Reader View button sometimes disappearing from the article toolbar by re-syncing its state whenever the current article page changes and by ignoring stale extractor callbacks. 2026-08-08 10:40:01 -07:00
Brent Simmons 9256a6858a Stop overriding UISplitViewController.show(_:) which causes issues with tapping timeline rows (and other issues). 2026-08-06 13:05:39 -07:00
Brent Simmons 00efcc2bcf Defer the pending article page flush until the swipe transition has finished, to avoid a UIKit assertion crash. Fixes #5384. 2026-08-05 09:37:56 -07:00
Brent Simmons 4021fb3639 Fix bug where reader view articles could open scrolled to the middle instead of the top. Fixes #5243. 2026-08-03 09:27:27 -07:00
Brent Simmons 6d259827f0 Use a constant logging system name instead of getting it from Bundle. 2026-08-02 10:33:23 -07:00
Brent Simmons 7ed23bde76 Use SF Symbols instead of custom icons for the reader view icon. 2026-07-08 09:52:23 -07:00
Brent Simmons 4d9a6407f4 Get unread count from AccountManager rather than AppDelegate. Also: fix bug where next unread button would be enabled when there is just one unread article and it's the current article. Fixes #5008. 2026-07-07 10:57:38 -07:00
Brent Simmons 7b136b6bbe Fix UIPageViewController setViewControllers crash by re-checking transition state in async block. 2026-05-30 12:54:49 -07:00
Brent Simmons b100374065 Fix iOS pager crash: defer setViewControllers when called during active UIPageViewController transition. 2026-05-18 16:41:21 -07:00
Brent Simmons a8885d0444 Fix iOS crash on article disappear: don't animate showBars() in viewWillDisappear. 2026-05-18 16:24:30 -07:00
Stuart Breckenridge d44d20b20d 🐛 Fix full-screen article view
Remove the split view collapse check from the full-screen availability
condition and drop the trait collection transition override that forced
bars to appear on rotation. Fixes #5145.
2026-04-16 21:06:44 +08:00
Brent Simmons c12970dfc4 Space out the toolbar items on iOS 17/18. Give the article extractor button a stable width, so it doesn’t change widths when the progress indicator is showing. 2026-04-02 10:33:14 -07:00
Brent Simmons 50af78936c Fix bug on iOS 17 and 18 where the article content would be active and not blurred behind the navbar. 2026-03-31 09:02:00 -07:00
Brent Simmons 95dfaae20c Make sure reader button has no tint on iOS 26 and up. 2026-03-30 09:40:27 -07:00
Brent Simmons 5974d0adc4 Make sure next unread button is centered in article view toolbar. 2026-03-30 09:17:27 -07:00
Brent Simmons d4a95ae007 Fix tint color for reader view button. 2026-03-29 22:12:33 -07:00
Brent Simmons 4a2c62cc6c Make app run on iOS 17 and up. 2026-03-29 21:31:02 -07:00
Stuart Breckenridge 8d51ee3c8e 🩹 Fix 5097 & 5115 2026-02-17 18:30:21 +08:00
Brent Simmons 4698696d8c Add logger to ArticleViewController. 2026-01-28 13:22:14 -08:00
Brent Simmons 8ec78a26bc Use label color instead of accent color so that the button doesn’t appear blue. Fix #5036. 2026-01-27 19:29:11 -08:00
Brent Simmons a9b4efeaab Remove most uses of forEach. (Note: not talking about SwiftUI ForEach, which is fine and good and should not be removed.) 2026-01-04 12:36:41 -08:00
Brent Simmons 9ff1bd9836 Fix various SwiftLint warnings. 2026-01-02 17:50:35 -08:00
Brent Simmons 0832a7cf67 Fix various SwiftLint warnings. 2026-01-01 17:55:12 -08:00
Brent Simmons c4fe05617e Move some things to RSCore. 2025-11-19 19:33:12 -08:00
Brent Simmons beeeabba24 Convert AppAssets to shared Assets. 2025-11-19 10:38:18 -08:00
Brent Simmons 39ffd38461 Continue conversion from AppAssets to shared Assets. 2025-11-18 22:08:33 -08:00
Brent Simmons 9efde554d4 Clean whitespace-only lines. 2025-11-05 11:22:10 -08:00
Brent Simmons 5e39b569a7 Merged main to branch. 2025-11-01 15:53:33 -07:00
Stuart Breckenridge 00d34234ff 🔥 Remove debug UIResponder code 2025-09-28 10:54:46 +08:00
Stuart Breckenridge c095334cff 🩹 Stop keyboard reappearing after it dismissal
Only allow the article search bar to start editing viewDidAppear. This stops the keyboard appearing at the wrong time. Fixes #4796
2025-09-28 10:53:25 +08:00