Bases Freeze Panes

by theluckystrike
5
4
3
2
1
Score: 50/100

Description

Keeps the header row and the first columns of a Bases table in view while you scroll, in base files and in bases embedded in notes.

Reviews

No reviews yet.

Stats

0
stars
717
downloads
0
forks
40
days
4
days
4
days
1
total PRs
0
open PRs
0
closed PRs
1
merged PRs
0
total issues
0
open issues
0
closed issues
18
commits

Latest Version

5 days ago

Changelog

Patch Changes

  • The Sponsor button now opens the NoteMods one-time tier.

README file from

Github

Bases Freeze Panes

Bases Freeze Panes keeps the header and first column of a Bases table in view while you scroll, like a spreadsheet.

It supports base files, note embeds and base code blocks. The header and first column are free. A total payment of $15 meets the payment requirement for Pro without further payment. Sign-in and the checks below still apply.

Quick start

Paste this into a note:

views:
  - type: table
    name: All notes
    order:
      - file.name
      - file.folder
      - file.path
      - file.ext
      - file.size
      - file.ctime
      - file.mtime
      - file.tags

Freezing works for every table view of a base in a note: embedded base files, base code blocks, live preview and reading view. In a wide base, the first column stays in place when you scroll right. The plugin caps embedded tables at 500 pixels by default. A taller table scrolls inside this box, so its header row sticks to the top.

Features

Pro costs $15 one time or $5 a month: Sponsor or $15 one-time offer.

Frozen header and first column in base files

In a wide base, the first column stays in place when you scroll right. The other columns slide under it, and a thin line marks its edge. The header has a solid background.

Embedded bases keep their header

The plugin caps embedded tables at 500 pixels by default. A taller table scrolls inside this box, so its header row sticks to the top.

Frozen Markdown and Dataview tables

Turn on "Freeze Markdown and Dataview tables" in the settings. This free feature gives each rendered table in a note tab its own scroll box. The header stays at the top, and the first column stays on the left. Cell text does not wrap, so a wide table scrolls to the side. It works in reading view and live preview.

The main switch, the file switch, the header switch, "Frozen columns" (0 or 1) and the height setting apply. Dataview queries need the Dataview plugin.

Two or three frozen columns (Pro)

Change the column order in the base to choose which columns come first.

Pinned last column (Pro)

Turn on "Freeze the last column" for a status, a total or a due date.

Pin a property (Pro)

Type a property name in "Pin a property", for example author, note.author or formula.total. A hidden property stays hidden.

Clear the field to remove this pin. If the property is also the last column, it uses the left edge. Note tables do not change.

Reading view, live preview and code blocks

Freezing works for every table view of a base in a note: embedded base files, base code blocks, live preview and reading view.

Solid cells in light and dark themes

Frozen cells use theme colors, so the cells that slide under them stay hidden.

Choices for one file

Two commands change one base file or note:

  • "Turn frozen panes on or off for the current file" is free.
  • "Set frozen columns for the current file" picks 0 to 3 columns for that file. This one needs Pro.

Each choice moves with its file or folder when you rename or move it, and goes away when you delete the file. The settings list the choices.

Choices for one view

A wide view may need frozen columns while a narrow view does not. Open the view, then run "Set frozen panes for the current view". In a note, it needs exactly one embedded view.

  • "Freeze this view" and "Freeze the header row" are free. Header off also removes the height cap of an embedded view.
  • "Frozen columns" sets 0 to 3 columns for the view. This needs Pro.
  • "Use the file choice" removes the view choice.

A view choice is saved with the open file, so a base-tab choice does not reach notes that embed the view. It wins over the file choice, but a file that is off stays off. A renamed view leaves its old file > view choice in the settings to delete. Markdown and Dataview tables ignore view choices.

Install

Open Settings, Community plugins, then Browse. Search for "Bases Freeze Panes". Select Install, then Enable.

To install by hand, download main.js, manifest.json and styles.css from the latest release. Put them in <vault>/.obsidian/plugins/bases-freeze-panes/. Reload the community plugins, then turn on Bases Freeze Panes.

Bases Freeze Panes needs Obsidian 1.13.4 or newer and the Bases core plugin. Tests for this update ran on desktop Obsidian 1.14.4.

Usage

  1. Turn on the plugin. Bases tables now have a frozen header and first column.
  2. Open a wide base and scroll down and to the right.
  3. To compare with the normal table, run "Turn frozen panes on or off". Run it again to undo.
  4. For Pro, sponsor on GitHub, then open the settings and select "Sign in with GitHub".

Pro

The command "What Pro adds" shows each with a demo.

  • Freeze 2 or 3 columns on the left. The free version freezes 1 column.
  • Set the number of frozen columns for one file or for one view of a base.
  • Keep the last column at the right edge while you scroll sideways.
  • Pin a property, so that its column stays next to the frozen columns.

Sponsor $5 a month, or $15 once. When you have paid $15 in total, Pro stays on.

Sponsor through the links above, then select "Sign in with GitHub" in settings. Saved choices return when Pro is on again.

Settings

After a minor or major update, this plugin opens one What's new tab in the background. The tab and settings card suggest other NoteMods plugins and Zovo Chat and link to notemods.com for feedback (privacy). The tab sends no data. Turn the tab off in Settings.

Setting Default Allowed values
Freeze panes On On or off
Freeze the header row On On or off
Freeze Markdown and Dataview tables Off On or off (free)
Frozen columns 1 0 to 3 (2 and 3 need Pro)
Freeze the last column Off On or off (Pro)
Pin a property Empty A visible property name (Pro)
Embedded table height 500 200 to 1200 pixels, in steps of 50
Choices for single files Empty File choices and file > view choices from the commands

Delete an entry in "Choices for single files" to remove it. If a saved value is out of range, the plugin moves it to the nearest allowed value.

FAQ

Why did my CSS snippet for the first column not work?

The core table draws only visible cells to stay fast on large bases. After you scroll right, the first-column cells leave the page. The plugin keeps and pins them.

Does it change my base files or notes?

No. It writes only its own settings file, data.json in the plugin folder.

What happens after an Obsidian update?

The plugin checks the Bases table before it changes anything. If a future update changes the table, columns stop freezing and the settings tab says so. The header row keeps working.

Why is the outline of the selected cell not visible in a frozen column?

The core app draws that outline in a separate layer. You can still click and edit the cell.

Does it work for cards and list views?

No. Only table views.

Payment, account and network

The core features are free. Pro features need a GitHub Sponsors sponsorship of theluckystrike: $5 a month or more, or $15 once. A total payment of $15 meets the payment requirement for Pro without further payment. Sign-in and the checks below still apply. Your notes stay readable and editable with or without Pro.

One payment turns on Pro in every NoteMods plugin.

GitHub handles the payment. Sponsor at https://github.com/sponsors/theluckystrike?frequency=one-time&metadata_source=bases-freeze-panes. You need no account for the free features. Pro needs the GitHub account that sponsors.

Until you select "Sign in with GitHub" in the settings, Bases Freeze Panes makes no network requests. Sign in uses the GitHub device flow. Bases Freeze Panes sends its public client ID and the scope read:user to https://github.com/login/device/code and shows you a code. While you enter the code at https://github.com/login/device, it asks https://github.com/login/oauth/access_token every few seconds to check the sign-in status. The scope permits profile reads only. GitHub needs this access to show the sponsorship tier. It grants no repository scope and no write access.

After sign in, Bases Freeze Panes sends one query to https://api.github.com/graphql. It checks if the signed-in account sponsors theluckystrike. It asks for the tier and the total payment to theluckystrike. The plugin reuses a successful check for 7 days. Failed checks can retry after 6 hours. Select Refresh to request an earlier check. It sends no note content, file names or other vault data, and it has no telemetry.

After a successful check, Pro can work offline for up to 14 days. Sign out or a negative sponsorship answer turns Pro off. The plugin stores the GitHub token through the secret storage API of Obsidian. It does not put the token in its saved settings or its local sponsorship data. The local storage of this device keeps your GitHub login, the tier and the time of the last check. Sign out clears the token. You can also revoke the access in your GitHub settings, under Applications.

Support

Plugin page: bases-freeze-panes.

Report bugs and feature requests in this repository's issue tracker. Include your Obsidian version, theme and the view settings of the base.

To build from source:

npm ci
npm run build
npm test

License

MIT

Community

Questions, bugs or plugin ideas? Talk to me and other Obsidian users in Zovo Chat on Telegram. It has a topic for these plugins. You can also open an issue here.