-
Notifications
You must be signed in to change notification settings - Fork 13
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
Feature/active label #55
Feature/active label #55
Conversation
- Modified podspec for ActiveLabel subspec. - Increased version to 1.3.6 - Updated readme with details for ActiveLabel. - Added ActiveLabel to Examples - Added Unit Tests for ActiveLabel.
This reverts commit 03639e5.
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.
One question I have is how does this behave when using dynamic type? Do the gradient animations scale accordingly?
Examples/UtiliKit-iOSExample/ViewController/ActiveLabelViewController.swift
Outdated
Show resolved
Hide resolved
Examples/UtiliKit-iOSExample/ViewController/ActiveLabelViewController.swift
Outdated
Show resolved
Hide resolved
- Added some backticks to the ActiveLabel documentation.
- Added some backticks to the documentation. - Created loadingGray static class constant to be used for the default color. - Removed use of defer in initializers since it isn't needed. - Moved constraint setup into its own function which is called when configuring the loading views. - Cleaned up code.
- Modified UnitTests and Added specific Snapshot Tests.
Replaced isLoading Bool to now use the State enum. Tweaked documentation.
…UtiliKit into feature/ActiveLabel
…g indicators do not scale with Dynamic Type.
@tylermilner Due to some weirdness with trying to dynamically size the loading views based on the Content Size Category change I don't feel like supporting it at this time is worthwhile. I have some ideas on how to handle it, but I don't think they would be worth introducing in a version 1 of this class. I've added a Note to the class documentation calling out that the loading views don't support resizing via dynamic type. |
…ced under ActiveLabel. Changed ActiveLabel configuration properties to used the Configuration.default values. Removed showLoadingViewsInStoryboard and isSnapshotTesting in favor of a private isGradientCentered bool to signal centering the gradient. Added public function configureForSnapshotTesting that sets isGradientCentered to true in order to keep that variable private.
Moved configurationChanged() to private and added didSet to all configuration properties that now call configurationChanged() Updated default state value to .text(nil) Added configuredForSnapshotTest public function in order to center the gradient for snapshot tests. Fixed textDidUpdate to use new State initializer. Corrected some comments. Fixed tests to work properly with latest changes. Updated ReadMe to reflect changes. Added line to ReadMe about configuring for snapshot tests.
I just pushed an update that addresses the open issues for the PR. |
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.
@JobsIsMyHomeboy I think this should be good to go after you add a CHANGELOG
entry!
…re now done with a library installed via Carthage.
Codecov Report
@@ Coverage Diff @@
## master #55 +/- ##
======================================
Coverage 100% 100%
======================================
Files 3 4 +1
Lines 204 413 +209
======================================
+ Hits 204 413 +209
Continue to review full report at Codecov.
|
@JobsIsMyHomeboy It looks like Codebeat is complaining about a few issues regarding |
@wmcginty @tylermilner I don't have write access so I can't merge. :( |
Is there anything we can do to fix any/some of those Codebeat issues @JobsIsMyHomeboy ? |
…onfiguration by adding a secondary struct for the LoadingView portion of the variables. Updated ReadMe and fixed tests with configuration changes.
…ld resolve the function too long warning.
fe9cc31
This adds a new subclass of UILabel called ActiveLabel. It can be used to show activity for a label while maintaining some spacing on the screen as well as visual indicator that something is happening. The use of nil on the label is what turns the activity indicator on and off.