@explorer-1/html 1.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.pre-commit-config.yaml +19 -0
- package/.stylelintcache +1 -0
- package/CHANGELOG.md +49 -0
- package/LICENSE +21 -0
- package/index.html +1202 -0
- package/package.json +55 -0
- package/postcss.config.js +7 -0
- package/src/assets/README.md +12 -0
- package/src/assets/fonts/README.md +12 -0
- package/src/assets/scss/styles.scss +1 -0
- package/src/components/AppBarInternal/AppBarInternal.js +102 -0
- package/src/components/BaseButton/BaseButton.js +115 -0
- package/src/components/BaseButton/BaseButton.stories.js +275 -0
- package/src/components/BaseImage/BaseImage.js +23 -0
- package/src/components/BaseImage/BaseImage.stories.js +85 -0
- package/src/components/BaseImagePlaceholder/BaseImagePlaceholder.js +47 -0
- package/src/components/BaseImagePlaceholder/BaseImagePlaceholder.stories.js +147 -0
- package/src/components/BaseLink/BaseLink.js +86 -0
- package/src/components/BaseLink/BaseLink.stories.js +114 -0
- package/src/components/FooterInternal/FooterInternal.js +156 -0
- package/src/components/FooterInternal/FooterInternal.stories.js +43 -0
- package/src/components/FooterInternal/FooterInternalContactList.js +30 -0
- package/src/components/HeaderInternal/HeaderInternal.docs.mdx +154 -0
- package/src/components/HeaderInternal/HeaderInternal.js +39 -0
- package/src/components/HeaderInternal/HeaderInternal.stories.js +64 -0
- package/src/components/Icons/IconArrow.js +20 -0
- package/src/components/Icons/IconCaret.js +19 -0
- package/src/components/Icons/IconClose.js +20 -0
- package/src/components/Icons/IconDownload.js +22 -0
- package/src/components/Icons/IconDropdown.js +19 -0
- package/src/components/Icons/IconExpand.js +20 -0
- package/src/components/Icons/IconExternal.js +19 -0
- package/src/components/Icons/IconMenu.js +20 -0
- package/src/components/Icons/IconNext.js +15 -0
- package/src/components/Icons/IconPrev.js +15 -0
- package/src/components/Icons/IconSearch.js +20 -0
- package/src/components/Icons/IconSocialEmail.js +20 -0
- package/src/components/Icons/IconSocialFacebook.js +20 -0
- package/src/components/Icons/IconSocialInstagram.js +23 -0
- package/src/components/Icons/IconSocialReddit.js +19 -0
- package/src/components/Icons/IconSocialTwitter.js +19 -0
- package/src/components/Icons/IconSocialYoutube.js +23 -0
- package/src/components/Icons/IconUser.js +16 -0
- package/src/components/LogoJPL/LogoJPL.docs.mdx +28 -0
- package/src/components/LogoJPL/LogoJPL.js +17 -0
- package/src/components/LogoJPL/LogoJPL.stories.js +40 -0
- package/src/components/MixinAnimationCaret/MixinAnimationCaret.js +42 -0
- package/src/components/MixinAnimationCaret/MixinAnimationCaret.stories.js +42 -0
- package/src/components/NavInternal/NavInternal.js +135 -0
- package/src/components/NavInternal/NavInternal.stories.js +68 -0
- package/src/components/NavInternal/NavInternalHighlight.js +64 -0
- package/src/components/NavInternal/NavInternalHighlight.stories.js +36 -0
- package/src/components/NavInternal/NavInternalPanel.js +88 -0
- package/src/components/NavInternal/NavInternalPanel.stories.js +248 -0
- package/src/components/NavInternal/NavInternalSection.js +47 -0
- package/src/components/NavInternal/NavInternalSection.stories.js +55 -0
- package/src/components/SearchInput/SearchInput.js +44 -0
- package/src/components/SearchInput/SearchInput.stories.js +30 -0
- package/src/main.js +6 -0
- package/stylelint.config.js +60 -0
- package/tailwind.config.js +19 -0
- package/tsconfig.json +23 -0
- package/vite.config.js +25 -0
|
@@ -0,0 +1,154 @@
|
|
|
1
|
+
import { Meta, Story, Canvas, Controls } from '@storybook/addon-docs/blocks'
|
|
2
|
+
import * as Stories from './HeaderInternal.stories'
|
|
3
|
+
import * as NavInternalPanelStories from './../NavInternal/NavInternalPanel.stories'
|
|
4
|
+
|
|
5
|
+
<Meta of={Stories} />
|
|
6
|
+
|
|
7
|
+
# Internal Header
|
|
8
|
+
|
|
9
|
+
Configurable to accommodate just an AppBar or complex site navigation, along with optional search and sign in/out buttons.
|
|
10
|
+
|
|
11
|
+
Note: to view with functioning dropdowns and search field expansion, you must switch to <strong>Canvas View</strong>.
|
|
12
|
+
|
|
13
|
+
- [With Navigation](#top)
|
|
14
|
+
- [With Sign In Buttons](#with-sign-in-buttons)
|
|
15
|
+
- [How to configure dropdowns and menu items](#configuring-dropdowns-and-menu-items)
|
|
16
|
+
- [AppBar Only](#just-the-appbar)
|
|
17
|
+
|
|
18
|
+
<span id="top"></span>
|
|
19
|
+
|
|
20
|
+
## With Navigation
|
|
21
|
+
|
|
22
|
+
<Canvas
|
|
23
|
+
className="sbdocs-preview-full-width"
|
|
24
|
+
of={Stories.Default}
|
|
25
|
+
/>
|
|
26
|
+
|
|
27
|
+
<span id="props"></span>
|
|
28
|
+
|
|
29
|
+
### Props
|
|
30
|
+
|
|
31
|
+
<Controls of={Stories.Default} />
|
|
32
|
+
|
|
33
|
+
<span id="with-sign-in-buttons"></span>
|
|
34
|
+
|
|
35
|
+
## With Sign In buttons
|
|
36
|
+
|
|
37
|
+
<Canvas
|
|
38
|
+
className="sbdocs-preview-full-width"
|
|
39
|
+
of={Stories.WithSignIn}
|
|
40
|
+
/>
|
|
41
|
+
|
|
42
|
+
<Controls of={Stories.WithSignIn} />
|
|
43
|
+
|
|
44
|
+
<span id="configuring-dropdowns-and-menu-items"></span>
|
|
45
|
+
|
|
46
|
+
## Configuring dropdowns and menu items
|
|
47
|
+
|
|
48
|
+
The create your own menu items, you can either copy the html template as rendered here and manually edit as needed, or you can populate the `menuItems` array to have the template generated for you in Storybook. Either way, be sure that each menu item is given a unique id.
|
|
49
|
+
|
|
50
|
+
To populate the `menuItems` array, a specific structure for each object in the array must be followed. Use the examples below as starting points to construct your array. You can then update the `menuItems` value in the [Props Table](#props) at the top of the page (or in Canvas view). Be sure to switch to raw data values when doing this.
|
|
51
|
+
|
|
52
|
+
Items in `menuItems` can be given a property of `isActive: true` to highlight them with a red underline to indicate that they are the page you are on (or section you are in).
|
|
53
|
+
|
|
54
|
+
### Example of a single menu item, no dropdown
|
|
55
|
+
|
|
56
|
+
```json
|
|
57
|
+
{ "id": 1, "title": "Home", "url": "#" }
|
|
58
|
+
```
|
|
59
|
+
|
|
60
|
+
The navigation assumes you are using relative links for local links and will auto-detect external links by checking for `h` (as in http or https) at the beginning of the url string.
|
|
61
|
+
|
|
62
|
+
```json
|
|
63
|
+
{ "id": 7, "title": "External", "url": "https://www.jpl.nasa.gov/" }
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
This data would create similar navigation links such as "Home" and "External" in the example [at the top of this page](#top)
|
|
67
|
+
|
|
68
|
+
### Example panel with a simple combination
|
|
69
|
+
|
|
70
|
+
One highlight, and several single-level nav items.
|
|
71
|
+
|
|
72
|
+
<Canvas
|
|
73
|
+
className="sbdocs-preview-full-width"
|
|
74
|
+
meta={NavInternalPanelStories}
|
|
75
|
+
of={NavInternalPanelStories.Default}
|
|
76
|
+
/>
|
|
77
|
+
|
|
78
|
+
<Controls
|
|
79
|
+
of={NavInternalPanelStories.Default}
|
|
80
|
+
include={['menuItems', 'highlights']}
|
|
81
|
+
/>
|
|
82
|
+
|
|
83
|
+
### Example panel with no highlights
|
|
84
|
+
|
|
85
|
+
<Canvas
|
|
86
|
+
className="sbdocs-preview-full-width"
|
|
87
|
+
meta={NavInternalPanelStories}
|
|
88
|
+
of={NavInternalPanelStories.NoHighlights}
|
|
89
|
+
/>
|
|
90
|
+
|
|
91
|
+
Note the lack of `highlights` in the data structure below:
|
|
92
|
+
|
|
93
|
+
<Controls
|
|
94
|
+
of={NavInternalPanelStories.NoHighlights}
|
|
95
|
+
include={['menuItems', 'highlights']}
|
|
96
|
+
/>
|
|
97
|
+
|
|
98
|
+
### Example panel with highlights only
|
|
99
|
+
|
|
100
|
+
<Canvas
|
|
101
|
+
className="sbdocs-preview-full-width"
|
|
102
|
+
meta={NavInternalPanelStories}
|
|
103
|
+
of={NavInternalPanelStories.AllHighlights}
|
|
104
|
+
/>
|
|
105
|
+
|
|
106
|
+
Note the lack of `menuItems` in the data structure below:
|
|
107
|
+
|
|
108
|
+
<Controls
|
|
109
|
+
of={NavInternalPanelStories.AllHighlights}
|
|
110
|
+
include={['menuItems', 'highlights']}
|
|
111
|
+
/>
|
|
112
|
+
|
|
113
|
+
### Example panel with navigation headings
|
|
114
|
+
|
|
115
|
+
<Canvas
|
|
116
|
+
className="sbdocs-preview-full-width"
|
|
117
|
+
meta={NavInternalPanelStories}
|
|
118
|
+
of={NavInternalPanelStories.WithHeadings}
|
|
119
|
+
/>
|
|
120
|
+
|
|
121
|
+
Note the nested `menuItems` array within each top-level `menuItem`. For more details on how these work, view the nav [Section](?path=/story/global-layout-headers-for-internal-sites-elements-panel--with-headings) documentation.
|
|
122
|
+
|
|
123
|
+
<Controls
|
|
124
|
+
of={NavInternalPanelStories.WithHeadings}
|
|
125
|
+
include={['menuItems', 'highlights']}
|
|
126
|
+
/>
|
|
127
|
+
|
|
128
|
+
### Example panel with a more complex combination
|
|
129
|
+
|
|
130
|
+
One highlight, section headings, and allowing breaks across columns.
|
|
131
|
+
|
|
132
|
+
<Canvas
|
|
133
|
+
className="sbdocs-preview-full-width"
|
|
134
|
+
meta={NavInternalPanelStories}
|
|
135
|
+
of={NavInternalPanelStories.Combination}
|
|
136
|
+
/>
|
|
137
|
+
|
|
138
|
+
<Controls of={NavInternalPanelStories.Combination} />
|
|
139
|
+
|
|
140
|
+
> In all of the above examples, `allowSectionBreaks` and `allowSectionColumns` can be modified as needed. For information on what these are, see documentation on the Internal Navigation [Panel](?path=/story/global-layout-headers-for-internal-sites-elements-panel--default)
|
|
141
|
+
|
|
142
|
+
<span id="just-the-appbar"></span>
|
|
143
|
+
|
|
144
|
+
## Just the AppBar
|
|
145
|
+
|
|
146
|
+
<Canvas of={Stories.AppBarOnly} />
|
|
147
|
+
|
|
148
|
+
<Controls of={Stories.AppBarOnly} />
|
|
149
|
+
|
|
150
|
+
### With Sign In buttons
|
|
151
|
+
|
|
152
|
+
<Canvas of={Stories.AppBarWithSignIn} />
|
|
153
|
+
|
|
154
|
+
<Controls of={Stories.AppBarWithSignIn} />
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { AppBarInternalTemplate } from './../AppBarInternal/AppBarInternal'
|
|
2
|
+
import { NavInternalTemplate } from './../NavInternal/NavInternal'
|
|
3
|
+
|
|
4
|
+
export const HeaderInternalTemplate = ({
|
|
5
|
+
orgNumber,
|
|
6
|
+
siteTitle,
|
|
7
|
+
includeSignIn,
|
|
8
|
+
includeSearch,
|
|
9
|
+
menuItems
|
|
10
|
+
}) => {
|
|
11
|
+
// prop defaults
|
|
12
|
+
if (!orgNumber) orgNumber = ''
|
|
13
|
+
if (!siteTitle) siteTitle = ''
|
|
14
|
+
if (includeSignIn == undefined) includeSignIn = false
|
|
15
|
+
if (includeSearch == undefined) includeSearch = false
|
|
16
|
+
if (!menuItems) menuItems = []
|
|
17
|
+
|
|
18
|
+
const AppBar = AppBarInternalTemplate({
|
|
19
|
+
orgNumber: orgNumber,
|
|
20
|
+
siteTitle: siteTitle,
|
|
21
|
+
includeMobileMenuToggle: menuItems.length > 0 ? true : false,
|
|
22
|
+
includeSignIn: includeSignIn
|
|
23
|
+
})
|
|
24
|
+
|
|
25
|
+
return `
|
|
26
|
+
<header id="HeaderInternal" class="sticky top-0 z-30">
|
|
27
|
+
${AppBar}
|
|
28
|
+
${
|
|
29
|
+
menuItems.length > 0
|
|
30
|
+
? `
|
|
31
|
+
${NavInternalTemplate({
|
|
32
|
+
includeSearch: includeSearch,
|
|
33
|
+
menuItems: menuItems
|
|
34
|
+
})}`
|
|
35
|
+
: ''
|
|
36
|
+
}
|
|
37
|
+
</header>
|
|
38
|
+
`
|
|
39
|
+
}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import { HeaderInternalTemplate } from './HeaderInternal'
|
|
2
|
+
import { NavInternalData } from './../NavInternal/NavInternal.stories'
|
|
3
|
+
|
|
4
|
+
export const HeaderInternalData = {
|
|
5
|
+
orgNumber: '18x',
|
|
6
|
+
siteTitle: 'DesignLab',
|
|
7
|
+
includeSignIn: false,
|
|
8
|
+
includeSearch: true,
|
|
9
|
+
menuItems: NavInternalData.menuItems
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
export default {
|
|
13
|
+
title: 'Internal Header',
|
|
14
|
+
excludeStories: /.*Data$/,
|
|
15
|
+
tags: ['!autodocs'],
|
|
16
|
+
argTypes: {
|
|
17
|
+
includeSearch: {
|
|
18
|
+
type: { name: 'boolean', required: false },
|
|
19
|
+
description:
|
|
20
|
+
"If search should be included in the nav. Set to `false` if all you need is the AppBar or if your application doesn't support search capabilities."
|
|
21
|
+
},
|
|
22
|
+
menuItems: {
|
|
23
|
+
type: { name: 'array', required: false },
|
|
24
|
+
description:
|
|
25
|
+
'Complex object containing all menu items, including highlights. Leave empty if all you need is the AppBar'
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
parameters: {
|
|
29
|
+
viewMode: 'docs',
|
|
30
|
+
layout: 'fullscreen',
|
|
31
|
+
docs: {
|
|
32
|
+
description: {
|
|
33
|
+
component:
|
|
34
|
+
'Configurable to accommodate just an AppBar or complex site navigation, along with optional search and sign in/out buttons'
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
export const Default = HeaderInternalTemplate.bind({})
|
|
41
|
+
Default.storyName = 'With Navigation'
|
|
42
|
+
Default.args = HeaderInternalData
|
|
43
|
+
|
|
44
|
+
export const WithSignIn = HeaderInternalTemplate.bind({})
|
|
45
|
+
WithSignIn.args = {
|
|
46
|
+
...HeaderInternalData,
|
|
47
|
+
includeSignIn: true
|
|
48
|
+
}
|
|
49
|
+
|
|
50
|
+
export const AppBarOnly = HeaderInternalTemplate.bind({})
|
|
51
|
+
AppBarOnly.args = {
|
|
52
|
+
...HeaderInternalData,
|
|
53
|
+
includeSignIn: true,
|
|
54
|
+
menuItems: [],
|
|
55
|
+
includeSearch: false
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
export const AppBarWithSignIn = HeaderInternalTemplate.bind({})
|
|
59
|
+
AppBarWithSignIn.args = {
|
|
60
|
+
...HeaderInternalData,
|
|
61
|
+
menuItems: [],
|
|
62
|
+
includeSearch: false,
|
|
63
|
+
includeSignIn: true
|
|
64
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export const IconArrowTemplate = ({ customClass }) => {
|
|
2
|
+
if (!customClass) customClass = ''
|
|
3
|
+
return `
|
|
4
|
+
<svg
|
|
5
|
+
class="IconArrow ${customClass}"
|
|
6
|
+
width="26"
|
|
7
|
+
height="16"
|
|
8
|
+
viewBox="0 0 26 16"
|
|
9
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
10
|
+
aria-hidden="true"
|
|
11
|
+
focusable="false"
|
|
12
|
+
>
|
|
13
|
+
<path
|
|
14
|
+
d="M17.935.929L25.006 8l-7.071 7.071-1.414-1.414L21.177 9H1V7h20.177l-4.656-4.657L17.935.93z"
|
|
15
|
+
fill="currentColor"
|
|
16
|
+
fill-rule="evenodd"
|
|
17
|
+
/>
|
|
18
|
+
</svg>
|
|
19
|
+
`
|
|
20
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
export const IconCaretTemplate = ({ customClass }) => {
|
|
2
|
+
if (!customClass) customClass = ''
|
|
3
|
+
return `
|
|
4
|
+
<svg
|
|
5
|
+
class="IconCaret ${customClass}"
|
|
6
|
+
width="8"
|
|
7
|
+
height="14"
|
|
8
|
+
viewBox="0 0 8 14"
|
|
9
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
10
|
+
aria-hidden="true"
|
|
11
|
+
focusable="false"
|
|
12
|
+
>
|
|
13
|
+
<path
|
|
14
|
+
d="M7.864 7.004L1.5 13.368.086 11.954l4.948-4.95-4.948-4.95L1.5.64l6.364 6.364z"
|
|
15
|
+
fill="currentColor"
|
|
16
|
+
/>
|
|
17
|
+
</svg>
|
|
18
|
+
`
|
|
19
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export const IconCloseTemplate = ({ customClass }) => {
|
|
2
|
+
if (!customClass) customClass = ''
|
|
3
|
+
return `
|
|
4
|
+
<svg
|
|
5
|
+
class="IconClose ${customClass}"
|
|
6
|
+
width="24"
|
|
7
|
+
height="24"
|
|
8
|
+
viewBox="0 0 24 24"
|
|
9
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
10
|
+
aria-hidden="true"
|
|
11
|
+
focusable="false"
|
|
12
|
+
>
|
|
13
|
+
<path
|
|
14
|
+
d="M21.192-.02l2.829 2.828L14.828 12l9.193 9.192-2.829 2.829L12 14.828l-9.192 9.193-2.829-2.829L9.172 12-.02 2.808 2.808-.021 12 9.172 21.192-.02z"
|
|
15
|
+
fill="currentColor"
|
|
16
|
+
fill-rule="evenodd"
|
|
17
|
+
/>
|
|
18
|
+
</svg>
|
|
19
|
+
`
|
|
20
|
+
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
export const IconDownloadTemplate = ({ customClass }) => {
|
|
2
|
+
if (!customClass) customClass = ''
|
|
3
|
+
return `
|
|
4
|
+
<svg
|
|
5
|
+
class="IconDownload ${customClass}"
|
|
6
|
+
width="24"
|
|
7
|
+
height="24"
|
|
8
|
+
viewBox="0 0 24 24"
|
|
9
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
10
|
+
aria-hidden="true"
|
|
11
|
+
focusable="false"
|
|
12
|
+
>
|
|
13
|
+
<g fill="none" fill-rule="evenodd">
|
|
14
|
+
<path
|
|
15
|
+
d="M2 16v6h20v-6h2v8H0v-8h2zM13.003 0v14.245l4.657-4.656 1.414 1.414-7.071 7.071-7.071-7.071 1.414-1.414 4.657 4.656V0h2z"
|
|
16
|
+
fill="currentColor"
|
|
17
|
+
fill-rule="nonzero"
|
|
18
|
+
/>
|
|
19
|
+
</g>
|
|
20
|
+
</svg>
|
|
21
|
+
`
|
|
22
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
export const IconDropdownTemplate = ({ customClass }) => {
|
|
2
|
+
if (!customClass) customClass = ''
|
|
3
|
+
return `
|
|
4
|
+
<svg
|
|
5
|
+
class="IconDropdown ${customClass}"
|
|
6
|
+
width="12"
|
|
7
|
+
height="8"
|
|
8
|
+
viewBox="0 0 12 8"
|
|
9
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
10
|
+
aria-hidden="true"
|
|
11
|
+
focusable="false"
|
|
12
|
+
>
|
|
13
|
+
<path
|
|
14
|
+
d="M.343 2L1.757.586 6 4.828 10.243.586 11.657 2 6 7.657.343 2z"
|
|
15
|
+
fill="currentColor"
|
|
16
|
+
/>
|
|
17
|
+
</svg>
|
|
18
|
+
`
|
|
19
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export const IconExpandTemplate = ({ customClass }) => {
|
|
2
|
+
if (!customClass) customClass = ''
|
|
3
|
+
return `
|
|
4
|
+
<svg
|
|
5
|
+
class="IconExpand ${customClass}"
|
|
6
|
+
width="60"
|
|
7
|
+
height="60"
|
|
8
|
+
viewBox="0 0 60 60"
|
|
9
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
10
|
+
aria-hidden="true"
|
|
11
|
+
focusable="false"
|
|
12
|
+
>
|
|
13
|
+
<path
|
|
14
|
+
d="M48 37v11H37v-2h9v-9h2zm-34 0v9h9v2H12V37h2zm9-25v2h-9v9h-2V12h11zm25 0v11h-2v-9h-9v-2h11z"
|
|
15
|
+
fill="currentColor"
|
|
16
|
+
fill-rule="evenodd"
|
|
17
|
+
/>
|
|
18
|
+
</svg>
|
|
19
|
+
`
|
|
20
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
export const IconExternalTemplate = ({ customClass }) => {
|
|
2
|
+
if (!customClass) customClass = ''
|
|
3
|
+
return `
|
|
4
|
+
<svg
|
|
5
|
+
class="IconExternal ${customClass}"
|
|
6
|
+
width="18"
|
|
7
|
+
height="18"
|
|
8
|
+
viewBox="0 0 18 18"
|
|
9
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
10
|
+
aria-hidden="true"
|
|
11
|
+
focusable="false"
|
|
12
|
+
>
|
|
13
|
+
<path
|
|
14
|
+
d="M7 2v2H2v12h12v-5h2v7H0V2h7zm11-2v8h-2V3.413l-8.243 8.244-1.414-1.414L14.585 2H10V0h8z"
|
|
15
|
+
fill="currentColor"
|
|
16
|
+
/>
|
|
17
|
+
</svg>
|
|
18
|
+
`
|
|
19
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export const IconMenuTemplate = ({ customClass }) => {
|
|
2
|
+
if (!customClass) customClass = ''
|
|
3
|
+
return `
|
|
4
|
+
<svg
|
|
5
|
+
class="IconMenu ${customClass}"
|
|
6
|
+
width="30"
|
|
7
|
+
height="26"
|
|
8
|
+
viewBox="0 0 30 26"
|
|
9
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
10
|
+
aria-hidden="true"
|
|
11
|
+
focusable="false"
|
|
12
|
+
>
|
|
13
|
+
<path
|
|
14
|
+
d="M30 22v4H0v-4h30zm0-11v4H0v-4h30zm0-11v4H0V0h30z"
|
|
15
|
+
fill="currentColor"
|
|
16
|
+
fill-rule="evenodd"
|
|
17
|
+
/>
|
|
18
|
+
</svg>
|
|
19
|
+
`
|
|
20
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export const IconNextTemplate = ({ customClass }) => {
|
|
2
|
+
if (!customClass) customClass = ''
|
|
3
|
+
return `
|
|
4
|
+
<svg viewBox="0 0 50 50" class="IconNext ${customClass}">
|
|
5
|
+
<path
|
|
6
|
+
fill-rule="evenodd"
|
|
7
|
+
clip-rule="evenodd"
|
|
8
|
+
d="M21 36.314l-1.414-1.415 9.9-9.899-9.9-9.9L21 13.687 32.314 25 21 36.314z"
|
|
9
|
+
fill="currentColor"
|
|
10
|
+
aria-hidden="true"
|
|
11
|
+
focusable="false"
|
|
12
|
+
/>
|
|
13
|
+
</svg>
|
|
14
|
+
`
|
|
15
|
+
}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export const IconPrevTemplate = ({ customClass }) => {
|
|
2
|
+
if (!customClass) customClass = ''
|
|
3
|
+
return `
|
|
4
|
+
<svg viewBox="0 0 50 50" class="IconPrev ${customClass}">
|
|
5
|
+
<path
|
|
6
|
+
fill-rule="evenodd"
|
|
7
|
+
clip-rule="evenodd"
|
|
8
|
+
d="M29 13.686l1.414 1.415-9.9 9.899 9.9 9.9L29 36.313 17.686 25 29 13.686z"
|
|
9
|
+
fill="currentColor"
|
|
10
|
+
aria-hidden="true"
|
|
11
|
+
focusable="false"
|
|
12
|
+
/>
|
|
13
|
+
</svg>
|
|
14
|
+
`
|
|
15
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export const IconSearchTemplate = ({ customClass }) => {
|
|
2
|
+
if (!customClass) customClass = ''
|
|
3
|
+
return `
|
|
4
|
+
<svg
|
|
5
|
+
class="IconSearch ${customClass}"
|
|
6
|
+
width="20"
|
|
7
|
+
height="20"
|
|
8
|
+
viewBox="0 0 20 20"
|
|
9
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
10
|
+
aria-hidden="true"
|
|
11
|
+
focusable="false"
|
|
12
|
+
|
|
13
|
+
>
|
|
14
|
+
<path
|
|
15
|
+
d="M8 0a8 8 0 016.096 13.181l5.293 5.294-1.414 1.414-5.357-5.356A8 8 0 118 0zm0 2a6 6 0 100 12A6 6 0 008 2z"
|
|
16
|
+
fill="currentColor"
|
|
17
|
+
/>
|
|
18
|
+
</svg>
|
|
19
|
+
`
|
|
20
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export const IconSocialEmailTemplate = ({ customClass }) => {
|
|
2
|
+
if (!customClass) customClass = ''
|
|
3
|
+
return `
|
|
4
|
+
<svg
|
|
5
|
+
class="IconSocialEmail ${customClass}"
|
|
6
|
+
width="22"
|
|
7
|
+
height="16"
|
|
8
|
+
viewBox="0 0 22 16"
|
|
9
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
10
|
+
aria-hidden="true"
|
|
11
|
+
focusable="false"
|
|
12
|
+
>
|
|
13
|
+
<path
|
|
14
|
+
d="M11 9l11-7v14H0V2l11 7zm11-9L11 7 0 0h22z"
|
|
15
|
+
fill="currentColor"
|
|
16
|
+
fill-rule="evenodd"
|
|
17
|
+
/>
|
|
18
|
+
</svg>
|
|
19
|
+
`
|
|
20
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export const IconSocialFacebookTemplate = ({ customClass }) => {
|
|
2
|
+
if (!customClass) customClass = ''
|
|
3
|
+
return `
|
|
4
|
+
<svg
|
|
5
|
+
class="IconSocialFacebook ${customClass}"
|
|
6
|
+
width="12"
|
|
7
|
+
height="23"
|
|
8
|
+
viewBox="0 0 12 23"
|
|
9
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
10
|
+
aria-hidden="true"
|
|
11
|
+
focusable="false"
|
|
12
|
+
>
|
|
13
|
+
<path
|
|
14
|
+
d="M11.214 12.84l.622-4.131h-3.89V6.028c0-1.13.543-2.232 2.285-2.232H12V.28S10.395 0 8.86 0C5.656 0 3.562 1.978 3.562 5.56V8.71H0v4.13h3.562v9.987a13.877 13.877 0 004.383 0V12.84h3.269"
|
|
15
|
+
fill="currentColor"
|
|
16
|
+
fill-rule="evenodd"
|
|
17
|
+
/>
|
|
18
|
+
</svg>
|
|
19
|
+
`
|
|
20
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export const IconSocialInstagramTemplate = ({ customClass }) => {
|
|
2
|
+
if (!customClass) customClass = ''
|
|
3
|
+
return `
|
|
4
|
+
<svg
|
|
5
|
+
class="IconSocialInstagram ${customClass}"
|
|
6
|
+
width="22"
|
|
7
|
+
height="22"
|
|
8
|
+
viewBox="0 0 22 22"
|
|
9
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
10
|
+
aria-hidden="true"
|
|
11
|
+
focusable="false"
|
|
12
|
+
>
|
|
13
|
+
<g fill="none" fill-rule="evenodd">
|
|
14
|
+
<path d="M0 0H24V24H0z" transform="translate(-1 -1)" />
|
|
15
|
+
<path
|
|
16
|
+
d="M13.092 1.008c2.01.003 2.427.019 3.438.065 1.17.054 1.97.24 2.67.511a5.39 5.39 0 011.947 1.269A5.39 5.39 0 0122.416 4.8c.272.7.457 1.5.51 2.67l.03.655.006.205c.02.581.028 1.211.03 2.578v2.191a80.391 80.391 0 01-.03 2.578l-.007.205-.028.655c-.053 1.17-.24 1.97-.511 2.67a5.39 5.39 0 01-1.269 1.947 5.39 5.39 0 01-1.947 1.269c-.7.272-1.5.457-2.67.51a89.3 89.3 0 01-.655.029l-.205.007c-.581.02-1.211.028-2.578.03h-2.191a80.392 80.392 0 01-2.578-.03l-.205-.007a89.299 89.299 0 01-.655-.028c-1.17-.054-1.97-.24-2.67-.511a5.39 5.39 0 01-1.947-1.269 5.39 5.39 0 01-1.269-1.947c-.272-.7-.457-1.5-.51-2.67-.047-1.01-.063-1.429-.066-3.438v-2.191c.003-2.01.019-2.427.065-3.438.054-1.17.24-1.97.511-2.67a5.39 5.39 0 011.269-1.947 5.39 5.39 0 011.947-1.269c.7-.272 1.5-.458 2.67-.51 1.01-.047 1.429-.063 3.438-.066zm.014 1.981h-2.22c-1.375.002-1.976.01-2.562.031l-.208.008a98.53 98.53 0 00-.563.024c-1.072.05-1.654.228-2.042.379-.513.2-.88.438-1.264.823a3.407 3.407 0 00-.823 1.264c-.15.388-.33.97-.379 2.042l-.024.563-.008.208c-.02.586-.029 1.187-.03 2.563v2.22c.002 1.942.017 2.34.062 3.333.05 1.072.229 1.654.38 2.042.199.513.437.88.822 1.264.384.385.75.623 1.264.823.388.15.97.33 2.042.379 1.04.047 1.426.06 3.612.063h1.664c2.185-.002 2.572-.016 3.611-.063 1.072-.05 1.654-.229 2.042-.38.513-.199.88-.437 1.264-.822.385-.384.623-.75.823-1.264.15-.388.33-.97.379-2.042.047-1.035.06-1.423.063-3.585v-1.717a86.876 86.876 0 00-.028-2.71l-.01-.312a98.528 98.528 0 00-.025-.563c-.05-1.072-.228-1.654-.379-2.042-.2-.513-.438-.88-.823-1.264a3.407 3.407 0 00-1.264-.823c-.388-.15-.97-.33-2.042-.379-.994-.045-1.391-.06-3.334-.063zM12.5 7a5.5 5.5 0 110 11 5.5 5.5 0 010-11zm0 1.93a3.57 3.57 0 100 7.14 3.57 3.57 0 000-7.14zM18 5a1 1 0 110 2 1 1 0 010-2z"
|
|
17
|
+
fill="currentColor"
|
|
18
|
+
transform="translate(-1 -1)"
|
|
19
|
+
/>
|
|
20
|
+
</g>
|
|
21
|
+
</svg>
|
|
22
|
+
`
|
|
23
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
export const IconSocialRedditTemplate = ({ customClass }) => {
|
|
2
|
+
if (!customClass) customClass = ''
|
|
3
|
+
return `
|
|
4
|
+
<svg
|
|
5
|
+
class="IconSocialReddit ${customClass}"
|
|
6
|
+
width="24"
|
|
7
|
+
height="22"
|
|
8
|
+
viewBox="0 0 24 22"
|
|
9
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
10
|
+
aria-hidden="true"
|
|
11
|
+
focusable="false"
|
|
12
|
+
>
|
|
13
|
+
<path
|
|
14
|
+
d="M24,11.187c0.001-1.449-1.172-2.625-2.622-2.626c-0.681-0.001-1.336,0.264-1.826,0.737 c-1.795-1.296-4.268-2.132-7.023-2.228l1.196-5.628l3.908,0.832c0.048,1.036,0.927,1.837,1.963,1.789s1.837-0.927,1.789-1.963 c-0.048-1.036-0.927-1.837-1.963-1.789c-0.683,0.032-1.295,0.432-1.597,1.045l-4.364-0.928c-0.253-0.054-0.502,0.108-0.556,0.361 l-1.336,6.28C8.775,7.146,6.263,7.984,4.444,9.294C3.399,8.289,1.738,8.322,0.733,9.366s-0.973,2.706,0.072,3.711 c0.218,0.21,0.472,0.381,0.748,0.504c-0.041,0.263-0.062,0.528-0.063,0.794c0,4.04,4.703,7.316,10.504,7.316 s10.504-3.275,10.504-7.316c0-0.264-0.021-0.528-0.062-0.789C23.387,13.167,24,12.226,24,11.187z M5.996,13.063 c0-1.036,0.84-1.876,1.875-1.876c1.036,0,1.876,0.84,1.876,1.875c0,1.036-0.839,1.876-1.875,1.876 C6.837,14.938,5.997,14.099,5.996,13.063z M16.455,18.02c-1.28,1.278-3.733,1.378-4.455,1.378s-3.175-0.099-4.453-1.378 c-0.19-0.19-0.19-0.498,0-0.687c0.19-0.19,0.498-0.19,0.687,0c0.807,0.807,2.533,1.093,3.767,1.093s2.959-0.286,3.767-1.094 c0.193-0.186,0.501-0.181,0.688,0.013C16.637,17.533,16.636,17.832,16.455,18.02L16.455,18.02z M16.125,14.939 c-1.036,0-1.876-0.84-1.876-1.876c0-1.036,0.84-1.876,1.876-1.876c1.036,0,1.876,0.84,1.876,1.876c0,0,0,0,0,0 C17.999,14.099,17.16,14.938,16.125,14.939z"
|
|
15
|
+
fill="currentColor"
|
|
16
|
+
/>
|
|
17
|
+
</svg>
|
|
18
|
+
`
|
|
19
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
export const IconSocialTwitterTemplate = ({ customClass }) => {
|
|
2
|
+
if (!customClass) customClass = ''
|
|
3
|
+
return `
|
|
4
|
+
<svg
|
|
5
|
+
class="IconSocialTwitter ${customClass}"
|
|
6
|
+
width="24"
|
|
7
|
+
height="24"
|
|
8
|
+
viewBox="0 0 24 24"
|
|
9
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
10
|
+
aria-hidden="true"
|
|
11
|
+
focusable="false"
|
|
12
|
+
>
|
|
13
|
+
<path
|
|
14
|
+
d="M14.2,10.2L23,0h-2.1l-7.6,8.8L7.3,0h-7l9.2,13.3L0.3,24h2.1l8-9.3l6.4,9.3h7L14.2,10.2L14.2,10.2z M11.4,13.5 l-0.9-1.3L3.1,1.6h3.2l6,8.5l0.9,1.3l7.8,11.1h-3.2L11.4,13.5L11.4,13.5z"
|
|
15
|
+
fill="currentColor"
|
|
16
|
+
/>
|
|
17
|
+
</svg>
|
|
18
|
+
`
|
|
19
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
export const IconSocialYoutubeTemplate = ({ customClass }) => {
|
|
2
|
+
if (!customClass) customClass = ''
|
|
3
|
+
return `
|
|
4
|
+
<svg
|
|
5
|
+
class="IconSocialYoutube ${customClass}"
|
|
6
|
+
width="24"
|
|
7
|
+
height="16"
|
|
8
|
+
viewBox="0 0 24 16"
|
|
9
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
10
|
+
aria-hidden="true"
|
|
11
|
+
focusable="false"
|
|
12
|
+
>
|
|
13
|
+
<g fill="none" fill-rule="evenodd">
|
|
14
|
+
<path d="M0 0H24V24H0z" transform="translate(0 -4)" />
|
|
15
|
+
<path
|
|
16
|
+
d="M12.239 4l.1.001.248.001c.88.006 2.62.025 4.352.089l.546.021c1.632.07 3.175.183 3.892.366 1.032.262 1.845 1.037 2.121 2.02.455 1.616.498 4.822.502 5.409v.186c-.004.587-.047 3.793-.502 5.409-.276.983-1.089 1.758-2.121 2.02-1.713.437-8.14.475-9.222.478h-.31c-1.082-.003-7.51-.04-9.222-.478-1.032-.262-1.845-1.037-2.121-2.02-.44-1.56-.494-4.603-.501-5.339v-.326c.007-.737.062-3.779.5-5.339.277-.983 1.09-1.758 2.122-2.02.797-.204 2.613-.32 4.437-.387l.547-.02c1.543-.048 3.019-.064 3.805-.069l.248-.001h.1zM10 8.5v7l6-3.5-6-3.5z"
|
|
17
|
+
fill="currentColor"
|
|
18
|
+
transform="translate(0 -4)"
|
|
19
|
+
/>
|
|
20
|
+
</g>
|
|
21
|
+
</svg>
|
|
22
|
+
`
|
|
23
|
+
}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
export const IconUserTemplate = ({ customClass }) => {
|
|
2
|
+
if (!customClass) customClass = ''
|
|
3
|
+
return `
|
|
4
|
+
<svg
|
|
5
|
+
class="IconUser ${customClass}"
|
|
6
|
+
width="21"
|
|
7
|
+
height="21"
|
|
8
|
+
viewBox="0 0 21 21"
|
|
9
|
+
xmlns="http://www.w3.org/2000/svg"
|
|
10
|
+
aria-hidden="true"
|
|
11
|
+
focusable="false"
|
|
12
|
+
>
|
|
13
|
+
<path d="M10.5 0C4.7 0 0 4.7 0 10.5S4.7 21 10.5 21 21 16.3 21 10.5 16.3 0 10.5 0zm5.42 17.867c-1.525 1.143-3.43 1.778-5.42 1.778-2.032 0-3.938-.635-5.42-1.778v-.593a2.701 2.701 0 0 1 2.71-2.71c.466 0 1.143.509 2.71.509 1.524 0 2.202-.508 2.71-.508a2.729 2.729 0 0 1 2.71 2.71v.592zm1.27-1.143c-.297-1.99-1.948-3.514-3.98-3.514-.89 0-1.313.508-2.71.508-1.44 0-1.863-.508-2.71-.508-2.074 0-3.725 1.524-4.022 3.514-1.524-1.651-2.413-3.81-2.413-6.224A9.134 9.134 0 0 1 10.5 1.355c5.038 0 9.145 4.107 9.145 9.145 0 2.413-.931 4.573-2.456 6.224zM10.5 4.742a3.731 3.731 0 0 0-3.726 3.726 3.704 3.704 0 0 0 3.726 3.726 3.731 3.731 0 0 0 3.726-3.726c0-2.033-1.694-3.726-3.726-3.726zm0 6.097a2.367 2.367 0 0 1-2.371-2.371c0-1.27 1.059-2.371 2.371-2.371 1.27 0 2.371 1.1 2.371 2.37 0 1.313-1.1 2.372-2.371 2.372z" fill="currentColor"/>
|
|
14
|
+
</svg>
|
|
15
|
+
`
|
|
16
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { Meta, Story, Canvas } from '@storybook/addon-docs/blocks'
|
|
2
|
+
import * as Stories from './LogoJPL.stories'
|
|
3
|
+
|
|
4
|
+
<Meta of={Stories} />
|
|
5
|
+
|
|
6
|
+
# JPL Logo
|
|
7
|
+
|
|
8
|
+
The JPL Logo has strict color usage restrictions and should only be used on internal sites, namely in the [AppBar](?path=/docs/global-layout-headers-for-internal-sites-elements-overview--docs).
|
|
9
|
+
|
|
10
|
+
You can change the size of the logo by using [TailwindCSS width classes](https://v2.tailwindcss.com/docs/width). Explorer 1 includes other widths not documented by Tailwind. You can find all custom widths in the [appendix](?path=/docs/appendix-tailwindcss--docs), in the `extend.spacing` object.
|
|
11
|
+
|
|
12
|
+
## On light backgrounds
|
|
13
|
+
|
|
14
|
+
### Standard
|
|
15
|
+
|
|
16
|
+
<Canvas of={Stories.Default} />
|
|
17
|
+
|
|
18
|
+
<span id="with-sign-in-buttons"></span>
|
|
19
|
+
|
|
20
|
+
### Black
|
|
21
|
+
|
|
22
|
+
<Canvas of={Stories.Black} />
|
|
23
|
+
|
|
24
|
+
## On dark backgrounds
|
|
25
|
+
|
|
26
|
+
### White
|
|
27
|
+
|
|
28
|
+
<Canvas of={Stories.White} />
|