Skip to content
tanaydinPublic

About

The 1965 Commodore logo rebuilt in pure CSS from its construction card, with an editor to restyle and export it (PNG, WebP, JPEG, SVG, CSS, HTML).

Topics

Resources

Stars

10 stars

Watchers

0 watching

Forks

Repository files navigation

Commodore logo in CSS

The Commodore logo built from the ratios on a reference card (c64.jpg), drawn with CSS only, plus an editor to zoom, restyle and export it.

Live: reference card · editor

The logo editor

Open index.html or editor.html in a browser. There is nothing to install or build, and no dependencies.

To run it from a local server instead (some browsers limit clipboard access on file:// pages):

python3 -m http.server 8000
# then open http://localhost:8000

Publish on GitHub Pages

The site is static files at the repository root. In the repository's Settings → Pages, choose Deploy from a branch, pick main and / (root), and the reference card will be served as the home page.

Files

File What it is
commodore.css The logo: one element, no images, SVG or JavaScript
index.html The reference card redrawn in CSS, with colour variants and sizes
editor.html, editor.css, editor.js The editor
favicon.svg Site icon
c64.jpg The reference card
preview.png Screenshot used in this README

Use the logo

<link rel="stylesheet" href="commodore.css">
<span class="cbm cbm--classic" style="--A: 20rem" role="img" aria-label="Commodore"></span>
Setting Effect
--A Width. Everything scales from it. Default 10rem
color Logo colour when no fill is set
--fill Any CSS gradient, painted across the whole logo
--flag-fill A separate gradient for the flags
--B to --J, --hole-x Proportions

Variants: cbm--classic, cbm--rainbow, cbm--crt, cbm--chrome, cbm--outline.

A solid colour is written as a gradient: --fill: linear-gradient(red 0 0).

Ratios

Every length is a multiple of A, the logo's width.

Key Ratio What it sets
A 1 Total width
B 0.034 Gap between the flags
C 0.166 Height of one flag
D 0.30 Space above and below the flags
E 0.364 Flag width
F 0.52 Hole height
G 0.53 Hole width
H 0.636 Where the C is cut
I 0.97 Height, and diameter of the C
J 90° Angle of the flag notch

Where the card is unclear:

  • The full-width dimension is printed as "10"; it measures as A.
  • 2D + 2C + B is 0.966, not 0.97. The flags are centred in I, so D is about 0.302.
  • The notch is drawn at about 93°. The printed 90° is used.
  • The hole's centre is not given. It was measured at 0.495 × A.

Editor

Zoom: scroll, pinch, use the slider, or use the keys below. Drag to pan and double-click to fit.

Key Action
+ - Zoom in, zoom out
0 Fit to view
1 100%
Arrow keys Pan (with the preview focused)
Ctrl+Z, Ctrl+Shift+Z (or Ctrl+Y) Undo, redo

The same list is in the editor under Keyboard and mouse.

Edit:

  • 12 presets; the one in use is highlighted
  • Solid, gradient or striped fills, with 2 to 8 colours for gradients and stripes
  • Background colour or transparency
  • Outline, extrude, shadow, glow and scanlines
  • Rotate, slant and mirror
  • Spin, pulse and colour-cycle motion
  • The card's proportions

Work is saved in the browser. Copy link puts the whole design in a URL. Presets can be linked directly, for example editor.html#preset=neon.

Export:

Format Notes
PNG, WebP, JPEG 16 to 8192 px wide. JPEG has no transparency
SVG Outline and extrusion are vector paths; shadow and glow are SVG filters
CSS The HTML to pair it with is in the first line
HTML A complete page

Motion is kept in CSS and HTML only, and is off for people who prefer reduced motion.

Limits

  • Outline and extrusion in exported CSS use chains of drop-shadow, which browsers snap to whole pixels. Outlines can be up to about a pixel heavier than in SVG, and sharp tips slightly stepped. Use SVG or PNG when that matters.
  • Those chains add up to three wrapper elements and are slow to repaint at large sizes. The editor previews them as SVG instead.
  • Saving as WebP falls back to PNG in browsers that cannot encode it.
  • Needs a browser with CSS tan(), round() and masks. Tested in Chrome and Firefox on Linux; not tested in Safari.

Credit

The card credits the design to Chris Yaneff for Commodore, 1965. The Commodore name and logo belong to their owners.

Browser support

The logo uses CSS tan(), clip-path, mask and custom properties, so it needs a browser from 2023 or later: Chrome/Edge 111+, Firefox 108+, Safari 15.4+. The outline variant and exported CSS with an outline or extrusion also use CSS round(): Chrome/Edge 125+, Firefox 118+, Safari 15.4+.

Contributing

Issues and pull requests are welcome. There is no build step: edit the files and reload the page. Please check changes in at least one Chromium browser and Firefox.

Licence and trademark

The code is released under the MIT licence.

The Commodore name and logo are trademarks of their respective owners. This project is an unofficial study of the logo's 1965 construction, designed by Chris Yaneff, and is not affiliated with or endorsed by the trademark holder. The MIT licence covers the code, not the trademark: check the trademark holder's terms before using the logo commercially.

About

The 1965 Commodore logo rebuilt in pure CSS from its construction card, with an editor to restyle and export it (PNG, WebP, JPEG, SVG, CSS, HTML).

Topics

Resources

Stars

10 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages