SnapFrame 26.3.65169

dotnet tool install --global SnapFrame --version 26.3.65169
                    
This package contains a .NET tool you can call from the shell/command line.
dotnet new tool-manifest
                    
if you are setting up this repo
dotnet tool install --local SnapFrame --version 26.3.65169
                    
This package contains a .NET tool you can call from the shell/command line.
#tool dotnet:?package=SnapFrame&version=26.3.65169
                    
nuke :add-package SnapFrame --version 26.3.65169
                    

SnapFrame

SnapFrame is a .NET CLI tool that uses Playwright to capture webpage screenshots and SkiaSharp to add optional window chrome and backgrounds. It runs a background server over a named pipe so you can script multiple commands against a shared browser session.

Requirements

  • .NET SDK (target framework net10.0)
  • Playwright browsers (installed via the Playwright tooling if needed)

Quick Start (dotnet tool)

Use the same flow as the test script (test_cli.sh):

1. Install the tool

dotnet tool install --global SnapFrame

2. Install Chromium

SnapFrame requires Chromium. You can install it using the playwright.ps1 script that is included in the tool path folder.

If you don't have PowerShell, you can install it as a dotnet tool:

dotnet tool install --global PowerShell

To install Chromium, run the following command once after installing the SnapFrame tool:

snapframe install

Note: This command internally runs the playwright.ps1 script located in the tool's installation folder to download the required browsers.

3. Run Commands

# 1) Navigate to a page
PAGE_ID=$(snapframe navigate https://example.com)

# 2) Take a styled screenshot
snapframe capture "$PAGE_ID" example_mac.png --chrome macOS --bg Gradient:Sunset

# 3) Click a link by visible text
snapframe click "$PAGE_ID" --text "More information..."

# 4) Take another screenshot
snapframe capture "$PAGE_ID" iana.png

# 5) Close the page and stop the server
snapframe close "$PAGE_ID"
snapframe stop

You can run the complete scripted flow with:

./test_cli.sh

CLI Commands

  • navigate <url>: Opens a website and returns a Page ID.
  • capture <pageId> <path> [--chrome macOS|Windows11] [--bg Transparent|Gradient|Gradient:Midnight|Gradient:Sunset|Gradient:Candy|Gradient:Breeze|Gradient:Peach|Gradient:Aqua] [--full-page]: Captures a screenshot and optionally applies window chrome/background styling. Use --full-page to include the full scrollable page.
  • click <pageId> [--x <int> --y <int> | --text <string>]: Clicks by coordinates or visible text.
  • close <pageId>: Closes the page.
  • stop: Stops the background server and closes the browser.

Gradient themes (inspired by ray.so): Midnight, Sunset, Candy, Breeze, Peach, Aqua. Use them as --bg Gradient:<Theme> or pass the theme name directly (--bg Peach) to get the same effect.

Example Output

These images are generated by test_cli.sh:

  • macOS chrome + gradient background:

    macOS chrome + gradient background

  • Gradient theme samples:

    • Midnight: Gradient Midnight
    • Sunset: Gradient Sunset
    • Candy: Gradient Candy
    • Breeze: Gradient Breeze
    • Peach: Gradient Peach
    • Aqua: Gradient Aqua
  • Windows 11 chrome + transparent background:

    Windows 11 chrome + transparent background

  • Follow-up navigation screenshot:

    Follow-up navigation screenshot

Product Compatible and additional computed target framework versions.
.NET net10.0 is compatible.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

This package has no dependencies.

Version Downloads Last Updated
26.3.65169 134 3/11/2026
26.3.65157 110 3/10/2026
26.1.63723 140 1/24/2026
26.1.63719 125 1/24/2026
26.1.63712 114 1/24/2026
26.1.63707 109 1/23/2026
26.1.63690 108 1/23/2026
26.1.63686 106 1/23/2026
26.1.63685 108 1/23/2026
26.1.63680 118 1/22/2026
26.1.63674 120 1/22/2026
26.1.63673 114 1/22/2026