Skip to content

fix(html5): keep media-sharing and confirmation buttons at a consistent size - #25942

Merged
lfzawacki merged 6 commits into
bigbluebutton:v4.0.x-developfrom
germanocaumo:u40d/fix/button-sizing
Oct 13, 2026
Merged

lfzawacki merged 6 commits into
bigbluebutton:v4.0.x-developfrom
germanocaumo:u40d/fix/button-sizing

Conversation

@germanocaumo

@germanocaumo germanocaumo commented Oct 2, 2026 •

Copy link
Copy Markdown
Contributor

What does this PR do?

Depends on #25989, which bumps bbb-ui-components-react to 0.9.0. Its commit is the first one listed here until it merges.

Fixes button sizing and focus in the media-area sharing popover and in the confirmation modals.

BBButton sizes itself to its label. The migration to it dropped the full width and padding the old styled buttons carried. Since then the media-sharing buttons change width with the language and the label, and short confirmation buttons ("Pin", "No") render as squares.

The buttons are sized with BBButton's own fullWidth prop, or styled directly with styled(BBButton). Both are new in 0.9.0. No wrapper reaches into the button's markup anymore.

In detail:

  • fix(media-sharing): keep the presenter and share buttons at one size
    • The take/request presenter button and the Share/Stop sharing footers span the popover and the modal.
    • All three states of the presenter-request popover (take, request, waiting) render at the same sm height.
    • Long translations wrap instead of overflowing.
  • fix(modal): hold a minimum width on confirmation buttons
    • Each footer button in ConfirmationModal and in the recording consent modal gets an 8.5rem minimum width.
    • On phones the footer wraps: the pair stacks with each button filling the line, and a label wider than the dialog breaks onto two lines.
  • fix(media-sharing): give every non-presenter the same popover width
    • The popover was narrowed to 250px for moderators only. That condition dates from before viewers got the request presenter view.
    • Every non-presenter now gets the 26.25rem popover. At 250px the waiting label and longer translations wrapped onto two lines.
  • fix(modal): focus the cancel button when a confirmation modal opens
    • ConfirmationModal tried to focus Cancel in componentDidUpdate, before react-modal had mounted the content, so focus never reached it. It now focuses Cancel from onAfterOpen.
    • For modals opened from a menu (end meeting, remove user), BBBMenu's delayed restore then pulled focus back to the menu trigger, behind the modal. It now only restores focus if nothing has claimed it since the menu closed.
  • refactor(buttons): size BBButtons with fullWidth and className
    • The commits above first sized the buttons through wrapper divs, because 0.7.0 had no width option and didn't pass className through. This commit switches them to the 0.9.0 props, as asked in review.
    • The presenter and share buttons use fullWidth.
    • The confirmation and recording-consent footers use a styled(BBButton) with the minimum width, so the MinWidthButtonWrapper added earlier is gone.
    • BBButton doesn't forward refs, so the confirmation modal finds its Cancel button by id instead of through a wrapper.

Presenter-request popover

Presenter-request popover, before and after

Sharing footers (Slides, Play video from link, Share camera as content, Stop sharing)

Sharing footers, before and after

Colors are unchanged. The "before" Stop Sharing is darker only because it was hovered in that capture.

Confirmation modal

Pin message confirmation, before and after

The same footer is used by every ConfirmationModal: pin/unpin/delete message, end meeting, remove user, clear annotations, and others. In "after", Cancel shows its focus ring because it now receives focus when the modal opens.

The screenshots were taken before the switch to fullWidth/styled(BBButton). The refactor renders the same sizes; it was re-measured live.

How to test

  1. Join as a moderator who is not the presenter and open the media-area button.
    • The Take presenter button spans the popover in en, pt-BR and lv.
  2. Join as a viewer with the default presenter policy.
    • Request presenter spans the popover.
    • After clicking it, the waiting state keeps the same size.
  3. As presenter, open Slides, Play video from link and Share camera as content.
    • Share spans the modal.
    • While something is shared, Stop Sharing spans the main view.
  4. Pin a chat message.
    • Pin and Cancel have the same width.
    • Cancel is focused, so Enter cancels.
  5. Open End meeting from the leave menu, and Remove user from the user list.
    • Cancel is focused. Before this change, focus went back to the menu trigger behind the modal.
  6. Phone (e.g. Pixel 5 emulation): open End meeting.
    • The buttons stack and both fill the dialog width.
    • Long translations (hu, el, ru) stay inside the dialog.
  7. Regression: close the leave menu with Escape, and pick a user-menu item that opens no dialog (Promote).
    • Focus returns where it did before.

How it was verified

  • Original fixes: all of the above, on a 4.0 dev server in Chromium, including emulated Safari and RTL for the focus cases.

  • Refactor: re-checked live in Chromium, with the 4.0 client running against a 4.1 backend:

    • the popover states (en, lv, viewer, waiting);
    • the three share footers and Stop sharing;
    • End meeting on desktop, and on a phone in ru;
    • the Pin dialog;
    • Cancel focus in each dialog.

    The sizes match the screenshots. The recording consent modal wasn't re-checked live; it uses the same styled(BBButton) as the confirmation footer.

  • Static checks: eslint is clean on the changed files, tsc is clean at every commit, and the production webpack build passes.

More

@coderabbitai

coderabbitai Bot commented Oct 2, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration
  • Configuration used: Repository UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 102f1478-bb94-4725-a3af-42280c9e35ab
📥 Commits

Reviewing files that changed from the base of the PR and between ccc9cf2 and 3251130.

⛔ Files ignored due to path filters (1)
  • bigbluebutton-html5/package-lock.json is excluded by !**/package-lock.json
📒 Files selected for processing (11)
  • bigbluebutton-html5/imports/ui/components/actions-bar/media-area/media-sharing/camera-as-content/component.tsx
  • bigbluebutton-html5/imports/ui/components/actions-bar/media-area/media-sharing/component.tsx
  • bigbluebutton-html5/imports/ui/components/actions-bar/media-area/media-sharing/external-video/component.tsx
  • bigbluebutton-html5/imports/ui/components/actions-bar/media-area/media-sharing/presentation/component.jsx
  • bigbluebutton-html5/imports/ui/components/actions-bar/media-area/media-sharing/styles.ts
  • bigbluebutton-html5/imports/ui/components/common/modal/confirmation/component.jsx
  • bigbluebutton-html5/imports/ui/components/common/modal/confirmation/styles.js
  • bigbluebutton-html5/imports/ui/components/nav-bar/nav-bar-graphql/recording-indicator/notify/component.tsx
  • bigbluebutton-html5/imports/ui/components/poll/component.tsx
  • bigbluebutton-html5/imports/ui/components/poll/components/ResponseArea.tsx
  • bigbluebutton-html5/package.json
🚧 Files skipped from review as they are similar to previous changes (1)
  • bigbluebutton-html5/imports/ui/components/actions-bar/media-area/media-sharing/styles.ts

Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 7 remain after this review.


Walkthrough

The changes update button layouts and styles in media-sharing and confirmation interfaces. Menu focus restoration now depends on the focus state after closing, and the confirmation modal focuses its cancel button after opening. Poll toggle test attributes move to slotProps.input. The UI component and MUI dependency ranges are raised.

Priority: ➖ Normal

Estimated code review effort: 3 (Moderate) | ~20 minutes

Change: Bug fix

Suggested reviewers: guiibecker

Merge Risk: ⚪ Minimal · up to 32511

No identified issue blocks merging after normal checks.

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 1…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Title check ✅ Passed The title clearly and concisely describes the primary button-sizing changes in the media-sharing and confirmation interfaces.
Description check ✅ Passed The description is directly related to the changeset and explains the button sizing, focus behavior, responsive layout, testing, and dependency context.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create a new PR
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Autopilot is currently an internal CodeRabbit preview.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@antobinary antobinary added this to the Release 4.0 milestone Oct 2, 2026
@guiiBecker

Copy link
Copy Markdown
Contributor

Looks good to me

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟢 Approval recommended

The sizing and focus changes are internally consistent and no blocking correctness issues were identified.

Review effort: Balanced
Findings: None

What changed in this PR

Standardizes media-sharing and confirmation button sizing while correcting modal focus behavior.

Changes:

  • Adds reusable full/minimum-width button wrappers with responsive wrapping.
  • Standardizes media-sharing popover widths and button dimensions.
  • Focuses confirmation cancellation safely without menu focus restoration overriding it.
File Description
button-wrapper/​styles.ts Adds the shared minimum-width wrapper.
modal/​confirmation/​styles.js Adds responsive footer sizing.
modal/​confirmation/​component.jsx Wraps buttons and focuses Cancel after opening.
menu/​component.jsx Avoids overriding newly claimed focus.
media-sharing/​styles.ts Standardizes popover and button dimensions.
media-sharing/​component.tsx Applies consistent small button sizing.
recording-indicator/​notify/​styles.ts Reuses confirmation footer wrappers.
recording-indicator/​notify/​component.tsx Wraps consent footer buttons.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@Tainan404

Copy link
Copy Markdown
Member

honestly, isn't simpler make BBButton accept a min-width or a style/sytled-component/css prop? the idea of have a component library is remove some core complexity having some reusable components, but this component doesn't look reusable at all, there's thousands of wrappers around it to make it works, looks like a issue on componet or a issue of integration

0.9.0 adds BBButton's fullWidth prop and className forwarding, and keeps
a disabled button's 1px border so enabling it no longer shifts layout.

It raises the @mui/material and @mui/icons-material peer floor to 6.4.9,
since BBBToggle now passes its accessibility props through
slotProps.input, which Switch only forwards from that release on. Bump
both to 6.5.0, the latest 6.x.

BBBToggle also dropped inputProps, so the poll toggles' data-test hooks
move to slotProps.input. Without this, the E2E selectors for the
anonymous poll and custom input toggles would no longer match.
The BBButton migration dropped the full width the old ConfirmationButton
carried, since BBButton sizes itself to its label. The take/request
presenter button and the Share/Stop sharing footers changed width with
the language and the label, and the popover's three states rendered at
three heights (37, 51 and 45px).

Span the popover and the modal with the shared full-width wrapper, give
the take/request presenter states the same `sm` size and match the
waiting state's box to it. Let long translations wrap instead of
overflowing the popover.
BBButton sizes itself to its label, so after the migration a short one
("Pin", "No") rendered as a square next to a wider Cancel in every
confirmation modal and in the recording consent modal.

Wrap each footer button in a shared 8.5rem floor and let both the footer
and the label wrap. On a phone a long label next to the floor stacks the
pair, each button filling its line, and a label wider than the dialog
breaks onto two lines instead of overflowing it.
The popover is narrowed to 250px for moderators only, a condition left
over from when only moderators saw it. Viewers got the 26.25rem popover
when they gained the request presenter view, so the same popover has
two widths. At 250px the waiting state and longer translations (lv)
also wrap onto two lines, changing the button height between states.

Drop the reduced width so every non-presenter gets the 26.25rem one.
ConfirmationModal moved focus to its cancel button in componentDidUpdate,
but react-modal mounts the dialog content after the component renders,
so the button did not exist yet and nothing re-rendered the component
afterwards: focus never reached it. Focus it from react-modal's
onAfterOpen instead.

Modals opened from a menu item (end meeting, remove user) still lost it:
BBBMenu restores focus to its trigger from a timeout after closing,
which landed behind the open modal. Only restore it if nothing has
claimed focus since the menu closed.
bbb-ui-components-react 0.9.0 adds a fullWidth prop to BBButton and
forwards className, so the buttons this branch resized no longer need a
wrapper reaching into their markup.

- The take/request presenter and share/stop sharing buttons use
  fullWidth. The presenter button is a styled(BBButton) that also lets a
  long translation wrap.
- The confirmation and recording consent footers style BBButton itself
  for the minimum width, so MinWidthButtonWrapper goes away.
- The confirmation modal finds its cancel button by id: BBButton does
  not forward refs, and the wrapper that held the ref is gone.
@github-actions

github-actions Bot commented Oct 7, 2026

Copy link
Copy Markdown

✅ Automated tests have passed!

@lfzawacki
lfzawacki merged commit 2bfd8d9 into bigbluebutton:v4.0.x-develop Oct 13, 2026
34 of 35 checks passed
antobinary added a commit that referenced this pull request Oct 28, 2026
* docs: doc sync for 4.0 since 4.0.0-rc.5

Range v4.0.0-rc.5..v4.0.x-develop 0f90159 (52 commits). No changes to
bigbluebutton.properties, settings.yml, akka-apps application.conf,
ApiParams, the create/join tables, resources.xml or bbb-conf. The Grails 8
upgrade (#25466) brought its own docs; its "Upgraded components" list was
checked against the Spring Boot 4.1.1 and Grails 8.0.0 BOMs and the build
files (Spring Framework 7.0.9, Groovy 5.1.3, Tomcat 11.0.26, Gradle 9.8.0).

administration/customize.md, "Configuration of gladia.io":
- #26010 moved bbb-transcription-controller from v0.2.10 to v0.4.0, which
  talks to Gladia's v2 live API and reads the key from gladia.key
  (gladia-proxy.js); nothing reads x_gladia_key in gladia.startMessage any
  more, so the documented command left the server without a key. Set
  gladia.key instead, and drop the "3.0 or higher, use >0.3.x" paragraph
  and its startMessage (bit_depth and endpointing are now gladia.bitDepth
  and gladia.endpointing). Mention the translation options.
- Warn that the package's after-install.sh copies default.example.yml
  over default.yml on every install and upgrade, and every BigBlueButton
  upgrade reinstalls the package (its version comes from
  bigbluebutton-release). That removes the key and the ESL password
  bbb-conf --setip writes, and the service then crash-loops with "FSESL
  connection authentication error".
- Say up front which service applies: 4.0 defaults to the LiveKit audio
  bridge, where bbb-livekit-stt (not packaged; uv or Docker) does the
  work; bbb-transcription-controller forks audio from FreeSWITCH and only
  covers audioBridge=bbb-webrtc-sfu. The client settings (audioCaptions
  enabled, provider gladia) apply to both: bbb-livekit-stt starts on the
  speech-locale event that carries the provider.

new-features.md:
- "bbb-transcription-controller 0.4.0 (Gladia v2)" under Other notable
  changes, as the upgrade note for the above (rc.1 to rc.5 shipped
  v0.2.10).
- "Learning Dashboard: polls and quizzes numbered in the order they were
  asked" (#25988): untitled polls are numbered chronologically, the
  header tooltip shows when they were asked, and the Download Session
  Data CSV uses the same order.

Not documented: the UI fixes (#25942, #25993, #25974), the recording
panzoom fix (#25991), the bbb-ui-components-react and MUI bumps, the
pres-checker build cleanup, the Tomcat parameter limit and upload limits
(moved to Spring Boot keys in bbb-web's application.properties with the
same values), and the Jackson string limit (raised and dropped again).

(cherry picked from commit bcaed58)

* docs: iteration doc sync for 4.0.1

Documents the v4.0.0..v4.0.x-develop (cd89568) delta that the per-PR
docs commits in the range did not cover.

new-features.md
- Usability: "Live captions transcribed on the user's device" for
  public.app.audioCaptions.speechProcessing (#26179)
- Dedicated Audio settings tab: the processing pick is now scoped to the
  browser session and the meeting, public.app.audioFilterStorage (#25744)
- Behind the scenes: fewer video-grid re-renders (#26096), lock settings
  changes without reconnecting viewers (#26004), client modals on
  BBBModal (#25829), bbb-web Grails 2 cleanup (#26002)
- Media: "Last-N audio for the LiveKit bridge (experimental)" (#26211)
- Other notable changes: component versions in 4.0.1 (LiveKit stack
  #25912, bbb-webrtc-recorder 0.18.0, bbb-webrtc-sfu 2.25.0-beta.3,
  bbb-playback 5.4.8, Tomcat 11.0.27 #26241, Gradle 9.8.1 #26259,
  FreeSWITCH rtp-port-usage-robustness, livekit-sip rtp_port default),
  minimum Safari 14.1 (WeakRef, #25912), password-protected Redis for
  bbb-graphql-actions (#26110)
- Upgraded components list: Gradle 9.8.1, Tomcat 11.0.27
- Recent releases: 4.0.1 (the tag does not exist yet)
- Client settings / Added: speechProcessing, audioFilterStorage,
  public.chat.announceUserAwayStatusInChat (#26090),
  public.media.livekit.selectiveSubscription.lastN; the existing
  paginationToggleModeratorOnly bullet is tagged 4.0.1

customize.md
- speechProcessing was added in 4.0.1, not 4.0
- Advanced Filtering: paragraph on audioFilterStorage
- Audio: new section "Play only the most relevant microphones (Last-N)"

api.md
- New "Updated in 4.0.1" block. The userdata-bbb_parent_room_moderator
  removal (#26087) moves there from the 4.0 block: it landed after v4.0.0.

Left out on purpose: fixes (#26269, #26250, #26118, #26085, #26212 and
the rest), the presenter authorization change (#25887), test/CI work and
dependency bumps belong in the release notes, not in the docs. akka-apps
application.conf, ApiParams.java and LockSettingsParams.java did not
change in the range.

* docs: keep the 4.0.1 join note in the 4.0 block, drop four sections

api.md
- userdata-bbb_parent_room_moderator stays in the 4.0 "Removed
  parameters" line, marked "removed in 4.0.1", instead of a separate
  "Updated in 4.0.1" block.

new-features.md
- Drop the 4.0.1 "Behind the scenes" subsections (video-grid
  re-renders, lock settings without reconnects, BBBModal, bbb-web
  cleanup): release-notes material, not documentation.
- Drop "Learning Dashboard: polls and quizzes numbered in the order
  they were asked", carried over from the rc.5 sync.

* docs: drop the "Other notable changes" entries added for 4.0.1

new-features.md
- Drop "Component versions in 4.0.1", "Minimum Safari version is 14.1",
  "Password-protected Redis for bbb-graphql-actions" and the
  "bbb-transcription-controller 0.4.0 (Gladia v2)" note carried over
  from the rc.5 sync. The Safari floor and the Redis password are
  already documented on their own pages; the version bumps belong in
  the release notes.

* docs: drop the customize.md changes from the 4.0.1 sync

customize.md
- Back to its v4.0.x-develop content: no Last-N section, no
  audioFilterStorage paragraph, speechProcessing stays "added in 4.0",
  and the Gladia v2 edits from the rc.5 sync cherry-pick are gone too.

new-features.md
- The Last-N section no longer links to the dropped customize.md
  section; the client-settings bullet still links to it.
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.

6 participants