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

fix(toolbar): no longer auto-generate toolbar rows #6661

Merged

Commits on Oct 5, 2017

  1. fix(toolbar): no longer auto-generate toolbar rows

    Currently the toolbar always generates the first `<md-toolbar-row>`. This means that developers have no opportunity to set directives/attributes/classes on the first toolbar row (e.g with flex-layout).
    
    With this change, the toolbar won't auto-generate any `<md-toolbar-row>` element.
    
    The toolbar will have two different row modes:
    
    _Single row toolbar_
    
    ```html
    <md-toolbar>
      First Tow
    </md-toolbar>
    ```
    
    _Multiple rows toolbar_
    
    ```html
    <md-toolbar>
      <md-toolbar-row>First Row</md-toolbar-row>
      <md-toolbar-row>Second Row</md-toolbar-row>
    </md-toolbar>
    ```
    
    This means that mixing those two row modes is no longer possible and allowed
    
    ```html
    <md-toolbar>
      <span>First Row</span>
      <md-toolbar-row>Second Row</md-toolbar-row>
    </md-toolbar>
    ```
    
    BREAKING CHANGE: `<md-toolbar-row>` elements will be no longer auto-generated for the first row. Meaning that custom styling for the first `<md-toolbar-row>` is no longer working as before. Since no toolbar-row is auto-generated anymore, there are two different modes for the toolbar now. Either place content directly inside of the `<md-toolbar>` or place multiple `<md-toolbar-row>` elements.
    
    Fixes angular#6004. Fixes angular#1718.
    devversion committed Oct 5, 2017
    Configuration menu
    Copy the full SHA
    aeb3bd0 View commit details
    Browse the repository at this point in the history