Closed bryanjclark closed 4 years ago
One thing that occurs to me is that I don't think we need to do if let on the textField here, as it's an implicitly unwrapped optional
I'd expected that to work, too, but I was seeing this in Xcode:
...but I'll assign it to a variable like you suggest!
Oh interesting! After a bit of Googling, I see now that since Swift 4.2, implicit optional-ness is only part of a variable declaration, so any variables assigned from an implicitly-unwrapped optional will have an optional type (https://swift.org/blog/iuo/#implicit-unwrapping-is-part-of-a-declaration).
This looks good, thanks for making the change 👍
Hey there! Thanks for making such a fantastic app. It's been on my homescreen for a while, it's a delightful nudge to keep reading.
One small suggestion-nit is that it'd be faster to update the progress for a book if the textfield's contents are selected when the "Update" button is tapped. I'm often reading a book, and want to update the progress from, say,
32%
to48%
, so it'd be faster if I could just type48
instead of having to delete the contents and then type48
.(I know this is a terribly-small nit! No worries if you don't want to merge it!)
Here's a GIF of it in action:![select-textfield-contents-on-modal-presentation](https://user-images.githubusercontent.com/868389/87844778-98e38d80-c875-11ea-8e9b-d09fdfd41889.gif)