[FR] Set NgbModalOptions Globally
See original GitHub issueFeature request description:
It would be nice to have an ability to set NgbModalOptions
globally, as it is currently implemented for NgbTooltipConfig
, for example: https://stackoverflow.com/a/44660183/1611569.
Version of Angular, ng-bootstrap, and Bootstrap:
Angular: 6.0.0
ng-bootstrap: 2.1.2
Bootstrap: 4.1.1
Issue Analytics
- State:
- Created 5 years ago
- Comments:5 (1 by maintainers)
Top Results From Across the Web
Modal - Angular powered Bootstrap
Bootstrap widgets for Angular: autocomplete, accordion, alert, carousel, datepicker, dropdown, offcanvas, pagination, popover, progressbar, rating, tabset, ...
Read more >How to set NgbModalOptions when open modal in angular 2
It's very simple. Follow these steps: Import NgbModalOptions: import { NgbModal, NgbActiveModal, NgbModalOptions } from '@ng-bootstrap/ng-bootstrap';.
Read more >Custom NgbModal service to set default config on open does ...
I want all the modals in our application to have a set of default options, ... way to have a global config on...
Read more >UI/Angular/Modal | Documentation Center | ABP.IO
ModalComponent is a pre-built component exposed by @abp/ng.theme.shared package to show modals. The component uses the ng-bootstrap's modal ...
Read more >how to set the z-index of two modal overlays in a stack wise in ...
Coding example for the question how to set the z-index of two modal overlays in a stack wise in Angular?-angular.js.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Properties of NgbModalConfig should have the same types as in NgbModalOptions.
NgbModalOptions has property: backdrop?: boolean | ‘static’; NgbModalConfig has property: backdrop: boolean;
@pkozlowski-opensource, could you please explain me how to use
NgbModalConfig
? I can’t find the example on https://ng-bootstrap.github.io/#/components/modal/api#NgbModalConfig. I tried to follow typeaheads global configuration example,but got an error TS2322: Type ‘“static”’ is not assignable to type ‘boolean’.
And one more question. Since I updated to 3.1.0, my IDE warns me that
NgbModule.forRoot()
is deprecated. However, on this demo I see exactly the same. The question is, should I just remove.forRoot()
?