Skip to content

yachi666/support-roster-ui

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

132 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸ“± Support Roster UI

δΈ­ζ–‡ Β· Parent workspace

Vue 3 Vite Tailwind CSS Node.js License

A modern Vue 3 frontend for the support roster platform, delivering public on-call visibility, authenticated workspace management, and operational tools through a polished single-page application.

Support Roster UI is the user-facing web interface for managing and viewing on-call schedules. It provides a public roster viewer, an admin workspace for planning and operations, contact information pages, product release notes, and protected toolsβ€”all built with Vue 3, Vite, and Tailwind CSS.

This repository is designed to work as a Git submodule within support-platform, where backend services, automated tests, development scripts, and curated screenshots are centrally coordinated.


✨ Highlights

  • 🎯 Vue 3 Composition API with <script setup> and reusable feature structure
  • ⚑ Lightning-fast development powered by Vite 7 with HMR
  • 🎨 Modern styling using Tailwind CSS 4 with custom design tokens
  • πŸ›£οΈ Smart routing via Vue Router 5 with role-based access guards
  • πŸ”’ Access control enforcing workspace policies on protected pages
  • πŸ“¦ Modular architecture with feature-based organization
  • 🌐 Internationalization support via Vue I18n
  • 🐳 Production-ready with Docker + Nginx deployment path
  • πŸ“š Comprehensive specs maintained in .specs/ for all features

πŸ–ΌοΈ Screenshots

Public Viewer Workspace Overview
Public roster viewer Workspace overview
Monthly Roster Planner Validation Center
Monthly roster planner Workspace validation center

πŸ—ΊοΈ Product Surfaces & Routes

Surface Route Access Purpose
Public Viewer /viewer Public Read-only on-call timeline with date picker, timezone selector, and responsive layout
Login /login Public Staff ID authentication and account activation flow
Admin Workspace /workspace/* Authenticated + Policy Complete roster management: overview, monthly planning, staff, shifts, teams, validation, import/export, accounts
Contact Hub /contact-information Public + Protected Public viewing and admin management of contact details
Host Hub /linux-passwords Protected Operational password vault gated by workspace access policy
Product Updates /product-updates Public User-facing release notes tracking visible product changes

Note: Navigating to /workspace redirects users to the appropriate workspace entry page based on their authenticated permissions and workspace policy.


πŸ› οΈ Tech Stack

Category Technology
Framework Vue 3.5 (Composition API)
Build Tool Vite 7
Router Vue Router 5
State Management Vue reactivity + Pinia stores
Styling Tailwind CSS 4
UI Components Radix Vue (headless primitives)
Icons Lucide Vue Next
Utilities clsx, tailwind-merge, class-variance-authority
Date Handling date-fns, date-fns-tz
i18n Vue I18n
Runtime Node.js ^20.19.0 || >=22.12.0

πŸš€ Quick Start

Prerequisites

  • Node.js ^20.19.0 || >=22.12.0
  • npm (comes with Node.js)
  • Backend API running at http://127.0.0.1:8080/api (see Backend Dependency)

Installation

# Clone the repository (if standalone) or init submodules (if from parent workspace)
git submodule update --init --recursive

# Navigate to the UI directory
cd support-roster-ui

# Install dependencies
npm install

Development

# Start the Vite dev server (default port: 5173)
npm run dev

The app will be available at http://localhost:5173 with hot module replacement enabled.

Default API Configuration:

VITE_API_BASE_URL=http://127.0.0.1:8080/api

You can override this in .env.development.local (not tracked by Git).

Build & Preview

# Build for production
npm run build

# Preview the production build locally
npm run preview

The build output will be in the dist/ directory.


πŸ“œ Available Scripts

Command Description
npm run dev Start Vite development server with HMR
npm run build Build production-ready static bundle to dist/
npm run preview Preview production build locally
npm run format Format src/ with Prettier

πŸ”§ Environment Variables

Variable Purpose Default (Dev) Example (Prod)
VITE_API_BASE_URL Backend API base URL http://127.0.0.1:8080/api https://supportui.servier/api
VITE_XMATTERS_URL External Systems drawer link for xMatters https://www.xmatters.com/
VITE_SERVICENOW_URL External Systems drawer link for ServiceNow https://www.servicenow.com/
VITE_MESSAGE_DELIVERY_KB_URL Message Delivery Knowledge Base link https://learn.microsoft.com/

Configuration Files:

  • .env.development – Development defaults
  • .env.production – Production defaults
  • .env.development.local / .env.production.local – Local overrides (not committed)

See Vite's environment variables documentation for more details.


πŸ—οΈ Architecture

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                   Browser                       β”‚
β”‚                                                 β”‚
β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚
β”‚  β”‚           Vue 3 SPA (Vite)                β”‚ β”‚
β”‚  β”‚                                           β”‚ β”‚
β”‚  β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ β”‚
β”‚  β”‚  β”‚  /viewer       # Public roster view β”‚ β”‚ β”‚
β”‚  β”‚  β”‚  /login        # Auth & activation  β”‚ β”‚ β”‚
β”‚  β”‚  β”‚  /workspace/*  # Admin workspace    β”‚ β”‚ β”‚
β”‚  β”‚  β”‚  /contact-information/* # Contact flows β”‚ β”‚ β”‚
β”‚  β”‚  β”‚  /linux-passwords       # Protected vaultβ”‚ β”‚ β”‚
β”‚  β”‚  β”‚  /product-updates       # Release notes  β”‚ β”‚ β”‚
β”‚  β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ β”‚
β”‚  β”‚                                           β”‚ β”‚
β”‚  β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β” β”‚ β”‚
β”‚  β”‚  β”‚      src/api/ (API Client Layer)    β”‚ β”‚ β”‚
β”‚  β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚ β”‚
β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β”‚
β”‚                       β”‚                         β”‚
β”‚                       β–Ό                         β”‚
β”‚              HTTP Requests                      β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                        β”‚
                        β–Ό
        β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
        β”‚   support-roster-server       β”‚
        β”‚   (PostgreSQL backend)        β”‚
        β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

Key Concepts:

  • Single-page application with client-side routing
  • API layer (src/api/) abstracts backend communication
  • Route guards enforce authentication and workspace policies
  • Feature modules encapsulate domain logic (workspace, contact-info, etc.)
  • Pinia stores manage cross-component state when reactivity isn't enough

πŸ“‚ Project Structure

support-roster-ui/
β”œβ”€β”€ .specs/                          # πŸ“š Frontend specifications
β”‚   β”œβ”€β”€ spec.md                      # Main spec navigation
β”‚   β”œβ”€β”€ architecture.md              # Architecture decisions
β”‚   β”œβ”€β”€ development.md               # Local dev workflow
β”‚   β”œβ”€β”€ deployment.md                # Deployment guides
β”‚   β”œβ”€β”€ ui-design.md                 # Design system & patterns
β”‚   β”œβ”€β”€ product-updates.md           # Product update log rules
β”‚   β”œβ”€β”€ modules/                     # Module-specific specs
β”‚   └── workspace/                   # Workspace feature specs
β”‚       └── index.md
β”œβ”€β”€ build/                           # 🐳 Deployment configs
β”‚   β”œβ”€β”€ build-frontend.sh
β”‚   β”œβ”€β”€ push-to-ecr.example.sh
β”‚   └── ecs-task-definition.example.json
β”œβ”€β”€ public/                          # Static assets (served as-is)
β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ api/                         # πŸ”Œ Backend API wrappers
β”‚   β”œβ”€β”€ assets/                      # 🎨 Global styles, images
β”‚   β”œβ”€β”€ components/                  # 🧩 Shared UI components
β”‚   β”œβ”€β”€ data/                        # Static data (teams, etc.)
β”‚   β”œβ”€β”€ features/                    # 🎯 Feature modules
β”‚   β”‚   β”œβ”€β”€ contact-information/
β”‚   β”‚   β”œβ”€β”€ linux-passwords/
β”‚   β”‚   β”œβ”€β”€ product-updates/
β”‚   β”‚   └── workspace/               # Admin workspace feature
β”‚   β”œβ”€β”€ i18n/                        # 🌐 Internationalization
β”‚   β”‚   └── locales/
β”‚   β”œβ”€β”€ lib/                         # πŸ› οΈ Utility functions
β”‚   β”œβ”€β”€ pages/                       # πŸ“„ Top-level route pages
β”‚   β”œβ”€β”€ router/                      # πŸ›£οΈ Route config & guards
β”‚   β”œβ”€β”€ stores/                      # πŸ“¦ Pinia state stores
β”‚   β”œβ”€β”€ App.vue                      # Root component
β”‚   └── main.js                      # App entry point
β”œβ”€β”€ Dockerfile                       # Production container
β”œβ”€β”€ nginx.container.conf             # Nginx config for SPA routing
β”œβ”€β”€ package.json
β”œβ”€β”€ vite.config.js
└── tailwind.config.js

πŸ”— Backend Dependency

The UI communicates with support-roster-server, which must expose:

API Scope Base Path Purpose
Public Data /api/** Viewer roster data, public contacts
Workspace Admin /api/workspace/** CRUD for staff, shifts, teams, rosters, validation
Authentication /api/auth/** Login, logout, account activation

Local Development Setup

  1. Start PostgreSQL (required by backend)
  2. Start backend server (support-roster-server on port 8080)
  3. Start frontend dev server (npm run dev in this directory)

Convenience script (from parent workspace):

../scripts/dev/restart-all.sh

This script handles restarting both backend and frontend services together.

For detailed backend setup, see the support-roster-server repository README.


🐳 Deployment

Supported Deployment Paths

  1. Linux + Nginx (static hosting)

    • Build with npm run build
    • Serve dist/ with Nginx
    • Configure reverse proxy to backend API
  2. Docker + Nginx (containerized)

    • Build Docker image: docker build -t support-ui .
    • Run with environment variables for VITE_API_BASE_URL
    • Suitable for AWS ECR/ECS Fargate or any container orchestrator

Deployment Resources

Production Environment Variables:

See .env.production for default production config. Override as needed in your deployment environment.


πŸ“š Documentation & Specs

All frontend technical specifications live in the .specs/ directory:

Document Description
.specs/spec.md πŸ—‚οΈ Main spec navigation hub
.specs/architecture.md πŸ›οΈ Architecture decisions & patterns
.specs/development.md πŸ’» Local dev workflow, health checks, restarts
.specs/deployment.md πŸš€ Deployment guides (Nginx, Docker, AWS)
.specs/ui-design.md 🎨 Design system, colors, typography, components
.specs/product-updates.md πŸ“ Product update log maintenance rules
.specs/workspace/index.md 🏒 Workspace feature navigation
.specs/modules/ πŸ“¦ Individual module specs

When to update specs:

  • Adding or changing routes, pages, components
  • Modifying state management, API integration, or data models
  • Changing visual rules, interaction patterns, or development workflow
  • Adding or removing features

🀝 Contributing

We welcome contributions! Please follow these guidelines:

Spec Maintenance

Critical: Specs are not optional. They are part of the implementation.

  • βœ… Always update .specs/ docs when changing routes, pages, components, state, APIs, or workflows
  • βœ… Update navigation files (.specs/spec.md or relevant index.md) when adding new spec documents
  • βœ… Keep specs synced with code in the same commit/PR
  • ❌ Don't create scattered spec files outside .specs/

Product Update Log

  • βœ… Maintain src/features/product-updates/data/productUpdates.js for user-visible changes
  • βœ… Update both zh-CN and en entries (bilingual requirement)
  • βœ… Write for users, not developers (focus on value, not implementation)
  • ⚠️ Skip for internal refactors (note "no user-visible changes" in PR description)

Code Quality

  • Follow Vue 3 Composition API best practices
  • Use <script setup> for new components
  • Maintain consistent code style (use npm run format)
  • Write meaningful commit messages

For detailed agent instructions, see AGENTS.md.


πŸ“„ License

This project is licensed under the MIT License. See LICENSE for details.


Made with ❀️ using Vue 3, Vite, and Tailwind CSS

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages