Skip to content

0.5.0 Breaking Changes

Mathieu Lajoie edited this page May 9, 2019 · 20 revisions

Below is the list of all breaking changes paired to the 0.5.0 release. They are listed in no particular order and accompanied by a short explanation on why the change was necessary. Before and after examples are also provided for most of the changes.

Action Bar

  • **ActionBarTitleComponent is now a directive called ActionBarTitleDirective.

    Done to allow developers to customize the heading level of the action bar title. In terms of web accessibility, there should only be one h1 per page. Our previous action bar had a hardcoded h1, which would mean that there could only be one per page.

    <fd-action-bar-title>Action Bar Title</fd-action-bar-title>
    
    <!-- NOW -->
    <h2 fd-action-bar-title>Action Bar Title</h2>

Calendar

  • mondayStartOfWeek boolean input is now startingDayOfWeek number input.

    As the functionality for the first day of the week was made more flexible, we had to change the input name and type. It is now a number, with 1 representing Monday and so on. Note that this change also affects the datetime and date pickers.

    <!-- BEFORE -->
    <fd-calendar [mondayStartOfWeek]="true"></fd-calendar>
    
    <!-- NOW -->
    <fd-calendar [startingDayOfWeek]="1"></fd-calendar>

Forms

  • FormLegendComponent is now a directive called FormLegendDirective.

    Developers should ideally have access to the legend element themselves to facilitate customization. There was also little to no point of having a component since it only adds a class to the element.

    <!-- BEFORE -->
    <fd-form-legend>Legend</fd-form-legend>
    
    <!-- NOW -->
    <legend fd-form-legend>Legend</legend>
  • FormLabelComponent is now a directive called FormLabelDirective.

    Implemented to allow developers direct access to the native label element. All the component used to do was add a class to the element, which can be easily done through a directive.

    <!-- BEFORE -->
    <fd-form-label>Label</fd-form-label>
    
    <!-- NOW -->
    <label fd-form-label>Label</label>

Panel

  • PanelTitleComponent is now a directive called PanelTitleDirective.

    Implemented to allow customization of the heading level of the title. Previously, we had a hardcoded h1, which is terrible for web accessibility.

    <!-- BEFORE -->
    <fd-panel-title>Panel Title</fd-panel-title>
    
    <!-- NOW -->
    <h2 fd-panel-title>Panel Title</h2>
Clone this wiki locally