Preview changes in xcode 15 and lesson 28 of polishing the app

I am learning from Catie on polishing the app but since she uploaded the video Xcode 15 has changed the preview to just #preview {}. It behaves differently as I am getting the error "Attribute “private” can only be used in a non-local scope. I thought if I wanted something kept local I used private. How do I fix this error with the new xcode . Catie shows the line static private var alertIsVisible = Binding.constant(false) but it creates two errors now. The one I mentioned as well as it wants static removed.