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

Banner component implementation, #2672 #2978

Merged
merged 17 commits into from
Nov 30, 2018
Merged
Show file tree
Hide file tree
Changes from 16 commits
Commits
Show all changes
17 commits
Select commit Hold shift + click to select a range
e196227
feat(igxBanner): IgxBannerComponent implementation, #2672
wnvko Oct 3, 2018
0c4896e
chore(banner): fix lint errors
ViktorSlavov Nov 23, 2018
0e60f11
Merge branch 'master' into mvenkov/banner-component-implementation
ViktorSlavov Nov 23, 2018
9ef2edf
Merge branch 'master' into mvenkov/banner-component-implementation
ViktorSlavov Nov 26, 2018
d20d3e9
docs(igxBanner): update banner API in Readme, add banner to changelog
ViktorSlavov Nov 26, 2018
e8e264f
Merge branch 'master' into mvenkov/banner-component-implementation
rkaraivanov Nov 26, 2018
4cd6616
feat(igxBanner): remove BrowserModule import from banner, #2672
ViktorSlavov Nov 26, 2018
7dd5b1a
feat(igxBanner): adding aria-live and aria-hidden to banner template,…
ViktorSlavov Nov 26, 2018
a100e69
Merge branch 'master' into mvenkov/banner-component-implementation
ViktorSlavov Nov 26, 2018
9f770de
Merge branch 'master' into mvenkov/banner-component-implementation
ViktorSlavov Nov 26, 2018
47cb7b4
Merge branch 'master' into mvenkov/banner-component-implementation
ViktorSlavov Nov 27, 2018
62207f7
docs(igxBanner): move banner docs to proper section
ViktorSlavov Nov 27, 2018
40d4022
Merge branch 'master' into mvenkov/banner-component-implementation
ViktorSlavov Nov 27, 2018
af9f57d
docs(*): update CHANGELOG.md
ViktorSlavov Nov 28, 2018
9024d6a
Merge remote-tracking branch 'remotes/origin/master' into mvenkov/ban…
ViktorSlavov Nov 28, 2018
e614c93
docs(banner): add banner top comment
ViktorSlavov Nov 30, 2018
28c52d5
docs(banner): add more detailed comments to banner props
ViktorSlavov Nov 30, 2018
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

All notable changes for each version of this project will be documented in this file.

## 7.1.0
- **New component** `IgxBannerComponent`:
- Allows the developer to easily display a highly templateable message that requires minimal user interaction (1-2 actions) to be dismissed. Read up more information about the IgxBannerComponent in the official [documentation](https://www.infragistics.com/products/ignite-ui-angular/angular/components/banner.html) or the [ReadMe](https://github.com/IgniteUI/igniteui-angular/tree/master/projects/igniteui-angular/src/lib/banner/README.md)

## 7.0.0
- Updated package dependencies to Angular 7 ([#3000](https://github.com/IgniteUI/igniteui-angular/pull/3000))
- Themes: Add dark schemas and mixins (PR [#3025](https://github.com/IgniteUI/igniteui-angular/pull/3025))
Expand Down
50 changes: 50 additions & 0 deletions projects/igniteui-angular/src/lib/banner/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
# igx-banner

**igx-banner** supports banner component that is shown at the full width of the screen above the app content but below a Navigation Bar if available. A walkthrough of how to get started can be found [here](https://www.infragistics.com/products/ignite-ui-angular/angular/components/banner.html)

# Usage
```html
<igx-banner #banner>
This is default template's message!
</igx-banner>
```

# API Summary

### Inputs

Inputs available on the **IgxBanner**:

| Name | Type | Description |
|---------------------|:-------------:|----------------------------------------------------------|
| `animationSettings` | `{ openAnimation: AnimationRefMetadata, closeAnimation: AnimationRefMetadata }` | Sets the open / close animations for the banner. |


### Outputs

A list of the events emitted by the **IgxBanner**:

| Name | Description | Cancelable |
|---------------------|--------------------------------------------------------------------------|------------|
| `onOpening` | Fires before the banner is opened | `true` |
| `onOpened` | Fires after the banner is opened | `false` |
| `onClosing` | Fire before the banner is closed | `true` |
| `onClosed` | Fires after the banner is closed | `false`|

### Getters

Getters available on the **IgxBanner**:

| Name | Type | Getter | Setter | Description |
|---------------------|:-------------:|:------:|:------:|----------------------------------------|
| `collapsed` | boolean | Yes | No |Gets whether `igx-banner` is collapsed. |

### Methods

Here is a list of all public methods exposed by **IgxBanner**:

| Signature | Description |
|---------------------|--------------------------------------------------------------------------|
| `open()` | Opens the banner |
| `close()` | Closes the banner |
| `toggle()` | Toggles the banner |
27 changes: 27 additions & 0 deletions projects/igniteui-angular/src/lib/banner/banner.component.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
<igx-expansion-panel #expansionPanel [animationSettings]="animationSettings" (onCollapsed)="onExpansionPanelClose()" (onExpanded)="onExpansionPanelOpen()"
[collapsed]="collapsed" aria-live="polite" [attr.aria-hidden]="collapsed">
<igx-expansion-panel-body>
<div class="igx-banner">
<div class="igx-banner__message">
<div *ngIf="bannerIcon" class="igx-banner__illustration">
ViktorSlavov marked this conversation as resolved.
Show resolved Hide resolved
<ng-content select="igx-icon"></ng-content>
</div>
<span class="igx-banner__text">
<ng-content></ng-content>
</span>
</div>
<div class="igx-banner__actions">
<div class="igx-banner__row">
<ng-container *ngIf="useDefaultTemplate">
<button igxButton="flat" igxRipple (click)="close()">
Dismiss
</button>
</ng-container>
<ng-container *ngIf="!useDefaultTemplate">
<ng-content select="igx-banner-actions"></ng-content>
</ng-container>
</div>
</div>
</div>
</igx-expansion-panel-body>
</igx-expansion-panel>
Loading