20 Commits

Author SHA1 Message Date
Jeff Verkoeyen
c34de39e30 Internal change.
PiperOrigin-RevId: 397316843
2021-09-17 07:45:01 -07:00
Wenyu Zhang
a3381717f7
Fix the bazel BUILD files and snapshot that were restored unintentionally.(#9983) 2020-04-29 11:00:00 -04:00
Randall Li
0100cfe414 [MDC-iOS/BottomSheet] Fix dismissOnDraggingDownSheet behavior
The bottom sheet incorrectly allowed the sheet to be drag dismissed when `dismissOnDraggingDownSheet` was set to NO.

This change permits the gesture to dismiss to begin but prevents it from actually closing the sheet.

https://github.com/material-components/material-components-ios/issues/9723

Closes https://github.com/material-components/material-components-ios/pull/9885

PiperOrigin-RevId: 307802500
2020-04-22 06:21:26 -07:00
Jeff Verkoeyen
8abbb099a9 Delete all bazel support.
We no longer support bazel.

This PR deletes everything related to bazel support from our repo.

Closes https://github.com/material-components/material-components-ios/pull/9968

PiperOrigin-RevId: 306227127
2020-04-13 07:13:47 -07:00
featherless
162a063bda
[bazel] Remove all unused mdc_objc_library loads. (#9376)
Found by searching for all references to `\bmdc_objc_library` and removing load statements from files that only returned one result.

Clean up as part of https://github.com/material-components/material-components-ios/issues/9363
2020-01-02 14:34:36 -05:00
featherless
b7cf0de915
[bazel] Remove all unused swift_library load statements. (#9369)
Found by searching for all references to `\bswift_library` and removing load statements from files that only returned one result.

Clean up as part of https://github.com/material-components/material-components-ios/issues/5491
2020-01-02 11:01:31 -05:00
featherless
0a0bc4b47b
[automated] Ran buildifier on all BUILD files. (#9366)
```
find . -name BUILD | xargs buildifier
```

This is in preparation of https://github.com/material-components/material-components-ios/issues/9363
2020-01-02 10:05:07 -05:00
Randall Li
b86e38f249
[UIApplication] Use prefix on category name for UIApplication+AppExtensions so that category names don't conflict in ObjC namespace. (#9277)
[UIApplication] Use prefix on category name for UIApplication+AppExtensions so that category names don't conflict in ObjC namespace.

sourced from cl/285233749
2019-12-20 13:24:53 -05:00
Robert Moore
4d435b8096
[Application] Use Starlark macros in BUILD file. (#8200)
Update the BUILD file to use more Starlark macros. Makes releasing easier.

Part of #8150
2019-08-02 16:34:59 -04:00
Andrew Overton
056e4701f0
Make pod install work on Cocoapods 1.6.0.beta.2 (#5966)
# Original PR description:

On Cocoapods version 1.6.0 beta 2 we get an error on pod install because certain test targets don't have any sources to compile. This PR adds some skeleton unit test source files to get that working. Is everyone okay with these (for now) basically empty files?

Closes #5825

# FInal PR description:

The original aim of this PR was to get the project working with the Cocoapods 1.6 beta.

I initially didn't know where to begin getting it to work, so I used `pod lib lint` to get answers. `pod lib lint` had issues with the following things:

1. test_specs not having any sources to compile. This was due to our pattern of putting unit test test_specs inside of parent test_specs that didn't have anything else.

To address this I did two things. First, I moved away from the nested test_spec pattern. Now, instead of "Subspec/tests/unit_tests" it's "Subspec/UnitTests". This is more in line with the style Cocoapods uses [here](http://blog.cocoapods.org/CocoaPods-1.6.0-beta/). Secondly, I added some dummy files for things like UIMetrics and MaterialMath.

2. Importing headers across modules without using framework style imports.

I added framework style imports. This required some additional rewrite rules in the kokoro script.

3. Dependencies across subspecs being implicit.

I made them explicit by adding dependency statements to the podspecs where needed. 

`pod lib lint` didn't take issue with this, but I also saw that `MaterialComponents` was depending on `MaterialComponentsBeta` in various places. For example, all the theming extensions were in beta, but the tests for them weren't. I moved the tests to test_specs within the beta extensions. This required some directory structure changes. These changes then required some BUILD file changes. Making BUILD file changes made me realize that some swift unit tests weren't being accounted for by bazel. I took care of this too.

This PR also fixes some swift debugging stuff--"po" statements that weren't working before now do. I didn't rigorously verify this, but I also think this PR will lead to faster clean build times? It kinda seemed like it was while I was working on it.
2019-01-11 10:08:05 -05:00
featherless
a247edea76
Update bazel to 0.20 and all dependencies as a result (#5926)
Kokoro's Bazel version has been increased from 0.11.0 to 0.20.0

As part of this change, the `.kokoro` bazel header rewrite phase's rewrites for MDF libraries has been made less generic because MDFInternationalization can now be imported using framework-style imports as expected. MDFTextAccessibility does not yet have this functionality, so we still need to rewrite it.

Version changes in the bazel workspace:

- bazelbuild/rules_apple has been increased from 0.3.0 to 0.9.0
- bazel_skylib has been increased from 0.2.0 to 0.6.0
- bazelbuild/rules_swift has been added at 0.4.0
- xctestrunner has been increased from 0.2.1 to 0.2.5
- material_internationalization_ios has been increased from v1.0.4 to v2.0.1
- material_text_accessibility_ios has been increased from fd570d71ae0124c75ad5af00e6b8b4b1668d5e40 to v2.0.0
- motion_interchange_objc has been increased from v1.6.0 to v2.0.0
- motion_animator_objc has been increased from v2.5.0 to v3.0.0
- motion_transitioning_objc has been increased from v5.0.0 to v6.0.0
- Swift version has been pinned to 3 for all swift libraries.

buildifier was ran on all affected build targets.

This unblocks https://github.com/material-components/material-components-ios/pull/5550.
2018-12-13 14:27:43 -05: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
Jeff Verkoeyen
9854044c96 Revert "[automated] Standardize our open source license stanza to what Xcode generates. (#4982)"
This reverts commit b45bc2fdd4dfe12fc76751a45c9cf7b0d6c1261f.
2018-08-31 12:01:24 -04:00
featherless
b45bc2fdd4
[automated] Standardize our open source license stanza to what Xcode generates. (#4982)
Removes the need to copy-paste stanzas from other files anymore as we'll rely on https://github.com/material-components/material-components-ios/pull/4478 to generate the correct stanza for us instead.

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

### Find

```
/\*
 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\.
 \*/
```

### Replace

```
// 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 11:49:00 -04:00
Yarden Eitan
7b742b5745
[Kokoro / CI] Have Kokoro test multiple iOS versions and simulators on different Xcodes. (#3117)
* Remove dependency on Travis by having Kokoro test multiple iOS versions and simulators on different Xcodes.

* refactor

* refactor

* refactor
2018-03-21 09:40:30 -04:00
featherless
4ef8b6fdae
Initial addition of kokoro and bazel continuous integration support. (#2316)
* Initial addition of kokoro and bazel continuous integration support.

Only adds support for ActivityIndicator and its dependencies. Will add other components to the continuous integration in follow up changes.

* Add AnimationTiming.

* Fix target name.

* Use ... matching to run all tests and build all targets.

* Just run tests.

* Add skeleton tests.

* Fix copyrights and build files.

* Add bzl file.

* Standardize build files.

* Fix typo.

* Naming.

* Remove confusing comment.

* Use Xcode 8.2.
2017-11-01 13:29:49 -04:00
Adrian Secord
7ba66bf09c Formatted all Objective-C sources with clang-format. (#1133) 2017-01-05 10:17:24 -05:00
Sam Morrison
bbf124c534 Replace containsString with rangeOfString (#981) 2016-12-08 12:08:36 -05:00
Adrian Secord
6c598f6b74 Add missing private/Application umbrella header. (#938) 2016-12-05 10:46:52 -05:00
Sam Morrison
e69f038d88 Wrap sharedApplication calls so we can build for app extension targets (#897)
* Add UIApplication+AppExtensions

* Fix extension name

* Add comments

* s/safeApplication/safeSharedApplication/g

* Doc for class extension
2016-11-29 13:46:05 -05:00