I have an AppleScript which sets my preferences, in this case for Finder. Prior to Big Sur, I was able to select a checkbox to toggle with the following:
However, in Big Sur, the name property of these particular checkboxes appears to be missing. The following script run with Script Editor shows the difference:
Prior to Big Sur, the results are:
But on Big Sur (at least on the M1 MBP I have access to with Big Sur), the results are:
You can see the name property on Big Sur is missing. Is this a bug? Some other preferences scripts I have appear to still work using the element names to interact with the UI, though I have not tested them all.
Code Block tell checkbox "Recents" to if value is 1 then click
However, in Big Sur, the name property of these particular checkboxes appears to be missing. The following script run with Script Editor shows the difference:
Code Block tell application "Finder" activate delay 1 end tell tell application "System Events" tell process "Finder" keystroke "," using {command down} delay 1 tell window "Finder Preferences" click button "Sidebar" of toolbar 1 delay 0.5 tell checkbox 1 get properties end tell end tell end tell end tell
Prior to Big Sur, the results are:
Code Block {minimum value:missing value, orientation:missing value, position:{47, 943}, class:checkbox, accessibility description:missing value, role description:"checkbox", focused:false, title:"Recents", size:{297, 18}, help:missing value, entire contents:{}, enabled:true, maximum value:missing value, role:"AXCheckBox", value:0, subrole:missing value, selected:missing value, name:"Recents", description:"checkbox"}
But on Big Sur (at least on the M1 MBP I have access to with Big Sur), the results are:
Code Block {minimum value:missing value, orientation:missing value, position:{705, 234}, class:checkbox, accessibility description:"Recents", role description:"checkbox", focused:false, title:"", size:{14, 16}, help:missing value, entire contents:{}, enabled:true, maximum value:missing value, role:"AXCheckBox", value:1, subrole:missing value, selected:missing value, name:missing value, description:"Recents"}
You can see the name property on Big Sur is missing. Is this a bug? Some other preferences scripts I have appear to still work using the element names to interact with the UI, though I have not tested them all.