Skip to content

dash: allow placing a card type more than once - #4312

Merged
purian23 merged 3 commits into
duxlabs-dev:masterfrom
Conava:dash-multi-placement
Nov 18, 2026
Merged

purian23 merged 3 commits into
duxlabs-dev:masterfrom
Conava:dash-multi-placement

Conversation

@Conava

@Conava Conava commented Nov 17, 2026

Copy link
Copy Markdown
Contributor

Description

First PR for the system monitor widgets redesign that I shared in the design channel. This lets a dash card be placed more than once. The new System monitor card will need that later (e.g. one card per drive or per GPU), and the clock is the first card that already uses it, so an analog and a digital clock side by side, or a big one plus a small one with the date.

A card type opts in with allowMultiple, the same flag the Control Center widgets use. Each copy keeps its own options, so two clocks can be set up differently. Cards that don't opt in work exactly like before and saved dash layouts load unchanged.

Settings -> Dashboard shows one options card per clock, numbered from the second one on (Clock, Clock 2, ...). The first clock keeps the existing clock options, so nothing changes for anyone.

Type of change

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that changes existing behavior)
  • Refactor / internal cleanup
  • Documentation
  • Other

Related issues

Screenshots / video

screenshot_2026-11-18_00-26-29

Checklist

  • My code follows the conventions in CONTRIBUTING.md
  • I have tested my changes locally
  • New user-facing strings are wrapped in I18n.tr() with translator context, reusing existing terms where possible
  • Go changes: ran make fmt, added/updated tests, make test passes, and go mod tidy is clean
  • QML changes: ran make lint-qml with no new warnings
  • I have opened a corresponding pull request in dux-docs to document any new behaviors: https://github.com/duxlabs-dev/dux-docs

A card type can set card.allowMultiple in the registry. Each placement
of such a type gets its own instanceId and keeps its options on the
placement in dashCards, like Control Center widgets do. Placements
without an instanceId keep using dashOptions, so saved layouts load
unchanged.

Claude-Session: https://claude.ai/code/session_01DQu2E4BboXnuoPrnnmViJ7
Clock is the first card that can be placed more than once, e.g. an
analog and a digital clock side by side. Each copy is set up from its
own options sheet in edit mode, so Settings no longer shows one shared
Clock card for them. Keyboard focus returns to the copy it was on.

Claude-Session: https://claude.ai/code/session_01DQu2E4BboXnuoPrnnmViJ7
Settings -> Dashboard lists one options card per placed clock again,
numbered from the second one on, instead of hiding them. The first clock
keeps using the shared options, so its settings and search entries work
as before.

Claude-Session: https://claude.ai/code/session_01DQu2E4BboXnuoPrnnmViJ7
@github-actions github-actions Bot added feature ui Quickshell UI under quickshell/ labels Nov 17, 2026
@github-actions

github-actions Bot commented Nov 17, 2026 •

Copy link
Copy Markdown
Contributor

Claude review

No issues found.
Checked: per-instance option read/write/reset paths in DashRegistry, instanceId survival through grid move/resize commits (placedItems, syncTiles keyed by id+instanceId), addCard instance assignment, focus-key consumers (cache, tab host), options sheet and Settings → Dashboard keyed ScriptModel numbering, remaining callers of the renamed unplaced/storedOptions APIs, deprecated shims, tokens and i18n. Model: claude-opus-5-5.

@purian23
purian23 merged commit 02dd552 into duxlabs-dev:master Nov 18, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature ui Quickshell UI under quickshell/

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants