Skip to content

Conditional questions: linear scale and color as trigger - #3837

Open
AndyScherzinger wants to merge 1 commit into
feat/conditional-questions-4-filefrom
feat/conditional-questions-5-scale-color
Open

AndyScherzinger wants to merge 1 commit into
feat/conditional-questions-4-filefrom
feat/conditional-questions-5-scale-color

Conversation

@AndyScherzinger

@AndyScherzinger AndyScherzinger commented Nov 4, 2026 •

Copy link
Copy Markdown
Member

Part 5 of the conditional questions stack from #3123 (by Micke Nordin, with fixes by TimedIn and the review fixes). Based on #3836; the "Files changed" tab shows only this part.

Stack

  1. Conditional questions: base implementation plus support for radio and dropdown triggers #3833 Conditional questions: radio and dropdown triggers
  2. Conditional questions: checkboxes as trigger #3834 Conditional questions: checkboxes as trigger
  3. Conditional questions: date and time as trigger #3835 Conditional questions: date and time as trigger
  4. Conditional questions: file upload as trigger #3836 Conditional questions: file upload as trigger
  5. Conditional questions: linear scale and color as trigger #3837 Conditional questions: linear scale and color as trigger ← this PR
  6. Conditional questions: short and long text as trigger #3838 Conditional questions: short and long text as trigger

This PR

A linear scale trigger shows a branch when its value equals, does not equal, lies within a range, or is above a minimum or below a maximum. A color trigger shows a branch when the color matches, ignoring case.

  • condition matching on the server and in the browser;
  • condition editor for both, with labelled fields; the color button names the selected color for screen readers;
  • docs and tests.

Tests

  • Unit tests: 614, all passing except the 15 IUserFolder errors main has as well.
  • php-cs-fixer, eslint and the build are clean.

🤖 AI (if applicable)

  • The content of this PR was partly or fully generated using AI

@codecov

codecov Bot commented Nov 4, 2026 •

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 36.66667% with 19 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
lib/Service/SubmissionService.php 36.66% 19 Missing ⚠️

📢 Thoughts on this report? Let us know!

@AndyScherzinger
AndyScherzinger force-pushed the feat/conditional-questions-5-scale-color branch from 624a98f to 5734f04 Compare November 4, 2026 14:07
@AndyScherzinger
AndyScherzinger force-pushed the feat/conditional-questions-4-file branch 2 times, most recently from 21c5283 to fe30885 Compare November 4, 2026 14:20
@AndyScherzinger
AndyScherzinger force-pushed the feat/conditional-questions-5-scale-color branch from 5734f04 to 6e7c64d Compare November 4, 2026 14:20
@timedin-de

Copy link
Copy Markdown

Sorry i didnt have the time to check it currently. But my two cents regarding trigger. For my use case we would need the linear scale as a number input for higher/lower than, which is not possible using choice/options (and is not ideal using number input), for a "How many people do you want to signup" (with Name etc per Person).

Thats why i would seperate it from color, as i See no real usecase for color trigger (except some specific quizzes or sth, and then its also possible to use the choice or Text input)

@Chartman123

Copy link
Copy Markdown
Collaborator

@timedin-de did you already have a look at this feature request? #1728

For me, it sounds a bit more like this is what you would like to achieve?

A linear scale trigger activates a branch when its value equals, does
not equal, lies within a range, or is above a minimum or below a
maximum. A color trigger activates a branch when the color matches,
ignoring case. The color button names the selected color for screen
readers.

The code comes from the original pull request #3123 by Micke Nordin
and TimedIn, with the review fixes applied.

Assisted-by: Claude Code:claude-opus-5-5
Signed-off-by: Andy Scherzinger <info@andy-scherzinger.de>
@AndyScherzinger
AndyScherzinger force-pushed the feat/conditional-questions-4-file branch from fe30885 to f1898c5 Compare November 4, 2026 16:51
@AndyScherzinger
AndyScherzinger force-pushed the feat/conditional-questions-5-scale-color branch from 6e7c64d to 7124f48 Compare November 4, 2026 16:51
@timedin-de

Copy link
Copy Markdown

@timedin-de did you already have a look at this feature request? #1728

For me, it sounds a bit more like this is what you would like to achieve?

Yes a proper implementation would probably be better, but as you already posted there, its a rather complicated edge case probably not beeing implemented in near future.

My case was just this workaround (similar to our current Google forms, [in Gforms we use a nested checkbox "you want to signup more people?]), was:

"How many attendants" (1-5)
Name 1
Adress 1
if attendants > 1:
Name 2
Adress 2
if attendants > 2:
....

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

Labels

3. to review Waiting for reviews enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants