Skip to content

Commit

Permalink
feat(media): add reject icon and some fixes
Browse files Browse the repository at this point in the history
feat(media): add reject icon and some fixes
  • Loading branch information
AndrewKhizhnyak authored and antongolub committed Apr 16, 2019
1 parent 9ffd16d commit 2ad7983
Show file tree
Hide file tree
Showing 8 changed files with 32 additions and 8 deletions.
3 changes: 3 additions & 0 deletions packages/media/src/icon/Icon.md
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,9 @@
<FlexItem shrink={0} width={6} height={6} m={3}>
<Icon name="success"/>
</FlexItem>
<FlexItem shrink={0} width={6} height={6} m={3}>
<Icon name="reject"/>
</FlexItem>
<FlexItem shrink={0} width={6} height={6} m={3}>
<Icon name="attention"/>
</FlexItem>
Expand Down
2 changes: 2 additions & 0 deletions packages/media/src/icon/Icon.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ import {
QiwiIcon,
ReceiptIcon,
RefundIcon,
RejectIcon,
RepeatIcon,
SearchIcon,
SendIcon,
Expand Down Expand Up @@ -151,6 +152,7 @@ const Icons: { [name in IconName]: FC } = {
qiwi: QiwiIcon,
receipt: ReceiptIcon,
refund: RefundIcon,
reject: RejectIcon,
repeat: RepeatIcon,
search: SearchIcon,
send: SendIcon,
Expand Down
1 change: 1 addition & 0 deletions packages/media/src/icon/IconName.ts
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ export type IconName =
'question' |
'receipt' |
'refund' |
'reject' |
'repeat' |
'search' |
'send' |
Expand Down
13 changes: 13 additions & 0 deletions packages/media/src/icon/RejectIcon.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import React from 'react'

const RejectIcon: React.FunctionComponent = () => (
<svg viewBox="0 0 24 24" focusable="false">
<circle cx="12" cy="12" r="12" />
<path
fill="#FFF"
d="M12 10.94l4.72-4.72a.75.75 0 0 1 1.06 1.06L13.06 12l4.72 4.72a.75.75 0 0 1-1.06 1.06L12 13.06l-4.72 4.72a.75.75 0 0 1-1.06-1.06L10.94 12 6.22 7.28a.75.75 0 0 1 1.06-1.06L12 10.94z"
/>
</svg>
)

export default RejectIcon
10 changes: 5 additions & 5 deletions packages/media/src/icon/SuccessIcon.tsx
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
import React from 'react'

const AttentionIcon: React.FunctionComponent = () => (
<svg viewBox="0 0 40 40" focusable="false">
<circle cx="20" cy="20" r="20" />
const SuccessIcon: React.FunctionComponent = () => (
<svg viewBox="0 0 24 24" focusable="false">
<circle cx="12" cy="12" r="12" />
<path
fill="#FFF"
d="M16.94 26.06a1.5 1.5 0 0 0 2.12 0L29 15.122A1.5 1.5 0 0 0 26.879 13L18 23l-2.94-3.06a1.5 1.5 0 0 0-2.12 2.12l4 4z"
d="M8.707 12.293a1 1 0 1 0-1.414 1.414l2.5 2.5a1 1 0 0 0 1.414 0l5.5-7.5a1 1 0 1 0-1.414-1.414L10.5 14.086l-1.793-1.793z"
/>
</svg>
)

export default AttentionIcon
export default SuccessIcon
6 changes: 3 additions & 3 deletions packages/media/src/icon/WaitingIcon.tsx
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
import React from 'react'

const WaitingIcon: React.FunctionComponent = () => (
<svg viewBox="0 0 40 40" focusable="false">
<circle cx="20" cy="20" r="20" />
<svg viewBox="0 0 24 24" focusable="false">
<circle cx="12" cy="12" r="12" />
<path
fill="#FFF"
d="M21.667 20.723l7.524 4.515a1.667 1.667 0 1 1-1.715 2.858l-8.333-5a1.667 1.667 0 0 1-.81-1.43V10a1.667 1.667 0 0 1 3.334 0v10.723z"
d="M13 12.434l4.514 2.709a1 1 0 0 1-1.028 1.714l-5-3A1 1 0 0 1 11 13V6a1 1 0 0 1 2 0v6.434z"
/>
</svg>
)
Expand Down
3 changes: 3 additions & 0 deletions packages/media/src/icon/WeakIcon.md
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,9 @@
<FlexItem shrink={0} width={6} height={6} m={3}>
<WeakIcon name="success"/>
</FlexItem>
<FlexItem shrink={0} width={6} height={6} m={3}>
<WeakIcon name="reject"/>
</FlexItem>
<FlexItem shrink={0} width={6} height={6} m={3}>
<WeakIcon name="attention"/>
</FlexItem>
Expand Down
2 changes: 2 additions & 0 deletions packages/media/src/icon/icons.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ import QuestionIcon from './QuestionIcon'
import QiwiIcon from './QiwiIcon'
import ReceiptIcon from './ReceiptIcon'
import RefundIcon from './RefundIcon'
import RejectIcon from './RejectIcon'
import RepeatIcon from './RepeatIcon'
import SearchIcon from './SearchIcon'
import SendIcon from './SendIcon'
Expand Down Expand Up @@ -144,6 +145,7 @@ export {
QiwiIcon,
ReceiptIcon,
RefundIcon,
RejectIcon,
RepeatIcon,
SearchIcon,
SendIcon,
Expand Down

0 comments on commit 2ad7983

Please sign in to comment.