Skip to content

Commit

Permalink
Added partial glyph to EuiIcon (#2152)
Browse files Browse the repository at this point in the history
  • Loading branch information
cchaos authored Jul 23, 2019
1 parent 9105457 commit 72c3d97
Show file tree
Hide file tree
Showing 6 changed files with 35 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ No public interface changes since `13.0.0`.
- Added `transition` utility services to help create timeouts that account for CSS transition durations and delays ([#2136](https://github.com/elastic/eui/pull/2136))
- Removed `EuiFlexGroup` dependency from `EuiAccordion` ([#2143](https://github.com/elastic/eui/pull/2143))
- Exported `prettyDuration` and `commonDurationRanges` for pretty printing date ranges outside `EuiSuperDatePicker` ([#2132](https://github.com/elastic/eui/pull/2132))
- Added `partial` glyph to `EuiIcon` ([#2152](https://github.com/elastic/eui/pull/2152))

**Bug fixes**

Expand Down
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 @@ -126,6 +126,7 @@ const iconTypes = [
'number',
'offline',
'online',
'partial',
'pause',
'pencil',
'pin',
Expand Down
15 changes: 15 additions & 0 deletions src/components/icon/__snapshots__/icon.test.tsx.snap
Original file line number Diff line number Diff line change
Expand Up @@ -5408,6 +5408,21 @@ exports[`EuiIcon props type packetbeatApp is rendered 1`] = `
</svg>
`;

exports[`EuiIcon props type partial is rendered 1`] = `
<svg
class="euiIcon euiIcon--medium euiIcon-isLoaded"
focusable="false"
height="16"
viewBox="0 0 16 16"
width="16"
xmlns="http://www.w3.org/2000/svg"
>
<path
d="M6.664 14.871a7 7 0 0 1-2.42-12.778.5.5 0 0 1 .612.06c.456.431 8.216 8.212 8.98 9.002a.5.5 0 0 1 .063.618 7.002 7.002 0 0 1-7.235 3.098zm6.168-3.312a1961.733 1961.733 0 0 0-8.377-8.4 6 6 0 1 0 8.378 8.4zm2.095-2.548a.5.5 0 1 1-.99-.144c.01-.066.01-.066.018-.133a6.007 6.007 0 0 0-.034-1.714.5.5 0 1 1 .987-.163c.108.655.122 1.326.04 1.999l-.021.155zm-1.273-5.138a.5.5 0 1 1-.808.59 6.026 6.026 0 0 0-1.304-1.308.5.5 0 0 1 .59-.806 7.026 7.026 0 0 1 1.522 1.524zM9.169 1.098a.5.5 0 1 1-.166.986 6.105 6.105 0 0 0-1.849-.026.5.5 0 0 1-.14-.99 7.02 7.02 0 0 1 2.155.03z"
/>
</svg>
`;

exports[`EuiIcon props type pause is rendered 1`] = `
<svg
class="euiIcon euiIcon--medium euiIcon-isLoaded"
Expand Down
14 changes: 14 additions & 0 deletions src/components/icon/assets/partial.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import React from 'react';

const EuiIconPartial = props => (
<svg
width={16}
height={16}
viewBox="0 0 16 16"
xmlns="http://www.w3.org/2000/svg"
{...props}>
<path d="M6.664 14.871a7 7 0 0 1-2.42-12.778.5.5 0 0 1 .612.06c.456.431 8.216 8.212 8.98 9.002a.5.5 0 0 1 .063.618 7.002 7.002 0 0 1-7.235 3.098zm6.168-3.312a1961.733 1961.733 0 0 0-8.377-8.4 6 6 0 1 0 8.378 8.4zm2.095-2.548a.5.5 0 1 1-.99-.144c.01-.066.01-.066.018-.133a6.007 6.007 0 0 0-.034-1.714.5.5 0 1 1 .987-.163c.108.655.122 1.326.04 1.999l-.021.155zm-1.273-5.138a.5.5 0 1 1-.808.59 6.026 6.026 0 0 0-1.304-1.308.5.5 0 0 1 .59-.806 7.026 7.026 0 0 1 1.522 1.524zM9.169 1.098a.5.5 0 1 1-.166.986 6.105 6.105 0 0 0-1.849-.026.5.5 0 0 1-.14-.99 7.02 7.02 0 0 1 2.155.03z" />
</svg>
);

export const icon = EuiIconPartial;
3 changes: 3 additions & 0 deletions src/components/icon/assets/partial.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 src/components/icon/icon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -238,6 +238,7 @@ const typeToPathMap = {
offline: 'offline',
online: 'online',
packetbeatApp: 'app_packetbeat',
partial: 'partial',
pause: 'pause',
pencil: 'pencil',
pin: 'pin',
Expand Down

0 comments on commit 72c3d97

Please sign in to comment.