Skip to content

Add QR Code Encoder plugin - #226

Merged
ItsLemmy merged 16 commits into
noctalia-dev:mainfrom
Yocraft-2000:qr-code
Aug 3, 2026
Merged

Add QR Code Encoder plugin#226
ItsLemmy merged 16 commits into
noctalia-dev:mainfrom
Yocraft-2000:qr-code

Conversation

@Yocraft-2000

Copy link
Copy Markdown
Contributor

Plugin

  • Id: yocraft/qrcode
  • New plugin
  • Update to an existing plugin (version bumped in plugin.toml)

What it does

Transform any text or URL into a QR code completely offline. Then scan or copy the code.

External dependencies

qrencode

Testing

  • Tested on Niri
  • Tested on Hyprland
  • Tested on Sway
  • Tested on another compositor:
  • Noctalia version tested against: v5.0.0
  • Plugin API level: 15

Screenshots / Videos

image image

Checklist

  • The directory name matches the part of id after the / in plugin.toml exactly.
  • It ships plugin.toml, README.md, thumbnail.webp, and translations/en.json.
  • README.md follows the
    README template, documents
    every entry id and dependency, and includes exact panel IPC commands and launcher prefixes where applicable.
  • I created thumbnail.webp with the thumbnail generator.
  • version follows semver and is bumped in this PR; plugin_api is the oldest API level this plugin requires.
  • Every non-English translation in this PR uses a locale supported by Noctalia core, and I can read, write, and
    understand that language well enough to review and maintain it (no unreviewed machine/LLM translations).
  • I did not edit catalog.toml; CI generates it.
  • This PR touches exactly one plugin directory.

Code review attestation

Plugins run as trusted, unsandboxed Luau in the user's session. Confirm:

  • The code is readable and not obfuscated, minified, or generated.
  • It does not download and execute remote code.
  • Every network call, filesystem write, and spawned process is something the description above accounts for.
  • I have the right to publish this code under the license declared in plugin.toml.

@ItsLemmy

ItsLemmy commented Aug 3, 2026

Copy link
Copy Markdown
Contributor
  1. blocking - qrcode/plugin.toml:24

The custom_image widget setting uses type = "image", which the repository validator does not support.
Use "file" instead

[[widget.setting]]
key = "custom_image"
type = "file"
label_key = "widget.custom_image.label"
description_key = "widget.custom_image.description"
default = ""
extensions = [".png", ".jpg", ".jpeg", ".webp", ".svg"]
  1. non-blocking - qrcode/panel.luau:105

generate() shell-escapes the trimmed input before checking whether it is empty. Empty or whitespace-only input becomes "''", so the branch at qrcode/panel.luau:107 is unreachable. Submitting empty input invokes qrencode and reports a generation error instead of clearing the existing image and returning to the idle state.

@ItsLemmy
ItsLemmy marked this pull request as draft August 3, 2026 03:55
@Yocraft-2000
Yocraft-2000 marked this pull request as ready for review August 3, 2026 06:26
@ItsLemmy
ItsLemmy merged commit 8277d1b into noctalia-dev:main Aug 3, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants