@anguless/angulux/confirmdialog
ConfirmDialog
import
import { ConfirmDialogModule } from '@anguless/angulux/confirmdialog';Basic
ConfirmDialog renders what ConfirmationService is asked to confirm; the service is provided by the component that owns the dialog.
<agl-confirmDialog /><agl-button label="Delete" severity="danger" (onClick)="confirm()" /><span>{{ result() }}</span>API
Generated from the committed corpus, which check:corpus holds to the built library.
ConfirmDialog
componentagl-confirmDialog, agl-confirmdialog, agl-confirm-dialogConfirmDialog uses a Dialog UI that is integrated with the Confirmation API.
| Input | Type | Default | Description |
|---|---|---|---|
| header | string | undefined | not documented | Title text of the dialog. |
| icon | string | undefined | not documented | Icon to display next to message. |
| message | string | undefined | not documented | Message of the confirmation. |
| style | { [klass: string]: any } | null | undefined | not documented | Inline style of the element. |
| style | string | undefined | not documented | Class of the element. |
| mask | string | undefined | not documented | Specify the CSS class(es) for styling the mask element |
| accept | string | undefined | not documented | Icon of the accept button. |
| accept | string | undefined | not documented | Label of the accept button. |
| close | string | undefined | not documented | Defines a string that labels the close button for accessibility. |
| accept | string | undefined | not documented | Defines a string that labels the accept button for accessibility. |
| accept | boolean | not documented | Visibility of the accept button. |
| reject | string | undefined | not documented | Icon of the reject button. |
| reject | string | undefined | not documented | Label of the reject button. |
| reject | string | undefined | not documented | Defines a string that labels the reject button for accessibility. |
| reject | boolean | not documented | Visibility of the reject button. |
| accept | string | undefined | not documented | Style class of the accept button. |
| reject | string | undefined | not documented | Style class of the reject button. |
| close | boolean | not documented | Specifies if pressing escape key should hide the dialog. |
| dismissable | boolean | undefined | not documented | Specifies if clicking the modal background should hide the dialog. |
| block | boolean | not documented | Determines whether scrolling behavior should be blocked within the component. |
| rtl | boolean | not documented | When enabled dialog is displayed in RTL direction. |
| closable | boolean | not documented | Adds a close icon to the header to hide the dialog. |
| append | HTMLElement | ElementRef | TemplateRef<any> | 'self' | 'body' | null | undefined | any | 'body' | Target element to attach the overlay, valid values are "body" or a local ng-template variable of another element (note: use binding with brackets for template variables, e.g. [appendTo]="mydiv" for a div element having #mydiv as variable name). |
| key | string | undefined | not documented | Optional key to match the key of confirm object, necessary to use when component tree has multiple confirm dialogs. |
| auto | boolean | not documented | Whether to automatically manage layering. |
| base | number | not documented | Base zIndex value to use in layering. |
| transition | string | not documented | Transition options of the animation. |
| focus | boolean | not documented | When enabled, can only focus on elements inside the confirm dialog. |
| default | 'accept' | 'reject' | 'close' | 'none' | not documented | Element to receive the focus when the dialog gets visible. |
| breakpoints | any | not documented | Object literal to define widths per screen size. |
| modal | boolean | not documented | Defines if background should be blocked when dialog is displayed. |
| visible | any | not documented | Current visible state as a boolean. |
| position | 'center' | 'top' | 'bottom' | 'left' | 'right' | 'topleft' | 'topright' | 'bottomleft' | 'bottomright' | not documented | Allows getting the position of the component. |
| draggable | boolean | not documented | Enables dragging to change the position using header. |
| Output | Type | Description |
|---|---|---|
| on | EventEmitter<ConfirmEventType> | Callback to invoke when dialog is hidden. |
| Template slot | Description |
|---|---|
| <ng-template #header> | Custom header template. |
| <ng-template #footer> | Custom footer template. |
| <ng-template #rejecticon> | Custom reject icon template. |
| <ng-template #accepticon> | Custom accept icon template. |
| <ng-template #message> | Custom message template. |
| <ng-template #icon> | Custom icon template. |
| <ng-template #headless> | Custom headless template. |
Inherited from BaseComponent
inherited| Input | Type | Default | Description |
|---|---|---|---|
| dt | Object | undefined | undefined | Defines scoped design tokens of the component. |
| unstyled | boolean | undefined | undefined | Indicates whether the component should be rendered without styles. |
| pt | PT | undefined | undefined | Used to pass attributes to DOM elements inside the component. Keys become attributes, and a key that names a DOM property is also assigned to that property. Values the browser would execute go through Angular's sanitizer first, as in a template binding: markup in `innerHTML`, `outerHTML` and `srcdoc`, and URLs in `href`, `src`, `action`, `formaction` and `xlink:href`. To write one of those unsanitized on purpose, pass a `DomSanitizer.bypassSecurityTrustHtml` or `bypassSecurityTrustUrl` value. An `on*` key must be a function, and any other value for it is ignored. Keys themselves are applied as given, so let data from users choose values, never keys. |
| pt | PassThroughOptions | undefined | undefined | Used to configure passthrough(pt) options of the component. |