From 08be77242df16d5a9ba8f5c28ca8ea5409e21b20 Mon Sep 17 00:00:00 2001 From: Vasavi Kanamarlapudi Date: Fri, 27 Sep 2024 17:15:33 +0530 Subject: [PATCH] Digital ACT-191 ONEAPP-10928 story: onClick for close button --- VDS/Components/Modal/ModalDialogViewController.swift | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/VDS/Components/Modal/ModalDialogViewController.swift b/VDS/Components/Modal/ModalDialogViewController.swift index ba113b52..4d29a91f 100644 --- a/VDS/Components/Modal/ModalDialogViewController.swift +++ b/VDS/Components/Modal/ModalDialogViewController.swift @@ -81,13 +81,11 @@ open class ModalDialogViewController: UIViewController, Surfaceable { }.store(in: &subscribers) //clicking button - onClickSubscriber = modalDialog.closeButton.publisher(for: .touchUpInside) + onClickSubscriber = modalDialog.closeCrossButton.publisher(for: .touchUpInside) .sink {[weak self] button in guard let self else { return } self.dismiss() } - - modalDialog.closeCrossButton.onClick = { _ in self.dismiss() } view.addSubview(modalDialog)