Skip to content
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

Update MaterialComponents podspec to separate extensions from component. Breaking change, please see description when sending out a new release #2748

Merged
merged 15 commits into from
Jan 2, 2018

Conversation

yarneo
Copy link
Contributor

@yarneo yarneo commented Dec 19, 2017

This solves #2696

  • To install the component without any extensions: pod MaterialComponents/<Component>

  • To install the component with all its extensions: pod MaterialComponents/<Component>+Extensions

  • To install the component with only one if its extensions: pod MaterialComponents/<Component>+Extensions/<Extension>

@randallli is good with this approach, we discussed offline.

I will add a isBreaking label and won't merge for now, as we should discuss the implications of current users having a pod MaterialComponents/<Component> and expecting the extensions to come with it.

The podspec passes pod spec lint

This is a breaking change, so when pushing out a new version please make sure to add a note of this change in the CHANGELOG with possibly adding the above examples of usage

@@ -102,29 +104,30 @@ Pod::Spec.new do |mdc|

component.dependency "MDFInternationalization"
component.dependency "MaterialComponents/Buttons"
component.dependency "MaterialComponents/NavigationBar"
component.dependency "MaterialComponents/NavigationBar+Extensions"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Confirming that we are intentionally bringing in the extensions here.

If so, can we bring in a more specific subset of extensions?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unfortunately so: https://github.com/material-components/material-components-ios/blob/develop/components/BottomAppBar/src/MDCBottomAppBarView.m#L101

I will update it to point only to the themer in case more extensions are added in the future.

spec.source_files = "components/#{component.base_name}/src/#{spec.base_name}/*.{h,m}"
spec.dependency "MaterialComponents/ButtonBar/Component"
spec.dependency "MaterialComponents/NavigationBar/Component"
spec.public_header_files = "components/ButtonBar/src/#{spec.base_name}/*.h"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

May be reasonable to do a find and replace of 'spec' with 'extension' now.

Copy link
Contributor

@jverkoey jverkoey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM overall - just some minor questions.

@codecov-io
Copy link

Codecov Report

Merging #2748 into develop will decrease coverage by 0.14%.
The diff coverage is n/a.

Impacted file tree graph

@@             Coverage Diff             @@
##           develop    #2748      +/-   ##
===========================================
- Coverage    46.89%   46.74%   -0.15%     
===========================================
  Files          165      165              
  Lines        24651    24797     +146     
  Branches      1060     1063       +3     
===========================================
+ Hits         11559    11591      +32     
- Misses       13029    13141     +112     
- Partials        63       65       +2
Impacted Files Coverage Δ
components/private/Math/src/MDCMath.h 39.34% <0%> (-2.4%) ⬇️
components/Chips/src/MDCChipView.m 22.3% <0%> (+0.26%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c63eeaf...02c0933. Read the comment docs.

@yarneo yarneo changed the title Update MaterialComponents podspec to separate extensions from component Update MaterialComponents podspec to separate extensions from component. Breaking change, please see description when sending out a new release Jan 2, 2018
@yarneo yarneo merged commit 6df22d2 into material-components:develop Jan 2, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants