Design system github.com

GitHub · Change is constant. GitHub keeps you ahead. · GitHub

github.commode gelap1.600 elemen diukurdiukur 2 jam yang lalu
Kunjungi github.com

github.com memakai Mona Sans, Mona Sans VF untuk tipografi dan #08872b sebagai warna aksennya. Diukur pada 28 September 2026.

Pakai dengan AI Andajuga ada di dalam zip sebagai README.md dan PROMPT.md

  1. .
  2. Unzip paket ke dalam proyek Anda sehingga foldernya berada di design/github.com-design-pack/.
  3. Opsional: salin juga folder ke .claude/skills/github-com-design/. SKILL.md di dalamnya membuat Claude Code memuat paket dengan sendirinya setiap kali membangun UI.
  4. Tempel prompt di bawah ke Claude Code dan isi apa yang ingin Anda bangun.
Prompt

Prompt tetap dalam bahasa Inggris: prompt itu menyebut nama file di dalam paket, dan AI Anda bisa membacanya dalam bahasa apa pun.

Use the design pack in `design/github.com-design-pack/` as the source of truth for how the UI looks and behaves. It was measured from https://github.com/.

1. Read DESIGN.md (colours, type, spacing, radii, shadows, components) and BEHAVIOR.md (hover, focus, tooltips, menus, motion, scrolling, forms, responsive rules, dark mode) before writing any code.
2. Look at every image in `design/github.com-design-pack/screenshots/` and match the composition, density, whitespace and image treatment. Tokens do not carry those; the screenshots do.
3. Style everything with `design/github.com-design-pack/tokens.css` (or `tailwind.css` if this project uses Tailwind v4). Do not invent colours, radii, shadows or font sizes that are not in the pack.
4. Load the fonts named in DESIGN.md. Where a font is not freely available, use the stand-in it names at the same sizes and weights.
5. Match the breakpoints and hover, focus and motion rules in BEHAVIOR.md. Build both themes.

Now build: [describe the page or app you want]

When you are done, compare the result with the screenshots at desktop and phone widths, fix the biggest visual difference first, and repeat.

Warna9 token

background
#000000
surface
#0d1117
surface-2
#1c1f25
foreground
#ffffff
muted-foreground
#a4aea6
primary
#08872b
on-primary
#ffffff
secondary
#1f6feb
border
#25292e

Jarakunit 4px

48121620243240486496
Lebar konten
1280px

Tipografi3 font family

Mona Sansself-hosted, pengganti InterMona Sans VFself-hosted, pengganti InterMona Sans Monoself-hosted, pengganti Inter
headline-displayQuick brown fox64px / 425 / lh 1.08 / -2.24px
headline-lgQuick brown fox40px / 460 / lh 1.2
headline-mdQuick brown fox22px / 480 / lh 1.4
body-mdThe quick brown fox jumps over the lazy dog16px / 400 / lh 1.69
label-mdThe quick brown fox jumps over the lazy dog16px / 400 / lh 1.5 / 0.21px
buttonThe quick brown fox jumps over the lazy dog14px / 400 / lh 1.5
codeconst pack = extract(url)11px / 400 / lh 0.91 / 0.21px
Ukuran yang dipakai
111214161822244064

Tema terang

Dicapai lewat data-color-mode=light. Terang → gelap:

background#000000 → #000000
surface#0d1117 → #0d1117
surface-2#151a22 → #1c1f25
foreground#ffffff → #ffffff
muted-foreground#a4aea6 → #a4aea6
primary#08872b → #08872b
on-primary#ffffff → #ffffff
secondary#0969da → #1f6feb
border#ffffff → #25292e

Bayangan mode terang: rgb(25, 31, 27) 0px -1px 0px 0px inset

Radius

tombol 6pxinput 8pxkartu 16pxgambar 0px

Bayangan1

1

Komponen

PlatformSearch/Sign up for GitHubAlamat email
tombol ghost
teks #ffffff di atas transparan di atas #0d1117, r 0px, h 40px, 16px/500
tombol secondary
teks #ffffff di atas transparan di atas #0d1117, r 6px, h 32px, 16px/400
tombol primary
teks #ffffff di atas #08872b, r 6px, h 48px, 14px/400
input
h 41px, 0px solid #000000, r 8px
kartu
transparent, 1px solid #484f5880, r 16px
tautan
#ffffff, tanpa garis bawah, 400
header
72px, fixed, 12 tautan pada 16px
h1
64px / 425, perataan center, maks 924px
pemisah
Divider 1px #ffffff, margin 0px
formulir
2 forms, 2 inputs. Required markers: 0. Help texts: 0. Submit button is content-width. Label placement: floating (2).
ikon
Icons: 76 inline SVGs, filled, sizes 16px/18px/20px/31px, stroke 1.5; icon font classes icon-.

Interaksi dan animasi

  • button primary "Search/": background transparent → #ffffff29, border #262c28 → #ffffff1f
  • button secondary "Sign in": background transparent → #ffffff29, border #262c28 → #ffffff1f
  • nav link "Pricing": text #ffffff → #a4aea6, border #ffffff → #a4aea6
  • input: tanpa perubahan hover
  • fokus button primary: outline 2px solid rgb(48, 148, 255)
  • fokus input: no visible focus style measured (may rely on :focus-visible with keyboard only)
  • tooltip: No tooltip could be triggered from the first viewport, but the stylesheet defines tooltip rules (.tooltipped): position: relative.
  • menu: Hover/click menus: below the trigger, 1496px gap, shifted right; transparent, radius 0px, padding 0px 0px, shadow none; appears instantly (no fade); stays open after the pointer leaves (click-away or hover-intent grace).
  • animasi: 99 elements carry transitions; typical 0.2s with cubic-bezier(0.165, 0.84, 0.44, 1), mostly on opacity, transform, background-color. 1 running keyframe animations (Primer_Brand__LogoSuite-module__LogobarScrollX___eGhi4 60s infinite). 14 sizable elements sit at opacity 0 before scrolling: scroll-reveal animations are in use (reveal on enter, fade + rise is the usual recipe).

Responsif1440 / 1024 / 768 / 390 px

github.com pada 1440 piksel
1440px
github.com pada 1024 piksel
1024px
github.com pada 768 piksel
768px
github.com pada 390 piksel
390px
github.com pada 1440 piksel
1440px mode terang
ViewportKontenGutterBodyH1HeaderHeroGridTombol
desktop 14401280px258px14px64px, 2 lines, center72px, 3 links, 3 CTAtext only2→2 col; 2→1 col; 2→2 colcontent-width
laptop 1024928px50px14px64px, 2 lines, center72px, 3 links, 3 CTAtext only2→2 col; 2→1 col; 2→2 colcontent-width
tablet 768574px48px14px56px, 2 lines, center65px, hamburger (Toggle navigation), 1 CTAtext only2→2 col; 2→1 col; 2→2 colcontent-width
phone 390342px48px14px40px, 4 lines, center65px, hamburger (Toggle navigation), 1 CTAtext only4→2 col13 full-width
  • H1 goes 64px → 40px (63%), 2 → 4 lines.
  • Nav collapses to a hamburger by 390px (first seen at 768px); header 72px → 65px.
  • Body text stays 14px at every width.
  • Phone side gutter 48px.
  • 13 buttons stretch full-width on phones.
  • Section top padding 72px → 65px.

File di dalam paket15 file

DESIGN.md
Format DESIGN.md dari Google; Stitch, Claude Code, dan Cursor membacanya
11 kB
tokens.json
W3C Design Tokens (DTCG) untuk Style Dictionary dan plugin Figma
10 kB
tokens.css
Nilai yang sama sebagai CSS custom property
1,6 kB
tailwind.css
Blok @theme Tailwind v4
717 byte
SKILL.md
Skill Claude Code / Cursor yang mengurutkan isi paket untuk agen
2,2 kB
BEHAVIOR.md
Hover, fokus, tooltip, menu, animasi, scrolling, tabel, formulir, teks, responsif, mode gelap, stack
12 kB
evidence.json
Pengukuran mentah di balik kedua dokumen (setiap viewport, probe, dan aturan)
75 kB
screenshots/
desktop-1440-fold.png, desktop-1440-full.jpg, desktop-1440-light.png, laptop-1024-fold.png, tablet-768-fold.png, phone-390-fold.png, phone-390-full.jpg
7 gambar
DESIGN.md271 baris
---
version: alpha
name: "github.com"
description: "Design system extracted from https://github.com/ on 2026-09-28"
colors:
  background: "#000000"
  surface: "#0d1117"
  surface-2: "#1c1f25"
  foreground: "#ffffff"
  muted-foreground: "#a4aea6"
  primary: "#08872b"
  on-primary: "#ffffff"
  secondary: "#1f6feb"
  border: "#25292e"
typography:
  headline-display:
    fontFamily: "Mona Sans"
    fontSize: "64px"
    fontWeight: 425
    lineHeight: "1.08"
    letterSpacing: "-2.24px"
  headline-lg:
    fontFamily: "Mona Sans"
    fontSize: "40px"
    fontWeight: 460
    lineHeight: "1.2"
  headline-md:
    fontFamily: "Mona Sans"
    fontSize: "22px"
    fontWeight: 480
    lineHeight: "1.4"
  body-md:
    fontFamily: "Mona Sans"
    fontSize: "16px"
    fontWeight: 400
    lineHeight: "1.69"
  label-md:
    fontFamily: "Mona Sans"
    fontSize: "16px"
    fontWeight: 400
    lineHeight: "1.5"
    letterSpacing: "0.21px"
  button:
    fontFamily: "Mona Sans VF"
    fontSize: "14px"
    fontWeight: 400
    lineHeight: "1.5"
  code:
    fontFamily: "Mona Sans Mono"
    fontSize: "11px"
    fontWeight: 400
    lineHeight: "0.91"
    letterSpacing: "0.21px"
rounded:
  none: "0px"
  md: "6px"
  xl: "16px"
  2xl: "60px"
  full: "9999px"
spacing:
  unit: "4px"
  1: "4px"
  2: "8px"
  3: "12px"
  4: "16px"
  5: "20px"
  6: "24px"
  7: "32px"
  8: "40px"
  9: "48px"
  10: "64px"
  11: "96px"
components:
  button-ghost:
    backgroundColor: "#0d1117"
    textColor: "#ffffff"
    typography: "{typography.button}"
    rounded: "0px"
    height: "40px"
    padding: "8px 8px"
  button-secondary:
    backgroundColor: "#0d1117"
    textColor: "#ffffff"
    typography: "{typography.button}"
    rounded: "6px"
    height: "32px"
    padding: "1px 12px"
  button-primary:
    backgroundColor: "{colors.primary}"
    textColor: "{colors.on-primary}"
    typography: "{typography.button}"
    rounded: "6px"
    height: "48px"
    padding: "6px 20px"
  input:
    backgroundColor: "transparent"
    rounded: "8px"
    height: "41px"
  card:
    backgroundColor: "transparent"
    rounded: "16px"
    padding: "0px"
---

# github.com

## Overview

GitHub · Change is constant. GitHub keeps you ahead. · GitHub: Join the world's most widely adopted, AI-powered developer platform where millions of developers, businesses, and the largest open source community build software that advances humanity.

Gently rounded controls, one soft shadow for depth, large display type at 64px / 425, a single green accent on neutrals. The site ships in dark mode by default (dark surfaces, light type). Measured from 1600 rendered elements at 1440px wide on 2026-09-28.

Reference screenshots live beside this file; look at them before writing any layout, they carry the composition, density and image treatment that tokens cannot:

- `screenshots/desktop-1440-fold.png`: Desktop 1440, above the fold
- `screenshots/desktop-1440-full.jpg`: Desktop 1440, full page
- `screenshots/desktop-1440-light.png`: Desktop 1440, light mode
- `screenshots/laptop-1024-fold.png`: Laptop 1024, above the fold
- `screenshots/tablet-768-fold.png`: Tablet 768, above the fold
- `screenshots/phone-390-fold.png`: Phone 390, above the fold
- `screenshots/phone-390-full.jpg`: Phone 390, full page

## Colors

| Token | Value | Use |
| --- | --- | --- |
| background | `#000000` | Page background |
| surface | `#0d1117` | Cards, panels, raised or recessed surfaces |
| surface-2 | `#1c1f25` | Secondary surface |
| foreground | `#ffffff` | Primary text |
| muted-foreground | `#a4aea6` | Secondary text, captions |
| primary | `#08872b` | Accent: primary buttons, links, focus |
| on-primary | `#ffffff` | Text on the accent |
| secondary | `#1f6feb` | Secondary accent (blue) |
| border | `#25292e` | Hairlines, dividers, input borders |

Full painted palette by area (largest first): `#000000`, `#0d1117`, `#1c1f25`, `#3d4145`, `#31353a`, `#08872b`, `#5fed83`, `#1f6feb`.

Gradients in use: `linear-gradient(rgb(0, 2, 64), rgba(0, 0, 0, 0))`; `radial-gradient(circle at 0px 100%, rgb(230, 183, 254) 10%, rgb(80, 73, 194) 20%, rgba(87, 78, 255, 0) 60%)`; `linear-gradient(rgb(0, 2, 64), rgb(0, 0, 0) 117%)`.

The accent `#08872b` is used sparingly: primary buttons, links and focus rings. Everything else stays neutral.

## Typography

- **Mona Sans** for h1, h2, h3, body, label: self-hosted webfont, not freely available; use **Inter** from Google Fonts as the stand-in.
- **Mona Sans VF** for button: self-hosted webfont, not freely available; use **Inter** from Google Fonts as the stand-in.
- **Mona Sans Mono** for code: self-hosted webfont, not freely available; use **Inter** from Google Fonts as the stand-in.

| Role | Family | Size | Weight | Line height | Tracking |
| --- | --- | --- | --- | --- | --- |
| headline-display | Mona Sans | 64px | 425 | 1.08 | -2.24px |
| headline-lg | Mona Sans | 40px | 460 | 1.2 | normal |
| headline-md | Mona Sans | 22px | 480 | 1.4 | normal |
| body-md | Mona Sans | 16px | 400 | 1.69 | normal |
| label-md | Mona Sans | 16px | 400 | 1.5 | 0.21px |
| button | Mona Sans VF | 14px | 400 | 1.5 | normal |
| code | Mona Sans Mono | 11px | 400 | 0.91 | 0.21px |

Type scale in use: 11px, 12px, 14px, 16px, 18px, 22px, 24px, 40px, 64px. Base body size 16px.

The H1 renders at 64px / 425, center aligned, up to 924px wide, tracking -2.24px. Sample: "The future of building happens together".

## Layout

- Spacing unit: 4px. Scale in use: 4, 8, 12, 16, 20, 24, 32, 40, 48, 64, 96 (px).
- Flex and grid gaps: 4, 8, 12, 16, 24, 32, 44, 48 px.
- Content max width: 1280px, centred.
- Header: 72px tall, fixed, background `rgba(0, 0, 0, 0)`; 12 nav links at 16px / 400 (GitHub CopilotWrite better code with AI · GitHub Copilot appDirect agents from issue to merge · MCP RegistryIntegrate external tools · ActionsAutomate any workflow · CodespacesInstant dev environments · IssuesPlan and track work · Code ReviewManage code changes · Code QualityEnforce quality at merge).

## Elevation & Depth

Shadows in use, most common first:

- shadow-1: `rgb(25, 31, 27) 0px -1px 0px 0px inset`

## Shapes

- Buttons: 6px
- Inputs: 8px
- Cards and panels: 16px
- Images and media: 0px
- Radius scale: none 0px, md 6px, xl 16px, 2xl 60px, full 9999px

## Components

### Button, ghost

Background transparent (it sits on `#0d1117`, so place it on that colour), text `#ffffff`, border none, radius 0px, height 40px, padding 8px 8px, 16px / 500. Sample label: "Platform".

### Button, secondary

Background transparent (it sits on `#0d1117`, so place it on that colour), text `#ffffff`, border 1px solid #262c28, radius 6px, height 32px, padding 1px 12px, 16px / 400. Sample label: "Search/".

### Button, primary

Background `#08872b`, text `#ffffff`, border 1px solid transparent, radius 6px, height 48px, padding 6px 20px, 14px / 400. Sample label: "Sign up for GitHub".

### Input

Height 41px, background `transparent`, border 0px solid #000000, radius 8px, 16px text, padding 18px 12px.

### Card

Background `transparent`, border 1px solid #484f5880, radius 16px, padding 0px, no shadow. Typical size about 378×332px.

### Link

Colour `#ffffff`, no underline at rest, weight 400.

## Dark Mode

Both themes exist; the default render is dark and the light theme was reached via data-color-mode=light. Token pairs, light → dark:

