Website Style Guide

http://robertcsmith.me

Version 1.1 |

Typography

HTML Headings Tags

HTML tags define default Heading styles.
All H1 Headings
or
heading-style-h1
H2
subheading

Inside an hgroup

Heading 1 - Long Boring Text and Stuff & B Tag Text

H2 With Subheading Class & Long Boring Text and Stuff Long Boring Text and Stuff

All H2 Headings
or
heading-style-h2
H3
subheading

Inside an hgroup

Heading 2 - Long Boring Text and Stuff Long Boring Text and Stuff & B Tag Text

H3 With Subheading Class & Long Boring Text and Stuff Long Boring Text and Stuff

All H3 Headings
or
heading-style-h3
H4
subheading

Inside an hgroup

Heading 3 - Long Boring Text and Stuff Long Boring Text and Stuff & B Tag Text

H4 With Subheading Class & Long Boring Text and Stuff Long Boring Text and Stuff Long Boring Text and Stuff Long Boring Text and Stuff

All H4 Headings
or
heading-style-h4
H5
subheading

Heading 4 & B Tag Text

H5 With Subheading Class
All H5 Headings
or
heading-style-h5
H6
subheading
Heading 5 & B Tag Text
H6 With Subheading Class
All H6 Headings
or
heading-style-h6
Heading 6 & B Tag Text

Other HTML Tags

HTML tags define default text styles.
All Paragraphs

A <p> element denotes a paragraph. A paragraph (from the Greek paragraphos, “to write beside” or “written beside”) is a self-contained unit of a discourse in writing dealing with a particular point or idea. A paragraph consists of one or more sentences. Though not required by the syntax of any language, paragraphs are usually an expected part of formal writing, used to organize longer prose.

All Links

This is a paragraph with a link inside of it. Links are anchor or <a> elements. This is an external link

Download file type icon indicators appear automatically when the link ends in .doc .docx or .pdf :

Links to email addresses and telephone numbers are auto decorated by css automatically, such as the email address Jon Doe and his telephone number +1 415-997-9947.

del
and
ins

The <del> element denotes deleted text and the <ins> element denotes inserted text in edited documents.

s

A strikethrough ( <s> element) is used to indicate content that has been superceeded, is no longer accurate or is no longer relevant. Such as when referring to Twitter X.

sup

The <sup> superscript® element.

sub

The <sub> subscript for things like H2O.

small

The <small> element is for fine print, legal copy, etc.

abbr

The <abbr title="Hypertext Markup Language"> element is for acronyms and abbreviations such as HTML

q

This text is a short inline quotation.

cite

This is a citation.

dfn

The <dft> element indicates a definition.

mark

The <mark> element indicates a highlight.

var

The <var> variable element, such as x = y. It is used outside of code blocks

time

The 1<time datetime="2024-01-21T12:32"> time element: is an inline element with a datatime attribute which defines the precise date and time to which the txt refers. It is used in the title of blog posts

Block Quotes
containing
Paragraphs
x 2 and
cite

A <blockquote> (also known as a long quotation or extract) is a quotation in a written document, that is set off from the main text as a paragraph, or block of text.

It is distinguished visually using indentation and a serif typeface in italics. It contains one or more <p> elements and may or may not include a citation <cite> (which may or may not link to the source with <a href="url">) placed at the bottom.

To emphasize or call out text within a blockquote like this you may wrap text with the 1<mark> element

When a blockquote contains a <p> element, the oopening and closing quotation marks are added automatically are styled nicely.

Said no one, ever.
Description list
Description Lists
Description lists (<dl> elements) are used to group terms/descriptions in a block-level list (such as this). They consist of one or more key/value pair entries consisting of a description term (<dt> element) and a description detail (<dd> element).
This Is A Description Term
And I am the Description Detail which typically contains a paragraph with more information. These are used when there is more information to convey than a typical inline definition (<dfn> element).
Unordered List (ul)
list-unstyled

This is an unordered list (1<ul class="list-unstyled"> element)

  • Unstyled, unordered list item 1
  • Unstyled, unordered list item 2
  • Unstyled, unordered list item 3
Unordered List (ul)
  • List Item 1
  • List Item 2
    • List Item 1
    • List Item 2
      • List Item 1
      • List Item 2
        • List Item 1
        • List Item 2
          • List Item 1
          • List Item 2
          • List Item 3
        • List Item 3
      • List Item 3
    • List Item 3
  • List Item 3
Ordered (ol)
  1. List Item 1
  2. List Item 2
    1. List Item 1
    2. List Item 2
      1. List Item 1
      2. List Item 2
        1. List Item 1
        2. List Item 2
          1. List Item 1
          2. List Item 2
          3. List Item 3
        3. List Item 3
      3. List Item 3
    3. List Item 3
  3. List Item 3
details
/
summary
Expand for details

Lorem ipsum dolor sit amet consectetur adipisicing elit. Cum, odio! Odio natus ullam ad quaerat, eaque necessitatibus, aliquid distinctio similique voluptatibus dicta consequuntur animi. Quaerat facilis quidem unde eos! Ipsa.

address
Robert C Smith
4481 25th Ave.
Sacramento, CA 95820
USA
Horizontal Rule (hr)

table
with
caption
thead
tr
th
td
tfoot
tbody
Table Caption
Table Heading 1 Table Heading 2 Table Heading 3 Table Heading 4 Table Heading 5
Table Footer 1 Table Footer 2 Table Footer 3 Table Footer 4 Table Footer 5
Table Cell 1 Table Cell 2 Table Cell 3 Table Cell 4 Table Cell 5
Table Cell 1 Table Cell 2 Table Cell 3 Table Cell 4 Table Cell 5
Table Cell 1 Table Cell 2 Table Cell 3 Table Cell 4 Table Cell 5
Table Cell 1 Table Cell 2 Table Cell 3 Table Cell 4 Table Cell 5
img
figure
with
img
figcaption
Here is a caption for this image.
keyboard input (kbd)
(inside a paragraph)

The Keyboard input (<kbd> element) has innerHTML text of what is physically displayed on the key itself such as: shift. Combinations of keystrokes are indicated with a plus sign between them: Ctrl + Alt + Del

samp-le output
(inside a paragraph)

The Sample Output (1<samp/>) Element is used to denote example text feedback on a computer resulting from a specified user action. The element is to be used inline for example, when you successfully start this application on your local computer it should read [Bootstrap] Application is running at http://[::1]:3000 which indicates it is successfully serving pages on that address. If you want to to show larger output or feedback that would be more appropriate to use the the 1<pre/>1<code data--grammar="source.shell"/> elements to generate a code block.

code
- Inline (inside a paragraph)

Inline code: <div class="adsfadsf">code</div>

pre
code
1import winston, { createLogger } from 'winston';2import { getLoggingConfig } from './app/config/logging-config.mjs';3import { ExpressAdapter, NestExpressApplication } from '@nestjs/platform-express';4import { Logger, LoggerService } from '@nestjs/common';5import { NestFactory } from '@nestjs/core';6import { ConfigService } from '@nestjs/config';7import { WinstonModule } from 'nest-winston';8import { AppConfig } from './app/config/app-config.mjs';9import { AppModule } from './app/app-module.mjs';10 11const winstonLogger: winston.Logger = createLogger(getLoggingConfig(process.env.NODE_ENV));12const logger: LoggerService = new Logger('Bootstrap');13let app: NestExpressApplication;14 15const bootstrap = async (): Promise<string | void> => {16 17    app = await NestFactory.create<NestExpressApplication>(18        AppModule,19        new ExpressAdapter(),20        {21            logger: WinstonModule.createLogger({22                instance: winstonLogger23            }),24        }25    );26    AppConfig.configure(app);27    await app.listen(app.get(ConfigService).get<number>('APP_PORT'));28    return await app.getUrl();29};30 31bootstrap().then((url) => {32    logger.log(`Application is running at ${url}`);33}).catch(async (error) => {34    logger.error(error.toString());35    try {36        await app.close();37        logger.log('app successfully closed');38    } catch (e) {39        logger.error(e.toString());40    }41    process.exit(1);42});

Text Sizes

Text sizes classes when typography size doesn't match the default HTML tag.
text-size-large

Lorem ipsum dolor sit amet, consectetur adipiscing elit. This text is wrapped in a strong tag. Suspendisse varius enim in eros. Here is a link in the paragraph. Elementum tristique. This is an external link to an "external link in the paragraph. Duis cursus, mi quis viverra ornare, eros dolor interdum nulla, ut commodo diam libero vitae erat. This text is wrapped in an em tag for emphasis Aenean faucibus nibh et justo cursus id rutrum lorem imperdiet. This text is wrapped in a b tag Nunc ut sem vitae risus tristique posuere. This text here is wrapped in an i tag. Duis cursus, mi quis viverra ornare, eros dolor interdum nulla, ut commodo diam libero vitae erat. This text here is wrapped in an u tag Aenean faucibus nibh et justo cursus id rutrum lorem imperdiet.

text-size-medium

Lorem ipsum dolor sit amet, consectetur adipiscing elit. This text is wrapped in a strong tag. Suspendisse varius enim in eros. Here is a link in the paragraph. Elementum tristique. This is an external link to an "external link in the paragraph. Duis cursus, mi quis viverra ornare, eros dolor interdum nulla, ut commodo diam libero vitae erat. This text is wrapped in an em tag for emphasis Aenean faucibus nibh et justo cursus id rutrum lorem imperdiet. This text is wrapped in a b tag Nunc ut sem vitae risus tristique posuere. This text here is wrapped in an i tag. Duis cursus, mi quis viverra ornare, eros dolor interdum nulla, ut commodo diam libero vitae erat. This text here is wrapped in an u tag Aenean faucibus nibh et justo cursus id rutrum lorem imperdiet.

text-size-regular

Lorem ipsum dolor sit amet, consectetur adipiscing elit. This text is wrapped in a strong tag. Suspendisse varius enim in eros. Here is a link in the paragraph. Elementum tristique. This is an external link to an "external link in the paragraph. Duis cursus, mi quis viverra ornare, eros dolor interdum nulla, ut commodo diam libero vitae erat. This text is wrapped in an em tag for emphasis Aenean faucibus nibh et justo cursus id rutrum lorem imperdiet. This text is wrapped in a b tag Nunc ut sem vitae risus tristique posuere. This text here is wrapped in an i tag. Duis cursus, mi quis viverra ornare, eros dolor interdum nulla, ut commodo diam libero vitae erat. This text here is wrapped in an u tag Aenean faucibus nibh et justo cursus id rutrum lorem imperdiet.

text-size-small

Lorem ipsum dolor sit amet, consectetur adipiscing elit. This text is wrapped in a strong tag. Suspendisse varius enim in eros. Here is a link in the paragraph. Elementum tristique. This is an external link to an "external link in the paragraph. Duis cursus, mi quis viverra ornare, eros dolor interdum nulla, ut commodo diam libero vitae erat. This text is wrapped in an em tag for emphasis Aenean faucibus nibh et justo cursus id rutrum lorem imperdiet. This text is wrapped in a b tag Nunc ut sem vitae risus tristique posuere. This text here is wrapped in an i tag. Duis cursus, mi quis viverra ornare, eros dolor interdum nulla, ut commodo diam libero vitae erat. This text here is wrapped in an u tag Aenean faucibus nibh et justo cursus id rutrum lorem imperdiet.

Text Weights

Text weight classes when typography weight doesn't match the default HTML tag.
text-weight-xbold
text-weight-xbold (800)
text-weight-bold
text-weight-bold (700)
text-weight-semibold
text-weight-semibold (600)
text-weight-medium
text-weight-medium (500)
text-weight-normal
text-weight-normal (400)
text-weight-light
text-weight-light (300)

Text Styles

Text style classes when typography style doesn't match the default HTML tag.
text-style-italic
text-style-italic
text-style-strikethrough
text-style-strikethrough
text-style-allcaps
text-style-allcaps
text-style-nowrap
text-style-nowrap
text-style-quote
text-style-quote
text-style-link
text-style-link
text-style-2lines
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Suspendisse varius enim in eros elementum tristique. Duis cursus, mi quis viverra ornare, eros dolor interdum nulla, ut commodo diam libero vitae erat. Aenean faucibus nibh et justo cursus id rutrum lorem imperdiet. Nunc ut sem vitae risus tristique posuere.
text-style-3lines
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Suspendisse varius enim in eros elementum tristique. Duis cursus, mi quis viverra ornare, eros dolor interdum nulla, ut commodo diam libero vitae erat. Aenean faucibus nibh et justo cursus id rutrum lorem imperdiet. Nunc ut sem vitae risus tristique posuere. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Suspendisse varius enim in eros elementum tristique. Duis cursus, mi quis viverra ornare, eros dolor interdum nulla, ut commodo diam libero vitae erat. Aenean faucibus nibh et justo cursus id rutrum lorem imperdiet. Nunc ut sem vitae risus tristique posuere.
text-style-muted
text-style-muted

Text Alignment

Text alignment classes when typography alignment doesn't match the default HTML tag.
text-align-left
text-align-left
text-align-center
text-align-center
text-align-right
text-align-right

Colors

Color Palette

bg-color-black
bg-color-white
100
200
300
400
500
600
700
800
900
bg-color-gray
#eeeded
#dad9d9
#bdbab9
#a3a1a0
#7b7978
#686665
#4a4948
#2e2d2d
#1a1817
bg-color-blue
e8f5ff
#ceecff
#9dd1ff
#6cb6ff
#3e8ae1
#0f5dc3
#0041ab
#002a81
#001a58
bg-color-green
#eff7f0
#d5ebd6
#acd6ad
#87c488
#6bb66c
#428d43
#196e1a
#015507
#003709
bg-color-red
#ffeded
#ffe0e0
#fab4b1
#f47067
#d8473d
#bf271d
#991209
#740801
#500601
bg-color-purple
#f8f2ff
#f1e5fe
#e4c4fc
#d69ef8
#c678dd
#924eb9
#60278d
#411077
#24014c
bg-color-orange
#fff4e9
#ffe5c4
#ffd9ac
#f5b97e
#e79552
#c36826
#973900
#6e2f00
#4a1f00
bg-color-yellow
#fef8e4
#fdf0c8
#fbe090
#f9d16c
#f7c147
#c29027
#8d5f06
#684500
#4a3100

Text Color

Manage recurring text colors.
Black and White
text-color-white
text-color-white
text-color-black
text-color-black
Gray
text-color-gray100
text-color-gray100
text-color-gray200
text-color-gray200
text-color-gray300
text-color-gray300
text-color-gray400
text-color-gray400
text-color-gray500
text-color-gray500
text-color-gray600
text-color-gray600
text-color-gray700
text-color-gray700
text-color-gray800
text-color-gray800
text-color-gray900
text-color-gray900
Green
text-color-green100
text-color-green100
text-color-green200
text-color-green200
text-color-green300
text-color-green300
text-color-green400
text-color-green400
text-color-green500
text-color-green500
text-color-green600
text-color-green600
text-color-green700
text-color-green700
text-color-green800
text-color-green800
text-color-green900
text-color-green900
Red
text-color-red100
text-color-red100
text-color-red200
text-color-red200
text-color-red300
text-color-red300
text-color-red400
text-color-red400
text-color-red500
text-color-red500
text-color-red600
text-color-red600
text-color-red700
text-color-red700
text-color-red800
text-color-red800
text-color-red900
text-color-red900
Yellow
text-color-yellow100
text-color-yellow100
text-color-yellow200
text-color-yellow200
text-color-yellow300
text-color-yellow300
text-color-yellow400
text-color-yellow400
text-color-yellow500
text-color-yellow500
text-color-yellow600
text-color-yellow600
text-color-yellow700
text-color-yellow700
text-color-yellow800
text-color-yellow800
text-color-yellow900
text-color-yellow900
Blue
text-color-blue100
text-color-blue100
text-color-blue200
text-color-blue200
text-color-blue300
text-color-blue300
text-color-blue400
text-color-blue400
text-color-blue500
text-color-blue500
text-color-blue600
text-color-blue600
text-color-blue700
text-color-blue700
text-color-blue800
text-color-blue800
text-color-blue900
text-color-blue900

Effects

Box Shadows

Shadows allow you to add depth and realism to designs by positioning elements on a z-axis.
shadow-xxsmall
shadow-xsmall
shadow-small
shadow-medium
shadow-large
shadow-xlarge
shadow-xxlarge
shadow-custom1
shadow-custom2
shadow-custom4
shadow-custom5
shadow-custom6

UI Elements

Buttons

button
/
button
is-submitting
button
is-small
/
button
is-small
is-submitting
button
is-secondary
/
button
is-secondary
is-submitting
button
is-secondary
is-small
/
button
is-secondary
is-small
is-submitting
button
is-tertiary
/
button
is-tertiary
is-submitting
button
is-tertiary
is-small
/
button
is-tertiary
is-small
is-submitting
button
is-link
button
is-icon
button
is-small
is-icon
button
is-secondary
is-icon
button
is-secondary
is-small
is-icon
button
is-tertiary
is-icon
button
is-tertiary
is-small
is-icon
button
is-link
is-icon
To use on a black background, simply use the add-on class is-alternate
button
is-alternate
button
is-alternate
is-small
button
is-alternate
is-secondary
button
is-alternate
is-secondary
is-small
button
is-alternate
is-link
button
is-alternate
is-icon
button
is-alternate
is-small
is-icon
button
is-alternate
is-secondary
is-icon
button
is-alternate
is-secondary
is-small
is-icon
button
is-alternate
is-link
is-icon
To use on a blue background, simply use the add-on class is-alternate-blue
button
is-alternate-blue
button
is-alternate-blue
is-small
button
is-alternate-blue
is-secondary
button
is-alternate-blue
is-secondary
is-small
button
is-alternate-blue
is-link
button
is-alternate-blue
is-icon
button
is-alternate-blue
is-small
is-icon
button
is-alternate-blue
is-secondary
is-icon
button
is-alternate-blue
is-secondary
is-small
is-icon
button
is-alternate-blue
is-link
is-icon

Buttons With Icons Only

button
is-icon-only
button
is-small
is-icon-only
button
is-secondary
is-icon-only
button
is-secondary
is-small
is-icon-only
button
is-tertiary
is-icon-only
button
is-tertiary
is-small
is-icon-only
button
is-link
is-icon-only
button
is-alternate
is-icon-only
button
is-alternate
is-small
is-icon-only
button
is-alternate
is-secondary
is-icon-only
button
is-alternate
is-secondary
is-small
is-icon-only
button
is-alternate
is-tertiary
is-icon-only
button
is-alternate
is-tertiary
is-small
is-icon-only
button
is-alternate
is-link
is-icon-only
button
is-alternate-blue
is-icon-only
button
is-alternate-blue
is-small
is-icon-only
button
is-alternate-blue
is-secondary
is-icon-only
button
is-alternate-blue
is-secondary
is-small
is-icon-only
button
is-alternate-blue
is-tertiary
is-icon-only
button
is-alternate-blue
is-tertiary
is-small
is-icon-only
button
is-alternate-blue
is-link
is-icon-only

Form Elements

form
label
input[type='text']
textarea
select
input[type='password']
input[type='checkbox']
 x 3
What are your interests? (choose 2 or more)
Choose 2 or more items in this set
fieldset
&
legend
input[type='radio']
 x 3
Fieldset Legend
A selection from this group is required
button
.success-message
.error-message
(click submit to view the status messages) Ideally output from the server goes here, the html which is received from the htmx form submittal is placed inside here.
Thank you! Your submission has been received!
Oops! Something went wrong while submitting the form.

Icons (Image)

icon-height-xxsmall

icon-height-xsmall

icon-height-small

icon-height-medium

icon-height-large

icon-height-xlarge

icon-height-xxlarge

icon-width-xxsmall

icon-width-xsmall

icon-width-small

icon-width-medium

icon-width-large

icon-width-xlarge

icon-width-xxlarge

icon-xxsmall

icon-xsmall

icon-small

icon-medium

icon-large

icon-xlarge

icon-xxlarge

icon-width-xxsmall

icon-width-xsmall

icon-width-small

icon-width-medium

icon-width-large

icon-width-xlarge

icon-width-xxlarge

icon-height-xxsmall

3

icon-height-xsmall

4

icon-height-small

5 ^ & * ( ) { } [ ]

icon-height-medium

6 ! " @ # $

icon-height-large

7 %

icon-height-xlarge

8

icon-height-xxlarge

9

Icons (HTML Embed)

HTML embed icons enable you to control icon color on hover.

icon-embed xxsmall

Cube

icon-embed xsmall

Cube

icon-embed small

Cube

icon-embed regular

Cube

icon-embed medium

Cube

icon-embed large

Cube

icon-embed xlarge

Cube

icon-embed xxlarge

Cube

Structure Classes

Core

Defined and flexible core structure we can use on all or most pages.
container-xxsmall
container-xsmall
container-small
container-medium
container-large
container-xlarge
container-xxlarge
padding-global
padding-section-small
padding-section-medium
padding-section-large
button-group

Max Widths

Use the max-width CSS property to contain inner content to a maximum width.
max-width-full
max-width-xxlarge
max-width-xlarge
max-width-large
max-width-medium
max-width-small
max-width-xsmall
max-width-xxsmall

Paddings

Direction Classes

padding-bottom
padding-medium
padding-top
padding-medium
padding-vertical
padding-medium
padding-horizontal
padding-medium
padding-left
padding-medium
padding-right
padding-medium

Size Classes

padding-0
padding-tiny
padding-xxsmall
padding-xsmall
padding-small
padding-medium
padding-large
padding-xlarge
padding-xxlarge
padding-huge
padding-xhuge
padding-xxhuge

Margins

Direction Classes

margin-bottom
margin-medium
margin-top
margin-medium
margin-vertical
margin-medium
margin-horizontal
margin-medium
margin-left
margin-medium
margin-right
margin-medium

Size Classes

margin-0
margin-tiny
margin-xxsmall
margin-xsmall
margin-small
margin-medium
margin-large
margin-xlarge
margin-xxlarge
margin-huge
margin-xhuge
margin-xxhuge

Utility Classes

Etcetera

Useful utility classes we like to use in most of our projects to build faster.
hide
This element is hidden
hide-tablet
hide-mobile-portrait
hide-mobile-landscape
overflow-visible
overflow-hidden
overflow-auto
overflow-scroll
pointer-events-off

This is a link. Notice that on hover, the cursor will remain the same and the link cannot be clicked.

pointer-events-off
>
pointer-events-on

This is another link It is inside a div.pointer-events-on inside a div.pointer-events-off and therefore the cursor should change on hover and the link should refresh the page when clicked

div-square
spacing-clean
align-center
display-inlineflex