Survey Progress Bar & Programmable Indicators
Configure linear, hierarchical, or sandboxed custom arithmetic progress indicators with minimal visual footprint and monotonic non-decrement protection.
Executive Overview & Business Value#
In quantitative market research and complex B2B surveys, participant drop-off directly tracks respondent cognitive load and perceived completion ambiguity. Progress bars that unexpectedly decrement following skip-logic branches or multi-dimensional batteries induce frustration and abandonment.
The [PROGRESS_BAR] directive provides a declarative, deterministic, and isomorphic standard unified across all three surfaces of the Daesen platform:
- 1DOCX Ingestion Engine: Parses and extracts progress configuration directly from Word documents.
- 2Survey Studio: Provides visual controls, Survey Studio syntax highlighting, diagnostic squiggles, and interactive simulation.
- 3Testing Sandbox & Production Runner: Ensures identical, deterministic execution with an ultra-slim footprint and assistive technology support.
Canonical Directive Syntax#
The directive is declared globally in the survey header or within the survey body:
[PROGRESS_BAR: mode="expression-weighted", visibility="floating-bottom", minStep=0, maxStep=100, formula="($survey.answered / $survey.total) * 100"]Configuration Parameters:#
| Parameter | Type | Allowed Values | Default Value | Description |
|---|---|---|---|---|
mode | string | "linear-steps", "page-tree", "expression-weighted" | "linear-steps" | Progression algorithm used to calculate completion percentage. |
visibility | string | "top", "floating-bottom", "none" (aliases: position, bottom, floating, off, disabled) | "top" | Viewport positioning of the indicator. When set to "none", it is completely omitted. |
formula | string | Arithmetic expression (alias: expression) | Optional | Mathematical formula evaluated when in expression-weighted mode. |
minStep | number | Number between 0 and 100 (alias: min) | 0 | Guaranteed lower bound of the progress bar. |
maxStep | number | Number between 0 and 100 (alias: max) | 100 | Guaranteed upper bound of the progress bar. |
showSteps | boolean | true, false (alias: steps) | true | Displays or hides the sequential step counter label (e.g. Step 3 of 10). |
showPercentage | boolean | true, false (alias: percentage) | false | Displays or hides the numerical percentage badge (e.g. 45%). |
To suppress the indicator directly, write [PROGRESS_BAR: none], off, false, or disabled.
Calculation Modes#
1. Linear Steps (mode="linear-steps")#
Calculates progress based on the linear index of the active question relative to total active questions:
Progress = (Current Index / Total Active Questions) × 100
Best suited for sequential surveys without complex branching graphs.
2. Page Tree Graph (mode="page-tree")#
Evaluates progress across hierarchical section depths and module weights. If sections are bypassed via [SKIP TO], the graph recalculates the critical path forward without penalizing the respondent.
3. Expression Weighted (mode="expression-weighted")#
Allows authors to define custom arithmetic formulas parsed and evaluated by a safe, sandboxed recursive-descent engine (zero-eval, completely immune to code injection).
Safe Context Variables:#
$survey.answered: Count of answered required questions.$survey.total: Total count of active, visible questions in the respondent's current path.$survey.answeredRequired/$survey.totalRequired: Required-question counters along the active path.$survey.answeredCount/$survey.totalQuestions: Total questions answered out of all study questions (ideal for multi-question screens).$survey.totalVisibleRequired: Total visible required questions based on condition visibility.$survey.currentIndex: 0-based index of current question.$survey.currentStep: 1-based step counter (e.g. Step 3).
Monotonic Progression Protection#
A frequent issue in legacy survey engines occurs when skip-logic jumps over multiple questions, causing the progress percentage to recalculate downwards. This creates respondent frustration and perceived survey lengthening.
Daesen enforces Strict Monotonic Progression:
Progress(t) = max(Progress(t-1), Progress(t))
The displayed progress value will never decrease during an active respondent session, even during dynamic graph re-evaluations.
Universal Accessibility (WCAG 2.1 AA)#
The NeuProgressBar atom satisfies international accessibility guidelines:
- Semantic role
role="progressbar". - Dynamic ARIA metadata:
aria-valuenow,aria-valuemin="0",aria-valuemax="100", andaria-label="Survey completion progress". - High-contrast ratio exceeding 4.5:1 across light and dark modes.
- Respects
prefers-reduced-motionsystem preferences by disabling CSS width transition animations.
Behavior with Paged Blocks ([PAGE] & [FLOW: PAGED_BLOCKS])#
When you group multiple related questions onto one shared screen using [FLOW: PAGED_BLOCKS] with [PAGE] ... [END PAGE] (or [PAGE_BREAK]), progress feedback adapts automatically to keep respondents oriented:
- 1Page Block Header (
Page X of Y): In grouped Paged Blocks layout, each screen renders a consolidated card displayingPage X of Yand active questions on that screen, uniting Back / Next navigation in one clean footer. - 2Monotonic Multi-Question Evaluation: Across screens, the underlying progress engine still filters active, visible, non-bypassed questions and enforces monotonic forward progression so percentage never steps backwards when conditional branches skip blocks.
- 3Practical Recommendation for Researchers: Pair
[FLOW: PAGED_BLOCKS]withmode="expression-weighted"andformula="($survey.answeredCount / $survey.totalQuestions) * 100"(ormode="page-tree") so multi-question screens translate cleanly into overall completion tracking. In 1-per-screen (wizard) mode, the ultra-slim bar renders directly above or floating below each card; in grouped (Paged Blocks) mode, the screen prioritizes the clean Page X of Y page counter.
formsDSL Code Examples#
Example A: Floating-Bottom Weighted Indicator with [PAGE] Blocks#
[PROGRESS_BAR: mode="expression-weighted", visibility="floating-bottom", minStep=0, maxStep=100, showSteps=true, showPercentage=true, formula="($survey.answeredCount / $survey.totalQuestions) * 100"]
[FLOW: PAGED_BLOCKS]
[SCREENER]
[PAGE]
S1. What is your primary organizational role?
[SINGLE CHOICE]
1. Chief Technology Officer / CIO
2. IT Director
3. Software Engineer
4. Non-IT Professional [CLOSE]
S2. Which cloud infrastructure providers do you actively utilize?
[MULTIPLE CHOICE]
1. Amazon Web Services (AWS)
2. Microsoft Azure
3. Google Cloud Platform (GCP)
99. None of the above [EXCLUSIVE, FIX]
[END PAGE]Example B: Page Tree Mode with [PAGE_BREAK]#
[PROGRESS_BAR: mode="page-tree", visibility="top", showSteps=true, showPercentage=false]
[FLOW: PAGED_BLOCKS]
Q1. How often does your team review vendor renewals?
[SINGLE CHOICE]
1. Quarterly
2. Annually
3. Every 2+ years
[PAGE_BREAK]
Q2. What is your top operational priority for the next 12 months?
[OPEN ENDED]Example C: Explicit Indicator Suppression#
[PROGRESS_BAR: none]Was this article helpful?
Your feedback helps us continuously improve our technical guides.