-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
Reader: Add a way to view posts that are restricted #23853
Conversation
@@ -247,6 +247,12 @@ class ReaderDetailViewController: UIViewController, ReaderDetailView { | |||
|
|||
webView.isP2 = post.isP2Type() | |||
|
|||
if post.content?.hasSuffix("[…]") == true { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There gotta be a better way to test, but I couldn't find one. I think it'll do for now.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey, @nbradbury, would you mind checking how the scenario from the PR is detected in Android?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
📲 You can test the changes from this Pull Request in WordPress Alpha by scanning the QR code below to install the corresponding build.
|
📲 You can test the changes from this Pull Request in Jetpack Alpha by scanning the QR code below to install the corresponding build.
|
I wonder if a generic |
.font: UIFont.preferredFont(forTextStyle: .body), | ||
.foregroundColor: UIColor.label | ||
]) | ||
let range = string.mutableString.range(of: "%@") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess we'd just have to hope the %@
in the original format doesn't get translated into %1$@
.
Probably not for this PR, but it should not be too difficult to find out the difference between the String format and the formatted string, and compute the argument values positions in the final String.
func formattedString(format: String, args: [Any]) -> (final: String, argsRange: [Range])
Version |
Fixes #23638 by adding support for posts that can't be viewed in the Reader.
Simulator.Screen.Recording.-.iPhone.16.Pro.-.2024-11-21.at.16.03.55.mp4
To test:
Regression Notes
Potential unintended areas of impact
What I did to test those areas of impact (or what existing automated tests I relied on)
What automated tests I added (or what prevented me from doing so)
PR submission checklist:
RELEASE-NOTES.txt
if necessary.Testing checklist: