Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[EuiIcon] Add launch and spaces glyphs #6260

Merged
merged 3 commits into from
Sep 23, 2022
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: 2 additions & 0 deletions src-docs/src/views/icon/icons.js
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,7 @@ export const iconTypes = [
'kqlValue',
'kubernetesNode',
'kubernetesPod',
'launch',
'layers',
'lettering',
'lineDashed',
Expand Down Expand Up @@ -208,6 +209,7 @@ export const iconTypes = [
'sortLeft',
'sortRight',
'sortUp',
'spaces',
'starEmpty',
'starEmptySpace',
'starFilled',
Expand Down
48 changes: 48 additions & 0 deletions src/components/icon/__snapshots__/icon.test.tsx.snap
Original file line number Diff line number Diff line change
Expand Up @@ -4009,6 +4009,33 @@ exports[`EuiIcon props type kubernetesPod is rendered 1`] = `
</svg>
`;

exports[`EuiIcon props type launch is rendered 1`] = `
<svg
aria-hidden="true"
class="euiIcon emotion-euiIcon-m-isLoaded"
data-icon-type="launch"
data-is-loaded="true"
fill="none"
height="16"
role="img"
viewBox="0 0 16 16"
width="16"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M11 6a1 1 0 11-2 0 1 1 0 012 0z"
/>
<path
clip-rule="evenodd"
d="M10.355 1.791A3.5 3.5 0 0112.57 1H14a1 1 0 011 1v1.43a3.5 3.5 0 01-.791 2.215l-3.144 3.843a2.5 2.5 0 00-.565 1.583v1.636l-1.646 1.647a.5.5 0 01-.557.103l-.634-.282a11.5 11.5 0 01-5.838-5.838l-.282-.634a.5.5 0 01.103-.557L3.293 5.5h1.636a2.5 2.5 0 001.583-.565l3.843-3.144zM12.57 2a2.5 2.5 0 00-1.583.565L7.145 5.71a3.5 3.5 0 01-2.215.79H3.707l-1.11 1.11.142.32a10.498 10.498 0 001.825 2.799l2.082-2.083a.5.5 0 11.708.708L5.27 11.436a10.496 10.496 0 002.798 1.825l.32.143L9.5 12.293V11.07a3.5 3.5 0 01.791-2.216l3.144-3.843A2.5 2.5 0 0014 3.43V2h-1.43z"
fill-rule="evenodd"
/>
<path
d="M1.9 10.7a.5.5 0 00-.88.163l-1 3.5A.5.5 0 000 14.5v1a.5.5 0 00.5.5h1a.502.502 0 00.137-.02l3.5-1a.5.5 0 00.163-.88l-1.314-.986a5.5 5.5 0 01-1.1-1.1L1.9 10.7z"
/>
</svg>
`;

exports[`EuiIcon props type layers is rendered 1`] = `
<svg
aria-hidden="true"
Expand Down Expand Up @@ -8388,6 +8415,27 @@ exports[`EuiIcon props type sortable is rendered 1`] = `
</svg>
`;

exports[`EuiIcon props type spaces is rendered 1`] = `
<svg
aria-hidden="true"
class="euiIcon emotion-euiIcon-m-isLoaded"
data-icon-type="spaces"
data-is-loaded="true"
fill="none"
height="16"
role="img"
viewBox="0 0 16 16"
width="16"
xmlns="http://www.w3.org/2000/svg"
>
<path
clip-rule="evenodd"
d="M6 3H3v3h3V3zM3 2a1 1 0 00-1 1v3a1 1 0 001 1h3a1 1 0 001-1V3a1 1 0 00-1-1H3zm3 8H3v3h3v-3zM3 9a1 1 0 00-1 1v3a1 1 0 001 1h3a1 1 0 001-1v-3a1 1 0 00-1-1H3zm10-6h-3v3h3V3zm-3-1a1 1 0 00-1 1v3a1 1 0 001 1h3a1 1 0 001-1V3a1 1 0 00-1-1h-3zm3 8h-3v3h3v-3zm-3-1a1 1 0 00-1 1v3a1 1 0 001 1h3a1 1 0 001-1v-3a1 1 0 00-1-1h-3z"
fill-rule="evenodd"
/>
</svg>
`;

exports[`EuiIcon props type spacesApp is rendered 1`] = `
<svg
aria-hidden="true"
Expand Down
42 changes: 42 additions & 0 deletions src/components/icon/assets/launch.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Elastic License
* 2.0 and the Server Side Public License, v 1; you may not use this file except
* in compliance with, at your election, the Elastic License 2.0 or the Server
* Side Public License, v 1.
*/

// THIS IS A GENERATED FILE. DO NOT MODIFY MANUALLY. @see scripts/compile-icons.js

import * as React from 'react';
interface SVGRProps {
title?: string;
titleId?: string;
}

const EuiIconLaunch = ({
title,
titleId,
...props
}: React.SVGProps<SVGSVGElement> & SVGRProps) => (
<svg
fill="none"
xmlns="http://www.w3.org/2000/svg"
width={16}
height={16}
viewBox="0 0 16 16"
aria-labelledby={titleId}
{...props}
>
{title ? <title id={titleId}>{title}</title> : null}
<path d="M11 6a1 1 0 11-2 0 1 1 0 012 0z" />
<path
fillRule="evenodd"
clipRule="evenodd"
d="M10.355 1.791A3.5 3.5 0 0112.57 1H14a1 1 0 011 1v1.43a3.5 3.5 0 01-.791 2.215l-3.144 3.843a2.5 2.5 0 00-.565 1.583v1.636l-1.646 1.647a.5.5 0 01-.557.103l-.634-.282a11.5 11.5 0 01-5.838-5.838l-.282-.634a.5.5 0 01.103-.557L3.293 5.5h1.636a2.5 2.5 0 001.583-.565l3.843-3.144zM12.57 2a2.5 2.5 0 00-1.583.565L7.145 5.71a3.5 3.5 0 01-2.215.79H3.707l-1.11 1.11.142.32a10.498 10.498 0 001.825 2.799l2.082-2.083a.5.5 0 11.708.708L5.27 11.436a10.496 10.496 0 002.798 1.825l.32.143L9.5 12.293V11.07a3.5 3.5 0 01.791-2.216l3.144-3.843A2.5 2.5 0 0014 3.43V2h-1.43z"
/>
<path d="M1.9 10.7a.5.5 0 00-.88.163l-1 3.5A.5.5 0 000 14.5v1a.5.5 0 00.5.5h1a.502.502 0 00.137-.02l3.5-1a.5.5 0 00.163-.88l-1.314-.986a5.5 5.5 0 01-1.1-1.1L1.9 10.7z" />
</svg>
);

export const icon = EuiIconLaunch;
40 changes: 40 additions & 0 deletions src/components/icon/assets/spaces.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Elastic License
* 2.0 and the Server Side Public License, v 1; you may not use this file except
* in compliance with, at your election, the Elastic License 2.0 or the Server
* Side Public License, v 1.
*/

// THIS IS A GENERATED FILE. DO NOT MODIFY MANUALLY. @see scripts/compile-icons.js

import * as React from 'react';
interface SVGRProps {
title?: string;
titleId?: string;
}

const EuiIconSpaces = ({
title,
titleId,
...props
}: React.SVGProps<SVGSVGElement> & SVGRProps) => (
<svg
fill="none"
xmlns="http://www.w3.org/2000/svg"
width={16}
height={16}
viewBox="0 0 16 16"
aria-labelledby={titleId}
{...props}
>
{title ? <title id={titleId}>{title}</title> : null}
<path
fillRule="evenodd"
clipRule="evenodd"
d="M6 3H3v3h3V3zM3 2a1 1 0 00-1 1v3a1 1 0 001 1h3a1 1 0 001-1V3a1 1 0 00-1-1H3zm3 8H3v3h3v-3zM3 9a1 1 0 00-1 1v3a1 1 0 001 1h3a1 1 0 001-1v-3a1 1 0 00-1-1H3zm10-6h-3v3h3V3zm-3-1a1 1 0 00-1 1v3a1 1 0 001 1h3a1 1 0 001-1V3a1 1 0 00-1-1h-3zm3 8h-3v3h3v-3zm-3-1a1 1 0 00-1 1v3a1 1 0 001 1h3a1 1 0 001-1v-3a1 1 0 00-1-1h-3z"
/>
</svg>
);

export const icon = EuiIconSpaces;
2 changes: 2 additions & 0 deletions src/components/icon/icon_map.ts
Original file line number Diff line number Diff line change
Expand Up @@ -186,6 +186,7 @@ export const typeToPathMap = {
kqlValue: 'kql_value',
kubernetesNode: 'kubernetesNode',
kubernetesPod: 'kubernetesPod',
launch: 'launch',
layers: 'layers',
lensApp: 'app_lens',
lettering: 'lettering',
Expand Down Expand Up @@ -338,6 +339,7 @@ export const typeToPathMap = {
sortRight: 'sortRight',
sortUp: 'sort_up',
sortable: 'sortable',
spaces: 'spaces',
spacesApp: 'app_spaces',
sqlApp: 'app_sql',
starEmpty: 'star_empty',
Expand Down
5 changes: 5 additions & 0 deletions src/components/icon/svgs/launch.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions src/components/icon/svgs/spaces.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions upcoming_changelogs/6260.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- Added `launch` and `spaces` glyphs to `EuiIcon`