Skip to content

Commit b65cc46

Browse files
authored
Merge branch 'development' into dev_feature_customBtn
2 parents f248850 + c0beddb commit b65cc46

File tree

4 files changed

+7
-7
lines changed

4 files changed

+7
-7
lines changed

src/modal/bs-modal-ref.service.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ export class BsModalRef<T = any> {
1414
/**
1515
* Allow user to ID for the modal. Otherwise, a unique number will be given
1616
*/
17-
id?: number;
17+
id?: number | string;
1818

1919
/**
2020
* Reference to a component inside the modal. Null if modal's been created with TemplateRef

src/modal/bs-modal.service.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ export class BsModalService {
7878
return this._showModal<T>(content);
7979
}
8080

81-
hide(id?: number) {
81+
hide(id?: number | string) {
8282
if (this.modalsCount === 1 || id == null) {
8383
this._hideBackdrop();
8484
this.resetScrollbar();
@@ -164,7 +164,7 @@ export class BsModalService {
164164
return bsModalRef;
165165
}
166166

167-
_hideModal(id?: number): void {
167+
_hideModal(id?: number | string): void {
168168
if (id != null) {
169169
const indexToRemove = this.loaders.findIndex(loader => loader.instance?.config.id === id);
170170
const modalLoader = this.loaders[indexToRemove];
@@ -245,7 +245,7 @@ export class BsModalService {
245245
this.loaders.push(loader);
246246
}
247247

248-
private removeLoaders(id?: number): void {
248+
private removeLoaders(id?: number | string): void {
249249
if (id != null) {
250250
const indexToRemove = this.loaders.findIndex(loader => loader.instance?.config.id === id);
251251
if (indexToRemove >= 0) {

src/modal/modal-options.class.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ export class ModalOptions<T = Record<string, unknown>> {
66
/**
77
* Allow user to ID for the modal. Otherwise, a unique number will be given
88
*/
9-
id?: number;
9+
id?: number | string;
1010
/**
1111
* Includes a modal-backdrop element. Alternatively,
1212
* specify static for a backdrop which doesn't close the modal on click.

src/typeahead/typeahead.directive.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -322,10 +322,10 @@ export class TypeaheadDirective implements OnInit, OnDestroy {
322322
this.typeaheadOnBlur.emit(this._container.active);
323323
}
324324

325-
if (!this.container && this._matches.length === 0) {
325+
if (!this.container && this._matches?.length === 0) {
326326
this.typeaheadOnBlur.emit(new TypeaheadMatch(
327327
this.element.nativeElement.value,
328-
this.element.nativeElement.value,
328+
this.element.nativeElement.value,
329329
false));
330330
}
331331
}

0 commit comments

Comments
 (0)