-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
16 changed files
with
168 additions
and
45 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
--- | ||
layout: docs.webc | ||
title: Canvas | ||
description: A canvas represents a part of the page that content and controls sit within, they can provide padding and backgrounds for their content area. | ||
tags: ['docs', 'Four Cs'] | ||
icon: canvas | ||
previous: /docs/controls/ | ||
next: /docs/composition/ | ||
--- | ||
|
||
<template webc:type="11ty" 11ty:type="md"> | ||
|
||
Canvases generally sit within a composition element to give them a layout context or they will flow outwards to fill the space. | ||
|
||
Canvases can provide padding for their content area, but should not generally dictate any other layout constraints. | ||
|
||
Typical examples of canvas components are: | ||
|
||
- Card - a box, often presented with an image, title, text and a call to action | ||
- Navbar - a floating element at the top of the page, containing the logo and main navigation | ||
- Hero - the first element in the main content of the page, containing the title and intro | ||
|
||
<img | ||
webc:is="eleventy-image" | ||
src="./src/docs/canvas/canvas.webp" | ||
alt="An example of UI with the canvas highlighted" | ||
/> | ||
|
||
<p class="codepen" data-height="300" data-theme-id="dark" data-default-tab="html,result" data-slug-hash="vYjypKv" data-pen-title="Canvas" data-preview="true" data-user="gavmck" style="height: 300px; box-sizing: border-box; display: flex; align-items: center; justify-content: center; border: 2px solid; margin: 1em 0; padding: 1em;"> | ||
<span>See the Pen <a href="https://codepen.io/gavmck/pen/vYjypKv"> | ||
Canvas</a> by gavmck (<a href="https://codepen.io/gavmck">@gavmck</a>) | ||
on <a href="https://codepen.io">CodePen</a>.</span> | ||
</p> | ||
<script async src="https://cpwebassets.codepen.io/assets/embed/ei.js" webc:keep></script> | ||
|
||
</template> |
This file was deleted.
Oops, something went wrong.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
--- | ||
layout: docs.webc | ||
title: Composition | ||
description: Compositions are an invisible element of the page that provides layout. | ||
tags: ['docs', 'Four Cs'] | ||
icon: composition | ||
previous: /docs/canvas/ | ||
next: /docs/the-realities/ | ||
--- | ||
|
||
<template webc:type="11ty" 11ty:type="md"> | ||
|
||
Compositions are solely concerned with creating structure and spacing. | ||
|
||
Typical examples of a composition component are: | ||
|
||
- Grid - creates a layout with grid cells arranged in columns and rows | ||
- Spacing - creates spacing between components or areas of the page | ||
- Container - sets a max width for a page, block of content or components | ||
|
||
<img | ||
webc:is="eleventy-image" | ||
src="./src/docs/composition/composition.webp" | ||
alt="An example of UI with the composition elements highlighted" | ||
/> | ||
|
||
<p class="codepen" data-height="300" data-theme-id="dark" data-default-tab="html,result" data-slug-hash="ExLNbbg" data-pen-title="Composition" data-preview="true" data-user="gavmck" style="height: 300px; box-sizing: border-box; display: flex; align-items: center; justify-content: center; border: 2px solid; margin: 1em 0; padding: 1em;"> | ||
<span>See the Pen <a href="https://codepen.io/gavmck/pen/ExLNbbg"> | ||
Composition</a> by gavmck (<a href="https://codepen.io/gavmck">@gavmck</a>) | ||
on <a href="https://codepen.io">CodePen</a>.</span> | ||
</p> | ||
<script async src="https://cpwebassets.codepen.io/assets/embed/ei.js" webc:keep></script> | ||
|
||
</template> |
This file was deleted.
Oops, something went wrong.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
--- | ||
layout: docs.webc | ||
title: Content | ||
description: Content components look after the general styles for text and images, but can extend to data-specific patterns such as user profiles or product information. | ||
tags: ['docs', 'Four Cs'] | ||
icon: content | ||
previous: /docs/the-solution/ | ||
next: /docs/controls/ | ||
--- | ||
|
||
<template webc:type="11ty" 11ty:type="md"> | ||
|
||
Content components are focused around text and images and the base level, but can extend into more specialised areas such as a person or a product. Content components are where the UI library can become more specialised towards the industry or product that the library is serving. | ||
|
||
Typical examples of content components are: | ||
|
||
- Heading - title elements, represented in HTML as h1-5 | ||
- Text - a piece of typographic content | ||
- Icon - a glyph representing something in the app ecosystem | ||
- Person, ProductSummary, PaymentDetails - product/industry-specific content | ||
|
||
<img | ||
webc:is="eleventy-image" | ||
src="./src/docs/content/content.webp" | ||
alt="An example of UI with content highlighted" | ||
/> | ||
|
||
<p class="codepen" data-height="300" data-theme-id="dark" data-default-tab="html,result" data-slug-hash="bGMBLgR" data-pen-title="Content" data-preview="true" data-user="gavmck" style="height: 300px; box-sizing: border-box; display: flex; align-items: center; justify-content: center; border: 2px solid; margin: 1em 0; padding: 1em;"> | ||
<span>See the Pen <a href="https://codepen.io/gavmck/pen/bGMBLgR"> | ||
Content</a> by gavmck (<a href="https://codepen.io/gavmck">@gavmck</a>) | ||
on <a href="https://codepen.io">CodePen</a>.</span> | ||
</p> | ||
<script async src="https://cpwebassets.codepen.io/assets/embed/ei.js" webc:keep></script> | ||
|
||
</template> |
This file was deleted.
Oops, something went wrong.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
--- | ||
layout: docs.webc | ||
title: Controls | ||
description: Controls are interactive elements of the page. | ||
tags: ['docs', 'Four Cs'] | ||
icon: controls | ||
previous: /docs/content/ | ||
next: /docs/canvas/ | ||
--- | ||
|
||
<template webc:type="11ty" 11ty:type="md"> | ||
|
||
Anything that can be clicked, dragged, typed into or accessed in some way with the mouse, keyboard or touch is a control. | ||
|
||
Typical examples of controls are: | ||
|
||
- Button - a clickable component that triggers an action, such as submitting a form | ||
- Link - a hypertext link that takes the user to another page or section of the app | ||
- Input - a form input that allows users to enter information | ||
|
||
<img | ||
webc:is="eleventy-image" | ||
src="./src/docs/controls/controls.webp" | ||
alt="An example of UI with controls highlighted" | ||
/> | ||
|
||
<p class="codepen" data-height="300" data-theme-id="dark" data-default-tab="html,result" data-slug-hash="NWMbyaw" data-pen-title="Controls" data-preview="true" data-user="gavmck" style="height: 300px; box-sizing: border-box; display: flex; align-items: center; justify-content: center; border: 2px solid; margin: 1em 0; padding: 1em;"> | ||
<span>See the Pen <a href="https://codepen.io/gavmck/pen/NWMbyaw"> | ||
Controls</a> by gavmck (<a href="https://codepen.io/gavmck">@gavmck</a>) | ||
on <a href="https://codepen.io">CodePen</a>.</span> | ||
</p> | ||
<script async src="https://cpwebassets.codepen.io/assets/embed/ei.js" webc:keep></script> | ||
|
||
</template> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters