Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Two "Close" buttons in Console #183

Closed
OneSman7 opened this issue Apr 13, 2023 · 8 comments
Closed

Two "Close" buttons in Console #183

OneSman7 opened this issue Apr 13, 2023 · 8 comments
Labels
bug Something isn't working

Comments

@OneSman7
Copy link

OneSman7 commented Apr 13, 2023

I just updated to the recent version (3.5.4 -> 3.5.7) and see this in Console))
I think screenshot says it all :D
It does not prevent from using console - both buttons work.

photo_2023-04-13 19 08 33

@kean
Copy link
Owner

kean commented Apr 13, 2023

Hey, thanks for the report. Can you the code that shows the console please?

@OneSman7
Copy link
Author

func presentPulseLogging(on controller: UIViewController) {
        
        let vc = PulseUI.MainViewController(store: .shared) { [weak controller] in
            controller?.dismiss(animated: true, completion: nil)
        }
        
        vc.modalPresentationStyle = .fullScreen
        
        controller.present(vc, animated: true, completion: nil)
    }

@OneSman7
Copy link
Author

It seems 2 buttons come from here

Снимок экрана 2023-04-13 в 21 11 47

@OneSman7
Copy link
Author

It was needed previously to provide onDismiss to close console correctly. Seems now it is not necessary and results in 2 buttons :)

@kean
Copy link
Owner

kean commented Apr 16, 2023

Yes, you can remove onDismiss for now as a workaround. I'm going to update the API in the upcoming release.

@kean kean added the bug Something isn't working label Apr 16, 2023
@kean
Copy link
Owner

kean commented Apr 22, 2023

Fixed in 3.6.0.

@kean kean closed this as completed Apr 22, 2023
@OneSman7
Copy link
Author

Hello again!
Now on iOS 14 no close button is displayed. Will have to resort to display console not fullscreen to be able to close it. Maybe it is connected to @Environment(.presentationMode) being debrecated, but I am not sure.

@kean
Copy link
Owner

kean commented Jul 12, 2023

I don't know; this API has been hit or miss. In my testing, it works, but it depends on how you present it and what View/ViewController hierarchy.

The expected behavior is that it should be displayed by default. I would appreciate it if you could provide a sample where I can reproduce it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants