How do I Change How Links are Opened?

A: By default, links in a PDF are opened in Safari. However, you can change this behaviour and instead open them in various ways, including an inline web view controller, an inline browser, first showing an alert before opening the link or not opening the link at all. You can change how links are handled by setting the linkAction property in the configuration of your view controller:

let controller = PSCKioskPDFViewController(document: document) {
    // Change link action to use inline browser
    $0.linkAction = .inlineBrowser