12 Commits

Author SHA1 Message Date
Sam Morrison
c63eeafda4
[Chips] Pixel align subviews (#2739)
* [Chips] Pixel align subviews

* Document MDCSizeCeilWithScale

* Scale arg
2017-12-19 16:23:36 -05:00
Will Larche
1bd5590bbb
[Kokoro] Support for TextFields, Math, and Typography (#2432)
* [TextFields] Kokoro work.

* [Math] Imports needed for kokoro.

* [Kokoro] Support for MDCMath.

* [TextFields] Alphabetizing.

* [Kokoro] Formatting.

* [Kokoro] Formatting
2017-11-16 22:25:52 -05:00
featherless
5c87a3fd9a
[BottomSheet] Add BUILD file for kokoro + bazel support. (#2396)
* [BottomSheet] Add BUILD file for kokoro + bazel support.

I will be sending out a variety of pull requests soon to the bottom sheet. Adding the component to kokoro will let the PRs land more quickly.

* Remove unused load statements.
2017-11-10 17:35:16 -05:00
Sam Morrison
663120a830 Shapes (#2086) 2017-10-04 15:29:06 -04:00
Robert Moore
65bf96dd7c [Math] MDCRectAlignToScale treats scale 0 as 1 (#2045)
Rather than potentially returning a CGRectNull and causing UIKit crashes
if it's assigned to a view's frame or bounds, treat a scale of 0 as a
scale of 1.

Closes #2044
2017-09-27 20:28:37 +09:00
Robert Moore
4fd3a41963 [Math] Round CGPoint and align UIView centers (#2042)
Although it is possible to currently align a CGRect (frame) to a
pixel-aligned bounding rectangle, in some cases manipulating the frame
is neither possible nor desirable (such as when the transform is not the
identity).  Adding two new methods to support rounding a CGPoint to a
pixel and aligning the center point of a UIVIew given its bounds.
2017-09-27 01:54:56 +09:00
Junius Gunaratne
d200d6cdef [Math] Add degrees to radians method to MDCMath (#2015)
* Adding radian/degree math

* Cast to float
2017-09-21 10:02:58 -07:00
Robert Moore
2a65ea5809 [Math] Adding more unit tests for rect alignment (#1751)
Adding unit tests for a scale of zero and CGRectNull inputs.

References #1723
2017-08-08 12:03:02 -04:00
Robert Moore
e03ad370c6 [Math] Align frames to pixel boundaries (#1730)
Adding a new function to realign a CGRect (frame) to pixel boundaries
based on the screen scale. After a review of the catalog, I'm updating
the areas where I found misaligned frames.

Closes #1723
2017-08-07 16:46:32 -04:00
Sam Morrison
f466588e4f [Feature Highlight] Swipe to dismiss (#1636)
* Add new Dismiss gesture recognizer to allow swiping away feature highlights

* Tap outside the feature highlight to dismiss

* Formatting and cleanup

* Fix unused var warnings

* Correctly cancel animation when gesture recognizer gets cancelled

* Fade out text when starting dismiss gesture

* Formatting

* Ignore multiple touches

* Remove debug state logging

* Fade text in/out during dismissal gesture

* Address comments

* Prevent floating point conversion warnings

* MDCPow / MDCSqrt

* Add accessibilityPerformEscape to feature highlight
2017-07-17 17:59:03 -04:00
Will Larche
d8a58feecd [All] Formatting. (#1329) 2017-04-18 18:10:02 -04:00
Will Larche
ff5d165869 [Math] New private math component (#1325)
* [Math] New private component.

* [Math] Putting MaterialMath everywhere it could help.
2017-04-17 16:14:17 -04:00