Cook Mode (Screen WakeLock)

by blotspot
5
4
3
2
1
Score: 35/100
New Plugin

Description

This plugin has not been manually reviewed by Obsidian staff. Keeps the display awake while the app is in the foreground, so you can keep cooking in your notes.

Reviews

No reviews yet.

Stats

stars
downloads
0
forks
0
days
NaN
days
NaN
days
0
total PRs
0
open PRs
0
closed PRs
0
merged PRs
0
total issues
0
open issues
0
closed issues
0
commits

Latest Version

Invalid date

Changelog

README file from

Github

GitHub Release GitHub Release License

Cook Mode (Screen WakeLock) Plugin

A plugin for Obsidian that ensures your screen stays awake while using the app. It leverages the Screen Wake Lock API to prevent your screen from going dark without interaction, making it ideal for long reading, writing or brainstorming sessions, or for using Obsidian as a cook book.

Features

  • Keeps the display awake while Obsidian is in the foreground.
  • Simple and lightweight implementation with minimal impact on performance.
  • Multiple activation strategies:
    • Always On: Keeps the screen awake as long as Obsidian is open.
    • Frontmatter: Control activation per file.
    • Editor Focus: Activates only when the editor is in focus.
    • Editor Typing: Activates after five seconds of inactivity (while in the editor).
  • Customizable settings:
    • Enable or disable the plugin with a toggle.
    • Choose your preferred activation strategy.
    • Show or hide the WakeLock status in the status bar.
    • Enable or disable notifications for WakeLock events.
    • Developer mode for debugging.
  • Cross-platform support: Works on desktop and mobile platforms (with some limitations on iOS).
  • Hotkey and command palette integration for quick toggling.
  • Status bar integration: Displays the current WakeLock state.

Usage

Once the plugin is enabled, it will automatically keep your screen awake whenever Obsidian is in the foreground. A successful wake lock is indicated by a "Cook Mode on." notification.

You can toggle the functionality through:

  • Hotkeys (configurable in Obsidian settings).
  • The command palette (Toggle Cook Mode).
  • The status bar icon (if enabled).

Activation Strategies

  • Always On: Keeps the screen awake as long as Obsidian is open.
  • Frontmatter: Use cook-mode: true in the frontmatter definition to keep the screen awake while the file is active.
  • Editor Focus: Activates only when the editor is in focus.
  • Editor Typing: Activates after five seconds of inactivity (while in the editor).

General rule: The wake lock will release when entering the settings window and reapplied when the settings are exited.

Compatibility

See: Browser Compatibility for the Wake Lock API.

iOS Limitations

Due to partial compatibility, the plugin may not work flawlessly on iOS devices. If the wake lock does not activate when starting the app, try disabling and re-enabling the plugin one or two times. Once it works, it will continue to function until the app is restarted. For convenience, consider creating a keyboard shortcut or configuring your mobile toolbar.

[!NOTE] For devices running iOS 18.4 and later, this is no longer true.

Installation

From Github

  1. Download the latest release from the releases page.
  2. Unzip the downloaded file.
  3. Copy the folder to your Obsidian plugins directory (usually located at .obsidian/plugins).
  4. Enable the "Screen WakeLock" plugin from the Settings > Community Plugins menu in Obsidian.

As beta plugin (using BRAT)

  1. Install BRAT from the Community Plugins in Obsidian.
  2. Open the command palette and run the command BRAT: Add a beta plugin for testing
  3. Copy the project link (https://github.com/blotspot/obsidian-wake-lock) into the modal that opens up.
  4. Make sure Enable after installing the plugin is checked
  5. Click on Add Plugin
Updating

Beta plugins can be updated using the command palette by running the command Check for updates to all beta plugins and UPDATE. Optionally, beta plugins can be configured to auto-update when starting Obsidian. This feature can be enabled in the BRAT plugin settings tab.

API Documentation