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] Index glyph #7498

Merged
merged 6 commits into from
Feb 8, 2024
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
1 change: 1 addition & 0 deletions changelogs/upcoming/7498.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
- Added `index` glyph to `EuiIcon`
1 change: 1 addition & 0 deletions src-docs/src/views/icon/icons.js
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,7 @@ export const iconTypes = [
'iInCircle',
'image',
'importAction',
'index',
'indexClose',
'indexEdit',
'indexFlush',
Expand Down
18 changes: 18 additions & 0 deletions src/components/icon/__snapshots__/icon.test.tsx.snap
Original file line number Diff line number Diff line change
Expand Up @@ -3819,6 +3819,24 @@ exports[`EuiIcon props type importAction is rendered 1`] = `
</svg>
`;

exports[`EuiIcon props type index is rendered 1`] = `
<svg
aria-hidden="true"
class="euiIcon emotion-euiIcon-m-isLoaded"
data-icon-type="index"
data-is-loaded="true"
height="16"
role="img"
viewBox="0 0 16 16"
width="16"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M13 2H3v11h11v1H2V1h12v12h-1V2ZM6 5h5.999V4H6v1ZM4 5V4h1v1H4Zm2 3V7h6v1H6ZM4 8V7h1v1H4Zm2 3v-1h6v1H6Zm-2 0v-1h1v1H4Z"
/>
</svg>
`;

exports[`EuiIcon props type indexClose is rendered 1`] = `
<svg
aria-hidden="true"
Expand Down
34 changes: 34 additions & 0 deletions src/components/icon/assets/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
/*
* 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';
import type { SVGProps } from 'react';
interface SVGRProps {
title?: string;
titleId?: string;
}
const EuiIconIndex = ({
title,
titleId,
...props
}: SVGProps<SVGSVGElement> & SVGRProps) => (
<svg
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="M13 2H3v11h11v1H2V1h12v12h-1V2ZM6 5h5.999V4H6v1ZM4 5V4h1v1H4Zm2 3V7h6v1H6ZM4 8V7h1v1H4Zm2 3v-1h6v1H6Zm-2 0v-1h1v1H4Z" />
</svg>
);
export const icon = EuiIconIndex;
1 change: 1 addition & 0 deletions src/components/icon/icon_map.ts
Original file line number Diff line number Diff line change
Expand Up @@ -175,6 +175,7 @@ export const typeToPathMap = {
iInCircle: 'iInCircle',
image: 'image',
importAction: 'import',
index: 'index',
indexClose: 'index_close',
indexEdit: 'index_edit',
indexFlush: 'index_flush',
Expand Down
3 changes: 3 additions & 0 deletions src/components/icon/svgs/index.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading