Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion packages/docs/src/_includes/components/logo.njk
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@

<h3 class="c-logo">
<a href="/" class="c-logo__link" rel="home">
<img class="c-logo__img" src="https://patternlab.io/images/icon-atom.svg" alt="Pattern Lab">
<img class="c-logo__img" src="https://patternlab.io/images/icon-atom.svg" alt="Pattern Lab logo" aria-hidden="true">

<div class="c-logo__body">
<span class="c-logo__text">Pattern Lab</span>
Expand Down
2 changes: 1 addition & 1 deletion packages/docs/src/_includes/components/tree-subnav.njk
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
{% for entry in navPages %}
{% if entry.key == subnavCategory %}
<li class="c-tree-nav__subnav-item">
<a href="{{entry.url}}" class="c-tree-nav__subnav-link">{{ entry.title }}<a>
<a href="{{entry.url}}" class="c-tree-nav__subnav-link">{{ entry.title }}</a>
</li><!--end c-tree-nav__subnav-item -->
{% endif %}
{% endfor %}
Expand Down
22 changes: 10 additions & 12 deletions packages/docs/src/_includes/layouts/demos.njk
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,15 @@
{% set demoListItems = collections.demos %}

{% block content %}
<main id="main-content">
<div class="l-container">
{% include "components/page-header.njk" %}

<h2 class="c-section-header">In the wild</h2>
{% set demoListCategory = 'example' %}
{% include "partials/components/demo-list.njk" %}
<div class="l-container">
{% include "components/page-header.njk" %}

<h2 class="c-section-header">In the wild</h2>
{% set demoListCategory = 'example' %}
{% include "partials/components/demo-list.njk" %}

<h2 class="c-section-header">Starterkits</h2>
{% set demoListCategory = 'starterkit' %}
{% include "partials/components/demo-list.njk" %}
</div>
</main>
<h2 class="c-section-header">Starterkits</h2>
{% set demoListCategory = 'starterkit' %}
{% include "partials/components/demo-list.njk" %}
</div>
{% endblock %}
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
<div class="c-stacked-block__bar-dots"></div>
</div>
<div class="c-stacked-block__preview-content">
<iframe class="c-stacked-block__frame-item" src="{{item.data.refLink}}" sandbox="allow-same-origin allow-scripts allow-popups allow-forms allow-modals"></iframe>
<iframe title="preview of {{ item.data.title }}" class="c-stacked-block__frame-item" src="{{item.data.refLink}}" sandbox="allow-same-origin allow-scripts allow-popups allow-forms allow-modals"></iframe>
<div class="c-stacked-block__frame-overlay"></div>
</div>
</div>
Expand Down
44 changes: 22 additions & 22 deletions packages/docs/src/docs/advanced-config-options.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ eleventyNavigation:

Pattern Lab Node comes with a configuration file [(`patternlab-config.json`)](https://github.com/pattern-lab/patternlab-node/blob/master/packages/core/patternlab-config.json) that allows you to modify certain aspects of the system. The latest default values are included within. This file is shipped within [the editions](https://github.com/pattern-lab?utf8=%E2%9C%93&query=edition-node) or can be supplied from core and the command line interface. Below is a description of each configuration option and how it affects Pattern Lab Node.

### cacheBust
## cacheBust

Instructs Pattern Lab to append a unique query string to Javascript and CSS assets throughout the frontend.

Expand All @@ -21,13 +21,13 @@ Instructs Pattern Lab to append a unique query string to Javascript and CSS asse

**default**: `true`

### cleanPublic
## cleanPublic

Sets whether or not to delete `public.patterns/` upon each build of Pattern Lab. When set to false, [incremental builds](https://github.com/pattern-lab/patternlab-node/wiki/Incremental-Builds) are also enabled.

**default**: `true`

### defaultPattern
## defaultPattern

Sets a specific pattern upon launch of the styleguide. This pattern will not be available in the navigation, or in view all pages. The only way to get to it will be via a refresh. Set it using the [short-hand pattern-include syntax](/docs/including-patterns/):

Expand All @@ -39,19 +39,19 @@ A special value of `all` can also be supplied to display all patterns on load.

**default**: `all`

### defaultShowPatternInfo
## defaultShowPatternInfo

Sets whether or not you want the styleguide to load with the pattern info open or closed.

**default**: `false`

### defaultPatternInfoPanelCode (optional)
## defaultPatternInfoPanelCode (optional)

Sets default active pattern info code panel by file extension - if unset, uses the value out of _patternExtension_ config value, or instead use value `html` to display the html code initially, or the value defined for the _patternExtension_.

**default**: _patternExtension_ value (`"hbs"` | `"mustache"` | `"twig"` | `"html"`)

### ishControlsHide
## ishControlsHide

Sets whether or not to hide navigation options within the styleguide.

Expand All @@ -77,7 +77,7 @@ Sets whether or not to hide navigation options within the styleguide.
}
```

### ishViewportRange
## ishViewportRange

Sets the boundaries of each of the viewport toggles, 'S'mall, 'M'edium, and 'L'arge. Clicking on one of these buttons will randomly set the ish Viewport to a value within the given range. Setting the range to the same number can effectively set an exact value. The first entry in `ishViewportRange.s` is the `ishViewportMinimum`, which is now obsolete. The second entry in `ishViewportRange.l` is the `ishViewportMaximum`, which is now also obsolete.

Expand All @@ -91,7 +91,7 @@ Sets the boundaries of each of the viewport toggles, 'S'mall, 'M'edium, and 'L'a
},
```

### logLevel
## logLevel

Sets the level of verbosity for Pattern Lab Node logging.

Expand All @@ -105,7 +105,7 @@ This replaces the now obsolete `debug` flag.

**default**: `info`

### outputFileSuffixes
## outputFileSuffixes

Sets the naming of output pattern files. Suffixes are defined for 'rendered', 'rawTemplate', and 'markupOnly' files. This configuration is needed for some PatternEngines that use the same input and output file extensions. Most users will not have to change this.

Expand All @@ -117,7 +117,7 @@ Sets the naming of output pattern files. Suffixes are defined for 'rendered', 'r
},
```

### paths
## paths

Sets the configurable source and public directories for files Pattern Lab Node operates within. Build, copy, output, and server operations rely upon these paths. Some paths are relative to the current UIKit. See UIKit configuration for more info. Note the `patternlabFiles` which help create the front end styleguide. Note also the intentional repetition of the nested structure, made this way for maximum flexibility. These are unlikely to change unless you customize your environment or write custom UIKits.

Expand Down Expand Up @@ -158,13 +158,13 @@ Sets the configurable source and public directories for files Pattern Lab Node o
},
```

### patternExtension
## patternExtension

Sets the panel name and language for the code tab on the styleguide. Since this only accepts one value, this is a place where mixed pattern trees (different PatternEngines in the same instance of Pattern Lab) does not quite work.

**default**: `mustache`

### patternStateCascade
## patternStateCascade

See the [Pattern State Documentation](/docs/using-pattern-states/)

Expand All @@ -174,13 +174,13 @@ See the [Pattern State Documentation](/docs/using-pattern-states/)
"patternStateCascade": ["inprogress", "inreview", "complete"],
```

### patternExportDirectory
## patternExportDirectory

Sets the location that any export operations should output files to. This may be a relative or absolute path.

**default**: `./pattern_exports/`

### patternExportPatternPartials
## patternExportPatternPartials

Sets an array of patterns (using the [short-hand pattern-include syntax](/docs/including-patterns/)) to be exported after a build.

Expand All @@ -192,7 +192,7 @@ For example, to export the navigation, header, and footer, one might do:

**default**: `[]`

### patternMergeVariantArrays
## patternMergeVariantArrays

Used to override the merge behavior of pattern variants. For more information see [The Pseudo-Pattern File Data](docs/using-pseudo-patterns/#heading-the-pseudo-pattern-file-data).

Expand All @@ -205,7 +205,7 @@ Used to override the merge behavior of pattern variants. For more information se

**default**: `true` | `undefined`

### renderFlatPatternsOnViewAllPages
## renderFlatPatternsOnViewAllPages

Used to activate rendering flat patterns on view all pages and generate view all pages if only flat patterns are available

Expand All @@ -218,7 +218,7 @@ Used to activate rendering flat patterns on view all pages and generate view all

**default**: `false` | `undefined`

### serverOptions
## serverOptions

Sets [live-server options](https://github.com/pattern-lab/live-server#usage-from-node):

Expand All @@ -244,7 +244,7 @@ Sets [live-server options](https://github.com/pattern-lab/live-server#usage-from
},
```

### starterkitSubDir
## starterkitSubDir

[Starterkits](/docs/starterkits/) by convention house their files within the `dist/` directory. Should someone ever wish to change this, this key is available.

Expand All @@ -254,7 +254,7 @@ Sets [live-server options](https://github.com/pattern-lab/live-server#usage-from
"starterkitSubDir": "dist",
```

### styleGuideExcludes
## styleGuideExcludes

Sets whole pattern types to be excluded from the "All" patterns page on the styleguide. This is useful to decrease initial load of the styleguide. For example, to exlude all patterns under `templates` and `pages`, add the following:

Expand All @@ -269,7 +269,7 @@ These template and page patterns would still be accessible via navigation.

**default**: `[]`

### theme
## theme

Sets the theme options for the styleguide. There are five options:
* `"color"`
Expand Down Expand Up @@ -314,7 +314,7 @@ And `"logo"` lets you finetune the different aspects of the logo displayed on th
}
```

### transformedAssetTypes (optional)
## transformedAssetTypes (optional)

Prevent specific filetypes being copied from your `source` to your `public` folder like e.g. CSS preprocessor source files (`.scss`), you could specify those within an array of your pattern lab config:

Expand All @@ -328,7 +328,7 @@ These template and page patterns would still be accessible via navigation.

**default**: `[]`

### uikits
## uikits

Introduced in Pattern Lab Node v3, UIKits are a new term in the Pattern Lab [Ecosystem](/docs/overview-of-pattern-lab's-ecosystem/). They are an evolution of the original Styleguidekit pattern which separated front-end templates from front-end assets like stylesheets and code. The existing `styleguidekit-assets-default` and `styleguidekit-mustache-default` have merged into `uikit-workshop`.

Expand Down
8 changes: 4 additions & 4 deletions packages/docs/src/docs/editing-source-files.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,10 @@ When editing Pattern Lab you must put your files and edit them in the `./source/

For the most part you can organize `./source/` anyway you see fit. There are a few Pattern Lab-specific directories though. They are:

- `_annotations/` - where your annotations reside. [learn more](/docs/adding-annotations/).
- `_data/` - where the global data used to render your patterns resides. [learn more](/docs/overview-of-data/).
- `_meta/` - where the header and footer that get applied to all of your patterns resides. [learn more](/docs/modifying-the-pattern-header-and-footer/).
- `_patterns/` - where your patterns, pattern documentation, and pattern-specific data reside. [learn more](/docs/reorganizing-patterns/).
- `_annotations/` - where your annotations reside. [learn more about adding annotations](/docs/adding-annotations/).
- `_data/` - where the global data used to render your patterns resides. [learn more about (pattern) data](/docs/overview-of-data/).
- `_meta/` - where the header and footer that get applied to all of your patterns resides. [learn more about meta files](/docs/modifying-the-pattern-header-and-footer/).
- `_patterns/` - where your patterns, pattern documentation, and pattern-specific data reside. [learn more about how to organize patterns](/docs/reorganizing-patterns/).

## Configuring Pattern Lab Directories

Expand Down
2 changes: 1 addition & 1 deletion packages/docs/src/scss/abstracts/_variables.scss
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ $color-gray-02: #f2f2f2;
$color-gray-07: #eee;
$color-gray-13: #ddd;
$color-gray-27: #bbb;
$color-gray-50: #808080;
$color-gray-50: #777677;
$color-gray-60: #666;
$color-gray-73: #444;
$color-gray-88: #1f1f1f;
Expand Down
1 change: 1 addition & 0 deletions packages/docs/src/scss/base/_text.scss
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ code {
background: $color-brand-purple-light;
padding: 0.2rem;
line-height: 1.2;
color: $color-gray-60;
}

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export const NavButton = (props) => {
<span
class="pl-c-nav__link-icon"
dangerouslySetInnerHTML={{
__html: '<pl-icon name="arrow-down"></pl-icon>',
__html: '<pl-icon name="arrow-down" aria-hidden="true"></pl-icon>',
}}
/>
</button>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ export const NavTitle = (props) => {
<span
class="pl-c-nav__link-icon"
dangerouslySetInnerHTML={{
__html: '<pl-icon name="arrow-down"></pl-icon>',
__html: '<pl-icon name="arrow-down" aria-hidden="true"></pl-icon>',
}}
/>
<span className={`pl-c-nav__link-text`}>{props.children}</span>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export const NavToggle = (props) => {
<span
class="pl-c-nav__link-icon"
dangerouslySetInnerHTML={{
__html: '<pl-icon name="arrow-down"></pl-icon>',
__html: '<pl-icon name="arrow-down" aria-hidden="true"></pl-icon>',
}}
/>
</button>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,11 @@ class Drawer extends LitElement {
icon-only="true"
@click="${(_) => store.dispatch(updateDrawerState(false))}"
>
<pl-icon slot="after" name="close"></pl-icon>
<pl-icon
slot="after"
name="close"
aria-hidden="true"
></pl-icon>
</pl-button>
</div>
</div>
Expand All @@ -152,7 +156,11 @@ class Drawer extends LitElement {
<div class="pl-c-loader__content">
<div class="pl-c-loader__message">Loading Code Panel</div>
<div class="pl-c-loader__spinner">
<svg class="pl-c-loader-svg" viewBox="0 0 268 255">
<svg
class="pl-c-loader-svg"
viewBox="0 0 268 255"
aria-hidden="true"
>
<circle
class="pl-c-loader-svg__outer-circle"
cx="134.2"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,7 @@ class Header extends BaseLitComponent {
height="20"
width="20"
fill="currentColor"
aria-hidden="true"
></pl-icon>
<span class="is-vishidden">Toggle Menu</span>
</button>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@ class InfoToggle extends LitElement {
<pl-icon
name="${this.isDrawerOpen ? 'code-collapse' : 'code-expand'}"
slot="after"
aria-hidden="true"
></pl-icon>
</pl-button>
`;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ class LayoutToggle extends LitElement {
<pl-icon
slot="after"
name="${this.layoutMode === 'horizontal' ? 'layout-h' : 'layout-v'}"
aria-hidden="true"
></pl-icon>
</pl-button>
`;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,11 @@ class ThemeToggle extends LitElement {
>
Switch Theme

<pl-icon slot="after" name="theme-${this.themeMode}"></pl-icon>
<pl-icon
slot="after"
name="theme-${this.themeMode}"
aria-hidden="true"
></pl-icon>
</pl-button>
`;
}
Expand Down
Loading