How klausschaefers/quant-ux works
1. This repository is the front end of Quant-UX, a Vue-based product for building prototypes, running usability tests, and analyzing interaction data. The backend is separate (qux-java), so this repo is mainly the presentation, client-side state, rendering, and API orchestration layer.
2. The main application entry is src/main.js, with routing in src/router.js and the top-level shell in src/App.vue. The app is organized into route-level views under src/views, which split the product into major experiences such as login/account, app list/overview, studio/editor, simulator/testing, help, and legal pages.
3. The largest subsystem is the studio/editor experience under src/canvas. This is where users design screens and widgets, edit properties, arrange layers, wire interactions, and configure collaboration, comments, imports/exports, and design tokens. The editor is built from many Vue components, but the real domain behavior is concentrated in the controller layer under src/canvas/controller.
4. src/canvas/controller is the model and command boundary for the editor. It contains the app model, selection, grouping, screen/widget logic, copy-paste, merge/import utilities, collaboration session handling, and command abstractions. This is the core “business logic” layer that sits between UI components and stored app models.
5. Rendering and interaction handling are separated from model logic. Canvas behavior is implemented by components like Canvas.vue, Render.vue, Zoom.vue, DnD.vue, Lines.vue, and supporting utilities such as grid/ruler/snapping helpers. This subsystem turns the controller/model state into editable visual layouts and handles pointer/keyboard interaction.
6. The product also includes a simulator/test runner stack under src/core/simulator and src/views/simulator. That subsystem executes the designed app as a prototype, wiring events, data binding, scripting, REST calls, scrolling, tooltips, audio, animations, and workflow logic into a runtime experience for test sessions.
7. Analytics is a separate end-user mode under src/canvas/analytic and src/views/apps/analytics. It processes recorded sessions and events into funnels, heatmaps, outlier detection, scatter plots, user journeys, and task-performance views. Supporting algorithms live in src/dash and are used to derive those insights from collected interaction data.
8. The app depends on a service layer in src/services that isolates all external communication. These services wrap backend APIs for models, comments, uploads, notifications, help content, Git/Figma/Sketch/Swagger imports, AI features, WebSocket collaboration, public sharing, and authentication. This is the main boundary between the Vue UI and the backend infrastructure.
9. Authentication and deployment concerns are built into the frontend. The README and service names indicate support for a custom auth flow plus Keycloak-based auth, with environment-driven configuration for backend proxying and websocket endpoints. The frontend itself is served by a small Node server in server/start.js / server/start_dev.js, which also acts as the proxy entrypoint in local or containerized deployments.
10. The data model is heavily theme- and template-driven. UI widgets and screens are defined through JSON theme files in src/themes, while reusable widget implementations live in src/core/widgets. This lets the editor generate and render many kinds of UI components, including forms, navigation, tables, charts, SVG, and mobile-style controls.
11. There is a clear separation between low-level rendering/model utilities and high-level product screens. src/core contains shared geometry, layout, responsive, SVG, text, animation, scripting, and model utilities; src/common, src/page, and src/plugins provide reusable UI primitives and page-level components used throughout the app.
12. The repository includes substantial support for import/export and reverse engineering of designs. Importers exist for HTML, YAML, SVG, Sketch, Figma, and Swagger-like data sources; exporters cover images, ZIP, Git, CSS, and comments. The tests and fixture data under src/unit/data and tests/unit/data show that these conversion paths are core architecture surfaces, not edge features.
13. Styling is a first-class layer, with extensive SCSS organization under src/style and multiple theme palettes for editor, simulator, widgets, and dialogs. The UI depends on those style bundles for the product’s different modes rather than using a single generic stylesheet.
14. The repository’s quality and release flow are centered on Node tooling: Vue build scripts, Jest unit tests, ESLint, Docker packaging, and GitHub Actions for image builds. The architecture diagram should therefore show a client-heavy SPA frontend, a thin Node delivery/proxy layer, and external backend services for persistence, auth, mail, collaboration, and websocket sync.
Main entry points: canvas Canvas UI · apps App workspace · services Services · unit Tests
Components 23
Entry & routes
SPA bootstrap and top-level navigation
- main · Bootstraps the frontend application
src/main.js - router · Defines application navigation and page boundaries
src/router.js - App shell · Top-level application container and layout chrome
src/App.vue - Views · Login, app overview, studio, simulator, help, and legal pages
src/views - Login/account · User authentication and account flows
src/views/user - App workspace · App list, overview, design, share, and settings surfaces
src/views/apps
Studio editor
Design, editing, and canvas interactions
- Studio · Main design and editing experience
src/views/apps/Studio.vue - Canvas UI · Visual editor surface and interaction layer
src/canvas - Controller · App model, selection, commands, grouping, import/export, and collaboration logic
src/canvas/controller - Toolbar · Editing controls, properties, dialogs, and mode-specific panels
src/canvas/toolbar - Render & input · Canvas drawing, zooming, drag/drop, selection, rulers, and pointer handling
src/canvas/Render.vue - Share mode · Shared model presentation and share controller
src/canvas/share
Runtime & analytics
Prototype execution and insight modes
- Simulator · Executes designed apps as testable prototypes
src/views/simulator - Runtime core · Event, script, REST, animation, scroll, tooltip, and workflow execution
src/core/simulator - Analytics · Session analysis, funnels, heatmaps, journeys, and outlier views
src/views/apps/analytics - Dash algorithms · Clustering, density, outlier detection, and dimensionality reduction
src/dash
Shared platform
Common core, widgets, services, and UI primitives
- Services · Backend API, auth, collaboration, import/export, uploads, and notifications
src/services - Core libs · Geometry, layout, rendering, scripting, responsive, and utility primitives
src/core - Widgets · Reusable UI widgets and theme-driven building blocks
src/core/widgets - Themes · Widget and screen templates plus visual palettes
src/themes - Styles · Mode-specific style bundles for editor, simulator, widgets, and dialogs
src/style
Delivery & tooling
Node delivery, build, and test surfaces
- Node server · Local/container entrypoint and frontend delivery proxy
server/start.js - Tests · Unit tests and fixture data for core editor, runtime, and import paths
tests/unit
Connections 27
- main → router: configures · Application bootstraps routing
- main → App shell: mounts · Root Vue shell is mounted by the entrypoint
- router → Views: routes to · Route table points at page-level views
- Views → Login/account: includes · Auth and account pages
- Views → App workspace: includes · Product workspace pages
- App workspace → Studio: opens · Studio is the central workspace mode
- App workspace → Analytics: opens · Analytics is a workspace mode
- App workspace → Simulator: opens · Simulator is a workspace mode
- Studio → Canvas UI: composes · Studio is built around the canvas subsystem
- Canvas UI → Controller: drives · UI delegates model logic to the controller boundary
- Canvas UI → Render & input: renders · Canvas view layer turns model state into editable layouts
- Canvas UI → Toolbar: configures · Toolbar and dialogs expose editing operations
- Canvas UI → Share mode: shares · Shared model presentation uses a dedicated mode
- Controller → Services: calls · Editor logic persists and syncs via services
- Render & input → Core libs: uses · Canvas interaction builds on shared geometry and layout utilities
- Render & input → Styles: skins · Rendering depends on editor-specific styles
- Toolbar → Widgets: uses · Properties and widgets are built from reusable component primitives
- Toolbar → Themes: loads · Theme templates drive widget and screen generation
- Simulator → Runtime core: executes · Simulator page relies on runtime execution engine
- Runtime core → Services: fetches · Runtime interacts with backend APIs and data sources
- Analytics → Dash algorithms: derives from · Insight views are powered by analysis algorithms
- Analytics → Services: reads · Analytics mode loads session and event data
- Node server → main: serves · Node server delivers the SPA and proxy entrypoints
- Services → Node server: proxies via · Frontend service layer targets the delivery/proxy boundary
- Tests → Controller: verifies · Tests cover the editor model and command logic
- Tests → Runtime core: verifies · Tests cover simulator and runtime behavior
- Tests → Dash algorithms: verifies · Tests cover analytics algorithms