15 Commits

Author SHA1 Message Date
Andrew Overton
38840677ff
[Tabs] Don't use MDCTabBarColorThemer in examples (#9125)
This PR makes it so that Tabs examples use the theming extension instead of the themer.

Related to #9061.
Related to #9063.
Related to #9062.
2019-12-05 15:30:13 -05:00
Yarden Eitan
efe61588a6
update (#7246)
We need to add @objc annotations to colorScheme and typographyScheme instances in our Swift examples, because we moved to Swift 4.2, the respondsToSelector won't find `setColorScheme:` and `setTypographyScheme:` setters otherwise.
2019-04-23 10:21:14 -04:00
featherless
2181084272
[automated] Standardize our open source license stanza to what Xcode generates. (#4985)
Removes the need to copy-paste stanzas from other files anymore as we'll rely on #4478 to generate the correct stanza for us instead.

This was an automated change generated by running a find-and-replace regular expression:

```
/\*
 Copyright ([0-9]+)-present the Material Components for iOS authors\. All Rights Reserved\.

 Licensed under the Apache License, Version 2\.0 \(the "License"\);
 you may not use this file except in compliance with the License\.
 You may obtain a copy of the License at

 http://www\.apache\.org/licenses/LICENSE-2\.0

 Unless required by applicable law or agreed to in writing, software
 distributed under the License is distributed on an "AS IS" BASIS,
 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied\.
 See the License for the specific language governing permissions and
 limitations under the License\.
 \*/
```

```
/\*
Copyright ([0-9]+)-present the Material Components for iOS authors\. All Rights Reserved\.

Licensed under the Apache License, Version 2\.0 \(the "License"\);
you may not use this file except in compliance with the License\.
You may obtain a copy of the License at

http://www\.apache\.org/licenses/LICENSE-2\.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied\.
See the License for the specific language governing permissions and
limitations under the License\.
\*/
```

```
/\*
 Copyright ([0-9]+)-present the Material Components for iOS authors\. All Rights Reserved\.
 Licensed under the Apache License, Version 2\.0 \(the "License"\);
 you may not use this file except in compliance with the License\.
 You may obtain a copy of the License at
 http://www\.apache\.org/licenses/LICENSE-2\.0
 Unless required by applicable law or agreed to in writing, software
 distributed under the License is distributed on an "AS IS" BASIS,
 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied\.
 See the License for the specific language governing permissions and
 limitations under the License\.
 \*/
```

```
// Copyright $1-present the Material Components for iOS authors. All Rights Reserved.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
// http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.
```
2018-08-31 12:13:07 -04:00
Robert Moore
175942d9e0
[Catalog] Fix Swift example imports (#4780)
Many of our Swift examples are either missing imports or are importing all of
MaterialComponents. Both of these will cause failures during internal builds.
2018-08-14 13:26:37 -04:00
featherless
50e1fd091d
[Catalog] Conversion to new App Bar View Controller API (#4696)
This PR updates the catalog to use the new MDCAppBar API throughout.
2018-08-07 09:30:37 -04:00
Robert Moore
cb08164a8d
[Tabs] Fix alerts in examples (#4480)
Several of the Tabs examples were using UIAlertControllers to present
multi-select options. Due to missing sourceView/sourceRect in the
popoverPresentationController, they would crash on iPads.  On iPhones,
they were shown as an action sheet and so did not require a source view.

## Sample screenshots
![simulator screen shot - ipad air 2 - 2018-07-06 at 14 14 28](https://user-images.githubusercontent.com/1753199/42394115-f90fd03a-8126-11e8-8471-b2d71e4b8b65.png)
![alignment-ipadair2-11 0 1](https://user-images.githubusercontent.com/1753199/42394116-f91d328e-8126-11e8-9a20-95e794145203.png)


Closes #3103
2018-07-06 14:37:26 -04:00
featherless
08403aecf7
[Tabs] Add umbrella headers for all extension targets. (#3476)
Also updated all imports to make use of the umbrella headers.

Pivotal story: https://www.pivotaltracker.com/story/show/157045283
2018-04-26 21:20:08 -04:00
featherless
a5c816e823
[Tabs] Replace MDCRaisedButton with contained button themer in TabBarIconExample. (#3499)
Pivotal story: https://www.pivotaltracker.com/story/show/157102565
Pivotal story: https://www.pivotaltracker.com/story/show/157102482

Before:
![simulator screen shot - iphone se - 2018-04-25 at 17 07 13](https://user-images.githubusercontent.com/45670/39277305-20f082c4-48bb-11e8-8a39-0f3d8f2e55a7.png)

After:
![simulator screen shot - iphone se - 2018-04-25 at 17 06 22](https://user-images.githubusercontent.com/45670/39277310-25e5b948-48bb-11e8-8914-af88737e5f77.png)
2018-04-26 12:53:32 -04:00
Yarden Eitan
7f7bc36202
[Catalog] Expose colorScheme + typographyScheme properties for all examples to use app wide theming (#3478)
Made colorScheme and typographyScheme properties in the class interfaces for all our examples.
Moved theming away from example inits and into viewDidLoad
Small update for slider example to allow it to grab the theming properly.
Related Pivotal: https://www.pivotaltracker.com/story/show/156616695
2018-04-25 15:15:17 -04:00
John Detloff
7799a15025
Update MDCTabBar color themer (#3361)
https://www.pivotaltracker.com/story/show/156171753


Before:
https://user-images.githubusercontent.com/1418389/38756680-56e300aa-3f38-11e8-8ab3-c4cae293c689.png
https://user-images.githubusercontent.com/1418389/38756681-574887e0-3f38-11e8-99bf-e4993d093a8a.png
https://user-images.githubusercontent.com/1418389/38756682-575790aa-3f38-11e8-858e-a44fe1312875.png
https://user-images.githubusercontent.com/1418389/38756683-576b5b94-3f38-11e8-9cb6-3f0b7bf49b55.png
https://user-images.githubusercontent.com/1418389/38756684-577a85ce-3f38-11e8-96f7-2b5d6a600ff8.png
https://user-images.githubusercontent.com/1418389/38756685-57854748-3f38-11e8-9fb9-2ba5c7c9142b.png
https://user-images.githubusercontent.com/1418389/38756686-57902276-3f38-11e8-91a6-d34bf054553f.png
https://user-images.githubusercontent.com/1418389/38756687-579e0684-3f38-11e8-9f3a-7b335aa0b9c7.png

After:
https://user-images.githubusercontent.com/1418389/38756708-6825c8c0-3f38-11e8-9f00-bc5a871cc26b.png
https://user-images.githubusercontent.com/1418389/38756709-68338faa-3f38-11e8-89c5-588cba6711f6.png
https://user-images.githubusercontent.com/1418389/38756710-68443d46-3f38-11e8-8894-8d11096e0650.png
https://user-images.githubusercontent.com/1418389/38756711-68502836-3f38-11e8-8cba-2f492c25042a.png
https://user-images.githubusercontent.com/1418389/38756713-685fa5d6-3f38-11e8-868a-5481e1a8d5f1.png
https://user-images.githubusercontent.com/1418389/38756714-686a62b4-3f38-11e8-8a36-b4fd948ea00b.png
https://user-images.githubusercontent.com/1418389/38756715-6875927e-3f38-11e8-9a9a-5371514156a5.png
https://user-images.githubusercontent.com/1418389/38756716-68817f26-3f38-11e8-8d2b-162dda9a6780.png
2018-04-17 14:23:36 -04:00
Will Larche
96fb533554 [Catalog] Fixes improper use of Bundle and assets (#2118)
* [Catalog] Fixing bundle usage in some examples.

* [Examples] Correcting use of assets and bundles.

* [Examples] Formatting.
2017-10-08 15:04:48 -04:00
Martin Petrov
1e14d41091 Explicitly annotating some known ObjC methods. (#1617)
This improves Swift4 compatibility, see:
https://help.apple.com/xcode/mac/current/#/deve838b19a1
2017-07-10 19:46:22 -04:00
Martin Petrov
ec1feb81a5 [MDCPalette] Use class properties (#1470)
* Replacing methods with class properties.

* Updating docs to reflect new Swift call style.

* Updating examples.

* Updating ObjC examples to use dot syntax
2017-05-30 08:20:00 -04:00
Justin Shephard
95d71cfaac [Project] Clear warnings within project (#1205)
* [Project] - Clear warnings within project

* [Project] - Clean errant code
2017-02-14 18:53:02 -05:00
Brian Moore
fd074fca51 [New Component] Tab component with MDCTabBar (#1164)
* Initial implementation of MDCTabBar and private MDCItemBar (#711)

* Add initial headers for MDC*Bar

* Initial chunk of work

* It works…ish

* Update demo images and update style with appearance

* Update Podfile.lock

* Merge

* Merge

* Revert bottom bar for now

* Update description

* Formatting and cleanup

* Manual revert of mistaken changes

* Manual revert of mistaken changes

* Manual revert of mistaken changes

* Update with consistent terminology

* Update constant names

* Update localizable strings

* More naming updates

* Rename TabBar to Tabs, move ItemBar into Tabs/private

* Rename string keys

* Rename string files from ItemBar to Tabs

* Rename string keys header

* Update podspec and move bundle

* Reset Podfile.lock in preparation for re-updating

* Clean update to Podfile.lock, adding MaterialTabs

* Update import paths

* Move CatalogByConvention method to end of file

* Add copyright notice on all h/m files

* Add safe fallbacks for switches

* Use conventional common init method name

* Podfile.lock checksum update

* [Tabs] Initial README template and changes

* [Tabs] Updating intro content.

* [Tabs] Commenting out mention of bottom navigation bars in readme.

* Initial implementation of MDCTabBar and private MDCItemBar (#711)

* Add initial headers for MDC*Bar

* Initial chunk of work

* It works…ish

* Update demo images and update style with appearance

* Update Podfile.lock

* Merge

* Merge

* Revert bottom bar for now

* Update description

* Formatting and cleanup

* Manual revert of mistaken changes

* Manual revert of mistaken changes

* Manual revert of mistaken changes

* Update with consistent terminology

* Update constant names

* Update localizable strings

* More naming updates

* Rename TabBar to Tabs, move ItemBar into Tabs/private

* Rename string keys

* Rename string files from ItemBar to Tabs

* Rename string keys header

* Update podspec and move bundle

* Reset Podfile.lock in preparation for re-updating

* Clean update to Podfile.lock, adding MaterialTabs

* Update import paths

* Move CatalogByConvention method to end of file

* Add copyright notice on all h/m files

* Add safe fallbacks for switches

* Use conventional common init method name

* Podfile.lock checksum update

* [Tabs] Initial README template and changes

* [Tabs] Updating intro content.

* [Tabs] Commenting out mention of bottom navigation bars in readme.

* [Tabs] Correcting resources key in pod spec.

* [Tabs] Correcting implementation of resources key in pod spec.

* [Tabs] Removing duplicate entry in pod spec (cherry pick artifact.)

* [Tabs] Overview written

* [Tabs] Mentioning badges in overview.

* [Tabs] Removing TODO in ready.

* [Tabs] Duplicating tabs example in prep for splitting it into two.

* [Tabs] Examples crudely split apart.

* [Pods] Update of lock, catalog and tests for new version.

* [Tabs] Refactored examples to be in style of supplemented examples.

* [Tabs] Formatting.

* [Tabs] Formatting.

* [Tabs] Formatting.

* Add usage examples

* Add usage examples

* Fix bad merge

* Update import documentation

* Small edits

* Do not show badges for title-only tabs

Also updates the text-only example to toggle upcasing rather than increment non-existent badges.

* Update title-only documentation re: badges

* Update README.md

* Update Podfile.lock

* Manually fix Podfile.lock

* Feature tabs rebase from develop (#7)

* [Docs] Add hero image to top-level README.md (#1100)

* Added hero image.

* Added retina-sized hero image.

* Add `srcset` image tag.

* Flow image to the right.

* Update README.md

* Fixed srcset, duh.

* Update README.md

* Update README.md

* Gave up on srcset+markdown for now.

* Update README.md

* Update README.md

* Increased image size.

* Remove redundant RTL frame adjustment (#1103)

* Made build/test scripts exit with failure if anything failed. (#1088)

* [ReadMes] - First image of each component is too big (#1110)

* MDC_#917 - Activity Indicator Readme Update

* MDC_#917 - Updated remaining readme image links

* MDC_#917 - Fixed typo

* [Site] Removing unused files for and from generated doc site. (#1108)

* [ReadMes] - Updated asset name for collection_cells (#1111)

* Enable Travis CI integration (#1095)

* Add file to kick off Travis

* Checking Travis CI's installed Xcode and simulator devices.

* Adding Cocoapods init to Travis CI config.

* Enabling building in Travis CI config.

* Added temporary dumping of the log file on error.

* Switched Shrine to manual signing.

* Dump Travis code signing options.

* Adding CocoaPods version to debug output.

* Remove code signing reporting from Travis CI config.

* Forcing `build_all` to skip code signing.

* Switching Shrine back to automatic provisioning style.

* Re-enabling testing in Travis CI.

* Bump up verbosity of testing.

* Changing test device from 10.2 to 10.1 to work around Travis CI bug.

* Remove the printing of available devices, Xcode will print them out on error.

* Added more context on failure for Travis CI builds only.

* Re-enable CI for our normal branches.

* Remove "do not merge" file.

* Removing our development team and switching Catalog to automatic profiles.

* Removing our development team and switching Bare to automatic profiles.

* Removing our development team and switching Pesto to automatic profiles.

* Add Travis CI build badge to README.md (#1112)

* Add uploading of testing code coverage results to codecov.io (#1114)

This won't do anything yet, but once we start emitting code coverage files it will.

* Enable test code coverage reports in Xcode and in Travis CI. (#1115)

* Add codecov.io badge to README.md. (#1116)

* Add Codecov config to exclude uninteresting paths. (#1118)

* Extracts header code into method removing repetition (#1119)

* [AppBar] Header stack view in AppBarController (#1121)

Since the header stack view is going to be laid out with auto layout, it should be inited with a CGRectZero. Doing it with self.view.bounds creates a tiny loop since the view is not loaded yet.

* Initial implementation of MDCTabBar and private MDCItemBar (#711)

* Add initial headers for MDC*Bar

* Initial chunk of work

* It works…ish

* Update demo images and update style with appearance

* Update Podfile.lock

* Merge

* Merge

* Revert bottom bar for now

* Update description

* Formatting and cleanup

* Manual revert of mistaken changes

* Manual revert of mistaken changes

* Manual revert of mistaken changes

* Update with consistent terminology

* Update constant names

* Update localizable strings

* More naming updates

* Rename TabBar to Tabs, move ItemBar into Tabs/private

* Rename string keys

* Rename string files from ItemBar to Tabs

* Rename string keys header

* Update podspec and move bundle

* Reset Podfile.lock in preparation for re-updating

* Clean update to Podfile.lock, adding MaterialTabs

* Update import paths

* Move CatalogByConvention method to end of file

* Add copyright notice on all h/m files

* Add safe fallbacks for switches

* Use conventional common init method name

* Podfile.lock checksum update

* Initial implementation of MDCTabBar and private MDCItemBar (#711)

* Add initial headers for MDC*Bar

* Initial chunk of work

* It works…ish

* Update demo images and update style with appearance

* Update Podfile.lock

* Merge

* Merge

* Revert bottom bar for now

* Update description

* Formatting and cleanup

* Manual revert of mistaken changes

* Manual revert of mistaken changes

* Manual revert of mistaken changes

* Update with consistent terminology

* Update constant names

* Update localizable strings

* More naming updates

* Rename TabBar to Tabs, move ItemBar into Tabs/private

* Rename string keys

* Rename string files from ItemBar to Tabs

* Rename string keys header

* Update podspec and move bundle

* Reset Podfile.lock in preparation for re-updating

* Clean update to Podfile.lock, adding MaterialTabs

* Update import paths

* Move CatalogByConvention method to end of file

* Add copyright notice on all h/m files

* Add safe fallbacks for switches

* Use conventional common init method name

* Podfile.lock checksum update

* [Tabs] Initial README template and changes

* [Tabs] Updating intro content.

* [Tabs] Commenting out mention of bottom navigation bars in readme.

* [Tabs] Overview written

* [Tabs] Correcting resources key in pod spec.

* [Tabs] Correcting implementation of resources key in pod spec.

* [Tabs] Mentioning badges in overview.

* [Tabs] Removing TODO in ready.

* [Tabs] Removing duplicate entry in pod spec (cherry pick artifact.)

* [Tabs] Duplicating tabs example in prep for splitting it into two.

* [Tabs] Examples crudely split apart.

* [Pods] Update of lock, catalog and tests for new version.

* [Tabs] Refactored examples to be in style of supplemented examples.

* [Tabs] Formatting.

* [Tabs] Formatting.

* [Tabs] Formatting.

* Add usage examples

* Add usage examples

* Update import documentation

* Small edits

* Do not show badges for title-only tabs

Also updates the text-only example to toggle upcasing rather than increment non-existent badges.

* Update title-only documentation re: badges

* Update README.md

* Update Podfile.lock

* Manually fix Podfile.lock

* [Tabs] Making delegate methods all optional. (#8)

* [Tabs] Now that protocol has optional methods, putting in safety for the method calls. (#9)

* [Tabs] Small changes for UIAppearance support.

* [Tabs] Formatting examples.

* [Tabs] Changed icon example to be an appBar’s bottomBar.

* [Tabs] Styling of examples.

* [Tabs] Example layout correction.

* [Tabs] Example update.

* [Tabs] Example has more ‘content’.

* [Tabs] Removing unused delegate method in example.

* [Tabs] Formatting of code for style.

* [Tabs] Better unselected style choice in icon example.

* [Tabs] More content in example vies.

* [Tabs] iOS 8 support for icons example.

* [Tabs] Still image.

* [Tabs] Video added.

* [Tabs] Renaming for clarity.

* [Tabs] Correcting comment.

* [Tabs] Better organization of example view creation methods.

* [Tabs] Cleaning up imports in example.

* [Tabs] Better code for incrementing badge in example.

* [Tabs] Using local variable vs @property in example

* [Tabs] Example format correction.

* [Tabs] Alphabetizing lists in examples.

* [Tabs] Example code style improvement.

* [Tab] Example NSAssert. Safety.

* [Tabs] Comments and clarity in example.

* [Tabs] clang-format in examples.

* [Tabs] Text color correction in example.

* [Tabs] Catalog tile.

* [Tabs] clang-format in tile.

* [Tabs] Adding IBOutlet for delegate (optional.)

* [Tabs] Fix 32-bit build

* [Tabs] Interface Builder example.

* [Tabs] Beginning Swift example.

* [Tabs] More swift example content.

* [Tabs] Swift example complete

* [Tabs] Swift example PR note implementations.

* [Tabs] Swift formatting

* [Tabs] Formatting in example

* [Tabs] Formatting swift example.

* [Tabs] Swift example clarity.

* [Tabs] Example wrapping revert.

* [Tabs] Example wrapping revert.

* Fixes from review
2017-01-25 11:52:40 -05:00