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

upgraded angular & material modules to latest #90

Merged
merged 18 commits into from
Oct 3, 2016

Conversation

richavyas
Copy link
Collaborator

@richavyas richavyas commented Sep 21, 2016

Description

Upgraded angular to 2.0.0 and angular-material2 to 2.0.0-alpha.9
https://github.com/angular/material2/blob/master/CHANGELOG.md#2.0.0-alpha.9

What's included?

  • Updated main package.json and platform/core/package.json for angular & angular2-material to use latest

Test Steps

  • npm i
  • ng serve

@richavyas richavyas added this to the Alpha 0.8 milestone Sep 21, 2016
@kyleledbetter
Copy link
Contributor

think we should skip this and jump to 2.0.0-alpha.9? i'm sure it's a bigger jump since they introduced themes, but probably might as well right?

@emoralesb05
Copy link
Contributor

emoralesb05 commented Sep 30, 2016

yes, we should use this PR for that

https://github.com/angular/material2/blob/master/CHANGELOG.md

@emoralesb05
Copy link
Contributor

emoralesb05 commented Sep 30, 2016

What's included?

  • Updated to material alpha.9 (now @angular/material)
  • Added theme.scss for theming.
  • Updated rollup build for platform to work with changes from material and webpack.
  • Added snackbar example.

Test Steps

  • npm i
  • ng serve
  • npm run build to test rollup build

Note: Dialogs seem to have a bug, so i couldnt create an example for them.. also, we need to update theme.scss and remove things from app.component.scss.

@kyleledbetter
Copy link
Contributor

Theme Breaking Change Docs:

Now that angular-material has SCSS theme variables, this update will require Covalent users to:

  1. Remove most of app.component.scss and just leave:
@import "../theme";
/* :host /deep/ lets shadowdom style child elements */
:host /deep/ {
    md-divider {
        border-top-color: rgba(black, 0.12);
    }
    md-nav-list {
        [md-list-item].active {
            md-icon[md-list-avatar] {
                background-color: md-color($accent);
                color: md-color($accent, default-contrast)
            }
            md-icon[md-list-icon] {
                color: md-color($accent);
            }
        }
    }
    a[md-icon-button] {
        line-height: 36px;
    }
    .md-tab-label {
        flex-grow: 1;
    }
}
  1. add /src/theme.scss with (their color choices) in:
@import '~@angular/material/core/theming/all-theme';
// Plus imports for other components in your app.

// Include the base styles for Angular Material core. We include this here so that you only
// have to load a single css file for Angular Material in your app.
@include md-core();

// Define the palettes for your theme using the Material Design palettes available in palette.scss
// (imported above). For each palette, you can optionally specify a default, lighter, and darker
// hue.
$primary: md-palette($md-orange, 800);
$accent:  md-palette($md-light-blue, 600, A100, A400);

// The warn palette is optional (defaults to red).
$warn:    md-palette($md-red, 600);

// Create the theme object (a Sass map containing all of the palettes).
$theme: md-light-theme($primary, $accent, $warn);

// Include theme styles for core and each component used in your app.
// Alternatively, you can import and @include the theme mixins for each component
// that you are using.
@include angular-material-theme($theme);

@kyleledbetter
Copy link
Contributor

theme-docs
my theme updates working, and docs for using custom and multiple themes updated as well

@emoralesb05
Copy link
Contributor

emoralesb05 commented Oct 3, 2016

  • Added dialog examples
  • Moved global scss to styles.scss

Copy link
Contributor

@kyleledbetter kyleledbetter left a comment

Choose a reason for hiding this comment

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

Let's merge this and make sure to note the BREAKING CHANGES for the release docs

@emoralesb05 emoralesb05 merged commit 790278d into develop Oct 3, 2016
@emoralesb05 emoralesb05 deleted the feature/upgrade-alpha.8-2 branch October 3, 2016 20:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants