Skip to content

Property Editors: Hide "add button" when maximum configuration is 1 (fixes #20407)#20738

Merged
leekelleher merged 3 commits intomainfrom
hide-add-btn-when-max-one
Nov 5, 2025
Merged

Property Editors: Hide "add button" when maximum configuration is 1 (fixes #20407)#20738
leekelleher merged 3 commits intomainfrom
hide-add-btn-when-max-one

Conversation

@NguyenThuyLan
Copy link
Contributor

@NguyenThuyLan NguyenThuyLan commented Nov 5, 2025

Prerequisites

Fixes #20407.

Description

  • When the maximum is set to 1 item and contains one item, then hide the add button.
  • When the maximum is set to >= 2 items, keep displaying the button despite the number of items reaching the limit.

The following Property Editors should be handled:

  • Block Grid
  • Block List
  • Content Picker (also known as Multi Node Tree Picker)
  • Media Picker
  • Multi URL Picker
  • Multiple Text String

@leekelleher leekelleher self-requested a review November 5, 2025 09:59
@leekelleher leekelleher changed the title Media Picker, Multi Text String, Multi URL, Content Picker, Block List, Block Grid: Hide add button when max 1 Property Editors: Hide "add button" when maximum configuration is 1 (fixes #20407) Nov 5, 2025
Copy link
Member

@leekelleher leekelleher left a comment

Choose a reason for hiding this comment

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

Tested out, works as described. Good work! 🙌

@leekelleher leekelleher merged commit 72d7ed4 into main Nov 5, 2025
27 of 28 checks passed
@leekelleher leekelleher deleted the hide-add-btn-when-max-one branch November 5, 2025 12:12
@bjarnef
Copy link
Contributor

bjarnef commented Dec 4, 2025

@leekelleher @iOvergaard can this be included in v16.5.0 as well? :)

iOvergaard pushed a commit that referenced this pull request Dec 4, 2025
…ixes #20407) (#20738)

Hide add button when max 1

Co-authored-by: Lan Nguyen Thuy <[email protected]>
@iOvergaard
Copy link
Contributor

Picked for 16.5 with f7ba2ea - thanks, @bjarnef !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Media Picker Configured to Pick one AND ONLY one Image and not a pixel more gives you a UI to allow you to pick billions

5 participants