Commit Graph
57 Commits
Author SHA1 Message Date
Linus Rath 35be105a73 fix: size small text in rem so it follows the browser and app text size 2026-10-29 19:38:45 +01:00
Linus Rath 1111dd6709 fix: show the focus outline on menu items, grid cells and other roving-focus controls 2026-10-29 19:38:44 +01:00
Linus Rath bead8ccbab fix: keep the keyboard focus inside plugin dialogs and return it when they close 2026-10-29 18:02:58 +01:00
Linus Rath 8108249a35 Merge pull request #1406 from HOLOEYE-JZ/feat/plugin-ui-navigate
# Conflicts:
#	app/(main)/[locale]/layout.tsx
2026-10-28 17:02:42 +01:00
Linus Rath 96797597c5 Merge branch 'main' into feat/org-features 2026-10-28 15:14:34 +01:00
Jacob Zeitz ba45d0f8b9 feat(plugins): api.ui.openPage moves the tab to one of the plugin's own pages 2026-10-28 13:50:12 +01:00
Linus Rath 23f67a5e72 fix: keep plugin chips named by their filter, draw the team icons at once and pass attributes to icons still loading 2026-10-28 08:16:52 +01:00
Linus Rath a69d7eee33 feat: let plugins work with team mailboxes: list filters, row badge icons, account info and message conditions
What the team inbox plugin needs, kept general for other plugins:

- `api.ui.setListFilters`: keyword filters drawn as chips in the list
  header of the folders they apply to (by account kind and folder
  role). A chip the user turns on is ANDed into the folder's query and
  comes off with one click; a keyword change a filter tests loads the
  list again (ui:message-list).
- Actions get `accounts`, `hasKeyword` and `notKeyword`, so a button
  shows only on messages of group accounts, or of a keyword state; the
  click of message-row-actions and reader-actions carries the message's
  `accountId`.
- `api.email.updateKeywords`: several keywords in one change, through
  the list for a listed message (email:write).
- `api.user.getSelf`, `getMailAccounts` and `findPeople`: the user's own
  account id (Stalwart's principal id), which accounts are group
  accounts, and people from the directory (account:read).
- `api.accountData`: a plugin's own entry in a mail account's shared
  Inbox metadata on Stalwart 1.0 (email:read / email:write).
- Row badges take an `icon`.
2026-10-28 06:39:57 +01:00
Linus Rath e33f95989d fix: use the vertical More icon on plugin menus like everywhere else 2026-10-28 04:20:39 +01:00
Linus Rath 778d46fc3a fix: give the plugin permission and connect dialogs and the phone notification sheet the same title size as other dialogs 2026-10-28 04:13:19 +01:00
Linus Rath 1f1319d46e fix: hand the retired plugin's parts over one switch at a time and tell plugins about each switch 2026-10-28 03:54:47 +01:00
Linus Rath 04f45e0b29 fix: point the plugin sidebar section arrows the right way in right-to-left languages 2026-10-28 03:36:44 +01:00
Linus Rath ae412e0cda feat: show notifications, the command palette and the account avatar in every app's phone header 2026-10-28 03:05:41 +01:00
Linus Rath ab878ebf4f feat: tell plugins when Bulwark's own external mail warnings are on and skip the retired plugin's 2026-10-28 02:10:10 +01:00
Jacob Zeitz 4a130bc1f9 feat: let plugins show a count on their buttons
An action declared with ui.setActions may carry a badge, a whole number
from 0. On buttons it is drawn as the search's filter button draws its
count: the button tinted, the number in a bubble at its corner, "99+"
past two digits. In menus it follows the label, as the mobile header's
notification count does. 0 shows none.
2026-10-25 14:36:01 +01:00
Linus Rath 6be0f70452 perf: skip plugin round trips when a slot re-renders with the same props 2026-10-25 02:40:43 +02:00
Linus Rath 3b8dd4cd82 Merge pull request #1317 from LeonardNJU/feat/plugin-sidebar-heading-actions
feat(plugins): allow inline actions in collapsible sidebar headers
2026-10-24 17:54:53 +02:00
lsamc 51404ed015 feat(plugins): allow inline actions beside sidebar section headings 2026-10-21 21:20:29 -04:00
ghoztyandClaude Opus 5.5 30f51e5ca4 feat: name the app with the configured APP_NAME in user-facing strings
Some user-facing strings still said "Bulwark" on a deployment with its own
APP_NAME: Settings > General > Default apps (protocol handlers), the "Open
Bulwark" notification, the rate-limit banner and toast, the plugin connect
dialog, one plugin permission text and the connector page.

These strings now take an {appName} placeholder, filled by productName():
the configured APP_NAME, or "Bulwark" when it is unset or the default
"Webmail" (the same rule as the TOTP issuer and the About card, #1160).
A stock install reads as before.

The settings search (the settings page and api.app.searchSettings) indexes
these texts with the name filled in, so "bulwark" or the configured name
finds Default apps and no result carries the raw placeholder.

Locales: the 13 keys in every locale that has "Bulwark" in them. Languages
that inflect the name (cs, et, hu, ko, ro, sk, tr) use a neutral form such
as "{appName} uygulamasında" instead of a declined "Bulwark'ta"; a native
check of those is welcome.

Not changed on purpose: the mobile app, push relay, Lite, demo and admin
texts, which speak about Bulwark itself.

Closes #1314

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-22 04:14:54 +03:00
Linus Rath 95003fd28b feat: let a plugin panel start folded until the user or the plugin opens it 2026-10-20 17:21:13 +02:00
Linus Rath 95bfb1681c feat: let a plugin's panel frame fill the panel and scroll inside 2026-10-20 17:21:13 +02:00
Linus Rath 1e992e6c7f fix: check plugin dropdown messages before the host draws them 2026-10-18 14:39:59 +02:00
Tobias Genannt d6d3683b65 feat(plugins): add Combobox component to UI kit with host floating dropdown portal
- Add Combobox component supporting single and multiselect modes, search filtering, and clear button
- Implement floating dropdown bridge and host slot portal so dropdown renders cleanly outside plugin iframe
- Fix clear button and chip removals to not unexpectedly open the dropdown
- Add comprehensive unit tests covering Combobox options, clear behavior, multiselect, and bridge communication
2026-10-16 10:08:27 +02:00
Linus Rath db7a4408a1 fix: list plugin composer buttons under Options when the composer is too narrow for them 2026-10-14 14:59:29 +02:00
Linus Rath 9d7dc4fc4e fix: stop plugin frames from painting a white backdrop in dark themes 2026-10-14 14:02:40 +02:00
Linus Rath 9d8f762b1d feat: let a plugin title its sidebar section 2026-10-14 11:47:25 +02:00
Linus Rath 1bd4f743a1 feat: give plugins the app's own controls and draw their dialogs like the app's dialogs 2026-10-14 11:10:14 +02:00
Linus Rath c87ef9c44a fix: move plugin buttons in a narrow selection toolbar into a more menu so the toolbar no longer wraps 2026-10-14 09:28:56 +02:00
Linus Rath ae2130f5c8 feat: let a plugin ask a question on top of its own dialog 2026-10-14 06:47:53 +02:00
Linus Rath d841785cbd feat: let composer plugins read the selected text and write over it 2026-10-14 06:45:08 +02:00
Linus Rath 14c5b10c6a feat: tell a plugin page which of its pages is open 2026-10-14 05:30:34 +02:00
Linus Rath 7a6a0fc67f Merge branch 'slots/nav' into feat/plugin-system-audit
# Conflicts:
#	lib/__tests__/plugin-slot-catalog.test.ts
2026-10-14 05:30:34 +02:00
Linus Rath 425eae2227 Merge branch 'slots/mail' into feat/plugin-system-audit
# Conflicts:
#	lib/__tests__/plugin-slot-catalog.test.ts
2026-10-14 05:07:18 +02:00
Linus Rath b8b7a4ed15 feat: let plugins add pages of their own with an entry in the navigation 2026-10-14 04:57:00 +02:00
Linus Rath 37846bec44 feat: let plugins add collapsible sections to the mail sidebar 2026-10-14 04:45:24 +02:00
Linus Rath d144a6e85c feat: let plugins add sections to event details and the event form, and label calendar days 2026-10-14 04:43:40 +02:00
Linus Rath 8fbc8a1c1d feat: let plugins add frames above and in an empty message list and buttons to message rows and the selection toolbar 2026-10-14 04:43:22 +02:00
Linus Rath 5d9268c923 feat: let plugins add buttons, calendar day labels and pages, and use connected accounts from the sandbox 2026-10-14 04:31:43 +02:00
Linus Rath 60257bb732 feat: let users connect accounts for plugins in a dialog the plugin can't read, and disconnect them in settings 2026-10-14 04:14:13 +02:00
Linus Rath 2adb1e2b12 fix: size toolbar plugin slots to their content and give composer plugin buttons their own row 2026-10-14 02:53:46 +02:00
Linus Rath f048db7b52 fix: count each plugin hook failure once and keep a plugin that kept failing turned off 2026-10-14 02:33:45 +02:00
Linus Rath ff1d1f399d fix: limit plugin dialogs to one at a time, name the plugin in each and offer to turn it off 2026-10-14 02:15:45 +02:00
Linus Rath e720be7e17 feat: let users install their own plugins, with admin review of the actual code
The admin page offered "User Plugin Uploads" and "Require Admin
Approval", but nothing in Settings used them: there was no upload, no
uninstall and no way to ask for approval, and the admin had no list of
requests. The approval code that existed pinned a hash of the code only
and showed the admin a manifest the browser sent, never the code.

Now:
- Settings > Plugins has an install button (when uploads are allowed),
  a remove button for the user's own plugins, and lists in plain
  language what each plugin may do, high-risk items first
- an install sends the ZIP to the server, which reads the manifest and
  code itself and pins the request to a hash of both
- the admin Plugins tab lists requests with the code and approves or
  denies them; a user may have 10 open requests
- a user plugin is checked again on every start, so a revoked approval
  or turning user plugins off takes effect
- the consent dialog and the plugin settings are translated, use the
  theme colours, and show the sites a plugin may send data to
2026-10-14 02:03:26 +02:00
Linus Rath c45533646e fix: give slot plugins the message, event or contact only with the matching read permission 2026-10-14 01:31:30 +02:00
Linus Rath 4d733aa598 chore: remove unused exports and the dead plugin error boundary 2026-10-13 13:36:51 +02:00
Linus Rath 3c59e811a5 chore: remove unused files and dependencies 2026-09-22 19:36:33 +02:00
bartfaizoli76 2adc281a9d feat: add ui.openDialog + 'plugin-dialog' slot for large, clickable custom UI
Every existing plugin slot renders wherever it's placed in the page (a
toolbar row, an attachment's hover-action bar, etc.) and is constrained
by that spot's own CSS - fine for small controls, but there's no way
for a plugin to show a large custom UI (a graphical file browser, a
multi-step wizard) since even a position:fixed overlay rendered from
inside such a slot is clipped to the surrounding row's own layout, not
the real page (confirmed live building the webdav-storage plugin: a
folder browser rendered but was squeezed into an unusable sliver).

Adds:
- host-dialog.ts: new 'custom' DialogKind + awaitCustomDialog(), reusing
  the existing confirm/alert/prompt queue plumbing.
- host-api.ts: 'ui.openDialog' API method.
- runtime.tsx: sandbox-side api.ui.openDialog(opts) proxy.
- plugin-types.ts: new 'plugin-dialog' SlotName - a plugin implements
  this slot with its actual custom UI.
- plugin-dialog-host.tsx: renders the requested slot via the existing
  PluginIframeSlot INSIDE the dialog's real app-root fixed overlay
  (position: fixed; inset: 0, above everything) instead of the
  confirm/prompt form, for kind: 'custom'. Resolves via a generic
  onResult callback in extraProps (marshalled the same way
  composer-attachment-source's onAttach already is - no new plumbing
  needed there).

A plugin calls api.ui.openDialog({ slot: 'plugin-dialog', extraProps,
title, width }) and awaits the Promise, which resolves to whatever its
own slot component passes to props.onResult(), or null if the user
closes the dialog without doing so.
2026-09-05 18:57:49 +02:00
Linus Rath 9ab7339320 feat: add plugin ui.prompt dialog and first-class settings-section tabs 2026-07-09 14:51:17 +02:00
Linus Rath 512adab7e3 feat: add privileged same-origin plugin tier + crypto API surface 2026-06-28 16:51:42 +02:00
Linus Rath 6ee3849463 fix: theme plugin slot iframes with host font + color tokens 2026-05-31 16:28:22 +02:00