-
Notifications
You must be signed in to change notification settings - Fork 242
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: support for TemplateRef and literal string as modal content
BREAKING CHANGE: until now a modal can only open a component, this change allows a modal to open A `ContainerContent` which is a type the can be `string`, `TemplateRef` or a component (`Type`). To support this feature some partially breaking changes were made in the `Modal` class For developers using the library the `modal.open(componentType: any, config?: OverlayConfig)`, the 1st parameter is now called `content` and it's type is `ContainerContent`: `modal.open(content: ContainerContent, config?: OverlayConfig)`. For developers building plugins the same rule apply on the 2nd parameter of the`create` method. Also, the `createModal` method is deprecated, plugins should now use the `createBackdrop` and `createContainer` methods. Each container component supplied to `createContainer` must express `<ng-content` in it's template so the content (string, templateRef, component) can be injected into it.
- Loading branch information
Shlomi Assaf (shlassaf)
committed
Aug 30, 2016
1 parent
d115100
commit 2e6f6a0
Showing
8 changed files
with
90 additions
and
60 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters