RetroCSS — About

Win9x styling for the modern web

The look of 1995 with the ergonomics of today: themeable tokens, a dark mode that actually reads, keyboard-operable components and WCAG AA contrast throughout. Every component is demonstrated on this page.

npm install @phantompixeldev/retrocss
6.0.4 Version
22 KB CSS, gzipped
8 KB JS, gzipped
Zero Dependencies
AA WCAG, both themes
RTL Supported

Theme matrix · RTL example · Dashboard

Navigation

Navigation .retro-nav

Vertical Navigation .retro-nav-vertical

Pills Navigation .retro-nav-pills

Tabbed Navigation .retro-nav-tabbed

Home Tab

Welcome to RetroCSS! This is the home tab content.

Profile Tab

This is your profile information.

Messages Tab

You have 3 unread messages.

  • Message from Admin
  • Welcome to RetroCSS
  • Your account was created

Settings Tab

Configure your application settings.

Underlined Navigation .retro-nav-underlined

Dashboard Overview

Users
1,254
Sessions
5,678
Uptime
99.9%

Analytics Data

Performance metrics and analytics information would display here.

Traffic: 75%
Conversion: 42%

Reports

Generated reports would be listed here.

  • Monthly Performance Report
  • User Activity Summary
  • Resource Usage Statistics
  • Error Logs

User Management

Username Role Status Actions
admin Administrator Active
user1 User Inactive

Button Group Navigation .retro-nav-buttons

Daily View

Showing activities for today, June 15, 2023.

  • 9:00 AM - Team Meeting
  • 11:30 AM - Client Call
  • 1:00 PM - Lunch Break
  • 2:30 PM - Project Review
  • 4:00 PM - Development Time

Weekly View

Showing schedule for the week of June 12-18, 2023.

Day Events
Monday Sprint Planning
Tuesday Development
Wednesday Mid-week Review
Thursday Development
Friday Sprint Review

Monthly View

Calendar for June 2023

Sun
Mon
Tue
Wed
Thu
Fri
Sat
28
29
30
31
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
1

Yearly View

Overview of 2023

Q1
Jan - Mar
Q2
Apr - Jun
Q3
Jul - Sep
Q4
Oct - Dec

Combined with Other Styles

Layout

Utilities utilities

Atomic helpers on the same tokens as the components. retro-bg-<hue> sets the fill and its on-fill text colour, so a filled panel reads correctly in both themes from one class.

Backgrounds

primary
success
danger
warning
info
teal
pink
lime

Subtle tints

primary-subtle
success-subtle
danger-subtle
warning-subtle
info-subtle
teal-subtle
pink-subtle
lime-subtle

Text colours

primary success danger warning info teal pink lime muted

Spacing & flex

retro-flex retro-gap-2 retro-flex-wrap retro-items-center retro-mt-4 retro-px-5 retro-mx-auto

Margins and padding run 0–8 on a 0/4/8/12/16/24/32/40/48px scale.

Effects

retro-raised
retro-sunken
retro-shadow-md
retro-shadow-lg

Grid System .retro-grid

Basic Grid

Grid Item 1
Grid Item 2
Grid Item 3

Responsive Grid

Responsive Item 1
Responsive Item 2
Responsive Item 3
Responsive Item 4

Container Queries .retro-cq-*

Container Query Grid

Grid Item 1
Grid Item 2
Grid Item 3
Grid Item 4
Grid Item 5
Grid Item 6

Content

Typography .retro-h1 … .retro-h6

Heading 1 (h1)

Heading 2 (h2)

Heading 3 (h3)

Heading 4 (h4)

Heading 5 (h5)
Heading 6 (h6)

Heading Variants

⭐ PRIMARY HEADING
βœ”οΈ SUCCESS HEADING
⚠️ WARNING HEADING
❌ DANGER HEADING
ℹ️ INFO HEADING
πŸ’§ TEAL HEADING
🌸 PINK HEADING
πŸ‹ LIME HEADING

Text Utilities

Primary | Success | Danger | Warning | Info | Teal | Pink | Lime

Bold | Italic | Underline | Shadow | Outline | UPPERCASE | lowercase | capitalize each word | Monospace | Extra Small | Large | Strike


Fancy Text Styles

Rainbow Text | Gradient Text | Outline Strong | Emboss | Deboss | Multicolor Shadow | Glitch | Metallic | Fire


Retro Blockquote

"This is a retro blockquote. The only limit to our realization of tomorrow will be our doubts of today."

Retro Code Block

          
function helloWorld() {
  // This is a comment
  const message = "Hello, Win9x!";
  let count = 42;
  
  if (count > 0) {
    console.log(message);
  }
  
  return count + 1;
}

class Example {
  constructor() {
    this.name = "Example";
  }
  
  sayHello() {
    return `Hello from ${this.name}!`;
  }
}
          
        

HTML Example

          
<div class="retro-container">
  <h1 class="retro-heading-primary">Hello World</h1>
  <p class="retro-text-primary">
    This is a paragraph with primary text color.
  </p>
</div>
          
        

Retro Listbox

  • Listbox Item 1
  • Listbox Item 2
  • Listbox Item 3
  • Listbox Item 4

Inline code: npm install retrocss

Deleted text Inserted text sub sup

Badges .retro-badge

Badge Variants

Default Primary Success Danger Warning Info Secondary

Badge Sizes

XS SM MD LG XL XXL
New Hot Sale Featured Premium Special

Special Badge Themes

Neon Style

Neon Cyan Green Red

Pixel Style

Pixel 8-Bit Game

Badge Usage Examples

Notifications
Messages 42
Updates 7
Tasks 13
Product Tags
v1.0 New In Stock Limited Sale Featured Exclusive

Cards .retro-card

Card Title 🏷️

This is a simple card. You can put any content here.

Card with Footer βž•

This card has a footer for extra actions or status.

Lists .retro-list

Unordered List

  • First item
  • Second item
  • Third item
    • Nested item 1
    • Nested item 2

Ordered List

  1. First item
  2. Second item
  3. Third item
    1. Nested item 1
    2. Nested item 2

Description List

Term 1
Description for term 1
Term 2
Description for term 2

List Variants

  • Bordered list item
  • Another bordered item
  • Striped list item
  • Another striped item
  • One more striped item
  • Hoverable list item
  • Another hoverable item

Dividers .retro-divider

Basic Dividers

Style Variants

Colored Dividers

Text Divider

OR
Continue with

Vertical Divider

Left Content
Right Content

Tables .retro-table

Name Email Address with a very long header to test truncation Status Role Joined Date Last Login Timestamp Notes and Comments about the user that could be very long Actions
Alice Wonderland alice.wonderland.in.a.very.long.email.address@example.com Active Administrator Extraordinaire 2022-01-15 2023-10-26 10:00 AM This user is a very important administrator with many responsibilities and access to all system features.
Bob The Builder bob.the.builder.constructs.long.emails@example.com Inactive User Account 2022-03-22 2023-01-15 08:30 PM Bob was a user but his account is now inactive. He liked to build things.
Charlie Chaplin charlie.chaplin.the.comedian.with.a.long.name@example.com Pending Approval Process Editor in Chief 2022-05-10 2023-10-25 12:00 PM Charlie is pending account approval. He has a great sense of humor and is expected to write amazing articles.
Dana Scully dana.scully.federal.agent.xfiles.division@example.com Active Special Investigator User 2022-07-08 2023-10-26 09:00 AM Dana investigates paranormal activities and writes detailed reports. Trust no one. The truth is out there. This is a very long note to test how the cell handles overflow and truncation.
Product Name with an exceedingly long title to ensure truncation works Price (USD) Stock Availability (Units) Category Type Average Customer Rating (out of 5) Supplier Information Details and Contacts Actions
Retro Encabulator Mark II - Now with more sinusoidal depleneration! $10.99 1500+ Advanced Fictional Accessories 4.5 Stars Sourced from Galactic HyperMart, contact: sales@ghypermart.nebula
Turbo-Charged Keyboard Wiffer Duster - Keeps crumbs out of your retro keyboard $20.50 0 (Out of Stock) Essential Cleaning Accessories 4.2 Stars DustBusters Inc., contact: orders@dustbusters.local
PixelPerfect CRT Monitor Enhancer - For the truest retro display experience ever $120.00 75 High-End Display Peripherals 4.8 Stars Retro Displays Ltd., contact: support@retrodisplays.co.uk
Analog Dial-Up Modem Simulator - Experience the sweet sounds of 56k again and again $35.75 15 (Low Stock) Nostalgic Computer Accessories 3.9 Stars DialTones Corp., contact: info@dialtonescorp.vintage
Click a column heading to sort. Headings are focusable, so Enter and Space work too.
Item ID Description of Item which can be quite lengthy for testing purposes Quantity Unit Price Total Price Warehouse Location and Bin Number Last Restock Date Status Notes
SKU-001-XYZ-LONG A very fine item with an exceptionally long description that will most certainly need to be truncated. This description goes on and on to fill up space. 120 $5.25 $630.00 Warehouse A, Section 3, Bin 105-C, Shelf 2, Position Left 2023-09-01 On Order
SKU-002-ABC-SHORT Another item, this one has a slightly shorter but still quite verbose description for testing. 75 $12.99 $974.25 Warehouse B, Section 1, Bin 201-A, Shelf 1, Position Right 2023-10-15 In Stock
SKU-003-DEF-NORMAL A standard item. 200 $2.50 $500.00 Warehouse A, Section 2, Bin 050-B, Shelf 3, Position Center 2023-08-20 In Stock
SKU-004-GHI-VERYLONGNAMEINITSELF This item's name is already very long, and its description continues to elaborate on its many features, characteristics, and benefits to the end-user, making it an ideal candidate for truncation. 30 $25.00 $750.00 Warehouse C, Section 4, Bin 312-D, Shelf 4, Position Front 2023-10-01 Low Stock
Project Name - This header is designed to be very very long Lead Developer Name and Contact Email Status Due Date Completion (%) Budget Allocated (USD) Resources Assigned and their roles in this project Client Notes and Feedback Snippets
Project Phoenix: Next Generation OS Development and Deployment Dr. Elara Vance (elara.vance.long.email.address@devteam.example.com) In Progress 2024-06-30 65% $2,500,000 Team Alpha (Core Dev), Team Beta (QA), Team Gamma (UI/UX), John Doe (PM) - This cell is intentionally very long to test wrapping and truncation behavior. Client is very happy with progress but requests more frequent updates. Also, please ensure the login screen has a retro animation. This is an extremely long piece of text for testing.
Operation Hydra: Secure Data Storage Initiative for Retro Systems Mr. Ben Carter (ben.carter.security.specialist@secure.example.org) Delayed 2023-12-15 30% $1,200,000 Security Team (Implementation), Audit Team (Compliance), Jane Smith (Consultant) Concerns about encryption strength. Budget overruns are becoming a significant issue for this project.
RetroWave UI Kit: Crafting the Ultimate Nostalgic User Interface Ms. Anya Sharma (anya.sharma.design.lead@uistudio.example.net) Completed 2023-09-01 100% $750,000 Designers (UI/UX), Frontend Devs (Implementation) Exceeded expectations! The client loves the pixel-perfect icons and the authentic 9x feel. Ready for market.
Code Cleanup Initiative: Refactoring Legacy Codebase for Project Chimera The Entire Team of Very Dedicated and Hardworking Developers Ongoing 2024-03-01 15% $500,000 Senior Developers (Refactoring), Junior Developers (Testing and Documentation) - This field contains a lot of text. This is a critical internal project to improve maintainability and performance of a core system component. Morale is high.

Forms

Forms .retro-input

Checkboxes & Radio Buttons

Inline Checkbox & Radio Groups

Toggle Switches

Other Form Controls

File Upload .retro-file-upload

No file chosen
Drag & Drop file here

Tag/Chip Input .retro-tag-input

Example Γ—

Rating Stars .retro-rating

β˜… β˜… β˜… β˜… β˜…

Date / Time Picker .retro-datetime

Actions

Buttons .retro-btn

Button Variants

Button Sizes

Colored Button Sizes

Dropdown Menu .retro-dropdown

Feedback

Alerts .retro-alert

This is a retro alert! Something happened.
This is a primary alert!
This is a success alert!
This is a danger alert!
This is a warning alert!
This is an info alert!
Primary Alert
This alert has a header, body, and a close button.
Success!
Your operation was successful.

Toasts RetroToast.show()

Modals .retro-modal

Modals are used to display content in a layer above the app. They are useful for confirmations, forms, or important messages.

The original demoModal is still available as well:

Progress / Loading Bars .retro-progress

35%
Loading…
Complete!

Tooltips data-retro-tooltip

Position Variants

Style Variants

Component Variants modifiers

Size and layout modifiers that ship with the components above. These were in the stylesheet for several releases without appearing on any page, so nobody could find them.

Button and input sizes

Form layouts

Progress variants

Card variants

Compact card
.retro-card-compact tightens the content padding.
Card with image
.retro-card-image is a full-bleed band above the content.

Avatars and loaders

RC RC Loading

Modal sizes

Add .retro-modal-lg, .retro-modal-xl or .retro-modal-scroll to .retro-modal-content.

Large modal

.retro-modal-lg widens the dialog; .retro-modal-xl widens it further and .retro-modal-scroll caps the body height.

Tooltip positions and variants

Position with data-tooltip-position and colour with data-tooltip-variant β€” neither was documented.

Toast variants

Disclosure

Accordion .retro-accordion

Welcome to RetroCSS

RetroCSS is a CSS framework that brings back the nostalgic look and feel of Win9x era interfaces.

To get started, include the following in your HTML:

<link rel="stylesheet" href="dist/retro.min.css">
<script src="dist/retro.min.js"></script>

Installation Options

Via NPM

npm install retrocss

Via CDN

<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@phantompixeldev/retrocss/dist/retro.min.css">
<script src="https://cdn.jsdelivr.net/npm/@phantompixeldev/retrocss/dist/retro.min.js"></script>

Customizing RetroCSS

You can customize RetroCSS by overriding CSS variables:

:root {
  --retro-primary: #0000aa;
  --retro-bg: #c0c0c0;
  --retro-border-dark: #404040;
  --retro-border-medium: #808080;
  --retro-border-light: #ffffff;
  --retro-font: 'MS Sans Serif', Arial, sans-serif;
}

Frequently Asked Questions

Is RetroCSS responsive?

Yes, RetroCSS is built with modern responsive design in mind while maintaining the nostalgic Win9x aesthetic.

Does RetroCSS support dark mode?

Yes, RetroCSS includes a dark mode theme that can be toggled using the built-in theme switcher.

Can I use RetroCSS with modern frameworks?

Absolutely! RetroCSS works with React, Vue, Angular, and other modern frameworks.

Pagination .retro-pagination

Breadcrumbs .retro-breadcrumbs

Infinite Scroll .retro-infinite-scroll

Retro Modal

This is a modal dialog.

Basic Modal Title

This is a basic modal dialog. It's great for short messages or simple confirmations.

Modal with Long Content

This modal contains a lot of text to demonstrate how scrolling might work if the content exceeds the modal's height. In classic interfaces, modals often grew to fit content, or content within them would scroll if the modal itself had fixed dimensions.

Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.

Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium doloremque laudantium, totam rem aperiam, eaque ipsa quae ab illo inventore veritatis et quasi architecto beatae vitae dicta sunt explicabo. Nemo enim ipsam voluptatem quia voluptas sit aspernatur aut odit aut fugit, sed quia consequuntur magni dolores eos qui ratione voluptatem sequi nesciunt.

Neque porro quisquam est, qui dolorem ipsum quia dolor sit amet, consectetur, adipisci velit, sed quia non numquam eius modi tempora incidunt ut labore et dolore magnam aliquam quaerat voluptatem. Ut enim ad minima veniam, quis nostrum exercitationem ullam corporis suscipit laboriosam, nisi ut aliquid ex ea commodi consequatur? Quis autem vel eum iure reprehenderit qui in ea voluptate velit esse quam nihil molestiae consequatur, vel illum qui dolorem eum fugiat quo voluptas nulla pariatur?

At vero eos et accusamus et iusto odio dignissimos ducimus qui blanditiis praesentium voluptatum deleniti atque corrupti quos dolores et quas molestias excepturi sint occaecati cupiditate non provident, similique sunt in culpa qui officia deserunt mollitia animi, id est laborum et dolorum fuga. Et harum quidem rerum facilis est et expedita distinctio. Nam libero tempore, cum soluta nobis est eligendi optio cumque nihil impedit quo minus id quod maxime placeat facere possimus, omnis voluptas assumenda est, omnis dolor repellendus.

Login Form Modal

This modal has no explicit header. The close button is part of the body content here, or could be omitted for modals that require explicit action in the footer.

Content directly in the body.

Informational Modal

This modal has a header and body, but no footer. Useful for displaying information that doesn't require explicit actions beyond closing the modal itself (via the 'Γ—' button).

Ensure the close button in the header is sufficient for user interaction.