@villedemontreal/angular-ui 19.0.1 → 20.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/fesm2022/villedemontreal-angular-ui.mjs +346 -335
- package/fesm2022/villedemontreal-angular-ui.mjs.map +1 -1
- package/index.d.ts +2385 -3
- package/package.json +5 -5
- package/lib/alert/alert.component.d.ts +0 -78
- package/lib/alert/index.d.ts +0 -2
- package/lib/alert/module.d.ts +0 -10
- package/lib/avatar/avatar.component.d.ts +0 -26
- package/lib/avatar/index.d.ts +0 -2
- package/lib/avatar/module.d.ts +0 -8
- package/lib/badge/badge.component.d.ts +0 -6
- package/lib/badge/index.d.ts +0 -2
- package/lib/badge/module.d.ts +0 -8
- package/lib/bao.module.d.ts +0 -28
- package/lib/breadcrumb/breadcrumb.component.d.ts +0 -12
- package/lib/breadcrumb/index.d.ts +0 -2
- package/lib/breadcrumb/module.d.ts +0 -9
- package/lib/button/button.component.d.ts +0 -47
- package/lib/button/index.d.ts +0 -2
- package/lib/button/module.d.ts +0 -9
- package/lib/card/card.component.d.ts +0 -44
- package/lib/card/index.d.ts +0 -2
- package/lib/card/module.d.ts +0 -8
- package/lib/checkbox/checkbox-group.component.d.ts +0 -25
- package/lib/checkbox/checkbox.component.d.ts +0 -152
- package/lib/checkbox/index.d.ts +0 -3
- package/lib/checkbox/module.d.ts +0 -11
- package/lib/common-components/error-text/errorText.component.d.ts +0 -5
- package/lib/common-components/guiding-text/guidingText.component.d.ts +0 -5
- package/lib/common-components/index.d.ts +0 -5
- package/lib/common-components/label-text/labelText.component.d.ts +0 -6
- package/lib/common-components/module.d.ts +0 -11
- package/lib/common-components/title-text/titleText.component.d.ts +0 -5
- package/lib/core/breakpoints.d.ts +0 -7
- package/lib/core/colors.d.ts +0 -12
- package/lib/core/index.d.ts +0 -2
- package/lib/dropdown-menu/dropdown-menu.component.d.ts +0 -174
- package/lib/dropdown-menu/index.d.ts +0 -2
- package/lib/dropdown-menu/module.d.ts +0 -11
- package/lib/file/file-input.component.d.ts +0 -123
- package/lib/file/file-intl.d.ts +0 -44
- package/lib/file/file-preview.component.d.ts +0 -31
- package/lib/file/index.d.ts +0 -4
- package/lib/file/module.d.ts +0 -13
- package/lib/header-info/header-info.component.d.ts +0 -39
- package/lib/header-info/index.d.ts +0 -2
- package/lib/header-info/module.d.ts +0 -8
- package/lib/hyperlink/hyperlink.component.d.ts +0 -18
- package/lib/hyperlink/index.d.ts +0 -2
- package/lib/hyperlink/module.d.ts +0 -8
- package/lib/icon/bao-icon-registry.d.ts +0 -12
- package/lib/icon/icon.component.d.ts +0 -44
- package/lib/icon/icons-dictionary.d.ts +0 -4
- package/lib/icon/index.d.ts +0 -2
- package/lib/icon/module.d.ts +0 -8
- package/lib/list/index.d.ts +0 -2
- package/lib/list/list.component.d.ts +0 -21
- package/lib/list/module.d.ts +0 -8
- package/lib/message-bar/index.d.ts +0 -2
- package/lib/message-bar/message-bar.component.d.ts +0 -28
- package/lib/message-bar/module.d.ts +0 -11
- package/lib/modal/index.d.ts +0 -6
- package/lib/modal/modal-config.d.ts +0 -116
- package/lib/modal/modal-container.d.ts +0 -105
- package/lib/modal/modal-directives.d.ts +0 -25
- package/lib/modal/modal-ref.d.ts +0 -104
- package/lib/modal/modal.d.ts +0 -90
- package/lib/modal/module.d.ts +0 -11
- package/lib/pagination/index.d.ts +0 -2
- package/lib/pagination/module.d.ts +0 -10
- package/lib/pagination/pagination.component.d.ts +0 -106
- package/lib/radio/index.d.ts +0 -3
- package/lib/radio/module.d.ts +0 -13
- package/lib/radio/radio-group.component.d.ts +0 -110
- package/lib/radio/radio.component.d.ts +0 -112
- package/lib/shared/enum/display-mode.d.ts +0 -4
- package/lib/shared/index.d.ts +0 -1
- package/lib/snack-bar/index.d.ts +0 -6
- package/lib/snack-bar/module.d.ts +0 -13
- package/lib/snack-bar/simple-snack-bar.component.d.ts +0 -51
- package/lib/snack-bar/snack-bar-animations.d.ts +0 -8
- package/lib/snack-bar/snack-bar-config.d.ts +0 -51
- package/lib/snack-bar/snack-bar-container.d.ts +0 -111
- package/lib/snack-bar/snack-bar-ref.d.ts +0 -51
- package/lib/snack-bar/snack-bar.d.ts +0 -89
- package/lib/summary/index.d.ts +0 -3
- package/lib/summary/list-summary.component.d.ts +0 -9
- package/lib/summary/module.d.ts +0 -10
- package/lib/summary/summary.component.d.ts +0 -47
- package/lib/system-header/index.d.ts +0 -2
- package/lib/system-header/module.d.ts +0 -9
- package/lib/system-header/system-header.component.d.ts +0 -42
- package/lib/tabs/index.d.ts +0 -2
- package/lib/tabs/module.d.ts +0 -8
- package/lib/tabs/tabs.component.d.ts +0 -95
- package/lib/tag/index.d.ts +0 -2
- package/lib/tag/module.d.ts +0 -8
- package/lib/tag/tag.component.d.ts +0 -25
- package/public-api.d.ts +0 -25
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import * as i0 from "@angular/core";
|
|
2
|
-
import * as i1 from "./message-bar.component";
|
|
3
|
-
import * as i2 from "@angular/common";
|
|
4
|
-
import * as i3 from "../icon/module";
|
|
5
|
-
import * as i4 from "../button/module";
|
|
6
|
-
import * as i5 from "../hyperlink/module";
|
|
7
|
-
export declare class BaoMessageBarModule {
|
|
8
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<BaoMessageBarModule, never>;
|
|
9
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<BaoMessageBarModule, [typeof i1.BaoMessageBarComponent, typeof i1.BaoMessageBarContent], [typeof i2.CommonModule, typeof i3.BaoIconModule, typeof i4.BaoButtonModule, typeof i5.BaoHyperlinkModule], [typeof i1.BaoMessageBarComponent, typeof i1.BaoMessageBarContent]>;
|
|
10
|
-
static ɵinj: i0.ɵɵInjectorDeclaration<BaoMessageBarModule>;
|
|
11
|
-
}
|
package/lib/modal/index.d.ts
DELETED
|
@@ -1,116 +0,0 @@
|
|
|
1
|
-
import { Direction } from '@angular/cdk/bidi';
|
|
2
|
-
import { ScrollStrategy } from '@angular/cdk/overlay';
|
|
3
|
-
import { ElementRef, Injector, ViewContainerRef } from '@angular/core';
|
|
4
|
-
export declare const FILTER_MODAL_WIDTH = "360px";
|
|
5
|
-
export declare enum eModalDesktopWidthSize {
|
|
6
|
-
SMALL = "bao-modal-sm",// 500px
|
|
7
|
-
MEDIUM = "bao-modal-md",// 800px
|
|
8
|
-
LARGE = "bao-modal-lg"
|
|
9
|
-
}
|
|
10
|
-
export declare enum eModalVariant {
|
|
11
|
-
GLOBAL = "global",
|
|
12
|
-
FILTER = "filter"
|
|
13
|
-
}
|
|
14
|
-
export declare enum eModalMobileWidthSize {
|
|
15
|
-
FULL = "bao-modal-mobil-full",// Full width on mobile screen
|
|
16
|
-
COMPACT = "bao-modal-mobil-compact"
|
|
17
|
-
}
|
|
18
|
-
export interface BaoModalConfig {
|
|
19
|
-
size?: eModalDesktopWidthSize;
|
|
20
|
-
mobileSize?: eModalMobileWidthSize;
|
|
21
|
-
data?: unknown;
|
|
22
|
-
ariaLabelledBy?: string;
|
|
23
|
-
variant?: eModalVariant;
|
|
24
|
-
triggerElement?: ElementRef;
|
|
25
|
-
}
|
|
26
|
-
/** Options for where to set focus to automatically on dialog open */
|
|
27
|
-
export type AutoFocusTarget = 'dialog' | 'modal' | 'first-tabbable' | 'first-heading';
|
|
28
|
-
/** Valid ARIA roles for a dialog element. */
|
|
29
|
-
export type ModalRole = 'dialog' | 'alertdialog';
|
|
30
|
-
/** Possible overrides for a dialog's position. */
|
|
31
|
-
export interface ModalPosition {
|
|
32
|
-
/** Override for the dialog's top position. */
|
|
33
|
-
top?: string;
|
|
34
|
-
/** Override for the dialog's bottom position. */
|
|
35
|
-
bottom?: string;
|
|
36
|
-
/** Override for the dialog's left position. */
|
|
37
|
-
left?: string;
|
|
38
|
-
/** Override for the dialog's right position. */
|
|
39
|
-
right?: string;
|
|
40
|
-
}
|
|
41
|
-
/**
|
|
42
|
-
* Configuration for opening a modal dialog with the BaoModal service.
|
|
43
|
-
*/
|
|
44
|
-
export declare class BaoModalInitialConfig<D = unknown> {
|
|
45
|
-
/**
|
|
46
|
-
* Where the attached component should live in Angular's *logical* component tree.
|
|
47
|
-
* This affects what is available for injection and the change detection order for the
|
|
48
|
-
* component instantiated inside of the dialog. This does not affect where the dialog
|
|
49
|
-
* content will be rendered.
|
|
50
|
-
*/
|
|
51
|
-
viewContainerRef?: ViewContainerRef;
|
|
52
|
-
/**
|
|
53
|
-
* Injector used for the instantiation of the component to be attached. If provided,
|
|
54
|
-
* takes precedence over the injector indirectly provided by `ViewContainerRef`.
|
|
55
|
-
*/
|
|
56
|
-
injector?: Injector;
|
|
57
|
-
/** ID for the dialog. If omitted, a unique one will be generated. */
|
|
58
|
-
id?: string;
|
|
59
|
-
/** The ARIA role of the dialog element. */
|
|
60
|
-
role?: ModalRole;
|
|
61
|
-
/** Custom class for the overlay pane. */
|
|
62
|
-
panelClass?: string | string[];
|
|
63
|
-
/** Whether the dialog has a backdrop. */
|
|
64
|
-
hasBackdrop?: boolean;
|
|
65
|
-
/** Custom class for the backdrop. */
|
|
66
|
-
backdropClass?: string | string[];
|
|
67
|
-
/** Whether the user can use escape or clicking on the backdrop to close the modal. */
|
|
68
|
-
disableClose?: boolean;
|
|
69
|
-
/** Width of the dialog. */
|
|
70
|
-
width?: string;
|
|
71
|
-
/** Height of the dialog. */
|
|
72
|
-
height?: string;
|
|
73
|
-
/** Min-width of the dialog. If a number is provided, assumes pixel units. */
|
|
74
|
-
minWidth?: number | string;
|
|
75
|
-
/** Min-height of the dialog. If a number is provided, assumes pixel units. */
|
|
76
|
-
minHeight?: number | string;
|
|
77
|
-
/** Max-width of the dialog. If a number is provided, assumes pixel units. Defaults to 80vw. */
|
|
78
|
-
maxWidth?: number | string;
|
|
79
|
-
/** Max-height of the dialog. If a number is provided, assumes pixel units. */
|
|
80
|
-
maxHeight?: number | string;
|
|
81
|
-
/** Position overrides. */
|
|
82
|
-
position?: ModalPosition;
|
|
83
|
-
/** Data being injected into the child component. */
|
|
84
|
-
data?: D | null;
|
|
85
|
-
/** Layout direction for the dialog's content. */
|
|
86
|
-
direction?: Direction;
|
|
87
|
-
/** ID of the element that describes the dialog. */
|
|
88
|
-
ariaDescribedBy?: string | null;
|
|
89
|
-
/** ID of the element that labels the dialog. */
|
|
90
|
-
ariaLabelledBy?: string | null;
|
|
91
|
-
/** Aria label to assign to the dialog element. */
|
|
92
|
-
ariaLabel?: string | null;
|
|
93
|
-
/** Modal variant (default or filter). */
|
|
94
|
-
variant?: eModalVariant;
|
|
95
|
-
/** Trigger element for connected positioning (used with filter variant). */
|
|
96
|
-
triggerElement?: ElementRef;
|
|
97
|
-
/**
|
|
98
|
-
* Where the dialog should focus on open.
|
|
99
|
-
*/
|
|
100
|
-
autoFocus?: AutoFocusTarget;
|
|
101
|
-
/**
|
|
102
|
-
* Whether the dialog should restore focus to the
|
|
103
|
-
* previously-focused element, after it's closed.
|
|
104
|
-
*/
|
|
105
|
-
restoreFocus?: boolean;
|
|
106
|
-
/** Whether to wait for the opening animation to finish before trapping focus. */
|
|
107
|
-
delayFocusTrap?: boolean;
|
|
108
|
-
/** Scroll strategy to be used for the dialog. */
|
|
109
|
-
scrollStrategy?: ScrollStrategy;
|
|
110
|
-
/**
|
|
111
|
-
* Whether the dialog should close when the user goes backwards/forwards in history.
|
|
112
|
-
* Note that this usually doesn't include clicking on links (unless the user is using
|
|
113
|
-
* the `HashLocationStrategy`).
|
|
114
|
-
*/
|
|
115
|
-
closeOnNavigation?: boolean;
|
|
116
|
-
}
|
|
@@ -1,105 +0,0 @@
|
|
|
1
|
-
import { FocusMonitor, FocusOrigin, ConfigurableFocusTrapFactory, InteractivityChecker } from '@angular/cdk/a11y';
|
|
2
|
-
import { BasePortalOutlet, CdkPortalOutlet, ComponentPortal, TemplatePortal } from '@angular/cdk/portal';
|
|
3
|
-
import { ChangeDetectorRef, ComponentRef, ElementRef, EmbeddedViewRef, EventEmitter, NgZone } from '@angular/core';
|
|
4
|
-
import { BaoModalInitialConfig } from './modal-config';
|
|
5
|
-
import * as i0 from "@angular/core";
|
|
6
|
-
/** Event that captures the state of modal container animations. */
|
|
7
|
-
interface DialogAnimationEvent {
|
|
8
|
-
state: 'opened' | 'opening' | 'closing' | 'closed';
|
|
9
|
-
totalTime: number;
|
|
10
|
-
}
|
|
11
|
-
/**
|
|
12
|
-
* Throws an exception for the case when a ComponentPortal is
|
|
13
|
-
* attached to a DomPortalOutlet without an origin.
|
|
14
|
-
* @docs-private
|
|
15
|
-
*/
|
|
16
|
-
export declare function throwBaoModalContentAlreadyAttachedError(): void;
|
|
17
|
-
/**
|
|
18
|
-
* Base class for the `BaoModalContainer`. The base class does not implement
|
|
19
|
-
* animations as these are left to implementers of the modal container.
|
|
20
|
-
*/
|
|
21
|
-
export declare abstract class _BaoModalContainerBase extends BasePortalOutlet {
|
|
22
|
-
protected _elementRef: ElementRef;
|
|
23
|
-
protected _focusTrapFactory: ConfigurableFocusTrapFactory;
|
|
24
|
-
protected _changeDetectorRef: ChangeDetectorRef;
|
|
25
|
-
/** The modal configuration. */
|
|
26
|
-
_config: BaoModalInitialConfig;
|
|
27
|
-
private readonly _interactivityChecker;
|
|
28
|
-
private readonly _ngZone;
|
|
29
|
-
private _focusMonitor?;
|
|
30
|
-
/** The portal outlet inside of this container into which the modal content will be loaded. */
|
|
31
|
-
_portalOutlet: CdkPortalOutlet;
|
|
32
|
-
/** Emits when an animation state changes. */
|
|
33
|
-
_animationStateChanged: EventEmitter<DialogAnimationEvent>;
|
|
34
|
-
/**
|
|
35
|
-
* Type of interaction that led to the modal being closed. This is used to determine
|
|
36
|
-
* whether the focus style will be applied when returning focus to its original location
|
|
37
|
-
* after the modal is closed.
|
|
38
|
-
*/
|
|
39
|
-
_closeInteractionType: FocusOrigin | null;
|
|
40
|
-
/** ID of the element that should be considered as the modal's label. */
|
|
41
|
-
_ariaLabelledBy: string | null;
|
|
42
|
-
/** ID for the container DOM element. */
|
|
43
|
-
_id: string;
|
|
44
|
-
protected _document: Document;
|
|
45
|
-
/** The class that traps and manages focus within the modal. */
|
|
46
|
-
private _focusTrap;
|
|
47
|
-
/** Element that was focused before the modal was opened. Save this to restore upon close. */
|
|
48
|
-
private _elementFocusedBeforeDialogWasOpened;
|
|
49
|
-
constructor(_elementRef: ElementRef, _focusTrapFactory: ConfigurableFocusTrapFactory, _changeDetectorRef: ChangeDetectorRef, _document: any,
|
|
50
|
-
/** The modal configuration. */
|
|
51
|
-
_config: BaoModalInitialConfig, _interactivityChecker: InteractivityChecker, _ngZone: NgZone, _focusMonitor?: FocusMonitor);
|
|
52
|
-
/** Initializes the modal container with the attached content. */
|
|
53
|
-
_initializeWithAttachedContent(): void;
|
|
54
|
-
/**
|
|
55
|
-
* Attach a ComponentPortal as content to this modal container.
|
|
56
|
-
*/
|
|
57
|
-
attachComponentPortal<T>(portal: ComponentPortal<T>): ComponentRef<T>;
|
|
58
|
-
/**
|
|
59
|
-
* Attach a TemplatePortal as content to this modal container.
|
|
60
|
-
*/
|
|
61
|
-
attachTemplatePortal<C>(portal: TemplatePortal<C>): EmbeddedViewRef<C>;
|
|
62
|
-
/** Moves focus back into the modal if it was moved out. */
|
|
63
|
-
_recaptureFocus(): Promise<void>;
|
|
64
|
-
/**
|
|
65
|
-
* Moves the focus inside the focus trap. When autoFocus is not set to 'modal', if focus
|
|
66
|
-
* cannot be moved then focus will go to the modal container.
|
|
67
|
-
*/
|
|
68
|
-
protected _trapFocus(): Promise<void>;
|
|
69
|
-
/** Restores focus to the element that was focused before the modal opened. */
|
|
70
|
-
protected _restoreFocus(): void;
|
|
71
|
-
/**
|
|
72
|
-
* Focuses the provided element. If the element is not focusable, it will add a tabIndex
|
|
73
|
-
* attribute to forcefully focus it. The attribute is removed after focus is moved.
|
|
74
|
-
*/
|
|
75
|
-
private _forceFocus;
|
|
76
|
-
/**
|
|
77
|
-
* Focuses the first element that matches the given selector within the focus trap.
|
|
78
|
-
*/
|
|
79
|
-
private _focusByCssSelector;
|
|
80
|
-
/** Sets up the focus trap. */
|
|
81
|
-
private _setupFocusTrap;
|
|
82
|
-
/** Captures the element that was focused before the modal was opened. */
|
|
83
|
-
private _capturePreviouslyFocusedElement;
|
|
84
|
-
/** Focuses the modal container. */
|
|
85
|
-
private _focusDialogContainer;
|
|
86
|
-
/** Returns whether focus is inside the modal. */
|
|
87
|
-
private _containsFocus;
|
|
88
|
-
/** Starts the modal exit animation. */
|
|
89
|
-
abstract _startExitAnimation(): void;
|
|
90
|
-
abstract _startOpenAnimation(): void;
|
|
91
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<_BaoModalContainerBase, [null, null, null, { optional: true; }, null, null, null, null]>;
|
|
92
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<_BaoModalContainerBase, never, never, {}, {}, never, never, true, never>;
|
|
93
|
-
}
|
|
94
|
-
export declare class BaoModalContainer extends _BaoModalContainerBase {
|
|
95
|
-
/** State of the modal animation. */
|
|
96
|
-
_state: 'void' | 'enter' | 'exit';
|
|
97
|
-
_startOpenAnimation(): void;
|
|
98
|
-
/** Starts the modal exit animation. */
|
|
99
|
-
_startExitAnimation(): void;
|
|
100
|
-
private _finishDialogOpen;
|
|
101
|
-
private _openAnimationDone;
|
|
102
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<BaoModalContainer, never>;
|
|
103
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<BaoModalContainer, "bao-modal-container", never, {}, {}, never, never, false, never>;
|
|
104
|
-
}
|
|
105
|
-
export {};
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
import { OnChanges, OnInit, SimpleChanges, ElementRef } from '@angular/core';
|
|
2
|
-
import { BaoModal } from './modal';
|
|
3
|
-
import { BaoModalRef } from './modal-ref';
|
|
4
|
-
import * as i0 from "@angular/core";
|
|
5
|
-
/**
|
|
6
|
-
* Button that will close the current dialog.
|
|
7
|
-
*/
|
|
8
|
-
export declare class BaoModalClose implements OnInit, OnChanges {
|
|
9
|
-
modalRef: BaoModalRef<unknown> | null;
|
|
10
|
-
private _elementRef;
|
|
11
|
-
private _dialog;
|
|
12
|
-
/** Screenreader label for the button. */
|
|
13
|
-
ariaLabel: string;
|
|
14
|
-
/** Default to "button" to prevents accidental form submits. */
|
|
15
|
-
type: 'submit' | 'button' | 'reset';
|
|
16
|
-
/** Dialog close input. */
|
|
17
|
-
dialogResult: unknown;
|
|
18
|
-
_baoModalClose: unknown;
|
|
19
|
-
constructor(modalRef: BaoModalRef<unknown> | null, _elementRef: ElementRef<HTMLElement>, _dialog: BaoModal);
|
|
20
|
-
ngOnInit(): void;
|
|
21
|
-
ngOnChanges(changes: SimpleChanges): void;
|
|
22
|
-
_onButtonClick(event: MouseEvent): void;
|
|
23
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<BaoModalClose, [{ optional: true; }, null, null]>;
|
|
24
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<BaoModalClose, "[bao-modal-close], [baoModalClose]", ["BaoModalClose"], { "ariaLabel": { "alias": "aria-label"; "required": false; }; "type": { "alias": "type"; "required": false; }; "dialogResult": { "alias": "bao-modal-close"; "required": false; }; "_baoModalClose": { "alias": "baoModalClose"; "required": false; }; }, {}, never, never, false, never>;
|
|
25
|
-
}
|
package/lib/modal/modal-ref.d.ts
DELETED
|
@@ -1,104 +0,0 @@
|
|
|
1
|
-
import { FocusOrigin } from '@angular/cdk/a11y';
|
|
2
|
-
import { OverlayRef } from '@angular/cdk/overlay';
|
|
3
|
-
import { Observable } from 'rxjs';
|
|
4
|
-
import { ModalPosition } from './modal-config';
|
|
5
|
-
import { _BaoModalContainerBase } from './modal-container';
|
|
6
|
-
/** Possible states of the lifecycle of a modal. */
|
|
7
|
-
export declare const enum BaoModalState {
|
|
8
|
-
OPEN = 0,
|
|
9
|
-
CLOSING = 1,
|
|
10
|
-
CLOSED = 2
|
|
11
|
-
}
|
|
12
|
-
/**
|
|
13
|
-
* Reference to a modal opened via the BaoModalService.
|
|
14
|
-
*/
|
|
15
|
-
export declare class BaoModalRef<T, R = unknown> {
|
|
16
|
-
private _overlayRef;
|
|
17
|
-
_containerInstance: _BaoModalContainerBase;
|
|
18
|
-
/** Id of the modal. */
|
|
19
|
-
readonly id: string;
|
|
20
|
-
/** The instance of component opened into the modal. */
|
|
21
|
-
componentInstance: T;
|
|
22
|
-
/** Whether the user is allowed to close the modal. */
|
|
23
|
-
disableClose: boolean | undefined;
|
|
24
|
-
/** Subject for notifying the user that the modal has finished opening. */
|
|
25
|
-
private readonly _afterOpened;
|
|
26
|
-
/** Subject for notifying the user that the modal has finished closing. */
|
|
27
|
-
private readonly _afterClosed;
|
|
28
|
-
/** Subject for notifying the user that the modal has started closing. */
|
|
29
|
-
private readonly _beforeClosed;
|
|
30
|
-
/** Result to be passed to afterClosed. */
|
|
31
|
-
private _result;
|
|
32
|
-
/** Handle to the timeout that's running as a fallback in case the exit animation doesn't fire. */
|
|
33
|
-
private _closeFallbackTimeout;
|
|
34
|
-
/** Current state of the modal. */
|
|
35
|
-
private _state;
|
|
36
|
-
constructor(_overlayRef: OverlayRef, _containerInstance: _BaoModalContainerBase,
|
|
37
|
-
/** Id of the modal. */
|
|
38
|
-
id?: string);
|
|
39
|
-
/**
|
|
40
|
-
* Close the modal.
|
|
41
|
-
* @param modalResult Optional result to return to the modal opener.
|
|
42
|
-
*/
|
|
43
|
-
close(modalResult?: R): void;
|
|
44
|
-
startOpenAnimation(): void;
|
|
45
|
-
/**
|
|
46
|
-
* Gets an observable that is notified when the modal is finished opening.
|
|
47
|
-
*/
|
|
48
|
-
afterOpened(): Observable<void>;
|
|
49
|
-
/**
|
|
50
|
-
* Gets an observable that is notified when the modal is finished closing.
|
|
51
|
-
*/
|
|
52
|
-
afterClosed(): Observable<R | undefined>;
|
|
53
|
-
/**
|
|
54
|
-
* Gets an observable that is notified when the modal has started closing.
|
|
55
|
-
*/
|
|
56
|
-
beforeClosed(): Observable<R | undefined>;
|
|
57
|
-
/**
|
|
58
|
-
* Gets an observable that emits when the overlay's backdrop has been clicked.
|
|
59
|
-
*/
|
|
60
|
-
backdropClick(): Observable<MouseEvent>;
|
|
61
|
-
/**
|
|
62
|
-
* Gets an observable that emits when keydown events are targeted on the overlay.
|
|
63
|
-
*/
|
|
64
|
-
keydownEvents(): Observable<KeyboardEvent>;
|
|
65
|
-
/**
|
|
66
|
-
* Updates the dialog's position.
|
|
67
|
-
*/
|
|
68
|
-
updatePosition(position?: ModalPosition): this;
|
|
69
|
-
/**
|
|
70
|
-
* Updates the modal's width and height.
|
|
71
|
-
*/
|
|
72
|
-
updateSize(width?: string, height?: string): this;
|
|
73
|
-
/** Add a CSS class or an array of classes to the overlay pane. */
|
|
74
|
-
addPanelClass(classes: string | string[]): this;
|
|
75
|
-
/** Remove a CSS class or an array of classes from the overlay pane. */
|
|
76
|
-
removePanelClass(classes: string | string[]): this;
|
|
77
|
-
/** Gets the current state of the modal's lifecycle. */
|
|
78
|
-
getState(): BaoModalState;
|
|
79
|
-
/**
|
|
80
|
-
* Finishes the modal close by updating the state of the modal
|
|
81
|
-
* and disposing the overlay.
|
|
82
|
-
*/
|
|
83
|
-
private _finishModalClose;
|
|
84
|
-
/** Fetches the position strategy object from the overlay ref. */
|
|
85
|
-
private _getPositionStrategy;
|
|
86
|
-
/**
|
|
87
|
-
* Applies the position strategy to the overlay.
|
|
88
|
-
*
|
|
89
|
-
* This method sets the position of the modal based on the provided `position` configuration.
|
|
90
|
-
* It determines whether to apply the position to the vertical or horizontal axis based on the
|
|
91
|
-
* `axis` parameter.
|
|
92
|
-
*
|
|
93
|
-
* @param position The position configuration for the modal.
|
|
94
|
-
* @param strategy The position strategy to be applied.
|
|
95
|
-
* @param axis The axis to apply the position (`'horizontal' | 'vertical'`)
|
|
96
|
-
*/
|
|
97
|
-
private applyPositionStrategy;
|
|
98
|
-
}
|
|
99
|
-
/**
|
|
100
|
-
* Closes the modal with the specified interaction type. This is currently not part of
|
|
101
|
-
* `BaoModalRef` as that would conflict with custom modal ref mocks provided in tests.
|
|
102
|
-
* More details. See: https://github.com/angular/components/pull/9257#issuecomment-651342226.
|
|
103
|
-
*/
|
|
104
|
-
export declare function _closeModalVia<R>(ref: BaoModalRef<R>, interactionType: FocusOrigin, result?: R): void;
|
package/lib/modal/modal.d.ts
DELETED
|
@@ -1,90 +0,0 @@
|
|
|
1
|
-
import { ComponentType, Overlay, OverlayContainer } from '@angular/cdk/overlay';
|
|
2
|
-
import { InjectionToken, Injector, OnDestroy, TemplateRef, Type } from '@angular/core';
|
|
3
|
-
import { Observable, Subject } from 'rxjs';
|
|
4
|
-
import { BaoModalConfig } from './modal-config';
|
|
5
|
-
import { _BaoModalContainerBase, BaoModalContainer } from './modal-container';
|
|
6
|
-
import { BaoModalRef } from './modal-ref';
|
|
7
|
-
import * as i0 from "@angular/core";
|
|
8
|
-
/** Injection token that can be used to access the data that was passed in to a modal. */
|
|
9
|
-
export declare const BAO_MODAL_DATA: InjectionToken<unknown>;
|
|
10
|
-
export declare abstract class BaoModalBase<C extends _BaoModalContainerBase> implements OnDestroy {
|
|
11
|
-
private _overlay;
|
|
12
|
-
private _injector;
|
|
13
|
-
private _parentModal;
|
|
14
|
-
private _overlayContainer;
|
|
15
|
-
private _modalRefConstructor;
|
|
16
|
-
private _modalContainerType;
|
|
17
|
-
private _modalDataToken;
|
|
18
|
-
readonly afterAllClosed: Observable<void>;
|
|
19
|
-
private _openModalsAtThisLevel;
|
|
20
|
-
private readonly _afterAllClosedAtThisLevel;
|
|
21
|
-
private readonly _afterOpenedAtThisLevel;
|
|
22
|
-
private _ariaHiddenElements;
|
|
23
|
-
private _modalAnimatingOpen;
|
|
24
|
-
private _animationStateSubscriptions;
|
|
25
|
-
private _lastModalRef;
|
|
26
|
-
constructor(_overlay: Overlay, _injector: Injector, _parentModal: BaoModalBase<C> | undefined, _overlayContainer: OverlayContainer, _modalRefConstructor: Type<BaoModalRef<unknown>>, _modalContainerType: Type<C>, _modalDataToken: InjectionToken<unknown>);
|
|
27
|
-
/** Keeps track of the currently-open modals. */
|
|
28
|
-
get openModals(): BaoModalRef<unknown>[];
|
|
29
|
-
/** Stream that emits when a modal has been opened. */
|
|
30
|
-
get afterOpened(): Subject<BaoModalRef<unknown>>;
|
|
31
|
-
getAfterAllClosed(): Subject<void>;
|
|
32
|
-
/**
|
|
33
|
-
* Opens a modal modal containing the given template.
|
|
34
|
-
*/
|
|
35
|
-
open<T>(componentOrTemplateRef: ComponentType<T> | TemplateRef<T>, config?: BaoModalConfig): BaoModalRef<unknown>;
|
|
36
|
-
/**
|
|
37
|
-
* Closes all of the currently-open modals.
|
|
38
|
-
*/
|
|
39
|
-
closeAll(): void;
|
|
40
|
-
/**
|
|
41
|
-
* Finds an open modal by its id.
|
|
42
|
-
*/
|
|
43
|
-
getModalById(id: string): BaoModalRef<unknown> | undefined;
|
|
44
|
-
ngOnDestroy(): void;
|
|
45
|
-
/**
|
|
46
|
-
* Creates the overlay into which the modal will be loaded.
|
|
47
|
-
*/
|
|
48
|
-
private _createOverlay;
|
|
49
|
-
/**
|
|
50
|
-
* Creates an overlay config from a modal config.
|
|
51
|
-
*/
|
|
52
|
-
private _getOverlayConfig;
|
|
53
|
-
/**
|
|
54
|
-
* Attaches a modal container to a modal's already-created overlay.
|
|
55
|
-
*/
|
|
56
|
-
private _attachModalContainer;
|
|
57
|
-
/**
|
|
58
|
-
* Attaches the user-provided component to the already-created modal container.
|
|
59
|
-
*/
|
|
60
|
-
private _attachModalContent;
|
|
61
|
-
/**
|
|
62
|
-
* Creates a custom injector to be used inside the modal. This allows a component loaded inside
|
|
63
|
-
* of a modal to close itself and, optionally, to return a value.
|
|
64
|
-
*/
|
|
65
|
-
private _createInjector;
|
|
66
|
-
/**
|
|
67
|
-
* Removes a modal from the array of open modals.
|
|
68
|
-
*/
|
|
69
|
-
private _removeOpenModal;
|
|
70
|
-
/**
|
|
71
|
-
* Hides all of the content that isn't an overlay from assistive technology.
|
|
72
|
-
*/
|
|
73
|
-
private _hideNonModalContentFromAssistiveTechnology;
|
|
74
|
-
/** Closes all of the modals in an array. */
|
|
75
|
-
private _closeModals;
|
|
76
|
-
/**
|
|
77
|
-
* Applies default options to the modal config.
|
|
78
|
-
*/
|
|
79
|
-
private _applyConfigDefaults;
|
|
80
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<BaoModalBase<any>, never>;
|
|
81
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<BaoModalBase<any>, never, never, {}, {}, never, never, true, never>;
|
|
82
|
-
}
|
|
83
|
-
/**
|
|
84
|
-
* Service to open modal.
|
|
85
|
-
*/
|
|
86
|
-
export declare class BaoModal extends BaoModalBase<BaoModalContainer> {
|
|
87
|
-
constructor(overlay: Overlay, injector: Injector, parentModal: BaoModal, overlayContainer: OverlayContainer);
|
|
88
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<BaoModal, [null, null, { optional: true; skipSelf: true; }, null]>;
|
|
89
|
-
static ɵprov: i0.ɵɵInjectableDeclaration<BaoModal>;
|
|
90
|
-
}
|
package/lib/modal/module.d.ts
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import * as i0 from "@angular/core";
|
|
2
|
-
import * as i1 from "./modal-container";
|
|
3
|
-
import * as i2 from "./modal-directives";
|
|
4
|
-
import * as i3 from "@angular/common";
|
|
5
|
-
import * as i4 from "@angular/cdk/overlay";
|
|
6
|
-
import * as i5 from "@angular/cdk/portal";
|
|
7
|
-
export declare class BaoModalModule {
|
|
8
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<BaoModalModule, never>;
|
|
9
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<BaoModalModule, [typeof i1.BaoModalContainer, typeof i2.BaoModalClose], [typeof i3.CommonModule, typeof i4.OverlayModule, typeof i5.PortalModule], [typeof i1.BaoModalContainer, typeof i2.BaoModalClose]>;
|
|
10
|
-
static ɵinj: i0.ɵɵInjectorDeclaration<BaoModalModule>;
|
|
11
|
-
}
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
import * as i0 from "@angular/core";
|
|
2
|
-
import * as i1 from "./pagination.component";
|
|
3
|
-
import * as i2 from "@angular/common";
|
|
4
|
-
import * as i3 from "../icon/module";
|
|
5
|
-
import * as i4 from "@angular/forms";
|
|
6
|
-
export declare class BaoPaginationModule {
|
|
7
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<BaoPaginationModule, never>;
|
|
8
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<BaoPaginationModule, [typeof i1.BaoPaginationComponent], [typeof i2.CommonModule, typeof i3.BaoIconModule, typeof i4.FormsModule], [typeof i1.BaoPaginationComponent]>;
|
|
9
|
-
static ɵinj: i0.ɵɵInjectorDeclaration<BaoPaginationModule>;
|
|
10
|
-
}
|
|
@@ -1,106 +0,0 @@
|
|
|
1
|
-
import { ChangeDetectorRef, EventEmitter, OnChanges, OnInit, SimpleChanges } from '@angular/core';
|
|
2
|
-
import * as i0 from "@angular/core";
|
|
3
|
-
export declare class BaoPaginationComponent implements OnChanges, OnInit {
|
|
4
|
-
private cdr;
|
|
5
|
-
/**
|
|
6
|
-
* The total number of items.
|
|
7
|
-
*/
|
|
8
|
-
totalItems: number;
|
|
9
|
-
/**
|
|
10
|
-
* The number of items per page as selected.
|
|
11
|
-
*/
|
|
12
|
-
itemsPerPage: number;
|
|
13
|
-
/**
|
|
14
|
-
* The current page number.
|
|
15
|
-
*/
|
|
16
|
-
currentPage: number;
|
|
17
|
-
/**
|
|
18
|
-
* The different page size options.
|
|
19
|
-
*/
|
|
20
|
-
pageSizeOptions: number[];
|
|
21
|
-
/**
|
|
22
|
-
* The label for the type of items that are displayed on the page
|
|
23
|
-
*/
|
|
24
|
-
itemLabel: string;
|
|
25
|
-
/**
|
|
26
|
-
* If selector for number of items per page should be displayed or not
|
|
27
|
-
*/
|
|
28
|
-
showItemsPerPageSelector: boolean;
|
|
29
|
-
/**
|
|
30
|
-
* EventEmitter that triggers when there is a page change and emits page number (index adjusted)
|
|
31
|
-
*/
|
|
32
|
-
pageChanged: EventEmitter<number>;
|
|
33
|
-
/**
|
|
34
|
-
* EventEmitter that triggers when the number of items per page is changed.
|
|
35
|
-
*/
|
|
36
|
-
itemsPerPageChanged: EventEmitter<number>;
|
|
37
|
-
/**
|
|
38
|
-
* Page number list to display
|
|
39
|
-
*/
|
|
40
|
-
displayedPages: number[];
|
|
41
|
-
/**
|
|
42
|
-
* Max number of pages to display
|
|
43
|
-
*/
|
|
44
|
-
private _maxPages;
|
|
45
|
-
/**
|
|
46
|
-
* Number of pages in total.
|
|
47
|
-
*/
|
|
48
|
-
private _totalPages;
|
|
49
|
-
/**
|
|
50
|
-
* Position of first item being displayed on current page.
|
|
51
|
-
*/
|
|
52
|
-
private _startItem;
|
|
53
|
-
/**
|
|
54
|
-
* Position of last item being displayed on current page.
|
|
55
|
-
*/
|
|
56
|
-
private _endItem;
|
|
57
|
-
constructor(cdr: ChangeDetectorRef);
|
|
58
|
-
get totalPages(): number;
|
|
59
|
-
set totalPages(value: number);
|
|
60
|
-
get startItem(): number;
|
|
61
|
-
set startItem(value: number);
|
|
62
|
-
get endItem(): number;
|
|
63
|
-
set endItem(value: number);
|
|
64
|
-
get rangeLabel(): string;
|
|
65
|
-
/**
|
|
66
|
-
* Flag that indicates if a previous page exists for the current list
|
|
67
|
-
*/
|
|
68
|
-
get hasPrevious(): boolean;
|
|
69
|
-
/**
|
|
70
|
-
* Flag that indicates if a next page exists for the current list
|
|
71
|
-
*/
|
|
72
|
-
get hasNext(): boolean;
|
|
73
|
-
ngOnInit(): void;
|
|
74
|
-
/**
|
|
75
|
-
* Update list of displayed pages when current page is changed.
|
|
76
|
-
*/
|
|
77
|
-
ngOnChanges(changes: SimpleChanges): void;
|
|
78
|
-
/**
|
|
79
|
-
* Navigate to specific page
|
|
80
|
-
*/
|
|
81
|
-
goTo(page: number): void;
|
|
82
|
-
/**
|
|
83
|
-
* Navigate to previous page
|
|
84
|
-
*/
|
|
85
|
-
handlePreviousClick(): void;
|
|
86
|
-
/**
|
|
87
|
-
* Navigate to next page
|
|
88
|
-
*/
|
|
89
|
-
handleNextClick(): void;
|
|
90
|
-
/**
|
|
91
|
-
* Update all required variables whenever the number of items displayed per page is changed.
|
|
92
|
-
* @param value New amount of items per page
|
|
93
|
-
*/
|
|
94
|
-
handlePageSizeChange(value: number): void;
|
|
95
|
-
private updateTotalPages;
|
|
96
|
-
private updateStartItem;
|
|
97
|
-
private updateEndItem;
|
|
98
|
-
/**
|
|
99
|
-
* Generate series of page numbers to display. The list always starts with page 1
|
|
100
|
-
* and ends with last page.
|
|
101
|
-
* Adds negative numbers for ellipsis.
|
|
102
|
-
*/
|
|
103
|
-
private buildPageNumbers;
|
|
104
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<BaoPaginationComponent, never>;
|
|
105
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<BaoPaginationComponent, "bao-pagination", never, { "totalItems": { "alias": "totalItems"; "required": false; }; "itemsPerPage": { "alias": "itemsPerPage"; "required": false; }; "currentPage": { "alias": "currentPage"; "required": false; }; "pageSizeOptions": { "alias": "pageSizeOptions"; "required": false; }; "itemLabel": { "alias": "itemLabel"; "required": false; }; "showItemsPerPageSelector": { "alias": "showItemsPerPageSelector"; "required": false; }; }, { "pageChanged": "pageChanged"; "itemsPerPageChanged": "itemsPerPageChanged"; }, never, never, false, never>;
|
|
106
|
-
}
|
package/lib/radio/index.d.ts
DELETED
package/lib/radio/module.d.ts
DELETED
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import * as i0 from "@angular/core";
|
|
2
|
-
import * as i1 from "./radio.component";
|
|
3
|
-
import * as i2 from "./radio-group.component";
|
|
4
|
-
import * as i3 from "@angular/common";
|
|
5
|
-
import * as i4 from "@angular/forms";
|
|
6
|
-
import * as i5 from "../common-components/module";
|
|
7
|
-
import * as i6 from "../button/module";
|
|
8
|
-
import * as i7 from "@angular/cdk/observers";
|
|
9
|
-
export declare class BaoRadioModule {
|
|
10
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<BaoRadioModule, never>;
|
|
11
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<BaoRadioModule, [typeof i1.BaoRadioButtonComponent, typeof i1.BaoRadioDescription, typeof i2.BaoRadioButtonGroupComponent], [typeof i3.CommonModule, typeof i4.FormsModule, typeof i4.ReactiveFormsModule, typeof i5.BaoCommonComponentsModule, typeof i6.BaoButtonModule, typeof i7.ObserversModule], [typeof i1.BaoRadioButtonComponent, typeof i1.BaoRadioDescription, typeof i2.BaoRadioButtonGroupComponent]>;
|
|
12
|
-
static ɵinj: i0.ɵɵInjectorDeclaration<BaoRadioModule>;
|
|
13
|
-
}
|