| Token | Light | Dark |
| --- | --- | --- |
| background | `#000000` | `#000000` |
| surface | `#0d1117` | `#0d1117` |
| surface-2 | `#151a22` | `#1c1f25` |
| foreground | `#ffffff` | `#ffffff` |
| muted-foreground | `#a4aea6` | `#a4aea6` |
| primary | `#08872b` | `#08872b` |
| on-primary | `#ffffff` | `#ffffff` |
| secondary | `#0969da` | `#1f6feb` |
| border | `#ffffff` | `#25292e` |

Light-theme shadows: `rgb(25, 31, 27) 0px -1px 0px 0px inset`

The light pass changed the page but the result still reads as dark; check the light screenshot.

## Responsive Behavior

| Viewport | Content width | Gutter | Body | H1 | Header | Hero | Grids | Buttons |
| --- | --- | --- | --- | --- | --- | --- | --- | --- |
| desktop 1440px | 1280px | 258px | 14px | 64px, 2 lines, center | 72px, 3 links, 3 CTA | text only | 2→2 col; 2→1 col; 2→2 col | content-width |
| laptop 1024px | 928px | 50px | 14px | 64px, 2 lines, center | 72px, 3 links, 3 CTA | text only | 2→2 col; 2→1 col; 2→2 col | content-width |
| tablet 768px | 574px | 48px | 14px | 56px, 2 lines, center | 65px, hamburger (Toggle navigation), 1 CTA | text only | 2→2 col; 2→1 col; 2→2 col | content-width |
| phone 390px | 342px | 48px | 14px | 40px, 4 lines, center | 65px, hamburger (Toggle navigation), 1 CTA | text only | 4→2 col | 13 full-width |

- H1 goes 64px → 40px (63%), 2 → 4 lines.
- Nav collapses to a hamburger by 390px (first seen at 768px); header 72px → 65px.
- Body text stays 14px at every width.
- Phone side gutter 48px.
- 13 buttons stretch full-width on phones.
- Section top padding 72px → 65px.

## Interaction & Motion

99 elements carry transitions; typical 0.2s with cubic-bezier(0.165, 0.84, 0.44, 1), mostly on opacity, transform, background-color. 1 running keyframe animations (Primer_Brand__LogoSuite-module__LogobarScrollX___eGhi4 60s infinite).

- Hover on button-primary ("Search/"): background transparent → #ffffff29, border #262c28 → #ffffff1f; cursor pointer; transition background-color, border-color | 0.2s, 0.2s | ease, ease | delay 0s, 0s.
- Hover on button-secondary ("Sign in"): background transparent → #ffffff29, border #262c28 → #ffffff1f; cursor pointer; transition background-color, border-color | 0.2s, 0.2s | ease, ease | delay 0s, 0s.
- Hover on nav-link ("Pricing"): text #ffffff → #a4aea6, border #ffffff → #a4aea6; cursor pointer.
- Hover on input: no visible change; cursor text; transition color, background-color, box-shadow | 0.08s | cubic-bezier(0.33, 1, 0.68, 1).
- Focus on button-primary: outline 2px solid rgb(48, 148, 255).
- Focus on input: no visible focus style measured (may rely on :focus-visible with keyboard only).
- No tooltip could be triggered from the first viewport, but the stylesheet defines tooltip rules (.tooltipped): position: relative.
- Hover/click menus: below the trigger, 1496px gap, shifted right; transparent, radius 0px, padding 0px 0px, shadow none; appears instantly (no fade); stays open after the pointer leaves (click-away or hover-intent grace).
- 14 sizable elements sit at opacity 0 before scrolling: scroll-reveal animations are in use (reveal on enter, fade + rise is the usual recipe).

Full detail (every overlay, table, form, scroll and text rule measured) is in `BEHAVIOR.md`; raw evidence in `evidence.json`.

## Do's and Don'ts

- Do use 4px multiples for every padding, margin and gap; the site does not use odd values.
- Do reserve `#08872b` for actions and focus; never paint large areas with it.
- Do keep body text at 16px in Mona Sans.
- Do match corner radii per element class (buttons 6px, cards 16px); do not pick one radius for everything.
- Do use the measured shadows above; do not invent heavier ones.
- Don't substitute a different accent hue or introduce gradients that are not listed above.
- Don't rebuild from the tokens alone; open the screenshots for composition, density and image treatment.