I'm currently doing some frontend work in an application that is using angular-cli which I'm not all that used to. I've finished up most of the work but I'm trying to get a forum that currently loads above a table into a modal.
Currently, it comes from another linked component and loads in at the top of the html file like so.
<app-data-edit *ngIf="editEnabled" (editComplete)="onFinish($event)" [dataSet]="dataToEdit"></app-data-edit>
I loaded ngx-bootstrap into the project and got everything all set up. Following their documentation, specifically the component example I created a simple button and made it open a modal. So good so far, I can make a modal pop up with basic content in the modal body. Then I tried something like this:
@Component({
selector: 'modal-content',
template: `
<div class="modal-header">
<h4 class="modal-title pull-left">{{title}}</h4>
<button type="button" class="close pull-right" aria-label="Close" (click)="bsModalRef.hide()">
<span aria-hidden="true">×</span>
</button>
</div>
<div class="modal-body">
<app-data-edit *ngIf="editEnabled" (editComplete)="onFinish($event)" [dataSet]="dataToEdit"></app-data-edit>
</div>
<div class="modal-footer">
<button type="button" class="btn btn-default" (click)="bsModalRef.hide()">Close</button>
</div>'
})
export class ModalContentComponent {
title: string;
constructor(public bsModalRef: BsModalRef) {}
}
And it comes back with no results. Am I missing something?