(button: AlertButton | undefined, data?: any)
| 525 | } |
| 526 | |
| 527 | private async callButtonHandler(button: AlertButton | undefined, data?: any) { |
| 528 | if (button?.handler) { |
| 529 | // a handler has been provided, execute it |
| 530 | // pass the handler the values from the inputs |
| 531 | const returnData = await safeCall(button.handler, data); |
| 532 | if (returnData === false) { |
| 533 | // if the return value of the handler is false then do not dismiss |
| 534 | return false; |
| 535 | } |
| 536 | if (typeof returnData === 'object') { |
| 537 | return returnData; |
| 538 | } |
| 539 | } |
| 540 | return {}; |
| 541 | } |
| 542 | |
| 543 | private getValues(): any { |
| 544 | if (this.processedInputs.length === 0) { |
no test coverage detected