Toggle Shopping Mode

Posted by agiletortoise, Last update over 1 year ago

Enable or disable “Shopping mode”. This is a convenience script to turn on or off three features at once:

  • Focus mode
  • Link mode
  • The device idle (sleep) timer

My primary use for this “mode” is shopping at the grocery store. I make a task [ ] list in a draft. Enabling focus mode keeps my shopping list active. Enabling link mode keeps accidental taps from entering edit mode and showing the keyboard. Disabling the system idle timer keeps your phone from going to sleep so you don’t have to wake up the phone every time you want to check off another item.

For more details on using this action, read the Working with Lists tip article.


  • script

    let p = Prompt.create();
    p.title = "Shopping Mode"
    p.message = "Pin current draft, enable link mode, and disable device idle timer to make it easier to check off lists while shopping."
    p.isCancellable = true
    if ( {
    	if (p.buttonPressed == "Enable") {
    		app.isIdleDisabled = true
    		editor.focusModeEnabled = true
    		editor.linkModeEnabled = true
    	else { // disable
    		app.isIdleDisabled = false
    		editor.focusModeEnabled = false
    		editor.linkModeEnabled = false


  • After Success Nothing
    Notification Error
    Log Level Error
Items available in the Drafts Directory are uploaded by community members. Use appropriate caution reviewing downloaded items before use.