Fixed #2266 - Type declaration and export bug on ConfirmationService

pull/2324/head
Tuğçe Küçükoğlu 2022-03-16 13:00:50 +03:00
parent 1a2084935a
commit 9fe6164d9a
3 changed files with 61 additions and 2 deletions

View File

@ -4,8 +4,15 @@ import { ConfirmationOptions } from '../confirmationoptions';
declare const plugin: Plugin;
export default plugin;
interface ConfirmationServiceMethods {
export interface ConfirmationServiceMethods {
/**
* Displays the dialog using the confirmation object options.
* @param {ConfirmationOptions} options - Confirmation Object
*/
require(options: ConfirmationOptions): void;
/**
* Hides the dialog without invoking accept or reject callbacks.
*/
close(): void;
}

View File

@ -32,6 +32,7 @@ import ConfirmDialog from 'primevue/confirmdialog';
<ConfirmDialog></ConfirmDialog>
<Button @click="delete()" icon="pi pi-check" label="Confirm"></Button>
</code></pre>
<pre v-code.script><code>
@ -202,6 +203,31 @@ export default {
</table>
</div>
<h5>ConfirmationService</h5>
<div class="doc-tablewrapper">
<table class="doc-table">
<thead>
<tr>
<th>Name</th>
<th>Parameters</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td>require</td>
<td>confirm: Confirmation Object</td>
<td>Displays the dialog using the confirmation object options.</td>
</tr>
<tr>
<td>close</td>
<td>-</td>
<td>Hides the dialog without invoking accept or reject callbacks.</td>
</tr>
</tbody>
</table>
</div>
<h5>Properties</h5>
<p>Any property as style and class are passed to the main container element. Following are the additional properties to configure the component.</p>
<div class="doc-tablewrapper">

View File

@ -32,6 +32,7 @@ import ConfirmPopup from 'primevue/confirmpopup';
&lt;ConfirmPopup&gt;&lt;/ConfirmPopup&gt;
&lt;Button @click="delete($event)" icon="pi pi-check" label="Confirm"&gt;&lt;/Button&gt;
</code></pre>
<pre v-code.script><code>
@ -201,6 +202,31 @@ export default {
</table>
</div>
<h5>ConfirmationService</h5>
<div class="doc-tablewrapper">
<table class="doc-table">
<thead>
<tr>
<th>Name</th>
<th>Parameters</th>
<th>Description</th>
</tr>
</thead>
<tbody>
<tr>
<td>require</td>
<td>confirm: Confirmation Object</td>
<td>Displays the dialog using the confirmation object options.</td>
</tr>
<tr>
<td>close</td>
<td>-</td>
<td>Hides the dialog without invoking accept or reject callbacks.</td>
</tr>
</tbody>
</table>
</div>
<h5>Properties</h5>
<p>Any property as style and class are passed to the main container element. Following are the additional properties to configure the component.</p>
<div class="doc-tablewrapper">