const categories = [
{
id: 'typography',
name: 'Typography',
description: 'HTML, being a markup language, has abundantly clear semantics for basic typography. Water.css leaves those semantics untouched.',
snippets: [
{
id: 'copy',
name: 'Headings and copy',
code: `
Heading 1
This is a paragraph that could contain long-form text. Heck, here's a link.
This is important, this is normal, and this is emphasized!
This is another paragraph that could contain long-form text.
Heading 2
You probably get the idea by now!
Heading 3
Heading 4
Heading 5
Heading 6
`
},
{
id: 'quotes',
name: 'Quotes',
code: `
"The HTML blockquote Element (or HTML Block Quotation Element) indicates that the enclosed text is an extended quotation. Usually, this is rendered visually by indentation (see Notes for how to change it). A URL for the source of the quotation may be given using the cite attribute, while a text representation of the source can be given using the <cite> cite element."
Did you know HTML supports inline quotes? I didn't, until I read that
the <q> HTML element indicates that the enclosed text is a short inline quotation
.
`
},
{
id: 'lists',
name: 'Lists',
code: `
Unordered list item 1
Unordered list item 2
Unordered list item 3
Ordered list item 1
Ordered list item 2
Ordered list item 3
Unordered lists
Represents an unordered list of items, typically rendered as a bulleted list
Ordered lists
Represents an ordered list of items, typically rendered as a numbered list
Description lists
Encloses a list of groups of terms and descriptions
Below is some code. If you select it, you can copy using Ctrl-C.
Did you know that alert(1) can show an alert in JavaScript?
// This logs a message to the console and check out the scrollbar.
console.log('Hello, world!')
HTML also has elements for variables and sample output: Hello, world!
`
}
]
},
{
id: 'forms',
name: 'Form controls',
description: 'Water.css provides a set of styles for form controls, including text inputs, select boxes, buttons, and more.',
snippets: [
{
id: 'text-inputs',
name: 'Text inputs',
code: `
`
},
{
id: 'buttons',
name: 'Buttons',
code: `
`
},
{
id: 'assorted-inputs',
name: 'Assorted other controls',
code: `
`
},
{
id: 'dialogs',
name: 'Dialogs',
caniuse: 'https://caniuse.com/dialog',
code: `
`,
realCode: `
`
}
]
},
{
id: 'misc',
name: 'Miscellaneous',
description: 'Styles are also provided for various other elements that don\'t strictly fit into the other categories. These include tables, dialogs, and images.',
snippets: [
{
id: 'tables',
name: 'Tables',
code: `