Skip to content

feat(plugins): let plugins import frappe-ui's Dialog - #242

Merged
Rl0007 merged 4 commits into
developfrom
feat/plugin-dialogs-develop
Oct 10, 2026
Merged

Rl0007 merged 4 commits into
developfrom
feat/plugin-dialogs-develop

Conversation

@NagariaHussain

Copy link
Copy Markdown
Contributor

Summary

Plugins can now import frappe-ui's Dialog on pages, cards, settings and actions. The dashboard stylesheet now also styles classes that a plugin uses only in its .js or .ts files.

#241 has these same three commits. It merged into feat/order-hooks after #201 had merged that branch into develop, so the commits did not reach develop.

Why

The build kit refused every Dialog import to prevent a dialog on top of Commera's action dialog. That is a UX preference, not a technical limit, and it blocked normal page uses such as a create form or a confirmation. A plugin author can decide this. We can add a rule later if plugins misuse it.

The stylesheet scanned only commera/**/*.vue in each plugin. A class or icon that appears only in shared .js code, for example a Dropdown option icon, got no style and drew nothing.

What changed

  • @commera/plugin-kit no longer fails a build that imports Dialog from frappe-ui. The kit README no longer lists it.
  • dashboard/tailwind.config.js scans commera/**/*.{vue,js,ts} in each installed plugin.
  • Rollout: run bench build --app commera so that existing plugins pick up classes from their .js files.
  • The docs page "Dashboard entries" on docs.bwh.tech still lists Dialog under build checks. Remove it there.

Screenshots

A plugin page that opens a Dialog:

A Dropdown option icon set only in a plugin's .js file. Before, the Duplicate icon is blank. After, it draws:

🤖 Generated with Claude Code

NagariaHussain and others added 3 commits October 9, 2026 18:22
The kit failed any plugin build that imported Dialog, to stop a dialog on top
of Commera's action dialog. That blocked normal uses on pages and cards, such
as a create form or a confirmation. Plugins can now import Dialog anywhere.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The dashboard stylesheet scanned only a plugin's .vue files, so a class or
icon used only in shared .js code, such as a Dropdown option icon, had no
style and drew nothing.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@Rl0007
Rl0007 merged commit 3940fed into develop Oct 10, 2026
8 checks 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