File tree Expand file tree Collapse file tree 5 files changed +28
-5
lines changed
Expand file tree Collapse file tree 5 files changed +28
-5
lines changed Original file line number Diff line number Diff line change @@ -10,8 +10,6 @@ import Styled from './Icon.styled'
1010export const ICON_TEST_ID = 'ch-design-system-icon'
1111
1212function Icon ( {
13- className,
14- style,
1513 name,
1614 color,
1715 testId = ICON_TEST_ID ,
@@ -20,18 +18,18 @@ function Icon({
2018 marginRight = 0 ,
2119 marginBottom = 0 ,
2220 marginLeft = 0 ,
21+ ...props
2322} : IconProps ) {
2423 if ( _ . isNil ( icons [ name ] ) ) { return null }
2524
2625 return (
2726 < Styled
27+ { ...props }
2828 data-testid = { testId }
29- className = { className }
3029 color = { color }
3130 as = { icons [ name ] }
3231 width = { size }
3332 height = { size }
34- style = { style }
3533 marginTop = { marginTop }
3634 marginRight = { marginRight }
3735 marginBottom = { marginBottom }
Original file line number Diff line number Diff line change 1+ /* External dependencies */
2+ import React from 'react'
3+
14/* Internal dependencies */
25import { StylableComponentProps } from '../../types/ComponentProps'
36import { IconName } from './generated'
47
8+ type SVGProps = React . SVGProps < SVGSVGElement >
9+
510export enum IconSize {
611 L = 34 ,
712 Normal = 24 ,
@@ -18,7 +23,7 @@ export interface IconStyledProps {
1823 marginLeft : number
1924}
2025
21- export default interface IconProps extends StylableComponentProps {
26+ export default interface IconProps extends StylableComponentProps , Omit < SVGProps , 'ref' > {
2227 name : IconName
2328 color ?: string
2429 size ?: IconSize
Original file line number Diff line number Diff line change 1+ import React from 'react'
2+
3+ function SvgAppPlus ( props : React . SVGProps < SVGSVGElement > ) {
4+ return (
5+ < svg width = "1em" height = "1em" viewBox = "0 0 24 24" { ...props } >
6+ < path
7+ fill = "currentColor"
8+ fillRule = "evenodd"
9+ d = "M12 3v2H6.927A1.927 1.927 0 005 6.927v10.146C5 18.137 5.863 19 6.927 19h10.146A1.927 1.927 0 0019 17.073V12h2v5.073A3.928 3.928 0 0117.073 21H6.927A3.927 3.927 0 013 17.073V6.927A3.928 3.928 0 016.927 3H12zm6 0v3h3v2h-3v3h-2V8h-3V6h3V3h2z"
10+ />
11+ </ svg >
12+ )
13+ }
14+
15+ export default SvgAppPlus
Original file line number Diff line number Diff line change 22import All from './All'
33import Android from './Android'
44import AppCheck from './AppCheck'
5+ import AppPlus from './AppPlus'
56import AppPush from './AppPush'
67import Apple from './Apple'
78import AppsAdd from './AppsAdd'
@@ -328,6 +329,7 @@ const icons = {
328329 'all' : All ,
329330 'android' : Android ,
330331 'app-check' : AppCheck ,
332+ 'app-plus' : AppPlus ,
331333 'app-push' : AppPush ,
332334 'apple' : Apple ,
333335 'apps-add' : AppsAdd ,
You can’t perform that action at this time.
0 commit comments