Interactive Quiz SPA Full Feature Specification

Interactive Quiz SPA Full Feature Specification

Builds a complete single-page browser quiz app in vanilla JS with multiple question types, timers, scoring, leaderboard, review mode and accessibility notes.

Interactive Quiz SPA — Full Feature Specification

Role

You are a front-end engineer who ships small, polished single-page apps. You write HTML5 / CSS3 / vanilla JS (no framework unless requested), think in user states, and make UX decisions visible in the code.

Objective

Produce a single-page quiz application that feels considered — smooth transitions, multiple question types, adaptive scoring, persistent leaderboard, and a reflective review mode.

Inputs

  • question_bank (JSON) or a sample the user provides
  • categories: array of category names with icons
  • difficulty_levels: e.g., easy / medium / hard with time and score multipliers
  • brand_palette (optional): 3 hex colors + font pairing

Output

Deliver in this order:

  1. Architecture sketch — component map and state machine (idle → playing → review → results).
  2. Data schema — questions, categories, attempts, leaderboard shape.
  3. HTML structure — semantic skeleton.
  4. CSS approach — variables for brand tokens, transition curves, reduced-motion fallback.
  5. JS modules — timer, scorer, question renderer, persistence (localStorage), share-card generator.
  6. Feature implementations:
    • Question types: multiple choice, true/false, matching, short answer with fuzzy grading.
    • Per-question timer with a visible arc countdown.
    • Score = base points × difficulty × speed-bonus factor.
    • Progress bar with category icon row.
    • Review mode showing correct/incorrect with explanations.
    • Leaderboard keyed by category + difficulty.
    • Results analytics: accuracy per category, average response time, suggested focus area.
    • Share card: canvas-drawn PNG with customizable message.
  7. Accessibility checklist — keyboard nav, aria-live for timer, focus management between questions.
  8. Test plan — 8 edge cases worth asserting.

Constraints

  • No runtime dependencies unless explicitly approved.
  • Do not over-animate — two signature transitions, not twenty.
  • All state must survive refresh for in-progress attempts.
  • Avoid AI-aesthetic UI (floating purple gradients, generic glassmorphism). Commit to a real palette.

© Shen Huang · MIT · source · posted by @OpenSourceBuffGuy on promptparty.com

@OpenSourceBuffGuy

I find openly licensed prompts and post them here.

0 followers · 6,373 prompts

More by @OpenSourceBuffGuy

See all
Website Clone Architect prompt image

Website Clone Architect

Reverse-engineers a website section by section, writes component specs, and hands them to parallel builder agents in git worktrees to rebuild it.

agent-skill, orchestrator, parallel-agents, multi-agent, plan-then-execute, web-development, frontend, codebase-analysis, scaffolding, css, html, nextjs, typescript, git, mcp, claude-code, for-developers, for-designers, long-form, advanced, technical-spec, task-decomposition, structured-output, design-systems, ui-ux, tool-use, checklist, report, vibe-coding

Italian Terrace Cafe Candid Portrait prompt image

Italian Terrace Cafe Candid Portrait

Generates a photorealistic candid shot of a woman in a white corset dress laughing at a sunny hotel terrace cafe, written as detailed JSON.

image-prompt, json-prompt, structured-output, photorealistic, portrait, woman, candid, fashion, cottagecore, natural-light, golden-hour, bokeh, summer, travel, cityscape, mountains, medium-shot, vibrant-colors, for-photographers, nano-banana, fashion-shoot, luxury

Night Street Photo With Leashed Cat prompt image

Night Street Photo With Leashed Cat

Generates a flash-lit night street photo of a blonde woman in a retro track jacket walking a hissing tabby cat on a leash.

image-prompt, json-prompt, nano-banana, structured-output, portrait, woman, animals, pet-portrait, night-scene, street-photography, candid, editorial, fashion, dramatic-lighting, photorealistic, vertical-format, medium-shot, graffiti, for-photographers, for-content-creators

1 view

Reviews

Loading reviews…

Discussion

Loading comments…