Sidebar created on macOS 26 with NSSplitViewItem(sidebarWithViewController:) is cut off at the top in fullscreen mode

I noticed that when I have a fullscreen window in macOS 26, sidebars look like they are cut off at the top: they suddenly stop where the title bar/toolbar would appear when moving the mouse to the top of the screen, leaving a wide empty gap. Am I the only one who finds this ugly? Is this intended, or is there a workaround?

This is how it looks in fullscreen (the sidebar borders are not easy to distinguish, look for the drop shadow):

And this when moving the mouse to the top screen border to show the menu bar:

I created FB20291636.


@main
class AppDelegate: NSObject, NSApplicationDelegate, NSWindowDelegate {

    func applicationDidFinishLaunching(_ aNotification: Notification) {
        let splitViewController = NSSplitViewController()
        splitViewController.addSplitViewItem(NSSplitViewItem(sidebarWithViewController: ViewController()))
        splitViewController.addSplitViewItem(NSSplitViewItem(viewController: ViewController()))
        let window = NSWindow(contentViewController: splitViewController)
        window.styleMask = [.titled, .closable, .miniaturizable, .resizable, .fullSizeContentView]
        window.toolbar = NSToolbar()
        window.delegate = self
        window.makeKeyAndOrderFront(nil)
    }

    func window(_ window: NSWindow, willUseFullScreenPresentationOptions proposedOptions: NSApplication.PresentationOptions = []) -> NSApplication.PresentationOptions {
        return [.autoHideToolbar, .autoHideMenuBar, .fullScreen]
    }

}

class ViewController: NSViewController {

    override func loadView() {
        let stack = NSStackView(views: [
            NSTextField(labelWithString: "asdf")
        ])
        stack.orientation = .vertical
        stack.alignment = .leading
        view = stack
        view.frame = CGRect(x: 0, y: 0, width: 300, height: 300)
    }

}

I forgot to mention that this behaviour only happens when using the .fullSizeContentView window style mask. Without it, the sidebar extends almost to the top of the screen in fullscreen mode. It's still cut off shortly before reaching the top, but at least there's not such a big gap.

When moving the mouse to the top of the screen to show the menu bar, the top of the sidebar and content view are hidden, but that's what I would also expect with a full screen content view.

Sidebar created on macOS 26 with NSSplitViewItem(sidebarWithViewController:) is cut off at the top in fullscreen mode
 
 
Q